|
@@ -4757,11 +4757,13 @@ void CrealityDWINClass::Start_Print(bool sd) {
|
4757
|
4757
|
printing = true;
|
4758
|
4758
|
statusmsg[0] = '\0';
|
4759
|
4759
|
if (sd) {
|
4760
|
|
- if (recovery.valid()) {
|
4761
|
|
- SdFile *diveDir = nullptr;
|
4762
|
|
- const char * const fname = card.diveToFile(true, diveDir, recovery.info.sd_filename);
|
4763
|
|
- card.selectFileByName(fname);
|
4764
|
|
- }
|
|
4760
|
+ #if ENABLED(POWER_LOSS_RECOVERY)
|
|
4761
|
+ if (recovery.valid()) {
|
|
4762
|
+ SdFile *diveDir = nullptr;
|
|
4763
|
+ const char * const fname = card.diveToFile(true, diveDir, recovery.info.sd_filename);
|
|
4764
|
+ card.selectFileByName(fname);
|
|
4765
|
+ }
|
|
4766
|
+ #endif
|
4765
|
4767
|
strcpy_P(filename, card.longest_filename());
|
4766
|
4768
|
}
|
4767
|
4769
|
else
|
|
@@ -4801,7 +4803,7 @@ void MarlinUI::update() { CrealityDWIN.Update(); }
|
4801
|
4803
|
|
4802
|
4804
|
void CrealityDWINClass::State_Update() {
|
4803
|
4805
|
if ((print_job_timer.isRunning() || print_job_timer.isPaused()) != printing) {
|
4804
|
|
- if (!printing) Start_Print((card.isFileOpen() || recovery.valid()));
|
|
4806
|
+ if (!printing) Start_Print(card.isFileOpen() || TERN0(POWER_LOSS_RECOVERY, recovery.valid()));
|
4805
|
4807
|
else Stop_Print();
|
4806
|
4808
|
}
|
4807
|
4809
|
if (print_job_timer.isPaused() != paused) {
|