Refactoring on pid iterm
Some pid refactoring mainly addresses the accumulation of iterm. I believe this will improve flight performance on low-authority multirotor, such as vtol platform.
Changes:
- Stronger
iterm_windup, enhances the effectiveness when the value is set below the default value(50), no accumulation occurs wheniterm_windup+50of motor correction range is reached. When value is set to equal or above 50, remain the same behaviors as the current master. - ~~combine
itermLimitActivewithitermFreezeActivetoitermFreezeActive. Because the actualitermLimitActiveimplementation has the same result asitermFreezeActive~~ - remove
fw_iterm_throw_limitand introducepid_iterm_limit_percent pid_iterm_limit_percentlimit the accumulated iterm by percentage ofpidsum_limitorpidsum_limit. This iterm limit is also applied to MR pid controller. The default value is set to 33%, which behaves the same asfw_iterm_throw_limitdefault 165.- add option to enable tpa on yaw axis
- I term back caculation anti-windup can not push the I iterm to opposite direction
Have done some tests with SITL in the real flight simulator, The flight performance was terrible but become acceptable with vtol platforms
we need something equivalent to IMAX
Ah, I thought it's for MR and wanted to test it today :)
after some study, i have found this pr https://github.com/iNavFlight/inav/pull/6387
thinking about revert this
combine itermLimitActive with itermFreezeActive to itermFreezeActive. Because the actual itermLimitActive implementation has the same result as itermFreezeActive
@shota3527 I see this was opened, then closed, then re-opened. Is it still current?