Design and Implementation of a Two-Wheeled Self-Balancing Robot Using a Complementary Filter and PID Controller |
کد مقاله : 1039-ITME |
نویسندگان |
Kaveh Hooshmandi * دانشگاه صنعتی اراک |
چکیده مقاله |
Two-wheeled self-balancing robots represent a class of inherently unstable systems that require continuous control to maintain equilibrium. This study presents the modeling, simulation, and implementation of a two-wheeled self-balancing robot controlled by a Proportional-Integral-Derivative (PID) controller. The robot is modeled as an inverted pendulum mounted on a pair of motor-driven wheels, and its nonlinear dynamics are derived using the Euler-Lagrange method. An MPU6050 sensor, which combines a gyroscope and an accelerometer, is used to estimate the tilt angle through a complementary filter. The control algorithm is first developed and tested in MATLAB, with gains initially determined using the built-in PID Tuner App and refined through simulation. A disturbance-based test demonstrates the controller’s ability to restore balance with minimal overshoot. The discrete-time version of the PID controller is then implemented on an Arduino Nano microcontroller, and real-time testing confirms that manual trial-and-error tuning of the gains improves robustness and stability. The final prototype demonstrates reliable performance under practical conditions, confirming the feasibility of low-cost implementation for real-world self-balancing applications. |
کلیدواژه ها |
Two-Wheeled Self-Balancing Robot, PID Control, Arduino Implementation, Nonlinear Dynamics, Complementary Filter, Inverted Pendulum. |
وضعیت: پذیرفته شده |