aboutsummaryrefslogtreecommitdiffstats
path: root/klippy/extras/adc_temperature.py
Commit message (Collapse)AuthorAgeFilesLines
* Isort all klippy codeTomasz Kramkowski2025-08-151-2/+2
|
* Run black on all first party python codeTomasz Kramkowski2025-08-061-115/+450
|
* adc_temperature: Enhance "ADC out of range" error reportsKevin O'Connor2024-06-211-4/+38
| | | | | | Try to report which ADC is reporting out of range. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* mcu: Rename setup_minmax() to setup_adc_sample()Kevin O'Connor2024-06-211-4/+4
| | | | | | | Rename this method so that it is more distinct from the the common temperature setup_minmax() method. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* klippy: Replace deprecated logger.warn with logger.warning (#6385)Thijs Triemstra2023-11-161-2/+2
| | | | | | | Replace deprecated logger.warn with logger.warning logger.warn will be removed in Python 3.13 Signed-off-by: Thijs Triemstra <info@collab.nl>
* spi_temperature: Simplify and comment MAX31865 temperature calculationsKevin O'Connor2020-09-021-1/+1
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* adc_temperature: Minor simplification of default sensor registrationKevin O'Connor2020-08-231-16/+15
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* adc_temperature: Calculate "PT100 INA826" values from formulaKevin O'Connor2020-08-221-13/+7
| | | | | | Calculate the "PT100 INA826" values instead of using a voltage table. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* adc_temperature: Calculate PT1000 temperature/resistance pairs from formulaKevin O'Connor2020-08-221-4/+6
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* adc_temperature: add support for AD597 (#3164)Bryan Boettcher2020-08-091-0/+9
| | | | | | The AD597 thermocouple amplifier is used in the Raise3D N2+ (and possibly others). Signed-off-by: Bryan Boettcher <bryan.boettcher@gmail.com>
* klippy: Rename try_load_module() to load_object()Kevin O'Connor2020-05-081-3/+3
| | | | | | | | Rename try_load_module() so that it uses consistent naming for "printer objects". Change the function to raise an error by default if the specified module does not exist. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* heaters: Make heater.py an "extras" moduleKevin O'Connor2020-04-251-5/+5
| | | | | | | The heater logic is an independent module that does not need to be treated as part of the "core" klipper code. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* adc_temperature: Add builtin definition for PT1000 sensorsKevin O'Connor2020-03-051-2/+12
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* query_adc: Add a new module to help query and debug analog pinsKevin O'Connor2019-11-071-0/+2
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* adc_temperature: add support for AD849x thermocouple amplifiers (#1994)Geoff Shannon2019-10-101-2/+86
| | | Signed-off-by: Geoff Shannon <geoffpshannon@gmail.com>
* adc_temperature: Minor comment updateKevin O'Connor2019-06-021-2/+2
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* heater: Rename add_sensor() to add_sensor_factory()Kevin O'Connor2019-02-251-2/+2
| | | | | Signed-off-by: Douglas Hammond <wizhippo@gmail.com> Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* adc_temperature: Add support for linear interpolation of resistancesKevin O'Connor2019-01-211-2/+49
| | | | | | | Add support for performing linear interpolation between a set of measured temperature/resistance pairs. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* adc_temperature: Split linear interpolation code into its own classKevin O'Connor2019-01-211-46/+60
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* adc_temperature: Move PrinterADCtoTemperature to adc_temperature.pyKevin O'Connor2019-01-211-19/+37
| | | | | | | Move the low-level PrinterADCtoTemperature() class from thermistor.py to adc_temperature.py and use it from the Linear() class. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* adc_temperature: Minor whitespace changesKevin O'Connor2018-07-261-11/+12
| | | | | | Wrap lines at 80 columns. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* adccmds: Add support for min/max temperature check filteringKevin O'Connor2018-07-021-1/+3
| | | | | | | | | | | Extend the ADC out of range check so that it is possible to sample multiple times before going into a shutdown state. This reduces the chance that measurement noise will cause an error. In an actual over temperature (or under temperature event) it is expected that the sensor will consistently report the problem, so extra checks for an additional second or two should not substantially increase risk. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* adc_temperature: Support defining custom sensors in the config fileKevin O'Connor2018-04-091-0/+19
| | | | | | | Allow the user to define a custom sensor with their own set of temperature/voltage measurements. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* adc_temperatures: Add "PT100 INA826" sensor typeKevin O'Connor2018-04-091-1/+13
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* adc_temperature: Support multiple ranges for ADC lookupKevin O'Connor2018-04-091-10/+54
| | | | | | | | | | Instead of supporting a single linear range for the temperature lookup, allow multiple ranges to be defined. This makes the lookup more accurate when a full lookup table is available. Update the AD595 sensor to use the full table defined in its spec. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* heater: Move Thermistor and Linear to their own files in extras/Kevin O'Connor2018-04-041-0/+45
Move the Thermistor code to a new thermistor.py module. Move the Linear code to a new adc_temperature.py module. This simplifies the heater.py code. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>