Publication: Controlling an inverted pendulum with microcontroller
Loading...
Date
2023-07-01
Authors
Raymond Roy A/L Rayappan
Journal Title
Journal ISSN
Volume Title
Publisher
Abstract
TWSB robot functions based on the principle of inverted pendulum. When a pendulum is hung with a mass below its pivot point is displaced to the left and right, will slowly return to its equilibrium position due to loss of energy to the surrounding and friction. When this configuration of pendulum is inverted and the rope is replaced with a solid rod, an inverted pendulum can be created. An inverted pendulum is a pendulum which has its center of mass above its pivot point where it is deemed unstable and will fall over without any additional support. This unstable system can be made stable by using a control system to monitor and control the angle of the solid rod through a closed-loop feedback system. This closed-loop feedback system must be able to monitor the angle of the rod continuously to avoid the pendulum from falling down. This project aims to study the performance and the ability of the Arduino microcontroller in controlling the TWSB robot and maintain an upright stable position throughout the experiment. Control system is very important for a TWSB robot to receive the data from the sensor and decide how much the robot has to move or tilt to stay in an upright stable position. The controller that is usually used for balancing purpose like in the case of the TWSB robot is PID controller. Simulation of TWSB robot has been done using Matlab software to study the performance of the PID controller in stabilizing the unstable TWSB robot. The model of the TWSB robot has been bulit using Matlab software in the Simscape Multibody before the simulation is done. The result from the simulation is later used during the experiment. The simulation is very important to be used during the experiment to get the desired result and so that the TWSB robot can be balanced in an upright and stable position. In this experiment, a TWSB robot is built with the PID gains of Kp=2.5 dan Kd=0.02. Based on the simulation result done in Simscape these values are good enough for the robot to balance. But when the experiment is done, the robot couldn’t balance itself properly and falls after few seconds. The TWSB robot also couldn’t move forward for a long time and falls down after moving a certain distance. The performance of the robot proved to be the same as the previous one and there seems to be no improvement in the performance of the TWSB robot.