This repository shows how to control the robot from ros2_control to make Isaac Sim easier to use. Important packages are "isaac_ros2_control" and "isaac_ros2_scripts". "isaac_ros2_control" provide hardware_interface class and send the commands from ros2_control to "isaac_ros2_scripts". "isaac_ros2_scripts" is needed bacause Isaac Sim needs specific python environment. "isaac_ros2_scripts" has the python script to launch and control Isaac Sim.
The features of this repository are below:
- This shows how to control a robot on Isaac Sim with ros2_control.
- This provides a Dockerfile where Isaac Sim and ROS2 Humble can coexist.
- This currently supports only rotational joints using velocity control.
- This sends joint status (position, velocity and effort) to ros2_control from Isaac Sim.
- This launches sensors from URDF description.
- Docker
- Isaac Sim Docker Image (Tested using image based on nvcr.io/nvidia/isaac-sim:2022.2.1)
- Nucleus Server (I installed with the Omniverse Laungher)
-
Install Docker and pull Isaac Sim Docker Image. refer to https://docs.omniverse.nvidia.com/app_isaacsim/app_isaacsim/install_container.html
-
Clone the repo to your ros2 workspace
git clone https://github.com/hijimasa/isaac-ros2-control-sample.git
-
Get git submodules
cd isaac-ros2-control-sample/docker git submodule update --init --recursive
-
Build a docker image with shell script.
./build_docker_image.sh
-
Launch a docker container
./launch_docker.sh
-
Build ros2 source codes
colcon build && source install/setup.bash
-
Launch the package
- To launch simulator
ros2 launch isaac_diffbot_sim diffbot_spawn.launch.py
- To launch teleop_twist_keyboard
docker exec -it isaac-sim /bin/bash ros2 run teleop_twist_keyboard teleop_twist_keyboard
- LaserScan topic do not published when 2D Lidar config file is used.
- You should uncheck "Normarize Image" in your depth topic in RViz2 if you get black depth image.