Contiki 3.x
|
Driver for the cc2538 Watchdog Timer. More...
Files | |
file | watchdog.c |
Implementation of the cc2538 watchdog driver. | |
Functions | |
void | watchdog_init (void) |
Initialisation function for the WDT. More... | |
void | watchdog_start (void) |
Starts the WDT in watchdog mode if enabled by user configuration, maximum interval. | |
void | watchdog_periodic (void) |
Writes the WDT clear sequence. More... | |
void | watchdog_stop (void) |
In watchdog mode, the WDT can not be stopped. More... | |
void | watchdog_reboot (void) |
Keeps control until the WDT throws a reset signal. More... | |
Driver for the cc2538 Watchdog Timer.
void watchdog_init | ( | void | ) |
Initialisation function for the WDT.
Copyright (c) 2014, Analog Devices, Inc.
Currently simply explicitly sets the WDT interval to max interval
Definition at line 63 of file watchdog.c.
References SMWDTHROSC_WDCTL.
void watchdog_periodic | ( | void | ) |
Writes the WDT clear sequence.
Due to how the SMWDTHROSC_WDCTL works, it is OK to simply write these bits rather than use RMW operations.
Definition at line 85 of file watchdog.c.
References SMWDTHROSC_WDCTL, SMWDTHROSC_WDCTL_CLR_0, SMWDTHROSC_WDCTL_CLR_1, SMWDTHROSC_WDCTL_CLR_2, and SMWDTHROSC_WDCTL_CLR_3.
void watchdog_reboot | ( | void | ) |
Keeps control until the WDT throws a reset signal.
Starts the WDT if not already started.
Definition at line 103 of file watchdog.c.
References INTERRUPTS_DISABLE, SMWDTHROSC_WDCTL, SMWDTHROSC_WDCTL_EN, and SMWDTHROSC_WDCTL_INT.
void watchdog_stop | ( | void | ) |
In watchdog mode, the WDT can not be stopped.
This function is defined here to satisfy API requirements.
Definition at line 95 of file watchdog.c.