Page 3 of 3

Re: Constant current IR LED circuit

Posted: Fri Feb 23, 2024 5:51 pm
by nibbler
After working a looong while on other parts of this project I am back at this point, now I built myself a small ammeter to see what actually hits the LED. However the max I am getting is about 10mA.

timestamp/busvoltage/shuntsvoltage/loadvoltage/mA/mW
45491327 / 0.87 / 0.97 / 0.87 / 9.90 / 10.00

The measuring frequency is a at about 18ms (script isn't faster, running on a D1 mini),
so I might miss some peaks but those should appear once in a while I guess.
The signal length is 29ms (IRRemote lib)

Power supply is a 2A power bank, circuit as above. The resistor on the emitter would be a 0,5 Ohm to hit the max of the allowed A for the ir diode. I just left it out cause I couldn't get 0,5 Ohm resistors yet but I don't think this is the problem?

What do I need to do to push 1A to the diode?

Re: Constant current IR LED circuit

Posted: Sat Feb 24, 2024 2:55 pm
by AnalysIR
post a circuit diagram of your setup -hand drawn is OK showing part numbers and values etc. Also show the voltage supply to the IR LED(s)

A photo would also be useful .

FYI: having no or too low value resistor 'could' blow the IR LED and/or transistor. See my previous post!

Re: Constant current IR LED circuit

Posted: Sun Feb 25, 2024 1:07 pm
by nibbler
photo.gif
circuit.gif

I know missing a resistor in front of the LED could kill it but the bursts are so short and for visual reasons I replaced the IR diode with a cheap yellow one. It is a bit risky, yes.

Signal (IRRemote) : (6 + (16 * 3) + 1) * 526 = 55 * 526 = 28930 microseconds or 29 ms

The IR diode can handle 3A for 10 microseconds, technically it should burn but with my measuring results I am far away from that.

Power supply is a 2A power bank.

Re: Constant current IR LED circuit

Posted: Sun Feb 25, 2024 2:03 pm
by AnalysIR
As before put a resistor on the emitter of the transistor. It is likely the IR LED is blown because of effective short.
resistor value: 3R (you can make this up by paralleling 3 or 4 10R resistors)
This resistor is required.!!!!!

You cannot put a yellow led in place because the current is much higher....so likely also blown because of effective short.

Re: Constant current IR LED circuit

Posted: Sun Feb 25, 2024 5:11 pm
by nibbler
This just makes the signal weaker, just tried with 4.5 Ohm and 2 Ohm.

According to your article:
"Next we look at R1/R4, which at 2.5ohms means that the current going through the resistor will be 0.5/2.5 = 0.2A or 200 mA."

If I put 4 Ohm there it would be 0.5/4 = 125mA or 0.5/2 = 250mA.

Following that sentence a 0.5 Ohm would lead to 1A or lower to even more and that SHOULD kill the LED but it doesn't, it doesn't with the cheap yellow and it doesn't with the IR diode :(
Never thought I could be unhappy NOT destroying a component but that is where I am now.

With the IR Led and 4.5 Ohm resistor:

timestime/microseconds/mA/mW
18:08:58.143 -> 70562044 10.00 10.00
18:08:58.189 -> 70581205 9.30 6.00
18:08:58.189 -> 70600310 6.10 6.00
18:08:58.189 -> 70619321 2.10 4.00

Re: Constant current IR LED circuit

Posted: Sun Feb 25, 2024 5:54 pm
by nibbler
ok 3 diodes and 2 Ohm: about 130mA
4 diodes and 2 Ohm: about 190mA

Maybe I should consider using a different transistor? The TIP120 is a bit too huge I guess.

Re: Constant current IR LED circuit

Posted: Sun Feb 25, 2024 7:03 pm
by AnalysIR
It could also be that the GPIO pin can not provide enough current to drive the transistor + the 2 diodes.

Try taking out the diodes and see if it is any better.

Maybe I should consider using a different transistor? The TIP120 is a bit too huge I guess.
Agree just any jellybean NPN is OK (I usually use 2n4401 or similar....no need for power NPN)