Reflective Optical Sensor

I am looking at this optical reflective sensor to make a simple encoder.

http://www.omron.com/ecb/products/photo/3/ee_sy124.html#Dimensions

Just need it to count motor revolutions and I have a very limited space so this sensor seems like ti woule work well. I guess I don't understand howow these things work though - I assumed that I would just supply some voltage, and a pin on the thing would go high or low depending on reflectivity. However I am confused...

Emitter - Forward Current = 50ma Emitter Pulse frward current 1 A Emitter Foward Reverse voltage 4V

Detector Collector-Emitter Voltage 30V!!!!!!!!!!!!!! What is that? I need to spuplly that? Read that? etc. etc...

Please help! I need to interface this to the Arduino. Thanks! Brandon

somewhere on that page it says "absolute max. ratings" ;D

connect:

  • pin c to digital input

  • pin c through 10K resistor to +5

  • pin e to gnd

  • pin k to gnd

  • pin a through a 330 ohm resistor to +5

Then read digital input pin …

I would draw it for you, but someone needs to invent an easy java drawing thing for fora like this.

If you want something like this premounted on a compact PCB for easy connectivity, you could consider using a QTR reflectance sensor:

http://www.pololu.com/catalog/product/958 http://www.pololu.com/catalog/product/959

If you don't need it, you can grind off the mounting hole to make it even smaller. We even have an Arduino library for interfacing with the sensor, though for the analog version (QTR-1A) it's pretty much as simple as reading an analog voltage.

To interface with an Arduino, just connect GND to ground and VIN to your 5 V line or a digital output pin (in which case you can control when the sensor is on). OUT is the sensor's output.

  • Ben

Holly crap! Thanks guys! This forum is awesome.

bens,

I will take a look at that sensor - I think it will work for me. Brandon

Bens, You mentioned there was an Arduino Lib for interfacing with the digital version of this sensor - where would I find it? I didn't see it in the hardware section. Thanks! Brandon

Here is a direct link to the library and its documentation:

http://www.pololu.com/docs/0J19/all

I added the library to the Interfacing With Hardware section of the Playground (Input > Visual/IR subsection).

  • Ben

Thanks