photointerruptor application

Thread Starter

amsim

Joined May 24, 2009
14
Hi, everybody! I have these Sharp photointerruptors, GP1A50HR. I'm trying to get them to work, but the schematics in the data sheet have two conflicting pinouts. I've wired the emitter with 5v and a 1k resistor, and I can see IR with the camera on my phone. I tried to power the detector side with 5v, according to both pinouts in turn, but I can't read a change in either current or voltage on pin 4 when I put a piece of cardboard into the slot. I think I might have fried it with the reverse voltage, though. Is there anyone who has worked with these?
 

Attachments

AlexR

Joined Jan 16, 2008
732
Your LED current limiting resistor is way too high. The spec sheet state that the LED needs between 10mA (min) and 20mA(max) to drive it. It has a Vf of about 1.1Volt so your series resistor should be around 220Ω or 270Ω rather than 1K.
 

Thread Starter

amsim

Joined May 24, 2009
14
Yeah, I'm wanting to power both sides from the same +5v, with the current limiting resistor to the emitter side. I had mistakenly gotten a value of 5mA from the data sheet. After reading your post, I did some reading, and I saw all over the place that LEDs are usually powered on 20mA. I was looking here -- http://led.linear1.org/1led.wiz -- and I get 220 ohm for 1.1v @ 20mA and 390 ohm for 1.1v @ 10mA, so 270 ohm seems like a good compromise. Looks like a trip to Radio Shack after work tomorrow, cuz I don't have anything even in the ballpark. I did see the inverted output, though. Thanks, guys!
 
Last edited:

Thread Starter

amsim

Joined May 24, 2009
14
Nope, still not workin. I put a 220 ohm resistor in there, but I'm only getting a half a volt from the output. I have 5v going to the detector side. Is that enough?
 

MikeML

Joined Oct 2, 2009
5,444
Nope, still not workin. I put a 220 ohm resistor in there, but I'm only getting a half a volt from the output. I have 5v going to the detector side. Is that enough?
What is the load resistor on the output side? Is the load resistor wired between the collector of the phototransistor and +5V? Emitter to ground, base open? The output voltage is at the collector. 0.5V sounds like the transistor is saturated (sensing the illumination) . The collector should swing to ~+5V when the light is blocked (or the current to the emitter is interupted).
 

Thread Starter

amsim

Joined May 24, 2009
14
What is the load resistor on the output side? Is the load resistor wired between the collector of the phototransistor and +5V? Emitter to ground, base open? The output voltage is at the collector. 0.5V sounds like the transistor is saturated (sensing the illumination) . The collector should swing to ~+5V when the light is blocked (or the current to the emitter is interupted).
I have my meter hooked directly to output and ground. Are you saying that there should be a resistor in series with the meter? How large?
Have you looked at the posted data sheet? There is no direct access to the phototransistor.
 
Last edited:

AlexR

Joined Jan 16, 2008
732
I have my meter hooked directly to output and ground. Are you saying that there should be a resistor in series with the meter? How large?
Have you looked at the posted data sheet? There is no direct access to the phototransistor.
No the GP1A50HR has a built-in load resistor so you don't need extra resistors on the output.

It does look like your interruptor is fried but before you bin it just make sure and use a piece of foil to interrupt the beam. Some materials are opaque to normal light but are actually transparent to IR. I very much doubt that this is the case here but it does no harm to make doubly sure.
 

Thread Starter

amsim

Joined May 24, 2009
14
Yeah, now that you mention it, I think I caught a wiff of magic smoke at some point, you are probably right. I got another unit on order that I think will be simpler to implement. I'll still use these for limit switches, though. Does reverse voltage on the detector side fry it?
 
Top