指令飞行

2025-01-07
暂无评分

Event

请求授权结果通知

Topic: thing/product/{gateway_sn}/events

Direction: up

Method: cloud_control_auth_notify

Data:

ColumnNameTypeconstraintDescription
result返回码int{"max":"","min":"","step":"","unit_name":null}非0代表错误
output输出struct
»status任务状态enum_string{"canceled":"有其他用户发起授权请求弹窗,本次弹窗被取消。","failed":"错误或者用户拒绝","ok":"用户同意"}

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"output": {
			"status": "ok"
		},
		"result": 0
	},
	"method": "cloud_control_auth_notify",
	"need_reply": 0,
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1704038400000
}

flyto 执行结果事件通知

Topic: thing/product/{gateway_sn}/events

Direction: up

Method: fly_to_point_progress

Data:

ColumnNameTypeconstraintDescription
fly_to_id飞向目标点 IDtext{"length":""}
status状态enum_string{"wayline_cancel":"取消飞向目标点","wayline_failed":"执行失败","wayline_ok":"执行成功,已飞向目标点","wayline_progress":"执行中"}
result返回码int{"max":"","min":"","step":"","unit_name":null}非 0 代表错误
way_point_index当前执行到第几个航点int{"max":"","min":"","step":"","unit_name":null}
remaining_distance剩余任务距离float{"max":"","min":"","step":0.1,"unit_name":"米 / m"}
remaining_time剩余任务时间float{"max":"","min":"","step":0.1,"unit_name":"秒 / s"}
planned_path_points规划的轨迹点列表array{"size": -, "item_type": struct}
»latitude轨迹点纬度double{"max":90,"min":-90,"step":"","unit_name":null}轨迹点纬度,角度值,南纬是负,北纬是正,精度到小数点后6位
»longitude轨迹点经度double{"max":180,"min":-180,"step":"","unit_name":null}轨迹点经度,角度值,东经是正,西经是负,精度到小数点后6位
»height轨迹点高度float{"step":0.1,"unit_name":"米 / m"}轨迹点高度,椭球高

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"fly_to_id": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
		"planned_path_points": [
			{
				"height": 123.234,
				"latitude": 13.23,
				"longitude": 123.234
			}
		],
		"remaining_distance": 0,
		"remaining_time": 0,
		"result": 0,
		"status": "wayline_progress",
		"way_point_index": 0
	},
	"need_reply": 1,
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 16540709686556,
	"method": "fly_to_point_progress"
}

一键起飞结果事件通知

Topic: thing/product/{gateway_sn}/events

Direction: up

Method: takeoff_to_point_progress

Data:

ColumnNameTypeconstraintDescription
status任务状态enum_string{"task_finish":"一键起飞任务完成","task_ready":"准备起飞","wayline_cancel":"取消飞向目标点","wayline_failed":"执行失败","wayline_ok":"执行成功,已飞向目标点","wayline_progress":"执行中"}
result返回码int{"max":"","min":"","step":"","unit_name":null}
flight_id一键起飞任务 UUIDtext{"length":""}
track_id航迹 IDtext{"length":""}
way_point_index当前执行到第几个航点int{"max":"","min":"","step":"","unit_name":null}
remaining_distance剩余任务距离float{"max":"","min":"","step":0.1,"unit_name":"米 / m"}
remaining_time剩余任务时间float{"max":"","min":"","step":0.1,"unit_name":"秒 / s"}
planned_path_points规划的轨迹点列表array{"size": -, "item_type": struct}
»latitude轨迹点纬度double{"max":90,"min":-90,"step":"","unit_name":null}轨迹点纬度,角度值,南纬是负,北纬是正,精度到小数点后6位
»longitude轨迹点经度double{"max":180,"min":-180,"step":"","unit_name":null}轨迹点经度,角度值,东经是正,西经是负,精度到小数点后6位
»height轨迹点高度float{"max":"","min":"","step":0.1,"unit_name":"米 / m"}轨迹点高度,椭球高

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"flight_id": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
		"planned_path_points": [
			{
				"height": 123.234,
				"latitude": 13.23,
				"longitude": 123.234
			}
		],
		"remaining_distance": 0,
		"remaining_time": 0,
		"result": 0,
		"status": "wayline_ok",
		"track_id": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
		"way_point_index": 1
	},
	"need_reply": 1,
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 16540709686556,
	"method": "takeoff_to_point_progress"
}

DRC 链路状态通知

Topic: thing/product/{gateway_sn}/events

Direction: up

Method: drc_status_notify

Data:

ColumnNameTypeconstraintDescription
result返回码int非 0 代表错误
drc_stateDRC 状态enum_int{"0":"未连接","1":"连接中","2":"已连接"}

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"drc_state": 2,
		"result": 0
	},
	"need_reply": 1,
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "drc_status_notify"
}

DRC-飞行控制无效原因通知

DRC-飞行控制是一个无人机综合控制功能,若不可用,则无法使用飞行控制能力

Topic: thing/product/{gateway_sn}/events

Direction: up

Method: joystick_invalid_notify

Data:

ColumnNameTypeconstraintDescription
reason任务状态int{"0":"遥控器失联","1":"低电量返航","2":"低电量降落","3":"靠近限飞区","4":"遥控器夺权(例如:触发了返航,B控夺权)"}

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"reason": 0
	},
	"need_reply": 1,
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "joystick_invalid_notify"
}

上报拍照进度

当拍照行为需持续进行时会通过该事件上报进度。目前仅支持:全景拍照模式

Topic: thing/product/{gateway_sn}/events

Direction: up

Method: camera_photo_take_progress

Data:

ColumnNameTypeconstraintDescription
output输出struct
»status拍照状态enum_string{"fail":"失败","in_progress":"执行中","ok":"完成"}
»progress进度struct
»»current_step执行步骤enum_int{"3000":"全景图拍摄未开始或者已结束","3002":"全景图正在拍摄","3005":"全景图合成中"}
»»percent进度值int{"max":"100","min":"0","step":"1"}
»ext扩展内容struct
»»camera_mode当前相机模式enum_int{"3":"全景拍照"}
result返回码int{"max":"","min":"","step":"","unit_name":null}非 0 代表错误

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"output": {
			"ext": {
				"camera_mode": 3
			},
			"progress": {
				"current_step": 0,
				"percent": 100
			},
			"status": "ok"
		},
		"result": 0
	},
	"need_reply": 1,
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "camera_photo_take_progress"
}

DRC-图传链路延时信息上报

Topic: thing/product/{gateway_sn}/drc/up

Direction: up

Method: delay_info_push

Data:

ColumnNameTypeconstraintDescription
sdr_cmd_delay图传协议命令链路延时int{"max":"","min":"","step":"","unit_name":"毫秒 / ms"}图传协议命令链路延时
liveview_delay_list图传视频码流延时array{"size": -, "item_type": struct}
»video_id码流编号text{"length":""}码流编号
»liveview_delay_time码流延时int{"max":"","min":"","step":"","unit_name":"毫秒 / ms"}码流延时

Example:

{
	"data": {
		"liveview_delay_list": [
			{
				"liveview_delay_time": 60,
				"video_id": "1581BN210004555439234/52-0-0/normal-0"
			},
			{
				"liveview_delay_time": 80,
				"video_id": "1581BN210004555439234/53-0-0/normal-0"
			}
		],
		"sdr_cmd_delay": 10
	},
	"timestamp": 1670415891013,
	"method": "delay_info_push"
}

DRC-避障信息上报

Topic: thing/product/{gateway_sn}/drc/up

Direction: up

Method: hsi_info_push

Data:

ColumnNameTypeconstraintDescription
up_distance上方的障碍物距离int{"max":"","min":"","step":"","unit_name":"毫米 / mm"}
down_distance下方的障碍物距离int{"max":"","min":"","step":"","unit_name":"毫米 / mm"}
up_enable上视避障开关状态bool{"0":"关闭","1":"开启"}
up_work上视避障工作状态bool{"0":"关闭","1":"开启"}
down_enable下视避障开关状态bool{"0":"关闭","1":"开启"}
down_work下视避障工作状态bool{"0":"关闭","1":"开启"}
around_distances周边的障碍物距离array{"size": -, "item_type": int}
left_enable左视避障开关状态bool{"0":"关闭","1":"开启"}
left_work左视避障工作状态bool{"0":"关闭","1":"开启"}
right_enable右视避障开关状态bool{"0":"关闭","1":"开启"}
right_work右视避障工作状态bool{"0":"关闭","1":"开启"}
front_enable前视避障开关状态bool{"0":"关闭","1":"开启"}
front_work前视避障工作状态bool{"0":"关闭","1":"开启"}
back_enable后视避障开关状态bool{"0":"关闭","1":"开启"}
back_work后视避障工作状态bool{"0":"关闭","1":"开启"}
vertical_enable垂直避障开关状态bool{"0":"关闭","1":"开启"}
vertical_work垂直避障工作状态bool{"0":"关闭","1":"开启"}
horizontal_enable水平避障开关状态bool{"0":"关闭","1":"开启"}
horizontal_work水平避障工作状态bool{"0":"关闭","1":"开启"}

