RPM refactoring

This commit is contained in:
rusefi 2017-07-06 19:15:10 -04:00
parent ba42a98c2f
commit 534b8f154e
2 changed files with 2 additions and 2 deletions

View File

@ -259,7 +259,7 @@ static void periodicSlowCallback(Engine *engine) {
}
#endif
if (!engine->rpmCalculator.isRunning()) {
if (engine->rpmCalculator.isStopped(PASS_ENGINE_PARAMETER_SIGNATURE)) {
#if (EFI_PROD_CODE && EFI_ENGINE_CONTROL && EFI_INTERNAL_FLASH) || defined(__DOXYGEN__)
writeToFlashIfPending();
#endif

View File

@ -63,7 +63,7 @@ RpmCalculator::RpmCalculator() {
}
bool RpmCalculator::isStopped(DECLARE_ENGINE_PARAMETER_SIGNATURE) {
return false;
return rpmValue == 0;
}
bool RpmCalculator::isCranking(DECLARE_ENGINE_PARAMETER_SIGNATURE) {