Tutorial: Docking with Nova Carter in Sim and Real

This tutorial demonstrates docking using AprilTag. AprilTags are a system of visual tags that provide low overhead, high accuracy localization.

If you are not interested in using AprilTag, see the tutorial on docking with FoundationPose:

Prerequisites

Ensure an AprilTag is affixed to the front of the dock to allow the robot to accurately detect the dock’s position. The AprilTag must belong to the tag36h11 family and measure 6 inches. The image below illustrates how to measure the tag size. For further information about AprilTags, see the details provided here.

https://media.githubusercontent.com/media/NVIDIA-ISAAC-ROS/.github/main/resources/isaac_ros_docs/robots/nova_carter/apriltag_size_measure.png/

Docking with Nova Carter in Isaac Sim Using AprilTag

  1. Set up Isaac Sim:

https://media.githubusercontent.com/media/NVIDIA-ISAAC-ROS/.github/main/resources/isaac_ros_docs/robots/nova_carter/set_up_isaac_sim.gif/
  • Install and launch Isaac Sim following the Isaac ROS Isaac Sim Setup Guide.

  • Add the charging dock at the path localhost/NVIDIA/Assets/Isaac/Props/NVIDIA/Carter/ChargingDock/charging_station_galileo.usd to the Isaac ROS Sample scene.

  • Adjust docking and robot transforms as desired. For example: set dock to (-10.0, 14.0, 0.01, 0.0, 0.0, 180) and set robot to (-2.0, 14.0, 0.0, 0.0, 0.0, 180).

  • Select /World/Nova_Carter_ROS/ros_lidars/publish_front_2d_lidar_scan in the Stage pane and change the topic name for front 2D Lidar as shown below.

    https://media.githubusercontent.com/media/NVIDIA-ISAAC-ROS/.github/main/resources/isaac_ros_docs/concepts/localization/lidar/isaac_sim_lidar_topic.png/
  • Select /World/Nova_Carter_ROS/ros_lidars/front_2d_lidar_render_product in the Stage pane and set enabled to True (checked).

  • Select /World/Nova_Carter_ROS/ros_lidars/front_3d_lidar_render_product in the Stage pane and set enabled to False (unchecked).

  • Press Play to initiate data publishing from Isaac Sim.

  1. AprilTag attachment and configuration:

The following image illustrates the attachment of the AprilTag to the dock in the simulation environment. The default dock is equipped with four AprilTags. The following steps configure the AprilTag for docking:

  • Select an AprilTag: Choose one of the four AprilTags to scale.

  • Adjust Parameters: Scale the selected AprilTag using the parameters shown in the image below.

  • Hide Remaining Tags: Make the other three AprilTags invisible.

https://media.githubusercontent.com/media/NVIDIA-ISAAC-ROS/.github/main/resources/isaac_ros_docs/robots/nova_carter/dock_with_apriltag_sim.png/
  1. Build and install the required packages:

  1. Make sure you followed the Prerequisites and you are inside the Isaac ROS Docker container.

  2. Install the prebuilt Debian package:

    sudo apt-get install -y ros-humble-nova-carter-bringup
    
  1. Run the launch file:

    ros2 launch nova_carter_docking docking_with_apriltag_sim.launch.py init_pose_x:=-2.0 init_pose_y:=14.0 init_pose_yaw:=3.14
    
  2. Send a docking action:

    ros2 action send_goal /dock_robot opennav_docking_msgs/action/DockRobot "
    {
        use_dock_id: false,
        dock_pose: {
            pose: {
            position: {x: -10.0, y: 14.0, z: 0.0},
            orientation: {x: 0.0, y: 0.0, z: 1.0, w: 0.0}
            },
            header: {
            frame_id: 'map'
            }
        },
        dock_type: 'nova_carter_dock',
        navigate_to_staging_pose: true
    }"
    
https://media.githubusercontent.com/media/NVIDIA-ISAAC-ROS/.github/main/resources/isaac_ros_docs/robots/nova_carter/docking_with_apriltag_sim.gif/

Docking with Nova Carter in Isaac Sim Using AprilTag

Docking with Nova Carter in Real Using AprilTag

  1. Attach the AprilTag to the dock.

    The image below illustrates the attachment of the AprilTag to the dock in the real-world environment:

    https://media.githubusercontent.com/media/NVIDIA-ISAAC-ROS/.github/main/resources/isaac_ros_docs/robots/nova_carter/dock_with_apriltag.png/
  2. SSH into the robot (instructions). Make sure you have successfully connected the PS5 joystick to the robot (instructions).

  3. Build and install the required packages:

  1. Pull the docker image:

    docker pull nvcr.io/nvidia/isaac/nova_carter_bringup:release_3.1-aarch64
    
  2. Run the docker image:

    docker run -it --privileged --network host \
       -v /dev/*:/dev/* \
       -v /tmp/argus_socket:/tmp/argus_socket \
       -v /etc/nova:/etc/nova \
       nvcr.io/nvidia/isaac/nova_carter_bringup:release_3.1-aarch64 /bin/bash
    
  1. Run the launch file for your cloud services configuration:

ros2 launch nova_carter_docking docking_with_apriltag_real.launch.py \
    map_yaml_path:=<path_to_map_yaml>

Note

You must replace <path_to_map_yaml> with the path of the map YAML file. If you do not have a map of your environment you can create one using the Lidar mapping tutorial

  1. Obtain an initial pose for your dock.

    The docking server uses this dock pose to calculate an approximate initial pose for dock detection. Precise measurements are not necessary.

    Use the PS5 joystick to maneuver the Nova Carter into the dock. Open a new terminal in the container and execute:

    ros2 run tf2_ros tf2_echo map base_link
    

    Verify that you receive output similar to the following:

    - Translation: [45.199, 19.320, 0.000]
    - Rotation: in Quaternion [0.000, 0.000, 0.614, 0.789]
    - Rotation: in RPY (radian) [0.000, -0.000, 1.323]
    - Rotation: in RPY (degree) [0.000, -0.000, 75.787]
    

    Record the Translation and Rotation in Quaternion for later use.

  2. Send a docking action appropriate for your cloud services configuration:

ros2 action send_goal /dock_robot opennav_docking_msgs/action/DockRobot "
 {
     use_dock_id: false,
     dock_pose: {
         pose: {
         position: {x: 45.199, y: 19.320, z: 0.0},
         orientation: {x: 0.0, y: 0.0, z: 0.614, w: 0.789}
         },
         header: {
         frame_id: 'map'
         }
     },
     dock_type: 'nova_carter_dock',
     navigate_to_staging_pose: true
 }"
https://media.githubusercontent.com/media/NVIDIA-ISAAC-ROS/.github/main/resources/isaac_ros_docs/robots/nova_carter/docking_from_cloud.gif/

Docking with Nova Carter in Real Using AprilTag

Troubleshooting

If the Nova Carter does not establish contact with the dock after the docking process is complete, consider adjusting the external_detection_translation_x parameter in /workspaces/isaac_ros-dev/src/nova_carter/nova_carter_docking/params/nova_carter_docking.yaml. The default value is -0.18. You may increase this value to bring the Nova Carter closer to the dock. More details for docking parameters can be found on GitHub.