Shop OBEX P1 Docs P2 Docs Learn Events
BS2 and optoisolator — Parallax Forums

BS2 and optoisolator

firestorm.v1firestorm.v1 Posts: 94
edited 2007-05-25 20:04 in BASIC Stamp
Using this optointerruptor http://www.datasheetcatalog.com/datasheets_pdf/G/P/1/A/GP1A50HR.shtml

I was trying to hook it up to the BS2 and I noticed that the BS2 was not receiving any signal from it. Additionally, my cellphone camera can detect IR when I fire several remotes to it and I don't see the opto LED light up in the device.


The way I have it hooked up: (disregard the periods, they're used for spacing, the ='s indicate conenctions)
..................................................Infrared LED
Vcc)=====(470 ohm resistor)====(pin 1)==|>|==(pin 2)====(another LED, non IR)==|>|==Gnd

Vcc)==================(Pin 3)===[noparse][[/noparse]Isolator]===(Pin 5)=====================GND
...................................................................||
...............................................................(Pin 4)=====(220 ohm resistor)==========(IO pin 1)
.....................................................................\\========(10K resistor)=============GND


The 2nd LED remains lit, so I know that voltage is going through the IR side of the opto, but I get nothing out the other end and I don't get anything out of the little slit in the jacket. I reversed the leads going to the IR Led of the opto in case I had it backwards and the non IR led went out. I restored the original connection and the non IR led lit up again. On a hunch I took one of the remotes and aimed at the receiver of the opto and fired at it. The BS2 still did not respond with any value. My VOM also showed nothing on the sensor pin (pin 4). Does anyone have any suggestions on things I can check or did I cook the opto by accident?

Comments

  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2007-05-25 14:31
    Because you didn’t use the code window your schematic lost all of its formatting and is difficult to follow. Forgetting that the connections of the opto you have really depend on how you want it connected, but this may be irrelevant since it appears you’re trying to read the signal from a remote control. The device you have isn’t designed for that. The unit you have is designed to detect the interruption of the IR beam from the adjacent LED. To detect the IR signal from a Remote (which is modulated @ ~40 kHz) you would need a special type of IR detector with the demodulator built-in (linked below). However depending on the protocol the remote is using it may be to fast for the BASIC Stamp to read anyway. I would suggest reading the PDF file located at the bottom of the second link. It discusses reading an IR Remote. I hope this helps. Take care.

    http://www.parallax.com/detail.asp?product_id=350-00014

    http://www.parallax.com/detail.asp?product_id=28139

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
  • firestorm.v1firestorm.v1 Posts: 94
    edited 2007-05-25 20:04
    Oops, sorry about that, lemme try again.

                                      Infrared LED         Regular LED
    Vcc)=====(470 ohm resistor)====(pin 1)==|>|==(pin 2)======|>|======Gnd
    

    Vcc)==================(Pin 3)===[noparse][[/noparse]Isolator]===(Pin 5)================================GND
                                         ||
          (Pin 4)===========(220 ohm resistor)==========(IO pin 1)
                                          [url=]\\==============(10K[/url] resistor)=============GND
    

    Oh wow, that is much better.· I'll keep that in mind if I need to post a schematic or code in the future.

    My concern is that the opto's LED is burned out, as I don't get any indication that it is emitting light. I'm not naieve enough to believe I can see infrared, but I have a camera that does.·It doesn't detect any light coming from the IR LED and I don't know what else I can do to try and troubleshoot this.

    Any suggestions?


    Thank you for your hint about the code window. I thought that was for HTML code..
Sign In or Register to comment.