ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

DWA suddenly stops when it arrives to the goal

asked 2021-08-10 03:56:17 -0500

rappy gravatar image

updated 2021-08-11 02:07:17 -0500

I am using move_base and dwa_local_planner. Robot moves smoothly at start but when it arrives to goal it suddenly stops instead of slowing down when getting closer to the goal. I have tried different acceleration values but it didn't effect the behavior. My planner parameters are set like this

DWAPlannerROS:
  max_vel_trans: 1.0
  min_vel_trans: 0.1

  max_vel_x: 1.0
  min_vel_x: -1.0
  max_vel_theta: 1.0 
  min_vel_theta: 0.1 
  max_vel_y: 0.0
  min_vel_y: 0.0

  acc_lim_x: 0.15
  acc_lim_y: 0.0
  acc_lim_theta: 0.35
  acc_lim_trans: 0.15
  prune_plane: true  

  xy_goal_tolerance: 0.5
  yaw_goal_tolerance: 6.28
  latch_xy_goal_tolerance: false

  sim_time: 1.5
  sim_granularity: 0.1
  angular_sim_granularity: 0.1
  vx_samples: 20
  vy_samples: 1
  vth_samples: 20

  path_distance_bias: 32.0
  goal_distance_bias: 15.0
  occdist_scale: 0.02
  forward_point_distance: 0.325
  stop_time_buffer: 0.2
  scaling_speed: 0.25
  max_scaling_factor: 0.2
  oscillation_reset_dist: 0.05

  publish_traj_pc : true
  publish_cost_grid_pc: true
  controller_frequency: 1.0

Example of this behavior can be seen from rqt plots

image description image description

Edit 1: I have noticed that yaw goal tolerance is too high which prevents rotating_to_goal behavior in computeVelocityCommandsStopRotate function at the end and directly sets cmd_vel to 0. However, it still doesn't fix sudden stop problem if the goal yaw and final position yaw is in the given tolerance

edit retag flag offensive close merge delete

Comments

Why do we not see cmd_vel.linear.x in these plots? What is the black line?

Mike Scheutzow gravatar image Mike Scheutzow  ( 2021-08-11 20:39:28 -0500 )edit

Black line is cmd_vel actually I have changed the plot style manually but I think rqt didn't update the legend

rappy gravatar image rappy  ( 2021-08-12 02:00:07 -0500 )edit
1

A couple thoughts on your DWAPlanner config:

Your controller_frequency is insanely low, and is not consistent with the black dots in first plot. Most people prefer to inherit this rate from the parent move_base.

Under normal circumstances, DWAPlanner will linearly ramp the x velocity down to 0 once it is a certain distance from the goal. Your very low acc_lim_x and very short stop_time_buffer might be interfering with this ramp-down mechanism.

Mike Scheutzow gravatar image Mike Scheutzow  ( 2021-08-12 20:54:55 -0500 )edit

You are right I forgot to remove controller frequency parameter from this config and it is set to 15 in move_base config. So I have changed the parameters you have suggested to and it fixed the problem. Thanks for the advice.

acc_lim_trans: 0.3
acc_lim_x: 0.3
stop_time_buffer: 1
rappy gravatar image rappy  ( 2021-08-13 03:27:41 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
1

answered 2021-08-13 08:52:25 -0500

Mike Scheutzow gravatar image

A couple thoughts on your DWAPlanner config:

Your controller_frequency is insanely low, and is not consistent with the black dots in first plot. Most people prefer to inherit this rate from the parent move_base.

Under normal circumstances, DWAPlanner will linearly ramp the x velocity down to 0 once it is a certain distance from the goal. Your very low acc_lim_x and very short stop_time_buffer might be interfering with this ramp-down mechanism.

edit flag offensive delete link more

Question Tools

2 followers

Stats

Asked: 2021-08-10 03:56:17 -0500

Seen: 254 times

Last updated: Aug 13 '21