AnsweredAssumed Answered

How do I get the number of bytes read from UART DMA?

Question asked by tec on Oct 19, 2009
Latest reply on Oct 21, 2009 by jeyanthi.jegadeesan

Is there a way to read a register and get the number of bytes that the UART DMA has in the receive buffer. I have multiple message formats that I am reading and they are different sizes. I have headers on the messages so I know which message I receive when I get into the uart isr. I would like to tell the UART DMA engine that I want any size message instead of assigning a size to pCUART0RX.

 

 

// UART0 receiver is configured in DMA mode
(*pUART0RXCTL) = 0;      // clears the UART receive control register

 

*pIIUART0RX = (unsigned int) &uart_receive_message[0]; // address for DMA
*pIMUART0RX = 1; // modifier
*pCUART0RX = UART_receive_count; // count

Outcomes