only: unique variable name so that nice IDE would not be needed

This commit is contained in:
Andrey 2024-05-10 23:08:11 -04:00
parent 9fd4e930d3
commit 6eaf9b117d
5 changed files with 11 additions and 11 deletions

View File

@ -14,7 +14,7 @@
#include "trigger_structure.h"
struct AngleBasedEvent {
scheduling_s scheduling;
scheduling_s eventScheduling;
action_s action;
/**
* Trigger-based scheduler maintains a linked list of all pending tooth-based events.

View File

@ -195,8 +195,8 @@ void HpfpController::pinTurnOn(HpfpController *self) {
// By scheduling the close after we already open, we don't have to worry if the engine
// stops, the valve will be turned off in a certain amount of time regardless.
scheduleByAngle(&self->m_event.scheduling,
self->m_event.scheduling.getMomentNt(),
scheduleByAngle(&self->m_event.eventScheduling,
self->m_event.eventScheduling.getMomentNt(),
self->m_deadtime + engineConfiguration->hpfpActivationAngle,
{ pinTurnOff, self });
}

View File

@ -257,7 +257,7 @@ if (engineConfiguration->debugMode == DBG_DWELL_METRIC) {
// We can schedule both of these right away, since we're going for "asap" not "particular angle"
engine->executor.scheduleByTimestampNt("dwell", &event->dwellStartTimer, nextDwellStart, { &turnSparkPinHighStartCharging, event });
engine->executor.scheduleByTimestampNt("firing", &event->sparkEvent.scheduling, nextFiring, { fireSparkAndPrepareNextSchedule, event });
engine->executor.scheduleByTimestampNt("firing", &event->sparkEvent.eventScheduling, nextFiring, { fireSparkAndPrepareNextSchedule, event });
} else {
if (engineConfiguration->enableTrailingSparks) {
#if SPARK_EXTREME_LOGGING
@ -469,7 +469,7 @@ static void scheduleSparkEvent(bool limitedSpark, IgnitionEvent *event,
* and it looks like current (smart?) re-queuing is effectively cancelling out the overdwell? is that the way this was intended to work?
* [tag:overdwell]
*/
engine->executor.scheduleByTimestampNt("overdwell", &event->sparkEvent.scheduling, fireTime, { overFireSparkAndPrepareNextSchedule, event });
engine->executor.scheduleByTimestampNt("overdwell", &event->sparkEvent.eventScheduling, fireTime, { overFireSparkAndPrepareNextSchedule, event });
#if EFI_UNIT_TEST
engine->onScheduleOverFireSparkAndPrepareNextSchedule(*event, fireTime);

View File

@ -29,7 +29,7 @@ bool TriggerScheduler::scheduleOrQueue(const char *msg, AngleBasedEvent *event,
if (event->shouldSchedule(currentPhase, nextPhase)) {
// if we're due now, just schedule the event
scheduleByAngle(
&event->scheduling,
&event->eventScheduling,
edgeTimestamp,
event->getAngleFromNow(currentPhase),
action
@ -99,7 +99,7 @@ void TriggerScheduler::scheduleEventsUntilNextTriggerTooth(int rpm,
// one also fired and thus the call to LL_DELETE2 is closer to O(1).
LL_DELETE2(keephead, current, nextToothEvent);
scheduling_s * sDown = &current->scheduling;
scheduling_s * sDown = &current->eventScheduling;
#if SPARK_EXTREME_LOGGING
efiPrintf("time to invoke [%.1f, %.1f) %d %d",

View File

@ -262,13 +262,13 @@ TEST(HPFP, Schedule) {
// First call to setRpmValue will cause a dummy call to fast periodic timer.
// Injection Mass will be 0 so expect a no-op.
EXPECT_CALL(mockExec, scheduleByTimestampNt(testing::NotNull(), &hpfp.m_event.scheduling, nt0, action_s(HpfpController::pinTurnOff, &hpfp)));
EXPECT_CALL(mockExec, scheduleByTimestampNt(testing::NotNull(), &hpfp.m_event.eventScheduling, nt0, action_s(HpfpController::pinTurnOff, &hpfp)));
// Second call will be the start of a real pump event.
EXPECT_CALL(mockExec, scheduleByTimestampNt(testing::NotNull(), &hpfp.m_event.scheduling, nt1, action_s(HpfpController::pinTurnOn, &hpfp)));
EXPECT_CALL(mockExec, scheduleByTimestampNt(testing::NotNull(), &hpfp.m_event.eventScheduling, nt1, action_s(HpfpController::pinTurnOn, &hpfp)));
// Third call will be off event
EXPECT_CALL(mockExec, scheduleByTimestampNt(testing::NotNull(), &hpfp.m_event.scheduling, nt2, action_s(HpfpController::pinTurnOff, &hpfp)));
EXPECT_CALL(mockExec, scheduleByTimestampNt(testing::NotNull(), &hpfp.m_event.eventScheduling, nt2, action_s(HpfpController::pinTurnOff, &hpfp)));
}
EXPECT_CALL(mockExec, cancel(_)).Times(2);
@ -299,7 +299,7 @@ TEST(HPFP, Schedule) {
// Since we have a mock scheduler, lets insert the correct timestamp in the scheduling
// struct.
hpfp.m_event.scheduling.setMomentNt(nt1);
hpfp.m_event.eventScheduling.setMomentNt(nt1);
HpfpController::pinTurnOn(&hpfp);