Playground · Month 4 · control
Hold a drone in the air with three numbers.
Every robot you've seen balance, hover or hold a pose runs a feedback loop: measure the error, push against it, repeat hundreds of times a second. Start with the presets, then break it on purpose.
Dashed green line: the target height. Shaded band: within 10 cm. The flight replays in real time.
Bounces forever and never holds the height.
the controller
thrust = Kp·e + Ki·∫e dt + Kd·de/dt
e = target − height
P: the spring
Push in proportion to the error. Alone, it overshoots and, against gravity, never quite gets there.
I: the memory
Add up the error over time. It slowly finds the exact thrust hovering needs and kills the leftover gap.
D: the brake
React to how fast the error changes. It damps the bouncing before it starts.