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

TWI recover from timeout

I am using the TWI module in master mode, with sdk 10. I purposely create an error situation, in which the TWI gets stuck and keeps returning NRF_ERROR_BUSY every time I try to initiate a transfer. How may the device recover from this block? I have tried uninit/init the TWI module, with no success.

Parents Reply
  • Once the error is introduced (pull SDA/SCL to GND) and detected, the TWI module is re-initialized (including the above mentioned flag clear) and the following happens:

    • nrf_drv_twi_tx()/nrf_drv_twi_rx() returns NRF_SUCCESS
    • However, SDA/SCL lines have no transitions, they are completely still
    • nrf_drv_twi_int_handler() is never called again

    Porting to SDK11 is not an option as I need the functionalities offered specifically by SDK10 (S110)

Children
No Data
Related