Skip to content

Commit

Permalink
fix(start_planner): plan freespace pull over even if any path has nev…
Browse files Browse the repository at this point in the history
…er been found (autowarefoundation#4561)

Signed-off-by: kosuke55 <kosuke.tnp@gmail.com>
  • Loading branch information
kosuke55 committed Aug 13, 2023
1 parent da4c01d commit eecd9fb
Showing 1 changed file with 13 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1074,11 +1074,22 @@ bool GoalPlannerModule::isStopped()

bool GoalPlannerModule::isStuck()
{
constexpr double stuck_time = 5.0;
if (!isStopped(odometry_buffer_stuck_, stuck_time)) {
return false;
}

// not found safe path
if (!status_.is_safe) {
return true;
}

// any path has never been found
if (!status_.pull_over_path) {
return false;
}
constexpr double stuck_time = 5.0;
return isStopped(odometry_buffer_stuck_, stuck_time) && checkCollision(getCurrentPath());

return checkCollision(getCurrentPath());
}

bool GoalPlannerModule::hasFinishedCurrentPath()
Expand Down

0 comments on commit eecd9fb

Please sign in to comment.