Example:

{
	"data": {
		"around_distance": [
			10,
			8,
			9,
			16,
			2
		],
		"back_enable": true,
		"back_work": true,
		"down_distance": 10,
		"down_enable": true,
		"down_work": true,
		"front_enable": true,
		"front_work": true,
		"horizontal_enable": true,
		"horizontal_work": true,
		"left_enable": true,
		"left_work": true,
		"right_enable": true,
		"right_work": true,
		"up_distance": 10,
		"up_enable": true,
		"up_work": true,
		"vertical_enable": true,
		"vertical_work": true
	},
	"timestamp": 1670415891013,
	"method": "hsi_info_push"
}

返航信息

Topic: thing/product/{gateway_sn}/events

Direction: up

Method: return_home_info

Data:

ColumnNameTypeconstraintDescription
planned_path_points规划的轨迹点列表array{"size": -, "item_type": struct}
»latitude轨迹点纬度(角度值)double{"max":90,"min":-90}轨迹点纬度,角度值,南纬是负,北纬是正,精度到小数点后6位
»longitude轨迹点经度(角度值)double{"max":180,"min":-180}轨迹点经度,角度值,东经是正,西经是负,精度到小数点后6位
»height轨迹点高度float{"max":"","min":"","step":0.1,"unit_name":"米 / m"}轨迹点高度,椭球高
flight_id任务 IDtext{"length":""}

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"flight_id": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
		"planned_path_points": [
			{
				"height": 107.91999816894531,
				"latitude": 22.591622374020517,
				"longitude": 114.00506408885121
			},
			{
				"height": 107.91999816894531,
				"latitude": 22.591547439806163,
				"longitude": 114.00506366975605
			}
		]
	},
	"gateway": "7XJDLC10010639",
	"method": "return_home_info",
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1734446832046
}

Service

请求授权云端控制

请求后,遥控器会出现“请求授权”的弹窗。

Topic: thing/product/{gateway_sn}/services

Direction: down

Method: cloud_control_auth_request

Data:

ColumnNameTypeconstraintDescription
user_id用户IDtext{"length":""}请求授权的云端用户ID。
user_callsign用户呼号text{"length":""}请求授权的云端用户昵称。
control_keys控制权的键array{"size": 1, "item_type": text}请求飞行控制权,请填写“flight”。

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"control_keys": [
			"flight"
		],
		"user_callsign": "xxxxxxx",
		"user_id": "xxxxxxxxxxx"
	},
	"method": "cloud_control_auth_request",
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1704038400000
}

Topic: thing/product/{gateway_sn}/services_reply

Direction: up

Method: cloud_control_auth_request

Data:

ColumnNameTypeconstraintDescription
result返回码int{"max":"","min":"","step":"","unit_name":null}非0代表错误

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"output": {
			"status": "ok"
		},
		"result": 0
	},
	"method": "cloud_control_auth_request",
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1704038400000
}

释放云端控制

Topic: thing/product/{gateway_sn}/services

Direction: down

Method: cloud_control_release

Data:

ColumnNameTypeconstraintDescription
control_keys控制权列表array{"size": 1, "item_type": text}需要释放的控制权列表。“flight”代表飞行控制权。

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"control_keys": [
			"flight"
		]
	},
	"method": "cloud_control_release",
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1704038400000
}

Topic: thing/product/{gateway_sn}/services_reply

Direction: up

Method: cloud_control_release

Data:

ColumnNameTypeconstraintDescription
result返回码int{"max":"","min":"","step":"","unit_name":null}非0代表错误

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"output": {
			"status": "ok"
		},
		"result": 0
	},
	"method": "cloud_control_release",
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1704038400000
}

进入指令飞行控制模式

Topic: thing/product/{gateway_sn}/services

Direction: down

Method: drc_mode_enter

Data:

ColumnNameTypeconstraintDescription
mqtt_brokerBroker 连接信息struct获取 MQTT 中继服务的地址与认证信息
»address服务器连接地址text服务器连接地址,例如:192.0.2.1:8883, mqtt.dji.com:8883
»client_id客户端 IDtext可自定义的 MQTT 客户端 ID。建议使用设备的 SN 码,也可以与具有语义的前缀组合,例如,drc-4J4R101
»username用户名text建立连接时使用的用户名
»password密码text建立连接时认证所需要的密码
»expire_time认证信息过期时间int{"unit_name":"秒 / s"}在有效期内认证信息可以重复使用,另外认证信息过期后,并不会影响已建立连接的设备
»enable_tls是否启用 TLSbool启用 TLS 即对 MQTT 链路开启加密
osd_frequencyOSD 频率int{"max":30,"min":1,"unit_name":"赫兹 / Hz"}设置 OSD 上报频率
hsi_frequencyHSI 频率int{"max":30,"min":1,"unit_name":"赫兹 / Hz"}设置 HSI 上报频率

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"hsi_frequency": 1,
		"mqtt_broker": {
			"address": "mqtt.dji.com:8883",
			"client_id": "sn_a",
			"enable_tls": true,
			"expire_time": 1672744922,
			"password": "jwt_token",
			"username": "sn_a_username"
		},
		"osd_frequency": 10
	},
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "drc_mode_enter"
}

