diff --git a/Marlin/power.cpp b/Marlin/power.cpp index 6eac58db2..dbe2ff1dc 100644 --- a/Marlin/power.cpp +++ b/Marlin/power.cpp @@ -86,16 +86,18 @@ void Power::check() { void Power::power_on() { lastPowerOn = millis(); - PSU_PIN_ON(); + if (!powersupply_on) { + PSU_PIN_ON(); - #if HAS_TRINAMIC - delay(100); // Wait for power to settle - restore_stepper_drivers(); - #endif + #if HAS_TRINAMIC + delay(100); // Wait for power to settle + restore_stepper_drivers(); + #endif + } } void Power::power_off() { - PSU_PIN_OFF(); + if (powersupply_on) PSU_PIN_OFF(); } #endif // AUTO_POWER_CONTROL diff --git a/Marlin/ultralcd.cpp b/Marlin/ultralcd.cpp index b0b833d0c..2651d6c6f 100644 --- a/Marlin/ultralcd.cpp +++ b/Marlin/ultralcd.cpp @@ -168,10 +168,6 @@ uint16_t max_display_update_time = 0; #define TALL_FONT_CORRECTION 0 #endif - #if HAS_POWER_SWITCH - extern bool powersupply_on; - #endif - bool no_reentry = false; constexpr int8_t menu_bottom = LCD_HEIGHT - (TALL_FONT_CORRECTION);