mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-22 04:03:33 +08:00
Navigator: make sure to reset mission.item fields touched by set_vtol_transition_item (#21641)
set_vtol_transition_item sets the params of the mission item directly to values that make sense for NAV_CMD_DO_VTOL_TRANSITION, but don't for other NAV_CMDs. So make sure that whenever we use it, we then in the next step reset the touched mission_item fields. Signed-off-by: Silvan Fuhrer <silvan@auterion.com>
This commit is contained in:
@@ -982,7 +982,10 @@ Mission::set_mission_items()
|
||||
_mission_item.altitude_is_relative = false;
|
||||
_mission_item.nav_cmd = NAV_CMD_WAYPOINT;
|
||||
_mission_item.autocontinue = true;
|
||||
_mission_item.time_inside = 0.0f;
|
||||
|
||||
// have to reset here because these field were used in set_vtol_transition_item
|
||||
_mission_item.time_inside = 0.f;
|
||||
_mission_item.acceptance_radius = _navigator->get_acceptance_radius();
|
||||
|
||||
// make previous setpoint invalid, such that there will be no prev-current line following.
|
||||
// if the vehicle drifted off the path during back-transition it should just go straight to the landing point
|
||||
|
||||
Reference in New Issue
Block a user