assert that watchdog can't be restarted
This commit is contained in:
parent
9cf4f9dfc7
commit
49afe683a0
|
@ -101,6 +101,10 @@ void wdg_lld_init(void) {
|
||||||
* @notapi
|
* @notapi
|
||||||
*/
|
*/
|
||||||
void wdg_lld_start(WDGDriver *wdgp) {
|
void wdg_lld_start(WDGDriver *wdgp) {
|
||||||
|
osalDbgAssert((wdgp->state == WDG_STOP),
|
||||||
|
"This WDG driver cannot be restarted once activated");
|
||||||
|
|
||||||
|
/* Generate interrupt on timeout */
|
||||||
#if WDG_USE_TIMEOUT_CALLBACK == TRUE
|
#if WDG_USE_TIMEOUT_CALLBACK == TRUE
|
||||||
wdgp->wdt->INTENSET = WDT_INTENSET_TIMEOUT_Msk;
|
wdgp->wdt->INTENSET = WDT_INTENSET_TIMEOUT_Msk;
|
||||||
#endif
|
#endif
|
||||||
|
@ -134,7 +138,7 @@ void wdg_lld_start(WDGDriver *wdgp) {
|
||||||
*/
|
*/
|
||||||
void wdg_lld_stop(WDGDriver *wdgp) {
|
void wdg_lld_stop(WDGDriver *wdgp) {
|
||||||
(void)wdgp;
|
(void)wdgp;
|
||||||
osalDbgAssert(false, "WDG cannot be stopped once activated");
|
osalDbgAssert(false, "This WDG driver cannot be stopped once activated");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
Loading…
Reference in New Issue