- Calibration order is now consistently SOLIT in both GUI and assistant

pull/36/head
Rune Broberg 2019-10-03 14:27:53 +02:00
rodzic 56ec60b2c9
commit e6560ba1e1
1 zmienionych plików z 20 dodań i 19 usunięć

Wyświetl plik

@ -85,8 +85,8 @@ class CalibrationWindow(QtWidgets.QWidget):
calibration_control_layout.addRow(btn_cal_short, self.cal_short_label) calibration_control_layout.addRow(btn_cal_short, self.cal_short_label)
calibration_control_layout.addRow(btn_cal_open, self.cal_open_label) calibration_control_layout.addRow(btn_cal_open, self.cal_open_label)
calibration_control_layout.addRow(btn_cal_load, self.cal_load_label) calibration_control_layout.addRow(btn_cal_load, self.cal_load_label)
calibration_control_layout.addRow(btn_cal_through, self.cal_through_label)
calibration_control_layout.addRow(btn_cal_isolation, self.cal_isolation_label) calibration_control_layout.addRow(btn_cal_isolation, self.cal_isolation_label)
calibration_control_layout.addRow(btn_cal_through, self.cal_through_label)
calibration_control_layout.addRow(QtWidgets.QLabel("")) calibration_control_layout.addRow(QtWidgets.QLabel(""))
@ -460,15 +460,13 @@ class CalibrationWindow(QtWidgets.QWidget):
self.btn_automatic.setDisabled(False) self.btn_automatic.setDisabled(False)
return return
open_step = QtWidgets.QMessageBox(QtWidgets.QMessageBox.Information, short_step = QtWidgets.QMessageBox(QtWidgets.QMessageBox.Information,
"Calibrate open", "Calibrate short",
"Please connect the \"open\" standard to port 0 of the NanoVNA.\n\n" + "Please connect the \"short\" standard to port 0 of the NanoVNA.\n\n" +
"Either use a supplied open, or leave the end of the cable unconnected " +
"if desired.\n\n" +
"Press Ok when you are ready to continue.", "Press Ok when you are ready to continue.",
QtWidgets.QMessageBox.Ok | QtWidgets.QMessageBox.Cancel) QtWidgets.QMessageBox.Ok | QtWidgets.QMessageBox.Cancel)
response = open_step.exec() response = short_step.exec()
if response != QtWidgets.QMessageBox.Ok: if response != QtWidgets.QMessageBox.Ok:
self.btn_automatic.setDisabled(False) self.btn_automatic.setDisabled(False)
return return
@ -482,16 +480,19 @@ class CalibrationWindow(QtWidgets.QWidget):
if self.nextStep == -1: if self.nextStep == -1:
self.app.worker.signals.finished.disconnect(self.automaticCalibrationStep) self.app.worker.signals.finished.disconnect(self.automaticCalibrationStep)
if self.nextStep == 0: if self.nextStep == 0:
# Open # Short
self.saveOpen() self.saveShort()
self.nextStep = 1 self.nextStep = 1
short_step = QtWidgets.QMessageBox(QtWidgets.QMessageBox.Information,
"Calibrate short", open_step = QtWidgets.QMessageBox(QtWidgets.QMessageBox.Information,
"Please connect the \"short\" standard to port 0 of the NanoVNA.\n\n" + "Calibrate open",
"Please connect the \"open\" standard to port 0 of the NanoVNA.\n\n" +
"Either use a supplied open, or leave the end of the cable unconnected " +
"if desired.\n\n" +
"Press Ok when you are ready to continue.", "Press Ok when you are ready to continue.",
QtWidgets.QMessageBox.Ok | QtWidgets.QMessageBox.Cancel) QtWidgets.QMessageBox.Ok | QtWidgets.QMessageBox.Cancel)
response = short_step.exec() response = open_step.exec()
if response != QtWidgets.QMessageBox.Ok: if response != QtWidgets.QMessageBox.Ok:
self.nextStep = -1 self.nextStep = -1
self.btn_automatic.setDisabled(False) self.btn_automatic.setDisabled(False)
@ -502,8 +503,8 @@ class CalibrationWindow(QtWidgets.QWidget):
return return
elif self.nextStep == 1: elif self.nextStep == 1:
# Short # Open
self.saveShort() self.saveOpen()
self.nextStep = 2 self.nextStep = 2
load_step = QtWidgets.QMessageBox(QtWidgets.QMessageBox.Information, load_step = QtWidgets.QMessageBox(QtWidgets.QMessageBox.Information,
"Calibrate load", "Calibrate load",