0% found this document useful (0 votes)
27 views5 pages

Ashis 2019

This document summarizes a research paper presented at the 2019 2nd International Conference on Intelligent Computing, Instrumentation and Control Technologies about dynamic modeling and altitude control of a Parrot Rolling Spider quadcopter. The paper describes modeling the kinematics and dynamics of the quadcopter, and compares controlling altitude using proportional-integral-derivative and linear quadratic regulator control techniques. Simulations were performed in MATLAB/Simulink using a support package for Parrot minidrones to obtain system parameters and test controller performance.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
27 views5 pages

Ashis 2019

This document summarizes a research paper presented at the 2019 2nd International Conference on Intelligent Computing, Instrumentation and Control Technologies about dynamic modeling and altitude control of a Parrot Rolling Spider quadcopter. The paper describes modeling the kinematics and dynamics of the quadcopter, and compares controlling altitude using proportional-integral-derivative and linear quadratic regulator control techniques. Simulations were performed in MATLAB/Simulink using a support package for Parrot minidrones to obtain system parameters and test controller performance.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

2019 2nd International Conference on Intelligent Computing, Instrumentation and Control Technologies (ICICICT)

Dynamic Modeling and Altitude Control of Parrot


Rolling Spider using LQR
Ashis C K1 , Rahul Sharma K.2
Department of Electrical and Electronics Engineering
Amrita School of Engineering, Coimbatore
Amrita VishwaVidyapeetham, India
1
[email protected], 2 k [email protected]

Abstract—Parrot Rolling Spider/minidrone is one of the most drone. The nonlinear model of the quadcopter was linearised
favoured quadcopters around the world which is used for using Jacobian method in [10]. A full state feedback controller
academic and experimental purposes. This paper deals with the was designed here for measuring all the 12 states of the
mathematical modeling of kinematics and dynamics of the parrot
minidrone, employing linear feedback controller for stabilizing quadcopter. The PID controller was tested on a hardware
the system and a comparative analysis of altitude control of prototype [14]. The primary aim of selecting parrot minidrone
Parrot minidrone using Proportional Integral Derivative (PID) for the simulation studies is its availability. Unlike most of the
and Linear Quadratic Regulator (LQR) control techniques. drones, this minidrone is compatible with Simulink working
Matlab/SIMULINK software was used for simulating the plant environment. This work has a step by step approach for
response. The Simulink support package for parrot minidrones
was used for obtaining the parameters of the system. All the studying the system in detail and it has been organized into
studies and simulations conducted in this paper are based different sections. The next section describes the properties of
on kinematics and dynamics of parrot minidrone. The highly the system under study in detail. Successive sections include
nonlinear plant model is linearized around equilibrium points the modelling of the system, controller design, estimation and
and a linear feedback controller is employed for stabilizing the simulation studies.
system.
Keywords—PID, LQR, Matlab, SIMULINK, Parrot Rolling spi-
der II. S YSTEM D ESCRIPTION
The Parrots Rolling Spider is a palm size quadcopter which
I. I NTRODUCTION
works with Bluetooth Low Energy (BLE) technology. It can
Researches on Unmanned Aerial Vehicles (UAVs) are in- be operated with a smartphone which supports BLE. Since
creasing day by day. Because of its huge popularity, UAVs the minidrone weighs only 55 grams, it is more sensitive to
are a hot topic nowadays. A UAV does not carry a human environmetal disturbances. It includes a 3 axis accelerometer, 3
pilot on it. These aerial vehicles are really helpful to test axis gyroscope, 0.3 megapixel 60fps downward facing camera
and evaluate new ideas in the fields like flight control theory, and a pressure sensor. It is compatible with Windows and
robotics, GPS navigation etc. The UAV market is growing Linux operating systems. It has an operating range of 20
everyday with variety of UAVs. Among them, quadcopters meters and is powered by a 550 mAh Lithium-Polymer (Li-
are the widely used ones because of its huge popularity and Po) removable battery which can give a flight time of 8 min-
symmetry. Quadcopters are more vulnerable to environmental utes/6minutes (with wheels). The four BLDC motors mounted
disturbances because of its compact structure. They make use above the drone rotates the propellers. The motherboard of the
of Vertical Take off and Landing (VTOL) technology [15]. rolling spider features Parrot SIP6 chipset with an 800 MHz
Many online delivery companies are on their development Arm A9 processor. The Fig 1 shows the Parrot Rolling Spider
stage to deliver products using drones at the doorstep of their [16].
customers. A stable hovering should be achieved by the system
for this process. LQR has been used over many years in
robotics and it is one of the most trusted control algorithms.
This paper focuses on detailed mathematical modeling of a
quadcopter UAV. For simulation studies, a support package
from Simulink for parrot minidrones was used and was studied
in detail. A practical approach was needed for students to test
their knowledge on flight dynamics, control theory etc. The
Simulink support package for parrot minidrones is a good
initiative from Matlab for this. The lab experiments done in
[4] using parrot minidrone had achieved a stable hovering
Fig. 1. Parrot Rolling Spider

