ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Help on amcl usage and .yaml files

asked 2012-06-28 04:16:19 -0500

lgb gravatar image

updated 2014-01-28 17:12:50 -0500

ngrennan gravatar image

Hi folks,

I'm trying to build a map in the Stage environment using gmapping and posteriorly serving this map with map_server and using amcl to give the estimated position of the robot on the map.

I have already successfully build the map, and save it to a file (mymap.yaml and mymap.pgm) . I tried to get the estimated robot position by echoing topic /amcl_pose, but the pose I got was very different from the one in Stage, so I tried playing with origin and resolution parameters in the .yaml file.

But I'm in doubt about what would be the best way to correct the position given by /amcl_pose topic, and how to adjust origin and resolution parameters for that. It seems I'm not understanding correctly something very basic about the metrics of the map, can someone help me with that?

Thank you in advance, lgb.

edit retag flag offensive close merge delete

Comments

you can set your position on the map by programatically ( publishing /initialpose topic in your node ) or by using rviz 2D pose estimate then send simple nav goals check out for detailed information on amcl 's wiki page. Then you may localize yourself by using amcl

cagatay gravatar image cagatay  ( 2012-06-28 04:44:10 -0500 )edit

3 Answers

Sort by ยป oldest newest most voted
0

answered 2012-06-28 04:44:06 -0500

michikarg gravatar image

You can use RVIZ to provide your amcl localization with an initial position estimation. Then after driving around a little with your robot, the localization should work fine... expecially in simulation...

I don't think it is a good idea to "play around" with the resolution/position parameters if you are not really sure about what they mean. You should first check if you set up all sensor-streams and tf-settings correctly and visualize your map and localization in RVIZ...

What sensor are you using for localization?

edit flag offensive delete link more
0

answered 2012-07-01 21:56:40 -0500

michikarg gravatar image

I know that the place where your robot starts moving is the origin of the Odometry-frame. I guess it should then also be the origin of your map-frame.

But you should open a new topic on ROS answers for this question, since this question is not related to your original topic. I'm sure you then will find someone who knows the answer...

edit flag offensive delete link more
0

answered 2012-07-01 09:16:21 -0500

lgb gravatar image

Thank you guys, I was missing that. Another way, beside the way you described, is to launch amcl with the parameters _initial_pose_x, _initial_cov_xx, etc. The available parameters are listed on AMCL's ros page.

But it is still not clear how GMAPPING finds out where the origin is to build the map. Does it consider the place where he beggan moving as the origin?

edit flag offensive delete link more

Question Tools

Stats

Asked: 2012-06-28 04:16:19 -0500

Seen: 1,791 times

Last updated: Jul 01 '12