From 0fc4f0946ed6801de1a3403311f5fc2836559dd9 Mon Sep 17 00:00:00 2001 From: Kevin O'Connor Date: Wed, 4 Apr 2018 14:13:59 -0400 Subject: heater: Move adc logic into Thermistor class The Thermistor (and Linear) class should handle all the details of reading the ADC values and converting them to temperatures. So, move that logic out of the Heater() class. Signed-off-by: Kevin O'Connor --- klippy/extras/pid_calibrate.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'klippy/extras/pid_calibrate.py') diff --git a/klippy/extras/pid_calibrate.py b/klippy/extras/pid_calibrate.py index 1caffeb7..bd2b29d6 100644 --- a/klippy/extras/pid_calibrate.py +++ b/klippy/extras/pid_calibrate.py @@ -62,7 +62,7 @@ class ControlAutoTune: self.pwm_samples.append((read_time + heater.PWM_DELAY, value)) self.last_pwm = value self.heater.set_pwm(read_time, value) - def adc_callback(self, read_time, temp): + def temperature_callback(self, read_time, temp): self.temp_samples.append((read_time, temp)) if self.heating and temp >= self.heater.target_temp: self.heating = False -- cgit v1.2.3-70-g09d2