检测到您已登录华为云国际站账号,为了您更好的体验,建议您访问国际站服务网站 https://www.huaweicloud.com/intl/zh-cn
不再显示此消息
ClientRequestException as e: print(e.status_code) print(e.request_id) print(e.error_code) print(e.error_msg) 1 2
线通信,具备即插即用、无需布线、易于安装等特点。 在该文档中,我们基于华为一站式开发工具平台(VS code工具IoTlink插件),从设备(小熊派开发套件)、平台(IoTDA华为物联网平台)、端到端构建一款智慧烟感解决方案样例,带您体验十分钟快速上云。实现智慧烟感检测并上报烟雾
ClientRequestException as e: print(e.status_code) print(e.request_id) print(e.error_code) print(e.error_msg) 1 2
上行Topic是指设备向平台发送请求,或上报数据,或回复响应。 下行Topic是指平台向设备下发指令,或回复响应。 设备与平台建立连接后,需要订阅下行Topic(华为云平台中具有隐式订阅功能,若通信质量为Qos0,平台的系统topic无需订阅。),否则无法收到平台下发的指令或回复的响
设备ID取值函数,JSON格式,平台通过解析该函数获取对应设备信息。 timestamp 是否开启时间戳校验 否 是否校验设备连接信息中的时间戳,如果设备连接参数(clientId、username)中包含时间戳建议开启校验。开启校验平台会对比设备携带时间戳与平台系统时间,若设备时间戳加一小时小于平台系统时间则校验失败。
设备属性 设备属性上报 网关批量设备属性上报 平台设置设备属性 平台查询设备属性 设备侧获取平台的设备影子数据 父主题: 设备侧MQTT/MQTTS接口参考
ClientRequestException as e: print(e.status_code) print(e.request_id) print(e.error_code) print(e.error_msg) 1 2
ClientRequestException as e: print(e.status_code) print(e.request_id) print(e.error_code) print(e.error_msg) 1 2
ClientRequestException as e: print(e.status_code) print(e.request_id) print(e.error_code) print(e.error_msg) 停止执行指定目标集合的子任务
name,设备发往设备发放平台时,为平台的Topic name,设备接收消息时,为设备的Topic name,具体参见Topic说明。 有效载荷(Payload)中的主要参数填写:为完整的数据上报和命令下发的消息内容,目前是一个JSON对象。 Topic说明 设备发放平台作为消息接收方时,
ClientRequestException as e: print(e.status_code) print(e.request_id) print(e.error_code) print(e.error_msg) 重新执行指定目标集合的子任务
ClientRequestException as e: print(e.status_code) print(e.request_id) print(e.error_code) print(e.error_msg) 创建编解码函数
文件上传/下载管理 设备上报获取文件上传URL请求 平台下发文件上传临时URL 设备上报文件上传结果 设备上报获取文件下载URL请求 平台下发文件下载临时URL 设备上报文件下载结果 父主题: 设备侧MQTT/MQTTS接口参考
(ConnectionException e) { e.printStackTrace(); } catch (RequestTimeoutException e) { e.printStackTrace();
ClientRequestException as e: print(e.status_code) print(e.request_id) print(e.error_code) print(e.error_msg) 1 2
ClientRequestException as e: print(e.status_code) print(e.request_id) print(e.error_code) print(e.error_msg) 1 2
ClientRequestException as e: print(e.status_code) print(e.request_id) print(e.error_code) print(e.error_msg) 1 2
ClientRequestException as e: print(e.status_code) print(e.request_id) print(e.error_code) print(e.error_msg) 创建OTA升
如果在通信过程中因为网络原因断开,模组会尝试重连并订阅已经订阅的主题。 - - +HMSTS:0 表示和IoT平台已经连接上 +HMSTS:1 表示网络原因和IoT平台断开 父主题: 模组AT指令参考
ClientRequestException as e: print(e.status_code) print(e.request_id) print(e.error_code) print(e.error_msg) 1 2