Assembled kit
This document applies to you if you ordered an assembled kit. This page instructs you on how to partly set up the already assembled SO-ARM101 package.
Here's what has been done to your arms:
Set motor ids
Calibration
Teleoperation
However, you will have to calibrate the arms again,
Follow the following steps, to get started:
Install LeRobot
Download the LeRobot source code:
git clone https://github.com/huggingface/lerobot.git
cd lerobot
Create a virtual environment with Python 3.10, using Miniconda
conda create -y -n lerobot python=3.10
Then activate your conda environment, you have to do this each time you open a shell to use lerobot:
conda activate lerobot
When using miniconda
, install ffmpeg
in your environment:
conda install ffmpeg -c conda-forge
This usually installs ffmpeg 7.X
for your platform compiled with the libsvtav1
encoder. If libsvtav1
is not supported (check supported encoders with ffmpeg -encoders
), you can:
Explicitly install
ffmpeg 7.X
using:conda install ffmpeg=7.1.1 -c conda-forge
If you want to bring your own ffmpeg: Install ffmpeg build dependencies and compile ffmpeg from source with libsvtav1, and make sure you use the corresponding ffmpeg binary to your install with
which ffmpeg
.
Install 🤗 LeRobot:
pip install -e .
Troubleshooting
If you encounter build errors, you may need to install additional dependencies: cmake
, build-essential
, and ffmpeg libs
. To install these for linux run:
sudo apt-get install cmake build-essential python-dev pkg-config libavformat-dev libavcodec-dev libavdevice-dev libavutil-dev libswscale-dev libswresample-dev libavfilter-dev pkg-config
2. Find the USB ports associated with each arm
To connect servo board to the pc refer to this picture.
To find the port for each bus servo adapter, run this script:
python -m lerobot.find_port
Example output:
Finding all available ports for the MotorBus.
['/dev/tty.usbmodem575E0032081', '/dev/tty.usbmodem575E0031751']
Remove the USB cable from your MotorsBus and press Enter when done.
[...Disconnect corresponding leader or follower arm and press Enter...]
The port of this MotorsBus is /dev/tty.usbmodem575E0032081
Reconnect the USB cable.
Where the found port is: /dev/tty.usbmodem575E0032081
corresponding to your leader or follower arm.
Calibrate
Next, you’ll need to calibrate your robot to ensure that the leader and follower arms have the same position values when they are in the same physical position. The calibration process is very important because it allows a neural network trained on one robot to work on another.
Follower
Run the following command:
python -m lerobot.calibrate \
--robot.type=so101_follower \
--robot.port=/dev/tty.usbmodem58760431551 \ # <- The port of your robot
--robot.id=my_awesome_follower_arm # <- Give the robot a unique name
The video below shows how to perform the calibration. First you need to move the robot to the position where all joints are in the middle of their ranges. Then after pressing enter you have to move each joint through its full range of motion.
Please refer to these joint movements for now as we work on our video.
Leader
Do the same steps to calibrate the leader arm, run the following command and follow calibration step:
python -m lerobot.calibrate \
--teleop.type=so101_leader \
--teleop.port=/dev/tty.usbmodem58760431551 \ # <- The port of your robot
--teleop.id=my_awesome_leader_arm # <- Give the robot a unique name
Teleoperate
Note that the
id
associated with a robot is used to store the calibration file. It’s important to use the sameid
when teleoperating, recording, and evaluating when using the same setup.Command:
python -m lerobot.teleoperate \ --robot.type=so101_follower \ --robot.port=/dev/tty.usbmodem58760431541 \ -> the port of your follower arm --robot.id=my_awesome_follower_arm \ --teleop.type=so101_leader \ --teleop.port=/dev/tty.usbmodem58760431551 \ -> the port of your leader arm --teleop.id=my_awesome_leader_arm
You are now ready to do more. Follow... Reach out to us at [hello@partabot.com] if anything seems off — we’re here to help!
Last updated