I've inspected the flight code and found a simple workaround for this issue, I think.
Do not set
Flight Mode to
Manual in
Flight Mode Switch Positions.
Instead, set
Flight Mode to
Stabilized 6, e.g., and then setup the
Roll, Pitch, Yaw & Thrust = Manual for it in the respective row in
Stabilization Modes Configuration.
This will force all axes to reinitialize upon ANY flight mode change, incl. from "Manual", as it is now treated as just another Stabilization Mode, and will zero the integrals:
stabSettings.innerPids[t].iAccumulator = 0;
stabSettings.outerPids[t].iAccumulator = 0; effectively canceling the potential windup.
I'd like the "
Zero the integral when throttle is low" to be
disabled to help when gliding the plane without throttle. This can, however, cause trouble on take-off. But with the previously described setup, I just need to switch from Manual to Attitude *JUST* before launch to zero the integrals
The only drawback I see with this setup is that manual controls do not work until the EKF is initialized. Not a big deal...