auto-sync
This commit is contained in:
parent
1181fa4fc0
commit
822ff72a0c
|
@ -64,13 +64,22 @@ EngineTestHelper::EngineTestHelper(engine_type_e engineType) : engine (&persiste
|
||||||
engine->triggerCentral.addEventListener(mainTriggerCallback, "main loop", engine);
|
engine->triggerCentral.addEventListener(mainTriggerCallback, "main loop", engine);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void EngineTestHelper::firePrimaryTriggerRise() {
|
||||||
|
board_configuration_s * boardConfiguration = &engine.engineConfiguration->bc;
|
||||||
|
engine.triggerCentral.handleShaftSignal(SHAFT_PRIMARY_RISING, &engine, engine.engineConfiguration, &persistentConfig, boardConfiguration);
|
||||||
|
}
|
||||||
|
|
||||||
|
void EngineTestHelper::firePrimaryTriggerFall() {
|
||||||
|
board_configuration_s * boardConfiguration = &engine.engineConfiguration->bc;
|
||||||
|
engine.triggerCentral.handleShaftSignal(SHAFT_PRIMARY_FALLING, &engine, engine.engineConfiguration, &persistentConfig, boardConfiguration);
|
||||||
|
}
|
||||||
|
|
||||||
void EngineTestHelper::fireTriggerEvents2(int count, int duration) {
|
void EngineTestHelper::fireTriggerEvents2(int count, int duration) {
|
||||||
for (int i = 0; i < count; i++) {
|
for (int i = 0; i < count; i++) {
|
||||||
timeNow += duration;
|
timeNow += duration;
|
||||||
board_configuration_s * boardConfiguration = &engine.engineConfiguration->bc;
|
firePrimaryTriggerRise();
|
||||||
engine.triggerCentral.handleShaftSignal(SHAFT_PRIMARY_RISING, &engine, engine.engineConfiguration, &persistentConfig, boardConfiguration);
|
|
||||||
timeNow += duration;
|
timeNow += duration;
|
||||||
engine.triggerCentral.handleShaftSignal(SHAFT_PRIMARY_FALLING, &engine, engine.engineConfiguration, &persistentConfig, boardConfiguration);
|
firePrimaryTriggerFall();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -16,6 +16,8 @@ class EngineTestHelper {
|
||||||
public:
|
public:
|
||||||
EngineTestHelper(engine_type_e engineType);
|
EngineTestHelper(engine_type_e engineType);
|
||||||
void applyTriggerShape();
|
void applyTriggerShape();
|
||||||
|
void firePrimaryTriggerRise();
|
||||||
|
void firePrimaryTriggerFall();
|
||||||
void fireTriggerEvents(int count);
|
void fireTriggerEvents(int count);
|
||||||
void fireTriggerEvents2(int count, int duration);
|
void fireTriggerEvents2(int count, int duration);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue