Merge remote-tracking branch 'origin/master'

This commit is contained in:
rusefi 2021-10-26 17:02:21 -04:00
commit 6161ed34b1
31 changed files with 92 additions and 74 deletions

View File

@ -0,0 +1 @@
#define ts_show_etb_pins false

View File

@ -15,6 +15,7 @@
#define ts_show_can2 false
#define ts_show_software_knock true
#define ts_show_hardware_simulator false
#define ts_show_etb_pins false
#define show_test_presets false
#define show_Frankenso_presets false

View File

@ -12,6 +12,7 @@
#endif // HW_PROTEUS
/**
* K24A4 engine
* PROTEUS_HONDA_ELEMENT_2003
*/
void setProteusHondaElement2003(DECLARE_CONFIG_PARAMETER_SIGNATURE) {
@ -26,6 +27,9 @@ void setProteusHondaElement2003(DECLARE_CONFIG_PARAMETER_SIGNATURE) {
engineConfiguration->vvtMode[0] = VVT_FIRST_HALF;
engineConfiguration->vvtMode[1] = VVT_FIRST_HALF;
engineConfiguration->map.sensor.type = MT_DENSO183;
engineConfiguration->injector.flow = 270;
strcpy(CONFIG(engineMake), ENGINE_MAKE_HONDA);
strcpy(CONFIG(engineCode), "K24");
strcpy(CONFIG(vehicleName), "test");

View File

@ -1,4 +1,4 @@
// this file was generated automatically by rusEFI tool ConfigDefinition.jar based on gen_config.sh integration/rusefi_config.txt Mon Oct 25 21:51:44 UTC 2021
// this file was generated automatically by rusEFI tool ConfigDefinition.jar based on gen_config.sh integration/rusefi_config.txt Tue Oct 26 19:16:32 UTC 2021
// by class com.rusefi.output.FileFsioSettingsConsumer
FSIO_SETTING_ACIDLEEXTRAOFFSET = 1000,

View File

@ -1,4 +1,4 @@
// this file was generated automatically by rusEFI tool ConfigDefinition.jar based on gen_config.sh integration/rusefi_config.txt Mon Oct 25 21:51:44 UTC 2021
// this file was generated automatically by rusEFI tool ConfigDefinition.jar based on gen_config.sh integration/rusefi_config.txt Tue Oct 26 19:16:32 UTC 2021
// by class com.rusefi.output.FileFsioSettingsConsumer
case FSIO_SETTING_ACIDLEEXTRAOFFSET:

View File

@ -1,4 +1,4 @@
// this file was generated automatically by rusEFI tool ConfigDefinition.jar based on gen_config.sh integration/rusefi_config.txt Mon Oct 25 21:51:44 UTC 2021
// this file was generated automatically by rusEFI tool ConfigDefinition.jar based on gen_config.sh integration/rusefi_config.txt Tue Oct 26 19:16:32 UTC 2021
// by class com.rusefi.output.FileFsioSettingsConsumer
static LENameOrdinalPair leacIdleExtraOffset(FSIO_SETTING_ACIDLEEXTRAOFFSET, "cfg_acIdleExtraOffset");

View File

@ -1,4 +1,4 @@
// this file was generated automatically by rusEFI tool ConfigDefinition.jar based on gen_config.sh integration/rusefi_config.txt Mon Oct 25 21:51:44 UTC 2021
// this file was generated automatically by rusEFI tool ConfigDefinition.jar based on gen_config.sh integration/rusefi_config.txt Tue Oct 26 19:16:32 UTC 2021
// by class com.rusefi.output.FileFsioSettingsConsumer
case FSIO_SETTING_ACIDLEEXTRAOFFSET:

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD all
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 2075277480
#define TS_SIGNATURE "rusEFI 2021.10.25.all.2075277480"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 2749080011
#define TS_SIGNATURE "rusEFI 2021.10.26.all.2749080011"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD atlas
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 2075277480
#define TS_SIGNATURE "rusEFI 2021.10.25.atlas.2075277480"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 3205584108
#define TS_SIGNATURE "rusEFI 2021.10.26.atlas.3205584108"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD f429-discovery
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 2075277480
#define TS_SIGNATURE "rusEFI 2021.10.25.f429-discovery.2075277480"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 2749080011
#define TS_SIGNATURE "rusEFI 2021.10.26.f429-discovery.2749080011"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD frankenso_na6
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 25193793
#define TS_SIGNATURE "rusEFI 2021.10.25.frankenso_na6.25193793"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 3655988258
#define TS_SIGNATURE "rusEFI 2021.10.26.frankenso_na6.3655988258"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD hellen-nb1
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 3569383272
#define TS_SIGNATURE "rusEFI 2021.10.25.hellen-nb1.3569383272"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 212463115
#define TS_SIGNATURE "rusEFI 2021.10.26.hellen-nb1.212463115"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD hellen121nissan
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 4030947562
#define TS_SIGNATURE "rusEFI 2021.10.25.hellen121nissan.4030947562"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 673905033
#define TS_SIGNATURE "rusEFI 2021.10.26.hellen121nissan.673905033"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD hellen121vag
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 677304558
#define TS_SIGNATURE "rusEFI 2021.10.25.hellen121vag.677304558"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 4030153101
#define TS_SIGNATURE "rusEFI 2021.10.26.hellen121vag.4030153101"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD hellen128
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 2914132088
#define TS_SIGNATURE "rusEFI 2021.10.25.hellen128.2914132088"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 1977334043
#define TS_SIGNATURE "rusEFI 2021.10.26.hellen128.1977334043"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD hellen154hyundai
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 1070440082
#define TS_SIGNATURE "rusEFI 2021.10.25.hellen154hyundai.1070440082"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 3886286833
#define TS_SIGNATURE "rusEFI 2021.10.26.hellen154hyundai.3886286833"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD hellen72
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 489117839
#define TS_SIGNATURE "rusEFI 2021.10.25.hellen72.489117839"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 3310273004
#define TS_SIGNATURE "rusEFI 2021.10.26.hellen72.3310273004"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD hellen88bmw
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 2368914501
#define TS_SIGNATURE "rusEFI 2021.10.25.hellen88bmw.2368914501"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 1432050982
#define TS_SIGNATURE "rusEFI 2021.10.26.hellen88bmw.1432050982"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD hellenNA6
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 2373472580
#define TS_SIGNATURE "rusEFI 2021.10.25.hellenNA6.2373472580"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 1427228711
#define TS_SIGNATURE "rusEFI 2021.10.26.hellenNA6.1427228711"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD hellen_cypress
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 969859960
#define TS_SIGNATURE "rusEFI 2021.10.25.hellen_cypress.969859960"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 3785849371
#define TS_SIGNATURE "rusEFI 2021.10.26.hellen_cypress.3785849371"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD kin
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 3328913284
#define TS_SIGNATURE "rusEFI 2021.10.25.kin.3328913284"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 503494375
#define TS_SIGNATURE "rusEFI 2021.10.26.kin.503494375"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD mre_f4
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 4079103804
#define TS_SIGNATURE "rusEFI 2021.10.25.mre_f4.4079103804"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 726382175
#define TS_SIGNATURE "rusEFI 2021.10.26.mre_f4.726382175"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD mre_f7
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 4079103804
#define TS_SIGNATURE "rusEFI 2021.10.25.mre_f7.4079103804"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 726382175
#define TS_SIGNATURE "rusEFI 2021.10.26.mre_f7.726382175"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD prometheus_405
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 727245134
#define TS_SIGNATURE "rusEFI 2021.10.25.prometheus_405.727245134"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 4080105517
#define TS_SIGNATURE "rusEFI 2021.10.26.prometheus_405.4080105517"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD prometheus_469
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 727245134
#define TS_SIGNATURE "rusEFI 2021.10.25.prometheus_469.727245134"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 4080105517
#define TS_SIGNATURE "rusEFI 2021.10.26.prometheus_469.4080105517"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD proteus_f4
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 329075135
#define TS_SIGNATURE "rusEFI 2021.10.25.proteus_f4.329075135"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 4117680908
#define TS_SIGNATURE "rusEFI 2021.10.26.proteus_f4.4117680908"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD proteus_f7
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 329075135
#define TS_SIGNATURE "rusEFI 2021.10.25.proteus_f7.329075135"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 4117680908
#define TS_SIGNATURE "rusEFI 2021.10.26.proteus_f7.4117680908"

View File

@ -3,6 +3,6 @@
//
#define SIGNATURE_BOARD subaru_eg33_f7
#define SIGNATURE_DATE 2021.10.25
#define SIGNATURE_HASH 3996701643
#define TS_SIGNATURE "rusEFI 2021.10.25.subaru_eg33_f7.3996701643"
#define SIGNATURE_DATE 2021.10.26
#define SIGNATURE_HASH 911297192
#define TS_SIGNATURE "rusEFI 2021.10.26.subaru_eg33_f7.911297192"

View File

@ -67,10 +67,22 @@ static void handleCanFrame(LuaHandle& ls, CANRxFrame* frame) {
return;
}
// TODO: push arguments to function!
UNUSED(frame);
auto dlc = frame->DLC;
int status = lua_pcall(ls, 0, 0, 0);
// Push bus, ID and DLC
lua_pushinteger(ls, 1); // TODO: support multiple busses!
lua_pushinteger(ls, CAN_EID(*frame));
lua_pushinteger(ls, dlc);
// Build table for data
lua_newtable(ls);
for (size_t i = 0; i < dlc; i++) {
lua_pushinteger(ls, frame->data8[i]);
lua_rawseti(ls, -2, i);
}
// Perform the actual function call
int status = lua_pcall(ls, 4, 0, 0);
if (0 != status) {
// error calling CAN rx hook function

View File

@ -1039,7 +1039,7 @@ bit unusedBitHere4
uint8_t etbNeutralPosition;+Expected neutral position;"%", 1, 0, 0, 100, 0
! todo: convert this into a bit setting no need for 4 bytes and we do not expect a third option any day soon
custom idle_mode_e 4 bits, U32, @OFFSET@, [0:0], "Closed Loop", "Open Loop"
custom idle_mode_e 4 bits, U32, @OFFSET@, [0:0], "Open Loop + Closed Loop", "Open Loop"
idle_mode_e idleMode;See also idleRpmPid;
bit isInjectionEnabled;+Enable fuel injection - This is default off for new projects as a safety feature, set to "true" to enable fuel injection and further injector settings.

View File

@ -2675,7 +2675,6 @@ cmd_set_engine_type_default = "@@TS_IO_TEST_COMMAND_char@@\x00\x31\x00\x00"
field = "Idle Solenoid Frequency", idle_solenoidFrequency, !useStepperIdle
dialog = etbHbridgeHardware, "ETB H-Bridge Hardware"
field = "PWM Frequency", etbFreq
field = "Two-wire mode", etb_use_two_wires
field = "No1 Direction #1", etbIo1_directionPin1
field = "No1 Direction #2", etbIo1_directionPin2
@ -2727,8 +2726,8 @@ cmd_set_engine_type_default = "@@TS_IO_TEST_COMMAND_char@@\x00\x31\x00\x00"
panel = idleStepperHwType
dialog = idleHwType, "Idle Valve Hardware", yAxis
panel = idleStepper
panel = idleSolenoid
panel = idleStepper
dialog = idlehw, "", yAxis
field = "!ECU reboot needed to apply these settings"
@ -3470,11 +3469,12 @@ cmd_set_engine_type_default = "@@TS_IO_TEST_COMMAND_char@@\x00\x31\x00\x00"
field = "Disable ETB Motor", pauseEtbControl
field = "H-Bridge #1 function", etbFunctions1
field = "H-Bridge #2 function", etbFunctions2
field = "PWM Frequency", etbFreq
; we need the term about stepper idle in here, because there's a bug in TS that you can't have different visibility
; criteria for the same panel when used in multiple places
; todo: report bug to TS?
; another todo: split panel into two panels so that we can enable/disable h-bridge #1 separately from h-bridge #2
panel = etbHbridgeHardware, { etbFunctions1 != @@etb_function_e_ETB_None@@ || etbFunctions2 != @@etb_function_e_ETB_None@@ || (useStepperIdle && useHbridgesToDriveIdleStepper) }
panel = etbHbridgeHardware, { etbFunctions1 != @@etb_function_e_ETB_None@@ || etbFunctions2 != @@etb_function_e_ETB_None@@ || (useStepperIdle && useHbridgesToDriveIdleStepper) } @@if_ts_show_etb_pins
dialog = etbAutotune, "PID Autotune"
field = "First step: calibrate TPS and hit 'Burn'"