# -*- coding: utf-8 -*-

# Form implementation generated from reading ui file 'brickv/plugin_system/plugins/analog_in_v3/ui/calibration.ui'
#
# Created by: PyQt5 UI code generator 5.15.6
#
# WARNING: Any manual changes made to this file will be lost when pyuic5 is
# run again.  Do not edit this file unless you know what you are doing.


from PyQt5 import QtCore, QtGui, QtWidgets


class Ui_Calibration(object):
    def setupUi(self, Calibration):
        Calibration.setObjectName("Calibration")
        Calibration.resize(354, 548)
        self.verticalLayout_2 = QtWidgets.QVBoxLayout(Calibration)
        self.verticalLayout_2.setObjectName("verticalLayout_2")
        self.grid = QtWidgets.QGridLayout()
        self.grid.setObjectName("grid")
        self.button_cal_remove = QtWidgets.QPushButton(Calibration)
        self.button_cal_remove.setObjectName("button_cal_remove")
        self.grid.addWidget(self.button_cal_remove, 6, 0, 1, 3)
        self.line_3 = QtWidgets.QFrame(Calibration)
        self.line_3.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_3.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_3.setObjectName("line_3")
        self.grid.addWidget(self.line_3, 4, 0, 1, 3)
        self.line_2 = QtWidgets.QFrame(Calibration)
        self.line_2.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_2.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_2.setObjectName("line_2")
        self.grid.addWidget(self.line_2, 10, 0, 1, 3)
        self.button_cal_gain = QtWidgets.QPushButton(Calibration)
        self.button_cal_gain.setObjectName("button_cal_gain")
        self.grid.addWidget(self.button_cal_gain, 13, 0, 1, 3)
        self.label = QtWidgets.QLabel(Calibration)
        self.label.setObjectName("label")
        self.grid.addWidget(self.label, 0, 0, 1, 1)
        self.label_14 = QtWidgets.QLabel(Calibration)
        self.label_14.setTextFormat(QtCore.Qt.AutoText)
        self.label_14.setScaledContents(False)
        self.label_14.setWordWrap(True)
        self.label_14.setObjectName("label_14")
        self.grid.addWidget(self.label_14, 8, 0, 1, 3)
        self.label_offset = QtWidgets.QLabel(Calibration)
        self.label_offset.setObjectName("label_offset")
        self.grid.addWidget(self.label_offset, 1, 1, 1, 2)
        self.line = QtWidgets.QFrame(Calibration)
        self.line.setFrameShape(QtWidgets.QFrame.HLine)
        self.line.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line.setObjectName("line")
        self.grid.addWidget(self.line, 7, 0, 1, 3)
        self.label_16 = QtWidgets.QLabel(Calibration)
        self.label_16.setObjectName("label_16")
        self.grid.addWidget(self.label_16, 12, 0, 1, 1)
        self.label_15 = QtWidgets.QLabel(Calibration)
        self.label_15.setWordWrap(True)
        self.label_15.setObjectName("label_15")
        self.grid.addWidget(self.label_15, 11, 0, 1, 3)
        self.label_voltage = QtWidgets.QLabel(Calibration)
        self.label_voltage.setObjectName("label_voltage")
        self.grid.addWidget(self.label_voltage, 0, 1, 1, 2)
        self.spinbox_voltage = QtWidgets.QSpinBox(Calibration)
        self.spinbox_voltage.setMaximum(42000)
        self.spinbox_voltage.setObjectName("spinbox_voltage")
        self.grid.addWidget(self.spinbox_voltage, 12, 1, 1, 2)
        self.label_2 = QtWidgets.QLabel(Calibration)
        self.label_2.setObjectName("label_2")
        self.grid.addWidget(self.label_2, 3, 0, 1, 1)
        self.label_4 = QtWidgets.QLabel(Calibration)
        self.label_4.setObjectName("label_4")
        self.grid.addWidget(self.label_4, 1, 0, 1, 1)
        self.button_cal_offset = QtWidgets.QPushButton(Calibration)
        self.button_cal_offset.setObjectName("button_cal_offset")
        self.grid.addWidget(self.button_cal_offset, 9, 0, 1, 3)
        self.label_8 = QtWidgets.QLabel(Calibration)
        self.label_8.setWordWrap(True)
        self.label_8.setObjectName("label_8")
        self.grid.addWidget(self.label_8, 5, 0, 1, 3)
        self.label_multiplier = QtWidgets.QLabel(Calibration)
        self.label_multiplier.setObjectName("label_multiplier")
        self.grid.addWidget(self.label_multiplier, 2, 1, 1, 2)
        self.label_divisor = QtWidgets.QLabel(Calibration)
        self.label_divisor.setObjectName("label_divisor")
        self.grid.addWidget(self.label_divisor, 3, 1, 1, 2)
        self.label_7 = QtWidgets.QLabel(Calibration)
        self.label_7.setObjectName("label_7")
        self.grid.addWidget(self.label_7, 2, 0, 1, 1)
        self.button_close = QtWidgets.QPushButton(Calibration)
        self.button_close.setObjectName("button_close")
        self.grid.addWidget(self.button_close, 16, 0, 1, 3)
        self.line_4 = QtWidgets.QFrame(Calibration)
        self.line_4.setFrameShape(QtWidgets.QFrame.HLine)
        self.line_4.setFrameShadow(QtWidgets.QFrame.Sunken)
        self.line_4.setObjectName("line_4")
        self.grid.addWidget(self.line_4, 14, 0, 1, 3)
        spacerItem = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding)
        self.grid.addItem(spacerItem, 15, 0, 1, 1)
        self.verticalLayout_2.addLayout(self.grid)

        self.retranslateUi(Calibration)
        QtCore.QMetaObject.connectSlotsByName(Calibration)

    def retranslateUi(self, Calibration):
        _translate = QtCore.QCoreApplication.translate
        Calibration.setWindowTitle(_translate("Calibration", "Analog In Bricklet 3.0 Calibration"))
        self.button_cal_remove.setText(_translate("Calibration", "Remove Old Calibration"))
        self.button_cal_gain.setText(_translate("Calibration", "Calibrate Gain"))
        self.label.setText(_translate("Calibration", "Voltage:"))
        self.label_14.setText(_translate("Calibration", "Step 2: To calibrate offset connect VIN to GND and press \"Calibrate Offset\"."))
        self.label_offset.setText(_translate("Calibration", "0"))
        self.label_16.setText(_translate("Calibration", "Voltage:"))
        self.label_15.setText(_translate("Calibration", "Step 3: To calibrate gain apply a known voltage to VIN. Enter the known correct voltage below and press \"Calibrate Gain\"."))
        self.label_voltage.setText(_translate("Calibration", "0"))
        self.spinbox_voltage.setSuffix(_translate("Calibration", " mV"))
        self.label_2.setText(_translate("Calibration", "Gain Divisor:"))
        self.label_4.setText(_translate("Calibration", "Offset:"))
        self.button_cal_offset.setText(_translate("Calibration", "Calibrate Offset"))
        self.label_8.setText(_translate("Calibration", "Step 1: To recalibrate the Bricklet you have to remove the old calibration and then calibrate the offset first and gain second. For best result use highest oversampling during calibration."))
        self.label_multiplier.setText(_translate("Calibration", "0"))
        self.label_divisor.setText(_translate("Calibration", "0"))
        self.label_7.setText(_translate("Calibration", "Gain Multiplier:"))
        self.button_close.setText(_translate("Calibration", "Close"))