Topic: thing/product/{gateway_sn}/services_reply

Direction: up

Method: drc_mode_enter

Data:

ColumnNameTypeconstraintDescription
result返回码int非 0 代表错误

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"result": 0
	},
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "drc_mode_enter"
}

退出指令飞行控制模式

Topic: thing/product/{gateway_sn}/services

Direction: down

Method: drc_mode_exit

Data: null

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {},
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "drc_mode_exit"
}

Topic: thing/product/{gateway_sn}/services_reply

Direction: up

Method: drc_mode_exit

Data:

ColumnNameTypeconstraintDescription
result返回码int非 0 代表错误

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"result": 0
	},
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "drc_mode_exit"
}

一键起飞

Topic: thing/product/{gateway_sn}/services

Direction: down

Method: takeoff_to_point

Data:

ColumnNameTypeconstraintDescription
target_latitude目标点纬度(角度值)double{"max":90,"min":-90,"step":"","unit_name":null}
target_longitude目标点经度(角度值)double{"max":180,"min":-180,"step":"","unit_name":null}
target_height目标点高度float{"max":1500,"min":2,"step":0.1,"unit_name":"米 / m"}
security_takeoff_height安全起飞高度float{"max":1500,"min":20,"step":0.1,"unit_name":"米 / m"}
rth_mode【必填】返航模式设置值enum_int{"0":"智能高度","1":"设定高度"}
rth_altitude返航高度int{"max":1500,"min":2,"step":1,"unit_name":"米 / m"}
rc_lost_action遥控器失控动作enum_int{"0":"悬停","1":"着陆(降落)","2":"返航"}
commander_mode_lost_action【必填】指点飞行失控动作enum_int{"0":"继续执行指点飞行任务","1":"退出指点飞行任务,执行普通失控行为"}
commander_flight_mode【必填】指点飞行模式设置值enum_int{"0":"智能高度飞行","1":"设定高度飞行"}
commander_flight_height【必填】指点飞行高度float{"max":3000,"min":2,"step":0.1,"unit_name":"米 / m"}
flight_id一键起飞任务 UUIDtext{"length":""}
max_speed一键起飞的飞行过程中能达到的最大速度int{"max":15,"min":1,"step":"","unit_name":"米每秒 / m/s"}
simulate_mission是否在模拟器中执行任务struct
»is_enable是否开启模拟器任务enum_int{"0":"不开启","1":"开启"}当次任务打开或关闭模拟器
»latitude纬度double{"max":"90.0","min":"-90.0"}
»longitude经度double{"max":"180.0","min":"-180.0"}
flight_safety_advance_check飞行安全预检查bool{"0":"关闭","1":"开启"}设置一键起飞和航线任务中的飞行安全是否预先检查。此字段为可选,默认为0,值为0表示关闭,1表示开启。飞行安全预先检查表示: 飞行器执行任务前,检查自身作业区文件是否与云端一致,如果不一致则拉取文件更新,如果一致则不处理

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"commander_flight_height": 80,
		"commander_mode_lost_action": 1,
		"flight_id": "ABDEAC21DCADDA",
		"flight_safety_advance_check": 1,
		"max_speed": 12,
		"rc_lost_action": 0,
		"rth_altitude": 100,
		"security_takeoff_height": 100,
		"target_height": 100,
		"target_latitude": 12.23,
		"target_longitude": 12.32
	},
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "takeoff_to_point"
}

Topic: thing/product/{gateway_sn}/services_reply

Direction: up

Method: takeoff_to_point

Data:

ColumnNameTypeconstraintDescription
result返回码int{"max":"","min":"","step":"","unit_name":null}

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"result": 0
	},
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "takeoff_to_point"
}

flyto 飞向目标点

特别说明:飞机有最低飞行高度(20m)安全保障机制,如果飞机相对起飞点高度低于20m,会先上升到20m

Topic: thing/product/{gateway_sn}/services

