84
10.1
SPI0
CW6632B Bluetooth 3.0 Audio Player SOC
Version 1.0.0
Copyright ©2015, www.appotech.com. All Rights Reserved.
10
SPI
10.1
SPI0
SPI0 can serve as master or slave. It can operate in normal or DMA mode.
SPI0 map to three group ports configured by PWKEDGE[6] and SPICON[3]:
Group0
– P27, P25, P26;
Group1
– P04, P06, P05;
Group2
– P14, P00, P34.
Group3
– P30(P40), P31, P32
When PWKEDGE[6]=0 and SPI0CON.3 = 0, Group0 actived
2wire mode: P2.6 as SPI0CLK0, P2.7 as SPI0DIDO0;
3wire mode: P2.6 as SPI0CLK0, P2.7 as SPI0DO2, P2.5 as SPI0DI0.
When PWKEDGE[6]=0 and SPI0CON.3 = 1, Group1 actived
2wire mode: P0.5 as SPI0CLK1, P0.4 as SPI0DIDO1;
3wire mode: P0.5 as SPI0CLK1, P0.4 as SPI0DO1, P0.6 as SPI0DI1.
When PWKEDGE[6]=1 and SPI0CON.3 = 0 Group2 actived
2wire mode: P3.4 as SPI0CLK2, P1.4 as SPI0DIDO2;
3wire mode: P3.4 as SPI0CLK2, P1.4 as SPI0DO2, P0.0 as SPI0DI2.
When PWKEDGE[6]=1 and SPI0CON.3 = 1, Grop3 actived
2wire mode: P3.0 as SPI0CLK3, P3.2 as SPI0DIDO3;
3wire mode: P3.0 as SPI0CLK3, P3.2 as SPI0DO3, P3.1 as SPI0DI3.
when PMUXCON0[5] = 1 P4.0 as SPI0CLK3
3
4
1
2
8
7
6
5
SPICLK CYCLE #
MSB
6
5
4
3
2
1
LSB
MSB
6
5
4
3
2
1
LSB
SPICLK
(SPIIDST = 0)
SPICLK
(SPIIDST = 1)
SAMPLE INPUT
DATA OUT
(SPIEDGE = 0)
SAMPLE INPUT
DATA OUT
(SPIEDGE = 1)
Figure 10-1 SPI timing