ZILOGIG SYSTEMS ZigBee User manual

USB ZigBee Adapter
User Manual
1.0, Dec 2011

USB ZigBee Adapter User Manual Rev. 1.0
This work is licensed under the Creative Commons Attribution-Share Alike 2.5 India License. To view a
copy of this license, visit http://creativecommons.org/licenses/by-sa/2.5/in/ or send a letter to Creative
Commons, 171 Second Street, Suite 300, San Francisco, California, 94105, USA.

USB ZigBee Adapter User Manual Rev. 1.0
Zilogic Systems Page iii
Table of Contents
1. Introduction ............................................................................................................................ 1
1. Features ........................................................................................................................ 1
2. Wireless Parameters ...................................................................................................... 1
2. Board Design ......................................................................................................................... 2
1. Overview ....................................................................................................................... 2
2. Locating Components ..................................................................................................... 2
3. Power Supply ................................................................................................................ 2
4. XBee Module ................................................................................................................. 3
5. USB Serial ..................................................................................................................... 3
6. Status LEDs .................................................................................................................. 3
7. Debug Key & LED ......................................................................................................... 3
3. Board Usage .......................................................................................................................... 4
1. AT Mode and API Mode ................................................................................................. 4
2. Updating the Firmware ................................................................................................... 4
3. Communicating in AT mode ............................................................................................ 6
4. Sending and Receiving Data in Transparent Mode ........................................................... 9
A. Legal Information ................................................................................................................. 11
1. Copying ....................................................................................................................... 11
2. Disclaimers .................................................................................................................. 11
B. Determining COM Port ......................................................................................................... 12

USB ZigBee Adapter User Manual Rev. 1.0
Zilogic Systems Page 1
Chapter 1. Introduction
ZigBee is a low power, wireless mesh network standard, largely used in the areas of home automation,
medical data collection and industrial control. The USB ZigBee Adapter connects a PC or any USB
capable host to a ZigBee network.
At the core of the USB ZigBee Adapter is the XBee module from Digi, which implements the ZigBee
stack. Once connected to the PC, the USB ZigBee Adapter is visible as a virtual COM port. The user
can interact with the ZigBee stack, by sending commands through the virtual COM port.
The USB ZigBee Adapter also doubles up as an XBee Module Programmer for firmware upgrades.
1. Features
• USB Powered
• Built in +3.3V regulator for XBee module
• XBee ZB and XBee-PRO ZB compatible
• LEDs for TX/RX and ZigBee state
• Debug LED and Key
• Local and remote loopback
2. Wireless Parameters
Parameter XBee ZB XBee-PRO
ZB
Data rate 250Kbps 250Kbps
Indoor range 40m 90m
Line of sight 120m 1500m
Tx. Power 1.25mW / 2mW 63mW
The international variant of XBee-Pro ZB are limited to 10mW Tx. Power

USB ZigBee Adapter User Manual Rev. 1.0
Zilogic Systems Page 2
Chapter 2. Board Design
1. Overview
The devices available on the board, is shown in the following block diagram. Each device is described
in details in the following sections.
Figure 2.1. Block Diagram
2. Locating Components
The location of the components on the board is indicated in the following diagram.
Figure 2.2. Front View
3. Power Supply
The USB ZigBee Adapter is powered from a PC USB port, and does not require an external power
supply.

USB ZigBee Adapter User Manual Rev. 1.0
Zilogic Systems Page 3
4. XBee Module
The XBee ZB Module or XBee-PRO ZB Module can be mounted in the USB ZigBee Adapter. The
module provides a UART interface through which the host PC can send and received data. The module
can also be configured through the serial interface.
5. USB Serial
The USB ZigBee Adapter has a FT232R USB to serial UART converter, for communication between
the host PC and the XBee module. The OS detects the USB Serial device as a Virtual COM port. Any
standard serial terminal application should be able to communicate with the XBee module, using the
Virtual COM port.
The RTS and CTS signals of the USB serial converter are connected to the XBee module, for optional
hardwareflowcontrol.TheDTRsignaloftheUSBserialconverterisalsoconnectedtotheXBeemodule,
for switching the module into firmware upgrade mode, during module power up.
6. Status LEDs
The status LEDs indicate the following information.
RXD LED Blink indicates data has been received by the module from the host.
TXD LED Blink indicates data has been transmitted by the module to the host.
ASC LED Continuos blinking indicates associated with a network, in case of a router or end
device. And PAN ID and radio channel has been selected in the case of coordinator.
SIG LED Brighter LED indicates a more stable link. In other words, shows the received signal
strength of the last received packet.
NAP LED On indicates device has woken up from sleep state.
7. Debug Key & LED
A Debug Key and Debug LED is provided for testing the local and remote IOs. The Debug Key is
connected to the pin DIO11 of the XBee module. The Debug LED is connected to the pin DIO4 of the
XBee module.

