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.

Using DMA to copy between L2SRAM & DDR3 - where to start?

Other Parts Discussed in Thread: MIDAS

Hi,

I would like to use DMA for copying image-data back and forth between DDR3 and a buffer located in L2SRAM on the C6678. For now the program is single-threaded, but once the OpenMP implementation is a bit more stable, we plan to move it to multicore in the next 2-3 months (so it would be great if the design descision would be MC safe).

I had a look at the many different options and I am a bit confused:

- CSL & Register based programming, very low level, probably too hard to get started with
- ACPY3 usually used for memcpy-like (1D, 2D) operations; deprecated
- ECPY; sucessor of ACPY3, from what I have seen largely undocumented
- EDMA3 Low Level Driver: I had a look at the LLD, but all samples from TI are based on a very large and quite complex sample-project located in "ccsv5\edma3_lld_02_11_05_02\packages\ti\sdo\edma3\drv\sample\"

I would use the Low Level Driver, especially as there is an implementation of the old DAT module which does exactly what I am looking for.
However, is EDMA3 really that hard to initialize, so that it requires a whole sample project just to set it up? Are there example projects better suited to my needs based on the LowLevelDriver?

Thank you in advance, Clemens

  • EDMA3 is going to be the most efficient transport of large blocks of data.  Once it's setup, it's easy to maintain.

    I'd take a look at the csl example in the PDK first.  ti\pdk_C6678_X_X_X_XX\packages\ti\csl\example\edma.

    Best Regards,

    Chad

  • Hi Chad,

    I am not sure, maybe ACPY3 or ECPY is enough for me - as both are based on EDMA3. Do you know wether these libraries are multicore-safe? If so, could you please point me to some documentation related to ECPY, as ACPY3 has been deprecated.

    Thank you in advance, Clemens

  • Clemens,

    I'm not familiar w/ ECPY, but I'll ping someone who is to reply to this.

    Best Regards,
    Chad

  • Clemens,

    See http://processors.wiki.ti.com/index.php/Framework_Components_RMAN_Users_Guide to begin with. ECPY details can be found with the module in the Framework Components installation.

    There are general examples of ECPY/RMAN/IRES that are part of the FC package, which are a good starting point. For instance, look at the examples at framework_components_x_xx_xx_xx\examples\ti\sdo\fc\ires\examples\codecs and also at framework_components_x_xx_xx_xx/examples/ti/sdo/fc/rman/examples/dmaXferScratch 

    A more advanced system-level example with multiple codecs on C6678 that leverages RMAN/IRES and ECPY is at http://processors.wiki.ti.com/index.php/MIDAS_Ultrasound_v4.0_Demo with source code at https://gforge.ti.com/gf/download/frsrelease/753/5292/midas_usound_demo4_rel.zip

  • Hi Chad,

           How to do a memcpy using DMA?

    Regards,

    Sohal