EMQPERSIST – report a set value to the device shadow
Report a set value to the device shadow/twin. The operation depends on which AWSSHADOW mode you
set, either simple or complete.
You set AWSSHADOW in the Configuration File. For more information, see Using the Quectel BG96
module configuration file on page62. Alternatively, send:
AT+ETMCFG=mqtt,awsshadow,<off/simple/complete>, for example:
AT+ETMCFG=mqtt,awsshadow,simple
AWSSHADOW simple mode
The shadow Eseye Telemetry Module (ETM) performs the following automatically:
•
Generates the JSON state and reported or desired objects
•
Subscribes to the shadow/update/delta topic, and filters out the containing objects
•
Presents the host with the state object JSON content only, sent via URC
The host only sends the content of the reported object.
AWSSHADOW complete mode
The host sends the complete JSON for the shadow to ETM.
ETM sends the complete shadow message as a URC, without filtering.
EMQPERSIST commands
Type Syntax Returned Result
Test
AT+EMQPERSIST=? +EMQPERSIST: <data>
OK
Read
AT+EMQPERSIST? OK
or
ERROR
Write
AT+EMQPERSIST=<JSON>
where JSON is the JSON code, which
depends on the AWSSHADOW mode you
configured.
For simple mode:
Either the content of the state reported
object or desired object is required, in this
format:
AT+EMQPERSIST="{\"key\":value}"
where value is a numeric value, including
OK
SEND OK
or
ERROR
Eseye-enabled Quectel BG96 module Developer Guide v1.8
46
MQTT telemetry ATcommands