Ask Your Question

Hector mapping stabilized frame

asked 2012-04-11 00:35:17 -0500

fmarques gravatar image

updated 2012-04-11 00:41:33 -0500


I'm working in a robot and started to use the hector mapping package in replacement of gmapping. I only have one doubt regarding the setting up your robot tutorial.

How can I provide the transformation between the base_link and base_stabilized, i have a mems imu and robot pose ekf implemented. So I simply add a new frame /base_stabilized) to tf??? Can anybody that already has this working in their robot help me out... Thanks

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted

answered 2012-04-11 21:50:17 -0500

Hi, I also recently noticed that the description in the tutorial is a bit misleading, as the base_footprint described there is not rigidly attached to the robot as it is the case with most robot models out there. I'll have to think about how improve the description :)

Now for your specific problem: Yes, you have to get to transform from the IMU published to tf. If your robot actually experiences significant roll/pitch motion, that is. If it doesn't, the 'base_stabilized' frame is not needed, as described in the tutorial.

I uploaded a very simple helper node for publishing roll/pitch attitude data from imu to tf just a few minutes ago here (not yet indexed on So what should work is the following: Copy/Use the example.launch and use your imu topic there. For the base_frame you have to use a body-fixed frame of your robot, let's use 'base_footprint' as an example. You now only have to get your odometry publisher to publish 'base_stabilized → odom' instead of 'base_footprint → odom'.

For hector_mapping you can then set the following parameters:

<param name="pub_map_odom_transform" value="true"/>
<param name="map_frame" value="map" />
<param name="base_frame" value="base_stabilized" />
<param name="odom_frame" value="odom" />

Let me know if that works for you.

edit flag offensive delete link more



Thanks, yesterday I managed to solve the problem, i modified my urdf so that the root link is base link. Created a node similiar to yours that publishes the roll a pitch of the base_stabilized -> base_link,

fmarques gravatar image fmarques  ( 2012-04-11 23:18:39 -0500 )edit

A a static transform publisher that gives me the base_footprint to base_stabilized height in my case the radius of the robot wheels. I was going to publish the answer also, but you explained it better. Thanks you.

fmarques gravatar image fmarques  ( 2012-04-11 23:19:23 -0500 )edit

Stefan, I would certainly like to see the example launch that you created. I am also struggling to learn Hector mapping.

Thank you very much, Morpheus

Morpheus gravatar image Morpheus  ( 2015-06-13 07:18:04 -0500 )edit

fmarques, how do you modify the urdf? I'm assuming there is an existing file somewhere. When I search for urdf, I get dozens of files; pr2.urdf.xacro, urdf.rvis, etc. many located in ros/indigo/share/

casper911ca gravatar image casper911ca  ( 2015-07-31 14:54:42 -0500 )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



Asked: 2012-04-11 00:35:17 -0500

Seen: 4,257 times

Last updated: May 07 '12