Help with decade counter

Discussion in 'The Projects Forum' started by CaptainPrice, Oct 23, 2011.

  1. CaptainPrice

    Thread Starter Active Member

    Aug 12, 2009
    So heres what I want:

    When output 1 goes high LED1 goes on.
    When output 2 goes high both LED1 and LED2 goes on.
    When output 3 goes high LED1 & LED2 & LED3 goes on.

    what Im stumped on is that output2 would short with output1 (cause when output2 is hi all other are low (right?)).
    How can I wire this up?

    Thanks. Ive been puzzling with this for hours...
  2. KJ6EAD

    Senior Member

    Apr 30, 2011
    The correct use of steering diodes is the key. Additional diodes are strategically added to balance the voltage drops.

    This is the equivalent circuit function implemented with integrated OR gates instead of discrete diodes.$+3...16+0 w+320+112+320+152+0 w+320+152+320+184+0

    Edit: Sgt.Wookie points out the current budgeting flaw below. I always forget the driver transistors and supply voltage when I'm playing with the Falstad demonstrator.
    Last edited: Oct 23, 2011
  3. SgtWookie


    Jul 17, 2007
    Unfortunately, steering diodes don't work so well with this problem, as the voltage drop across the diodes is cumulative, and the current requirement exceeds the capacity of a 4017 to supply it.

    I came up with a solution using AND gates awhile back... now to track down where I put it...

    Oh yeah, here:


    Bernard came up with this circuit:


    It will work OK if you just have a few LEDs to light and are running from 12v. The ULN2004 has a pretty high input resistance (~10.7k Ohms), but even then after cascading three or so you'll be about out of current to supply the inputs.
    Last edited: Oct 23, 2011
  4. KJ6EAD

    Senior Member

    Apr 30, 2011
    This is more realistic than my previous examples. It's a demonstrator, not a simulator so the component models are simplified and idealized.