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 support@ccsinfo.com

Need help with timer (prescaler)

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



Joined: 21 May 2004
Posts: 1

View user's profile Send private message

Need help with timer (prescaler)
PostPosted: Fri May 21, 2004 12:25 pm     Reply with quote

I'm a newbie with PIC. I need to know how to set a conter, if example i want an event every seconde.

Juste an explanation on how to calculate the prescaler will help. Because i ave no idea how to set it!

What this mean
setup_counters( RTCC_INTERNAL, RTCC_DIV_256)
What is RTCC_INTERNAL and the divisor


Tanks in advance for your help and support
Haplo



Joined: 06 Sep 2003
Posts: 659
Location: Sydney, Australia

View user's profile Send private message

PostPosted: Fri May 21, 2004 4:33 pm     Reply with quote

RTCC_INTERNAL defines the source of Timer0 and RTCC_DIV_256 sets the prescaler. You look at the device datasheet under Timer0, it explains everything very clearly.
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