0
$\begingroup$

Rosanswers logo

I need to get the map -> odom transform which is the pose of the robot in the map frame. During the execution of my program, I serve a built map to the map server, so I fear that if I have gmapping running with the map server there may be a conflict, ie my program will subscribe to the wrong map topic.

Is there a way to get the map -> odom transform without using gmapping? Or if I use gmapping will it cause a conflict in my program, if I have an exisiting map on the map server?


Originally posted by kachilous on ROS Answers with karma: 31 on 2013-03-12

Post score: 1

$\endgroup$

2 Answers 2

0
$\begingroup$

Rosanswers logo

If i understand correctly, you only want to localize in a given (static?) map. Have a look at AMCL, which should be exactly what you need.

If you are building your own map dynamically, i think you have to set use_map_topic to true and first_map_only to false (default).


Originally posted by Ben_S with karma: 2510 on 2013-03-12

This answer was ACCEPTED on the original site

Post score: 0

$\endgroup$
0
$\begingroup$

Rosanswers logo

You can usually remap everything when running gmapping, i.e. the /map topic and possibly the /map frame (via param) for tf. If you do so gmapping will not interfere with other algorithms producing the same kind of data.


Originally posted by dornhege with karma: 31395 on 2013-03-12

This answer was NOT ACCEPTED on the original site

Post score: 1


Original comments

Comment by kachilous on 2013-03-12:
In the map -> odom transform that gmapping provides, where will it get the map data? From the map on the map server or on the map that gmapping has

Comment by dornhege on 2013-03-13:
gmapping make its own map.

Comment by kachilous on 2013-03-13:
So in calculating the transform map -> odom, instead of using the map that I've loaded on the map server, (which is what I want) it will instead use the map that it has created.

Comment by dornhege on 2013-03-13:
gmapping will always create and use its own map.

Comment by kachilous on 2013-03-13:
So if I want to know the location of the robot in my map that I built with gmapping, would it matter that gmapping uses its own map to calculate the map -> odom transform?

Comment by dornhege on 2013-03-14:
gmapping will only give you the position in the map that it builds right now. If you want to localize in a previously recorded map, use something like amcl. See @Ben_S answer for that.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.