2016-01-07 07:05 AM
2016-01-07 10:17 AM
The buffer values are 32 bit. and the spi data register is 16 bit.
I don't think the SPI/DMA care what form the data is for the C compiler, it's just words in memory. I'd probably lean to doing 16-bit memory accesses, double the transfer count, and let it pull the 32-bit data as a pair of 16-bit half-words.the dma did not work.What does that mean? Transferred the wrong data, threw and error?2016-01-07 10:36 AM
DMA_InitStructure.DMA_Memory0BaseAddr = (uint32_t)(&outpuf_pfc) ;
Where is output_pfc defined? Is it word aligned and the same size as buffer_count?2016-01-08 03:22 AM
clive, i can do how you suggested.
what you mean by I don't think the SPI/DMA care what form the data is for the C compiler, it's just words in memory.2016-01-08 04:42 AM
Packing and unpacking (converting 32 bit memory to two 16-bit SPI outputs) is performed in the DMA hardware using the DMA FIFO buffer. AS long as memory is aligned to the declared boundary (32 bit in this case) it won't matter what compiler you are using, memory location is the same.