-
Notifications
You must be signed in to change notification settings - Fork 34
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[xslocobot_nav] SLAM and Nav2 functionalities #35
base: humble
Are you sure you want to change the base?
Conversation
amcl, map_server, use_sim_time parameter substitution, behavior server in humble, static costmap layer
Renaming slam_mode launch argument to slam_toolbox_mode so it will not interfere when launching rtabmap. Log level info.
@stephenadhi what is left to do before this is ready to be reviewed? |
Hi, you can review and test whether the localization with AMCL is working.
|
@LSinterbotix UPDATE 23/05/2023: So if anyone ever wants to use AMCL, they should just launch the xslocobot_nav2_bringup.launch.py directly with the launch argument slam_mode:=localization (PR description updated). This is exactly how it is done in Nav2 bringup , support for using localization with slam toolbox is then out of scope. For me the simulation seems to be a bit problematic with the robot odometry, both in mapping and localization mode (Its more prone to shifts compared to in real life). So far I have been mapping using the slam toolbox in the real robot hardware without problem, performance is really good. I did not have the time to test this AMCL localization yet. Also specific to the humble distro branch: |
Fix bug Waiting for service map_server/get_state
Adjust launch file to accomodate both rtabmap and slam_toolbox
Hi,
I'm further improving nav2 functionalities, hoping to make both RTABMAP and slam_toolbox work as well as adding localizazion mode using nav2_amcl given a map yaml file.
Changes
The nav2 parameters are by default configured for the real robot.
For testing in simulation, we need to either change the parameters or adjust the odom and cmd_vel topic remappings inside the urdf file to reproduce the same result.
Testing
Launching simulator
ros2 launch interbotix_xslocobot_sim xslocobot_gz_classic.launch.py robot_model:=locobot_base robot_name:=locobot use_lidar:=true
Mapping mode: Launching SLAM using slam_toolbox
ros2 launch interbotix_xslocobot_nav xslocobot_slam_toolbox.launch.py launch_driver:=false slam_mode:=online_async use_sim_time:=true cmd_vel_topic:=/locobot/diffdrive_controller/cmd_vel_unstamped
Localization mode: launching nav2 + map from yaml and using amcl localization
*Note: replace map filepath to your interbotix_ros_rovers folder location
ros2 launch interbotix_xslocobot_nav xslocobot_nav2_bringup.launch.py slam_mode:=localization robot_name:=locobot map:=/workspaces/locobot/src/interbotix_ws/interbotix_ros_rovers/interbotix_ros_xslocobots/interbotix_xslocobot_nav/maps/interbotix_map.yaml use_sim_time:=true cmd_vel_topic:=/locobot/diffdrive_controller/cmd_vel_unstamped