sensor calibration delete temperature (CAL_ACCx_TEMP, CAL_GYROx_TEMP, CAL_MAGx_TEMP)

- this was an experiment to casually monitor sensor offsets relative to temperature, but now that all calibration offsets can be adjusted post-flight the stored temperature can be misleading
 - deleting to save a little bit of flash (and storing the temperature wasn't useful)
This commit is contained in:
Daniel Agar
2022-03-12 11:38:49 -05:00
committed by GitHub
parent aa64789792
commit 3d54d25867
15 changed files with 11 additions and 196 deletions
@@ -194,7 +194,6 @@ void VehicleMagnetometer::UpdateMagBiasEstimate()
const Vector3f offset = _calibration[mag_index].BiasCorrectedSensorOffset(_calibration_estimator_bias[mag_index]);
if (_calibration[mag_index].set_offset(offset)) {
_calibration[mag_index].set_temperature(_last_data[mag_index].temperature);
// save parameters with preferred calibration slot to current sensor index
_calibration[mag_index].ParametersSave(mag_index);
@@ -253,7 +252,6 @@ void VehicleMagnetometer::UpdateMagCalibration()
_calibration_estimator_bias[mag_index];
_mag_cal[i].variance = bias_variance;
_mag_cal[i].temperature = _last_data[mag_index].temperature;
_in_flight_mag_cal_available = true;
break;
@@ -298,8 +296,6 @@ void VehicleMagnetometer::UpdateMagCalibration()
(double)mag_cal_offset(0), (double)mag_cal_offset(1), (double)mag_cal_offset(2),
(double)_mag_cal[i].offset(0), (double)_mag_cal[i].offset(1), (double)_mag_cal[i].offset(2));
_calibration[mag_index].set_temperature(_last_data[mag_index].temperature);
_calibration[mag_index].ParametersSave();
calibration_param_save_needed = true;