Skip to content

Commit

Permalink
heaters: Don't raise an error if PID Ki is set to zero
Browse files Browse the repository at this point in the history
Signed-off-by: Kevin O'Connor <[email protected]>
  • Loading branch information
KevinOConnor committed Oct 18, 2020
1 parent abb0d88 commit f8cb1e3
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion klippy/extras/heaters.py
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,9 @@ def __init__(self, heater, config):
self.min_deriv_time = heater.get_smooth_time()
imax = config.getfloat('pid_integral_max', self.heater_max_power,
minval=0.)
self.temp_integ_max = imax / self.Ki
self.temp_integ_max = 0.
if self.Ki:
self.temp_integ_max = imax / self.Ki
self.prev_temp = AMBIENT_TEMP
self.prev_temp_time = 0.
self.prev_temp_deriv = 0.
Expand Down

0 comments on commit f8cb1e3

Please sign in to comment.