Ask Your Question
0

Static Map corner at origin for Navigation Stack

asked 2018-03-15 20:36:07 -0600

hni19 gravatar image

Going through the tutorials for the ROS Navigation stack, using a static map generated through gmapping.

This is done on a simulation. When to robot is initialized, it is located at the origin. I perform gmapping and the map is generated, centered around origin.

However, after launching the navigation stack, following the tutorial, the static map seems to have the corner located at origin, and thus leads to

[ WARN] [1521163803.387421877, 5297.630000000]: The origin for the sensor at (-0.10, 0.03) is out of map bounds. So, the costmap cannot raytrace for it.

image description image description

Note: If i add the map through map_server, and visualize it through RVIZ, then the map is properly centered with the center of the map on origin. I am vaguely aware about the ability to add offsets to the static map. But not too clear on how, and I feel as though static offsets arn't an ideal solution, if the size of the map can change.

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2018-03-15 22:35:50 -0600

hni19 gravatar image

Just solved the issue. The navigation tutorial directs you to use the pgm (image file) of the map. Using the YAML file instead provides resolution as well as the correct origin offsets.

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

1 follower

Stats

Asked: 2018-03-15 20:36:07 -0600

Seen: 257 times

Last updated: Mar 15 '18