upkie
3.4.0
|
Upkie's code is organized into spines, which communicate with the simulation or mjbots actuators, and agents, the programs that implement robot behaviors. We use Bazel to build spines, both for simulation on your development computer or for running on the robot's Raspberry Pi. Bazel does not install anything on your system: it fetches dependencies with specific versions and builds them locally, making sure the code stays consistent over time. Check out this introduction for more details.
The Bullet spine runs an agent in the Bullet 3 simulator. We can start this spine as a standalone process and let it run waiting for agents to connect:
This script is just an alias for a Bazel run
command:
Check out simulation options (fly like an eagle!) with the help flag -h
.
The pi3hat spine is the one that runs on the real robot, where a pi3hat r4.5 is mounted on top of the onboard Raspberry Pi computer. To run this spine, we can either: download it from GitHub, or build it locally from source.
To get the latest pi3hat spine from GitHub, download the latest pi3hat_spine
binary from Continuous Integration build artifacts, then scp
it to the robot. TODO: make this more user-friendly ;)
Once the spine is running, you can run any agent in a separate shell on the robot, for example the wheel balancer:
To build the pi3hat locally from source, then upload it to Raspberry Pi, use the Makefile at the root of the repository:
Next, log into the Pi and run a pi3hat spine:
Once the spine is running, you can run any agent in a separate shell on the robot, for example the wheel balancer:
The mock spine is useful to run an agent on the robot without firing up the actuators. It works exactly as the pi3hat spine, replacing "pi3hat" with "mock" in all instructions above.