Ask Your Question
0

how to configure the map to put its origin as in stage

asked 2012-10-15 22:51:10 -0500

Reza Ch gravatar image

updated 2012-10-19 03:08:36 -0500

Part 1: Hi, I already posted nearly same question but I ended up with sth new. I am using gmapping (localization and map) to run the navigation by move_base node and I have this famous error :

[ WARN] [1350293255.494001686]: The origin for the sensor at (-0.16, 0.68) is out of map bounds. So, the costmap cannot raytrace for it.

I am running a simple differential robot, gmapping node, laser node, and move_base.

As I found from some discussions, it seems that I didn’t realise that I had to configure the map to put its origin as in stage; so can it be the reason? if yes then the question is that how can I configure that?

Thanks in advance.

Part 2: Thanks for your answers. Now I am putting the global costmap static_map parameter to true. and the local costmap static_map parameter to false. and rolling_window to false as well and I set no map parameter in the yaml files. So it should take all from map_server. In my saved map file, the origin is [-10, -10] for a 20X20 map. but again I am receiving the out of map bound error!

The map is from map server (including map parameters of course). the laser data is going from the laser. the localization from gmapping. it is putting the robot foot print on origin so my laser will be out bound. How can I get rid of it then? Well generally how this map updating should go now? I want to have a implementation like the implementation in the link: http://www.ros.org/wiki/navigation/Tutorials/Using%20rviz%20with%20the%20Navigation%20Stack

I mean to have the general map and also have the online updating of the obstacles (not an updated map though).

edit retag flag offensive close merge delete

Comments

I added a 2nd part to my question.

Reza Ch gravatar imageReza Ch ( 2012-10-18 06:40:32 -0500 )edit

you might want to set the local costmap rolling_window to true (since static_map is false). Then look at RViz to see your map, and show your laser link and see where it is with reference to the map.

weiin gravatar imageweiin ( 2012-10-18 16:10:21 -0500 )edit

2 Answers

Sort by » oldest newest most voted
2

answered 2012-10-16 15:41:23 -0500

weiin gravatar image

updated 2012-10-18 16:17:23 -0500

This problem arises from your global costmap parameters. In your other question, you set the global costmap to NOT use static map ("static_map: false"). This means you have to give the costmap some data (height/width/resolution/origin), or it will default to a 10m by 10m costmap with origin at (0,0). This default costmap does not have any negative x, y cells since origin is at (0,0), so if your sensor is placed "behind" the robot centre, you get the "out-of-bounds" message.

Setting the costmap origin to some negative value would solve this problem (as mentioned in the other post). Usually this value is set such that your robot is in the centre of the costmap (so if using default 10m by 10m map, origin would be at -5,-5)

The other way is to set global costmap "static_map: true". This means you will need a map obtained from the map server. In this case, since you are using gmapping, the global costmap will take the initial map created when gmapping starts. You will not need to set any costmap data (height/width etc) and you should not get any out-of-bound message. However, this means you will not be able to set a goal beyond the size of the initial map obtained (but that's a problem in the path planner).

EDIT 19 Oct 2012:

These are good places to look when there are navigation problems:

http://www.ros.org/wiki/navigation/Tutorials/RobotSetup

http://www.ros.org/wiki/navigation/Tutorials/Navigation%20Tuning%20Guide

edit flag offensive delete link more
0

answered 2012-10-16 01:02:02 -0500

Lorenz gravatar image

According to the move_base configuration in your previous question, the map generated by gmapping should not be used at all by move_base (the static_map parameter is false for both maps). I don't really think that gmapping or the position of a map has anything to do with the above error.

edit flag offensive delete link more

Your Answer

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

Add Answer

Question Tools

2 followers

Stats

Asked: 2012-10-15 22:51:10 -0500

Seen: 3,518 times

Last updated: Oct 19 '12