document.write('
Data hosted with ♥ by Pastebin.com - Download Raw - See Original
  1. #include <RCSwitch.h>
  2. RCSwitch mSwitch = RCSwitch();
  3.  
  4. void setup(){
  5.  
  6. mSwitch.enableReceive(0);
  7. Serial.begin(9600);
  8.  
  9. }
  10. void loop(){
  11.  
  12. int value=0;
  13. if (mSwitch.available()>0) {
  14.  
  15. value = mSwitch.getReceivedValue();
  16.  
  17. }
  18. if(value>0){
  19.  
  20. Serial.println(mSwitch.getReceivedValue());
  21. delay(1000);
  22.  
  23. }
  24.  
  25. }
');