Pages: [1]   Go Down
Author Topic: IR sensor from other devices, on arduino  (Read 3519 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Newbie
*
Karma: 0
Posts: 6
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I found an old TV PCI board, wich has an IR receiver module used for the remote control.

Is it possible to use this device with arduino?

I open the plastic jacket and found 2 cable(red/white) wrapped around copper cables .. is that a shield? or there are 3 different signal?

How can I used with arduino?


edit :


« Last Edit: September 12, 2010, 11:33:50 am by MattiaReznor » Logged

0
Offline Offline
Faraday Member
**
Karma: 16
Posts: 2857
ruggedcircuits.com
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

This looks like 3 signals, power (probably 5V), ground, and a data output. My guess is that it's a logic-level IR detector like a PNA4602. It should be possible to use this with an Arduino.

For an example of how to use logic-level detectors with an Arduino, and how to learn and re-create IR signals you can look at our sample code for the Gadget Shield.

--
The Gadget Shield: accelerometer, RGB LED, IR transmit/receive, light sensor, potentiometers, pushbuttons
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 6
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The unwrapped one should be the ground in your opinion?
should I put some resistor between the 5v and the anode?
or somewhere else ( before the input) like I would do with a LDR ?
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 6
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

BTW, thanks for the code, but i'm not kinda interest in mux/demux the signal for some remote control ... I just wanna relieve if there is some ir point to the receiver ( for some kind of alarm)

Is that possible without that size of code? or this will alway receive some kind of IR signal from the ambient?
« Last Edit: September 12, 2010, 12:07:54 pm by MattiaReznor » Logged

0
Offline Offline
Faraday Member
**
Karma: 16
Posts: 2857
ruggedcircuits.com
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
The unwrapped one should be the ground in your opinion?

I would think so, but I can't be sure.

Quote
should I put some resistor between the 5v and the anode?

If it's a logic-level receiver like I think it is, then no. It's not so much an "anode/cathode" device as a full integrated circuit with logic. So just plain 5V and GND for power, and the output is digital.

I'm not really understanding how you plan to use this for an alarm...sorry.

--
The Quick Shield: breakout all 28 pins to quick-connect terminals
Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 6
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

let's say that I point a IR LED turned to the IR receiver, then this should be like in a status 1 ... if an object pass between the LED and the receiver, this should prevent the IR to get to the receiver which then be on a status 0


Thats the general idea that I had ...I dont know if is impossible for some reason, like a noisy IR ambient wich could keep the receiver in a 1 status ( is that make sense ? smiley-grin)
Logged

Sussex UK / CT USA
Offline Offline
Edison Member
*
Karma: 0
Posts: 1028
Forums forever
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

You just want to sense "IR signal seen"/"not seen".... which might well work... sort of.

Regarding will ambient IR be a problem: probably not. Probably the sensor is only paying attention to an IR signal, if that signal is on/off/on/off very rapidly... a specific frequency... when it is "on". There are two signals here, working a very different frequencies. Think of Morse code being sent by a buzzer. A "dit" or "dah" might last, say, 100-300 ms... but be made up of an on/off/on/off in the kilo hertz.

Using the signal sent by the IR transmitter is REALLY easy.... If you're going to go to the trouble of getting the thing working, you might as well take the small extra step....

See...

http://sheepdogguides.com/arduino/ar3ne1ir.htm

At that page, you'll see where you can buy.... $3 + p&p something that we all THINK you MIGHT have. Might as well work with a known-good new one as fight with something that may or may not work? And when everything ELSE is working, swap in your salvaged part, and see if it will do.
Logged

Left Coast, USA
Offline Offline
Sr. Member
****
Karma: 5
Posts: 499
Sometimes I just can't help myself.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

This kind of receiver will have an output that is high unless it sees signals with certain characteristics.

1.
In particular, it will not work with a constant signal from an IR LED.  There is a phase-locked loop inside the detector module that only responds to carriers of 38-40 kHz. Any given detector type is optimized for a particular frequency, but my experience is that the carrier frequency can be off by 5-10% and it will work (but the range may be reduced from, say, several meters to, say, one meter or so, depending on the power and optical characteristics of the IR transmitter).

2.
There are filters that make the detector immune to a steady carrier, so if you apply a continuous 38-40 kHz square wave to your transmitting LED, the receiver still won't work. (Its output will remain high.)

Control signals that use devices like this consist of a sequence of on-off keyed carrier of pulses. That is, for each bit in the control signal, the carrier will be on for a few hundred microseconds and off for a few hundred microseconds, where the ratio of on-time to off-time may be used to determine whether a particular bit is a zero or a one.  There are lots and lots and (and lots) of different timing and bit sequence schemes for specific appliances, but the bottom line is that the hardware won't act as a simple IR detector that you are trying to make.

A simple IR photo-transistor might be a better choice for simple applications.  It won't be as "robust" (might require optical filtering to reduce effects of ambient light, for example), and it might not have the performance of the packaged module, but if all you want is to detect whether the IR beam is interrupted, the software can be really simple.


Regards,

Dave

Footnote:If you really want to "get into" the real deal about using TV remote controls, you might start at Ken Shirriff's arcfn.com site.

For example: http://www.arcfn.com/2010/03/understanding-sony-ir-remote-codes-lirc.html
« Last Edit: September 12, 2010, 02:26:17 pm by davekw7x » Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 6
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thank you davekw7x, ill go with the IR phototransitor which seems to be the right choice for what i'm looking for

Never thought about a phase-locked loop inside the detector
Always think to it as simple as possibile!

BTW, with this kind of device(IR phototransitor) woulndt be possibile to make a remote function( with on-off pulses and a computer which understand that )?

I belive that's not completely clear to me the difference between this receiver

Thanks again anyway!
Logged

0
Offline Offline
Faraday Member
**
Karma: 16
Posts: 2857
ruggedcircuits.com
View Profile
WWW
 Bigger Bigger  Smaller Smaller  Reset Reset

The photodiode is just the sensing element. Devices like the PNA4602 take the current from a photodiode it, filter it, amplify it, etc. to provide a digital on/off signal. Here is a block diagram of the PNA4602 showing the photodiode within it:



--
Need a custom shield? Let us design and build one for you.
Logged

0
Offline Offline
Edison Member
*
Karma: 0
Posts: 1103
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

The funny thing is, that those receivers cost only as much as you would expect each of the 7 or 8  elements inside it will cost.
Logged

Left Coast, USA
Offline Offline
Sr. Member
****
Karma: 5
Posts: 499
Sometimes I just can't help myself.
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
cost only as much
Production costs are ridiculously low.  Development costs are completely amortized by the first few million parts sold (probably a lot sooner than that).  These things are used in just about every TV and other IR remote-controlled consumer appliance on the planet.

We small-timers benefit from the economics of scale.  If you can buy one from Digi-Key for a less than a buck, the cost to a big-time contract manufacturer is literally a few cents in large quantities. The parts manufacturer still makes a profit, and the distributer and other middlemen also mark it up a few percent as the parts pass through their hands.

It's a wonderful time to be alive, right?


Regards,

Dave
« Last Edit: September 13, 2010, 02:47:05 am by davekw7x » Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 3
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I got the same "IR eye on wire" as on the first picture in this topic, i took it apart and this is the connections:

Wire---Function--mini Jack
--------------------------------
Red    =  signal = tip
White  = Vcc    =  ring
Shield =  Gnd   = buttom

I connected it to a 5V PSU and measured with digital multimeter on the red wire, it was 5V when not activated and 3V when i pointed a remote control to it. I believe that if I used a scope, I would see the signal go to zero.
BR
Johan o r
Logged

Pages: [1]   Go Up
Jump to: