From 86a20d5917a914d472fbbc99aa799997e1eee666 Mon Sep 17 00:00:00 2001 From: G6EJD Date: Mon, 16 Apr 2018 13:29:31 +0000 Subject: [PATCH] Corrected Gas reference errors both were a factor of 10 too high --- ESP32_bme680_CC_demo_02.ino | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ESP32_bme680_CC_demo_02.ino b/ESP32_bme680_CC_demo_02.ino index f98b94a..89d9b6a 100644 --- a/ESP32_bme680_CC_demo_02.ino +++ b/ESP32_bme680_CC_demo_02.ino @@ -111,8 +111,8 @@ void loop() { } //Calculate gas contribution to IAQ index - int gas_lower_limit = 50000; // Bad air quality limit - int gas_upper_limit = 500000; // Good air quality limit + int gas_lower_limit = 5000; // Bad air quality limit + int gas_upper_limit = 50000; // Good air quality limit   if (gas_reference > gas_upper_limit) gas_reference = gas_upper_limit;  if (gas_reference < gas_lower_limit) gas_reference = gas_lower_limit; gas_score = (0.75/(gas_upper_limit-gas_lower_limit)*gas_reference -(gas_lower_limit*(0.75/(gas_upper_limit-gas_lower_limit))))*100;