IT lexicon › Hardware › SWD (Serial Wire Debug)

SWD (Serial Wire Debug)

Hardware På svenska → Updated: 2026-11-02
More info
Creator
ARM
Type
Debug interface
Predecessor
JTAG

ARM's two-wire alternative to JTAG for flashing and debugging Cortex processors.

JTAG needs at least four signals and was designed to test solder joints along a chain of chips. SWD gets by with two — SWDIO for bidirectional data and SWCLK for the clock — and still gives full access to the CPU's debug port: breakpoints, single-stepping, reading and writing memory while the program runs. On a cramped board, two pins instead of five is the difference between having a debug header and not having one.

It arrived with ARM Debug Interface v5 and is now the normal way to program a Cortex-M. A cheap ST-Link or CMSIS-DAP probe, OpenOCD or pyOCD, and GDB are all you need. The security caveat is the same as for JTAG: an unlocked SWD port on a shipping product is an invitation to dump the entire firmware.

← Back to the lexicon