A voltage indicator LED circuit, that runs off what it's measuring? - Page 1
Forum section: electronics / beginners

author: badgerthing
author_rank: Contributor
timestamp: March 11, 2021, 04:28:25 am
content: Hello!I'm designing something, and would like to have a voltage indicator LED that is ON above a certain voltage (such as 4.8V).There is no auxiliary supply I can use - it must be powered from the voltage source it's measuring (plenty of current is available).A zener diode and resistor is the first thing I tried, but as I expected, it is much too linear, turning on quite gradually as the voltage rises above the zener voltage.I imagine I'll need a transistor circuit of some sort which provides a bunch of gain.Thanks!JD

author: gregben
author_rank: Newbie
timestamp: March 11, 2021, 04:53:03 am
content: What's the maximum voltage in this circuit?DC or AC or both?

author: badgerthing
author_rank: Contributor
timestamp: March 11, 2021, 04:57:28 am
content: The maximum voltage will be 5.0V DC, provided the power supply is operating correctly. Let's say 5.1V for a good margin.

author: sleemanj
author_rank: Super Contributor
timestamp: March 11, 2021, 05:12:16 am
content: What about a TL431?

author: badgerthing
author_rank: Contributor
timestamp: March 11, 2021, 05:14:21 am
content: Quote from: sleemanj on March 11, 2021, 05:12:16 amOh yes I see a lot of TL431 "battery indicator" circuits people have made. I do have some TL431s, so I'll experiment. Thanks!

author: bobbydazzler
author_rank: Regular Contributor
timestamp: March 11, 2021, 03:34:10 pm
content: https://www.ebay.com.au/itm/0-28-Inch-Mini-LCD-Display-Voltmeter-DC-2-6-30V-AU-Stock/393009925992?ssPageName=STRK%3AMEBIDX%3AIT&var=661929433449&_trksid=p2057872.m2749.l2649This voltmeter does exactly as you describe, this means it gets slightly brighter the higher the voltage it's measuring and I doubt it's super accurate but I'm sure it's accurate enough for a lot of uses(like an LED circuit).

author: MikeK
author_rank: Super Contributor
timestamp: March 11, 2021, 03:54:24 pm
content: Constant current source with an open-drain/collector comparator switch?

author: StillTrying
author_rank: Super Contributor
timestamp: March 11, 2021, 08:48:12 pm
content: Well this nearly works,greenis the 5V changing between 4V8 and 5V2, andredis the current through a red LED. I don't know how good the TL431 model is or how much improvement could be done.Added .asc if any LTer wants to improve it.Edity: Tweaked the values for a faster switch on and off of the LED.

author: richard.cs
author_rank: Super Contributor
timestamp: March 12, 2021, 11:04:46 am
content: Quote from: StillTrying on March 11, 2021, 08:48:12 pmIt looks far too slow a transition for a 431 to me. Definitely suspicious of your model.

author: StillTrying
author_rank: Super Contributor
timestamp: March 12, 2021, 05:01:57 pm
content: Quote from: richard.cs on March 12, 2021, 11:04:46 amI tried adding 910k of positive feedback from the transistor's collector to the TL431's Ref which helped alot and gave it around 60mV of hysteresis, but then found I could tweak the resistances, mostly reducing the base emitter resistance to speed up the switching of the LED current.

author: badgerthing
author_rank: Contributor
timestamp: March 13, 2021, 11:35:41 pm
content: HelloThis circuit works well for me and is adequate for the 5V indicator.And the same circuit works for an AC voltage indicator, just with a 1N4148 in front.

author: StillTrying
author_rank: Super Contributor
timestamp: March 14, 2021, 12:35:54 pm
content: That looks OK badgerthing, I'll simulate it later.Later... It switches the red LED on and off around 4.82V, I lowered the 10k LED resistor to 680R to get some current through the LED.

author: badgerthing
author_rank: Contributor
timestamp: March 14, 2021, 05:58:59 pm
content: Ahh I don't trust my simulate ability. I've been testing in person, with a variac for the AC control. They both work great.I've always found resistor values odd for LEDs. OR most of my LEDs are just efficient types.Some of my LEDs you do indeed want 20mA for good brightness.But most of my LEDs are quite visible at barely 1mA, with 5mA being quite bright.The application of these circuits are a power brick - you don't really want bright LEDs on them. 10K works well for the particular LEDs in my junk bin.

author: StillTrying
author_rank: Super Contributor
timestamp: March 14, 2021, 06:30:48 pm
content: "Ahh I don't trust my simulate ability"LT Spice is quite easy when someone else has drawn the circuit, it's not much more than opening or dragging and dropping the .asc, clicking on run and then the wires to see the voltages.The wasted 6mA through the 470R can be lowered a lot down to about 0.25mA.For the superbright LEDs I've got 1mA is enough for a blue or green indicator, unfortunately not for the red orange or yellow, to see a red at similar brightness to blue or green needs around 5 X the current.

author: badgerthing
author_rank: Contributor
timestamp: March 14, 2021, 06:33:56 pm
content: I find increase the 470 to 1K, but going much higher seems to increase the linear region rather than the LED coming on suddenly.I am using diffused red 3mm LEDs from China. I don't get many components from China, but it seemed the best place for an "LED assortment box".I also have some 3mm red from Broadcom that I actually have datasheet for. These are very dim - oldschool.I've used Multisim for some simulating - it is quite advanced/cluttered, and has bugs, but is easy for basic stuff. Circuitsjs is my fave for visualising fundamental stuff.

author: StillTrying
author_rank: Super Contributor
timestamp: March 14, 2021, 07:15:35 pm
content: "seems to increase the linear region rather than the LED coming on suddenly."It does, but the switching curves are not too bad at least in this simulation, here's a switching at 7.56V version,redtrace is the wasted current.