You are on page 1of 6

2018 18th International Conference on Control, Automation and Systems (ICCAS 2018)

Oct. 17–20, 2018; YongPyong Resort, PyeongChang, GangWon, Korea

PID with derivative filter and integral sliding-mode controller techniques


applied to an indoor micro quadrotor
Kranthi Kumar Deveerasetty1 and Yimin Zhou1∗
1
Center for Intelligent Bionic, Shenzhen Institutes of Advanced Technology, Chinese Academy of Sciences,
Shenzhen, China. (emails:(kranthi;ym.zhou)@siat.ac.cn)

Abstract: The paper proposes two different controllers for tracking control of a quadrotor. An Euler-Lagrange for-
mulation is used to drive the dynamic mathematical model of a quadrotor. To illustrate the advantages of the proposed
controllers and for simplicity, all the aerodynamics, Coriolis, drags and gyroscopic effect are abandoned. A PID con-
troller with derivative filter is proposed for the position tracking of the quadrotor here. The advantage of the proposed
PID controller include easiness of implementation, effectuate higher stability and less dependent on the system model.
The integral sliding-mode controller is proposed to obtain the desired attitude angles for the quadrotor tracking and its
advantage is unaffected by the system model errors. The designed controllers can stabilize the roll, pitch, and yaw angles
and make the quadrotor to move (x, y, z) positions to their desired values. The Lyapunovs theorem is useful to obtain the
quadrotor controllers and also ensure the system track to attain and maintain on the sliding surfaces. The validation of
results has been tested in MATLAB simulation and exhibits adequate performance.

Keywords: PID controller, Integral sliding mode control, Position tracking, Quadrotor.

1. INTRODUCTION split into inner-outer loop control or full control. In the


inner-outer loop control methods, different control strate-
Autonomous flying robots are becoming more attrac- gies are used for internal and external loops. While in
tive, due to their utilization in environmental exploration, full control methods, the same control technique is used
mapping, agriculture plant protection, military applica- in internal and external loops. Distinctive control meth-
tions, surveillance, aerial cinematography and so on. ods which are lately examined on quadrotor are as per the
Quadrotor has the ability of Vertical Take Off and Land- following: classic PD control [14], P D2 feedback con-
ing (VTOL), hover flight performance and additional troller [13], PID controller [7],[9], LQR controller [7],
deftness, makes them ideal vehicles. Unmanned Aerial backstepping controller [9],[11], adaptive controller [10],
Vehicles (UAVs) are not a new invention, where the con- feedback controller [18], H∞ [17] and sliding mode con-
cept of Quadrotor was introduced in 1907, known as the troller [12],[15].
Gyroplane No.1 [1]. The quadrotor has four propellers A dynamic part of the feedback controller was developed
in the cross constellation. In recent years, the research to change the closed-loop part of system into linear, con-
on quadrotor modelling and control has been increased trollable and decoupled subsystem, while the feedback
enormously. VTOL controlling aircraft models are stud- linearization control is not sufficiently vigorous towards
ied by Hauser et al. [2],[3]. Quadrotors are progressively wind unsettling influences [8]. Bristeau et al., [16] anal-
unstable and in this way, appropriate controllers are im- ysed the aerodynamic consequences of the propellers.
portant to make them stable. Although unstable dynamics Two assumptions are formulated by the author. One is
is beneficial to agility, it is not desirable. The cause of in- propellers twisting to make sure that the angle of the
stability is due to the changing parameters in quadrotor attack is constant along the blades and the another is
and disturbances such as wind, snow. Quadrotor dynam- along the blades, the velocity is considered as constant
ics using Euler-Newton methods [4] and visual feedback to show that the flexibility of the propellers play a signifi-
is utilized to appraise the position and orientation of the cant role in the quadrotor dynamics. To study the dynam-
quadrotor [5]. The fundamental idea of this method is to ics quadrotor hover conditions, the inherent nonlinearities
utilize control techniques based on nonlinear to stabilize are quantified by comparing the gramians obtained from
and attain output tracking control of a quadrotor. In this impulse response using empirical controllability gramian
method, it has demonstrated that the backstepping con- with that obtained from a linearized assumption at the
troller works superior to the feedback stabilization. In steady-state operating point using linear controllability
[6], using Lagrange-Euler to form a nonlinear model of a gramian [20]. This method has the advantage of utiliz-
quadrotor was developed. The quadrotor control can be ing the impulse response data directly to determine unit
input energy reachability sets without a vehicle dynam-
This work was supported under the Shenzhen Science and Technology
Innovation Commission Project Grant Ref. JCYJ20160510154736343
ics model. The empirical gramians has two main advan-
and JCYJ20170818153635759 and Science and Technology Planning tages. First, there is no assumption of linearity in system
Project of Guangdong Province Ref. 2017B010117009 dynamics, and the second is that the reachability sets can
* Corresponding author

