Next Article in Journal
CSAC-Net: Fast Adaptive sEMG Recognition through Attention Convolution Network and Model-Agnostic Meta-Learning
Next Article in Special Issue
Application of Improved CycleGAN in Laser-Visible Face Image Translation
Previous Article in Journal
Sensor Screening Methodology for Virtually Sensing Transmission Input Loads of a Wind Turbine Using Machine Learning Techniques and Drivetrain Simulations
Previous Article in Special Issue
A Review of the Methods on Cobb Angle Measurements for Spinal Curvature
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Research on Trajectory Tracking Control of Inspection UAV Based on Real-Time Sensor Data

Department of Mechanical and Electronic Engineering, School of Mechanical and Material Engineering, North China University of Technology, Beijing 100144, China
*
Author to whom correspondence should be addressed.
Sensors 2022, 22(10), 3648; https://doi.org/10.3390/s22103648
Submission received: 25 February 2022 / Revised: 7 April 2022 / Accepted: 11 April 2022 / Published: 11 May 2022

Abstract

:
In power inspection, uncertainties, such as wind gusts in the working environment, affect the trajectory of the inspection UAV (unmanned aerial vehicle), and a sliding mode adaptive robust control algorithm is proposed in this paper to solve this problem. For the nonlinear and under-driven characteristics of the inspection UAV system, a double closed-loop control system which includes a position loop and attitude loop is designed. Lyapunov stability analysis is used to determine whether the designed system could finally achieve asymptotic stability. Sliding-mode PID control and a backstepping control algorithm are applied to analyze the superiority of the control algorithm proposed in this paper. A PX4 based experimental platform system is built and experimental tests were carried out under outdoor environment. The effectiveness and superiority of the control algorithm are proposed in this paper. The experimental results show that the sliding mode PID control can achieve good accuracy with smaller computing costs. For nonlinear interference, the sliding mode adaptive robust control strategy can achieve higher trajectory tracking accuracy.

1. Introduction

Since the second industrial revolution, electricity has played an indispensable role in human life. China has a vast territory, and overhead transmission lines cover most of it for power transmission. However, most of these transmission networks are built outdoors and are vulnerable to bird nesting, thunder, and lightning. Therefore, it is necessary to conduct power inspections on the transmission line network. At present, China mainly uses electric inspection drones for this project. Compared with manual inspections, inspection drones can improve inspection efficiency and enhance safety [1,2,3]. As shown in Figure 1, electric power workers are conducting electric inspection work by use inspection drone.
In the power inspection project, the inspection drone works according to the inspection trajectory established by the staff, as shown in Figure 2. However, due to the interference of factors such as wind gusts at work, the inspection UAV has deviations in the process of tracking the inspection trajectory. Therefore, it is very necessary to design a controller that can make the patrol unmanned and track the patrol track stably.
At present, researchers have proposed the following control algorithms for the trajectory tracking control of the inspection drone: PID control, adaptive control, backstepping control, active disturbance rejection control, sliding mode control, etc. [4,5,6,7]. The PID control structure is simple, but the process of adjusting the parameters is relatively cumbersome and the robustness is poor.
Literature [8,9] uses PID control algorithm to design the controller. The error is calculated by the data obtained by the position and attitude sensor and theoretical data, the PID parameters are adjusted to make the error approach zero, and the flight trajectory of the UAV can be tracked. However, there are two main disadvantages. On the one hand, the process of adjusting parameters is complicated, while on the other hand, the robustness is poor, and it is difficult to achieve high-precision trajectory tracking. Literature [10] proposed the use of back-stepping control to design the trajectory tracking controller, establishing the position and attitude error dynamic model of the UAV, using the backstepping method to design the stabilization control items, and using Lyapunov theory to prove the closed-loop system stability, the final trajectory tracking experiment proved the effectiveness of the control algorithm. Although the system is stable, after disturbance is added, the tracking effect becomes worse, and the anti-interference ability of the system is not strong. In [11], the extended state observer of the switching function is used to estimate the disturbance in trajectory tracking, and the calculated estimated value is combined with sliding mode control to finally achieve the trajectory tracking effect. However, chattering occurs in sliding mode control, and the tracking accuracy is affected. Literature [12] uses dual-loop control to achieve high-precision trajectory tracking. The inner loop adopts sliding mode control, while the outer loop adopts linear auto-disturbance rejection control to suppress external interference. Experiments have proven that this method has fast response speed, strong robustness, and can meet the needs of trajectory tracking control of inspection drones. In the literature [13,14,15], fuzzy control is used to design the controller, and the fuzzy system is used to gradually approximate the uncertain items and external interference in the attitude model, while the controller is designed in combination with back-stepping control, which improves the accuracy of trajectory tracking. In recent years, neural network control has begun to increase in popularity, and it has also been favored by scholars. In the literature [16,17,18], facing the uncertainty of the inspection UAV model, the neural network control is used to approximate, and then the external disturbance is suppressed by the observer. Finally, combined with the backstep control, the trajectory tracking effect of the attitude and position of the inspection drone is well achieved.
This paper addresses the problem whereby the inspection UAV is disturbed by unknown factors, such as wind gusts in the trajectory tracking process, resulting in the inability to track the inspection trajectory with high accuracy. In this paper, a sliding mode adaptive robust control algorithm is used to design the controller. Compared with other control algorithms, the adaptive algorithm part can better suppress disturbances, while the sliding mode control part can enhance the stability of the system and compensate for the poor robustness of other control algorithms. A control group experiment was also conducted using the sliding mode PID control algorithm and the backstepping control algorithm, and the simulation results and experimental results proved that, in terms of control structure, the method in this paper is more concise, efficient, and has certain advantages compared with other control methods that require the design of an observer or compensator and the repeated adjustment of control parameters.

2. Inspection Drone Dynamic Model

2.1. Establishment of Coordinate System

