MATLAB & Simulink Tutorial: Quadrotor UAV Trajectory and Control Design (PID + Cascaded)

  Рет қаралды 80,351

VDEngineering

VDEngineering

Күн бұрын

#Drone #Controller #UAVControl #ModelBasedDesign
Hi Everyone,
In this video I walk you through designing and implementing a 2D linear controller for a quad rotor moving along a specified trajectory.
The quad is commanded to move across a trajectory defined as a function of time x(t), z(t). The equations of motion are first linearized and then implemented in Simulink.
This tutorial covers the following fundamental control concepts
1) Linearization
2) Under-actuation
3) Coupling
4) PID/PD/PI control
5) Tuning
6) Inner Loop Control
Feel free to leave your feedback below.
For more videos like this, tutorials, and tips & tricks, subscribe to this channel at:
/ vinayak678matlabsimulink
Best Wishes
VDEngineering
~~My Udemy Courses on Motion Planning / Navigation / Trajectory Planning:
www.udemy.com/...
My Instagram: / vinayak_desh
My Website: www.vinayakd.com/

Пікірлер: 69
@magizhmaranfpv9583
@magizhmaranfpv9583 5 жыл бұрын
I have bought a mini drone. And am interested in the physics and mechanics behind its flight. This lecture is exactly what I want. Thank You!
@rajshah7433
@rajshah7433 5 жыл бұрын
Hi Vin, Thanks for the awesome explanation. How did you choose kp, ki and kd values and how did you mathematically model the quad rotor?
@kumar9867
@kumar9867 6 жыл бұрын
Nice tutorial , if I want to implement for the 3d trajectory what will be the resultant linearised equation of motion. Can you please share the reference paper.
@sandeepgupta07031986
@sandeepgupta07031986 4 жыл бұрын
Thanks a lot dear. I found lots of literature on quadrotor pid design and control. But your way of repeating is awesome. We are waiting for more lectures on different controllers and 3D version also.
@mohamedkandil8782
@mohamedkandil8782 6 жыл бұрын
God bless you man, you are awesome!
@splinter95war
@splinter95war 4 жыл бұрын
Hi Vin! Thanks for the tutorial! Just one question... observing the trend of the commanded input of the inner loop (M =u2), it reaches high values (hundreds of Nm)... Would it be more appropriate to consider a saturation of the inner loop too?
@MrMJY
@MrMJY 4 жыл бұрын
with that scheme, response of z with pid giving to me unstable output. i don't know why..
@andresvasquez4458
@andresvasquez4458 2 жыл бұрын
Thanks for the informative vid!
@konetivamsikrishna4435
@konetivamsikrishna4435 3 жыл бұрын
sir may know on which software you have modeled the aerial drone, matlab software or any other type of software
@kienvo9072
@kienvo9072 3 жыл бұрын
Thank you for this tutorial !
@cuk5466
@cuk5466 3 жыл бұрын
Good Tutorial But Remember, earth radius is a vector unit. I think an equation at z should be z_ddot=-g+(u1/m)cos(theta) cos(theta)~=1 z_ddot=-g+(u1/m) please correct me if i'm wrong Thank you
@muralikrishnay2734
@muralikrishnay2734 Жыл бұрын
Why are we considering PID Y instead of just taking the reference value for Phi?
@zhenyuwei9171
@zhenyuwei9171 2 жыл бұрын
Very helpful! Thank you!
@zakariahousni5053
@zakariahousni5053 3 жыл бұрын
thank you for this tutorial I learned a lot
@REDSLibrary
@REDSLibrary 5 жыл бұрын
Very nice work
@ahs4771384
@ahs4771384 5 жыл бұрын
Great efforts ..Thanks
@otg9806
@otg9806 2 жыл бұрын
Where can I get the outputs of 8.58min?
@antonete125
@antonete125 4 жыл бұрын
Greetings from Spain, this is a fantastic video, One question, in order the design the altititude and attitude controlles of the quadrotor, Is it okey to ignore the motor dinamics? That is to say, the output of the PID is a force, then the force is converted to angular velocity of the rotor, then a command pwm is generated, and finally te motor generate a force which is the one that goes into the plant (equations of motion). It seems okey simply ignoring the plant that model the actuators , don't you think?
@VDEngineering
@VDEngineering 4 жыл бұрын
Its ok for this case, as long as the input-output relation is near unity (similar)
@thenguyenduc9426
@thenguyenduc9426 5 жыл бұрын
great!You give more background information? I don't really understand
@siddheshnalawade6674
@siddheshnalawade6674 6 жыл бұрын
Thank you very much for this tutorial
@thenguyenduc9426
@thenguyenduc9426 5 жыл бұрын
thanks. You give me more clarity about equation of motion?
@anupamkumar1372
@anupamkumar1372 2 жыл бұрын
hi, kindly provide referred research paper/book etc for your mathematical model of drone.
@aniketsawant3473
@aniketsawant3473 3 жыл бұрын
Awesome 😎👍
@gawayne1374
@gawayne1374 3 жыл бұрын
My dude, why did you flip the y double dot and phi double dot equations around in the 1:42 slide? It breaks the visual continuity making the problem harder to study.
@prashantnigam2882
@prashantnigam2882 2 жыл бұрын
Hello sir ..can you help me out in designing Quadcopter with 6DOF in simulink....
@matiullah9551
@matiullah9551 4 жыл бұрын
Could you please eleborate why did you put u1=g and u2=g?
@gokhankiremit4322
@gokhankiremit4322 5 жыл бұрын
Hi, thank you for great videos. I have a question. Why did you use saturation for outer loop ? I am designing 2 axis gimbal controller outer(position) and inner(rate ) loop. Can I have to use, to saturation for outer loop ? What is logic of saturation limits at cascaded pid ? Can you help me about this issue ? Thank you
@VDEngineering
@VDEngineering 5 жыл бұрын
It prevents overshooting
@carlosarturoriveraquezada7783
@carlosarturoriveraquezada7783 4 жыл бұрын
I tried to simulate my code using matlab but I found different values for kpz and kdz, using the same values so it's kinda weird... maybe there's something wrong in my controller.
@jamisonsanchez9372
@jamisonsanchez9372 6 жыл бұрын
Love your channel. Thank you for the upload!
@sohamranade2586
@sohamranade2586 5 жыл бұрын
can you make a 3d model for this as well ?
@abdulbasetjoma6465
@abdulbasetjoma6465 2 жыл бұрын
Hi.what's the pdf name used in the end of these toturial
@jobaidulislam7506
@jobaidulislam7506 3 жыл бұрын
Could you please help me to establish UAVs mathematical modeling?
@brandongan2022
@brandongan2022 3 жыл бұрын
Thank you!
@ramilabbaszadeh1628
@ramilabbaszadeh1628 3 жыл бұрын
Thanks man,
@p.s5522
@p.s5522 4 жыл бұрын
Sir if possible please guide how to design LQR CONTROLLER for quadrotor .... during this lockdown period it vl be great help for me🙏
@VDEngineering
@VDEngineering 4 жыл бұрын
It's coming in a future video
@hearmeright607
@hearmeright607 Жыл бұрын
Id recommend using an LQI controller in combination with an observer. Also for the Modelling of the 3D dynamics of the drone its best to use the Lagrange approach for the equations of motion. Also don't forget to take into account the linearization you have done when implementing the controller on a real system. The Controller may work with your linearized model, but if u use it on the nonlinear plant without the addition of ur stationary point where u linearized ur system around the controller will most likely fail.
@sandhyarathore6025
@sandhyarathore6025 3 жыл бұрын
Hi, the model didn't give me same results when I implemented in Simulink. Because of double integrators system is highly unstable. Can u guide
@VDEngineering
@VDEngineering 3 жыл бұрын
Hey, check the initial conditions or use a different solver
@sandhyarathore6025
@sandhyarathore6025 3 жыл бұрын
@@VDEngineering can you share your email id as my problem remains unsorted
@1willFALL
@1willFALL 5 жыл бұрын
Could you do videos on introduction to Simulink?
@VDEngineering
@VDEngineering 5 жыл бұрын
The MATLAB channel has great videos on that. I recommend you watch those!
@alirezasharifan9663
@alirezasharifan9663 4 жыл бұрын
Hi Vin I reproduced it, but I faced a problem in the first integrator of z in the subsystem. This is the prompt from matlab: -------------------- An error occurred while running the simulation and the simulation was terminated Caused by: Derivative of state '1' in block 'cascade/Subsystem/z' ' at time 47.808863760417289 is not finite. The simulation will be stopped. There may be a singularity in the solution. If not, try reducing the step size (either by reducing the fixed step size or by tightening the error tolerances) ------------------- I reduced the step size, but I have still the problem. I am appreciated for your assistance in advance.
@alirezasharifan9663
@alirezasharifan9663 4 жыл бұрын
I used a saturation block after the z-controller and z-output raised up exponentially, there is no any problem in phi and y. Thanks for your consideration.
@nicolasdziemian9942
@nicolasdziemian9942 4 жыл бұрын
@@alirezasharifan9663 It sounds like it's something within your gain values within the PID Controller
@alirezasharifan9663
@alirezasharifan9663 4 жыл бұрын
@@nicolasdziemian9942 Thank you. By checking PID controller and tuning it, Matlab recommended negative p and d parameters therefore, I found out that the problem was related to the sign of (g) and (u/m) in the subsystem.
@nurhadiarif1039
@nurhadiarif1039 5 жыл бұрын
Give me report.pdf, please...
@kennyhnsom
@kennyhnsom 2 жыл бұрын
What about 3D controller
@VDEngineering
@VDEngineering Жыл бұрын
coming in future
Жыл бұрын
@@VDEngineering future when :(
@federicosagun8243
@federicosagun8243 5 жыл бұрын
You can be a math nerd but its all about the skills of flying the drone.
@VDEngineering
@VDEngineering 5 жыл бұрын
Trust me I'm a good pilot.
@minimon796
@minimon796 5 жыл бұрын
Why need skills when he can design the controller
@federicosagun8243
@federicosagun8243 5 жыл бұрын
@@minimon796 because developing your own skills is not a cheating.
@minimon796
@minimon796 5 жыл бұрын
@@federicosagun8243 Flying drones with hands requires no skill at all. Designing an auto controller however, do require special knowlege and skills
@federicosagun8243
@federicosagun8243 5 жыл бұрын
@@minimon796well it is much fun and very challenging when flying the drone with full authority and control. Drone pilot prefer it that way.
@JTGudgin
@JTGudgin Жыл бұрын
This was good till the last segment, you clearly do not understand the exercise you were following at the fundamental level. You did not add the saturation function to "stabilise much quicker", which it doesn't, it increases from 0.1 to 0.6 seconds. You added the saturation function to affirm your use of small angle approximations in the plant model. In reality this large angle would be much quicker but would affect the z output as well as the y, your plant model does not account for this, and as such you have to limit to small angle (which should really be 88 to 90, not 85 to 90 as you have)
@trollmaster7048
@trollmaster7048 2 жыл бұрын
Doenst work
Quadcopter PID explained
12:18
Aquisitions and Adventures Archive
Рет қаралды 60 М.
АЗАРТНИК 4 |СЕЗОН 3 Серия
30:50
Inter Production
Рет қаралды 986 М.
Новый уровень твоей сосиски
00:33
Кушать Хочу
Рет қаралды 4,5 МЛН
when you have plan B 😂
00:11
Andrey Grechka
Рет қаралды 64 МЛН
Players vs Corner Flags 🤯
00:28
LE FOOT EN VIDÉO
Рет қаралды 53 МЛН
Quadrotor Equations of Motion and Control KCC Final 4 2023 Video
2:06:47
How to Design and Analyze a Quadcopter - Part01
1:09:42
Frank Rudley
Рет қаралды 1,8 М.
Modeling a Thrust Vectored Rocket In Simulink
14:15
BPS.space
Рет қаралды 257 М.
An In-depth Look at the Multicopter Control System Architecture - PX4 Developer Summit Virtual 2020
14:09
PX4 Autopilot - Open Source Flight Control.
Рет қаралды 7 М.
Getting Started with Simulink for Controls
11:31
MATLAB
Рет қаралды 176 М.
АЗАРТНИК 4 |СЕЗОН 3 Серия
30:50
Inter Production
Рет қаралды 986 М.