14-5
Seiko Epson Corporation
S1C31D50 TECHNICAL MANUAL
(Rev. 1.00)
14.3.2.
Clock Supply During Debugging
In master mode, the operating clock supply during debugging should be controlled using the
T16_
m
CLK.DBRUN bit.
The CLK_T16_
m
supply to SPIA Ch.
n
is suspended when the CPU enters debug state if the
T16_
m
CLK.DBRUN bit = 0. After the CPU returns to normal operation, the CLK_T16_
m
supply resumes.
Although SPIA Ch.
n
stops operating when the CLK_T16_
m
supply is suspended, the output pins and
registers retain the status before the de- bug state was entered. If the T16_
m
CLK.DBRUN bit = 1, the
CLK_T16_
m
supply is not suspended and SPIA Ch.
n
will keep operating in a debug state.
SPIA in slave mode operates with the external SPI master clock input from the SPICLK
n
pin regardless of
whether the CPU is placed into debug state or normal operation state.
14.3.3.
SPI Clock (SPICLK
n
) Phase and Polarity
The SPICLKn phase and polarity can be configured separately using the SPIA_nMOD.CPHA bit and the
SPIA_ nMOD.CPOL bit, respectively. Figure 14.3.3.1 shows the clock waveform and data input/output
timing in each setting.
Figure 14.3.3.1 SPI Clock Phase and Polarity (SPIA_
n
MOD.LSBFST bit = 0, SPIA_
n
MOD.CHLN[3:0] bits = 0x7)
14.4.
Data Format
The SPIA data length can be selected from 2 bits to 16 bits by setting the SPIA_
n
MOD.CHLN[3:0] bits.
The input/ output permutation is configurable to MSB first or LSB first using the SPIA_
n
MOD.LSBFST
bit. Figure 14.4.1 shows a data format example when the SPIA_
n
MOD.CHLN[3:0] bits = 0x7, the
SPIA_
n
MOD.CPOL bit = 0 and the SPIA_
n
MOD.CPHA bit = 0.
Figure 14.4.1 Data Format Selection Using the SPIA_nMOD.LSBFST Bit (SPIA_nMOD.CHLN[3:0] bits = 0x7,
SPIA_nMOD.CPOL bit = 0, SPIA_nMOD.CPHA bit = 0)
MSB
LSB
MSB
LSB
MSB
LSB
MSB
LSB
Writing data to the SPIA_
n
TXD register
Cycle No.
SPICLK
n
SPICLK
n
SPICLK
n
SPICLK
n
SDI
n
(Master mode) SDO
n
(Slave mode) SDO
n
(Slave mode) SDO
n
1
2
3
4
5
6
7
8
1
0
1
0
x
x
1
0
1
1
0
0
x
x
x
x
CPHA bit
CPOL bit
SPIA_
n
MOD register
Dw7
Dw6
Dw5
Dw4
Dw3
Dw2
Dw1
Dw0
Dr7
Dr6
Dr5
Dr4
Dr3
Dr2
Dr1
Dr0
Dw0
Dw1
Dw2
Dw3
Dw4
Dw5
Dw6
Dw7
Dr0
Dr1
Dr2
Dr3
Dr4
Dr5
Dr6
Dr7
Writing Dw[7:0] to the SPIA_
n
TXD register
Loading Dr[7:0] to the SPIA_
n
RXD register
Cycle No.
SPICLK
n
SDO
n
SDI
n
SDO
n
SDI
n
1
2
3
4
5
6
7
8
SPIA_
n
MOD.
LSBFST bit
0
1
Summary of Contents for S1C31D50
Page 461: ...25 1 Seiko Epson Corporation S1C31D50 TECHNICAL MANUAL Rev 1 00 25 Package TQFP12 48PIN ...
Page 462: ...25 2 Seiko Epson Corporation S1C31D50 TECHNICAL MANUAL Rev 1 00 QFP13 64PIN ...
Page 463: ...25 3 Seiko Epson Corporation S1C31D50 TECHNICAL MANUAL Rev 1 00 TQFP14 80PIN ...
Page 464: ...25 4 Seiko Epson Corporation S1C31D50 TECHNICAL MANUAL Rev 1 00 QFP15 100PIN ...