Add fallback map table (#2248)

* table

* sd math

* config

* debug channel name

* ptr vs not ptr

* actually use return value

* memory

* less magic
This commit is contained in:
Matthew Kennedy 2021-01-31 14:19:06 -08:00 committed by GitHub
parent 10c31c2955
commit 0e70d08a22
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 67 additions and 27 deletions

View File

@ -17,7 +17,7 @@ AirmassResult SpeedDensityAirmass::getAirmass(int rpm) {
return {};
}
auto map = Sensor::get(SensorType::Map).value_or(CONFIG(failedMapFallback));
auto map = getMap(rpm);
engine->engineState.sd.manifoldAirPressureAccelerationAdjustment = engine->engineLoadAccelEnrichment.getEngineLoadEnrichment(PASS_ENGINE_PARAMETER_SIGNATURE);
@ -41,3 +41,21 @@ AirmassResult SpeedDensityAirmass::getAirmass(int rpm) {
map, // AFR/VE table Y axis
};
}
float SpeedDensityAirmass::getMap(int rpm) const {
float fallbackMap;
if (CONFIG(enableMapEstimationTableFallback)) {
// if the map estimation table is enabled, estimate map based on the TPS and RPM
fallbackMap = m_mapEstimationTable->getValue(rpm, TPS_2_BYTE_PACKING_MULT * Sensor::get(SensorType::Tps1).value_or(0));
} else {
fallbackMap = CONFIG(failedMapFallback);
}
#if EFI_TUNER_STUDIO
if (CONFIG(debugMode) == DBG_MAP) {
tsOutputChannels.debugFloatField4 = fallbackMap;
}
#endif // EFI_TUNER_STUDIO
return Sensor::get(SensorType::Map).value_or(fallbackMap);
}

View File

@ -4,6 +4,15 @@
class SpeedDensityAirmass : public SpeedDensityBase {
public:
explicit SpeedDensityAirmass(const ValueProvider3D& veTable) : SpeedDensityBase(veTable) {}
explicit SpeedDensityAirmass(const ValueProvider3D& veTable, const ValueProvider3D& mapEstimationTable)
: SpeedDensityBase(veTable)
, m_mapEstimationTable(&mapEstimationTable)
{}
AirmassResult getAirmass(int rpm) override;
float getMap(int rpm) const;
private:
const ValueProvider3D* const m_mapEstimationTable;
};

View File

