10 SPI
85
CW6632B Bluetooth 3.0 Audio Player SOC
Version 1.0.0
Copyright ©2015, www.appotech.com. All Rights Reserved.
10.1.1
SPI0 Special Function Registers
Register 10-1 SPI0CON
– SPI0 control
Position
7
6
5
4
3
2
1
0
Name
SPI0PND
SPI0SM
SPI0RT
SPI0WS
SPI0PS0
SPI0EDGE SPI0IDST
SPI0EN
Default
1
0
0
0
0
0
0
0
Access
RO
R/W
R/W
R/W
R/W
R/W
R/W
R/W
SPI0PND
: SPI0 Pending bit (read only, writing SPI0BUF will clear this bit)
0 = Transmission is not finish
1 = Transmission finish
SPI0SM
: SPI0 mode selection
0 = Master mode
1 = Slave mode
SPI0RT:
SPI0 RX/TX select bit in 2-wire mode or DMA mode
0 = TX
1 = RX
In 3-wire mode, SPI0 can both Transmit and receive at the same time. But when using DMA mode or 2-wire mode,
just one direction (TX or RX) is allowed. Use this bit to select TX or RX.
SPI0WS
: SPI0 2-wire mode/3-wire mode select bit
0 = 3-wire mode
1 = 2-wire mode
SPI0PS0
: SPI0 Port select 0
0 = Select P27, P25, P26 when SPI0PS1 = 0; Select P14, P00, P34 when SPI0PS1 = 1
1 = Select P04, P06, P05 when SPI0PS1 = 0
SPI0EDGE
: SPI0 sampling edge select bit
When SPI0IDST = 0:
0 = Sample at falling edge
1 = Sample at rising edge
When SPI0IDST = 1:
0 = Sample at rising edge
1 = Sample at falling edge
SPI0IDST
: SPI0 clock signal idle state
0 = Clock signal stay at 0 when idle
1 = Clock signal stay at 1 when idle
SPI0EN
: SPI0 enable bit
0 = SPI0 disable
1 = SPI0 enable
Register 10-2 SPIBAUD
– SPI0 Baud Rate