mc_att_control_main: do not apply the yaw weight for the feedforward term

The meaning of the yaw weight changed with #8003:
- before, the yaw weight decreased with increasing tilt angle error, so
  it was mostly 1
- now, it is constant and depends on the tuning gains (around 0.4 by default)

It means that #8003 reduced the feedforward term, and we get the closer
behavior as before with this change.
It also reduces coupling between different parameters.
This commit is contained in:
Beat Küng
2018-04-25 16:33:09 +02:00
committed by Lorenz Meier
parent 202505fd73
commit 332a612f35
@@ -424,7 +424,6 @@ MulticopterAttitudeControl::control_attitude(float dt)
* because it's the rotation axis for body yaw and multiply it by the rate and gain. */
Vector3f yaw_feedforward_rate = q.inversed().dcm_z();
yaw_feedforward_rate *= _v_att_sp.yaw_sp_move_rate * _yaw_ff.get();
yaw_feedforward_rate(2) *= yaw_w;
_rates_sp += yaw_feedforward_rate;