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

PPI on TWI instance 1 not working

I have adapted the "nrf52-mpu-easydma-using-timers-and-drivers" project from Github that I saw referenced in another post and have successfully modified it to work with my A/D converter on TWI instance 0.  However, I have implemented a virtual "ditto" of this design on TWI instance 1 and the TWI transfers never happen.  I can tell from the debug terminal that all 4 of the PPI channels appear to be set up properly (channels 0 - 3, 2 channels for each TWI instance) and have tested to confirm that the timer instance that should generate the TWI transfers is indeed triggering at the desired interval (tested by temporarily enabling the timer handler and toggling a GPIO pin).  I can share the code on a private ticket if needed, but I first want to confirm that this should be capable of working on two TWI instances.  Since they aren't on the same bus, I would have thought that this should be ok.  I appreciate any feedback/assistance.

UpdateI forgot to mention I'm using SDK 15.2 (was being used by one of our partners, so we're staying aligned) and SES 3.40, just in case that is relevant.  Also, I know the TWI instance 1 is set up properly because the init routine performs a proper tx/rx to configure the I2C accelerometer on that bus.

Parents
  • I'm finding some related issues to using easyDMA / PPI with multiple devices on the same TWI bus (different problem with the same project).  From this thread I was thinking that I could use PPI with two slaves on one bus and just know that the RAM buffer would have alternating data, but the transfer sequence update (to update the slave address) blows away the RAM buffer, so I never get more than one sample of data in the buffer.  Is there a way to implement this that doesn't involve reloading the transfer sequence?  I can put this on a different ticket if you prefer, but I was suspecting that there may be enough in common to keep these issues together.

Reply
  • I'm finding some related issues to using easyDMA / PPI with multiple devices on the same TWI bus (different problem with the same project).  From this thread I was thinking that I could use PPI with two slaves on one bus and just know that the RAM buffer would have alternating data, but the transfer sequence update (to update the slave address) blows away the RAM buffer, so I never get more than one sample of data in the buffer.  Is there a way to implement this that doesn't involve reloading the transfer sequence?  I can put this on a different ticket if you prefer, but I was suspecting that there may be enough in common to keep these issues together.

Children
No Data
Related