|
#include <IRremote.h>
#include <IRremoteInt.h>
#include <LiquidCrystal.h>
/*
* IRremote: IRrecvDemo - demonstrates receiving IR codes with IRrecv
* An IR detector/demodulator must be connected to the input RECV_PIN.
* Version 0.1 July, 2009
* Copyright 2009 Ken Shirriff
* http://arcfn.com
*/
LiquidCrystal lcd(43, 42, 41, 40, 39, 38);
int RECV_PIN = 48;
IRrecv irrecv(RECV_PIN);
decode_results results;
void setup()
{
lcd.begin(16,2);
irrecv.enableIRIn(); // Start the receiver
}
void loop() {
if (irrecv.decode(&results)) {
lcd.print(results.value, HEX);
delay(20000);
lcd.clear();
irrecv.resume(); // Receive the next value
}
}
|
|