diff --git a/pytec/tec_qt.py b/pytec/tec_qt.py index 7334265..a46daed 100644 --- a/pytec/tec_qt.py +++ b/pytec/tec_qt.py @@ -315,6 +315,8 @@ class MainWindow(QtWidgets.QMainWindow, Ui_MainWindow): self.actionReset.triggered.connect(reset_thermostat) self.menu.addAction(self.actionReset) + self.menu.addAction(self.actionEnter_DFU_Mode) + self.thermostat_settings.setMenu(self.menu) self.plot_menu = QtWidgets.QMenu() diff --git a/pytec/tec_qt.ui b/pytec/tec_qt.ui index aa28348..c894598 100644 --- a/pytec/tec_qt.ui +++ b/pytec/tec_qt.ui @@ -460,6 +460,17 @@ QAction::NoRole + + + Enter DFU Mode + + + Reset thermostat and enter USB device firmware update (DFU) mode + + + QAction::NoRole + + diff --git a/pytec/ui_tec_qt.py b/pytec/ui_tec_qt.py index a6b44b9..7c10a57 100644 --- a/pytec/ui_tec_qt.py +++ b/pytec/ui_tec_qt.py @@ -198,6 +198,9 @@ class Ui_MainWindow(object): self.actionReset = QtGui.QAction(parent=MainWindow) self.actionReset.setMenuRole(QtGui.QAction.MenuRole.NoRole) self.actionReset.setObjectName("actionReset") + self.actionEnter_DFU_Mode = QtGui.QAction(parent=MainWindow) + self.actionEnter_DFU_Mode.setMenuRole(QtGui.QAction.MenuRole.NoRole) + self.actionEnter_DFU_Mode.setObjectName("actionEnter_DFU_Mode") self.retranslateUi(MainWindow) QtCore.QMetaObject.connectSlotsByName(MainWindow) @@ -218,6 +221,8 @@ class Ui_MainWindow(object): self.report_apply_btn.setText(_translate("MainWindow", "Apply")) self.actionReset.setText(_translate("MainWindow", "Reset")) self.actionReset.setToolTip(_translate("MainWindow", "Reset the Thermostat")) + self.actionEnter_DFU_Mode.setText(_translate("MainWindow", "Enter DFU Mode")) + self.actionEnter_DFU_Mode.setToolTip(_translate("MainWindow", "Reset thermostat and enter USB device firmware update (DFU) mode")) from pglive.sources.live_plot_widget import LivePlotWidget from pyqtgraph.parametertree import ParameterTree