diff --git a/ArduPlane/Log.cpp b/ArduPlane/Log.cpp index 6b7f698e25..5b8bd3e3a7 100644 --- a/ArduPlane/Log.cpp +++ b/ArduPlane/Log.cpp @@ -20,9 +20,13 @@ void Plane::Log_Write_Attitude(void) quadplane.attitude_control->get_attitude_target_quat().to_euler(targets.x, targets.y, targets.z); targets *= degrees(100.0f); quadplane.ahrs_view->Write_AttitudeView(targets); - } else { + } else +#endif + { ahrs.Write_Attitude(targets); } + +#if HAL_QUADPLANE_ENABLED if (AP_HAL::millis() - quadplane.last_att_control_ms < 100) { // log quadplane PIDs separately from fixed wing PIDs logger.Write_PID(LOG_PIQR_MSG, quadplane.attitude_control->get_rate_roll_pid().get_pid_info());