Ask Your Question
0

no local costmap

asked 2020-12-01 09:30:50 -0600

lslabon gravatar image

updated 2020-12-01 09:56:07 -0600

I am a little confused with the costmaps and pre hydro paramters, plugins etc...

I am using move base for my navigation and have a prebuild static map included. When launching the navigation there is no local_costmap visible. The global costmap looks like everything is working fine. I did not have this problem a few days ago. I do not remember changing anything... but this makes no sense so I must.

These are my .yaml files:

Costmap_common_params.yaml

footprint: [[-0.29, -0.26], [-0.29, 0.26], [0.29, 0.26], [0.29, -0.26]]

obstacle_layer:

  enabled:              true

  max_obstacle_height:  0.6

  combination_method:   1

  track_unknown_space:  true

  obstacle_range: 2.5

  raytrace_range: 3.0

  observation_sources:  scan_filtered

  scan_filtered:

    data_type: LaserScan

    topic: /scan_filtered

    marking: true

    clearing: true

    min_obstacle_height: 1

    max_obstacle_height: 5

inflation_layer:

  enabled: true

  cost_scaling_factor:  5.0

  inflation_radius:     0.5 


static_layer:

  enabled: true

Local_costmap_params.yaml

local_costmap:

  global_frame: "odom"

  robot_base_frame: "base_footprint"

  update_frequency: 10.0

  publish_frequency: 10.0

  always_send_full_costmap: true

  transform_tolerance: 0.5

  rolling_window: true

  width: 5

  height: 5

  resolution: 0.05

  origin_x: 0.0

  origin_y: 0.0

  plugins:

     {name: obstacle_layer, type: "costmap_2d::VoxelLayer"}

     {name: inflation_layer, type: "costmap_2d::InflationLayer"}

Global_costmap_params.yaml

global_costmap:

  global_frame: "map"

  robot_base_frame: "base_footprint"

  update_frequency: 10.0

  publish_frequency: 10.0

  always_send_full_costmap: true

  transform_tolerance: 0.5

  width: 100

  height: 100

  resolution: 0.05

  origin_x: 0.0

  origin_y: 0.0

  plugins:

     {name: static_layer, type: "costmap_2d::StaticLayer"}

     {name: obstacle_layer, type: "costmap_2d::VoxelLayer"}

     {name: inflation_layer, type: "costmap_2d::InflationLayer"}

I thought I did build the yaml. files correctly without using pre-hydro parameters but I use to get the WARNINGS 'Pre Hydro parameter static_map / map_type unused since plugins is provided... Can anybody tell me why this is?

I hope somebody can help me with this issue. Thank you!

Laura

edit retag flag offensive close merge delete

Comments

1

You don't appear to have scan_filtered defined properly in your obstacle_layer (common params). Try

...

observation_sources:  scan_filtered

scan_filtered:
  data_type: LaserScan
  topic: /scan_filtered
  marking: true
  clearing: true
  min_obstacle_height: 1
  max_obstacle_height: 5

...
tryan gravatar image tryan  ( 2020-12-01 09:46:39 -0600 )edit

Ah thanks yes - I forgot it when I wrote the question.. I just added it (and edited my question) So apparently costmap is still empty.

lslabon gravatar image lslabon  ( 2020-12-01 09:55:15 -0600 )edit

Do you definitely have incoming data on /scan_filtered? Does rostopic echo /move_base/local_costmap/costmap show an empty costmap?

tryan gravatar image tryan  ( 2020-12-01 10:53:33 -0600 )edit

I have incoming data on scan_filtered.. (-> rostopic echo /scan_filtered)

The local_costmap is empty (0 0 0 0 0 ...). Global_costmap (-1 -1 -1 -1 ...)

lslabon gravatar image lslabon  ( 2020-12-02 01:51:34 -0600 )edit

1 Answer

Sort by ยป oldest newest most voted
1

answered 2020-12-02 02:02:43 -0600

lslabon gravatar image

Finally got the answer... Found it here https://answers.ros.org/question/1939... I had to change min_obstacle_height to 0... He says it is because map wall in STDR is defined to be lower than my paramter (1) but I could only find STDR for kinetic and I am working with melodic. So I don't know whether (or where) I can change that to fit with my parameters. At least it is working for now :)

edit flag offensive delete link more

Comments

I'm glad you got it working! Simple Two Dimensional Robot Simulator (STDR) is an older simulation environment, so it's not likely something you need to worry about. The main thing is that the z limits on obstacle_layer overlap with the z limits on the sensor, and that the overlap occurs where you expect obstacles. Before, your layer had max_obstacle_height = 0.6, but your sensor had min_obstacle_height = 1 (no overlap). Out of curiosity, did your obstacle layer work in the global map before?

tryan gravatar image tryan  ( 2020-12-02 07:59:16 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2020-12-01 09:30:50 -0600

Seen: 517 times

Last updated: Dec 02 '20