Sick My XBEE

April 10, 2010 at 21:14 (Electronics, Uncategorized) (, , , )

This is the Story i had the last weekend with some cool Chips named “XBEE”.
These Chips are intelligent RS-232 -> Wireless sender and reciever who can stickt together to a so called mesh network.

First i have to tell the terminology:
“Coordinator” – is the Main Boss of the Network, who coordinates everything – and let routers and endpoints connect
“Router” – is a endpoint but can route packets and other endpoints can connect to it.
“End Device” – is a endpoint but noone can conenct to it – it is designed to save energy and run from batteries.

Mesh Networking is really fantastic because you can have a coordinator (“middle”) which is connected to routers and end devices, and is “self-healing” this means if a router is powered off, packets get automatically routed through another reachable router – so packets can arrive to their destination.
If a Enddevice don’t have a connection to a router or the coordinator, put a router in between and it will connect seamless without configuring routing or anything manually.

More about the theory you can find in the references section at the end of my Post.

Okay, first a Picture of my actual “Setup” then the painful story :)

First of all i wanted to see if i can interface with the XBEE’s, so i took a MAX232 5v serial transciver out of my inventory and connected Tx,GND to the xbee.
Rx i connected with with a voltage divider (german: Spannungsteiler) because it came in with 5v and the Xbee only like 3,3v.

Looked everything well, started X-CTU (xbee config software), got a reply and can change values in the configurtion.

GREAT i thought, while reading the documentation i see i need to flash the firmware of one Xbee to get a Coordinator so i can connect the other Xbee to it.

So readed so done, selected “ZNet 2.5 Coordinator AT” in X-CTU, and clicked WRITE.

X-CTU is giving me the following output:

“Entering command mode…
No response from Modem…

Damn i thought!

The Xbee looks now damaged as i cannot connect to it anymore – resetting power helped me :)

Anything gone wrong, i readed the documentation again and saw that i need to connect RTS and DTE.

Tried again, don’t work, interchanging cables, don’t work.
I tried interchanging the cables in all possible ways for about 8 fscking hours but nothing helped me.

I can connect to the xbee and change values but i don’t get an other firmware on it.

For this day i was so angry that i gone to bed :o) I thought, new day new chance…

So new day in the morning first i installed an free Serial Sniffer so i can see what’s going on.
Communication is fine before it tries to flash then it invokes a command to flash and it looks like the chip is responsing binary bullshit.

I readed the documentation again and saw that i can enter the bootloader manually by Setting DTE, DIN (serial break) to low and RTS to high.
Tried that and i can enter the bootloader (you see this monitoring the CTS signal, if off it is in bootloader mode)

HAH! The same binary bullshit!

Now i have two possibilities:
– the Bootloader speaks binary bullshit  (against the documentation which says it should respond with “BL >”) or
– there is some problem with the communication

 I see the bootloader only works at 115200bps – that gave me finally the trick.

The 5v Max232 with the connected voltage divider seems to get the high-low and low-high transition not correct at 115200 baud – 9600, 19200 etc no problem, but 115200 is too fast for a voltage divider – at least mine.
I found a ADM2032 in my inventory after long search and hooked that up to the Xbee.

Immediately it flashed the Xbee without ANY problems!
Damn, whole Saturday for such an easy problem gone :(

After i solved this issue i had to fight with the Xbee’s as they didn’t associate.

Final solution was that i flashed the ZIGBEE firmware which looks to me more robust and also is recommended by Digi and now everything looks like a charm. ;)))

Have fun, and update your Xbees to the latest ZIGBEE firmware as described here: ZNet 2.5 to ZB Migration Instructions

More on the Xbee’s to come… ;)


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: