On the Control of Self-Balancing Unicycles

Abstract

This paper discusses the problem of designing a self-balancing unicycle where pedals are used for both power generation and speed control. After developing the principal physical aspects (in the longitudinal dimension), we describe an abstract model in the form of a collection of hybrid automata, together with design requirements to be met by an ideal controller. We discuss simplifications and assumptions that make this model amenable to verification and validation tools such as SpaceEx. To enable experimentation with different prototypical controllers and user behaviours in concrete scenarios, we also develop a simple simulation framework using digital time.

You can find the paper at EPTCS and arXiv or download the PDF version here.

Additional Materials

Here, you can find additional materials and background information.

Mathematica Model

We have developed a simulation framework in Mathematica.

You can find all files referenced below in a ZIP file you can download here.

The model is split up into multiple files, quickly described below:

File Description
ControllableSystem.m Defines methods to simulate systems with a given controller and user input using digital time.
Unicycle.m Defines the unicycle (with exemplary parameters), the equations of motion and methods to visualize states.
ControlledUnicycle.nb This file defines exemplary user input and a simple PID-based controller and runs the simulation.

Visualizations

The Mathematica model can generate a visualization of states of the unicycle. These can be played back as a movie. The animated image below visualizes the results of the simulation run by ControlledUnicycle.nb.

SpaceEx Model

We have formalized a linearized version of our Model in SpaceEx.

You can find all files referenced below in a ZIP file you can download here:

There are multiple verions of this model, quickly described below:

Files Description
unicycle-base.xml, unicycle-base.cfg A linearized version of the system with a minimal controller which simple passes on userIntent without any modification.
unicycle-pid.xml A variant of unicycle-base.xml that includes a PID-based controller, but cannot be analyzed in SpaceEx anymore.