USB ZigBee Adapter User Manual Rev. 1.0
Zilogic Systems Page 4
Chapter 3. Board Usage
1. AT Mode and API Mode
The XBee modules can communicate using two protocols with the host.
1. AT Mode
2. API Mode
In AT mode, the module provides an AT command interface, similar to AT modem commands, for
configuration. The AT mode also supports transparent mode of operation in which serial data sent to
the module, is transmitted over the air to a remote ZigBee node.
In API mode, the module uses a binary packet interface for communicating with the host. The available
packets and their formats is described in the module user manual.
2. Updating the Firmware
Separate firmware is available to make the XBee module operate as a coordinator, router or end device.
Moreover separate firmware is available for AT mode and API mode.
The firmware is identified using a version no. Firmware version nos. have the format ABCD, where A, B,
Cand Dare hexadecimal digits 0x0 - 0xF. Each digit has the following meaning.
Digit Value Meaning
A1 indicates 802.15.4 firmware
2 indicates ZigBee firmware
B0 indicates ZigBee Coordinator, AT Command Mode
1 indicates ZigBee Coordinator, API Mode
2 indicates ZigBee Router, AT Command Mode
3 indicates ZigBee Router, API Mode
4 indicates ZigBee End Device, AT Command Mode
5 indicates ZigBee End Device, API Mode
Ceven indicates stable releases
odd indicates development releases
D- not clear from Digi’s documentation
Thefirmware can beobtained from, Digi’sFTP site ftp://ftp1.digi.com/support/firmware/update/xbee_zb/
2.1. Updating the firmware in Linux
The firmware can be updated from Linux using xbfwup on Linux. The steps to update the firmware
is given below.
1. Identify the firmware version to be downloaded.
2. Download the firmware from Digi’s FTP site.
3. Unzip the downloaded .ZIP file.
4. Use xbfwup to update the firmware.
For example to update the firmware of the module to Coordinator in AT mode.
1. The firmware version to be downloaded should look like 20xx.

USB ZigBee Adapter User Manual Rev. 1.0
Zilogic Systems Page 5
2. Download the file ftp://ftp1.digi.com/support/firmware/update/xbee_zb/XB24-ZB_2070.zip
$ wget ftp://ftp1.digi.com/support/firmware/update/xbee_zb/XB24-ZB_2070.zip
3. Unzip the downloaded zip archive.
$ unzip XB24-ZB_2070.zip
4. Updatethefirmwareusingxbfwup.Specifythecurrentmodeusingthe -A <mode> option. mode
is 1 for API mode, and 0 for AT mode. Specify the serial device file using -d <device> option.
$ cd ebl_files
$ xbfwup -A 1 -d /dev/ttyUSB0 XB24-ZB_2070.ebl
2.2. Updating the firmware in Windows
The firmware can be updated from Windows using the X-CTU application from Digi. The steps to update
the firmware is given below.
Figure 3.1. PC Settings
In the PC Settings tab, configure the following parameters.
No. Parameter Value
1 Select COM Port USB Serial Port

USB ZigBee Adapter User Manual Rev. 1.0
Zilogic Systems Page 6
No. Parameter Value
2 Baudrate 9600
3 Data Bits 8
4 Parity NONE
5 Stop Bits 1
6 Flow Control NONE
7 Enable API True / False
The Enable API parameter depends on the current firmware within the device. If the current firmware is
API firmware set this to True. If the current firmware is AT firmware set this to False.
Figure 3.2. Modem Configuration
In the Modem Configuration tab:
1. Select the firmware type in the Function Set combo box.
2. Select the required firmware version in the Version combo box.
3. Click the Write button to update the firmware.
3. Communicating in AT mode
The module is first updated with an AT mode firmware. AT commands can then be sent to the device
using a terminal software, like putty, hyperterminal or minicom.

USB ZigBee Adapter User Manual Rev. 1.0
Zilogic Systems Page 7
When the device is connected to the host system, it is detected a Virtual COM device in Windows, and
a USB serial device in Linux. The procedure to determine the COM port name in Windows, is specified
in Appendix B, Determining COM Port.
The terminal software configuration is shown below with putty as an example. Open up the putty, and
configure the following parameters in the Serial panel.
No. Parameter Value
1 Baudrate 9600
2 Data Bits 8
3 Stop Bits 1
4 Parity None
5 Flow Control None
Figure 3.3. Serial Configuration Screenshot
Configure the following parameters in the Terminal panel.
No. Parameter Value
1 Implicit LF in every CR True
2 Local Echo Force On

USB ZigBee Adapter User Manual Rev. 1.0
Zilogic Systems Page 8
Figure 3.4. Terminal Configuration Screenshot
Figure 3.5. Session Screenshot
In the Session panel,
1. Specify the serial port device name.
2. Click the Open button.
By default the module will be in transparent mode of operation, to enter AT command mode type +++.
A one second gap, called the guard time, should be provided before and after the +++ sequence. The

