IC for driving LEDs

Discussion in 'The Projects Forum' started by FastEddy_AAC, May 7, 2014.

  1. FastEddy_AAC

    Thread Starter New Member

    May 7, 2014
    4
    0
    Hi everyone,
    I am glad to have found this forum.
    I am working on a project that involves driving 6 white surface mount LEDs.
    I am using a small tactile push button. So I need to find an IC that will allow me to operate it.
    When I push the button once, I need all LEDs to turn on. When I push it again, I need to have every other one to turn on for a total of 3. When I push it again, I need all of them to turn off. I could design it using descreet TTLs, but I want to use surface mount components to be able to shrink the overall profile.
    If anyone has any ideas on what IC I could use and/or have I circuit diagram or schematic, I would appreciate it.

    Thanks for advance.
    Eddy
     
  2. ErnieM

    AAC Fanatic!

    Apr 24, 2011
    7,386
    1,605
    If 3 lights come on and off together then you have just two "things" to control.

    Your circuit has 3 states: off, A & B on, and A only on. Then it repeats.

    The "controller" has 3 lines: one input for the button, one output for the A channel, one for the B channel.

    A single SOT-5 pin microcontroller has the smarts to do all this, including debouncing the button. Simple MOSFETs would do as sink switches to turn the LEDs on, either in parallel or series depending on the power supply voltage.

    Most any dual flip flop could also do this, but you have to add some sort of debounce circuitry, a power on clear signal, and something to drive the next state.

    And welcome to the forums!
     
  3. wayneh

    Expert

    Sep 9, 2010
    12,100
    3,034
    Power source?

    I'd probably use 2 parallel strings of 3 LEDs each, so the sequence would be 2 strings, 1 string, off. You could get that with a 4017 counter IC, but there are many other approaches. Each series string could be switched with a MOSFET under control of the counter's output.

    And Ernie beats me again.
     
    absf likes this.
  4. FastEddy_AAC

    Thread Starter New Member

    May 7, 2014
    4
    0
    Thanks for everyone's response. I like the idea of the SOT–23-5 surface mount component.
    Would anyone be able to steer me in the right direction to a circuit that would use one of those driving LEDs with a MOSFET driver, just so I can reference it and modify the circuit to do what I need it to do.

    Thanks
    Eddy
     
  5. ErnieM

    AAC Fanatic!

    Apr 24, 2011
    7,386
    1,605
    Well... while the circuit is falling off a log simple (for those of us who have done these things before) but that chip is a micro controller, meaning you have to learn how to do programming, have to program that chip, and figure out a way to either do the programming out of circuit or shoehorn in the connections... and you need a programmer too.

    I just gave it as an example of the smallest possibility. However, if you want to proceed up that hill we'll be here to help. While the chip itself is 50 cents the programmer will run you 40-50 bucks. The development tools (programs) are all freebies.

    A dual JK flip flop will also do the job, it's all of 6 cents cheaper but needs a few extra parts that eats that up. Those parts are resistors and caps so they are cheap and small too.

    So which way would you like to go?

    aside to digital guys: anyone care to check the JK input for me for him? I have the 3 state pattern as:

    J1 = 1
    K1 = (NOT)Q2
    J2 = (NOT)Q1
    K3 = 1

    POC (power on clear) would take us to Q1=0, Q2=0 (both off)
    Q1=0, Q2=1 is the unwanted (illegal?) state, but if it hits this should reset to 0-0.
     
    Last edited: May 8, 2014
  6. absf

    Senior Member

    Dec 29, 2010
    1,492
    372
    I agree with wayneh's idea of using 4017 to drive the 3 state-LED pattern.

    Attached is the schematic in proteus. I simulated it and it worked.

    Allen
     
    djsfantasi and wayneh like this.
  7. ErnieM

    AAC Fanatic!

    Apr 24, 2011
    7,386
    1,605
    What is the output state when this turns on?

    If it is indeterminate, how would you add a power on clear signal?
     
    absf likes this.
  8. #12

    Expert

    Nov 30, 2010
    16,261
    6,770
    I think, a cap from +5V to a resistor to ground, diode "or" to the MR (master reset) pin.
     
    Last edited: May 8, 2014
    absf and djsfantasi like this.
  9. ErnieM

    AAC Fanatic!

    Apr 24, 2011
    7,386
    1,605
    I was thinking more along these lines:

    A dual FF chip, 3 caps, 2 resistors, 2 MOSFETs, and the push button.

    Not in that count are the LEDs, though 2 methods of driving 3 LEDs is shown. The choice would depend on the supply voltage.
     
    absf likes this.
  10. ErnieM

    AAC Fanatic!

    Apr 24, 2011
    7,386
    1,605
    But nothing beats a tiny micro to do this. Sketch shown.

    No resistors, one cap, one chip...
     
  11. absf

    Senior Member

    Dec 29, 2010
    1,492
    372
    I simulated your circuit and it worked well too. Both the circuits can be constructed using SMD parts (4027 or 4017, leds, button, BJT, mosfet etc) and can be made very small (may be 1.5" x 1". Using a PIC mcu can cut the size further down.

    Attached is the simulation of Ernie's circuit after the first press of the button.

    Thanks.

    Allen
     
  12. ErnieM

    AAC Fanatic!

    Apr 24, 2011
    7,386
    1,605
    Thanks Making up the state table for JK flip flops is one of my more error prone disabilities. :D
     
    absf likes this.
  13. FastEddy_AAC

    Thread Starter New Member

    May 7, 2014
    4
    0
    Thanks ErnieM, I appreciate it.
    The supply voltage to the circuit will be from a USB port.
     
  14. FastEddy_AAC

    Thread Starter New Member

    May 7, 2014
    4
    0
    And I will be using white surface mount LEDs, so I'm not sure if the bias voltage or current is different from the yellow ones.

    Thank
    Eddy
     
  15. #12

    Expert

    Nov 30, 2010
    16,261
    6,770
    Every color of LED has a different voltage range.
     
Loading...