switch back to flag (#4155)

This commit is contained in:
Matthew Kennedy 2022-05-09 21:52:29 -07:00 committed by GitHub
parent e8811e60a4
commit 7e0f2d8337
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View File

@ -226,7 +226,7 @@ void TriggerStateWithRunningStatistics::resetTriggerState() {
prevInstantRpmValue = 0;
m_instantRpm = 0;
synchronizedPhase.init();
m_hasSynchronizedPhase = false;
}
void TriggerStateWithRunningStatistics::movePreSynchTimestamps() {
@ -408,7 +408,7 @@ angle_t TriggerStateWithRunningStatistics::syncEnginePhase(int divider, int rema
}
// Allow injection/ignition to happen, we've now fully sync'd the crank based on new cam information
synchronizedPhase.reset();
m_hasSynchronizedPhase = true;
if (totalShift > 0) {
vvtSyncCounter++;

View File

@ -217,7 +217,7 @@ public:
// i.e. if we have enough VVT information to have full sync on
// an indeterminite crank pattern
bool hasSynchronizedPhase() const {
return !synchronizedPhase.hasElapsedSec(3);
return m_hasSynchronizedPhase;
}
private:
@ -228,7 +228,7 @@ private:
float m_instantRpm = 0;
float m_instantRpmRatio = 0;
Timer synchronizedPhase;
bool m_hasSynchronizedPhase = false;
};
angle_t getEngineCycle(operation_mode_e operationMode);