only:Expand daihatsu 3+1 3cyl trigger to 4+1 as well #5925

This commit is contained in:
rusefillc 2024-02-08 10:03:43 -05:00
parent c48a733025
commit 26dc08634f
5 changed files with 19 additions and 16 deletions

View File

@ -293,7 +293,7 @@ enum class trigger_type_e : uint32_t {
TT_MAZDA_MIATA_NA = 3,
TT_VVT_FORD_COYOTE = 4,
TT_GM_7X = 5,
TT_DAIHATSU = 6,
TT_DAIHATSU_3_CYL = 6,
TT_MAZDA_SOHC_4 = 7,
// "60/2"
// See also TT_ONE_PLUS_TOOTHED_WHEEL_60_2
@ -415,13 +415,15 @@ enum class trigger_type_e : uint32_t {
TT_6_TOOTH_CRANK = 80,
TT_DAIHATSU_4_CYL = 81,
// do not forget to edit "#define trigger_type_e_enum" line in integration/rusefi_config.txt file to propogate new value to rusefi.ini TS project
// do not forget to invoke "gen_config.bat" once you make changes to integration/rusefi_config.txt
// todo: one day a hero would integrate some of these things into Makefile in order to reduce manual magic
//
// Another point: once you add a new trigger, run get_trigger_images.bat which would run rusefi_test.exe from unit_tests
//
TT_UNUSED = 81, // this is used if we want to iterate over all trigger types
TT_UNUSED = 82, // this is used if we want to iterate over all trigger types
};
typedef enum {

View File

@ -100,7 +100,7 @@ void configureFordST170(TriggerWaveform * s) {
s->addEventAngle(8 * total, TriggerValue::FALL);
}
void configureDaihatsu4(TriggerWaveform * s) {
void configureDaihatsu3cyl(TriggerWaveform * s) {
s->initialize(FOUR_STROKE_CAM_SENSOR, SyncEdge::RiseOnly);
int width = 10;
@ -173,16 +173,16 @@ void configureBenelli(TriggerWaveform *s) {
}
void configure60degSingleTooth(TriggerWaveform *s) {
/** @todo
/** @todo
* My approach was to utilize ::Both especially for single
* tooth and manual kikstarter, to be ready on both sides of blind.
* But unfortuneally, my experiments show me the Trigger can't
* become syncronized by 'last' and folowed 'first' events only.
* Also I observe phase-aligment mehanism is trying to consume a
* tooth and manual kikstarter, to be ready on both sides of blind.
* But unfortuneally, my experiments show me the Trigger can't
* become syncronized by 'last' and folowed 'first' events only.
* Also I observe phase-aligment mehanism is trying to consume a
* longer side of trigger as latest before TDC.
* I wish to setup SyncEdge::Both for my TT_60DEG_TOOTH after
* this case of scenario become work well. For now, ::Rise work
* well for my 60 degree trigger and both edges phase sync work
* I wish to setup SyncEdge::Both for my TT_60DEG_TOOTH after
* this case of scenario become work well. For now, ::Rise work
* well for my 60 degree trigger and both edges phase sync work
* as mush as expected for my engine startup. */
s->initialize(FOUR_STROKE_CRANK_SENSOR, SyncEdge::Rise);
@ -191,7 +191,7 @@ void configure60degSingleTooth(TriggerWaveform *s) {
s->addEvent360(360, TriggerValue::FALL);
s->tdcPosition = 60;
s->isSynchronizationNeeded = false;
s->useOnlyPrimaryForSync = true;
}

View File

@ -10,7 +10,7 @@
class TriggerWaveform;
void configureFiatIAQ_P8(TriggerWaveform * s);
void configureDaihatsu4(TriggerWaveform * s);
void configureDaihatsu3cyl(TriggerWaveform * s);
void configureFordPip(TriggerWaveform * s);
void configureFordST170(TriggerWaveform * s);
void configureTriTach(TriggerWaveform * s);

View File

@ -578,8 +578,9 @@ void TriggerWaveform::initializeTriggerWaveform(operation_mode_e triggerOperatio
configureMazdaProtegeSOHC(this);
break;
case trigger_type_e::TT_DAIHATSU:
configureDaihatsu4(this);
case trigger_type_e::TT_DAIHATSU_3_CYL:
case trigger_type_e::TT_DAIHATSU_4_CYL:
configureDaihatsu3cyl(this);
break;
case trigger_type_e::TT_VVT_TOYOTA_3_TOOTH:

View File

@ -565,7 +565,7 @@ adc_channel_e fuelLevelSensor;This is the processor pin that your fuel level sen
struct trigger_config_s
! 'INVALID' for TT_VVT_* wheels
#define trigger_type_e_enum "custom toothed wheel", "Ford Aspire", "Dodge Neon 1995", "Miata NA", "INVALID", "GM_7X", "Cooper R50", "Mazda SOHC 4", "60/2", "36/1", "Mercedes Two Segment", "Single Tooth", "EZ30", "INVALID", "Dodge Neon 2003", "Mazda DOHC 1+4", "1+1", "INVALID", "Half Moon", "Dodge Ram 1+16", "60/2 VW", "Benelli Tre", "Dodge Stratus", "36_2_2_2", "Nissan Primera", "dev 2JZ 3/34 simulator", "Rover K", "GM 24x 5 degree", "Honda CBR 600 Cam", "Mitsubishi 4G92/93/94 Cam 29", "Honda CBR 600 custom", "3/1 skipped", "Dodge Neon 2003 crank", "Miata NB", "Mitsubishi 4G63 Cam 34", "INVALID", "Subaru 7+6", "Jeep 18-2-2-2", "12 tooth crank", "Dodge Neon 1995 crank only", "Jeep XJ 4 cyl", "FiatIAQ_P8", "Mazda Z5", "INVALID", "Renix 44-2-2", "Renix 66-2-2-2", "Honda K 12+1", "INVALID", "36/2", "Subaru SVX", "1+16", "Subaru 7 without 6", "INVALID", "TriTach", "GM 60/2/2/2", "Skoda Favorit", "Barra 3+1 Cam", "Kawa KX450F", "Nissan VQ35", "INVALID", "Nissan VQ30", "Nissan QR25", "INVALID", "Subaru SVX Crank 1", "Subaru SVX Cam VVT", "Ford PIP", "Suzuki G13B", "Honda K 4+1", "Nissan MR18 Crank", "32/2", "36-2-1", "36-2-1-1", "3/0", "INVALID", "GM 24x 3 degree", "60-2-2 F3R", "Mitsu 4G63 Crank", "x2 30 Deg camshaft BTDC", "INVALID", "Mitsu 6G72 Cam", "6/0", "trg81", "trg82", "trg83"
#define trigger_type_e_enum "custom toothed wheel", "Ford Aspire", "Dodge Neon 1995", "Miata NA", "INVALID", "GM_7X", "Daihatsu 3 cylinder", "Mazda SOHC 4", "60/2", "36/1", "Mercedes Two Segment", "Single Tooth", "EZ30", "INVALID", "Dodge Neon 2003", "Mazda DOHC 1+4", "1+1", "INVALID", "Half Moon", "Dodge Ram 1+16", "60/2 VW", "Benelli Tre", "Dodge Stratus", "36_2_2_2", "Nissan Primera", "dev 2JZ 3/34 simulator", "Rover K", "GM 24x 5 degree", "Honda CBR 600 Cam", "Mitsubishi 4G92/93/94 Cam 29", "Honda CBR 600 custom", "3/1 skipped", "Dodge Neon 2003 crank", "Miata NB", "Mitsubishi 4G63 Cam 34", "INVALID", "Subaru 7+6", "Jeep 18-2-2-2", "12 tooth crank", "Dodge Neon 1995 crank only", "Jeep XJ 4 cyl", "FiatIAQ_P8", "Mazda Z5", "INVALID", "Renix 44-2-2", "Renix 66-2-2-2", "Honda K 12+1", "INVALID", "36/2", "Subaru SVX", "1+16", "Subaru 7 without 6", "INVALID", "TriTach", "GM 60/2/2/2", "Skoda Favorit", "Barra 3+1 Cam", "Kawa KX450F", "Nissan VQ35", "INVALID", "Nissan VQ30", "Nissan QR25", "INVALID", "Subaru SVX Crank 1", "Subaru SVX Cam VVT", "Ford PIP", "Suzuki G13B", "Honda K 4+1", "Nissan MR18 Crank", "32/2", "36-2-1", "36-2-1-1", "3/0", "INVALID", "GM 24x 3 degree", "60-2-2 F3R", "Mitsu 4G63 Crank", "x2 30 Deg camshaft BTDC", "INVALID", "Mitsu 6G72 Cam", "6/0", "Daihatsu 4 cylinder", "trg82", "trg83"
custom trigger_type_e 4 bits, U32, @OFFSET@, [0:6], @@trigger_type_e_enum@@
trigger_type_e type;https://github.com/rusefi/rusefi/wiki/All-Supported-Triggers\nset trigger_type X