Skip to main content
Version: 5.0

L2 AT Commands

The content of Acklio FullSDK can be described in its simplistic view as an adaptation layer with the SCHC mechanisms, and a set of interfaces: the Management API, the Datagram API, the Network API and the L2A interface.
Refer to the diagram of layers and interfaces for a better understanding.

The "UDP Client" and "DLMS using Gurux" Demo examples both use the following AT commands in their communication sequences.

Set or Get the Device EUI​

The expected format of the device EUI is 8 pairs of hexadecimal numbers separated by a colon.
For example: hh:hh:hh:hh:hh:hh:hh:hh.
Possible hexadecimal numbers (h) are 0 to 9, a to f or A to F.

WhatSetGet
CommandAT+DEUI=<dev_eui>AT+DEUI=?
Parameter<dev_eui> - See format expectations above—
Result codesOKDevice EUI value and then OK
 AT_PARAM_ERROR—

Set or Get the Application EUI​

The expected format of the application EUI is 8 pairs of hexadecimal numbers separated by a colon.
For example: hh:hh:hh:hh:hh:hh:hh:hh.
Possible hexadecimal numbers (h) are 0 to 9, a to f or A to F.

WhatSetGet
CommandAT+APPEUI=<app_eui>AT+APPEUI=?
Parameter<app_eui> - See format expectations above—
Result codesOKApplication EUI value and then OK
 AT_PARAM_ERROR—

Set or Get the Application Key​

The expected format of the application key is 16 pairs of hexadecimal numbers separated by a colon.
For example: hh:hh:hh:hh:hh:hh:hh:hh.
Possible hexadecimal numbers (h) are 0 to 9, a to f or A to F.

WhatSetGet
CommandAT+APPKEY=<app_key>AT+APPKEY=?
Parameter<app_key> - See format expectations above—
Result codesOKApplication key value and then OK
 AT_PARAM_ERROR—

Join the Network​

WhatDetail
CommandAT+JOIN=<class>
Parameter<class> - A or C
Result codesOK
 AT_PARAM_ERROR
 AT_ERROR,1,<error>
 +JOINED

Transmissions​

When the class is correct, the OK result code is returned immediately. If the join request succeeds, the +JOINED result code is returned a few seconds later. If it does not succeed, no additional result code is returned.

Error Messages​

AT_ERROR,1,<status> reports a management layer error. with the following possible values:

Numeric valueError codeComment
5MGT_L2A_ERRNot joined yet
6MGT_FRM_ERRError returned by the FRM layer
7MGT_MUX_ERRError returned by the Mux layer
8MGT_SYNC_ERRError returned by the Sync layer
9MGT_CD_ERRError returned by the C/D layer

Set or Get the Data Rate​

WhatSetGet
CommandAT+DR=<data_rate>AT+DR=?
Parameter<data_rate> - Value from 0 to 6—
Result codesOKData rate value, from 0 to 6, and then OK
 AT_PARAM_ERROR—

Set or Get the Adaptive Data Rate​

Set​

WhatSetGet
CommandAT+ADR=<adr>AT+ADR=?
Parameter<adr> - 0: off, 1: on—
Result codesOKAdaptive data rate value, 0 or 1, and then OK
 AT_PARAM_ERROR—

Set or Get the Active Region​

WhatSetGet
CommandAT+REGION=<region>AT+REGION=?
Parameter<region> - See below—
Result codesOKActive region string (see above) and then OK
 AT_PARAM_ERROR—

Recommendations​

The region (frequency plans) must comply with the LoRaWAN regional parameters and therefore, be one of the following strings:

  • AS923
  • AU915
  • CN470
  • CN779
  • EU433
  • EU868
  • KR920
  • IN865
  • US915
  • RU864

Get detailed information on the Regional Parameters by downloading this document from the LoRa Alliance.

The selected region must be supported by the radio module in use.

This command is not accepted once the device has joined the network.