aboutsummaryrefslogtreecommitdiffstats
path: root/klippy
diff options
context:
space:
mode:
authorKevin O'Connor <kevin@koconnor.net>2021-08-19 15:03:41 -0400
committerKevin O'Connor <kevin@koconnor.net>2021-08-21 18:08:11 -0400
commit65fb494e7769fdd75be49abd1b82b17fa79ea37d (patch)
tree1213eda9e95ff18e0dc3c4a543f805d69e1c678d /klippy
parent8f85786b3fc0341b966a127406e21b32d98338d3 (diff)
downloadkutter-65fb494e7769fdd75be49abd1b82b17fa79ea37d.tar.gz
kutter-65fb494e7769fdd75be49abd1b82b17fa79ea37d.tar.xz
kutter-65fb494e7769fdd75be49abd1b82b17fa79ea37d.zip
heater_fan: Use config.getlist() for heater config option
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'klippy')
-rw-r--r--klippy/extras/heater_fan.py5
1 files changed, 2 insertions, 3 deletions
diff --git a/klippy/extras/heater_fan.py b/klippy/extras/heater_fan.py
index 43009b06..ab4c8a81 100644
--- a/klippy/extras/heater_fan.py
+++ b/klippy/extras/heater_fan.py
@@ -12,7 +12,7 @@ class PrinterHeaterFan:
self.printer = config.get_printer()
self.printer.load_object(config, 'heaters')
self.printer.register_event_handler("klippy:ready", self.handle_ready)
- self.heater_name = config.get("heater", "extruder")
+ self.heater_names = config.getlist("heater", ("extruder",))
self.heater_temp = config.getfloat("heater_temp", 50.0)
self.heaters = []
self.fan = fan.Fan(config, default_shutdown_speed=1.)
@@ -20,8 +20,7 @@ class PrinterHeaterFan:
self.last_speed = 0.
def handle_ready(self):
pheaters = self.printer.lookup_object('heaters')
- self.heaters = [pheaters.lookup_heater(n.strip())
- for n in self.heater_name.split(',')]
+ self.heaters = [pheaters.lookup_heater(n) for n in self.heater_names]
reactor = self.printer.get_reactor()
reactor.register_timer(self.callback, reactor.monotonic()+PIN_MIN_TIME)
def get_status(self, eventtime):