Library containing Crazyflie 2.0 controller classes: - Attitude estimator - Horizontal estimator - Vertical estimator - Attitude controller - Horizontal controller - Vertical controller - Mixer
Parameters/Parameters.h
- Committer:
- fbob
- Date:
- 2018-09-28
- Revision:
- 11:fad579538b4c
- Parent:
- 9:15058b4fa090
- Child:
- 12:9fed6f656f88
File content as of revision 11:fad579538b4c:
#ifndef Parameters_h #define Parameters_h // Attitude and position interrupt frequencies const float f_att = 200.0f; // Hz const float f_pos = 20.0f; // Hz const float dt_att = 1.0f/f_att; // s const float dt_pos = 1.0f/f_pos; // s // Motor constants const float alpha = 1.16e-07f; const float beta = 7.149e-10f; // Propeller constants const float kl = 1.726e-08f; // N.s^2/rad^2 const float kd = 1.426e-10f; // N.m.s^2/rad^2 // Quadcopter dimensions const float l = 0.033f; // m const float m = 0.030f; // kg const float I_xx = 16.0e-6f; // kg.m^2 const float I_yy = 16.0e-6f; // kg.m^2 const float I_zz = 29.0e-6f; // kg.m^2 // Gravity constant const float g = 9.81f; // m/s^2 // Attitude estimator weighthing (accelerometer X gyroscope) const float rho = 0.02f; // Attitude controller time constants const float T_phi = 0.12f; // s const float T_theta = 0.12f; // s const float T_psi = 0.2f; // s const float T_p = 0.04f; // s const float T_q = 0.04f; // s const float T_r = 0.1f; // s // Vertical estimator weighthing (measurement X prediction) const float rho_ver = 0.3f; // Vertical controller time constants const float zeta = 0.7f; const float omega_n = 2.0f; // rad/s const float K_z = pow(omega_n,2); const float K_w = 2*zeta*omega_n; // Horizontal estimator weighthing (measurement X prediction) const float rho_hor = 0.1f; // Horizontal controller time constants const float T_u = 2.0f; const float T_v = 2.0f; #endif