ArduCopter Questions

Hi,

 

I have several questions.

 

Question on Kp Ki  (PI) regulator:

In this file Arducopter.h is write:

 

Kp_ROLLPITCH          = 0.0014;                      //Pitch&Roll Proportional Gain
Ki_ROLLPITCH           = 0.00000015;               //Pitch&Roll Integrator Gain
Kp_YAW                    = 1.0;                           //Yaw Porportional Gain
Ki_YAW                     = 0.00002;                    //Yaw Integrator Gain

 

This 4 values are use in this file DCM.pde.

 

How can I find the best Kp and Ki for Pitch&Roll and Yaw?

What method (calcul) I must to do for find the best Kp and Ki?

I need someone to explain step by step for this method.

 

Why the Kp_ROLLPITCH value and Kp_YAW value is different?

It is because dt (Time) for Kp_ROLLPITCH = 200Hz and  Kp_YAW = 60Hz?

 

If I use different kind of gyroscope(ITG-3200, L3G4200D, LYPR540AH, and other), I can use the same Kp and Ki values for each kind of gyroscope?

 

Question on DCM vs quaternion approach:

 

What is good and not good in the DCM approach?

What is good and not good in the quaternion approach with Mahony paper?

 

 

Thank you

Nicolas

You need to be a member of diydrones to add comments!

Join diydrones

Email me when people reply –

Replies

  • T3

    Hi Nicolas,

    I will try to answer a couple of your questions.

    Regarding different kinds of gyroscopes, you can use the same values of Kp and Ki in the drift feedback controller. Of course, you do have to use different gain factors to convert the A/D values into turn rates in radians/second.

    Regarding direction cosine matrix (DCM) versus quaternion approach in the Mahony paper, they will give you exactly the same accuracy. In my opinion, it is mostly a matter of personal preference which one to use.

    DCM requires more calculations to update than quaternions, but when you want to convert vectors from one frame of reference to another, it is easier to do that with DCM.

    Personally, I prefer DCM. I think that Mahony prefers quaternions, but he thinks that DCM is a valid way to do it too. Isn't it nice to have a choice?

    Regarding the gains used in ArduCopter, I have no idea how they were selected, you will have to get the attention of the ArduCopter team to get your answer to that question.

    Best regards,

    Bill

     

     

This reply was deleted.

Activity