diff --git a/firmware/controllers/algo/engine_configuration_generated_structures.h b/firmware/controllers/algo/engine_configuration_generated_structures.h index 48aa8cba10..106d5fa96d 100644 --- a/firmware/controllers/algo/engine_configuration_generated_structures.h +++ b/firmware/controllers/algo/engine_configuration_generated_structures.h @@ -1,4 +1,4 @@ -// this section was generated automatically by ConfigDefinition.jar based on integration\rusefi_config.txt Mon Jun 10 12:49:03 EDT 2019 +// this section was generated automatically by ConfigDefinition.jar based on integration\rusefi_config.txt Mon Jun 10 13:04:10 EDT 2019 // begin #ifndef CONTROLLERS_ALGO_ENGINE_CONFIGURATION_GENERATED_STRUCTURES_H #define CONTROLLERS_ALGO_ENGINE_CONFIGURATION_GENERATED_STRUCTURES_H @@ -2552,7 +2552,7 @@ struct persistent_config_s { /** * offset 6400 */ - pedal_to_tps_t pedalToTps; + pedal_to_tps_t pedalToTpsTable; /** * offset 6464 */ @@ -2800,4 +2800,4 @@ typedef struct persistent_config_s persistent_config_s; #endif // end -// this section was generated automatically by ConfigDefinition.jar based on integration\rusefi_config.txt Mon Jun 10 12:49:03 EDT 2019 +// this section was generated automatically by ConfigDefinition.jar based on integration\rusefi_config.txt Mon Jun 10 13:04:10 EDT 2019 diff --git a/firmware/controllers/algo/rusefi_generated.h b/firmware/controllers/algo/rusefi_generated.h index 823575e4c5..80d69a16a2 100644 --- a/firmware/controllers/algo/rusefi_generated.h +++ b/firmware/controllers/algo/rusefi_generated.h @@ -1476,10 +1476,12 @@ #define pauseEtbControl_offset 744 #define pauseEtbControl_offset_hex 2e8 #define PEDAL_TO_TPS_SIZE 8 -#define pedalToTps_offset 6400 -#define pedalToTps_offset_hex 1900 +#define pedalToTps_offset 6472 +#define pedalToTps_offset_hex 1948 #define pedalToTpsBins_offset 6464 #define pedalToTpsBins_offset_hex 1940 +#define pedalToTpsTable_offset 6400 +#define pedalToTpsTable_offset_hex 1900 #define pidExtraForLowRpm_offset 3180 #define pidExtraForLowRpm_offset_hex c6c #define pin_mode_e_enum "default", "INVALID", "INVALID", "INVALID", "opendrain", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "PULLUP", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "INVALID", "PULLDOWN" diff --git a/firmware/controllers/algo/rusefi_types.h b/firmware/controllers/algo/rusefi_types.h index 1cd987c8f5..58ab3ea814 100644 --- a/firmware/controllers/algo/rusefi_types.h +++ b/firmware/controllers/algo/rusefi_types.h @@ -77,6 +77,7 @@ typedef uint8_t afr_table_t[FUEL_LOAD_COUNT][FUEL_RPM_COUNT]; typedef float fuel_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 int8_t pedal_to_tps_t[PEDAL_TO_TPS_SIZE][PEDAL_TO_TPS_SIZE]; typedef float baro_corr_table_t[BARO_CORR_SIZE][BARO_CORR_SIZE]; diff --git a/firmware/integration/rusefi_config.txt b/firmware/integration/rusefi_config.txt index b112892f9b..c3ffefe410 100644 --- a/firmware/integration/rusefi_config.txt +++ b/firmware/integration/rusefi_config.txt @@ -125,13 +125,13 @@ struct_no_prefix engine_configuration_s #define MAF_DECODING_COUNT 256 ! please note that 1024 here is 4 * FUEL_RPM_COUNT * FUEL_LOAD_COUNT -custom fuel_table_t 1024 array, F32, @OFFSET@, [16x16],"ms", 1, 0, 0.0, 500.0, 2 -custom ve_table_t 1024 array, F32, @OFFSET@, [16x16],"%", 1, 0, 0, 999.0, 2 -custom afr_table_t 256 array, U08, @OFFSET@, [16x16],"deg", 0.1, 0, 0, 25.0, 1 +custom fuel_table_t 1024 array, F32, @OFFSET@, [@@FUEL_RPM_COUNT@@x@@FUEL_LOAD_COUNT@@],"ms", 1, 0, 0.0, 500.0, 2 +custom ve_table_t 1024 array, F32, @OFFSET@, [@@FUEL_RPM_COUNT@@x@@FUEL_LOAD_COUNT@@],"%", 1, 0, 0, 999.0, 2 +custom afr_table_t 256 array, U08, @OFFSET@, [@@FUEL_RPM_COUNT@@x@@FUEL_LOAD_COUNT@@],"deg", 0.1, 0, 0, 25.0, 1 -custom fsio_table_8x8_u8t 64 array, U08, @OFFSET@, [8x8],"value", 1, 0, 0.0, 255.0, 0 -custom fsio_table_8x8_f32t 256 array, F32, @OFFSET@, [8x8],"value", 1, 0, 0.0, 30000.0, 2 -custom tps_tps_table_t 256 array, F32, @OFFSET@, [8x8],"value", 1, 0, 0.0, 30000.0, 2 +custom fsio_table_8x8_u8t 64 array, U08, @OFFSET@, [@@FSIO_TABLE_8@@x@@FSIO_TABLE_8@@],"value", 1, 0, 0.0, 255.0, 0 +custom fsio_table_8x8_f32t 256 array, F32, @OFFSET@, [@@FSIO_TABLE_8@@x@@FSIO_TABLE_8@@],"value", 1, 0, 0.0, 30000.0, 2 +custom tps_tps_table_t 256 array, F32, @OFFSET@, [@@TPS_TPS_ACCEL_TABLE@@x@@TPS_TPS_ACCEL_TABLE@@],"value", 1, 0, 0.0, 30000.0, 2 ! todo support table size multiplocation @@ -139,10 +139,10 @@ custom baro_corr_table_t 64 array, F32, @OFFSET@, [@@BARO_CORR_SIZE@@x@@BARO ! please note that 1024 here is 4 * IGN_LOAD_COUNT * IGN_RPM_COUNT -custom ignition_table_t 1024 array, F32, @OFFSET@, [16x16],"deg", 1, 0, -20, 90, 2 -custom ignition_tps_table_t 512 array, S16, @OFFSET@, [16x16],"deg", 0.01, 0, -20, 90, 2 +custom ignition_table_t 1024 array, F32, @OFFSET@, [@@IGN_RPM_COUNT@@x@@IGN_LOAD_COUNT@@],"deg", 1, 0, -20, 90, 2 +custom ignition_tps_table_t 512 array, S16, @OFFSET@, [@@IGN_RPM_COUNT@@x@@IGN_TPS_COUNT@@],"deg", 0.01, 0, -20, 90, 2 -custom angle_table_t 1024 array, F32, @OFFSET@, [16x16],"deg", 1, 0, -720, 720, 2 +custom angle_table_t 1024 array, F32, @OFFSET@, [@@IGN_RPM_COUNT@@x@@IGN_LOAD_COUNT@@],"deg", 1, 0, -720, 720, 2 custom pedal_to_tps_t 64 array, U08, @OFFSET@, [@@PEDAL_TO_TPS_SIZE@@x@@PEDAL_TO_TPS_SIZE@@],"deg", 1, 0, -720, 720, 2 struct pid_s @@ -1062,7 +1062,7 @@ end_struct engine_configuration_s engineConfiguration; -pedal_to_tps_t pedalToTps; +pedal_to_tps_t pedalToTpsTable; uint8_t[PEDAL_TO_TPS_SIZE] pedalToTpsBins;;"%", 1, 0, 0.0, 120.0, 0 uint8_t[PEDAL_TO_TPS_SIZE] pedalToTps;;"%", 1, 0, 0.0, 120.0, 0 diff --git a/firmware/tunerstudio/rusefi.ini b/firmware/tunerstudio/rusefi.ini index 295622fc0c..15f72c1473 100644 --- a/firmware/tunerstudio/rusefi.ini +++ b/firmware/tunerstudio/rusefi.ini @@ -72,7 +72,7 @@ enable2ndByteCanID = false ; see PAGE_0_SIZE in C source code ; CONFIG_DEFINITION_START -; this section was generated automatically by ConfigDefinition.jar based on integration\rusefi_config.txt Mon Jun 10 12:49:03 EDT 2019 +; this section was generated automatically by ConfigDefinition.jar based on integration\rusefi_config.txt Mon Jun 10 13:04:10 EDT 2019 pageSize = 20000 page = 1 @@ -877,7 +877,7 @@ page = 1 mc33972spiDevice = bits,U32, 4032, [0:2], "Off", "SPI1", "SPI2", "SPI3", "SPI4" ;no TS info - skipping unusedSpiPadding8 offset 4033 ;no TS info - skipping mainUnusedEnd offset 4036 - pedalToTps = array, U08, 6400, [8x8],"deg", 1, 0, -720, 720, 2 + pedalToTpsTable = array, U08, 6400, [8x8],"deg", 1, 0, -720, 720, 2 pedalToTpsBins = array, U08, 6464, [8], "%", 1, 0, 0.0, 120.0, 0 pedalToTps = array, U08, 6472, [8], "%", 1, 0, 0.0, 120.0, 0 cltCrankingCorrBins = array, F32, 6480, [8], "C", 1, 0, -100.0, 250.0, 2 diff --git a/firmware/tunerstudio/rusefi_frankenso.ini b/firmware/tunerstudio/rusefi_frankenso.ini index b77c24376f..ccfd087f41 100644 --- a/firmware/tunerstudio/rusefi_frankenso.ini +++ b/firmware/tunerstudio/rusefi_frankenso.ini @@ -72,7 +72,7 @@ enable2ndByteCanID = false ; see PAGE_0_SIZE in C source code ; CONFIG_DEFINITION_START -; this section was generated automatically by ConfigDefinition.jar based on integration\rusefi_config.txt Mon Jun 10 12:49:13 EDT 2019 +; this section was generated automatically by ConfigDefinition.jar based on integration\rusefi_config.txt Mon Jun 10 13:04:21 EDT 2019 pageSize = 20000 page = 1 @@ -877,7 +877,7 @@ page = 1 mc33972spiDevice = bits,U32, 4032, [0:2], "Off", "SPI1", "SPI2", "SPI3", "SPI4" ;no TS info - skipping unusedSpiPadding8 offset 4033 ;no TS info - skipping mainUnusedEnd offset 4036 - pedalToTps = array, U08, 6400, [8x8],"deg", 1, 0, -720, 720, 2 + pedalToTpsTable = array, U08, 6400, [8x8],"deg", 1, 0, -720, 720, 2 pedalToTpsBins = array, U08, 6464, [8], "%", 1, 0, 0.0, 120.0, 0 pedalToTps = array, U08, 6472, [8], "%", 1, 0, 0.0, 120.0, 0 cltCrankingCorrBins = array, F32, 6480, [8], "C", 1, 0, -100.0, 250.0, 2 diff --git a/firmware/tunerstudio/rusefi_microrusefi.ini b/firmware/tunerstudio/rusefi_microrusefi.ini index 6645d19b8b..69b2e0bcfb 100644 --- a/firmware/tunerstudio/rusefi_microrusefi.ini +++ b/firmware/tunerstudio/rusefi_microrusefi.ini @@ -72,7 +72,7 @@ enable2ndByteCanID = false ; see PAGE_0_SIZE in C source code ; CONFIG_DEFINITION_START -; this section was generated automatically by ConfigDefinition.jar based on integration\rusefi_config.txt Mon Jun 10 12:49:08 EDT 2019 +; this section was generated automatically by ConfigDefinition.jar based on integration\rusefi_config.txt Mon Jun 10 13:04:16 EDT 2019 pageSize = 20000 page = 1 @@ -877,7 +877,7 @@ page = 1 mc33972spiDevice = bits,U32, 4032, [0:2], "Off", "SPI1", "SPI2", "SPI3", "SPI4" ;no TS info - skipping unusedSpiPadding8 offset 4033 ;no TS info - skipping mainUnusedEnd offset 4036 - pedalToTps = array, U08, 6400, [8x8],"deg", 1, 0, -720, 720, 2 + pedalToTpsTable = array, U08, 6400, [8x8],"deg", 1, 0, -720, 720, 2 pedalToTpsBins = array, U08, 6464, [8], "%", 1, 0, 0.0, 120.0, 0 pedalToTps = array, U08, 6472, [8], "%", 1, 0, 0.0, 120.0, 0 cltCrankingCorrBins = array, F32, 6480, [8], "C", 1, 0, -100.0, 250.0, 2 diff --git a/firmware/tunerstudio/rusefi_prometheus.ini b/firmware/tunerstudio/rusefi_prometheus.ini index 631440ac65..585d01a77f 100644 --- a/firmware/tunerstudio/rusefi_prometheus.ini +++ b/firmware/tunerstudio/rusefi_prometheus.ini @@ -72,7 +72,7 @@ enable2ndByteCanID = false ; see PAGE_0_SIZE in C source code ; CONFIG_DEFINITION_START -; this section was generated automatically by ConfigDefinition.jar based on integration\rusefi_config.txt Mon Jun 10 12:49:16 EDT 2019 +; this section was generated automatically by ConfigDefinition.jar based on integration\rusefi_config.txt Mon Jun 10 13:04:25 EDT 2019 pageSize = 20000 page = 1 @@ -877,7 +877,7 @@ page = 1 mc33972spiDevice = bits,U32, 4032, [0:2], "Off", "SPI1", "SPI2", "SPI3", "SPI4" ;no TS info - skipping unusedSpiPadding8 offset 4033 ;no TS info - skipping mainUnusedEnd offset 4036 - pedalToTps = array, U08, 6400, [8x8],"deg", 1, 0, -720, 720, 2 + pedalToTpsTable = array, U08, 6400, [8x8],"deg", 1, 0, -720, 720, 2 pedalToTpsBins = array, U08, 6464, [8], "%", 1, 0, 0.0, 120.0, 0 pedalToTps = array, U08, 6472, [8], "%", 1, 0, 0.0, 120.0, 0 cltCrankingCorrBins = array, F32, 6480, [8], "C", 1, 0, -100.0, 250.0, 2 diff --git a/java_console/models/src/com/rusefi/config/Fields.java b/java_console/models/src/com/rusefi/config/Fields.java index 66db4885b1..4ec951058b 100644 --- a/java_console/models/src/com/rusefi/config/Fields.java +++ b/java_console/models/src/com/rusefi/config/Fields.java @@ -1,6 +1,6 @@ package com.rusefi.config; -// this file was generated automatically by ConfigDefinition.jar based on integration\rusefi_config.txt Mon Jun 10 12:49:03 EDT 2019 +// this file was generated automatically by ConfigDefinition.jar based on integration\rusefi_config.txt Mon Jun 10 13:04:10 EDT 2019 public class Fields { public static final int accelerometerSpiDevice_offset = 2736; public static final int acCutoffHighRpm_offset = 1498; @@ -960,10 +960,12 @@ public class Fields { public static final int overrideCrankingIgnition_offset_hex = 204; public static final int pauseEtbControl_offset = 744; public static final int PEDAL_TO_TPS_SIZE = 8; - public static final int pedalToTps_offset = 6400; - public static final int pedalToTps_offset_hex = 1900; + public static final int pedalToTps_offset = 6472; + public static final int pedalToTps_offset_hex = 1948; public static final int pedalToTpsBins_offset = 6464; public static final int pedalToTpsBins_offset_hex = 1940; + public static final int pedalToTpsTable_offset = 6400; + public static final int pedalToTpsTable_offset_hex = 1900; public static final int pidExtraForLowRpm_offset = 3180; public static final int postCrankingDurationSec_offset = 2464; public static final int postCrankingFactor_offset = 2460; @@ -1996,7 +1998,7 @@ public class Fields { public static final Field MC33816SPIDEVICE = Field.create("MC33816SPIDEVICE", 4025, FieldType.INT8); public static final Field TLE6240SPIDEVICE = Field.create("TLE6240SPIDEVICE", 4028, FieldType.INT8); public static final Field MC33972SPIDEVICE = Field.create("MC33972SPIDEVICE", 4032, FieldType.INT8); - public static final Field PEDALTOTPS = Field.create("PEDALTOTPS", 6400, FieldType.INT); + public static final Field PEDALTOTPSTABLE = Field.create("PEDALTOTPSTABLE", 6400, FieldType.INT); public static final Field FSIOFORMULAS1 = Field.create("FSIOFORMULAS1", 6672, FieldType.INT); public static final Field FSIOFORMULAS2 = Field.create("FSIOFORMULAS2", 6872, FieldType.INT); public static final Field FSIOFORMULAS3 = Field.create("FSIOFORMULAS3", 7072, FieldType.INT);