Professional Documents
Culture Documents
Full Control of A Quadrotor
Full Control of A Quadrotor
spin the rotor. 4) Rotor Dynamics: OS4 is equipped with four fixed-
pitch rotors, each one includes a BrushLess DC (BLDC)
Q = CQ ρA(ΩRrad )2 Rrad motor, a one-stage gearbox and a propeller. The entire rotor
CQ 1 2 1 1 1 (3) dynamics was identified and validated using the Matlab
σa = 8a (1 + µ )Cd + λ( 6 θ0 − 8 θtw − 4 λ)
Identification Toolbox. A first-order transfer function (6) is
Rolling moment Rm is the integration over the entire rotor sufficient to reproduce the dynamics between the propeller’s
of the lift of each section acting at a given radius (not to speed set-point and its true speed.
confuse with the overall rolling moment). 0.936
G(s) = (6)
2
0.178s + 1
Rm = CRm ρA(ΩRrad ) Rrad
CRm 1 1 1 (4) C. Equations of Motion
σa = −µ( 6 θ0 − 8 θtw − 8 λ)
The equations of motion are derived from the dynamic
Ground effect is related to a reduction of the induced airflow model already developed in the author’s thesis [2] and all
velocity. The principal need is to find a model of this effect the forces and moments listed in Subsection II-B.
for OS4 to improve the autonomous take-off and landing P4
i+1 P
4
wd1,...,d4 Zd
φ̇
Quadrotor ST Motor Speed
θ̇ψ̇a1 + θ̇a2 Ωr + b1 U2 Take-off/Landing
tf,q,j Control
Control
θ̇
PI
φ̇ψ̇a3 − φ̇a4 Ωr + b2 U3
ψ̇
Fig. 2. The control structure implemented on OS4.
θ̇φ̇a5 + b3 U4
f (X, U ) = (12)
ż
1
g − (cos φ cos θ) m U1
simulation and experimentation, Integral Backstepping was
ẋ
proposed as a single approach for attitude, altitude and
1
ux m U1
ẏ
position control. This process is presented in the next section.
1
uy m U1 Thanks to this technique, OS4 is able to perform autonomous
hovering with altitude control and autonomous take-off and
With: landing. The derivation is similar for attitude, altitude and
a1 = (Iyy − Izz )/Ixx b1 = l/Ixx
a2 = Jr /Ixx b2 = l/Iyy position controllers. So, only roll angle controller derivation
a3 = (Izz − Ixx )/Iyy b3 = 1/Izz (13) will be presented. The OS4 control system is structured in
a4 = Jr /Iyy six different controllers as illustrated in Fig. 2. Take-off
a5 = (Ixx − Iyy )/Izz and landing controller outputs the desired altitude (zd ) to
ux = (cos φ sin θ cos ψ + sin φ sin ψ) altitude controller which outputs the desired overall thrust
(14) (Td ) based on sonar data. Position controller receives OS4
uy = (cos φ sin θ sin ψ − sin φ cos ψ)
position (x, y) and desired thrust, it outputs desired roll
It is worthwhile to note in the latter system that the angles
(φd ) and pitch (θd ) while desired yaw (ψd ) comes directly
and their time derivatives do not depend on translation
from the user. Attitude controller outputs then the desired
components. On the other hand, the translations depend
motor speed to the motor controllers. Integral backstepping
on the angles. One can ideally imagine the overall system
technique is used for attitude, altitude and position control.
described by (12) as constituted of two subsystems, the
This permits a powerful and flexible control structure.
angular rotations and the linear translations.
B. Attitude Control
A. Control Approach Selection
Attitude control is the heart of the control system, it keeps
During the OS4 project we explored several control ap- the 3D orientation of the helicopter to the desired value.
proaches from theoretical development to final experiments. Attitude control loop runs at 76 Hz which is the update rate
As a first attempt, we tested on OS4 two linear controllers, of the IMU (Microstrain 3DM-GX1). The first step in IB
a PID and an LQR based on a simplified model. The main control design is to consider the tracking-error e1 = φd − φ
result was an autonomous hover flight presented in [7]. How- and its dynamics:
ever, strong disturbances were poorly rejected as in presence
de1
of wind. In the second attempt we reinforced the control = φ̇d − ωx (15)
using backstepping techniques. This time, we were able to dt
elegantly reject strong disturbances but the stabilization in The angular speed ωx is not our control input and has its
hover flight was delicate (see [8]). Another improvement is own dynamics. So, we set for it a desired behavior and we
now introduced thanks to integral backstepping (IB) [10]. consider it as our virtual control:
The idea of using integral action in the backstepping design ωxd = c1 e1 + φ̇d + λ1 χ1 (16)
was first proposed in [11] and applied in [12] from which Rt
this control design was derived. After the evaluation of with c1 and λ1 positive constants and χ1 = 0 e1 (τ )dτ the
all the control approaches tested in this work, it became integral of roll tracking error. So, the integral term is now
clear that the way to follow is a combination between PID introduced in (16).
and Backstepping into the so-called Integral Backstepping. Since ωx has its own error e2 , we compute its dynamics
In fact, the backstepping is well suited for the cascaded using (16) as follows:
structure of the quadrotor dynamics. Moreover, the controller de2
design process can be straight forward if done properly. In = c1 (φ̇d − ωx ) + φ̈d + λ1 e1 − φ̈ (17)
dt
addition, this method guarantees asymptotic stability and has
where e2 , the angular velocity tracking error is defined by:
robustness to some uncertainties, while the integral action
cancels the steady state errors. After a phase of extensive e2 = ωxd − ωx (18)
Roll angle Pitch angle
0.5 0.5
Using (16) and (18) we rewrite roll tracking error dynamics 0.4 0.4
as: 0.3
0.2
0.3
0.2
de1
Pitch [rad]
0.1 0.1
Roll [rad]
= −c1 e1 − λχ1 + e2 (19) 0 0
dt -0.1
-0.2
-0.1
-0.2
-0.3 -0.3
-0.5
-0.4
-0.5
0 5 10 15 20 25 30 0 5 10 15 20 25 30
model (12), the control input U2 appears in (20): Time [s] Time [s]
Yaw angle
0.5
de2 0.4
dt 0.2
0.1
Yaw [rad]
0
The real control input has appeared in (20). So, using -0.1
-0.2
equations (15), (19) and (20) we combine the tracking errors -0.3
-0.4
de2
= −c2 e2 − e1 (22)
dt
This is obtained if one chooses the control input U2 as:
1
U2 = + [(1 − c21 + λ1 )e1 + (c1 + c2 )e2
b1
−c1 λ1 χ1 + φ̈d − θ̇ψ̇a1 − θ̇a2 Ωr ] (23) Fig. 4. OS4 in hover. A training frame was added for safety.
0.4 0.4
x [m]
y [m]
0 0
Altitude [m]
-0.2 -0.2
0.4
-0.4 -0.4
-0.6 -0.6
0.3
-0.8 -0.8
-1 -1
0 5 10 15 20 25 30 0 5 10 15 20 25 30
0.2
Time [s] Time [s]
0.8 0.8
0
0 5 10 15 20 25 30 0.6 0.6
Time [s]
0.4 0.4
0.2 0.2
dx [m/s]
dy [m/s]
Fig. 5. Autonomous take-off, altitude control and landing in simulation 0
-0.2
0
-0.2
-0.6 -0.6
-0.8 -0.8
-1 -1
0 5 10 15 20 25 30 0 5 10 15 20 25 30
Time [s] Time [s]
D. Position Control
Position control keeps the helicopter over the desired Fig. 7. Four way-points for a square trajectory tracked by OS4.
point. It is meant here the (x, y) horizontal position with
regard to a starting point. Horizontal motion is achieved by
orienting the thrust vector towards the desired direction of The control laws are then:
motion. This is done by rotating the vehicle itself in the case
Ux = Um1 [(1 − c29 + λ5 )e9 + (c9 + c10 )e10 − c9 λ5 χ5 ]
of a quadrotor. In practice, one performs position control by
rolling or pitching the helicopter in response to a deviation Uy = − m [(1 − c2 + λ6 )e11 + (c11 + c12 )e12 − c11 λ6 χ6 ]
U1 11
from the yd or xd references respectively. Thus, the position (33)
controller outputs the attitude references φd and θd , which where (c9 , c10 , c11 , c12 , λ5 , λ6 ) are positive constants.
are tracked by the attitude controller (see Fig. 2). The thrust 1) Results: The main result in position control was ob-
vector orientation in the earth fixed frame is given by R, the tained in simulation. Fig. 2 shows how the different con-
rotation matrix. Applying small angle approximation to R trollers are cascaded. In fact, only the attitude is driven
gives: by the position, altitude controller is simply feeding them
1 ψ θ with U1 . Attitude and position loops run at 76 Hz and 25 Hz
R = ψ 1 −φ (29) respectively. This spectral separation is necessary to avoid a
−θ φ 1 conflict between the two loops; it is often accompanied with
gain reductions in the driving loop. Control parameters were
From (12) and using (29) one can simplify horizontal motion C9 = 2, C10 = 0.5, C11 = 2, C12 = 0.5 in the simulation of
dynamics to Fig. 6.
mẍ −θU1 2) Way-points following: The planner block in the simu-
= (30)
mÿ φU1 lator defines the way-points and hence the trajectories OS4
has to follow. The position of the next way-point is sent
The control law is then derived using IB technique. Position to position controller which directs the vehicle towards the
tracking errors for x and y are defined as: goal. A way-point is declared reached when the helicopter
enters a sphere around this point. The radius of this sphere
e9 = xd − x
(31) (0.1 m) is the maximum admitted error. Figure 7 shows a
e11 = yd − y
square trajectory defined by four way-points. The task was
Accordingly speed tracking errors are: to climb to 1 m from the ground and then follow the four
way-points of a square of 2 m side. In order to track the
e10 = c9 e9 + ẋd + λ5 χ5 − ẋ square trajectory, the planner generates the (xd , yd ) position
(32)
e12 = c11 e11 + ẏd + λ6 χ6 − ẏ references, and consequently the position controller generates
Fig. 9. Experiment: Collision avoidance with OS4. The helicopter flies
back until the obstacle disappears.
Fig. 8. Simulation: The position and attitude signals generated to track the
square trajectory. experiment has shown that OS4 is currently able to take-
off, hover, land and avoid collisions automatically thanks to
model-based control. The future work is to firstly enhance
the (φd , θd ) attitude references for every cycle. Figure 8 the propulsion group towards more reliability and high
depicts these signals and shows that the 2 m side square bandwidth. Secondly, it is necessary to improve the vision
is tracked with about 10% overshoot (20 cm), while the sensor in order to get rid of the external pattern. Thirdly,
trajectory is completed in 20 s. it would be very interesting to practically test a way-points
following maneuver with obstacle avoidance capability. OS4
E. Obstacle Avoidance is undoubtedly one of the most integrated quadrotor ever
OS4 is equipped with a sonar-based obstacle avoidance designed. As far as we know, it is the first one practically
system composed of four miniature ultrasound range finders capable of a collision avoidance maneuver.
in cross configuration. Several algorithms were simulated V. ACKNOWLEDGMENTS
with various results presented in details in [13]. The lack
The authors gratefully acknowledge all the people that
of precise sensors for linear speed made the implementation
contributed directly or indirectly to this work.
of this approach difficult. A simple collision avoidance
algorithm was then developed. The idea was to avoid col- R EFERENCES
lision with walls or persons present in the flight area. The [1] RCtoys, http://www.rctoys.com/.
inherent noise of the sonar especially in absence of obstacles [2] S. Bouabdallah, “Design and control of quadrotors with application to
was threatening OS4 stability. This is mainly due to the autonomous flying,” Ph.D. dissertation, EPFL, 2006.
[3] G. Fay, “Derivation of the aerodynamic forces for the mesicopter
interferences between the five sonar and the effect of the simulation,” Stanford University, USA, 2001.
propellers on the ultrasound waves. [4] E. Altuğ, “Vision based control of unmanned aerial vehicles with
1) Results: A collision avoidance behavior was practically applications to an autonomous four rotor helicopter, quadrotor,” Ph.D.
dissertation, University of Pennsylvania, 2003.
obtained after numerous tests and tuning. Once the obstacle [5] P. Castillo et al., Modelling and Control of Mini-Flying Machines.
is detected, a pitch reference is given to fly away the Springer.
helicopter from the obstacle. Figure 9 shows the reaction [6] N. Guenard et al., “Control laws for the tele operation of an unmanned
aerial vehicle known as an x4-flyer,” in Proc. (IEEE) International
of OS4 to an obstacle at 40 cm, one can see the distance to Conference on Intelligent Robots (IROS’06), Beijing, China, 2006.
the obstacle increasing until the latter disappears, then OS4 [7] S. Bouabdallah et al., “Design and control of an indoor micro
recovers a normal flight. quadrotor,” in Proc. (IEEE) International Conference on Robotics and
Automation (ICRA’04), New Orleans, USA, 2004.
[8] S. Bouabdallah and R. Siegwart, “Backstepping and sliding-mode
IV. CONCLUSIONS AND FUTURE WORKS techniques applied to an indoor micro quadrotor,” in Proc. (IEEE)
International Conference on Robotics and Automation (ICRA’05),
This paper presented the final developments in OS4 Barcelona, Spain, 2005.
project. A quadrotor simulation model was introduced. It [9] J. G. Leishman, Principles of Helicopter Aerodynamics. Cambridge
University Press.
includes major aerodynamical effects modeled with blade [10] M. Krstić et al., Nonlinear and Adaptive Control Design. New York,
element and momentum theory. In addition, the actuator’s USA: Wiley Interscience, 1995.
model was identified and all sensor delays and noises were [11] I. Kanellakopoulos and P. Krein, “Integral-action nonlinear control of
induction motors,” in Proc. of the 12th IFAC World Congress, Sydney,
taken into account. Real experiments were conducted with Australia, 1993.
the same control parameters tuned in simulation. A control [12] Y. Tan et al., “Advanced nonlinear control strategy for motion control
approach was proposed it permitted the design of the main systems,” in Proc. of (IEEE) Power Electronics and Motion Control
Conference, (PIEMC’00), Beijing, China, 2000.
controllers: Attitude, altitude, position and the auxiliary ones: [13] S. Bouabdallah et al., “Toward obstacle avoidance on quadrotors,” in
Take-off and landing, obstacle avoidance and way-point Proc. of the XII International Symposium on Dynamic Problems of
following. The latter was demonstrated in simulation. The Mechanics (DYNAME’07), Ilhabela, Brazil, Feb. 2006.