Bosch Sensortec Community

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

    BME680 I2C interface reading Erroneous Temp, Pressure and Humidity Data

    BME680 I2C interface reading Erroneous Temp, Pressure and Humidity Data

    nikhil1429
    New Poster

    We have interfaces BME680 to an external host over I2C Interface and e are using BME680 driver api files.

    We are able to read CHIP ID as 0x61 0r 97 successfully which mean our I2c inteface is working fine. But STatus register never shws new data available, alwys reads 0x00

    below is the Log of I2c data:

    [INF] : Write Addr : 77 Reg Addr : e0 Size : 1 /* Soft Reset AS per SAmple Driver COde bt Writing B6 to 0xE0 Resiter */
    Write Data : b6

    [INF] : Read Addr : 77 Reg : d0, Size: 1 /* Reading CHip ID from Register 0xD0 */
    Read Data : 61

    [INF] : Read Addr : 77 Reg : 89, Size: 19 /* Reading Coefficients Startign from Register 0x89 25 bytes in length */
    user: Read Data : 0 f4 67 3 f0 6f 8d cb d7 58 0 f 20 82 ff 28 1e 0 0 b0 f6 70 f5 1e b2

    [INF] : Read Addr : 77 Reg : e1, Size: 10 /* Reading Coefficients Startign from Register 0xE1 16 bytes in length */
    Read Data : 3f c5 2d 0 2d 14 78 9c 3b 65 c7 f3 c6 12 aa 0

    [INF] : Read Addr : 77 Reg : 2, Size: 1 /* Reading Res Heat Range Register 0x02 */
    Read Data : 16

    [INF] : Read Addr : 77 Reg : 0, Size: 1 /* Reading Res Heat Value Register 0x00 */
    Read Data : 2e

    [INF] : Read Addr : 77 Reg : 4, Size: 1 /* Reading range switching error Register 0x04 */
    Read Data : 33

    [INF] : Write Addr : 77 Reg Addr : 5a Size : 1 /* Writing gas heat Res 0x5A to 320 C (0x6f is caluclated by driver library) */
    Write Data : 6f

    [INF] : Write Addr : 77 Reg Addr : 64 Size : 1 /* Writing heat duration Reg 0x64 to 150 ms (0x65 is caluclated by driver library) */
    Write Data : 65

    [INF] : Read Addr : 77 Reg : 74, Size: 1 /* Readign Register 0x74 */
    Read Data : 8c
    [INF] : Read Addr : 77 Reg : 75, Size: 1 /* Reading Register 0x75 */
    Read Data : 8
    [INF] : Read Addr : 77 Reg : 74, Size: 1 /* Reading Register 0x74 */
    Read Data : 8c
    [INF] : Read Addr : 77 Reg : 72, Size: 1 /* Reading Register 0x72 */
    Read Data : 2
    [INF] : Read Addr : 77 Reg : 71, Size: 1 /* Reading Register 0x71 */
    Read Data : 10

    [INF] : Write Addr : 77 Reg Addr : 75 Size : 1 /* Writing Register 0x75 */
    Write Data : 8
    [INF] : Write Addr : 77 Reg Addr : 74 Size : 1 /* Writing Register 0x74 */
    Write Data : 8c
    [INF] : Write Addr : 77 Reg Addr : 72 Size : 1 /* Writing Register 0x72 */
    Write Data : 2
    [INF] : Write Addr : 77 Reg Addr : 71 Size : 1 /* Writing Register 0x71 */
    Write Data : 10

    [INF] : Read Addr : 77 Reg : 74, Size: 1 /* reading Register 0x74 */
    Read Data : 8c
    [INF] : Write Addr : 77 Reg Addr : 74 Size : 1 /* Setting Forced POwer Mode in in 0x74 */
    Write Data : 8d

    [INF] : Read Addr : 77 Reg : 1d, Size: f /* New Data Status & Adc values */
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [EVT] :T: -167.06 degC, P: 0.00 hPa, H 268435.47 %rH /* Error */

    [INF] : Read Addr : 77 Reg : 74, Size: 1
    Read Data : 8c
    [INF] : Write Addr : 77 Reg Addr : 74 Size : 1
    Write Data : 8d

    [INF] : Reg Read Addr : 77 Reg : 71, Data : 10
    [INF] : Reg Read Addr : 77 Reg : 72, Data : 2
    [INF] : Reg Read Addr : 77 Reg : 74, Data : 8c
    [INF] : Reg Read Addr : 77 Reg : 75, Data : 8

    [EVT] :BME680 read

    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [EVT] :T: -167.06 degC, P: 0.00 hPa, H 268435.47 %rH

    [INF] : Read Addr : 77 Reg : 74, Size: 1
    [INF] : Received 0, Current State 2 Change state to 3
    Read Data : 8c
    [INF] : Write Addr : 77 Reg Addr : 74 Size : 1
    Write Data : 8d

    [INF] : Reg Read Addr : 77 Reg : 71, Data : 10
    [INF] : Reg Read Addr : 77 Reg : 72, Data : 2
    [INF] : Reg Read Addr : 77 Reg : 74, Data : 8c
    [INF] : Reg Read Addr : 77 Reg : 75, Data : 8

    [EVT] :BME680 read

    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [EVT] :T: -167.06 degC, P: 0.00 hPa, H 268435.47 %rH

    [INF] : Read Addr : 77 Reg : 74, Size: 1
    Read Data : 8c
    [INF] : Write Addr : 77 Reg Addr : 74 Size : 1
    Write Data : 8d

    [INF] : Reg Read Addr : 77 Reg : 71, Data : 10
    [INF] : Reg Read Addr : 77 Reg : 72, Data : 2
    [INF] : Reg Read Addr : 77 Reg : 74, Data : 8c
    [INF] : Reg Read Addr : 77 Reg : 75, Data : 8

    [EVT] :BME680 read

    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [INF] : Read Addr : 77 Reg : 1d, Size: f
    Read Data : 0 0 80 0 0 80 0 0 80 0 80 0 0 0 4
    [EVT] :T: -167.06 degC, P: 0.00 hPa, H 268435.47 %rH

    1 REPLY 1

    BSTRobin
    Community Moderator
    Community Moderator

    Hello ,

    I setuped a SW demo and tested on STM32, status was not 0x00 after reading 0x1d register.

    This is my log:

    status=0x80
    T: 31.19 degC, P: 1017.66 hPa, H 47.46 %rH , meas_period=183, G: 1095160 ohms
    status=0x80
    T: 31.19 degC, P: 1017.64 hPa, H 47.49 %rH , meas_period=183, G: 1098765 ohms
    status=0x80
    T: 31.19 degC, P: 1017.64 hPa, H 47.47 %rH , meas_period=183, G: 1096960 ohms
    status=0x80
    T: 31.19 degC, P: 1017.64 hPa, H 47.47 %rH , meas_period=183, G: 1108804 ohms
    status=0x80
    T: 31.19 degC, P: 1017.64 hPa, H 47.47 %rH , meas_period=183, G: 1098765 ohms
    status=0x80
    T: 31.19 degC, P: 1017.64 hPa, H 47.48 %rH , meas_period=183, G: 1107884 ohms
    status=0x80
    T: 31.19 degC, P: 1017.64 hPa, H 47.49 %rH , meas_period=183, G: 1101485 ohms
    status=0x80
    T: 31.19 degC, P: 1017.64 hPa, H 47.49 %rH , meas_period=183, G: 1100577 ohms

     

    I also uploaded my example code for your reference.

    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