978-89-93215-15-1/18/$31.00 ⓒICROS 439


be obtained through direct empirical impulse response. follows [8]:
Recently, a hybrid controller has been developed for ob-  1
taining desired positions and global attitude trajectory as 
 ẍ = (cos φ sin θ cos ψ + sin φ sin ψ) m U1
1
ÿ = (cos φ sin θ sin ψ − sin φ cos ψ) U

per the initial conditions [21]. The hybrid controller is 

 m 1
1
 z̈ = (cosφ cos θ)  m U1 − g

originated to quash the topological limitations. A novel 

I −I
reconfigurable quadrotor with foldable rotor arms and the φ̈ = θ̇ψ̇ yIx z − JIxr θ̇Ω + Ilx U2 (1)
deployed carrier is proposed [22].  
Iz −Ix

+ Jr φ̇Ω + Ily U3

θ̈ = φ̇ ψ̇


The fundamental point of this investigation is to under- 

  Iy  Iy
 ψ̈ = φ̇θ̇ Ix −Iy + 1 U4

stand the basics of the mathematical model of the quadro- 
Iz Iz
tor. Then different control techniques are developed to
stabilize and perform output tracking control of a quadro- where (x, y, z) are three positions and (φ, θ, ψ) repre-
tor so as to study the efficacy of a designed position and senting pitch, roll and yaw respectively, m is the mass
attitude control system for the quadrotor. of the quadrotor, g is the gravity of the acceleration, l is
The remainder of the paper is organized as follows. the half length of the quadrotor, Jr is the rotor inertia, Ii
In Section 2 the quadrotor model and dynamics of the is the moment of the inertia with respect to the axes, Ω is
quadrotor are presented. The simplified quadrotor equa- the disturbance and Ui (i = 1, 2, 3, 4) is the control input,
tion of motion based on the simplified quadrotor model defined as
is explained here. The PID controller with derivative fil-  
ter and Integral Sliding-Mode Controller (ISMC) is de- 
 U1 = b Ω21 + Ω22 +  Ω23 + Ω24
U2 = bl Ω22 − Ω24 

scribed in Section 3. Validation of simulation results are (2)
also examined as a subsection in Section 3. Finally, the U = bl Ω23 − Ω21
 3

 
2 2 2 2
conclusion is given in Section 4. U4 = d Ω1 − Ω2 + Ω3 − Ω4