978-1-7281-0283-2/19/$31.00 ©2019 IEEE 1377

Authorized licensed use limited to: Auckland University of Technology. Downloaded on May 27,2020 at 22:00:05 UTC from IEEE Xplore. Restrictions apply.
2019 2nd International Conference on Intelligent Computing, Instrumentation and Control Technologies (ICICICT)

A generic block diagram showing the altitude control of


minidrone using altitude controller is shown in Fig 2. The ν = R·νb (1)
sensors can sense the altitude output and it can feedback the ω = T ·ωb (2)
altitude commands to the controller. The controller can give  T  T
control outputs as thrust commands to the four motors of the where ν = ẋ ẏ ż , ω = φ̇ θ̇ ψ̇ , νb =
system. For controlling the roll angle, pitch angle, yaw anglw  T  T
u v w , ωb = p q r and R is the rotation matrix
and thrust command seperately, seperate PID controllers can which rotates the points from one frame to the other frame.
be implemented in the system. The matrix of angular transformation T is given by,
 
1 s(φ)t(θ) c(φ)t(θ)
0 c(φ) −s(φ) 
T =  (3)
 s(φ) c(φ) 
0
c(θ) c(θ)
The total force experienced by the quadcopter is the sum of
all individual forces acting on x, y and z directions which is
given by,
Fig. 2. Block diagram for altitude control
 
fx
FB = fy  = m(ωb · νb + ν˙b ) (4)
III. S YSTEM MODELING fz
This section explains the kinematics and dynamics of the
where m gives the mass of the system and fx , fy and fz are
quadcopter. A nonlinear state space model has been derived
the forces acting on x, y, and z directions respectively. The
after study. A schematic showing the quadcopter control
total torque on the quadcopter is,
frames is shown in Fig 3. The earth inertial frame consists  
of unit vectors along x, y and z directions. The alignment Mx
of the body reference frame keeps on changing based on the MB = My  = ωb × (I · ωb ) + I · ω˙b (5)
attitude of the quadcopter. The kinematic model of the system Mz
explains about the rotational matrix and matrix of angular
where Mx , My and Mz are the torques acting on x, y, and z
transformation.
directions respectively. The inertia matrix I is given by,
I = diag(Ix , Iy , Iz ) (6)
 
fw = fwx fwy fwz is the force acting on the quadcopter
due to wind effect. The difference in rotor speeds generates a
control torque and is given by,
 T
τB = τx τy τz (7)
Torques produced by wind on quadrotor,
 
τw = τwx τwy τwz (8)
The squared speeds of the rotors is proportional to the torques
and input forces. ie,
   2
b(δ1 + δ22 + δ32 + δ42 )

ft
Fig. 3. Schematic of quadcopter reference frames τx  
 = bl(δ32 − δ12 ) 
 (9)
 τy   bl(δ42 − δ22 ) 
A. Nonlinear model 2 2 2 2
τz d(δ2 + δ4 − δ3 − δ1 )
The physical properties of the quadcopter are measured
using the two reference frames. Some of the physical prop- where the distance between the drone’s centre and the rotor is
erties of the quadcopter such as roll, pitch, yaw angles and denoted by l. b represents thrust factor and d represents drag
the angular velocities are measured in earth frame. Some factor and δi is the speed of the rotor for i = {1, 2, 3, 4}. The
other properties such as linear accelarations are measured in state variables are,
body frame. The linear and angular position vectors T
T of the

 X= x y z u v w φ θ ϕ p q r (10)
quadrotor in earth frame is x y z φ θ ψ where
 T
