HaFred / ROS-DiLearnNavi

Yet Another Navigation Package
0 stars 0 forks source link

[Dev Log] Odom Related #13

Open HaFred opened 2 years ago

HaFred commented 2 years ago

This issue records the odometry-relevant logs.

HaFred commented 2 years ago

How to observe odom

Typically, the following roscmd help as long as turtlebot_bringup pkg and turbot3_robot.launch is executed.

rostopic echo odom # the bottom window

rosrun tf tf_echo base_footprint odom # the middle one, tf_echo [reference_frame][target_frame]
rosrun tf tf_echo odom base_footprint # the top one

We can see from the comparison of these two, the bottom one is for the odometer returning the instant odometer data, whereas the first two windows are for the accumulated positioning using odom (because even for static, the first two have translation and rotation result, while the bottom one has no translation, because no moving).

And the top and middle are just two reverse pairs, with reverse reference frame and target frame, referring to intro to tf.

HaFred commented 2 years ago

These two are providing same data, even though these two methods have different definition for target_frame:

rosrun tf tf_echo map base_link # tf_echo [reference_frame][target_frame]
latestPoseFromEKF = tfBuffer.lookupTransform("map", "base_link", ros::Time(0)); // lookupTransform (const std::string &target_frame, const std::string &source_frame, const ros::Time &time, const ros::Duration timeout=ros::Duration(0.0))