Hardware · SWD
Connect a debug probe
To flash and debug, your STM32 talks to a debug probe over four SWD wires. Nucleo boards have a built-in ST-Link, so they need no wiring — but bare boards like the Black Pill require an external probe (ST-Link, DAPLink, and similar). This guide wires up an ST-Link V2; step through it below — each tap draws and highlights one jumper at a time.
Ready when you are
Press Next wire to connect the first jumper. You can step forward and back through all four SWD connections.
The four connections
Block Designer flashes over ST-Link / OpenOCD, so these four pins are all you need for both flashing and live debugging:
| # | ST-Link V2 | Black Pill | Wire | |
|---|---|---|---|---|
| 1 | GND | → | GND | |
| 2 | SWCLK | → | SCK | |
| 3 | SWDIO | → | DIO | |
| 4 | 3.3V | → | 3V3 |
3.3V wire off. Feeding
3.3V from the ST-Link and USB at once can back-feed the regulators.
GND + SWCLK + SWDIO are enough to flash a self-powered board.
Once it's wired
Plug the ST-Link into your computer's USB, head back to Flash to hardware, and click Program STM32. Block Designer probes the attached chip, generates firmware, and flashes it over this SWD link.
Wiring not taking? Open a discussion or file an issue — happy to help.