Question
Syncing USART/DMA RX
Posted on May 20, 2013 at 22:38
I am using a STM32F407 and have set it up for using USART with DMA.
I have some problems with the RX part. What is the best way to sync the enabling of the RX DMA with the remote transmitter? If I enable it in the middle of a transmission, only part of the message will fill the buffer and I will get the TC interrupt during transmission of next message. Or if I enable it when the transmitter is idle but some garbage is clocked in, for instance a break symbol when the transmitter is reset, I will get one byte offset in my buffer and the interrupt will fire too early.What is the best way to tackle this? #usart-dma #stm32f4-dma-usart