Copyright © Neoway Technology Co., Ltd
<CR><LF>OK<CR><LF>
<Topic>: Topic to be published
<Qos>: QoS value, ranging from 0 to 2
<Message>: message to be published
[format]: message format
0: normal character strings
1: character string in hexadecimal format
Optional, the default value is 0
[fragment_id]: fragment ID of long message.
Optional, the default value is 0
+IMQTTRCVPUB=24761,“/test_topic_001”,5,“hello”
OK
The module reports
message received in an
unsolicited manner.
The module reports message received in an unsolicited manner after it receives
the message.
16.9 Querying MQTT Connection Status: +IMQTTSTATE
To query the status of the MQTT connection.
<CR><LF>+IMQTTSTATE:<state>
<CR><LF>OK<CR><LF>
<state>: MQTT connection state
0: MQTT disconnected
1: Reserve
2: MQTT connected
AT+IMQTTSTATE?
+IMQTTSTATE:2
OK
The device was connected to the
MQTT server.