use onConfigurationChange instead of version holder
This commit is contained in:
parent
dff215461f
commit
6be4d6073f
|
@ -39,11 +39,13 @@ void VvtController::onFastCallback() {
|
|||
return;
|
||||
}
|
||||
|
||||
if (engine->vvtParametersVersion.isOld(engine->getGlobalConfigurationVersion())) {
|
||||
update();
|
||||
}
|
||||
|
||||
void VvtController::onConfigurationChange(engine_configuration_s const * previousConfig) {
|
||||
if (!m_pid.isSame(&previousConfig->auxPid[index])) {
|
||||
m_pid.reset();
|
||||
}
|
||||
|
||||
update();
|
||||
}
|
||||
|
||||
expected<angle_t> VvtController::observePlant() const {
|
||||
|
|
|
@ -28,6 +28,7 @@ public:
|
|||
|
||||
// EngineModule implementation
|
||||
void onFastCallback() override;
|
||||
void onConfigurationChange(engine_configuration_s const * previousConfig) override;
|
||||
|
||||
// ClosedLoopController implementation
|
||||
expected<angle_t> observePlant() const override;
|
||||
|
|
|
@ -219,7 +219,6 @@ public:
|
|||
void setConfig();
|
||||
|
||||
LocalVersionHolder versionForConfigurationListeners;
|
||||
LocalVersionHolder vvtParametersVersion;
|
||||
|
||||
AuxActor auxValves[AUX_DIGITAL_VALVE_COUNT][2];
|
||||
|
||||
|
|
Loading…
Reference in New Issue