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

I2C driver with soft device

hello there i want to send output of i2C sensor on ble. but how to add i2c driver for ble application???

Parents Reply
  • #define TWI0_ENABLED 0

    #if (TWI0_ENABLED == 1)
    #define TWI0_CONFIG_FREQUENCY    NRF_TWI_FREQ_100K
    #define TWI0_CONFIG_SCL          0
    #define TWI0_CONFIG_SDA          1
    #define TWI0_CONFIG_IRQ_PRIORITY APP_IRQ_PRIORITY_LOW
    
    #define TWI0_INSTANCE_INDEX      0
    #endif
    
    #define TWI1_ENABLED 0
    
    #if (TWI1_ENABLED == 1)
    #define TWI1_CONFIG_FREQUENCY    NRF_TWI_FREQ_100K
    #define TWI1_CONFIG_SCL          0
    #define TWI1_CONFIG_SDA          1
    #define TWI1_CONFIG_IRQ_PRIORITY APP_IRQ_PRIORITY_LOW
    
    #define TWI1_INSTANCE_INDEX      (TWI0_ENABLED)
    #endif
    
    #define TWI_COUNT                (TWI0_ENABLED+TWI1_ENABLED)
    
Children
No Data
Related