AHRS: make P gain on PI roll/pitch controller tunable

this is to make it easier for Craig and Alan to tune
This commit is contained in:
Andrew Tridgell 2012-07-03 14:14:46 +10:00
parent fd97eb5a8d
commit 1314e4f872
2 changed files with 3 additions and 2 deletions

View File

@ -37,6 +37,7 @@ const AP_Param::GroupInfo AP_AHRS::var_info[] PROGMEM = {
// @Range: 0 .4
// @Increment: .01
AP_GROUPINFO("YAW_P", 0, AP_AHRS_DCM, _kp_yaw),
AP_GROUPINFO("RP_P", 1, AP_AHRS_DCM, _kp),
AP_GROUPEND
};

View File

@ -23,7 +23,7 @@ public:
_ki = 0.0087;
_ki_yaw = 0.01;
_kp = 0.4;
_kp.set(0.4);
_kp_yaw.set(0.4);
}
@ -44,9 +44,9 @@ public:
// settable parameters
AP_Float _kp_yaw;
AP_Float _kp;
private:
float _kp;
float _ki;
float _ki_yaw;
bool _have_initial_yaw;