Hello,
thanks, I know these definitions, already working with the sensors since a very long time.
In these older logs was a wide range of IAQ and VOC values. Later the range was normal for a working room, IAQ between 25 and 90.
In any case the described accuracy change was seen.
I have changed not the code and request the values after some more than 3 seconds using a delay in the loop.
After 2 days I see the normal recalibration if the IAQ is going down to 25.00, so that a calibration could be needed. The values are stable.
Will tell you after next days the results and can provide the logs then.
Thanks!
Hello micha_pr,
Did it work well on your side?
Hi,
no, not solved,... see attached log.
After some time the sensor is going "for ever" (at least for >24 hours) to accuracy = 1 and will not come back.
Before all is normal, it is working at accuracy "3" and sometimes is going o "2" and coming back to "3".
Header of the syslog data:
"Sensor, Timestamp [ms], raw temperature [°C], pressure [hPa], raw relative humidity [%], gas [Ohm], IAQ, IAQ accuracy, temperature [°C], relative humidity [%]"
Code used basically Github:
const uint8_t bsec_config_iaq[] = {
#include "config/generic_33v_3s_4d/bsec_iaq.txt"
};
void setup(void)
{...
iaqSensor1.setConfig(bsec_config_iaq);
iaqSensor2.setConfig(bsec_config_iaq);
checkIaqSensorStatus();
loadState();
...
iaqSensor1.updateSubscription(sensorList, 10, BSEC_SAMPLE_RATE_LP);
iaqSensor2.updateSubscription(sensorList, 10, BSEC_SAMPLE_RATE_LP);
checkIaqSensorStatus();
...
}
void loop(void)
{
...
if (iaqSensor1.run()) {
delay(50); // If new data is available
output = "1, " + String(millis());
output += ", " + String(iaqSensor1.rawTemperature);
output += ", " + String(iaqSensor1.pressure);
output += ", " + String(iaqSensor1.rawHumidity);
output += ", " + String(iaqSensor1.gasResistance);
output += ", " + String(iaqSensor1.iaq);
output += ", " + String(iaqSensor1.iaqAccuracy);
output += ", " + String(iaqSensor1.temperature);
output += ", " + String(iaqSensor1.humidity);
output += ", " + String(iaqSensor1.staticIaq);
output += ", " + String(iaqSensor1.co2Equivalent);
output += ", " + String(iaqSensor1.breathVocEquivalent);
Serial.println(output);
syslog.log(LOG_INFO, output);
updateState();
} else {
checkIaqSensorStatus();
}
if (iaqSensor2.run()) {
delay(50);// If new data is available
output = "2, " + String(millis());
output += ", " + String(iaqSensor2.rawTemperature);
output += ", " + String(iaqSensor2.pressure);
output += ", " + String(iaqSensor2.rawHumidity);
output += ", " + String(iaqSensor2.gasResistance);
output += ", " + String(iaqSensor2.iaq);
output += ", " + String(iaqSensor2.iaqAccuracy);
output += ", " + String(iaqSensor2.temperature);
output += ", " + String(iaqSensor2.humidity);
output += ", " + String(iaqSensor2.staticIaq);
output += ", " + String(iaqSensor2.co2Equivalent);
output += ", " + String(iaqSensor2.breathVocEquivalent);
Serial.println(output);
syslog.log(LOG_INFO, output);
updateState();
} else {
checkIaqSensorStatus();
}
delay(3000);
}
Maybe you have any idea?
In this time I restart the ESP32, if a very long time the accuracy is "1", then it is going back after some time to "3" (reading before the config state)
Thanks!
Michael
Hello micha_pr,
Let's check and give you feedback later.
Hello micha_pr,
We have checked the data log, there's nothing wrong with data.
IAQ accuracy drops to 1 may because of sensor lacking of stimuli.
Gas data curve is really smooth, that may have caused the change of IAQ accuracy.
You could try to open the windows or put a glass of wine next to sensor, check if IAQ accuracy would goes up to 3.