本帖最后由 三水 于 2020-9-14 22:45 编辑
Blinker MQTT接入失败问题说明
Blinker中选择阿里云MQTT Broker接入的设备于9月10后陆续出现设备上线失败,目前已知如下两个原因:
1.阿里云更新了MQTT非加密通信接入接口,目前已更新接口代码;
2.设备未上报接入方式时服务器将默认返回非加密通信接入的设备登陆信息,目前已修改为默认返回加密通信接入的设备登陆信息。
如果因为如上两个原因不能正常接入的设备更新最新的库以后可以正常接入。
库下载地址:https://github.com/blinker-iot/blinker-library/archive/dev_3.0.zip
如果还有不能正常接入的设备请按文档开启所以调试信息并截取设备有效的启动信息留言告知我。
有效启动信息示例如下:
[md]```cpp
12:01:53.336 -> [681] [HTTP] begin: https://iot.diandeng.tech/api/v1/user/device/diy/auth?authKey=53081589XXXX&version=0.1.0&protocol=mqtts
12:01:54.824 -> [2190] [HTTP] GET... code: 200
12:01:54.824 -> [2199] reply was:
12:01:54.824 -> [2199] ==============================
12:01:54.859 -> [2199] {"detail": {"broker": "aliyun", "deviceName": "C4D61ADEQ8JMLY51U4UEXXXX", "host": "mqtts://public.iot-as-mqtt.cn-shanghai.aliyuncs.com", "iotId": "y63zwBYLsRorcJm4Nj2f0010f9XXXX", "iotToken": "^1^1600056114444^f21ca6a08faXXXX", "port": "1883", "productKey": "JgCGbHlXXXX", "uuid": "73c7b5a4b2f221c0a72d7b4128e4XXXX"}, "message": 1000}
12:01:54.859 -> [2223] ==============================
12:01:54.893 -> [2227] _num: 5
12:01:54.893 -> [2228] ====================
12:01:54.893 -> [2230] DEVICE_NAME_MQTT: C4D61ADEQ8JMLY51U4UEXXXX
12:01:54.893 -> [2235] MQTT_PRODUCTINFO_MQTT: JgCGbHlXXXX
12:01:54.893 -> [2238] MQTT_ID_MQTT: C4D61ADEQ8JMLY51U4UEXXXX
12:01:54.893 -> [2242] MQTT_NAME_MQTT: y63zwBYLsRorcJm4Nj2f0010f9XXXX
12:01:54.893 -> [2247] MQTT_KEY_MQTT: ^1^1600056114444^f21ca6a08faXXXX
12:01:54.893 -> [2252] MQTT_BROKER: aliyun
12:01:54.893 -> [2254] HOST: public.iot-as-mqtt.cn-shanghai.aliyuncs.com
12:01:54.893 -> [2260] PORT: 1883
12:01:54.927 -> [2261] HOST: public.iot-as-mqtt.cn-shanghai.aliyuncs.com
12:01:54.927 -> [2266] PORT: 1883
12:01:54.927 -> [2268] UUID_MQTT: 73c7b5a4b2f221c0a72d7b4128e4XXXX
12:01:54.927 -> [2272] ====================
12:01:54.927 -> [2275] BLINKER_PUB_TOPIC_MQTT: /JgCGbHlXXXX/C4D61ADEQ8JMLY51U4UEXXXX/s
12:01:54.927 -> [2281] BLINKER_SUB_TOPIC_MQTT: /JgCGbHlXXXX/C4D61ADEQ8JMLY51U4UEXXXX/r
12:01:54.927 -> [2288] Freeheap: 8760
12:01:54.927 -> [2294] mDNS responder started
```[/md]
|