ESPHome 2025.9.0-dev
Loading...
Searching...
No Matches
bme680.cpp
Go to the documentation of this file.
1#include "bme680.h"
2#include "esphome/core/hal.h"
3#include "esphome/core/log.h"
4
5namespace esphome {
6namespace bme680 {
7
8static const char *const TAG = "bme680.sensor";
9
10static const uint8_t BME680_REGISTER_COEFF1 = 0x89;
11static const uint8_t BME680_REGISTER_COEFF2 = 0xE1;
12
13static const uint8_t BME680_REGISTER_CONFIG = 0x75;
14static const uint8_t BME680_REGISTER_CONTROL_MEAS = 0x74;
15static const uint8_t BME680_REGISTER_CONTROL_HUMIDITY = 0x72;
16static const uint8_t BME680_REGISTER_CONTROL_GAS1 = 0x71;
17static const uint8_t BME680_REGISTER_CONTROL_GAS0 = 0x70;
18static const uint8_t BME680_REGISTER_HEATER_HEAT0 = 0x5A;
19static const uint8_t BME680_REGISTER_HEATER_WAIT0 = 0x64;
20
21static const uint8_t BME680_REGISTER_CHIPID = 0xD0;
22
23static const uint8_t BME680_REGISTER_FIELD0 = 0x1D;
24
25const float BME680_GAS_LOOKUP_TABLE_1[16] PROGMEM = {0.0, 0.0, 0.0, 0.0, 0.0, -1.0, 0.0, -0.8,
26 0.0, 0.0, -0.2, -0.5, 0.0, -1.0, 0.0, 0.0};
27
28const float BME680_GAS_LOOKUP_TABLE_2[16] PROGMEM = {0.0, 0.0, 0.0, 0.0, 0.1, 0.7, 0.0, -0.8,
29 -0.1, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0};
30
31[[maybe_unused]] static const char *oversampling_to_str(BME680Oversampling oversampling) {
32 switch (oversampling) {
34 return "None";
36 return "1x";
38 return "2x";
40 return "4x";
42 return "8x";
44 return "16x";
45 default:
46 return "UNKNOWN";
47 }
48}
49
50[[maybe_unused]] static const char *iir_filter_to_str(BME680IIRFilter filter) {
51 switch (filter) {
53 return "OFF";
55 return "1x";
57 return "3x";
59 return "7x";
61 return "15x";
63 return "31x";
65 return "63x";
67 return "127x";
68 default:
69 return "UNKNOWN";
70 }
71}
72
74 uint8_t chip_id;
75 if (!this->read_byte(BME680_REGISTER_CHIPID, &chip_id) || chip_id != 0x61) {
76 this->mark_failed();
77 return;
78 }
79
80 // Read calibration
81 uint8_t cal1[25];
82 if (!this->read_bytes(BME680_REGISTER_COEFF1, cal1, 25)) {
83 this->mark_failed();
84 return;
85 }
86 uint8_t cal2[16];
87 if (!this->read_bytes(BME680_REGISTER_COEFF2, cal2, 16)) {
88 this->mark_failed();
89 return;
90 }
91
92 this->calibration_.t1 = cal2[9] << 8 | cal2[8];
93 this->calibration_.t2 = cal1[2] << 8 | cal1[1];
94 this->calibration_.t3 = cal1[3];
95
96 this->calibration_.h1 = cal2[2] << 4 | (cal2[1] & 0x0F);
97 this->calibration_.h2 = cal2[0] << 4 | cal2[1] >> 4;
98 this->calibration_.h3 = cal2[3];
99 this->calibration_.h4 = cal2[4];
100 this->calibration_.h5 = cal2[5];
101 this->calibration_.h6 = cal2[6];
102 this->calibration_.h7 = cal2[7];
103
104 this->calibration_.p1 = cal1[6] << 8 | cal1[5];
105 this->calibration_.p2 = cal1[8] << 8 | cal1[7];
106 this->calibration_.p3 = cal1[9];
107 this->calibration_.p4 = cal1[12] << 8 | cal1[11];
108 this->calibration_.p5 = cal1[14] << 8 | cal1[13];
109 this->calibration_.p6 = cal1[16];
110 this->calibration_.p7 = cal1[15];
111 this->calibration_.p8 = cal1[20] << 8 | cal1[19];
112 this->calibration_.p9 = cal1[22] << 8 | cal1[21];
113 this->calibration_.p10 = cal1[23];
114
115 this->calibration_.gh1 = cal2[14];
116 this->calibration_.gh2 = cal2[12] << 8 | cal2[13];
117 this->calibration_.gh3 = cal2[15];
118
119 uint8_t temp_var = 0;
120 if (!this->read_byte(0x02, &temp_var)) {
121 this->mark_failed();
122 return;
123 }
124 this->calibration_.res_heat_range = ((temp_var & 0x30) / 16);
125
126 if (!this->read_byte(0x00, &temp_var)) {
127 this->mark_failed();
128 return;
129 }
130 this->calibration_.res_heat_val = (int8_t) temp_var;
131
132 if (!this->read_byte(0x04, &temp_var)) {
133 this->mark_failed();
134 return;
135 }
136 this->calibration_.range_sw_err = ((int8_t) temp_var & (int8_t) 0xf0) / 16;
137
138 this->calibration_.ambient_temperature = 25; // prime ambient temperature
139
140 // Config register
141 uint8_t config_register;
142 if (!this->read_byte(BME680_REGISTER_CONFIG, &config_register)) {
143 this->mark_failed();
144 return;
145 }
146 config_register &= ~0b00011100;
147 config_register |= (this->iir_filter_ & 0b111) << 2;
148 if (!this->write_byte(BME680_REGISTER_CONFIG, config_register)) {
149 this->mark_failed();
150 return;
151 }
152
153 // Humidity control register
154 uint8_t hum_control;
155 if (!this->read_byte(BME680_REGISTER_CONTROL_HUMIDITY, &hum_control)) {
156 this->mark_failed();
157 return;
158 }
159 hum_control &= ~0b00000111;
160 hum_control |= this->humidity_oversampling_ & 0b111;
161 if (!this->write_byte(BME680_REGISTER_CONTROL_HUMIDITY, hum_control)) {
162 this->mark_failed();
163 return;
164 }
165
166 // Gas 1 control register
167 uint8_t gas1_control;
168 if (!this->read_byte(BME680_REGISTER_CONTROL_GAS1, &gas1_control)) {
169 this->mark_failed();
170 return;
171 }
172 gas1_control &= ~0b00011111;
173 gas1_control |= 1 << 4;
174 gas1_control |= 0; // profile 0
175 if (!this->write_byte(BME680_REGISTER_CONTROL_GAS1, gas1_control)) {
176 this->mark_failed();
177 return;
178 }
179
180 const bool heat_off = this->heater_temperature_ == 0 || this->heater_duration_ == 0;
181
182 // Gas 0 control register
183 uint8_t gas0_control;
184 if (!this->read_byte(BME680_REGISTER_CONTROL_GAS0, &gas0_control)) {
185 this->mark_failed();
186 return;
187 }
188 gas0_control &= ~0b00001000;
189 gas0_control |= heat_off << 3;
190 if (!this->write_byte(BME680_REGISTER_CONTROL_GAS0, gas0_control)) {
191 this->mark_failed();
192 return;
193 }
194
195 if (!heat_off) {
196 // Gas Heater Temperature
198 if (!this->write_byte(BME680_REGISTER_HEATER_HEAT0, temperature)) {
199 this->mark_failed();
200 return;
201 }
202
203 // Gas Heater Duration
204 uint8_t duration = this->calc_heater_duration_(this->heater_duration_);
205
206 if (!this->write_byte(BME680_REGISTER_HEATER_WAIT0, duration)) {
207 this->mark_failed();
208 return;
209 }
210 }
211}
212
214 ESP_LOGCONFIG(TAG, "BME680:");
215 LOG_I2C_DEVICE(this);
216 if (this->is_failed()) {
217 ESP_LOGE(TAG, ESP_LOG_MSG_COMM_FAIL);
218 }
219 ESP_LOGCONFIG(TAG, " IIR Filter: %s", iir_filter_to_str(this->iir_filter_));
220 LOG_UPDATE_INTERVAL(this);
221
222 LOG_SENSOR(" ", "Temperature", this->temperature_sensor_);
223 ESP_LOGCONFIG(TAG, " Oversampling: %s", oversampling_to_str(this->temperature_oversampling_));
224 LOG_SENSOR(" ", "Pressure", this->pressure_sensor_);
225 ESP_LOGCONFIG(TAG, " Oversampling: %s", oversampling_to_str(this->pressure_oversampling_));
226 LOG_SENSOR(" ", "Humidity", this->humidity_sensor_);
227 ESP_LOGCONFIG(TAG, " Oversampling: %s", oversampling_to_str(this->humidity_oversampling_));
228 LOG_SENSOR(" ", "Gas Resistance", this->gas_resistance_sensor_);
229 if (this->heater_duration_ == 0 || this->heater_temperature_ == 0) {
230 ESP_LOGCONFIG(TAG, " Heater OFF");
231 } else {
232 ESP_LOGCONFIG(TAG, " Heater temperature=%u°C duration=%ums", this->heater_temperature_, this->heater_duration_);
233 }
234}
235
237
239 uint8_t meas_control = 0; // No need to fetch, we're setting all fields
240 meas_control |= (this->temperature_oversampling_ & 0b111) << 5;
241 meas_control |= (this->pressure_oversampling_ & 0b111) << 2;
242 meas_control |= 0b01; // forced mode
243 if (!this->write_byte(BME680_REGISTER_CONTROL_MEAS, meas_control)) {
244 this->status_set_warning();
245 return;
246 }
247
248 this->set_timeout("data", this->calc_meas_duration_(), [this]() { this->read_data_(); });
249}
250
252 if (temperature < 200)
253 temperature = 200;
254 if (temperature > 400)
255 temperature = 400;
256
257 const int8_t ambient_temperature = this->calibration_.ambient_temperature;
258 const int8_t gh1 = this->calibration_.gh1;
259 const int16_t gh2 = this->calibration_.gh2;
260 const int8_t gh3 = this->calibration_.gh3;
261 const uint8_t res_heat_range = this->calibration_.res_heat_range;
262 const int8_t res_heat_val = this->calibration_.res_heat_val;
263
264 uint8_t heatr_res;
265 int32_t var1;
266 int32_t var2;
267 int32_t var3;
268 int32_t var4;
269 int32_t var5;
270 int32_t heatr_res_x100;
271
272 var1 = (((int32_t) ambient_temperature * gh3) / 1000) * 256;
273 var2 = (gh1 + 784) * (((((gh2 + 154009) * temperature * 5) / 100) + 3276800) / 10);
274 var3 = var1 + (var2 / 2);
275 var4 = (var3 / (res_heat_range + 4));
276 var5 = (131 * res_heat_val) + 65536;
277 heatr_res_x100 = (int32_t) (((var4 / var5) - 250) * 34);
278 heatr_res = (uint8_t) ((heatr_res_x100 + 50) / 100);
279
280 return heatr_res;
281}
283 uint8_t factor = 0;
284 uint8_t duration_value;
285
286 if (duration >= 0xfc0) {
287 duration_value = 0xff;
288 } else {
289 while (duration > 0x3F) {
290 duration /= 4;
291 factor += 1;
292 }
293 duration_value = duration + (factor * 64);
294 }
295
296 return duration_value;
297}
299 uint8_t data[15];
300 if (!this->read_bytes(BME680_REGISTER_FIELD0, data, 15)) {
301 if (this->temperature_sensor_ != nullptr)
303 if (this->pressure_sensor_ != nullptr)
305 if (this->humidity_sensor_ != nullptr)
307 if (this->gas_resistance_sensor_ != nullptr)
309 ESP_LOGW(TAG, ESP_LOG_MSG_COMM_FAIL);
310 this->status_set_warning();
311 return;
312 }
313 this->status_clear_warning();
314
315 uint32_t raw_temperature = (uint32_t(data[5]) << 12) | (uint32_t(data[6]) << 4) | (uint32_t(data[7]) >> 4);
316 uint32_t raw_pressure = (uint32_t(data[2]) << 12) | (uint32_t(data[3]) << 4) | (uint32_t(data[4]) >> 4);
317 uint32_t raw_humidity = (uint32_t(data[8]) << 8) | uint32_t(data[9]);
318 uint16_t raw_gas = (uint16_t) ((uint32_t) data[13] * 4 | (((uint32_t) data[14]) / 64));
319 uint8_t gas_range = data[14] & 0x0F;
320
321 float temperature = this->calc_temperature_(raw_temperature);
322 float pressure = this->calc_pressure_(raw_pressure);
323 float humidity = this->calc_humidity_(raw_humidity);
324 float gas_resistance = this->calc_gas_resistance_(raw_gas, gas_range);
325
326 bool gas_valid = (data[14] >> 5) & 1;
327 bool heat_stable = (data[14] >> 4) & 1;
328 if (this->heater_temperature_ == 0 || this->heater_duration_ == 0)
329 heat_stable = true; // Allow reporting gas resistance when heater is disabled
330
331 ESP_LOGD(TAG, "Got temperature=%.1f°C pressure=%.1fhPa humidity=%.1f%% gas_resistance=%.1fΩ", temperature, pressure,
332 humidity, gas_resistance);
333 if (!gas_valid)
334 ESP_LOGW(TAG, "Gas measurement unsuccessful, reading invalid!");
335 if (!heat_stable)
336 ESP_LOGW(TAG, "Heater unstable, reading invalid! (Normal for a few readings after a power cycle)");
337
338 if (this->temperature_sensor_ != nullptr)
339 this->temperature_sensor_->publish_state(temperature);
340 if (this->pressure_sensor_ != nullptr)
341 this->pressure_sensor_->publish_state(pressure);
342 if (this->humidity_sensor_ != nullptr)
343 this->humidity_sensor_->publish_state(humidity);
344 if (this->gas_resistance_sensor_ != nullptr) {
345 if (gas_valid && heat_stable) {
346 this->gas_resistance_sensor_->publish_state(gas_resistance);
347 } else {
348 this->status_set_warning();
350 }
351 }
352}
353
354float BME680Component::calc_temperature_(uint32_t raw_temperature) {
355 float var1 = 0;
356 float var2 = 0;
357 float var3 = 0;
358 float calc_temp = 0;
359 float temp_adc = raw_temperature;
360
361 const float t1 = this->calibration_.t1;
362 const float t2 = this->calibration_.t2;
363 const float t3 = this->calibration_.t3;
364
365 /* calculate var1 data */
366 var1 = ((temp_adc / 16384.0f) - (t1 / 1024.0f)) * t2;
367
368 /* calculate var2 data */
369 var3 = (temp_adc / 131072.0f) - (t1 / 8192.0f);
370 var2 = var3 * var3 * t3 * 16.0f;
371
372 /* t_fine value*/
373 this->calibration_.tfine = (var1 + var2);
374
375 /* compensated temperature data*/
376 calc_temp = ((this->calibration_.tfine) / 5120.0f);
377
378 return calc_temp;
379}
380float BME680Component::calc_pressure_(uint32_t raw_pressure) {
381 const float tfine = this->calibration_.tfine;
382 const float p1 = this->calibration_.p1;
383 const float p2 = this->calibration_.p2;
384 const float p3 = this->calibration_.p3;
385 const float p4 = this->calibration_.p4;
386 const float p5 = this->calibration_.p5;
387 const float p6 = this->calibration_.p6;
388 const float p7 = this->calibration_.p7;
389 const float p8 = this->calibration_.p8;
390 const float p9 = this->calibration_.p9;
391 const float p10 = this->calibration_.p10;
392
393 float var1 = 0;
394 float var2 = 0;
395 float var3 = 0;
396 float var4 = 0;
397 float calc_pres = 0;
398
399 var1 = (tfine / 2.0f) - 64000.0f;
400 var2 = var1 * var1 * (p6 / 131072.0f);
401 var2 = var2 + var1 * p5 * 2.0f;
402 var2 = (var2 / 4.0f) + (p4 * 65536.0f);
403 var1 = (((p3 * var1 * var1) / 16384.0f) + (p2 * var1)) / 524288.0f;
404 var1 = (1.0f + (var1 / 32768.0f)) * p1;
405 calc_pres = 1048576.0f - float(raw_pressure);
406
407 /* Avoid exception caused by division by zero */
408 if (int(var1) != 0) {
409 calc_pres = ((calc_pres - (var2 / 4096.0f)) * 6250.0f) / var1;
410 var1 = (p9 * calc_pres * calc_pres) / 2147483648.0f;
411 var2 = calc_pres * (p8 / 32768.0f);
412 var4 = calc_pres / 256.0f;
413 var3 = var4 * var4 * var4 * (p10 / 131072.0f);
414 calc_pres = calc_pres + (var1 + var2 + var3 + (p7 * 128.0f)) / 16.0f;
415 } else {
416 calc_pres = 0;
417 }
418
419 return calc_pres / 100.0f;
420}
421
422float BME680Component::calc_humidity_(uint16_t raw_humidity) {
423 const float tfine = this->calibration_.tfine;
424 const float h1 = this->calibration_.h1;
425 const float h2 = this->calibration_.h2;
426 const float h3 = this->calibration_.h3;
427 const float h4 = this->calibration_.h4;
428 const float h5 = this->calibration_.h5;
429 const float h6 = this->calibration_.h6;
430 const float h7 = this->calibration_.h7;
431
432 float calc_hum = 0;
433 float var1 = 0;
434 float var2 = 0;
435 float var3 = 0;
436 float var4 = 0;
437 float temp_comp;
438
439 /* compensated temperature data*/
440 temp_comp = tfine / 5120.0f;
441
442 var1 = float(raw_humidity) - (h1 * 16.0f + ((h3 / 2.0f) * temp_comp));
443 var2 = var1 *
444 (((h2 / 262144.0f) * (1.0f + ((h4 / 16384.0f) * temp_comp) + ((h5 / 1048576.0f) * temp_comp * temp_comp))));
445 var3 = h6 / 16384.0f;
446 var4 = h7 / 2097152.0f;
447
448 calc_hum = var2 + (var3 + var4 * temp_comp) * var2 * var2;
449
450 if (calc_hum > 100.0f) {
451 calc_hum = 100.0f;
452 } else if (calc_hum < 0.0f) {
453 calc_hum = 0.0f;
454 }
455
456 return calc_hum;
457}
458float BME680Component::calc_gas_resistance_(uint16_t raw_gas, uint8_t range) {
459 float calc_gas_res;
460 float var1 = 0;
461 float var2 = 0;
462 float var3 = 0;
463 float raw_gas_f = raw_gas;
464 float range_f = 1U << range;
465 const float range_sw_err = this->calibration_.range_sw_err;
466
467 var1 = 1340.0f + (5.0f * range_sw_err);
468 var2 = var1 * (1.0f + BME680_GAS_LOOKUP_TABLE_1[range] / 100.0f);
469 var3 = 1.0f + (BME680_GAS_LOOKUP_TABLE_2[range] / 100.0f);
470
471 calc_gas_res = 1.0f / (var3 * 0.000000125f * range_f * (((raw_gas_f - 512.0f) / var2) + 1.0f));
472
473 return calc_gas_res;
474}
476 uint32_t tph_dur; // Calculate in us
477 uint32_t meas_cycles;
478 const uint8_t os_to_meas_cycles[6] = {0, 1, 2, 4, 8, 16};
479
480 meas_cycles = os_to_meas_cycles[this->temperature_oversampling_];
481 meas_cycles += os_to_meas_cycles[this->pressure_oversampling_];
482 meas_cycles += os_to_meas_cycles[this->humidity_oversampling_];
483
484 /* TPH measurement duration */
485 tph_dur = meas_cycles * 1963u;
486 tph_dur += 477 * 4; // TPH switching duration
487 tph_dur += 477 * 5; // Gas measurement duration
488 tph_dur += 500; // Get it to the closest whole number.
489 tph_dur /= 1000; // Convert to ms
490
491 tph_dur += 1; // Wake up duration of 1ms
492
493 /* The remaining time should be used for heating */
494 tph_dur += this->heater_duration_;
495
496 return tph_dur;
497}
499 this->temperature_oversampling_ = temperature_oversampling;
500}
502 this->pressure_oversampling_ = pressure_oversampling;
503}
505 this->humidity_oversampling_ = humidity_oversampling;
506}
507void BME680Component::set_iir_filter(BME680IIRFilter iir_filter) { this->iir_filter_ = iir_filter; }
508void BME680Component::set_heater(uint16_t heater_temperature, uint16_t heater_duration) {
509 this->heater_temperature_ = heater_temperature;
510 this->heater_duration_ = heater_duration;
511}
512
513} // namespace bme680
514} // namespace esphome
virtual void mark_failed()
Mark this component as failed.
bool is_failed() const
void status_set_warning(const char *message=nullptr)
void status_clear_warning()
void set_timeout(const std::string &name, uint32_t timeout, std::function< void()> &&f)
Set a timeout function with a unique name.
uint8_t calc_heater_duration_(uint16_t duration)
Calculate the heater duration value to send to the BME680 register.
Definition bme680.cpp:282
void read_data_()
Read data from the BME680 and publish results.
Definition bme680.cpp:298
sensor::Sensor * humidity_sensor_
Definition bme680.h:134
uint8_t calc_heater_resistance_(uint16_t temperature)
Calculate the heater resistance value to send to the BME680 register.
Definition bme680.cpp:251
float calc_humidity_(uint16_t raw_humidity)
Calculate the relative humidity in % using the provided raw ADC value.
Definition bme680.cpp:422
BME680Oversampling pressure_oversampling_
Definition bme680.h:126
BME680CalibrationData calibration_
Definition bme680.h:124
void set_pressure_oversampling(BME680Oversampling pressure_oversampling)
Set the pressure oversampling value. Defaults to 16X.
Definition bme680.cpp:501
BME680Oversampling temperature_oversampling_
Definition bme680.h:125
float get_setup_priority() const override
Definition bme680.cpp:236
BME680Oversampling humidity_oversampling_
Definition bme680.h:127
void set_temperature_oversampling(BME680Oversampling temperature_oversampling)
Set the temperature oversampling value. Defaults to 16X.
Definition bme680.cpp:498
sensor::Sensor * temperature_sensor_
Definition bme680.h:132
float calc_gas_resistance_(uint16_t raw_gas, uint8_t range)
Calculate the gas resistance in Ω using the provided raw ADC value.
Definition bme680.cpp:458
void set_heater(uint16_t heater_temperature, uint16_t heater_duration)
Set how the internal heater should operate.
Definition bme680.cpp:508
sensor::Sensor * pressure_sensor_
Definition bme680.h:133
void set_iir_filter(BME680IIRFilter iir_filter)
Set the IIR Filter value. Defaults to no IIR Filter.
Definition bme680.cpp:507
uint32_t calc_meas_duration_()
Calculate how long the sensor will take until we can retrieve data.
Definition bme680.cpp:475
float calc_temperature_(uint32_t raw_temperature)
Calculate the temperature in °C using the provided raw ADC value.
Definition bme680.cpp:354
void set_humidity_oversampling(BME680Oversampling humidity_oversampling)
Set the humidity oversampling value. Defaults to 16X.
Definition bme680.cpp:504
float calc_pressure_(uint32_t raw_pressure)
Calculate the pressure in hPa using the provided raw ADC value.
Definition bme680.cpp:380
sensor::Sensor * gas_resistance_sensor_
Definition bme680.h:135
BME680IIRFilter iir_filter_
Definition bme680.h:128
bool write_byte(uint8_t a_register, uint8_t data, bool stop=true)
Definition i2c.h:266
bool read_byte(uint8_t a_register, uint8_t *data, bool stop=true)
Definition i2c.h:239
bool read_bytes(uint8_t a_register, uint8_t *data, uint8_t len)
Compat APIs All methods below have been added for compatibility reasons.
Definition i2c.h:216
void publish_state(float state)
Publish a new state to the front-end.
Definition sensor.cpp:45
Range range
Definition msa3xx.h:0
uint8_t duration
Definition msa3xx.h:0
const char * iir_filter_to_str(BME280IIRFilter filter)
BME680IIRFilter
Enum listing all IIR Filter options for the BME680.
Definition bme680.h:11
@ BME680_IIR_FILTER_63X
Definition bme680.h:18
@ BME680_IIR_FILTER_15X
Definition bme680.h:16
@ BME680_IIR_FILTER_OFF
Definition bme680.h:12
@ BME680_IIR_FILTER_3X
Definition bme680.h:14
@ BME680_IIR_FILTER_31X
Definition bme680.h:17
@ BME680_IIR_FILTER_127X
Definition bme680.h:19
@ BME680_IIR_FILTER_7X
Definition bme680.h:15
@ BME680_IIR_FILTER_1X
Definition bme680.h:13
BME680Oversampling
Enum listing all oversampling options for the BME680.
Definition bme680.h:23
@ BME680_OVERSAMPLING_2X
Definition bme680.h:26
@ BME680_OVERSAMPLING_4X
Definition bme680.h:27
@ BME680_OVERSAMPLING_16X
Definition bme680.h:29
@ BME680_OVERSAMPLING_NONE
Definition bme680.h:24
@ BME680_OVERSAMPLING_8X
Definition bme680.h:28
@ BME680_OVERSAMPLING_1X
Definition bme680.h:25
const float BME680_GAS_LOOKUP_TABLE_1[16] PROGMEM
Definition bme680.cpp:25
const float DATA
For components that import data from directly connected sensors like DHT.
Definition component.cpp:50
Providing packet encoding functions for exchanging data with a remote host.
Definition a01nyub.cpp:7
uint16_t temperature
Definition sun_gtil2.cpp:12
uint8_t pressure
Definition tt21100.cpp:7