2010-01-19 04:10 PM
2011-05-17 12:58 AM
Hello,
I am working on STR91x processor I am trying to use WDG_RST(WDG Reset event flag) in SCU_SYSSTATUS register. While initializing PLL, after setting SCU_FLAG_LOCK SCU->SYSSTATUS |=SCU_FLAG_LOCK all other bits in SYSSTATUS register have been reset, so I am loosing WDG_RST information. I have also tried to do the same thing manually in debugger and observed the same beviour. Can anybody help? Thank you2011-05-17 12:58 AM
Hello,
do you perhaps have a solution for this. I am having the same problem that after a software watchdog reset, the SCU->SYSSTATUS did not set the WDG_RST flag accordingly. Thank you!2011-05-17 12:58 AM
That's because the SYSSTATUS register bits are cleared by writing a 1. You're or'ing in the current value of the SYSSTATUS register to itself, effectivly clearing each bit that's been set.
If you want to clear the SCU_FLAG_LOCK bit it you should be doing this- SCU->SYSSTATUS = SCU_FLAG_LOCK;