Other Parts Discussed in Thread: CC3200
Hello,
Im using a WDT in my application code, and its initialized as shown below
Watchdog_Params params;
Watchdog_init();
Watchdog_Params_init(¶ms);
params.callbackFxn = watchdog_callback;
params.resetMode = Watchdog_RESET_ON;
g_watchdogHandle = Watchdog_open(CONFIG_WATCHDOG_0, ¶ms);
if (g_watchdogHandle == NULL) {
// Error opening Watchdog
UART_PRINT("Error: Watchdog_open()\n");
while (1);
}
// Set timeout period to 10000 ms
uint32_t tickValue = Watchdog_convertMsToTicks(g_watchdogHandle, 10000);
Watchdog_setReload(g_watchdogHandle, tickValue);
As you can see, Im adding a callback function watchdog_callback that I want to execute when the WDT timer expires. However, when I trigger a WDT timeout, the handler watchdog_callback starts to execute but stops in middle of the handler, seems like the MCU is reset before the whole callback function is executed. Any idea what I'm doing wrong?
BR Tomas