why the costmaps don't clear obstacles in time when using move_base package?

asked 2014-06-05 22:37:43 -0600

Yuichi Chu gravatar image

updated 2014-06-13 12:38:25 -0600

David Lu gravatar image

Hello all, I am using gmapping and move_base to navigate and generate a map.But I ran into a problem.Becaust of the interference of external factors to laser(URG04LX),the map may take several points as obstacles.But with the robot moving ,the map updates and the points (fake obstacles) are cleared.But the costmap donot clear the points in time ,even several minutes after the map have already cleared those points.Picture 1 is the costmap and Picture2 is the map at the same time.As we can see ,the costmap take those yellow points as obstacles including those around the robot which actually has already been cleared on the map.As a result the robot was stuck and can't rotate.

Picture1 : costmap

Picture2 : map

I donot know if I have something wrong with configuration of costmap,so I paste the files below. base_local_planner_params.yaml:

  max_vel_x: 0.20   
  min_vel_x: 0.08
  max_rotational_vel: 0.23  
  min_in_place_rotational_vel: 0.05

  acc_lim_th: 1.05
  acc_lim_x: 1.0
  acc_lim_y: 1.0

  holonomic_robot: false


obstacle_range: 5.0       
raytrace_range: 5.0         
footprint: [[0.5, 0.25],
            [-0.3, 0.25],
            [-0.3, -0.25],
            [0.5, -0.25]]                   
inflation_radius: 0.15   
observation_sources: laser_scan_sensor 
laser_scan_sensor: {sensor_frame: base_laser, data_type: LaserScan, topic: scan, marking: true, clearing: true}


  global_frame: /map
  robot_base_frame: base_link
  update_frequency: 0.5
  publish_frequency: 0.5
  static_map: false
  rolling_window: true

  width: 190.0
  height: 190.0
  resolution: 0.03


  global_frame: odom
  robot_base_frame: base_link
  update_frequency: 0.5       
  publish_frequency: 0.5        
  static_map: false
  rolling_window: true
  width: 3.0
  height: 3.0
  resolution: 0.03


<?xml version="1.0"?>
  <master auto="start"/>

  <node pkg="move_base" type="move_base" respawn="false" name="move_base" output="screen">
    <rosparam file="$(find SEU_Jolly_2dnav)/costmap_common_params.yaml" command="load" ns="global_costmap" />
    <rosparam file="$(find SEU_Jolly_2dnav)/costmap_common_params.yaml" command="load" ns="local_costmap" />
    <rosparam file="$(find SEU_Jolly_2dnav)/local_costmap_params.yaml" command="load" />
    <rosparam file="$(find SEU_Jolly_2dnav)/global_costmap_params.yaml" command="load" />
    <rosparam file="$(find SEU_Jolly_2dnav)/base_local_planner_params.yaml" command="load" />
    <param name="controller_frequency" value="5.0" />

Has anyone met the problem before?Any advice will be appreciated.Thank you very much.


edit retag flag offensive close merge delete


Where did the yellow points come from? Is it leftover from the localization, or from the sensors?

David Lu gravatar image David Lu  ( 2014-06-13 12:39:23 -0600 )edit

Hi YuiChi Chu,

I have exactly same problem as yours. Did you get solution ?


WB gravatar image WB  ( 2015-12-16 02:01:27 -0600 )edit

Same problem here. Any answers?

Usman Arif gravatar image Usman Arif  ( 2016-04-09 23:26:31 -0600 )edit

I think your laser sensor cannot update map information until your robot moves. My suggestion is calling service move_base/clear_costmaps before your new navigation task. Hope it helps!

WB gravatar image WB  ( 2016-04-11 02:31:36 -0600 )edit