An IMU temperature calibration is being learned
What ArduPilot says:
- PreArm: temperature cal running
- TCAL[N]: started calibration t=N.NC tmax=N.NC
- TCAL finished all IMUs
- TCAL[N]: failed fit
- TCAL[N]: completed calibration tmin=N.N tmax=N.N
INS_TCALn_ENABLE is 2 for an IMU: the board is recording how its gyro and accelerometer zeros change as it warms up, from the temperature it started at to INS_TCALn_TMAX. While this runs the aircraft will not arm. “started” and “completed” mark the two ends for each IMU (numbered from 1) and “TCAL finished all IMUs” the end of the whole run; the parameter then becomes 1 by itself. “failed fit” means the data could not be turned into a calibration, and the parameter was set to 0.
What to do, most likely first
A temperature calibration was started on purpose and has not reached its target temperature yet.
CheckWatch the IMU temperature in the ground station climb towards INS_TCALn_TMAX; it has to rise at least 10 °C above where it started.
FixLet it finish: keep the board completely still while it warms. Then reboot.
The parameter was set to 2 by mistake, or the board cannot reach INS_TCALn_TMAX in these conditions.
FixSet INS_TCALn_ENABLE back to 1 if a calibration already exists, or to 0 if there is none, and reboot.
“failed fit”: the board was moved while it warmed, or the temperature range covered was too small.
FixCool the board well (a freezer bag keeps it dry), set INS_TCALn_ENABLE to 2, power it on a still surface and do not touch it until “TCAL finished all IMUs”.
Parameters to look at
| Parameter | What it is |
|---|---|
INS_TCAL1_ENABLE | Enable temperature calibration |
INS_TCAL1_TMIN | Temperature calibration min |
INS_TCAL1_TMAX | Temperature calibration max |
INS_TCAL_OPTIONS | Options for temperature calibration |
The code that sends it
PreArm: temperature cal running
libraries/AP_Arming/AP_Arming.cpp AP_Arming::ins_checks() · Open in ArduPilot Copter-4.7.1
TCAL[N]: started calibration t=N.NC tmax=N.NC
libraries/AP_InertialSensor/AP_InertialSensor_tempcal.cpp AP_InertialSensor_TCal::update_accel_learning() · Open in ArduPilot Copter-4.7.1
TCAL finished all IMUs
libraries/AP_InertialSensor/AP_InertialSensor.cpp AP_InertialSensor::update() · Open in ArduPilot Copter-4.7.1
TCAL[N]: failed fit
libraries/AP_InertialSensor/AP_InertialSensor_tempcal.cpp AP_InertialSensor_TCal::Learn::finish_calibration() · Open in ArduPilot Copter-4.7.1
And 1 more messages, sent from the same places.