通讯协议
协议结构
参数名称 |
类型 |
描述 |
action_type |
int |
操作类型 |
msgInfo |
object |
每个接口特有的参数,详见每个接口定义 |
数据格式
心跳
参数名称 |
类型 |
描述 |
action_type |
int |
0 |
msgInfo |
object |
|
msgInfo 参数如下
参数名称 |
类型 |
描述 |
name |
string |
程序名称 |
version |
string |
版本信息 |
查询软件参数信息
参数名称 |
类型 |
描述 |
action_type |
int |
1 |
参数名称 |
类型 |
描述 |
action_type |
int |
1 |
msgInfo |
Dictionary < string, string > |
设置信息 |
修改软件参数信息
参数名称 |
类型 |
描述 |
action_type |
int |
2 |
msgInfo |
Dictionary < string, string > |
设置信息 |
参数名称 |
类型 |
描述 |
action_type |
int |
2 |
msgInfo |
object |
|
msgInfo 参数如下
参数名称 |
类型 |
描述 |
status |
bool |
true: 成功; false: 失败; |
message |
string |
异常信息 |
查询日志
参数名称 |
类型 |
描述 |
action_type |
int |
3 |
msgInfo |
object |
|
msgInfo 参数如下
参数名称 |
类型 |
描述 |
type |
int |
0: 系统事件; 1: 用户操作; 2: 视频通道; |
date |
string |
日期 |
index |
int |
通道号(仅视频通道日志有效) |
month |
bool |
true: 检索全月; false: 不检索全月 |
参数名称 |
类型 |
描述 |
action_type |
int |
3 |
msgInfo |
object[] |
|
**msgInfo ** 参数如下
参数名称 |
类型 |
描述 |
timestamp |
DateTime |
事件事件 |
type |
int |
事件类型 |
index |
int |
视频通道日志类型时为通道号,其他为空 |
message |
string |
消息 |
data |
string |
详细信息 |
添加日志
参数名称 |
类型 |
描述 |
action_type |
int |
4 |
msgInfo |
object |
|
msgInfo 参数如下
参数名称 |
类型 |
描述 |
timestamp |
DateTime |
事件事件 |
type |
int |
事件类型 |
index |
int |
视频通道日志类型时为通道号,其他为空 |
message |
string |
消息 |
data |
string |
详细信息 |
查询录像
参数名称 |
类型 |
描述 |
action_type |
int |
5 |
msgInfo |
object |
|
msgInfo 参数为空,查询最早的一条录像数据
msgInfo 参数如下, 按通道、开始日期、结束日期参数查询录像数据
参数名称 |
类型 |
描述 |
channel |
int |
通道号 |
start_date |
DateTime |
开始日期 |
end_date |
DateTime |
结束日期 |
msgInfo 参数如下, 按日期查询录像数据
参数名称 |
类型 |
描述 |
date |
DateTime |
日期 |
参数名称 |
类型 |
描述 |
action_type |
int |
5 |
msgInfo |
object[] |
|
**msgInfo ** 参数如下
参数名称 |
类型 |
描述 |
channel |
int |
通道号 |
start_date |
DateTime |
开始日期 |
end_date |
DateTime |
结束日期 |
duration |
int |
录像时长 |
name |
string |
文件名称 |
path |
string |
文件路径 |
更新录像数据
参数名称 |
类型 |
描述 |
action_type |
int |
6 |
msgInfo |
object |
|
**msgInfo ** 参数如下
参数名称 |
类型 |
描述 |
channel |
int |
通道号 |
start_date |
DateTime |
开始日期 |
end_date |
DateTime |
结束日期 |
duration |
int |
录像时长 |
name |
string |
文件名称 |
path |
string |
文件路径 |
删除录像数据
参数名称 |
类型 |
描述 |
action_type |
int |
7 |
msgInfo |
object |
|
msgInfo 参数如下, 按文件路径删除录像
参数名称 |
类型 |
描述 |
path |
string |
文件路径 |
msgInfo 参数如下, 按录像日期删除录像
参数名称 |
类型 |
描述 |
date |
DateTime |
日期 |
创建报警视频
参数名称 |
类型 |
描述 |
action_type |
int |
10 |
msgInfo |
object |
|
msgInfo 参数如下
参数名称 |
类型 |
描述 |
channel |
int |
通道 |
timestamp |
string |
报警时间 |
车辆状态
参数名称 |
类型 |
描述 |
action_type |
int |
100 |
msgInfo |
object |
|
msgInfo 参数如下
参数名称 |
类型 |
描述 |
speed |
float |
车速 |
brake |
int |
刹车 1: 刹车 0: 未刹车 |
reversing |
int |
倒车 1: 倒车 0: 未倒车 |
left |
int |
左转向 1: 转向 0: 未转向 |
right |
int |
右转向 1: 转向 0: 未转向 |
智能分析数据
参数名称 |
类型 |
描述 |
action_type |
int |
101 |
msgInfo |
object |
|
msgInfo 参数如下
参数名称 |
类型 |
描述 |
timestamp |
DateTime |
报警事件 |
channel |
int |
通道 |
level |
int |
报警级别 |
event_type |
int |
事件类型 |
object_infos |
object[] |
目标信息 |
face_land_marks |
object[] |
人脸关键点 |
left_line_type |
int |
左车道线类型 |
right_line_type |
int |
右车道线类型 |
object_infos 参数如下
参数名称 |
类型 |
描述 |
detect_type |
int |
目标类型 |
left |
int |
目标位置左 |
top |
int |
目标位置上 |
right |
int |
目标位置右 |
bottom |
int |
目标位置下 |
distance |
float |
距离 [0, 250] |
speed |
float |
相对运动目标的相对速度 (m/s) |
ttc |
float |
ttc 时间 (s) |
target_post_x |
int |
落脚点横坐标 (BSD用) |
target_post_y |
int |
落脚点纵坐标 (BSD用) |
face_land_marks 参数如下
参数名称 |
类型 |
描述 |
x |
int |
x坐标 |
y |
int |
y坐标 |