mirror of
https://github.com/Klipper3d/klipper.git
synced 2025-07-16 03:07:56 -06:00
heaters: Make MINIMUM optional for TEMPERATURE_WAIT command (#3674)
Signed-off-by: Justin Schuh <code@justinschuh.com>
This commit is contained in:
parent
1a9218532b
commit
a5ebe5825a
2 changed files with 7 additions and 4 deletions
|
@ -329,8 +329,11 @@ class PrinterHeaters:
|
|||
sensor_name = gcmd.get('SENSOR')
|
||||
if sensor_name not in self.available_sensors:
|
||||
raise gcmd.error("Unknown sensor '%s'" % (sensor_name,))
|
||||
min_temp = gcmd.get_float('MINIMUM')
|
||||
min_temp = gcmd.get_float('MINIMUM', float('-inf'))
|
||||
max_temp = gcmd.get_float('MAXIMUM', float('inf'), above=min_temp)
|
||||
if min_temp == float('-inf') and max_temp == float('inf'):
|
||||
raise gcmd.error(
|
||||
"Error on 'TEMPERATURE_WAIT': missing MINIMUM or MAXIMUM.")
|
||||
if self.printer.get_start_args().get('debugoutput') is not None:
|
||||
return
|
||||
if sensor_name in self.heaters:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue