Advertisement
bladatwarz6

Untitled

Oct 25th, 2014
130
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.31 KB | None | 0 0
  1. #include <IRremote.h>
  2. #define irPin 11
  3. IRrecv irrecv(irPin);
  4. decode_results results;
  5.  
  6. void setup() {
  7. Serial.begin(57600);
  8. irrecv.enableIRIn();
  9. }
  10.  
  11. void loop() {
  12. if (irrecv.decode(&results)) {
  13. Serial.print("0x");
  14. Serial.println(results.value, HEX);
  15. delay(250);
  16. irrecv.resume();
  17. }
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement