From 0fec4c31b6a65a0ff9fd5c72f09d44b1432fd8b3 Mon Sep 17 00:00:00 2001 From: Koki Shinjo Date: Fri, 6 Oct 2023 09:59:23 +0900 Subject: [PATCH 1/8] Update README.md --- jsk_unitree_robot/README.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/jsk_unitree_robot/README.md b/jsk_unitree_robot/README.md index 7d80256051..0ef8eed162 100644 --- a/jsk_unitree_robot/README.md +++ b/jsk_unitree_robot/README.md @@ -50,6 +50,14 @@ source devel/setup.bash 5. Deployment Once you have completed your development, put your code into [apps](https://github.com/jsk-ros-pkg/jsk_robot/blob/master/jsk_unitree_robot/jsk_unitree_startup/apps/) directory and build on cross environment and copy to onboard computer. + + To run cross compile, you need to do following steps. + + - https://github.com/jsk-ros-pkg/jsk_robot/tree/master/jsk_unitree_robot/cross#prepare-cross-compiling-environment-run-only-the-fist-time-per-host-computer + - https://github.com/jsk-ros-pkg/jsk_robot/tree/master/jsk_unitree_robot/cross#build-ros-system-on-docker--run-only-the-fist-time-per-host-computer + + After that, please run command below to build ros workspace and deploy it to robot. + ``` roscd jsk_unitree_startup/../cross make user From 411934854d4409f7ba1c3e1eb4fbf401fe5bacd7 Mon Sep 17 00:00:00 2001 From: Koki Shinjo Date: Fri, 6 Oct 2023 10:48:46 +0900 Subject: [PATCH 2/8] Update README.md --- jsk_unitree_robot/cross/README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/jsk_unitree_robot/cross/README.md b/jsk_unitree_robot/cross/README.md index 4c38e5c985..c1bda99999 100644 --- a/jsk_unitree_robot/cross/README.md +++ b/jsk_unitree_robot/cross/README.md @@ -25,7 +25,9 @@ $ sudo apt install -y qemu-user-static make system ``` -Caution!!! It will take more than a few hours !! So for JSK users, download the `arm64v8_System.tgz` archive file from [here](https://drive.google.com/drive/u/2/folders/1SBA9oAwjfD84yRFEB-jsCH1m5Q8eEGSK) and extract under `jsk_unitree_robot/cross/` directory before run `make` command. +**Caution!!! It will take more than a few hours !! (some times longer than 24 hours).** + +So For JSK users, download the output of this command (`arm64v8_System.tgz` archive file) from [here](https://drive.google.com/drive/u/2/folders/1SBA9oAwjfD84yRFEB-jsCH1m5Q8eEGSK) and extract under `jsk_unitree_robot/cross/` directory so that you can skip this process. Run following command to copy ROS1 base sytem to Go1 onboard computer. This should be done only in the first time. So normally user do not have to run this command ``` From 343c5e40e8516b36406b60c226418678ef27df93 Mon Sep 17 00:00:00 2001 From: Koki Shinjo Date: Fri, 6 Oct 2023 10:50:53 +0900 Subject: [PATCH 3/8] Update README.md --- jsk_unitree_robot/cross/README.md | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/jsk_unitree_robot/cross/README.md b/jsk_unitree_robot/cross/README.md index c1bda99999..ffcced2e83 100644 --- a/jsk_unitree_robot/cross/README.md +++ b/jsk_unitree_robot/cross/README.md @@ -29,7 +29,10 @@ make system So For JSK users, download the output of this command (`arm64v8_System.tgz` archive file) from [here](https://drive.google.com/drive/u/2/folders/1SBA9oAwjfD84yRFEB-jsCH1m5Q8eEGSK) and extract under `jsk_unitree_robot/cross/` directory so that you can skip this process. -Run following command to copy ROS1 base sytem to Go1 onboard computer. This should be done only in the first time. So normally user do not have to run this command +### Deploy ROS System to Go1 robot + +After finishing former step, run following command to copy ROS1 base sytem to Go1 onboard computer. This should be done only in the first time. So normally user do not have to run this command + ``` ./install.sh -p 123 -D System ``` @@ -42,7 +45,10 @@ You can build your current `jsk_unitree_robot` workspace on Docker environment w make user ``` +### Deploy ROS workspace to Go1 robot + To copy your software to Go1 onboard computer, run following command + ``` ./install.sh -p 123 ``` From 8f22df9dc65e260e005ba8fdf33496c1e794dfcb Mon Sep 17 00:00:00 2001 From: Koki Shinjo Date: Fri, 6 Oct 2023 11:50:47 +0900 Subject: [PATCH 4/8] Update README.md --- jsk_unitree_robot/README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/jsk_unitree_robot/README.md b/jsk_unitree_robot/README.md index 0ef8eed162..99f80c205f 100644 --- a/jsk_unitree_robot/README.md +++ b/jsk_unitree_robot/README.md @@ -53,8 +53,8 @@ source devel/setup.bash To run cross compile, you need to do following steps. - - https://github.com/jsk-ros-pkg/jsk_robot/tree/master/jsk_unitree_robot/cross#prepare-cross-compiling-environment-run-only-the-fist-time-per-host-computer - - https://github.com/jsk-ros-pkg/jsk_robot/tree/master/jsk_unitree_robot/cross#build-ros-system-on-docker--run-only-the-fist-time-per-host-computer + - [prepare-cross-compiling-environment-run-only-the-fist-time-per-host-computer](./cross/README.md#prepare-cross-compiling-environment-run-only-the-fist-time-per-host-computer) + - [build-ros-system-on-docker--run-only-the-fist-time-per-host-computer](./cross/README.md#build-ros-system-on-docker--run-only-the-fist-time-per-host-computer) After that, please run command below to build ros workspace and deploy it to robot. From b47e63481c05cf3db105d43d1181faf9894903cc Mon Sep 17 00:00:00 2001 From: Koki Shinjo Date: Sat, 7 Oct 2023 15:52:07 +0900 Subject: [PATCH 5/8] Update README.md to fix network configuration of ethernet --- jsk_unitree_robot/README.md | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/jsk_unitree_robot/README.md b/jsk_unitree_robot/README.md index 99f80c205f..0453660fa5 100644 --- a/jsk_unitree_robot/README.md +++ b/jsk_unitree_robot/README.md @@ -29,16 +29,20 @@ source devel/setup.bash 1. Connect to the robot via Ethernet -2. Set your PC'S IP address to `192.168.96.162` +2. Configure your PC's ethernet like below + + - IP Address: 192.168.123.162 + - Subnet Mask: 255.255.255.0 + - Gateway: 192.168.123.161 3. Setup ROS_IP and ROS_MASTER_URI ``` rossetmaster 192.168.96.161 - rossetip + rossetip 192.168.96.162 ``` -4. Run roseus +6. Run roseus ```lisp (load "package://unitreeeus/unitree-interface.l") ;; load modules @@ -47,7 +51,7 @@ source devel/setup.bash See `https://github.com/jsk-ros-pkg/jsk_robot/blob/master/jsk_unitree_robot/unitreeeus/test/test-go1.l` for example. -5. Deployment +7. Deployment Once you have completed your development, put your code into [apps](https://github.com/jsk-ros-pkg/jsk_robot/blob/master/jsk_unitree_robot/jsk_unitree_startup/apps/) directory and build on cross environment and copy to onboard computer. From 4bdff7401c87d9890e9b96a70f09ac5c6771236d Mon Sep 17 00:00:00 2001 From: Koki Shinjo Date: Sat, 7 Oct 2023 17:05:58 +0900 Subject: [PATCH 6/8] Update README.md --- jsk_unitree_robot/README.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/jsk_unitree_robot/README.md b/jsk_unitree_robot/README.md index 0453660fa5..22897d40ee 100644 --- a/jsk_unitree_robot/README.md +++ b/jsk_unitree_robot/README.md @@ -65,7 +65,8 @@ source devel/setup.bash ``` roscd jsk_unitree_startup/../cross make user - ./install -p 123 + ./install -t Pro -p 123 # for Go1 Pro + ./install -t Air -p 123 # for Go1 Air ``` Then, reboot the robot and go to [app_chooser](http://192.168.123.161:8000/rwt_app_chooser) and start your application From ce6f61735bb1f257d4d57c1c5dc8c152143b068c Mon Sep 17 00:00:00 2001 From: Koki Shinjo Date: Sat, 7 Oct 2023 17:37:54 +0900 Subject: [PATCH 7/8] Update README.md --- jsk_unitree_robot/README.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/jsk_unitree_robot/README.md b/jsk_unitree_robot/README.md index 22897d40ee..ec826e5e2c 100644 --- a/jsk_unitree_robot/README.md +++ b/jsk_unitree_robot/README.md @@ -25,6 +25,10 @@ catkin build unitreeeus jsk_unitree_startup source devel/setup.bash ``` +### Prepare JSK Environment to Go1 Robot + +Please follow [this instruction](./cross/README.md#setup-go1-robot). This is only required for the first time. + ### Program Go1 robot 1. Connect to the robot via Ethernet From a112987101f45ef571d4f2ee7c7743bab7bd8e41 Mon Sep 17 00:00:00 2001 From: Kei Okada Date: Thu, 19 Oct 2023 10:56:24 +0900 Subject: [PATCH 8/8] use archive for docker, System, Users. --- jsk_unitree_robot/README.md | 13 ++++++------- jsk_unitree_robot/cross/README.md | 29 +++++++++++++++++++++++------ 2 files changed, 29 insertions(+), 13 deletions(-) diff --git a/jsk_unitree_robot/README.md b/jsk_unitree_robot/README.md index ec826e5e2c..2ac52a5c99 100644 --- a/jsk_unitree_robot/README.md +++ b/jsk_unitree_robot/README.md @@ -2,6 +2,8 @@ ROS package for Unitree Go1 robot. +This document assumes that your robot is already configured with JSK's ROS environment. To configure this, please ask your robot's administrator along with [this instruction](./cross/README.md#setup-go1-robot). + ## How to Run See [manual](https://drive.google.com/drive/folders/1PZDOo8WUcqwU8mNek2qAaTwW9WjJVVRL?usp=sharing) before you use Go 1. (jsk.imi.i.u-tokyo.ac.jp account is required.) @@ -25,10 +27,6 @@ catkin build unitreeeus jsk_unitree_startup source devel/setup.bash ``` -### Prepare JSK Environment to Go1 Robot - -Please follow [this instruction](./cross/README.md#setup-go1-robot). This is only required for the first time. - ### Program Go1 robot 1. Connect to the robot via Ethernet @@ -46,7 +44,7 @@ Please follow [this instruction](./cross/README.md#setup-go1-robot). This is onl rossetip 192.168.96.162 ``` -6. Run roseus +4. Run roseus ```lisp (load "package://unitreeeus/unitree-interface.l") ;; load modules @@ -55,11 +53,12 @@ Please follow [this instruction](./cross/README.md#setup-go1-robot). This is onl See `https://github.com/jsk-ros-pkg/jsk_robot/blob/master/jsk_unitree_robot/unitreeeus/test/test-go1.l` for example. -7. Deployment +5. Deployment Once you have completed your development, put your code into [apps](https://github.com/jsk-ros-pkg/jsk_robot/blob/master/jsk_unitree_robot/jsk_unitree_startup/apps/) directory and build on cross environment and copy to onboard computer. - To run cross compile, you need to do following steps. + To run cross compile, you need `ros1-unitree` docker image and `arm64v8_System` directory. If you do not have them, pleas ask your development environment administrator along with following instructions. + - [prepare-cross-compiling-environment-run-only-the-fist-time-per-host-computer](./cross/README.md#prepare-cross-compiling-environment-run-only-the-fist-time-per-host-computer) - [build-ros-system-on-docker--run-only-the-fist-time-per-host-computer](./cross/README.md#build-ros-system-on-docker--run-only-the-fist-time-per-host-computer) diff --git a/jsk_unitree_robot/cross/README.md b/jsk_unitree_robot/cross/README.md index ffcced2e83..b73b5d13a0 100644 --- a/jsk_unitree_robot/cross/README.md +++ b/jsk_unitree_robot/cross/README.md @@ -8,33 +8,50 @@ This project contains a set of patches and scripts to compile and run ROS1 on a We're going to use Docker to set up a container that will compile all the tools for cross-compiling ROS and all of its dependencies. Go to https://docs.docker.com/install/linux/docker-ce/ubuntu/#install-using-the-repository to install it for your Linux distribution. +We strongly recommend using an arm64v8 machine, but it will also work on x86_64 machines. + 1. Add your user to docker group ``` $ sudo usermod -aG docker $USER $ newgrp ``` -2. Install Qemu software +2. Install Qemu software (Only for x86_64 machine) ``` $ sudo apt install -y qemu-user-static ``` -### Build ROS System on Docker (Run only the fist time per host computer) +### <> Build ROS System on Docker from Archive (Run only the fist time per host computer) + +**Caution!!! Build ROS System for Unitree robot will take more than a few hours !! (some times longer than 24 hours). Therefor, if you are not a unitree robot's JSK ROS system developer, we strongly recommend to use the archive, ** + +Download the docker image (`ros1-unitree-arm64v8.tar`) and System and User archvie file (`arm64v8_System.tgz` and `arm64v8_User.tgz`) from [here](https://drive.google.com/drive/u/2/folders/1SBA9oAwjfD84yRFEB-jsCH1m5Q8eEGSK) +To extract archive, run folowing commands ``` -make system +cat ~/Downloads/ros1-unitree-arm64v8.tar | docker import - ros1-unitree:arm64v8 +roscd jsk_unitree_startup/../cross +tar -xvzf ~/Downloads/arm64v8_System.tgz +tar -xvzf ~/Downloads/arm64v8_User.tgz ``` -**Caution!!! It will take more than a few hours !! (some times longer than 24 hours).** +To confarm evemTo verify that the archive was decompressed correctly, check that the following commands are executed without error. +``` +make user +``` + +### Build ROS System on Docker from Scratch (Run only the fist time per host computer) -So For JSK users, download the output of this command (`arm64v8_System.tgz` archive file) from [here](https://drive.google.com/drive/u/2/folders/1SBA9oAwjfD84yRFEB-jsCH1m5Q8eEGSK) and extract under `jsk_unitree_robot/cross/` directory so that you can skip this process. +``` +make system +``` ### Deploy ROS System to Go1 robot After finishing former step, run following command to copy ROS1 base sytem to Go1 onboard computer. This should be done only in the first time. So normally user do not have to run this command ``` -./install.sh -p 123 -D System +./install.sh -p 123 -d System ``` ### Build `jsk_unitree_robot` software on Docker