Unitree Go2 Quadruped
Unitree Go2 EDU Quadruped (dog)
- Step 1 - Establishing Ethernet and DDS Connectivity
- Step 2 - Add the DDS module
- Step 3 - Connect an XBOX controller
- Step 4 - Controlling the Quadruped
- Accessing Unitree data
- Unitree Go2 EDU Common Problems
OM1 can control a Unitree Go2 EDU out of the box. This has been tested on Nvidia Orin, Mac Mini, and current (silicon) Mac laptops.
Step 1 - Establishing Ethernet and DDS Connectivity
Connect the Unitree Go2 EDU to your development machine with an Ethernet cable. Open the network settings and find the network interface that is connected to the Go2 EDU. In the IPv4 settings, change the IPv4 mode to manual
, set the address to 192.168.123.99
, and set the mask to 255.255.255.0
. After completion, click apply
(or equivalent) and wait for the network to reconnect. Provide the name of the network adapter in the "unitree_ethernet": "en0"
entry in the unitree_go2.config
file.
Then, install CycloneDDS
. CycloneDDS
works on Mac, Linux, and PC. Run:
Next, set CYCLONEDDS_HOME
, CMAKE_PREFIX_PATH
, and CYCLONEDDS_URI
to the correct values for your computer. Example settings for a typical Mac installation are provided below. You should add these paths to your environment via your .zshrc
or equivalent.
Then, compile and run the listtopics
example:
On Mac, you may need to allow incoming connections
in the popup the first time you run listtopics
.
Running listtopics
should result in an extensive data dump of available topics:
Step 2 - Add the Python CycloneDDS module
Add the dds
python module to your code base: uv pip install -r pyproject.toml --extra dds
.
Step 3 - Connect an Xbox controller
On Mac, make sure that your Xbox controller is running the most recent firmware, otherwise you will be able to pair but not connect to the controller. You will need a PC with Xbox Accessories
to update the Xbox controller’s firmware. Many Mac OS updates hose support for the Xbox controller, which is then fixed (after some delay) via an Xbox firmware update. On Mac, you will also need to install hidapi
(brew install hidapi
).
NOTE: There is a bug on Mac when installing packages with brew
- some libraries cannot be found by uv
. If you get errors such as
Unable to load any of the following libraries:libhidapi-hidraw.so
, set export DYLD_FALLBACK_LIBRARY_PATH=$HOMEBREW_PREFIX/lib
in your .zshenv
or equivalent.
On Linux, install hidapi
like this:
Step 4 - Controlling the Quadruped
Run
OM1 will control a safe and limited subset of motions (such as stretch
and sit down
). You can also manually control the dog via the game controller. Press:
- A to stand up
- B to sit down
- X to shake paw
- Y to stretch
Allowing the dog to move
, pounce
, and run
requires you to add this functionality. Warning: If you add additional movement capabilities, this is at your own risk. Due to the autonomous nature of the system, we recommend to perform such testing in the absence of squirrels, cats, rabbits, or small children (assuming you are providing a dog
prompt).
Accessing Unitree data
Front video feed:
Front video single image:
Lowstate system/joint data:
Lidar:
Unitree Go2 EDU Common Problems
Channel factory init error: If you see a channel factory init error
, then you have not set the correct network interface adapter - the one you want to use is the network interface adapter on your development machine - the computer you are currently sitting in front of that is plugged into the Unitree quadruped (which has its own internal RockChip computer and network interface, which is not relevant to you right now). The Ethernet adapter - such as eno0
or en0
- needs to be set in the "unitree_ethernet": "en0"
entry in the unitree_go2.config
file.
The CycloneDDS library could not be located: You did not install CycloneDDS (see above), or, you did not provide a path to the /install
, via export CYCLONEDDS_HOME=$HOME/Documents/GitHub/cyclonedds/install
or equivalent.
“nothing is working” There are dozens of potential reasons “nothing is working”. The first step is to test your ability to ping
the quadruped motion control computer:
Assuming you can ping
the robot, then test the cycloneDDS
middleware (see STEP 1). Once you can see data flowing, then the rest of the system should work.
Was this page helpful?