Bosch Sensortec Community

    cancel
    Showing results for 
    Search instead for 
    Did you mean: 

    BMI270 read of CHIP_ID fails occasionally

    BMI270 read of CHIP_ID fails occasionally

    bront
    Member

    I have a custom board leveraging the official BMI270 driver and I'm having inconsistent results when initializing the chip. I'm using the official Github based driver. On startup a dummy read of CHIP_ID is performed and the BMI270 does not reply. This should put it in SPI mode per the datasheet. At least 450us later a real read of CHIP_ID is performed with mixed results. When using a SPI clock of 6MHz (CPOL=CPHA=0) it responds, but the bits are often shifted or wrong altogether about 50% of the time. With a 1.5 MHz SPI clock (CPOL=CPHA=0) this initialization works every time. From the datasheet it states that the device powers up in APS mode. Does this require a slower clock until it's turned off? Should it work with up to 10 MHz every time. 

    3 REPLIES 3

    Minhwan
    Community Moderator
    Community Moderator

    Hi Bront, 

     

    Are you using our BMI270 API? 

    https://github.com/BoschSensortec/BMI270-Sensor-API/

    If you are doing in register level programming, there are many things you have to check manually. 

    You just need to change communication part in common.c/h. 

    Therefore, I recommend to use our github API. 

    If not, for initial part, you have to check 4.4 POR and device initialization in our datasheet. 

    https://www.bosch-sensortec.com/media/boschsensortec/downloads/datasheets/bst-bmi270-ds000.pdf

    Also, you need to check last part of 4.5 and 6.4 our SPI spec. 

    For example, you need to wait over 450us if you want to do write access in suspend mode, low power mode. 

    Thank you. 

     

    Yes, I'm using the latest API that you reference. The process I described is what happens early in your driver.

    I noticed the chip identifiecation is the following. Can you please confirm this is a legitimate chip?

    5N-3CN

    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