ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | Q&A
Ask Your Question

How do I orient fake_localization with stage? [closed]

asked 2012-09-17 19:25:24 -0500


I am confused about coordinate frame orientation when using stage and fake_localization. First of all, I have my simulation working with amcl, but I want to use fake_localization to get better performance.

So, I have a worldfile for stage that loads a map. The map origin is the bottom left corner, and I give stage an offset, so that the map is centered in the stage window: (from my stage .world file)

floorplan (
  # Size in meters (the image has 870x672 pixels x 0.05 resolution in the .yaml)
  size [43.5 33.6 1]    
  # Where to make the origin (rotate and offset)
  pose [21.75 16.8 0 0] # Center of the image
  bitmap "../../maps/3rdFloorNorth.pgm"

Next, I include fake_localization in my launch file.

<node pkg="fake_localization" type="fake_localization" name="fake_localization" respawn="false">
<param name="delta_x" value="0"/>
<param name="delta_y" value="0"/>
<param name="delta_yaw" value="0"/>


The issue is, the odom and amcl_pose do not match. In the example above, I put a robot in the world file at position [25 28 0 0]. I can see this when I rostopic echo odom. However, when I rostopic echo amcl_pose, I get x=28 and y=-25! Is there a rotation happening here? I thought that the /map was loaded with the origin at the bottom left corner, same as with stage? Is this something that I set with the fake_localization delta values, or is there something bigger happening here?

Thanks in advance!

edit retag flag offensive reopen merge delete

Closed for the following reason duplicate question by tfoote
close date 2015-04-23 03:26:31.470217

1 Answer

Sort by » oldest newest most voted

answered 2012-09-17 21:28:28 -0500

Procópio gravatar image
edit flag offensive delete link more

Question Tools

1 follower


Asked: 2012-09-17 19:25:24 -0500

Seen: 482 times

Last updated: Sep 17 '12