Bosch Sensortec Community

    cancel
    Showing results for 
    Search instead for 
    Did you mean: 
    SOLVED

    Precision of BME680

    Precision of BME680

    Cris
    New Poster

    Hi,

    i'm working with the sensor BME 680. I'm interested in reading the VOC, IAQ and Co2eq.

    I have created the algorithm on STM32F100 to read the data from the BME680. I've integrated even the BSEC library. I don't use the floating point compensation.

    But about the breath VOC read from the sensor seems very different from the measurement instrument reference that I'm using which read the TVOC.

    The reference instrument is a Trotec BQ16.

    While warming up the BME680 sensor give this values  

    IAQ - 25

    Precision IAQ - 0

    CO2 - 500 ppm

    VOC - 499 ppb

    but since it's warming up it's not a problem.

    But after some minutes time the BME sensor report:

    IAQ - 104

    IAQ accurency - 1

    CO2 - 638 ppm

    VOC - 843 ppb

    While the reference instruments (BQ16) give me a TVOC of 0,22 ppm which is between a third and a quarter of the value read from the BME 680.

    Why? Have I made any mistake integrating your code? If you need I can give even the gas resistance. I'm reading data every 3 seconds.

    The temperature, umidity and pressure seems correct, the CO2 seems quaite similar to the value read from another instrument. But the VOC seems always between 2 and 4 time bigger than the reading from the reference instrument.

    We note even that if the sensor has been turned on for long time, the value of VOC is much bigger. Shutting down and turning on again, the value read of the VOC seems to read a smaller value

    Thanks in advance,

    Cris

    21 REPLIES 21

    The values are the one taken from the bsec (from the function BSEC_output_ready in bsec_iot_example.c):

    void BSEC_output_ready(int64_t timestamp, float a_iaq, uint8_t a_iaq_accuracy, float a_temperature, float a_humidity,
    float a_pressure, float a_raw_temperature, float a_raw_humidity, float a_gas, bsec_library_return_t a_bsec_status,
    float a_static_iaq, float a_co2_equivalent, float a_breath_voc_equivalent).

    Every 3 seconds this function is called and return all data logged in the excel file and converted to integer value. In reality I've made some modification to the file BSEC_iot_example.c and bsec_integration.c to avoid blocking functions.

    In Bsec_integration.c I have modified the number of data requested in order to have all data (compensated and raw data). The defined constant NUM_USED_OUTPUTS has been set to 10 

    /*!
    * @brief Virtual sensor subscription
    * Please call this function before processing of data using bsec_do_steps function
    *
    * @param[in] sample_rate mode to be used (either BSEC_SAMPLE_RATE_ULP or BSEC_SAMPLE_RATE_LP)
    *
    * @return subscription result, zero when successful
    */
    static bsec_library_return_t bme680_bsec_update_subscription(float sample_rate)
    {
    bsec_sensor_configuration_t requested_virtual_sensors[NUM_USED_OUTPUTS];
    uint8_t n_requested_virtual_sensors = NUM_USED_OUTPUTS;

    bsec_sensor_configuration_t required_sensor_settings[BSEC_MAX_PHYSICAL_SENSOR];
    uint8_t n_required_sensor_settings = BSEC_MAX_PHYSICAL_SENSOR;

    bsec_library_return_t status = BSEC_OK;

    /* note: Virtual sensors as desired to be added here */
    requested_virtual_sensors[0].sensor_id = BSEC_OUTPUT_IAQ;
    requested_virtual_sensors[0].sample_rate = sample_rate;
    requested_virtual_sensors[1].sensor_id = BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_TEMPERATURE;
    requested_virtual_sensors[1].sample_rate = sample_rate;
    requested_virtual_sensors[2].sensor_id = BSEC_OUTPUT_RAW_PRESSURE;
    requested_virtual_sensors[2].sample_rate = sample_rate;
    requested_virtual_sensors[3].sensor_id = BSEC_OUTPUT_SENSOR_HEAT_COMPENSATED_HUMIDITY;
    requested_virtual_sensors[3].sample_rate = sample_rate;
    requested_virtual_sensors[4].sensor_id = BSEC_OUTPUT_BREATH_VOC_EQUIVALENT;
    requested_virtual_sensors[4].sample_rate = sample_rate;
    requested_virtual_sensors[5].sensor_id = BSEC_OUTPUT_RAW_TEMPERATURE;
    requested_virtual_sensors[5].sample_rate = sample_rate;
    requested_virtual_sensors[6].sensor_id = BSEC_OUTPUT_RAW_HUMIDITY;
    requested_virtual_sensors[6].sample_rate = sample_rate;
    requested_virtual_sensors[7].sensor_id = BSEC_OUTPUT_CO2_EQUIVALENT;
    requested_virtual_sensors[7].sample_rate = sample_rate;
    requested_virtual_sensors[8].sensor_id = BSEC_OUTPUT_RAW_GAS;
    requested_virtual_sensors[8].sample_rate = sample_rate;
    requested_virtual_sensors[9].sensor_id = BSEC_OUTPUT_STATIC_IAQ;
    requested_virtual_sensors[9].sample_rate = sample_rate;

    /* Call bsec_update_subscription() to enable/disable the requested virtual sensors */
    status = bsec_update_subscription(requested_virtual_sensors, n_requested_virtual_sensors, required_sensor_settings,
    &n_required_sensor_settings);

    return status;
    }

    I'm talking to the BME680 via SPI.

    The BSEC version is  1.4.7.4 genric release. The microprocessor is an ARM (STM32)

     

     

     

    I forgot, the VOC value is taken from  BSEC_OUTPUT_BREATH_VOC_EQUIVALENT and shown multiplied for 1000, since we have decided to show the ppb. One issue is that since the VOC are converted from float to integer and I didn't expect this value to overtake 32768 ppb, the negative values happened when the VOC value overtakes 32768 ppb

    Vincent
    Community Moderator
    Community Moderator

    Which column in the excel file is the VOC sensor output you meant? 

    I saw you are enable 10 different output virtual sensor in BSEC,  are they both in the data log? 

    I also expect the data which input into the lib can be stored in data log also.  then i can try to compare the data set from our side.

    Sorry, probably I had attached the wrong excel file probably. Now there is a new file that I want to be verified if it's correct, with all data taken from a sensor placed outside for a weekend in a protected place from sulight. The acquisition has been taken all weekend. It was placed in a box in order to protect from the rain that was expected on the morning of the last day. Because of the box, the temperature didn't drop very mutch during the night and the condition were stable (too stable seems since IAQ accurancy drop to 1 during the nigth)

    Cris_5-1599464280786.png

     

    Cris_0-1599463635192.png

    Temperature graph

    Cris_1-1599463865001.png

    The pressure seems correct since a low pressure were approaching during the weekend

    Cris_2-1599463923232.png

    Don't mind the last column VOC/100 filtrated that  was created by me 

    Cris_3-1599464061361.png

     

     

     

     

     

    Vincent
    Community Moderator
    Community Moderator

    Thank you for sharing us the correct data log. 

    With your data log,  i can get the following pollter.

    Vincent_0-1599609356523.png

    Vincent_1-1599609368666.png

    From the plotter,  you can see the IAQ accuracy is not drop to 1,  it just change between 3 and 2 which is expected.  During the weekend,  the door is keep closed,  then the air quality is not changing too much.   then the accuracy level will drop to 2.  then if there is some activity,  the indoor air quality changes,  then it will change back to 3. 

    Also i found that in your data log, the time interval is 1 minute not 3 second you mentioned. 

    We are gurantee the BSEC lib accuracy only for 3s and 300s.  Any other time interval are not supported and tested right now. 

     

    Icon--AD-black-48x48Icon--address-consumer-data-black-48x48Icon--appointment-black-48x48Icon--back-left-black-48x48Icon--calendar-black-48x48Icon--center-alignedIcon--Checkbox-checkIcon--clock-black-48x48Icon--close-black-48x48Icon--compare-black-48x48Icon--confirmation-black-48x48Icon--dealer-details-black-48x48Icon--delete-black-48x48Icon--delivery-black-48x48Icon--down-black-48x48Icon--download-black-48x48Ic-OverlayAlertIcon--externallink-black-48x48Icon-Filledforward-right_adjustedIcon--grid-view-black-48x48IC_gd_Check-Circle170821_Icons_Community170823_Bosch_Icons170823_Bosch_Icons170821_Icons_CommunityIC-logout170821_Icons_Community170825_Bosch_Icons170821_Icons_CommunityIC-shopping-cart2170821_Icons_CommunityIC-upIC_UserIcon--imageIcon--info-i-black-48x48Icon--left-alignedIcon--Less-minimize-black-48x48Icon-FilledIcon--List-Check-grennIcon--List-Check-blackIcon--List-Cross-blackIcon--list-view-mobile-black-48x48Icon--list-view-black-48x48Icon--More-Maximize-black-48x48Icon--my-product-black-48x48Icon--newsletter-black-48x48Icon--payment-black-48x48Icon--print-black-48x48Icon--promotion-black-48x48Icon--registration-black-48x48Icon--Reset-black-48x48Icon--right-alignedshare-circle1Icon--share-black-48x48Icon--shopping-bag-black-48x48Icon-shopping-cartIcon--start-play-black-48x48Icon--store-locator-black-48x48Ic-OverlayAlertIcon--summary-black-48x48tumblrIcon-FilledvineIc-OverlayAlertwhishlist