Bosch Sensortec Community

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

    BME280: Reading Temperature Skipped

    BME280: Reading Temperature Skipped

    ttuser
    Member

    Hello,

    I have a BME280 device and read the data out with the Linux kernel module bmp280-i2c. From time to time, I get the message "reading temperature skipped", i.e. the device sends the value 0x80000. It happens irregularly. If it happens, this error arises several times within a period of some seconds, then it takes few hours until the error comes next time.

    In the data sheet it is written that temperature read out can be skipped by setting the oversampling ratio to zero and then the device sends the 0x80000 value. My oversampling ratio for the temperature is 16 and I don't change it at all. I have checked that the oversampling ratio is not zero when the 0x80000 value is sent.

    What are possible reasons that the device sends this value?

    9 REPLIES 9

    FAE_CA1
    Community Moderator
    Community Moderator

    Hi,

    Thank you. Please send a private message to me with your company email address. I will introduce you to our local FAE for further support.

    Thanks.

    Hi,

    I have the exact same issue. What was the solution?

    It is not clear from the data sheet if:

    1. a value of 0x800000 always means the reading was skipped (as the kernel driver assumes)
    2. is a valid reading if the measurement is not being skipped and is the value read if it is being skipped

    Could you confirm which answer is correct so I can either fix the kernel driver or need further support to understand why readings are being skipped.

    I am based in the UK

    Thanks

    FAE_CA1
    Community Moderator
    Community Moderator

    Hi,

    If the sensor is continuously running in normal mode, 'skipped values' (0x80000) should not be observed in the data registers anymore as soon as one conversion was successfully completed, since the previous value with remained cached if the register is over-read.

    In my opinion, the most probable root causes for the behavior on the log could be that:

    • The OS/driver triggers configuration updates/changes to the sensor. If the sensor is at least temporarily switched to sleep mode, or the ‘osrs_t’ (temperature oversampling) settings is temporarily set to ‘0’, then the temperature ADC register will be reset to 'skipped values' (0x80000) until the first measurement/conversion cycle is completed,
    • The OS/driver triggers a hard- or soft-reset of the sensor from time to time. Again here booting from sleep mode would reset the temperature ADC registers to 0x80000 until the first conversion is completed.

    Please let us know how it goes.

    Thanks.

    Thanks for your reply.

    Can Iconfirm you are saying it is not possible for the BME280 to read 0x800000 for temperature if the temperature has been successfully read by the chip? Even if the temperature current temperature would give this value?

    Looking at a log of the data on the I2C bus neither of your suggestions seem to fit the data I have recorded. The BME280 is always on in our design so is only hard reset on a system power cycle. In the log below from you can see a successful read of 0x77FF10, followed by the "skipped" value of 0x800000 1 second later with several retries as this value is currently considered bad. Then finally 1 second later a successful read of 0x800050.

    To me this looks like option 2 of the data sheet interpretations I gave above with the value of 0x800000 being valid (it corresponds to a temperature of 23.34 C using the  compenstation formulat in the linux driver).

    The ctrl_meas register (0xF4) is set to 0x57 when the driver first loads. This corresponds to osrs_t = 010 2x oversampling and osrs_p = 101 16x oversampling, normal mode.
    The config register is set once to 0x08, t_standby 0.5ms, filter coefficient 4 

    Time [s] Decoded Protocol Result
    -1.00761985Setup Write to [0x77] + ACK
    -1.006970250xFA + ACK
    -1.0062784Setup Read to [0x77] + ACK
    -1.00562690x7F + ACK
    -1.00495680xFF + ACK
    -1.004805750x10 + NAK
    -1.00446535Setup Write to [0x77] + ACK
    -1.00431490xFD + ACK
    -1.0041434Setup Read to [0x77] + ACK
    -1.00399170x65 + ACK
    -1.003840050x7D + NAK
    -1.0034806Setup Write to [0x77] + ACK
    -1.00333020xFA + ACK
    -1.0031587Setup Read to [0x77] + ACK
    -1.003007650x7F + ACK
    -1.00285790xFF + ACK
    -1.00270750x10 + NAK
    -1.0023701Setup Write to [0x77] + ACK
    -1.00221970xF7 + ACK
    -1.00204815Setup Read to [0x77] + ACK
    -1.00189650x4F + ACK
    -1.00169490x3A + ACK
    -1.001542550xF0 + NAK
    -0.00679885Setup Write to [0x77] + ACK
    -0.006648450xFA + ACK
    -0.00647755Setup Read to [0x77] + ACK
    -0.00632650x80 + ACK
    -0.006176750x00 + ACK
    -0.006026350x00 + NAK
    0.00160155Setup Write to [0x77] + ACK
    0.00178010xFA + ACK
    0.00200155Setup Read to [0x77] + ACK
    0.002155150x80 + ACK
    0.00230810x00 + ACK
    0.002459150x00 + NAK
    0.0109354Setup Write to [0x77] + ACK
    0.01110370xFA + ACK
    0.0112317Setup Read to [0x77] + ACK
    0.011334750x80 + ACK
    0.01143650x00 + ACK
    0.011538250x00 + NAK
    0.01936935Setup Write to [0x77] + ACK
    0.019527450xFA + ACK
    0.01970025Setup Read to [0x77] + ACK
    0.01985190x80 + ACK
    0.02000170x00 + ACK
    0.020157850x00 + NAK
    0.9924992Setup Write to [0x77] + ACK
    0.99260160xFA + ACK
    0.99272385Setup Read to [0x77] + ACK
    0.99282560x80 + ACK
    0.99292610x00 + ACK
    0.993027850x50 + NAK
    0.993318Setup Write to [0x77] + ACK
    0.99341980xFD + ACK
    0.99354265Setup Read to [0x77] + ACK
    0.99364440x65 + ACK
    0.99374620x70 + NAK
    0.99405475Setup Write to [0x77] + ACK
    0.99415650xFA + ACK
    0.99427875Setup Read to [0x77] + ACK
    0.99438050x80 + ACK
    0.994481650x00 + ACK
    0.99458340x50 + NAK
    0.9948706Setup Write to [0x77] + ACK
    0.994972350xF7 + ACK
    0.9950946Setup Read to [0x77] + ACK
    0.995196350x4F + ACK
    0.995297450x3A + ACK
    0.99539920xC0 + NAK

    FAE_CA1
    Community Moderator
    Community Moderator

    Hi,

    Please try the attached "bme280_v1.3.1_Linux_driver.zip" to see if the issue can be resolved or not.

    Thanks.

    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