MUX-5 Debug pins reused as GPIO¶
| Severity | Status | Implementation |
|---|---|---|
| error | planned | mid, depends on NET-12 |
Looks at. Which pins are SWD/JTAG on the part.
What it catches. SWDIO, SWCLK, TCK, TMS, TDI, TDO (or a SoC's JTAG) used for an application signal, so the firmware must reconfigure them as GPIO.
Why it matters. Once the firmware takes the pins, the debugger cannot attach; flashing then needs connect-under- reset (if NRST is wired to the probe) or the ROM bootloader. A load on the pin also fights the debug pulls: SWDIO comes up with a pull-up, SWCLK with a pull-down (AN5096 §4.3.2), and driving them the other way wastes current (AN4899 §6.6).
Example. An STM32 board that uses PA13/PA14 for two LEDs because "all other pins were taken": the second firmware image locks the debugger out, and production programming has to change to connect-under-reset.
How to check. Debug functions per pin from part data (NET-12); report nets on those pins that also reach other parts than a debug connector, unless the project marks it as intended (with NRST on the debug connector).
Fix. Keep debug pins for debug; if one must be shared, make it an input with a weak load and wire NRST to the debug connector.
References. AN5096 §4.3.2; AN4899 §6.6.