diff options
author | Lorenz Meier <lm@inf.ethz.ch> | 2013-10-08 09:17:58 +0200 |
---|---|---|
committer | Lorenz Meier <lm@inf.ethz.ch> | 2013-10-08 09:17:58 +0200 |
commit | a3bdf536e5f6b95d54ef6684d7092ebff2d23dc8 (patch) | |
tree | 3d02ca2a53b9035f3f8499a07ed3902def18fd15 /src/modules/fw_att_control/fw_att_control_main.cpp | |
parent | d59cdf6fcc99e85cc1d897637b1bf9e18269f77c (diff) | |
download | px4-firmware-a3bdf536e5f6b95d54ef6684d7092ebff2d23dc8.tar.gz px4-firmware-a3bdf536e5f6b95d54ef6684d7092ebff2d23dc8.tar.bz2 px4-firmware-a3bdf536e5f6b95d54ef6684d7092ebff2d23dc8.zip |
Dynamic integral resets for straight and circle mode, announcing turn radius now
Diffstat (limited to 'src/modules/fw_att_control/fw_att_control_main.cpp')
-rw-r--r-- | src/modules/fw_att_control/fw_att_control_main.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/modules/fw_att_control/fw_att_control_main.cpp b/src/modules/fw_att_control/fw_att_control_main.cpp index 6b98003fd..ae9aaa2da 100644 --- a/src/modules/fw_att_control/fw_att_control_main.cpp +++ b/src/modules/fw_att_control/fw_att_control_main.cpp @@ -593,6 +593,10 @@ FixedwingAttitudeControl::task_main() pitch_sp = _att_sp.pitch_body; throttle_sp = _att_sp.thrust; + /* reset integrals where needed */ + if (_att_sp.roll_reset_integral) + _roll_ctrl.reset_integrator(); + } else { /* * Scale down roll and pitch as the setpoints are radians |