Plant fit
Identify the roll, pitch and yaw plant from a Betaflight blackbox log and get nominal control gain (b0) estimates for ADRC tuning. Everything runs in this browser tab.
The Python packages take a little while to load when the page first opens, so wait for the status below to say it's ready before dropping in a file.
The wc you plan to fly, applied to all axes. b0 is reported as the value that matches the plant at this wc, so change it here if you change wc and run again.
Plant fits
Check that the fitted lines follow the recovered data. If the fits look nonsensical, the numbers below will be too. Select the plot to open it full size.
Nominal control gain, b0 (deg/s per u), by method
Motor lag
Fitted on the chirp windows only, over a wider band than b0, as an integrator behind a first-order motor lag plus a transport delay. Motor lag (gyro) is the lag from motor command to gyro; motor lag (eRPM) is the motors' own response, from motor command to rotor speed (needs bidirectional DShot).
Warnings
Reading the results
- Inspect the plant fit plots first. They should look reasonable before you trust any of the numbers.
- If the methods in the b0 table disagree significantly, use your own judgment about which fit most closely matches the recovered G.
- Start tuning with the recovered b0 for each axis from the fit that best matches the recovered data. On a chirp flight this is usually the controller-free fit.
- The b0 values are for the proposed wc above. They are not interchangeable between wc values: the same log gives a larger b0 at a higher wc, most of all on yaw. Re-run with the wc you will actually fly.
- A “2nd pole above the excited band” warning means that axis wasn’t excited enough for a proper fit. Since b0 doesn’t need to be exact, the value can usually still be used without repeating the flight.
- The two motor lag values should be close; a gap of 1–3 ms is normal and doesn’t matter for tuning. If the gyro value is shorter, use the eRPM value, since the gyro fit can mix up lag and delay. If the gyro value is clearly longer, use the gyro value: the extra lag is real (gyro filtering, frame or props) and eRPM can’t see it.
- Yaw is fitted with an extra zero from rotor reaction torque, which makes it close to first order around wc. Its b0 therefore scales with wc: re-fit it whenever you change yaw wc. The “yaw HF gain” column (shown with Verbose output) is the number that doesn’t move with wc.