From 3fa2f440143564e82b8f5e476be55539d6a4eb4b Mon Sep 17 00:00:00 2001 From: Matthew Kennedy Date: Thu, 2 Mar 2023 22:10:11 -0800 Subject: [PATCH] remove twoWireBatchIgnition --- firmware/config/engines/toyota_jzs147.cpp | 1 - firmware/controllers/engine_cycle/spark_logic.cpp | 7 ++----- firmware/controllers/settings.cpp | 3 --- firmware/integration/rusefi_config.txt | 2 +- firmware/tunerstudio/rusefi.input | 1 - 5 files changed, 3 insertions(+), 11 deletions(-) diff --git a/firmware/config/engines/toyota_jzs147.cpp b/firmware/config/engines/toyota_jzs147.cpp index 02b66cd345..727d47c926 100644 --- a/firmware/config/engines/toyota_jzs147.cpp +++ b/firmware/config/engines/toyota_jzs147.cpp @@ -86,7 +86,6 @@ void setToyota_2jz_vics() { engineConfiguration->ignitionMode = IM_WASTED_SPARK; // just for now engineConfiguration->injectionMode = IM_BATCH; // just for now - engineConfiguration->twoWireBatchIgnition = true; engineConfiguration->twoWireBatchInjection = true; strcpy(engineConfiguration->engineMake, ENGINE_MAKE_TOYOTA); diff --git a/firmware/controllers/engine_cycle/spark_logic.cpp b/firmware/controllers/engine_cycle/spark_logic.cpp index 84a5248f83..66cc864600 100644 --- a/firmware/controllers/engine_cycle/spark_logic.cpp +++ b/firmware/controllers/engine_cycle/spark_logic.cpp @@ -116,11 +116,8 @@ static void prepareCylinderIgnitionSchedule(angle_t dwellAngleDuration, floatms_ IgnitionOutputPin *secondOutput; - // We need two outputs if: - // - we are running wasted spark, and have "two wire" mode enabled - // - We are running sequential mode, but we're cranking, so we should run in two wire wasted mode (not one wire wasted) - bool isTwoWireWasted = engineConfiguration->twoWireBatchIgnition || (engineConfiguration->ignitionMode == IM_INDIVIDUAL_COILS); - if (ignitionMode == IM_WASTED_SPARK && isTwoWireWasted) { + // If wasted spark, find the paired coil in addition to "main" output for this cylinder + if (ignitionMode == IM_WASTED_SPARK) { int secondIndex = index + engineConfiguration->specs.cylindersCount / 2; int secondCoilIndex = ID2INDEX(getCylinderId(secondIndex)); secondOutput = &enginePins.coils[secondCoilIndex]; diff --git a/firmware/controllers/settings.cpp b/firmware/controllers/settings.cpp index d6161d0629..8838daa9b7 100644 --- a/firmware/controllers/settings.cpp +++ b/firmware/controllers/settings.cpp @@ -452,9 +452,6 @@ static void enableOrDisable(const char *param, bool isEnabled) { } else if (strEqualCaseInsensitive(param, "boardUseTachPullUp")) { engineConfiguration->boardUseTachPullUp = isEnabled; incrementGlobalConfigurationVersion(); - } else if (strEqualCaseInsensitive(param, "two_wire_wasted_spark")) { - engineConfiguration->twoWireBatchIgnition = isEnabled; - incrementGlobalConfigurationVersion(); } else if (strEqualCaseInsensitive(param, "verbose_idle")) { engineConfiguration->isVerboseIAC = isEnabled; } else if (strEqualCaseInsensitive(param, "auxdebug1")) { diff --git a/firmware/integration/rusefi_config.txt b/firmware/integration/rusefi_config.txt index c26da0d8a6..5eb9864694 100644 --- a/firmware/integration/rusefi_config.txt +++ b/firmware/integration/rusefi_config.txt @@ -994,7 +994,7 @@ bit skippedWheelOnCam,"On camshaft","On crankshaft";Where is your primary skippe bit isManualSpinningMode;Usually if we have no trigger events that means engine is stopped\nUnless we are troubleshooting and spinning the engine by hand - this case a longer\ndelay is needed bit twoWireBatchInjection;This is needed if your coils are individually wired and you wish to use batch injection.\nenable two_wire_batch_injection bit neverInstantRpm - bit twoWireBatchIgnition;This is needed if your coils are individually wired (COP) and you wish to use batch ignition (Wasted Spark). + bit unused1200b14 bit useFixedBaroCorrFromMap bit useSeparateAdvanceForCranking,"Table","Fixed (auto taper)";In Constant mode, timing is automatically tapered to running as RPM increases.\nIn Table mode, the "Cranking ignition advance" table is used directly. bit useAdvanceCorrectionsForCranking;This enables the various ignition corrections during cranking (IAT, CLT, FSIO and PID idle).\nYou probably don't need this. diff --git a/firmware/tunerstudio/rusefi.input b/firmware/tunerstudio/rusefi.input index b769fbf5fd..d175c9319a 100644 --- a/firmware/tunerstudio/rusefi.input +++ b/firmware/tunerstudio/rusefi.input @@ -2106,7 +2106,6 @@ cmd_set_engine_type_default = "@@TS_IO_TEST_COMMAND_char@@@@ts_command_e_TS_ dialog = ignitionBasic, "" field = "Enabled", isIgnitionEnabled field = "Mode", ignitionMode, {isIgnitionEnabled == 1} - field = "Individually wired Wasted Spark", twoWireBatchIgnition, {isIgnitionEnabled == 1 && ignitionMode == @@ignition_mode_e_IM_WASTED_SPARK@@ } field = "Override ignition table load axis", ignOverrideMode, {isIgnitionEnabled} field = "#Use fixed timing while validating with a timing gun" field = "Timing Mode", timingMode, {isIgnitionEnabled == 1}