where b is the thrust factor, d is the drag factor and Ωi (i =


2. QUADROTOR MODEL 1, 2, 3, 4) is the speed of each rotor. The quadrotor model
The quadrotor is a four-rotor helicopter which has four Eq. (1) has four independent inputs (U1 , U2 , U3 , U4 ) and
actuators and six degrees of freedom. It consists of fixed it has six outputs (x, y, z, φ, θ, ψ), hence, the quadrotor is
pitch angle rotors whereas conventional helicopters are known as an under-actuated system. It means that all the
having variable pitch angles. The desired lift forces of the outputs of the system cannot be controlled directly. The
quadrotor can be achieved by controlling the rotor speed. most efficient way to control the outputs can be x, y, z
The basic structure of the quadrotor and its motions can and ψ with a specific goal to track the desired positions,
be described in Fig. 1. Quadrotor vertical motion can then an arbitrary heading is expected to stabilize the other
be attained by varying the four rotor speed in concert. two angles (φ, θ), which demonstrates a stable system
Varying (2) and (4) propellers speed conversely (reverse) [4]. A characteristic of a successful controller should
produce pitch rotation coupled with lateral motion. Roll acquire the desired positions (xd , yd , zd ) and yaw angle
rotation and the corresponding lateral motion results from while keeping the pitch and roll angles constant.
(1) and (3) propellers speed conversely modified. Yaw ro-
3. THE CONTROLLER DESIGN OF THE
tation is more elusive as its results from the difference in QUADROTOR
the counter-torque between each pair of propellers. The
The main purpose of this paper is to develop a con-
F1 F2 trol algorithm to track the desired trajectory Ξd =
T
(xd , yd , zd ) and a desired yaw angle ψd . The angles of
Front Right
Ω1 zb Ω2
the quadrotor and their time derivatives have no effect on
ψ
the translational subsystem but the translational subsys-
ϕ θ tem depends on the Euler angles. The quadrotor model
Ze F4 F3 Eq. (1) can be split into two subsystems: the position
O
xb yb subsystem Eq. (3) and the attitude subsystem Eq. (4).
mg
Ω4 Ω3
 1
 ẍ = (cos φ sin θ cos ψ + sin φ sin ψ) m U1
Ye Left Back 1
ÿ = (cos φ sin θ sin ψ − sin φ cos ψ) m U1
O (3)
1
z̈ = (cos φ cos θ) m U1 − g

Xe   
I −I Jr l
Fig. 1 The quadrotor model.


 φ̈ = θ̇ψ̇ yIx z − Ix θ̇Ω + Ix U2
  
θ̈ = φ̇ψ̇ IzI−I x
+ Jr
Iy φ̇Ω +
l
Iy U 3 (4)
dynamic model of a quadrotor can be derived using Euler-   y 

 ψ̈ = φ̇θ̇ I x −Iy 1
+ Iz U4

Lagrangian equation and the simplified model is given as Iz

440
So, it is necessary to design two different controllers for trounce this problem, a first-order filter on the derivative
the two subsystems. To obtain the control law U1 and the term is introduced to tune its pole so that the chattering
desired pitch and roll of the quadrotor (φd , θd ), a PID caused by the noise can be removed. It can reduce the
controller with derivative filter is designed, which can effect of high frequency noise so that the derivative will
guarantee the tracking precision. Hence, the desired an- reduce the high frequency noise.
T
gles Hd = (φd , θd , ψd ) are derived. An integral sliding A new control inputs U1x , U1y and U1z are defined as,
mode controller is designed in the attitude subsystem to 
calculate the control laws U2 , U3 and U4 which confirms  U1x = U1 (cos φ sin θ cos ψ + sin φ sin ψ)
the tracking precision and the integral element helps to U1y = U1 (cos φ sin θ sin ψ − sin φ cos ψ) (6)
U1z = U1 (cos φ cos θ)

assure the system’s stability. The overall control strategy
is exhibited in Fig. 2.
Then the equation of the position subsystem can be writ-
ten as follows, 
xd , yd , zd PID with U1 Translational  ẍ = U1x /m
Desired derivative
Position filter
Subsystem
 x, y , z  ÿ = U1y /m (7)
z̈ = U1z − g

d ,  d  , ,  The desired control inputs for X, Y and Z are given
U2 ,U3,U4
d
ISMC
Rotational  , ,  by
Subsystem  R
 ẍ = Kpx (xd − x) + Kix R (xd − x) dt + Kdx (ẋd − ẋ)
ÿ = Kpy (y − y) + Kiy (y − y) dt + K (ẏ − ẏ)
 z̈ = K (zd − z) + K R (zd − z) dt + K dy (ż d − ż)
