Because of the holidays, TI E2E™ design support forum responses will be delayed from Dec. 25 through Jan. 2. Thank you for your patience.

This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[FAQ] PROCESSOR-SDK-J721E: How to use TR for transfers in McSPI, instead of packet descriptors?

Part Number: PROCESSOR-SDK-J721E

By default, McSPI/SPI Drivers in PSDKRA uses packet descriptors for transferring or for receiving data to/from the SPI slave device. Sometimes it might require to use TR descriptors, because TR supports additional functionalities like event based triggers, interrupts on various icnts. This article descriptors how TR can be used for SPI driver in PSDKRA. In general, it can also be used in other driver, like UART, where packed descriptor is used. 

  • Attached patch enables support for TR descriptors in the McSPI driver. This patch can be applied on the folder ti-processor-sdk-rtos-j721e-evm-08_06_00_12\pdk_jacinto_08_06_00_31.

    /cfs-file/__key/communityserver-discussions-components-files/791/McSPI_5F00_Use_5F00_TR.patch

    • This patch adds additional parameters in the SPI DMA information data structure. It adds additional flag useTr in the DMA information structure, which, when enabled, uses TR descriptor for the data transfer. 
    • When this flag is enabled, the driver expects the application to provide memory the TRPD descriptors in the pointers txTrpdMem and rxTrpdMem. It is assumed here that the this memory is allocated by the core on which this driver is running.. 
    • The lowest increment count in the TR is assigned to data size of the SPI, ie 8bits, 16bits or 32bits and accordingly, the total transfer size must be aligned to this data size. 
    • When this flag is set, there is no need to provide memory pointers in txHpdMem and rxHpdMem.

    Regards,

    Brijesh