cancel
Showing results for 
Search instead for 
Did you mean: 

LwIP: link always down

Rick MC
Associate III
Posted on June 21, 2018 at 16:53

I have a problem using the LwIP

If I have a project where there is only the LwIP, everything works.

MX_GPIO_Init();

MX_LWIP_Init();

httpd_init();

myCGIinit();

while (1)

{

   MX_LWIP_Process();

}

If I add something else (as a QSPI or SDMMC  or Touch Screen...) the ETH stops working: in particular, the link is always down, since in function MX_LWIP_Init(), the condition

if (netif_is_link_up(&gnetif))

is always false..

Why does this happen?? Is there anything wrong with the code generated by CubeMX?

Thank you all!

#lwip #eth #stm32f7 #discovery
1 REPLY 1
Rick MC
Associate III
Posted on June 21, 2018 at 17:17

UPDATE: the main problem is in function HAL_StatusTypeDef HAL_ETH_GetReceivedFrame(ETH_HandleTypeDef *heth), called by MX_LWIP_Process();

This function never returns HAL_OK.. so the board cannot be reached via Ethernet!