This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

PPI to SPIM Task, How to?

Hello,

I am having much fun with nrf52. I'd like to implement SPI read (few bytes) per GPIOTE event over PPI, the source is the GPIO event and the destination task is a SPI read of few specified bytes. The event is currently generated without Interrupt, and this is preferred.

I'd like to use easyDMA on the SPIM end. I have done the easyDMA setup, the MAXCNT, PTR, LIST are all setup register writes are verified correctly.

The issue is I am still missing something, I can not stitch together in my mind the steps needed to setup a READ task for SPI without interrupts to trigger a START Task, also how it looks from PPI to easyDMA. Please help to explain. Would the p_spim->START register contains actually a pointer to a chunk of code? How to best take advantage of the sweet nRF52 features?

I have checked the path over PPI assignment and verified the external event are generated and general routing (from event to task) over PPI is working via a test GPIO output:

err_code = nrf_drv_ppi_channel_assign(ppi_channel1,
	  nrf_drv_gpiote_in_event_addr_get(trigPIN),
	  nrf_drv_gpiote_out_task_addr_get(testOutPin));
	  //nrf_drv_spi_start_task_get(&afeSpi));

Please enlight! Thanks in advance!

FI

Parents Reply Children
No Data
Related