Quantcast
Channel: Forums - Recent Threads
Viewing all articles
Browse latest Browse all 262198

CC3200: Question about SPI multi word transmission performance

$
0
0

Part Number:CC3200

I'm seeing a larger than expected delay in between words on a multi word SPI transmission.  I'm transferring thirty two 16-bit transmissions per SPITransfer.  For each 16-bit transfer, the SPIEN is active low for 824nS, then goes high between words for 900nS.  This is the code for testing:

    // Test non TI-RTOS SPI performance
    unsigned short transmitBuffer[256];
    unsigned short receiveBuffer[256];
    PinMuxConfig();
    MAP_PRCMPeripheralClkEnable(PRCM_GSPI,PRCM_RUN_MODE_CLK);
    MAP_PRCMPeripheralReset(PRCM_GSPI);
    MAP_SPIReset(GSPI_BASE);
    MAP_SPIConfigSetExpClk(GSPI_BASE,MAP_PRCMPeripheralClockGet(PRCM_GSPI),
                     20000000,SPI_MODE_MASTER,SPI_SUB_MODE_0,
                     (SPI_HW_CTRL_CS |
                     SPI_4PIN_MODE |
                     SPI_TURBO_ON |
                     SPI_CS_ACTIVELOW |
                     SPI_WL_16));
    MAP_SPIEnable(GSPI_BASE);
    while(1){
    MAP_SPITransfer(GSPI_BASE,(unsigned char *)transmitBuffer,(unsigned char *)receiveBuffer,64,SPI_CS_ENABLE|SPI_CS_DISABLE);
    }

For this attached SPI device, SPIEN must go high between each transfer.  Currently it takes less time to send the 16-bits than it does to get the SPIEN back low for the next transfer.  Is there anything I can do to reduce the between word delay?  Does using the uDMA help?  

Thanks,

Alex


Viewing all articles
Browse latest Browse all 262198

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>