Connect with us

Need help with LED Circuit

Discussion in 'LEDs and Optoelectronics' started by cmos1, Dec 6, 2012.

Scroll to continue with content
  1. cmos1

    cmos1

    5
    0
    Dec 6, 2012
    Hi, new to this forum and to this hobby.

    I have a friend that i'm trying to help out with a circuit. I know very little and am learning so excuse me for some stupid questions:)

    The circuit that we discussed is a simple circuit with one LED. They would like to have the LED vary in brightness using a push button switch. So, that's easy but here is where I am stuck ... the LED needs to vary in brightness at each push of the button from High to Low. The 4th push of the button turns the LED off. I suggested using a Pot but they would like to use a push button. Is it even possible to do this with a switch? ie: on,on,on,off . I have never done this before so i think another component or two might need to be added to do this.

    Any and all suggestions would be grateful,

    Thank you in advance :)
     
  2. BobK

    BobK

    7,682
    1,688
    Jan 5, 2010
    Not as simple a circuit as you think. For one thing, a pushbutton will turn on and off multiple times each time you press it. This is known as "bounce" and you need a debouncing circuit.

    Next, you need some memory. The circuit has to remember how many times the button has been pushed! There are chips that can do this. Here is a tutorial for one that would be appropriate:

    http://www.doctronics.co.uk/4017.htm


    Bob
     
    Last edited: Dec 6, 2012
  3. KJ6EAD

    KJ6EAD

    1,114
    159
    Aug 13, 2011
  4. cmos1

    cmos1

    5
    0
    Dec 6, 2012
    Thanks to both of you. I will have to check on adding the 4017 to the circuit aqlong with the debouncer.

    I have a headlamp at home that works just like that :) i suppose i could take it apart and have a look.
     
  5. cmos1

    cmos1

    5
    0
    Dec 6, 2012
    I only have 1 LED that i am working with and it seems that the 4017 is over kill. Is there any other solution possibly?
     
  6. CocaCola

    CocaCola

    3,635
    5
    Apr 7, 2012
    Several other ways to go about it but the 4017 is probably the easiest and one of the most cost effective overall...

    What about it do you consider 'overkill' ?

    And don't forget you still need a hardware debounce in addition to the 4017...
     
  7. cmos1

    cmos1

    5
    0
    Dec 6, 2012
    well, i am a newb so all those unused pins on the 4017 seemed like a waste but i don't know jack :)

    i'm still befuddled on how to make the 4017 turn on 1 LED (3 variances of light) with one push button. Plus adding the debouncing circuit. I guess i need to visualize as well.

    Is there an online circuit diagram tester program that any of you prefer>? I've tried Circuit Labs but didn't seem to work well.
     
  8. cmos1

    cmos1

    5
    0
    Dec 6, 2012
    i just saw that link to Yenka on the 4017 link. ill download that and check it out
     
  9. CocaCola

    CocaCola

    3,635
    5
    Apr 7, 2012
    Yeah, sometimes you don't use all the pins, not an big deal...

    As for how it works you vary the resistance, when pin 1 it output there is a high resistance, when pin 2 is output there is less resistance etc... Pin 0 output should be your 'off' position so that the circuit always starts in the off state...

    You can simulate it here

    http://www.falstad.com/circuit/

    The page Bob linked to gives a lot of good info about the chip, don't forget to read it over...
     
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day

-