2
\$\begingroup\$

I want to design a circuit that has 3 LEDs connected to it.

When the voltage of the power source connected to the circuit is...

3.6 volts I want only the first LED to light.

7.2 volts I want the second LED to light. The first LED can light also.

14.4 volts I want the third LED to light. The first and second LED can light also.

Is this kind of thing possible? and how do I make a start?

Thanks,

Karl

EDIT: sorry guys, the dashes were confusing. I'm trying to measure positive voltage. What I'm making is an enclosure system that allows you to make battery packs of various voltages, 3.6, 7.2 and 14.4v. I want to make a measurement tool that confirms there is power and indicates what voltage the pack currently has.

\$\endgroup\$
2
  • 2
    \$\begingroup\$ You can google "bar graph LED schematic". There are many possible approaches. \$\endgroup\$
    – Wesley Lee
    Apr 5, 2018 at 16:53
  • 6
    \$\begingroup\$ Ar those voltages actually negative or are you just setting them off with dashes in front? \$\endgroup\$ Apr 5, 2018 at 17:16

7 Answers 7

2
\$\begingroup\$

Here is a straightforward Zener-based circuit which accounts for the forward voltage drop over the LEDs themselves:

schematic

simulate this circuit – Schematic created using CircuitLab

D1 is a 4.7V device, and D2 is an 11V device. These should give enough margin to work with different colours of LED, not just red (which tends to have the lowest forward voltage).

Note that since the full voltage is still applied to the first LED's limiting resistor, that will be the brightest one even when a higher LED is in fact lit. For that reason I do recommend that you use different coloured LEDs, taking advantage of the fact that red appears less bright than other colours.

An alternative circuit using transistors as LED drivers avoids this problem, and yields LEDs with identical brightness:

schematic

simulate this circuit

In this case, D1 is a 5.1V type and D2 is 10V. The precise values are less critical than with the first circuit; the forward voltage that has to be added to the Zener voltage to obtain the threshold is that of the transistor (typically 0.7V), not the LED.

Notice also that all three LEDs now draw from the same limiting resistor. This makes the brightness of each LED more nearly the same regardless of which battery is connected, since although the current through the resistor is increased with higher voltage, that current is shared by more LEDs. However, because the LEDs are now effectively connected in parallel, they should all be the same colour (and hence forward voltage).

\$\endgroup\$
6
  • \$\begingroup\$ Why do we need to add Zener voltage + transistor Fwd voltage for the threshold value instead of the LED? \$\endgroup\$
    – CNA
    Apr 9, 2018 at 3:48
  • 1
    \$\begingroup\$ Just look at the second circuit - the Zener is in series with the transistor's base-emitter path, but not with the LED. So the Zener will conduct when the battery voltage rises above the Zener threshold plus the base threshold, and that's when the transistor will turn on, driving the LED. \$\endgroup\$
    – Chromatix
    Apr 9, 2018 at 16:51
  • \$\begingroup\$ Hello, thank you very much for your elegant solution. I'm new to this and only beginning to understand. This application I'm speaking of is a battery voltage tester. Does the transistor set-up increase the current draw of the circuit? I'm asking because this circuit will need to draw as little current as possible in order to do its job. \$\endgroup\$ May 23, 2018 at 11:43
  • \$\begingroup\$ @KarlPeters The second, transistorised circuit should consume less power than the first, Zener-only circuit with the higher voltage batteries, and the same amount with the lowest voltage battery. The vast majority of the power goes to lighting the LEDs, and you can tune that by varying the resistor value. \$\endgroup\$
    – Chromatix
    May 24, 2018 at 8:44
  • 2
    \$\begingroup\$ The second circuit does not have current limitations for the series connection of the zeners and the B-E junctions, so when the battery voltage is higher than their thresholds, the current will increase to probably catastrophic levels. \$\endgroup\$
    – PStechPaul
    May 19, 2023 at 23:09
3
\$\begingroup\$

The device you need is called "dot bar graph driver", most commonly implemented as LM3914 integrated circuit. Here are instructions how to use it. You just need to adjust voltage dividers to suit your particular levels.

enter image description here

The LM3914 can safely operate up to 25V, so just connect the net labeled (5V) to positive terminal of your source, and ground net to negative terminal of the source you need to monitor. The circuit, however, will consume maybe 10-20 mA, so the source should be capable of supplying this current without affecting its voltage.

