13 SeRial inTeRFaCe
S1C63003/004/008/016 TeChniCal Manual
Seiko epson Corporation
13-3
(Rev. 1.1)
SPi slave mode
SPI slave mode is provided to use the S1C63004/008/016 as an SPI slave device. In this mode, the serial interface
inputs the synchronous clock that is sent by the external master device from the SCLK terminal to perform serial
transfer. The SPI master device outputs the SS (Slave Select) signal to select a slave device. SPI slave mode sup-
ports the SS signal input.
Sample basic serial connection diagrams are shown in Figure 13.4.1.
S1C630xx
External
slave device
(a-1) Master mode
SCLK
SOUT
SIN
Pxx
CLK
SOUT
SIN
READY
S1C630xx
SPI slave
device
(a-2) Master mode (SPI)
SCLK
SOUT
SIN
Pxx
CLK
SDO
SDI
SS
S1C630xx
External
master device
(b) Slave mode
SCLK
SOUT
SIN
SRDY
CLK
SOUT
SIN
READY input
S1C630xx
SPI master
device
(c) SPI slave mode
SCLK
SOUT
SIN
SS
SCLK
SDO
SDI
SS
4.1 Sample basic connection of serial input/output terminals
Figure 13.
The SMOD, ENCS and ESREADY registers are used for setting the mode.
Master mode: SMOD = "1," ENCS = "0," ESREADY = "0"
Slave mode:
SMOD = "0," ENCS = "1," ESREADY = "1"
SPI slave mode: SMOD = "0," ENCS = "1," ESREADY = "0"
Table 13.4.1 lists the combination of mode settings and used terminal configurations.
4.1 Mode settings and configurations of serial interface terminals
Table 13.
ESIF
SMOD
ENCS
ESREADY
ESOUT
Mode
P30
terminal
P31
terminal
P32
terminal
P33
terminal
1
1
1
1
*
Master mode
Prohibited
1
1
*
0
1
SCLK (O)
SOUT (O)
SIN (I)
P33 (I/O)
1
1
0
1
1
SCLK (O)
SOUT (O)
SIN (I)
P33 (I/O)
1
1
*
0
0
SCLK (O)
P31 (I/O)
SIN (I)
P33 (I/O)
1
1
0
1
0
SCLK (O)
P31 (I/O)
SIN (I)
P33 (I/O)
1
0
1
1
1
Slave mode
SCLK (I)
SOUT (O)
SIN (I)
SRDY (O)
1
0
1
1
0
SCLK (I)
P31 (I/O)
SIN (I)
SRDY (O)
1
0
0
*
1
SCLK (I)
SOUT (O)
SIN (I)
P33 (I/O)
1
0
0
*
0
SCLK (I)
P31 (I/O)
SIN (I)
P33 (I/O)
1
0
1
0
1
SPI slave mode
SCLK (I)
SOUT (O)
SIN (I)
SS (I)
1
0
1
0
0
SCLK (I)
P31 (I/O)
SIN (I)
SS (I)
0
*
*
*
*
Serial I/F not used
P30 (I/O)
P31 (I/O)
P32 (I/O)
P33 (I/O)