close socket
This commit is contained in:
parent
feb97e994c
commit
a6b33ff78d
|
@ -37,6 +37,7 @@ class SocketRobotArm:
|
||||||
self.socket.close()
|
self.socket.close()
|
||||||
|
|
||||||
def close(self):
|
def close(self):
|
||||||
|
self.socket.close()
|
||||||
self.tkinter_root.destroy()
|
self.tkinter_root.destroy()
|
||||||
sys.exit()
|
sys.exit()
|
||||||
|
|
||||||
|
@ -48,10 +49,7 @@ class SocketRobotArm:
|
||||||
def connect(self):
|
def connect(self):
|
||||||
self.socket.connect((self.host, self.port))
|
self.socket.connect((self.host, self.port))
|
||||||
|
|
||||||
self.tkinter_root.geometry("500x500")
|
self.tkinter_root.geometry("500x300")
|
||||||
|
|
||||||
exit_button = tkinter.Button(self.tkinter_root, text="Exit", command=self.close)
|
|
||||||
exit_button.pack(pady=20)
|
|
||||||
|
|
||||||
self.get_axis()
|
self.get_axis()
|
||||||
self.set_text(text=f"Координаты осей {self.start_axis_coordinates}")
|
self.set_text(text=f"Координаты осей {self.start_axis_coordinates}")
|
||||||
|
@ -77,6 +75,10 @@ class SocketRobotArm:
|
||||||
my_label = tkinter.Label(self.tkinter_root, text=f"Отправка данных")
|
my_label = tkinter.Label(self.tkinter_root, text=f"Отправка данных")
|
||||||
my_label.pack()
|
my_label.pack()
|
||||||
self.tkinter_root.update()
|
self.tkinter_root.update()
|
||||||
|
|
||||||
|
exit_button = tkinter.Button(self.tkinter_root, text="Exit", command=self.close)
|
||||||
|
exit_button.pack(pady=20)
|
||||||
|
|
||||||
step = 2
|
step = 2
|
||||||
for i in range(0, len(self.add_rcc_list), step):
|
for i in range(0, len(self.add_rcc_list), step):
|
||||||
print(f"Отправка данных {i}...{i+step-1}")
|
print(f"Отправка данных {i}...{i+step-1}")
|
||||||
|
|
Loading…
Reference in New Issue