|
@ -995,32 +995,28 @@ void setup() { |
|
|
ui.show_bootscreen(); |
|
|
ui.show_bootscreen(); |
|
|
#endif |
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
ui.reset_status(); // Load welcome message early. (Retained if no errors exist.)
|
|
|
|
|
|
|
|
|
#if ENABLED(SDSUPPORT) |
|
|
#if ENABLED(SDSUPPORT) |
|
|
card.mount(); // Mount the SD card before settings.first_load
|
|
|
card.mount(); // Mount the SD card before settings.first_load
|
|
|
#endif |
|
|
#endif |
|
|
|
|
|
// Load data from EEPROM if available (or use defaults)
|
|
|
// Load data from EEPROM if available (or use defaults)
|
|
|
settings.first_load(); // This also updates variables in the planner, elsewhere
|
|
|
// This also updates variables in the planner, elsewhere
|
|
|
|
|
|
settings.first_load(); |
|
|
|
|
|
|
|
|
|
|
|
#if ENABLED(TOUCH_BUTTONS) |
|
|
#if ENABLED(TOUCH_BUTTONS) |
|
|
touch.init(); |
|
|
touch.init(); |
|
|
#endif |
|
|
#endif |
|
|
|
|
|
|
|
|
#if HAS_M206_COMMAND |
|
|
#if HAS_M206_COMMAND // Initialize current position based on home_offset
|
|
|
// Initialize current position based on home_offset
|
|
|
|
|
|
current_position += home_offset; |
|
|
current_position += home_offset; |
|
|
#endif |
|
|
#endif |
|
|
|
|
|
|
|
|
// Vital to init stepper/planner equivalent for current_position
|
|
|
sync_plan_position(); // Vital to init stepper/planner equivalent for current_position
|
|
|
sync_plan_position(); |
|
|
|
|
|
|
|
|
|
|
|
thermalManager.init(); // Initialize temperature loop
|
|
|
thermalManager.init(); // Initialize temperature loop
|
|
|
|
|
|
|
|
|
print_job_timer.init(); // Initial setup of print job timer
|
|
|
print_job_timer.init(); // Initial setup of print job timer
|
|
|
|
|
|
|
|
|
ui.reset_status(); // Print startup message after print statistics are loaded
|
|
|
|
|
|
|
|
|
|
|
|
endstops.init(); // Init endstops and pullups
|
|
|
endstops.init(); // Init endstops and pullups
|
|
|
|
|
|
|
|
|
stepper.init(); // Init stepper. This enables interrupts!
|
|
|
stepper.init(); // Init stepper. This enables interrupts!
|
|
@ -1175,6 +1171,10 @@ void setup() { |
|
|
#if ENABLED(PRUSA_MMU2) |
|
|
#if ENABLED(PRUSA_MMU2) |
|
|
mmu2.init(); |
|
|
mmu2.init(); |
|
|
#endif |
|
|
#endif |
|
|
|
|
|
|
|
|
|
|
|
#if HAS_SERVICE_INTERVALS |
|
|
|
|
|
ui.reset_status(true); // Show service messages or keep current status
|
|
|
|
|
|
#endif |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
/**
|
|
|
/**
|
|
|