Download - 802.15.4 at Command Specification
-
8/3/2019 802.15.4 at Command Specification
1/25
connectBlue
Copyright 2010 connectBlue AB Page 1 of 25
802.15.4 SERIAL PORT ADAPTER AT COMMANDSPECIFICATION
Document RevisionPublished: Jul 02, 2010 16:26Document version: 2
Copyright 2010 connectBlue AB. The contents of this document can be changed by connectBlue AB without prior notice and do notconstitute any binding undertakings from connectBlue AB. connectBlue AB is not responsible under any circumstances for direct, indirect,unexpected damage or consequent damage that is caused by this document. All rights reserved. All brand and product names aretrademarks or service marks of their respective owners.
-
8/3/2019 802.15.4 at Command Specification
2/25
connectBlue
Copyright 2010 connectBlue AB Page 2 of 25
-
8/3/2019 802.15.4 at Command Specification
3/25
connectBlue
Copyright 2010 connectBlue AB Page 3 of 25
1 Table of Content
Table of ContentIntroduction
Related DocumentsData Mode and AT Mode
Restoring Default ConfigurationRestoring Serial SettingsRestoring Factory Settings
Configuration and OperationDefault Serial SettingsNon-volatile settingsLED IndicationAT Commands over AirRadio ChannelsSearching for other devicesClient or ServerRemote peerZigBeeMapping of Bluetooth Functionality
AddressDevice NameClass of DeviceGAP ModesInquiryDevice DiscoveryName DiscoveryBonding / PairingPaging / ScanConnectionRadio ChannelProfiles
SecurityPower Saving ModesExamples
Creating Serial Connections and Sending DataAT Command Syntax
Command Line FormatData Types
AT Command ReferenceStandard AT Commands
AT Attention CommandAT&F Restore to Factory SettingsATE Echo On/OffATS2 Escape CharacterATS General Settings S Register Manipulation
Link Layer CommandsAT*AGDM Discoverability ModeAT*AGCM Connectability ModeAT*AGPM Pairing ModeAT*AGSM Security ModeAT*AGFP Fixed PINAT*AGLN Local NameAT*AGLC Local CodAT*AGCH Channel Number
AT*AGRSS RSSI ValueAT*AGND Name DiscoveryAT*AGI InquiryAT*AGBD Bonded devicesAT*AGUB Unbond
Data Mode CommandsAT*ADDM Enter Data ModeAT*ADCP Connect to Serial ServiceAT*ADCC Close Serial ConnectionAT*ADCP Default Client ProfileAT*ADSP Default Server ProfileAT*ADNRP Number of Remote PeersAT*ADRDRP Read Default Remote PeerAT*ADWDRP Write Default Remote Peer
Informational CommandsAT*AILBA ReadDevice Address
AT*AILTI ReadType InformationAT*AILVI Reads Local Version Information
Miscellaneous CommandsAT*AMRS Serial SettingsAT*AMET Escape Sequence Timing
-
8/3/2019 802.15.4 at Command Specification
4/25
connectBlue
Copyright 2010 connectBlue AB Page 4 of 25
AT*AMWS Watchdog SettingsAT*AMPM Power Saving ModeAT*AMMP Max output powerAT*AMRFM Read Feature MaskAT*AMWFM Write Feature MaskAT*ACCB Configuration over Air
EventsADCCO Connection Closed
Model Compatibility
2 Introduction
The IEEE 802.15.4 serial port adapter is implemented to be as similar as possible to the Bluetooth serial port adapter regarding conceptsand AT commands. Since many of the Bluetooth concepts are not directly mapped to the IEEE 802.15.4 technology some innovativethinking has been applied. The advantage is, of course, that both the Bluetooth and IEEE 802.15.4 serial port adapter can be used in thesame customer application with very limited consideration. This also applies to the connectBlue AB WLAN serial port adapter. All of themare designed to be mechanically, electrically and functionally compatible.
The section Model Compatibility describes the differences in the AT command sets between the IEEE 802.15.2 Serial Port Adapter andthe Bluetooth Serial Port Adapter. This chapter givesan overview of the differences in functionality between the products.
2.1 Related Documents
The Serial Port Adapter AT Commands document, this document, contains a description of the AT commands supported in theSerial Port Adapter. It also contains information on how to use the AT commands to create applications.The OEM Serial Port Adapter Electrical & Mechanical Data sheet contains important information about the OEM Serial PortAdapter. Read this document if you are using the OEM Serial Port Adapter.
3 Data Mode and AT Mode
TheSerial Port Adapteroperates in two different modes, AT mode and data mode. The module starts up in data mode and can berequested to move to AT mode by sending an escape sequence. The default escape sequence consists of three consecutive forwardslash characters '/'. The escape sequence character can be changed using the ATS2 command. Pressing the restore-button on the SerialPort Adapter, when it is powered up, restores the default escape character. The following criteria must be met for the module to interpretthe sequence as a valid escape sequence:
Before the escape sequence there must be no data for 1 second. This time can be changed using the AT*AMET EscapeSequence Timing Settings command.After the escape sequence there must be no data for 1 second. This time can be changed using the AT*AMET EscapeSequence Timing Settings command.The entire escape sequence must be sent within 200 ms.
To move from AT mode to data mode, use the AT*ADDM Enter Data Mode command.
Any connection that you have with theSerial Port Adaptercan be used to enter AT mode. The procedure is the same as describedabove. By default, it is only possible to enter AT mode from the serial connection. This behavior can be changed using the AT commandAT*ACCB Allow Configuration over Air.
4 Restoring Default Configuration
4.1 Restoring Serial Settings
In some situations it is necessary to restore the serial settings and the escape character and timing to their default values. The followingsettings can be restored using the procedure described below:
Serial settings: 57600 baud, 8 data bits, no parity, 1 stop bit, hardware flow control.Serial interface type: RS232.AT escape sequence: '///'.Escape sequence timing: 1000 ms of no data transmission required before and after the escape sequence for the escapesequence to be valid.
-
8/3/2019 802.15.4 at Command Specification
5/25
connectBlue
Copyright 2010 connectBlue AB Page 5 of 25
The serial settings are restored by applying a logic low signal on the Switch-1 input on the module during startup. If the module ismounted on a Module Adapter, this is done in the following way:
Remove power from the Serial Port Adapter.Press and hold the default serial settings button on the Serial Port Adapter.Apply power to the Serial Port Adapter. Now the default serial settings and escape configuration are restored.
4.2 Restoring Factory Settings
The factory setting is the configuration of the serial port adapter set when it is produced. To restore the factory settings configuration usethe "AT&F" command. After the "AT&F" command has been executed the serial port adapter must be reset for the factory settings to beapplied.Note that this command shall not be used at every startup to restore the factory settings. Instead it is better not to write to the startupdatabase at all.
5 Configuration and Operation
5.1 Default Serial Settings
The defaultserial settings are:
57600 Baud8 Data bitsNo parity1 Stop bitHardware flow control enabled
Pressing the restore-button on the Serial Port Adapter, when it is powered up, restores the default serial settings. The module does notsupport auto baud rate. Theserial settings are configured using the AT command AT*AMRS.
5.2 Non-volatile settings
There are several AT commands that can be used to configure the module which anenumerator parameter called . If thisparameter is set to 1 the setting will be applied directly and will also apply after a power off/on cycle. If this parameter is set to 0 thesetting will be applied immediately but it will not be applied when the module starts up in the next power cycle.
5.3 LED Indication
The LED indicates what mode is currently active and what activity that is currently in progress.The following color indications are used:
Green: The current mode is data mode and no connection attempt is in pro-gress.Orange: The current mode is AT mode.Purple: A connection attempt is in progress.Blue: A connection is currently active.Blue Blinking: A connection is active and data is transmitted or received over air.Red Blinking: Buffer overflow, parity or framing error detected on the UART.
5.4 AT Commands over Air
It is possible to configure and control a remote Serial Port Adapter using AT commands over air. The criterias for using AT commandsover air are:
A connection to the remote device (the device to configure) must exist.The remotedevice must haveallow configuration over airenabled. By default this is disabled. See the AT command AT*ACCBfor for further information.
The same escape sequence rules apply to AT over air as for AT over cable, for more information see the section about Data Mode andAT Mode. Note that the same escape sequence is used for cable and IEEE 802.15.4. Therefore, one of the Serial Port Adapters musthave its escape sequence changed using the ATS2 command. This is to keep the first Serial Port Adapter to enter AT mode instead ofthe remote Serial Port Adapter.
5.5 Radio Channels
The IEEE 802.15.4 Serial Port Adapter supports the 16 channels in the 2450 MHz band. The 915 MHz band and the 868 MHz band arenot supported. Serial Port Adapters must be configured to use the same channel to be able to communicate. The radio channel isconfigured using the AT command AT*AGCH.
-
8/3/2019 802.15.4 at Command Specification
6/25
connectBlue
Copyright 2010 connectBlue AB Page 6 of 25
5.6 Searching for other devices
TheInquirycommand AT*AGI is used to search for other devices. TheInquiry command returns the device address of all the devices inthe vicinity that are in discoverable mode. The IEEE Serial Port Adapter will only search in the currently configured channel. Only IEEE802.15.4 devices responding with the extended address is listed by the Inquiry command.
5.7 Client or Server
Configure theSerial Port Adapteras server if it shall accept incoming connections. The Serial Port Adapteris configured as server usingthe AT command AT*ADSP.
Configure theSerial Port Adapterasclientif it shallinitiateconnections. The Serial Port Adapteris configured asclient using the ATcommand AT*ADCP.
The Serial Port Adaptercan be configured as both client and server.
5.8 Remote peer
Which deviceaSerial PortAdapterconfigured as clientshall connect to is configured using the remote peer. The remote peer isconfigured using the AT command write default remote peer, AT*ADWDRP.
5.9 ZigBee
The IEEE 802.15.4 Serial Port Adapter does not support ZigBee. It is not able to communicate with ZigBee devices.
5.10 Mapping of Bluetooth Functionality
5.10.1 Address
The address of a Bluetooth device is composed of 48bits.Example: 0012F3004523The address of a IEEE 802.15.4 device is composed of 64bits.Example: 0012F3FFFF0795a7
The The IEEE 802.15.4 Serial Port Adapter always usesextended addresses.
5.10.2 Device Name
IEEE 802.15.4 has no attribute that corresponds to the Bluetooth device name. In the IEEE 802.15.4 Serial Port Adapter the concept of auser friendly device name has been kept. You can request the name of a remote device usinga name discovery.
5.10.3 Class of Device
The Class of Device (COD)concept is not used in either IEEE 802.15.4 or the IEEE 802.15.4 Serial Port Adapter. A dummy ATcommand exists to read and write the COD for compatibility with the Bluetooth Serial Port Adapter.
5.10.4 GAP Modes
Connectability - The IEEE 802.15.4 Serial Port Adapter implements connectable and and non-connectable modes by simplyalways denying connection requests when non-connectable.Discover ability - The IEEE 802.15.4 Serial Port Adapter implements discoverable and and non-discoverable modes by notsending beacon when receiving a beacon request when non-discoverable.Pair ability - The IEEE 802.15.4 Serial Port Adapter does not implement pair ability mode. A dummy AT command for readingand writing pair ability mode exists in the IEEE 802.15.4 Serial Port Adapter for compatibility for with the Bluetooth Serial PortAdapter.
5.10.5 Inquiry
The Bluetooth inquiry procedure is implemented using beacon requests and corresponding beacons. Note that only IEEE 802.15.4devices answering the beacon request with an extended address in the beacon will be listed as a found device. Only devices configuredto use the same channel will be found.
5.10.6 Device Discovery
Device Discovery is not implemented in either IEEE 802.15.4 or the IEEE 802.15.4 Serial Port Adapter.
-
8/3/2019 802.15.4 at Command Specification
7/25
connectBlue
Copyright 2010 connectBlue AB Page 7 of 25
5.10.7 Name Discovery
A name discovery procedure like the one supported in Bluetooth is implemented in the IEEE 802.15.4 Serial Port Adapter.
5.10.8 Bonding / Pairing
The concept of bonding or pairing does not exist for the IEEE 802.15.4 Serial Port Adapter. Instead authentication and key generation is
done for every new connection.
5.10.9 Paging / Scan
Since the IEEE 802.15.4 Serial Port Adapter operates on one specific channel no paging is required to set up a connection. The IEEESerial Port Adapter always has its radio in receiving mode when not transmitting.
5.10.10 Connection
The IEEE 802.15.4 Serial PortAdapter implements a connection concept which providesreliable data transfer in both directions. It doesnot support any of the network topologies described in the IEEE 802.15.4.
After a successful connection setup two IEEE Serial Port Adapters are connected. The device thatinitiated the connection setup is themaster of the connection and is polling the slave. If either the master or slave stops receiving acknowledgements or data from the theremote device for acertain time the connection is considered lost. This corresponds to the Bluetooth link supervision timeout.
5.10.11 Radio Channel
The Bluetooth radio uses frequency hopping over several channels while the IEEE 802.15.4 radio uses one specific channel. Comparedto the Bluetooth serial port adapter the channel must be specified on the IEEE 802.15.4 serial port adapter. The channel is specifiedusing the AT command AT*AGCH. The IEEE 802.15.4 serial port adapter. will never operate outside the channel specified by the writechannel command.
The adaptive frequency hopping supported in Bluetooth is not supported by IEEE 802.15.4. This means that the channel must beselected carefully so that other radio technologies are not disturbed by the IEEE 802.15.4 radio.
5.10.12 Profiles
The IEEE 802.15.4 Serial Port Adapter currently implements the concepts of the Bluetooth Serial Port Profile.
5.11 Security
Security is based on authentication during connection establishment and encryption oftransferred data. Data is encrypted using AES128as described in the security section in the IEEE 802.15.2 specification. Authentication and key generation is designed as a four-wayhandshake with HMAC. Inspiration for the authentication and key generation procedure has been taken from the IEEE 802.11i standard.
5.11.0.1 Security Modes
A device can be in two different security modes, security enabled (authentication and encryption turned on) and security disabled(authentication and encryption turned off). If at least one of the two devices wanting to communicate has security enabled, security will beused. Use thesecurity modecommand AT*AGMS to set the security mode for the device.
5.11.0.2 Bonding and Pairing
Compared to the Bluetooth Serial Port Adapters the concepts of pairing and bonding do not exist. Instead authentication and keygeneration is done on every new connection when security is enabled.
5.12 Power Saving Modes
A typical Bluetooth chip supports different sleep modes where it is e.g. possible to wake the chip up on an incoming connection or byactivating an IO pin. In IEEE 802.15.4 the concept of saving power is quite different. Since the 802.15.4 serial port adapter must simulatea Bluetooth connection where data can be transmitted in both directions, it not obvious how to implement the different power modes.Therefore, the current implementation of the 802.15.4 serial port adapter does not support any low power modes. The radio needs toactively listen at all times which means that the power consumption for the serial port adapter application is currently quite high comparedto the Bluetooth serial port adapter low power modes.
-
8/3/2019 802.15.4 at Command Specification
8/25
connectBlue
Copyright 2010 connectBlue AB Page 8 of 25
5.13 Examples
5.13.1 Creating Serial Connections and Sending Data
6 AT Command Syntax
6.1 Command Line Format
Each command line sent from the DTE to the DCE is made up of a prefix, body and terminator. As prefix for the Serial Port Adapter ATcommands, only "AT" (ASCII 065, 084) and "at" (ASCII 097, 116) can be used. There is no distinction between upper and lower casecharacters. The body is a string of characters in the range ASCII 032-255. Control characters other than (carriage return; ASCII013) and (back space; ASCII 008) in a command line are ignored. The terminator is .Commands denoted with a "*" character are extended AT commands, i.e. Serial Port Adapter specific AT commands.Multiple commands in the same command line are not supported. Each command has to be terminated by a before a newcommand can be sent.A command can either be:
Read commands without parameters:AT?
Write commands without parameters:ATRead and write commands with parameters:AT=, parameter2>, ...
Responses are sent back to the host and can be any of the following:
Successful final message:OKSuccessful intermediate/final message with parameters follows an OK mes-sage in some commands. In these cases the OKmessage works as a con-firm message only.:, parameter2>, ...Error message:ERROR
6.2 Data Types
The definition of each command specifies the data types used for values associated with the command. The different data types arelisted in the table below:
Type Deecription
String A string shall consist of a sequence of displayable characters from the ISO 8859-1 (8-bit ASCII) character set, except forcharacters "\" and """ and charac-ters below 32 (space). A string constant shall be delimited by two double-qoute (""")characters, e.g. "Donald Duck". If the double-quote character (""") is to be used within a string, e.g. "My friend "Bono" is asinger", they have to be represented as "\22". If the back-slash character ("\") is to be used within a string constant, it hasto be represented as "\5C". An empty string is represented by two adjacent delimiters, "".
Integer An integer value consists of a sequence of characters all in the range{0..9. Numeric constants are expressed in decimal format only.
Enumerator An enumerator value is actually an integer, where all its possible values are specified in each case. Only the definedvalues are accepted for the command in question.
Address This type is used to represent the extended IEEE Device Address. The type is composed of eight fields, eachrepresenting a hexadecimal value using two characters. For example, the Device Address 0x112233AABBCCDDEE isrep-resented as 112233AABBCCDDEE or 112233aabbccddee. Note that the Device Address is not delimited with by twodouble-qoute (""") characters.
-
8/3/2019 802.15.4 at Command Specification
9/25
connectBlue
Copyright 2010 connectBlue AB Page 9 of 25
7 AT Command Reference
7.1 Standard AT Commands
7.1.1 AT Attention Command
Syntax Description
AT Attention command determining the presence of a DCE, i.e. the OZSPA311.
Responses Description
OK Successful response
ERROR Error response
7.1.2 AT&F Restore to Factory Settings
Syntax Description
AT&F This command instructs the unit to set all parameters to their defaults as specified by themanufacturer.
Responses Description
OK Successful response
ERROR Error response
7.1.3 ATE Echo On/Off
Syntax Description
ATE Set whether or not the Serial Port Adapter shall echo incoming characters.
Parameters Type Description
echo_on Enumerator 0 = Unit does not echo characters during command state and online command state.
1 = Unit echoes characters during command state and online command state.
Responses Description
OK Successful write response
ERROR Error response
7.1.4 ATS2 Escape Character
Syntax Description
ATS2= Write the escape character used to switch the unit from data mode to AT mode.
ATS2? Read escape character
Parameters Type Description
esc_char Integer 0...255 (Note: The escape sequence will be the value repeated three times. I.e. "///".)
Responses Description
>LF>esc_charOK Successful read response
OK Successful write response
ERROR Error response
-
8/3/2019 802.15.4 at Command Specification
10/25
connectBlue
Copyright 2010 connectBlue AB Page 10 of 25
7.1.5 ATS General Settings S Register Manipulation
Syntax Description
ATS= Write to a general settings S register.
ATS? Read from a general settings S register.
Parameters Type Description
register Integer Any of the registers described below.
value Integer Valid values for each register is listed below.
Responses Description
valueOK Successful read response
OK Successful write response
ERROR Error response
Register Description
2000 Poll interval in mil liseconds.The poll interval determines how often the master of a connection polls its slaves. A longer interval increases the latency ofthe connection but decreases the radio activity on the channel when no data is transferred on the connection.Min 100Max 2000Default 100
2100 Trimming interval seconds. The trimming interval determines how often the internal clocks are calibrated.Min 0Max 60Default 30
7.2 Link Layer Commands
7.2.1 AT*AGDM Discoverability Mode
Syntax Description
AT*AGDM=, Write discoverability mode.
AT*AGDM? Read discoverability mode.
Parameters Type Description
mode Enumerator 1 = Non-discoverable
3 =Discoverable (default)
store Enumerator 0 = Do not store1 = Store (will store between reboots)
Responses Description
*AGDM:OK Successful read response
OK Successful response
ERROR Error response
-
8/3/2019 802.15.4 at Command Specification
11/25
connectBlue
Copyright 2010 connectBlue AB Page 11 of 25
7.2.2 AT*AGCM Connectability Mode
Syntax Description
AT*AGCM=, Writeconnectability mode.
AT*AGAM? Readconnectability mode
Parameters Type Description
mode Enumerator 1 =Non-connectable2 =Connectable (default)
store Enumerator 0 = Do not store1 = Store (will store between reboots)
Responses Description
*AGCM:OK Successful read response
OK Successful response
ERROR Error response
7.2.3 AT*AGPM Pairing Mode
Syntax Description
AT*AGPM=, Writepairing mode.
AT*AGPM? Read pairing mode
Parameters Type Description
mode Enumerator 1 = Non-pairable mode2 =Pairable mode (default value)
store Enumerator 0 = Do not store1 = Store (will store between reboots)
Responses Description
*AGPM:OK Successful read response
OK Successful response
ERROR Error response
Model Constraint
cB-OZS311 Dummy implementation for compatibility with Bluetooth SPA.Hence, the command exists but it does not affect the behavior of the 802.15.4 SPA.
7.2.4 AT*AGSM Security Mode
Syntax Description
AT*AGSM=, Write security mode.
AT*AGSM? Read security mode
Parameters Type Description
mode Enumerator 1: Link level authentication and encryption disabled. (default)
2: Link level authentication and encryption enabled.
store Enumerator 0 = Do not store1 = Store (will store between reboots)
-
8/3/2019 802.15.4 at Command Specification
12/25
connectBlue
Copyright 2010 connectBlue AB Page 12 of 25
Responses Description
*AGSM:OK Successful read response
OK Successful response
ERROR Error response
7.2.5 AT*AGFP Fixed PIN
Syntax Description
AT*AGFP=, WritePINcode.
AT*AGFP? Read PIN code.
Parameters Type Description
pin String The PIN code is a string of one to sixteen al-phanumerical characters.It is recommended to use a pin codeof at least eight characters of mixed type, e.g. "12w35tg7".The default value is "0".
store Enumerator 0 = Do not store1 = Store (will store between reboots)
Responses Description
*AGFP:OK Successful read response
OK Successful response
ERROR Error response
7.2.6 AT*AGLN Local Name
Syntax Description
AT*AGLN=, Writelocal name
AT*AGLN? Readlocal name
Parameters Type Description
name String Max 32 characters. The default name is "cB-OZS311".
store Enumerator 0 = Do not store1 = Store (will store between reboots)
Responses Description
*AGLN:OK Successful read response
OK Successful response
ERROR Error response
7.2.7 AT*AGLC Local Cod
Syntax Description
AT*AGLC=, Write the Class Of Device code
AT*AGLC? Read the Class Of Device code
Parameters Type Description
cod Integer Class of device
store Enumerator 0 = Do not store1 = Store (will store between reboots)
Responses Description
-
8/3/2019 802.15.4 at Command Specification
13/25
connectBlue
Copyright 2010 connectBlue AB Page 13 of 25
*AGLC:OK Successful read response
OK Successful response
ERROR Error response
Model Constraint
cB-OZS311 Dummy implementation for compatibility with Bluetooth SPA.
Hence, the command exists but it does not affect the behavior of the 802.15.4 SPA.
7.2.8 AT*AGCH Channel Number
Syntax Description
AT*AGCH=, Write IEEE 802.15.4 channel number.
AT*AGCH? Read IEEE 802.15.4 channel number.
Parameters Type Description
channel Integer Min = 11Max = 26
Default = 21
store Enumerator 0 = Do not store1 = Store (will store between reboots)
Responses Description
*AGCH:OK Successful read response
OK Successful response
ERROR Error response
7.2.9 AT*AGRSS RSSI Value
Syntax Description
AT*AGRSS? This request returns the current received signal strength, RSSI, for the connection between the Serial Port Adapter andthe remote device identified by the 'dev_addr' parameter.Note that this command can only be used on an exist-ingconnection that has been established using theAT*ADCP command and only while still in AT mode.The RSSI ismeasured in steps of 1 dBm with an uncertainty of 5dBm.
Parameters Type Description
rssi Integer RSSI value.Where value is dBm value + 128, i.e. 128 = 0dBm.If no connection is established, the response is an error response.
Responses Description
*AGRSS:OK Successful response
ERROR Error response
7.2.10 AT*AGND Name Discovery
Syntax Description
AT*AGND= Retrieves the device name of a remote device given its device address
Parameters Type Description
address String Address of remote device.
name String String of maximum 32 characters (8-bit ASCII).
Responses Description
-
8/3/2019 802.15.4 at Command Specification
14/25
connectBlue
Copyright 2010 connectBlue AB Page 14 of 25
*AGND:OK Successful response
ERROR Error response
7.2.11 AT*AGI Inquiry
Syntax Description
AT*AGI=,,
Performs an inquiry procedure to find any discoverable devices in thevicinity.
Parameters Type Description
type Enumerator 2: General inquiry
length Integer Maximum amount of time specified before the inquiry is halted.Range: 1 - 48 Time = inquiry_length*1.28 secondsRange in seconds: 1.28-61.44
max_no_of_devices_to_find Integer 0: No limitation on the number of devices to find.1-255: Maximum number of devices to find.
adddess Address Device address of a found device.
cod Integer Always 0. For compatibility with Bluetooth SPAs
Responses Description
*AGI:, This response is sent for every found device.
OK Successful response.
ERROR Error message.
Model Constraint
cB-OZS311 Returned class of device (cod) is always 0.
7.2.12 AT*AGBD Bonded devices
Syntax Description
AT*AGBD? Read bonded devices.
Parameters Type Description
no_of_bonded_devices Integer Number of bonded devices.
address Address Address of bonded device
name_valid Enumerator Always 1. Device is bonded but its device name is not valid.
name String Always the empty string ""
Responses Description
*AGBD:OK Successful response
*AGBDE:,, This response is sent for every found device.
ERROR Error response
Model Constraint
cB-OZS311 Bonding / pairing does not exist on the IEEE 802.15.4 Serial Port Adapter. This command is kept for backwardscompatibility with the Bluetooth Serial Port Adapters. The last device that the Serial Port Adapter was connected to willbe listed.
-
8/3/2019 802.15.4 at Command Specification
15/25
connectBlue
Copyright 2010 connectBlue AB Page 15 of 25
7.2.13 AT*AGUB Unbond
Syntax Description
AT*AGUB= This command un-bonds a previously bonded device.
Parameters Type Description
address Address Device address of the device subject to un-bond.
Responses Description
OK Successful response
ERROR Error response
Model Constraint
cB-OZS311 cB-OZS311 Bonding / pairing does not exist on the IEEE 802.15.4 Serial Port Adapter. This command is kept forbackwards compatibility with the Bluetooth Serial Port Adapters.
7.3 Data Mode Commands
7.3.1 AT*ADDM Enter Data Mode
Syntax Description
AT*ADDM Enter data mode.
Responses Description
OK Successful response
ERROR Error response
7.3.2 AT*ADCP Connect to Serial Service
Syntax Description
AT*ADCP=,,,
Connect to a serial service enabled on a remote device. This request is used to connect to profiles basedon the Serial Port Profile. The connection shall be used in data mode. When the host connects to a serviceon a remote device it implicitly registers to receive the Serial_Connection_Data_Mode_Closed event.
Parameters Type Description
address Address Address of remote device
profile Enumerator 0 = Serial profile
server_channel Integer Reserved
must_be_master Enumerator reserved
handle Integer Connection handle. The connection handle is used when closing the connection.
Responses Description
*ADCP:OK Successful response
ERROR Error response
Model Constraint
cB-OZS311 server_channel and must_be_master parameters are ignored. These are kept for backwards compatibility with theBleutooth Serial Port Adapter.
-
8/3/2019 802.15.4 at Command Specification
16/25
connectBlue
Copyright 2010 connectBlue AB Page 16 of 25
7.3.3 AT*ADCC Close Serial Connection
Syntax Description
AT*ADCC= Close an existing connection.
Parameters Type Description
handle Integer The connection handle identif ies the connection.
Responses Description
OK Successful response.
ERROR Error response.
7.3.4 AT*ADCP Default Client Profile
Syntax Description
AT*ADDCP=, Write Client Profile.
AT*ADDCP? Read Client Profile.
Parameters Type Description
profile Enumerator Client profile.0: Serial Port Profile255: No profile (default)
store Enumerator 0 = Do not store1 = Store (will store between reboots)
Responses Description
OK Successful writeresponse.
*ADDCP:OK Successful read response.
ERROR Error response.
Model Constraint
cB-OZS311 Only Serial Port Profile or No profile supported.
7.3.5 AT*ADSP Default Server Profile
Syntax Description
AT*ADDSP=, WriteServer Profile.
AT*ADDCP? ReadServer Profile.
Parameters Type Description
profile Enumerator Client profile.0: Serial Port Profile (default)255: No profile
store Enumerator 0 = Do not store1 = Store (will store between reboots)
Responses Description
OK Successful writeresponse.
*ADDSP:OK Successful read response.
ERROR Error response.
-
8/3/2019 802.15.4 at Command Specification
17/25
connectBlue
Copyright 2010 connectBlue AB Page 17 of 25
Model Constraint
cB-OZS311 Only Serial Port Profile or No profile supported.
7.3.6 AT*ADNRP Number of Remote Peers
Syntax Description
AT*ADNRP=, Write number of remote peers.
AT*ADNRP? Read number of remote peers.
Parameters Type Description
nr_of_peers Integer The number of remote peers.0 is default.
store Integer 0 = Do not store1 = Store (will store between reboots)
Responses Description
*ADMRP:OK Successful read response
OK Successful response
ERROR Error response
7.3.7 AT*ADRDRP Read Default Remote Peer
Syntax Description
AT*ADRDRP= Read theconfiguration for a remote peer with the given id.
Parameters Type Description
peer_id Integer Any value between 0 and mximum remote peers supported.
address Address Address of remote peer.
connection_scheme Integer This parameter is a bit field. Bit 0 is the least significant bit. Each bit is defined as follows:Bit 0: Connect on data. Try to connect to default remote peer on data traffic.Bit 1: Always connected. Always try to be connected to the default re-mote peer when in datamode.Bit 2-15: Reserved for future use.Advanced:Bit 16-23: Always connected period.This field can be used to define the period for connectionattempts for always connected (Bit 1 set). If not set or set to 0 then the default period 10s is used.Time in seconds.Bit 24-31: Reserved for future use.
update_on_incoming Enumerator 1: Every time a remote device connects to the selected DefaultServerProfile, update the re-motepeer device address to the device address of the connecting device. The new remote peer deviceaddress will be stored in the startup database. Only one of all the remote peers can use thisfeature.0: Do not update the remote peer device ad-dress on incoming connections.
name String A string with a user defined name of the peer. Max length is 32 characters.
Responses Description
*ADRDRP:,
,,,OK
Successful response
ERROR Error response.
Model Constraint
cB-OZS311 Compared to the Bluetooth Serial Port Adapters connect to name or easy connect are not supported.
-
8/3/2019 802.15.4 at Command Specification
18/25
-
8/3/2019 802.15.4 at Command Specification
19/25
connectBlue
Copyright 2010 connectBlue AB Page 19 of 25
7.5.1 AT*AILTI ReadType Information
Syntax Description
AT*AILTI? Read thetype ofdevice.
Parameters Type Description
major_id Enumerator 3 = IEEE 802.15.4 Serial Port Adapter
minor_id Enumerator 1 = OZSPA311
Responses Description
*AILTI:
OK
Successful response.
ERROR Error response
7.5.2 AT*AILVI Reads Local Version Information
Syntax Description
AT*AILVI? Read local version information
Parameters Type Description
manufacturer String Serial Port Adapter manufacturer.
spa_sw_version String Serial Port Adapter software version.
mac_driver_version String MAC driver version.
lm_version String Reserved, always "".
radio_manufacturer String IEEE 802.15.4 hardware manufacturer.
Responses Description
*AILVI:,,
,,OK
Successful response
ERROR Error response
7.6 Miscellaneous Commands
7.6.1 AT*AMRS Serial Settings
Syntax Description
AT*AMRS=,,,,,,
Write theserialsettings.
AT*AMRS? Read the serial settings.
Parameters Type Description
-
8/3/2019 802.15.4 at Command Specification
20/25
connectBlue
Copyright 2010 connectBlue AB Page 20 of 25
baud_rate Enumerator Baud rate1 = 3002 = 12003 = 24004 = 48005 = 96006 = 192007 = 384008 = 57600 (default)
data_bits Enumerator 1 = 8 data bits (default)2 = 7 data bits
stop_bits Enumerator 1 = 1 bit (default)2 = 2 bits
parity Enumerator 1 = None (default)2 = Odd3 = Even
flow_control Enumerator Flow control settings1 = cts/rts (default)2 = None
change_after_confirm Enumerator 0: The Serial Port Adapter will not changeserial settings until after the next power cycle. 1: TheSerial Port Adapter will changeserial settings after it has sent the OK to the Host.
store Enumerator 0 = Do not store1 = Store (will store between reboots)
Responses Description
*AMRS:,
,,,OK
Successful read response
OK Successful write response
ERROR Error response
Model Constraint
cB-OZS311 Non standard or special baud rates not supported.Maximum baudrate is 57600.
7.6.2 AT*AMET Escape Sequence Timing
Syntax Description
AT*AMET=,
,
Write the escape sequence timing settings.For an escape sequence to be valid, a period of no data activity is required before and after theescape sequence. This command reads the minimum time of no data activity required before andafter the escape sequence.
AT*AMET? Read the escape sequence timing settings.
Parameters Type Description
min_time_before Integer Min 50Max 5000ms1000 default
min_time_after Integer Min 50Max 5000ms1000 default
store Integer 0 = Do not store1 = Store (will store between reboots)
Responses Description
-
8/3/2019 802.15.4 at Command Specification
21/25
connectBlue
Copyright 2010 connectBlue AB Page 21 of 25
*AMET:,OK
Successful read response
OK Successful write response
ERROR Error response
7.6.3 AT*AMWS Watchdog Settings
Syntax Description
AT*AMWS=,
,,,,
Write the watchdog settings.The watchdog functionality will disconnect from a remote peer if one of the given conditions are met.
AT*AMWS? Read the watchdog settings
Parameters Type Description
write_timeout Integer Time in seconds before SPA disconnects when a write operation fails.0: Disabled (default value)> 0: Timeout in seconds
inactivity_timeout Integer Time in seconds before SPA disconnects if no activity.0: Disabled (default value)> 0: Timeout in seconds
connect_timeout Integer Max connection time in seconds before a connection is terminated.0: Disabled (default value)> 0: Timeout in seconds
disconnect_reset Integer 0: Disabled (default value) 1: An SPA enabled as a server will reset on a terminated connection.
reset Integer If set to 1 the SPA will reset immediately. All other parameters wil l be ignored.
store Integer 0 = Do not store1 = Store (will store between reboots)
Responses Description
*AMWS:,,,,OK
Successful read response
OK Successful write response
ERROR Error response
7.6.4 AT*AMPM Power Saving Mode
Syntax Description
AT*AMPM=, Write the power saving mode
AT*AMPM? Read the power saving mode
Parameters Type Description
power_mode Enumerator 1 = Online2 = Sleep mode (default)3 = Stop mode
store Enumerator 0 = Do not store1 = Store (will store between reboots)
Responses Description
*AMPM:OK Successful read response
-
8/3/2019 802.15.4 at Command Specification
22/25
connectBlue
Copyright 2010 connectBlue AB Page 22 of 25
OK Successful response
ERROR Error response
7.6.5 AT*AMMP Max output power
Syntax Description
AT*AMMP=, Write max output power setting.
AT*AMPM? Read max output power setting.
Parameters Type Description
max_power Integer Actual output power in dBm + 128.255: Use the highest output power supported by the Serial Port Adapter as the maximum output power(default value)
store Enumerator 0 = Do not store1 = Store (will store between reboots)
Responses Description
*AMPM:OK Successful read response
OK Successful response
ERROR Error response
7.6.6 AT*AMRFM Read Feature Mask
Syntax Description
AT*AMRFM= Read feature mask. This command is deprecated and only kept for compatibility reasons.
Parameters Type Description
mask_id Integer Only mask id 1 is supported.
mask_value Integer Dummy value.
Responses Description
*AMRFM:,
OK
Successful response
ERROR Error response
Model Constraint
cB-OZS311 Dummy implementation for compatibility with Bluetooth SPA.
7.6.7 AT*AMWFM Write Feature Mask
Syntax Description
AT*AMWFM=,,
Write feature mask. This command is deprecated and only kept for compatibility with theBluetooth module.
Parameters Type Description
mask_id Integer See AT*AMRFM Read Feature Mask command
mask_value Integer See AT*AMRFM Read Feature Mask command
Responses Description
OK Successful response
-
8/3/2019 802.15.4 at Command Specification
23/25
connectBlue
Copyright 2010 connectBlue AB Page 23 of 25
ERROR Error response
Model Constraint
cB-OZS311 Dummy implementation for compatibility with Bluetooth SPA.
7.6.8 AT*ACCB Configuration over Air
Syntax Description
AT*ACCB=, Write allow configuration over air.
AT*ACCB? Read allow configuration over air.
Parameters Type Description
allow Enumerator 0 = AT mode can only be entered from theserial interface(default)1 = AT mode can be entered from boththe serrial interfaceand any connected remote peer
store Enumerator 0 = Do not store1 = Store (will store between reboots)
Responses Description
*ACCB:OK Successful read response
OK Successful write response
ERROR Error response
7.7 Events
7.7.1 ADCCO Connection Closed
Syntax Description
*ADCCO:, A connection to a remote device has been disconnected. This event will onlyoccur when a connection established using AT*ADCP is disconnected when thedevice is still in AT mode.
Parameters Type Value
connection_handle Integer Hanlde identifying the connection.
reason Enumerator 0: Disconnected by command1: Disconnected by link loss255: Reason unknown
8 Model Compatibility
The following table describes what AT commands and events that differ from the IEEE 802.15.4 SPA compared to the Bluetooth SPA.
Command Supported inOZSPA311
Comment
AT Yes
AT* No
ATZ No
AT&F No
ATS2 Yes
ATS Yes New compared to Bluetooth SPA. General settings registers are used for configuration of someparameters.
ATE Yes
-
8/3/2019 802.15.4 at Command Specification
24/25
connectBlue
Copyright 2010 connectBlue AB Page 24 of 25
AT*AGDM Yes
AT*AGCM Yes
AT*AGPM Yes Bonding/Pairing concept do not exist for the IEEE 802.15.4 SPA. Dummy implementation forbackward compatibility with the Bluetooth SPA.
AT*AGSM Yes
AT*AGCH Yes New compared to Bluetooth SPA.
AT*AGND Yes
AT*AGDD No
AT*AGI Yes
AT*AGB No
AT*AGUB Yes Bonding/Pairing concept do not exist for the IEEE 802.15.4 SPA. Dummy implementation forbackward compatibility with the Bluetooth SPA.
AT*AGBD Yes Bonding/Pairing concept do not exist for the IEEE 802.15.4 SPA. Dummy implementation forbackward compatibility with the Bluetooth SPA.
AT*AGFP Yes
AT*AGLN Yes
AT*AGLC Yes Class of device concept does not exist for the IEEE 802.15.4 SPA. Dummy implementation forbackward compatibility with the Bluetooth SPA.
AT*AGGMSR No
AT*AGCMSR No
AT*AGMSP No
AT*AGRSS Yes
AT*ARSS No
AT*ADDM Yes
AT*ADCP Yes
AT*ADCC Yes
AT*ADDCP Yes Only the serial port profile concept is supported by the IEEE 802.15.4 SPA.
AT*ADDSP Yes Only the serial port profile concept is supported by the IEEE 802.15.4 SPA.
AT*ADMRP No
AT*ADNRP Yes
AT*ADRDRP Yes Only basic connection schemes are supported.
AT*ADWDRP Yes Only basic connection schemes are supported.
AT*ADIT No
AT*ADWM No
AT*AILBA Yes
AT*AILVI Yes
AT*AILTI Yes
AT*AMRS Yes Not all baud rates supported by the Bluetooth SPA is supported by the IEEE 802.15.4 SPA.
AT*AMSIT No
AT*ACF No
AT*ACACF No
AT*ACDF No
AT*ACCB Yes
-
8/3/2019 802.15.4 at Command Specification
25/25
connectBlue
AT*AMPM No
AT*AMMP Yes
AT*AMET No
AT*AMBOR No
AT*AMBO No
AT*AMLO No
AT*AMSF No
AT*AMWS Yes
AT*AMDS No
AT*AMLP No
AT*AMWFM Yes Dummy implementation for backward compatibility with the Bluetooth SPA.
AT*AMRFM Yes Dummy implementation for backward compatibility with the Bluetooth SPA.
*ADCCO Yes