Performance Comparison between Sliding Mode Controller SMC and Proportional-Integral-Derivative PID Controller for a Highly Nonlinear Two-wheeled Balancing Robot Ahmad Nor Kasruddin Nasir 1 ,Mohd Zaidi Mohd Tumari 2 , Mohd Riduwan Ghazali 3 Faculty of Electrical & Electronics Engineering, Universiti Malaysia Pahang (UMP), 26600 Pekan Pahang. kasruddin@ump.edu.my 1 , zaidimt@ump.edu.my 2 , riduwan@ump.edu.my 3 Abstract – The research on two-wheels balancing robot has gained momentum due to their functionality and reliability when completing certain tasks. This paper presents investigations into the performance comparison of Sliding Mode Controller (SMC) and Proportional-Integral-Derivative (PID) controller for a highly nonlinear 2-wheels balancing robot. The mathematical model of 2-wheels balancing robot that is highly nonlinear is derived. The final model is then represented in state-space form and the system suffers from mismatched condition. Two system responses namely the robot position and robot angular position are obtained. The performances of the SMC and PID controllers are examined in terms of input tracking and disturbances rejection capability. Simulation results of the responses of the nonlinear 2–wheels balancing robot are presented in time domain. A comparative assessment of both control schemes to the system performance is analyzed and discussed. Keywords - SMC, PID, balancing robot. 1 INTRODUCTION The research on two-wheeled balancing robot has gained momentum over the last decade due to the nonlinear and unstable dynamics system. Various control strategies had been proposed by numerous researchers to control the two-wheeled balancing robot such that the robot able to balance itself. Two wheels balancing robot is a good platform for researchers to investigate the efficiency of various controllers in control system. The research on two wheels balancing robot is based on inverted pendulum model. Thus, a two wheels balancing robot needs a good controller to control itself in upright position without the needs from outside. Motion of two wheels balancing robot is governed by under-actuated conguration, i.e., the number of control inputs is less than the number of degrees of freedom to be stabilized [1], which makes it difficult to apply the conventional robotics approach for controlling the systems. Due to these reasons, increasing effort has been made towards control designs that guarantee stability and robustness for mobile wheeled inverted pendulums. Although two wheels balancing robot are intrinsically nonlinear and their dynamics will be described by nonlinear differential equations, it is often possible to obtain a linearized model of the system. If the system operates around an operating point and the signals involved are small signals, a linear model that approximates the nonlinear system in the region of operation can be obtained. Several techniques for the design of controllers and analysis techniques for linear systems were applied. In [2], motion control was proposed using linear state-space model. In [3], dynamics was derived using a Newtonian approach and the control was design by the equations linearized around an operating point. In [4], the dynamic equations were studied, with the balancing robot pitch and the rotation angles of the two wheels as the variables of interest, and a linear controller was designed for stabilization under the consider of its robustness in [5]. In [6], a linear stabilizing controller was derived by a planar model without considering vehicle yaw. The above control laws are designed on the linearized dynamics which only exhibits desirable behavior around the operating point, and do not have global applicability. In [7], the exact dynamics of two wheels inverted pendulum was investigated, and linear feedback control was developed on the dynamic model. In [8], a two- level velocity controller via partial feedback linearized and a stabilizing position controller were derived; however, the controller design is not robust with respect to parameter uncertainties. In [9], a controller using sliding mode approach was proposed to ensure robustness versus parameter uncertainties for controlling both the position and the orientation of the balancing robot. The mathematical model is established through a modelling process where the system is identified based on the conservation laws and property laws. This process is crucial since a controller is design solely based on this mathematical model. Thus, an accurate equation must be derived in order for the controller to response accordingly. This paper presents investigations of performance comparison between conventional control PID and modern control SMC schemes for a two wheels balancing robot. The mathematical model of the two wheels balancing robot system is presented in differential equation form. The dynamic model of the system with the permanent magnet DC motors dynamic included is derived based on [3] and [9]. Performances of both control strategy with respect to balancing robot outputs angular position θ and linear position x are examined. Comparative assessment of both control schemes to the two balancing robot system performance is analyzed and discussed. SCIS-ISIS 2012, Kobe, Japan, November 20-24, 2012 978-1-4673-2743-5/12/$31.00 ©2012 IEEE 1403