pz d iz d dz d
Fig. 2 The control scheme of the quadrotor. (8)
where Kpx , Kpy , Kpz are propositional gains of the PID
3.1 PID with derivative filter controller design for the controller; Kix , Kiy , Kiz are the integral gains of the PID
position subsystem controller; Kdx , Kdy , Kdz are the differential gains of the
Control tracking scheme is designed for the position PID controller. Combining Eq. (3) and Eq. (8) it can be
subsystem, which confirms the tracking error to converge given,
to zero asymptotically. A classical PID controller com- R 
prises four parameters and it is a second-order controller m Kpz e + Kiz e + Kdz ė + g
U1 = (9)
but, most of the available techniques are designed only cos φ cos ψ
for three parameters. In this paper, we are using a PID
controller with derivative filter corresponding to a lead- where e = (zd − z) ; ė = (żd − ż).
lag controller in the series form and low-pass filter in the The inverse function combines two equations in Eq.
parallel form. The derivative filter is considered as an in- (8), given rise to the reference value as follows,
stinctive part of the design. N is the bandwidth of the " mẍ #
low-pass filter on the derivative. Use of pure derivative U1 − sin φ sin ψ
θd = arcsin (10)
in PID would amplify measurement noise. Therefore, cos φ cos ψ
in practical implementation, pure derivative should be
avoided and low-pass filter should be used instead. The  
block diagram of PID with filter derivative is shown in (ẍm/U1 ) sin ψ − (ÿm/U1 ) cos ψ
φd = arcsin (11)
Fig. 3. The PID structure can be written as in the Laplace U1
Controller 3.2 The Integral Sliding Mode based control for atti-
Kp
+ tude subsystem
Reference + System
 Error Ki
1 + 
states
s
System The attitude control performance significantly affect
- +
+ the stability of the flight, so it is considered as a vital
Kd  N
-
1
quadrotor control. The ISMC has been implemented to
s track the desired attitude angles. The limitation of using
Feedback sliding mode control is in the presence of disturbances
that it is difficult to obtain zero tracking error. To over-
Fig. 3 The PID controller with derivative filter. come this limitation, an ISMC is adopted for attitude con-
domain, trol. The ISMC applied individually for the control of

Ki

Ns
 pitch, roll and yaw.
Gc (s) = Kp + + Kd E (s) (5)
s s+N
Let the function of the sliding surface determined as
Implementing the derivative term in the PID controller
can cause an excessive size control input to the plant. To S = ė + Ke (12)

441
where K ∈ R+ , e is the tracking error. Table 1 Quadrotor of the parameters
An integral term action scheme is introduced to the slid- Parameter
m
Description
Mass of quadrotor
Nominal Value
0.65
Units
kg
l Half-length of the quadrotor 0.23 m
ing mode control with a sliding surface along which the g Gravitational 9.81
.
m s2
sliding motion is to occur. This surface is represented by b Thrust force coefficient 3.13 × 10−5 kg.m
d Drag torque coefficient 7.5 × 10−7 kg.m2
S and elucidated as follows: Ix Moment of Inertia about X-axis 7.5 × 10−3 kg.m2
Iy Moment of Inertia about Y-axis 7.5 × 10−3 kg.m2
Zt Iz Moment of Inertia about Z-axis 1.3 × 10−2 kg.m2
Jr Moment of Inertia of the rotor 6 × 10−5 kg.m2
S = ė + ρp e + ρI edτ (13)
0

As of the control of phase angle, its dynamic equation behaviour is shown in Fig. 4. The attitude tracking be-
is   haviour is shown in Fig. 5. The simulation results demon-
Iy − Iz Jr l strates that the PID controller with the derivative filter and
φ̈ = θ̇ψ̇ − θ̇Ω + U2 (14)
Ix Ix Ix ISMC are able to stabilize the quadrotor and competent
Let the desired phase angle be φd , and define the error as to proceed to the desired position with the desired yaw
e = φ − φd . Thus, the integral surface is designed as, angle while keeping the pitch angles and roll angles to
zero.
Zt
S = φ̇ − φ̇d + ρ1 e + (ρ2 e)dτ (15)
0

where ρ1 is the sliding line slope and ρ2 is the integral


gain. The sliding surface derivative can be given as

Ṡ = φ̈ − φ̈d + ρ1 ė + ρ2 e (16)

Choosing the following exponential reaching law:

Ṡ = −M sgn (S) − ρS (17)

where M and ρ are positive constants, and sgn (·) denotes


the signum function. From Eq. (14), Eq. (16) and Eq.
(17), it can be shown that:

I −I Fig. 4 Position tracking of x,y,z


U2 = Ilx φ̈d − Ilx θ̇ψ̇ yIx z + Ilx JIxr θ̇Ω̇
(18)
− Ilx Mφ sgn (S) − Ilx ρφ S + Ilx ρ1φ ė + Ix
l ρ2φ e
4. CONCLUSION
Iy Iy Iz −Ix I
U3 = l θ̈d −
l φ̇ψ̇ Iy + ly JIyr φ̇Ω̇ In this paper, we present a new control approach for
I (19) a quadrotor. The dynamics of the quadrotor is divided
− ly Mθ sgn (S) − Ilx ρθ S + Ilx ρ1θ ė + Ilx ρ2θ e
into a position subsystem and attitude subsystem. The
PID controller with first-order derivative filter is proposed
I −I for position subsystem. The integral sliding-mode con-
U4 = Iz ψ̈d − Iz φ̇θ̇ xIz y − Iz Mψ sgn (s)
(20) troller is designed for attitude subsystem which is able to
−Iz ρψ S + Iz ρ1ψ ė + Iz ρ2ψ e
drive the quadrotor to the desired position. Simulations
where Mθ , Mφ , Mψ , ρ1φ , ρ2φ , ρ1θ , ρ2θ , ρ1ψ and ρ2ψ are conducted without parametric uncertainties. The ob-
are the controller parameters, and they are all positive. tained results are able to move to any position and to sta-
bilize the quadrotor. Further research will be carried out
3.3 Simulation validation in real time applications.
The quadrotor parameters and the initial conditions
used in the simulations are demonstrated in Table 1. REFERENCES
In theexperiments, thedesired path is defined as xd = [1] A. Gessow and G. Myers, “Aerodynamics of the he-
1
2 cos 2t ; yd = 21 sin 2t ; zd = 2 + 10 t
; ψd = π6 . In the licopter,” 3rd ed., Frederick Ungar Publishing Co,
simulation, the following controller parameters are used New York, 1967.
as Kpx = Kpy = Kpz = 4.5, Kdx = Kdy = Kdz = 10, [2] Hauser, Sastry, and Meter, “Nonlinear control de-
Kix = Kiy = Kiz = 0.5, N=60. The position tracking sign for slightly non-minimum phase systems: ap-

442
Fig. 7 Control inputs U1 , U2 , U3 , U4

and integral sliding-mode techniques applied to an


indoor micro quadrotor,” Proceedings of the IEEE
Int. Conf. on Robotics & Automation, pp.2259–
Fig. 5 Attitude angle tracking of φ, θ, ψ 2264, 2005.
[10] E. N. Johnson, and S. K. Kannan, “Adaptive trajec-
tory control for autonomous helicopters,” Journal of
Guidance, Control, and Dynamics, vol. 28, no. 3,
pp. 524–537, 2005.
[11] T. Madani and A. Benallegue, “Backstepping con-
trol for a quadrotor helicopter, Proceedings of the
IEEE Int. Conf. on Intelligent Robotics and Sys-
tems,” pp. 3255–3260, 2006.
Fig. 6 Trajectory tracking [12] R. Xu, and U. Ozguner, “Sliding mode control of a
quadrotor helicopter,” Proceedings of the 45th IEEE
Conf. on Decision & Control, San Diego, CA, USA,
plication to V/STOL Aircraft,” Automatica, vol. 28, pp. 4957–4962, 2006.
no. 4, pp. 665–679, 1992. [13] A. Tayebi, and S. McGilvray, “Attitude stabilization
[3] Martin, Devasia, and Paden, “A different look at of a VTOL quadrotor aircraft,” IEEE Trans. Contr.
output tracking: Control of a VTOL aircraft,” Au- Sys. Technology, vol. 14, no.3, pp. 562–571, 2006.
tomatica, vol. 32, no. 1, pp. 101–107, 1996. [14] B. Erginer and E. Altug, “Modelling and PD control
[4] R. Olfati-Saber, “Nonlinear control of underac- of a quadrotor VTOL vehicle,” Proceedings of the
tuated mechanical systems with applications to IEEE Intelligent Vehicle Symposium, pp.894–899,
robotics and aerospace vehicles,” Ph.D. thesis, MIT, 2007.
2001. [15] R. Xu and U. Ozguner, “Sliding mode control
[5] E. Altug, J. P. Ostrowski, and R. Mahony, “Control of a class of underactuated systems,” Automatica,
of a quadrotor helicopter using visual feedback,” vol.44, pp.233–241, 2008.
Proceedings of the IEEE Int. Conf. on Robotics & [16] P.-J. Bristeau, P. Martin, and E. Salaun, “The role of
Automation, pp. 72–77, 2002. propeller aerodynamics in the model of a quadrotor
[6] S. Bouabdallah, P. Murrieri, and R. Siegwart, “De- UAV,” Proceedings of the European Control Confer-
sign and control of an indoor micro quadrotor,” Pro- ence, pp.683–688, 2009.
ceedings of the IEEE Int. Conf. on Robotics & Au- [17] G. Cai, Ben M. Chen, X. Dong and Tong H. Lee,
tomation, pp.4393-4398, 2004. “Design and implementation of a robust and non-
[7] S. Bouabdallah, A. Noth, and R. Siegwart, “PID vs linear flight control system for an unmanned heli-
LQ control techniques applied to an indoor micro copter,” Mechatronics, vol. 21, pp. 803–820, 2011.
quadrotor,” Proceedings of the IEEE/RSJ Int. Conf. [18] M.D. Hua, T. Hamel, P. Morin, and C. Samson,
on Robotics and Systems, pp.2451–2456, 2004. “Introduction to feedback control of underactuated
[8] A. Mokhtari, and A. Benallegue,“Dynamic feed- VTOL vehicles,” IEEE Control Systems Magazine,
back control of Euler angles and wind parame- pp. 61–75, 2013.
ters estimation for a quadrotor unmanned aerial [19] A. Koszewnik, “The parrot UAV controlled by PID
vehicle,” Proceedings of the IEEE Int. Conf. on controllers,” ACTA Mechanica et Automatica, vol.
Robotics & Automation, pp.2359-2366, 2004. 8, no.2, pp. 65–69, 2014.
[9] S. Bouabdallah, and R. Siegwart, “Backstepping [20] V. Hrishikeshavan, E. Shrestha, and I. Chopra,

443
“Controllability analysis of a quadrotor in hover us-
ing empirical gramians,” AHS International Tech-
nical Meeting, 7th VTOL Unmanned Aircraft Sys-
tems Preliminary Program, Mesa, Arizona, 2017.
[21] R. Naldi, M. Furci, R.G. Sanfelice, and L. Mar-
coni, “Robust global trajectory tracking for under-
actuated VTOL aerial vehicles using inner-outer
loop control paradigms,” IEEE Trans. Autom. Con-
trol, vol. 62, no.1, pp. 97–112, 2017.
[22] H. Xiu, T. Xu, Anthony H. Jones, Guowu Wei, and
L. Ren, “A reconfigurable quadrotor with foldable
rotor arms and a deployed carrier,” Proceedings of
the IEEE Int. Conf. on Robotics and Biomimetics,
Macau SAR, China, December-2017.
[23] A. J. Isaksson, and S. F. Graebe, “Derivative filter is
an integral part of PID design,” IEE Proceedings-
Control Theory and Applications, vol. 149, no.1,
pp. 41–45, 2002.

444

You might also like