How to improve IR LED range (and project show off)

Hi all, I am working on a project where I want to make my own IR remote control. Function wise, everything is working fine. However, the signal strength of the transmitter is very weak. The effective range is less than a meter with direct line of sight. I'm pretty sure it's the transmitter side's problem. The receiver is able to get signals from TV remote controls from at least 5 meters away with high reliability.

My setup on the transmitter side:

  • Generic IR LED from Amazon.
  • Driven by an Arduino Pro Mini 8MHz clone, directly from an output pin, with a 5.6 Ohm resistor.
  • Powered by 2 AAA batteries.

If I power the transmitter with 5V, or even 3.3V, with a bench power, it works much better. However, I need to use battery power to make it mobile.

I have tried to drive the IR LED with a BJT to increase power. However, the microcontroller would brown out (judged from the serial console output) when transmitting. I suppose power supply drops too low. The Pro Mini can theoretically run on 2.8V DC. 3V cuts too close.

I am considering a few options, increasing in complexity for my project.

  1. Use an IR LED with lower forward voltage. I have no idea what IR LED to get. Nothing from Amazon or AliExpress is well speced. But I suppose those used by commercial remote controls must be sufficient since they all run on 3V.

  2. Use 3.7V lithium battery and use a BJT to drive the LED. This requires some mechanical modifictions to my transmitter. I also need a BMS for charging and discharging the battery.

  3. Discard IR altogether and use 433MHz. This requires a lot of changes on the receiver side. So it's my least favorite option. Not to mention I have no idea if 3V would be enough to drive a 433MHz transmitter either.

Any suggestions are appreciated!

P.S. here is the demo of my project, a remote controlled Wall-E. Aside from the weak remote control signal, it's pretty neat!

Try Mouser, Digikey, Newark. And expect to pay more.

1 Like

True, but measure the current value to the LED while it is turned on. Likely to me MUCH more than you are giving your LED.

1 Like

That would be bad. It will draw more than the absolute maximum of 40mA from the pin.

More LEDs in series is an easier way to increase range (old-style IR remotes had 4 LEDs)
IR LEDs have a Vf of 1.2volt to 1.65volt, depending on current.
Calculate for 1.6volt drop per LED and 100mA max peak current.
Narrow-beam LEDs have a longer range, but need better aiming.
You can mix narrow and wide beam LEDs.
Bluetooth (ESP32) could be a better way to control a robot.
Leo..

1 Like

That is not going to happen because that is dictated by Physics.

The problem you have is that you need a proper IR receiver, one that uses modulated light with a tuned amplifier.

Look up the data sheet for a TSOP312. That is a range of seven different specific parts working at different modulation frequencies.

As to the emitter side you then need to modulate (flash on and off) at the same frequency as your TSOP, which is simply a matter of setting one of the PWM pins to produce as close a match to your chosen TSOP312, and using the analogWrite function at 50% to turn it on and 0% to turn it off.

The data sheets contain sample circuits. Do not ignore the 4.7uF capacitor and the 100R resistor.

You can also use two IR LEDs like this:-

2 Likes

You can alter the fuses so it works down to 1.8 volts. Show the wiring diagram with the transistor in circuit.

Is the remote you're asking about the one used in the video?

I was going to suggest switching to AA batteries, but most of my remotes use two AAAs like yours, and that seems to work fine.

You are powering the Pro Mini at the Vcc pin, right? Not the Raw pin.

If you have another Arduino you can use as a programmer, like you would use to burn the bootloader to the Pro Mini, you can use AVRdudess to change the fuses to reduce the BOD voltage to 1.8V. The Pro Mini won't work at 8MHz that low, but it should handle 2.4V well enough, which might let you use the BJT without a brownout.

You can't get any decent distance driving the LED from the GPIO pin. It can't supply enough current. So you need to use the BJT.

But it's not clear why you're getting a brownout using the BJT. Have you tried it with a higher value resistor, like 10R or 22R? That would reduce the voltage sag, but should still provide pretty good distance. It might help to remove the power indicator red LED on the Pro Mini just to conserve that current, and put a big capacitor on the battery line - that will help prevent the sag a bit.

Using two LEDs in series would be ideal, but I just don't know if you can get away with that with two AAAs. That would be pushing your luck, particularly as the batteries discharge. If you have access to Digikey, you could look at the Vishay TSAL6100 (narrow beam) or TSAL6200 (wider beam) LEDs. They are probably more efficient than the Amazon generics.

1 Like

I built a special-purpose TV remote a while back that also uses an 8MHz Pro Mini. It's described here:

https://github.com/gbhug5a/Timed-Mute-TV-Remote

Included is a PDF that explains everything. Much of it is not relevant to your Wall-E, but the hardware LED drive section might be useful. I used a mosfet to drive the LED, but an NPN transistor would also work.

It also includes a detailed instruction on how to change the BOD voltage.

Hello,
Just asking, why don't you use 3 batteries AAA then?

