From ec82aa68c409ab7b14ee4cbf010bd691550d82a1 Mon Sep 17 00:00:00 2001 From: Randy Mackay Date: Thu, 17 Sep 2015 15:42:41 +0900 Subject: [PATCH] InertialSensor: add GYR_CAL to control when gyro calibration occurs --- .../AP_InertialSensor/AP_InertialSensor.cpp | 15 ++++++++---- .../AP_InertialSensor/AP_InertialSensor.h | 23 ++++++++----------- 2 files changed, 21 insertions(+), 17 deletions(-) diff --git a/libraries/AP_InertialSensor/AP_InertialSensor.cpp b/libraries/AP_InertialSensor/AP_InertialSensor.cpp index 2fdeb60514..6768e29ca4 100644 --- a/libraries/AP_InertialSensor/AP_InertialSensor.cpp +++ b/libraries/AP_InertialSensor/AP_InertialSensor.cpp @@ -303,6 +303,13 @@ const AP_Param::GroupInfo AP_InertialSensor::var_info[] PROGMEM = { AP_GROUPINFO("STILL_THRESH", 23, AP_InertialSensor, _still_threshold, DEFAULT_STILL_THRESH), #endif + // @Param: GYR_CAL + // @DisplayName: Gyro Calibration scheme + // @Description: Conrols when automatic gyro calibration is performed + // @Values: 0:Never, 1:Start-up only, 2:Start-up and first arming (Copter only) + // @User: Advanced + AP_GROUPINFO("GYR_CAL", 24, AP_InertialSensor, _gyro_cal_timing, 1), + /* NOTE: parameter indexes have gaps above. When adding new parameters check for conflicts carefully @@ -339,6 +346,7 @@ AP_InertialSensor::AP_InertialSensor() : for (uint8_t i=0; i