Getting started with WDG

Revision as of 18:30, 14 November 2022 by Registered User
Under construction.png Coming soon

This article explains what WDOG is and how to use it through examples

1. Introduction of WDOG

WDOG stands for Watch DOG. The main goal of this IP is to detect and resolve malfunctions due to software failures. The principle is to refresh the timer periodically, if the timer isn't refreshed, a system reset is generated. Once start by hardware or software, the WDG cannot be disabled.

2. WDOG type

There are two types of WDOG :

  • WWDG : Window WatchDoG
  • IWDG : Independent WatchDoG

2.1. WWDG

  • WWDG is clocked by the APB1 peripheral clock.

2.2. IWDG

The fact that the IWDG is clocked by the LSI give a strong benefits : totally independent process outside the main.

3. Configure WWDOG with LED indication

3.1. Definition

3.2. Objective

  • In this project, you will learn how to setup WWDG in STM32CubeIDE
  • How to Generate Code in STM32CubeIDE and use HAL functions
  • Create simple application to test WWDG

3.3. How

  • Configure WWDG in STM32CubeIDE and Generate Code
  • Learn how to activate and refresh WWDG
  • Add into the project the HAL_Delay function and HAL_GPIO_Toggle function
  • Verify the correct functionality on toggling LED

3.4. Create the project in CSTM32ubeIDE

4. Configure IWDOG with LED indication

4.1. Objective

  • In this project, you will learn how to setup IWDG in STM32CubeIDE
  • How to Generate Code in STM32CubeIDE and use HAL functions
  • Create simple application to test IWDG

4.2. How

  • Configure IWDG in STM32CubeIDE and Generate Code
  • Learn how to activate and refresh IWDG
  • Add into the project the HAL_Delay function and HAL_GPIO_Toggle function
  • Verify the correct functionality on toggling LED

4.3. Create the project in CSTM32ubeIDE

5. Conclusion

Keep in mind this :



[[category:Getting_started_with_STM32_system_peripherals | 15]]