rusEFI
The most advanced open source ECU
|
Variables | |
bool | verboseMode |
bool | printFuelDebug |
static const char * | prevSparkName = nullptr |
|
static |
Definition at line 52 of file spark_logic.cpp.
Referenced by prepareCylinderIgnitionSchedule().
|
static |
Definition at line 162 of file spark_logic.cpp.
void fireSparkAndPrepareNextSchedule | ( | IgnitionEvent * | event | ) |
TL,DR: each IgnitionEvent is in charge of it's own scheduling forever, we plant next event while finishing handling of the current one
ratio of desired dwell duration to actual dwell duration gives us some idea of how good is input trigger jitter
Definition at line 187 of file spark_logic.cpp.
Referenced by overFireSparkAndPrepareNextSchedule(), and scheduleSparkEvent().
|
static |
there are two kinds of 'out-of-order' 1) low goes before high, everything is fine afterwards
2) we have an un-matched low followed by legit pairs
Definition at line 29 of file spark_logic.cpp.
Referenced by fireSparkAndPrepareNextSchedule().
|
static |
Definition at line 169 of file spark_logic.cpp.
percent_t getCoilDutyCycle | ( | int | rpm | ) |
Definition at line 635 of file spark_logic.cpp.
Referenced by populateFrame(), and updateIgnition().
|
static |
cylinderIndex | from 0 to cylinderCount, not cylinder number |
Definition at line 61 of file spark_logic.cpp.
Referenced by prepareCylinderIgnitionSchedule().
int getNumberOfSparks | ( | ignition_mode_e | mode | ) |
Number of sparks per physical coil
Definition at line 616 of file spark_logic.cpp.
Referenced by getCoilDutyCycle().
void initializeIgnitionActions | ( | ) |
Definition at line 491 of file spark_logic.cpp.
Referenced by prepareIgnitionSchedule().
void onTriggerEventSparkLogic | ( | int | rpm, |
efitick_t | edgeTimestamp, | ||
float | currentPhase, | ||
float | nextPhase | ||
) |
Ignition schedule is defined once per revolution See initializeIgnitionActions()
Definition at line 539 of file spark_logic.cpp.
Referenced by mainTriggerCallback().
|
static |
Definition at line 176 of file spark_logic.cpp.
|
static |
Definition at line 83 of file spark_logic.cpp.
Referenced by fireSparkAndPrepareNextSchedule(), and initializeIgnitionActions().
|
static |
TODO: warning. there is a bit of a hack here, todo: improve. currently output signals/times dwellStartTimer from the previous revolutions could be still used because they have crossed the revolution boundary but we are already re-purposing the output signals, but everything works because we are not affecting that space in memory. todo: use two instances of 'ignitionSignals'
Definition at line 510 of file spark_logic.cpp.
Referenced by onTriggerEventSparkLogic().
|
static |
By the way 32-bit value should hold at least 400 hours of events at 6K RPM x 12 events per revolution
The start of charge is always within the current trigger event range, so just plain time-based scheduling
Note how we do not check if spark is limited or not while scheduling 'spark down' This way we make sure that coil dwell started while spark was enabled would fire and not burn the coil.
Spark event is often happening during a later trigger event timeframe
todo one: explicit unit test for this mechanism see https://github.com/rusefi/rusefi/issues/6373 todo two: can we please comprehend/document how this even works? we seem to be reusing 'sparkEvent.scheduling' instance and it looks like current (smart?) re-queuing is effectively cancelling out the overdwell? is that the way this was intended to work?
Definition at line 374 of file spark_logic.cpp.
Referenced by onTriggerEventSparkLogic().
|
static |
fact: we schedule both start of dwell and spark firing using a combination of time and trigger event domain in case of bad/noisy signal we can get unexpected trigger events and a small time delay for spark firing before we even start dwell if it scheduled with a longer time-only delay with fewer trigger events
here we are detecting such out-of-order processing and choose the safer route of not even starting dwell [tag] #6349
Definition at line 281 of file spark_logic.cpp.
Referenced by turnSparkPinHighStartCharging().
void turnSparkPinHighStartCharging | ( | IgnitionEvent * | event | ) |
Definition at line 322 of file spark_logic.cpp.
|
static |
Definition at line 27 of file spark_logic.cpp.
Referenced by startDwellByTurningSparkPinHigh().
|
extern |
Definition at line 27 of file main_trigger_callback.cpp.
Referenced by prepareCylinderIgnitionSchedule().
|
extern |