Re:UART Tx Interrupt
One way that may help, but not get you exactly where you want to be, is to use the TX FIFO level interrupt. If you're streaming data, you could configure the transmit FIFO to generate an interrupt at 1/8 full (or less) which is 2 bytes, and then start the system by putting 3 bytes in the FIFO. After 1 byte is transmitted, an interrupt should be generated due to the FIFO level condition. Put another byte in the FIFO in the interrupt handler.
The downside is that if you don't have any outbound data for the transmit stream, the last two bytes are transmitted without interrupt. I picked the 1/8 FIFO level to minimize the missing interrupts.
Credit LMI Brian for the starting idea.
login or register to reply
|