# Johnson counter

Status
Not open for further replies.

#### Ybody

##### New Member
There is probably an extremely easy way of doing this that I am missing.

Using a 4017, I am able to verify my counting works by breadboarding some LEDs to the respective outputs.

I have a stopwatch that requires a low to start and another low to stop. Normal stopwatch, so if the low never goes high, it will still be timing. As it stands right now, once output 0 goes from high to low, the timing starts. It cycles through all the other LEDs and the stopwatch continues running. Go back through the cycle, LED 0 lights up and as it goes out, the timer stops timing. Say I want it to start on the dropout of LED 0 and stop on the dropout of LED 8...

Code:
|   4017   |
|__________|
0 1 2    8 9
|        |
|        |
R1       R1
|        |
LED      LED
|_*____*_|
|
|
SW
|
Ground

Should I just pop 2 diodes in where the "*"s are or is there a better way of doing this? SW is the stopwatch connection to the start/stop button. This is my first shot at this, and after about a day and a half of 4017 and quad comparitor searching, mind mind is pretty much fried. TIA

#### kinjalgp

##### Active Member
Since LED is also a diode, you don't require any additional diodes.

#### mechie

##### New Member
Edited for stupid mistake
The best way of dealing with this (depending on what you want) is...
Use the LEDs as the 'OR' gate - move the resistor to further down the circuit
-- still loses about 2v across the LEDs

Better to use signal diodes (1N914 or similar) as the 'OR' gate then the LEDs can be omitted if required
-- only loses about 0.7v across diodes

#### Attachments

• Stopwatch.gif
3.2 KB · Views: 525

#### kinjalgp

##### Active Member
Use the LEDs as the 'AND' gate

Two diodes, with their cathodes shorted will form "OR" gate not "AND" gate. The output will be logic 1 even if anode of any one diode is at logic 1. And thats the truth table of "OR" gate.

#### Sebi

##### Active Member
The two diodes can work as AND gate with reverse polarity, and pull-up resistor in common anode....

#### mechie

##### New Member
Dho !

Sorry guys --- you got me :!:

The diagram is correct
My waffle is wrong
Not thinking before I rattle my keyboard -- I meant 'OR' gate, honest :roll:
....................Original post corrected !

#### kinjalgp

##### Active Member
Sebi said:
The two diodes can work as AND gate with reverse polarity, and pull-up resistor in common anode....

Yeah ,thats true!

Status
Not open for further replies.

Replies
4
Views
1K
Replies
6
Views
1K
Replies
4
Views
2K
Replies
4
Views
697
Replies
60
Views
7K