In order to better study the motion state of inspection drone dynamic model, it is necessary to select the appropriate coordinate system. In this paper, the body axis system and inertial coordinate system are introduced to describe the rotation, position, and attitude of the aircraft. The body axis system is A( A x , A y , A z ). The inertial coordinate system is B( B x ,     B y , B z ). As shown in Figure 3, γ, θ, and ψ are roll angle, pitch angle, and yaw angle, respectively. Through the rotation matrix of three angles, the transformation matrix from body axis system A to inertial coordinate system B can be deduced R A B [19].
R A B   = R γ R θ R ψ = [ C θ C ψ S θ S γ C ψ S ψ C γ C ψ C γ S θ + S γ S ψ C θ S ψ S θ S γ S ψ + C ψ C γ S θ S ψ C γ S γ C ψ S θ C θ S γ C θ C γ ]

2.2. Establishment of Coordinate System

In order to facilitate the establishment of the dynamic model, the following assumptions are proposed:
  • The four-rotor aircraft is regarded as a rigid body, and its body structure is completely uniform and symmetrical.
  • The origin O of the airframe coordinate system coincides with the origin O of the inertial coordinate system to ensure that the inertial matrix is a diagonal matrix in the rigid body coordinate system [20].
Because the main motion forms of quadrotor aircraft are divided into two types, one is translation motion relative to inertial frame B, while the other is rotation relative to body axis system A. Translation has 3 degrees of freedom, rotation has 3 degrees of freedom, a total of 6 degrees of freedom. Therefore, according to the total degrees of freedom, the generalized coordinates can be determined as q = ( ξ , η ) T , where ξ = [x,y,z]T represents location information; η   = [   γ ,   θ ,   ψ ]T indicates attitude information. The mass of the aircraft is m, the acceleration of gravity is g, and the distance from the end of the rotor to the center of gravity of the aircraft is l. The inertia matrix of quadrotor aircraft in the body axis system is as follows:
I   =   [ I x 0 0 0 I y 0 0 0 I z ]
where I x ,   I y ,   I z represent the moment of inertia of the x axis, y axis, and z axis in a coordinate system, which can be obtained by testing [21].
The expression equation of position part of quadrotor aircraft is as follows:
m ξ ¨ =   u 1 R A B e 3 mg e 3 + d s
where e 3   =   [ 0 0 1 ] T ,   d s is the disturbing force of the moving part of the position, u 1 is the lift power of a four rotor aircraft, R A B is a transformation matrix, and d s   = [ d x d y d z ] T is the interference force in the translational motion.
The equations for the rotational part of the quadrotor aircraft are as follows:
J   η ¨   +   C η ˙ =   τ + d M
where τ is the moment of rolling, pitching and yawing, τ = [ τ γ τ θ τ ψ ] T . d M = [ d γ d θ d ψ ] T ; is the disturbing torque in the rotational motion; J is the representation of the moment of inertia I of the rigid body in B coordinate system.
J = [ I x 0 I x S θ 0 I y C γ 2 + I z S γ 2 ( I y I z ) S γ C γ C θ I x S θ ( I y I z ) S γ C γ C θ I x S θ 2 + I y S γ 2 C θ 2 + I z C γ 2 C θ 2 ]
The coefficient C is the Coriolis force and centrifugal term [22], which is expressed in the following form [23].
C = [ C 11 C 12 C 13 C 21 C 22 C 23 C 31 C 32 C 33 ]
C 11 = 0 C 12 = I x ψ ˙ C θ + ( I y I z ) (   θ ˙ S γ C γ + ψ S γ 2 C θ ψ ˙ C γ 2 C θ ) C 13 = ( I z I y )   ψ ˙ S γ C γ C θ 2 C 21 = C 12 C 22 = ( I z I y )   γ ˙   S γ C γ C 23 = I x ψ ˙ C θ S θ + I y ψ ˙ C θ S θ S γ 2 + I z ψ ˙ C θ S θ C γ 2 C 31 = ( I y I z ) ψ ˙ S γ C γ I x θ ˙ C θ C 32 = ( I z I y ) ( θ ˙ S γ C γ S θ + γ ˙   S γ 2 C θ ) + ( I y I z ) γ ˙   C γ 2 C θ + I x ψ ˙ C θ S θ I y ψ ˙ S γ 2 C θ S θ I z ψ ˙ C γ 2 C θ S θ C 33 = ( I y I z ) γ ˙   S γ C γ C θ 2 I y θ ˙ S γ 2 C θ S θ I z θ ˙ C γ 2 C θ S θ + I x θ ˙ C θ S θ

3. Control System Design

3.1. Controller Design Structure

In this paper, a sliding mode adaptive robust trajectory tracking control strategy for quadrotor aircraft is proposed. The system is divided into two dynamic subsystems: position subsystem and attitude subsystem. The position subsystem is taken as the outer loop subsystem, and the attitude part is taken as the inner loop subsystem. The overall design scheme is shown in Figure 4.

3.2. Position Controller Design

