Gazebo | Ignition | Community
Ask Your Question

Set Odometry and SetModelState

asked 2013-06-03 20:38:15 -0600

David Lu gravatar image

updated 2013-06-04 16:20:36 -0600

For repeated tests, I want to move my robot back to (0,0). I've been using SetModelState, but that does not reset the odometry. Is there a way to reset the odometry easily?

I found LAYER_POSITION2D_REQ_SET_ODOM here but it's unclear how to use it from ROS.

Edit: I'm using the basic PR2 setup in conjunction with ROS. I create an empty world and spawn a PR2 in it. The /base_odometry/odom topic is published by the /gazebo node.

edit retag flag offensive close merge delete


what robot and which odometry are you talking about? Where do you get the odometry from, a plugin?

ffurrer gravatar imageffurrer ( 2013-06-03 21:53:37 -0600 )edit

2 Answers

Sort by ยป oldest newest most voted

answered 2013-06-05 15:35:02 -0600

hsu gravatar image

Hi David,

PR2 odometry information is published by a ROS odometry controller. All controllers in gazebo are loaded through a gazebo plugin that mimics the PR2 controller manager on the robot. Gazebo itself does not keep odometry information.


edit flag offensive delete link more

answered 2013-06-04 11:36:50 -0600

nkoenig gravatar image

Odometry information is not stored with Gazebo, unless you have a special plugin (or one of the ROS plugins has an odometry value).

Can you describe what robot you're using, and what plugins?

edit flag offensive delete link more


Updated in description above.

David Lu gravatar imageDavid Lu ( 2013-06-05 14:48:40 -0600 )edit
Login/Signup to Answer

Question Tools

1 follower


Asked: 2013-06-03 20:38:15 -0600

Seen: 1,891 times

Last updated: Jun 05 '13