Copyright © Neoway Technology Co., Ltd
16 Ali MQTT Command
16.1 Setting MQTT Mode: +IMQTTMODE
To set the mode of MQTT connection
<Mode>: MQTT mode
0: MQTT
1: MQTT over TLS
Set the mode of MQTT connection
to MQTT over TLS
By default, MQTT communication uses plain TCP connections.
To use MQTT over TLS, execute this command before authentication.
16.2 Setting Device Authentication: +IMQTTAUTH
Device authentication information
AT+CLOUDAUTH=<productKey>,<deviceName>,<deviceSecret><CR>
<productKey>: product key
<deviceName>: device name
<deviceSecret>: device key
AT+IMQTTAUTH=“productKey001”,“device
Name001”,“deviceSecret123”
OK
+IMQTTAUTH:OK
The device is authenticated
successfully.
After the authentication is started, OK is returned to indicate legal input and then
authentication result is returned.