mirror of
https://gitee.com/xiaohuolufeihua/bizhang_-obav.git
synced 2026-05-22 01:12:31 +00:00
events: don't start baro calibration until specified temperature achieved
This commit is contained in:
committed by
Lorenz Meier
parent
e75f2b9cf7
commit
f3d30564ed
@@ -96,6 +96,12 @@ int TemperatureCalibrationBaro::update_sensor_instance(PerSensorData &data, int
|
||||
data.sensor_sample_filt[0] = 100.0f * baro_data.pressure; // convert from hPA to Pa
|
||||
data.sensor_sample_filt[1] = baro_data.temperature;
|
||||
|
||||
|
||||
// wait for min start temp to be reached before starting calibration
|
||||
if (data.sensor_sample_filt[1] < _min_start_temperature) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (!data.cold_soaked) {
|
||||
data.cold_soaked = true;
|
||||
data.low_temp = data.sensor_sample_filt[1]; //Record the low temperature
|
||||
|
||||
Reference in New Issue
Block a user