Author |
Topic |
|
ahonda55
Apprentice
Egypt
57 Posts |
Posted - Sep 07 2009 : 7:15:00 PM
|
Hello, i need a simple circuit please. The circuit is to make a single LED go ON from an array of 6 LEDs using one button. I mean, when the user press the button, the first LED lights, if he press again next LED lights while turning off the first one. One LED in each press, from 1 to 6 and again to 1 to 6, one LED every press.
What does this circuit called ? counter ? sequencer ??! anyway, very simple one, digital of analogue will work.
Many thanks |
|
wasssup1990
Nobel Prize Winner
A Land Down Under
2261 Posts |
Posted - Sep 07 2009 : 10:18:56 PM
|
Look-up "decade counter IC". Study the data sheet on one. To get only six LEDs to light up, you'll need to route the 7th output pin to the reset pin so that it only counts from 1 to 6. |
When one person suffers from a delusion it is called insanity. When many people suffer from a delusion it is called religion. |
|
|
boron
Mad Scientist
Canada
223 Posts |
Posted - Sep 08 2009 : 10:22:02 AM
|
Feed the signal from a button into a debounce circuit then feed the debounced signal into a decade counter like the 4017. As mentioned above, the 4017 is 10 outputs so you'll need to wire the reset pin on the IC to ouput 6, in order to only count to 6. |
|
|
ahonda55
Apprentice
Egypt
57 Posts |
Posted - Sep 08 2009 : 8:04:14 PM
|
EXACTLY what i need, heaps of thanks people :) |
|
|
wasssup1990
Nobel Prize Winner
A Land Down Under
2261 Posts |
Posted - Sep 08 2009 : 10:40:32 PM
|
quote: Originally posted by boron
Feed the signal from a button into a debounce circuit then feed the debounced signal into a decade counter like the 4017. As mentioned above, the 4017 is 10 outputs so you'll need to wire the reset pin on the IC to ouput 6, in order to only count to 6.
It has been a while since I have used one of these chips. If the count is from 1 to 10 and assuming the reset triggers on the rising edge, you would need to connect the 7th output to the reset if you only wanted to count from 1 to 6. As soon as count is 7 the reset will trigger and count is reset back to 1. Anyway, you'll find out for yourself ahonda55. It's a good experiment for the newbie. |
When one person suffers from a delusion it is called insanity. When many people suffer from a delusion it is called religion. |
|
|
boron
Mad Scientist
Canada
223 Posts |
Posted - Sep 09 2009 : 8:32:50 PM
|
Ah, sorry maybe I need a wee bit of clarification.
You were correct above when you said the 7th output should be tied to reset. What I was referring to was that on the datasheet for the 4017 they generally start the output pin numbering at 0. By that system the 7th output would be output 6.
My apologies if I caused any confusion . |
Edited by - boron on Sep 09 2009 8:33:56 PM |
|
|
ahonda55
Apprentice
Egypt
57 Posts |
Posted - Sep 10 2009 : 6:49:31 PM
|
Very soon i will buy the IC and start building the circuit, many thanks mates for your help.
Greetings Ahmed |
|
|
ahonda55
Apprentice
Egypt
57 Posts |
Posted - Sep 13 2009 : 6:42:34 PM
|
Hello again, i made this circuit
and i used this debounce circuit
now when i let the "clk" pin floating not connecting to anything, the LEDs go ON and OFF in a random movement, when i connect the 5v signal from the debounce circuit to "clk" pin nothing happens, just the LEDs stops, or sometimes one LED lights, again randomly. by the way, the results are the same, when i use the debounce circuit above or when i use the 4017 circuit as it is. something is wrong !! I use a PC power supply, 12v or 5v same results. Please if anyone can send me a circuit with the debounce circuit i would be so happy.
many thanks Ahmed
|
Edited by - ahonda55 on Sep 13 2009 6:45:45 PM |
|
|
audioguru
Nobel Prize Winner
Canada
4218 Posts |
Posted - Sep 13 2009 : 7:28:31 PM
|
Look in Google for a debounce circuit that works. Yours does not have the capacitor to ground at the clock input of the CD4017.
Download Attachment: debouncer.PNG 19.54 KB
|
|
|
ahonda55
Apprentice
Egypt
57 Posts |
Posted - Sep 16 2009 : 7:22:04 PM
|
100% Done, my thanks to aaroncake forums.
Greetings Ahmed |
|
|
|
Topic |
|