Functional Description
24.3.2.2 Interrupt Events in Master Mode
In master mode, the interrupt events related to the transmitter register state are TX_empty and
TX_underflow. The interrupt event related to the receiver register state is RX_full.
24.3.2.2.1 TX_empty
The event TX_empty is activated when a channel is enabled and its transmitter register becomes empty
(transient event). Enabling channel automatically raises this event, except for the Master receive only
mode. (See
). When the FIFO buffer is enabled (MCSPI_CH(I)CONF[FFEW] set to 1), the
TX_empty is asserted as soon as there is enough space in the buffer to write a number of bytes defined
by MCSPI_XFERLEVEL[AEL].
Transmitter register must be loaded to remove the source of the interrupt and the TX_empty interrupt
status bit must be cleared for interrupt line de-assertion (if event enabled as interrupt source) . (See
).
When FIFO is enabled, no new TX_empty event will be asserted as soon as CPU has not performed the
number of write into transmitter register defined by MCSPI_XFERLEVEL[AEL]. It is the responsibility of
CPU to perform the right number of writes.
24.3.2.2.2 TX_underflow
The event TX_underflow is activated when the channel is enabled and if the transmitter register or FIFO is
empty (not updated with new data) at the time of shift register assignment.
The TX_underflow is a harmless warning in master mode.
To avoid having TX_underflow event at the beginning of a transmission, the event TX_underflow is not
activated when no data has been loaded into the transmitter register since channel has been enabled.
To avoid having a TX_underflow event, the Transmit Register (MCSPI_TX(i)) should be loaded as
infrequently as possible.
TX_underflow interrupt status bit must be cleared for interrupt line de-assertion (if event enable as
interrupt source).
Note: When more than one channel has an FIFO enable bit field (FFER or FFEW) set, the FIFO will not
be used on any channel. Software must ensure that only one enabled channel is configured to use the
FIFO buffer.
24.3.2.2.3 RX_ full
The event RX_full is activated when channel is enabled and receiver register becomes filled (transient
event). When FIFO buffer is enabled (MCSPI_CH(I)CONF[FFER] set to 1), the RX_full is asserted when
the number of bytes in the buffer equals the level defined by MCSPI_XFERLEVEL[AFL].
Receiver register must be read to remove source of interrupt and RX_full interrupt status bit must be
cleared for interrupt line de-assertion (if event enabled as interrupt source).
When the FIFO is enabled, no new RX_FULL event will be asserted once the CPU has read the number
of bytes defined by MCSPI_XFERLEVEL[AFL]. It is the responsibility of the CPU to perform the correct
number of read operations.
24.3.2.2.4 End of Word Count
The event end of word (EOW) count is activated when channel is enabled and configured to use the built-
in FIFO. This interrupt is raised when the controller had performed the number of transfer defined in
MCSPI_XFERLEVEL[WCNT] register. If the value was programmed to 0000h, the counter is not enabled
and this interrupt is not generated.
The EOW count interrupt also indicates that the SPI transfer has halted on the channel using the FIFO
buffer.
The EOW interrupt status bit must be cleared for interrupt line de-assertion (if event enable as interrupt
source).
4005
SPRUH73H – October 2011 – Revised April 2013
Multichannel Serial Port Interface (McSPI)
Copyright © 2011–2013, Texas Instruments Incorporated