The base_link frame is the main coordinate frame attached to the robot's body. It moves as the robot moves and serves as the reference for all other robot parts.
The odom frame tracks the robot's position relative to where it started. It uses odometry data, which can drift over time, so it is not fixed globally.
odom and base_link frames?The map frame is fixed to the environment and does not move. The odom frame moves relative to the map due to odometry drift, and base_link moves with the robot.
- map -> odom: corrected by localization
- odom -> base_link: from wheel odometry
What is the correct way to get the robot's position in the map frame?
To get the robot's position in the map frame, multiply the map->odom transform by the odom->base_link transform in that order.
map frame unexpectedly drifts over time despite a static environment. Which of the following is the most likely cause?The odom frame accumulates drift from odometry. Without localization correcting map->odom, the robot's position in map drifts.
