Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

android universal active IR remote (IRdroid)

Status
Not open for further replies.

Misterbenn

Active Member
Hello everyone.

I'm trying to make a universal IR remote for my android smart phone so i can trigger my new DSLR.

I've found IRdroid which seems perfect. It's an active IR transmitter that takes it's input from the 3.5 mm jack of my phone. I've seen some other version just use an IR LED directly connected to the audio output but these all have limited range due to the low power of the audio output.

I’ve attached the circuit diagram. Can anyone tell me why it uses back to back LEDs? My best guess is that the audio output is only good for 20kHz, IR modulation is ~40kHZ, so with this set up you can feed it a square wave and get a pulse on the rising and falling edge effectively doubling your output frequency.

Edit - you can buy the IRdroid but the price is extortionate for what it is. I'm building a through hole version atm and will move onto SMD in the next iteration.
 
Last edited:
Shame no reply :(

Anyway, i've now confirmed this is the case. Both LEDs are lit when the unit is provided with a 20Khz signal. on the output i've measured a nice 20KHz square wave ~3Vp-p with -1.5V offset.

Now this is my question:
How can i check my modulation is correct? presumably if i'm flashing D1 and inversly flashing D2 i wont have a modulated output instead i'll just have a constant output. So do i need to make sure my capacitors discharge to <1V in 25% of the 20KHz period?

I've changed R4 to 30 Ohms in order to get a good brightness out of my LEDs and this will change the RC constant of my drive circuit.

Thoughts?
 
I don't see how it can work with the back to back LED's?, but the circuit is pretty bizarre anyway, why use an audio power amp to feed an LED? - when a simple transistor (or at most two) would do the job far better?.
 
For both LEDs to work you must has an AC signal not just a modulated DC signal. The current has to flow in reverse for the 2nd LED to light. You confirmed this " ~3Vp-p with -1.5V offset"

It is impossible for both LEDs to be on at once. Each time the voltage crosses zero both LEDs will be off. Persistence of vision causes the illusion that both are on at the same time.
 
I think it does work. To answer your question the impedance of the 10 Ufd at 20 Khz is less than 1 ohm so there is very little to be gained by changing it.
 
I think it does work.
It does if the drive voltage is a 19kHz sine wave rather than a square wave.
 
Hello everyone, and thank you for all the responces.

3v0 - you are correct in saying "It is impossible for both LEDs to be on at once. Each time the voltage crosses zero both LEDs will be off." i was concerned that the zero volt crossing would not be of sufficient time to create the correct 40kHz modulation effect.

I did try this with my phone and DSLR (SONY NEX-5) - didn't work. However i've taken the addvice of Nigel Goodwin and changed to a transostor design see attached file. This works very well with the 'DSLR remote' application from the android market.

EDIT - i've decided to add an extra stage after the first transistor stage. I'll use a single PNP on the path to the NPN collectors. From this i expect to be able to drive more current and more LEDS to extend the range while keeping the isolation from the phone
 
Last edited:
I did try this with my phone and DSLR (SONY NEX-5) - didn't work. However i've taken the addvice of Nigel Goodwin and changed to a transostor design see attached file. This works very well with the 'DSLR remote' application from the android market.

You don't want those 330 ohm resistors in the emitters, current limiting resistors should be in the collectors, with the emitters connected to the -ve of the battery.

330 ohm is also a VERY high value, IR output will be very low, and range corresponding very short. To perform as a proper remote control they should be more like 3.3 ohms (or less), and it's absolutely essential to have a decent sized electrolytic across the battery (as in my tutorial hardware).
 
New circuit

Nigel Goodwin i agree with you on both points.

However the resistors on the emitter are required to provide issolation of the L & R audio lines while still giving a ground return path. (disadvantage of using two different return paths!). Also these resistors must be quite large in order to not damage my phone, bigger the better! On the website that i got this diagram from the IR range was ~ 1m.

So i've adapted this design to use a secondary transistor stage. I'm now drawing very littel power from the audio jack ~2mA. But i'm able to drive two IR leds, about 100mA each.

I've also added a capacitor across the battery.

Thanks

EDIT - is the resistor on the base of my PNP transistor needed; I think the resistors on the collector of my NPNs should do the current limiting for me?
 
Last edited:
You can't put LED's in parallel, feed each one via it's own series resistor - or just use one LED - because they are pulsed you can easily exceed their rated continuous current (and all remotes do).
 
Many thanks for your comments again Nigel.

I built and tested the unit yesterday, circuit as in my prior post but without the base resistor on the 2N4126 (PNP). This works fantastically with my Sony Experia Neo -> Sony NEX-5. I’ve achieved >5m reliably so I’m really happy with that. However it doesn’t work with my HTC Desire HD, this needs investigation but I believe this is due to HTC hardware not reproducing the audio file as well as the Sony.

Back to your comment Nigel, you are of course totally correct. My single current limiting resistor should be replaced with two 13Ohm resistors, one in series with each LED.

If I understand correctly you are also saying that due to the LEDs being pulsed I can safely exceed the current limit of the LEDs? So maybe I could use less than 13Ohm current limiting resistor. However at the moment I’m very happy with the light intensity of this unit.

I’ll post photos of my build and latest circuit diagram later today.

EDIT - Just measured the output of my audio jack on the HTC Desire HD, i'm getting Vpeak-to-peak of 0.560V between the L & R channels. This isn't quite enough to turn my first stage transistors on and so is probbaly why this circuit isn't working. The Sony must have higher voltage output. Oh and before anyone says it, i've checked and the audio output is working normal. My headphones with the phone work fine.

Seems like a very low voltage for the audio output though can anyone shed any light on this? Can anyone recomend some small signal transistors or other pre-amp stage? Thanks
 
Last edited:
Ok so i mentioned that i think the voltage on my HTC audio is too low and i'm looking for a solution. I'm now thinking i'll bias the transistors in order to get this working.

I think this voltage issue is why in the first diagram i found they used an Op-amp?
 
Finished Product

Hey Guys,

Thanks for all the help, here is a picture of the finished device with circuit. I used 'DSLR remote' from the android market which works well with this device but this should also work for other applications such as IRdroid.

All the best!
 
It gave me reliable performance over 5m, I haven't had a chance to test it over a larger distance so i'm not sure what its max distance is. Maybe 10 meters for reliable performance
 
hi misterbenn,
i made this device and it works fine with the androlirc library when i test it on lirc interface (mode2) but it does not works on the actual tv sets.
Haave you tried this device with irdroid application on actual tv sets . Please Help. URGENT.
 
This site suffered a hard-drive failure some months ago and many attachments were lost :(
 
Status
Not open for further replies.

Latest threads

Back
Top