Skip to content

Commit

Permalink
AR_WPNav: use AC_OAPATHPLANNER_ENABLED
Browse files Browse the repository at this point in the history
  • Loading branch information
shiv-tyagi committed Aug 13, 2023
1 parent 20451f6 commit 730fc33
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions libraries/AR_WPNav/AR_WPNav_OA.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ void AR_WPNav_OA::update(float dt)
_destination_oabak = _destination;
}

#if AC_OAPATHPLANNER_ENABLED
AP_OAPathPlanner *oa = AP_OAPathPlanner::get_singleton();
if (oa != nullptr) {
Location oa_origin_new, oa_destination_new;
Expand Down Expand Up @@ -119,6 +120,7 @@ void AR_WPNav_OA::update(float dt)
} // switch (path_planner_used) {
} // switch (oa_retstate) {
} // if (oa != nullptr) {
#endif // AP_OAPATHPLANNER_ENABLED

update_oa_distance_and_bearing_to_destination();

Expand Down

0 comments on commit 730fc33

Please sign in to comment.