cancel
Showing results for 
Search instead for 
Did you mean: 

SPC560B-DIS Watchdog Issues

jleech92
Associate
Posted on April 13, 2015 at 11:42

Hello,

I am currently trying to set up the Watchdog on my SPC560B board.

Firstly, after enabling the watchdog and letting it time-out into a reset, it then enters SAFE mode and does not reset the program. RGM.DERD is set to 0 so the watchdog time-out should just reset the program from what I understand?

Also, when trying to use the interrupt-then-reset option, the triggered interrupt generates an SE_ILLEGAL and I'm not sure why that is? I have set up the interrupts correctly from what I can tell, setting them up in a similar way to ones I have previously done.

Any help greatly appreciated, thanks.

#spc560b-watchdog-issues
This discussion has been locked for participation. If you have a question, please start a new topic in order to ask your question
2 REPLIES 2
kevin239955_st
Associate II
Posted on April 13, 2015 at 18:46

Hi Jack

I do know that when I booted the processor from Flash the SWT in its default state would constantly reset the board, until I disabled it using the script in UDE.

Kevin

Erwan YVIN
ST Employee
Posted on April 29, 2015 at 14:48

Hello Jack ,

Did you solve your issue ? we disable the WD by using the following command

/* SWT disabled.*/
SWT.SR.R = 0xC520;
SWT.SR.R = 0xD928;
SWT.CR.R = 0xFF00000A;

if you want to enable it , you have to update your WSC (SR) Watchdog Service Code.This field is used to service the watchdog and to clear the soft lock bit (SWT_CR.SLK). To service the watchdog, the value 0xA602 followed by 0xB480 is written to the WSC field. To clear the soft lock bit (SWT_CR.SLKSWT_CR.), the value 0xC520 followed by 0xD928 is written to the WSC field. and you have to set correctly SWT_CR maybe ITR ITR Interrupt Then Reset. 0 = Generate a reset on a time-out 1 = Generate an interrupt on an initial time-out, reset on a second consecutive time-out (Cf Chapter 35) Best regards Erwan