AnsweredAssumed Answered

Watchdog ISR is not entered on Kinetis

Question asked by Baltech AG Baltech AG on Sep 4, 2017
Latest reply on Sep 5, 2017 by Mark Butcher

We try to activate the Watchdog interrupt in a Kinetis MK22FN512 without success.
As you can see in the attached code snippet we enabled the watchdog and activated the watchdog interrupt.
Then we start a endless loop.
As expected the watchdog does a resets after the timeout.
But it does not call the interrupt routine (WDOG_EWM_IRQHandler) before rebooting also "enableInterrupt" is set.


What are we doing wrong?


Best Regards,



#include "hal/nxp_mk/fsl_mk22fn512xxx12/drivers/fsl_wdog.h"


void main(void)
        wdog_config_t config;
        // Activate Watchdog
        config.prescaler = kWDOG_ClockPrescalerDivide8;
        config.timeoutValue = 3000000;
        config.enableWindowMode = false;
        config.clockSource = kWDOG_AlternateClockSource;
        config.enableInterrupt = 1;
        WDOG_Init(WDOG, &config);
        while (1);


void WDOG_EWM_IRQHandler(void)
        // #is never entered