aboutsummaryrefslogtreecommitdiffstats
path: root/klippy/extras/verify_heater.py
Commit message (Collapse)AuthorAgeFilesLines
* verify_heater: Don't raise a heater error if the heater is offKevin O'Connor2019-06-121-1/+1
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* verify_heater: If the heating_gain check fails, just use max_error checkKevin O'Connor2019-03-081-13/+17
| | | | | | | | | Don't immediately raise an error if the heating_gain check fails. Instead, just transition to the normal max_error check. This should make the code less likely to raise an error should the heater have a slow approach to the target temperature. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* verify_heater: Improve handling of new targets when temperature is droppingKevin O'Connor2019-03-081-1/+5
| | | | | | | | | Allow the first check_gain_time interval to only require a heating_gain relative to the lowest observed temperature during that interval. This makes the code less likely to raise a spurious error when the heater is enabled while the heater temperature is dropping. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* verify_heater: Only reset the error count if within the hysteresis rangeKevin O'Connor2019-03-081-1/+2
| | | | | | | | Don't reset the error counter if the reported temperature is significantly above the target temperature. This may help catch cases where the temperature sensor reports random values. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* klippy: Convert printer_state("connect") to an event handlerKevin O'Connor2019-01-081-11/+11
| | | | | | | Convert all users of the printer_state("connect") handler to register a "klippy:connect" event handler instead. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* klippy: Convert printer_state("shutdown") to an event handlerKevin O'Connor2019-01-081-1/+4
| | | | | | | Convert all users of the printer_state("shutdown") handler to register a "klippy:shutdown" event handler instead. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* verify_heater: Don't report a heater error if printer is shutdownKevin O'Connor2018-09-301-1/+6
| | | | | | | | Don't log a heater verification error if that error is due to the printer being shutdown for some other reason. Those spurious error reports can be confusing. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* verify_heater: Disable when writing output to a debug fileKevin O'Connor2018-06-081-0/+3
| | | | | | | Disable the verify_heater checks when debugging, as otherwise it can cause failures when processing files in batch mode. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* heater: Add PrinterHeaters class that stores all sensors and heatersKevin O'Connor2018-04-041-3/+2
| | | | | | | | | | | | Add a PrinterHeaters class that can stores references to available temperature sensors and stores references to instantiated heaters. Add a extras/heater_bed.py file and delay instantiation of the heater_bed object. This allows the heater.py module to be imported earlier during the setup phase, and allows the PrinterHeaters class to be available for registering sensors and heaters. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* verify_heater: Provide additional information on a heater errorKevin O'Connor2018-03-121-2/+8
| | | | Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* verify_heater: Scale hysteresis duration checkKevin O'Connor2018-03-111-6/+7
| | | | | | | | | | If a heater falls out of the target range, accumulate the temperature differences to determine if an error should be raised. This should make it less likely to report an error for heaters that drift slightly out of range, and it should make error reporting faster for heaters that rapidly fall out of range. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* verify_heater: Change default hysteresis to 10 degreesKevin O'Connor2018-03-111-2/+2
| | | | | | | A default of 4 degrees and 10 seconds may be too aggressive - change the default to 10 degrees and 15 seconds. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
* verify_heater: Add initial support for verifying heaters and sensorsKevin O'Connor2018-03-111-0/+67
Add runtime checks to heaters and temperature sensors to check for possible hardware faults. Signed-off-by: Kevin O'Connor <kevin@koconnor.net>