spi rom master with dma rom

Discussion created by lpcware Employee on Jun 15, 2016
Content originally posted in LPCWare by DAMEK on Fri Aug 29 04:29:24 MST 2014
Hey team,

i want to share my progress with you.
the attached file is an working spi transfer with dma based on rom drivers and sleepmode (so i know the work is without the cpu).

i hope it helps to reduce progresstime   :bigsmile:

my question is how to eliminate the second dma irq / callback?  when i clear the callback for tx, the rx callback fires normal but the cpu don't wakeup..
if tx and rx callbacks are set, the cpu wakeup..

and my second question:
if i want to pingpong / stream in via spi by software trigger (pininterrupt and LPC_SPID_API->spi_master_transfer()) - is it posible to reduce the SPI_DMA_REQ_T callback to:

LPC_DMAD_API->dma_init(dma_handle, &chn, &tsk1); // for rx
LPC_DMAD_API->dma_init(dma_handle, &chn, &tsk2); // for tx

to reduce downtime for the steam / cpu working?

greatings and thanks

Original Attachment has been moved to: spi_rom_dma_2.c.zip