cc26xx - implemented watchdog_stop

Also modified watchdog_start so that if we stop and start again the
watchdog timeout will be reset (by calling watchdog_periodic).
This commit is contained in:
Billy Kozak 2015-08-17 11:11:30 -06:00
parent dfdb0a6487
commit 22d8a8dd56

View file

@ -70,6 +70,7 @@ watchdog_init(void)
void
watchdog_start(void)
{
watchdog_periodic();
ti_lib_watchdog_reset_enable();
}
/*---------------------------------------------------------------------------*/
@ -83,6 +84,15 @@ watchdog_periodic(void)
ti_lib_watchdog_int_clear();
}
/*---------------------------------------------------------------------------*/
/**
* \brief Stops the WDT such that it won't timeout and cause MCU reset
*/
void
watchdog_stop(void)
{
ti_lib_watchdog_reset_disable();
}
/*---------------------------------------------------------------------------*/
/**
* \brief Manually trigger a WDT reboot
*/