GUI: Control Panel changes #2

Open
atse wants to merge 21 commits from gui_dev-ctrl_panel into gui_dev
2 changed files with 3 additions and 3 deletions
Showing only changes of commit 85c8c23f2c - Show all commits

View File

@ -355,7 +355,7 @@
}, },
{ {
"name": "pid_autotune", "name": "pid_autotune",
"title": "PID Auto Tune", "title": "PID Autotune",
"expanded": false, "expanded": false,
"type": "group", "type": "group",
"tip": "Automatically tune PID parameters", "tip": "Automatically tune PID parameters",

View File

@ -82,7 +82,7 @@ class MainWindow(QtWidgets.QMainWindow):
[["load"], partial(self.thermostat.load_cfg, ch)], [["load"], partial(self.thermostat.load_cfg, ch)],
[ [
["pid", "pid_autotune", "run_pid"], ["pid", "pid_autotune", "run_pid"],
partial(self.pid_auto_tune_request, ch), partial(self.pid_autotune_request, ch),
], ],
] ]
for ch in range(self.NUM_CHANNELS) for ch in range(self.NUM_CHANNELS)
@ -292,7 +292,7 @@ class MainWindow(QtWidgets.QMainWindow):
self.autotuners.set_params(auto_tuner_param, ch, new_value) self.autotuners.set_params(auto_tuner_param, ch, new_value)
@asyncSlot() @asyncSlot()
async def pid_auto_tune_request(self, ch=0): async def pid_autotune_request(self, ch=0):
match self.autotuners.get_state(ch): match self.autotuners.get_state(ch):
case PIDAutotuneState.STATE_OFF | PIDAutotuneState.STATE_FAILED: case PIDAutotuneState.STATE_OFF | PIDAutotuneState.STATE_FAILED:
self.autotuners.load_params_and_set_ready(ch) self.autotuners.load_params_and_set_ready(ch)