Base Image
- The base image uses Debian12, which can be downloaded from the Download Center.
Dependency Installation
bash
# Basic dependencies
sudo apt update && sudo apt install -y \
cmake g++ build-essential curl zip unzip tar \
libyaml-cpp-dev python3-pip libjsoncpp-dev \
libeigen3-dev python3-serial python3-evdev
# Eigen feature extensions
sudo apt update && sudo apt install -y libsuitesparse-dev \
libopenblas-dev liblapack-dev libfftw3-dev libboost-all-dev \
libmpfr-dev libgmp-dev libhwloc-dev1
2
3
4
5
6
7
8
9
10
2
3
4
5
6
7
8
9
10
Environment Setup
Here we will build the relevant dependencies and complete the environment setup:
unitree_sdk2- pull, build and set up environmentUnitree Actuator SDK- pull, build and set up environmentYAML-CPP- pull, build and set up environmentEigen- pull, build and set up environmentJsonCpp- pull, build and set up environmentPyGame- installationRoboTamerSdk4Qmini:SDKcode pullOnnxRuntimeinstallationUnitreeMotorSDKinstallationRoboTamerSdk4Qminibuild
1. unitree_sdk2
Repository:
https://github.com/unitreerobotics/unitree_sdk2Git commit:
7694ddffcadc88436343dc0e0d1abb02da74691b
bash
# Return to lckfb home directory
cd ~
# Pull repository
git clone https://github.com/unitreerobotics/unitree_sdk2
# Build
cd unitree_sdk2 && mkdir build && cd build && \
cmake .. -DCMAKE_INSTALL_PREFIX=/opt/unitree
# Install
sudo make install
# Set up environment
echo "export CMAKE_PREFIX_PATH=/opt/unitree:$CMAKE_PREFIX_PATH" >> ~/.bashrc
source ~/.bashrc1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
Results are as follows【Click to Expand】
bash
lckfb@localhost:~$ git clone https://github.com/unitreerobotics/unitree_sdk2
Cloning into 'unitree_sdk2'...
remote: Enumerating objects: 2706, done.
remote: Counting objects: 100% (545/545), done.
remote: Compressing objects: 100% (228/228), done.
remote: Total 2706 (delta 353), reused 322 (delta 317), pack-reused 2161 (from 2)
Receiving objects: 100% (2706/2706), 86.02 MiB | 5.95 MiB/s, done.
Resolving deltas: 100% (1199/1199), done.
lckfb@localhost:~$ cd unitree_sdk2 && mkdir build && cd build && \
cmake .. -DCMAKE_INSTALL_PREFIX=/opt/unitree
-- The C compiler identification is GNU 13.3.0
-- The CXX compiler identification is GNU 13.3.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Check for working C compile features
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Check for working CXX compile features
-- Detecting CXX compile features - done
-- Setting build type to 'Release' as none was specified.
-- Current system architecture: aarch64
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success
-- Found Threads: TRUE
-- Importing: /home/lckfb/unitree_sdk2/thirdparty/lib/aarch64/libddsc.so
-- Importing: /home/lckfb/unitree_sdk2/thirdparty/lib/aarch64/libddscxx.so
-- Unitree SDK library found at: /home/lckfb/unitree_sdk2/lib/aarch64/libunitree_sdk2.a
-- Importing: /home/lckfb/unitree_sdk2/lib/aarch64/libunitree_sdk2.a
-- Found Boost: /usr/lib/aarch64-linux-gnu/cmake/Boost-1.83.0/BoostConfig.cmake (found version "1.83.0") found components: program_options
-- Found yaml-cpp version 0.8.0
-- Configuring done (2.5s)
-- Generating done (0.2s)
-- Build files have been written to: /home/lckfb/unitree_sdk2/build
lckfb@localhost:~/unitree_sdk2/build$ sudo make install
[ 1%] Building CXX object example/helloworld/CMakeFiles/test_publisher.dir/publisher.cpp.o
[ 2%] Building CXX object example/helloworld/CMakeFiles/test_publisher.dir/HelloWorldData.cpp.o
[ 3%] Linking CXX executable ../../bin/test_publisher
[ 3%] Built target test_publisher
[ 5%] Building CXX object example/helloworld/CMakeFiles/test_subscriber.dir/subscriber.cpp.o
[ 6%] Linking CXX executable ../../bin/test_subscriber
[ 7%] Built target test_subscriber
[ 8%] Building CXX object example/wireless_controller/CMakeFiles/advanced_gamepad.dir/main.cpp.o
[ 10%] Linking CXX executable ../../bin/advanced_gamepad
[ 10%] Built target test_subscriber
...
-- Installing: /opt/unitree/include/dds/dds.h1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
2. Unitree Actuator SDK
Repository:
https://github.com/unitreerobotics/unitree_actuator_sdk
bash
# Return to lckfb home directory
cd ~
# Pull repository
git clone https://github.com/unitreerobotics/unitree_actuator_sdk
# Build
cd unitree_actuator_sdk && \
git checkout GO-M8010-6 && \
mkdir build && cd build && cmake .. && \
make -j41
2
3
4
5
6
7
8
9
10
11
2
3
4
5
6
7
8
9
10
11
Results are as follows【Click to Expand】
bash
lckfb@localhost:~$ git clone https://github.com/unitreerobotics/unitree_actuator_sdk
Cloning into 'unitree_actuator_sdk'...
remote: Enumerating objects: 529, done.
remote: Counting objects: 100% (60/60), done.
remote: Compressing objects: 100% (38/38), done.
remote: Total 529 (delta 34), reused 22 (delta 22), pack-reused 469 (from 1)
Receiving objects: 529 (100% 529), 9.03 MiB | 6.12 MiB/s, done.
Resolving deltas: 100% (100/100), done.
lckfb@localhost:~$ cd unitree_actuator_sdk && \
git checkout GO-M8010-6 && \
mkdir build && cd build && cmake .. && \
make -j4
branch 'GO-M8010-6' set up to track 'origin/GO-M8010-6'.
Switched to a new branch 'GO-M8010-6'
CMake Deprecation Warning at CMakeLists.txt:1 (cmake_minimum_required):
Compatibility with CMake < 3.5 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
-- The C compiler identification is GNU 13.3.0
-- The CXX compiler identification is GNU 13.3.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Check for working C compile features
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Check for working CXX compile features
-- Detecting CXX compile features - done
-- Configuring done (1.5s)
-- Generating done (0.0s)
-- Build files have been written to: /home/lckfb/unitree_actuator_sdk/build
[ 50%] Building CXX object CMakeFiles/motorctrl.dir/example/main.cpp.o
[100%] Linking CXX executable motorctrl
[100%] Built target motorctrl1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
3. YAML-CPP
Repository:
https://github.com/jbeder/yaml-cpp
bash
# Return to lckfb home directory
cd ~
# Pull repository
git clone https://github.com/jbeder/yaml-cpp
# Build
cd yaml-cpp && mkdir build && cd build && \
cmake .. && make -j4 && sudo make install1
2
3
4
5
6
7
8
9
2
3
4
5
6
7
8
9
Results are as follows【Click to Expand】
bash
lckfb@localhost:~$ git clone https://github.com/jbeder/yaml-cpp
Cloning into 'yaml-cpp'...
remote: Enumerating objects: 9510, done.
remote: Counting objects: 153 (153), done.
remote: Compressing objects: 100% (112/112), done.
remote: Total 9510 (delta 96), reused 41 (delta 41), pack-reused 9357 (from 3)
Receiving objects: 100% (9510/9510), 4.94 MiB | 4.88 MiB/s, done.
Resolving deltas: 100% (6244/6244), done.
lckfb@localhost:~$ cd yaml-cpp && mkdir build && cd build && \
cmake .. && make -j4 && sudo make install
-- The CXX compiler identification is GNU 13.3.0
-- The CXX compiler identification is GNU 13.3.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Check for working C compile features
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Check for working CXX compile features
-- Detecting CXX compile features - done
-- Configuring done (0.8s)
-- Generating done (0.1s)
-- Build files have been written to: /home/lckfb/yaml-cpp/build
[ 5%] Building CXX object CMakeFiles/yaml-cpp.dir/src/binary.cpp.o
...
[100%] Built target yaml-cpp-read
[100%] Built target yaml-cpp-parse
[100%] Built target yaml-cpp-sandbox
Install the project...
-- Install configuration: ""
-- Installing: /usr/local/lib/libyaml-cpp.a
-- Up-to-date: /usr/local/include
-- Installing: /usr/local/include/yaml-cpp
...
-- Installing: /usr/local/lib/pkgconfig/yaml-cpp.pc1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
4. Eigen
Repository:
https://gitlab.com/libeigen/eigen
bash
# Return to lckfb home directory
cd ~
# Pull repository
git clone https://gitlab.com/libeigen/eigen
# Build
# It is not recommended to use multi-core compilation here as it uses a lot of memory.
cd eigen && mkdir -p build && cd build && \
cmake .. && make && sudo make install1
2
3
4
5
6
7
8
9
10
2
3
4
5
6
7
8
9
10
Results are as follows【Click to Expand】
bash
-- Performing Test HAVE_HWLOC_PARENT_MEMBER
-- Performing Test HAVE_HWLOC_PARENT_MEMBER - Success
-- Performing Test HAVE_HWLOC_CACHE_ATTR
-- Performing Test HAVE_HWLOC_CACHE_ATTR - Success
...
-- Configuring done (27.9s)
-- Generating done (7.0s)
-- Build files have been written to: /home/lckfb/eigen/build
[ 0%] Building CXX object blas/CMakeFiles/eigen_blas_static.dir/single.cpp.o
...
[100%] Built target eigen_lapack
Install the project...
-- Install configuration: "Release"
-- Installing: /usr/local/include/eigen3/signature_of_eigen3_matrix_library
...
-- Installing: /usr/local/lib/libeigen_lapack.so1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
5. JsonCpp
Repository:
https://github.com/Microsoft/vcpkg
bash
# Return to lckfb home directory
cd ~
# Pull repository
git clone https://github.com/Microsoft/vcpkg
# Build
cd vcpkg && ./bootstrap-vcpkg.sh && \
./vcpkg integrate install && \
./vcpkg install jsoncpp1
2
3
4
5
6
7
8
9
10
2
3
4
5
6
7
8
9
10
Results are as follows【Click to Expand】
bash
lckfb@localhost:~$ git clone https://github.com/Microsoft/vcpkg
Cloning into 'vcpkg'...
remote: Enumerating objects: 313794, done.
remote: Counting objects: 100% (245/245), done.
remote: Compressing objects: 100% (136/136), done.
remote: Total 313794 (delta 175), reused 129 (delta 109), pack-reused 313549 (from 3)
Receiving objects: 100% (313794/313794), 99.46 MiB | 6.72 MiB/s, done.
Updating files: 100% (13622/13622), done.
lckfb@localhost:~$ cd vcpkg && ./bootstrap-vcpkg.sh && \
./vcpkg integrate install && \
./vcpkg install jsoncpp
Downloading vcpkg-arm64-glibc...
vcpkg package management program version 2026-03-04-4b3e4c276b5b87a649e66341e11553e8c577459c
See LICENSE.txt for license information.
Telemetry
---------
vcpkg collects usage data in order to help us improve your experience.
The data collected by Microsoft is anonymous.
You can opt-out of telemetry by re-running the bootstrap-vcpkg script with -disableMetrics,
passing --disable-metrics to vcpkg on the command line,
or by setting the VCPKG_DISABLE_METRICS environment variable.
Read more about vcpkg telemetry at docs/about/privacy.md
Applied user-wide integration for this vcpkg root.
CMake projects should use: "-DCMAKE_TOOLCHAIN_FILE=/home/lckfb/vcpkg/scripts/buildsystems/vcpkg.cmake"
Computing installation plan...
A suitable version of cmake was not found (required v3.31.10).
Downloading https://github.com/Kitware/CMake/releases/download/v3.31.10/cmake-3.31.10-linux-aarch64.tar.gz -> cmake-3.31.10-linux-aarch64.tar.gz
Successfully downloaded cmake-3.31.10-linux-aarch64.tar.gz
Extracting cmake...
The following packages will be built and installed:
jsoncpp:arm64-linux@1.9.6
...
Completed submission of jsoncpp:arm64-linux@2024-04-23 in 332 ms (1/1)
All requested installations completed successfully in: 24 s1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
6. PyGame
Install the relevant dependencies:
bash
sudo apt install -y python3-pygame1
2
2
7. RoboTamerSdk4Qmini
The main code uses RoboTamerSdk4Qmini for quick deployment. If there are issues later, you can fine-tune on this basis.
7.1. SDK Code Pull
bash
# Return to lckfb home directory
cd ~
# Pull code
git clone https://github.com/vsislab/RoboTamerSdk4Qmini.git1
2
3
4
5
2
3
4
5
7.2. OnnxRuntime Installation
bash
# Enter target directory
cd ~/RoboTamerSdk4Qmini/lib/onnx
# Copy files to target directory
sudo cp -r libonnxruntime.so libonnxruntime.so.1.* /usr/local/lib
# Update cache
sudo ldconfig1
2
3
4
5
6
7
8
2
3
4
5
6
7
8
7.3. UnitreeMotorSDK Installation
bash
# Enter target directory
cd ~/RoboTamerSdk4Qmini/lib/m8010motor
# Copy files to target directory
sudo cp libUnitreeMotorSDK_Arm64.so /usr/local/lib/
# Update cache
sudo ldconfig1
2
3
4
5
6
7
8
2
3
4
5
6
7
8
7.4. RoboTamerSdk4Qmini Build
bash
# Create directory and enter
mkdir -p ~/RoboTamerSdk4Qmini/build && cd ~/RoboTamerSdk4Qmini/build
# Build project
cmake -DPLATFORM=arm64 .. && make -j21
2
3
4
5
2
3
4
5
Results are as follows【Click to Expand】
bash
lckfb@localhost:~$ git clone https://github.com/vsislab/RoboTamerSdk4Qmini.git
Cloning into 'RoboTamerSdk4Qmini'...
remote: Enumerating objects: 912, done.
remote: Counting objects: 100% (5/5), done.
remote: Total 912 (delta 4), reused 4 (delta 4), pack-reused 907 (from 2)
Receiving objects: 100% (912/912), 30.75 MiB | 6.76 MiB/s, done.
Resolving deltas: 100% (294/294), done.
Updating files: 100% (774/774), done.
lckfb@localhost:~$ cd ~/RoboTamerSdk4Qmini/lib/onnx
lckfb@localhost:~/RoboTamerSdk4Qmini/lib/onnx$ sudo cp -r libonnxruntime.so libonnxruntime.so.1.* /usr/local/lib
lckfb@localhost:~/RoboTamerSdk4Qmini/lib/onnx$ sudo ldconfig
lckfb@localhost:~/RoboTamerSdk4Qmini/lib/onnx$ cd ~/RoboTamerSdk4Qmini/lib/m8010motor
lckfb@localhost:~/RoboTamerSdk4Qmini/lib/m8010motor$ sudo cp libUnitreeMotorSDK_Arm64.so /usr/local/lib/
lckfb@localhost:~/RoboTamerSdk4Qmini/lib/m8010motor$ sudo ldconfig
lckfb@localhost:~/RoboTamerSdk4Qmini/lib/m8010motor$ mkdir -p ~/RoboTamerSdk4Qmini/build && cd ~/RoboTamerSdk4Qmini/build
lckfb@localhost:~/RoboTamerSdk4Qmini/build$ cmake -DPLATFORM=arm64 .. && make -j2
...
[100%] Linking CXX executable /home/lckfb/RoboTamerSdk4Qmini/bin/run_interface
[100%] Built target run_interface
lckfb@localhost:~/RoboTamerSdk4Qmini/build$ ls -la ~/RoboTamerSdk4Qmini/bin/
total 56440
drwxr-xr-x 2 lckfb lckfb 4096 Mar 26 15:15 .
drwxr-xr-x 9 lckfb lckfb 4096 Mar 26 15:13 ..
-rw-rw-r-- 1 lckfb lckfb 1018 Mar 26 15:13 config.yaml
-rw-rw-r-- 1 lckfb lckfb 4537107 Mar 26 15:13 general.txt
-rwxr-xr-x 1 lckfb lckfb 805015 Mar 26 15:13 policy.onnx
-rwxr-xr-x 1 lckfb lckfb 17552152 Mar 26 15:15 run_interface1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
After RoboTamerSdk4Qmini is built, an executable file run_interface will be generated in the ~/RoboTamerSdk4Qmini/bin/ directory. We will need this file later.