Skip to content

Commit

Permalink
navigator land: don't project VTOL braking waypoint without global po…
Browse files Browse the repository at this point in the history
…sition
  • Loading branch information
MaEtUgR authored and sfuhrer committed Oct 25, 2024
1 parent b6eb8db commit b8a6024
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/modules/navigator/land.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,9 @@ void
Land::on_active()
{
/* for VTOL update landing location during back transition */
if (_navigator->get_vstatus()->is_vtol &&
_navigator->get_vstatus()->in_transition_mode) {
if (_navigator->get_vstatus()->is_vtol
&& _navigator->get_vstatus()->in_transition_mode
&& _navigator->get_local_position()->xy_global) {
struct position_setpoint_triplet_s *pos_sp_triplet = _navigator->get_position_setpoint_triplet();

// create a wp in front of the VTOL while in back-transition, based on MPC settings that will apply in MC phase afterwards
Expand Down

0 comments on commit b8a6024

Please sign in to comment.