Society of Robots - Robot Forum
Software => Software => Topic started by: nanotechopolis_gr on July 03, 2013, 01:58:29 PM
-
hi guys!
i have an ir receiver(TSOP38238) and a sony remote control! my problem is that when i press one button it displays 3 times the same code, for example if i press 4 then it appears c10 its something wrong with the code or with the sony control?
c10
c10
code:
#include <IRremote.h>
int receiver = 7;
IRrecv irrecv(receiver);
decode_results results;
void setup()
{
Serial.begin(9600);
irrecv.enableIRIn();
}
void loop()
{
if (irrecv.decode(&results))
{
Serial.println(results.value, HEX);
irrecv.resume();
}
}
-
No, remote control senders typically send the code multiple times for error checking.
Google "Sony remote controller decoding" for lots of info.
http://picprojects.org.uk/projects/sirc/sonysirc.jpg (http://picprojects.org.uk/projects/sirc/sonysirc.jpg)
-
thanks :)