LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

MPC Quadcopter

Hello everyone,

 

I am a student and quite new.

 

I want to implement MPC and PID on quadcopter simulation example.

 

Quadcopter simulation can be found in:

 

NI Example Finder -> Control and simulation -> Case studies -> Aerospace -> Quadcopter dynamics.

 

I have spent so much time on this but I just couldn't reach anywhere. Can anyone please help.

 

Note: I am using Labview 2014.

 

Thanks

0 Kudos
Message 1 of 11
(4,226 Views)

I'll help.  Study the example, try it out, put extra indicators in place to check on variables being computed, slow it down by putting in Wait (ms) functions, or turn on Highlight Execution.

 

If you are still puzzled, ask a specific question.  Do some of the work, yourself, like posting the code that is giving you fits and explain why (or where) you are having problems.

 

Alternatively, come and spend a few days "apprenticing" yourself to one of us (it would be prudent to offer a small honorarium for our time).

 

Bob Schor

0 Kudos
Message 2 of 11
(4,221 Views)

Thank you Bob for your reply.

 

I am trying to combine the MPC transfer function model with delay with the quadcopter code.(both codes availble in example finder) I have limitations with highlight execution. I don't know why but the execution stops after 5-6 secs in to execution. And right now I don't have time to look in to that problem. 😞 

 

I have tried numberous combitinations. Attaching one of them.

 

 

 

0 Kudos
Message 3 of 11
(4,214 Views)

Well, when I look at your code (oops, I can't look at your code, because you didn't post it) ...  Sorry, let me rephrase -- if I could look at your code, I could tell you what the error means, and suggest how you might fix it ...

 

Bob Schor

0 Kudos
Message 4 of 11
(4,208 Views)

I have attached the VI in my previous post.

 

Attaching a screenshot with this post for your reference.

 

 

0 Kudos
Message 5 of 11
(4,206 Views)

Anyone?

0 Kudos
Message 6 of 11
(4,165 Views)

Here's an Analogy for you.  I read about Linux, a computer program that looks "kind of neat", with available source code.  I download the source code, and decide to try it out.  I'm "new" at C, never heard of C++, and when I try, it just doesn't work, so I find a C Forum and ask for help.

 

What would you advise me to do?

 

Here's what I advise you to do.  Don't start off with an extremely advanced example that is probably well beyond what someone having a CLAD (Certified LabVIEW Associate Developer) certification could handle.  Even with a CLD (same words, without "Associate"), if they weren't really familiar with Control Theory, and possibly with Real-Time programming, this would be probably a few weeks of study.

 

Start Small.  Be sure you know all of the basics of LabVIEW, can easily program other simulations (make some up and try it out), have familiarity with 70%-80% of the functions on the Block Diagram, then you can tackle advanced toolkits such as Control and Simulation.

 

The good news is that once you invest the necessary time, actually doing new development should go much faster than if you did it in C (or C++).

 

Bob Schor

Message 7 of 11
(4,151 Views)

Thank you very much for your advice

0 Kudos
Message 8 of 11
(4,123 Views)

hi, bob i work on this example and i got every thing except on e problem. i used another model instead of the quadcopter . it is the same analogy and get the 12 states . my model about undewater vehicles i also made a GUI for this example for UV . the problem faced me here is how to calculate the feedback and forward gain matrices  for the new model. i think i will use the pole placement method but i don't know how espiceally with this MIMO system with continuosly varying input vector. i realy want help in that specific point. thanks in advance 

 

with my regards....

0 Kudos
Message 9 of 11
(3,988 Views)

any help, Mr BoB in that point? 

0 Kudos
Message 10 of 11
(3,900 Views)