diff --git a/src/modules/control_allocator/VehicleActuatorEffectiveness/ActuatorEffectivenessControlSurfaces.cpp b/src/modules/control_allocator/VehicleActuatorEffectiveness/ActuatorEffectivenessControlSurfaces.cpp index 46f93f4e97..f6e216b855 100644 --- a/src/modules/control_allocator/VehicleActuatorEffectiveness/ActuatorEffectivenessControlSurfaces.cpp +++ b/src/modules/control_allocator/VehicleActuatorEffectiveness/ActuatorEffectivenessControlSurfaces.cpp @@ -32,6 +32,7 @@ ****************************************************************************/ #include +#include #include "ActuatorEffectivenessControlSurfaces.hpp" @@ -121,8 +122,12 @@ void ActuatorEffectivenessControlSurfaces::updateParams() // If PWM center is set and CA_SV_CS trim is non-zero, warn and reset to 0 if (pwm_center_set && fabsf(_params[i].trim) > FLT_EPSILON) { - PX4_WARN("CA_SV_CS%d_TRIM (%.3f) should be 0 when PWM CENTER is used. Resetting to 0.", - i, (double)_params[i].trim); + /* EVENT + * @description Display warning in GCS when TRIM settings were present and now CENTER are set. + */ + events::send(events::ID("control_surfaces_reset_trim"), events::Log::Warning, + "CA_SV_CS{1}_TRIM ({2}) is reset to 0 as PWM CENTER is used", i, _params[i].trim); + _params[i].trim = 0.0f; // Update the parameter storage param_set(_param_handles[i].trim, &_params[i].trim);