IR SEND

Hello, i want to send a specific data throught IR LED from my arduino to a PC. i want to send this message "0x41 0x61 0x36"

how can i program that , please help me

how can i program that

To match whatever is going to read it.

i don't understand ?, i want to send those data 0x41 0x61 0x36 throuh IR.

i want to send those data 0x41 0x61 0x36 throuh IR.

To what? Something has to be reading the data. How you send the data depends on what is reading it.

i have an IR sensor that read IR DATA. this IR SENSOR is pluged on a specefic electronic card. look the picture.

me i want to communicate with this IR SENSOR, throuh an other IR wich will be an IR led on my arduino.

so to start this card we have to send this data 0x41 0x61 0x36.

so how to program that

OP’s pic for others:

7aafb2150ec8e21a05c8ce160455ada240d3bfe3.png

Do you understand what that diagram means?- you need a 156300Hz carrier.

So, first thing you need to do is make a 156300Hz carrier wave and see if your sensor accepts it. You need to get that right before you then try to modulate that with your message.

This example at adafruit makes a 38kHz carrier, so using that as a starting point, let’s see if we can do 156.3kHz using their method.

156300 Hz is 4.11x 38k so we need to speed adafruit’s example up by 4.11x. So instead of 26us per cycle we need 26/4.11 = 6.3us(edit: I see the pic says 6.5, whatever) of which 2x3us = 6 is already taken up with the 2x digitalWrites so that’s not going to work. (In fact I found in practice the digitalWrites were 4us each, so that’s 8 already…)

The alternative way to make carriers is to use tone() but it only goes as high as 65k.

So I’m not sure it’s feasible to make a 156k carrier, but others may now of different methods.

You can use direct port manipulation for faster IO changes. For example:

while(1){
PIND = PIND | 0b00000100; // toggle output by Writing to Input register.
}

Will create a 2 MHz square wave.

@JIMBOZA thanks for this detail :)

@CrossRoads i don't understand could you explain more .

the idea of the project is to comunicate with the IR sensor by an IR LED, based with an RS232 communication.

there was a pda who has an IR led that communicate with this IR sensor based on rs232 / ttl communication.

me i want to do the samething, the problem is i haven't the source code of the program that run the IR led. they used the IR LED like an rs232 communication

and now i want to do the same with arduino the data i posted befor is to start the card and make the card blinking. i tried with ir adapter from my pc, i send the same data that the PDA SEND, but the IR SENSOR not answer

could you help me please

No ansewer :(

I don't know if blink without delay can be used to make 156300 Hz , I've not been able to make it run that fast. Maybe the solution is an external 156300 Hz generator, then use an AND gate with an Arduino signal to control the burst of signal going out.

I wonder if this IR Thread may help?

...R

there was a pda who has an IR led that communicate with this IR sensor based on rs232 / ttl communication.

Was this an IRDA PDA? AFAIK, IRDA is baseband signalling; there is no carrier.

No it is not an IRDA PDA, i said we use the rs232 communication with IR. we don't rs232 wire we use ir led. so imagine like you mak an rs232 communication but with IR LED not with the cable.

jone31: we use the rs232 communication with IR.

That's what the link in Reply #10 is about.

...R

?? link there is no thing when i clic on it !!!!!

jone31: ?? link there is no thing when i clic on it !!!!!

Works for me....

send me the link please :(

jone31: send me the link please :(

http://forum.arduino.cc/index.php/topic,10555.0.html