
Independent watchdog (IWDG)
RM0008
Doc ID 13902 Rev 12
19
Independent watchdog (IWDG)
Low-density
devices
are STM32F101xx, STM32F102xx and STM32F103xx
microcontrollers where the Flash memory density ranges between 16 and 32 Kbytes.
Medium-density
devices
are STM32F101xx, STM32F102xx and STM32F103xx
microcontrollers where the Flash memory density ranges between 64 and 128 Kbytes.
High-density devices
are STM32F101xx and STM32F103xx microcontrollers where the
Flash memory density ranges between 256 and 512 Kbytes.
XL-density devices
are STM32F101xx and STM32F103xx microcontrollers where the
Flash memory density ranges between 768 Kbytes and 1 Mbyte.
Connectivity line devices
are STM32F105xx and STM32F107xx microcontrollers.
This section applies to the whole STM32F10xxx family, unless otherwise specified.
19.1 IWDG
introduction
The STM32F10xxx have two embedded watchdog peripherals which offer a combination of
high safety level, timing accuracy and flexibility of use. Both watchdog peripherals
(Independent and Window) serve to detect and resolve malfunctions due to software failure,
and to trigger system reset or an interrupt (window watchdog only) when the counter
reaches a given timeout value.
The independent watchdog (IWDG) is clocked by its own dedicated low-speed clock (LSI)
and thus stays active even if the main clock fails. The window watchdog (WWDG) clock is
prescaled from the APB1 clock and has a configurable time-window that can be
programmed to detect abnormally late or early application behavior.
The IWDG is best suited to applications which require the watchdog to run as a totally
independent process outside the main application, but have lower timing accuracy
constraints. The WWDG is best suited to applications which require the watchdog to react
within an accurate timing window. For further information on the window watchdog, refer to
.
19.2 IWDG
main
features
●
Free-running downcounter
●
clocked from an independent RC oscillator (can operate in Standby and Stop modes)
●
Reset (if watchdog activated) when the downcounter value of 0x000 is reached
19.3 IWDG
functional
description
shows the functional blocks of the independent watchdog module.
When the independent watchdog is started by writing the value 0xCCCC in the Key register
(IWDG_KR), the counter starts counting down from the reset value of 0xFFF. When it
reaches the end of count value (0x000) a reset signal is generated (IWDG reset).