MC68HC912B32MFU8 MOTOROLA [Motorola, Inc], MC68HC912B32MFU8 Datasheet - Page 96

no-image

MC68HC912B32MFU8

Manufacturer Part Number
MC68HC912B32MFU8
Description
16-Bit Microcontroller
Manufacturer
MOTOROLA [Motorola, Inc]
Datasheet
MODF — SPI Mode Error Interrupt Status Flag
SP0DR — SPI Data Register
13.4 Port S
PORTS — Port S Data Register
DDRS — Data Direction Register for Port S
96
MOTOROLA
Function
RESET:
RESET:
Pin
(read or write) to the SP0DR register.
This bit is set automatically by SPI hardware if the MSTR control bit is set and the slave select input pin
becomes zero. This condition is not permitted in normal operation. In the case where DDRS bit 7 is set,
the PS7 pin is a general-purpose output pin or SS output pin rather than being dedicated as the SS input
for the SPI system. In this special case the mode fault function is inhibited and MODF remains cleared.
This flag is automatically cleared by a read of the SP0SR (with MODF set) followed by a write to the
SP0CR1 register.
Read anytime (normally only after SPIF flag set). Write anytime (see WCOL write collision flag).
Reset does not affect this address.
This 8-bit register is both the input and output register for SPI data. Reads of this register are double
buffered but writes cause data to be written directly into the serial shifter. In the SPI system the 8-bit
data register in the master and the 8-bit data register in the slave are linked by the MOSI and MISO
wires to form a distributed 16-bit register. When a data transfer operation is performed, this 16-bit reg-
ister is serially shifted eight bit positions by the SCK clock from the master so the data is effectively ex-
changed between the master and the slave. Note that some slave devices are very simple and either
accept data from the master without returning data to the master or pass data to the master without re-
quiring data from the master.
In all modes, port S bits PS[7:0] can be used for either general-purpose I/O, or with the SCI and SPI
subsystems. During reset, port S pins are configured as high-impedance inputs (DDRS is cleared).
PORTS can be read anytime. When configured as an input, a read will return the pin level. When con-
figured as output, a read will return the latched output data. Writes do not change pin state when pin
configured for SPI or SCI output.
After reset all bits are configured as general-purpose inputs.
Port S shares function with the on-chip serial systems (SPI0 and SCI0).
Read or write anytime.
After reset, all general-purpose I/O are configured for input only.
0 = No write collision
1 = Indicates that a serial transfer was in progress when the MCU tried to write new data into the
0 = Configure the corresponding I/O pin for input only
1 = Configure the corresponding I/O pin for output
SP0DR data register.
DDS7
Bit 7
Bit 7
Bit 7
Bit 7
PS7
SS
CS
0
0
DDS6
SCK
PS6
6
6
0
6
6
0
MOMI
DDS5
MOSI
PS5
5
5
0
5
5
0
DDS4
MISO
SISO
PS4
4
4
0
4
4
0
DDS3
PS3
I/O
3
3
0
3
3
0
DDS2
PS2
I/O
2
2
0
2
2
0
DDS1
TXD0
PS1
1
1
0
1
1
0
MC68HC912B32TS/D
RXD0
DDS0
Bit 0
Bit 0
Bit 0
Bit 0
PS0
MC68HC912B32
0
0
$00D5
$00D6
$00D7

Related parts for MC68HC912B32MFU8