mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-10-22 21:43:33 +08:00
VTOL rate control architecture improvements (#10819)
* attitude and rate setpoint message: use 3D array for thrust demand * FixedWingAttitudeControl: rework airspeed scaling * move airspeed and scaling calculation into separate method * if vtol in hover and airspeed disabled use minimum airspeed instead of trim airspeed
This commit is contained in:
@@ -103,7 +103,7 @@ vehicle_attitude_setpoint_s thrustToAttitude(const Vector3f &thr_sp, const float
|
||||
Eulerf euler = R_sp;
|
||||
att_sp.roll_body = euler(0);
|
||||
att_sp.pitch_body = euler(1);
|
||||
att_sp.thrust = thr_sp.length();
|
||||
att_sp.thrust_body[2] = -thr_sp.length();
|
||||
|
||||
return att_sp;
|
||||
}
|
||||
|
||||
@@ -827,7 +827,7 @@ MulticopterPositionControl::run()
|
||||
matrix::Quatf q_sp = matrix::Eulerf(_att_sp.roll_body, _att_sp.pitch_body, _att_sp.yaw_body);
|
||||
q_sp.copyTo(_att_sp.q_d);
|
||||
_att_sp.q_d_valid = true;
|
||||
_att_sp.thrust = 0.0f;
|
||||
_att_sp.thrust_body[2] = 0.0f;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user