The SO-101
make so101-fetch # once
make sim # in Gazebo
make scenario NAME=all # in a second terminal
The SO-101 is TheRobotStudio's open arm: five joints and a jaw, six
STS3215 bus servos, Apache-2.0. It is the robot the course is taught on.
Nobody here designed it. It runs under this project's controllers,
client, scenarios and test suite, and the only thing that names it is
PROFILE, whose default is so101_follower. The 3VN Arm 1, the arm
this project was first built on, is one argument away:
PROFILE=threevn_arm_v1.
The spike is how that started, and what it broke. This page is what it became.
A profile that is an overlay
The 3VN arm's profile is the source of its physical truth: every length, mass and limit is in the YAML, and the URDF is generated from it.
The SO-101 already has a URDF. Copying its numbers into a profile would
create a second copy that could disagree with the first, with nothing to
say which was right. So so101_follower.yaml restates no kinematics.
It adds only what a URDF has no place for:
| In the profile | Why |
|---|---|
| Which joints are the arm, and which is the gripper | Nothing in a URDF says so |
| How far the gripper opens and closes | It is a revolute jaw, in radians; the 3VN arm's is prismatic, in metres |
| Named poses | Five numbers each, for this arm |
| The servo's datasheet figures | Upstream's limits are placeholders |
| The execution targets | mock, gz and feetech |
describe() puts the two together at launch, in memory. The file in
vendor/ is never edited.
make urdf | less
What the overlay changes, and why
It anchors the arm. Upstream has no world link, so its base is a
free body, and a 632 g arm falls over the first time a joint moves. A
real one is clamped to a bench. The overlay is that clamp.
It replaces the limits. Upstream declares effort="10" on every
joint. An STS3215 stalls at about 1.9 N·m, so the arm as shipped is five
times stronger in simulation than on the bench: a motion that succeeds
in Gazebo and stalls in reality. The overlay derives effort and velocity
from the datasheet, the same rule the 3VN arm follows. Position limits
are upstream's, untouched.
It simplifies what the physics sees. Upstream's collision geometry is its visual geometry: full printed-part meshes, most of them tens of thousands of triangles. Measured here, on CPU physics:
| Collision geometry | Real-time factor |
|---|---|
| Upstream's meshes | 0.11 to 0.13 |
| Each mesh's bounding box | 0.91 to 1.03 |
The simulator tier of the test suite refuses anything under 0.3. A bounding box is never smaller than the part, so it errs toward a contact that would not quite have happened. It is too coarse for the jaws to close on something small; a grasp will want the two jaw links back as meshes.
It gives the joints friction. Upstream declares none, so every joint is a frictionless hinge. That was invisible until the jaw was closed with the gripper pointing down. Gravity helped it along, which held it at exactly its velocity limit, and it ran through "closed" into its hard stop and never moved again. The physics engine gives each joint one constraint, in the order position limit, velocity limit, servo: a joint sitting on a limit is not being driven at all. Level, gravity does not act about that axis, and everything worked.
The pick_and_place scenario passed throughout. Its release step was a
bare wait with no check, and the gripper action "succeeded" by stalling.
The step has a check now, and with the friction removed it fails.
One piece of this is still there. A joint commanded exactly onto a hard stop in Gazebo can stay on it. The gripper's named travel keeps clear of both stops, and the teleop uses that travel, so the ordinary commands never do it; sending the jaw to its raw upper limit by hand still can.
It says what the robot is. A <threevn_semantics> element carries
the arm's joints, the gripper's travel and the named poses inside the
description. The client reads them from /robot_description, where it
already reads the joint limits. So a client attached to a running robot
gets that robot's poses without being told which profile launched it.
make urdf | grep -A9 threevn_semantics
The description is a dependency, so it has a version
make so101-fetch used to pull from upstream's main. A joint renamed
there would have failed tests here with nothing changed in this
repository. It now fetches one commit and checks the URDF's SHA-256
before installing it. Taking a newer upstream is a deliberate change:
move the pin, read the diff, run the suite, then update the checksum.
The same suite, another robot
make test-ros
make test-sim
These are the 3VN arm's integration tests. They name no joint: they read
the joints, limits, frames and poses out of the description of whichever
robot PROFILE is. One test is skipped on the SO-101 and says why: the
3VN arm's home position can be added up by hand from its YAML, and a
foreign arm's cannot.
Running them found something the mock target could not. The move_joint
scenario used to jog each joint and leave it there. On the 3VN arm, with
hand-picked targets, that was survivable. On a longer arm three small
jogs forward put the gripper through the bench, and only physics
noticed. Each joint now returns before the next moves.
The swap point
make mock # target: mock
make sim # target: gz
make robot # target: feetech (the physical arm)
The third line is the only one that needs an arm. The controllers file,
the topics, the actions and the six scenarios do not change between
them; the description's <ros2_control> block names a different plugin,
and that is all.
That plugin is FeetechSystemInterface. It is small, because a bus
servo is already a closed-loop controller with a serial port: there is
no firmware of ours on the far side, as there is for the 3VN arm's
ESP32. Every control cycle it asks all six servos where they are in one
request, and tells all six where to go in one more. What it is
responsible for is the part that matters on a bench:
- It will not start if a servo the description names does not answer, and it says which one, by joint name and bus id.
- It does not move the arm when torque comes on. Each servo's goal is set to where it already is, and only then is it powered.
- It converts between a joint's radians and a servo's counts using a zero and a direction per joint, from the profile.
- A servo that stays quiet for half a second is an error the controller manager can act on, not a line in a log.
Rehearsing the swap with nothing plugged in
make fake-bus # terminal 1: six simulated servos
make robot BUS=fake # terminal 2: the real plugin
make scenario NAME=all # terminal 3
make fake-bus is the arm one layer below the simulator. Gazebo stands
in for the arm's physics; this stands in for its wiring. It answers the
servo protocol byte for byte, behind a TCP port, so what runs against it
is the real plugin, the real protocol code and the real transport. It is
test equipment: it is built with the tests and is not in the image that
ships to a robot.
The integration suite runs the same way:
make test-ros TARGET=feetech
TCP is not a detour. Docker Desktop on a Mac cannot pass a USB device into a container, so on a Mac the real adapter is also reached through a TCP port served from the host:
make robot TRANSPORT=tcp ENDPOINT=host.docker.internal:6560
On a Linux host the profile's serial device is opened directly.
What the rehearsal does not prove
No real servo has answered this code. The protocol was written from the published packet layout and register table. The simulated bus was written from the same reading, so the two agree by construction. The tests check the packet encoder against bytes worked out by hand, which catches a slip in the code but not a misreading of the manual.
Three things are assumptions until the arm exists, and each is marked where it lives:
- The register addresses and byte order, in
feetech_protocol.hpp. - Each joint's zero count and direction, in the profile. They are
2048and+1for every joint, which is what a perfectly centred arm with every servo the right way round would have. A wrong direction drives a joint the wrong way, so the first motion on the real arm is small and slow. - Whether a servo's goal register follows its shaft while torque is off. The simulated bus assumes it does not, which is the stricter case.
One behaviour is a decision, and worth knowing before the first session:
when the hardware is deactivated the servos are released, and the arm
goes limp. That is why the profile has a rest pose.
Deactivation only happens on a clean stop: Ctrl-C, or make stop, which
sends SIGINT and waits before forcing anything. Until 2026-11-27
make stop killed the stack with -9, the interface never ran, and
measured on the simulated bus every servo kept torque on. A crash still
does that: if the host dies, the servos hold their last goal under
power. What should happen then is not decided yet.
A leader arm, rehearsed
make fake-bus # the follower's bus, 6560
make robot BUS=fake # the follower
make fake-bus BUS_PORT=6561 HAND=1:600:4 # the leader's bus, a hand on servo 1
make leader # read the leader, drive the follower
make leader-lag # how far behind it runs
threevn_control's leader node reads the leader's six positions with
one sync read per tick (30 Hz, the profile's leader.rate_hz), turns
them into radians through the leader's own calibration (the profile's
leader: block, assumed until measured), clips each to the follower's
limits from its description, and sends the arm a trajectory and the jaw
a gripper goal. It publishes what it read on /leader/joint_states.
Its protocol module, feetech.py, has no write instruction: a leader is
limp so a hand can move it.
HAND=ID:AMPLITUDE:PERIOD on the fake bus swings a limp servo, which is
what a hand does to a real leader. Measured on 2026-11-30 on two fake
buses: the follower ran 90 ms and 120 ms behind the leader on two runs,
with under 3 degrees of error left at that delay. That is the software
chain only. The lag between two physical arms waits on the physical
leader arm, and serial transport for the reader is not written yet.
What does not work yet
- The physical arm. Everything above has run against simulations of it, at two levels, and against nothing else. So has the course lab's Arm panel, which drives it from a browser over Web Serial behind its own gate (see the course site): tested against a simulated bus in the page, never a real servo. The same goes for its Leader panel, which reads a leader arm and has the sim (and an armed follower) copy it.
- Grasping on a real bench. In Gazebo it works and is verified, with
mesh collisions on the two jaw links (
make grasp, see manipulation); the physical jaw, its friction and its servo's stall behaviour are unmeasured. - A real camera. The simulated one is a fixed overhead camera added by
the overlay (ADR 0006,
make camera); a real one needs calibrated intrinsics and has lens distortion this one does not.
To see the arm move, make play starts it in headless Gazebo with RViz
at http://localhost:8106/vnc.html. On any other backend, start it and
run make watch in another terminal: RViz, attached to whichever robot
is running.