fix #570
This commit is contained in:
parent
5db803a2bd
commit
c049eea877
|
@ -32,7 +32,7 @@ void configureNeon2003TriggerShapeCrank(TriggerShape *s DECLARE_ENGINE_PARAMETER
|
|||
s->useRiseEdge = true;
|
||||
|
||||
s->setTriggerSynchronizationGap(3);
|
||||
int m = 2;
|
||||
int m = CRANK_MODE_MULTIPLIER;
|
||||
|
||||
s->addEvent2(m * 25, T_PRIMARY, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(m * 30, T_PRIMARY, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
|
@ -394,44 +394,46 @@ static void configureNeon1995TriggerShapeCommon(bool withCam, TriggerShape *s DE
|
|||
trigger_wheel_e crank = withCam ? T_SECONDARY : T_PRIMARY;
|
||||
|
||||
// voodoo magic - we always need 720 at the end
|
||||
int base = 720 - 560;
|
||||
int base = withCam ? 720 - 560 : 360 - 135;
|
||||
|
||||
s->addEvent2(base - 720 + 600, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base - 720 + 604, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base - 720 + 616, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base - 720 + 620, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base - 720 + 643, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base - 720 + 648, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base - 720 + 671, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base - 720 + 676, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
float m = withCam ? 1 : 2;
|
||||
|
||||
if (withCam)
|
||||
s->addEvent2(m * (base - 120), crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(m * (base - 116), crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(m * (base - 720 + 616), crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(m * (base - 100), crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(m * (base - 720 + 643), crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(m * (base - 720 + 648), crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(m * (base - 720 + 671), crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(m * (base - 44), crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
|
||||
if (withCam) {
|
||||
s->addEvent2(base + 0, T_PRIMARY, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
}
|
||||
s->addEvent2(m * (base + 20), crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(m * (base + 60), crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(m * (base + 75), crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(m * (base + 79), crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(m * (base + 101), crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(m * (base + 106), crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(m * (base + 130), crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(m * (base + 135), crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
|
||||
s->addEvent2(base + 20, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 60, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 75, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 79, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 101, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 106, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 130, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 135, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
|
||||
if (withCam)
|
||||
if (withCam) {
|
||||
s->addEvent2(base + 200, T_PRIMARY, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX); // width = 150
|
||||
|
||||
s->addEvent2(base + 236, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 239, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 250, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 255, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 277, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 282, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 305, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 310, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 236, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 239, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 250, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 255, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 277, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 282, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 305, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 310, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
|
||||
s->addEvent2(base + 374, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
|
||||
if (withCam)
|
||||
// if (withCam)
|
||||
s->addEvent2(base + 395, T_PRIMARY, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX); // width =
|
||||
|
||||
s->addEvent2(base + 418, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
|
@ -442,12 +444,15 @@ static void configureNeon1995TriggerShapeCommon(bool withCam, TriggerShape *s DE
|
|||
s->addEvent2(base + 492, crank, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
s->addEvent2(base + 497, crank, TV_FALL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
|
||||
if (withCam)
|
||||
// if (withCam)
|
||||
s->addEvent2(base + 560, T_PRIMARY, TV_RISE PASS_ENGINE_PARAMETER_SUFFIX); // width =
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
void configureNeon1995TriggerShapeOnlyCrank(TriggerShape *s DECLARE_ENGINE_PARAMETER_SUFFIX) {
|
||||
s->initialize(FOUR_STROKE_CRANK_SENSOR, false);
|
||||
s->setTriggerSynchronizationGap(3.79);
|
||||
|
||||
configureNeon1995TriggerShapeCommon(false, s PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
}
|
||||
|
|
|
@ -384,6 +384,8 @@ void printAllTriggers() {
|
|||
TriggerShape *s = &engine->triggerCentral.triggerShape;
|
||||
s->initializeTriggerShape(NULL PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
|
||||
efiAssertVoid(!s->shapeDefinitionError, "trigger error");
|
||||
|
||||
fprintf(fp, "TRIGGERTYPE %d %d %s %.2f\n", triggerId, s->getLength(), getTrigger_type_e(tt), s->tdcPosition);
|
||||
|
||||
fprintf(fp, "# duty %.2f %.2f\n", s->expectedDutyCycle[0], s->expectedDutyCycle[1]);
|
||||
|
|
|
@ -475,10 +475,13 @@ void TriggerShape::initializeTriggerShape(Logging *logger DECLARE_ENGINE_PARAMET
|
|||
break;
|
||||
|
||||
case TT_DODGE_NEON_1995:
|
||||
case TT_DODGE_NEON_1995_ONLY_CRANK:
|
||||
configureNeon1995TriggerShape(this PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
break;
|
||||
|
||||
case TT_DODGE_NEON_1995_ONLY_CRANK:
|
||||
configureNeon1995TriggerShapeOnlyCrank(this PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
break;
|
||||
|
||||
case TT_DODGE_STRATUS:
|
||||
configureDodgeStratusTriggerShape(this PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
break;
|
||||
|
|
|
@ -337,7 +337,7 @@ void TriggerShape::addEvent2(angle_t angle, trigger_wheel_e const waveIndex, tri
|
|||
efiAssertVoid(angle > 0, "angle should be positive");
|
||||
if (size > 0) {
|
||||
if (angle <= previousAngle) {
|
||||
warning(CUSTOM_ERR_TRG_ANGLE_ORDER, "invalid angle order: %.2f and %.2f, size=%d", angle, previousAngle, size);
|
||||
warning(CUSTOM_ERR_TRG_ANGLE_ORDER, "invalid angle order: new=%.2f and prev=%.2f, size=%d", angle, previousAngle, size);
|
||||
shapeDefinitionError = true;
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -276,5 +276,5 @@ int getRusEfiVersion(void) {
|
|||
if (initBootloader() != 0)
|
||||
return 123;
|
||||
#endif /* EFI_BOOTLOADER_INCLUDE_CODE */
|
||||
return 20180210;
|
||||
return 20180301;
|
||||
}
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
package com.rusefi.config;
|
||||
|
||||
// this file was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Sun Feb 25 20:46:04 EST 2018
|
||||
// this file was generated automatically by ConfigDefinition.jar based on rusefi_config.txt Mon Feb 26 22:17:31 EST 2018
|
||||
public class Fields {
|
||||
public static final int LE_COMMAND_LENGTH = 200;
|
||||
public static final int BLOCKING_FACTOR = 400;
|
||||
|
@ -1266,7 +1266,7 @@ public class Fields {
|
|||
public static final Field TPSADCCHANNEL = Field.create("TPSADCCHANNEL", 520, FieldType.INT, adc_channel_e);
|
||||
public static final Field OVERRIDECRANKINGIGNITION = Field.create("OVERRIDECRANKINGIGNITION", 524, FieldType.INT);
|
||||
public static final Field SENSORCHARTFREQUENCY = Field.create("SENSORCHARTFREQUENCY", 528, FieldType.INT);
|
||||
public static final String[] trigger_type_e = {"custom toothed wheel", "Ford Aspire", "Dodge Neon 1995", "Miata NA", "Miata NB", "GM_7X", "Cooper R50", "Mazda SOHC 4", "60/2", "36/1", "Honda 4+24+1", "Mitsubishi", "Honda 4+24", "Honda 1+4+24", "Dodge Neon 2003", "Mazda DOHC 1+4", "1+1", "1+60/2", "Single Tooth", "Dodge Ram 1+16", "60/2 VW", "Honda 1+24", "Dodge Stratus", "36_2_2_2", "Nissan Primera", "2JZ", "Rover K", "GM LS 24", "Honda CBR 600", "2JZ_1_12", "Honda CBR 600 custom", "3/1 skipped" , "Dodge Neon 2003 crank", "Miata VVT", "trg34", "trg35", "Subaru 7+6", "Jeep 18-2-2-2", "WIP", "trg39", "trg40", "trg41", "trg42", "INVALID"};
|
||||
public static final String[] trigger_type_e = {"custom toothed wheel", "Ford Aspire", "Dodge Neon 1995", "Miata NA", "Miata NB", "GM_7X", "Cooper R50", "Mazda SOHC 4", "60/2", "36/1", "Honda 4+24+1", "Mitsubishi", "Honda 4+24", "Honda 1+4+24", "Dodge Neon 2003", "Mazda DOHC 1+4", "1+1", "1+60/2", "Single Tooth", "Dodge Ram 1+16", "60/2 VW", "Honda 1+24", "Dodge Stratus", "36_2_2_2", "Nissan Primera", "2JZ", "Rover K", "GM LS 24", "Honda CBR 600", "2JZ_1_12", "Honda CBR 600 custom", "3/1 skipped" , "Dodge Neon 2003 crank", "Miata VVT", "trg34", "trg35", "Subaru 7+6", "Jeep 18-2-2-2", "WIP", "Dodge Neon 1995 crank only", "trg40", "trg41", "trg42", "INVALID"};
|
||||
public static final Field TRIGGER_TYPE = Field.create("TRIGGER_TYPE", 532, FieldType.INT, trigger_type_e);
|
||||
public static final Field TRIGGER_UNUSEDCUSTOMISSYNCHRONIZATIONNEEDED = Field.create("TRIGGER_UNUSEDCUSTOMISSYNCHRONIZATIONNEEDED", 536, FieldType.BIT, 0);
|
||||
public static final Field TRIGGER_UNUSEDCUSTOMNEEDSECONDTRIGGERINPUT = Field.create("TRIGGER_UNUSEDCUSTOMNEEDSECONDTRIGGERINPUT", 536, FieldType.BIT, 1);
|
||||
|
|
|
@ -2411,21 +2411,37 @@ event 182 1001 541.00
|
|||
event 183 1000 542.00
|
||||
event 184 1001 543.00
|
||||
event 185 0 544.00
|
||||
TRIGGERTYPE 39 16 TT_DODGE_NEON_1995_ONLY_CRANK 0.00
|
||||
# duty 0.00 0.00
|
||||
TRIGGERTYPE 39 32 TT_DODGE_NEON_1995_ONLY_CRANK 0.00
|
||||
# duty 0.80 0.00
|
||||
event 0 1 0.00
|
||||
event 1 0 0.00
|
||||
event 2 1 0.00
|
||||
event 3 0 0.00
|
||||
event 4 1 0.00
|
||||
event 5 0 0.00
|
||||
event 6 1 0.00
|
||||
event 7 0 0.00
|
||||
event 8 1 0.00
|
||||
event 9 0 0.00
|
||||
event 10 1 0.00
|
||||
event 11 0 0.00
|
||||
event 12 1 0.00
|
||||
event 13 0 0.00
|
||||
event 14 1 0.00
|
||||
event 15 0 0.00
|
||||
event 1 0 4.00
|
||||
event 2 1 16.00
|
||||
event 3 0 20.00
|
||||
event 4 1 43.00
|
||||
event 5 0 48.00
|
||||
event 6 1 71.00
|
||||
event 7 0 76.00
|
||||
event 8 1 140.00
|
||||
event 9 0 180.00
|
||||
event 10 1 195.00
|
||||
event 11 0 199.00
|
||||
event 12 1 221.00
|
||||
event 13 0 226.00
|
||||
event 14 1 250.00
|
||||
event 15 0 255.00
|
||||
event 16 1 360.00
|
||||
event 17 0 364.00
|
||||
event 18 1 376.00
|
||||
event 19 0 380.00
|
||||
event 20 1 403.00
|
||||
event 21 0 408.00
|
||||
event 22 1 431.00
|
||||
event 23 0 436.00
|
||||
event 24 1 500.00
|
||||
event 25 0 540.00
|
||||
event 26 1 555.00
|
||||
event 27 0 559.00
|
||||
event 28 1 581.00
|
||||
event 29 0 586.00
|
||||
event 30 1 610.00
|
||||
event 31 0 615.00
|
||||
|
|
Loading…
Reference in New Issue