Skip to content

Mapping

To interact with the slam_toolbox, you can use the following ROS 2 interfaces.

Topics

Topic Message type Description
/map nav_msgs/msg/OccupancyGrid Current map of the environment (OccupancyGrid) used by the navigation stack.
/map_metadata nav_msgs/msg/MapMetaData Metadata for the current map (OccupancyGrid) with its size, origin, etc.
/slam_toolbox/graph_visualization visualization_msgs/msg/MarkerArray Visualization of the graph generated by slam_toolbox.
/slam_toolbox/scan_visualization sensor_msgs/msg/LaserScan Visualization of the scan used by slam_toolbox.
/slam_toolbox/update visualization_msgs/msg/InteractiveMarkerUpdate Visualize the graph in RViz and allows the user to apply changes in the position of the graph’s nodes.

Services

Service Message type Description
/slam_toolbox/clear_changes slam_toolbox/srv/Clear Clears all manual pose-graph manipulation changes pending.
/slam_toolbox/deserialize_map slam_toolbox/srv/DeserializePoseGraph Loads a saved serialized pose-graph file from disk.
/slam_toolbox/dynamic_map nav_msgs/msg/OccupancyGrid Requests the current state of the pose-graph as an occupancy grid.
/slam_toolbox/manual_loop_closure slam_toolbox/srv/LoopClosure Requests the manual changes to the pose-graph pending to be processed.
/slam_toolbox/pause_new_measurements slam_toolbox/srv/Pause Pauses processing of new incoming laser scans by the toolbox.
/slam_toolbox/save_map slam_toolbox/srv/SaveMap Saves the map image file of the pose-graph usable for display or AMCL localization (wrapper on map_server/map_saver).
/slam_toolbox/serialize_map slam_toolbox/srv/SerializePoseGraph Saves the map pose-graph and data usable for continued mapping, localization, offline manipulation, and more.
/slam_toolbox/toggle_interactive_mode slam_toolbox/srv/ToggleInteractive Toggles interactive mode, publishing interactive markers of nodes and their positions to be updated in an application.
/slam_toolbox/reset slam_toolbox/srv/Reset Resets current map back to the initial state.