mirror of https://github.com/rusefi/rusefi.git
only:hellen154hyundai
This commit is contained in:
parent
1a08a8fa5b
commit
116838b4d4
|
@ -52,8 +52,10 @@ bool boardEnableSendWidebandInfo() {
|
||||||
return getHellenBoardEnabled();
|
return getHellenBoardEnabled();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static bool hellenEnPinInitialized = false;
|
||||||
|
|
||||||
bool fansDisabledByBoardStatus() {
|
bool fansDisabledByBoardStatus() {
|
||||||
return !getHellenBoardEnabled();
|
return hellenEnPinInitialized && !getHellenBoardEnabled();
|
||||||
}
|
}
|
||||||
|
|
||||||
void hellenEnableEn() {
|
void hellenEnableEn() {
|
||||||
|
@ -65,9 +67,8 @@ void hellenDisableEn() {
|
||||||
}
|
}
|
||||||
|
|
||||||
void setHellenEnPin(Gpio pin, bool enableBoardOnStartUp) {
|
void setHellenEnPin(Gpio pin, bool enableBoardOnStartUp) {
|
||||||
static bool initialized = false;
|
if (!hellenEnPinInitialized) {
|
||||||
if (!initialized) {
|
hellenEnPinInitialized = true;
|
||||||
initialized = true;
|
|
||||||
megaEn.initPin("EN", pin);
|
megaEn.initPin("EN", pin);
|
||||||
if (enableBoardOnStartUp) {
|
if (enableBoardOnStartUp) {
|
||||||
hellenEnableEn();
|
hellenEnableEn();
|
||||||
|
|
Loading…
Reference in New Issue