Skip to main content
Lyong.161
Visitor II
May 10, 2019
Question

STM32F429 Ethernet crash

  • May 10, 2019
  • 1 reply
  • 639 views

I use STM32F429, refer to en. Stsw-stm32070 source code, remove lwip, only Ethernet data transceiver, found a long time communication, Ethernet will crash, mainly set TBUS, RBUS, RS, ETS。But I used the following code in the interrupt, and it could not be restored. The program has been in the Ethernet interrupt state, so the data could not be sent or received. How to solve this problem

if (ETH->DMASR & INT_RBUIE) 

{

/* Receive buffer unavailable, resume DMA */

ETH->DMASR = ETH_DMASR_RBUS;

ETH->DMARPDR = 0;

  }

 if (ETH->DMASR & INT_TBUIE) 

{

/* Receive buffer unavailable, resume DMA */

ETH->DMASR = ETH_DMASR_TBUS;

ETH->DMATPDR = 0;

  }

ETH->DMASR = ETH_DMASR_NIS | ETH_DMASR_AIS;

This topic has been closed for replies.

1 reply

Piranha
Principal III
May 14, 2019

https://github.com/blueskycoco/stsw-stm32070/blob/master/STM32F4x7_ETH_LwIP_V1.1.1/Utilities/Third_Party/lwip-1.4.1/port/STM32F4x7/FreeRTOS/ethernetif.c

When ethernetif_input() gets semaphore, it calls low_level_input() only once, but it should loop while unprocessed frames are available.