antilag and anti-lag #2403

TurboMarian is the ALS boss
This commit is contained in:
rusefillc 2022-12-21 21:29:01 -05:00
parent 5556841520
commit d671cee3a8
3 changed files with 12 additions and 2 deletions

View File

@ -464,6 +464,9 @@ static void setDefaultEngineConfiguration() {
setLinearCurve(config->scriptCurve5Bins, 0, 100, 1);
setLinearCurve(config->scriptCurve6Bins, 0, 100, 1);
setLinearCurve(config->alsIgnRetardLoadBins, 0, 10, 5);
setRpmTableBin(config->alsIgnRetardrpmBins);
#if EFI_ENGINE_CONTROL
setDefaultWarmupIdleCorrection();

View File

@ -406,10 +406,11 @@ float getfuelALSCorrection(int rpm, float engineLoad) {
config->alsFuelAdjustmentrpmBins, rpm
);
return AlsFuelAdd;
} else {
} else
#endif /* EFI_ANTILAG_SYSTEM */
{
return 1;
}
#endif /* EFI_ANTILAG_SYSTEM */
}
#if EFI_ENGINE_CONTROL

View File

@ -570,6 +570,12 @@ bool validateConfig() {
ensureArrayIsAscending("Boost control RPM", config->boostRpmBins);
#endif // EFI_BOOST_CONTROL
#if EFI_ANTILAG_SYSTEM
// ALS
ensureArrayIsAscending("ALS TPS", config->alsIgnRetardLoadBins);
ensureArrayIsAscending("ALS RPM", config->alsIgnRetardrpmBins);
#endif // EFI_ANTILAG_SYSTEM
// ETB
ensureArrayIsAscending("Pedal map pedal", config->pedalToTpsPedalBins);
ensureArrayIsAscending("Pedal map RPM", config->pedalToTpsRpmBins);