Robot rotates near goal when goal is set in RViz

Hello. I am moving my robot NVIDIA Jetbot using move_base with gmapping, for navigation and vision using only LiDAR information (without odometry & encoders). The goal is set in RViz, and overall it works great with one exception - when robot reaches goal it starts to rotate a lot in one place.

I have tried to, logically, tune yaw_goal_tolerance in dwa_local_planner_params.yaml, but it seems that no values had solve this problem - small (i.e. 0.07), medium (i.e. 1.57) or even big (i.e. 6.28, and I assume yaw_goal_tolerance is measured in radians, and 6.28 equals to full 360 degrees, which means it should totally ignore any direction given, but it keeps rotating at the goal). I tried to also change xy_goal_tolerance, but that did not work as well. I've tried using Navigation Tuning Guide, but nothing related to my task helped me.

And I have also noticed that giving goal as a point in RViz (without direction) still makes robot rotate near goal. The issue might be in local trajectory, because in process of rotating it seems like local trajectory doesn't match global trajectory near goal, but I am not sure.

Can someone give me advice how to solve this? Is there anything that can help minimize rotating near goal?

Ubuntu 18.04, ROS Melodic

edit retag close merge delete

I've changed my path_distance_bias to 100 in dwa_local_planner, and it somehow helped a bit (but not fully). Not sure if this might be a solution, so I would still appreciate any advice on this problem!

( 2022-05-25 10:45:05 -0500 )edit

Sort by » oldest newest most voted

Did you try setting latch_xy_goal_tolerance to true?

~<name>/latch_xy_goal_tolerance (bool, default: false)
If goal tolerance is latched, if the robot ever reaches the goal xy location it will simply rotate in place, even if it ends up outside the goal tolerance while it is doing so. - New in navigation 1.3.1


If the localization is unstable around the goal point, you might get this kind of rotations.

more

Thank you for the advice! I set it to true, but it did not help. When I freshly launch Jetbot and move_base, robot moves to goal perfectly with minimum rotation. But when the second goal is set, robot gets to it as close as possible and then keeps rotating a lot. After approximately 3-7 seconds he stops and publishes message of successful achievement of goal.

( 2022-05-25 04:33:03 -0500 )edit