|
|
The goal of this project is to equip a mobile robot with self-localization capabilities, enabling it to determine its position within a known environment.
The core process involves:
As we perform a map-based approach, we define a chain of transformations (frames). This is inspired by the Robot Operating System (ROS):
These transformations form a hierarchical chain, allowing the robot to localize itself accurately within the environment while accounting for sensor drift and maintaining a consistent global reference.
In our case, the transformations are determined as follows:
This hierarchical approach ensures accurate localization by continuously refining the robot's position within the map while accounting for sensor drift and environmental changes.
Additionally, each transformation can be updated at different rates depending on the sensor or system providing the data. For instance, the map → root transformation is typically updated at the frequency of the laser scanner sensors, which ranges from approximately 10 Hz to 50 Hz. In contrast, the odom → root transformation is updated at a much higher frequency, around 1000 Hz, as it is provided by the robot's real-time unit. (Yet, this information will also only be available at a lower rate in the robot state memory.)
The aforementioned transformations are available in the robot state memory within the Localization core segment.
From the robot state memory, we obtain the odometry estimates. Also, we provide the world → map transformation and continuously update the map → root transformation.
On the code level, this package contains the following libraries and components:
fake_localizer simulates localization data for testing purposes. It eliminates the need for actual sensor input or a physical environment. The robot's location can be configured through the component's properties, making it ideal for debugging and development scenarios.cartographer_mapping_and_localization is responsible for simultaneous localization and mapping (SLAM) using the Cartographer library. This component allows the robot to dynamically create a map of its environment while simultaneously determining its position within that map. It supports both mapping and localization modes, making it versatile for various operational scenarios.