SPRUIY4B February 2023 – May 2024 TMS320F2800152-Q1 , TMS320F2800153-Q1 , TMS320F2800154-Q1 , TMS320F2800155 , TMS320F2800155-Q1 , TMS320F2800156-Q1 , TMS320F2800157 , TMS320F2800157-Q1
The SCI receiver and transmitter can be interrupt controlled. The SCICTL2 register has one flag bit (TXRDY) that indicates active interrupt conditions, and the SCIRXST register has two interrupt flag bits (RXRDY and BRKDT), plus the RX ERROR interrupt flag that is a logical-OR of the FE, OE, BRKDT, and PE conditions. The transmitter and receiver have separate interrupt-enable bits. When not enabled, the interrupts are not asserted; however, the condition flags remain active, reflecting transmission and receipt status.
The SCI has independent peripheral interrupt vectors for the receiver and transmitter. Peripheral interrupt requests can be either high priority or low priority. This is indicated by the priority bits that are output from the peripheral to the PIE controller. When both RX and TX interrupt requests are made at the same priority level, the receiver always has higher priority than the transmitter, reducing the possibility of receiver overrun.
The operation of peripheral interrupts is described in the Peripheral Interrupts section of the System Control and Interrupts chapter.
SCI Module Interrupt Reaction Time - Occasional BRKDT or other errors such as FE/PE being triggered can occur if there are tight timings occurring in the application.
Interrupts are not triggered until approximately 7/8 of the stop bit has been detected (approximately 0.875 bit time). Actual value of this delay before ISR entry is: ((7*BAUD_CLK_PERIOD)/8+3*SYSCLK_PERIOD).
The SCI does not begin reading additional bits/characters until the RX ISR completes, so complete the ISR before the next byte's start bit begins. This leaves approximately 1/8 bit time (approximately 0.125 bit time) to complete the entire ISR, regardless of interrupt cause.
If the ISR is not completed before the beginning of the next start bit (before the RX line goes low again), the SCI module begins reading the start bit late in the wrong location and therefore may read all bits incorrectly until the next correctly aligned start bit (when ISR has sufficient time to process before a start bit again).
Recommended methods for avoiding errors (to accommodate for the 0.875 bit time required for ISR to begin):