XK-Z11-M Digi International, XK-Z11-M Datasheet

no-image

XK-Z11-M

Manufacturer Part Number
XK-Z11-M
Description
ZIGBEE MODULE DEVELOPMENT KIT
Manufacturer
Digi International
Series
XBee™r
Type
Transceiver, 802.15.4/ZigBeer
Datasheets

Specifications of XK-Z11-M

Frequency
2.4GHz
For Use With/related Products
XBee Modules
Lead Free Status / RoHS Status
Lead free / RoHS Compliant
Other names
602-1184
XBee®/XBee-PRO® ZB RF Modules
ZigBee RF Modules by Digi International
Models: XBEE2, XBEEPRO2, PRO S2B
Hardware: S2 and S2B
Firmware Versions:
- 20xx - Coordinator - AT/Transparent Operation
- 21xx - Coordinator - API Operation
- 22xx - Router - AT/Transparent Operation
- 23xx - Router - API Operation
- 28xx - End Device - AT/Transparent Operation
- 29xx - End Device - API Operation
Digi International Inc.
11001 Bren Road East
Minnetonka, MN 55343
877 912-3444 or 952 912-3444
http://www.digi.com
90000976_F
5/17/2010

Related parts for XK-Z11-M

XK-Z11-M Summary of contents

Page 1

... XBee®/XBee-PRO® Modules ZigBee RF Modules by Digi International Models: XBEE2, XBEEPRO2, PRO S2B Hardware: S2 and S2B Firmware Versions: - 20xx - Coordinator - AT/Transparent Operation - 21xx - Coordinator - API Operation - 22xx - Router - AT/Transparent Operation - 23xx - Router - API Operation - 28xx - End Device - AT/Transparent Operation - 29xx - End Device - API Operation Digi International Inc ...

Page 2

... XBee®/XBee‐PRO® ZB RF Modules © 2010 Digi International, Inc. All rights reserved No part of the contents of this manual may be transmitted or reproduced in any  form or by any means without the written permission of Digi International, Inc. ...

Page 3

XBee®/XBee‐PRO® ZB RF Modules    Contents 1 - Overview 6 What's New in 2x7x 6 Firmware 6 Manual 7 Key Features 8 Worldwide Acceptance 8 Specifications 9 Hardware Specs for Programmable Variant 10 Mechanical Drawings 10 SIF Header Interface 11 Mounting Considerations 12 Pin ...

Page 4

XBee®/XBee‐PRO® ZB RF Modules    Contents Managing Multiple ZigBee Networks 50 PAN ID Filtering 50 Preconfigured Security Keys 50 Permit Joining 51 Application Messaging Transmission, Addressing, and Routing 52 Addressing 52 64-bit Device Addresses 52 16-bit Device Addresses 52 Application Layer ...

Page 5

XBee®/XBee‐PRO® ZB RF Modules    Contents Transmission Timeout 91 Putting it all Together 91 Short Sleep Periods 91 Extended Sleep Periods 92 Sleep Examples XBee Analog and Digital IO Lines 94 IO Configuration 94 IO Sampling 94 Queried Sampling 96 Periodic ...

Page 6

This manual describes the operation of the XBee/XBee-PRO ZB RF module, which consists of ZigBee firmware loaded onto XBee S2 and S2B hardware, models: XBEE2, XBEEPRO2 and PRO S2B. The XBee/XBee-PRO ZB RF Modules are designed to operate within ...

Page 7

XBee®/XBee‐PRO® ZB RF Modules  Manual The XBee/XBee-PRO/S2B ZB 2x7x manual includes the following corrections over the 2x6x manual: •Descriptions and specification for the PRO S2B. •SIF Header Interface, pin 8 relabeled as pin 10. •Pin mappings for pins 22 and 24 updated. •New ...

Page 8

XBee®/XBee‐PRO® ZB RF Modules  Key Features High Performance, Low Cost XBee • Indoor/Urban 133’ (40 m) • Outdoor line-of-sight 400’ (120 m) • Transmit Power dBm) • Receiver Sensitivity: -96 dBm XBee-PRO (S2) • Indoor/Urban: up ...

Page 9

XBee®/XBee‐PRO® ZB RF Modules  Specifications Specifications of the XBee®/XBee‐PRO® ZB RF Module  Specification XBee Performance Indoor/Urban Range up to 133 ft. (40 m) Outdoor RF line-of-sight up to 400 ft. (120 m) Range 2mW (+3dBm), boost mode enabled Transmit Power Output 1.25mW (+1dBm), boost mode disabled RF Data Rate ...

Page 10

XBee®/XBee‐PRO® ZB RF Modules  Specifications of the XBee®/XBee‐PRO® ZB RF Module  Specification XBee Australia C-Tick Japan R201WW07215215 RoHS Compliant Hardware Specs for Programmable Variant The following specifications need to be added to the current measurement of the previous table if the module has the programmable secondary processor. For example, ...

Page 11

XBee®/XBee‐PRO® ZB RF Modules  Mechanical Drawings for the RPSMA Variant SIF Header Interface The XBee/XBee-PRO ZB modules include a SIF programming header that can be used with Ember's programming tools to upload custom firmware images onto the XBee module. The SIF header orientation and pinout are shown below. ...

Page 12

XBee®/XBee‐PRO® ZB RF Modules  Mounting Considerations The XBee modules were designed to mount into a receptacle (socket) and therefore does not require any soldering when mounting board. The XBee-PRO Development Kits contain RS-232 and USB interface boards which use two ...

Page 13

XBee®/XBee‐PRO® ZB RF Modules  Pin Signals Pin Assignments for the XBee‐PRO Modules Pin # • Signal Direction is specified with respect to the module • See Design Notes ...

