Skip to content

Commit

Permalink
Plane:adjust CTUN.Pitch to remove PITCH_TRIM
Browse files Browse the repository at this point in the history
  • Loading branch information
Hwurzburg committed Jan 27, 2025
1 parent 4e12b4e commit 59e34da
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ArduPlane/Log.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -101,14 +101,14 @@ void Plane::Log_Write_Control_Tuning()
if (!ahrs.synthetic_airspeed(synthetic_airspeed)) {
synthetic_airspeed = logger.quiet_nan();
}

int16_t pitch = ahrs.pitch_sensor - g.pitch_trim * 100.0f;
struct log_Control_Tuning pkt = {
LOG_PACKET_HEADER_INIT(LOG_CTUN_MSG),
time_us : AP_HAL::micros64(),
nav_roll_cd : (int16_t)nav_roll_cd,
roll : (int16_t)ahrs.roll_sensor,
nav_pitch_cd : (int16_t)nav_pitch_cd,
pitch : (int16_t)ahrs.pitch_sensor,
pitch : pitch,
throttle_out : SRV_Channels::get_output_scaled(SRV_Channel::k_throttle),
rudder_out : SRV_Channels::get_output_scaled(SRV_Channel::k_rudder),
throttle_dem : TECS_controller.get_throttle_demand(),
Expand Down

0 comments on commit 59e34da

Please sign in to comment.