Skip to content
← All builds
Muted demo loop from the projectCredit: Unitree Robotics — Go2
Write your own controller for a Unitree robot with SDK2: media published by Unitree Robotics — Go2 (image 2)
Write your own controller for a Unitree robot with SDK2: media published by Unitree Robotics — Go2 (image 3)

Write your own controller for a Unitree robot with SDK2

Quad, Hard

unitree_sdk2 is Unitree's C++ SDK for its current robots, with examples for high-level motion and low-level joint control.

Build the SDK on Ubuntu (x86_64 or aarch64), run the examples over Ethernet to your robot, and script sport-mode moves or read the IMU and joints. A Python wrapper (unitree_sdk2_python) also exists.

Hardware & cost: A Unitree Go2, B2, G1 or H1. Ubuntu 20.04+ with CMake and GCC.

Difficulty: Hard. Always test low-level control with the robot hung or lying down.

Agent install prompt (paste into Claude Code, Cursor or Codex): "Clone https://github.com/unitreerobotics/unitree_sdk2, install CMake/GCC per the README, build it, and walk me through running a high-level sport-mode example over my robot's network interface."

Source: unitreerobotics/unitree_sdk2 on GitHub — https://github.com/unitreerobotics/unitree_sdk2 (facts checked against the project README, Oct 2026; prices vary by region).

Quick answers

What do you need to write your own controller for a Unitree robot with SDK2?
A Unitree Go2, B2, G1 or H1. Ubuntu 20.04+ with CMake and GCC.
How hard is it to write your own controller for a Unitree robot with SDK2?
Hard. Always test low-level control with the robot hung or lying down.

How your agent drives it

Copied from the unitreerobotics/unitree_sdk2 README

  1. Shell
    $ mkdir build
    cd build
    cmake ..
    make

Any coding agent that can run a shell can run these. Read the README before you run anything on a robot that moves.

Ideas to try with it

Our ideas, not the builder's claims.

  1. Write a tiny C++ program that makes the Go2 sit when you clap
  2. Build a follow-me mode on top of the high-level motion examples
  3. Log joint torques during a walk and plot them
1 more idea
  1. Wrap one SDK call as a tool your agent can trigger
Source
unitreerobotics/unitree_sdk2 on GitHub
Last commit
2026-10-30
Builder
unitreerobotics
Repo
unitreerobotics/unitree_sdk2, 1,431 stars
Built with
Unitree Go2, Unitree G1

Unitree, 2 builds: Train a walking policy for Unitree Go2, H1 or G1 in sim · Write your own controller for a Unitree robot with SDK2

Parts notes for this device are in the Hermes Workshop catalog.

What to build next

Builds that share a board, robot or agent with this one.