Buying guide · Intermediate · 3 min read
Programmers and Debug Probes
USBasp, ST-Link, J-Link
By Geekobot Learning Team · Updated 24 Oct 2026
On this page
A programmer writes firmware into a chip without a bootloader, and a debug probe also lets you pause code, step through it and inspect variables. Use a USBasp or Arduino as ISP for AVR chips such as the ATmega328P. Use an ST-Link or a CMSIS-DAP probe over SWD for STM32, RP2040 and other Arm chips. Always match the target voltage and connect ground first.
Key specs at a glance
- USBasp
- AVR ISP programmer, 6- or 10-pin header, 3.3/5 V jumper
- ST-Link V2
- SWD for STM32 (and many Cortex-M via OpenOCD)
- CMSIS-DAP / Picoprobe
- Open-standard SWD probes; a spare Pico can be one
- J-Link
- Fast commercial probe supporting most Arm chips
- SWD pins
- SWDIO, SWCLK, GND, optional 3.3 V sense and NRST
- Software
- avrdude, STM32CubeProgrammer, OpenOCD, PlatformIO
Which tool for which chip
| Target | Interface | Tool |
|---|---|---|
| ATmega328P, ATtiny85 | ISP (SPI) | USBasp, Arduino as ISP |
| STM32 Blue Pill, Black Pill | SWD | ST-Link V2, CMSIS-DAP |
| RP2040 / Pico | SWD (or UF2 drag-drop) | Debug Probe, Picoprobe |
| ESP32 | USB serial / JTAG | Built-in USB on S3 and C3; ESP-Prog for classic |
| Most Arm Cortex-M | SWD / JTAG | J-Link, CMSIS-DAP |
- ATmega328P, ATtiny85
- Interface:
- ISP (SPI)
- Tool:
- USBasp, Arduino as ISP
- STM32 Blue Pill, Black Pill
- Interface:
- SWD
- Tool:
- ST-Link V2, CMSIS-DAP
- RP2040 / Pico
- Interface:
- SWD (or UF2 drag-drop)
- Tool:
- Debug Probe, Picoprobe
- ESP32
- Interface:
- USB serial / JTAG
- Tool:
- Built-in USB on S3 and C3; ESP-Prog for classic
- Most Arm Cortex-M
- Interface:
- SWD / JTAG
- Tool:
- J-Link, CMSIS-DAP
Wiring and voltage
- ISP: MOSI, MISO, SCK, RESET, VCC and GND. Set the USBasp jumper to the target's voltage, and be aware some cheap units need a firmware update to work with newer avrdude versions.
- SWD: SWDIO, SWCLK and GND are required. Connect 3.3 V only if you want the probe to power the board, never with another supply also feeding it. NRST helps recover a chip whose firmware disables the debug pins.
- Keep wires short (under about 20 cm) and lower the clock speed if connection is unreliable.
Debugging, not just flashing
With SWD you can set breakpoints, step line by line and watch variables live in VS Code with PlatformIO or STM32CubeIDE, which finds bugs far faster than adding print statements. Many clone ST-Links work for this, though only genuine ST tools are supported for firmware updates. The STM32 Blue Pill is a common first target; see ATmega328P standalone for burning AVR bootloaders.
Common mistakes to avoid
- Powering the target from the probe and another supply at once.
- Wrong USBasp voltage jumper for a 3.3 V target.
- Long, loose SWD wires at a high clock speed.
- Firmware that reuses SWD pins and locks the probe out (use connect-under-reset).
- Forgetting the common ground.
Frequently asked questions
What is the difference between a programmer and a debugger?
A programmer only writes firmware; a debugger also lets you pause, step and inspect running code.
Can I program STM32 without an ST-Link?
Yes, with a USB-to-serial adapter and the built-in bootloader, but you lose debugging.
Do I need a programmer for Arduino Uno?
No, it has a USB bootloader. You need one for blank chips or to recover a broken bootloader.
Can a Raspberry Pi Pico be a debug probe?
Yes, with the Debugprobe firmware it becomes a CMSIS-DAP SWD probe.
What is SWD?
Serial Wire Debug, a two-wire programming and debug interface for Arm Cortex-M chips.
Parts for this guide
Terms in this guide
Keep learning
Sources
- Arm CoreSight SWD documentation
- STMicroelectronics ST-LINK/V2 user manual
- avrdude documentation
- Raspberry Pi Debug Probe documentation
Written by the Geekobot team from manufacturer datasheets. Always check the datasheet for the exact part and variant you buy.