\$\endgroup\$
7
  • \$\begingroup\$ All of which don't operate with negative voltages. This isn't an answer, just a copy-and-paste. Downvoting, I'm afraid. \$\endgroup\$
    – TonyM
    Apr 5, 2018 at 17:10
  • \$\begingroup\$ (sorry for my rubbish writing, I meant:) To be fair, I don't have to be - you wrote an answer to the question. I just compared the question and your answer then commented. But if you doubted the polarities, how comes you wrote an answer? Using an LM3914 is a way of doing it but please then show a circuit to the OP that does the whole job, rather than imply it. \$\endgroup\$
    – TonyM
    Apr 5, 2018 at 18:56
  • \$\begingroup\$ Take care when flagging answers, use the downvote first, use low quality or not answer only if it fits the bill. See this: meta.stackexchange.com/questions/86984/… \$\endgroup\$
    – Voltage Spike
    Apr 5, 2018 at 19:01
  • \$\begingroup\$ @TonyM cut people some slack, remember SE's policy is 'be nice'. People can edit they're answers. \$\endgroup\$
    – Voltage Spike
    Apr 5, 2018 at 19:44
  • \$\begingroup\$ @laptop2d, I completely endorse the rules and am one of many very polite on the site, ready to discuss and to reach friendly agreement. You can follow that chain here, including frankly silly and snide replies with no goodwill. Those wear out patience. Answers can indeed be corrected, which I've been encouraging but not seen. We're representing professional engineering here, sad to see petulance and impatience. This had all run its course some time back, though. \$\endgroup\$
    – TonyM
    Apr 5, 2018 at 20:59
3
\$\begingroup\$

The cheapest and easiest solution I can think of at the moment is using zener diodes. Get the zener diodes for the voltages you want to indicate 3V, 7V, and 14V approximately.

Putting an led in series with the zener, and a current limiting resistor should work. The first light will turn on at 3V, at 7V the second light will turn on and the 3V one will remain on, and so on.

\$\endgroup\$
3
  • \$\begingroup\$ This seems like a good answer, but don't forget to account for the LED's forward drop voltage (typically 1.8 to 3.3 V depending on colour) when choosing your Zeners. You probably don't need a Zener on the 3V indicator; if you're using red LEDs, a 5V and a 12V Zener will correctly select the upper two. \$\endgroup\$
    – Chromatix
    Apr 6, 2018 at 18:22
  • \$\begingroup\$ If the first led lights at 3.6v, wont the current become excessive on that led at 14.4v? \$\endgroup\$
    – Drew
    Apr 6, 2018 at 18:46
  • \$\begingroup\$ It'll certainly be brighter, but you should choose your limiting resistor for the highest voltage anticipated. I've posted an answer of my own which includes a slightly more sophisticated circuit. \$\endgroup\$
    – Chromatix
    Apr 6, 2018 at 19:14
1
\$\begingroup\$

Use three comparators with inputs at -3.6V, -7.2V and -14.4V.

\$\endgroup\$
1
\$\begingroup\$

Well, this is the simplest as possible. Since diodes are current elements, it matters to them, that enough current is flowing through, which for a regular led is something between ~1mA and no more than 20mA.

(I'm often using LEDs, that you can see, if they're turned on at already 1mA)

3.6V - D1, resisor 960 R, the current will be about 3.75mA 7.2V - D2, resistor 1920 R, the current will be about 3.75mA 14.4V - D3, resisor 3840 R, the current will be about 3.75mA.

This schematics will work just fine and diodes and none of the diodes at voltage 14.4V will not be harmed.

schematic

simulate this circuit – Schematic created using CircuitLab

\$\endgroup\$
1
  • 1
    \$\begingroup\$ This won't work as required. Any of the three specified voltages applied will light all three LEDs, with the second and third ones simply being dimmer. \$\endgroup\$
    – Chromatix
    Apr 6, 2018 at 18:15
1
\$\begingroup\$

Here is a preliminary idea:

schematic

simulate this circuit – Schematic created using CircuitLab

Voltages

LED currents

Here's a simpler implementation:

schematic

simulate this circuit

Battery voltages

LED currents

I had to make one more try at optimizing this design:

Battery tester

\$\endgroup\$
5
  • 1
    \$\begingroup\$ I think we are obsessed with these little LED circuits :-) \$\endgroup\$ May 20, 2023 at 14:30
  • 1
    \$\begingroup\$ I consider it a challenge, and the circuits may prove useful in other applications. \$\endgroup\$
    – PStechPaul
    May 20, 2023 at 21:31
  • 1
    \$\begingroup\$ I think we are also possessed by a spirit of invention:-) It's just a pity that the environment here does not stimulate it. I also made quite a few variations of the circuit similar to yours. I had high hopes for the simple voltage divider, but no distinct thresholds are obtained. Another problem here is the varying input voltage (no constant supply voltage). I came to the idea that in addition to threshold diode elements (Zener diodes or the LEDs themselves) connected in series, there is also a need for diode elements (Zener diodes) connected in parallel to fix the input voltage of each cell. \$\endgroup\$ May 21, 2023 at 6:45
  • \$\begingroup\$ PStechPaul, I have improved the parallel diode circuit (as my comment above) and am now thinking of a series transistor circuit with constant-current diodes (JFET). In this regard, I am interested in your preliminary transistor circuit. \$\endgroup\$ May 22, 2023 at 21:32
  • \$\begingroup\$ PStechPaul, As far as I understand, in the output part of your first transistor circuit above, you drive the LEDs with identical current sources (to ensure uniform brightness). It remains only to make the input part so that the current sources are turned on at different input voltage levels. But what I see is not exactly the case because the input voltages, respectively the LED currents, change. It turns out that there is still a need for voltage threshold elements at the input? \$\endgroup\$ May 23, 2023 at 14:21
