Recovering from a Watchdog Reset

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
ShSh_291626
Level 3
Level 3

the "recovering from a watchdog reset" can do it in psoc

   

like it >>  http://www.cypress.com/?rID=40391

   

how can i do it function in the psoc3??

   

 

   

thanks.

0 Likes
8 Replies
HeLi_263931
Level 8
Level 8
100 solutions authored 50 solutions authored 25 solutions authored

It basically works the same: a WatchDog reset is signalled with the RESET_SR0[3] bit. See the PSoC5LP TRM at page 137.

   

So the check would be:

   
if (0!=(RESET_SR0&8)) {   // watchdog reset }
0 Likes
ShSh_291626
Level 3
Level 3

 Hi,

   

how can i  at watchdog reset after preserve SRAM value?

0 Likes
Anonymous
Not applicable

Content of RAM are normally initialized by functions generated by the compiler which would be called during reset.

   

While you can tried to hack the code to preserved the RAM content but this is not recommened. It would be better to save the RAM content to EEPROM/FLASH -you need some sort of mechnism to update the content before it resets or use external RAM.

0 Likes
ShSh_291626
Level 3
Level 3

 The original PSoC1 can save RAM value, updated to the function but can not be used after the PSOC3, really bad.How do I explain it with the customer? : (

0 Likes
HeLi_263931
Level 8
Level 8
100 solutions authored 50 solutions authored 25 solutions authored

For the PSoC3, there is a flag in the design wide resources called "Clear SRAM during startup". Uncheck that, and you should be fine.

0 Likes
ShSh_291626
Level 3
Level 3

 I tried Clear SRAM during startup

   

just a start must be given all the initial value

   

 

   

Thanks!

0 Likes
Anonymous
Not applicable

 Looks like I missed this option. 

   

There are always some new to learn everyday. 🙂

0 Likes
ETRO_SSN583
Level 9
Level 9
250 likes received 100 sign-ins 5 likes given

That option does not seem to exist in PSOC 5, seems unfortunate.

   

 

   

Regards, Dana.

0 Likes