MUX-4 GPIO on a pin that is NRST, BOOT or another reset-time function by default¶
| Severity | Status | Implementation |
|---|---|---|
| error | planned | mid, depends on NET-12, IMP-9 |
Looks at. Per-pin reset-time functions, option-byte defaults.
What it catches. A pin used as a plain GPIO although at reset (and with factory option bytes) it is the reset input, a boot pin or another function that the firmware cannot take over before it matters.
Why it matters. On the STM32G0 the pin PF2-NRST is the reset input/output as delivered (AN5096 §1.3.2); it becomes PF2 only after NRST_MODE in the option bytes is changed (RM0444 §3.7.8), and even then the pin must rise above VIH(NRST) at power-on or the chip never leaves power-on reset (RM0444 §7.3.17). A pull-down on it, or a load that pulls it low, holds the MCU in reset.
Example. B153A used PF2 as the hub reset output, with R304 10 kΩ to GND. The library symbol said plain PF2. In factory state PF2 is the MCU's NRST: the pull-down fought the internal pull-up of about 40 kΩ (AN4899 §6.7), and flashing and booting failed until the trace was cut and the hub reset moved to PC13. Rev B names the symbol pin PF2-NRST.
How to check. Mark pins whose reset-time function is not GPIO (part data, NET-12; pin names like PF2-NRST, PA14-BOOT0 help but are not reliable); report any use as a GPIO, and any pull or load that would block the reset-time function.
Fix. Use another pin; if the pin must be a GPIO, program the option bytes in production and keep its load compatible with the reset function at power-on.
References. RM0444 §3.7.8, §7.3.17; AN5096 §1.3.2; STM32G0B1 Table 12; B153 rev B change list.