Arduino Card : Arduino Uno R3
Im using Arduino 2.0.4 with IRreceiver library by shirriff.
i have the IRreceiver setup with the arduino card and when i push buttons on my LG remote i keep receiving the same hex code for every input. Please correct me where i am going wrong.
My code is as follows :
#include <IRremote.h>
int receiverpin = 7;
IRrecv irrecv(receiverpin);
decode_results results;
void setup() {
pinMode(receiverpin, INPUT);
Serial.begin(9600);
irrecv.enableIRIn();
}
void loop() {
if (irrecv.decode(&results))
{
Serial.println(results.value, HEX);
irrecv.resume();
delay(150);
}
}
Output is as follows : (i receive same reading for every button i press on the remote.)
12:10:56.169 -> FFFFFFFF
12:10:56.308 -> FFFFFFFF
12:10:56.541 -> FFFFFFFF
12:10:56.716 -> FFFFFFFF
12:10:57.697 -> FFFFFFFF