2007-03-02 01:01 AM
watchdog does not want to shut down
2007-02-27 07:57 PM
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, Jimmey2007-02-27 08:02 PM
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.
- mike2007-02-27 08:41 PM
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. Jimmey2007-03-02 01:01 AM
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?. ;)