aboutsummaryrefslogtreecommitdiffstats
path: root/klippy/extras
diff options
context:
space:
mode:
authorKevin O'Connor <kevin@koconnor.net>2019-02-25 20:20:37 -0500
committerKevin O'Connor <kevin@koconnor.net>2019-02-25 20:34:12 -0500
commitbb4fab5570b2176dabfda8b916d2231ce995d31d (patch)
tree169c77f0f85d3c406b9db89d0eb09b0ad1569552 /klippy/extras
parentcf6c5e6f180587924f9c46bb1db141089823da3a (diff)
downloadkutter-bb4fab5570b2176dabfda8b916d2231ce995d31d.tar.gz
kutter-bb4fab5570b2176dabfda8b916d2231ce995d31d.tar.xz
kutter-bb4fab5570b2176dabfda8b916d2231ce995d31d.zip
heater: Rename add_sensor() to add_sensor_factory()
Signed-off-by: Douglas Hammond <wizhippo@gmail.com> Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'klippy/extras')
-rw-r--r--klippy/extras/adc_temperature.py4
-rw-r--r--klippy/extras/spi_temperature.py2
-rw-r--r--klippy/extras/thermistor.py4
3 files changed, 5 insertions, 5 deletions
diff --git a/klippy/extras/adc_temperature.py b/klippy/extras/adc_temperature.py
index 086f2858..10825901 100644
--- a/klippy/extras/adc_temperature.py
+++ b/klippy/extras/adc_temperature.py
@@ -191,7 +191,7 @@ def load_config(config):
for sensor_type, params in [("AD595", AD595), ("PT100 INA826", PT100)]:
func = (lambda config, params=params:
PrinterADCtoTemperature(config, LinearVoltage(config, params)))
- pheater.add_sensor(sensor_type, func)
+ pheater.add_sensor_factory(sensor_type, func)
def load_config_prefix(config):
if config.get("resistance1", None) is None:
@@ -199,4 +199,4 @@ def load_config_prefix(config):
else:
custom_sensor = CustomLinearResistance(config)
pheater = config.get_printer().lookup_object("heater")
- pheater.add_sensor(custom_sensor.name, custom_sensor.create)
+ pheater.add_sensor_factory(custom_sensor.name, custom_sensor.create)
diff --git a/klippy/extras/spi_temperature.py b/klippy/extras/spi_temperature.py
index 6dbb0b94..ff4b10e4 100644
--- a/klippy/extras/spi_temperature.py
+++ b/klippy/extras/spi_temperature.py
@@ -342,4 +342,4 @@ def load_config(config):
# Register sensors
pheater = config.get_printer().lookup_object("heater")
for name, klass in Sensors.items():
- pheater.add_sensor(name, klass)
+ pheater.add_sensor_factory(name, klass)
diff --git a/klippy/extras/thermistor.py b/klippy/extras/thermistor.py
index 3dff1520..eee14b1c 100644
--- a/klippy/extras/thermistor.py
+++ b/klippy/extras/thermistor.py
@@ -117,9 +117,9 @@ def load_config(config):
pheater = config.get_printer().lookup_object("heater")
for sensor_type, params in Sensors.items():
func = (lambda config, params=params: PrinterThermistor(config, params))
- pheater.add_sensor(sensor_type, func)
+ pheater.add_sensor_factory(sensor_type, func)
def load_config_prefix(config):
thermistor = CustomThermistor(config)
pheater = config.get_printer().lookup_object("heater")
- pheater.add_sensor(thermistor.name, thermistor.create)
+ pheater.add_sensor_factory(thermistor.name, thermistor.create)