AnsweredAssumed Answered

Can't enable Watchdog

Question asked by Mattia Berton on May 5, 2016
Latest reply on May 5, 2016 by jeremyzhou


I'm using a Kinetis KM33Z128A5 serie Microcontroller, Codewarrior 10.6 and Baremetal drivers.

However, I can't enable in proper way the watchdog.

I just copied the example, in the baremetal drivers:


/* enable clocks to all on chip peripherals                             */
// Watchdog Init
   /* Watchdog timeout is of 1.5 sec approximately                         */


But the watchdog doesn't start, neither in debug mode, nor in normal mode. I can see that it is working only if I put a breakpoint on the WDOG_Init instruction, when I see that the successive instruction is a reset.

I tried to watch the register, and what I see is that the WDOG_STCTRLH is kept at the value of 0x0152 no matter what I put in the WDOG_Init arguments. Also, after the reset this value is 0x0153.


Any ideas?