Skip to content

Commit

Permalink
Update heaters.py (#98)
Browse files Browse the repository at this point in the history
Allow PID_V parameter to be modify whithout reloading too
  • Loading branch information
fbeauKmi committed Nov 17, 2023
1 parent 2c60047 commit a52d731
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions klippy/extras/heaters.py
Original file line number Diff line number Diff line change
Expand Up @@ -194,8 +194,8 @@ def cmd_SET_HEATER_TEMPERATURE(self, gcmd):
cmd_SET_HEATER_PID_help = "Sets a heater PID parameter"

def cmd_SET_HEATER_PID(self, gcmd):
if not isinstance(self.control, ControlPID):
raise gcmd.error("Not a PID controlled heater")
if not isinstance(self.control, (ControlPID, ControlVelocityPID)):
raise gcmd.error("Not a PID/PID_V controlled heater")
kp = gcmd.get_float("KP", None)
if kp is not None:
self.control.Kp = kp / PID_PARAM_BASE
Expand Down

0 comments on commit a52d731

Please sign in to comment.