Verified Commit c8dbb334 authored by Rahix's avatar Rahix
Browse files

fix(watchdog): Don't enable when debugger is connected


Signed-off-by: Rahix's avatarRahix <rahix@rahix.de>
parent 781d4129
Pipeline #3336 passed with stages
in 1 minute and 11 seconds
......@@ -16,6 +16,13 @@ static void watchdog_clearer_callback()
void watchdog_init()
{
/*
* Don't enable the the watchdog when a debugger is connected.
*/
if ((CoreDebug->DHCSR & CoreDebug_DHCSR_C_DEBUGEN_Msk) != 0) {
return;
}
sys_cfg_wdt_t wdt_cfg = NULL;
WDT_Init(MXC_WDT0, wdt_cfg);
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment