Browse Source

🐛 Fix M140 print job timer autostart (#22046)

Taylor Talkington 4 years ago
parent
commit
c2c771a1cc
No account linked to committer's email address
2 changed files with 17 additions and 7 deletions
  1. 14
    5
      Marlin/Configuration.h
  2. 3
    2
      Marlin/src/gcode/temp/M140_M190.cpp

+ 14
- 5
Marlin/Configuration.h View File

1824
 /**
1824
 /**
1825
  * Print Job Timer
1825
  * Print Job Timer
1826
  *
1826
  *
1827
- * Automatically start and stop the print job timer on M104/M109/M190.
1828
- *
1829
- *   M104 (hotend, no wait) - high temp = none,        low temp = stop timer
1830
- *   M109 (hotend, wait)    - high temp = start timer, low temp = stop timer
1831
- *   M190 (bed, wait)       - high temp = start timer, low temp = none
1827
+ * Automatically start and stop the print job timer on M104/M109/M140/M190/M141/M191.
1828
+ * The print job timer will only be stopped if the bed/chamber target temp is
1829
+ * below BED_MINTEMP/CHAMBER_MINTEMP.
1830
+ *
1831
+ *   M104 (hotend, no wait)  - high temp = none,        low temp = stop timer
1832
+ *   M109 (hotend, wait)     - high temp = start timer, low temp = stop timer
1833
+ *   M140 (bed, no wait)     - high temp = none,        low temp = stop timer
1834
+ *   M190 (bed, wait)        - high temp = start timer, low temp = none
1835
+ *   M141 (chamber, no wait) - high temp = none,        low temp = stop timer
1836
+ *   M191 (chamber, wait)    - high temp = start timer, low temp = none
1837
+ *
1838
+ * For M104/M109, high temp is anything over EXTRUDE_MINTEMP / 2.
1839
+ * For M140/M190, high temp is anything over BED_MINTEMP.
1840
+ * For M141/M191, high temp is anything over CHAMBER_MINTEMP.
1832
  *
1841
  *
1833
  * The timer can also be controlled with the following commands:
1842
  * The timer can also be controlled with the following commands:
1834
  *
1843
  *

+ 3
- 2
Marlin/src/gcode/temp/M140_M190.cpp View File

83
 
83
 
84
   thermalManager.setTargetBed(temp);
84
   thermalManager.setTargetBed(temp);
85
 
85
 
86
-  TERN_(PRINTJOB_TIMER_AUTOSTART, thermalManager.auto_job_check_timer(true, false));
87
-
88
   ui.set_status_P(thermalManager.isHeatingBed() ? GET_TEXT(MSG_BED_HEATING) : GET_TEXT(MSG_BED_COOLING));
86
   ui.set_status_P(thermalManager.isHeatingBed() ? GET_TEXT(MSG_BED_HEATING) : GET_TEXT(MSG_BED_COOLING));
89
 
87
 
88
+  // with PRINTJOB_TIMER_AUTOSTART, M190 can start the timer, and M140 can stop it
89
+  TERN_(PRINTJOB_TIMER_AUTOSTART, thermalManager.auto_job_check_timer(isM190, !isM190));
90
+
90
   if (isM190)
91
   if (isM190)
91
     thermalManager.wait_for_bed(no_wait_for_cooling);
92
     thermalManager.wait_for_bed(no_wait_for_cooling);
92
 }
93
 }

Loading…
Cancel
Save