Fix PSU pin initialization
This commit is contained in:
parent
369d756b74
commit
31c473eadb
1 changed files with 3 additions and 9 deletions
|
@ -601,13 +601,7 @@ uint8_t target_extruder;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if HAS_POWER_SWITCH
|
#if HAS_POWER_SWITCH
|
||||||
bool powersupply_on = (
|
bool powersupply_on;
|
||||||
#if ENABLED(PS_DEFAULT_OFF)
|
|
||||||
false
|
|
||||||
#else
|
|
||||||
true
|
|
||||||
#endif
|
|
||||||
);
|
|
||||||
#if ENABLED(AUTO_POWER_CONTROL)
|
#if ENABLED(AUTO_POWER_CONTROL)
|
||||||
#define PSU_ON() powerManager.power_on()
|
#define PSU_ON() powerManager.power_on()
|
||||||
#define PSU_OFF() powerManager.power_off()
|
#define PSU_OFF() powerManager.power_off()
|
||||||
|
@ -943,9 +937,9 @@ void setup_powerhold() {
|
||||||
#endif
|
#endif
|
||||||
#if HAS_POWER_SWITCH
|
#if HAS_POWER_SWITCH
|
||||||
#if ENABLED(PS_DEFAULT_OFF)
|
#if ENABLED(PS_DEFAULT_OFF)
|
||||||
PSU_OFF();
|
powersupply_on = true; PSU_OFF();
|
||||||
#else
|
#else
|
||||||
PSU_ON();
|
powersupply_on = false; PSU_ON();
|
||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue