From 0e231dd03512fe3c52cb4413acf75341bc4f2620 Mon Sep 17 00:00:00 2001 From: rusefi Date: Mon, 23 Dec 2019 21:55:08 -0500 Subject: [PATCH] Revert "couple of dead lines" This reverts commit dc20ee1d --- firmware/controllers/algo/engine.h | 1 + firmware/controllers/engine_cycle/rpm_calculator.cpp | 3 +++ 2 files changed, 4 insertions(+) diff --git a/firmware/controllers/algo/engine.h b/firmware/controllers/algo/engine.h index 08264430f2..dc91cbf19b 100644 --- a/firmware/controllers/algo/engine.h +++ b/firmware/controllers/algo/engine.h @@ -68,6 +68,7 @@ public: AuxActor auxValves[AUX_DIGITAL_VALVE_COUNT][2]; + bool needTdcCallback = true; /** * if 2nd TPS is not configured we do not run 2nd ETB */ diff --git a/firmware/controllers/engine_cycle/rpm_calculator.cpp b/firmware/controllers/engine_cycle/rpm_calculator.cpp index 9259f918ad..32caf18c03 100644 --- a/firmware/controllers/engine_cycle/rpm_calculator.cpp +++ b/firmware/controllers/engine_cycle/rpm_calculator.cpp @@ -296,6 +296,9 @@ static char rpmBuffer[_MAX_FILLER]; * digital sniffer. */ static void onTdcCallback(Engine *engine) { + if (!engine->needTdcCallback) { + return; + } EXPAND_Engine; itoa10(rpmBuffer, GET_RPM()); #if EFI_ENGINE_SNIFFER