กลับไปหน้ารวมไฟล์
ball-and-plate-pid-en.md

Precision PID Control: Ball and Plate

The Ball and Plate system is a classic control theory problem, similar to a self-balancing robot but on two axes instead of one. It demands sub-millimeter precision and aggressive mathematical tuning.

ultrasonic_servo_mount_detail_1772682020744.png

The PID Algorithm

  1. The Error: The center of the plate is [X:0, Y:0]. The camera (or resistive touch panel) detects that the ball is at [X:15, Y:-10]. That difference is the "Error".
  2. Proportional: Make an immediate correction based on how big the error is.
  3. Integral: If the ball isn't moving fast enough to the center, slowly ramp up the correction.
  4. Derivative: As the ball gets close to the center, apply the brakes (reverse correction) so it doesn't shoot past the center and roll off the other side!

Essential Hardware

  • Arduino Mega/Uno: Requires intense mathematical calculations.
  • Resistive Touch Panel (4-wire): Pulled from an old tablet, this acts as the "Plate." When the steel ball rolls on it, it instantly outputs its exact X/Y coordinates.
  • High-Speed Servos (x2): Placed underneath the plate on a universal joint. One controls the X-axis tilt, the other controls the Y-axis tilt.

Mastering this project means you have mastered PID, making you capable of programming stabilizing gimbals or hovering quadcopters.

ข้อมูล Frontmatter ดั้งเดิม

title: "Ball and Plate Balancing Robot"
description: "The ultimate physics challenge! Build an active control system that perfectly balances a rolling steel ball on a moving flat plate."
category: "Motors & Robotics"
difficulty: "Advanced"