Software Installation Guide

Estimated Time: 1 hour | Difficulty: Easy

PC Software Installation

1. Python Environment Setup

Recommended Version: Python 3.10 (Required)
# Method 1: Using Conda (Recommended)
conda create -n py310 python=3.10
conda activate py310

# Method 2: Using Official Python
# Download Python 3.10 installer from python.org
Python Installation

Python environment configuration interface

2. Dependency Installation

# Clone project (or download from GitHub)
git clone https://github.com/yourorg/delta-robot.git
cd delta-robot/pc

# Install dependencies
pip install -r requirements.txt

Main Dependencies in requirements.txt:

  • PySide6 - GUI framework
  • OpenCV - Image processing
  • ultralytics - YOLOv8 object detection
  • pyserial - Serial communication
  • numpy - Numerical computation

3. YOLOv8 Model Download

# Model will auto-download on first run
# Or manually download and place in pc/models/
wget https://github.com/ultralytics/assets/releases/download/v0.0.0/yolov8n.pt

4. Camera Drivers

Ensure PC camera or USB camera has drivers installed and is recognized by the system.

# Test camera
python -c "import cv2; print('Camera:', cv2.VideoCapture(0).isOpened())"

ESP32 Firmware Upload

1. Arduino IDE Installation

  1. Download Arduino IDE
  2. Install and launch Arduino IDE
Arduino IDE Configuration

Arduino IDE configuration interface

2. ESP32 Core Installation

1. Open: File → Preferences
2. Add to "Additional Boards Manager URLs":
   https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json
3. Open: Tools → Board → Boards Manager
4. Search "ESP32", install "esp32 by Espressif Systems"

3. Firmware Upload Process

  1. Open esp32/DeltaRobot.ino in Arduino IDE
  2. Select board: Tools → Board → ESP32 Dev Module
  3. Select port: Tools → Port → COM3 (adjust as needed)
  4. Configure settings:
    • Upload Speed: 115200
    • Flash Frequency: 80MHz
    • Partition Scheme: Default
  5. Click "Upload" button

4. Serial Test

Open: Tools → Serial Monitor
Baud Rate: 115200
Input: G28
Should see: ok (or motors start moving)
✅ Firmware Upload Successful

If serial monitor receives response, firmware is working properly!

First Run

1. Start PC Software

cd E:\DeltaRobot\pc
conda activate py310
python CameraDetect.py
GUI Interface

PC software main interface

2. Connect ESP32

  1. Select correct serial port in GUI (COM3 or COM4)
  2. Set baud rate: 115200
  3. Click "Open Port" button
  4. Status bar shows "Connected"
Serial Connection

Serial connection success interface

3. Interface Features

  • Video Stream: Real-time camera feed display
  • Detection Results: YOLOv8 identified object bounding boxes
  • Serial Debug: Send GCode commands
  • Coordinate Transform: Click image to get robot coordinates
  • Auto Pick: One-click automatic sorting

4. Basic Function Test

  1. Test video stream: Camera feed should display normally
  2. Test object detection: Place object, detection box should appear
  3. Test serial: Send G28, robot arm homes
  4. Test coordinates: Click on screen, serial sends corresponding coordinates

Common Issues

Q: Serial port connection failed?

Possible Causes:

  • USB driver not installed (install CP2102 or CH340 driver)
  • Wrong port selected (check Device Manager)
  • Port occupied by other program (close Arduino IDE)

Q: Python dependency error?

Solution:

# Upgrade pip
python -m pip install --upgrade pip

# Reinstall dependencies
pip install -r requirements.txt --force-reinstall

Q: GUI won't start?

Check:

  • Python version is 3.10
  • PySide6 correctly installed
  • Run python --version to confirm

Q: Camera not recognized?

Solution:

  • Check camera permissions (Windows Settings)
  • Change camera ID (in code: cv2.VideoCapture(0) to 1 or 2)
  • Test camera: Windows Camera App

Next Step

After software installation, proceed to system calibration:

→ Calibration Process