Estimators, controllers, and mixers — the pipeline from sensor fusion to motor outputs.
The flight stack is the collection of guidance, navigation, and control algorithms for autonomous drones. It includes controllers for fixed-wing, multirotor, and VTOL airframes, as well as estimators for attitude and position.
The pipeline flows from sensors through three key stages: estimation (what is my state?), control (what corrections are needed?), and mixing (how do I translate corrections into motor commands?).
Flight Stack Pipeline
Sensor → Motor Pipeline
Sensors
IMU (accel + gyro), magnetometer, barometer, GPS, optical flow, rangefinder. Each driver publishes raw data to uORB.
Estimator (EKF2)
Extended Kalman Filter fuses all sensor inputs into vehicle_attitude, vehicle_local_position, and vehicle_global_position estimates.
Navigator / Commander
Mission logic and mode management. Generates position and velocity setpoints for the controller.
Position Controller
Compares position setpoint with estimated position. Outputs velocity setpoint.
Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.
Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.
Each stage publishes its output as a uORB topic — the next stage subscribes to it
Estimator vs Controller vs Mixer
Estimator: combines sensor inputs to compute state (attitude, position). Controller: takes a setpoint and estimated state, outputs a correction. Mixer: takes force/torque commands and maps them to specific motor/servo outputs based on airframe geometry.
The cascaded controller design means each inner loop runs faster than the outer loop. Rate control runs at the IMU rate (~250 Hz). Attitude control typically runs at the same rate. Position and velocity control run at a lower rate (50–100 Hz). This separation lets each loop be tuned independently.