Compare commits

..

15 Commits

Author SHA1 Message Date
3552a582f8 ctrl_panel: Keep i_set visible when PID engaged
Since i_set is also plotted, we would want to see its precise value too.
2024-07-19 15:55:43 +08:00
d7defecaaa ctrl_panel: Remove MutexParameter
Use the standard ListParamenter instead, and hook up UI changes
elsewhere.
2024-07-19 15:49:19 +08:00
282f3d1e82 ctrl_panel: Limits fixes
* PID Autotune test current should be positive

* Maximum absolute voltage should be 4 V not 5 V
2024-07-19 15:49:19 +08:00
d4171f002e ctrl_panel: Code cleanup
* Remove unnecessary duplication of `THERMOSTAT_PARAMETERS`

* i -> ch

* Separate ParameterTree and Parameter initiation

* Remove extra "channel" option to root parameters, as the "value"
option is already the channel number
2024-07-19 15:49:19 +08:00
1221ac4436 ctrl_panel: PID Auto Tune -> PID Autotune 2024-07-19 15:49:19 +08:00
abecac44d6 ctrl_panel: Stop crushing spinboxes
It might not be the case on some themes, but on the default Qt theme the
spinbox are a bit too short for the containing numbers. See
https://github.com/pyqtgraph/pyqtgraph/issues/701.
2024-07-19 15:49:19 +08:00
8902052ee0 ctrl_panel: Appropriate units for measured current
Allow the readonly display of current to vary its SI prefix in the unit,
since as a display entry it won't have the unit adjustment problem.
2024-07-19 15:49:19 +08:00
fd7e22fd23 ctrl_panel: Pin down units for editable fields
Avoids awkward value editing
2024-07-19 15:49:19 +08:00
681a7539fe ctrl_panel: Improve postfilter description 2024-07-19 15:49:19 +08:00
ed835ddfe6 ctrl_panel: Add tooltips
For users' better understanding of what the parameters do
2024-07-19 15:49:19 +08:00
437c9cec34 ctrl_panel: Refer to Parameters by concise names
For displayed string representations, use the `title` key, or for
`ListParameter`s, use the dictionary mapping method instead.
2024-07-19 15:49:19 +08:00
7829ce6adf ctrl_panel: Config -> Settings 2024-07-19 15:49:16 +08:00
0f14212622 Format JSON 2024-07-19 15:48:57 +08:00
b768d61e39 Merge pull request 'GUI: Text changes' (#3) from gui_dev-str_changes into gui_dev
Reviewed-on: linuswck/thermostat#3
2024-07-19 15:36:01 +08:00
d244ba392a Fix typos 2024-07-19 15:34:31 +08:00
2 changed files with 2 additions and 2 deletions

View File

@ -117,7 +117,7 @@ class Thermostat(QObject, metaclass=PropertyMeta):
async def save_cfg(self, ch): async def save_cfg(self, ch):
await self._client.save_config(ch) await self._client.save_config(ch)
self.info_box_trigger.emit( self.info_box_trigger.emit(
"Settings loaded", f"Channel {ch} Settings has been loaded to flash." "Settings saved", f"Channel {ch} Settings has been saved to flash."
) )
@asyncSlot() @asyncSlot()

View File

@ -332,7 +332,7 @@ class MainWindow(QtWidgets.QMainWindow):
case PIDAutotuneState.STATE_FAILED: case PIDAutotuneState.STATE_FAILED:
self.info_box.display_info_box( self.info_box.display_info_box(
"PID Autotune Failed", f"Channel {ch} PID Autotune is failed." "PID Autotune Failed", f"Channel {ch} PID Autotune has failed."
) )
self.info_box.show() self.info_box.show()