mirror of
https://gitee.com/mirrors_PX4/PX4-Autopilot.git
synced 2026-05-19 20:29:05 +08:00
FW att ctrl - Fix vehicle_attitude_setpoint timestamp logging when in stabilized (#7803)
This commit is contained in:
parent
63306ada92
commit
25bbe76530
@ -989,6 +989,7 @@ FixedwingAttitudeControl::task_main()
|
||||
// in STABILIZED mode we need to generate the attitude setpoint
|
||||
// from manual user inputs
|
||||
if (!_vcontrol_mode.flag_control_climb_rate_enabled && !_vcontrol_mode.flag_control_offboard_enabled) {
|
||||
_att_sp.timestamp = hrt_absolute_time();
|
||||
_att_sp.roll_body = _manual.y * _parameters.man_roll_max + _parameters.rollsp_offset_rad;
|
||||
_att_sp.roll_body = math::constrain(_att_sp.roll_body, -_parameters.man_roll_max, _parameters.man_roll_max);
|
||||
_att_sp.pitch_body = -_manual.x * _parameters.man_pitch_max + _parameters.pitchsp_offset_rad;
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user