12-13-2019 01:44 AM
Hi.
Why does it take the BSEC 5 minutes (exactly) to start to produce valid IAQ signals, and is there a way to speed that up?
Here's what output_ready produces every time:
...
output_ready [284.354675]: timestamp_NS=284354687000, bsec_status=0, iaq=25.00, iaq_accuracy=0
output_ready [287.576751]: timestamp_NS=287576750000, bsec_status=0, iaq=25.00, iaq_accuracy=0
output_ready [290.797851]: timestamp_NS=290797843000, bsec_status=0, iaq=25.00, iaq_accuracy=0
output_ready [294.019897]: timestamp_NS=294019906000, bsec_status=0, iaq=25.00, iaq_accuracy=0
output_ready [297.241973]: timestamp_NS=297241968000, bsec_status=0, iaq=25.00, iaq_accuracy=0
output_ready [300.463073]: timestamp_NS=300463062000, bsec_status=0, iaq=25.00, iaq_accuracy=1
output_ready [303.685119]: timestamp_NS=303685125000, bsec_status=0, iaq=21.78, iaq_accuracy=1
output_ready [306.907196]: timestamp_NS=306907187000, bsec_status=0, iaq=23.73, iaq_accuracy=1
output_ready [310.129241]: timestamp_NS=310129250000, bsec_status=0, iaq=23.23, iaq_accuracy=1
output_ready [313.351318]: timestamp_NS=313351312000, bsec_status=0, iaq=25.88, iaq_accuracy=1
...
The sample rate is BSEC_SAMPLE_RATE_LP.
Thanks,
Kevin
void output_ready(int64_t timestamp_ns, float iaq, uint8_t iaq_accuracy, float temperature, float humidity, float pressure, float raw_temperature, float raw_humidity, float raw_gas, bsec_library_return_t bsec_status, float static_iaq, float co2_equivalent, float breath_voc_equivalent) { float timestamp_sec = timestamp_ns / 1000000000.0; printf("output_ready [%1.6f]: timestamp_NS=%lld, bsec_status=%d, iaq=%1.2f, iaq_accuracy=%d\n", timestamp_sec, timestamp_ns, bsec_status, iaq, iaq_accuracy); }
12-17-2019 07:57 PM
There is one (easy to miss) keyword that you missed in the original reply 😉