[Unitree H1] - Isaac Sim & ROS2 Quick Guide

Hi all,

over the past few days I have tried to follow the tutorial provided (Unitree H1 ROS2 Newsletter: Integration Guide for ROS2 and Isaac Sim), also referring to the repository I found on your github page (GitHub - MYBOTSHOP/issac_sim: ROS2 Package for utilization of Issac Sim). However, once I have completed the setup and launched the demo that allows H1 to be controlled by ROS2, the behaviour is not as expected: in fact, the walk that depends on the values of the published joint positions causes the robot to fall inexorably to the ground. Are you by any chance aware of this problem? In case it is just my problem:

  • Is it likely that I have made a mistake when importing the robot model?

  • the Xform primitive that the ROS2 publisher must refer to is H1/pelvis?

  • must the Xform primitive that the articulation controller refers to be the same?

Dear @rich97,

Please note that the H1 Isaac sim tutorial requires that you write your own controller to dynamically plan its gait and stabilize itself with either reinforcement learning or some sort of controller like MPC.

If you are looking for an easier approach where you do not want to write the controller yourself. Nvidia has recently released the latest Isaac Lab that contains the full H1 controller via teleop as well as reinforcement learning that is preconfigured. You may want to give that a try.

https://isaac-sim.github.io/IsaacLab/

Hi @Sohail

Thanks for the prompt response. I’ll definitely give a try to Isaac Lab. Instead, regarding the controller that basically assures that the robot is stable during a walking trajectory can you recommend me some resources I can refer to? On top, Isaac Lab works with ROS2?

I would recommend the trained controller from unitree trained on Isaac Lab.

Yes.

I managed to install Isaac Lab, btw it seems that there isn’t a teleoperation for the H1 robot, this feature seems to be available only for manipulators.

In order to use Isaac Lab, I’ve updated Isaac Sim from 4.0.0 to 4.2.0. As shown here

(Deploying Policies in Isaac Sim — Omniverse IsaacSim latest documentation)

is possible to launch the H1 demo, which basically allows to teleoperate the humanoid within the environment, and as said “the example uses the H1 Flat Terrain Policy trained in Isaac Lab to control the humanoid’s locomotion”. At this point, how can I integrate this control layer with the ROS2 pipeline I have based on the tutorial I followed?

The trained policy is directly sending commands to the prim actuactors in Isaac Sim, you have to redirect it to the ROS2 control. For this you have to cover most of the Isaac lab tutorial as it is quite in depth. Currently, there is no in between tutorial of the trained policy with ROS2.

So basically at the moment the only thing you can have is to take advantage of that example, modify it to receive data possibly from a ROS topic, but without being able to save the project but only the associated codes. So the classic pipeline that allows ROS2 and Sim to interact in the created graph is not implementable because of the lack of a locomotion controller within the available controllers, correct?

You should be able to save it in the omniverse environment.

There are available but a lot of them take a large time investment to get it working with all 3 items i.e. Nvidia, ROS2, Controller.

How can I save it? Because actually, if I stop the simulation the robot stops, and then if I press play, it seems that nothing controls it, and consequently the humanoid fall to the groud. Like I’ve said, at the moment, I save the related codes, in order to export always the H1 example.

Which names have these controllers? Are built-in within isaac sim?

No they are provided externally like towr. I am not aware of any built in Isaac Sim using classical dynamic controllers. You will find, however, their reinforcement learning controllers in Isaac Lab for controlling the H1.

I don’t quite understand the problem but you can refer to the omniverse documentation on seeing how resetting the environment when using ros2 control effects the simulation.