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

Is there no I2C/TWI peripheral example in the SDK documentation?

As I run through the examples for the nRF51 S110 SDK, I'm not seeing anything for communicating with a sensor over I2C.

On a secondary note, since I have the option to talk to this sensor over SPI vs I2C, is SPI the recommended route to use for an nRF51822?

There are lots of tradeoffs between SPI and I2C in general. I'm just looking to understand tradeoffs between them in the context of an nRF51822. Is something unreliable with the TWI hardware peripheral? Will it will soon no longer be available? Will I generally get lower power consumption if I use SPI instead? Will there be less blocking code is I use SPI instead? etc.

Parents Reply
  • I'm having a lot of trouble using TWI with the S110 softdevice and v8.0 sdk. Specifically, the softdevice cannot find nrf_delay.h. The workaround has been to not include the twi while compiling the softdevice, then include it when compiling application code. I understand there isn't a need for TWI in the sdk examples since not TWI slave is on the new board, but, it seems like the consequence is inadvertently dropping TWI support entirely...

Children
No Data
Related