## 1.1. Learning Objectives¶

In this ROS2 sample, we are demonstrating Omniverse Isaac Sim integrated with the ROS2 Nav2 project.

## 1.2. Getting Started¶

Prerequisite

• This ROS2 Navigation sample is only supported on ROS2 Foxy Fitzroy or later. See the ROS2 website for requirements and installation instructions: https://docs.ros.org/en/foxy/Releases/Release-Foxy-Fitzroy.html

• The Nav2 project is required to run this sample. To install the Nav2 project refer to the Nav2 installation page.

• The ROS2 teleop_twist_keyboard package is also required. To install the package run the following:

sudo apt-get install ros-\$ROS_DISTRO-teleop-twist-keyboard

• Enabled the omni.isaac.ros2_bridge extension from the extension manager menu Windows->Extensions.

• We use the carter_navigation ROS2 package which contains the required launch file and navigation parameters. The carter_description ROS2 package is also used for displaying the NVIDIA Carter robot model in RViz2. Both ROS2 packages are located under the directory ros2_workspace/src/navigation/. Complete ROS & ROS2 Installation, make sure ROS environment is setup correctly and those packages are inside your ROS_PACKAGE_PATH.

## 1.4. Running Nav2¶

1. Go to Isaac Examples -> ROS -> Navigation to load the warehouse scenario.

2. Click on Play to begin simulation.

3. In a new terminal, run the ROS2 launch file to begin Nav2.

ros2 launch carter_navigation carter_navigation.launch.py


RViz2 will open and begin loading the occupancy map. If a map does not appear, repeat the previous step.

4. Load the the URDF model into the RViz2 window by clicking on RobotModel -> Description File and navigate to the location of the Carter URDF model which can be found at the urdf directory in the sample carter_description ROS2 package (carter_description/urdf/carter.urdf).

1. It is mostly likely after launching carter_navigation.launch.py, that the local costmap will not match the occupancy map. This means the robot is not correctly localized. To mitigate this, click on the 2D Pose Estimate button near the top of the RViz2 window and set the initial estimated pose by clicking and dragging at a point on the map where you think the robot is located.

6. To get a better idea of where the robot is located, you may wish to change camera views by clicking at the top left of the viewport in the Omniverse Isaac Sim window.

In RViz2, the robot model will immediately jump to the indicated pose. The local costmap should now be similarly aligned to the occupancy map.

Note

The local and occupancy maps don’t have to perfectly align yet. However if their alignment is quite different, you may repeat the previous step until getting a closer alignment.

7. To make both the local and global maps properly align, manually drive around the robot (rotating in place works the fastest in most cases). For manually controlling the robot, run the teleop_twist_keyboard ROS2 node using the following command in a new terminal.

ros2 run teleop_twist_keyboard teleop_twist_keyboard

1. Use the keyboard to move the robot until the local costmap has properly aligned with the occupancy map.

Now the robot has been properly localized! You may now stop the teleop_twist_keyboard node as it is not required anymore.

9. Click on the Navigation2 Goal button and then click and drag at the desired location point in the map. Nav2 will now generate a trajectory and the robot will start moving towards its destination!

## 1.5. Summary¶

In this tutorial, we covered running Isaac Sim with ROS2 navigation stack.

### 1.5.1. Next Steps¶

Go to the next tutorial Multiple Robot ROS2 Navigation to move multiple navigating robots with ROS2.