![GigaDevice Semiconductor GD32E23 Series Скачать руководство пользователя страница 533](http://html.mh-extra.com/html/gigadevice-semiconductor/gd32e23-series/gd32e23-series_user-manual_2225794533.webp)
GD32E23x User Manual
533
1: Master mode
1
CKPL
Clock polarity selection
0: CLK pin is pulled low when SPI is idle.
1: CLK pin is pulled high when SPI is idle.
0
CKPH
Clock phase selection
0: Capture the first data at the first clock transition.
1: Capture the first data at the second clock transition.
18.5.2.
Control register 1 (SPI_CTL1)
Address offset: 0x04
Reset value: SPI0: 0x0000 0000
SPI1: 0x0000 0700
This register can be accessed by byte (8-bit) or half-word (16-bit) or word (32-bit).
31
30
29
28
27
26
25
24
23
22
21
20
19
18
17
16
Reserved
15
14
13
12
11
10
9
8
7
6
5
4
3
2
1
0
Reserved
TXDMA_
ODD
RXDMA_
ODD
BYTEN
DZ[3:0]
TBEIE
RBNEIE
ERRIE
TMOD
NSSP
NSSDRV DMATEN DMAREN
rw
rw
rw
rw
rw
rw
rw
rw
rw
rw
rw
rw
Bits
Fields
Descriptions
31:15
Reserved
Must be kept at reset value.
14
TXDMA_ODD
Odd bytes in TX DMA channel (only for SPI1)
In data merging mode, this bit is set if the total number of data to transmit by DMA
is odd. It has effect only when DMATEN is set and data merging mode enable (data
size is less than or equal to 8-bit and write access to SPI_DATA is 16-bit wide).
This field can be written only when SPI is disabled.
0: The total number of data to transmit by DMA is even.
1: The total number of data to transmit by DMA is odd.
13
RXDMA_ODD
Odd bytes in RX DMA channel (only for SPI1)
In data merging mode, this bit is set if the total number of data to receive by DMA is
odd. It has effect only when DMAREN is set and data merging mode enable (data
size is less than or equal to 8-bit and write access to SPI_DATA is 16-bit wide).
This field can be written only when SPI is disabled.
0: The total number of data to receive by DMA is even.
1: The total number of data to receive by DMA is odd.
12
BYTEN
Byte access enable (only for SPI1)
This bit is used to indicate the access size to FIFO, and set the threshold of the