mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-25 15:43:35 +08:00
Commander: add position slow mode
This commit is contained in:
@@ -540,6 +540,10 @@
|
||||
"name": "stab",
|
||||
"description": "Stabilized"
|
||||
},
|
||||
"9": {
|
||||
"name": "position_slow",
|
||||
"description": "Position Slow"
|
||||
},
|
||||
"10": {
|
||||
"name": "auto_takeoff",
|
||||
"description": "Takeoff"
|
||||
|
||||
@@ -51,6 +51,7 @@ static inline uint32_t getValidNavStates()
|
||||
(1u << vehicle_status_s::NAVIGATION_STATE_AUTO_MISSION) |
|
||||
(1u << vehicle_status_s::NAVIGATION_STATE_AUTO_LOITER) |
|
||||
(1u << vehicle_status_s::NAVIGATION_STATE_AUTO_RTL) |
|
||||
(1u << vehicle_status_s::NAVIGATION_STATE_POSITION_SLOW) |
|
||||
(1u << vehicle_status_s::NAVIGATION_STATE_ACRO) |
|
||||
(1u << vehicle_status_s::NAVIGATION_STATE_TERMINATION) |
|
||||
(1u << vehicle_status_s::NAVIGATION_STATE_OFFBOARD) |
|
||||
@@ -62,7 +63,7 @@ static inline uint32_t getValidNavStates()
|
||||
(1u << vehicle_status_s::NAVIGATION_STATE_ORBIT) |
|
||||
(1u << vehicle_status_s::NAVIGATION_STATE_AUTO_VTOL_TAKEOFF);
|
||||
|
||||
static_assert(vehicle_status_s::NAVIGATION_STATE_MAX == 31, "code requires update");
|
||||
static_assert(vehicle_status_s::NAVIGATION_STATE_MAX == 31, "update valid nav states");
|
||||
}
|
||||
|
||||
const char *const nav_state_names[vehicle_status_s::NAVIGATION_STATE_MAX] = {
|
||||
@@ -72,7 +73,7 @@ const char *const nav_state_names[vehicle_status_s::NAVIGATION_STATE_MAX] = {
|
||||
"Mission",
|
||||
"Hold",
|
||||
"Return",
|
||||
"6: unallocated",
|
||||
"Position Slow",
|
||||
"7: unallocated",
|
||||
"8: unallocated",
|
||||
"9: unallocated",
|
||||
|
||||
Reference in New Issue
Block a user