This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Interfacing between nRF52840 and BME680: I2C or SPI

Hi! Currently I have a nrf52840 devkit hooked up to an SD-card for storage through FATFS (using SPI). I would like to add a BME680 environment-sensor to the board and have ordered a breakout-board. I was wondering what the recommended way to go was of hooking it up to the nrf52840.

Could I use it simultaneously with the SD-card using the same SPI instance, would I go for a separate SPI instance or would I go for I2C? 

Note: I'm also planning to interface with a VEML6030 light-sensor which does only seem to interface through I2C.

Parents
  • This really has nothing to do with the nRF chip: the BME680  and the SD-Card - like any other external devices - neither know nor care what microcontroller you use.

    So it's really just a question of whether it's ever wise to share an SPI connection between an SD-Card and other devices.

    I would suggest that it's best avoided - so go for a separate SPI connection, or use I2C.

    EDIT

    For some of the issues to consider, see:

    http://elm-chan.org/docs/mmc/mmc_e.html#spibus

    There may well be others 

    Debugging SD-Card issues can be hard enough just on its own - you don't want to be adding extra complications!

    - hence my recommendation is, "just don't do it!"

Reply
  • This really has nothing to do with the nRF chip: the BME680  and the SD-Card - like any other external devices - neither know nor care what microcontroller you use.

    So it's really just a question of whether it's ever wise to share an SPI connection between an SD-Card and other devices.

    I would suggest that it's best avoided - so go for a separate SPI connection, or use I2C.

    EDIT

    For some of the issues to consider, see:

    http://elm-chan.org/docs/mmc/mmc_e.html#spibus

    There may well be others 

    Debugging SD-Card issues can be hard enough just on its own - you don't want to be adding extra complications!

    - hence my recommendation is, "just don't do it!"

Children
No Data
Related