Black Box MDR3243A User Manual

Manual Documentation Number: MDR3243A-807 Table of Contents
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
2.4GHZ, 100Mw 250kpbs
Model Number: MDR3243A
Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
Manual Documentation Number: MDR3243A-807 Table of Contents
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
Table of Contents
Chapter 1 – Introduction… … … … … … … … … … … … … … … … … … .1 Chapter 2 – Check Package Contents… … … … … … … … … … … … 1 Chapter 3 – Dip Switch Settings…………………………………….. 1 Chapter 4 – Product Installation… … ………………………………. 2 Chapter 5 – Software………………………………………… ………..3 Chapter 6 – Basic Software Configuration… … … … … … … … … … 4 Chapter 7 – LED Status………………………………………………..5 Chapter 8 – Range Selection/Antenna Selection… … … … … … … .6 Chapter 9 – Table of Specifications… … … … … … … … … … … … … .6 Chapter 10 – Programming Examples… … … … … … … … … … … ...9
Manual Documentation Number: MDR3243A-807 1
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
1) Introduction
Easy to install, up to 1 mile range. No wires, no cables! Wireless data extenders get your data moving farther, easier, and at less cost than running cable. Plug-n-play, Modbus compatible, signal strength indicator, space saving DIN rail mounting. Heavy-duty, wide temperature design handles most industrial power configurations and tough indoor/outdoor environments.
Table 1
2) Check Package Contents
Wireless data extenders
Antenna
Software CD
Will require separate 18-30VAC or 10-48VDC Power Supply
MDR3243A = 2.0W max
3) Dip switch Settings
Table 2
Dipswitch OFF ON
1 4-wire 2-wire 2 4-wire 2-wire 3 No termination Termination 4 RS-422 RS-485
Model # Frequency Radio
Power
RF Data Rate
MDR3243A 2.4GHz 100mW 250Kbps
2 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
RS-485 (2Wire) RS-422/485 (4Wire)RS-232
4) Product Installation
Install on properly grounded DIN rail
Operating Temperature is -40 to 85C
Operating Humidity is 10-90% non-condensing
Connect Power Supply
Power supply is 10-48 VDC or 18-30 VAC
– +
Determine RS-232, RS-422, RS-485 communication
RS-232 always present on DB9
DB9F Pin Signal Name Direction
1 Data Carrier Detect Out 2 Receive Data Out 3 Transmit Data In 4 Data Terminal Ready In 5 Signal Ground --­6 Data Set Ready Out 7 Request To Send In 8 Clear To Send Out 9 Not used ---
10-48 VDC
or
18-30 VAC
2
1
ANT
Manual Documentation Number: MDR3243A-807 3
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
Note: The DTR input is used to put the radio into sleep mode. The radio sleep option must be enabled first using the configuration software. Once enabled, lowering the DTR signal will put the radio in sleep mode and raising the DTR signal will put the radio in idle mode, ready to receive or transmit data.
Wireless Link Failure Output
Wireless data extenders offer a source (PNP)transistor output when the wireless signal strength drops below a critical level (link failure or miss packets)
40 mA max current
Note: For the RSSI LED to work correctly the “RP” command (RSSI PWM Timer) must be set to “FF”.
5) Software Installation
Insert CD and it will autostart
Follow screen instructions to install software
Connect to PC with straight through serial cable
4 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
6) Basic Software Configuration
Under PC Settings
Setup your COM port
Baud Rate (Default is… 9600) Flow Control (Default is… none) Data Bits (Default is… 8) Parity (Default is… none) Stop Bits (Default is… 1)
Test Connection with Test/Query button
Under Modem Configuration T a b
Select Appropriate Modem Part Number or use the “Read” button to automatically detect the Modem type.
Follow on-screen help files and refer to section 10 for advanced operations.
Model # Frequency Radio
Power
RF Data Rate
MDR3243A 2.4GHz 100mW 250Kbps
Manual Documentation Number: MDR3243A-807 5
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
7) LED Status
Table 3
Front Panel LED Status
Power Red = ON
OFF = No Power
RSSI (Signal Strength) Green = Strong
Yellow = OK Red = Weak OFF = No Signal
Wireless Data Green = Blink ON with
data
6 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
Note: For the RSSI LED to work correctly the “RP” command (RSSI PWM Timer) must be set to “FF”.
8) Range Selection/Antenna Selection
The Wireless data extenders Product is shipped with an antenna with the following expected ranges (see table 4)
These ranges are for reference only with Line of Sight
The antenna connector on the Wireless data
extenders product is a reverse polarity SMA female plug
Table 4
9) Table of Specifications
RF Properties
Physical Standard IEEE 802.15.4
Range up to 300 feet indoor or 1 mile outdoor
Frequency 2.4GHz
Transmit Power 100mW
Software Wireless data extenders
Support Win 98, ME, 2K, XP
Features AT Command
Terminal emulation RSSI signal range test Modem emulation
Antenna Options
External Reverse Polarity SMA male jack connector, omni directional (includ ed wit h product)
Radio Address
Defaulted at factory, set by software otherwise
Serial settings
Baud 1200, 2400, 4800, 9600, 19200, 38400, 57600,
115200
Data bit 8 only
Parity None only
Model # Indoor
Range
Outdoor Range
MDR3243A up to 300
feet
up to 1 mile
Manual Documentation Number: MDR3243A-807 7
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
Stop bit 1 only
RS-232
Connector DB9F DCE
Lines TX, RX, RTS, CTS, DTR, DSR, DCD, RI, GND
Connector Removable terminal block
Lines TX, RX, GND
RS-422
Connector Removable terminal block
Lines 2 or 4 wire – TX+, TX-, RX+, RX-, GND (2 or 4
wire dipswitch selectable)
Termination 120 Ohm Dipswitch selectable
RS-485
Connector Removable terminal block
Lines 2 or 4 wire with SD control – TX+, TX-, RX+,
RX-, GND (2 or 4 wire dipswitch selectable)
SD control Bit wise
Termination 120 Ohm Dipswitch selectable
Transistor link failure
No wireless signal or RSSI LED off
Connector Removable terminal block with RS-422/485
Output type Open collector, dry contact, 40mA
Power Supply
Connector Removable terminal block
Input Voltage 10– 48VDC, 18-30VAC
Power
Consumption
2.0W max
Dimensions
1.2W x 3.3D x 4.7H
Environmental
Intended for indoor use only
Operating
Temperature
-40 to 85ºC (-40 to 185ºF)
Storage
Temperature
-40 to 85ºC (-40 to 185ºF)
Operating
Humidity
10 to 90% non-condensing
Enclosure Rating
Rating IP30
Mounting DIN rail mount, 35mm
8 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
LED Status
Front Panel LED Status Power Red = On
OFF = No Power RSSI (Signal Strength)
Green = Strong
Yellow = OK
Red = Weak
OFF = No Signal Wireless Data Green = Blink on with
data
Note: For the RSSI LED to work correctly the “RP” command (RSSI PWM Timer), must be set to “FF”
Certifications
FCC
FCC Part 15 Class B
CE CISPR (EN55022) Class B
EN61000-6-1 Generic Standards for Residential, Commercial, & Light Industrial EN61000-4-2 ESD EN61000-4-3 RFI EN61000-4-4 EFT EN61000-4-5 Surge EN61000-4-6 CI EN61000-4-8 Power Frequency Magnetic EN61000-4-11 Voltage Dips & Interruptions
RoHS directive
(lead free)
Yes
Manual Documentation Number: MDR3243A-807 9
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
10) Advanced Programming
For information about entering and exiting AT and Binary Command Modes, refer to the Command Mode section.
Sample Configuration: Modify RF Module Destination Address
Sample Configuration: Restore RG Module Defaults
Setup
The programming examples in this section require the installat ion of BLACK BOX's WIRELESS DATA EXTENDERS Soft ware and a serial connection to a PC. (BLACK BOX stocks RS-232 and USB boards to facilitate interfacing with a PC.)
1. Install BLACK BOX's WIRELESS DATA EXTENDERS Software to a PC by double-clicking the "setup_ WIRELESS DATA EXTENDERS.exe" file.
2. Mount the RF module to an interface board, then connect the module assembly to a PC.
3. Launch the WIRELESS DATA EXTENDERS Software and select the 'PC Settings' tab. Verify the baud and parity settings of the Com Port match those of the RF module. NOTE: Failure to enter AT Command Mode is most commonly due to baud rate mismatch. Ensure the ‘Baud’ setting on the ‘PC Settings’ tab matches the interface data rate of the RF module. By default, the BD parameter = 3 (which corresponds to 9600 bps).
Example: Utilize the WIRELESS DATA EXTENDERS “Terminal” tab to change the RF module's DL (Destinat ion Address Low) parameter and save the new address to non-volatile memory. tion above], select the “Terminal” tab of t h e WIRELESS DATA EXTENDERS Software and enter the following command lines (‘CR’ stands for carriage return):
Method 1 (One line per command)
Send AT Command System Response_
+++
OK <CR> (Enter into Command Mode)
ATDL <Enter> {current value} <CR> (Read Destination Address Low)
ATDL1A0D <Enter> OK <CR> (Modify Destination Address Low)
ATWR <Enter> OK <CR> (Write to non-volatile memory) ATCN <Enter> OK <CR> (Exit Command Mode)
Method 2 (Multiple commands on one line)
Send AT Command_ System Response_
+++
OK <CR> (Enter into Command Mode)
ATDL <Enter> {current value} <CR> (Read Destination Address Low)
ATDL1A0D,WR,CN <Enter>
OK, OK, OK <CR> (Command execution is triggered upon each instance of the comma)
10 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
Command Reference Table
XBee/XBee-PRO RF Modules expect numerical values in hexadecimal. Hexadecimal values are designated by a “0x” prefix. Decimal equivalents are designated by a “d” suffix. Commands are contained within the following command categories (listed in the order that their tables appear):
• Special
• Networking & Security
• RF Interfacing
• Sleep (Low Power)
• Serial Interfacing
• I/O Settings
• Diagnostics
• AT Command Options All modules within a PAN should operate using the same firmware version.
Commands-Special
AT_ Command
Command _ Category
Name and Description
Parameter Range
Default
WR Special
Write. Write parameter values to non-volatile memory so that parameter modifications persist through subsequent power-up or reset. Note: Once WR is issued, no additional characters should be sent to the module until after the response "OK\r" is received.
- -
RE Special
Restore Defaults. Restore module parameters to factory defaults.
- -
FR ( v1.x80*) Special
Software Reset. Responds immediately with an OK then performs a hard reset ~100ms later.
- -
*Firmware version in which the command was first introduced (firmware versions are numbered in hexadecimal notation.)
Commands-Networking & Security (Sub categories designated within {brackets})
AT_ Command
Command_ Category
Name and Description
Parameter Range
Default
CH
Networking {Addressing}
Channel. Set/Read the channel number used for transmitting and receivin
g
data between RF
0x0B - 0x1A (XBee) 0x0C ­0x17 (XBee-PRO)
0x0C (12d)
Example: Utilize the WIRELESS DATA EXTENDERS “Modem Configuration” tab to rest ore default parameter values. After establishing a connection between the module and a PC [refer to the 'Setup' section above], select the “Modem Configuration” tab of the WI RELESS DATA EXTENDERS Software.
1. Select the 'Read' button.
2. Select the 'Restore' button.
Manual Documentation Number: MDR3243A-807 11
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
modules (uses 802.15.4 protocol channel numbers).
ID
Networking {Addressing}
PAN ID. Set/Read the PAN (Personal Area Network) ID._ Use 0xFFFF to broadcast messages to all PANs.
0 - 0xFFFF
0x3332_ (13106d)
DH
Networking {Addressing}
Destination Address High. Set/Read the upper 32 bits of the 64-bit destination address. When combined with DL, it defines the destination address used for transmission. To transmit using a 16-bit address, set DH parameter to zero and DL less than 0xFFFF. 0x000000000000FFFF is the broadcast address for the PAN.
0 - 0xFFFFFFFF 0
DL
Networking {Addressing}
Destination Address Low. Set/Read the lower 32 bits of the 64-bit destination address. When combined with DH, DL defines the destination address used for transmission. To transmit using a 16-bit address, set DH parameter to zero and DL less than 0xFFFF. 0x000000000000FFFF is the broadcast address for the PAN.
0 - 0xFFFFFFFF 0
MY
Networking {Addressing}
16-bit Source Address.Set/Read the RF module 16-bit source address. Set MY = 0xFFFF to disable reception of pack et s wit h 16-bit addresses. 64-bit source address (serial number) and broadcast address (0x000000000000FFFF) is always enabled.
0 - 0xFFFF 0
SH
Networking {Addressing}
Serial Number High. Read high 32 bits of the RF module's unique IEEE 64-bit address. 64-bit source address is always enabled.
0 - 0xFFFFFFFF
[read-only]
Factory-set
SL
Networking {Addressing}
Serial Number Low. Read low 32 bits of the RF module's unique IEEE 64-bit address. 64-bit source address is always enabled.
0 - 0xFFFFFFFF
[read-only]
Factory-set
RR ( v1.xA0*)
Networking {Addressing}
XBee Retries. Set/Read the maximum number of retries the module will execute in addition to the 3 retries provided by the
802.15.4 MAC. For each XBee retry, the 802.15.4 MAC can execute up to 3 retries.
0 - 6 0
RN
Networking {Addressing}
Random Delay Slots. Set/Read the minimum value of the back-off exponent in the CSMA-CA
0 - 3 [exponent] 0
12 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
algorithm that is used for collision avoidance. If RN = 0, collision avoidance is disabled during the first iteration of the algorithm (802.15.4 - macMinBE).
MM ( v1.x80*)
Networking {Addressing}
MAC Mode.Set/Read MAC Mode value. MAC Mode enables/disables the use of a BLACK BOX header in the
802.15.4 RF packet. When Mode 0 is enabled (MM=0), duplicate packet detection is enabled as well as certain AT commands. Modes 1 and 2 are strict 802.15.4 modes.
0 – 2 0 = 1 = BLACK BOX Mode 1 = 802.15.4 (no ACKs) 2 =802.15.4 (with ACKs)
0
NI ( v1.x80*)
Networking {Identification}
Node Identifier.Stores a string identifier. The register only accepts printable ASCII da t a. A string can not start with a space. Carriage return ends command. Command will automatically end when maximum bytes for the string have been entered. This string is returned as part of the ND (Node Discover) command. This identifier is also used with the DN (Destination Node) command.
20-character ASCII string
-
ND ( v1.x80*)
Networking {Identification}
Node Discover.Discovers and reports all RF modules found. The following information is reported for each module discovered (the example cites use of Transparent operation (AT command for m at) ­refer to the long ND command description regarding differences between Transparent and API operation). MY<CR> SH<CR> SL<CR> DB<CR> NI<CR><CR> The amount of time the module allows for responses is determined by the NT parameter. In Transparent operation, command completion is designated by a <CR> (carriage return). ND also accepts a No de Identifier as a parameter. In this case, only a module matching the supplied identifier will respond.
Optional
20-character NI
value
NT ( v1.xA0*)
Networking {Identification}
Node Discover Time.Set/Read the amount of time a node will wait for responses from other
0x01 - 0xFC 0x19
Manual Documentation Number: MDR3243A-807 13
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
nodes when using the ND (Node Discover) command.
DN ( v1.x80*)
Networking {Identification}
Destination Node. Resolves an NI (Node Identifier) string to a physical address. The following events occur upon successful command execution:
1. DL and DH are set to the address of the module with the matching Node Identifier.
2. “OK” is returned.
3. RF module automatically exits AT Command Mode If there is no response from a module within 200 msec or a parameter is not specified (left blank), the command is terminated and an “ERROR” message is returned.
20-character ASCII string
-
CE ( v1.x80*)
Networking {Association}
Coordinator Enable. Set/Read the coordinator setting.
0 - 1 0 = End Device_ 1 = Coordinator
0
SC ( v1.x80*)
Networking {Association}
Scan Channels. Set/Read list of channels to scan for all Active and Energy Scans as a bitfield. This affects scans initiated in command mode (AS, ED) and during End Device Association and Coordinator startup: bit 0 - 0x0B bit 4 - 0x0F bit 8 - 0x13 bit12 - 0x17 bit 1 - 0x0C bit 5 - 0x10 bit 9 - 0x14 bit13 - 0x18 bit 2 - 0x0D bit 6 - 0x11 bit 10 - 0x15 bit14 - 0x19 bit 3 - 0x0E bit 7 - 0x12 bit 11 - 0x16 bit 15 - 0x1A
0 - 0xFFFF [bitfield]_ (bits 0, 14, 15 not allowed on the XBee-PRO)
0x1FFE (all XBee-PRO Channels)
SD ( v1.x80*)
Networking {Association}
Scan Duration. Set/Read the scan duration exponent. End Device- Duration of Active Scan during Association. On beacon system, set SD = BE of coordinator. SD must be set at least to the highest BE parameter of any Beaconing Coordinator with which an End Device or Coordinator wish to discover. Coordinator- If ‘ReassignPANID’ option is set on Coordinator [refer to A2 parameter], SD determines the length of time the Coordinator will scan channels to locate existing PANs. If ‘ReassignChannel’ option is set, SD determines how long the Coordinator will perform an Energy Scan to determine which
0-0x0F [exponent] 4
14 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
channel it will operate on. ‘Scan Time’ is measured as (# of channels to scan] * (2 ^ SD) *
15.36ms). The number of channels to scan is set by the SC command. The XBee can scan up to 16 channels (SC = 0xFFFF). The XBee PRO can scan up to 13 channels (SC = 0x3FFE). Example: The values below show results for a 13 channel scan: If SD = 0, time = 0.18 sec SD = 8, time = 47.19 sec SD = 2, time = 0.74 sec SD = 10, time = 3.15 min SD = 4, time = 2.95 sec SD = 12, time = 12.58 min SD = 6, time = 11.80 sec SD = 14, time = 50.33 min
A1 ( v1.x80*)
Networking {Association}
End Device Association. Set/Read End Device association options. bit 0 - ReassignPanID 0 - Will only associate with Coordinator operating on PAN ID that matches module ID 1 - May associate with Coordinator operating on any PAN ID bit 1 – ReassignChannel 0 - Will only associate with Coordinator operating on matching CH Channel set ting 1 - May associate with Coordinator operating on any Channel bit 2 – AutoAssociate 0 - Device will not attempt Association 1 - Device attempts Association until success Note: This bit is used only for Non-Beacon systems. End Devices in Beacon-enabled system must always associate to a Coordinator bit 3 – PollCoordOnPinWake 0 - Pin Wake will not poll the Coordinator for indirect (pending) data 1 - Pin Wake will send Poll Request to Coordinator to extract any pending data bits 4 - 7 are reserved
0 - 0x0F [bitfield] 0
A2 ( v1.x80*)
Networking {Association}
Coordinator Association. Set/Read Coordinator association
0 - 7 [bitfield] 0
Manual Documentation Number: MDR3243A-807 15
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
options. bit 0 – ReassignPanID 0 - Coordinator will not perform Active Scan to locate available PAN ID. It will operate on ID (PAN ID). 1 - Coordinator will perform Active Scan to determine an available ID (PAN ID). If a PAN ID conflict is found, the ID parameter will change. bit 1 - ReassignChannel – 0 - Coordinator will not
perform Energy Scan to determine free channel. It will operate_ on the channel determined by the CH parameter. 1 - Coordinator will perform Energy Scan to find a free channel, then operate on
that channel. bit 2 - AllowAssociatio n – 0 - Coordinator will not
allow any devices to
associate to it.
1 - Coordinator will allow
devices to associate to it. bits 3 - 7 are reserved
AI ( v1.x80*)
Networking {Association}
Association Indication. Read errors with the last association request: 0x00 - Successful Completion ­Coordinator successfully started or End Device association complete 0x01 - Active Scan Timeout 0x02 - Active Scan found no PANs 0x03 - Active Scan found PAN, but the CoordinatorAllowAssociation bit is not set 0x04 - Active Scan found PAN, but Coordinator and End Devic e are not configured to support beacons 0x05 - Active Scan found PAN, but the Coordinator ID parameter does not match the ID parameter of the End Device 0x06 - Active Scan found PAN, but the Coordinator CH parameter does not match the CH parameter of the End Device
0 - 0x13 [read­only]
-
16 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
0x07 - Energy Scan Timeout 0x08 - Coordinator start request failed_ 0x09 - Coordinator co uld not start due to invalid parameter 0x0A - Coordinator Realignment is in progress 0x0B - Association Request not sent 0x0C - Association Request timed out - no reply was received 0x0D - Association Request had an Invalid Parameter 0x0E - Association Request Channel Access Failure. Request was not transmitted - CCA failure 0x0F - Remote Coordinator did not send an ACK after Association Request was sent 0x10 - Remote Coordinator did not reply to the Association Request, but an ACK was received after sending the request 0x11 - [reserved] 0x12 - Sync-Loss - Lost synchronization with a Beaconing Coordinator 0x13 - Disassociated - No longer associated to Coordinator
DA ( v1.x80*)
Networking {Association}
Force Disassociation. End Device will immediately disassociate from a Coordinator (if associated) and reattempt to associate.
- -
FP ( v1.x80*)
Networking {Association}
Force Poll. Request indirect messages being held by a coordinator.
- -
AS ( v1.x80*)
Networking
{Association}
A
ctive Scan. Send Beacon
Request to Broadcast Address (0xFFFF) and Broadcast PAN (0xFFFF) on every channel. The parameter determines the time the radio will listen for Beacons on each channel. A PanDescriptor is created and returned for every Beacon received from the scan. Each PanDescriptor contains the following information: CoordAddress (SH, SL)< CR> CoordPanID (ID)<CR> CoordAddrMode <CR> 0x02 = 16-bit Short Address 0x03 = 64-bit Long Address _ Channel (CH parameter) <CR> _ SecurityUse<CR> _
0 - 6
-
Manual Documentation Number: MDR3243A-807 17
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
ACLEntry<CR> _ SecurityFailure<CR> _ SuperFrameSpec<CR> (2 bytes): bit 15 - Association Permitted (MSB) bit 14 - PAN Coordinator bit 13 – Reserved bit 12 - Battery Life Extension bits 8-11 - Final CAP Slot bits 4-7 - Superframe Order bits 0-3 - Beacon Order GtsPermit<CR> RSSI<CR> (RSSI is returned as ­dBm) TimeStamp<CR> (3 bytes) <CR> A carriage return <CR> is sent at the end of the AS command. The Active Scan is capable of returning up to 5 PanDescriptors in a scan. The actual scan time on each channel is measured as Time = [(2 ^SD PARAM) * 15.36] ms. Note the total scan time is this time multiplied by the number of channels to be sca nned (16 for the XBee and 13 for the XBee­PRO). Also refer to SD command description.
ED ( v1.x80*)
Networking
{Association}
Energy Scan. Send an Energy
Detect Scan. This parameter
determines the length of scan on
each channel. The maximal
energy on each channel is
returned & each value is followed
by a carriage return. An additional
carriage return is s ent at the end
of the command. The values
returned represent the detected energy level in units of -dBm. The actual scan time on each channel is measured as Time = [(2 ^ED) *
15.36] ms. Note the total scan
time is this time multiplied by the
number of channels t o be
scanned (refer to SD parameter).
0 - 6
-
EE ( v1.xA0*)
Networking {Security}
AES Encryption Enable. Disable/Enable 128-bit AES encryption support. Use in conjunction with the KY command.
0 - 1
0 (disabled)
KY ( v1.xA0*)
Networking {Security}
AES Encryption Key. Set the 128-bit AES (Advanced Encryption Standard) key for encrypting/decrypt in g dat a . Th e KY register cannot be read.
0 - (any 16-Byte value)
-
18 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
*Firmware version in which the command was first introduced (firmware versions are numbered in hexadecimal notation.)
Commands-RF Interfacing
AT_ Command
Command_ Category
Name and Description
Parameter Range
Default
PL RF Interfacing
Power Level. Select/Read the power level at which the RF module transmits conducted power. NOTE: XBee-PRO RF
Modules optimized for use in Japan contain firmware that limits transmit power output to 10 dBm. If PL=4 (default), the maximum power output level is fixed at 10 dBm.
0 - 4 0 = -10 / 10 dBm 1 = -6 / 12 dBm 2 = -4 / 14 dBm 3 = -2 / 16 dBm 4 = 0 / 18 dBm
4
CA (v1.x80*) RF Interfacing
CCA Threshold. Set/read the CCA (Clear Channel Assessment) threshold. Prior to transmitting a packet, a CCA is performed to detect energy on the channel. If the detected energy is above the CCA Threshold, the modul e will not transmit the packet.
0 - 0x50 [-dBm]
0x2C (-44d dBm)
*Firmware version in which the command was first introduced (firmware versions are numbered in hexadecimal notation.)
Commands-Sleep (Low Power)
AT_ Command
Command_ Category
Name and Description
Parameter Range
Default
SM
Sleep_ (Low Power)
Sleep Mode. <NonBeacon firmware> Set/Read Sleep Mode configurations.
0 – 5 0 = No Sleep 1 = Pin Hibernate 2 = Pin Doze 3 = Reserved 4 = Cyclic sleep remote 5 = Cyclic sleep remote w/ pin wake-up 6 = [Sleep Coordinator] for backwards compatibility w/ v1.x6 only; otherwise, use CE command.
0
Manual Documentation Number: MDR3243A-807 19
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
ST
Sleep_ (Low Power)
Time before Sleep.<NonBeacon firmware> Set/Read time period of inactivity (no serial or RF data is sent or received) before activating Sleep Mode. ST parameter is only valid with Cyclic Sleep settings (SM = 4 - 5). Coordinator and End Device ST values must be equal. Also note, the GT parameter value must always be less than the ST value. (If GT > ST, the configuration will render the module unable to enter into command mode.) If the ST parameter is modified, also modify the GT parameter accordingly.
1 -0xFFFF [x 1 ms]
0x1388 (5000d)
SP
Sleep_ (Low Power)
Cyclic Sleep Period.<NonBeacon firmware> Set/Read sleep period for cyclic sleeping remotes. Coordinator and End Device SP values should always be equal. To send Direct Messages, set SP = 0. End Device- SP determines the sleep period for cyclic sleeping remotes. Maximum sleep period is 268 seconds (0x68B0). Coordinator- If non-zero, SP determines the time to hold an indirect message before discarding it. A Coordinator will discard indirect messages after a period of (2.5 * SP).
0 - 0x68B0 [x 10 ms]
0
DP (1.x80*)
Sleep_ (Low Power)
Disassociated Cycl i c Sl ee p Period.<NonBeacon firmware> _
End Device - Set/Read time period of sleep for cyclic sleeping remotes that are configured fo r Assoc i ation but are not associated to a Coordinator. (i.e. If a device is configured to associate, configured as a Cyclic Sleep remote, but does not find a Coordinator, it will sleep for DP time before reattempting association.) Maximum sleep period is 268 seconds (0x68B0). DP should be > 0 for NonBeacon systems.
1 - 0x68B0 [x 10 ms]
0x3E8_ (1000d)
*Firmware version in which the command was first introduced (firmware versions are numbered in hexadecimal notation.)
Commands-Serial Interfacing
AT_ Command
Command_ Category
Name and Description
Parameter Range
Default
20 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
BD
Serial _
Interfacing
Interface Data Rate. Set/Read the serial interface data rate for communications between the RF module serial port and host. Request non-standard baud rates with values above 0x80 us ing a terminal window. Read the BD register to find actual baud rate achieved.
0 - 7 (standard baud rates) 0 = 1200 bps 1 = 2400 2 = 4800 3 = 9600 4 = 19200 5 = 38400 6 = 57600 7 = 115200 0x80 - 0x1C200 (non-standard baud rates)
3
RO
Serial _ Interfacing
Packetization Timeout. Set/Read number of character times of inter­character delay required before transmission. Set to zero to transmit characters as they arrive instead of buffering them into one RF packet.
0 - 0xFF [x character times]
3
AP (v1.x80*)
Serial _
Interfacing
API Enable. Disable/Enable API Mode.
0 - 2 0 = Disabled 1 = API enabled 2 = API enabled (w/escaped control characters)
0
PR (v1.x80*)
Serial _ Interfacing
Pull-up Resistor Enable. Set/Read bitfield to configure internal pull-up resistor status for I/O lines Bitfield Map: bit 0 - AD4/DIO4 (pin11) bit 1 - AD3 / DIO3 (pin17) bit 2 - AD2/DIO2 (pin18) bit 3 - AD1/DIO1 (pin19) bit 4 - AD0 / DIO0 (pin20) bit 5 - RTS / AD6 / DIO6 (pin16) bit 6 - DTR / SLEEP_RQ / DI8 (pin9) bit 7 - DIN/CONFIG (pin3) Bit set to “1” specifies pull-up enabled; “0” specifies no pull-up
0 - 0xFF 0xFF
*Firmware version in which the command was first introduced (firmware versions are numbered in hexadecimal notation.)
Commands-I/O Settings (sub category designated within {brackets})
AT_ Command
Command_ Category
Name and Description
Parameter Range
Default
Manual Documentation Number: MDR3243A-807 21
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
D8 I/O Settings
DI8 Configuration. Select/Read options for the DI8 line (pin 9) of the RF module.
0 – 1 0 = Disabled 3 = DI (1,2,4 & 5 n/a)
0
D7 (v1.x80*) I/O Settings
DIO7 Configurat ion. Select/Read settings for the DIO7 line (pin 12) of the RF module. Options include CTS flow control and I/O line settings.
0 – 1 0 = Disabled 1 = CTS Flow Control 2 = (n/a) 3 = DI 4 = DO low 5 = DO high
1
D6 (v1.x80*) I/O Settings
DIO6 Configurat ion. Select/Read settings for the DIO6 line (pin 16) of the RF module. Options include RTS flow control and I/O line settings.
0 – 1 0 = Disabled 1 = RTS flow control 2 = (n/a) 3 = DI 4 = DO low 5 = DO high
0
D5 (v1.x80*) I/O Settings
DIO5 Configurat ion. Configure settings for the DIO5 line (pin 15) of the RF module. Options include Associated LED indicator (blinks when associated) and I/O line settings.
0 – 1 0 = Disabled 1 = Associated indicator 2 = ADC 3 = DI 4 = DO low 5 = DO high
1
D0 - D4 (v1.xA0*)
I/O Settings
(DIO4 -DIO4) Configuration. Select/Read settings for the following lines: AD0/DIO0 (pin
20), AD1/DIO1 (pin 19), AD2/DIO2 (pin 18), AD3/DIO3 (pin 17), AD4/DIO4 (pin 11). Options include: Anal og-to-digital converter, Digital Input and Digital Output.
0 – 1 0 = Disabled 1 = (n/a) 2 = ADC 3 = DI 4 = DO low 5 = DO high
0
IU (v1.xA0*) I/O Settings
I/O Output Enable.Disables/Enables I/O data
received to be sent out UART. The data is sent using an API frame regardless of the current AP parameter value.
0 – 1 0 = Disabled 1 = Enabled
1
IT (v1.xA0*) I/O Settings
Samples before TX.Set/Read the number of samples to collect before transmitting data. Maximum number of samples is dependent upon the number of enabled inputs.
1 - 0xFF 1
IS (v1.xA0*) I/O Settings
Force Sample.Force a read of all enabled inputs (DI or ADC). Data is returned through the UART. If no inputs are defined (DI or ADC), this command will return error.
8-bit bitmap (each bit represents the level of an I/O line setup as an output)
-
22 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
IO (v1.xA0*) I/O Settings
Digital Output Level.Set digital output level to allow DIO lines that are setup as outputs to be changed through Command Mode.
- -
IC (v1.xA0*) I/O Settings
DIO Change Detect.Enables/Disables the
monitoring of the change detect feature on DIO line s 0-7. If a change is detected, data is transmitted with DIO data only. Any samples queued and waiting for transmission will be sent first.
0 - 0xFF [bitfield]
0 (disabled)
IR (v1.xA0*) I/O Settings
Sample Rate. Set/Read sample rate. When set, this parameter causes the module to sample all enabled inputs at a specified interval.
0 -0xFFFF [x 1 msec]
0
AV (v1.xA0*) I/O Settings
ADC Voltage Reference. <XBee­PRO only> Set/Read ADC reference voltage switch.
0 – 1 0 = VREF pin 1 = Internal
0
IA (v1.xA0*)
I/O Settings {I/O Line Passing}
I/O Input Address. Set/Read addresses of module to which outputs are bound. Setting all bytes to 0xFF will not allow any received I/O packet to change outputs. Setting address to 0xFFFF will allow any received I/O packet to change outputs.
0 ­0xFFFFFFFFFFFF FFFF
0xFFFFFF F FFFFFFFF F
T0 - T7 (v1.xA0*)
I/O Settings {I/O Line Passing}
(D0 - D7) Output Timeout.
Set/Read Output timeout values for lines that correspond with the D0 - D7 parameters. When output is set (due to I/O line passing) to a non-default level, a timer is started which when expired will set the output to it default level. The timer is reset when a valid I/O packet is received.
0 - 0xFF [x 100 ms]
0xFF
P0
I/O Settings {I/O Line Passing}
PWM0 Configuration. Select/Read function for PWM0 pin.
0 – 2 0 = Disabled 1 = RSSI 2 = PWM Output
1
P1 (v1.xA0*)
I/O Settings {I/O Line Passing}
PWM1 Configuration. Select/Read function for PWM1 pin.
0 – 2 0 = Disabled 1 = RSSI 2 = PWM Output
0
M0 (v1.xA0*)
I/O Settings {I/O Line Passing}
PWM0 Output Level. Set/Read the PWM0 output level.
0 - 0x03FF -
M1 (v1.xA0*)
I/O Settings {I/O Line Passing}
PWM1 Output Level. Set/Read the PWM0 output level.
0 - 0x03FF -
PT (v1.xA0*)
I/O Settings {I/O Line Passing}
PWM Output Timeout. Set/Read output timeout value for both PWM outputs. When PWM is set to a non-zero value: Due to I / O
0 - 0xFF [x 100 ms]
0xFF
Manual Documentation Number: MDR3243A-807 23
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
line passing, a time is started which when expired will set the PWM output to zero. The timer is reset when a valid I/O packet is received.]
RP
I/O Settings {I/O Line Passing}
RSSI PWM Timer.Set/Read PWM timer register. Set the duration of PWM (pulse width modulation) signal output on the RSSI pin. The signal duty cycle is updated with each received packet and is shut off when the timer expires.]
0 - 0xFF [x 100 ms]
0x28 (40d)
*Firmware version in which the command was first introduced (firmware versions are numbered in hexadecimal notation.)
Commands-Diagnostics
AT_ Command
Command_ Category
Name and Description
Parameter Range
Default
VR Diagnostics
Firmware Version. Read firmware version of the RF module.
0 - 0xFFFF [read-only]
Factory-set
VL (v1.x80*) Diagnostics
Firmware Version - Verbose. Read detailed version in formation (including application build date, MAC, PHY and bootloader versions).
- -
HV (v1.x80*) Diagnostics
Hardware Version. Read hardware version of the RF module.
0 - 0xFFFF [read-only]
Factory-set
DB Diagnostics
Received Signal Strength. Read signal level [in dB] of last good packet received (RSSI). Absolute value is reported. (For example: 0x58 = -88 dBm) Reported val ue is accurate between -40 dBm and RX sensitivity.
0 - 0x64 [read-only]
-
EC (v1.x80*) Diagnostics
CCA Failures.Reset/Read count of CCA (Clear Channel Assessment) failures. This parameter value increments when the module does not transmit a packet because it detected energy above the CCA threshold level set with CA command. This count saturates at its maximum value. Set count to “0” to reset count.
0 - 0xFFFF -
EA (v1.x80*) Diagnostics
ACK Failures. Reset/Read count of acknowledgment failures. This parameter value increments when the module expires its transmission retries without receiving an ACK on a packet transmission. This count saturates at its maximum value. Set the parameter to “0” to reset count.
0 - 0xFFFF -
24 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
ED (v1.x80*) Diagnostics
Energy Scan. Send ‘Energy Detect Scan’. ED parameter determines the lengt h of scan on each channel. The maximal energy on each channel is ret urned and each value is followed by a carriage return. Values returned represent detected energy levels in units of -dBm. Actual s c an time on each channel is measured as Time = [(2 ^ SD) * 15.36] ms. Total scan time is this time multiplied by the number of channels to be scanned.
0 - 6 -
*Firmware version in which the command was first introduced (firmware versions are numbered in hexadecimal notation.)
Commands-AT Command Options
AT_ Command
Command_ Category
Name and Description
Parameter Range
Default
CT
AT Command Mode Options
Command Mode Timeout.Set/Read the period of
inactivity (no valid commands received) after which the RF module automatically exits AT Command Mode and returns to Idle Mode.
2 - 0xFFFF [x 100 ms]
0x64 (100d)
CN
AT Command Mode Options
Exit Command Mode. Explicitly exit the module from AT Command Mode.
-- --
AC (v1.xA0*)
AT Command Mode Options
Apply Changes. Explicitly apply changes to queued parameter value(s) and re-initialize module.
-- --
GT
AT Command Mode Options
Guard Times. Set required period of silence before an d after the Command Sequence Characters of the AT Command Mode Sequence (GT+ CC + GT). The period of silence is used to prevent inadvertent entrance into AT Command Mode.
2 - 0x0CE4 [x 1 ms]
0x3E8 (1000d)
CC
AT Command Mode Options
Command Sequence Character. Set/Read the ASCII character value to be used between Guard Times of the AT Command Mode Sequence (GT+CC+GT). The AT Command Mode Sequence enters the RF module into AT Command Mode.
0 - 0xFF
0x2B (‘+’ ASCII)
*Firmware version in which the command was first introduced (firmware versions are numbered in hexadecimal notation.)
Manual Documentation Number: MDR3243A-807 25
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
Command Descriptions
Command descriptions in this section are listed alphabetically. Command categories are designated within "< >" symbols that follow each command title. XBee/XBee-PRO RF Modules expect parameter values in hexadecimal (designated by the "0x" prefix). All modules operating within the same network should contain the same firmware version.
A1 (End Device Association) Command
<Networking {Association}> The A1 command is used to set and read association options for an End Device.
Use the table below to determine End Device behavior in relation to the A1 parameter.
A2 (Coordinator Association) Command
<Networking {Association}> The A2 command is used to set and read association options of the Coordinator.
Use the table below to determine Coordinator behavior in relation to the A2 parameter.
AT Command: ATA1 Parameter Range: 0 - 0x0F [bitfield] Default Parameter Value: 0 Related Commands: ID (PAN ID), NI
(Node Identifier), CH (Channel), CE (Coordinator Enable), A2 (Coordinator Association) Minimum Firmware Version Required: v1.x80
Bit number End Device Association Option
0 - Will only associate with Coordinator operating on PAN ID that matches Node Identifier
0 - ReassignPanID
1 - May associate with Coordinator operating on any PAN ID 0 - Will only associate with Coordinator operating on Channel that matches CH setting
1 - ReassignChannel
1 - May associate with Coordinator operating on any Channel 0 - Device will not attempt Association
2 - AutoAssociate
1 - Device attempts Association until success_ Note: This bit is used only for Non­Beacon systems. End Devices in a Beaconing system must always associate to a Coordinator
0 - Pin Wake will not poll the Coordinator for pending (indirect) Data
3 ­PollCoordOnPinWake
1 - Pin Wake will send Poll Request to Coordinator to extract any pending data
4 - 7 [reserved]
AT Command: ATA2 Parameter Range: 0 - 7 [bitfield] Default Parameter Value: 0 Related Commands: ID (PAN ID),
NI (Node Identifier), CH (Channel), CE (Coordinator E nable), A1 (End Device Association), AS Active Scan), ED (Energy Scan) Minimum Firmware Version Required: v1.x80
26 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
Bit number End Devi ce Asso ciation Option
0 - Coordinator will not perform Active Scan to locate available PAN ID. It will operate on ID (PAN ID).
0 ­ReassignPanID
1 - Coordinator will perform Active Scan to determine an available ID (PAN ID). If a PAN ID conflict is found, the ID parameter will change.
0 - Coordinator will no t perform Energy Scan to determine free channel. It will operate on the channel determined by the CH parameter.
1 ­ReassignChannel
1 - Coordinator will perform Energy Scan to find a free channel, then operate on that channel.
0 - Coordinator will not allow any devices to associate to it.
2 -AllowAssociate
1 - Coordinator will allow devices to associate to it.
3 - 7 [reser v ed]
AC (Apply Changes) Command
<AT Command Mode Options> The AC command is used to explicitly apply changes to module parameter values. ‘Applying changes’ means that the module is re-initialized based on changes made to its parameter values. Once changes are applied, the module immediately operates according to the new parameter values.
This behavior is in contrast to issuing the WR (Write) command. The WR command saves parameter values to non-volatile memory, but the module still operates according to previously saved values until the module is re-booted or the CN (Exit AT Command Mode) command is issued.
Refer to the “AT Command - Queue Parameter Value” API type for more information.
AI (Association Indication) Command
<Networking {Association}> The AI command is used to indicate occurrences of errors during the last association request.
Use the table below to determine meaning of the returned values.
AT Command: ATAC Minimum Firmware Version
Required: v1.xA0
AT Command: ATAI Parameter Range: 0 - 0x13 [read-only] Related Commands: AS (Active Scan), ID (PAN ID), CH (Channel), ED (Energy Scan), A1 (End Device Association), A2 (Coordinator Association), CE (Coordinator Enable) Minimum Firmware Version Required: v1.x80
Manual Documentation Number: MDR3243A-807 27
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
Returned Value (Hex)
Association Indication
0x00
Successful Completion - Coordinator successfully started or End Device association
complete 0x01 Active Scan Timeout 0x02 Active Scan found no PANs 0x03 Active Scan found PAN, but the Coordinator Allow Association bit is not set
0x04
Active Scan found PAN, but Coordinator and End Device are not configured to support
beacons 0x05
Active Scan found PAN, but Coordinator ID (PAN ID) value does not match the ID of the End
Device 0x06
Active Scan found PAN, but Coordinator CH (Channel) value does not match the CH of the
End Device 0x07 Energy Scan Timeout 0x08 Coordinator start request failed 0x09 Coordinator could not start due to Invalid Parameter 0x0A Coordinator Realignment is in progres s 0x0B Association Request not sent 0x0C Association Request timed out - no reply was received 0x0D Association Request had an I nvalid Parameter 0x0E Association Request Channel Access Failure - Request was not transmitted - CCA failure 0x0F Remote Coordinator did not send an ACK after Association Request was sent
0x10
Remote Coordinator did not reply to the Association Request, but an ACK was received _
after sending the request 0x11 [reserved] 0x12 Sync-Loss - Lost synchronization with a Beaconing Coordinator 0x13 Disassociated - No longer associated to Coordinator
AP (API Enable) Command
<Serial Interfacing> The AP command is used to enable the RF module to operate using a framebased API instead of using the default Transparent (UART) mode.
Refer to the API Operation section when API operation is enabled (AP = 1 or 2).
AT Command: ATAP Parameter Range:0 - 2 Parameter Configuration
0
Disabled (Transparent operation)
1 API enabled 2
API enabled (with escaped characters)
Default Parameter Value:0 Minimum Firmware Version Required:
v1.x80
28 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
AS (Active Scan) Command
<AT Command Mode Options> The AS command is used to send a Beacon Request to a Broadcast Address (0xFFFF) and Broadcast PAN (0xFFFF) on every channel. The parameter determines the amount of time the RF module will listen for Beacons on each channel. A ‘PanDescriptor’ is created and returned for every Beacon received from the scan. Each PanDescriptor contains the following information:
CoordAddress (SH + SL parameters)<CR> CoordPanID (ID parameter)<CR> CoordAddrMode <CR> 0x02 = 16-bit Short Address 0x03 = 64-bit Long Address Channel (CH parameter) <CR> SecurityUse<CR> ACLEntry<CR> SecurityFailure<CR> SuperFrameSpec<CR> (2 bytes): bit 15 - Association Permitted (MSB) bit 14 - PAN Coordinator bit 13 - Reserved bit 12 - Battery Life Extension bits 8-11 - Final CAP Slot bits 4-7 - Superframe Order bits 0-3 - Beacon Order GtsPermit<CR> RSSI<CR> (- RSSI is returned as -dBm) TimeStamp<CR> (3 bytes) <CR> (A carriage return <CR> is sent at the end of the AS command.
The Active Scan is capable of returning up to 5 PanDescriptors in a scan. The actual scan time on each channel is measured as Time = [(2 ^ (SD Parameter)) * 15.36] ms. Total scan time is this time multiplied by the number of channels to be scanned (16 for the XBee, 12 for the XBee-PRO).
NOTE: Refer the scan table in the SD description to determine scan times. If using API Mode, no <CR>’s are returned in the response. Refer to the API Mode Operation section.
AT Command: ATAS Parameter Range: 0 - 6 Related Command: SD (Scan
Duration), DL (Destination Low Address), DH (Destination High Address), ID (PAN ID), CH (Channel) Minimum Firmware Version Required: v1.x80
Manual Documentation Number: MDR3243A-807 29
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
AV (ADC Voltage Reference) Command
<Serial Interfacing> The AV command is used to set/read the ADC reference voltage switch. The XBee-PRO has an ADC voltage reference switch which allows the module to select between an onboard voltage reference or to use the VREF pin on the connector.
This command only applies to XBee-PRO RF Modules and will return error on an XBee RF Module.
BD (Interface Data Rate) Command
<Serial Interfacing> The BD command is used to set and read the serial interface data rate usedbetween the RF module and host. This parameterdetermines the rate at which serial data is sent to the module from the host. Modified interface data rates do not take effect until the CN (Exit AT Command Mode) command is issued and the system returns the 'OK' response.
When parameters 0-7 are sent to the module, the respective interface data rates are used (as shown in the table on the right).
The RF data rate is not affected by the BD parameter. If the interface data rate is set higher than the RF data rate, a flow control configuration may need to be implemented.
Non-standard Interface Data Rates: Any value above 0x07 will be interpreted as an actual baud rate. When a value above 0x07 is sent, the closest interface data rate represented by the number is stored in the BD register. For example, a rate of 19200 bps can be set by sending the following command line "ATBD4B00". NOTE: When using BLACK BOX’s WIRELESS DATA EXTENDERS Software, non-standard interface data rates can only be set and read using the WIRELESS DATA EXTENDERS ‘Terminal’ tab. Non-standard rates are not accessible through the ‘Modem Configuration’ tab.
When the BD command is sent with a non-standard interface data rate, the UART will adjust to accommodate the requested interface rate. In most cases, the clock resolution will cause the stored BD parameter to vary from the parameter that was sent (refer to the table below). Reading the BD command (send "ATBD" command without an associated parameter value) will return the value actually stored in the module’s BD register.
Parameters Sent Versus Parameters Stored BD Parameter Sent
(HEX)
Interface Data Rate (bps)
BD Parameter Stored (HEX)
AT Command: ATAV Parameter Range:0 - 1
Parameter Configuration
0 VREF Pin
1
Internal (on­board reference
- VCC) Default Parameter Value:0 Minimum Firmware Version
Required: v1.xA0
AT Command: ATBD Parameter Range:0 - 7 (standard rates)_ 0x80-0x1C200 (non­stndard rates)
Parameter Configuration (bps)
0 1200 1 2400 2 4800 3 9600 4 19200 5 38400 6 57600 7 115200
Default Parameter Value:3
30 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
0 1200 0 4 19,200 4 7 115,200 7
12C 300 12B
1C200 115,200 1B207
CA (CCA Threshold) Command
<RF Interfacing> CA command is used to set and read CCA (Clear Channel Assessment) thresholds.
Prior to transmitting a packet, a CCA is performed to detect energy on the transmit channel. If the detected energy is above the CCA Threshold, the RF module will not transmit the packet.
CC (Command Sequence Character) Command
<AT Command Mode Options> The CC command is used to set and read the ASCII character used
between guard times of the AT Command Mode Sequence (GT + CC + GT). This sequence enters the RF module into AT Command Mode so that data entering the module from the host is recognized as commands instead of payload.
The AT Command Sequence is explained further in the AT Command Mode section.
CE (Coordinator Enable) Command
<Serial Interfacing> The CE command is used to set and read the behavior (End Device vs. Coordinator) of the RF module.
AT Command: ATCA Parameter Range: 0 - 0x50 [-
dBm] Default Parameter Value: 0x2C
(-44 decimal dBm) Minimum Firmware Version
Required: v1.x80
AT Command: ATCC Parameter Range: 0 - 0xFF Default Parameter Value: 0x2B (ASCII
“+”) Related Command: GT (Guard Times)
AT Command: ATCE Parameter Range:0 - 1
Parameter Configuration
0 End Device 1 Coordinator
Default Parameter Value:0 Minimum Firmware Version Required:
v1.x80
Manual Documentation Number: MDR3243A-807 31
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
CH (Channel) Command
<Networking {Addressing}> The CH command is used to set/read the operating channel on which RF connections are made between RF modules. The channel is one of three addressing options available to the module. The other options are the PAN ID (ID command) and destination addresses (DL & DH commands).
In order for modules to communicate with each other, the modules must share the same channel number. Different channels can be used to prevent modules in one network from listening to transmissions of another. Adjacent channel rejection is 23 dB.
The module uses channel numbers of the 802.15.4 standard. Center Frequency = 2.405 + (CH - 11d) * 5 MHz (d = decimal)
CN (Exit Command Mode) Command
<AT Command Mode Options> The CN command is used to explicitly exit the RF module from AT Command Mode.
CT (Command Mode Timeout) Command
<AT Command Mode Options> The CT command is used to set and read the amount of inactive time that elapses before the RF module automatically exits from AT Command Mode and returns to Idle Mode.
Use the CN (Exit Command Mode) command to exit AT Command Mode manually.
AT Command: ATCH Parameter Range: 0x0B - 0x1A
(XBee)0x0C - 0x17 (XBee­PRO) Default Parameter Value: 0x0C (12 decimal) Related Commands: ID (PAN ID), DL (Destination Address Low, DH (Destination Address High)
AT Command: ATCN
AT Command: ATCT Parameter Range:2 - 0xFFFF [x 100
milliseconds] Default Parameter Value: 0x64 (100
decimal (which equals 10 decimal seconds))
Number of bytes returned: 2 Related Command: CN (Exit
Command Mode)
32 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
D0 - D4 (DIOn Configuration) Commands
<I/O Settings> The D0, D1, D2, D3 and D4 commands are used to select/read the behavior of their respective AD/DIO lines (pins 20, 19, 18, 17 and 11 respectively). Options include:
• Analog-to-digital converter
• Digital input
• Digital output
D5 (DIO5 Configuration) Command
<I/O Settings> The D5 command is used to select/read the behavior of the DIO5 line (pin 15). Options include:
• Associated Indicator (LED blinks when the module is associated)
• Analog-to-digital converter
• Digital input
• Digital output
AT Commands: _ ATD0, ATD1, ATD2, ATD3, ATD4
Parameter Range:0 - 5
Parameter Configuration
0 Disabled 1 n/a 2 ADC 3 DI 4 DO low 5 DO high
Default Parameter Value:0 Minimum Firmware Version
Required: 1.x.A0
AT Command: ATD5 Parameter Range:0 - 5
Parameter Configuration
0 Disabled 1
Associated
Indicator
2 ADC 3 DI 4 DO low
5 DO high Default Parameter Value:1 Parameters 2-5 supported as of
firmware version 1.xA0
Manual Documentation Number: MDR3243A-807 33
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
D6 (DIO6 Configuration) Command
<I/O Settings> The D6 command is used to select/read the behavior of the DIO6 line (pin 16). Options include:
• RTS flow control
• Analog-to-digital
converter
• Digital input
• Digital output
D7 (DIO7 Configuration) Command
<I/O Settings> The D7 command is used to select/read the behavior of the DIO7 line (pin 12). Options include:
• CTS flow control
• Analog-to-digital converter
• Digital input
• Digital output
D8 (DI8 Configuration) Command
<I/O Settings> The D8 command is used to select/read the behavior of the DI8 line (pin 9). This command enables configuring the pin to function as a digital input. This line is also used with Pin Sleep.
AT Command: ATD6 Parameter Range:0 - 5
Parameter Configuration 0 Disabled 1 RTS Flow Control 2 n/a 3 DI 4 DO low 5 DO high
Default Parameter Value:0 Parameters 3-5 supported as of firmware
version 1.xA0
AT Command: ATD7 Parameter Range:0 - 5
Parameter Configuration
0 Disabled 1 CTS Flow Control 2 n/a 3 DI 4 DO low
5 DO high Default Parameter Value:1 Parameters 3-5 supported as of firmware version
1.x.A0
AT Command: ATD8 Parameter Range:0 - 5 _ (1, 2, 4 & 5 n/a)
Parameter Configuration 0 Disabled 3 DI
Default Parameter Value:0 Minimum Firmware Version Required: 1.xA0
34 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
DA (Force Disassociation) Command
<(Special)> The DA command is used to immediately disassociate an End Device from a Coordinator and reattempt to associate.
DB (Received Signal Strength) Command
<Diagnostics> DB parameter is used to read the received signal strength (in dBm) of the last RF packet received. Reported values are accurate between -40 dBm and the RF module's receiver sensitivity.
Absolute values are reported. For example: 0x58 = -88 dBm (decimal). If no packets have been received (since last reset, power cycle or sleep event), “0” will be reported.
DH (Destination Address High) Command
<Networking {Addressing}> The DH command is used to set and read the upper 32 bits of the RF module's 64-bit destination address. When combined with the DL (Destination Address Low) parameter, it defines the destination address used for transmission.
An module will only communicate with other modules having the same channel (CH parameter), PAN ID (ID parameter) and destination address (DH + DL parameters).
To transmit using a 16-bit address, set the DH parameter to zero and the DL parameter less than 0xFFFF. 0x000000000000FFFF (DL concatenated to DH) is the broadcast address for the PAN.
Refer to the XBee/XBee-PRO Addressing section for more information.
DL (Destination Address Low) Command
<Networking {Addressing}> The DL command is used to set and read the lower 32 bits of the RF module's 64-bit destination address. When combined with the DH (Destination Address High) parameter, it defines the destination address used for transmission.
A module will only communicate with other modules having the same channel (CH parameter), PAN ID (ID parameter) and destination address (DH + DL parameters).
To transmit using a 16-bit address, set the DH parameter to zero and the DL parameter less than 0xFFFF. 0x000000000000FFFF (DL concatenated to DH) is the
AT Command: ATDA Minimum Firmware Version Required: v1.x80
AT Command: ATDB Parameter Range: 0 - 0x64 [read-only]
AT Command: ATDH Parameter Range: 0 - 0xFFFFFFFF Default Parameter Value: 0
Related Commands: DL (Destination Address Low), CH (Channel), ID (PAN VID), MY (Source Address)
AT Command: ATDL Parameter Range: 0 - 0xFFFFFFFF Default Parameter Value: 0
Related Commands: DH (Destination Address High), CH (Channel), ID (PAN VID), MY (Source Address)
Manual Documentation Number: MDR3243A-807 35
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
broadcast address for the PAN. Refer to the XBee/XBee-PRO Addressing section for more information.
DN (Destination Node) Command
<Networking {Identification}> The DN command is used to resolve a NI (Node Identifier) string to a physical address. The following events occur upon successful command execution:
1. DL and DH are set to the address of the module with the matching NI (Node Identifier).
2. ‘OK’ is returned.
3. RF module automatically exits AT Command Mode. If there is no response from a modem within 200 msec or a parameter is not specified
(left blank), the command is terminated and an ‘ERROR’ message is returned.
DP (Disassociation Cyclic Sleep Period) Command
<Sleep Mode (Low Power)>
NonBeacon Firmware
End Device - The DP command is used to set and read the time period of sleep for cyclic sleeping remotes that are configured for Association but are not associated to a Coordinator. (i.e. If a device is configured to associate, configured as a Cyclic Sleep remote, but does not find a Coordinator; it will sleep for DP time before reattempting association.) Maximum sleep period is 268 seconds (0x68B0). DP should be > 0 for NonBeacon systems.
EA (ACK Failures) Co mm an d
<Diagnostics> The EA command is used to reset and read the count of ACK (acknowledgement) failures. This parameter value increments when the module expires its transmission retries without receiving an ACK on a packet transmission. This count saturates at its maximum value.
Set the parameter to “0” to reset count.
EC (CCA Failures) Command
<Diagnostics> The EC command is used to read and reset the count of CCA (Clear Channel Assessment) failures. This parameter value increments when the RF module does not transmit a packet due to the detection of
AT Command: ATDN Parameter Range: 20-character ASCII String Minimum Firmware Version Required: v1.x80
AT Command: ATDP Parameter Range: 1 - 0x68B0 _ [x 10
milliseconds]
Default Parameter Value:0x3E8_ (1000 decimal)
Related Commands: SM (Sleep Mode), SP (Cyclic Sleep Period), ST (Time before Sleep)
Minimum Firmware Version Required: v1.x80
AT Command: ATEA Parameter Range:0 - 0xFFFF Minimum Firmware Version Required: v1.x80
AT Command: ATEC Parameter Range:0 - 0xFFFF Related Command: CA (CCA Threshold) Minimum Firmware Version Required: v1.x80
36 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
energy that is above the CCA threshold level (set with CA command). This count saturates at its maximum value. Set the EC parameter to “0” to reset count.
ED (Energy Scan) Command
<Networking {Association}> The ED command is used to send an “Energy Detect Scan”. This parameter determines the length of scan on each channel. The maximal energy on each channel is returned and each value is followed by a carriage return. An additional carriage return is sent at the end of the command.
The values returned represent the detected energy level in units of -dBm. The actual scan time on each channel is measured as Time = [(2 ^ ED PARAM) * 15.36] ms.
Note: Total scan time is this time multiplied by the number of channels to be scanned. Also refer to the SD (Scan Duration) table. Use the SC (Scan Channel) command to choose which channels to scan.
EE (AES Encryption Enable) Command
<Networking {Security}> The EE command is used to set/read the parameter that disables/enables 128-bit AES encryption.
The Wireless data extenders firmware uses the 802.15.4 Default Security protocol and uses AES encryption with a 128-bit key. AES encryption dictates that all modules in the network use the same key and the maximum RF packet size is 95 Bytes.
When encryption is enabled, the module will always use its 64-bit long address as the source address for RF packets. This does not affect how the MY (Source Address), DH (Destination Address High) and DL (Destination Address Low) parameters work
If MM (MAC Mode) > 0 and AP (API Enable) parameter > 0: With encryption enabled and a 16-bit short address set, receiving modules will only be able to issue RX (Receive) 64-bit indicators. This is not an issue when MM = 0.
If a module with a non-matching key detects RF data, but has an incorrect key: When encryption is enabled, non-encrypted RF packets received will be rejected and will not be sent out the UART.
Transparent Operation --> All RF packets are sent encrypted if the key is set.
AT Command: ATED Parameter Range:0 - 6 Related Command: SD (Scan Duration), SC
(Scan Channel) Minimum Firmware Version Required: v1.x80
AT Command: ATEE Parameter Range:0 - 1
Parameter Configuration 0 Disabled 1 Enabled
Default Parameter Value:0 Related Commands: KY (Encryption Key), AP
(API Enable), MM (MAC Mode) Minimum Firmware Version Required: v1.xA0
Manual Documentation Number: MDR3243A-807 37
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
API Operation --> Receive frames use an option bit to indicate that the packet was encrypted.
FP (Force Poll) Command
<Networking (Association)> The FP command is used to request indirect messages being held by a Coordinator.
FR (Software Reset) Command
<Special> The FR command is used to force a software reset on the RF module. The reset simulates powering off and then on again the module.
GT (Guard Times) Command
<AT Command Mode Options> GT Command is used to set the DI (data in from host) time-of-silence that surrounds the AT command sequence character (CC Command) of the AT Command Mode sequence (GT + CC + GT).
The DI time-of-silence is used to prevent inadvertent entrance into AT Command Mode.
Refer to the Command Mode section for more information regarding the AT Command Mode Sequence.
HV (Hardware Version) Command
<Diagnostics> The HV command is used to read the hardware version of the RF module.
IA (I/O Input Address) Command
<I/O Settings {I/O Line Passing}> The IA command is used to bind a module output to a specific address. Outputs will only change if received from this address. The IA command can be used to set/read both 16 and 64-bit addresses.
Setting all bytes to 0xFF will not allow the reception of any I/O packet to change outputs. Setting the IA address to 0xFFFF will cause the module to accept all I/O packets.
AT Command: ATFP Minimum Firmware Version Required: v1.x80
AT Command: ATFR Minimum Firmware Version Required: v1.x80
AT Command: ATGT Parameter Range:2 - 0x0CE4 [x 1 millisecond]
Default Parameter Value:0x3E8 _ (1000 decimal)
Related Command: CC (Command Sequence Character)
AT Command: ATHV Parameter Range:0 - 0xFFFF [Read-only] Minimum Firmware Version Required: v1.x80
AT Command: ATIA Parameter Range:0 - 0xFFFFFFFFFFFFFFFF
Default Parameter Value:0xFFFFFFFFFFFFFFFF_ (will not allow any received I/O packet to change outputs)
Minimum Firmware Version Required: v1.xA0
38 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
IC (DIO Change Detect) Command
<I/O Settings> The IC command is used to enable the monitoring of the change detect feature on DIO lines 0-7. If a change is detected, data is transmitted with DIO data only. Any samples queued and waiting for transmission are sent first.
Refer to the “ADC and Digital I/O Line Support” sections of the “RF Module Operations” chapter for more information.
ID (Pan ID) Command
<Networking {Addressing}> The ID command is used to set and read the PAN (Personal Area Network) ID of the RF module. Only modules with matching PAN IDs can communicate with each other. Unique PAN IDs enable control of which RF packets are received by a module.
Setting the ID parameter to 0xFFFF indicates a global transmission for all PANs. It does not indicate a global receive.
IO (Digital Output Level) Command
<I/O Settings> The IO command is used to set digital output levels. This allows DIO lines setup as outputs to be changed through Command Mode.
IR (Sample Rate) Command
<I/O Settings> The IR command is used to set/read the sample rate. When set, the module will sample all enabled DIO/ADC lines at a specified interval. This command allows periodic reads of the ADC and DIO lines in a non-Sleep Mode setup.
Example: When IR = 0x0A, the sample rate is 10 ms (or 100 Hz).
AT Command: ATIC Parameter Range:0 - 0xFF [bitfield] Default Parameter Value:0 (disabled) Minimum Firmware Version Required: 1.xA0
AT Command: ATID Parameter Range: 0 - 0xFFFF
Default Parameter Value:0x3332 (13106 decimal)
AT Command: ATIO Parameter Range: 8-bit bitmap _
(where each bit represents the level of an I/O line that is setup as an output.)
Minimum Firmware Version Required: v1.xA0
AT Command: ATIR Parameter Range: 0 - 0xFFFF [x 1 msec]_ (cannot
guarantee 1 ms timing when IT=1) Default Parameter Value:0 Related Command: IT (Samples before TX) Minimum Firmware Version Required: v1.xA0
Manual Documentation Number: MDR3243A-807 39
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
IS (Force Sample) Command
<I/O Settings> The IS command is used to force a read of all enabled DIO/ADC lines. The data is returned through the UART. When operating in Transparent Mode (AP=0), the data is retuned in the following format:
All bytes are converted to ASCII: number of samples<CR> channel mask<CR> DIO data<CR> (If DIO lines are enabled<CR> ADC channel Data<cr> <-This will repeat for every enabled ADC channel<CR> <CR> (end of data noted by extra <CR>)
When operating in API mode (AP > 0), the command will immediately return an ‘OK’ response. The data will follow in the normal API format for DIO data.
IT (Samples before TX) Command
<I/O Settings> The IT command is used to set/read the number of DIO and ADC samples to collect before transmitting data.
One ADC sample is considered complete when all enabled ADC channels have been read. The module can buffer up to 93 Bytes of sample data. Since the module uses a 10-bit A/D converter, each sample uses two Bytes. This leads to a maximum buffer size of 46 samples or IT=0x2E.
When Sleep Modes are enabled and IR (Sample Rate) is set, the module will remain awake until IT samples have been collected.
IU (I/O Output Enable) Command
<I/O Settings> The IU command is used to disable/enable I/O UART output. When enabled (IU = 1), received I/O line data packets are sent out the UART. The data is sent using an API frame regardless of the current AP parameter value.
AT Command: ATIS Parameter Range: 1 - 0xFF Default Parameter Value:1 Minimum Firmware Version Required: v1.xA0
AT Command: ATIT Parameter Range: 1 - 0xFF Default Parameter Value:1 Minimum Firmware Version Required: v1.xA0
AT Command: ATIU Parameter Range:0 - 1
Parameter Configuration
0
Disabled -Received I/O
line data packets will NOT sent out UART.
1
Enabled -Received I/O
line data will be sent out
UART Default Parameter Value:1 Minimum Firmware Version Required: 1.xA0
40 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
KY (AES Encryption Key) Command
<Networking {Security}> The KY command is used to set the 128­bit AES (Advanced Encryption Standard) key for encrypting/decrypting data. Once set, the key cannot be read out of the module by any means.
The entire payload of the packet is encrypted using the key and the CRC is computed across the ciphertext. When encryption is enabled, each packet carries an additional 16 Bytes to convey the random CBC Initialization Vector (IV) to the receiver(s). The KY value may be “0” or any 128-bit value. Any other value, including entering ATKY by itself with no parameters, will cause an error. A module with the wrong key (or no key) will receive encrypted data, but the data driven out the serial port will be meaningless. Likewise, a module with a key will receive unencrypted data sent from a module without a key, but the output will be meaningless. Because CBC mode is utilized, repetitive data appears differently in different transmissions due to the randomly-generated IV.
When queried, the system will return an ‘OK’ message and the value of the key will not be returned.
M0 (PWM0 Output Level) Command
<I/O Settings> The M0 command is used to set/read the output level of the PWM0 line (pin 6).
Before setting the line as an output:
1. Enable PWM0 output (P0 = 2)
2. Apply settings (use CN or AC) The PWM period is 64 µsec and there are 0x03FF (1023 decimal) steps within this
period. When M0 = 0 (0% PWM), 0x01FF (50% PWM), 0x03FF (100% PWM), etc.
M1 (PWM1 Output Level) Command
<I/O Settings> The M1 command is used to set/read the output level of the PWM1 line (pin 7).
Before setting the line as an output:
1. Enable PWM1 output (P1 = 2)
2. Apply settings (use CN or AC)
AT Command: ATKY Parameter Range:0 - (any 16-Byte value) Default Parameter Value:0 Related Command: EE (Encryption Enable) Minimum Firmware Version Required: v1.xA0
AT Command: ATM0 Parameter Range:0 - 0x03FF [steps] Default Parameter Value:0
Related Commands: P0 (PWM0 Enable), AC (Apply Changes), CN (Exit Command Mode)
Minimum Firmware Version Required: v1.xA0
AT Command: ATM1 Parameter Range:0 - 0x03FF Default Parameter Value:0
Related Commands: P1 (PWM1 Enable), AC (Apply Changes), CN (Exit Command Mode)
Minimum Firmware Version Required: v1.xA0
Manual Documentation Number: MDR3243A-807 41
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
MM (MAC Mode) Command
<Networking {Addressing}> The MM command is used to set and read the MAC Mode value. The MM command disables/enables the use of a Max-Stream header contained in the 802.15.4 RF packet. By default (MM = 0), BLACK BOX Mode is enabled and the module adds an extra header to the data portion of the 802.15.4 packet. This enables the following features:
• ND and DN command support
• Duplicate packet detection when using ACKs The MM command allows users to turn off the use of the extra header. Modes 1 and 2 are strict 802.15.4 modes. If the BLACK BOX header is disabled, ND and DN parameters are also disabled.
Note: When MM > 0, application and CCA failure retries are not supported.
MY (16-bit Source Address) Command
<Networking {Addressing}> The MY command is used to set and read the 16-bit source address of the RF module.
By setting MY to 0xFFFF, the reception of RF packets having a 16-bit address is disabled. The 64-bit address is the module’s serial number and is always enabled.
AT Command: ATMM Parameter Range:0 - 2
Parameter Configuration
0
BLACK BOX Mode (802.15.4 + BLACK
BOX header) 1 802.15.4 (no ACKs) 2 802.15.4 (with ACKs)
Default Parameter Value:0 Related Commands: ND (Node Discover), DN
(Destination Node) Minimum Firmware Version Required: v1.x80
AT Command: ATMY Parameter Range: 0 - 0xFFFF Default Parameter Value: 0
Related Commands: DH (Destination Address High), DL (Destination Address Low), CH (Channel), ID (PAN ID)
42 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
ND (Node Discover) Command
<Networking {Identification}> The ND command is used to discover and report all modules on its current operating channel (CH parameter) and PAN ID (ID parameter). ND also accepts an NI (Node Identifier) value as a parameter. In this case, only a module matching the supplied identifier will respond.
ND uses a 64-bit long address when sending and responding to an ND request. The ND command causes a module to transmit a globally addressed ND command packet. The amount of time allowed for responses is determined by the NT (Node Discover Time) parameter.
In AT Command mode, command completion is designated by a carriage return (0x0D). Since two carriage returns end a command response, the application will receive three carriage returns at the end of the command. If no responses are received, the application should only receive one carriage return. When in API mode, the application should receive a frame (with no data) and status (set to ‘OK’) at the end of the command. When the ND command packet is received, the remote sets up a random time delay (up to 2.2 sec) before replying as follows:
Node Discover Response (AT command mode format - Transparent operation): MY (Source Address) value<CR> SH (Serial Number High) value<CR> SL (Serial Number Low) value<CR> DB (Received Signal Strength) value<CR> NI (Node Identifier) value<CR> <CR> (This is part of the response and not the end of command indicator.)
Node Discover Response (API format - data is binary (except for NI)): 2 bytes for MY (Source Address) value 4 bytes for SH (Serial Number High) value 4 bytes for SL (Serial Number Low) value 1 byte for DB (Received Signal Strength) value NULL-terminated string for NI (Node Identifier) value (max 20 bytes w/out NULL terminator)
NI (Node Identifier) Command
<Networking {Identification}> The NI command is used to set and read a string for identifying a particular node.
Rules:
• Register only accepts printable ASCII data.
• A string can not start with a space.
• A carriage return ends command
AT Command: ATND Range: optional 20-character NI value Related Commands: CH (Channel), ID (Pan ID),
MY (Source Address), SH (Serial Number High), SL (Serial Number Low), NI (Node Identifier), NT (Node Discover Time)
Minimum Firmware Version Required: v1.x80
AT Command: ATNI Parameter Range: 20-character ASCII string
Related Commands: ND (Node Discover), DN (Destination Node)
Minimum Firmware Version Required: v1.x80
Manual Documentation Number: MDR3243A-807 43
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
• Command will automatically end when maximum bytes for the string have been entered.
This string is returned as part of the ND (Node Discover) command. This identifier is also used with the DN (Destination Node) command.
NT (Node Discover Time) Command
<Networking {Identification}> The NT command is used to set the amount of time a base node will wait for responses from other nodes when using the ND (Node Discover) command. The NT value is transmitted with the ND command.
Remote nodes will set up a random hold-off time based on this time. The remotes will adjust this time down by 250 ms to give each node the ability to respond before the base ends the command. Once the ND command has ended, any response received on the base would be discarded.
P0 (PWM0 Configuration) Command
<I/O Setting {I/O Line Passing}> The P0 command is used to select/read the function for PWM0 (Pulse Width Modulation output 0). This command enables the option of translating incoming data to a PWM so that the output can be translated back into analog form.
With the IA (I/O Input Address) parameter correctly set, AD0 values can automatically be passed to PWM0.
P1 (PWM1 Configuration) Command
<I/O Setting {I/O Line Passing}> The P1 command is used to select/read the function for PWM1 (Pulse Width Modulation output 1). This command enables the option of translating incoming data to a PWM so that the output can be translated back into analog form.
With the IA (I/O Input Address) parameter correctly set, AD1 values can automatically be passed to PWM1.
AT Command: ATNT Parameter Range: 0x01 - 0xFC
[x 100 msec] Default: 0x19 (2.5 decimal seconds) Related Commands: ND (Node Discover) Minimum Firmware Version Required: 1.xA0
AT Command: ATP0_ The second character in the command is the number zero (“0”), not the letter “O”.
Parameter Range: 0 - 2
Parameter Configuration
0 Disabled 1 RSSI 2 PWM0 Output
Default Parameter Value: 1
AT Command: ATP1 Parameter Range: 0 - 2
Parameter Configuration 0 Disabled 1 RSSI 2 PWM1 Output
Default Parameter Value: 0 Minimum Firmware Version Required: v1.xA0
44 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
PL (Power Level) Command
<RF Interfacing> The PL command is used to select and read the power level at which the RF module transmits conducted power.
WHEN OPERATING IN EUROPE: XBee-PRO RF Modules must be configured to operate at a maximum transmit power output level of 10 dBm. The PL parameter must equal “0” (10 dBm). Additionally, European regulations stipulate an EIRP power maximum of 12.86 dBm (19 mW) for the XBee-PRO and
12.11 dBm for the XBee when integrating high-gain antennas. WHEN OPERATING IN JAPAN:
XBee-PRO RF Modules optimized for use in Japan contain firmware that limits transmit power output to 10 dBm. If PL=4 (default), the maximum power output level is 10 dBm. For a list of module part numbers approved for use in Japan
PR (Pull-up Resistor Enable) Command
<Serial Interfacing> The PR command is used to set and read the bit field that is used to configure internal the pull-up resistor status for I/O lines. “1” specifies the pull-up resistor is enabled. “0” specifies no pull up.
bit 0 - AD4/DIO4 (pin 11) bit 1 - AD3/DIO3 (pin 17) bit 2 - AD2/DIO2 (pin 18) bit 3 - AD1/DIO1 (pin 19) bit 4 - AD0/DIO0 (pin 20) bit 5 - AD6/DIO6 (pin 16) bit 6 - DI8 (pin 9) bit 7 - DIN/CONFIG (pin 3)
For example: Sending the command “ATPR 6F” will turn bits 0, 1, 2, 3, 5 and 6 ON; and bits 4 & 7 will be turned OFF. (The binary equivalent of “0x6F” is “01101111”. Note that ‘bit 0’ is the last digit in the bitfield.
PT (PWM Output Timeout) Command
<I/O Settings {I/O Line Passing}> The PT command is used to set/read the output timeout value for both PWM outputs.
AT Command: ATPL
Parameter Range: 0 - 4
Parameter
XBee XBee-PRO
0
-10 dBm 10 dBm
1
-6 dBm 12 dBm
2
-4 dBm 14 dBm
3
-2 dBm 16 dBm
4
0 dBm 18 dBm
Default Parameter Value: 4
AT Command: ATPR Parameter Range: 0 - 0xFF
Default Parameter Value: 0xFF _ (all pull-up resistors are enabled)
Minimum Firmware Version Required: v1.x80
AT Command: ATPT Parameter Range: 0 - 0xFF [x 100 msec] Default Parameter Value: 0xFF Minimum Firmware Version Required: 1.xA0
Manual Documentation Number: MDR3243A-807 45
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
When PWM is set to a non-zero value: Due to I/O line passing, a time is started which when expired will set the PWM output to zero. The timer is reset when a valid I/O packet is received.
RE (Restore Defaults) Command
<(Special)> The RE command is used to restore all configurable parameters to their factory default settings. The RE command does not write restored values to non-volatile (persistent) memory. Issue the WR (Write) command subsequent to issuing the RE command to save restored parameter values to non-volatile memory.
RN (Random Delay Slots) Command
<Networking & Security> The RN command is used to set and read the minimum value of the back-off exponent in the CSMA-CA algorithm. The CSMA-CA algorithm was engineered for collision avoidance (random delays are inserted to prevent data loss caused by data collisions).
If RN = 0, collision avoidance is disabled during the first iteration of the algorithm (802.15.4 - macMinBE).
CSMA-CA stands for "Carrier Sense Multiple Access - Collision Avoidance". Unlike CSMA-CD (reacts to network transmissions after collisions have been detected), CSMA-CA acts to prevent data collisions before they occur. As soon as a module receives a packet that is to be transmitted, it checks if the channel is clear (no other module is transmitting). If the channel is clear, the packet is sent over-the-air. If the channel is not clear, the module waits for a randomly selected period of time, then checks again to see if the channel is clear. After a time, the process ends and the data is lost.
RO (Packetization Timeout) Command
<Serial Interfacing> RO command is used to set and read the number of character times of intercharacter delay required before transmission.
RF transmission commences when data is detected in the DI (data in from host) buffer and RO character times of silence are detected on the UART receive lines (after receiving at least 1 byte).
RF transmission will also commence after 100 Bytes (maximum packet size) are received in the DI buffer.
Set the RO parameter to '0' to transmit characters as they arrive instead of buffering them into one RF packet.
AT Command: ATRE
AT Command: ATRN Parameter Range: 0 - 3 [exponent] Default Parameter Value: 0
AT Command: ATRO Parameter Range:0 - 0xFF [x character times] Default Parameter Value: 3
46 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
RP (RSSI PWM Timer) Command
<I/O Settings {I/O Line Passing}> The RP command is used to enable PWM (Pulse Width Modulation) output on the RF module. The output is calibrated to show the level a received RF signal is above the sensitivity level of the module. The PWM pulses vary from 24 to 100%. Zero percent means PWM output is inactive. One to 24% percent means the received RF signal is at or below the published sensitivity level of the module. The following table shows levels above sensitivity and PWM values.
The total period of the PWM output is 64 µs. Because there are 445 steps in the PWM output, the minimum step size is 144 ns.
PWM Percentages
dB above Sensitivity
PWM percentage (high period
/ total period) 10 41% 20 58% 30 75%
A non-zero value defines the time that the PWM output will be active with the RSSI value of the last received RF packet. After the set time when no RF packets are received, the PWM output will be set low (0 percent PWM) until another RF packet is received. The PWM output will also be set low at power-up until the first RF packet is received. A parameter value of 0xFF permanently enables the PWM output and it will always reflect the value of the last received RF packet.
RR (XBee Retries) Command
<Networking {Addressing}> The RR command is used set/read the maximum number of retries the module will execute in addition to the 3 retries provided by the
802.15.4 MAC. For each XBee retry, the 802.15.4 MAC can execute up to 3 retries.
This values does not need to be set on all modules for retries to work. If retries are enabled, the transmitting module will set a bit in the BLACK BOX RF Packet header which requests the receiving module to send an ACK (acknowledgement). If the transmitting module does not receive an ACK within 200 msec, it will re-send the packet within a random period up to 48 msec. Each XBee retry can potentially result in the MAC sending the packet 4 times (1 try plus 3 retries). Note that retries are not attempted for packets that are purged when transmitting with a Cyclic Sleep Coordinator.
SC (Scan Channels) Command
AT Command: ATRP Parameter Range: 0 - 0xFF
[x 100 msec] Default Parameter Value: 0x28 (40 decimal)
AT Command: ATRR Parameter Range: 0 - 6 Default: 0 Minimum Firmware Version Required: 1.xA0
Manual Documentation Number: MDR3243A-807 47
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
<Networking {Association}> The SC command is used to set and read the list of channels to scan for all Active and Energy Scans as a bit field.
This affects scans initiated in command mode [AS (Active Scan) and ED (Energy Scan) commands] and during End Device Association and Coordinator startup.
bit 0 - 0x0B bit 4 - 0x0F bit 8 - 0x13 bit 12 - 0x17 bit 1 - 0x0C bit 5 - 0x10 bit 9 - 0x14 bit 13 - 0x18 bit 2 - 0x0D bit 6 - 0x11 bit 10 - 0x15 bit 14 - 0x19 bit 3 - 0x0E bit 7 - 0x12 bit 11 - 0x16 bit 15 - 0x1A
SD (Scan Duration) Command
<Networking {Association}> The SD command is used to set and read the exponent value that determines the duration (in time) of a scan.
End Device (Duration of Active Scan during Association) - In a Beacon system, set SD = BE of the Coordinator. SD must be set at least to the highest BE parameter of any Beaconing Coordinator with which an End Device or Coordinator wish to discover.
Coordinator - If the ‘ReassignPANID’ option is set on the Coordinator [refer to A2 parameter], the SD parameter determines the length of time the Coordinator will scan channels to locate existing PANs. If the ‘ReassignChannel’ option is set, SD determines how long the Coordinator will perform an Energy Scan to determine which channel it will operate on.
Scan Time is measured as ((# of Channels to Scan) * (2 ^ SD) * 15.36ms). The number of channels to scan is set by the SC command. The XBee RF Module can scan up to 16 channels (SC = 0xFFFF). The XBee PRO RF Module can scan up to 12 channels (SC = 0x1FFE).
Examples: Values below show results for a 12 channel scan
SH (Serial Number High) Command
AT Command: ATSC Parameter Range: 0 - 0xFFFF [Bitfield]
(bits 0, 14, 15 are not allowed when using the XBee-PRO)
Default Parameter Value: 0x1FFE (all XBee-PRO channels)
Related Commands: ED (Energy Scan), SD (Scan Duration)
Minimum Firmware Version Required: v1.x80
AT Command: ATSD Parameter Range: 0 - 0x0F Default Parameter Value: 4
Related Commands: ED (Energy Scan), SC (Scan Channel)
Minimum Firmware Version Required: v1.x80
If SD = 0, time = 0.18 sec SD = 8, time = 47.19 sec SD = 2, time = 0.74 sec SD = 10, time = 3.15 min SD = 4, time = 2.95 sec SD = 12, time = 12.58 min SD = 6, time = 11.80 sec SD = 14, time = 50.33 min
48 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
<Diagnostics> The SH command is used to read the high 32 bits of the RF module's unique IEEE 64-bit address.
The module serial number is set at the factory and is read-only.
SL (Serial Number Low) Command
<Diagnostics> The SL command is used to read the low 32 bits of the RF module's unique IEEE 64-bit address.
The module serial number is set at the factory and is read-only.
SM (Sleep Mode) Command
AT Command: ATSH Parameter Range: 0 - 0xFFFFFFFF [read-only]
Related Commands: SL (Serial Number Low), MY (Source Address)
AT Command: ATSL Parameter Range: 0 - 0xFFFFFFFF [read-only]
Related Commands: SH (Serial Number High), MY (Source Address)
Manual Documentation Number: MDR3243A-807 49
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
<Sleep Mode (Low Power)> The SM command is used to set and read Sleep Mode settings. By default, Sleep Modes are disabled (SM = 0) and the RF module remains in Idle/Receive Mode. When in this state, the module is constantly ready to respond to either serial or RF activity.
SM command options vary according to the networking system type. By default, the module is configured to operate in a NonBeacon system.
* The Sleep Coordinator option (SM=6) only exists for backwards compatibility with firmware version
1.x06 only. In all other cases, use the CE command to enable a Coordinator.
SP (Cyclic Sleep Period) Command
<Sleep Mode (Low Power)> The SP command is used to set and read the duration of time in which a remote RF module sleeps. After the cyclic sleep period is over, the module wakes and checks for data. If data is not present, the module goes back to sleep. The maximum sleep period is 268 seconds (SP = 0x68B0).
The SP parameter is only valid if the module is configured to operate in Cyclic Sleep (SM = 4-6). Coordinator and End Device SP values should always be equal.
To send Direct Messages, set SP = 0.
NonBeacon Firmware
End Device - SP determines the sleep period for cyclic sleeping remotes. Maximum sleep period is 268 seconds (0x68B0).
Coordinator - If non-zero, SP determines the time to hold an indirect message before discarding it. A Coordinator will discard indirect messages after a period of (2.5 * SP).
AT Command: ATSM Parameter Range: 0 - 6
Parameter Configuration
0 Disabled 1 Pin Hibernate 2 Pin Doze 3 (reserved)
4
Cyclic Sleep
Remote
5
Cyclic Sleep
Remote (with Pin
Wake-up)
6
Sleep
Coordinator*
Default Parameter Value: 0 Related Commands: SP (Cyclic Sleep Period),
ST (Time before Sleep)
AT Command: ATSP Parameter
Range:
NonBeacon Firmware: 1 - 0x68B0 [x 10 milliseconds]
Default Parameter Value:
NonBeacon Firmware: 0
Related Commands: SM (Sleep Mode), ST (Time before Sleep), DP (Disassociation Cyclic Sleep Period, BE (Beacon Order)
50 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
ST (Time before Sleep) Command
<Sleep Mode (Low Power)> The ST command is used to set and read the period of inactivity (no serial or RF data is sent or received) before activating Sleep Mode.
NonBeacon Firmware
Set/Read time period of inactivity (no serial or RF data is sent or received) before activating Sleep Mode. ST parameter is only valid with Cyclic Sleep settings (SM = 4 - 5).
Coordinator and End Device ST values must be equal.
T0 - T7 ((D0-D7) Output Timeout) Command
<I/O Settings {I/O Line Passing}> The T0, T1, T2, T3, T4, T5, T6 and T7 commands are used to set/read output timeout values for the lines that correspond with the D0 - D7 parameters. When output is set (due to I/O line passing) to a nondefault level, a timer is started which when expired, will set the output to its default level. The timer is reset when a valid I/O packet is received. The Tn parameter defines the permissible amount of time to stay in a non-default (active) state. If Tn = 0, Output Timeout is disabled (output levels are held indefinitely).
VL (Firmware Version - Verbose)
<Diagnostics> The VL command is used to read detailed version information about the RF module. The information includes: application build date; MAC, PHY and bootloader versions; and build dates.
VR (Firmware Version) Command
<Diagnostics> The VR command is used to read which firmware version is stored in the module.
XBee version numbers will have four significant digits. The reported number will show three or four numbers and is stated in hexadecimal notation. A version can be reported as "ABC" or "ABCD". Digits ABC are the main release number and D is the revision number from the main release. "D" is not required and if it is not present, a zero is assumed for D. "B" is a variant designator. The following variants exist:
• "0" = Non-Beacon Enabled 802.15.4 Code
• "1" = Beacon Enabled 802.15.4 Code
AT Command: ATST Parameter
Range:
NonBeacon Firmware: 1 - 0xFFFF [x 1 millisecond]
Default Parameter Value:
NonBeacon Firmware: 0x1388 (5000 decimal)
Related Commands: SM (Sleep Mode), ST (Time before Sleep)
AT Commands: ATT0 - ATT7 Parameter Range:0 - 0xFF [x 100 msec] Default Parameter Value:0xFF Minimum Firmware Version Required: v1.xA0
AT Command: ATVL Parameter Range: 0 - 0xFF
[x 100 milliseconds] Default Parameter Value: 0x28 (40 decimal) Minimum Firmware Version Required: v1.x80
AT Command: ATVR Parameter Range: 0 - 0xFFFF [read only]
Manual Documentation Number: MDR3243A-807 51
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
WR (Write) Command
<(Special)> The WR command is used to write configurable parameters to the RF module's nonvolatile memory. Parameter values remain in the module's memory until overwritten by subsequent use of the WR Command.
If changes are made without writing them to non-volatile memory, the module reverts back to previously saved parameters the next time the module is powered-on.
NOTE: Once the WR command is sent to the module, no additional characters should be sent until after the “OK/r” response is received.
API Operation
By default, XBee/XBee-PRO RF Modules act as a serial line replacement (Transparent Operation) - all UART data received through the DI pin is queued up for RF transmission. When the module receives an RF packet, the data is sent out the DO pin with no additional information.
Inherent to Transparent Operation are the following behaviors:
• If module parameter registers are to be set or queried, a special operation is required for transitioning the module into Command Mode.
• In point-to-multipoint systems, the application must send extra information so that the receiving module(s) can distinguish between data coming from different remotes.
As an alternative to the default 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 how commands, command responses and module status messages are sent and received from the module using a UART Data Frame.
API Frame Specifications
Two API modes are supported and both can be enabled using the AP (API Enable) command. Use the following AP parameter values to configure the module to operate in a particular mode:
• AP = 0 (default): Transparent Operation (UART Serial line replacement) API modes are disabled.
• AP = 1: API Operation
• AP = 2: API Operation (with escaped characters) Any data received prior to the start delimiter is silently discarded. If the
frame is not received correctly or if the checksum fails, the data is silently discarded.
AT Command: ATWR
52 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
API Operation (AP parameter = 1)
When this API mode is enabled (AP = 1), the UART data frame structure is defined as follows:
UART Data Frame Structure:
MSB = Most Significant Byte, LSB = Least Significant Byte
API Operation - with Escape Characters (AP parameter = 2)
When this API mode is enabled (AP = 2), the UART data frame structure is defined as follows:
UART Data Frame Structure with escape control characters:
MSB = Most Significant Byte, LSB = Least Significant Byte
Escape characters
. When sending or receiv in g a UART data frame, sp e c if ic data values must be escaped (flagged) so they do not interfere with the UART or UART data frame operation. To escape an interfering data byte, insert 0x7D and follow it with the byte to be escaped XOR’d with 0x20.
Data bytes that need to be escaped:
• 0x7E – Frame Delimiter
• 0x7D – Escape
• 0x11 – XON
• 0x13 – XOFF
Note: In the above example, the length of the raw data (excluding the checksum) is 0x0002 and the checksum of the non-escaped data (excluding frame delimiter and length) is calculated as: 0xFF - (0x23 + 0x11) = (0xFF - 0x34) = 0xCB.
Checksum
To test data integrity, a checksum is calculated and verified on non-escaped data.
Example - Raw UART Data Frame (before esc aping interfering bytes): 0x7E 0x00 0x02 0x23 0x11 0xCB 0x11 needs to be escaped which results in the following frame: 0x7E 0x00 0x02 0x23 0x7D 0x31 0xCB
Manual Documentation Number: MDR3243A-807 53
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
To calculate
: Not including frame delimiters and length, add all bytes keeping only
the lowest 8 bits of the result and subtract from 0xFF.
To verify
: Add all bytes (include checksum, but not the delimiter and length). If the
checksum is correct, the sum will equal 0xFF.
3.4.2. API Types
Frame data of the UART data frame forms an API-specific structure as follows:
UART Data Frame & API specific Structure:
The cmdID frame (API-identifier) indicates which API messages will be contained in the cmdData
frame (Identifier-specific data). Refer to the sections that follow for more information regarding the supported API types. Note that multi-byte values are sent big endian.
Modem Status
API Identifier: 0x8A RF module status messages are sent from the module in response to specific conditions.
Modem Status Frames
54 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
AT Command
API Identifier Value: 0x08 The “AT Command” API type allows for module parameters to be queried or set. When using this command ID, new parameter values are applied immediately. This includes any register set with the “AT Command - Queue Parameter Value” (0x09) API type.
AT Command Frames
Example: API frames when reading the DL parameter value of the module.
Example: API frames when modifying the DL parameter value of the module.
AT Command - Queue Parameter Value
API Identifier Value: 0x09 This API type allows module parameters to be queried or set. In contrast to the “AT Command” API type, new parameter values are queued and not applied until either the “AT Command” (0x08) API type or the AC (Apply Changes) command is issued. Register queries (reading parameter values) are returned immediately.
AT Command Frames (Note that frames are identical to the “AT Command” API type except for the API identifier.)
Manual Documentation Number: MDR3243A-807 55
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
AT Command Response
API Identifier Value: 0x88 Response to previous command.
In response to an AT Command message, the module will send an AT Command Response message. Some commands will send back multiple frames (for example, the ND (Node Discover) and AS (Active Scan) commands). These commands will end by sending a frame with a status of ATCMD_OK and no cmdData.
AT Command Response Frames.
TX (Transmit) Request: 64-bit address
API Identifier Value: 0x00 A TX Request message will cause the module to send RF Data as an RF Packet.
TX Packet (64 bit address) Frames
TX (Transmit) Request: 16-bit address
API Identifier Value: 0x01 A TX Request message will cause the module to send RF Data as an RF Packet.
TX Packet (16 bit address) Frames
56 Manual Documentation Number: MDR3243A-807
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
TX (Transmit) Status
API Identifier Value: 0x89 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.
TX Status Frames
NOTES:
• “STATUS = 1” occurs when all retries are expired and no ACK is received.
• If transmitter broadcasts (destination address = 0x000000000000FFFF), only “STATUS = 0 or 2” will be returned.
• “STATUS = 3” occurs when Coordinator times out of an indirect transmission. Timeout is defined as (2.5 x SP (Cyclic Sleep Period) parameter value).
RX (Receive) Packet: 64-bit Address
API Identifier Value: 0x80 When the module receives an RF packet, it is sent out the UART using this message type.
Manual Documentation Number: MDR3243A-807 57
Black Box Corporation - 1000 Park Drive - Lawrence, PA 15055-1018
www.blackbox.com -- Tech Support and Ordering: 724-746-5500 - Fax: 724-746-0746
RX Packet (64 bit address) Frames
RX (Receive) Packet: 16-bit Address
API Identifier Value: 0x81 When the module receives an RF packet, it is sent out the UART using this message type.
RX Packet (16 bit address) Frames
Loading...