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.

TMS320C6748: How do the dma write four times for serializers

Part Number: TMS320C6748

我在调试 mcasp 的edma3 时遇到如下问题:

mcasp手册的“ Transfers through the DMA Port  ”一章中有这样语句话“ if serializers 0, 4, 5, and 7 are set up as active transmitters, the DMA/CPU should write to the XBUF DMA port address four times with data for serializers 0, 4, 5, and 7 upon each transmit data ready event.

我想问一下:对于DMA方式,如何让dma写四次呢?这样保证 0、4、5、7串行器都能获得数据。非常感谢!

  • 用cpu方式很直观就可以写到四个串行器,但是dma方式不知道如何才能正确配置

  • 文档中有下面这段话,通过写XRBUF DMA port address来访问。
    To access through the DMA port, simply have the CPU or DMA access the XRBUF through its DMA port location. See your device specific
    data manual for the exact memory address. Through the DMA port, the DMA/CPU can service all the serializers through a single address. The McASP automatically cycles through the appropriate serializers.

     DMA port address地址在数据手册第146页上。往这个地址里写4次数据,就会依次发送使能的serializer数据。
    Table 6-50. McASP Registers Accessed Through DMA Port
    https://www.ti.com/lit/ds/symlink/tms320c6748.pdf

  • 非常感谢您的解答,我理解您的意思。我也知道是向DMA port address地址写4次,但是我的问题是用DMA怎么写?如果用cpu写是可以很直观地明白,因为xbuf的地址不同,向四个不同地址写就行了,但是DMA方式的写就不是很直观能够理解的,我只知道写,但不知道怎么写。

  • 不知是否方便提供一个例程?

  • 用DMA去配置寄存器的话,要设置DMA Param,起始地址里放要配置的值,目的地址设成DMA port address,具体可以看EDMA章节。

    因为只是寄存器配置,建议直接往地址里写数值就可以了,不会占用太多的cpu。

  • 您好,我还是没能成功实现MCASP两个串行器与EDMA的结合,请问您这里能找到类似的例程么