only:hellen154hyundai
This commit is contained in:
rusefillc 2024-04-12 13:27:05 -04:00
parent 1a08a8fa5b
commit 116838b4d4
1 changed files with 5 additions and 4 deletions

View File

@ -52,8 +52,10 @@ bool boardEnableSendWidebandInfo() {
return getHellenBoardEnabled();
}
static bool hellenEnPinInitialized = false;
bool fansDisabledByBoardStatus() {
return !getHellenBoardEnabled();
return hellenEnPinInitialized && !getHellenBoardEnabled();
}
void hellenEnableEn() {
@ -65,9 +67,8 @@ void hellenDisableEn() {
}
void setHellenEnPin(Gpio pin, bool enableBoardOnStartUp) {
static bool initialized = false;
if (!initialized) {
initialized = true;
if (!hellenEnPinInitialized) {
hellenEnPinInitialized = true;
megaEn.initPin("EN", pin);
if (enableBoardOnStartUp) {
hellenEnableEn();