mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-04-14 10:07:39 +08:00
Fix VTOL stuck after back-transition in Mission Fast RTL
This commit is contained in:
parent
2a78d7dfd1
commit
618995da84
@ -169,8 +169,14 @@ void RtlMissionFast::setActiveMissionItems()
|
||||
|
||||
mission_item_to_position_setpoint(_mission_item, &pos_sp_triplet->current);
|
||||
|
||||
if (_vehicle_status_sub.get().vehicle_type == vehicle_status_s::VEHICLE_TYPE_FIXED_WING && isLanding() &&
|
||||
_mission_item.nav_cmd == NAV_CMD_WAYPOINT) {
|
||||
const bool fw_on_mission_landing = _vehicle_status_sub.get().vehicle_type == vehicle_status_s::VEHICLE_TYPE_FIXED_WING
|
||||
&& isLanding() &&
|
||||
_mission_item.nav_cmd == NAV_CMD_WAYPOINT;
|
||||
const bool mc_landing_after_transition = _vehicle_status_sub.get().vehicle_type ==
|
||||
vehicle_status_s::VEHICLE_TYPE_ROTARY_WING && _vehicle_status_sub.get().is_vtol &&
|
||||
new_work_item_type == WorkItemType::WORK_ITEM_TYPE_MOVE_TO_LAND;
|
||||
|
||||
if (fw_on_mission_landing || mc_landing_after_transition) {
|
||||
pos_sp_triplet->current.alt_acceptance_radius = FLT_MAX;
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user