The main design idea of the position controller is to compare the ideal position trajectory with the actual position trajectory, and finally make the error of the two approaches to zero.
Thus, the desired tracking displacement trajectory can be set as ξ c , The displacement obtained by actual tracking is recorded as ξ . Set the error to e s , where   e s = ξ ξ c . According to Formula (2), ξ ¨ can be expressed separately. Then, find the two derivatives on both sides of the error expression as follows:
e s ¨   =   u s +   d s   m   g e 3 ξ c ¨
In the formula, u s   = u 1 R A B e 3 is the control input that needs to be designed,   u s is understood as a virtual control law, as an intermediate quantity of coordinate transfomation.
According to the sliding mode adaptive robust control method, the sliding mode function is designed first. The sliding mode function can be set as follows:
S 1   =   e s ˙   +   λ 1 e s ,   λ 1   >   0
The virtual control law u s of the position subsystem is designed as follows:
u s = m ^ u ¯ s d s ^
u ¯ s is expressed as:
u ¯ s = g e 3 + ξ c ¨ λ 1   e s ˙ c 1 S 1
c 1 is the control coefficient, where   c 1 > 0 , m ^ is an estimator of quality, d s ^ is an etimate of the disturbance force of the displacement part.
Calculating the first derivative of sliding mode function:
S 1 ˙   =   e s ¨   +   λ 1 e s ˙
S 1 ˙ = m ^ u ¯ s d s ^ + d s m g e 3 ξ c ¨ + λ 1 e s ˙
Further sorting out:
S 1 ˙   =   m ^ u ¯ s   d s ^   +   d s m u ¯ s c 1 S 1
Compared with other articles, in the position motion part, the main purpose of this paper is to reduce the influence of the disturbance torque on the motion trajectory, so the disturbance torque is designed as the adaptive law to better track the position trajectory. Simultaneously, in order to reflect the superiority of the control method, considering the change of the mass caused by the load of the aircraft, which will affect the lift dynamics and stability of the quadrotor aircraft, the mass adaptive law is also designed.
The adaptive law is defined as follows:
d s ^ ˙   =   γ 1 S 1
m ^ ˙ = γ 2 S 1 T u ¯ s
γ 1 and   γ 2 are control coefficients.
The disturbance force error of displacement part is defined as e d s =   d s d s ^ . The quality error is e m = m m ^ .
Lyapunov function is defined as follows:
V 1 =   1 2 S 1 T S 1   +   1 2 m γ 1 e d s T e d s   +   1 2 m γ 2 e m 2
The derivation of Lyapunov function is obtained:
V 1 ˙ =   S 1 T ( m ^ u ¯ s   d s ^   +   d s m u ¯ s c 1 S 1 )   +   1 m γ 1 e d s T e ˙ d s + 1 m γ 2 e m e ˙ m
The interference force and mass of the position part are defined as slow time-varying signals, so the mass error e ˙ m is related to m ^ ˙ in adaptive control law e ˙ m = m ^ ˙ . By analogy, the position disturbance force error and d s ^ ˙ in adaptive control law also exists as e ˙ d s = d s ^ ˙ . The mass error of position interference force error is expressed by this relation, and then it is brought into the Lyapunov derivative function
V 1 ˙ = c 1 S 1 T S 1 e d s T m γ 1 ( d s ^ ˙ γ 1 S 1 ) e m m γ 2 ( m ^ ˙ + γ 2 S 1 T u ¯ s )
According to the above relations, V 1 ˙ is approximately equal to c 1 S 1 T S 1 . According to Lyapunov’s law [24], in order to ensure the system is in a stable state, it is necessary for V 1 ˙ = c 1 S 1 T S 1 0. The analysis shows that when the sliding mode function is not zero, the value of Lyapunov derivative function is always less than zero. According to the property of derivative function, the Lyapunov function decreases monotonically, and the sliding mode function, disturbance force error, and mass error decrease gradually. When the sliding mode function S 1 is equal to zero, the Liapunov derivative is equal to zero. At this time, the concept of LaSalle invariant set principle is introduced to analyze. According to the principle of LaSalle invariant set [25], it can be considered that the sliding mode function converges to zero gradually. When t   ,   S 1 0 . Further, the sliding mode function S 1 is equal to zero, because the Lyapunov derivative function V 1 ˙   = 0, so the Lyapunov function is a constant, and e d s and e m are invariant bounded quantities.
In this case, the sliding mode function will continue to cross at zero, causing the two error quantities to constantly change within a bounded interval, and there is no guarantee that the two error quantities will approach zero. In order to avoid the excessive amount of quality error, the input quantity u 1 needs to be continuously increased, so when the maximum and minimum values of the quality are known, the adaptive law of quality is corrected by a mapping adaptive algorithm [26].
m ^ ˙ = Pro j m ^ ( γ 2 S 1 T u ¯ s ) Pro j m ^ ( . ) = { 0 ,   if   m ^ m m a x and . > 0 0 ,   if   m ^ m m a x and . < 0 ,   other
When m ^ is greater than the maximum value of the limit range and is in an increasing state, at this time, m ^ remains unchanged, m ^ is equal to 0. When m ^ is lower than the minimum value of the limit range and is in a state of decreasing, at this time, m ^ remains unchanged, and m ^ is equal to 0. The mapping adaptive algorithm can not only ensure that m ^ is equal to 0, but also ensures that V 1 ˙ 0.
In the case that the virtual control law u s can be calculated, the actual lifting power u 1 of the quadrotor and the sum η s of the three attitude angle signals of the attitude subsystem must be calculated. Therefore, the virtual control input quantity u s can be expressed as: [ u x u y u z ] T , and the intermediate quantity η s is expressed as the following form: [ γ s θ s ψ s ] T .
Because   u s   =   u 1 R A B e 3 , the matrix operation on u s is expressed as the following form, and the power input expression in the x, y, and z directions can be obtained by sorting.
[ u x u y u z ] = u 1 R A B [ 0 0 1 ]
u x = u 1   ( cos ψ cos γ sin θ + sin γ sin ψ )
u y = u 1   ( sin θ sin ψ cos γ sin γ cos ψ )
u z = u 1   ( cos θ cos γ )
The u 1   = u z cos θ cos γ   are substituted into expressions (21) and (22) and transformed into state space expression.
u x = u z [ cos ψ sin ψ ] [ tan θ tan γ sec θ ]
u y = u z [ cos ψ sin ψ ] [ tan θ tan γ sec θ ]
Adding the intermediate amount η s leads to:
[ u x u y ] = u z [ cos ψ s sin ψ s cos ψ s sin ψ s ] [ tan θ s tan γ s sec θ s ]
u x cos ψ s + u y sin ψ s = u z tan θ s
u x sin ψ s u y cos ψ s = u z tan γ s cos θ s
The pitch angle and roll angle can be expressed as follows:
θ s = arctan u x cos ψ s + u y sin ψ s u z
γ s = arctan ( cos θ s   u x sin ψ s u y cos ψ s u z )
The pitch angle signal θ s and the roll angle signal γ s are used to track the reference position. They are generated by the virtual control input of the outer ring part and passed to the attitude subsystem of the inner ring part. The error generated by the outer ring part is processed by the inner ring part eliminate. The yaw angle ψ s is used as a given control signal and is generated by a signal generator. The input value of the signal generator can be set to track any yaw angle. The actual position controller input design is u 1   =   u z / cos θ cos γ , and u 1 is the actual control input.

3.3. Design of Attitude Tracking Controller

The attitude control part is the inner loop subsystem, which realizes attitude control through the inner loop control law, while tracking the pitch angle signal quantity θ s and roll angle signal quantity γ s generated by the outer loop control. In the control of the attitude subsystem, the main tracking quantity is η s . According to the expression of the posture part equation derived above, the controller of the attitude part is mainly designed for the control quantity input torque τ. At the same time, the uncertainty in the quadrotor model and the external non-structural disturbance torque in the rotational motion are considered. Therefore, the expression of the attitude part of the quadrotor can be written as follows.
J s η ¨ = C s η ˙ + τ + d M J Δ η ¨ C Δ η ˙
where J =   J s   + J Δ , C =   C s +   C Δ . The interference force d 1 in the x direction can be expressed as an expression related to the interference torque. Further, consider that d 1 is a bounded quantity.
So, the dynamic model of the attitude subsystem can be expressed as:
J s η ¨ + C s η ˙ =   τ +   d 1
The tracking error signal of the attitude subsystem is e η   =   η η s , and the derivative is further expressed as e r ˙   =   η s ˙ λ 2 e η , η s = [ γ s θ s ψ s ] T .
Similar to the design idea of the position controller, first define the sliding mode function. The sliding mode function S 2 is set to the following form:
S 2 = η ˙ e r ˙ = e η ˙ + λ 2 e η
λ 2 is the control parameter.   λ 2   > 0.
According to the defined sliding mode function relationship, the attitude error subsystem can be transformed into the following form:
J s S 2 ˙ =   τ +   d 1 C s η ˙ J s e r ¨
Therefore, the control quantity input torque can be expressed as the following form:
τ   =   J s e r ¨   +   C s η ˙ c 2 S 2 ε s g n ( S 2 )
In Formula (34): ε and c 2 are control parameters, ε   >   d γ ,   c 2   > 0.   s g n is a symbolic function.
It can be seen from the expression of the exponential reaching law that when the exponential approaching speed is gradually reduced from a larger value to zero, the reaching time becomes shorter and the speed of the target point approaching the switching plane is very small. Because it is a process of gradual approximation, it is difficult to ensure that the moving point reaches the switching plane in a certain time, so an isokinetic approach term ε s g n ( S 2 ) is added to the above-mentioned basis [18,19].
The nominal values of the defined model are:
J S = [ I x 0 0 0 I y + I Z 0 0 0 I x + I y + I Z ]   C s   =   0.9 C
Furthermore, the Lyapunov function is constructed as follows:
V 2   =     1   2 S 2 T J S S 2
The derivative function of V 2 can be obtained as follows:
V 2 ˙ =   S 2 T J S S 2 ˙   =   S 2 T ( τ   +   d 1 C s η ˙ J s e r ¨ )
After the control quantity τ is brought in, the following results can be obtained:
V 2 ˙ =   2 c 2 J S 1 V 2
It can be seen that Lyapunov derivative function V 2 ˙ is a negative number, so the characteristic of Lyapunov function is monotonic decreasing. According to Lyapunov stability law, the attitude subsystem can be considered as stable, and the error is convergent.
For the whole system, the Lyapunov function is defined as:
V =   V 1 +   V 2
Put V 1 and V 2 in it.
V ˙ c 1 S 1 T S 1 c 2 V 2   0
According to the Lyapunov stability law, the whole system can be considered to be in a state of asymptotic stability.
The position controller obtains the pitch signal θ s and roll signal γ s . From the expression of input torque in formula (34), it can be seen that the first derivative and the second derivative of the two signals need to be calculated respectively. In this case, we can use the form of third-order differentiator to realize the control of θ s and γ s first derivative and second derivative.

4. Simulation Research

Simulation

First of all, given the theoretical inspection trajectory parameter ξ c of the inspection drone, the theoretical trajectory is: x = cos(1/2t); y = sin(1/2t); z = t. Due to the under-driving characteristics of the inspection drone, the pitch angle and roll angle are transmitted to the inner loop control system as intermediate command signals, so only the yaw angle needs to be defined at this time. Set the constant of yaw angle to ψ s   = π/6. The distance from the end of the rotor to the center of gravity of the aircraft is 0.5 m. The parameters in the inertia matrix I are set as follows:   I x   = 0.121; I y   = 0.121; I z = 0.151.
Interference force in displacement motion d s is:
[ sin ( π t ) cos ( π t ) cos ( π t ) ]
Disturbing torque in rotating motion d M is taken as:
[ sin ( 0.5 π t ) + 0.5 cos ( 0.5 π t ) + 0.5 sin ( 0.5 π t ) + 0.6 ]
Set the simulation time to 30 s and change once in 10 s. In 0–10 s, m is 1 kg; in 10–20 s, m is 3 kg; in 20–30 s, m is 5 kg. In the position tracking controller, c 1 = 6, λ 1 = diag [2, 2, 2], γ 1 = 0.80 , γ 2 = 0.30 . In the attitude controller, c 2   = 8, ε = 0.30, λ 2   = diag [60, 60, 60]. In the switching control process, the saturation function is used instead of the switching function, and the boundary layer thickness is taken as 0.30.
The simulation results are shown in the figure.
It can be seen from Figure 5 that the inspection drone can track the inspection trajectory well. The blue is the theoretically designed inspection trajectory, and the red is the actual tracking trajectory under the disturbance of the disturbance. It can be seen from the figure The two trajectories are close to the same, which shows the effectiveness of the control algorithm proposed in this paper. Figure 6a–c present the tracking errors in the x, y, and z directions of the inspection drone, respectively. It can be seen that after the quality is changed, the error changes in different time periods are different, and the error is very small and within a reasonable range. Figure 7a–c are the trajectory tracking curves of the roll angle, pitch angle, and yaw angle of the inspection drone. It can be seen that the actual roll angle, pitch angle, and the yaw angle and the ideal roll angle, pitch angle, and yaw angle curve basically tend to be the same. Figure 8 shows the change in the lifting power of the inspection drone, i.e., the input quantity u 1 . From the figure, it can be seen that the lift changes with the change of mass, and the value is close to the gravity of the inspection drone. Figure 9 shows the quality self-adaptive estimation result. The quality estimation value and the actual quality value curve are roughly the same, and the error is within the allowable range. Figure 10 shows a comparison diagram of the disturbance force design value and estimated value of the position movement part. It can be clearly seen from the figure that the disturbance force error in the x-direction and y-direction basically approaches zero, achieving the expected goal. Compared with the designed interference force, the z direction is significantly reduced, and the disturbance is suppressed. The effectiveness and robustness of this control algorithm can also be seen from the before and after changes of the interference force. In practical experiments, the gust of wind can be regarded as a disturbance, and the disturbance can be well suppressed by the adaptive law.
Through the above simulation analysis and research, it can be seen that the controller designed by the sliding mode adaptive robust control method can accurately and stably track the given patrol, taking into account the dynamic characteristics of the patrol drone, external disturbance, and system uncertainty. Check the trajectory, obtain good control performance, and verify the effectiveness of the control algorithm.

5. Experimental Design

5.1. Sliding Mode PID Control Group Experiment

The first group of control experiments uses the sliding mode PID control algorithm to design the inspection drone controller. The control structure diagram is shown in Figure 11.
The system is divided into two parts, one is a full drive subsystem, the other is the under drive subsystem. PID control is used in the full drive subsystem and sliding mode control is used in the underactuated subsystem. When other conditions remain unchanged, the mass is 1 kg for the control experiment. The simulation results are shown in the figure.
From the simulation results of the sliding mode PID control algorithm, it can be seen from Figure 12 that the overall trajectory tracking has a good effect. The specific position tracking amount is shown in Figure 13. It is not difficult to see from the figure that the error in the x direction is between −0.03 and 0.03; the error in the y direction is between −0.02 and 0.02; the error in the z direction is between −0.026 and 0.026. Although the error is oscillating, it is higher in terms of accuracy than the control algorithm proposed in this paper. Figure 14 presents the attitude tracking curves. It can be seen that the overall trajectory tracking accuracy has a good effect, which is equivalent to the control effect in this article.

5.2. Backstepping Control Group Experiment

The second group of control group experiments adopts backstepping control to design the controller. The control structure diagram is shown in Figure 15. The basic principle of backstepping is to decompose a complex nonlinear system into subsystems that do not exceed the order of the system, and then design partial Lyapunov functions and intermediate virtual control variables for each subsystem, and “backward” to the entire system. They are integrated to complete the design of the entire control law. Therefore, the overall system of the inspection UAV can also be divided into two parts, namely the position subsystem and the attitude subsystem. Firstly, the theoretical inspection trajectory of the inspection drone is given. At the same time, the height control uses the error amount between the actual height and the theoretical height as input, and the lift u 1 in the z direction is obtained through the calculation of the controller. Similarly, in the translation part, the theoretical values and actual errors in the x and y directions are used as input, and the lift u 1 in the z direction is brought into the translation controller to calculate the lift u x and u y in the two directions. After u x and u y undergo backstepping control operations, the theoretical roll angle and theoretical pitch angle of the system are obtained. The second is the design of the attitude subsystem, which is similar to the design of the position controller. The theoretical value of the three angles of the attitude part and the actual value measured by the attitude sensor are calculated to obtain the error, and the error is used as the input. It should be noted that the yaw angle is still set at this time. The three angle errors are input into the attitude controller for calculation, and the input torques u 2 , u 3 , and u 4 of the three angles are obtained. Finally, the input lift and torque obtained by the two subsystems are used to control the work of the inspection drone. The simulation results are shown in the figure.
It can be seen from Figure 16 that due to the addition of disturbance, the overall trajectory tracking effect is not ideal, and the disturbance is relatively serious. Looking at the error change curves in the three directions, the overall error curve is in an oscillating state, and the oscillating range is relatively large, which shows that the control algorithm is greatly affected in terms of accuracy. It can be seen from Figure 17 and Figure 18 that the tracking effect of the three angles is affected by the disturbance and the angle tracking cannot be performed well.

6. Experimental Study

In order to better verify the effectiveness of the proposed control algorithm, this paper adds an actual experimental platform for verification. The hardware system part of the experimental platform is the PIX series flight controller with the model of the main control chip STM32F427. The MPU6050 sensor is selected as the attitude acquisition component. The GPS module with the model number M8N and the MS5611-01BA air pressure sensor are selected for the measurement of position parameters. The experiment mainly uses wind as interference to measure the flight status and trajectory tracking of the UAV to verify the superiority of the control strategy proposed in this paper. The patrol track of the experimental design is shown in Figure 19.
According to Figure 20, it can be seen that after designing the predetermined trajectory, the inspection drone can roughly track the predetermined trajectory, and although there is an error in the tracking result, considering the influence of wind gusts and disturbances during the experiment, the tracking result is also within the controllable range. The experimental data from Figure 21, Figure 22, Figure 23, Figure 24, Figure 25 and Figure 26 can clearly show the tracking results of each index, and the actual value curve and the theoretical value basically tend to be the same, which shows the effectiveness of the control algorithm, and the error range of each index is also within the plan.
In order to better compare the three control algorithms during the experiments, different algorithms are used for the control experiments. The parameters of the experimental equipment are kept constant and only the control algorithms are changed. The experimental results of the three control algorithms are shown in Table 1.
Combining the experimental data in Table 1 and Table 2, it can be seen that the sliding mode adaptive robust control algorithm is faster in terms of stabilization time than the sliding mode PID control algorithm and the backstepping control algorithm. Although the two algorithms used as the control group can finally track the motion trajectory of the quadrotor aircraft, in terms of tracking error, the tracking error range of the two algorithms is larger than that of the sliding mode adaptive robust control algorithm. Although the sliding mode PID algorithm can achieve good results in respect of stability time and tracking accuracy, it is very cumbersome to adjust the PID parameters, and the overshoot phenomenon is serious when the parameters are not selected properly. It can be concluded that the sliding mode adaptive robust control algorithm has good stability, higher precision, and obvious advantages by comparing the experimental results of the other two control algorithms under the condition of considering the disturbance.

7. Discussion

Although the simulation results can basically achieve the expected goal, the error in the z-direction is significantly different compared to the error variation range in the x and y directions. Moreover, the final obtained disturbance moment in z-direction is also significantly different compared to the other two directions, which shows that the accuracy and the suppression of disturbance in z-direction still need to be improved. Further analysis of the causes of this situation may be as follows.
  • The inspection drone is an underdriven system where the control volume is less than the output volume.
  • Jitter vibration will be generated near the transition to the slide surface during the control process.
  • The actual altitude always has a constant small deviation from the ideal altitude after the trajectory tracking process is stabilized.
  • The inner loop of attitude control and the outer loop of position control cannot be coordinated immediately during the continuous steering process.

8. Conclusions

The results show that the sliding mode adaptive robust control strategy used in this paper can support the inspection UAV to track the inspection trajectory well. In the presence of interference, the stability and accuracy of the inspection UAV are guaranteed. Simulation results and experimental results prove the effectiveness of the control method. The simulation experiments of the control group prove the advantages of the control strategy in this study. At the same time, in the process of comparison with the sliding mode PID control and the backstepping control, it can be clearly seen that the sliding mode PID can achieve reasonable results in terms of control accuracy, and the backstepping control, although designed with system stability in mind, struggles to achieve the expected results in terms of control accuracy. In the control process of the actual experiment, from the data measured by the sensor and the theoretical data curve calculated on the ground station, it can be seen that the control algorithm used can reach the actual demand, and the inspection drone can follow the control point well for inspection. In the future, we will continue to combine the algorithm from the anti-interference and the inspection drone in order to better apply to the actual project.

Author Contributions

Conceptualization, M.Y. and Z.Z.; methodology, Z.Z.; software, Z.Z.; validation, M.Y., Z.Z. and X.Y.; formal analysis, Z.Z. and M.Y.; investigation, X.Y.; resources, Z.Z. and X.Y.; data curation, Z.Z. and M.Y.; writing—original draft preparation, Z.Z.; writing—review and editing, Z.Z. and M.Y.; visualization, Z.Z. and M.Y.; supervision, M.Y.; project administration, M.Y.; funding acquisition, M.Y. All authors have read and agreed to the published version of the manuscript.

Funding

This research was funded by the Natural Science Foundation of Beijing under Grant 4204097, The Natural Science Foundation of China under Grant 62003005, and the Municipal Education Commission Scientific Research Project KM202110009009.

Funding

This research was funded by the Natural Science Foundation of Beijing under Grant 4204097, The Natural Science Foundation of China under Grant 62003005, and the Municipal Education Commission Scientific Research Project KM202110009009.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Conflicts of Interest

The authors declare no conflict of interest.

References

  1. Lopez Lopez, R.; Batista Sanchez, M.J.; Perez Jimenez, M.; Arrue, B.C.; Ollero, A. Autonomous UAV System for Cleaning Insulators in Power Line Inspection and Maintenance. Sensors 2021, 21, 8488. [Google Scholar] [CrossRef] [PubMed]
  2. Chang, C.-W.; Lo, L.-Y.; Cheung, H.C.; Feng, Y.; Yang, A.-S.; Wen, C.-Y.; Zhou, W. Proactive Guidance for Accurate UAV Landing on a Dynamic Platform: A Visual–Inertial Approach. Sensors 2022, 22, 404. [Google Scholar] [CrossRef] [PubMed]
  3. Tayyab, M.; Yuanqing, X.; Di-Hua, Z.; Dailiang, M. Trajectory tracking control of a VTOL unmanned aerial vehicle using offset-free tracking MPC. Chin. J. Aeronaut. 2020, 33, 2024–2042. [Google Scholar]
  4. Ma, H.; Xiong, Z.; Li, Y.; Liu, Z. Sliding Mode Control for Uncertain Discrete-Time Systems Using an Adaptive Reaching Law. IEEE Trans. Circuits Syst. II-Express Briefs 2022, 68, 722–726. [Google Scholar] [CrossRef]
  5. Xu, C.; Yin, C.; Han, W.; Wang, D. Two-UAV trajectory planning for cooperative target locating based on airborne visual tracking platform. Electron. Lett. 2020, 56, 301–303. [Google Scholar] [CrossRef]
  6. Jia, R.; Zong, X. Quadrotor UAV Trajectory Tracking Control based on ASMC and Improved ARDC. In Proceedings of the 2020 Chinese Automation Congress (CAC), Shanghai, China, 6–8 November 2020; pp. 6078–6083. [Google Scholar] [CrossRef]
  7. Xu, J.; Cai, C.; Li, Y.; Xu, J. Double closed-loop trajectory tracking and control of a small quadrotor UAV. Control. Theory Appl. 2015, 32, 1335–1342. [Google Scholar]
  8. Wang, S.; Yin, X.; Li, P.; Zhang, M.; Wang, X. Trajectory Tracking Control for Mobile Robots Using Reinforcement Learning and PID. Iran. J. Sci. Technol. Trans. Electr. Eng. 2020, 44, 1059–1068. [Google Scholar] [CrossRef]
  9. Yao, Q. Adaptive finite-time sliding mode control design for finite-time fault-tolerant trajectory tracking of marine vehicles with input saturation. J. Frankl. Inst. 2020, 357, 13593–13619. [Google Scholar] [CrossRef]
  10. Gu, J.; Sun, R.; Chen, J. Improved Back-Stepping Control for Nonlinear Small UAV Systems with Transient Prescribed Performance Design. IEEE Access 2021, 9, 128786–128798. [Google Scholar] [CrossRef]
  11. Li, J.; Liu, J.; Sun, Z. Quadrotor Trajectory Tracking Control Based on Backstepping Method. J. Qufu Norm. Univ. 2020, 46, 47–50. [Google Scholar]
  12. Shen, Z.; Cao, X. Output feedback control of input constrained quadrotor aircraft trajectory tracking dynamic surface based on extended observer. Syst. Eng. Electron. Technol. 2018, 40, 2766–2774. [Google Scholar]
  13. Chen, X. Hybrid trajectory tracking control algorithm for quadrotor aircraft. Electro-Opt. Control. 2020, 27, 58–62,67. [Google Scholar]
  14. Wang, N.; Wang, Y. Adaptive dynamic surface trajectory tracking control of quadrotor aircraft based on Fuzzy Uncertain observer. J. Autom. 2018, 44, 685–695. [Google Scholar]
  15. Luna, M.A.; Ale Isaac, M.S.; Ragab, A.R.; Campoy, P.; Flores Peña, P.; Molina, M. Fast Multi-UAV Path Planning for Optimal Area Coverage in Aerial Sensing Applications. Sensors 2022, 22, 2297. [Google Scholar] [CrossRef] [PubMed]
  16. López, B.; Muñoz, J.; Quevedo, F.; Monje, C.A.; Garrido, S.; Moreno, L.E. Path Planning and Collision Risk Management Strategy for Multi-UAV Systems in 3D Environments. Sensors 2021, 21, 4414. [Google Scholar] [CrossRef]
  17. Mehmood, Y.; Aslam, J.; Ullah, N.; Chowdhury, M.S.; Techato, K.; Alzaed, A.N. Adaptive Robust Trajectory Tracking Control of Multiple Quad-Rotor UAVs with Parametric Uncertainties and Disturbances. Sensors 2021, 21, 2401. [Google Scholar] [CrossRef]
  18. Tang, Y.R.; Xiao, X.; Li, Y. Nonlinear dynamic modeling and hybrid control design with dynamic compensator for a small-scale UAV quadrotor. Measurement 2017, 109, 51–64. [Google Scholar] [CrossRef]
  19. Yuan, D.; Wang, Y. Data Driven Model-Free Adaptive Control Method for Quadrotor Formation Trajectory Tracking Based on RISE and ISMC Algorithm. Sensors 2021, 21, 1289. [Google Scholar] [CrossRef]
  20. An, S.; Liu, X.; Hou, K.; Xu, X. Establishment of the dynamic model of the electric power system of a slight UAV. J. Harbin Univ. Sci. Technol. 2020, 25, 33–39. [Google Scholar]
  21. Qian, L.; Li, Z.; Wang, Y. Research on optimization design of quadrotor control system. Comput. Simul. 2018, 35, 18–23. [Google Scholar]
  22. Yu, S. Research on Intelligent Control Method of Quadrotor Aircraft; China University of Petroleum (East China): Beijing, China, 2018. [Google Scholar]
  23. Farrell, J.; Sharma, M.; Polycarpou, M. Backstepping-Based Flight Control with Adaptive Function Approximation. J. Guid. Control. Dyn. 2005, 28, 1089–1102. [Google Scholar] [CrossRef]
  24. Wang, L.; Wang, M. Analysis of the construction of Lyapunov functions for a class of third order nonlinear systems. J. Appl. Math. 1983, 6, 309–323. [Google Scholar]
  25. Iason, K.; Ioannis, M.; Nikos, N.; Pitas, I. Shot type constraints in UAV cinematography for autonomous target tracking. Inf. Sci. 2020, 506, 273–294. [Google Scholar]
  26. Marino, R.; Respondek, W.; Van der Schaft, A.J. Almost Disturbance Decoupling for Single-Input Single-Output Nonlinear Systems. Trans. Autom. Control. IEEE 1989, 34, 1013–1017. [Google Scholar] [CrossRef] [Green Version]
Figure 1. Inspection drone operations.
Figure 1. Inspection drone operations.
Sensors 22 03648 g001
Figure 2. Schematic diagram of patrol tracking track.
Figure 2. Schematic diagram of patrol tracking track.
Sensors 22 03648 g002
Figure 3. Establishment of four rotor aircraft coordinate system.
Figure 3. Establishment of four rotor aircraft coordinate system.
Sensors 22 03648 g003
Figure 4. Establishment of four rotor aircraft coordinate system.
Figure 4. Establishment of four rotor aircraft coordinate system.
Sensors 22 03648 g004
Figure 5. Trajectory tracking effect chart.
Figure 5. Trajectory tracking effect chart.
Sensors 22 03648 g005
Figure 6. Position tracking error. (a) x direction position error; (b) y direction position error; (c) z direction position error.
Figure 6. Position tracking error. (a) x direction position error; (b) y direction position error; (c) z direction position error.
Sensors 22 03648 g006
Figure 7. Posture tracking effect diagram. (a) Track of roll angle γ (b) Pitch angle θ track tracking (c) Yaw angle ψ trajectory tracking.
Figure 7. Posture tracking effect diagram. (a) Track of roll angle γ (b) Pitch angle θ track tracking (c) Yaw angle ψ trajectory tracking.
Sensors 22 03648 g007
Figure 8. Lifting power of drone.
Figure 8. Lifting power of drone.
Sensors 22 03648 g008
Figure 9. Mass adaptive estimation.
Figure 9. Mass adaptive estimation.
Sensors 22 03648 g009
Figure 10. Adaptive estimation of position direction interference force. (a) x direction disturbance adaptive effect diagram; (b) y direction disturbance adaptive effect diagram; (c) z direction disturbance adaptive effect diagram.
Figure 10. Adaptive estimation of position direction interference force. (a) x direction disturbance adaptive effect diagram; (b) y direction disturbance adaptive effect diagram; (c) z direction disturbance adaptive effect diagram.
Sensors 22 03648 g010
Figure 11. Structure chart of sliding mode PID control.
Figure 11. Structure chart of sliding mode PID control.
Sensors 22 03648 g011
Figure 12. Trajectory tracking effect chart.
Figure 12. Trajectory tracking effect chart.
Sensors 22 03648 g012
Figure 13. Position tracking error. (a) x direction position error; (b) y direction position error; (c) z direction position error.
Figure 13. Position tracking error. (a) x direction position error; (b) y direction position error; (c) z direction position error.
Sensors 22 03648 g013
Figure 14. Posture tracking effect diagram. (a) Track of roll angle γ; (b) Pitch angle θ track tracking; (c) Yaw angle ψ trajectory tracking.
Figure 14. Posture tracking effect diagram. (a) Track of roll angle γ; (b) Pitch angle θ track tracking; (c) Yaw angle ψ trajectory tracking.
Sensors 22 03648 g014
Figure 15. Structure chart of backstepping control.
Figure 15. Structure chart of backstepping control.
Sensors 22 03648 g015
Figure 16. Trajectory tracking effect chart.
Figure 16. Trajectory tracking effect chart.
Sensors 22 03648 g016
Figure 17. Position tracking error. (a) x direction position error; (b) y direction position error; (c) z direction position error.
Figure 17. Position tracking error. (a) x direction position error; (b) y direction position error; (c) z direction position error.
Sensors 22 03648 g017
Figure 18. Posture tracking effect diagram. (a) Track of roll angle γ; (b) Pitch angle θ track tracking; (c) Yaw angle ψ trajectory tracking.
Figure 18. Posture tracking effect diagram. (a) Track of roll angle γ; (b) Pitch angle θ track tracking; (c) Yaw angle ψ trajectory tracking.
Sensors 22 03648 g018
Figure 19. Inspection track design.
Figure 19. Inspection track design.
Sensors 22 03648 g019
Figure 20. Theoretical and practical trajectories.
Figure 20. Theoretical and practical trajectories.
Sensors 22 03648 g020
Figure 21. Altitude data from aircraft and GPS.
Figure 21. Altitude data from aircraft and GPS.
Sensors 22 03648 g021
Figure 22. Schematic diagram of tracking results for cross-roll angle.
Figure 22. Schematic diagram of tracking results for cross-roll angle.
Sensors 22 03648 g022
Figure 23. Schematic diagram of tracking results for pitch angle.
Figure 23. Schematic diagram of tracking results for pitch angle.
Sensors 22 03648 g023
Figure 24. Schematic diagram of tracking results for pitch angle.
Figure 24. Schematic diagram of tracking results for pitch angle.
Sensors 22 03648 g024
Figure 25. Location track tracking effect.
Figure 25. Location track tracking effect.
Sensors 22 03648 g025
Figure 26. Speed variation of inspection drones.
Figure 26. Speed variation of inspection drones.
Sensors 22 03648 g026
Table 1. Control algorithm error tracking result analysis table.
Table 1. Control algorithm error tracking result analysis table.
Control Methodx-Direction Tracking Error Rangey-Direction Tracking Error Rangez-Direction Tracking Error Range
Sliding Mode Adaptive Robustness−0.21–0.16−0.31–0.58−0.63–1.21
Sliding Mode PID−0.23–0.36−0.86–0.79−0.59–1.32
backstepping control−0.56–1.21−1.52–1.63−1.63–1.82
Table 2. Attitude trajectory tracking error.
Table 2. Attitude trajectory tracking error.
Control MethodRoll AnglePitch AngleYaw Angle
Sliding Mode Adaptive Robustness−0.5–0.75−0.04–0.58−0.21–0.36
Sliding Mode PID−0.86–0.95−0.5–0.36−0.31–0.48
backstepping control−0.98–1.025−0.93–0.86−1.26–1.10
Publisher’s Note: MDPI stays neutral with regard to jurisdictional claims in published maps and institutional affiliations.

Share and Cite

MDPI and ACS Style

Yang, M.; Zhou, Z.; You, X. Research on Trajectory Tracking Control of Inspection UAV Based on Real-Time Sensor Data. Sensors 2022, 22, 3648. https://doi.org/10.3390/s22103648

AMA Style

Yang M, Zhou Z, You X. Research on Trajectory Tracking Control of Inspection UAV Based on Real-Time Sensor Data. Sensors. 2022; 22(10):3648. https://doi.org/10.3390/s22103648

Chicago/Turabian Style

Yang, Mingbo, Ziyang Zhou, and Xiangming You. 2022. "Research on Trajectory Tracking Control of Inspection UAV Based on Real-Time Sensor Data" Sensors 22, no. 10: 3648. https://doi.org/10.3390/s22103648

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop