English
Language : 

MC68HC11G5 Datasheet, PDF (111/195 Pages) Motorola, Inc – High-density Complementary Metal Oxide Semiconductor (HCMOS) Microcontroller
Freescale Semiconductor, Inc.
8.4.2 Status Register (SPSR)
7
6
5
4
3
2
1
0
$1029 SPIF WCOL 0 MODF 0
0
0
0
SPSR
RESET:
0
0
0
0
0
0
0
0
READ: Any time.
WRITE: Has no meaning or effect.
SPIF — SPI Interrupt Request Flag
The serial peripheral data transfer flag bit is set after the eighth SCK cycle in a data
transfer and it is cleared by reading the SPSR register (with SPIF set) followed by reading
from or writing to the SPI Data Register (SPDAT).
WCOL — Write Collision
The write collision bit is used to indicate that a serial transfer was in progress when the
MCU tried to write new data into the SPDAT data register. The MCU write is disabled to
avoid writing over the data being transmitted. No interrupt is generated because the error
status flag can be read upon completion of the transfer that was in progress at the time
of the error. This flag is automatically cleared by a read of the SPSR (with WCOL set)
followed by an access (read or write) to the SPDAT register.
MODF — SPI Mode Error Interrupt Status Flag
This bit is set automatically by SPI hardware if the MSTR control bit is set to one and the
SS input pin goes low. This condition is not permitted in normal operation. In the special
case where DDRD bit 5 is set to one, the Port D bit 5 pin is a general purpose output pin
rather than being dedicated as the slave select input for the SPI system. In this special
case the mode error function is inhibited and MODF remains at zero. This flag is
automatically cleared by a read of the SPSR (with MODF set) followed by a write to the
SPCR register.
8.4.3 Data I/O Register (SPDAT)
7
6
5
4
3
2
1
0
$102A BIT7 BIT6 BIT5 BIT4 BIT3 BIT2 BIT1 BIT0 SPDAT
RESET:
0
0
0
0
0
0
0
0
READ: Any time (normally only after SPIF flag set)
WRITE: Any time (see WCOL write collision flag).
RESET: Does not affect this register.
The serial peripheral data I/O register is used to transmit and receive data on the serial bus. Only
a write to this register will initiate transmission/reception of another byte, and this will only occur in
SERIAL PERIPHERAL INTERFACE
8-7
For More Information On This Product,
Go to: www.freescale.com