Cranking add cold advance option (#872)
Co-authored-by: Josh Stewart <josh@noisymime.org>
This commit is contained in:
parent
424a96d9ea
commit
9a1c3e30c3
|
@ -326,7 +326,7 @@ page = 1
|
||||||
reqFuel = scalar, U08, 24, "ms", 0.1, 0.0, 0.0, 25.5, 1
|
reqFuel = scalar, U08, 24, "ms", 0.1, 0.0, 0.0, 25.5, 1
|
||||||
divider = scalar, U08, 25, "", 1.0, 0.0
|
divider = scalar, U08, 25, "", 1.0, 0.0
|
||||||
alternate = bits, U08, 26, [0:0], "Simultaneous", "Alternating"
|
alternate = bits, U08, 26, [0:0], "Simultaneous", "Alternating"
|
||||||
multiplyMAP1 = bits, U08, 26, [1:1], "No", "Yes"
|
crkngAddCLTAdv= bits, U08, 26, [1:1], "No", "Yes"
|
||||||
includeAFR = bits, U08, 26, [2:2], "No", "Yes"
|
includeAFR = bits, U08, 26, [2:2], "No", "Yes"
|
||||||
hardCutType = bits, U08, 26, [3:3], "Full", "Rolling"
|
hardCutType = bits, U08, 26, [3:3], "Full", "Rolling"
|
||||||
ignAlgorithm = bits, U08, 26, [4:6], $loadSourceNames
|
ignAlgorithm = bits, U08, 26, [4:6], $loadSourceNames
|
||||||
|
@ -2167,6 +2167,7 @@ menuDialog = main
|
||||||
ignBypassPin = "The ARDUINO pin that the ignition bypass is connected to. This is NOT the pin on the connector, but the pin it relates to on the arduino"
|
ignBypassPin = "The ARDUINO pin that the ignition bypass is connected to. This is NOT the pin on the connector, but the pin it relates to on the arduino"
|
||||||
ignBypassEnable = "If turned on, a ground signal will be output during cranking on the specified pin. This is used to bypass the Speeduino ignition control during cranking."
|
ignBypassEnable = "If turned on, a ground signal will be output during cranking on the specified pin. This is used to bypass the Speeduino ignition control during cranking."
|
||||||
ignCranklock = "On certain low resolution ignition patterns, the cranking timing can be locked to occur when a pulse is received."
|
ignCranklock = "On certain low resolution ignition patterns, the cranking timing can be locked to occur when a pulse is received."
|
||||||
|
crkngAddCLTAdv = "Adds cold advance values to cranking angle."
|
||||||
|
|
||||||
multiplyMAP = "If enabled, the MAP reading is included directly into the pulsewidth calculation by multiplying the VE lookup value by either the MAP:Baro ratio or MAP/100.\n This results in a flatter VE table that can be easier to tune in some instances. The MAP/100 option is generally used for compatibility with fuel tables from other ECUs. MAP:Baro ratio is recommended for new tunes. \n VE table must be retuned when this value is changed."
|
multiplyMAP = "If enabled, the MAP reading is included directly into the pulsewidth calculation by multiplying the VE lookup value by either the MAP:Baro ratio or MAP/100.\n This results in a flatter VE table that can be easier to tune in some instances. The MAP/100 option is generally used for compatibility with fuel tables from other ECUs. MAP:Baro ratio is recommended for new tunes. \n VE table must be retuned when this value is changed."
|
||||||
legacyMAP = "Use the legacy method of reading the MAP sensor that was used prior to the 201905 firmware. This should ONLY be enabled if you are upgrading from a firmware earlier than this"
|
legacyMAP = "Use the legacy method of reading the MAP sensor that was used prior to the 201905 firmware. This should ONLY be enabled if you are upgrading from a firmware earlier than this"
|
||||||
|
@ -2789,6 +2790,7 @@ menuDialog = main
|
||||||
|
|
||||||
dialog = crankingIgnOptions, "Cranking Timing", yAxis
|
dialog = crankingIgnOptions, "Cranking Timing", yAxis
|
||||||
field = "Cranking advance Angle", CrankAng, { ignCranklock == 0 }
|
field = "Cranking advance Angle", CrankAng, { ignCranklock == 0 }
|
||||||
|
field = "Add cold advance", crkngAddCLTAdv, { ignCranklock == 0 }
|
||||||
field = "Cranking bypass", ignBypassEnable
|
field = "Cranking bypass", ignBypassEnable
|
||||||
field = "Bypass output pin", ignBypassPin { ignBypassEnable }
|
field = "Bypass output pin", ignBypassPin { ignBypassEnable }
|
||||||
field = "Fix cranking timing with trigger", ignCranklock, { TrigPattern == 1 || TrigPattern == 4 || TrigPattern == 10 || TrigPattern == 9 }
|
field = "Fix cranking timing with trigger", ignCranklock, { TrigPattern == 1 || TrigPattern == 4 || TrigPattern == 10 || TrigPattern == 9 }
|
||||||
|
|
|
@ -723,7 +723,11 @@ int8_t correctionFixedTiming(int8_t advance)
|
||||||
int8_t correctionCrankingFixedTiming(int8_t advance)
|
int8_t correctionCrankingFixedTiming(int8_t advance)
|
||||||
{
|
{
|
||||||
int8_t ignCrankFixValue = advance;
|
int8_t ignCrankFixValue = advance;
|
||||||
if ( BIT_CHECK(currentStatus.engine, BIT_ENGINE_CRANK) ) { ignCrankFixValue = configPage4.CrankAng; } //Use the fixed cranking ignition angle
|
if ( BIT_CHECK(currentStatus.engine, BIT_ENGINE_CRANK) )
|
||||||
|
{
|
||||||
|
if ( configPage2.crkngAddCLTAdv == 0 ) { ignCrankFixValue = configPage4.CrankAng; } //Use the fixed cranking ignition angle
|
||||||
|
else { ignCrankFixValue = correctionCLTadvance(configPage4.CrankAng); } //Use the CLT compensated cranking ignition angle
|
||||||
|
}
|
||||||
return ignCrankFixValue;
|
return ignCrankFixValue;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -781,7 +781,7 @@ struct config2 {
|
||||||
byte reqFuel; //24
|
byte reqFuel; //24
|
||||||
byte divider;
|
byte divider;
|
||||||
byte injTiming : 1; ///< Injector timing (aka. injector staging) 0=simultaneous, 1=alternating
|
byte injTiming : 1; ///< Injector timing (aka. injector staging) 0=simultaneous, 1=alternating
|
||||||
byte multiplyMAP_old : 1;
|
byte crkngAddCLTAdv : 1;
|
||||||
byte includeAFR : 1; //< Enable AFR compensation ? (See also @ref config2.incorporateAFR)
|
byte includeAFR : 1; //< Enable AFR compensation ? (See also @ref config2.incorporateAFR)
|
||||||
byte hardCutType : 1;
|
byte hardCutType : 1;
|
||||||
byte ignAlgorithm : 3;
|
byte ignAlgorithm : 3;
|
||||||
|
|
|
@ -427,7 +427,7 @@ void doUpdates(void)
|
||||||
configPage13.outputPin[7] = 0;
|
configPage13.outputPin[7] = 0;
|
||||||
|
|
||||||
//New multiply MAP option added. Set new option to be the same as old
|
//New multiply MAP option added. Set new option to be the same as old
|
||||||
configPage2.multiplyMAP = configPage2.multiplyMAP_old;
|
configPage2.multiplyMAP = configPage2.crkngAddCLTAdv;
|
||||||
//New AE option added to allow for PW added in addition to existing PW multiply
|
//New AE option added to allow for PW added in addition to existing PW multiply
|
||||||
configPage2.aeApplyMode = 0; //Set the AE mode to Multiply
|
configPage2.aeApplyMode = 0; //Set the AE mode to Multiply
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue