Hi everyone. I have added the watchdog code from the TI example to my software, to be able to reset the system in case there would be some systemcrash. I have implemented the interrupt, this one contains a counter, in case couter reach some certain value, reset should be done by the microcontroller by writing "SysCtrlRegs.WDCR=0x003F;" to the register. Unfortunatelly when there are some crashes initiated through Electromagnetic (un)Compability in the cable used, then my F2806 just hangs and doesn't react anymore, only my LEDs are shining but not blinking (in working condition these are blinking). Does it means, that there are possible systemcrashes, were the watchdog is useless?
interrupt void wakeint_isr(void)
{
WakeCount++;
//if interrupt has been called more that 7 times
if (WakeCount > 7)
{
WakeCount = WakeCount;
EALLOW;
SysCtrlRegs.WDCR=0x003F;//reset
EDIS;
}
// Acknowledge this interrupt to get more from group 1
PieCtrlRegs.PIEACK.all = PIEACK_GROUP1;
}