DEV Community

Sachin pagar
Sachin pagar

Posted on

Introduction to Watchdog timer and Significance of watchdog timer in embedded

Introduction to Watchdog timer and Significance of watchdog timer in embedded
For detailed explanation please see Introduction to Watchdog timer and Significance of watchdog timer in embedded
INTRODUCTION:
Watchdog timer is a piece of hardware in micro-controller. Watchdog timer is used to generates system reset if system gets stuck somewhere i.e. if system goes into endless loop of execution watchdog timer will reset the system to come out of endless loop. Watchdog is safety mechanism in embedded system which makes your system reliable, but it depends on how you make use of watchdog timer.
1.1 How does watchdog works :
Watchdog is basically a counter, which starts from counting zero and reaches to a certain value. If counter reaches to certain value then watchdog hardware will generates a watchdog reset. To avoid system reset, software needs to kick the watchdog i.e. need to reset the counter to zero. In case software stuck into endless loop it system will not able to kick the watchdog hence counter reaches to certain value and resets the system.

Watchdog is initially loaded with certain value. This value is calculated based on timeout time of watchdog (Further section it is been shown how to calculate counter value based on timeout value). Before timeout time, system should reset the counter.
Resources :
https://pythonslearning.com/2021/03/introduction-to-watchdog-timer-and-significance-of-watchdog-timer-in-embedded.html

Top comments (0)