CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

how to test watchdog in practice it's really sparking

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
artohautala



Joined: 17 Nov 2011
Posts: 187

View user's profile Send private message Send e-mail

how to test watchdog in practice it's really sparking
PostPosted: Wed Feb 21, 2018 1:40 pm     Reply with quote

HI,
so I have programmed watchdog to make RESET if my program falls down ...
But I'm asking how I can test in practice it really works ?

all the best for you all !

regards
-arto-
Ttelmah



Joined: 11 Mar 2010
Posts: 19536

View user's profile Send private message

PostPosted: Wed Feb 21, 2018 1:47 pm     Reply with quote

Just do something that doesn't reset the watchdog.

If you just sit is a loop that never exits, the only way 'out' will be the watchdog.

Beware though. Using the watchdog properly is a lot more complex than most people realise. You need to design you code to only reset it, if everything is working right. Work out how often you will reach the point where you reset it, then look at the data sheet and work out what watchdog time is the closest fit above this _in all cases_. The caveat here is that many chips have a watchdog timer that gives an enormous time range. So the nominal '18mSec' for some chips actually gives a time between 7mSec and 28mSec. You'd have to ensure your reset always occurs in less than 7mSec on such a chip....
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group