Browse Source

Pause the print job timer while in M600

Scott Lahteine 8 years ago
parent
commit
4578c573fe
1 changed files with 8 additions and 0 deletions
  1. 8
    0
      Marlin/Marlin_main.cpp

+ 8
- 0
Marlin/Marlin_main.cpp View File

@@ -7328,6 +7328,10 @@ inline void gcode_M503() {
7328 7328
 
7329 7329
     busy_doing_M600 = true;  // Stepper Motors can't timeout when this is set
7330 7330
 
7331
+    // Pause the print job timer
7332
+    bool job_running = print_job_timer.isRunning();
7333
+    print_job_timer.pause();
7334
+
7331 7335
     // Show initial message and wait for synchronize steppers
7332 7336
     lcd_filament_change_show_message(FILAMENT_CHANGE_MESSAGE_INIT);
7333 7337
     stepper.synchronize();
@@ -7518,6 +7522,10 @@ inline void gcode_M503() {
7518 7522
 
7519 7523
     // Show status screen
7520 7524
     lcd_filament_change_show_message(FILAMENT_CHANGE_MESSAGE_STATUS);
7525
+
7526
+    // Resume the print job timer if it was running
7527
+    if (job_running) print_job_timer.start();
7528
+
7521 7529
     busy_doing_M600 = false;  // Allow Stepper Motors to be turned off during inactivity
7522 7530
   }
7523 7531
 

Loading…
Cancel
Save