Skip to content

Commit

Permalink
avoic calling updateCurrentPoseAndSpeeds() before needed
Browse files Browse the repository at this point in the history
  • Loading branch information
jlblancoc committed Oct 5, 2024
1 parent acc731b commit 60b7b60
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions libs/nav/src/reactive/CWaypointsNavigator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -121,15 +121,15 @@ void CWaypointsNavigator::waypoints_navigationStep()
mrpt::system::CTimeLoggerEntry tle(m_timlog_delays, "CWaypointsNavigator::navigationStep()");
auto lck = mrpt::lockHelper(m_nav_waypoints_cs);

// 0) Get current robot pose:
CAbstractNavigator::updateCurrentPoseAndSpeeds();

if (wps.waypoints.empty() || wps.final_goal_reached)
{
// No nav request is pending or it was canceled
}
else
{
// Get current robot pose:
CAbstractNavigator::updateCurrentPoseAndSpeeds();

internal_select_next_waypoint();
}

Expand Down

0 comments on commit 60b7b60

Please sign in to comment.