diff --git a/controller/main.py b/controller/main.py index a9beec2..479eb50 100644 --- a/controller/main.py +++ b/controller/main.py @@ -1,4 +1,4 @@ -import tkinter as tk, threading, robomasterpy as rm +import tkinter as tk, robomasterpy as rm from tkinter import ttk class RobomasterUI: @@ -73,7 +73,7 @@ class RobomasterUI: master.bind("<space>", lambda event: self.stop_chassis()) def _run_command(self, func, *args, **kwargs): - threading.Thread(target=lambda: self._command_executor(func, *args, **kwargs)).start() + self._command_executor(func, *args, **kwargs) def _command_executor(self, func, *args, **kwargs): try: @@ -154,7 +154,6 @@ class RobomasterUI: except ValueError: self._display_output("Error: Invalid speed value") - def main(): ip_address = "192.168.2.1" try: