Reaction Wheel Stabilized Inverted Pendulum

Inspiration


Goals

After seeing that video I wanted to learn more about this reaction wheel stabilized system and get some basic experience designing control algorithms. With the added desire to brush up on my EE skills I decided to embark on an effort to build the following:
- reaction wheel stabilization module for inverted pendulums (no swing up)
- LQR optimal control algorithm with quaternion based attitude specification
- brushless DC motors for reaction wheel torque
- battery powered electronics on PCB in small form factor

Controller Design

I performed this part in two stages: (1) single rotation axis with euler angles and (2) full three axis control with quaternions. Each control algorthim utilized an LQR controller. In the first stage I wrote my first LQR controller and simulated the physics in 2D space. Adapting some code by toddisfleet, I was able to create a visualization of the inverted pendulum and the one reaction wheel that stabilized it.


Figure 1: 1-axis stabilized inverted pendulum

The next stage was implementing 3-axis stabilization using quaternions and LQR controller. Particularly useful in [Yang 2010] was the reduction of number of quaternions from 4 terms to 3 terms and a few linearizations. The simulation below shows a top-down view of the inverted pendulum recovering from an initial offset.

Figure 2: Top down view of 2-axis stabilized inverted pendulum


Stay tuned...