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

Why my pic18f452 is restarting ?

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



Joined: 18 Oct 2005
Posts: 3

View user's profile Send private message MSN Messenger

Why my pic18f452 is restarting ?
PostPosted: Mon Feb 06, 2006 12:25 pm     Reply with quote

Hi,

I have little problem with my PIC18F452. I do not why he is going down. It is randomly, after few second or after one minute. I have heard that use capacitor 100 uF between +5 and GND near the PIC, to decouple any noise that could reset the PIC, can help. I am going to check it tomorrow, but maybe you have other idea?

Thanks
_________________
With best regards

Kostienko

MSN kostienk@coventry.ac.uk
kkostienko



Joined: 18 Oct 2005
Posts: 3

View user's profile Send private message MSN Messenger

PostPosted: Mon Feb 06, 2006 12:32 pm     Reply with quote

I have forgoten to say that i chacked few PIC18, one which I have got today(so for sure this is not coused by the PIC18F452).
_________________
With best regards

Kostienko

MSN kostienk@coventry.ac.uk
jecottrell



Joined: 16 Jan 2005
Posts: 559
Location: Tucson, AZ

View user's profile Send private message

PostPosted: Mon Feb 06, 2006 12:57 pm     Reply with quote

I had similar problems when PUT was enabled by accident. Ensure you have NOPUT in your fuses and see if that fixes it....

Good Luck,

John
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Mon Feb 06, 2006 1:17 pm     Reply with quote

Possible reasons for apparently "random" resets:

1. The Watchdog timer is enabled, but is not being reset frequently
enough, or in the correct places within the program.

2. The #fuses are set for LVP mode, instead of NOLVP, and the
PGM pin has been left floating.

3. The code is allowed to fall off the end of main(), so that the PIC
goes to sleep. The PIC then wakes up at random times, due to
an interrupt, and starts executing garbage code. It may eventually
jump to address 0 and start executing properly again, or maybe not.
rnielsen



Joined: 23 Sep 2003
Posts: 852
Location: Utah

View user's profile Send private message

PostPosted: Mon Feb 06, 2006 2:50 pm     Reply with quote

I have found that it very important to place a filter cap (VCC to GND) near the PIC. A .1uf cap should be enough, provided that your power supply is also sufficiently filtered. Stray noise Can cause problems with any processor.

Ronald
jecottrell



Joined: 16 Jan 2005
Posts: 559
Location: Tucson, AZ

View user's profile Send private message

PostPosted: Mon Feb 06, 2006 3:46 pm     Reply with quote

I gooned that one up. Remove all references to PUT and change it to BROWNOUT! Use NOBROWNOUT in your fuses and see if that helps....
kkostienko



Joined: 18 Oct 2005
Posts: 3

View user's profile Send private message MSN Messenger

PostPosted: Mon Feb 06, 2006 4:52 pm     Reply with quote

Thank you,

I will check all your guides tomorrow and will give then reply post.

See you soon
_________________
With best regards

Kostienko

MSN kostienk@coventry.ac.uk
kkostienko



Joined: 18 Oct 2005
Posts: 3

View user's profile Send private message MSN Messenger

PostPosted: Fri Feb 10, 2006 10:43 am     Reply with quote

Thanks,

I have used the 100 nF Cap and now works great Very Happy
_________________
With best regards

Kostienko

MSN kostienk@coventry.ac.uk
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