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.

sci DMA变长方式收发数据



大家好,最近在研究在TMA570LS上用串口DMA传输方式收发数据,看前辈们用DMA传输都是定长传输的,DMA需要定长才能产生接收或发送中断,我想问的是如何接收或发送可变长度的数据呢?

  • 我查了一下别人都是怎么做的:通过中断的形式对定时器清零,这样不会引起定时器中断,当没有数据传输的时候超时会引起定时器中断这样就可以在定时器中断实现传输接收的检测。

    不过都是其他单片机的例子

    http://no001.blog.51cto.com/1142339/902155/

    可以参考一下这个思路