[bme68x_bsec2] Fix uninitialized bme68x_conf in measurement duration calculation (#15168)

This commit is contained in:
Jonathan Swoboda
2026-03-25 14:10:04 -04:00
committed by GitHub
parent c42c6745b9
commit 19615f2eae
@@ -276,8 +276,8 @@ void BME68xBSEC2Component::run_() {
}
if (this->bsec_settings_.trigger_measurement && this->bsec_settings_.op_mode != BME68X_SLEEP_MODE) {
uint32_t meas_dur = 0;
meas_dur = bme68x_get_meas_dur(this->op_mode_, &bme68x_conf, &this->bme68x_);
bme68x_get_conf(&bme68x_conf, &this->bme68x_);
uint32_t meas_dur = bme68x_get_meas_dur(this->op_mode_, &bme68x_conf, &this->bme68x_);
ESP_LOGV(TAG, "Queueing read in %uus", meas_dur);
this->trigger_time_ns_ = curr_time_ns;
this->set_timeout("read", meas_dur / 1000, [this]() { this->read_(this->trigger_time_ns_); });