When I try to step through my code, I get a wdt event firing. I have tried setting the behaviour to pause during debug and sleep
void wdt_init(void)
{
uint32_t operationStatus = NRF_SUCCESS;
NRF_WDT->POWER = 1;
nrf_drv_wdt_config_t watchdogConfiguration;
watchdogConfiguration.behaviour = NRF_WDT_BEHAVIOUR_PAUSE_SLEEP_HALT;
watchdogConfiguration.reload_value = 3000;
watchdogConfiguration.interrupt_priority = APP_IRQ_PRIORITY_LOW;
operationStatus = nrf_drv_wdt_init(&watchdogConfiguration, wdt_error_handler);
APP_ERROR_CHECK(operationStatus);
operationStatus = nrf_drv_wdt_channel_alloc(&wdt_channel_id);
APP_ERROR_CHECK(operationStatus);
nrf_drv_wdt_enable();
}
Then I break on a scheduled task, step through, and then the wdt event (wdt_error_handler) fires. Any idea what I'm doing wrong?