This repository contains two ROS2 packages I designed for the SLAM experiments with the Turtlebot4 robot. These packages introduce noise for testing the robustness of SLAM algorithms.
-
Package 1: [turtlebot4_slam_noise]
- This package contains the programs that generate visual and LiDAR noise for the experiment. The two main programs are:
- visual_noise.py: Introduces visual noise to the camera data.
- lidar_dust_noise_v4.py: Adds noise to the LiDAR data.
- Additional programs that were not part of the final experiment are stored in the 'milestone_codes' directory.
- This package contains the programs that generate visual and LiDAR noise for the experiment. The two main programs are:
-
Package 2: [turtlebot4_bringup]
- This package contains the launch and configuration files required to setup the visual and LiDAR noise experiments.
To install and build the packages, follow these steps:
- Clone the repository into your ROS2 workspace:
cd ~/ros2_ws/src git clone https://github.com/SimonMartineau/turtlebot4-project.git
Here's how to install the packages and get the code working:
-
NAV2:
Follow the installation guide here. -
RTAB-Map:
Follow the installation guide here. -
Modifications:
-
For NAV2, modify the following file:
- File:
src/turtlebot4/turtlebot4_navigation/config/slam.yaml
- Change: On line 16, replace:
with:
'scan_topic: scan',
This change ensures NAV2 subscribes to the topic with the noisy LiDAR data.'scan_topic: scan_modified',
- File:
-
For RTAB-Map, modify the following file:
- File:
install/rtabmap_launch/share/rtabmap_launch/launch/rtabmap_bringup.launch.py
- Change: On line 57, replace:
with:
'rgb_topic': '/camera/pi3/color/image_raw',
This change ensures RTAB-Map subscribes to the topic with the noisy image data.'rgb_topic': '/image_modified',
- File:
-
-
Configure Noise Settings:
In theturtlebot4_bringup/config
folder, modify the.yaml
files to adjust the visual and LiDAR noise settings according to your experiment requirements. -
Build and Source Workspace:
Ensure that your ROS 2 workspace is built and sourced:colcon build source ~/ros2_ws/install/setup.bash
-
Run Noise Experiments:
You can run the noise experiments using the launch file:ros2 launch turtlebot4_bringup all_noise.launch.py
-
Run NAV2 or RTAB-Map:
After the noise experiments are running, you can launch either NAV2 or RTAB-Map:- For NAV2:
ros2 launch turtlebot4_bringup start_nav2.launch.py
- For RTAB-Map:
ros2 launch turtlebot4_bringup start_rtabmap.launch.py
- For NAV2: