Skip to content
Ac

Command queue Packet

Added on v1.0.0
TCP
HTTP

Defines the command queue packet for the Layrz Protocol, which is used to queue commands for execution by the server to the device.

Example Usage

<Ac>COMMAND+DEFINITION;CRC16</Ac>
ParameterTypeDescriptionExample
COMMAND+DEFINITIONCOMMAND+DEFINITIONDefines the command spec N/A
CRC16stringCyclic Redundancy Check for error checking1234

Command Definition COMMAND+DEFINITION

COMMAND_ID;COMMAND_NAME;EXTRA+ARGS;CRC16
ParameterTypeDescriptionExample
COMMAND_IDintID of the command to execute, this ID is the same that the device will return on the Pc packet1
COMMAND_NAMEstringIs the name of the command to execute.get_config
EXTRA+ARGSEXTRA+ARGSAdditional arguments that you need to send to the command, this is a key-value pair of parameters that the command will use to execute. N/A
CRC16integerCyclic Redundancy Check for error checking.1234

Extra Arguments EXTRA+ARGS

PARAMETER1:VALUE1,PARAMETER2:VALUE2,...
ParameterTypeDescription
PARAMETER1,PARAMETER2stringName of the parameter to send
VALUE1,VALUE2anyValue of the parameter to send

Example


gps.is.fixed:true,event.name:motion_detected

Considerations

  1. When you are on
    TCP
    , this packet can be sent without any kind of interaction by the server. On
    HTTP
    , this packet will return as replacement of the Ar or Ao packets, depending on the packet that was sent before.
  2. The COMMAND+DEFINITION can be N, depending of the number of commands that you want to queue.