Introduction: Configure an Xbee Using Arduino
This will help in configuring a series 2 Xbee directly via a Arduino without any need for a separate USB adapter.
Step 1: Requirements for Configuring the Xbee
Below are the requirements for configuring your xbee
1) Arduino uno board
2) Xbee adapter or Xbee shield(can also connect the pins of Xbee directly to the Arduino)
3) Xbee Series 2
4) male to female wires
5) Arduino IDE
6) old xctu software*
*in the new xctu software I was not able to configure to other modes like at to api, but the old one worked for me.
Note: This tutorial assumes that we have enough understanding about the Arduino and that we can connect and upload the code via the Arduino ide.
Step 2: Preparing the Arduino.
First we have to set up the Arduino by uploading this simple code. At this point Xbee is not connected to the Arduino.
Step 3: Connecting the Arduino With the Xbee 2
Connect the Arduino to the xbee as shown in the sketch.
please note that Tx of Arduino has to be connected to Tx of Xbee and Rx of Arduino to Rx of Xbee Make sure to connect the 3.3v of the Arduino to Xbee's vcc and not the 5v as you might damage the xbee.
For the ttl board that I purchased from robosoft I was asked to connect the reset of the board to reset of the Arduino, this can be seen in the second pic.
Once the connections are made open the Xctu software and use the test to detect the Xbee attached. If "All is well" then you should see the device is of the xbee attached if not don't worry change your baud rate to 115200 and check. If this also doesn't work please do leave your comment I will try my best to help you out /\.
If the device is detected now move to modem configuration tab and select the always update firmware and click on read , this will read the current configuration of the modem mostly it will be in router mode, in this case it's in API mode as I have configured it so.
Step 5: Refrrence and Thanks
Hope this helped you to config your Xbee if you face any difficulty please let me know, always there to lend my hand.
Thank you for spending your valuable time to read this post. Please leave your feedback.
I will leave the link on YouTube from where I learnt this.
Special thanks to Saravanan AL Sir for posting his video on this which helped me.