tune.friction) and gravity (tune.gravity) for all 14 joints, both arms times seven, in one command. You can also run it from the diagnostics dashboard (axol serve). For a step-by-step walkthrough, see Calibrating Axol.
Each joint sweeps back and forth at several speeds. From one sweep the tool fits both the joint’s friction and the center of mass of the link it moves.
- Time: about 6 minutes per joint, about 1.5 hours for both arms.
- Order: each arm runs from
wrist_3toshoulder_1. Each joint’s fit is saved before the next joint sweeps, so the shoulder fits use the corrected wrist and elbow values. - Poses: the clearance and gravity-load poses are the same as in
tune.frictionandtune.gravity.
slow profile calibrates friction for slow, smooth motion. On shoulder_1, shoulder_2 and elbow, a slow-profile calibration also switches the joint to stiffer slow-motion gains. A joint without one keeps the standard gains. A shoulder with an RMD-X8-P20-150 motor keeps its gains and takes only the friction fit.
Where the results go
The results are saved to~/.almond/calibration.json, and this computer uses them right away. They are also uploaded under the serial number of Axol’s hub, which stays with the arms when you swap the computer. The upload needs a write key in .env:
- A one-arm run keeps the other arm’s values.
- A joint whose gravity fit is rejected keeps its earlier
comandmass. - An interrupted run keeps and uploads every joint that finished.
Custom end-effectors
The gravity fit keeps each link’s mass fixed and fits only its center of mass. The gripper and everything mounted on it count as thewrist_3 link, including wrist cameras and their brackets. The stock mass, 0.75 kg, includes the Camera Kit wrist camera and its mount. With the parcel gripper the default is 0.6 kg. If you change the weight on the wrist, give the new wrist_3 mass before you calibrate. Otherwise the extra weight is spread over the wrong links.
Set the mass in one of two places:
- In the control panel, under General settings → Advanced, in the
wrist_3row of each arm’s table. The run uses this mass for its fits and saves it with the calibration. - On the command line, with
--mass wrist_3=<kg>. This overrides the panel setting.
--com optionally sets a starting center of mass, in metres, in that arm’s URDF link frame. A center of mass set in the panel overrides the fitted one when Axol runs, so the run warns you about it. Clear it in the panel, or use --keep-gravity.
The mass and center of mass are written to ~/.almond/calibration.json before the sweeps, so every fit uses them. They are uploaded with the calibration even if a fit fails. To go back to the standard gripper and Camera Kit wrist camera, pass the stock mass (--mass wrist_3=0.75) and calibrate again.
- A
--masswithout a side applies to every arm being calibrated. --commust name its side (left.orright.), because the arms are mirror images.- An arm that isn’t being calibrated, an unknown joint, or a mass of zero or less is an error, reported before anything moves.
elbow and wrist_1. For a step-by-step walkthrough, and when a rejected fit needs attention, see After you change the end-effector or add cameras.
Keeping a hand-tuned gravity model
If you set link masses or centers of mass by hand in the control panel (General settings → Advanced), run with--keep-gravity. The run then fits friction against your settings and doesn’t fit or save any mass or center of mass. --mass and --com still take priority over the settings. Without the flag, the run uses the masses from your settings, fits each center of mass, and warns you about any center of mass set in the settings.
friction, mass (kg) and com for each joint:
The calibration tools (
tune.factory, tune.friction, tune.gravity, tune.breakaway) move the arm under impedance control at fixed calibration gains, with gravity fed forward. They never use the motors’ firmware position loops or the production gains. Every joint is held before anything moves.calibration.push
Uploads this computer’s calibration file (~/.almond/calibration.json) under the hub serial. It merges joint by joint with what is already stored.
Use it after you calibrate joints one at a time with tune.friction, tune.gravity or tune.pid, so you don’t have to run tune.factory. It needs the same write key. --dry-run shows what would be uploaded and needs no key.
calibration.pull
Downloads a robot’s uploaded calibration into~/.almond/factory_calibration.json. This includes friction, link masses and centers of mass, so a custom gripper’s weight comes along. It needs no key. can.setup runs it at the end, so a new computer gets its robot’s calibration during setup. Run it by hand to refresh:
- The built-in defaults.
- The downloaded calibration.
- The calibration file on this computer,
~/.almond/calibration.json.
tune.friction --save, tune.pid --save or tune.gravity --save overrides the downloaded values.