![GigaDevice Semiconductor GD32F20 Series User Manual Download Page 790](http://html.mh-extra.com/html/gigadevice-semiconductor/gd32f20-series/gd32f20-series_user-manual_2225801790.webp)
GD32F20x User Manual
790
received the sending instruction, the TxDMA fetches the transmit frames from system memory
and pushes them into the TxFIFO, then the data in TxFIFO are poped to MAC for sending on
MII/RMII interface. The method of popping is according to the selected TxFIFO mode (Cut-
Through mode or Store-and-Forward mode, the specific definition see the next
paragraph).For convenient, application can configure automatically hardware calculated CRC
and insert it to the FCS domain of Ethernet frame function. The entire transmission process
complete when the MAC received the frame termination signal from transmit FIFO. When
transmission completed, the transmission status information will be composed of MAC and
write return to the DMA controller, the application can query through the DMA current transmit
descriptor.
Operation for popping data from FIFO to the MAC has two modes:
In Cut-Through mode, as soon as the number of bytes in the FIFO crosses or equals the
configured threshold level or when the end-of-frame flag in descriptor is written, the data
is ready to be popped out and forwarded to the MAC. The threshold level is configured
using the TTHC bits of ENET_DMA_CTL.
In Store-and-Forward mode, only after an integrated frame is stored in the FIFO, the
frame is popped towards the MAC. But there is another condition for FIFO popping out
data but the frame is not integrated. This is when the transmit FIFO size is smaller than
the Ethernet frame to be transmitted, the frame is popped towards the MAC when the
transmit FIFO becomes almost full.
Handle special cases
In the transmission process, due to the insufficient TxDMA descriptor or misuse of FTF bit in
ENET_DMA_CTL register (when this bit is set, it will clear FIFO data and reset the FIFO
pointer, after clear operation is completed, it will be reset), there will be a transmit data
underflow fault occurs because of insufficient data in FIFO. At the same time MAC will identify
such data underflow state and write relevant status flag.
If one transmit frame uses two TxDMA descriptors for sending data, then the first segment
(FSG) and the last segment (LSG) of the first descriptor should be 10b and the second ones
should be 01b.If both the FSG bit of the first and the second descriptor are set and the LSG
bit in the first descriptor is reset, then the FSB bit of the second descriptor will be ignored and
these two descriptors are considered to sending the only one frame.
If the byte length of one
transmission MAC frame’s data field is less than 46 (for Tagged MAC
frame is less than 42), application can configure the MAC for automatically adding a load of
content of ‘0’ bit to make the byte length of frame’s data field in accordance with the relevant
domain of definition of IEEE802.3 specification. At the same time, if automatically adding
zeros function is performed, the MAC will certainly calculate CRC value of the frame and
append it to the frame’s FCS field domain no matter what configuration of DCRC bit in the
descriptor is.
Summary of Contents for GD32F20 Series
Page 191: ...GD32F20x User Manual 191 Bits Fields Descriptions 31 0 TRNDATA 31 0 32 Bit Random data ...
Page 290: ...GD32F20x User Manual 290 conversion is ongoing ...
Page 325: ...GD32F20x User Manual 325 15 0 ALRM 15 0 RTC alarm value low ...
Page 385: ...GD32F20x User Manual 385 ...
Page 523: ...GD32F20x User Manual 523 clears AERR bit by writing 0 to it ...