rusEFI
The most advanced open source ECU
Loading...
Searching...
No Matches
Functions
m111.h File Reference

Functions

void setMercedesM111EngineConfiguration ()
 

Function Documentation

◆ setMercedesM111EngineConfiguration()

void setMercedesM111EngineConfiguration ( )

Definition at line 21 of file m111.cpp.

21 {
23 engineConfiguration->firingOrder = FO_1_3_4_2;
30 engineConfiguration->canNbcType = CAN_BUS_W202_C180;
31
32#if HW_HELLEN
34#endif
35
36 engineConfiguration->ignitionMode = IM_INDIVIDUAL_COILS;
38 engineConfiguration->injectionMode = IM_SEQUENTIAL;
39
40 strcpy(engineConfiguration->engineMake, ENGINE_MAKE_MERCEDES);
41 strcpy(engineConfiguration->engineCode, "M111");
42
43 engineConfiguration->vvtMode[0] = VVT_SINGLE_TOOTH;
45 engineConfiguration->globalTriggerAngleOffset = 109; // please use a timing light?
46
47 // todo: i wonder if we have less custom curve for same sensor?
48 setAtSensor(&engineConfiguration->iat, /*temp low*/0, 7400, /*temp mid*/22, 2180, /*temp high*/ 100, 180);
49 // todo: i wonder if these custom IAT and CLT curves are effectively same?
50 setAtSensor(&engineConfiguration->clt, /*temp low*/0, 5750, /*temp mid*/30, 1750, /*temp high*/ 50, 750);
51
52 setCustomMap(/*lowValue*/ 20, 0.3, 250, 4.65);
53
59
60 strcpy(engineConfiguration->gpPwmNote[0], "SC Bypass");
61#if HW_MICRO_RUSEFI && EFI_PROD_CODE
63 scBypass->pin = MRE_GPOUT_3;
64#endif // HW_MICRO_RUSEFI
65
66 strcpy(engineConfiguration->gpPwmNote[1], "SC Clutch");
67#if HW_MICRO_RUSEFI && EFI_PROD_CODE
69 scClutch->pin = MRE_LS_2;
70 engineConfiguration->vvtPins[0] = MRE_LS_1;
71
72 engineConfiguration->fuelPumpPin = MRE_GPOUT_1; // more or less MRE default
73 engineConfiguration->fanPin = MRE_GPOUT_2; // more or less MRE default
74 setPPSInputs(MRE_IN_PPS, MRE_IN_PPS2);
75 setTPS1Inputs(MRE_IN_TPS, MRE_IN_TPS2);
76
77 engineConfiguration->lowPressureFuel.hwChannel = MRE_IN_ANALOG_VOLT_4;
78 // assumes R30 is populated
79 engineConfiguration->boostControlPin = MRE_AV9_REUSE;
80#endif // HW_MICRO_RUSEFI
81 // note how these numbers are very flipped hyundai154 defaults?
82 setTPS1Calibration(891, 69, 98, 926);
83 // honda cable position sensor
84 setPPSCalibration(0.38, 4.77, 4.64, 2.47);
85
86#if HW_PROTEUS && EFI_PROD_CODE
87 engineConfiguration->triggerInputPins[0] = PROTEUS_VR_1;
88 engineConfiguration->camInputs[0] = PROTEUS_DIGITAL_2;
89
91#endif // HW_PROTEUS
92}
@ Unassigned
void setTPS1Calibration(uint16_t tpsMin, uint16_t tpsMax)
void setCustomMap(float lowValue, float mapLowValueVoltage, float highValue, float mapHighValueVoltage)
void setPPSInputs(adc_channel_e pps1, adc_channel_e pps2)
void setTPS1Inputs(adc_channel_e tps1, adc_channel_e tps2)
void setPPSCalibration(float primaryUp, float primaryDown, float secondaryUp, float secondaryDown)
static constexpr persistent_config_s * config
static constexpr engine_configuration_s * engineConfiguration
void setProteusEtbIO()
brain_input_pin_e triggerInputPins[TRIGGER_INPUT_PIN_COUNT]
void setAtSensor(ThermistorConf *thermistorConf, float tempLow, float rLow, float tempMid, float rMid, float tempHigh, float rHigh)

Referenced by applyEngineType(), hellen128_boardDefaultConfiguration(), and setHellenMercedes128_4_cyl().

Here is the call graph for this function:
Here is the caller graph for this function:

Go to the source code of this file.