mirror of https://github.com/rusefi/rusefi-1.git
TLE8888 should be re-initialized every time we get +12 volts #901
extremely ugly solution but it it works at least with LED blinking test
This commit is contained in:
parent
51902c12c5
commit
f858b26a50
|
@ -128,6 +128,10 @@ void Engine::periodicSlowCallback(DECLARE_ENGINE_PARAMETER_SIGNATURE) {
|
|||
}
|
||||
|
||||
|
||||
#if (BOARD_TLE8888_COUNT > 0)
|
||||
extern float vBattForTle8888;
|
||||
#endif /* BOARD_TLE8888_COUNT */
|
||||
|
||||
/**
|
||||
* We are executing these heavy (logarithm) methods from outside the trigger callbacks for performance reasons.
|
||||
* See also periodicFastCallback
|
||||
|
@ -149,6 +153,11 @@ void Engine::updateSlowSensors(DECLARE_ENGINE_PARAMETER_SIGNATURE) {
|
|||
}
|
||||
sensors.vBatt = hasVBatt(PASS_ENGINE_PARAMETER_SIGNATURE) ? getVBatt(PASS_ENGINE_PARAMETER_SIGNATURE) : 12;
|
||||
|
||||
#if (BOARD_TLE8888_COUNT > 0)
|
||||
// nasty value injection into C driver which would not be able to access Engine class
|
||||
vBattForTle8888 = sensors.vBatt;
|
||||
#endif /* BOARD_TLE8888_COUNT */
|
||||
|
||||
engineState.injectorLag = getInjectorLag(sensors.vBatt PASS_ENGINE_PARAMETER_SUFFIX);
|
||||
#endif
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue