From 50cef9a201cd1c657699bd0192a5be88469b23d7 Mon Sep 17 00:00:00 2001 From: rusefillc Date: Thu, 15 Sep 2022 22:12:49 -0400 Subject: [PATCH] tear down Engine god object #4511 --- firmware/controllers/trigger/trigger_central.cpp | 4 ++-- firmware/util/efilib.h | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/firmware/controllers/trigger/trigger_central.cpp b/firmware/controllers/trigger/trigger_central.cpp index 3648d1508f..6b054077da 100644 --- a/firmware/controllers/trigger/trigger_central.cpp +++ b/firmware/controllers/trigger/trigger_central.cpp @@ -925,7 +925,7 @@ void onConfigurationChangeTriggerCallback() { if (changed) { #if EFI_ENGINE_CONTROL engine->updateTriggerWaveform(); - engine->triggerCentral.noiseFilter.resetAccumSignalData(); + getTriggerCentral()->noiseFilter.resetAccumSignalData(); #endif } #if EFI_DEFAILED_LOGGING @@ -933,7 +933,7 @@ void onConfigurationChangeTriggerCallback() { #endif /* EFI_DEFAILED_LOGGING */ // we do not want to miss two updates in a row - engine->triggerCentral.triggerConfigChanged = engine->triggerCentral.triggerConfigChanged || changed; + getTriggerCentral()->triggerConfigChanged = getTriggerCentral()->triggerConfigChanged || changed; } static void initVvtShape(TriggerWaveform& shape, const TriggerConfiguration& config, TriggerDecoderBase &initState) { diff --git a/firmware/util/efilib.h b/firmware/util/efilib.h index 3354dc27dc..139f28fd20 100644 --- a/firmware/util/efilib.h +++ b/firmware/util/efilib.h @@ -8,7 +8,9 @@ #pragma once #include +#ifdef __cplusplus #include +#endif #define _MAX_FILLER 11