开发者社区> 问答> 正文

MTK2621平台移植sdk-c-3.0.1成功连接MQTT后PUB消息失败

游客4u26bcxwfjgow 2019-06-05 19:18:33 318

MTK2621平台(2625+6261)参考“MTK2503/MTK6261 + Nucleus 移植示例”说明移植sdk后设备可以通过MQTT连接阿里物联网平台,在设备信息页面可以看到设备在线状态,但连接成功后PUB消息一直不成功,会返回错误信息"MQTTPublish is error, rc = -14","mqtt client state is error,state = 3"即设备连接已断开,请问这个可能是什么原因?希望大家指导下,谢谢,部分log如下:
MOD_NIL, "g_mqtt_signout.hostname: 139.196.135.135"
MOD_NIL, "MQTT init success!"
MOD_NIL, "calling TCP or TLS connect HAL for [1/3] iteration"
MOD_NIL, "soc_create: 1
MOD_NIL, "IOT_MQTT_Construct Success"
MOD_NIL, "connect params: MQTTVersion=4, clientID=a1urEdmfoNQ.KonkaGps|timestamp=2524608000000,_v=sdk-c-3.0.1,securemode=3,signmethod=hma"
MOD_NIL, "mqtt connect success!"
MOD_NIL, "Upstream Topic: '/a1urEdmfoNQ/Gps/user/update'"
MOD_NIL, "MQTTPublish is error, rc = -14"
MOD_NIL, "IOT_MQTT_Publish failed
MOD_NIL, "failed to report firmware version"
MOD_NIL, "Aliyun connect success,start yield"
MOD_NIL, "Ali SOC_READ Event"
MOD_NIL, "ali_mqtt_yield..."
MOD_NIL, "mqtt client state is error,state = 3"
MOD_NIL, "publish failed, res=-27

分享到
取消 提交回答
全部回答(0)
IoT
+ 订阅

物联网软硬件开发者一站式基地

推荐文章
相似问题