Hi
Using M52259EVB and CW 10.1. Right now I'm doing really simple stuff by transmitting raw Ethernet frames, no IP stack. A Tx buffer descriptor is set up and contains a pattern in the data field, and I'm just trying to transmit this reliably. I'm using only one BD, and ETDSR was previously set to the address of the lone Tx BD. The below code is executed repeatedly, and slowly, by using CW debugger. The full code that runs at full speed without debugger checks things such as if TX_BD_R is clear before continuing.
NIC_TxBufDescPtr->length = 1500;
NIC_TxBufDescPtr->status = TX_BD_W | TX_BD_R | TX_BD_L |TX_BD_TC;
TDAR = TDAR_X_DES_ACTIVE_BITMASK;
When I step over the TDAR line, the board immediately transmits two identical frames in rapid succession. I have the cable connected to my computer and monitoring with Wireshark. I do not understand why it is transmitting twice. Any ideas?
Solved! Go to Solution.
This problem and workarounds are described in the MCU reference manual (21.5.7.1 Duplicate Frame Transmission, MCF52259RM rev. 2).
This problem and workarounds are described in the MCU reference manual (21.5.7.1 Duplicate Frame Transmission, MCF52259RM rev. 2).
Having one BD is unusual. it may be prefetching "ahead" and finding the same BD. Try it with at least two BDs.
Tom
You're both correct. All the searching I did to find the solution to the problem, and it turns out the issue is discussed right in the ref. manual.