@ -45,6 +45,7 @@ fuel_Map3D_t fuelPhaseMap("fl ph");
extern fuel_Map3D_t veMap;
extern lambda_Map3D_t lambdaMap;
extern baroCorr_Map3D_t baroCorrMap;
mapEstimate_Map3D_t mapEstimationTable("map est");
#if EFI_ENGINE_CONTROL
@ -160,7 +161,7 @@ floatms_t getRunningFuel(floatms_t baseFuel DECLARE_ENGINE_PARAMETER_SUFFIX) {
/* DISPLAY_ENDIF */
static SpeedDensityAirmass sdAirmass(veMap);
static SpeedDensityAirmass sdAirmass(veMap, mapEstimationTable);
static MafAirmass mafAirmass(veMap);
static AlphaNAirmass alphaNAirmass(veMap);
@ -350,6 +351,8 @@ void initFuelMap(DECLARE_ENGINE_PARAMETER_SIGNATURE) {
ENGINE(fuelComputer) = &fuelComputer;
ENGINE(injectorModel) = &injectorModel;
mapEstimationTable.init(config->mapEstimateTable, config->mapEstimateTpsBins, config->mapEstimateRpmBins);
#if (IGN_LOAD_COUNT == FUEL_LOAD_COUNT) && (IGN_RPM_COUNT == FUEL_RPM_COUNT)
fuelPhaseMap.init(config->injectionPhase, config->injPhaseLoadBins, config->injPhaseRpmBins);
#endif /* (IGN_LOAD_COUNT == FUEL_LOAD_COUNT) && (IGN_RPM_COUNT == FUEL_RPM_COUNT) */

View File

@ -92,6 +92,7 @@ typedef brain_pin_e egt_cs_array_t[EGT_CHANNEL_COUNT];
typedef uint8_t lambda_table_t[FUEL_LOAD_COUNT][FUEL_RPM_COUNT];
// todo: merge these two types together? but these tables have different TS parameters like ranges etc
typedef float fuel_table_t[FUEL_LOAD_COUNT][FUEL_RPM_COUNT];
typedef uint16_t map_estimate_table_t[FUEL_LOAD_COUNT][FUEL_RPM_COUNT];
typedef float ignition_table_t[IGN_LOAD_COUNT][IGN_RPM_COUNT];
typedef int16_t ignition_tps_table_t[IGN_LOAD_COUNT][IGN_RPM_COUNT];
typedef uint8_t pedal_to_tps_t[PEDAL_TO_TPS_SIZE][PEDAL_TO_TPS_SIZE];

View File

@ -711,7 +711,7 @@ void initEngineContoller(Logging *sharedLogger DECLARE_ENGINE_PARAMETER_SUFFIX)
* UNUSED_SIZE constants.
*/
#ifndef RAM_UNUSED_SIZE
#define RAM_UNUSED_SIZE 3300
#define RAM_UNUSED_SIZE 3200
#endif
#ifndef CCM_UNUSED_SIZE
#define CCM_UNUSED_SIZE 2800

View File

@ -185,6 +185,7 @@ struct_no_prefix engine_configuration_s
#define PACK_MULT_VOLTAGE 1000
#define PACK_MULT_MASS_FLOW 10
#define TPS_1_BYTE_PACKING_MULT 2
#define TPS_2_BYTE_PACKING_MULT 100
#define LOAD_1_BYTE_PACKING_MULT 2
#define PACK_MULT_AFR_CFG 10
#define PACK_MULT_LAMBDA_CFG 147
@ -210,7 +211,9 @@ struct_no_prefix engine_configuration_s
#define AFTERSTART_DECAY_CURVE_SIZE 8
#define AFTERSTART_ENRICH_CURVE_SIZE 8
custom fuel_table_t 4*@@FUEL_RPM_COUNT@@x@@FUEL_LOAD_COUNT@@ array, F32, @OFFSET@, [@@FUEL_RPM_COUNT@@x@@FUEL_LOAD_COUNT@@],"ms", 1, 0, 0.0, 500.0, 2
#define PACK_MULT_MAP_ESTIMATE 100
custom map_estimate_table_t 2*@@FUEL_RPM_COUNT@@x@@FUEL_LOAD_COUNT@@ array, U16, @OFFSET@, [@@FUEL_RPM_COUNT@@x@@FUEL_LOAD_COUNT@@],"kPa", {1/@@PACK_MULT_MAP_ESTIMATE@@}, 0, 0.0, 100.0, 2
custom ve_table_t 4*@@FUEL_RPM_COUNT@@x@@FUEL_LOAD_COUNT@@ array, F32, @OFFSET@, [@@FUEL_RPM_COUNT@@x@@FUEL_LOAD_COUNT@@],"%", 1, 0, 0, 999.0, 2
custom lambda_table_t @@FUEL_RPM_COUNT@@x@@FUEL_LOAD_COUNT@@ array, U08, @OFFSET@, [@@FUEL_RPM_COUNT@@x@@FUEL_LOAD_COUNT@@],"deg", {1/@@PACK_MULT_LAMBDA_CFG@@}, 0, 0.6, 1.5, 2
custom afr_table_t @@FUEL_RPM_COUNT@@x@@FUEL_LOAD_COUNT@@ array, U08, @OFFSET@, [@@FUEL_RPM_COUNT@@x@@FUEL_LOAD_COUNT@@],"deg", {1/@@PACK_MULT_AFR_CFG@@}, 0, 0, 25.0, 1
@ -517,7 +520,7 @@ bit antiLagEnabled;
bit useRunningMathForCranking,"Fuel Map","Fixed";
bit displayLogicLevelsInEngineSniffer;
bit useTLE8888_stepper;
bit issue_294_27;
bit enableMapEstimationTableFallback;+If enabled, the MAP estimate table will be used if the MAP sensor fails to estimate manifold pressure based on RPM and TPS.
bit issue_294_28;
bit issue_294_29;
bit issue_294_30;
@ -1545,7 +1548,11 @@ tcubinary_table_t tcuSolenoidTable;
float vssFilterReciprocal;+Good example: number of tooth on wheel, For Can 10 is a good number.;"Hz", 1, 0, 2.0, 20.0, 2
uint8_t[1088] unused15136;;"units", 1, 0, -20, 100, 0
map_estimate_table_t mapEstimateTable;
uint16_t[FUEL_LOAD_COUNT] mapEstimateTpsBins;;"% TPS", {1/@@TPS_2_BYTE_PACKING_MULT@@}, 0.0, 0, 100.0, 1
uint16_t[FUEL_RPM_COUNT] mapEstimateRpmBins;;"RPM", 1, 0.0, 0, 18000.0, 0
uint8_t[512] unused15136;;"units", 1, 0, -20, 100, 0
ignition_table_t ignitionTable;
float[IGN_LOAD_COUNT] ignitionLoadBins;;"Load", 1, 0.0, 0, 500.0, 2
@ -1556,14 +1563,9 @@ float[FUEL_LOAD_COUNT] veLoadBins;;"kPa", 1, 0.0, 0, 400.0, 2
float[FUEL_RPM_COUNT] veRpmBins;;"RPM", 1, 0.0, 0, 18000.0, 2
lambda_table_t lambdaTable;
float[FUEL_LOAD_COUNT] lambdaLoadBins;;"", 1, 0.0, 0, 500.0, 2
float[FUEL_RPM_COUNT] lambdaRpmBins;;"RPM", 1, 0.0, 0, 18000.0, 2
! ve_table_t ve2Table;
! float[FUEL_LOAD_COUNT] ve2LoadBins;;"kPa", 1, 0.0, 0, 500.0, 2
! float[FUEL_RPM_COUNT] ve2RpmBins;;"RPM", 1, 0.0, 0, 18000.0, 2
tps_tps_table_t tpsTpsAccelTable;
float[TPS_TPS_ACCEL_TABLE] tpsTpsAccelFromRpmBins;;"from", 1, 0, 0.0, 30000.0, 2
float[TPS_TPS_ACCEL_TABLE] tpsTpsAccelToRpmBins;RPM is float and not integer in order to use unified methods for interpolation;"to", 1, 0, 0.0, 25500.0, 2

View File

@ -430,22 +430,22 @@ enable2ndByteCanID = false
; wall of debug mode :)
; https://rusefi.com/wiki/index.php?title=Manual:Debug_fields
; 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
; Alternator TPS Acceleration GPPWM Idle Engine Load Acc Trigger Counters VVT Cranking Ignition Timing Fu Corr VSS SD Card Knock ETB PID Executor InstantRpm FSIO_1_7 CJ125 CAN TLE8888 Analog inputs 2 Boost Start Launcher ETB Autotune FSIO_8_14 FSIO_SPECIAL Injector flow compensation DYNO_VIEW LOGIC_ANALYZER Wideband TCU DBG_48
; 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48
; Alternator TPS Acceleration GPPWM Idle Engine Load Acc Trigger Counters VVT Cranking Ignition Timing Fu Corr VSS SD Card Knock ETB PID Executor InstantRpm FSIO_1_7 CJ125 CAN MAP TLE8888 Analog inputs 2 Boost Start Launcher ETB Autotune FSIO_8_14 FSIO_SPECIAL Injector flow compensation DYNO_VIEW LOGIC_ANALYZER Wideband TCU DBG_48
; DBG_ALTERNATOR_PID DBG_TPS_ACCEL DBG_GPPWM DBG_IDLE_CONTROL
debugFieldF1List = bits, U08, [0:7], "Controller Output", "From TPS", "GPPWM 1", "Controller Output", "Idle output", "Channel 1 Rise Counter", "", "", "VVT Event Position","", "Ign IAT Corr", "", "", "Total SD", "", "", "", "ETB Controller Output", "", "", "df1", "df1", "InstantRpm", "fsio 1", "24:df1", "CJ125: output", "", "", "", "", "", "", "TPS1 Pri/Sec Diff", "", "", "", "Boost Open Loop Duty", "S unused" "", "Osc Amplitude", "", "fsio 8", "idle offset", "Pressure across injector(kpa)", "VSS", "", "WB: Pump DAC duty", "", ""
debugFieldF2List = bits, U08, [0:7], "I-Term", "To TPS", "GPPWM 2", "I-Term", "Idle df2", "Channel 2 Rise Counter", "", "", "VVT Ratio", "", "Ign CLT Corr", "", "", "Write Cnt","", "", "", "ETB I-Term", "", "", "df2", "df2", "dRpm", "fsio 2", "24:df2", "CJ125: i-term", "", "", "", "", "", "", "TPS2 Pri/Sec Diff", "", "", "", "Boost Closed Loop Duty","S unused" "", "Duty Amplitude", "", "fsio 9", "idle min", "Pressure ratio vs. nominal", "Speed", "", "WB: ESR", "", ""
debugFieldF3List = bits, U08, [0:7], "Previous Error", "Current TPS<>TPS", "GPPWM 3", "prev error", "Idle df3", "ICU sum", "", "", "", "", "Ign FSIO Adj", "", "", "Sync Cnt", "", "", "", "ETB err", "", "", "df3", "df3", "22df3", "fsio 3", "24:df3", "CJ125: err", "", "", "", "", "", "", "TPS1/2 Diff", "", "", "", "", "S unused" "", "Tu", "", "fsio 10", "", "Flow ratio vs. configured", "DeltaSpeed", "", "WB: Heater duty", "", ""
debugFieldF4List = bits, U08, [0:7], "I Gain", "Extra Fuel", "GPPWM 4", "I Gain", "Idle df4", "VVT rise", "", "", "", "", "Ign PID Adj", "", "", "File Cnt", "", "", "", "ETB I setting", "", "", "df4", "df4", "22df4", "fsio 4", "24:df4", "CJ125: UA", "", "", "", "", "", "", "Acc Pedal Pri/Sec Diff","", "", "", "", "S unused" "", "Ku", "", "fsio 11", "", "", "accel", "", "WB: Lambda", "", ""
debugFieldF5List = bits, U08, [0:7], "D Gain", "df5", "df5", "D Gain", "Idle df5", "VVT fall", "df5", "", "", "", "", "", "", "", "", "", "", "ETB D setting", "df5", "df5", "df5", "df5", "22df5", "fsio 5", "24:df5", "CJ125: UR", "", "", "", "", "", "", "", "", "", "", "", "S unused" "", "Kp", "", "fsio 12", "", "", "", "", "", "", ""
debugFieldF6List = bits, U08, [0:7], "D Term", "", "", "D Term", "Idle df6", "Current Gap", "", "", "", "", "", "", "", "", "", "", "", "ETB df6", "", "", "df6", "df6", "22df6", "fsio 6", "24:df6", "cj: f7", "", "", "", "", "", "", "", "", "", "", "", "S unused" "", "Ki", "", "fsio 13", "", "", "", "", "", "", ""
debugFieldF7List = bits, U08, [0:7], "Max-Value", "", "", "Max-Value", "Idle df7", "", "", "", "", "", "", "", "", "", "", "", "", "ETB df7", "", "", "df7", "df7", "22df7", "fsio 7", "24:df7", "cj: f7", "", "", "", "", "", "", "", "", "", "", "", "S unused" "", "Kd", "", "fsio 14", "", "", "", "", "", "", ""
debugFieldF1List = bits, U08, [0:7], "Controller Output", "From TPS", "GPPWM 1", "Controller Output", "Idle output", "Channel 1 Rise Counter", "", "", "VVT Event Position","", "Ign IAT Corr", "", "", "Total SD", "", "", "", "ETB Controller Output", "", "", "df1", "df1", "InstantRpm", "fsio 1", "24:df1", "CJ125: output", "", "", "", "", "", "", "TPS1 Pri/Sec Diff", "", "", "", "Boost Open Loop Duty", "S unused" "", "Osc Amplitude", "", "fsio 8", "idle offset", "Pressure across injector(kpa)", "VSS", "", "WB: Pump DAC duty", "", ""
debugFieldF2List = bits, U08, [0:7], "I-Term", "To TPS", "GPPWM 2", "I-Term", "Idle df2", "Channel 2 Rise Counter", "", "", "VVT Ratio", "", "Ign CLT Corr", "", "", "Write Cnt","", "", "", "ETB I-Term", "", "", "df2", "df2", "dRpm", "fsio 2", "24:df2", "CJ125: i-term", "", "", "", "", "", "", "TPS2 Pri/Sec Diff", "", "", "", "Boost Closed Loop Duty","S unused" "", "Duty Amplitude", "", "fsio 9", "idle min", "Pressure ratio vs. nominal", "Speed", "", "WB: ESR", "", ""
debugFieldF3List = bits, U08, [0:7], "Previous Error", "Current TPS<>TPS", "GPPWM 3", "prev error", "Idle df3", "ICU sum", "", "", "", "", "Ign FSIO Adj", "", "", "Sync Cnt", "", "", "", "ETB err", "", "", "df3", "df3", "22df3", "fsio 3", "24:df3", "CJ125: err", "", "", "", "", "", "", "TPS1/2 Diff", "", "", "", "", "S unused" "", "Tu", "", "fsio 10", "", "Flow ratio vs. configured", "DeltaSpeed", "", "WB: Heater duty", "", ""
debugFieldF4List = bits, U08, [0:7], "I Gain", "Extra Fuel", "GPPWM 4", "I Gain", "Idle df4", "VVT rise", "", "", "", "", "Ign PID Adj", "", "", "File Cnt", "", "", "", "ETB I setting", "", "", "df4", "df4", "22df4", "fsio 4", "24:df4", "CJ125: UA", "", "MAP Estimate", "", "", "", "", "Acc Pedal Pri/Sec Diff","", "", "", "", "S unused" "", "Ku", "", "fsio 11", "", "", "accel", "", "WB: Lambda", "", ""
debugFieldF5List = bits, U08, [0:7], "D Gain", "df5", "df5", "D Gain", "Idle df5", "VVT fall", "df5", "", "", "", "", "", "", "", "", "", "", "ETB D setting", "df5", "df5", "df5", "df5", "22df5", "fsio 5", "24:df5", "CJ125: UR", "", "", "", "", "", "", "", "", "", "", "", "S unused" "", "Kp", "", "fsio 12", "", "", "", "", "", "", ""
debugFieldF6List = bits, U08, [0:7], "D Term", "", "", "D Term", "Idle df6", "Current Gap", "", "", "", "", "", "", "", "", "", "", "", "ETB df6", "", "", "df6", "df6", "22df6", "fsio 6", "24:df6", "cj: f7", "", "", "", "", "", "", "", "", "", "", "", "S unused" "", "Ki", "", "fsio 13", "", "", "", "", "", "", ""
debugFieldF7List = bits, U08, [0:7], "Max-Value", "", "", "Max-Value", "Idle df7", "", "", "", "", "", "", "", "", "", "", "", "", "ETB df7", "", "", "df7", "df7", "22df7", "fsio 7", "24:df7", "cj: f7", "", "", "", "", "", "", "", "", "", "", "", "S unused" "", "Kd", "", "fsio 14", "", "", "", "", "", "", ""
debugFieldI1List = bits, U08, [0:7], "P-Gain", "", "", "P-Gain", "Idle di1", "Channel 1 Fall Counter", "", "", "VVT Sync Counter", "Cycle Counter", "Multispark Count", "", "", "", "", "", "", "ETB P-Gain", "t counter", "", "di1", "di1", "22di1", "", "24:di1", "CJ125: state", "read count","", "", "", "", "SPI Counter", "", "", "", "", "", "Start Count", "", "", "", "", "", "", "deltatime", "", "", "Solenoid 1 State", ""
debugFieldI2List = bits, U08, [0:7], "Offset", "", "", "Offset", "Idle di2", "Channel 2 Fall Counter", "", "", "", "", "", "", "", "", "", "", "", "ETB di2", "invocationcounter", "", "di2", "di2", "22di2", "", "24:di2", "", "write count","", "", "", "", "Latest Transmit","", "", "", "", "", "Starter Enable", "", "", "", "", "", "", "", "", "", "Solenoid 2 State", ""
debugFieldI3List = bits, U08, [0:7], "Reset Cnt", "", "", "Reset Cnt", "Idle di3", "Cycle Index", "", "", "", "", "", "", "", "", "", "", "", "ETB di3", "s counter", "", "di3", "di3", "22di3", "", "24:di3", "", "write err", "", "", "", "", "Latest Received","", "", "", "", "", "Starter Disable","", "", "", "", "", "", "", "", "", "Solenoid 3 State", ""
debugFieldI4List = bits, U08, [0:7], "Period", "", "", "State", "Idle di4", "Cycle Cnt 1", "", "", "", "", "", "", "", "", "", "", "", "ETB di4", "executor", "", "di4", "di4", "22di4", "", "24:di4", "", "", "", "", "", "", "Init Count", "", "", "", "", "", "S unused" "", "", "", "", "", "", "", "", "", "Solenoid 4 State", ""
debugFieldI5List = bits, U08, [0:7], "", "", "", "", "Idle di5", "Cycle Cnt 2", "", "", "", "", "", "", "", "", "", "di5", "di5", "ETB di5", "max executor", "di5", "di5", "di5", "22di5", "di5", "di5", "di5", "di5", "di5", "di5", "di5", "di5", "di5", "", "di5", "di5", "di5", "di5", "S di5" "", "", "", "", "", "", "", "", "", "Solenoid 5 State", ""
debugFieldI1List = bits, U08, [0:7], "P-Gain", "", "", "P-Gain", "Idle di1", "Channel 1 Fall Counter", "", "", "VVT Sync Counter", "Cycle Counter", "Multispark Count", "", "", "", "", "", "", "ETB P-Gain", "t counter", "", "di1", "di1", "22di1", "", "24:di1", "CJ125: state", "read count","", "", "", "", "SPI Counter", "", "", "", "", "", "Start Count", "", "", "", "", "", "", "deltatime", "", "", "Solenoid 1 State", ""
debugFieldI2List = bits, U08, [0:7], "Offset", "", "", "Offset", "Idle di2", "Channel 2 Fall Counter", "", "", "", "", "", "", "", "", "", "", "", "ETB di2", "invocationcounter", "", "di2", "di2", "22di2", "", "24:di2", "", "write count","", "", "", "", "Latest Transmit","", "", "", "", "", "Starter Enable", "", "", "", "", "", "", "", "", "", "Solenoid 2 State", ""
debugFieldI3List = bits, U08, [0:7], "Reset Cnt", "", "", "Reset Cnt", "Idle di3", "Cycle Index", "", "", "", "", "", "", "", "", "", "", "", "ETB di3", "s counter", "", "di3", "di3", "22di3", "", "24:di3", "", "write err", "", "", "", "", "Latest Received","", "", "", "", "", "Starter Disable","", "", "", "", "", "", "", "", "", "Solenoid 3 State", ""
debugFieldI4List = bits, U08, [0:7], "Period", "", "", "State", "Idle di4", "Cycle Cnt 1", "", "", "", "", "", "", "", "", "", "", "", "ETB di4", "executor", "", "di4", "di4", "22di4", "", "24:di4", "", "", "", "", "", "", "Init Count", "", "", "", "", "", "S unused" "", "", "", "", "", "", "", "", "", "Solenoid 4 State", ""
debugFieldI5List = bits, U08, [0:7], "", "", "", "", "Idle di5", "Cycle Cnt 2", "", "", "", "", "", "", "", "", "", "di5", "di5", "ETB di5", "max executor", "di5", "di5", "di5", "22di5", "di5", "di5", "di5", "di5", "di5", "", "di5", "di5", "di5", "", "di5", "di5", "di5", "di5", "S di5" "", "", "", "", "", "", "", "", "", "Solenoid 5 State", ""
[ConstantsExtensions]
; defaultValue is used to provide TunerStudio with a value to use in the case of
@ -859,6 +859,10 @@ enable2ndByteCanID = false
gridOrient = 250, 0, 340 ; Space 123 rotation of grid in degrees.
upDownLabel = "(RICHER)", "(LEANER)"
table = mapEstimateTableTbl, mapEstimateTableMap, "MAP Estimate", 1
xBins = mapEstimateRpmBins, RPMValue
yBins = mapEstimateTpsBins, TPSValue
zBins = mapEstimateTable
table = injPhaseTableTbl, injPhaseTableMap, "Injection Phase", 1
topicHelp = "fuelHelp"
@ -1360,6 +1364,7 @@ menuDialog = main
subMenu = veTableDialog, "VE", 0, {isInjectionEnabled == 1}
subMenu = tChargeSettings, "Charge temperature estimation", 0, {isInjectionEnabled == 1}
subMenu = baroCorrTbl, "Barometric pressure correction", 0, {isInjectionEnabled == 1 && fuelAlgorithm == LM_SPEED_DENSITY}
subMenu = mapEstimateTableTbl, "MAP estimate table", 0, { enableMapEstimationTableFallback }
subMenu = std_separator
# Fuel model
@ -2944,7 +2949,8 @@ cmd_set_engine_type_default = "@@TS_IO_TEST_COMMAND_char@@\x00\x31\x00\x00"
field = "Boost cut pressure", boostCutPressure
dialog = fallbacks, "Fallbacks"
field = "Failed MAP sensor fallback", failedMapFallback
field = "Use MAP estimation table as fallback", enableMapEstimationTableFallback
field = "Failed MAP sensor fallback", failedMapFallback, { !enableMapEstimationTableFallback }
dialog = limitsAndFallback, "Limits and fallbacks"
panel = limits

View File

@ -94,6 +94,7 @@ typedef Map3D<BOOST_RPM_COUNT, BOOST_LOAD_COUNT, uint8_t, uint8_t, efi::ratio<LO
typedef Map3D<BOOST_RPM_COUNT, BOOST_LOAD_COUNT, uint8_t, uint8_t> boostClosedLoop_Map3D_t;
typedef Map3D<IAC_PID_MULT_SIZE, IAC_PID_MULT_SIZE, uint8_t, uint8_t> iacPidMultiplier_t;
typedef Map3D<GPPWM_RPM_COUNT, GPPWM_LOAD_COUNT, uint8_t, uint8_t> gppwm_Map3D_t;
typedef Map3D<FUEL_RPM_COUNT, FUEL_LOAD_COUNT, uint16_t, uint16_t, efi::ratio<1, PACK_MULT_MAP_ESTIMATE>> mapEstimate_Map3D_t;
void setRpmBin(float array[], int size, float idleRpm, float topRpm);