NuMicro® NUC029LEE/NUC029SEE
32-bit Arm
®
Cortex
®
-M0 Microcontroller
Aug, 2018
Page
421
of
497
Rev 1.00
N
U
MICRO
®
N
UC02
9L
E
E
/N
UC029
S
E
E
T
E
CHN
ICA
L R
E
F
E
R
E
NC
E
M
A
NU
A
L
cycle of SPI clock of a transaction, and the bit field VARCLK[28:27] defines the third clock cycle,
and so on. The VARCLK[0] has no meaning. The following figure shows the timing relationship
among the SPI bus clock, the VARCLK setting, the DIVIDER setting and the DIVIDER2 setting.
SPIn_CLK
VARCLK
(0x007FFF87)
Clock 1
(DIVIDER)
Clock 2
(DIVIDER2)
Clock sequence
1
2
3
4
5
6
7
8
9
10
11
12
13
14 15
16
0
00 00 00 00
11
11
11
11
11
11
11
11
00 00
11
1
Figure 6.15-5 Variable Bus Clock Frequency
6.15.5.4 Byte Reorder Function
When the transfer is set as MSB first (LSB = 0) and the REORDER bit is set to 1, the data stored
in the TX buffer and RX buffer will be rearranged in the order as [Byte0, Byte1, Byte2, Byte3] in
32-bit Transfer mode (TX_BIT_LEN = 0). The sequence of transmitted/received data will be
Byte0, Byte1, Byte2, and then Byte3. If the TX_BIT_LEN is set as 24-bit transfer mode, the data
in TX buffer and RX buffer will be rearranged as [unknown byte, Byte0, Byte1, Byte2]. The SPI
controller will transmit/receive data with the sequence of Byte0, Byte1 and then Byte2. Each byte
will be transmitted/received with MSB first. The rule of 16-bit mode is the same as above. Byte
Reorder function is only available when TX_BIT_LEN is configured as 16, 24, and 32 bits.
Note:
The Byte Reorder function is not supported when the variable bus clock function is
enabled.
Byte3
Byte0
Byte1
Byte2
SPI_TX0/SPI_RX0
TX/RX Buffer
LSB = 0 (MSB first)
& REORDER = 1
TX_BIT_LEN = 24 bits
TX_BIT_LEN = 16 bits
TX_BIT_LEN = 32 bits
MSB first
MSB first
nn = unknown byte
nn
Byte1
Byte0
nn
Byte1
Byte0
nn
Byte2
MSB first
Byte3
Byte0 Byte1 Byte2
MSB first
Figure 6.15-6 Byte Reorder Function