Autonomous Flight Control For An RC Helicopter
Autonomous Flight Control For An RC Helicopter
Abstract – This paper presents an autopilot system for a Radio evaluation of the same results, together with a brief
Controlled (RC) helicopter, in a simulation environment. The discussion of future work in this area.
controller is designed using Fuzzy Logic in order to achieve
simplicity and cost effectiveness. The system controls the II. BASIC KINEMATIC MODELLING
helicopter from takeoff to landing, allowing the craft to reach The helicopter is represented in 3D space by its position
any position and hover stably with a defined yaw attitude at the (X, Y and Z co-ordinates) and its rotations about the co-
request of the user. The Fuzzy Inference Systems (FIS) in use ordinate axis (yaw, pitch and roll). Due to the six-degree of
were able to allow for these operations with more than
freedom dynamics (6DOF), three frames of reference are
satisfactory results, even in simulated winds.
used. The earth co-ordinate system is centred at the starting
Index Terms — Autonomous Helicopter Flight, fuzzy logic location of the helicopter, and is used to map positions of the
control, Unmanned Aerial Vehicles. helicopter in 3D space. The model axis is positioned at the
centre of gravity (c.o.g.) of the helicopter, and is used to
I. INTRODUCTION define rotations with respect to the initial orientation. This
Although helicopters are some of the most agile (and can be conceptualised as having another co-ordinate axis
thus useful) machines ever invented, they remain some of (spatial frame) at the c.o.g. of the helicopter but with its
the most difficult contraptions to fly and control, with orientation fixed as for the earth frame. Rotations are then
autopilot technology still in its infancy. This stems in part defined between the model frame and the latter one.
from the complexities involved in mathematically modeling In order to use conventional matrix transformations, the
helicopter dynamics [1], which are somewhat unstable and well-known North-East-Down (NED) co-ordinate system is
highly coupled [2] making it very difficult to control them. employed [11]. However, the simulator itself uses a different
Some projects have indeed been implemented in this area representation, with the model facing –X, the left side
([3], [4], [5], [6] and [7]). However most, if not all, involve pointing towards +Z and the pilot head towards +Y. Thus, in
elaborate solutions which are too complex and expensive to retrieving the position/velocity data from the simulator,
be applicable to everyday situations; many are oriented these had to be appropriately converted. Acceleration data is
towards military applications. This project aims to achieve obtained by a first order derivative of the velocity data,
adequate flying performance for a Radio Controlled (RC) utilising the current and previous sample values:
helicopter with a focus on simplicity of design and cost
(1)
effectiveness. Fuzzy Logic Controllers (FLCs) are ideal for
these goals: they are certainly easier to design, requiring
limited insight into helicopter mathematics, while allowing Additionally, a moving average of the acceleration data
for relatively cheap hardware for a physical implementation. is then computed, covering ten sample points, to smooth out
In fact such techniques have already been tested, as any noise. This size appeared to be the best at the sampling
highlighted in [8], [9] and [10]. This project builds upon such rate used, in reducing noise, while not contaminating the
systems to develop a controller which is easy to design acceleration data with values that are too old.
without having to go into complex state-space representation. With respect to orientation, the simulator provides only
The project uses a model of the Honey Bee King II RC the rotational velocities in model co-ordinates. In order to
helicopter [14], in SVK Systems’ Clearview Simulator [16]. get at the attitude, these must be converted into the spatial
The user interacts with the controller by commanding a set frame (as indicated in [12]) and integrated over the elapsed
of positions and yaw attitudes, which the autopilot attempts simulation time. Angular acceleration is calculated in a
to achieve. The control system is modularised according to similar way to linear acceleration. In this way, angular rates
each of the control axes: collective for height control, lateral and accelerations are expressed in the model frame which is
and longitudinal cyclic for horizontal motion and heading adequate, since the control systems act in the same frame.
control through the tail collective. The Fuzzy Logic A further point needs to be noted regarding the angle
Controllers were designed using Matlab®’s Fuzzy Logic values. Obviously, orientation is limited over a range of 2π,
Toolbox, and ported to the C++ application implementing either between 0 and 2π or between –π and +π. As such, care
the controller as Look-Up Tables (LUT). The latter must be taken in the integration process to normalise the
application interfaces with the simulator using TCP/IP. angle to these regions as described hereunder:
The rest of the paper is organized as follows. Section II
introduces the theory regarding the kinematics involved in { (2)
the project: section III briefly covers the software
architecture, following with a description of the control
methodology used, in section IV. Section V presents the Also note that all the Fuzzy Inference Systems (FIS) act
results achieved. Finally the paper concludes with an upon an error in some axis of translation/rotation, defined as:
Angle/rad
-0.1
In addition, it was necessary to augment the Hover FIS -0.2
with two integral schemes. The first is enabled when the -0.3 Pitch Attitude
helicopter achieves steady state. It accumulates the error in -0.4
Pitch Cyclic Control
the X (or Y), multiplied by an integral control factor (0.0001 -0.5
Pitch Reference
for the X and 0.0005 for the Y, due to the roll axis having 5 10 15
Time/s
20 25 30
slightly slower dynamics), and adds it to the error input of Fig. 2. Pitch Reference and Attitude, with cyclic commands
the same FIS. The other scheme adds directly to the output
of the Cyclic FIS, and was necessary in windy conditions, 0.3
Roll Attitude
since the limits set at ± 0.1c, although sufficient to provide 0.2
Roll Reference
Roll Cyclic Control
stability, were unable to overcome wind disturbances. In this
Angle/rad
0.1
case, enabled by the user, the integral scheme accumulates
the error multiplied by 0.001 and saturated to ±0.25 only if 0
6
(keeping all else constant) and the respective controller
attempted to achieve it. During the simulation, data was 4
393
15
X-Pos of Helicopter
would render it difficult to manoeuvre in tight spaces. Some
X-Velocity degree of mathematical modelling to account for the axial
10 X-Reference
coupling can aid in this regard. The end goal would be to
Distance/m