as u v w p q r is the linear and angular velocity After considering the above kinematics and dynamics of the
vectors in the body frame. The relation between the two quadcopter, the nonlinear model, Ẋ = f (X, U ) can be written
reference frames is, as,

978-1-7281-0283-2/19/$31.00 ©2019 IEEE 1378

Authorized licensed use limited to: Auckland University of Technology. Downloaded on May 27,2020 at 22:00:05 UTC from IEEE Xplore. Restrictions apply.
2019 2nd International Conference on Intelligent Computing, Instrumentation and Control Technologies (ICICICT)

w[s(φ)s(ϕ) + c(φ)c(ϕ)s(θ)] − v[c(φ)s(ϕ) − c(ϕ)s(φ)s(θ)] + u[c(ϕ)c(θ)]


 
 

 ẏ  v[c(φ)c(ϕ) + s(φ)s(ϕ)s(θ)] − w[c(ϕ)s(φ) − c(φ)s(ϕ)s(θ)] + u[c(θ)s(ϕ)]
 
  
 ż   w[c(ϕ)c(θ)] − u[s(θ)] + v[c(θ)s(φ)] 

  
 φ̇   p + r[c(φ)t(θ)] + q[s(φ)t(θ)] 

  
 θ̇   q[c(φ)] − r[s(φ)] 
c(φ) s(φ)

  
 ϕ̇   r c(θ) + q c(θ) 

 = fwx (11)
rv − qw − g[s(θ)] + m

u  
   fwy
pw − ru + g[s(φ)c(θ)] + m

v   
fwz −ft
   
w  qu − pv + g[c(θ)c(φ)] + m 
Iy −Iz
   
p  τx +τwx
Ix rq +

   Ix 
q  Iz −Ix τ y +τ wy
pr +

 Iy Iy 
r Ix −Iy τz +τwz
Iz pq + Iz

The nonlinear model in (11) can further be simplified by A and B are the state matrix and input matrix respectively.
neglecting the forces produced by the wind on quadcopter. The system must be controllable for the design of controllers.
For introducing optimal control, the nonlinear system need to The parameters used for simulating the model in matlab are
be linearized. listed in Table I.

B. Linearization TABLE I
M ODEL PARAMETERS
The nonlinear state space equations can be linearized around
an operating point x̄ with a constant input value ū. A zero atti- Symbols Values Description
m 0.068 kg Mass of the quadcopter
tude condition was considered for linearization. Linearization g 9.81 m/s2 Gravitational constant
of the quadcopter model has been performed for a hovering Ix 0.0686*10−3 kg.m2 MOI along x axis
configuration and is carried out to obtain a generalized linear Iy 0.092*10−3 kg.m2 MOI along y axis
state space model of the form, Iz 0.1366*10−3 kg.m2 MOI along z axis
rho 1.184 kg/m3 Density of air
˙ = Ax(t) + Bu(t)
x(t) (12) b 0.0107 Thrust factor
l 0.0624 m Rotor to drone centre length
r 0.033 m Rotor radius
where,
 
0 0 0 1 0 0 0 0 0 0 0 0
0 IV. C ONTROLLER D ESIGN
0 0 0 1 0 0 0 0 0 0 0
A. PID control
 
0 0 0 0 0 1 0 0 0 0 0 0
 
0 0 0 0 0 0 0 0 0 0 0 0 A linear PID controller can be applied on a nonlinear
 
0 0 0 0 0 0 0 0 0 0 0 0 system without linearizing the system dynamics about the
 
0 0 0 0 0 0 0 0 0 0 0 0 equilibrium point. The controller can still stabilize the system
A=  (13)
0
 −g 0 0 0 0 0 0 0 0 0 0
 in case of external forces. The Simulink support package for
g 0 0 0 0 0 0 0 0 0 0 0 parrot minidrones was utilized for the PID control simulation.
 
0 0 0 0 0 0 0 0 0 0 0 0 This package includes one Simulink model with dynamics of
 
0 0 0 0 0 0 1 0 0 0 0 0 linear and nonlinear model. It also includes sensor dynamics
 
0 0 0 0 0 0 0 1 0 0 0 0 and disturbance. The flight control system bock includes six
0 0 0 0 0 0 0 0 1 0 0 0 PID controllers for stabilizing the system. A Proportional
Derivative (PD) controller was sufficient enough for the system
0 0 0 0
 
to stabilize itself at a reference altitude. The PID control output
0 0 0 0 is given as,

0 0 0 0

Z

0 1
0 0
 de(t)
Ix
1
u(t) = Kp e(t) + Ki e(t)dt + Kd (15)
dt
 
0 0 Iy 0
 
0 1  where u(t) denotes the control input, Kp denotes the propor-
0 0
B= Iz  (14)
0
 0 0 0  tional gain, Ki denotes the integral gain and Kd denotes the
0
 0 0 0  derivative gain. The tracking error,
1 0 0 0
m
0
 e(t) = y(t) − r(t) (16)
 0 0 0 
0 0 0 0 where y(t) and r(t) are the output and the desired output of
0 0 0 0 the system respectively.

978-1-7281-0283-2/19/$31.00 ©2019 IEEE 1379

Authorized licensed use limited to: Auckland University of Technology. Downloaded on May 27,2020 at 22:00:05 UTC from IEEE Xplore. Restrictions apply.
2019 2nd International Conference on Intelligent Computing, Instrumentation and Control Technologies (ICICICT)

B. Linear Quadratic Regulator The LQ control simulation for the minidrone has been
LQR formulates a state feedback law for a full state feed- shown in Fig 5. The control input given to the drone and
back control. The state feedback law for LQR is, the altitude output obtained after simulation has been plotted.
For LQ control, equation (17) is used as the controller model,
with parameters R = diag(0.01, 0.01, 0.01, 0.01) and Q =
u = −Kx (17)
diag(0, 0, 0, 0, 0, 0, 0, 0, 150, 150, 150, 150). From the plot, it
where u and K are the control input and the state feedback can be seen that the drone was able to track the reference
gain respectively. The process is assumed to be a continuous command.
time Linear Time Invariant (LTI). The function to be mini- Output
mized is given by, 2.5

2
z reference
z

Altitude(m)
Z ∞ 1.5

(xT Qx + uT Ru + 2xT N u)dt


1
J(u) = (18) 0.5

0 0

-0.5
where Q, R and and N are the state cost, control cost and 0 1 2 3 4 5
Time(s)
6 7 8 9 10

Control input
an optional cross term matrices respectively subject to the 60

40
dynamics of the system,

Voltage(V)
20

0
˙ = Ax(t) + Bu(t)
x(t) -20

(19) -40
y(t) = Cx(t) 0 1 2 3 4 5
Time(s)
6 7 8 9 10

The LQR controller generates the control law using A, B, Q Fig. 5. Altitude control with LQR
and R matrices. Solution of S can be obtained by solving the
Algebraic Riccati equation, The performance evaluation of the controllers has been
T
A S + SA − (SB + N )R −1 T T
(B S + N ) + Q = 0 (20) tabulated in Table II. From the table, it can be observed that
the LQR can give a better response than PID.
K can be derived as,
TABLE II
K = R−1 (B T S + N T ) (21) P ERFORMANCE EVALUATION OF CONTROLLERS

V. S IMULATION RESULTS Controller Settling time Peak overshoot Steady state error
PID 3 1.605 0.005
Matlab/SIMULINK software was used for simulating the LQR 2.5 1.56 0.005
plant model using PID and Linear Quadratic (LQ) control.
The altitude responses with PID and LQR controllers has
been plotted. Using equation (1) as the nonlinear model, a VI. C ONCLUSION AND FUTURE SCOPE
PID controller in the form of (15) was considered with a A nonlinear mathematical model of the Parrot Rolling
sampling time of T s = 0.05 second. The altitude control Spider, considering kinematics and dynamics of the system
of parrot minidrone using PID control is shown in Fig 4. A has been derived. Simulation on altitude control of the quad-
reference command of 1.5 meters was given to the model. copter using PID and LQR control has been done using
The PD controller for altitude control was able to stabilize the Matlab/SIMULINK software and simulation outputs has been
system within 5 seconds. The PD controller made the system observed. From the simulation studies it can be observed that
to hover at 1.5 meters. Tuning the PD controller for Kp = 0.8 the steady state error caused when using PID controller has
and Kd = 0.3 will result in a hovering control. been considerably reduced when LQ control technique was
introduced. Also the LQ control provided a better tracking of
1.8
PID control output the system with minimum settling time. This paper focussed
z
1.6 z reference on simulation studies of a stable hovering drone. Tuning the
1.4 PID control parameters was not that much difficult across
1.2
the studies. The minidrone was able to achieve stability at
Altitude (meter)

1
hovering condition by using the two controllers discussed in
0.8
the paper. When compared to the conventional PID control
0.6
technique, optimal control can ignore the difficulty in tuning
0.4
the PID control parameters. Instead of using six PID con-
0.2
trollers for the whole system, one LQR controller will be
0
enough for multiaxis control of minidrone. Future studies can
0 5 10 15 20 25 30
Time (seconds)
be carried out on the actual hardware by making use of the
Parrot minidrone support package from the Simulink which
Fig. 4. Altitude control with PID comes from the Aerospace blockset. The control technique

978-1-7281-0283-2/19/$31.00 ©2019 IEEE 1380

Authorized licensed use limited to: Auckland University of Technology. Downloaded on May 27,2020 at 22:00:05 UTC from IEEE Xplore. Restrictions apply.
2019 2nd International Conference on Intelligent Computing, Instrumentation and Control Technologies (ICICICT)

studied in this paper can be verified by deploying that to the


minidrone hardware after making modifications in the flight
control system block.
R EFERENCES
[1] Z. Benic, P. Piljek, and D. Kotarski, Mathematical Modelling of Un-
manned Aerial Vehicles with Four Rotors, Interdiscip. Descr. Complex
Syst., vol. 14, no. 1, pp. 88100, 2016.
[2] Q. Huang and B. Wingo, Mathematical Modeling of Quadcopter Dy-
namics Mathematical Modeling of Quadcopter Dynamics, 2016.
[3] J. Li and Y. Li, Dynamic analysis and PID control for a quadrotor, Int.
Conf. Mechatronics Autom., pp. 573578, 2011.
[4] R. Mahtani and A. Ollero, Control and Stability Analysis of quadcopter,
Int. Conf. Comput. Math. Eng. Technol. iCoMET, pp. 27, 2018.
[5] K. Patel and J. Barve, Modeling, simulation and control study for the
quad-copter UAV, 2014 9th Int. Conf. Ind. Inf. Syst., pp. 16, 2014.
[6] M. F. Everett, LQR with Integral Feedback on a Parrot Minidrone, no.
4, p. 6, 2015.
[7] A. Merheb and H. Noura, Emergency Control of AR Drone Quadrotor
UAV Suffering a Total Loss of One Rotor, vol. 4435, no. c, pp. 111,
2017.
[8] H. talla M. N. ElKholy, Dynamic Modeling and Control of a Quadrotor
Using Linear and Nonlinear Approaches, Master Thesis, Am. Univ.
Cairo, pp. 1143, 2014.
[9] J. Ajmera and V. Sankaranarayanan, Trajectory tracking control of a
quadrotor, 2015 Int. Conf. Control Commun. Comput. India, no. July,
pp. 4853, 2015.
[10] D. Uri and H. Lyu, Multivariable Control of a Rolling Spider Drone,
2017.
[11] B. E. Demir, R. Bayir, and F. Duran, Real-time trajectory tracking of an
unmanned aerial vehicle using a self-tuning fuzzy proportional integral
derivative controller, Int.J. Micro Air Veh., vol. 8, no. 4, pp. 252268,
2016.
[12] K. A. G. N. A. Tzes, Model predictive quadrotor control : attitude ,
altitude, vol. 6, no. March, pp. 18121827, 2012.
[13] S. Saha and S. Wadoo, Linear Optimal Control of a Parrot AR Drone
2 . 0, no. 9, 2017.
[14] V. Praveen and Dr. Anju Pillai S, Modelling and simulation of quad-
copter using PID controller, International Journal of Control Theory and
Applications, vol. 9, pp. 7151-7158 (2016).
[15] Anoop S, K Rahul Sharma, ”Model Predictive Control: Simulation
Studies for the Implementation on Vertical Take-Off and Landing Lab
Prototype”, 8th International Conference on Advances in Computing and
Communication (ICACC-2018), Vol. 143, pp. 663-670
[16] https://www.amainhobbies.com/parrot-rolling-spider-rtf-micro-electric-
quadcopter-drone-blue-ptapf723001/p362168

978-1-7281-0283-2/19/$31.00 ©2019 IEEE 1381

Authorized licensed use limited to: Auckland University of Technology. Downloaded on May 27,2020 at 22:00:05 UTC from IEEE Xplore. Restrictions apply.

You might also like