Add an enable/disable switch for the temperature controller

New TempControllerBase.enabled (default False) forces y=0 in
process_pid() when off, same mechanism as the existing cooling
override - the controller tries not to drive the heater at all.

tasks/tempctrl.py: new 'Enable' recv command and 'Enabled' broadcast
on the TempCtrl channel. tasks/sud.py: SudTask now enables the
controller on any non-IDLE/DONE Sud state and disables it (forcing
power back to 0) on IDLE/DONE, so automatic mode owns it for the
duration of a run and hands back manual control once it stops/finishes.

gui: new "Enabled" checkbox on the Manual tab's Controller group,
synced from the server; the temp/heatrate setpoint controls are
disabled whenever the controller itself is disabled.
This commit is contained in:
2026-06-21 12:54:09 +02:00
parent e2222dae5e
commit 3fea29cc58
6 changed files with 78 additions and 9 deletions
+20 -4
View File
@@ -517,11 +517,27 @@
<property name="title">
<string>Controller</string>
</property>
<widget class="QCheckBox" name="checkbox_tc_enable">
<property name="geometry">
<rect>
<x>0</x>
<y>25</y>
<width>141</width>
<height>25</height>
</rect>
</property>
<property name="toolTip">
<string>While disabled, the controller tries not to drive the heater (output forced to 0) and the setpoints below are inactive</string>
</property>
<property name="text">
<string>Enabled</string>
</property>
</widget>
<widget class="QSlider" name="Slider_temp_soll">
<property name="geometry">
<rect>
<x>20</x>
<y>70</y>
<y>100</y>
<width>63</width>
<height>281</height>
</rect>
@@ -540,7 +556,7 @@
<property name="geometry">
<rect>
<x>10</x>
<y>370</y>
<y>400</y>
<width>67</width>
<height>31</height>
</rect>
@@ -556,7 +572,7 @@
<property name="geometry">
<rect>
<x>80</x>
<y>370</y>
<y>400</y>
<width>51</width>
<height>31</height>
</rect>
@@ -575,7 +591,7 @@
<property name="geometry">
<rect>
<x>0</x>
<y>30</y>
<y>60</y>
<width>141</width>
<height>31</height>
</rect>