Not a with a decent current, single IR-LED has Vf ~3V if you take max juice out of it.

Wow, that's a lot of info! Thank you all so much. Instead of responding to individual comments, here's a summary of what I have done so far and what I am going to experiment next.

  1. I am modifying an existing PS2 gamepad, hoping to reuse the shell, joysticks, and buttons. Therefore I'm constrained with 2 AAA batteries. But if that doesn't work, I guess I'll just 3D print/laser cut a shell and use 3 AA batteries, which provide a lot more juice.
  2. I realized that driving the LED directly with a GPIO pin is not the way to go, since it maxes out at 40 mA. I am definitely going back to using a BJT or MOSFET transistor. But I need to figure out the brown out issue I experienced earlier. I just tried on a breadboard with another Pro Mini and 2XAAA. It didn't brown out this time. So I'm not sure if the problem was with that particular Pro Mini.
  3. I also measured the current draw. With a BJT, I'm getting ~150 mA out of the LED. If I can manage to use 2 LEDs without browning out the Pro Mini, that's probably going to be work OK.
  4. I'll add a capacitor to the power supply to eliminate voltage fluctuation when the LED is drawing a lot of amperage.
  5. The IR LEDs I got from Amazon might be crap. I'll get some decent ones from mouser. I might experiment with two in parallel.
  6. Since the target is moving and the IR sensor can easily be partially blocked, narrow beam LEDs may not be ideal. But I'll get one and give it a try.

How you measured that?
You can drive IR LEDs up to 1000mA, but only for tiny IR signal with carrier. You can't go above 100mA continuous (something you can measure with multimeter).
Also, to keep things simple, use BJT, but pick a one with higher max current like BC337.
Use single or low double digit series resistor according to your range needed. And use good quality batteries, not something that comes with chinese gadgets.

1 Like

I measured the current by pulling the GPIO high all the time and putting a multimeter in the circuit. I used an S8505 transistor, which. is supposed to be able to handle 700 mA. If I stick with 3V, and the LED's Vf is ~1.5V, with another ~0.7V drop on the transistor, I don't suppose I can get anywhere near 700 mA.
So, either I'll need to use 2 LEDs in parallel or bump up the voltage of the power supply. I have seen some Lithium batteries with the same form factor as AAA batteries (10440). I'm also considering using 2 in parallel to get me 3.7-4 V.

I don't know your specific transistor, but I think your calculations are not correct.
Make sure you saturate it, so don't use high value resistor on transistor base.
And you shouldn't drive the LED above 100mA continuous, so you can't measure the current with DMM.

The safest way to drive an IR LED at high pulse current is with a two-transistor constant current driver.
Peak current can be calculated, knowing 0.6volt falls across Rsense. Rcontrol can be 220 Ohm.
Top transistor 2N2222 ot BC337, bottom one any small signal NPN, like 1N3904, BC547 etc.

I would calculate for a peak current of ~200mA (Rsense = 3.3Ohm). Then the shown diagram with two LEDs needs 5volt minimum to work. A 470uF buffer cap on the supply is needed, to supply the pulse current.
Leo..

2 Likes

And the brutal simple way to drive it at 3V could be something like this.


Adjust the series resistor down to zero if needed.
But just for remote pulse, no way you can write the pin high and measure the current.

LED current of that simple circuit depends highly on supply voltage, and will go down with battery drain. If you want to drive the LED close to it's max current, then a constant current driver is the best option.
Unfortunately many (TV) remotes of the last decades have been using that simple circuit and only one LED. Eighties (Philips) remotes used four LEDs and a constand current circuit with a 9volt battery. The battery often lasted more than 10 years, and the range when pointed was 60m (180ft).
Leo..

2 Likes

More simple than that you can't have. 3V voltage limits the LED current to ~1A, so you don't need any current limiting circuit for normal IR signals. Component count counts :sweat_smile:

@Wawa Since this is just a toy project, I don't really need the battery to last 10 years, lol. But wow, a 60m range is super impressive. You can stand on the street and point it at people's TV in their living room, as long as their windows don't block IR. As you can see in the YouTube video, a cheap Roku remote control works pretty well within a few meters. It runs on 2 AAA batteries. I would think it uses that simple circuit and only one LED.

@kmin That circuit you showed is what I used on the breadboard last night. I used a 5.6 Ohm resistor in serial with the LED. I was not pulsing the LED. I simply pulled the base of the transistor HIGH with a GPIO, and measured 150 mA across the LED. Would the peak current be very different from this measured 150 mA when I use an IR library and modulate the signal?

Normal IR LED is rated to ~100mA continuous and ~1000mA pulsed. Your circuit was drawing more than rated for continuous. You were risking to fry it. So if you send tiny modulated IR remote signal, you can reduce the current limiting resistor and get more range. Down to zero ohm (no resistor). But if you try that with "continuous", you burn your LED. So do your prototyping with double digit resistor and only when you are done, go down for better range.

1 Like