批量设置 DO
注意:
该 API
用于批量设置机器人控制器上的 DO (Digital Output)
状态。
请求
- 编号: 6002 (0x1772)
- 名称: robot_other_setdos_req
- 描述: 批量设置 DO
- JSON 数据区: 见下
json
// 数据区必须为 JSON array, array 中的每个对象与 6001 指令中相同
// 以下为同时设置 DO 0,1,2,3 的状态,分别设置为高、高、低、低
[
{"id":0,"status":true},
{"id":1,"status":true},
{"id":2,"status":false},
{"id":3,"status":false}
]
1
2
3
4
5
6
7
8
2
3
4
5
6
7
8
请求示例
json
[
{"id":0,"status":true},
{"id":1,"status":true},
{"id":2,"status":false},
{"id":3,"status":false},
{"id":4,"status":true},
{"id":5,"status":true},
{"id":6,"status":false}
]
1
2
3
4
5
6
7
8
9
2
3
4
5
6
7
8
9
响应
- 编号: 16002 (0x3E82)
- 名称: robot_other_setdos_res
- 描述: 批量设置 DO 的响应
- JSON 数据区: 见下表
字段名 | 类型 | 描述 | 可缺省 |
---|---|---|---|
ret_code | number | API 错误码 | 是 |
create_on | string | API 上传时间戳 | 是 |
err_msg | string | 错误信息 | 是 |
响应示例
略
最近更新 2022/11/28
有用
没用