clarification: publishing nav_msgs/Odometry Twist
Hi All,
I checked all questions regarding nav_msgs/Odometry but could not find an answer. I have an IMU onboard my turtlebot and I want to publish the odometry from it. I am following the ROS odometry tutorial.
I understand the part regarding publishing of transforms; in my case these would be
- base_link_frame ---> imu_frame once
- odom_frame ---> base_link_frame continuously.
But I have a doubt about publishing the odometry information. The reference code in the tutorial publishes twist like so
odom.child_frame_id = "base_link"
odom.twist.twist.linear.x = vx;
odom.twist.twist.linear.y = vy;
odom.twist.twist.angular.z = vth;
with this comment
This populates the message with odometry data and sends it out over the wire. We'll set the child_frame_id of the message to be the "base_link" frame since that's the coordinate frame we're sending our velocity information in.
The velocity used is that of the robot (i.e. base_link) w.r.t. odom, yet it mentions setting child_frame_id to be that of base_link. As I understand, the velocity w.r.t base_link should be zero.
thanks, Rishabh