Page 14

XBee®/XBee‐PRO® ZB RF Modules  EM250 Pin Mappings The following table shows how the EM250 pins are used on the XBee. EM250 Pin Number XBee Pin Number 13 (Reset (GPIO 11) 16* 20 (GPIO 12) 12* 21 (GPIO (GPIO ...

Page 15

XBee®/XBee‐PRO® ZB RF Modules  Recommended Pin Connections The only required pin connections are VCC, GND, DOUT and DIN. To support serial firmware updates, VCC, GND, DOUT, DIN, RTS, and DTR should be connected. All unused pins should be left disconnected. All inputs on ...

Page 16

XBee®/XBee‐PRO® ZB RF Modules  © 2010 Digi International, Inc.      16 ...

Page 17

XBee®/XBee‐PRO® ZB RF Modules  Electrical Characteristics DC Characteristics of the XBee/XBee‐PRO  Symbol Parameter V Input Low Voltage IL V Input High Voltage IH V Output Low Voltage OL V Output High Voltage OH I Input Leakage Current IIN I Output source current (standard) OHS Output source current ...

Page 18

XBee®/XBee‐PRO® ZB RF Modules  © 2010 Digi International, Inc.      18 ...

Page 19

XBee®/XBee‐PRO® ZB RF Modules  XBEE Programmable Bootloader Overview The Xbee Programmable module is equipped with a Freescale MC9S08QExx application processor. This application processor comes with a supplied bootloader. The following section describes how to interface the customer's application code running on this processor ...

Page 20

XBee®/XBee‐PRO® ZB RF Modules  © 2010 Digi International, Inc.      20 ...

Page 21

XBee®/XBee‐PRO® ZB RF Modules  © 2010 Digi International, Inc.      21 ...

Page 22

XBee®/XBee‐PRO® ZB RF Modules  Operation Upon reset of any kind, the execution control begins with the bootloader. If the reset cause is Power-On reset (POR), Pin reset (PIN), or Low Voltage Detect(LVD) reset the bootloader will not jump to the application code if ...

Page 23

XBee®/XBee‐PRO® ZB RF Modules  Application Interrupt Vector table and Linker Command File Since the bootloader flash region is read-only, the interrupt vector table is redirected to the region 0xF1C0 to 0xF1FD so that application developers can use hardware interrupts. Note that in order ...

Page 24

XBee®/XBee‐PRO® ZB RF Modules  vDummyIsr, /* Int.no. 28 Vlvd (at F1F8) vDummyIsr, /* Int.no. 29 Virq (at F1FA) vDummyIsr, /* Int.no. 30 Vswi (at F1FC) _Startup }; void vDummyIsr(void){ for(;;){ if(iWriteToSci1("STUCK IN UNASSIGNED ISR\n\r>")); } } The interrupt routines themselves can be defined ...

Page 25

XBee®/XBee‐PRO® ZB RF Modules  Firmware Updates Wired Updates A user can update their application using the bootloader in a wired configuration with the following steps… a. Plug XBee programmable module into a suitable serial port on a PC. b. Open a hyperterminal (or ...

Page 26

XBee®/XBee‐PRO® ZB RF Modules  Bootloader updates The supplied bootloader requires files in a "flat binary" format which differs from the default ABS file produced. The Codewarrior tool also produces a S19 output file. In order to successfully flash new applications, the S19 file ...

Page 27

Serial Communications The XBee RF Modules interface to a host device through a logic-level asynchronous serial port. Through its serial port, the module can communicate with any logic and voltage compatible UART; or through a level translator to any ...

Page 28

XBee®/XBee‐PRO® ZB RF Modules  TInternal Data Flow Diagram DIN CTS DOUT RTS Serial Receive Buffer When serial data enters the RF module through the DIN Pin (pin 3), the data is stored in the serial receive buffer until it can be processed. Under certain conditions, the ...

Page 29

XBee®/XBee‐PRO® ZB RF Modules  periods of time to avoid filling the serial transmit buffer data packet is received, and the serial transmit buffer does not have enough space for all of the data bytes, the entire RF data packet will ...

Page 30

XBee®/XBee‐PRO® ZB RF Modules  A Comparison of Transparent and API Operation The following table compares the advantages of transparent and API modes of operation: Simple Interface Easy to support Easy to manage data transmissions to multiple destinations Received data frames indicate the sender's ...

Page 31

XBee®/XBee‐PRO® ZB RF Modules  Modes of Operation Idle Mode When not receiving or transmitting data, the RF module is in Idle Mode. The module shifts into the other modes of operation under the following conditions: •Transmit Mode (Serial data in the serial receive ...

Page 32

XBee®/XBee‐PRO® ZB RF Modules  When data is transmitted from one node to another, a network-level acknowledgement is transmitted back across the established route to the source node. This acknowledgement packet indicates to the source node that the data packet was received by the ...

Page 33

XBee®/XBee‐PRO® ZB RF Modules  When a command is sent to the module, the module will parse and execute the command. Upon successful execution of a command, the module returns an “OK” message. If execution of a command results in an error, the module ...

Page 34

Introduction to ZigBee ZigBee is an open global standard built on the IEEE 802.15.4 MAC/PHY. ZigBee defines a network layer above the 802.15.4 layers to support advanced mesh routing capabilities. The ZigBee specification is developed by a growing consortium ...

Page 35

XBee®/XBee‐PRO® ZB RF Modules  A router has the following characteristics: it •Must join a ZigBee PAN before it can transmit, receive, or route data •After joining, can allow routers and end devices to join the network •After joining, can assist in routing data ...

Page 36

XBee®/XBee‐PRO® ZB RF Modules  the same 16-bit PAN ID. If such a conflict is detected, the ZigBee stack can perform PAN ID conflict resolution to change the 16-bit PAN ID of the network in order to resolve the conflict. See the ZigBee specification ...

Page 37

XBee®/XBee‐PRO® ZB RF Modules  Each cluster has an associated 2-byte cluster identifier (cluster ID). The cluster ID is included in all application transmissions. Clusters often have associated request and response messages. For example, a smart energy gateway (service portal) might send a load ...

Page 38

XBee®/XBee‐PRO® ZB RF Modules  (broadcast) transmission on each potential channel. All nearby coordinators and routers (that have already joined a ZigBee network) will respond to the beacon request by sending a beacon back to the coordinator. The beacon contains information about the PAN ...

Page 39

XBee®/XBee‐PRO® ZB RF Modules  These behaviors are configurable using the following commands: Command any of the command values in the network formation commands table changes, the coordinator will leave its current network and start a new network, possibly on ...

Page 40

XBee®/XBee‐PRO® ZB RF Modules  Replacing a Coordinator (Security Disabled Only) In rare occasions, it may become necessary to replace an existing coordinator in a network with a new physical device. If security is not enabled in the network, a replacement XBee coordinator can ...

Page 41

XBee®/XBee‐PRO® ZB RF Modules  6. Reading the AI command (association status) will return a value of 0, indicating a successful startup. 7. Reading the MY command (16-bit address) will return a value of 0, the ZigBee-defined 16-bit address of the coordinator. After startup, ...

Page 42

XBee®/XBee‐PRO® ZB RF Modules  Persistent Data Once a router has joined a network, it retains the following information through power cycle or reset events: •PAN ID •Operating channel •Security policy and frame counter values •Child table (end device children that are joined to ...

Page 43

XBee®/XBee‐PRO® ZB RF Modules  The following commands control the router joining process. Command Once the router joins a network, the network configuration settings and child table data persist through power cycles as mentioned in the "Persistent Data" ...

Page 44

XBee®/XBee‐PRO® ZB RF Modules  These behaviors are configurable using the following commands: Command Permit Joining The permit joining attribute on the router is configurable with the NJ command. NJ can be configured to always allow joining allow joining ...

Page 45

XBee®/XBee‐PRO® ZB RF Modules  Network Watchdog The NW command (network watchdog timeout) can be used for a powered router to periodically check for the presence of a coordinator to verify network connectivity. The NW command specifies a timeout in minutes where the router ...

Page 46

XBee®/XBee‐PRO® ZB RF Modules  Leaving a Network There are a couple of mechanisms that will cause the router to leave its current PAN and attempt to discover and join a new network based on its network joining parameter values. These include the following: ...

Page 47

XBee®/XBee‐PRO® ZB RF Modules  Note that changes to ID, SC, ZS, and security command values only take effect when changes are applied ( commands). Resetting the Router When the router is reset or power cycled, it checks its PAN ID, operating ...

Page 48

XBee®/XBee‐PRO® ZB RF Modules  requirements, the end device will attempt scans per minute for the first 5 minutes, and 3 scans per minute thereafter. Note: The XBee ZB end device will not enter sleep until it has completed scanning all ...

Page 49

XBee®/XBee‐PRO® ZB RF Modules  If the orphaned end device receives a coordinator realignment command considered joined to the network. Otherwise, it will attempt to discover and join a valid network. XBee: ZB End Device Joining When an end device is powered ...

Page 50

XBee®/XBee‐PRO® ZB RF Modules  Command D5 LT SM, SP, ST, SN, SO Parent Connectivity The XBee ZB end device sends regular poll transmissions to its parent when it is awake. These poll transmissions query the parent for any new received data packets. The ...

Page 51

XBee®/XBee‐PRO® ZB RF Modules  changed from the default, apply changes (make SC and ID changes take effect) by issuing the command. 4. The Associate LED will start blinking once the end device has joined ...

Page 52

XBee®/XBee‐PRO® ZB RF Modules  Permit Joining The Permit Joining parameter can be disabled in a network to prevent unwanted devices from joining. When a new device must be added to a network, permit-joining can be enabled for a short time on the desired ...

Page 53

Addressing All ZigBee devices have two different addresses, a 64-bit and a 16-bit address. The characteristics of each are described below. 64-bit Device Addresses The 64-bit address is a unique device address assigned during manufacturing. This address is unique ...

Page 54

XBee®/XBee‐PRO® ZB RF Modules  Broadcast Transmissions Broadcast transmissions within the ZigBee protocol are intended to be propagated throughout the entire network such that all nodes receive the transmission. To accomplish this, the coordinator and all routers that receive a broadcast transmission will retransmit ...

Page 55

XBee®/XBee‐PRO® ZB RF Modules  16-bit address is obtained after joining a network. The 16-bit address can also change under certain conditions. When sending a unicast transmission, the ZigBee network layer uses the 16-bit address of the destination and each hop to route the ...

Page 56

XBee®/XBee‐PRO® ZB RF Modules  The application should always update the 16-bit address in the address table when one of these frames is received to ensure the table has the most recently known 16-bit address transmission failure occurs, the application should set ...

Page 57

XBee®/XBee‐PRO® ZB RF Modules  Alternatively, if the coordinator's 64-bit address is known, DH and DL can be set to the coordinator's 64-bit address. Suppose the coordinator's address is 0x0013A200404A2244. 1. Enter command mode ('+++') 2. After receiving an OK\r, issue the following commands: ...

Page 58

XBee®/XBee‐PRO® ZB RF Modules  Routing Approach Description Ad hoc On-demand Distance Vector (AODV) Mesh Routing Many-to-One Routing Source Routing Note – End devices do not make use of these routing protocols. Rather, an end device sends a unicast transmission to its parent and ...

Page 59

XBee®/XBee‐PRO® ZB RF Modules  AODV Mesh Routing ZigBee employs mesh routing to establish a route between the source device and the destination. Mesh routing allows data packets to traverse multiple nodes (hops network to route data from a source to a ...

Page 60

XBee®/XBee‐PRO® ZB RF Modules  Sample Route Request (Broadcast) Transmission Where R3 is Trying to Discover a Route to R6  When the destination node receives a route request, it compares the ‘path cost’ field against previously received route request commands. If the path cost stored in the route request is better than any previously received, the destination node ...

Page 61

XBee®/XBee‐PRO® ZB RF Modules  Refer to the ZigBee specification for more details. Many-to-One Routing In networks where many devices must send data to a central collector or gateway device, AODV mesh routing requires significant overhead. If every device in the network had to ...

Page 62

XBee®/XBee‐PRO® ZB RF Modules  © 2010 Digi International, Inc.      61 ...

Page 63

XBee®/XBee‐PRO® ZB RF Modules  The data collector sends a many-to-one route request broadcast to create reverse routes on all devices. Acquiring Source Routes Acquiring source routes requires the remote devices to send a unicast to a data collector (device that sends many-to-one route ...

Page 64

XBee®/XBee‐PRO® ZB RF Modules  Create Source Route API frame. The XBee can buffer one source route that includes hops (excluding source and destination). For example, suppose a network exists with a coordinator and 5 routers (R1, R2, R3, R4, R5) ...

Page 65

XBee®/XBee‐PRO® ZB RF Modules  provide it with a new source route. This requires that remote devices periodically send data transmissions into the data collector. See the earlier "Acquiring Source Routes" section for details. Retries and Acknowledgments ZigBee includes acknowledgment packets at both the ...

Page 66

XBee®/XBee‐PRO® ZB RF Modules  1 hop, ER hops, RR, SD 10kbps 4 hops, RR, SE 5kbps RR = router to router router to end device (non-sleeping end device (non-sleeping) to router security disabled ...

Page 67

XBee®/XBee‐PRO® ZB RF Modules  The first byte of payload in the API frame is an application sequence number (transaction sequence number) that can be set to any single byte value. This same value will be used in the first byte of the ZDO ...

Page 68

XBee®/XBee‐PRO® ZB RF Modules  0x11 - Explicit transmit request 0x01 - frame ID (set to a non-zero value to enable the transmit status message, or set disable) 0x00000000 0000FFFF - 64-bit address for a broadcast transmission 0xFFFE - Set to ...

Page 69

XBee®/XBee‐PRO® ZB RF Modules  (1600), or 4800 ms, or 4.8 seconds. Extended Timeout The worst-case transmission timeout when sending data to an end device is somewhat larger than when transmitting to a router or coordinator. As described later in chapter 6, ...

Page 70

XBee®/XBee‐PRO® ZB RF Modules  Example 2 - Send a broadcast API data transmission that all devices can receive (including sleeping end devices), with payload "TxData". API Frame: 7E 0014 10 01 00000000 0000FFFF FFFE Field ...

Page 71

ZigBee supports various levels of security that can be configured depending on the needs of the application. Security provisions include: •128-bit AES encryption •Two security keys that can be preconfigured or obtained during joining •Support for a trust center ...

Page 72

XBee®/XBee‐PRO® ZB RF Modules  Frame Counter The network header of encrypted packets includes a 32-bit frame counter. Each device in the network maintains a 32-bit frame counter that is incremented for every transmission. In addition, devices track the last known 32- bit frame ...

Page 73

XBee®/XBee‐PRO® ZB RF Modules  Message integrity Code If APS security is enabled, the APS header and data payload are authenticated with 128-bit AES. A hash is performed on these fields and appended as a 4-byte message integrity code (MIC) to the end of ...

Page 74

XBee®/XBee‐PRO® ZB RF Modules  Trust Center ZigBee defines a trust center device that is responsible for authenticating devices that join the network. The trust center also manages link key distribution in the network. Forming and Joining a Secure Network The coordinator is responsible ...

Page 75

XBee®/XBee‐PRO® ZB RF Modules  Enabling Security To enable security on a device, the EE command must be set the EE command value is changed and changes are applied (e.g. AC command), the XBee module will leave the network (PAN ID ...

Page 76

XBee®/XBee‐PRO® ZB RF Modules  Updating the Network Key with a Trust Center If the trust center has started a network and the NK value is changed, the coordinator will update the network key on all devices in the network. (Changes to NK will ...

Page 77

XBee®/XBee‐PRO® ZB RF Modules  (save networking parameters to preserve them through power cycle) 2. Configure one or more routers or end devices with the following settings: a. ID=2235 b. EE (save networking parameters to preserve them through ...

Page 78

Network commissioning is the process whereby devices in a mesh network are discovered and configured for operation. The XBee modules include several features to support device discovery and configuration. In addition to configuring devices, a strategy must be developed ...

Page 79

XBee®/XBee‐PRO® ZB RF Modules  API Firmware Send an Explicit Addressing ZigBee Command API frame (0x11) using 0x12 as the cluster ID and 0xE8 as the source and destination endpoint. Data packets received by the remote will be echoed back to the sender. RSSI ...

Page 80

XBee®/XBee‐PRO® ZB RF Modules  A pushbutton and an LED can be connected to module pins 20 and 15 respectively to support the commissioning pushbutton and associate LED functionalities. Commissioning Pushbutton The commissioning pushbutton definitions provide a variety of simple functions to aid in ...

Page 81

XBee®/XBee‐PRO® ZB RF Modules  The node identification frame is similar to the node discovery response frame – it contains the device’s address, node identifier string (NI command), and other relevant data. All API devices that receive the node identification frame send it out ...

Page 82

XBee®/XBee‐PRO® ZB RF Modules   Broadcast Node Identification Transmission  Associate Pin ( AD0/DIO0 Pin (Remote Device) © 2010 Digi International, Inc. A single button press on a remote device causes a broadcast node identification transmission to be sent. All devices that receive this transmission blink their associate pin rapidly ...

Page 83

ZigBee end devices are intended to be battery-powered devices capable of sleeping for extended periods of time. Since end devices may not be awake to receive RF data at a given time, routers and coordinators are equipped with additional ...

Page 84

XBee®/XBee‐PRO® ZB RF Modules  The parent can buffer one broadcast transmission for all of its end device children. When a broadcast transmission is received and buffered, the parent sets a flag in its child table when each child polls and retrieves the packet. ...

Page 85

XBee®/XBee‐PRO® ZB RF Modules  non-parent device does not know the destination is an end device, it will use the standard unicast timeout for the transmission. However, provisions exist in the Ember ZigBee stack for the parent to inform the message sender ...

Page 86

XBee®/XBee‐PRO® ZB RF Modules  In the figure above, t1, t2, and t3 represent the following events: •T1 - Time when Sleep_RQ is asserted (high) •T2 - Time when the XBee enters sleep (CTS state change only if hardware flow control is enabled) •T3 ...

Page 87

XBee®/XBee‐PRO® ZB RF Modules  Demonstration of Pin Sleep Parent and remote devices must be configured to buffer data correctly and to utilize adequate transmission timeouts. See the XBee Router / Coordinator Configuration section in this chapter for details. Cyclic Sleep Cyclic sleep allows the module to ...

Page 88

XBee®/XBee‐PRO® ZB RF Modules  In the figure above, t1, t2, and t3 represent the following events: •T1 - Time when the module wakes from cyclic sleep •T2 - Time when the module returns to sleep •T3 - Later time when the module wakes ...

Page 89

XBee®/XBee‐PRO® ZB RF Modules  DIN On/Sleep A cyclic sleep end device enters sleep mode when no serial or RF data is received for ST time . Legend On/Sleep Transmitting Poll Request Sleep Period The sleep period is configured based on the SP, SN, ...

Page 90

XBee®/XBee‐PRO® ZB RF Modules  On/Sleep ( Δ Transmitting poll request to parent Δ Setting SN > 1 allows the XBee to silently poll for data without asserting On /Sleep data is received Legend ...

Page 91

XBee®/XBee‐PRO® ZB RF Modules  The XBee ZB 2x6x firmware includes an adaptive polling enhancement where end device receives RF data from its parent, it sends another poll after a very short delay to check for more data. The end device continues ...

Page 92

XBee®/XBee‐PRO® ZB RF Modules  The value of these timeouts depends on the sleep time used by the end devices. Each of these timeouts are discussed below. RF Packet Buffering Timeout When a router or coordinator receives an RF data packet intended for one ...

Page 93

XBee®/XBee‐PRO® ZB RF Modules  Extended Sleep Periods Pin and cyclic sleep devices that might sleep longer than 30 seconds cannot receive data transmissions reliably unless certain design approaches are taken. Specifically, the end devices should use IO sampling or another mechanism to transmit ...

Page 94

XBee®/XBee‐PRO® ZB RF Modules  SP and SN must be set such that minutes. Since SP is measured in 10ms units, the following settings can be used to obtain 4 minute sleep (cyclic sleep ...

Page 95

XBee ZB firmware supports a number of analog and digital IO pins that are configured through software commands. Analog and digital IO lines can be set or queried. The following table lists the configurable IO pins and the corresponding ...

Page 96

XBee®/XBee‐PRO® ZB RF Modules  •Queried Sampling •Periodic Sampling •Change Detection Sampling. IO sample data is formatted as shown in the table below Bytes 1 Sample Sets 2 Digital Channel Mask 1 Analog Channel Mask Variable Sampled Data Set The sampled data set will ...

Page 97

XBee®/XBee‐PRO® ZB RF Modules  The reading in the sample frame represents voltage inputs of 1143.75 and 342.1875mV for AD0 and AD1 respectively. Queried Sampling The IS command can be sent to a device locally remote device using the API remote ...

Page 98

XBee®/XBee‐PRO® ZB RF Modules  RSSI (in dBm) is converted to PWM counts using the following equation: PWM counts = (41 * RSSI_Unsigned) - 5928 IO Examples Example 1: Configure the following IO settings on the XBee. Configure AD1/DIO1 as a digital input with ...

Page 99

As an alternative to Transparent Operation, API (Application Programming Interface) Operations are available. API operation requires that communication with the module be done through a structured interface (data is communicated in frames in a defined order). The API specifies ...

Page 100

XBee®/XBee‐PRO® ZB RF Modules  Data bytes that need to be escaped: •0x7E – Frame Delimiter •0x7D – Escape •0x11 – XON •0x13 – XOFF Example - Raw UART Data Frame (before escaping interfering bytes):  0x7E 0x00 0x02 0x23 0x11 0xCB 0x11 needs ...

Page 101

XBee®/XBee‐PRO® ZB RF Modules  Checksum To test data integrity, a checksum is calculated and verified on non-escaped data. To calculate: Not including frame delimiters and length, add all bytes keeping only the lowest 8 bits of the result and subtract the result from ...

Page 102

XBee®/XBee‐PRO® ZB RF Modules  API UART Exchanges AT Commands The following image shows the API frame exchange that takes place at the UART when sending an AT command request to read or set a module parameter. The response can be disabled by setting ...

Page 103

XBee®/XBee‐PRO® ZB RF Modules  Source Routing The following image shows the API frame exchanges that take place at the UART when sending a source routed transmission. Supporting the API Applications that support the API should make provisions to deal with new API frames ...

Page 104

XBee®/XBee‐PRO® ZB RF Modules  Start Delimiter Length A P Frame-specific Data Frame Type Checksum The above example illustrates an AT command when querying an NJ value. AT Command - Queue Parameter Value Frame Type: 0x09 This ...

Page 105

XBee®/XBee‐PRO® ZB RF Modules  The broadcast radius can be set from NH. If set to 0, the value of NH specifies the broadcast radius (recommended). This parameter is only used for broadcast transmissions. The maximum number of payload bytes can ...

Page 106

XBee®/XBee‐PRO® ZB RF Modules  0x7E 0x00 0x16 0x10 0x01 0x00 0x7D 0x33 0xA2 0x00 0x40 0x0A 0x01 0x27 0xFF 0xFE 0x00 0x00 0x54 0x78 0x44 0x61 0x74 0x61 0x30 0x41 0x7D 0x33 The checksum is calculated (on all non-escaped bytes) as [0xFF - ...

Page 107

XBee®/XBee‐PRO® ZB RF Modules  Start Delimiter Length Frame-specific Data Frame Type Checksum Example: Send a data transmission to the coordinator (64-bit address of 0x00s) using a source endpoint of 0xA0, destination endpoint 0xA1, cluster ...

Page 108

XBee®/XBee‐PRO® ZB RF Modules  Remote AT Command Request Frame Type: 0x17 Used to query or set module parameters on a remote device. For parameter changes on the remote device to take effect, changes must be applied, either by setting the apply changes options ...

Page 109

XBee®/XBee‐PRO® ZB RF Modules  Create Source Route Frame Type: 0x21 This frame creates a source route in the module. A source route specifies the complete route a packet should traverse to get from source to destination. Source routing should be used with many-to-one ...

Page 110

XBee®/XBee‐PRO® ZB RF Modules  AT Command Response Frame Type: 0x88 In response Command message, the module will send an AT Command Response message. Some commands will send back multiple frames (for example, the ND (Node Discover) command). Start Delimiter Length ...

Page 111

XBee®/XBee‐PRO® ZB RF Modules  ZigBee Transmit Status Frame Type: 0x8B When a TX Request is completed, the module sends a TX Status message. This message will indicate if the packet was transmitted successfully or if there was a failure. Start Delimiter Length A ...

Page 112

XBee®/XBee‐PRO® ZB RF Modules  ZigBee Receive Packet Frame Type: (0x90) When the module receives an RF packet sent out the UART using this message type. Start Delimiter Length Frame-specific Data Checksum Example: ...

Page 113

XBee®/XBee‐PRO® ZB RF Modules  ZigBee Explicit Rx Indicator Frame Type:0x91 When the modem receives a ZigBee RF packet it is sent out the UART using this message type (when AO=1). Frame Fields Start Delimiter Length Frame-specific Data ...

Page 114

XBee®/XBee‐PRO® ZB RF Modules  ZigBee IO Data Sample Rx Indicator Frame Type: 0x92 When the module receives an IO sample frame from a remote device, it sends the sample out the UART using this frame type (when AO=0). Only modules running API firmware ...

Page 115

XBee®/XBee‐PRO® ZB RF Modules  Example: Suppose an IO sample is received with analog and digital IO, from a remote with a 64- bit address of 0x0013A200 40522BAA and a 16-bit address of 0x7D84. If pin AD1/DIO1 is enabled as an analog input, AD2/DIO2 ...

Page 116

XBee®/XBee‐PRO® ZB RF Modules  0x016A To convert these to temperature and humidity values, the following equations should be used. Temperature (° 16), for T < 2048 Vsupply = (AD2 * 5.1) / 255 Voutput = (AD3 * 5.1) ...

Page 117

XBee®/XBee‐PRO® ZB RF Modules  Node Identification Indicator Frame Type: 0x95 This frame is received when a module transmits a node identification message to identify itself (when AO=0). The data portion of this frame is similar to a network discovery response frame (see ND ...

Page 118

XBee®/XBee‐PRO® ZB RF Modules  Remote Command Response Frame Type: 0x97 If a module receives a remote command response RF data frame in response to a Remote AT Command Request, the module will send a Remote AT Command Response message out the UART. Some ...

Page 119

XBee®/XBee‐PRO® ZB RF Modules  Over-the-Air Firmware Update Status Frame Type: 0xA0 The Over-the-Air Firmware Update Status frame provides a status indication of a firmware update transmission attempt query command (0x01 0x51) is sent to a target with a 64-bit address of ...

Page 120

XBee®/XBee‐PRO® ZB RF Modules  Route Record Indicator Frame Type: 0xA1 The route record indicator is received whenever a device sends a ZigBee route record command. This is used with many-to-one routing to create source routes for devices in a network. Start Delimiter Length ...

Page 121

XBee®/XBee‐PRO® ZB RF Modules  Many-to-One Route Request Indicator Frame Type: 0xA3 The many-to-one route request indicator frame is sent out the UART whenever a many-to-one route request is received Start Delimiter Length Frame-specific Data ...

Page 122

XBee®/XBee‐PRO® ZB RF Modules  Sending ZigBee Device Objects (ZDO) Commands with the API ZigBee Device Objects (ZDOs) are defined in the ZigBee Specification as part of the ZigBee Device Profile. These objects provide functionality to manage and map out the ZigBee network and ...

Page 123

XBee®/XBee‐PRO® ZB RF Modules  Frame Fields Start Delimiter Length Frame Type Frame ID 64-bit Destination Address A P 16-bit Destination I Network Address P Source Endpoint Frame-specific Data a c Destination Endpoint Cluster ID Profile ID Broadcast Radius Transmit Options ...

Page 124

XBee®/XBee‐PRO® ZB RF Modules  Sending ZigBee Cluster Library (ZCL) Commands with the API The ZigBee Cluster Library defines a set of attributes and commands (clusters) that can be supported in multiple ZigBee profiles. The ZCL commands are typically required when developing a ZigBee ...

Page 125

XBee®/XBee‐PRO® ZB RF Modules  The following table shows how the Explicit API frame can be used to read the hardware version attribute from a device with a 64-bit address of 0x0013A200 40401234 (unknown 16-bit address). This example uses arbitrary source and destination endpoints. ...

Page 126

XBee®/XBee‐PRO® ZB RF Modules  In the above example, the Frame Control field (offset 23) was constructed as follows: Name Frame Type Manufacturer Specific Direction Disable Default Response Reserved See the ZigBee Cluster Library specification for details. Sending Public Profile Commands with the API ...

Page 127

XBee®/XBee‐PRO® ZB RF Modules  Frame Fields Start Delimiter Length Frame Type Frame ID 64-bit Destination Address 16-bit Destination A Network P Address I Source P Endpoint a Destination Frame-specific c Endpoint Data k e Cluster ID t Profile ID Broadcast Radius Transmit Options ...

Page 128

XBee®/XBee‐PRO® ZB RF Modules  Frame Fields ZCL Payload - Load Control Event Data Checksum In the above example, the Frame Control field (offset 23) was constructed as follows: Name Frame Type Manufacturer Specific Direction Disable Default Response Reserved © 2010 Digi International, Inc. Offset Example 26 0x78 ...

Page 129

Addressing Addressing Commands AT Name and Description Command Destination Address High.Set/Get the upper 32 bits of the 64-bit destination address. When combined with DL, it defines the 64-bit destination address for data transmission. DH Special definitions for DH and DL ...

Page 130

XBee®/XBee‐PRO® ZB RF Modules  Networking Networking Commands AT Name and Description Command Operating Channel. Read the channel number used for transmitting and receiving CH between RF modules. Uses 802.15.4 channel numbers. A value of 0 means the device has not joined a PAN and ...

Page 131

XBee®/XBee‐PRO® ZB RF Modules  Networking Commands AT Name and Description Command Node Join Time. Set/Read the time that a Coordinator/Router allows nodes to join. This value can be changed at run time without requiring a Coordinator or Router to NJ restart. The time starts ...

Page 132

XBee®/XBee‐PRO® ZB RF Modules  Security Security Commands AT Name and Description Command EE Encryption Enable. Set/Read the encryption enable setting. Encryption Options. Configure options for encryption. Unused option bits should be set to 0. Options include: EO 0x01 - Send the security key unsecured ...

Page 133

XBee®/XBee‐PRO® ZB RF Modules  Serial Interfacing (I/O) Serial Interfacing Commands AT Name and Description Command API Enable. Enable API Mode. AP The AP command is only supported when using API firmware: 21xx (API coordinator), 23xx (API router), 29xx (API end device). API Options. Configure options ...

Page 134

XBee®/XBee‐PRO® ZB RF Modules  I/O Commands I/O Commands AT Name and Description Command IO Sample Rate. Set/Read the IO sample rate to enable periodic sampling. For periodic sampling to be enabled, IR must be set to a non-zero value, and at least one module ...

Page 135

XBee®/XBee‐PRO® ZB RF Modules  I/O Commands AT Name and Description Command AD3/DIO3 Configuration. Select/Read function for AD3/DIO3 DIO4 Configuration. Select/Read function for DIO4. D5 DIO5 Configuration. Configure options for the DIO5 line of the RF module. D8 DIO8 Configuration. Set/Read function for ...

Page 136

XBee®/XBee‐PRO® ZB RF Modules  Diagnostics Diagnostics Commands AT Name and Description Command Firmware Version. Read firmware version of the module. The firmware version returns 4 hexadecimal values (2 bytes) "ABCD". Digits ABC are the main release number and D is the revision number from ...

Page 137

XBee®/XBee‐PRO® ZB RF Modules  Sleep Commands Sleep Commands AT Name and Description Command Sleep Mode Sets the sleep mode on the RF module. An XBee loaded with router firmware can be configured as either a router (SM set end device ...

Page 138

XBee®/XBee‐PRO® ZB RF Modules  Execution Commands AT Name and Description Command Node Discover. Discovers and reports all RF modules found. The following information is reported for each module discovered. MY<CR> SH<CR> SL<CR> NI<CR> (Variable length) PARENT_NETWORK ADDRESS (2 Bytes)<CR> DEVICE_TYPE<CR> (1 Byte: 0=Coord, 1=Router, ...

Page 139

This chapter provides customization information for the XBee/XBee-PRO ZB modules. In addition to providing an extremely flexible and powerful API, the XBee and XBee-PRO ZB modules are a robust development platform that have passed FCC and ETSI testing. Developers ...

Page 140

XBee®/XBee‐PRO® ZB RF Modules  Programming XBee Modules Firmware on the XBee and XBee-PRO ZB modules can be updated through one of two means: •Serially •SIF header. Each method is described below. Serial Firmware Updates Serial firmware updates make use of the XBee custom ...

Page 141

XBee®/XBee‐PRO® ZB RF Modules  Hex Error Code 0x44 0x45 0x46 0x47 0x48 0x49 0x4A 0x4B 0x4C 0x4D SIF Firmware Updates The XBee/XBee-PRO modules have a 2x5 SIF header that can be used with Ember's InSight tools to upload firmware onto the modules. These ...

Page 142

XBee®/XBee‐PRO® ZB RF Modules  GPIO_CFG[7:4]Enabled Functionality Enabled Functionality Example 1 The following code enables GPIO 10, 11, and 12 and maintains all other GPIO_CFG bits. int16u GPIO_CFG; x &= (0xFF0F); // Clear bits 4 - ...

Page 143

XBee®/XBee‐PRO® ZB RF Modules  GPIO_DIRSETL = GPIO(2);// Set GPIO output GPIO_CLRL = GPIO(2); // Drive GPIO 2 low /* After at least 10ms, GPIO 2 should be set high to power the output power compensation circuitry. At the same time ...

Page 144

Appendix A: Definitions Definitions ZigBee Node Types Coordinator Router End device © 2010 Digi International, Inc. A node that has the unique function of forming a network. The coor- dinator is responsible for establishing the operating channel and PAN ID for an entire network. Once established, ...

Page 145

XBee®/XBee‐PRO® ZB RF Modules  ZigBee Protocol PAN Joining Network Address Operating Channel Energy Scan Route Request Route Reply Route Discovery ZigBee Stack © 2010 Digi International, Inc. Personal Area Network - A data communication network that includes a coordinator and one or more routers/end devices. The process ...

Page 146

Appendix B: Agency Certifications United States FCC The XBee RF Module complies with Part 15 of the FCC rules and regulations. Compliance with the labeling requirements, FCC notices and antenna usage guidelines is required. To fulfill FCC Certification, the OEM must comply with ...

Page 147

XBee®/XBee‐PRO® ZB RF Modules  If this equipment does cause harmful interference to radio or television reception, which can be determined by turning the equipment off and on, the user is encouraged to try to correct the interference by one or more of the ...

Page 148

XBee®/XBee‐PRO® ZB RF Modules  Antennas approved for use with the XBee RF Module  YAGI CLASS ANTENNAS for Channels Part Number Type (Description) A24-Y6NF Yagi (6-element) A24-Y7NF Yagi (7-element) A24-Y9NF Yagi (9-element) A24-Y10NF Yagi (10-element) A24-Y12NF Yagi (12-element) A24-Y13NF Yagi (13-element) A24-Y15NF Yagi (15-element) A24-Y16NF Yagi (16-element) A24-Y16RM Yagi ...

Page 149

XBee®/XBee‐PRO® ZB RF Modules  Antennas approved for use with the XBee‐PRO (S2) RF Module YAGI CLASS ANTENNAS for Channels Part Number Type (Description) A24-Y6NF Yagi (6-element) A24-Y7NF Yagi (7-element) A24-Y9NF Yagi (9-element) A24-Y10NF Yagi (10-element) A24-Y12NF Yagi (12-element) A24-Y13NF Yagi (13-element) A24-Y15NF Yagi (15-element) A24-Y16NF Yagi (16-element) A24-Y16RM Yagi ...

Page 150

XBee®/XBee‐PRO® ZB RF Modules  Antennas approved for use with the XBee‐PRO (S2B) RF Module YAGI CLASS ANTENNAS for Channels Part Number Type (Description) A24-Y6NF Yagi (6-element) A24-Y7NF Yagi (7-element) A24-Y9NF Yagi (9-element) A24-Y10NF Yagi (10-element) A24-Y12NF Yagi (12-element) A24-Y13NF Yagi (13-element) A24-Y15NF Yagi (15-element) A24-Y16NF Yagi (16-element) A24-Y16RM Yagi ...

Page 151

XBee®/XBee‐PRO® ZB RF Modules  Europe (ETSI) The XBee RF Modules have been certified for use in several European countries. For a complete list, refer to www.digi.com If the XBee RF Modules are incorporated into a product, the manufacturer must ensure compliance of the ...

Page 152

XBee®/XBee‐PRO® ZB RF Modules  Antenna Type: Yagi RF module was tested and approved with 15 dBi antenna gain with 1 dB cable-loss (EIRP Maximum of 14 dBm). Any Yagi type antenna with 14 dBi gain or less can be used with no cable-loss. ...

Page 153

XBee®/XBee‐PRO® ZB RF Modules  Detachable Antenna To reduce potential radio interference to other users, the antenna type and gain should be so chosen that the equivalent, istropically radiated power (e.i.r.p.) is not more than permitted for successful communication. Australia (C-Tick) These modules comply ...

Page 154

Appendix C: Migrating from ZNet 2.5 to XBee  The following paragraph contains the significant differences in XBee ZB compared to its predecessor, ZNet 2.5. •Command Set •Firmware Versions •New Features. Command Set The following ZNet 2.5 commands have changed for XBee ZB: •ZA - Set / read ...

Page 155

... Digi International, shipping prepaid, for prompt repair or replacement. The foregoing sets forth the full extent of Digi International's warranties regarding the Product. Repair or replacement at Digi International's option is the exclusive remedy. THIS WARRANTY IS GIVEN IN LIEU OF ALL OTHER WARRANTIES, EXPRESS OR IMPLIED, AND DIGI SPECIFICALLY DISCLAIMS ALL WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE ...

Related keywords