     Serial.println(results.value, HEX);
     // Serial.println(results.decode_type);
     
-    XBee.print("IR: ");
+    XBee.print(deviceId);
+    XBee.print(": ");
     XBee.println(results.value, HEX);
 
-    switch(results.value) {
-      case signalInit:
-        Serial.println("singalStart");
-        XBee.println("singalStart");
-        break;
+    // switch(results.value) {
+    //   case signalInit:
+    //     // Serial.println("singalInit");
+    //     // XBee.println("singalInit");
+    //     sendMsg("signalInit");
+
+    //     break;
       
-      case signalVerify:
-        Serial.println("singalVerify");
-        XBee.println("singalVerify");
-        break;
+    //   case signalVerify:
+    //     sendMsg("signalVerify");
+    //     break;
 
-      case signalConfirm:
-        Serial.println("singalConfirm");
-        XBee.println("singalConfirm");
-        break;
+    //   case signalConfirm:
+    //     sendMsg("signalConfirm");
+    //     break;
 
-    }
+    // }
 
     irrecv.resume(); // Receive the next value
 


void loop() // run over and over
{
  if(XBee.available()) {
    Serial.write(XBee.read());
    
    digitalWrite(ledPin, HIGH);
    delay(100);
    digitalWrite(ledPin, LOW);
    XBee.write("roger");
  }
  
  if(Serial.available()) {
    Serial.write(Serial.read());

decode_results results;
int deviceStatus = 0;
int pendingTimer;
int deviceId = 1;

char XBeeInString[50];

#define statusOff 0
#define statusPending 1
#define statusOn 2


// const unsigned long signalInit = 0xA90;
const unsigned long signalInit = 0xC1AA09F6;
const unsigned long signalVerify = 0xAF0;
const unsigned long signalConfirm = 0xA70;

