mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-11-09 12:51:36 +08:00
Mission_block: only accept VTOL backtransition once in full MC mode
Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
This commit is contained in:
@@ -110,7 +110,9 @@ MissionBlock::is_mission_item_reached_or_completed()
|
||||
|
||||
if (int(_mission_item.params[0]) == 3) {
|
||||
// transition to RW requested, only accept waypoint if vehicle state has changed accordingly
|
||||
return _navigator->get_vstatus()->vehicle_type == vehicle_status_s::VEHICLE_TYPE_ROTARY_WING;
|
||||
const bool in_pure_mc_mode = _navigator->get_vstatus()->vehicle_type == vehicle_status_s::VEHICLE_TYPE_ROTARY_WING &&
|
||||
!_navigator->get_vstatus()->in_transition_mode;
|
||||
return in_pure_mc_mode;
|
||||
|
||||
} else if (int(_mission_item.params[0]) == 4) {
|
||||
// transition to FW requested, only accept waypoint if vehicle state has changed accordingly
|
||||
|
||||
Reference in New Issue
Block a user