71. Watchdog overview

The STM32MP23/25xx device includes watchdogs which offer a combination of high safety, timing accuracy and flexibility. In the whole document:

71.1 Watchdog main features

71.2 Watchdog functional description

All watchdog peripherals (independent and window) are used to detect and resolve malfunctions due to software or hardware failures.

Figure 845 shows the interconnection of the independent watchdogs into the system.

The independent watchdogs (IWDG1 to IWDG5) are clocked by the low-speed clock (LSI), and thus stay active even if the main clock fails. In this way, they are best suited to applications which require the watchdog to run as a totally independent process outside the main application. The IWDGs are best suited to recover from unexpected software or hardware failures.

IWDGs may generate a system reset when a timeout occurs (rst_iwdg[5:1] signal) according to the application selection. This signal is also routed to the EXTI in order to wake up another CPU to handle the error.

Either IWDG1 when tdcid = 0x1 or IWDG3 when tdcid = 0x2, generates a system reset when the timeout occurs (rst_iwdg[3,1] signal). See Section 21.3.5: Watchdog resets for additional information.

In addition, the IWDG5 can be used to guarantee CPU3 software execution in a given time after a tamper event hardware detection (ePOS mode). The reset signal generates a tamper event when the timeout occurs (rst_iwdg[5] signal).

Figure 845. Top view of independent watchdogs

Block diagram showing the interconnection of independent watchdogs (IWDG1 to IWDG5) with CPU NVICs, EXTI2, and RCC reset control.

The diagram illustrates the interconnection of five independent watchdogs (IWDG1 to IWDG5) with the system's interrupt and reset controllers. Each watchdog block contains 'ewit' (early wakeup interrupt) and 'iwdg_out_rst' (watchdog output reset) signals. IWDG5 is connected to a TAMPER block. The 'ewit' signals from IWDG1 and IWDG2 are connected to EXTI2. The 'ewit' signals from IWDG3 and IWDG4 are connected to the RCC reset control block. The 'iwdg_out_rst' signals from all watchdogs are connected to EXTI2. EXTI2 provides reset signals to CPU1 GIC (rst_iwdg[5:2]) and CPU2 NVIC (rst_iwdg[5,4,2,1]). The RCC reset control block provides a 'System reset' signal and individual reset signals (c1rst, c2rst, c3rst) to the CPU NVICs. The CPU NVICs also receive 'ewit' signals: CPU3 NVIC receives ewit_iwdg[5], and CPU2 NVIC receives ewit_iwdg[4:3].

Block diagram showing the interconnection of independent watchdogs (IWDG1 to IWDG5) with CPU NVICs, EXTI2, and RCC reset control.

Figure 846 shows the interconnection of the window watchdogs into the system.

The WWDG1 is clocked with the APB3 clock, and provides a reset and an early interrupt (ewit_wwdg[1] signal) that is connected to the CPU2 (NVIC) interrupt controller.

The WWDG1 also generates a reset signal when a timeout occurs (rst_wwdg[1] signal). This signal is only routed to the EXTI in order to wake up the CPU1 core to handle emergency tasks if needed.

The WWDG2 is clocked with the APBSR clock, and provides a reset and an early interrupt (ewit_wwdg[2] signal) that is connected to the CPU3 (NVIC) interrupt controller.

The WWDG2 also generates a reset signal when a timeout occurs (rst_wwdg[2] signal). This signal is only routed to the EXTI in order to wake up the CPU1 or CPU2 cores to handle emergency tasks if needed.

Figure 846. Windows watchdogs top view

Block diagram of Windows watchdogs top view showing connections between WWDG1, WWDG2, EXTI1/2, CPU1 GIC, CPU2 NVIC, and CPU3 NVIC.

The diagram illustrates the interconnection of watchdog timers and interrupt controllers. WWDG1 and WWDG2 are watchdog timer blocks. EXTI1/2 is an external interrupt controller. CPU1 GIC, CPU2 NVIC, and CPU3 NVIC are interrupt controllers for the respective CPU cores. WWDG1 has outputs rstwdg and ewit. WWDG2 has outputs rstwdg and ewit. EXTI1/2 has inputs rst_wwdg[1] and rst_wwdg[2]. CPU1 GIC has input rst_wwdg[2:1]. CPU2 NVIC has inputs rst_wwdg[2] and ewit_wwdg[1]. CPU3 NVIC has input ewit_wwdg[2].

graph TD; WWDG1[WWDG1<br/>rstwdg ewit] --> EXTI12[EXTI1/2]; WWDG2[WWDG2<br/>rstwdg ewit] --> EXTI12; EXTI12 --> CPU1GIC[CPU1<br/>GIC]; EXTI12 --> CPU2NVIC[CPU2<br/>NVIC]; EXTI12 --> CPU3NVIC[CPU3<br/>NVIC]; WWDG1 --> CPU2NVIC; WWDG2 --> CPU3NVIC;
Block diagram of Windows watchdogs top view showing connections between WWDG1, WWDG2, EXTI1/2, CPU1 GIC, CPU2 NVIC, and CPU3 NVIC.