Index: DD_Conductivity/loader.py =================================================================== diff -u -r736bbf411c3a020f656991ae826ed4b2389dfe81 -r639e60ab542d69ff6c7b489c0e86bef287519c32 --- DD_Conductivity/loader.py (.../loader.py) (revision 736bbf411c3a020f656991ae826ed4b2389dfe81) +++ DD_Conductivity/loader.py (.../loader.py) (revision 639e60ab542d69ff6c7b489c0e86bef287519c32) @@ -1,5 +1,5 @@ """ - The TD Air Trap Mode ui loader + The DD Conductivity ui loader """ # Python import os Index: FP_BoostPump/interface.ui =================================================================== diff -u --- FP_BoostPump/interface.ui (revision 0) +++ FP_BoostPump/interface.ui (revision 639e60ab542d69ff6c7b489c0e86bef287519c32) @@ -0,0 +1,314 @@ + + + ui_interface + + + + 0 + 0 + 474 + 358 + + + + + 0 + 0 + + + + + 476 + 250 + + + + &7 FP info/&5 Boost Pump + + + + + + 2 + + + + + + 0 + 0 + + + + + 352 + 0 + + + + + 10 + + + + color: rgb(238, 238, 236); +background-color: rgb(137, 0, 213) + + + 80 : [0x5000] : FP RO Pump (P40) + + + Qt::AlignCenter + + + + + + + Send + + + + + + + reset + + + + + + + + + + + + + + 160 + 0 + + + + State + + + + + + + 5000 + + + + + + + + + + + + 160 + 0 + + + + Duty Cycle + + + + + + + 500 + + + + + + + + + + + + 160 + 0 + + + + Feedback Duty Cycle + + + + + + + 500 + + + + + + + + + + + + 160 + 0 + + + + RPM + + + + + + + 500.000000000000000 + + + + + + + + + + + + 160 + 0 + + + + Target Pressure + + + + + + + + + + + + + + + 160 + 0 + + + + Measured Flow + + + + + + + 500.000000000000000 + + + + + + + + + + + + 160 + 0 + + + + Target Duty Cycle + + + + + + + 500.000000000000000 + + + + + + + + + + + + 160 + 0 + + + + Duty Cycle % + + + + + + + 100.000000000000000 + + + + + + + + + + + + 160 + 0 + + + + Feedback Duty Cycle % + + + + + + + 100.000000000000000 + + + + + + + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + + Index: FP_BoostPump/loader.py =================================================================== diff -u --- FP_BoostPump/loader.py (revision 0) +++ FP_BoostPump/loader.py (revision 639e60ab542d69ff6c7b489c0e86bef287519c32) @@ -0,0 +1,97 @@ +""" + The FP Boost Pumps ui loader +""" +# Python +import os + +# Qt +from PySide2 import QtCore, QtWidgets +from PySide2.QtCore import Slot + +# parent +from engine.dynamicloader import DynamicLoader + +# fp Simulator +from leahi_dialin.ui.fp_messaging import FP_Messaging + + +class Loader(DynamicLoader): + """ + The FP Boost Pumps ui loader + """ + + def __init__(self): + self.fp_interface = FP_Messaging() + super().__init__(os.path.dirname(__file__)) + + + def _init_loader(self): + """ + finds and creates widgets + :return: none + """ + self.tbReset = self.find_widget(QtWidgets.QToolButton , 'tbReset' ) + self.tbSend = self.find_widget(QtWidgets.QToolButton , 'tbSend' ) + + self.sbP40State = self.find_widget(QtWidgets.QSpinBox , 'sbP40State' ) + self.sbP40DutyCycle = self.find_widget(QtWidgets.QSpinBox , 'sbP40DutyCycle' ) + self.sbP40FBDutyCycle = self.find_widget(QtWidgets.QSpinBox , 'sbP40FBDutyCycle' ) + self.dsbP40RPM = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP40RPM' ) + self.dsbP40TargetPressure = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP40TargetPressure' ) + self.dsbP40MeasuredFlow = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP40MeasuredFlow' ) + self.dsbP40TargetDutyCycle = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP40TargetDutyCycle' ) + self.dsbP40DutyCyclePct = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP40DutyCyclePct' ) + self.dsbP40FBDutyCyclePct = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP40FBDutyCyclePct' ) + + def _init_connections(self): + """ + initializes the widgets connections + :return: none + """ + self.tbReset.clicked.connect(self._init_widgets) + self.tbSend.clicked.connect(self.do_fp_boost_pump) + + @Slot() + def _init_widgets(self): + """ + initializes the widgets' properties + :return: none + """ + self.sbP40State .setValue(0) + self.sbP40DutyCycle .setValue(0) + self.sbP40FBDutyCycle .setValue(0) + self.dsbP40RPM .setValue(0) + self.dsbP40TargetPressure .setValue(0) + self.dsbP40MeasuredFlow .setValue(0) + self.dsbP40TargetDutyCycle .setValue(0) + self.dsbP40DutyCyclePct .setValue(0) + self.dsbP40FBDutyCyclePct .setValue(0) + + @Slot() + def do_fp_boost_pump(self): + """ + the slot for fp Boost Pump change + :return: none + """ + + p12PumpState = self.sbP40State .value() + p12PumpDutyCycle = self.sbP40DutyCycle .value() + p12PumpFBDutyCycle = self.sbP40FBDutyCycle .value() + p12PumpSpeed = self.dsbP40RPM .value() + p12TargetPressure = self.dsbP40TargetPressure .value() + p12TargetFlow = self.dsbP40MeasuredFlow .value() + p12TargetDutyCycle = self.dsbP40TargetDutyCycle .value() + p12PumpDutyCyclePct = self.dsbP40DutyCyclePct .value() + p12PumpFBDutyCyclePct = self.dsbP40FBDutyCyclePct .value() + + self.fp_interface.fp_boost_pump( + p12PumpState , + p12PumpDutyCycle , + p12PumpFBDutyCycle , + p12PumpSpeed , + p12TargetPressure , + p12TargetFlow , + p12TargetDutyCycle , + p12PumpDutyCyclePct , + p12PumpFBDutyCyclePct + ) \ No newline at end of file Index: FP_Conductivity/interface.ui =================================================================== diff -u --- FP_Conductivity/interface.ui (revision 0) +++ FP_Conductivity/interface.ui (revision 639e60ab542d69ff6c7b489c0e86bef287519c32) @@ -0,0 +1,136 @@ + + + ui_interface + + + + 0 + 0 + 581 + 116 + + + + + 0 + 0 + + + + + 476 + 250 + + + + &7 FP info/&3 Conductivity + + + + + + 2 + + + + + + 0 + 0 + + + + + 352 + 0 + + + + + 10 + + + + color: rgb(238, 238, 236); +background-color: rgb(173, 127, 168) + + + 55 : [0x3700] : FP Conductivity + + + Qt::AlignCenter + + + + + + + Send + + + + + + + reset + + + + + + + + + + + Conductivity 2 (P18) + + + + + + + 1000.000000000000000 + + + + + + + 1000.000000000000000 + + + + + + + Conductivity 1 (P8) + + + + + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + dsbp9Conductivity + dsbp18Conductivity + tbSend + tbReset + + + + Index: FP_Conductivity/loader.py =================================================================== diff -u --- FP_Conductivity/loader.py (revision 0) +++ FP_Conductivity/loader.py (revision 639e60ab542d69ff6c7b489c0e86bef287519c32) @@ -0,0 +1,68 @@ +""" + The FP Conductivity ui loader +""" +# Python +import os + +# Qt +from PySide2 import QtCore, QtWidgets +from PySide2.QtCore import Slot + +# parent +from engine.dynamicloader import DynamicLoader + +# fp Simulator +from leahi_dialin.ui.fp_messaging import FP_Messaging + + +class Loader(DynamicLoader): + """ + The FP Conductivity + """ + + def __init__(self): + self.fp_interface = FP_Messaging() + super().__init__(os.path.dirname(__file__)) + + + def _init_loader(self): + """ + finds and creates widgets + :return: none + """ + self.tbReset = self.find_widget(QtWidgets.QToolButton , 'tbReset' ) + self.tbSend = self.find_widget(QtWidgets.QToolButton , 'tbSend' ) + + self.dsbp9Conductivity = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbp9Conductivity' ) + self.dsbp18Conductivity = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbp18Conductivity' ) + + def _init_connections(self): + """ + initializes the widgets connections + :return: none + """ + self.tbReset.clicked.connect(self._init_widgets) + self.tbSend.clicked.connect(self.do_conductivity) + + @Slot() + def _init_widgets(self): + """ + initializes the widgets' properties + :return: none + """ + self.dsbp9Conductivity .setValue(0) + self.dsbp18Conductivity .setValue(0) + + @Slot() + def do_conductivity(self): + """ + the slot for FP conductivity change + :return: none + """ + p9Conductivity = self.dsbp9Conductivity .value() + p18Conductivity = self.dsbp18Conductivity.value() + + self.fp_interface.fp_conductivity( + p9Conductivity , + p18Conductivity + ) \ No newline at end of file Index: FP_Flow/interface.ui =================================================================== diff -u --- FP_Flow/interface.ui (revision 0) +++ FP_Flow/interface.ui (revision 639e60ab542d69ff6c7b489c0e86bef287519c32) @@ -0,0 +1,202 @@ + + + ui_interface + + + + 0 + 0 + 519 + 188 + + + + + 0 + 0 + + + + + 476 + 250 + + + + &7 FP info/&7 Flows + + + + + + 2 + + + + + + 0 + 0 + + + + + 352 + 0 + + + + + 10 + + + + color: rgb(238, 238, 236); +background-color: rgb(79, 30, 109) + + + 54 : [0x3600] : FP Flows + + + Qt::AlignCenter + + + + + + + Send + + + + + + + reset + + + + + + + + + + + + + + 180 + 0 + + + + Water Inlet Flow (P7) + + + + + + + + + + + + + + + 180 + 0 + + + + Water Inlet Temperature (P7) + + + + + + + 500.000000000000000 + + + + + + + + + + + + 180 + 0 + + + + RO Filter Outlet (P16) + + + + + + + 500.000000000000000 + + + + + + + + + + + + 180 + 0 + + + + RO Filter Outlet Temperature (P16) + + + + + + + 100.000000000000000 + + + + + + + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + dsbP7WaterInletFlow + dsbP16ROOutletFlow + dsbP7WaterInletTemp + dsbP16ROOutletTemp + tbSend + tbReset + + + + Index: FP_Flow/loader.py =================================================================== diff -u --- FP_Flow/loader.py (revision 0) +++ FP_Flow/loader.py (revision 639e60ab542d69ff6c7b489c0e86bef287519c32) @@ -0,0 +1,76 @@ +""" + The FP Flow ui loader +""" +# Python +import os + +# Qt +from PySide2 import QtCore, QtWidgets +from PySide2.QtCore import Slot + +# parent +from engine.dynamicloader import DynamicLoader + +# fp Simulator +from leahi_dialin.ui.fp_messaging import FP_Messaging + + +class Loader(DynamicLoader): + """ + The FP Flow ui loader + """ + + def __init__(self): + self.fp_interface = FP_Messaging() + super().__init__(os.path.dirname(__file__)) + + + def _init_loader(self): + """ + finds and creates widgets + :return: none + """ + self.tbReset = self.find_widget(QtWidgets.QToolButton , 'tbReset' ) + self.tbSend = self.find_widget(QtWidgets.QToolButton , 'tbSend' ) + + self.dsbP7WaterInletFlow = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP7WaterInletFlow' ) + self.dsbP7WaterInletTemp = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP7WaterInletTemp' ) + self.dsbP16ROOutletFlow = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP16ROOutletFlow' ) + self.dsbP16ROOutletTemp = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP16ROOutletTemp' ) + + def _init_connections(self): + """ + initializes the widgets connections + :return: none + """ + self.tbReset.clicked.connect(self._init_widgets) + self.tbSend.clicked.connect(self.do_fp_flow) + + @Slot() + def _init_widgets(self): + """ + initializes the widgets' properties + :return: none + """ + self.dsbP7WaterInletFlow .setValue(0) + self.dsbP7WaterInletTemp .setValue(0) + self.dsbP16ROOutletFlow .setValue(0) + self.dsbP16ROOutletTemp .setValue(0) + + @Slot() + def do_fp_flow(self): + """ + the slot for fp Boost Pump change + :return: none + """ + p7Flow = self.dsbP7WaterInletFlow .value() + p16Flow = self.dsbP16ROOutletFlow .value() + p7Temp = self.dsbP7WaterInletTemp .value() + p16Temp = self.dsbP16ROOutletTemp .value() + + self.fp_interface.fp_flow_sensors( + p7Flow , + p16Flow , + p7Temp , + p16Temp + ) \ No newline at end of file Index: FP_Levels/interface.ui =================================================================== diff -u --- FP_Levels/interface.ui (revision 0) +++ FP_Levels/interface.ui (revision 639e60ab542d69ff6c7b489c0e86bef287519c32) @@ -0,0 +1,147 @@ + + + ui_interface + + + + 0 + 0 + 476 + 77 + + + + + 0 + 0 + + + + + 476 + 250 + + + + &7 FP info/&6 FP Levels + + + + 4 + + + 0 + + + + + + + 2 + + + + + + 0 + 0 + + + + + 352 + 0 + + + + + 10 + + + + color: rgb(238, 238, 236); +background-color: rgb(165, 112, 184) + + + 53 : [0x3500] : FP Level + + + Qt::AlignCenter + + + + + + + Send + + + + + + + reset + + + + + + + + + + + QLayout::SetMaximumSize + + + 10 + + + 10 + + + 0 + + + + + Floater Level (P25) + + + + + + + 1000 + + + + + + + + + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + sbFloaterLevel + tbSend + tbReset + + + + Index: FP_Levels/loader.py =================================================================== diff -u --- FP_Levels/loader.py (revision 0) +++ FP_Levels/loader.py (revision 639e60ab542d69ff6c7b489c0e86bef287519c32) @@ -0,0 +1,64 @@ +""" + The FP Levels ui loader +""" +# Python +import os + +# Qt +from PySide2 import QtCore, QtWidgets +from PySide2.QtCore import Slot + +# parent +from engine.dynamicloader import DynamicLoader + +# fp Simulator +from leahi_dialin.ui.fp_messaging import FP_Messaging + + +class Loader(DynamicLoader): + """ + The FP Levels ui loader + """ + + def __init__(self): + self.fp_interface = FP_Messaging() + super().__init__(os.path.dirname(__file__)) + + + def _init_loader(self): + """ + finds and creates widgets + :return: none + """ + self.tbReset = self.find_widget(QtWidgets.QToolButton , 'tbReset' ) + self.tbSend = self.find_widget(QtWidgets.QToolButton , 'tbSend' ) + + self.sbFloaterLevel = self.find_widget(QtWidgets.QSpinBox , 'sbFloaterLevel' ) + + def _init_connections(self): + """ + initializes the widgets connections + :return: none + """ + self.tbReset.clicked.connect(self._init_widgets) + self.tbSend.clicked.connect(self.do_fp_level_sensors) + + @Slot() + def _init_widgets(self): + """ + initializes the widgets' properties + :return: none + """ + self.sbFloaterLevel .setValue(0) + + @Slot() + def do_fp_level_sensors(self): + """ + the slot for fp level sensor change + :return: none + """ + p25Level = self.sbFloaterLevel .value() + + self.fp_interface.fp_level( + p25Level + ) \ No newline at end of file Index: FP_ROPump/interface.ui =================================================================== diff -u --- FP_ROPump/interface.ui (revision 0) +++ FP_ROPump/interface.ui (revision 639e60ab542d69ff6c7b489c0e86bef287519c32) @@ -0,0 +1,339 @@ + + + ui_interface + + + + 0 + 0 + 474 + 364 + + + + + 0 + 0 + + + + + 476 + 250 + + + + &7 FP info/&4 RO Pump + + + + + + 2 + + + + + + 0 + 0 + + + + + 352 + 0 + + + + + 10 + + + + color: rgb(238, 238, 236); +background-color: rgb(117, 12, 149) + + + 50 : [0x3200] : FP RO Pump (P12) + + + Qt::AlignCenter + + + + + + + Send + + + + + + + reset + + + + + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + + + + + + 160 + 0 + + + + State + + + + + + + 5000 + + + + + + + + + + + + 160 + 0 + + + + Duty Cycle + + + + + + + 500 + + + + + + + + + + + + 160 + 0 + + + + Feedback Duty Cycle + + + + + + + 500 + + + + + + + + + + + + 160 + 0 + + + + RPM + + + + + + + 500.000000000000000 + + + + + + + + + + + + 160 + 0 + + + + Target Pressure + + + + + + + + + + + + + + + 160 + 0 + + + + Measured Flow + + + + + + + 500.000000000000000 + + + + + + + + + + + + 160 + 0 + + + + Target Duty Cycle + + + + + + + 500.000000000000000 + + + + + + + + + + + + 160 + 0 + + + + Duty Cycle % + + + + + + + 100.000000000000000 + + + + + + + + + + + + 160 + 0 + + + + Feedback Duty Cycle % + + + + + + + 100.000000000000000 + + + + + + + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + dsbP12RPM + sbP12State + dsbP12TargetPressure + dsbP12MeasuredFlow + sbP12FBDutyCycle + dsbP12DutyCyclePct + dsbP12TargetDutyCycle + sbP12DutyCycle + tbSend + tbReset + + + + Index: FP_ROPump/loader.py =================================================================== diff -u --- FP_ROPump/loader.py (revision 0) +++ FP_ROPump/loader.py (revision 639e60ab542d69ff6c7b489c0e86bef287519c32) @@ -0,0 +1,97 @@ +""" + The FP RO Pumps ui loader +""" +# Python +import os + +# Qt +from PySide2 import QtCore, QtWidgets +from PySide2.QtCore import Slot + +# parent +from engine.dynamicloader import DynamicLoader + +# fp Simulator +from leahi_dialin.ui.fp_messaging import FP_Messaging + + +class Loader(DynamicLoader): + """ + The FP RO Pumps ui loader + """ + + def __init__(self): + self.fp_interface = FP_Messaging() + super().__init__(os.path.dirname(__file__)) + + + def _init_loader(self): + """ + finds and creates widgets + :return: none + """ + self.tbReset = self.find_widget(QtWidgets.QToolButton , 'tbReset' ) + self.tbSend = self.find_widget(QtWidgets.QToolButton , 'tbSend' ) + + self.sbP12State = self.find_widget(QtWidgets.QSpinBox , 'sbP12State' ) + self.sbP12DutyCycle = self.find_widget(QtWidgets.QSpinBox , 'sbP12DutyCycle' ) + self.sbP12FBDutyCycle = self.find_widget(QtWidgets.QSpinBox , 'sbP12FBDutyCycle' ) + self.dsbP12RPM = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP12RPM' ) + self.dsbP12TargetPressure = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP12TargetPressure' ) + self.dsbP12MeasuredFlow = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP12MeasuredFlow' ) + self.dsbP12TargetDutyCycle = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP12TargetDutyCycle' ) + self.dsbP12DutyCyclePct = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP12DutyCyclePct' ) + self.dsbP12FBDutyCyclePct = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP12FBDutyCyclePct' ) + + def _init_connections(self): + """ + initializes the widgets connections + :return: none + """ + self.tbReset.clicked.connect(self._init_widgets) + self.tbSend.clicked.connect(self.do_fp_ro_pump) + + @Slot() + def _init_widgets(self): + """ + initializes the widgets' properties + :return: none + """ + self.sbP12State .setValue(0) + self.sbP12DutyCycle .setValue(0) + self.sbP12FBDutyCycle .setValue(0) + self.dsbP12RPM .setValue(0) + self.dsbP12TargetPressure .setValue(0) + self.dsbP12MeasuredFlow .setValue(0) + self.dsbP12TargetDutyCycle .setValue(0) + self.dsbP12DutyCyclePct .setValue(0) + self.dsbP12FBDutyCyclePct .setValue(0) + + @Slot() + def do_fp_ro_pump(self): + """ + the slot for fp RO Pump change + :return: none + """ + + p12PumpState = self.sbP12State .value() + p12PumpDutyCycle = self.sbP12DutyCycle .value() + p12PumpFBDutyCycle = self.sbP12FBDutyCycle .value() + p12PumpSpeed = self.dsbP12RPM .value() + p12TargetPressure = self.dsbP12TargetPressure .value() + p12TargetFlow = self.dsbP12MeasuredFlow .value() + p12TargetDutyCycle = self.dsbP12TargetDutyCycle .value() + p12PumpDutyCyclePct = self.dsbP12DutyCyclePct .value() + p12PumpFBDutyCyclePct = self.dsbP12FBDutyCyclePct .value() + + self.fp_interface.fp_ro_pump( + p12PumpState , + p12PumpDutyCycle , + p12PumpFBDutyCycle , + p12PumpSpeed , + p12TargetPressure , + p12TargetFlow , + p12TargetDutyCycle , + p12PumpDutyCyclePct , + p12PumpFBDutyCyclePct + ) \ No newline at end of file Index: FP_Temperature/interface.ui =================================================================== diff -u --- FP_Temperature/interface.ui (revision 0) +++ FP_Temperature/interface.ui (revision 639e60ab542d69ff6c7b489c0e86bef287519c32) @@ -0,0 +1,431 @@ + + + ui_interface + + + + 0 + 0 + 1043 + 466 + + + + + 0 + 0 + + + + + 476 + 250 + + + + &7 FP info/&8 Temperatures + + + + + + 2 + + + + + + 0 + 0 + + + + + 352 + 0 + + + + + 10 + + + + color: rgb(238, 238, 236); +background-color: rgb(49, 6, 77) + + + 57 : [0x3900] : FP Temperatures + + + Qt::AlignCenter + + + + + + + Send + + + + + + + reset + + + + + + + + + + + + + + 230 + 0 + + + + Inlet conductivity (P10) + + + + + + + 10000.000000000000000 + + + + + + + + + + + + 230 + 0 + + + + Before RO Pump (X1) + + + + + + + 10000.000000000000000 + + + + + + + + + + + + 230 + 0 + + + + Outlet Conductivity (P19) + + + + + + + 10000.000000000000000 + + + + + + + + + + + + 230 + 0 + + + + RO Concentrate (X2) + + + + + + + 10000.000000000000000 + + + + + + + + + + + + 230 + 0 + + + + Before Pressure Regulator (M1) + + + + + + + 10000.000000000000000 + + + + + + + + + + + + 230 + 0 + + + + RO Concentrate Pump (X3) + + + + + + + 10000.000000000000000 + + + + + + + + + + + + 230 + 0 + + + + After Pressure Regulator (M3) + + + + + + + 10000.000000000000000 + + + + + + + + + + + + 230 + 0 + + + + Drain Drop (X4) + + + + + + + 10000.000000000000000 + + + + + + + + + + + + 230 + 0 + + + + Before Inlet Conductivity (P8) + + + + + + + 10000.000000000000000 + + + + + + + + + + + + 230 + 0 + + + + RO Inlet (P7) + + + + + + + 10000.000000000000000 + + + + + + + + + + + + 230 + 0 + + + + Before RO Filter (P13) + + + + + + + 10000.000000000000000 + + + + + + + + + + + + 230 + 0 + + + + RO Outlet (P16) + + + + + + + 10000.000000000000000 + + + + + + + + + + + + 230 + 0 + + + + After RO Filter (P17) + + + + + + + 10000.000000000000000 + + + + + + + + + + + Qt::Vertical + + + + 20 + 40 + + + + + + + + dsbP10InletConductivity + dsbP19OutletConductivity + dsbM1BeforePressureRegulator + dsbM3AfterPressureRegulator + dsbP8BeforeInletConductivity + dsbP13ROFilter + dsbP17AfterROFilter + dsbX1BeforeROPump + dsbX2ROConcentrate + dsbX3ROConcentratePump + dsbX4DrainDrop + dsbP7ROInlet + dsbP16ROOutlet + tbSend + tbReset + + + + Index: FP_Temperature/loader.py =================================================================== diff -u --- FP_Temperature/loader.py (revision 0) +++ FP_Temperature/loader.py (revision 639e60ab542d69ff6c7b489c0e86bef287519c32) @@ -0,0 +1,113 @@ +""" + The FP temperature ui loader +""" +# Python +import os + +# Qt +from PySide2 import QtCore, QtWidgets +from PySide2.QtCore import Slot + +# parent +from engine.dynamicloader import DynamicLoader + +# fp Simulator +from leahi_dialin.ui.fp_messaging import FP_Messaging + + +class Loader(DynamicLoader): + """ + The FP temperature ui loader + """ + + def __init__(self): + self.fp_interface = FP_Messaging() + super().__init__(os.path.dirname(__file__)) + + + def _init_loader(self): + """ + finds and creates widgets + :return: none + """ + self.tbReset = self.find_widget(QtWidgets.QToolButton , 'tbReset' ) + self.tbSend = self.find_widget(QtWidgets.QToolButton , 'tbSend' ) + + self.dsbP10InletConductivity = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP10InletConductivity' ) + self.dsbP19OutletConductivity = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP19OutletConductivity' ) + self.dsbM1BeforePressureRegulator = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbM1BeforePressureRegulator' ) + self.dsbM3AfterPressureRegulator = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbM3AfterPressureRegulator' ) + self.dsbP8BeforeInletConductivity = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP8BeforeInletConductivity' ) + self.dsbP13ROFilter = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP13ROFilter' ) + self.dsbP17AfterROFilter = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP17AfterROFilter' ) + self.dsbX1BeforeROPump = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbX1BeforeROPump' ) + self.dsbX2ROConcentrate = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbX2ROConcentrate' ) + self.dsbX3ROConcentratePump = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbX3ROConcentratePump' ) + self.dsbX4DrainDrop = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbX4DrainDrop' ) + self.dsbP7ROInlet = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP7ROInlet' ) + self.dsbP16ROOutlet = self.find_widget(QtWidgets.QDoubleSpinBox , 'dsbP16ROOutlet' ) + + def _init_connections(self): + """ + initializes the widgets connections + :return: none + """ + self.tbReset.clicked.connect(self._init_widgets) + self.tbSend.clicked.connect(self.do_fp_temperature) + + @Slot() + def _init_widgets(self): + """ + initializes the widgets' properties + :return: none + """ + self.dsbP10InletConductivity .setValue(0) + self.dsbP19OutletConductivity .setValue(0) + self.dsbM1BeforePressureRegulator .setValue(0) + self.dsbM3AfterPressureRegulator .setValue(0) + self.dsbP8BeforeInletConductivity .setValue(0) + self.dsbP13ROFilter .setValue(0) + self.dsbP17AfterROFilter .setValue(0) + self.dsbX1BeforeROPump .setValue(0) + self.dsbX2ROConcentrate .setValue(0) + self.dsbX3ROConcentratePump .setValue(0) + self.dsbX4DrainDrop .setValue(0) + self.dsbP7ROInlet .setValue(0) + self.dsbP16ROOutlet .setValue(0) + + @Slot() + def do_fp_temperature(self): + """ + the slot for fp temperature change + :return: none + """ + + p10Temp = self.dsbP10InletConductivity .value() + p19Temp = self.dsbP19OutletConductivity .value() + m1Temp = self.dsbM1BeforePressureRegulator .value() + m3Temp = self.dsbM3AfterPressureRegulator .value() + p8Temp = self.dsbP8BeforeInletConductivity .value() + p13Temp = self.dsbP13ROFilter .value() + p17Temp = self.dsbP17AfterROFilter .value() + x1Temp = self.dsbX1BeforeROPump .value() + x2Temp = self.dsbX2ROConcentrate .value() + x3Temp = self.dsbX3ROConcentratePump .value() + x4Temp = self.dsbX4DrainDrop .value() + p7Temp = self.dsbP7ROInlet .value() + p16Temp = self.dsbP16ROOutlet .value() + + self.fp_interface.fp_temperature( + p10Temp , + p19Temp , + m1Temp , + m3Temp , + p8Temp , + p13Temp , + p17Temp , + x1Temp , + x2Temp , + x3Temp , + x4Temp , + p7Temp , + p16Temp + ) \ No newline at end of file