docs & refactoring
This commit is contained in:
parent
d1da567b85
commit
5e48109780
|
@ -2,9 +2,13 @@
|
|||
* @file GY6_139QMB.cpp
|
||||
* @brief 139qmb default engine configuration
|
||||
*
|
||||
* 4-stroke one cylinder
|
||||
*
|
||||
* set engine_type 8
|
||||
*
|
||||
* @date Feb 13, 2014
|
||||
* @author rus084, (c) 2015
|
||||
* @author Andrey Belomutskiy, (c) 2012-2018
|
||||
* @author Andrey Belomutskiy, (c) 2012-2019
|
||||
*/
|
||||
|
||||
#include "global.h"
|
||||
|
@ -102,4 +106,6 @@ void setGy6139qmbDefaultEngineConfiguration(DECLARE_CONFIG_PARAMETER_SIGNATURE)
|
|||
boardConfiguration->injectionPins[0] = GPIOC_9;
|
||||
boardConfiguration->ignitionPins[0] = GPIOC_8;
|
||||
|
||||
// set injection_mode 1
|
||||
engineConfiguration->injectionMode = IM_SEQUENTIAL;
|
||||
}
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
/*
|
||||
* @file GY6_139QMB.h
|
||||
*
|
||||
* @date 13 feb 2014 y.
|
||||
* @date 13 Feb 2014
|
||||
* @author rus084
|
||||
* @author Andrey Belomutskiy, (c) 2012-2017
|
||||
* @author Andrey Belomutskiy, (c) 2012-2019
|
||||
*/
|
||||
|
||||
#ifndef GY6_139QMB_H_
|
||||
|
|
|
@ -86,7 +86,7 @@ EngineTestHelper::EngineTestHelper(engine_type_e engineType) : EngineTestHelper(
|
|||
/**
|
||||
* mock a change of time and fire single RISE front event
|
||||
*/
|
||||
void EngineTestHelper::fireRise(int delayMs) {
|
||||
void EngineTestHelper::fireRise(float delayMs) {
|
||||
moveTimeForwardUs(MS2US(delayMs));
|
||||
firePrimaryTriggerRise();
|
||||
}
|
||||
|
@ -99,7 +99,7 @@ void EngineTestHelper::firePrimaryTriggerRise() {
|
|||
engine.triggerCentral.handleShaftSignal(SHAFT_PRIMARY_RISING, &engine, engine.engineConfigurationPtr, &persistentConfig, boardConfiguration);
|
||||
}
|
||||
|
||||
void EngineTestHelper::fireFall(int delayMs) {
|
||||
void EngineTestHelper::fireFall(float delayMs) {
|
||||
moveTimeForwardUs(MS2US(delayMs));
|
||||
firePrimaryTriggerFall();
|
||||
}
|
||||
|
@ -109,7 +109,7 @@ void EngineTestHelper::firePrimaryTriggerFall() {
|
|||
engine.triggerCentral.handleShaftSignal(SHAFT_PRIMARY_FALLING, &engine, engine.engineConfigurationPtr, &persistentConfig, boardConfiguration);
|
||||
}
|
||||
|
||||
void EngineTestHelper::fireTriggerEventsWithDuration(int durationMs) {
|
||||
void EngineTestHelper::fireTriggerEventsWithDuration(float durationMs) {
|
||||
fireTriggerEvents2(/*count*/1, durationMs);
|
||||
}
|
||||
|
||||
|
@ -118,7 +118,7 @@ void EngineTestHelper::fireTriggerEventsWithDuration(int durationMs) {
|
|||
*
|
||||
* This is helpful for TT_ONE trigger wheel decoder and probably other decoders as well.
|
||||
*/
|
||||
void EngineTestHelper::fireTriggerEvents2(int count, int durationMs) {
|
||||
void EngineTestHelper::fireTriggerEvents2(int count, float durationMs) {
|
||||
for (int i = 0; i < count; i++) {
|
||||
fireRise(durationMs);
|
||||
fireFall(durationMs);
|
||||
|
|
|
@ -30,8 +30,8 @@ public:
|
|||
EngineTestHelper(engine_type_e engineType, configuration_callback_t boardCallback);
|
||||
void applyTriggerShape();
|
||||
void setTriggerType(trigger_type_e trigger DECLARE_ENGINE_PARAMETER_SUFFIX);
|
||||
void fireRise(int delayMs);
|
||||
void fireFall(int delayMs);
|
||||
void fireRise(float delayMs);
|
||||
void fireFall(float delayMs);
|
||||
|
||||
/**
|
||||
* See also #fireRise() which would also move time forward
|
||||
|
@ -42,8 +42,8 @@ public:
|
|||
*/
|
||||
void firePrimaryTriggerFall();
|
||||
void fireTriggerEvents(int count);
|
||||
void fireTriggerEventsWithDuration(int delayMs);
|
||||
void fireTriggerEvents2(int count, int delayMs);
|
||||
void fireTriggerEventsWithDuration(float delayMs);
|
||||
void fireTriggerEvents2(int count, float delayMs);
|
||||
void clearQueue();
|
||||
|
||||
scheduling_s * assertEvent5(TestExecutor *executor, const char *msg, int index, void *callback, efitime_t start, efitime_t momentX);
|
||||
|
|
Loading…
Reference in New Issue