I have tried your library and it works great. However when I used the same arduino board for both sending and receiving IR data I noticed the following:
1. I couldn't receive the data I was sending, but I could receive data from other IR sources. The explanation probably here is that while IR data is sent, arduino is busy and the IR reception subsystem doesn't get a chance to record data.
2. I was receiving fine up until I sent the first byte via IR. From that point and further reception of IR data from any IR source stopped. Could this be some sort of "API interference" between IRsend and IRrecv?
The program is:
#include <IRremoteInt.h>
#include <IRremote.h>
// IRSendPin fixed to 3 (PWM)
int IRRecvPin = 11;
IRsend irsend;
IRrecv irrecv(IRRecvPin);
decode_results results;
void setup()
{
Serial.begin(9600);
irrecv.enableIRIn(); // Start the receiver
}
void loop() {
if (Serial.read() != -1) {
for (int i = 0; i < 3; i++) {
irsend.sendSony(0x90,

; // Sony TV power code
delay(100);
}
}
if (irrecv.decode(&results)) {
Serial.println(results.value, HEX);
irrecv.resume(); // Receive the next value
}
}