diff --git a/firmware/config/engines/mazda_miata_1_6.cpp b/firmware/config/engines/mazda_miata_1_6.cpp index 45b0ef5534..a2b9a25612 100644 --- a/firmware/config/engines/mazda_miata_1_6.cpp +++ b/firmware/config/engines/mazda_miata_1_6.cpp @@ -218,15 +218,6 @@ void miataNAcommonEngineSettings() { engineConfiguration->stft.cellCfgs[3] = { 5, -5, 30 }; } -static void miataNAcommon() { - engineConfiguration->idle.solenoidPin = Gpio::B9; // this W61 <> W61 jumper, pin 3W - - engineConfiguration->ignitionPins[0] = Gpio::E14; // Frankenso high side - pin 1G - engineConfiguration->ignitionPins[1] = Gpio::Unassigned; - engineConfiguration->ignitionPins[2] = Gpio::C7; // Frankenso high side - pin 1H - engineConfiguration->ignitionPins[3] = Gpio::Unassigned; -} - /** * MIATA_NA6_MAP */ @@ -271,90 +262,12 @@ void setMiataNA6_MAP_Frankenso() { // W58 PE4 A/C fan relay out #endif /* EFI_UNIT_TEST */ - miataNAcommon(); -} - - -/** - * set engine_type 66 - */ -void setMiataNA6_MAP_MRE() { - miataNAcommonEngineSettings(); - - engineConfiguration->triggerInputPins[0] = Gpio::A5; - engineConfiguration->triggerInputPins[1] = Gpio::C6; - engineConfiguration->camInputs[0] = Gpio::Unassigned; - - engineConfiguration->fuelPumpPin = Gpio::Unassigned; - - engineConfiguration->useIacTableForCoasting = true; - engineConfiguration->idlePidDeactivationTpsThreshold = 90; - - engineConfiguration->idleRpmPid.pFactor = 0.01; - engineConfiguration->idleRpmPid.iFactor = 0.02; - engineConfiguration->idle_derivativeFilterLoss = 0.1; - engineConfiguration->idle_antiwindupFreq = 0.1; - engineConfiguration->idleRpmPid.dFactor = 0.002; - engineConfiguration->acIdleExtraOffset = 14; - engineConfiguration->idleRpmPid.minValue = -7; - engineConfiguration->idleRpmPid.maxValue = 35; - engineConfiguration->idleRpmPid.periodMs = 40; - engineConfiguration->idlerpmpid_iTermMin = -6; - engineConfiguration->idlerpmpid_iTermMax = 30; - engineConfiguration->pidExtraForLowRpm = 25; - engineConfiguration->idlePidRpmDeadZone = 25; - engineConfiguration->idlePidRpmUpperLimit = 1000; - - engineConfiguration->useIdleTimingPidControl = true; - engineConfiguration->idleTimingPid.pFactor = 0.05; - engineConfiguration->idleTimingPid.iFactor = 0.0; - engineConfiguration->idleTimingPid.dFactor = 0.0; - engineConfiguration->idleTimingPid.minValue = -13; - engineConfiguration->idleTimingPid.maxValue = 13; - - // EFI_ADC_3: "22 - AN temp 4" - engineConfiguration->acSwitch = Gpio::A3; - -#if HW_MICRO_RUSEFI - // todo: ask Stefan to clarify this - engineConfiguration->tps1_1AdcChannel = MRE_IN_ANALOG_VOLT_2; // "26 - AN volt 2" - engineConfiguration->tpsMin = 0; - engineConfiguration->tpsMax = 982; - - engineConfiguration->map.sensor.hwChannel = MRE_IN_ANALOG_VOLT_5; // "20 - AN volt 5" - - engineConfiguration->mafAdcChannel = MRE_IN_ANALOG_VOLT_9; // "40 - AN volt 9" -#endif // HW_MICRO_RUSEFI - - -#if (BOARD_TLE8888_COUNT > 0) - // Gpio::G1: "Clutch Switch" - engineConfiguration->clutchDownPin = Gpio::G1; - - engineConfiguration->fanPin = Gpio::Unassigned; - - - // Gpio::TLE8888_PIN_23: "33 - GP Out 3" - engineConfiguration->malfunctionIndicatorPin = Gpio::TLE8888_PIN_23; - -#endif /* BOARD_TLE8888_COUNT */ -} - -void setMiata94_MAP_MRE() { - setMiataNA6_MAP_MRE(); - -#if (BOARD_TLE8888_COUNT > 0) - // "35 - GP Out 1" - engineConfiguration->fuelPumpPin = Gpio::TLE8888_PIN_21; -#endif /* BOARD_TLE8888_COUNT */ - - engineConfiguration->injectionMode = IM_SEQUENTIAL; - engineConfiguration->displacement = 1.8; - strcpy(engineConfiguration->engineMake, ENGINE_MAKE_MAZDA); - strcpy(engineConfiguration->engineCode, "94"); - - engineConfiguration->map.sensor.type = MT_MPX4250; + engineConfiguration->idle.solenoidPin = Gpio::B9; // this W61 <> W61 jumper, pin 3W + engineConfiguration->ignitionPins[0] = Gpio::E14; // Frankenso high side - pin 1G + engineConfiguration->ignitionPins[1] = Gpio::Unassigned; + engineConfiguration->ignitionPins[2] = Gpio::C7; // Frankenso high side - pin 1H + engineConfiguration->ignitionPins[3] = Gpio::Unassigned; } void setHellenNA94() { diff --git a/firmware/config/engines/mazda_miata_1_6.h b/firmware/config/engines/mazda_miata_1_6.h index 043bf822f1..81a6a77d91 100644 --- a/firmware/config/engines/mazda_miata_1_6.h +++ b/firmware/config/engines/mazda_miata_1_6.h @@ -16,10 +16,6 @@ void setMiataNA6_MAP_Frankenso(); void setMiataNA6_MAP_MRE(); -/** - * set engine_type 20 - */ -void setMiata94_MAP_MRE(); void miataNAcommonEngineSettings(); /** diff --git a/firmware/controllers/algo/engine_configuration.cpp b/firmware/controllers/algo/engine_configuration.cpp index abdd5d538b..6846f4fd72 100644 --- a/firmware/controllers/algo/engine_configuration.cpp +++ b/firmware/controllers/algo/engine_configuration.cpp @@ -683,10 +683,8 @@ void resetConfigurationExt(configuration_callback_t boardCallback, engine_type_e case engine_type_e::BMW_M73_MRE_SLAVE: setEngineBMW_M73_microRusEfi(); break; - case engine_type_e::MRE_MIATA_94_MAP: - setMiata94_MAP_MRE(); - break; - case engine_type_e::MRE_MIATA_NA6_MAP: + case engine_type_e::ET_UNUSED_20: + case engine_type_e::ET_UNUSED_66: setMiataNA6_MAP_MRE(); break; case engine_type_e::MRE_BODY_CONTROL: diff --git a/firmware/controllers/algo/engine_types.h b/firmware/controllers/algo/engine_types.h index 1105477a80..7789bee68d 100644 --- a/firmware/controllers/algo/engine_types.h +++ b/firmware/controllers/algo/engine_types.h @@ -44,12 +44,12 @@ enum class engine_type_e : uint32_t { PROTEUS_E65_6H_MAN_IN_THE_MIDDLE = 9, HELLEN_NA8_96 = 10, - MRE_MIATA_NA6_MAP = 66, + ET_UNUSED_66 = 66, TEST_ROTARY = 19, // Frankenso board FRANKENSO_MIATA_NA6_MAP = 41, - MRE_MIATA_94_MAP = 20, + ET_UNUSED_20 = 20, MIATA_1996 = 21, FORD_ESCORT_GT = 14, diff --git a/firmware/tunerstudio/rusefi.input b/firmware/tunerstudio/rusefi.input index 69dccbe4a4..97b057e110 100644 --- a/firmware/tunerstudio/rusefi.input +++ b/firmware/tunerstudio/rusefi.input @@ -2069,10 +2069,6 @@ cmd_openblt = "@@TS_IO_TEST_COMMAND_char@@\x00\xbc\x00\x00" cmd_set_engine_type_microRusEFI_VW_B6 = "@@TS_IO_TEST_COMMAND_char@@@@ts_command_e_TS_SET_ENGINE_TYPE_16_hex@@@@engine_type_e_MRE_VW_B6_16_hex@@" cmd_set_engine_type_microRusEFI_MRE_BODY_CONTROL = "@@TS_IO_TEST_COMMAND_char@@@@ts_command_e_TS_SET_ENGINE_TYPE_16_hex@@@@engine_type_e_MRE_BODY_CONTROL_16_hex@@" -cmd_set_engine_type_microRusEFI_Miata_NA6_MAP = "@@TS_IO_TEST_COMMAND_char@@@@ts_command_e_TS_SET_ENGINE_TYPE_16_hex@@@@engine_type_e_MRE_MIATA_NA6_MAP_16_hex@@" - -cmd_set_engine_type_microRusEFI_Miata_94_MAP = "@@TS_IO_TEST_COMMAND_char@@@@ts_command_e_TS_SET_ENGINE_TYPE_16_hex@@@@engine_type_e_MRE_MIATA_94_MAP_16_hex@@" - cmd_set_engine_type_MRE_SUBARU_EJ18 = "@@TS_IO_TEST_COMMAND_char@@@@ts_command_e_TS_SET_ENGINE_TYPE_16_hex@@@@engine_type_e_MRE_SUBARU_EJ18_16_hex@@" cmd_set_engine_type_MRE_M111 = "@@TS_IO_TEST_COMMAND_char@@@@ts_command_e_TS_SET_ENGINE_TYPE_16_hex@@@@engine_type_e_MRE_M111_16_hex@@" @@ -4250,8 +4246,6 @@ dialog = tcuControls, "Transmission Settings" commandButton = "Frankenso Miata NA6 Stage 1", cmd_set_engine_type_Frankenso_Miata_NA6_MAP@@if_show_Frankenso_presets commandButton = "Frankenso Miata NB2 MAP", cmd_set_engine_type_Frankenso_Miata_NB2@@if_show_Frankenso_presets - commandButton = "microRusEFI Miata NA6 MAP", cmd_set_engine_type_microRusEFI_Miata_NA6_MAP@@if_show_microRusEFI_presets - commandButton = "microRusEFI Miata 94/95 MAP", cmd_set_engine_type_microRusEFI_Miata_94_MAP@@if_show_microRusEFI_presets commandButton = "microRusEFI GDI VAG B6 test", cmd_set_engine_type_microRusEFI_VW_B6@@if_show_microRusEFI_presets commandButton = "microRusEFI BCM", cmd_set_engine_type_microRusEFI_MRE_BODY_CONTROL@@if_show_microRusEFI_presets commandButton = "microRusEFI Subaru EJ18", cmd_set_engine_type_MRE_SUBARU_EJ18@@if_show_microRusEFI_presets