high voltage LED indicator

Thread Starter

cobol__

Joined Sep 4, 2023
7
So I am currently trying to make a simple LED circut to indicate the charge of a capacitor. I want to have a green LED to indicate the charge is at ~90Vdc and when its under 90V it turns off and a red led turns on, and if possible have a seperate battery to drive the LED's instead of the capacitor, is there any relatively simple way to do this?

So far i thought maybe I could lower the voltage using a resistor to lower the voltage to ~12v and use a form c relay but im not quite sure if it would work.
Screenshot 2024-01-18 203442.png
I'm very new to electronics (I only know up to grade 11 circuitry) so any clarifications on how i could go about this would be greatly appreciated!
 

Ian0

Joined Aug 7, 2020
9,842
Your relay circuit is going to discharge the capacitor. Is that a problem?
Try a 48V coil relay in series with a 47V zener diode. That will switch on around 85V and off at about 60V.
You could also use an opto-isolator, but that wouldn't conveniently give you two LED outputs.
There are better electronic ways to do this, but they are not as simple.
 

Ya’akov

Joined Jan 27, 2019
9,170
Welcome to AAC.

As @Ian0 points out, the coil of the relay will discharge the capacitor. The general approach to this sort of problem that does require more effort is to use a voltage comparator. A comparator takes two inputs a candidate voltage to test and a reference voltage—to test the candidate voltage against.

When the candidate voltage is greater than the reference the output of the comparator is (logically) high, when it is less the output goes low. This can be used, through appropriate circuitry, to do whatever you want. It’s not a very difficult circuit, and surely there are many people here who would be happy to work out an appropriate version for you.

It has the additional advantage of offering different levels of sophistication including the ability to make it easily adjustable so it behaves exactly the way you want.
 

Thread Starter

cobol__

Joined Sep 4, 2023
7
Yes i was hoping to isolate the 2 leds and just have a battery drive the them that way i wouldnt exced the 20ma my 90v supply can handle.
 

Thread Starter

cobol__

Joined Sep 4, 2023
7
Your relay circuit is going to discharge the capacitor. Is that a problem?
Try a 48V coil relay in series with a 47V zener diode. That will switch on around 85V and off at about 60V.
You could also use an opto-isolator, but that wouldn't conveniently give you two LED outputs.
There are better electronic ways to do this, but they are not as simple.
No the capasitor discharging is what i want. I was hoping that after I switch off the power supply the capasitor would discharge via the risistors and coil, that way I won't acidently zap myself when I need to move it.
The capasitor shouldn't discharge until I switch off the power supply right?

I also should of mentioned this though but I'm going to be using the capasitor for a coil gun project I'm working on and the capasitor is just so I can get the high amperage.
 

BobTPH

Joined Jun 5, 2013
8,998
You can isolate the LED from the 90V, but you still need something to measure the voltage that is not isolated. The usual method for isolation is an opto-isolator, which involves lighting an LED, so you might just as well light the indicator.
 

Ya’akov

Joined Jan 27, 2019
9,170
No the capasitor discharging is what i want. I was hoping that after I switch off the power supply the capasitor would discharge via the risistors and coil, that way I won't acidently zap myself when I need to move it.
The capasitor shouldn't discharge until I switch off the power supply right?

I also should of mentioned this though but I'm going to be using the capasitor for a coil gun project I'm working on and the capasitor is just so I can get the high amperage.
While the relay’s coil will provide a load, you shouldn’t rely on it to act as a bleeder resistor which should be included as a guarantee the cap will discharge. If the relay coil fails open, the cap won’t discharge and the indicator will be “safe”—not a good situation.

If this is for safety and independent circuit measuring the voltage is the right way to do it.
 

Thread Starter

cobol__

Joined Sep 4, 2023
7
Hi,

What are you going to launch with it?
just a small peice of metal arround 5 cm long and arround 5 grams ish. ive done the research and as long as it stays under 152m/s and 5.6 joules its perfectly legal which mine is. Even if it exceeds this it is deemed a uncontrolled fire are which i have a licence for.
 

MrAl

Joined Jun 17, 2014
11,494
just a small peice of metal arround 5 cm long and arround 5 grams ish. ive done the research and as long as it stays under 152m/s and 5.6 joules its perfectly legal which mine is. Even if it exceeds this it is deemed a uncontrolled fire are which i have a licence for.
Hi,

I wasn't attacking the legality of such an object, just more curious than anything.
Would this help for some sort of self-protection if you had to carry a lot of money with you or something?
 

panic mode

Joined Oct 10, 2011
2,759
Is it? It's a small scale (talking about less than 30m/s) making little coil guns are perfectly legal here in Canada so I don't see why it would be.
your match checks out...

Energy stored in capacitor is E=C*V^2/2 or in your case about 4J
kinetic energy is E=m*v^2/2

so for a 5gram projectile, and absolutely no conversion losses, the maximum velocity would therefore be 40m/s
reality is that getting the projectile reach 30m/s would likely be quite a feat but reasonable.
 

Thread Starter

cobol__

Joined Sep 4, 2023
7
Hi,

I wasn't attacking the legality of such an object, just more curious than anything.
Would this help for some sort of self-protection if you had to carry a lot of money with you or something?
No i just thought it would be a cool project and so far its been a lot of fun. this is my first electronics project and i thought this would be a good first because it isnt overly complex :)
 

panic mode

Joined Oct 10, 2011
2,759
1705813917284.png
R1 and RX form a voltage divider (roughly 10:1 at max) meaning that you get up to 9V at the base of the Q1 but - this can be trimmed down to 0.7V adjusting Rx.
1N4148 is not necessary - it just adds 0.7V to voltage drop across Rx so that setpoint is closer to the middle of the Rx. Also makes voltage drop across Rx same as D2 zener voltage (Commpensates for Vbe of Q1).
high resistance of R1 (1M) means that current drain on high voltage capoacitor will be minimal.
D3 and Vbe of Q1 set base voltage treshold at 5.7V. At that voltage, and taking Vf of D1 into account, current through Rx is basically Vd2/Rx.
Current through R1 and Rx is
(90V-5.7V)/1M = 84.3uA
that current through Rx need to create voltage drop that matches zener voltage of D2 so Rx need to be set to
Rx=5.1V/84.3uA =60.5k which is close to middle of the Rx range.
Without D1 Rx would need to be set to about 5.7V/84.3uA = 68k

When voltage across C1 is higher, current through R1 and Rx is larger, Q1 turns on and that also turns on Q2

D2 is used to raise the threshold for Q1. without it, it would be only 0.6V (Vbe of the Q1).

R2 and R3 block Q2 - until Q1 turns on. this happens when base of Q1 is at about 5.7V.
so normally D4 would be off when C1 is discharged.
But when Q1 is on, Q2 also turns on and D4 is lit.

R3 limits Q2 base current to about 0.13mA.
D4 current is limited by R5 to sbout 4.5mA.
R6 and Q3 are just an inverter for the red LED.

to get those 4.5mA through Q2and D4, with base current of 0.132mA, transistor gain need to be at least 4.5mA/0.132mA = 35 which sould be no problem for just about any transistor (2N3606 lists it as min 60 at base current of 0.1mA). typically gain should be higher. Q3 is starved a bit by R6. here base current here is only 50uA. i would reduce R3 and R6 to something in the range 10-22k, or even less. this is meant to be switching LEDs on/off, so it is ok for transistors to saturate (work as switch).
also i would reduce the R5 and R7 to 1k, to get about 10mA through LEDs. that should be nice and bright even if you take this outdoors.
 
Top