English
Language : 

MC68HC705C8A_13 Datasheet, PDF (142/222 Pages) Freescale Semiconductor, Inc – Technical Data
Freescale Semiconductor, Inc.
Serial Peripheral Interface (SPI)
Addr.
$000A
$000B
$000C
Register Name
Bit 7
6
5
4
3
Read:
SPI Control Register
SPIE SPE
(SPCR) Write:
See page 149.
Reset: 0
0
MSTR CPOL
0
U
Read: SPIF
SPI Status Register
(SPSR) Write:
See page 151.
Reset: 0
WCOL
0
MODF
0
Read:
SPI Data Register
Bit 7 Bit 6
Bit 5
Bit 4
Bit 3
(SPDR) Write:
See page 149.
Reset:
Unaffected by reset
= Unimplemented U = Unaffected
2
CPHA
U
BIt 2
1
SPR1
U
Bit 1
Bit 0
SPR0
U
Bit 0
Figure 11-2. SPI I/O Register Summary
11.4 Operation
The master/slave SPI allows full-duplex, synchronous, serial
communication between the microcontroller unit (MCU) and peripheral
devices, including other MCUs. As the 8-bit shift register of a master SPI
transmits each byte to another device, a byte from the receiving device
enters the master SPI shift register. A clock signal from the master SPI
synchronizes data transmission.
Only a master SPI can initiate transmissions. Software begins the
transmission from a master SPI by writing to the SPI data register
(SPDR). The SPDR does not buffer data being transmitted from the SPI.
Data written to the SPDR goes directly into the shift register and begins
the transmission immediately under the control of the serial clock. The
transmission ends after eight cycles of the serial clock when the SPI flag
(SPIF) becomes set. At the same time that SPIF becomes set, the data
shifted into the master SPI from the receiving device transfers to the
SPDR. The SPDR buffers data being received by the SPI. Before the
master SPI sends the next byte, software must clear the SPIF bit by
reading the SPSR and then accessing the SPDR.
Technical Data
142
Serial Peripheral Interface (SPI)
For More Information On This Product,
Go to: www.freescale.com
MC68HC705C8A — Rev. 3