cancel
Showing results for 
Search instead for 
Did you mean: 

watchdog does not want to shut down

ezanen9
Associate II
Posted on March 02, 2007 at 10:01

watchdog does not want to shut down

4 REPLIES 4
ezanen9
Associate II
Posted on February 28, 2007 at 04:57

Hi all,

I am using Uvision3 from Keil to develop software for the STR715 MCU. However when debugging from SRAM I am not able to disable the watchdog.

When(during debugging) the program is loaded in the SRAM the program counter is set to the ''int main(void)'' function which is correct. However before starting the program at all, the WE(watchdog enable) bit in the watchdog control register)WDG_CR) is alread set to ''1''. I can see this via my JTAG interface. The watchdog resets my MCU during debugging one in a while. This is very irritating.

The software can not reset this bit when running. This is correct according to the datasheet.

How do I set the WE bit in WDG_CR to 0?

Regards,

Jimmey

kleshov
Associate II
Posted on February 28, 2007 at 05:02

I am not familiar with Keil tools, but could it be that their startup code enables watchdog timer? Start debugging your program from very beginning, before function main. Try setting a watchpoint on the watchdog configuration register to see where it gets modified.

- mike

ezanen9
Associate II
Posted on February 28, 2007 at 05:41

hi and thanks,

I checked already but there is no wachtdog initialisation in the startup code. The strange thing is that I programmed the bigger STR710 before and I never had this problem before.

I stopped the program now at the very beginning and the WE bit is already set.

Jimmey

kaouther
Associate II
Posted on March 02, 2007 at 10:01

Hi,

Once the WE bit is written to 1 it is not possible to clear this bit by software.

I've verified on STR710, STR712 and STR715, the WE is set to 0 by defaut. I've verified with different tools, IAR, RVDK and Uvision3 from Keil and the WE is not enabled. You can test any example available on Keil install directory and jut verify if the WE bit is set or not?.

😉