Bosch Sensortec Community

    Showing results for 
    Search instead for 
    Did you mean: 

    Getting error in bme680 calibration function.

    Community Moderator

    Re: Getting error in bme680 calibration function.

    Hi Sudeep1310,

    The temperature within the package is expected to increase with operation due to the heat dissipated by the gas sensor.  The bias stabiliizes depending on the operating mode and ambient temperature. This sensor heat can be compensated for with the use of the BSEC algorithm. 

    It is however strange that the gas measurement readings are so low. My intial guess is that the sensor might be contaminated and hence suggest reading the  HSMI manual. 

    Regarding the Status flags, it is a logic OR combination of the 3 flags,

    #define BME680_NEW_DATA_MSK    UINT8_C(0x80)
    #define BME680_GASM_VALID_MSK  UINT8_C(0x20)
    #define BME680_HEAT_STAB_MSK   UINT8_C(0x10)

    and hence 0xb0 means that there was a valid gas measurement and the data is new (not a repeat), and the heater was stable. 0xa0 means that the heater was unstable for that measurement, basically signifying that there wasn't sufficient time to heat the gas sensor to the needed temperature. This is pretty common for a cold start and normally observed after a power on reset for the first measurement. 


    Re: Getting error in bme680 calibration function.

    Hello  Kgoveas,

    You are right gas measurement value is so low as I compared with reading taken by same sensor interfaced with arduino board. 


    Temperature in Celsius: 30.04
    Humidity in %: 31.27
    Pressure in hPa: 944.86
    Altitude in Meters: 583.53
    Gas Resistance in Ohms: 16603.89

    I was not seen properly thatswhy I have mentioned wrong  statement. But yes value of Gas resistance getting  with API  as below may be wrong.

    Sample, TimeStamp(ms), Temperature(deg C), Pressure(Pa), Humidity(%), Gas resistance(ohm), Status
    1, 1000, 28.75, 94488.88, 35.88, 5825.59, 0xa0
    2, 1000, 28.98, 94491.52, 35.91, 1831.92, 0xb0
    3, 1000, 29.48, 94483.83, 35.98, 1680.24, 0xb0
    4, 1000, 29.97, 94487.53, 36.05, 1686.79, 0xb0
    5, 1000, 30.32, 94488.09, 36.12, 1692.28, 0xb0
    6, 1000, 30.56, 94490.24, 36.14, 1724.87, 0xb0
    7, 1000, 30.76, 94494.60, 36.15, 1746.91, 0xb0
    8, 1000, 30.94, 94484.99, 36.14, 1765.91, 0xb0
    9, 1000, 31.09, 94492.68, 36.11, 1779.22, 0xb0
    10, 1000, 31.22, 94493.74, 36.07, 1806.44, 0xb0

    I will check once again for all possible cases and let you know. Your suggestion also important to me. So if I need to change anything please suggest. I will give you feedback after testing once again.