axol-rt, the real-time core that controls the motors for teleop and every other command that moves the arms. Axol can’t control hardware without it. axol provision runs it for you. Run it yourself to rebuild:
What it does
- Installs Rust if needed. If
cargoisn’t on your PATH or in~/.cargo/bin, it installs a minimal Rust toolchain with rustup into~/.cargo. This doesn’t needsudo. - Gets the source code. In a development checkout it builds
rust/axol-rt. Otherwise it downloads the source that matches the installedaxolversion into~/.almond/axol-rt-src. - Builds and installs the binary. In a development checkout the binary stays in
rust/axol-rt/target/release/. Otherwise it goes inUV_TOOL_BIN_DIRif that is set, or in~/.local/bin/axol-rt. The hosted installer puts it in/usr/local/bin/axol-rt. Running it again at the same version skips the build. - Grants permissions. It gives the binary permission to run at real-time priority (
CAP_SYS_NICE) and to lock its memory (CAP_IPC_LOCK). This needs root, so it may ask for yoursudopassword. Withoutsudo, it prints thesudo setcapcommand to run once.
Building from other source
Ifrt.install can’t find the right source, such as when axol was installed from a wheel file, set AXOL_RT_SOURCE to a checkout path, or to <git url>@<branch|tag|commit>. Setting it always rebuilds.
Which binary runs
Axol uses the firstaxol-rt it finds, in this order:
- the path in
AXOL_RT_BIN - the build in the current development checkout
axol-rton your PATH
If arming fails
- Version mismatch.
axolandaxol-rtmust come from the same version. If they don’t,axol-rtrefuses to start before any motor moves, and the session fails withaxol-rt … refused the configuration and exited. Runaxol rt.install, or runcargo build --releaseinrust/axol-rtin a development checkout. - No real-time priority.
axol-rtwon’t arm the motors if it can’t get real-time priority. Runaxol rt.installagain to restore its permissions.
axol-rt can’t lock its memory, it logs a warning and runs anyway.
When
axol provision runs this step and it fails, provision finishes the other steps and then exits with code 1. Run axol rt.install by itself to see the full error.