Society of Robots - Robot Forum

Electronics => Electronics => Topic started by: HyperNerd on July 01, 2010, 09:19:45 AM

Title: Xbee 3-Point Network?
Post by: HyperNerd on July 01, 2010, 09:19:45 AM
Hi guys,

I need some help with XBee modules - the 1mW ones (XB24 in X-CTU).

I bought 2 of them a while back from Active Robots here in the UK and they are working great. Whilst the range is a lot less than advertised, they mostly do the job.

Here is where I need help; I currently have one XBee tethered to the PC with a Parallax USB XBee Breakout Board, and the other is mounted on my robot with a Parallax 3.3v/5v XBee Breakout Board. I am now rebuilding my old Sparky robot, and plan on retrofitting him with an XBee radio. I wish to have both of the robots able to communicate with each other and the PC (mesh networking I believe), rather than having them send a message to the PC which then sends it back to the robot which it is intended for (point to multi-point networking)

I know this is possible with ZigBees, but I only have XBees.

Hopefully someone has experience of this to some degree and can offer their guidance.

Title: Re: Xbee 3-Point Network?
Post by: waltr on July 01, 2010, 09:47:59 AM
Yes this can be done. What is needed is to set the Destination address to the XBee you want to send data to.

In AT command mode your processor needs to change the DH & DL parameters with the ATDHxxxxx and ATDLxxxx (where xxxx in the address of the XBee you want to send to) command after writing the +++ and waiting for the OK response and also ensuring that the processor obeys all the Guard times. see the data sheet.

The other way is to run the XBee in API command mode. Then the processor must build a "frame" that has the Destination address embedded in the frame. At first this seems more difficult but is really much easier for a processor to do and allows the greatest flexibility.
Another advantage of the API mode is that incoming data is also in an API frame and contains the address of the sending XBee. This way data could come from either the PC or the other Bot and you can determine from which it came.

 XBee is the module built and sold by Digi International. They come in two hardware flavors and four protocols and many firmware versions.

When asking specific questions about the XBees you have please state the Firmware Version (obtainable from X-CTU) as this is very specific the the XBees you have and then we know exactly which document and features your XBee uses.

Good luck and have fun
Title: Re: Xbee 3-Point Network?
Post by: HyperNerd on July 01, 2010, 10:13:14 AM
Thanks for the speedy reply and great info!

I think I will go with using the API command mode, because of the ability to identify the address of the sender, which will be useful for the project I'm working on.

Do you have any examples of using the API mode with an Arduino, or know where I could read up on it?

That would be greatly appreciated!