|
| void | nullCallback (void) |
| | A scheduler callback that does nothing.
|
| |
| void | setCallbacks (Schedule &schedule, Schedule::callback pStartCallback, Schedule::callback pEndCallback) noexcept |
| | Set the schedule callbacks. I.e the functions called when the action needs to start & stop.
|
| |
| static uint16_t | clipDuration (uint16_t duration) |
| |
| static void | setScheduleNext (Schedule &schedule, uint32_t delay, uint16_t duration) noexcept |
| |
| static void | setScheduleRunning (Schedule &schedule, uint32_t delay, uint16_t duration) noexcept |
| |
| void | setSchedule (Schedule &schedule, uint32_t delay, uint16_t duration, bool allowQueuedSchedule) |
| | Set the schedule action to run for a certain duration in the future.
|
| |
| void | moveToNextState (FuelSchedule &schedule) noexcept |
| | Shared fuel schedule timer ISR implementation. Should be called by the actual timer ISRs (as timed interrupts) when either the start time or the duration time are reached. See Schedule finite state machine.
|
| |
| template<typename T > |
| static void | increment_volatile (volatile T &value) |
| | Increment a volatile variable correctly.
|
| |
| static void | onEndIgnitionEvent (const IgnitionSchedule *pSchedule) |
| | Called when an ignition event ends. I.e. a spark fires.
|
| |
| | BEGIN_LTO_ALWAYS_INLINE (void) static ignitionPendingToRunning(Schedule *pSchedule) |
| | Called when the supplied schedule transitions from a PENDING state to RUNNING.
|
| |
| void | moveToNextState (IgnitionSchedule &schedule) noexcept |
| | Shared ignition schedule timer ISR implementation. Should be called by the actual ignition timer ISRs (as timed interrupts) when either the start time or the duration time are reached. See Schedule finite state machine.
|
| |
| void | adjustCrankAngle (const statuses ¤t, IgnitionSchedule &schedule, int16_t crankAngle) |
| | Adjust the crank angle used to originally set the schedule.
|
| |
Injector and Ignition (on/off) scheduling (functions). There is usually 8 functions for cylinders 1-8 with same naming pattern.
Scheduling structures
Structures FuelSchedule and Schedule describe (from scheduler.h) describe the scheduling info for Fuel and Ignition respectively. They contain duration, current activity status, start timing, end timing, callbacks to carry out action, etc.
Scheduling Functions
For Injection:
- setFuelSchedule*(tout,dur) - Setup schedule for (next) injection on the channel
- inj*StartFunction() - Execute start of injection (Interrupt handler)
- inj*EndFunction() - Execute end of injection (interrupt handler)
For Ignition (has more complex schedule setup):
- setIgnitionSchedule*(cb_st,tout,dur,cb_end) - Setup schedule for (next) ignition on the channel
- ign*StartFunction() - Execute start of ignition (Interrupt handler)
- ign*EndFunction() - Execute end of ignition (Interrupt handler)