USB ZigBee Adapter User Manual Rev. 1.0
Zilogic Systems Page 9
module on entry into AT command mode, responds with OK\r. After which AT commands can be sent
to the device.
For example, to get the firmware version (VR), the following sequence of commands can be used.
U: +++
M: OK
U: ATVR
M: 2070
The character +used for entering the AT command mode, is called the Command Character. The
guard time and command character is configurable using AT commands. The default is 1 second and
+, respectively.
The module can be put back to transparent mode of operation manually using the CN AT command.
The module also switches back to transparent mode of operation after a timeout, 10 seconds by default.
The command mode timeout is also configurable using the CT AT command.
4. Sending and Receiving Data in Transparent Mode
Transparent mode of operation is demonstrated using a two node network, consisting of a coordinator
and router. The following sequence shows how to send a message from the coordinator to the router.
1. Update the coordinator AT firmware in module A, and router AT firmware in module B.
2. Connect the ZigBee Adapters to the host PC. Ensure the ASC LED is blinking in both the
modules.
Figure 3.6. Two Node Network
3. Note down the 64-bit MAC address specified in the module B. The 64-bit MAC of the module
can be obtained from the label on the back of the module. The 64-bit MAC can also be obtained
using the SH and SL AT commands.
Figure 3.7. Obtaining MAC address

USB ZigBee Adapter User Manual Rev. 1.0
Zilogic Systems Page 10
4. In module A, set the destination addressing using the DH and DL AT commands. DH is used to
specify the higher order 32 bits and DL is used to specify the lower order 32 bits.
Figure 3.8. Setting the Destination
5. Switch both the module into transparent mode of operation, using the CN AT command. Type a
message to be sent to module B, the message should appear on module B’s serial output.
Figure 3.9. Sending and Receiving Message

USB ZigBee Adapter User Manual Rev. 1.0
Zilogic Systems Page 11
Appendix A. Legal Information
1. Copying
This work is licensed under the Creative Commons Attribution-Share Alike 2.5 India License. To view a
copy of this license, visit http://creativecommons.org/licenses/by-sa/2.5/in/ or send a letter to Creative
Commons, 171 Second Street, Suite 300, San Francisco, California, 94105, USA.
2. Disclaimers
NO WARRANTY. ZILOGIC SYSTEMS' DEVELOPMENT KITS (AND TECHNICAL SUPPORT,
IF ANY) ARE PROVIDED "AS IS" AND WITHOUT ANY WARRANTY OF ANY KIND, EXPRESS
OR IMPLIED. TO THE MAXIMUM EXTENT PERMITTED UNDER APPLICABLE LAWS, ZILOGIC
SYSTEMS EXPRESSLY DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING
BUT NOT LIMITED TO IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE, AND NONINFRINGEMENT. ZILOGIC SYSTEMS DOES NOT WARRANT
THAT THE FUNCTIONS CONTAINED IN ZILOGIC SYSTEMS' DEVELOPMENT KITS WILL
MEET YOUR REQUIREMENTS, OR THAT THE OPERATION WILL BE UNINTERRUPTED OR
ERROR-FREE, OR THAT DEFECTS IN ZILOGIC SYSTEMS' DEVELOPMENT KITS WILL BE
CORRECTED. FURTHERMORE, ZILOGIC SYSTEMS DOES NOT WARRANT OR MAKE ANY
REPRESENTATIONS REGARDING THE USE OR THE RESULTS OF THE USE OF THE
ZILOGIC SYSTEMS' DEVELOPMENT KITS IN TERMS OF THEIR CORRECTNESS, ACCURACY,
RELIABILITY, OR OTHERWISE. SOME JURISDICTIONS DO NOT ALLOW THE EXCLUSION OF
IMPLIED WARRANTIES, SO THE ABOVE EXCLUSION MAY NOT APPLY OR MAY BE LIMITED.
Limitation of Liability. Zilogic Systems' development kits are not designed, authorized or warranted
to be suitable for use in medical, military, aircraft, space or life support equipment, not in applications
where failure or malfunction of a Zilogic Systems product can resonably be expected to result in
personal injury, death or severe property or environmental damage. Zilogic Systems accepts no liability
for inclusion and/or use of Zilogic Systems' development kits in such equipment or applications and
therefore such inclusion and/or use is at the customer’s own risk.

USB ZigBee Adapter User Manual Rev. 1.0
Zilogic Systems Page 12
Appendix B. Determining COM Port
The USB Serial Adapter uses a USB serial interface to communicate with the PC. When the USB port
of the board is connected to the PC, MS Windows assigns a COM port to the board. To determine the
assigned COM port, follow the instructions given below.
Step 1. Right click on the My Computer icon, to get the drop down menu. Select the Properties
from the menu.
Step 2. In the System Properties window that appears, select the Hardware tab. In the tab, click
on the Device Manager button.
Step 3. In the Device Manager window, a tree of devices present in the system is shown. Expand
the Ports node in the device tree. Look for an entry called USB Serial Port. The assigned COM
port is specified in parenthesis, as shown in the figure below. If this does not appear make sure you
have installed the driver correctly as mentioned in installation manual.
Table of contents