From b263e591c3c29342989bf240bd0599d2087252bc Mon Sep 17 00:00:00 2001 From: G6EJD Date: Sun, 3 Mar 2019 15:02:28 +0000 Subject: [PATCH] Update ESP32_bme680_CC_demo_02.ino Correct gas average value --- ESP32_bme680_CC_demo_02.ino | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ESP32_bme680_CC_demo_02.ino b/ESP32_bme680_CC_demo_02.ino index 7d6d8ab..53a4661 100644 --- a/ESP32_bme680_CC_demo_02.ino +++ b/ESP32_bme680_CC_demo_02.ino @@ -135,7 +135,7 @@ void GetGasReference(){ // Now run the sensor for a burn-in period, then use combination of relative humidity and gas resistance to estimate indoor air quality as a percentage. Serial.println("Getting a new gas reference value"); int readings = 10; - for (int i = 0; i <= readings; i++){ // read gas for 10 x 0.150mS = 1.5secs + for (int i = 1; i <= readings; i++){ // read gas for 10 x 0.150mS = 1.5secs gas_reference += bme.readGas(); } gas_reference = gas_reference / readings;