Pages: [1]   Go Down
Author Topic: Can't figure out this sensor  (Read 757 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 1
Posts: 8
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi guys,

I've disassembled a Brother printer and I found a sensor that determines whether the tray is open/close.
It looks like a pretty straight-forward sensor with 3 pins, so I tried to figure out how to use it although I don't have the datasheet, but couldn't smiley-sad
I tried all combinations of 5v, GND and input pin. None worked.

I'm attaching two images of the sensor. You'll notice 2 little "bumps" with a small distance between them. When something comes in between, the sensor should detect that the tray is "closed", otherwise it's "open".

Thanks!
Eli.


* photo1.JPG (116.91 KB, 640x480 - viewed 25 times.)

* photo2.JPG (124.55 KB, 640x480 - viewed 23 times.)
Logged

Manchester (England England)
Offline Offline
Brattain Member
*****
Karma: 509
Posts: 31458
Solder is electric glue
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Looks like an opto sensor. If you wire it up to power and ground you could have killed it, I suspect it needs a seriese resistor in the power to limit the LED current.
Logged

United Kingdom
Offline Offline
Tesla Member
***
Karma: 220
Posts: 6587
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Looks like an optical sensor to me. One side will be an IR emitter - you can identify this using the diode test function on your multimeter (but if you have put 5V across it without, you may have blown it). The other side will be a phototransistor. You need to connect the diode through a series resistor to +5V so that it draws about 10mA, and the phototransistor between ground and a digital input pin, with the internal pullup resistor enabled.
Logged

Formal verification of safety-critical software, software development, and electronic design and prototyping. See http://www.eschertech.com. Please do not ask for unpaid help via PM, use the forum.

Offline Offline
Full Member
***
Karma: 3
Posts: 244
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

It's a OPTICAL INTERRUPTER something  like this one H21A1
Logged

Offline Offline
Newbie
*
Karma: 1
Posts: 8
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I forgot to mention that I a beginner smiley
If I understand correctly, what you're suggesting is to connect:
5v -> resistor (10K?) -> pin1
input -> pin2 (pullup resistor enabled)
ground -> pin3

Is that correct? I'm not sure of the order of the pins, is there a standard?
Logged

United Kingdom
Offline Offline
Tesla Member
***
Karma: 220
Posts: 6587
Hofstadter's Law: It always takes longer than you expect, even when you take into account Hofstadter's Law.
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

On the connector, the ground connection is evidently the middle pin. Try connecting a 330 ohm resistor (or thereabouts) between +5V and one of the outer pins. Connect the other outer pin to an Arduino input with pullup enabled. You're looking for it to read LOW when there is nothing in the gap and HIGH when there is. If you don't get that, swap the 2 outer pins.
Logged

Formal verification of safety-critical software, software development, and electronic design and prototyping. See http://www.eschertech.com. Please do not ask for unpaid help via PM, use the forum.

Offline Offline
Newbie
*
Karma: 1
Posts: 8
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

On the connector, the ground connection is evidently the middle pin. Try connecting a 330 ohm resistor (or thereabouts) between +5V and one of the outer pins. Connect the other outer pin to an Arduino input with pullup enabled. You're looking for it to read LOW when there is nothing in the gap and HIGH when there is. If you don't get that, swap the 2 outer pins.

It worked!  smiley-cool
Thanks for the info!
Logged

Johannesburg UTC+2
Online Online
Faraday Member
**
Karma: 60
Posts: 3242
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hmmmm I'm going to try dc's approach on a similar sensor I also liberated from a printer. Iirc, I did manage to read a part number and even find a data sheet and still didn't get it to work.... Assuming I didn't release magic smoke during my testing (read as: blundering about with wires and batteries) I might actually get it to work. Then all I have to do is find a use for it.

(Always assuming I can still find the darn thing....)
Logged

Have you looked for answers in the Learning, Reference, Products and Playground tabs on http://arduino.cc/en/ ?
Look here http://electronicsclub.info/ for basic electronics

Pages: [1]   Go Up
Jump to: