 /*
-  XBee test on Mega
+  XBee test 
 
-  For old code that works with Aruidno Uno, see git log and pull it from the repo
+  This code now takes charge of interfacing with XBee radio through Arduino Uno's software serial
 
-  Modified upon "Mega multple serial test"
-  
-  Receives from the main serial port, sends to the others. 
-  Receives from serial port 2 (XBee), sends to the main serial (Serial 0).
- 
-  This example works only on the Arduino Mega
- 
-  created 07/25/2013
-  by Ben Zhang <benzh@eecs.berkeley.edu>
+  The idea is to execute AT command.
+
+  created  : 07/25/2013
+  modified : 03/26/2013
+  author   : Sean Chen <sean.yhc@gmail.com>
  
  */
 #include <SoftwareSerial.h>
-
-// #define XBee Serial2
 
 SoftwareSerial XBee(3,2);
 int ledStatePin = 13;

  Serial.print("  count: ");
  Serial.println(i);
  return i;
}
  digitalWrite(ledTargetPin, LOW);
  delay(500);
}

void enterCommandMode() {
  delay(2000);
