UM11029
All information provided in this document is subject to legal disclaimers.
© NXP Semiconductors N.V. 2017. All rights reserved.
User manual
Rev. 1.0 — 16 June 2017
314 of 515
NXP Semiconductors
UM11029
Chapter 18: LPC84x SPI0/1
18.6.3 SPI Status register
The STAT register provides SPI status flags for software to read, and a control bit for
forcing an end of transfer. Flags other than read-only flags may be cleared by writing ones
to corresponding bits of STAT.
STAT contains 2 error flags (in slave mode only): RXOV and TXUR. These are receiver
overrun and transmit underrun, respectively. If either of these errors occur during
operation, the SPI should be disabled, then re-enabled in order to make sure all internal
states are cleared before attempting to resume operation.
In this register, the following notation is used: RO = Read-only, W1 = write 1 to clear.
Table 339. SPI Status register (STAT, addresses 0x4005 8008 (SPI0), 0x4005 C008 (SPI1)) bit description
Bit
Symbol
Description
Reset
value
Access
0
RXRDY
Receiver Ready flag. When 1, indicates that data is available to be read from
the receiver buffer. Cleared after a read of the RXDAT register.
0
RO
1
TXRDY
Transmitter Ready flag. When 1, this bit indicates that data may be written to
the transmit buffer. Previous data may still be in the process of being
transmitted. Cleared when data is written to TXDAT or TXDATCTL until the data
is moved to the transmit shift register.
1
RO
2
RXOV
Receiver Overrun interrupt flag. This flag applies only to slave mode (Master =
0). This flag is set when the beginning of a received character is detected while
the receiver buffer is still in use. If this occurs, the receiver buffer contents are
preserved, and the incoming data is lost. Data received by the SPI should be
considered undefined if RxOv is set.
0
W1
3
TXUR
Transmitter Underrun interrupt flag. This flag applies only to slave mode
(Master = 0). In this case, the transmitter must begin sending new data on the
next input clock if the transmitter is idle. If that data is not available in the
transmitter holding register at that point, there is no data to transmit and the
TXUR flag is set. Data transmitted by the SPI should be considered undefined if
TXUR is set.
0
W1
4
SSA
Slave Select Assert. This flag is set whenever any slave select transitions from
deasserted to asserted, in both master and slave modes. This allows
determining when the SPI transmit/receive functions become busy, and allows
waking up the device from reduced power modes when a slave mode access
begins. This flag is cleared by software.
0
W1
5
SSD
Slave Select Deassert. This flag is set whenever any asserted slave selects
transition to deasserted, in both master and slave modes. This allows
determining when the SPI transmit/receive functions become idle. This flag is
cleared by software.
0
W1
6
STALLED
Stalled status flag. This indicates whether the SPI is currently in a stall
condition.
0
RO