cancel
Showing results for 
Search instead for 
Did you mean: 

IWDG is not stopped at breakpoint - worked w/o change before

pl
Associate II

With a one-task-program (no RTC) on a STM32L476 and Cube-IDE rev. 1.7.0:

Until yesterday the IWDG was stopped at breakpoints and I could debug line by line, because the watchdog paused.

Since today the iwdg is not stopped and restarts the porgram after (set-up) 4 seconds assumably invoked by the IWDG.

Maybe I changed something accidetly but now I cannot find how to activate the former IWDG stop. Thanks for help

3 REPLIES 3
TDK
Guru

To stop IWDG when the core is halted, set the DBG_IWDG_STOP bit in DBGMCU_APB1FZR1.

> assumably invoked by the IWDG

Don't guess. Read the RCC->CSR registers to determine cause of reset.

If you feel a post has answered your question, please click "Accept as Solution".
pl
Associate II

asked myself if I changed accidentally something in the CubeIDE settings - and where I can activate it again. Thnx.

LaurentL
ST Employee

Hi,

In debug configuration, in Debugger tab of gdb server, you can change the WDG(s) and Low Power settings when debugging.

For STLink Gdb server (default gdb server), you need to activate it.

For Openocd, it is activated by default (Freeze Wdg counters when halted and debug in Low power modes).

Rgds,

Laurent