Part Number: MSP432P401R
Hi,
i'm trying to communicate to a Cypress FRAM with help of DMA over the SPI. Writing data seems to work fine. Reading data via ScatterGather and a task list is my problem.
I first need to send the opcode to read followed by the address. Then the data is presented as long as CS is active an there are clock-cycles. I'm trying to setup a task list to receive the data but it does not work.
Here is my tasklist
DMA_ControlTable SPI_FRAM_ReadLine[2] = { //Task 1 READ + Adresse senden DMA_TaskStructEntry(10, UDMA_SIZE_8, UDMA_SRC_INC_8, &ui_fram_tx_buf[0], UDMA_DST_INC_NONE, &EUSCI_B2_SPI->TXBUF, UDMA_ARB_1, (UDMA_MODE_PER_SCATTER_GATHER+UDMA_MODE_ALT_SELECT)), DMA_TaskStructEntry(10, UDMA_SIZE_8, UDMA_SRC_INC_NONE, &EUSCI_B2_SPI->RXBUF, UDMA_DST_INC_8, &ui_fram_rx_buf[0], UDMA_ARB_1, (UDMA_MODE_BASIC)) };
And here the start of DMA:
MAP_DMA_setChannelScatterGather(DMA_CH4_EUSCIB2TX0,2,(void*)&SPI_FRAM_ReadLine[0],1); MAP_DMA_clearInterruptFlag(DMA_CH4_EUSCIB2TX0 & 0x0F); MAP_DMA_enableChannel(4);
Is it the correct channel that i'm activating? Is the task list correct ?