IR for Advanced Beginners
deSilva
Posts: 2,967
There are two IR receivers in the Education Kit. There is ample documentation how to work them; but nevertheless - if someone needs some easy Sunday occupation here it goes:
(1) Connect the IR-Receiver. This is extremely simple, as it is not just an IR-diode but a quite complex chip! The leads are, looking at its "eye":
left = 1 = data output (there are sometimes marks on it, looking like a "3"... very confusing!)
middle = 2 = ground
right = 3 = power supply, nominally 5 V, but 3.3 V does fine!
Now chose any pin (I recommend 15) for connecting the Propeller.
Thats all!
(2) I enclose a small part of a diagnostic program that shows you what is going on with your IR RC. The program works with Andy's PropTerminal, but you can readily change the object to TV_TEXT. There are different carrier frequencies (36 and 38 kHz is standard) , but the hardware is a very complient type..
(3) Have a look into some more advanced explanations and make your own IR keyboard from an old zero cost remote control! I had no problem decoding RC5 and Sony protocol types...
users.pandora.be/davshomepage/index.htm is an instructive link
----
Edit: I was not aware of the work of Bob Belleville obex.parallax.com/objects/37/ This virtually parallels my activities as ever could be .. Have a look there, he also explains the most important protocols in an accompanying PDF
Post Edited (deSilva) : 3/1/2008 7:56:18 AM GMT
(1) Connect the IR-Receiver. This is extremely simple, as it is not just an IR-diode but a quite complex chip! The leads are, looking at its "eye":
left = 1 = data output (there are sometimes marks on it, looking like a "3"... very confusing!)
middle = 2 = ground
right = 3 = power supply, nominally 5 V, but 3.3 V does fine!
Now chose any pin (I recommend 15) for connecting the Propeller.
Thats all!
(2) I enclose a small part of a diagnostic program that shows you what is going on with your IR RC. The program works with Andy's PropTerminal, but you can readily change the object to TV_TEXT. There are different carrier frequencies (36 and 38 kHz is standard) , but the hardware is a very complient type..
(3) Have a look into some more advanced explanations and make your own IR keyboard from an old zero cost remote control! I had no problem decoding RC5 and Sony protocol types...
users.pandora.be/davshomepage/index.htm is an instructive link
----
Edit: I was not aware of the work of Bob Belleville obex.parallax.com/objects/37/ This virtually parallels my activities as ever could be .. Have a look there, he also explains the most important protocols in an accompanying PDF
Post Edited (deSilva) : 3/1/2008 7:56:18 AM GMT
Comments
I bought an IR reciever at what you call "the wrong place".
Think it was this one: http://www.conrad.de/goto.php?artikel=156406
I used IR kit from the object exchange·to figure out the code for my digital camera and "Sony Send Test" to remote control the Camera (Casio Exilim P700).
Works very nicely but it is very dirty so I can't post it until I've cleaned it up... I more or less destroyed the objects instead of using them.
But your code looks very comprehensive, so I'll try to understand it as soon as I got my DOGM figured out some more.
Spin wouldn't be fast enough to transmit IR signals though, would it?
Cheers,
Clemens
·
Which brings us to spin.. 38kHz is the Carrier needed, which is close to the limit of SPIN's capabilities
will need around 20 µs which results in 25 kHz. Unrolling the loop will bring you into that region, but witout any flexibility, unless you choose a very specific crystal.
But there come the TIMERs for rescue. They are absolutely easy to control from SPIN, so your only concern is the "RC protocol", which needs setting HIGH or LOW for 500µs to 700µs (dozens of SPIN instructions!) depending in the protocol; RC5 is most simple to do.
I am just trying to scroll a longer text downloaded from the PC through the DOGM display using your tiny font! I control it by IR, of course .
If needed I can rewrite the driver in PASM, but at the moment this is not the bottleneck, and it would need a seperate COG then...
Post Edited (deSilva) : 1/27/2008 7:35:59 PM GMT