Index: simulator/plugins/GeneralProgressMessage/loader.py
===================================================================
diff -u -r12408471ebe8f39c87bd0242a2d5e36f122175d4 -r1b402ab005844b85b8361ae611664731cfa39e0b
--- simulator/plugins/GeneralProgressMessage/loader.py (.../loader.py) (revision 12408471ebe8f39c87bd0242a2d5e36f122175d4)
+++ simulator/plugins/GeneralProgressMessage/loader.py (.../loader.py) (revision 1b402ab005844b85b8361ae611664731cfa39e0b)
@@ -76,4 +76,7 @@
message_id = self.leMessageID.text()
timeout = self.sldTimeout.value()
countdown = self.sldCountdown.value()
- self.hd_simulator.cmd_send_general_progress_data(int(message_id), timeout, countdown, self.rbHD.isChecked())
+ if self.rbHD.isChecked():
+ self.hd_simulator.cmd_send_general_hd_progress_data(int(message_id), timeout, countdown)
+ else:
+ self.hd_simulator.cmd_send_general_dg_progress_data(int(message_id), timeout, countdown)
Index: simulator/plugins/PostTreatment/interface.ui
===================================================================
diff -u -r7b31e16c71ec5da38ce5759fbfb44a885554cf13 -r1b402ab005844b85b8361ae611664731cfa39e0b
--- simulator/plugins/PostTreatment/interface.ui (.../interface.ui) (revision 7b31e16c71ec5da38ce5759fbfb44a885554cf13)
+++ simulator/plugins/PostTreatment/interface.ui (.../interface.ui) (revision 1b402ab005844b85b8361ae611664731cfa39e0b)
@@ -154,7 +154,7 @@
- 2(U32) Param 1
+ 2(F32) Param 1
leBloodFlowRate
@@ -169,13 +169,13 @@
- 9999999999
+ 9999999999.999
- 1
+ 41.1
- 10
+ 14
Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter
@@ -208,7 +208,7 @@
- 3(U32) Param 2
+ 3(F32) Param 2
leBloodFlowRate
@@ -223,13 +223,13 @@
- 9999999999
+ 9999999999.999
- 2
+ 42.2
- 10
+ 14
Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter
@@ -355,7 +355,7 @@
- 2(U32) Old
+ 2(F32) Old
leBloodFlowRate
@@ -370,13 +370,13 @@
- 9999999999
+ 9999999999.999
- 1
+ 51.1
- 10
+ 14
Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter
@@ -407,7 +407,7 @@
- 3(U32) New
+ 3(F32) New
leBloodFlowRate
@@ -422,13 +422,13 @@
- 9999999999
+ 9999999999.999
- 1
+ 51.2
- 10
+ 14
Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter
Index: simulator/plugins/PostTreatment/loader.py
===================================================================
diff -u -r7b31e16c71ec5da38ce5759fbfb44a885554cf13 -r1b402ab005844b85b8361ae611664731cfa39e0b
--- simulator/plugins/PostTreatment/loader.py (.../loader.py) (revision 7b31e16c71ec5da38ce5759fbfb44a885554cf13)
+++ simulator/plugins/PostTreatment/loader.py (.../loader.py) (revision 1b402ab005844b85b8361ae611664731cfa39e0b)
@@ -198,8 +198,8 @@
:return:
"""
tx_log_alarm_id = int(self.leTxLogAlarmID.text())
- tx_log_alarm_parameter1 = int(self.leTxLogAlarmP1.text())
- tx_log_alarm_parameter2 = int(self.leTxLogAlarmP2.text())
+ tx_log_alarm_parameter1 = float(self.leTxLogAlarmP1.text())
+ tx_log_alarm_parameter2 = float(self.leTxLogAlarmP2.text())
self.hd_simulator.cmd_send_treatment_log_alarm(tx_log_alarm_id,
tx_log_alarm_parameter1,
tx_log_alarm_parameter2)
Index: simulator/plugins/alarms/interface.ui
===================================================================
diff -u -rae63fbc76b4638ffdcdaad7b69648beeee3340c3 -r1b402ab005844b85b8361ae611664731cfa39e0b
--- simulator/plugins/alarms/interface.ui (.../interface.ui) (revision ae63fbc76b4638ffdcdaad7b69648beeee3340c3)
+++ simulator/plugins/alarms/interface.ui (.../interface.ui) (revision 1b402ab005844b85b8361ae611664731cfa39e0b)
@@ -6,14 +6,14 @@
0
0
- 994
- 801
+ 937
+ 808
&Alarms/&Alarm
-
+
-
@@ -29,6 +29,285 @@
-
+
+
-
+
+
+ color: rgb(238, 238, 236);
+background-color: rgb(252, 175, 62);
+
+
+ Alarm Active List
+
+
+ Qt::AlignCenter
+
+
+
+ -
+
+
-
+
+
+ Accept
+
+
+
+ -
+
+
+ Reject
+
+
+
+ -
+
+
+ 999
+
+
+
+ -
+
+
+
+ 0
+ 0
+
+
+
+ Reason
+
+
+
+ -
+
+
+ Qt::Horizontal
+
+
+
+ 40
+ 20
+
+
+
+
+
+
+ -
+
+
-
+
+
-
+
+
+ A0
+
+
+
+ -
+
+
+ 999
+
+
+
+
+
+ -
+
+
-
+
+
+ A1
+
+
+
+ -
+
+
+ 999
+
+
+
+
+
+ -
+
+
-
+
+
+ A2
+
+
+
+ -
+
+
+ 999
+
+
+
+
+
+ -
+
+
-
+
+
+ A3
+
+
+
+ -
+
+
+ 999
+
+
+
+
+
+ -
+
+
-
+
+
+ A4
+
+
+
+ -
+
+
+ 999
+
+
+
+ -
+
+
+ Qt::Horizontal
+
+
+
+ 40
+ 20
+
+
+
+
+
+
+ -
+
+
-
+
+
+ A5
+
+
+
+ -
+
+
+ 999
+
+
+
+
+
+ -
+
+
-
+
+
+ A6
+
+
+
+ -
+
+
+ 999
+
+
+
+
+
+ -
+
+
-
+
+
+ A7
+
+
+
+ -
+
+
+ 999
+
+
+
+
+
+ -
+
+
-
+
+
+ A8
+
+
+
+ -
+
+
+ 999
+
+
+
+
+
+ -
+
+
-
+
+
+ A9
+
+
+
+ -
+
+
+ 999
+
+
+
+ -
+
+
+ Qt::Horizontal
+
+
+
+ 40
+ 20
+
+
+
+
+
+
+
+
+
+
+ -
-
@@ -254,9 +533,6 @@
-
-
- false
-
Mute
@@ -690,21 +966,39 @@
+ btnAccept
+ btnReject
+ spnReason
+ spnP0
+ spnP1
+ spnP2
+ spnP3
+ spnP4
+ spnP5
+ spnP6
+ spnP7
+ spnP8
+ spnP9
+ btnSend
+ btnMute
spnTopID
rdoPriorityNone
- rdoPriorityLow
- rdoPriorityMed
rdoPriorityHigh
+ rdoPriorityMed
spnEscalatesIn
- spnMuteTimeout
- lstFlags
- spnAlarmID
tblTriggeredIDs
+ lstFlags
+ spnMuteTimeout
tblStatusIDs
- btnSend
- btnMute
btnTrigger
btnClear
+ spnAlarmID
+ btnCondition
+ leDataField1
+ leDataField2
+ cbFieldDescriptor1
+ cbFieldDescriptor2
+ rdoPriorityLow
Index: simulator/plugins/alarms/loader.py
===================================================================
diff -u -rae63fbc76b4638ffdcdaad7b69648beeee3340c3 -r1b402ab005844b85b8361ae611664731cfa39e0b
--- simulator/plugins/alarms/loader.py (.../loader.py) (revision ae63fbc76b4638ffdcdaad7b69648beeee3340c3)
+++ simulator/plugins/alarms/loader.py (.../loader.py) (revision 1b402ab005844b85b8361ae611664731cfa39e0b)
@@ -45,6 +45,20 @@
leDataField1: QtWidgets.QLineEdit
leDataField2: QtWidgets.QLineEdit
+ btnAccept: QtWidgets.QPushButton
+ btnReject: QtWidgets.QPushButton
+ spnReason: QtWidgets.QSpinBox
+ spnP0: QtWidgets.QSpinBox
+ spnP1: QtWidgets.QSpinBox
+ spnP2: QtWidgets.QSpinBox
+ spnP3: QtWidgets.QSpinBox
+ spnP4: QtWidgets.QSpinBox
+ spnP5: QtWidgets.QSpinBox
+ spnP6: QtWidgets.QSpinBox
+ spnP7: QtWidgets.QSpinBox
+ spnP8: QtWidgets.QSpinBox
+ spnP9: QtWidgets.QSpinBox
+
priority = AlarmPriority.ALARM_HIGH
flags = 0
@@ -55,6 +69,9 @@
eColFlags = 4
eColMessage = 5
eColCount = 6
+
+ eRowMute = 6
+
# column: (width, text)
fixedLabels = {
eColTime: (70, 'Time'),
@@ -110,6 +127,20 @@
self.leDataField1 = self.find_line_edit('leDataField1')
self.leDataField2 = self.find_line_edit('leDataField2')
+ self.btnAccept = self.find_button('btnAccept')
+ self.btnReject = self.find_button('btnReject')
+ self.spnReason = self.find_spinbox('spnReason')
+ self.spnP0 = self.find_spinbox('spnP0')
+ self.spnP1 = self.find_spinbox('spnP1')
+ self.spnP2 = self.find_spinbox('spnP2')
+ self.spnP3 = self.find_spinbox('spnP3')
+ self.spnP4 = self.find_spinbox('spnP4')
+ self.spnP5 = self.find_spinbox('spnP5')
+ self.spnP6 = self.find_spinbox('spnP6')
+ self.spnP7 = self.find_spinbox('spnP7')
+ self.spnP8 = self.find_spinbox('spnP8')
+ self.spnP9 = self.find_spinbox('spnP9')
+
def _init_widgets(self):
"""
initializes the widgets' properties
@@ -142,6 +173,9 @@
self.rdoPriorityMed.toggled.connect(self.do_set_priority_med)
self.rdoPriorityHigh.toggled.connect(self.do_set_priority_high)
+ self.btnAccept.clicked.connect(self.do_active_list_accept)
+ self.btnReject.clicked.connect(self.do_active_list_reject)
+
def set_flags(self):
"""
the slot for flags
@@ -261,17 +295,48 @@
the slot for mute button
:return: none
"""
- print(" --- ", QObject.sender(self).objectName())
+ if self.lstFlags.item(9).checkState() == Qt.Checked:
+ self.lstFlags.item(9).setCheckState(Qt.Checked)
+ else:
+ self.lstFlags.item(9).setCheckState(Qt.UnChecked)
+ self.do_send()
+
@Slot()
+ def do_active_list_accept(self):
+ """
+ the slot for mute button
+ :return: none
+ """
+ a0 = self.spnP0.value()
+ a1 = self.spnP1.value()
+ a2 = self.spnP2.value()
+ a3 = self.spnP3.value()
+ a4 = self.spnP4.value()
+ a5 = self.spnP5.value()
+ a6 = self.spnP6.value()
+ a7 = self.spnP7.value()
+ a8 = self.spnP8.value()
+ a9 = self.spnP9.value()
+ self.alarm.cmd_send_active_list_response(True, 0, a0, a1, a2, a3, a4, a5, a6, a7, a8, a9)
+
+ @Slot()
+ def do_active_list_reject(self):
+ """
+ the slot for mute button
+ :return: none
+ """
+ reason = self.spnReason.value()
+ self.alarm.cmd_send_active_list_response(False, reason)
+
+ @Slot()
def on_status_ids_item_clicked(self, item: QtWidgets.QTableWidgetItem):
"""
slot to handle on item clicked
:param item: the clicked item
:return: None
"""
selected = item.isSelected()
- self.btnMute.setEnabled(selected)
@Slot()
def on_trigger_ids_item_clicked(self, item: QtWidgets.QTableWidgetItem):
Index: simulator/plugins/disinfection/loader.py
===================================================================
diff -u -re25c762014f029632c278b0b324b05f353ea8986 -r1b402ab005844b85b8361ae611664731cfa39e0b
--- simulator/plugins/disinfection/loader.py (.../loader.py) (revision e25c762014f029632c278b0b324b05f353ea8986)
+++ simulator/plugins/disinfection/loader.py (.../loader.py) (revision 1b402ab005844b85b8361ae611664731cfa39e0b)
@@ -9,7 +9,7 @@
# parent
from simulator.dynamicloader import DynamicLoader
# hd Simulator
-from dialin.ui.hd_simulator import HDSimulator, TXStates
+from dialin.ui.hd_simulator import HDSimulator
# plugin specific
# -- none --
@@ -98,9 +98,8 @@
the slot for accept button
:return: none
"""
- # The FW enums have not been defined yet so put the msg here only to test, later shall be moved to a common file
- self.hd_simulator.cmd_send_general_response(128, True, 0)
- self.lblAction.setText('Accepted ')
+ self.hd_simulator.cmd_send_hd_disinfect_response(True, 0)
+ self.lblActionDisinfect.setText('Accepted ')
@Slot()
def do_reject_disinfect(self):
@@ -109,8 +108,7 @@
:return: none
"""
reason = self.spnReasonDisinfect.value()
- # The FW enums have not been defined yet so put the msg here only to test, later shall be moved to a common file
- self.hd_simulator.cmd_send_general_response(128, False, reason)
+ self.hd_simulator.cmd_send_hd_disinfect_response(False, reason)
self.lblActionDisinfect.setText('Rejected ' + "{}".format(reason))
@Slot()
@@ -119,8 +117,7 @@
the slot for accept button
:return: none
"""
- # The FW enums have not been defined yet so put the msg here only to test, later shall be moved to a common file
- self.hd_simulator.cmd_send_general_response(130, True, 0)
+ self.hd_simulator.cmd_send_hd_disinfect_chemical_confirm(True, 0)
self.lblAction.setText('Accepted ')
@Slot()
@@ -130,8 +127,7 @@
:return: none
"""
reason = self.spnReasonDisinfect.value()
- # The FW enums have not been defined yet so put the msg here only to test, later shall be moved to a common file
- self.hd_simulator.cmd_send_general_response(130, False, reason)
+ self.hd_simulator.cmd_send_hd_disinfect_chemical_confirm(False, reason)
self.lblActionDisinfect.setText('Rejected ' + "{}".format(reason))
@Slot()
@@ -143,8 +139,7 @@
"""
timeout_total = self.sldTimeoutTotalFlush.value()
timeout_countdown = self.sldTimeoutCountDownFlush.value()
- # The FW enums have not been defined yet so put the msg here only to test, later shall be moved to a common file
- self.hd_simulator.cmd_send_general_progress_data(131, timeout_total, timeout_countdown, False)
+ self.hd_simulator.cmd_send_dg_disinfect_progress_time_flush(timeout_total, timeout_countdown)
@Slot()
def do_data_heat(self):
@@ -155,8 +150,7 @@
"""
timeout_total = self.sldTimeoutTotalHeat.value()
timeout_countdown = self.sldTimeoutCountDownHeat.value()
- # The FW enums have not been defined yet so put the msg here only to test, later shall be moved to a common file
- self.hd_simulator.cmd_send_general_progress_data(132, timeout_total, timeout_countdown, False)
+ self.hd_simulator.cmd_send_dg_disinfect_progress_time_heat(timeout_total, timeout_countdown)
@Slot()
def do_data_chemical(self):
@@ -167,5 +161,4 @@
"""
timeout_total = self.sldTimeoutTotalChemical.value()
timeout_countdown = self.sldTimeoutCountDownChemical.value()
- # The FW enums have not been defined yet so put the msg here only to test, later shall be moved to a common file
- self.hd_simulator.cmd_send_general_progress_data(133, timeout_total, timeout_countdown, False)
+ self.hd_simulator.cmd_send_dg_disinfect_progress_time_checmical(timeout_total, timeout_countdown)