Direction: down

Method: fly_to_point

Data:

ColumnNameTypeconstraintDescription
fly_to_id飞向目标点 IDtext
max_speedflyto 的飞行过程中能达到的最大速度int{"max":15,"min":0,"unit_name":"米每秒 / m/s"}
pointsflyto 目标点列表array{"size": -, "item_type": struct}仅支持 1 个目标点
»latitude目标点纬度(角度值)double{"max":90,"min":-90}目标点纬度,角度值,南纬是负,北纬是正,精度到小数点后6位
»longitude目标点经度(角度值)double{"max":180,"min":-180}目标点经度,角度值,东经是正,西经是负,精度到小数点后6位
»height目标点高度float{"max":10000,"min":2,"step":0.1,"unit_name":"米 / m"}目标点高度(椭球高),使用 WGS84 模型

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"fly_to_id": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
		"max_speed": 12,
		"points": [
			{
				"height": 100,
				"latitude": 12.23,
				"longitude": 12.23
			}
		]
	},
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "fly_to_point"
}

Topic: thing/product/{gateway_sn}/services_reply

Direction: up

Method: fly_to_point

Data:

ColumnNameTypeconstraintDescription
result返回码int非 0 代表错误

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"result": 0
	},
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "fly_to_point"
}

结束 flyto 飞向目标点任务

Topic: thing/product/{gateway_sn}/services

Direction: down

Method: fly_to_point_stop

Data: null

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {},
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "fly_to_point_stop"
}

Topic: thing/product/{gateway_sn}/services_reply

Direction: up

Method: fly_to_point_stop

Data:

ColumnNameTypeconstraintDescription
result返回码int非 0 代表错误

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"result": 0
	},
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "fly_to_point_stop"
}

更新 flyto 目标点

「一键起飞」或「flyto 飞向目标点」的过程中,可以通过该命令快速更新目标点

Topic: thing/product/{gateway_sn}/services

Direction: down

Method: fly_to_point_update

Data:

ColumnNameTypeconstraintDescription
max_speed指令飞行过程中能达到的最大速度int{"max":"15","min":"1","step":"","unit_name":"米每秒 / m/s"}
points更新的目标点列表array{"size": -, "item_type": struct}
»latitude维度double{"max":"","min":"","step":"","unit_name":null}
»longitude维度double{"max":"","min":"","step":"","unit_name":null}
»height高度float{"max":"","min":"","step":"","unit_name":null}

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"max_speed": 12,
		"points": [
			{
				"height": 100,
				"latitude": 12.23,
				"longitude": 12.23
			}
		]
	},
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "fly_to_point_update"
}

Topic: thing/product/{gateway_sn}/services_reply

Direction: up

Method: fly_to_point_update

Data:

ColumnNameTypeconstraintDescription
result返回码int{"max":"","min":"","step":"","unit_name":null}非 0 代表错误

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"result": 0
	},
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "fly_to_point_update"
}

一键返航

Topic: thing/product/{gateway_sn}/services

Direction: down

Method: return_home

Data: null

Example:

{
	"bid": "f9f07aad-d1f1-4dc1-8ad0-a3417fd365cc",
	"data": null,
	"method": "return_home",
	"tid": "b103b00a-3fcc-476e-9cb6-bc5e27d2defd",
	"timestamp": 1734425015702
}

Topic: thing/product/{gateway_sn}/services_reply

Direction: up

Method: return_home

Data:

ColumnNameTypeconstraintDescription
result返回码int{"max":"","min":"","step":"","unit_name":null}非 0 代表错误

Example:

{
	"bid": "f9f07aad-d1f1-4dc1-8ad0-a3417fd365cc",
	"data": {
		"result": 0
	},
	"method": "return_home",
	"tid": "b103b00a-3fcc-476e-9cb6-bc5e27d2defd",
	"timestamp": 1734425014635
}

取消返航

返航后,飞行器会退出航线模式,此时取消返航,飞行器会悬停

Topic: thing/product/{gateway_sn}/services

Direction: down

Method: return_home_cancel

Data: null

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {},
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "return_home_cancel"
}

Topic: thing/product/{gateway_sn}/services_reply

Direction: up

Method: return_home_cancel

Data:

ColumnNameTypeconstraintDescription
result返回码int{"max":"","min":"","step":"","unit_name":null}非 0 代表错误

Example:

{
	"bid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"data": {
		"result": 0
	},
	"need_reply": 1,
	"tid": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxx",
	"timestamp": 1654070968655,
	"method": "return_home_cancel"
}
若您对文档有意见或疑惑,点击可快速反馈,我们会与您联系。