Hello ,
I wrote a code that if an input is HIGH,the IR send a code on HEX to a reciever,but it's not working.
Could someone help me.
this is the wrong code:
#include<IRremote.h>
IRsend irsend;
int Send_PIN=2;
void setup()
{
pinMode(digitalRead(13),INPUT);
pinMode(digitalRead(12),INPUT);
pinMode(Send_PIN,OUTPUT);
}
void loop ()
{
if(digitalRead(13) == HIGH)
{
irsend.sendSony(0xa00,13);
delay(50);
}
if(digitalRead(12) == HIGH)
{
irsend.sendSony(0xa01,13);
delay(50);
}
}