From 81444d33e27ca7a83d5f2313e841963a79b2a5b3 Mon Sep 17 00:00:00 2001 From: rusefillc Date: Sat, 12 Jun 2021 00:14:58 -0400 Subject: [PATCH] TCU cherry --- firmware/integration/rusefi_config.txt | 41 ++++++++++++++++++++++++-- 1 file changed, 39 insertions(+), 2 deletions(-) diff --git a/firmware/integration/rusefi_config.txt b/firmware/integration/rusefi_config.txt index 534c0450c6..08c79dbf08 100644 --- a/firmware/integration/rusefi_config.txt +++ b/firmware/integration/rusefi_config.txt @@ -1057,7 +1057,42 @@ custom maf_sensor_type_e 4 bits, S32, @OFFSET@, [0:1], @@maf_sensor_type_e_enum@ output_pin_e[LUA_PWM_COUNT iterate] luaOutputPins - int[57] unusedAtOldBoardConfigurationEnd;;"units", 1, 0, -20, 100, 0 + #define tcu_role_e_enum "Park", "Neutral" , "Park/Neutral", "Reverse", "Drive", "Manual", "Low", "Upshift", "Downshift", "3", "2", "1" + custom tcu_role_e 1 bits, U08, @OFFSET@, [0:3], @@tcu_role_e_enum@@ + tcu_role_e tcuState0Role; + tcu_role_e tcuState1Role; + tcu_role_e tcuState2Role; + tcu_role_e tcuState3Role; + tcu_role_e tcuState4Role; + tcu_role_e tcuState5Role; + tcu_role_e tcuState6Role; + tcu_role_e tcuState7Role; + + brain_pin_e tcuInputPin1D; + brain_pin_e tcuInputPin2D; + brain_pin_e tcuInputPin3D; + brain_pin_e tcuInputPin4D; + brain_pin_e tcuInputPin5D; + brain_pin_e tcuInputPin6D; + + adc_channel_e tcuInputPin1A; + adc_channel_e tcuInputPin2A; + adc_channel_e tcuInputPin3A; + adc_channel_e tcuInputPin4A; + adc_channel_e tcuInputPin5A; + adc_channel_e tcuInputPin6A; + + pin_input_mode_e tcuInputPin1Mode; + pin_input_mode_e tcuInputPin2Mode; + pin_input_mode_e tcuInputPin3Mode; + pin_input_mode_e tcuInputPin4Mode; + pin_input_mode_e tcuInputPin5Mode; + pin_input_mode_e tcuInputPin6Mode; + + float tcuAnalogInputTolerance;voltage tolerance of analog inputs;"v", 1, 0, 0, 5, 2 + + int[49] unusedAtOldBoardConfigurationEnd;;"units", 1, 0, -20, 100, 0 + uint16_t vehicleWeight;;"kg", 1, 0, 0, 10000, 0 brain_pin_e lps25BaroSensorScl brain_pin_e lps25BaroSensorSda @@ -1437,7 +1472,9 @@ float[CLT_CURVE_SIZE] iacCoasting; CLT-based idle position for coasting (used int8_t[CLT_LIMITER_CURVE_SIZE] cltRevLimitRpmBins;CLT-based target RPM for hard limit depending on CLT like on Lexus LFA;"C", 1, 0, -70, 120, 0 uint16_t[CLT_LIMITER_CURVE_SIZE] cltRevLimitRpm;See idleRpmPid;"", 1, 0, 0, 8000, 0 -uint8_t[524] unused3328;;"units", 1, 0, -20, 100, 0 +tcuinput_table_t tcuInputTable; + +uint8_t[476] unused3328;;"units", 1, 0, -20, 100, 0 float tChargeAirCoefMin;;"Min tCharge Coeff.", 1, 0, 0.0, 1.0, 4 float tChargeAirCoefMax;;"Max tCharge Coeff.", 1, 0, 0.0, 1.0, 4