Troubleshooting
11
Troubleshooting
Table 6
summarizes solutions to overcome some of the most frequent issues faced during
debug setting and operation.
Connection with target lost during debug of low-power
system
Fail to get printf via SWO
An unexpected power consumption is measured for a
low-power application.
Fail to connect to a board with Normal/System Reset
Fail to connect on board using
ConnectUnderReset/Hardware using ST-LINK
Fail to see clock signal on MCO output
Impossible to evaluate a value or a variable, or
impossible to set a breakpoint at a specific line in code
94/118
Table 6. Troubleshooting
Problem
Ensure debug in low-power in DBGMCU register is
enabled.
Ensure SWD pin not set in analog state.
Refer to
Section 4.1: SWD/JTAG pinout
Section 4.3: Low-power
Refer to
Section 7.3: Printf via
Check that low-power debug in DBGMCU register is
OFF. Beware that this register is reset only with a POR
(power-on reset).
Refer to
Section
Try ConnectUnderReset / Hardware Reset connection
mode. This resets SWD connection in case it has been
disabled by application.
Refer to
Section
Ensure NRST of ST-LINK is properly connected to MCU
NRST (e.g. check SB12 for Nucleo).
Ensure that the clock configured to MCO is in the
supported range of the GPIO and that the OSPEED
setting is correct.
Refer to
Section
Compiler optimization is probably enabled. Remove it.
Refer to
Chapter 3: Compiling for
AN4989 Rev 3
Solution
and to
case.
SWO/SWV.
4.3.
4.2.
8.2.
debug.
AN4989
Need help?
Do you have a question about the STM32 and is the answer not in the manual?