Go Down

Topic: Infrared LED transmitter and receiver (Read 12958 times) previous topic - next topic


So I have a foosball table and want the score keeping to be electronic. I've figured out the screen and for the sensing of each goal Im using an Infrared LED transmitter and receiver set I got for Radio Shack. I have them set up so 6v goes through a 1k resistor to each infrared led (ones a transmitter one a receiver). I then have a led to ground in series with the receiver. But for some reason it doesn't work, the led should go off when I place my hand between the 2 but it doesn't. It always stays on. If you are a visual person my schematic is like the one on this website; http://atifsheikh.wordpress.com/2011/07/31/infraredir-transmittertx-and-receiverrx/ .

Please help,


There is no way you can get that circuit to work. You can not get enough current through the sensor to control the LED. You need to use a transistor to switch the current.


This works:



hoff's example shows an IR phototransistor; the Atif Sheik blog post shows a regular IR receiver led in his schematic and that would not work.


Ok, then what if I have 5v to the infrared led with a 330 resistor in series and the receiver with a 330 ohm resistor to the base of an PNP transistor.Would that work? 

Atif Sheik blog post shows a regular IR receiver led in his schematic
And yes I do have a regular receiver do I need a phototransistor?


Jul 22, 2012, 05:15 pm Last Edit: Jul 22, 2012, 05:18 pm by Runaway Pancake Reason: 1
The me.umn.edu ought to work.
hadjisra shows a pic of his components in blog link.

I believe they are http://www.radioshack.com/product/index.jsp?productId=2049723

It's a pair, a simple IRED and an IR phototransistor.
It's not a full-blown 38kHz IR RC module (that would not work so simply.)

*** That device is also susceptible/responsive to ambient/visible light. ***
"Who is like unto the beast? who is able to make war with him?"
When all else fails, check your wiring!


Yes runaway pancake thats what they are and I only need  them to detect when a ball passes between them set at inches apart. Is there a way to calibrate them with arduino like over a analog pin?


First get the on/off operation right.
As I posted, that receiver will conduct in visible light, too.
So, when you experiment, put it in a box with the sender.

Maybe the pockets of your foosball table will be dark enough (IDK).

Anyway, I think you should use digitalRead to determine whether the receiver is on/off and digitalWrite to turn the sender on/off.
"Who is like unto the beast? who is able to make war with him?"
When all else fails, check your wiring!


digitalWrite to turn the sender on/off.

There is no need to turn the emitter on and off, just connect it to the supply.


Like Mike said, the emitter just stays on. It's just an led that puts out a little IR instead of visible light. The detector is just a switch that is off/on and is triggered by the IR from the emitter. Once you get that part nailed down you can use this off/on to tell your Arduino when the beam is broken and use that to run your score board.

If you go through the tutorial in the link I posted it should make more sense. It's a pretty neat little project in itself!  I had to make a little shroud for the detector to keep it from getting wonky from room lighting but it should work if you align the emitter and collector straight across from each other.



Hello there, im realy intresting about that project, i want to do the same thing but it is posible that the resiver and transmiter work in daylight too ?
To be or not to be? Read a book and you will see.
Join Discord Free_World (Arduino_Room) Live chat

Go Up