The MPC balancer allows Upkie to stand upright, balancing with its wheels only, by closed-loop model predictive control. It performs better than the demo PID balancer with significantly less hacks ;-)
conda create -f environment.yaml
conda activate mpc_balancer
pip install upkie[mpc_balancer]
This instruction works on both your dev machine and the robot's Raspberry Pi.
To test the agent in simulation, run the Bullet spine, then start the agent:
make run_locally
To run this agent on a real Upkie, you can use the Makefile at the root of the repository:
$ make build
$ make upload
$ ssh your-upkie
user@your-upkie:~$ make run_with_python