-
Notifications
You must be signed in to change notification settings - Fork 0
/
plotter.py
210 lines (201 loc) · 11.6 KB
/
plotter.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
# -*- coding: utf-8 -*-
# Form implementation generated from reading ui file 'plotter.ui'
#
# Created: Wed Jul 18 10:35:56 2012
# by: PyQt4 UI code generator 4.8.6
#
# WARNING! All changes made in this file will be lost!
from PyQt4 import QtCore, QtGui
try:
_fromUtf8 = QtCore.QString.fromUtf8
except AttributeError:
_fromUtf8 = lambda s: s
class Ui_MainWindow(object):
def setupUi(self, MainWindow):
MainWindow.setObjectName(_fromUtf8("MainWindow"))
MainWindow.resize(740, 460)
MainWindow.setWindowTitle(QtGui.QApplication.translate("MainWindow", "MainWindow", None, QtGui.QApplication.UnicodeUTF8))
self.centralwidget = QtGui.QWidget(MainWindow)
self.centralwidget.setObjectName(_fromUtf8("centralwidget"))
self.mplwidget = MatplotlibWidget(self.centralwidget)
self.mplwidget.setGeometry(QtCore.QRect(200, 30, 521, 381))
self.mplwidget.setObjectName(_fromUtf8("mplwidget"))
self.label_6 = QtGui.QLabel(self.centralwidget)
self.label_6.setGeometry(QtCore.QRect(200, 10, 371, 16))
font = QtGui.QFont()
font.setPointSize(14)
self.label_6.setFont(font)
self.label_6.setText(QtGui.QApplication.translate("MainWindow", "Quantum Wire Conductance Measurement", None, QtGui.QApplication.UnicodeUTF8))
self.label_6.setObjectName(_fromUtf8("label_6"))
self.widget = QtGui.QWidget(self.centralwidget)
self.widget.setGeometry(QtCore.QRect(50, 30, 143, 383))
self.widget.setObjectName(_fromUtf8("widget"))
self.verticalLayout_7 = QtGui.QVBoxLayout(self.widget)
self.verticalLayout_7.setMargin(0)
self.verticalLayout_7.setObjectName(_fromUtf8("verticalLayout_7"))
self.verticalLayout_6 = QtGui.QVBoxLayout()
self.verticalLayout_6.setObjectName(_fromUtf8("verticalLayout_6"))
self.verticalLayout_3 = QtGui.QVBoxLayout()
self.verticalLayout_3.setObjectName(_fromUtf8("verticalLayout_3"))
self.verticalLayout = QtGui.QVBoxLayout()
self.verticalLayout.setObjectName(_fromUtf8("verticalLayout"))
self.horizontalLayout = QtGui.QHBoxLayout()
self.horizontalLayout.setObjectName(_fromUtf8("horizontalLayout"))
self.label = QtGui.QLabel(self.widget)
self.label.setText(QtGui.QApplication.translate("MainWindow", "Gate Voltage", None, QtGui.QApplication.UnicodeUTF8))
self.label.setObjectName(_fromUtf8("label"))
self.horizontalLayout.addWidget(self.label)
self.gate_display = QtGui.QLCDNumber(self.widget)
self.gate_display.setObjectName(_fromUtf8("gate_display"))
self.horizontalLayout.addWidget(self.gate_display)
self.verticalLayout.addLayout(self.horizontalLayout)
self.horizontalLayout_2 = QtGui.QHBoxLayout()
self.horizontalLayout_2.setObjectName(_fromUtf8("horizontalLayout_2"))
self.conductanceLabel = QtGui.QLabel(self.widget)
self.conductanceLabel.setText(QtGui.QApplication.translate("MainWindow", "Conductance", None, QtGui.QApplication.UnicodeUTF8))
self.conductanceLabel.setObjectName(_fromUtf8("conductanceLabel"))
self.horizontalLayout_2.addWidget(self.conductanceLabel)
self.conductance = QtGui.QLCDNumber(self.widget)
self.conductance.setObjectName(_fromUtf8("conductance"))
self.horizontalLayout_2.addWidget(self.conductance)
self.verticalLayout.addLayout(self.horizontalLayout_2)
self.horizontalLayout_3 = QtGui.QHBoxLayout()
self.horizontalLayout_3.setObjectName(_fromUtf8("horizontalLayout_3"))
self.timeLabel = QtGui.QLabel(self.widget)
self.timeLabel.setText(QtGui.QApplication.translate("MainWindow", "Time", None, QtGui.QApplication.UnicodeUTF8))
self.timeLabel.setObjectName(_fromUtf8("timeLabel"))
self.horizontalLayout_3.addWidget(self.timeLabel)
self.time = QtGui.QLCDNumber(self.widget)
self.time.setObjectName(_fromUtf8("time"))
self.horizontalLayout_3.addWidget(self.time)
self.verticalLayout.addLayout(self.horizontalLayout_3)
self.horizontalLayout_4 = QtGui.QHBoxLayout()
self.horizontalLayout_4.setObjectName(_fromUtf8("horizontalLayout_4"))
self.tempLabel = QtGui.QLabel(self.widget)
self.tempLabel.setText(QtGui.QApplication.translate("MainWindow", "Temperature", None, QtGui.QApplication.UnicodeUTF8))
self.tempLabel.setObjectName(_fromUtf8("tempLabel"))
self.horizontalLayout_4.addWidget(self.tempLabel)
self.temp = QtGui.QLCDNumber(self.widget)
self.temp.setObjectName(_fromUtf8("temp"))
self.horizontalLayout_4.addWidget(self.temp)
self.verticalLayout.addLayout(self.horizontalLayout_4)
self.horizontalLayout_5 = QtGui.QHBoxLayout()
self.horizontalLayout_5.setObjectName(_fromUtf8("horizontalLayout_5"))
self.pointsLabel = QtGui.QLabel(self.widget)
self.pointsLabel.setText(QtGui.QApplication.translate("MainWindow", "Step Size", None, QtGui.QApplication.UnicodeUTF8))
self.pointsLabel.setObjectName(_fromUtf8("pointsLabel"))
self.horizontalLayout_5.addWidget(self.pointsLabel)
self.stepSize = QtGui.QDoubleSpinBox(self.widget)
self.stepSize.setProperty("value", 0.1)
self.stepSize.setObjectName(_fromUtf8("stepSize"))
self.horizontalLayout_5.addWidget(self.stepSize)
self.verticalLayout.addLayout(self.horizontalLayout_5)
self.horizontalLayout_6 = QtGui.QHBoxLayout()
self.horizontalLayout_6.setObjectName(_fromUtf8("horizontalLayout_6"))
self.maxGateLabel = QtGui.QLabel(self.widget)
self.maxGateLabel.setText(QtGui.QApplication.translate("MainWindow", "Max gate", None, QtGui.QApplication.UnicodeUTF8))
self.maxGateLabel.setObjectName(_fromUtf8("maxGateLabel"))
self.horizontalLayout_6.addWidget(self.maxGateLabel)
self.maxGate = QtGui.QDoubleSpinBox(self.widget)
self.maxGate.setMinimum(-99.0)
self.maxGate.setProperty("value", -2.0)
self.maxGate.setObjectName(_fromUtf8("maxGate"))
self.horizontalLayout_6.addWidget(self.maxGate)
self.verticalLayout.addLayout(self.horizontalLayout_6)
self.horizontalLayout_7 = QtGui.QHBoxLayout()
self.horizontalLayout_7.setObjectName(_fromUtf8("horizontalLayout_7"))
self.delayLabel_2 = QtGui.QLabel(self.widget)
self.delayLabel_2.setText(QtGui.QApplication.translate("MainWindow", "Delay", None, QtGui.QApplication.UnicodeUTF8))
self.delayLabel_2.setObjectName(_fromUtf8("delayLabel_2"))
self.horizontalLayout_7.addWidget(self.delayLabel_2)
self.delay = QtGui.QSpinBox(self.widget)
self.delay.setProperty("value", 1)
self.delay.setObjectName(_fromUtf8("delay"))
self.horizontalLayout_7.addWidget(self.delay)
self.verticalLayout.addLayout(self.horizontalLayout_7)
self.verticalLayout_3.addLayout(self.verticalLayout)
self.verticalLayout_6.addLayout(self.verticalLayout_3)
self.verticalLayout_5 = QtGui.QVBoxLayout()
self.verticalLayout_5.setObjectName(_fromUtf8("verticalLayout_5"))
self.label_2 = QtGui.QLabel(self.widget)
font = QtGui.QFont()
font.setPointSize(12)
self.label_2.setFont(font)
self.label_2.setText(QtGui.QApplication.translate("MainWindow", "Focus", None, QtGui.QApplication.UnicodeUTF8))
self.label_2.setObjectName(_fromUtf8("label_2"))
self.verticalLayout_5.addWidget(self.label_2)
self.verticalLayout_4 = QtGui.QVBoxLayout()
self.verticalLayout_4.setObjectName(_fromUtf8("verticalLayout_4"))
self.horizontalLayout_9 = QtGui.QHBoxLayout()
self.horizontalLayout_9.setObjectName(_fromUtf8("horizontalLayout_9"))
self.label_3 = QtGui.QLabel(self.widget)
self.label_3.setText(QtGui.QApplication.translate("MainWindow", "Lower Limit", None, QtGui.QApplication.UnicodeUTF8))
self.label_3.setObjectName(_fromUtf8("label_3"))
self.horizontalLayout_9.addWidget(self.label_3)
self.windowlower = QtGui.QDoubleSpinBox(self.widget)
self.windowlower.setMinimum(-5.0)
self.windowlower.setMaximum(5.0)
self.windowlower.setSingleStep(0.01)
self.windowlower.setObjectName(_fromUtf8("windowlower"))
self.horizontalLayout_9.addWidget(self.windowlower)
self.verticalLayout_4.addLayout(self.horizontalLayout_9)
self.horizontalLayout_8 = QtGui.QHBoxLayout()
self.horizontalLayout_8.setObjectName(_fromUtf8("horizontalLayout_8"))
self.label_4 = QtGui.QLabel(self.widget)
self.label_4.setText(QtGui.QApplication.translate("MainWindow", "Upper Limit", None, QtGui.QApplication.UnicodeUTF8))
self.label_4.setObjectName(_fromUtf8("label_4"))
self.horizontalLayout_8.addWidget(self.label_4)
self.windowupper = QtGui.QDoubleSpinBox(self.widget)
self.windowupper.setMinimum(-5.0)
self.windowupper.setMaximum(5.0)
self.windowupper.setSingleStep(0.01)
self.windowupper.setObjectName(_fromUtf8("windowupper"))
self.horizontalLayout_8.addWidget(self.windowupper)
self.verticalLayout_4.addLayout(self.horizontalLayout_8)
self.horizontalLayout_10 = QtGui.QHBoxLayout()
self.horizontalLayout_10.setObjectName(_fromUtf8("horizontalLayout_10"))
self.label_5 = QtGui.QLabel(self.widget)
self.label_5.setText(QtGui.QApplication.translate("MainWindow", "Step Size", None, QtGui.QApplication.UnicodeUTF8))
self.label_5.setObjectName(_fromUtf8("label_5"))
self.horizontalLayout_10.addWidget(self.label_5)
self.windowstep = QtGui.QDoubleSpinBox(self.widget)
self.windowstep.setDecimals(4)
self.windowstep.setSingleStep(0.001)
self.windowstep.setObjectName(_fromUtf8("windowstep"))
self.horizontalLayout_10.addWidget(self.windowstep)
self.verticalLayout_4.addLayout(self.horizontalLayout_10)
self.verticalLayout_5.addLayout(self.verticalLayout_4)
self.verticalLayout_6.addLayout(self.verticalLayout_5)
self.verticalLayout_7.addLayout(self.verticalLayout_6)
self.verticalLayout_2 = QtGui.QVBoxLayout()
self.verticalLayout_2.setObjectName(_fromUtf8("verticalLayout_2"))
self.goButton = QtGui.QPushButton(self.widget)
self.goButton.setText(QtGui.QApplication.translate("MainWindow", "Go!", None, QtGui.QApplication.UnicodeUTF8))
self.goButton.setObjectName(_fromUtf8("goButton"))
self.verticalLayout_2.addWidget(self.goButton)
self.quit = QtGui.QPushButton(self.widget)
self.quit.setText(QtGui.QApplication.translate("MainWindow", "Quit", None, QtGui.QApplication.UnicodeUTF8))
self.quit.setObjectName(_fromUtf8("quit"))
self.verticalLayout_2.addWidget(self.quit)
self.verticalLayout_7.addLayout(self.verticalLayout_2)
MainWindow.setCentralWidget(self.centralwidget)
self.menubar = QtGui.QMenuBar(MainWindow)
self.menubar.setGeometry(QtCore.QRect(0, 0, 740, 21))
self.menubar.setObjectName(_fromUtf8("menubar"))
MainWindow.setMenuBar(self.menubar)
self.statusbar = QtGui.QStatusBar(MainWindow)
self.statusbar.setObjectName(_fromUtf8("statusbar"))
MainWindow.setStatusBar(self.statusbar)
self.retranslateUi(MainWindow)
QtCore.QMetaObject.connectSlotsByName(MainWindow)
def retranslateUi(self, MainWindow):
pass
from matplotlibwidget import MatplotlibWidget
if __name__ == "__main__":
import sys
app = QtGui.QApplication(sys.argv)
MainWindow = QtGui.QMainWindow()
ui = Ui_MainWindow()
ui.setupUi(MainWindow)
MainWindow.show()
sys.exit(app.exec_())