Преглед изворни кода

Merge pull request #4223 from thinkyhead/rc_rename_heatup

Change cancel_heatup to wait_for_heatup
Scott Lahteine пре 8 година
родитељ
комит
7735ec5e7a
3 измењених фајлова са 9 додато и 11 уклоњено
  1. 7
    9
      Marlin/Marlin_main.cpp
  2. 1
    1
      Marlin/ultralcd.cpp
  3. 1
    1
      Marlin/ultralcd.h

+ 7
- 9
Marlin/Marlin_main.cpp Прегледај датотеку

@@ -332,7 +332,7 @@ uint8_t active_extruder = 0;
332 332
 // Relative Mode. Enable with G91, disable with G90.
333 333
 static bool relative_mode = false;
334 334
 
335
-bool cancel_heatup = false;
335
+bool wait_for_heatup = true;
336 336
 
337 337
 const char errormagic[] PROGMEM = "Error:";
338 338
 const char echomagic[] PROGMEM = "echo:";
@@ -1107,7 +1107,7 @@ inline void get_serial_commands() {
1107 1107
 
1108 1108
       // If command was e-stop process now
1109 1109
       if (strcmp(command, "M112") == 0) kill(PSTR(MSG_KILLED));
1110
-      if (strcmp(command, "M108") == 0) cancel_heatup = true;
1110
+      if (strcmp(command, "M108") == 0) wait_for_heatup = false;
1111 1111
 
1112 1112
       #if defined(NO_TIMEOUTS) && NO_TIMEOUTS > 0
1113 1113
         last_command_time = ms;
@@ -4540,9 +4540,7 @@ inline void gcode_M105() {
4540 4540
 /**
4541 4541
  * M108: Cancel heatup and wait for the hotend and bed, this G-code is asynchronously handled in the get_serial_commands() parser
4542 4542
  */
4543
-inline void gcode_M108() {
4544
-  cancel_heatup = true;
4545
-}
4543
+inline void gcode_M108() { wait_for_heatup = false; }
4546 4544
 
4547 4545
 /**
4548 4546
  * M109: Sxxx Wait for extruder(s) to reach temperature. Waits only when heating.
@@ -4602,7 +4600,7 @@ inline void gcode_M109() {
4602 4600
 
4603 4601
   float theTarget = -1.0, old_temp = 9999.0;
4604 4602
   bool wants_to_cool = false;
4605
-  cancel_heatup = false;
4603
+  wait_for_heatup = true;
4606 4604
   millis_t now, next_temp_ms = 0, next_cool_check_ms = 0;
4607 4605
 
4608 4606
   KEEPALIVE_STATE(NOT_BUSY);
@@ -4666,7 +4664,7 @@ inline void gcode_M109() {
4666 4664
       }
4667 4665
     }
4668 4666
 
4669
-  } while (!cancel_heatup && TEMP_CONDITIONS);
4667
+  } while (wait_for_heatup && TEMP_CONDITIONS);
4670 4668
 
4671 4669
   LCD_MESSAGEPGM(MSG_HEATING_COMPLETE);
4672 4670
   KEEPALIVE_STATE(IN_HANDLER);
@@ -4696,7 +4694,7 @@ inline void gcode_M109() {
4696 4694
 
4697 4695
     float theTarget = -1.0, old_temp = 9999.0;
4698 4696
     bool wants_to_cool = false;
4699
-    cancel_heatup = false;
4697
+    wait_for_heatup = true;
4700 4698
     millis_t now, next_temp_ms = 0, next_cool_check_ms = 0;
4701 4699
 
4702 4700
     KEEPALIVE_STATE(NOT_BUSY);
@@ -4760,7 +4758,7 @@ inline void gcode_M109() {
4760 4758
         }
4761 4759
       }
4762 4760
 
4763
-    } while (!cancel_heatup && TEMP_BED_CONDITIONS);
4761
+    } while (wait_for_heatup && TEMP_BED_CONDITIONS);
4764 4762
 
4765 4763
     LCD_MESSAGEPGM(MSG_BED_DONE);
4766 4764
     KEEPALIVE_STATE(IN_HANDLER);

+ 1
- 1
Marlin/ultralcd.cpp Прегледај датотеку

@@ -559,7 +559,7 @@ static void lcd_status_screen() {
559 559
       stepper.quick_stop();
560 560
       print_job_timer.stop();
561 561
       thermalManager.autotempShutdown();
562
-      cancel_heatup = true;
562
+      wait_for_heatup = false;
563 563
       lcd_setstatus(MSG_PRINT_ABORTED, true);
564 564
       #if DISABLED(DELTA) && DISABLED(SCARA)
565 565
         set_current_position_from_planner();

+ 1
- 1
Marlin/ultralcd.h Прегледај датотеку

@@ -95,7 +95,7 @@
95 95
   extern int absPreheatHPBTemp;
96 96
   extern int absPreheatFanSpeed;
97 97
 
98
-  extern bool cancel_heatup;
98
+  extern bool wait_for_heatup;
99 99
 
100 100
   #if ENABLED(FILAMENT_LCD_DISPLAY)
101 101
     extern millis_t previous_lcd_status_ms;

Loading…
Откажи
Сачувај