ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange |
1 | initial version |
The odometry information should be published by the ROS driver for your mobile robot base. Usually, the robot sends encoder ticks via serial or whatever, and the ROS driver then computes the odometry message (i.e., pose and twist; see the link by @stevejp). The formula how to compute the ROS odometry message from encoder ticks depends on your kinematics.
https://github.com/ros-controls/ros_controllers/blob/f5dc6f2c31cfc76419f073c54a14ab04394ab919/diff_drive_controller/src/odometry.cpp
https://github.com/PR2/pr2_controllers/blob/f5ad5f6b821ba2aab073703dcabc4c104cd86112/pr2_mechanism_controllers/src/pr2_odometry.cpp