auto-sync

This commit is contained in:
rusEfi 2016-09-17 19:02:34 -04:00
parent b47f20482d
commit 5d5337e306
10 changed files with 34 additions and 18 deletions

View File

@ -72,6 +72,6 @@ void setTestVVTEngineConfiguration(DECLARE_ENGINE_PARAMETER_F) {
engineConfiguration->globalTriggerAngleOffset = 0;
engineConfiguration->vvtMode = VVT_SECOND_HALF;
engineConfiguration->debugMode = VVT;
engineConfiguration->debugMode = DBG_VVT;
}

View File

@ -109,11 +109,11 @@ floatms_t AccelEnrichmemnt::getTpsEnrichment(DECLARE_ENGINE_PARAMETER_F) {
float tpsFrom = cb.get(index - 1);
float d = tpsTo - tpsFrom;
float deltaMult = tpsTpsMap.getValue(tpsFrom, tpsTo);
float valueFromTable = tpsTpsMap.getValue(tpsFrom, tpsTo);
floatms_t extraFuel;
if (d > engineConfiguration->tpsAccelEnrichmentThreshold) {
extraFuel = deltaMult;
extraFuel = valueFromTable;
} else if (d < -engineConfiguration->tpsDecelEnleanmentThreshold) {
extraFuel = d * engineConfiguration->tpsDecelEnleanmentMultiplier;
} else {
@ -124,7 +124,7 @@ floatms_t AccelEnrichmemnt::getTpsEnrichment(DECLARE_ENGINE_PARAMETER_F) {
if (engineConfiguration->debugMode == DBG_TPS_ACCEL) {
tsOutputChannels.debugFloatField1 = tpsFrom;
tsOutputChannels.debugFloatField2 = tpsTo;
tsOutputChannels.debugFloatField3 = deltaMult;
tsOutputChannels.debugFloatField3 = valueFromTable;
tsOutputChannels.debugFloatField4 = extraFuel;
}
#endif

View File

@ -676,7 +676,7 @@ void setDefaultConfiguration(DECLARE_ENGINE_PARAMETER_F) {
engineConfiguration->isWaveAnalyzerEnabled = true;
engineConfiguration->isIdleThreadEnabled = true;
engineConfiguration->debugMode = ALTERNATOR;
engineConfiguration->debugMode = ALTERNATOR_PID;
engineConfiguration->acIdleRpmBump = 200;
engineConfiguration->knockDetectionWindowStart = 35;

View File

@ -600,7 +600,7 @@ typedef enum {
} brain_pin_e;
typedef enum {
ALTERNATOR = 0,
ALTERNATOR_PID = 0,
DBG_TPS_ACCEL = 1,
WARMUP_ENRICH = 2,
IDLE = 3,
@ -608,7 +608,7 @@ typedef enum {
TRIGGER_COUNT = 5,
FSIO_ADC = 6,
AUX_PID_1 = 7,
VVT = 8,
DBG_VVT = 8,
DM_9 = 9,
DM_10 = 10,
DM_11 = 11,

View File

@ -75,7 +75,7 @@ static msg_t AltCtrlThread(int param) {
bool newState = (vBatt < targetVoltage - h) || (currentPlainOnOffState && vBatt < targetVoltage);
enginePins.alternatorPin.setValue(newState);
currentPlainOnOffState = newState;
if (engineConfiguration->debugMode == ALTERNATOR) {
if (engineConfiguration->debugMode == ALTERNATOR_PID) {
tsOutputChannels.debugIntField1 = newState;
}
@ -91,7 +91,7 @@ static msg_t AltCtrlThread(int param) {
}
#if ! EFI_UNIT_TEST || defined(__DOXYGEN__)
if (engineConfiguration->debugMode == ALTERNATOR) {
if (engineConfiguration->debugMode == ALTERNATOR_PID) {
tsOutputChannels.debugFloatField1 = currentAltDuty;
altPid.postState(&tsOutputChannels);
}

View File

@ -108,7 +108,7 @@ void hwHandleVvtCamSignal(trigger_value_e front) {
*/
tc->triggerState.intTotalEventCounter();
#if EFI_PROD_CODE || defined(__DOXYGEN__)
if (engineConfiguration->debugMode == VVT) {
if (engineConfiguration->debugMode == DBG_VVT) {
tsOutputChannels.debugIntField1++;
}
#endif /* EFI_PROD_CODE */
@ -119,7 +119,7 @@ void hwHandleVvtCamSignal(trigger_value_e front) {
// see above comment
#if EFI_PROD_CODE || defined(__DOXYGEN__)
tc->triggerState.intTotalEventCounter();
if (engineConfiguration->debugMode == VVT) {
if (engineConfiguration->debugMode == DBG_VVT) {
tsOutputChannels.debugIntField1++;
}
#endif /* EFI_PROD_CODE */

View File

@ -109,7 +109,7 @@ float baseFuel;+Fuel squirt duration while cranking\nA number of curves adjust t
int16_t rpm;+Cranking mode threshold. Special cranking logic controls fuel and spark while RPM is below this threshold\nset_cranking_rpm X;"RPM", 1, 0, 0, 3000, 0
end_struct
#define debug_mode_e_enum "Alternator", "TPS accel enrich", "Warmup PID", "IDLE", "EL accl enrich", "Trigger Counters", "FSIO_ADC", "AUX_PID_1", "VVT", "mode9", "mode10", "mode11", "mode12", "mode13", "mode14", "mode15"
#define debug_mode_e_enum "Alternator_PID", "TPS accel enrich", "Warmup PID", "IDLE", "EL accl enrich", "Trigger Counters", "FSIO_ADC", "AUX_PID_1", "VVT", "mode9", "mode10", "mode11", "mode12", "mode13", "mode14", "mode15"
custom debug_mode_e 4 bits, U32, @OFFSET@, [0:3], @@debug_mode_e_enum@@
#define vvt_mode_e_enum "First half", "Second half", "2GZ", "mode3"

View File

@ -42,7 +42,7 @@ enable2ndByteCanID = false
; see PAGE_0_SIZE in C source code
; CONFIG_DEFINITION_START
; this section was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Sat Sep 17 14:41:13 EDT 2016
; this section was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Sat Sep 17 18:26:30 EDT 2016
pageSize = 16376
page = 1
@ -554,7 +554,7 @@ page = 1
tpsDecelEnleanmentThreshold = scalar, F32, 2232, "roc", 1, 0, 0, 200, 3
tpsDecelEnleanmentMultiplier = scalar, F32, 2236, "coeff", 1, 0, 0, 200, 3
slowAdcAlpha = scalar, F32, 2240, "coeff", 1, 0, 0, 200, 3
debugMode = bits, U32, 2244, [0:3], "Alternator", "TPS accel enrich", "Warmup PID", "IDLE", "EL accl enrich", "Trigger Counters", "FSIO_ADC", "AUX_PID_1", "VVT", "mode9", "mode10", "mode11", "mode12", "mode13", "mode14", "mode15"
debugMode = bits, U32, 2244, [0:3], "Alternator_PID", "TPS accel enrich", "Warmup PID", "IDLE", "EL accl enrich", "Trigger Counters", "FSIO_ADC", "AUX_PID_1", "VVT", "mode9", "mode10", "mode11", "mode12", "mode13", "mode14", "mode15"
warmupAfrPid_pFactor = scalar, F32, 2248, "value", 1, 0, 0, 1000, 5
warmupAfrPid_iFactor = scalar, F32, 2252, "value", 1, 0, 0, 1000, 5
warmupAfrPid_dFactor = scalar, F32, 2256, "value", 1, 0, 0, 1000, 5
@ -1259,10 +1259,18 @@ fileVersion = { 20160702 }
entry = sparkDwellValue, "dwell", float,"%.3f"
entry = debugMode, "debugMode",int,"%d"
; Alternator_PID: alternator duty cycle
; DBG_TPS_ACCEL: from TPS
entry = debugFloatField1, "debug f1",float,"%.4f"
; DBG_TPS_ACCEL: to TPS
entry = debugFloatField2, "debug f2",float,"%.4f"
; DBG_TPS_ACCEL: tps<>tps table value
entry = debugFloatField3, "debug f3",float,"%.4f"
; DBG_TPS_ACCEL: extra fuel
entry = debugFloatField4, "debug f4",float,"%.4f"
entry = debugFloatField5, "debug f5",float,"%.4f"
entry = debugIntField1, "debug i1",int,"%d"

View File

@ -1232,10 +1232,18 @@ fileVersion = { 20160702 }
entry = sparkDwellValue, "dwell", float,"%.3f"
entry = debugMode, "debugMode",int,"%d"
; Alternator_PID: alternator duty cycle
; DBG_TPS_ACCEL: from TPS
entry = debugFloatField1, "debug f1",float,"%.4f"
; DBG_TPS_ACCEL: to TPS
entry = debugFloatField2, "debug f2",float,"%.4f"
; DBG_TPS_ACCEL: tps<>tps table value
entry = debugFloatField3, "debug f3",float,"%.4f"
; DBG_TPS_ACCEL: extra fuel
entry = debugFloatField4, "debug f4",float,"%.4f"
entry = debugFloatField5, "debug f5",float,"%.4f"
entry = debugIntField1, "debug i1",int,"%d"

View File

@ -1,6 +1,6 @@
package com.rusefi.config;
// this file was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Sat Sep 17 14:41:13 EDT 2016
// this file was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Sat Sep 17 18:26:30 EDT 2016
public class Fields {
public static final int LE_COMMAND_LENGTH = 200;
public static final int FSIO_ADC_COUNT = 4;
@ -1465,7 +1465,7 @@ public class Fields {
public static final Field TPSDECELENLEANMENTTHRESHOLD = Field.create("TPSDECELENLEANMENTTHRESHOLD", 2232, FieldType.FLOAT);
public static final Field TPSDECELENLEANMENTMULTIPLIER = Field.create("TPSDECELENLEANMENTMULTIPLIER", 2236, FieldType.FLOAT);
public static final Field SLOWADCALPHA = Field.create("SLOWADCALPHA", 2240, FieldType.FLOAT);
public static final String[] debug_mode_e = {"Alternator", "TPS accel enrich", "Warmup PID", "IDLE", "EL accl enrich", "Trigger Counters", "FSIO_ADC", "AUX_PID_1", "VVT", "mode9", "mode10", "mode11", "mode12", "mode13", "mode14", "mode15"};
public static final String[] debug_mode_e = {"Alternator_PID", "TPS accel enrich", "Warmup PID", "IDLE", "EL accl enrich", "Trigger Counters", "FSIO_ADC", "AUX_PID_1", "VVT", "mode9", "mode10", "mode11", "mode12", "mode13", "mode14", "mode15"};
public static final Field DEBUGMODE = Field.create("DEBUGMODE", 2244, FieldType.INT, debug_mode_e);
public static final Field WARMUPAFRPID_PFACTOR = Field.create("WARMUPAFRPID_PFACTOR", 2248, FieldType.FLOAT);
public static final Field WARMUPAFRPID_IFACTOR = Field.create("WARMUPAFRPID_IFACTOR", 2252, FieldType.FLOAT);