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

Adjustable led flash rate.

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



Joined: 04 Jun 2007
Posts: 13

View user's profile Send private message

Adjustable led flash rate.
PostPosted: Mon Oct 01, 2007 2:07 pm     Reply with quote

I wan to build an led flasher using a 12f683 and some sort of dial that I can turn to adjust the flash rate. I want to be able to turn the dial or wheel to make the flash rate increas or decrease accordingly. Can anyone help with get start with some sample code.

Thanks,
Rb8720
treitmey



Joined: 23 Jan 2004
Posts: 1094
Location: Appleton,WI USA

View user's profile Send private message Visit poster's website

PostPosted: Mon Oct 01, 2007 2:39 pm     Reply with quote

Sorry, no code. It looks simple enough.
Looks like you have a A to D converter and a timer.
1)setup timer, on trip of timer, toggle LED
2)setup A to D for correct pin
3)wire a 10k pot to A to D like the PICDEM 2 plus schematic show.
R16
http://ww1.microchip.com/downloads/en/DeviceDoc/PICDEM%202%20Plus%20RoHS.pdf


In software read A to D, when it changes, have the new value set a new value in timer.
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