How to Write your own Flight Controller Software — Part 3

The PID Loop

In Part 1 of our series we spoke about the flight controller PID Loop. It is worth revisting that now (see Figure 1). In previous parts we have spoken about how we decode the remote control input, r(t), and how we generate our PWM control for the ESC, u(t). In Part 3, we will look at the roll, pitch and yaw inputs from the IMU and combining that with r(t) to get our error signal , e(t), which is fed into our PID loop. We will output the desired setpoint and PID loop output to the Nexgen Configurator to assist…