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

# Form implementation generated from reading ui file 'single_channel_logger.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_Form(object):
    def setupUi(self, Form):
        Form.setObjectName("Form")
        Form.resize(803, 545)
        Form.setStyleSheet("#MyFrame {background-color: qlineargradient(spread:pad, x1:0, y1:0, x2:1, y2:0, stop:0 rgba(100, 0, 50, 255), stop:.9 rgba(255, 255, 255, 255));} ")
        self.verticalLayout = QtWidgets.QVBoxLayout(Form)
        self.verticalLayout.setContentsMargins(0, 0, 0, 0)
        self.verticalLayout.setSpacing(0)
        self.verticalLayout.setObjectName("verticalLayout")
        self.WidgetFrameOuter = QtWidgets.QFrame(Form)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.WidgetFrameOuter.sizePolicy().hasHeightForWidth())
        self.WidgetFrameOuter.setSizePolicy(sizePolicy)
        self.WidgetFrameOuter.setStyleSheet("")
        self.WidgetFrameOuter.setFrameShape(QtWidgets.QFrame.StyledPanel)
        self.WidgetFrameOuter.setFrameShadow(QtWidgets.QFrame.Raised)
        self.WidgetFrameOuter.setObjectName("WidgetFrameOuter")
        self.verticalLayout_4 = QtWidgets.QVBoxLayout(self.WidgetFrameOuter)
        self.verticalLayout_4.setContentsMargins(0, 0, 0, 0)
        self.verticalLayout_4.setSpacing(2)
        self.verticalLayout_4.setObjectName("verticalLayout_4")
        self.MyFrame = QtWidgets.QFrame(self.WidgetFrameOuter)
        self.MyFrame.setObjectName("MyFrame")
        self.verticalLayout_5 = QtWidgets.QVBoxLayout(self.MyFrame)
        self.verticalLayout_5.setContentsMargins(0, 0, 0, 0)
        self.verticalLayout_5.setSpacing(1)
        self.verticalLayout_5.setObjectName("verticalLayout_5")
        self.frame_6 = QtWidgets.QFrame(self.MyFrame)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.MinimumExpanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.frame_6.sizePolicy().hasHeightForWidth())
        self.frame_6.setSizePolicy(sizePolicy)
        self.frame_6.setMinimumSize(QtCore.QSize(0, 50))
        self.frame_6.setStyleSheet("#frame_6{background-color:rgb(238, 238, 236)}")
        self.frame_6.setFrameShape(QtWidgets.QFrame.StyledPanel)
        self.frame_6.setFrameShadow(QtWidgets.QFrame.Raised)
        self.frame_6.setObjectName("frame_6")
        self.gridLayout_5 = QtWidgets.QGridLayout(self.frame_6)
        self.gridLayout_5.setContentsMargins(2, 2, 2, 2)
        self.gridLayout_5.setHorizontalSpacing(2)
        self.gridLayout_5.setObjectName("gridLayout_5")
        self.scrollArea = QtWidgets.QScrollArea(self.frame_6)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Expanding, QtWidgets.QSizePolicy.MinimumExpanding)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.scrollArea.sizePolicy().hasHeightForWidth())
        self.scrollArea.setSizePolicy(sizePolicy)
        self.scrollArea.setWidgetResizable(True)
        self.scrollArea.setObjectName("scrollArea")
        self.scrollAreaWidgetContents = QtWidgets.QWidget()
        self.scrollAreaWidgetContents.setGeometry(QtCore.QRect(0, 0, 793, 535))
        self.scrollAreaWidgetContents.setObjectName("scrollAreaWidgetContents")
        self.gridLayout_6 = QtWidgets.QGridLayout(self.scrollAreaWidgetContents)
        self.gridLayout_6.setContentsMargins(2, 2, 2, 2)
        self.gridLayout_6.setSpacing(2)
        self.gridLayout_6.setObjectName("gridLayout_6")
        self.pushButton_2 = QtWidgets.QPushButton(self.scrollAreaWidgetContents)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.pushButton_2.sizePolicy().hasHeightForWidth())
        self.pushButton_2.setSizePolicy(sizePolicy)
        self.pushButton_2.setObjectName("pushButton_2")
        self.gridLayout_6.addWidget(self.pushButton_2, 8, 0, 1, 1)
        spacerItem = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding)
        self.gridLayout_6.addItem(spacerItem, 10, 0, 1, 1)
        self.pushButton = QtWidgets.QPushButton(self.scrollAreaWidgetContents)
        self.pushButton.setObjectName("pushButton")
        self.gridLayout_6.addWidget(self.pushButton, 13, 0, 1, 1)
        spacerItem1 = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding)
        self.gridLayout_6.addItem(spacerItem1, 7, 0, 1, 1)
        self.optionBox = QtWidgets.QComboBox(self.scrollAreaWidgetContents)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.optionBox.sizePolicy().hasHeightForWidth())
        self.optionBox.setSizePolicy(sizePolicy)
        self.optionBox.setObjectName("optionBox")
        self.optionBox.addItem("")
        self.optionBox.addItem("")
        self.gridLayout_6.addWidget(self.optionBox, 3, 0, 1, 1)
        self.msgwin = QtWidgets.QLabel(self.scrollAreaWidgetContents)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Maximum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.msgwin.sizePolicy().hasHeightForWidth())
        self.msgwin.setSizePolicy(sizePolicy)
        font = QtGui.QFont()
        font.setPointSize(9)
        self.msgwin.setFont(font)
        self.msgwin.setStyleSheet("QLabel{color:red}")
        self.msgwin.setObjectName("msgwin")
        self.gridLayout_6.addWidget(self.msgwin, 13, 2, 1, 1)
        self.pushButton_3 = QtWidgets.QPushButton(self.scrollAreaWidgetContents)
        self.pushButton_3.setObjectName("pushButton_3")
        self.gridLayout_6.addWidget(self.pushButton_3, 9, 0, 1, 1)
        self.checkBox_4 = QtWidgets.QCheckBox(self.scrollAreaWidgetContents)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Maximum, QtWidgets.QSizePolicy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.checkBox_4.sizePolicy().hasHeightForWidth())
        self.checkBox_4.setSizePolicy(sizePolicy)
        self.checkBox_4.setMinimumSize(QtCore.QSize(150, 25))
        self.checkBox_4.setStyleSheet("border : 2px solid green;")
        self.checkBox_4.setObjectName("checkBox_4")
        self.gridLayout_6.addWidget(self.checkBox_4, 6, 0, 1, 1)
        self.frame = QtWidgets.QFrame(self.scrollAreaWidgetContents)
        self.frame.setMinimumSize(QtCore.QSize(0, 150))
        self.frame.setFrameShape(QtWidgets.QFrame.StyledPanel)
        self.frame.setFrameShadow(QtWidgets.QFrame.Raised)
        self.frame.setObjectName("frame")
        self.gaugeLayout = QtWidgets.QVBoxLayout(self.frame)
        self.gaugeLayout.setContentsMargins(2, 2, 2, 2)
        self.gaugeLayout.setSpacing(2)
        self.gaugeLayout.setObjectName("gaugeLayout")
        self.gridLayout_6.addWidget(self.frame, 11, 0, 1, 1)
        self.durationBox = QtWidgets.QSpinBox(self.scrollAreaWidgetContents)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.durationBox.sizePolicy().hasHeightForWidth())
        self.durationBox.setSizePolicy(sizePolicy)
        self.durationBox.setMinimum(2)
        self.durationBox.setMaximum(300)
        self.durationBox.setProperty("value", 5)
        self.durationBox.setObjectName("durationBox")
        self.gridLayout_6.addWidget(self.durationBox, 4, 0, 1, 1)
        self.pushButton_6 = QtWidgets.QPushButton(self.scrollAreaWidgetContents)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Maximum, QtWidgets.QSizePolicy.Minimum)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.pushButton_6.sizePolicy().hasHeightForWidth())
        self.pushButton_6.setSizePolicy(sizePolicy)
        self.pushButton_6.setMinimumSize(QtCore.QSize(150, 25))
        self.pushButton_6.setObjectName("pushButton_6")
        self.gridLayout_6.addWidget(self.pushButton_6, 12, 0, 1, 1)
        self.graph = PlotWidget(self.scrollAreaWidgetContents)
        self.graph.setObjectName("graph")
        self.gridLayout_6.addWidget(self.graph, 3, 2, 10, 1)
        self.intervalBox = QtWidgets.QSpinBox(self.scrollAreaWidgetContents)
        sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Fixed)
        sizePolicy.setHorizontalStretch(0)
        sizePolicy.setVerticalStretch(0)
        sizePolicy.setHeightForWidth(self.intervalBox.sizePolicy().hasHeightForWidth())
        self.intervalBox.setSizePolicy(sizePolicy)
        self.intervalBox.setMinimum(2)
        self.intervalBox.setMaximum(300)
        self.intervalBox.setProperty("value", 2)
        self.intervalBox.setObjectName("intervalBox")
        self.gridLayout_6.addWidget(self.intervalBox, 5, 0, 1, 1)
        self.scrollArea.setWidget(self.scrollAreaWidgetContents)
        self.gridLayout_5.addWidget(self.scrollArea, 1, 0, 3, 3)
        self.verticalLayout_5.addWidget(self.frame_6)
        self.verticalLayout_4.addWidget(self.MyFrame)
        self.verticalLayout.addWidget(self.WidgetFrameOuter)

        self.retranslateUi(Form)
        self.optionBox.setCurrentIndex(1)
        self.pushButton_6.clicked.connect(Form.saveTraces) # type: ignore
        self.pushButton_2.clicked.connect(Form.sineFit) # type: ignore
        self.pushButton_3.clicked.connect(Form.dampedSineFit) # type: ignore
        self.durationBox.editingFinished.connect(Form.setDuration) # type: ignore
        self.pushButton.clicked.connect(Form.show_voltmeter) # type: ignore
        self.optionBox.currentIndexChanged['QString'].connect(Form.setInput) # type: ignore
        self.checkBox_4.clicked['bool'].connect(Form.startLogging) # type: ignore
        self.intervalBox.valueChanged['int'].connect(Form.setInterval) # type: ignore
        QtCore.QMetaObject.connectSlotsByName(Form)

    def retranslateUi(self, Form):
        _translate = QtCore.QCoreApplication.translate
        Form.setWindowTitle(_translate("Form", "Form"))
        self.WidgetFrameOuter.setProperty("class", _translate("Form", "PeripheralCollection"))
        self.frame_6.setProperty("class", _translate("Form", "PeripheralCollectionInner"))
        self.pushButton_2.setText(_translate("Form", "SINE FIT"))
        self.pushButton.setText(_translate("Form", "I/O Controls"))
        self.optionBox.setItemText(0, _translate("Form", "SR04"))
        self.optionBox.setItemText(1, _translate("Form", "VL53L0X"))
        self.msgwin.setText(_translate("Form", "."))
        self.pushButton_3.setText(_translate("Form", "DAMPED SINE FIT"))
        self.checkBox_4.setText(_translate("Form", "Record Data"))
        self.durationBox.setSuffix(_translate("Form", " S"))
        self.durationBox.setPrefix(_translate("Form", "Duration "))
        self.pushButton_6.setText(_translate("Form", "Save Data"))
        self.intervalBox.setSuffix(_translate("Form", " mS"))
        self.intervalBox.setPrefix(_translate("Form", "Interval "))
from pyqtgraph import PlotWidget
