mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-06-29 16:20:35 +08:00
PositionControl: add getter for output attitude setpoint
This commit is contained in:
@@ -365,6 +365,12 @@ void PositionControl::getLocalPositionSetpoint(vehicle_local_position_setpoint_s
|
||||
_thr_sp.copyTo(local_position_setpoint.thrust);
|
||||
}
|
||||
|
||||
void PositionControl::getAttitudeSetpoint(vehicle_attitude_setpoint_s &attitude_setpoint)
|
||||
{
|
||||
attitude_setpoint = ControlMath::thrustToAttitude(_thr_sp, _yaw_sp);
|
||||
attitude_setpoint.yaw_sp_move_rate = _yawspeed_sp;
|
||||
}
|
||||
|
||||
void PositionControl::updateParams()
|
||||
{
|
||||
ModuleParams::updateParams();
|
||||
|
||||
Reference in New Issue
Block a user