Stabilized quadcopter
A quadcopter built end to end, from part selection and PCB design to flight-control firmware, that holds a stable attitude in manual flight.
A quadcopter is unstable by construction: it has four actuators, six degrees of freedom, and no passive tendency to stay level. Keeping it in the air means closing a control loop faster than the airframe can fall out of one.
- Every part selected and sourced individually, no kit
- Custom PCB, designed and populated by hand
- Attitude loop running at about 1 kHz on an STM32, fast enough to correct before divergence
- Total mass budget fixed by the motors and props chosen first
Build the board rather than buy a flight controller
An off-the-shelf controller would have flown sooner, but the point was to understand the whole stack: power, sensing, actuation and the loop between them. Designing the PCB forced every one of those decisions to be explicit.
Sensor fusion over a single sensor
The accelerometer is trustworthy over long spans and noisy over short ones; the gyroscope is the reverse. Fusing them gives an attitude estimate that is neither jittery nor drifting, which is what the control loop actually needs.
Tune the inner loop before adding anything outer
Attitude hold had to be solid on its own before position or navigation could mean anything. Each outer loop was only added once the one beneath it stopped fighting back.
I would instrument the loop from the first day instead of the first crash. Logging attitude estimate and motor output to look at afterwards turned tuning from guesswork into reading a graph, and I only started doing it late.
