I'm trying to design a simple circuit for a 4 LED indicator. Its basically like a game show device that has four buttons. The first one to press their button would have their LED light up and "lock" everyone else out; not allowing the other 3 LEDs to light up.

Below is my attempt at making this circuit with a few AND gates and a few NOT gates. But it doesn't work as needed. It only slightly works by blocking the next LED in line but if the one before it is lit then it turns off. Plus the first LED can always be turned on.


simulate this circuit – Schematic created using CircuitLab

Is there a different component I should be using? Or a different configuration of NOT/AND/OR gates?

All help is appreciated!

  • 1
    \$\begingroup\$ The easiest way to do this is with a small microcontroller and a bit of code. \$\endgroup\$ – Spehro Pefhany Jan 7 '15 at 4:55
  • \$\begingroup\$ "Easiest" and cheapest is a $US3 Arduino from China. BUT using gates is a really really good idea as a learning experience. Highly commendable. See my IDL below - come to grips with that and it will transform your quick-lashup-circuits world. \$\endgroup\$ – Russell McMahon Jan 7 '15 at 9:48
  • \$\begingroup\$ Keith - WRB may think my IDL solution is a bit hard for a newcomer to the field to follow. What do you think of it? Does the latch make sense - or the set/reset system ...? \$\endgroup\$ – Russell McMahon Jan 7 '15 at 13:59
  • \$\begingroup\$ I am trying my best to avoid using microcontrollers of any sort. I have a strong programming background (computer engineering), but just trying to learn better circuit design because it is the weak point in my schooling education. \$\endgroup\$ – Keith Enlow Jan 7 '15 at 14:52

Don't listen to caveman.


simulate this circuit – Schematic created using CircuitLab

Flip-flops can be synthesized from gates, although you may well decide to take Spehro's advice.

In the schematic, Switch 5 is a reset, and pressing it causes all 4 outputs (at the LED) to go high, turning off the LEDs. Pushing any of Switches 1 - 4 will cause the corresponding LED to turn on, and disable any other switch activations by way of the AND gates.

If you want to use discrete logic, such as 7400/74LS/74HC, etc, the total package count is 5 ICs - 1 7400, 2 7410 and 2 7411.

ETA - You'll notice that the LEDs are driven by being pulled down, with current coming from VCC. This is important if you decide to use 7400 or 74LS - those technologies do not source current well, but they sink current just fine. If you decide to go with a CMOS family such as 74HC, this will still work. Or, if you like, you can use the other output from each latch, the 2-input NAND gate, and drive the LED to ground (being careful to get the LED polarity right). Just a thought.

  • \$\begingroup\$ Or 1/3 pkg channell + too many [tm] diodes using IDL (Inverter Diode Logic] :-). And yes, yours is the more proper way to do it. \$\endgroup\$ – Russell McMahon Jan 7 '15 at 9:38
  • \$\begingroup\$ @RussellMcMahon - You really want to fry the poor guy's brain, don't you? \$\endgroup\$ – WhatRoughBeast Jan 7 '15 at 13:39
  • \$\begingroup\$ Keith is 22 years old. Keen to learn. Using REAL gates in a world of instant gratification. IF he can see how my latch latches and how the diodes + inverters can make any gate he wishes (XOR is harder :-)) then it may open up thw wonderland for him that it did for me decades ago. In a world where the darkness is spreading apace a bit of risked brain fry is worthwhile when enlightenment may be the out come. One hopes :-). \$\endgroup\$ – Russell McMahon Jan 7 '15 at 13:51
  • \$\begingroup\$ This is the most readily understandable solution. However, I do enjoy learning so I will try both and solutions for a learning experience. \$\endgroup\$ – Keith Enlow Jan 7 '15 at 14:48
  • \$\begingroup\$ @KeithEnlow - please notice my edit, it may give you ideas. \$\endgroup\$ – WhatRoughBeast Jan 7 '15 at 15:07

See cct below. Warning: DO NOT let Olin see this diagram!!!

This circuit may be used as a guide to how to do what you want using other means, probably.

One circuit of N shown. Schmitt gates not essential but help.

IC1A IC1B form a latch. Master Reset line low sets all latches low via RESET diodes.

"Set" button pressed places high from lh column on IC1A latch in. 10k overrides 1M and IC1A input high sets IC1B out high. LED on (now I have moved it :-) ). AND IC1A out low pulls lh column low and steals the "pick me, pick me !!!" voltage from lh column so nobody else can join you.



enter image description here

IDL, inverter diode logic, a figment of my fevered imagination, is unlikely to be taught in most engineering schools, and certainly has its limits, but can be used to do a wide range of unlikely seeming tasks.
Using Schmitt trigger input CMOS inverters also gives you 1 inverter oscillators and even 1 gate PWM modulators!. For really tough assignment add an LM324 :-). Occasionally an LM339 is more useful than a '324, but usually not.

  • \$\begingroup\$ This solution is a little harder to understand. It also might be because its drawn on graph paper. I am going to try it just as a learning exercise to see if I can get it working! \$\endgroup\$ – Keith Enlow Jan 7 '15 at 14:49

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.