This provides a basic Watchdog service, and includes a startup detection to determine if the reset was caused by the WD.
Dependents: A_CANAdapter LeonardoMbos AVC_2012 RT_CAN ... more
Using this Watchdog Class
#include "Watchdog.h" Watchdog wd; ... void main() { if (wd.WatchdogCausedReset()) pc.printf("Watchdog caused reset.\r\n"); wd.Configure(3.0); // sets the timeout interval for (;;) { wd.Service(); // kick the dog before the timeout // do other work } }
Files at revision 1:5a1ff72b5915
Name | Size | Actions |
---|---|---|
[up] | ||
Watchdog.cpp | 883 | Revisions Annotate |
Watchdog.h | 2415 | Revisions Annotate |