Fix position setpoint update logic in Mission RTL

Currently, when proceeding to the landing point the previous setpoint is not updated, which results in an unexpected and off course landing pattern in fixed wing. (see #25436)
This commit is contained in:
Matthew Berk
2025-09-22 17:35:06 -05:00
committed by GitHub
parent 9670eb69b3
commit 4000180cc9
@@ -203,10 +203,10 @@ void RtlDirectMissionLand::setActiveMissionItems()
_mission_item.autocontinue = true;
_mission_item.time_inside = 0.0f;
pos_sp_triplet->previous = pos_sp_triplet->current;
}
pos_sp_triplet->previous = pos_sp_triplet->current;
if (num_found_items > 0) {
mission_item_to_position_setpoint(next_mission_items[0u], &pos_sp_triplet->next);
}