DWA planner fails to produce path

asked 2021-07-09 06:38:57 -0600

Nadine gravatar image

Hi, all.

I am totally new in ROS and trying to set up ros navigation stack with an iRobot Create 2 and a sick tim 561 lidar sensor.

I am using ros melodic on ubunut 18.04 on a Raspberry Pi 4.

Packages i am using are:

  • create_robot version 1.3.0
  • sick_scan version 1.10.1
  • slam_gmapping version 1.4.2
  • navigation version 1.17.1

Mapping is done with the slam_gmapping-Package of Ros and works fine. Amcl-loalization seems to work fine as well (when i look at rviz the robot movement in real world and rviz match quiet well).

I have trouble getting pathplanning to work well. As global planner i am using NavfnROS and as local planner i am using DWAPlannerROS. It seems that the global planner works well and always finds a good global path as I can see in rviz. There is probably a problem with the local planner since the following warning occurs continuously:

"DWA planner failed to produce path".

Also the movement commands for the robot are strange. Sometimes the robot follows the global path but when it is close to the goal pose it speeds up and passes the target pose. After that the robot seems to just randomly move around.

Another scenario is that the robot moves in the wrong direction, away from the target pose, even when there is no obstacle between the robot and the goal pose. In this scenario it often ends up that the robot moves close to an obstacle, then does some recovery behaviors but gets stuck and the pathplanning is aborted.

I started out using the default parameters for move_base, the planners and the costmaps and then tried to adjusting them. In the following you can see my parameter files.

move_base_params.yaml:

base_global_planner: navfn/NavfnROS
base_local_planner:  dwa_local_planner/DWAPlannerROS

controller_frequency: 5.0
planner_patience: 5.0
controller_patience: 15.0
conservative_reset_dist: 3.0
recovery_behavior_enabled: true
clearing_rotation_allowed: true
planner_frequency: 0.0
max_planning_retries: -1

NavfnROS:
  allow_unknown: true
  planner_window_x: 0.0
  planner_window_y: 0.0
  default_tolerance: 0.0
  visualize_potential: false

DWAPlannerROS:
  #Robot Configuration Parameters
  acc_lim_x: 0.1
  acc_lim_y: 0.0  #differential drive robot
  acc_lim_th: 0.1
  max_vel_trans: 0.1
  min_vel_trans: 0.1
  max_vel_x: 0.1
  min_vel_x: 0.0  #negative for backwards motion
  max_vel_y: 0.0  #differential drive robot
  min_vel_y: 0.0  #differential drive robot
  max_vel_theta: 0.1
  min_vel_theta: 0.1

  #Goal Tolerance Parameters
  yaw_goal_tolerance: 0.1
  xy_goal_tolerance: 0.12
  latch_xy_goal_tolerance: false

  #Forward Simulation Parameters
  sim_time: 1.0
  sim_granularity: 0.07  #Step Size in meters, to take between points on a given trajectory
  vx_samples: 6
  vy_samples: 1  #default 10
  vth_samples: 20
  controller_frequency: 2.0

  #Trajectory Scoring Parameters
  path_distance_bias: 90.0
  goal_distance_bias: 24.0
  occdist_scale: 0.3
  forward_point_distance: 0.0
  stop_time_buffer: 0.2
  scaling_speed: 0.2
  max_scaling_factor: 0.2
  publish_cost_grid: false

  #Oscillation Prevention Parameters
  oscillation_reset_dist: 0.05

  #Global Plan Parameters
  prune_plan: true

common_costmap_params.yaml:

robot_radius: 0.1735

#Plugins
static_layer:
  unknown_cost_value: -1
  lethal_cost_threshold: 100
  map_topic: map
  first_map_only: false
  subscribe_to_updates: false
  track_unknown_space: false
  use_maximum: false
  trinary_costmap: true

obstacle_layer:
  #Sensor Management Parameters
  observation_sources:  sick_tim
  sick_tim/topic: cloud ...
(more)
edit retag flag offensive close merge delete