Override trigger gaps feature #2734
This commit is contained in:
parent
8e409c3712
commit
bd48753682
|
@ -548,12 +548,14 @@ void TriggerState::decodeTriggerEvent(
|
||||||
|
|
||||||
int rpm = GET_RPM();
|
int rpm = GET_RPM();
|
||||||
floatms_t engineCycleDuration = getEngineCycleDuration(rpm PASS_ENGINE_PARAMETER_SUFFIX);
|
floatms_t engineCycleDuration = getEngineCycleDuration(rpm PASS_ENGINE_PARAMETER_SUFFIX);
|
||||||
|
if (!engineConfiguration->useOnlyRisingEdgeForTrigger) {
|
||||||
int time = currentCycle.totalTimeNt[0];
|
int time = currentCycle.totalTimeNt[0];
|
||||||
efiPrintf("%s duty %f %d",
|
efiPrintf("%s duty %f %d",
|
||||||
name,
|
name,
|
||||||
time / engineCycleDuration,
|
time / engineCycleDuration,
|
||||||
time
|
time
|
||||||
);
|
);
|
||||||
|
}
|
||||||
|
|
||||||
for (int i = 0;i<triggerShape.gapTrackingLength;i++) {
|
for (int i = 0;i<triggerShape.gapTrackingLength;i++) {
|
||||||
float ratioFrom = triggerShape.syncronizationRatioFrom[i];
|
float ratioFrom = triggerShape.syncronizationRatioFrom[i];
|
||||||
|
@ -567,10 +569,11 @@ void TriggerState::decodeTriggerEvent(
|
||||||
efiPrintf("index=%d NaN gap, you have noise issues?",
|
efiPrintf("index=%d NaN gap, you have noise issues?",
|
||||||
i);
|
i);
|
||||||
} else {
|
} else {
|
||||||
efiPrintf("%s rpm=%d time=%d index=%d: gap=%.3f expected from %.3f to %.3f error=%s",
|
efiPrintf("%s rpm=%d time=%d eventIndex=%d gapIndex=%d: gap=%.3f expected from %.3f to %.3f error=%s",
|
||||||
triggerConfiguration.PrintPrefix,
|
triggerConfiguration.PrintPrefix,
|
||||||
GET_RPM(),
|
GET_RPM(),
|
||||||
/* cast is needed to make sure we do not put 64 bit value to stack*/ (int)getTimeNowSeconds(),
|
/* cast is needed to make sure we do not put 64 bit value to stack*/ (int)getTimeNowSeconds(),
|
||||||
|
currentCycle.current_index,
|
||||||
i,
|
i,
|
||||||
gap,
|
gap,
|
||||||
ratioFrom,
|
ratioFrom,
|
||||||
|
|
Loading…
Reference in New Issue