auto-sync
This commit is contained in:
parent
7a2606450d
commit
1de0d3bfcb
|
@ -308,9 +308,9 @@ static void showFuelMap2(float rpm, float engineLoad) {
|
||||||
|
|
||||||
scheduleMsg(&logger2, "algo=%s", algorithmToString(engineConfiguration->algorithm));
|
scheduleMsg(&logger2, "algo=%s", algorithmToString(engineConfiguration->algorithm));
|
||||||
|
|
||||||
if (isCrankingR(rpm)) {
|
|
||||||
scheduleMsg(&logger2, "cranking fuel: %f", getCrankingFuel());
|
scheduleMsg(&logger2, "cranking fuel: %f", getCrankingFuel());
|
||||||
} else {
|
|
||||||
|
if (engine.rpmCalculator->isRunning()) {
|
||||||
float iatCorrection = getIatCorrection(getIntakeAirTemperature());
|
float iatCorrection = getIatCorrection(getIntakeAirTemperature());
|
||||||
float cltCorrection = getCltCorrection(getCoolantTemperature());
|
float cltCorrection = getCltCorrection(getCoolantTemperature());
|
||||||
float injectorLag = getInjectorLag(getVBatt());
|
float injectorLag = getInjectorLag(getVBatt());
|
||||||
|
|
|
@ -51,10 +51,10 @@ static void maThread(int param) {
|
||||||
chThdSleepMilliseconds(100);
|
chThdSleepMilliseconds(100);
|
||||||
|
|
||||||
systime_t now = chTimeNow();
|
systime_t now = chTimeNow();
|
||||||
if (!isRunning()) {
|
//todo? if (!isRunning()) {
|
||||||
timeAtNotRunning = now;
|
// timeAtNotRunning = now;
|
||||||
continue;
|
// continue;
|
||||||
}
|
// }
|
||||||
|
|
||||||
int wasNotRunningRecently = overflowDiff(now, timeAtNotRunning) < 60 * CH_FREQUENCY;
|
int wasNotRunningRecently = overflowDiff(now, timeAtNotRunning) < 60 * CH_FREQUENCY;
|
||||||
if (!wasNotRunningRecently)
|
if (!wasNotRunningRecently)
|
||||||
|
|
|
@ -59,10 +59,6 @@ uint64_t getLastRpmEventTime(void);
|
||||||
|
|
||||||
int getRevolutionCounter(void);
|
int getRevolutionCounter(void);
|
||||||
float getCrankshaftAngle(uint64_t timeUs);
|
float getCrankshaftAngle(uint64_t timeUs);
|
||||||
/**
|
|
||||||
* @return true if engine is running
|
|
||||||
*/
|
|
||||||
bool isRunning(void);
|
|
||||||
bool isValidRpm(int rpm);
|
bool isValidRpm(int rpm);
|
||||||
void addWaveChartEvent(const char *name, const char *msg, const char *msg2);
|
void addWaveChartEvent(const char *name, const char *msg, const char *msg2);
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue