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

How to use TWI interface at softdevice's BLE stack

I have to use TWI(I2C) interface to configure sensor. Now ,i reference "nRFready Smart Remote " project drv_gyro_mpu6050.c . and change the register number ' configure.(drv_gyro_xxx.c and hal_twi.c)

if i want to add my project , how to add drv_gyro_xxx.c and control ?

ble_app_pwr_.zip

Parents
  • Thx for your reply. I miss the keil uVision project file attach file. the question is : 1. I want to know how to add the peripherals(uart' spi 'rtc and Twi) on BLe. At the hal_twi.c is about the TWI peripheral file.it is use PPI controller by event.

    Whether other peripheral( uart ' spi' rtc and twi) is same operator? can you give me more sample for me ?

    2.at attach file(ble_app_uart_hasbro_rel1_715.7z) file. drv_gyro_mba222E.c mba222E_register_read(..) function. the line number 91 "transfer_succeeded = hal_twi_transfer(s_device_address, &address, 1, TWI_DONT_ISSUE_STOP);" my program always block there, and i have to fix to transfer_succeeded = hal_twi_transfer(s_device_address, &address, 1, TWI_ISSUE_STOP); why i have to change the TWI_ISSUE_STOP, it mean release the bus ?

    ble_app_uart_hasbro_rel1_715.zip

Reply
  • Thx for your reply. I miss the keil uVision project file attach file. the question is : 1. I want to know how to add the peripherals(uart' spi 'rtc and Twi) on BLe. At the hal_twi.c is about the TWI peripheral file.it is use PPI controller by event.

    Whether other peripheral( uart ' spi' rtc and twi) is same operator? can you give me more sample for me ?

    2.at attach file(ble_app_uart_hasbro_rel1_715.7z) file. drv_gyro_mba222E.c mba222E_register_read(..) function. the line number 91 "transfer_succeeded = hal_twi_transfer(s_device_address, &address, 1, TWI_DONT_ISSUE_STOP);" my program always block there, and i have to fix to transfer_succeeded = hal_twi_transfer(s_device_address, &address, 1, TWI_ISSUE_STOP); why i have to change the TWI_ISSUE_STOP, it mean release the bus ?

    ble_app_uart_hasbro_rel1_715.zip

Children
No Data
Related