Datasheet
Serial Peripheral Interface (S08SPI16V1)
MC9S08JM60 Series Data Sheet, Rev. 3
262 Freescale Semiconductor
The baud rate divisor equation is as follows:
The baud rate can be calculated with the following equation:
Figure 15-15. SPI Baud Rate Generation
15.4.7 Special Features
15.4.7.1 SS Output
The SS output feature automatically drives the SS pin low during transmission to select external devices
and drives it high during idle to deselect external devices. When SS output is selected, the SS output pin
is connected to the SS input pin of the external device.
The SS output is available only in master mode during normal SPI operation by asserting the SSOE and
MODFEN bits as shown in Table 15-2.
The mode fault feature is disabled while SS output is enabled.
NOTE
Care must be taken when using the SS output feature in a multi-master
system since the mode fault feature is not available for detecting system
errors between masters.
15.4.7.2 Bidirectional Mode (MOMI or SISO)
The bidirectional mode is selected when the SPC0 bit is set in SPI Control Register 2 (see Table 15-9.) In
this mode, the SPI uses only one serial data pin for the interface with external device(s). The MSTR bit
decides which pin to use. The MOSI pin becomes the serial data I/O (MOMI) pin for the master mode, and
the MISO pin becomes serial data I/O (SISO) pin for the slave mode. The MISO pin in master mode and
MOSI pin in slave mode are not used by the SPI.
BaudRateDivisor SPPR 1+()2•
SPR 1+()
=
Baud Rate BusClock BaudRateDivisor⁄=
DIVIDE BY
2, 4, 8, 16, 32, 64, 128, or 256
DIVIDE BY
1, 2, 3, 4, 5, 6, 7, or 8
PRESCALER BAUD RATE DIVIDER
SPPR2:SPPR1:SPPR0 SPR2:SPR1:SPR0
BUS CLOCK
MASTER
SPI
BIT RATE