-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathmanual_control_ui.py
195 lines (188 loc) · 11.1 KB
/
manual_control_ui.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
# -*- coding: utf-8 -*-
# Form implementation generated from reading ui file '..\manual_control.ui'
#
# Created by: PyQt5 UI code generator 5.15.0
#
# 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_ManualControl(object):
def setupUi(self, ManualControl):
ManualControl.setObjectName("ManualControl")
ManualControl.setEnabled(True)
ManualControl.resize(358, 356)
self.verticalLayout_3 = QtWidgets.QVBoxLayout(ManualControl)
self.verticalLayout_3.setObjectName("verticalLayout_3")
self.groupBox = QtWidgets.QGroupBox(ManualControl)
self.groupBox.setEnabled(True)
self.groupBox.setObjectName("groupBox")
self.verticalLayout_2 = QtWidgets.QVBoxLayout(self.groupBox)
self.verticalLayout_2.setObjectName("verticalLayout_2")
self.horizontalLayout_4 = QtWidgets.QHBoxLayout()
self.horizontalLayout_4.setObjectName("horizontalLayout_4")
self.label = QtWidgets.QLabel(self.groupBox)
self.label.setObjectName("label")
self.horizontalLayout_4.addWidget(self.label)
self.label_active_axis = QtWidgets.QLabel(self.groupBox)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.label_active_axis.sizePolicy().hasHeightForWidth())
self.label_active_axis.setSizePolicy(sizePolicy)
font = QtGui.QFont()
font.setBold(True)
font.setWeight(75)
self.label_active_axis.setFont(font)
self.label_active_axis.setAlignment(QtCore.Qt.AlignRight|QtCore.Qt.AlignTrailing|QtCore.Qt.AlignVCenter)
self.label_active_axis.setObjectName("label_active_axis")
self.horizontalLayout_4.addWidget(self.label_active_axis)
self.verticalLayout_2.addLayout(self.horizontalLayout_4)
self.line_2 = QtWidgets.QFrame(self.groupBox)
self.line_2.setFrameShape(QtWidgets.QFrame.HLine)
self.line_2.setFrameShadow(QtWidgets.QFrame.Sunken)
self.line_2.setObjectName("line_2")
self.verticalLayout_2.addWidget(self.line_2)
self.horizontalLayout_14 = QtWidgets.QHBoxLayout()
self.horizontalLayout_14.setObjectName("horizontalLayout_14")
self.push_back2 = QtWidgets.QPushButton(self.groupBox)
self.push_back2.setAutoRepeat(True)
self.push_back2.setAutoRepeatInterval(50)
self.push_back2.setObjectName("push_back2")
self.horizontalLayout_14.addWidget(self.push_back2)
self.push_back1 = QtWidgets.QPushButton(self.groupBox)
self.push_back1.setAutoRepeat(True)
self.push_back1.setAutoRepeatDelay(300)
self.push_back1.setAutoRepeatInterval(50)
self.push_back1.setObjectName("push_back1")
self.horizontalLayout_14.addWidget(self.push_back1)
self.push_fwd1 = QtWidgets.QPushButton(self.groupBox)
self.push_fwd1.setAutoRepeat(True)
self.push_fwd1.setAutoRepeatDelay(300)
self.push_fwd1.setAutoRepeatInterval(50)
self.push_fwd1.setObjectName("push_fwd1")
self.horizontalLayout_14.addWidget(self.push_fwd1)
self.push_fwd2 = QtWidgets.QPushButton(self.groupBox)
self.push_fwd2.setAutoRepeat(True)
self.push_fwd2.setAutoRepeatInterval(50)
self.push_fwd2.setObjectName("push_fwd2")
self.horizontalLayout_14.addWidget(self.push_fwd2)
self.verticalLayout_2.addLayout(self.horizontalLayout_14)
self.horizontalLayout_26 = QtWidgets.QHBoxLayout()
self.horizontalLayout_26.setObjectName("horizontalLayout_26")
self.push_set0 = QtWidgets.QPushButton(self.groupBox)
self.push_set0.setEnabled(False)
self.push_set0.setObjectName("push_set0")
self.horizontalLayout_26.addWidget(self.push_set0)
self.pause_go_home = QtWidgets.QPushButton(self.groupBox)
self.pause_go_home.setEnabled(False)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.pause_go_home.sizePolicy().hasHeightForWidth())
self.pause_go_home.setSizePolicy(sizePolicy)
self.pause_go_home.setMinimumSize(QtCore.QSize(0, 0))
self.pause_go_home.setStyleSheet("")
self.pause_go_home.setObjectName("pause_go_home")
self.horizontalLayout_26.addWidget(self.pause_go_home)
self.verticalLayout_2.addLayout(self.horizontalLayout_26)
self.verticalLayout_3.addWidget(self.groupBox)
self.groupBox_4 = QtWidgets.QGroupBox(ManualControl)
self.groupBox_4.setObjectName("groupBox_4")
self.verticalLayout = QtWidgets.QVBoxLayout(self.groupBox_4)
self.verticalLayout.setObjectName("verticalLayout")
self.horizontalLayout_25 = QtWidgets.QHBoxLayout()
self.horizontalLayout_25.setObjectName("horizontalLayout_25")
self.label_25 = QtWidgets.QLabel(self.groupBox_4)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.MinimumExpanding, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.label_25.sizePolicy().hasHeightForWidth())
self.label_25.setSizePolicy(sizePolicy)
self.label_25.setObjectName("label_25")
self.horizontalLayout_25.addWidget(self.label_25)
self.double_position = QtWidgets.QDoubleSpinBox(self.groupBox_4)
self.double_position.setMinimum(-999999.0)
self.double_position.setMaximum(999999.0)
self.double_position.setObjectName("double_position")
self.horizontalLayout_25.addWidget(self.double_position)
self.verticalLayout.addLayout(self.horizontalLayout_25)
self.horizontalLayout_27 = QtWidgets.QHBoxLayout()
self.horizontalLayout_27.setObjectName("horizontalLayout_27")
self.label_27 = QtWidgets.QLabel(self.groupBox_4)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.MinimumExpanding, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.label_27.sizePolicy().hasHeightForWidth())
self.label_27.setSizePolicy(sizePolicy)
self.label_27.setObjectName("label_27")
self.horizontalLayout_27.addWidget(self.label_27)
self.double_speed = QtWidgets.QDoubleSpinBox(self.groupBox_4)
self.double_speed.setMaximum(999999.0)
self.double_speed.setObjectName("double_speed")
self.horizontalLayout_27.addWidget(self.double_speed)
self.verticalLayout.addLayout(self.horizontalLayout_27)
self.push_manual_go = QtWidgets.QPushButton(self.groupBox_4)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Preferred, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.push_manual_go.sizePolicy().hasHeightForWidth())
self.push_manual_go.setSizePolicy(sizePolicy)
self.push_manual_go.setObjectName("push_manual_go")
self.verticalLayout.addWidget(self.push_manual_go)
self.verticalLayout_3.addWidget(self.groupBox_4)
self.groupBox_3 = QtWidgets.QGroupBox(ManualControl)
self.groupBox_3.setObjectName("groupBox_3")
self.gridLayout_2 = QtWidgets.QGridLayout(self.groupBox_3)
self.gridLayout_2.setObjectName("gridLayout_2")
self.horizontalLayout = QtWidgets.QHBoxLayout()
self.horizontalLayout.setObjectName("horizontalLayout")
self.label_26 = QtWidgets.QLabel(self.groupBox_3)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Maximum, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.label_26.sizePolicy().hasHeightForWidth())
self.label_26.setSizePolicy(sizePolicy)
self.label_26.setObjectName("label_26")
self.horizontalLayout.addWidget(self.label_26)
self.line_gcode_string = QtWidgets.QLineEdit(self.groupBox_3)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Fixed)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.line_gcode_string.sizePolicy().hasHeightForWidth())
self.line_gcode_string.setSizePolicy(sizePolicy)
self.line_gcode_string.setObjectName("line_gcode_string")
self.horizontalLayout.addWidget(self.line_gcode_string)
self.push_gcode_send = QtWidgets.QPushButton(self.groupBox_3)
sizePolicy = QtWidgets.QSizePolicy(QtWidgets.QSizePolicy.Fixed, QtWidgets.QSizePolicy.Preferred)
sizePolicy.setHorizontalStretch(0)
sizePolicy.setVerticalStretch(0)
sizePolicy.setHeightForWidth(self.push_gcode_send.sizePolicy().hasHeightForWidth())
self.push_gcode_send.setSizePolicy(sizePolicy)
self.push_gcode_send.setObjectName("push_gcode_send")
self.horizontalLayout.addWidget(self.push_gcode_send)
self.gridLayout_2.addLayout(self.horizontalLayout, 0, 0, 1, 1)
self.verticalLayout_3.addWidget(self.groupBox_3)
spacerItem = QtWidgets.QSpacerItem(20, 40, QtWidgets.QSizePolicy.Minimum, QtWidgets.QSizePolicy.Expanding)
self.verticalLayout_3.addItem(spacerItem)
self.retranslateUi(ManualControl)
QtCore.QMetaObject.connectSlotsByName(ManualControl)
def retranslateUi(self, ManualControl):
_translate = QtCore.QCoreApplication.translate
ManualControl.setWindowTitle(_translate("ManualControl", "Manual Control"))
self.groupBox.setTitle(_translate("ManualControl", "Motor control"))
self.label.setText(_translate("ManualControl", "Active axis (set in script editor)"))
self.label_active_axis.setText(_translate("ManualControl", "NOT SET"))
self.push_back2.setText(_translate("ManualControl", "<<"))
self.push_back1.setText(_translate("ManualControl", "<"))
self.push_fwd1.setText(_translate("ManualControl", ">"))
self.push_fwd2.setText(_translate("ManualControl", ">>"))
self.push_set0.setText(_translate("ManualControl", "Set 0"))
self.pause_go_home.setText(_translate("ManualControl", "GO HOME"))
self.groupBox_4.setTitle(_translate("ManualControl", "Manual positioning"))
self.label_25.setText(_translate("ManualControl", "ABS position [deg]"))
self.label_27.setText(_translate("ManualControl", "Speed (0 = rapid movement) [deg/min]"))
self.push_manual_go.setText(_translate("ManualControl", "GO"))
self.groupBox_3.setTitle(_translate("ManualControl", "Send manual g-code"))
self.label_26.setText(_translate("ManualControl", "MDI"))
self.line_gcode_string.setToolTip(_translate("ManualControl", "For example: G1 X100 F1000"))
self.push_gcode_send.setText(_translate("ManualControl", "Send"))