GD32F20x User Manual
809
maximum of two buffers. The value of the buffer 2 can be programmed to the second data
address or the next descriptor address which is determined by the configured descriptor table
type: Ring or Chain. Buffer space only contains frame data which
are located in host’s physical
memory space. One buffer can store only one frame data but one frame data can be stored
in more than one buffer which means one buffer can only store a part of a frame. When chain
structure is set, descriptor table is an explicitly one and when ring structure is set, descriptor
table is an implicitly one. Explicit chaining of descriptors is accomplished by configuring the
second address chained in both receive and transmit descriptors (RDES1[14] and
TDES0[20]), at this time RDES2 and TDES2 are stored the data buffer address, RDES3 and
TDES3 should be stored the next descriptor address, this connection method of descriptor
table is called chain structure. Implicitly chaining of descriptors is accomplished by clearing
the RDES1[14] and TDES0 [20], at this time RDES2, TDES2 and RDES3, TDES3 should be
all stored the data buffer address, this connection method of descriptor table is called ring
structure. When current descriptor’s buffer address is used, descriptor pointer will point to the
next descriptor. If chain structure is selected, the pointer points to the value of buffer 2. If ring
structure is selected, the pointer points to an address calculated as below:
Next descriptor address = Current descriptor a 16 + DPSL*4
If current descriptor is the last one in descriptor table, application needs to set the bit 21 in
TDES0 or bit 15 in RDES1 to inform DMA the current descriptor is the last one of the table in
ring structure. At this time, the next descriptor pointer points back to the first descriptor
address of the descriptor table. In chain structure, can also set TDES3 or RDES3 value to
point back to the first descriptor address of the descriptor table. The DMA skips to the next
frame buffer when the end of frame is detected.
Figure 27-8. Descriptor ring and chain structure
Descriptor 0
Descriptor 1
Descriptor 2
Descriptor n
Buffer 1
Buffer 2
Buffer 1
Buffer 2
Buffer 1
Buffer 2
Buffer 1
Buffer 2
Descriptor 0
Descriptor 1
Descriptor 2
Buffer 1
Buffer 1
Buffer 1
Next descriptor
Chain structure
Ring structure
If descriptor end
If descriptor end
.
.
.
.
Descriptor n
.
.
.
.
.
.
.
.
Содержание GD32F20 Series
Страница 1: ...GigaDevice Semiconductor Inc GD32F20x ARM Cortex M3 32 bit MCU User Manual Revision 2 2 Oct 2019 ...
Страница 191: ...GD32F20x User Manual 191 Bits Fields Descriptions 31 0 TRNDATA 31 0 32 Bit Random data ...
Страница 290: ...GD32F20x User Manual 290 conversion is ongoing ...
Страница 325: ...GD32F20x User Manual 325 15 0 ALRM 15 0 RTC alarm value low ...
Страница 385: ...GD32F20x User Manual 385 ...
Страница 523: ...GD32F20x User Manual 523 clears AERR bit by writing 0 to it ...