Easy SLAM with ROS using slam_toolbox
Why Robotics Stack Exchange recommends it
Robotics Stack Exchange users link it as the step-by-step guide for setting up slam_toolbox in ROS 2, both when answering map problems and when asking about their own setups.
Recommended by 2 people across 2 different months, 2023 to 2025.
What it is
A 26-minute ROS tutorial from Articulated Robotics on getting SLAM running on a mobile robot with the slam_toolbox package. It covers a SLAM overview, setup, online mapping, localisation with slam_toolbox and amcl, and a test on the real robot.
What people said
Recommends dani santana · 2024-01 · Robotics Stack Exchange · on “ros2 map not received when using slam_toolbox”
I've figured out what was the issue. Slam Toolbox package works with the topic /scan by default in his file "mapper_params_online_async.yaml" (you can use your owns params if you change it) and in my URDF my LIDAR sensor sent the data on /laserscan topic. So I remapping it for /scan. Then, in the mapper_params_online_async.yaml the default value for base_frame is base_footprint and in my robot is the base_frame so I had to change it too. After this it works properly! Thanks Ravi and Joan! So check the Slam params. I used this two video as a guide: [this video] [LINK]
Recommends SauceTheSecond · 2025-12 · Robotics Stack Exchange · on “SLAM Toolbox map size too small”
This fixed it for me: Easy SLAM with ROS using slam_toolbox [this video] At 12:30 [this video] he explains that the map made by Slam Toolbox (used by nav2) auto-updates when implemented correctly. If you doubt you have set it up correctly, try mapping the map using only Slam Toolbox as explained in the video and check if the robot maps it correctly. If that is the case, you can move on to the tutorial for implementing said map in nav2: Making robot navigation easy with Nav2 and ROS! [LINK]
Cites user37765 · 2023-12 · Robotics Stack Exchange · on “I tried to bring up the map server, but it doesn't seem to be coming up”
When I try to run the Nav2 stack ros2 run nav2_map_server map_server --ros-args -p yaml_filename:=my_map_save.yaml -p use_sim_time:=true The execution log of the above command [INFO] [1703343999.250577364] [map_server]: map_server lifecycle node launched. Waiting on external lifecycle transitions to activate See [LINK] for more information. [INFO] [1703343999.255554676] [map_server]: Creating The next time you try to run it ros2 run nav2_util lifecycle_bringup map_server I can see that my server is running. Even the pgm file seems to have loaded well. \[INFO] [1703343999.250577364] [map_server]: map_server lifecycle node launched. Waiting on external lifecycle transitions to activate See [LI
Cites dani santana · 2024-01 · Robotics Stack Exchange · on “ros2 map not received when using slam_toolbox”
I'm working with ros2 humble and I have my robot which I can spawn successfully on gazebo and RVIZ with the set up ready of the LIDAR and the IMU sensor. The thing is when I launch: ros2 launch slam_toolbox online_async_launch.py (after launching my gazebo and rviz launch) I should see the /map topic in RVIZ but it doesn't happen. I know the /map topic is published by slam_toolbox and RVIZ is subscribed to it. I straight follow the instructions of this video [this video] , but I don't know why I can't see it on RVIZ. Is anyone in the same situation? Maybe I skip some step? What is needed to use properly the package slam_toolbox? The prove the map topic is published here: [LINK] [LINK] [LINK] Than
Cites Balen · 2024-02 · Robotics Stack Exchange · on “Saved map fro Slam_toolbox won't show up in RViz”
I have been following this tutorial [this video] and he is able to load his saved map back into RViz with no issues but when I do the exact same thing I just get an empty map? Not really sure what I am doing wrong and I haven't been able to find an answer for a similar problem from my research. After launching gazebo, RViz2 and my teleopkeyboard script I also run Slam_toolbox with the following command: ros2 launch slam_toolbox online_async_launch.py file_params:=./src/ford_bot/config/mapper_params_online_async.yaml use_sim_time:=true Link to my yaml file [LINK]