Go Down

Topic: How to connect Zigbee modules to Xbee (Read 6769 times) previous topic - next topic

leftdal

Hello! Here is a quick question.

I have a xbee module on Arduino.

I will buy a couple of zigbee modules.

Scenario is as follows.

I will send commends to the zigbee modules from my computer via arduino.
Also, I will receive measured data from the zigbee modules at my computer.

Do I need to configure zigbee modules and xbee module?
Do I see the messages from zigbee modules at my computer via arduino?

Thanks


PaulS

Quote
I have a xbee module on Arduino.

One by itself does no good.

Quote
I will buy a couple of zigbee modules.

Generally, zigbee and xbee are interchangeable terms.

Quote
I will send commends to the zigbee modules from my computer via arduino.

What is the Arduino doing? You can just use a USB Explorer with XBee at the PC end, unless the Arduino is doing something useful.

Quote
Do I need to configure zigbee modules and xbee module?

Not according to digi. But, if you want them to work, you do.

Quote
Do I see the messages from zigbee modules at my computer via arduino?

Depends on configuration and code...

leftdal


Quote
I have a xbee module on Arduino.

One by itself does no good.

Quote
I will buy a couple of zigbee modules.

Generally, zigbee and xbee are interchangeable terms.

Quote
I will send commends to the zigbee modules from my computer via arduino.

What is the Arduino doing? You can just use a USB Explorer with XBee at the PC end, unless the Arduino is doing something useful.

Quote
Do I need to configure zigbee modules and xbee module?

Not according to digi. But, if you want them to work, you do.

Quote
Do I see the messages from zigbee modules at my computer via arduino?

Depends on configuration and code...


Thanks again

I want to clarify the design.

Zigbee temperature module -------(zigbee protocol)-------Xbee-(wired)-Arduino-(wired)-Ethernet--------(TCP/IP)-----computer.

Zigbee module (just commercial product) keeps sending data to Arduino or it sends data when it receives a commend.
(my question is that do I need to configure the zigbee module?, I set up arduino listen zigbee signal)

Computer sends "get Temp" to Arduino.
Then Arduino sends the stored data to the computer or sends commend to the zigbee module to receive data at that time..







PaulS

Quote
I want to clarify the design.

You could do that better by posting links to the devices in question.

jdesbonnet

This is indeed possible, but can be a little tricky to get working. I've been there myself and it wasn't easy. Get the XBee documentation and read it cover to cover. It helps if you understand ZigBee too... read the spec cover to cover (no, only joking! :) "ZigBee Wireless Networking" by Drew Gislason is a good book. Also consider getting "Building Wireless Sensor Networks" (O'Reilly) which is entirely based on the XBee modules.

Off the top of my head here are some of the challenges/pitfalls:

In order for your ZigBee network to work, you'll need a coordinator. Is your XBee+Arduino  device going to be the coordinator? If so make sure you load the Coordinator firmware onto the XBee using the Digi X-CTU software. You'll need to use the API mode version of the firmware eg "ZIGBEE COORDINATOR API".   If it's not the coordinator "ZIGBEE ROUTER API" is probably what you want.

I found the following to work when talking to HA (home automation) profile devices. You can configure with the Digi X-CTU software:

ZS=2   (ZigBee Stack Profile 2)
SC=7FFF  (This is the channel mask... see the documentation. 7FFF should give all available channels)
AO=1  (this will tell the XBee to forward ZigBee packets to the XBee UART ... ie to the Arduino)
AP=2  (this tells it to use escaping... you an also use AP=1 if you don't want to implement escaping when talking to the XBee via its UART .. see XBee doc)

Are your ZigBee devices configured to use encryption? If so you'll need to configure your XBee to use encryption. What has worked for me in the past is EE=1, EO=2, KY=5A6967426565416C6C69616E63653039 (that's a key defined in the HA profile -- it's actually string 'ZigBeeAlliance09' in hex with MSB first).

You'll then have to write software on your computer to formulate XBee API packets to send ZigBee queries to the devices and parse the replies. You should also be able to configure the devices to self report so that explicit queries are not needed. See XBee API packet types 0x11 and 0x91.

I hope this helps.

Joe.

Go Up