1
\$\begingroup\$

Such simple but clever circuits of LED voltage indicators have always attracted me and made me come up with the simplest possible solutions. There was an additional difficulty here - the indicator did not have its own power supply, but had to be powered from the input source. This awakened the inventiveness in me and made me join the competition here.

Improving the transistor circuit

First, I improved (added current-limiting and current-equalizing resistors to) the @Chromatix's transistor circuit.

schematic

simulate this circuit – Schematic created using CircuitLab

Inventing a new diode circuit

But the real challenge for me was to make a diode circuit in which the brightness of the LEDs does not depend on the varying supply (input) voltage. Guided by the notion that the path by which we arrived at the final circuit solution is more important than the circuit itself, I have shown below in four successive steps the course of my thoughts. Since my goal is to reveal the idea, I have considered a conceptual circuit with "ideal" diodes.

Basic idea

Such an LED bar indicator is a set of LEDs with step-increasing threshold voltages.
Parallel limiting. I came to the idea that in addition to threshold diode elements (Zener diodes or the LEDs themselves) connected in series, there is also a need for diode elements (Zener diodes) connected in parallel to fix the input voltage of each cell. Thus the currents will be equal.
Series limiting. Another solution would be to limit the current through the LED by a constant-current element but more on that later.

LED as a threshold element...

The single LED is itself a threshold element - it starts to pass current and lights up when the voltage across it exceeds its threshold voltage.

schematic

simulate this circuit

It is a very sensitive indicator that sharply reduces its "resistance" at that moment. As a result, the current increases sharply when the voltage increases and exceeds the maximum permissible value.

STEP 1

... with current-limiting resistor...

To limit the current, we insert a constant resistor R in series. The requirements for its resistance are contradictory - on the one hand, it must be low (to ensure high sensitivity) and on the other hand, it must be high enough (to limit the current to the permissible value).

schematic

simulate this circuit

But still the current varies and the LED changes its brightness when the input voltage varies.

STEP 2

... constant brightness...

We have to somehow make the current constant. We have two options to do it - either make the voltage constant or the resistance dynamic. Let's try the first one by starting to reason like this:

Once the LED starts to glow with its normal brightness, the voltage across the R-LED network should stop changing. Clearly, we have to connect a (Zener) diode in parallel to the network (I have used a forward-biased "ideal" diode for this purpose).

schematic

simulate this circuit

However, there is no desired change in the current through the LED...

STEP 3_1

... but the current through the shunt diode D has become unacceptably high.

STEP 3_2

... another current-limiting resistor...

Ah, we had to include another current-limiting resistor R1 because of the D diode.

schematic

simulate this circuit

Thus a kind of "voltage window" is obtained within which the current changes and then remains constant.

STEP 4

... and "lifted" threshold...

We can increase the threshold of the cell by "lifting" it on the right with a second (reference) voltage source Vref.

schematic

simulate this circuit

Thus we artificially increase the threshold voltage of the LED.

STEP 5

... with reference diode

But there is no power supply here to get Vref from. So, we again use another (Zener) diode D2 through which we pass the current of the cell and use the voltage drop across it as Vref.

schematic

simulate this circuit

STEP 6

LED bar assembled

Now it remains only to make a ladder of such cells and we get the desired LED bar indicator.

schematic

simulate this circuit

I have shown only three cells, but it can be expanded with more cells, only the current consumed increases (a disadvantage of the parallel configuration).

STEP 7

Advantages

As you can see, two more clever tricks are added to this Russian Matryoshka-like structure:

  • The shunt diodes (D1, D2, D3...) are not grounded but connected in parallel to the R-LED networks. The advantage of this connection is that the diodes have the same low threshold voltage.

  • The reference diodes (D4, D5...) are connected in series. The advantage of this string connection is that the diodes can have lower threshold voltage (because they are summed).

\$\endgroup\$
1
  • 1
    \$\begingroup\$ I want to point out that I was inspired to write this story by @PStechPaul's original circuit solutions and the thoughts exchanged with him, for which I thank him. \$\endgroup\$ May 22, 2023 at 21:24

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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