Datasheet

1998-2013 Microchip Technology Inc. DS30289C-page 133
PIC17C7XX
15.0 MASTER SYNCHRONOUS
SERIAL PORT (MSSP)
MODULE
The Master Synchronous Serial Port (MSSP) module is
a serial interface useful for communicating with other
peripheral or microcontroller devices. These peripheral
devices may be serial EEPROMs, shift registers, dis-
play drivers, A/D converters, etc. The MSSP module
can operate in one of two modes:
Serial Peripheral Interface (SPI)
Inter-Integrated Circuit
TM
(I
2
C)
Figure 15-1 shows a block diagram for the SPI mode,
while Figure 15-2 and Figure 15-3 show the block
diagrams for the two different I
2
C modes of operation.
FIGURE 15-1: SPI MODE BLOCK
DIAGRAM
FIGURE 15-2: I
2
C SLAVE MODE BLOCK
DIAGRAM
FIGURE 15-3: I
2
C MASTER MODE
BLOCK DIAGRAM
Read Write
Internal
Data Bus
SSPSR reg
SSPBUF reg
SSPM3:SSPM0
bit0
Shift
Clock
SS
Control
Enable
Edge
Select
Clock Select
TMR2 Output
Tosc
Prescaler
4, 16, 64
2
Edge
Select
2
4
Data to TX/RX in SSPSR
Data Direction bit
2
SMP:CKE
SDI
SDO
SS
SCK
Read Write
SSPSR reg
Match Detect
SSPADD reg
START and
STOP bit Detect
SSPBUF reg
Internal
Data Bus
Addr Match
Set, Reset
S, P bits
(SSPSTAT reg)
SCL
Shift
Clock
MSb
LSb
SDA
or General
Call Detected
Read Write
SSPSR reg
Match detect
SSPADD reg
START and STOP bit
Detect/Generate
SSPBUF reg
Internal
Data Bus
Addr Match
Set/Clear S bit
Clear/Set P, bit
(SSPSTAT reg)
SCL
Shift
Clock
MSb
LSb
SDA
Baud Rate Generator
7
SSPADD<6:0>
and
and Set SSPIF
or General
Call Detected