How waelegate/tcp-ip-python-v3 works
Project type and purpose
• This is a Python-based SDK (library) and demo application for controlling Dobot robots over TCP/IP.
• It wraps the Dobot TCP/IP control protocol in easy-to-use Python classes and ships with both CLI (main.py, PythonExample.py) and simple GUI demos (main_UI.py, ui.py).
File structure
• Top-level:
• dobot_api.py – core SDK module defining DobotApi, DobotApiDashboard, DobotApiMove, MyType.
• PythonExample.py – code samples for SDK usage.
• main.py – command-line demo (connect, enable, MovL/J, feedback).
• main_UI.py & ui.py – simple UI front end.
• files/ – alarm configuration (JSON) + corresponding Python classes.
• images/ – assets used in README.
• README.md / README-EN.md – project description and usage.
• SDK uses numpy for feedback deserialization.
• The SDK establishes three separate TCP sockets to the robot controller: dashboardPort (29999), movePort (30003), feedPort (30004).
README for additional insights
• Detailed description of each class’s responsibility.
• Usage patterns:
• Instantiate Dashboard, Move, Feed clients.
• Main thread issues control & motion commands.
• Background threads handle feedback sampling and exception handling.
Key recommendations
• Three parallel channels—control, motion, feedback—and their threads.
• Alarm JSONs and show how they map to alarm_controller.py / alarm_servo.py.
• Data flow with sample ports (29999, 30003, 30004).