GUI¶
The GUI is written using PySide2 and consists of one main PVP_Gui
object that instantiates a series of GUI Widgets. The GUI is responsible for setting ventilation control parameters
and sending them to the controller
(see set_control()
), as well as receiving and displaying sensor values (get_sensors()
).
The GUI also feeds the Alarm_Manager
SensorValues
objects so that it can compute alarm state. The Alarm_Manager
reciprocally updates the GUI with Alarm
s (PVP_Gui.handle_alarm()
) and Alarm limits (PVP_Gui.limits_updated()
).
The main polling loop of the GUI is PVP_Gui.update_gui()
which queries the controller for new SensorValues
and distributes
them to all listening widgets (see method documentation for more details). The rest of the GUI is event driven, usually with Qt
Signals and Slots.
The GUI is configured by the values
module, in particular it creates
Display
widgets in the left “sensor monitor” box from allValue
s inDISPLAY_MONITOR
,Display
widgets in the right “control” box from allValue
s inDISPLAY_CONTROL
, andPlot
widgets in the center plot box from allValue
s inPLOT
The GUI is not intended to be launched alone, as it needs an active coordinator
to communicate with the controller process
and a few prelaunch preparations (launch_gui()
). PVP should be started like:
python3 -m pvp.main
Module Overview¶
Screenshot¶
