This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TivaWare_C_Series-2.1.0.12573 bug in enet_uip example

description: The enet_uip example of using the uIP Ethernet stack never resets the FLAG_TXPKT flag (enet_uip.c, line 296), which results in the stack using up more processor time than necessary.

Reason: The condition if(ui32Temp & EMAC_INT_TRANSMIT) (line 291) in function EthernetIntHandler() never evaluates to TRUE. This happens because the EMAC_INT_TRANSMIT interrupt source has not been enabled. So when the DMA transfer is complete, an interrupt does not fire.


Solution: When enabling the Rx interrupt source also enable the Tx source:

    // Existing code:
    // Enable the Ethernet RX Packet interrupt source.
    //
    ROM_EMACIntEnable(EMAC0_BASE, EMAC_INT_RECEIVE);


    // Add this code:
    // Enable the Ethernet TX Packet interrupt source.
    //
    ROM_EMACIntEnable(EMAC0_BASE, EMAC_INT_TRANSMIT);

Tested to solve the bug and improve processor time consumption.