diff --git a/octoprint_enclosure/__init__.py b/octoprint_enclosure/__init__.py index d446981..55eb548 100644 --- a/octoprint_enclosure/__init__.py +++ b/octoprint_enclosure/__init__.py @@ -695,6 +695,7 @@ class EnclosurePlugin(octoprint.plugin.StartupPlugin, octoprint.plugin.TemplateP try: calculated_duty = ((current_temp - temp_a) * (duty_b - duty_a) / (temp_b - temp_a)) + duty_a + calculated_duty = self.constrain(calculated_duty, duty_a,100) except: calculated_duty = 0