LPC54616 - LwIP sporadic LWIP_ASSERT

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

LPC54616 - LwIP sporadic LWIP_ASSERT

705 Views
felu
Contributor II

Hello everyone,

I've ported the lwip_httpsrv freertos example (from SDK 2.8.2) to RTX5 on a custom board with a LPC54616 and LAN8720A. After some time it runs in one of the following asserts:

tcpip_thread: invalid message
pbuf_free: p->ref > 0

To reproduce the issue i send up to 20 http requests per second. Slowing down the request rate also reduces the crash rate.The network only consists of the board and my computer, so there is no other traffic.

To eliminate issues due to the porting I've also tested the unchanged example on a LPCXpresso54618. After some time this one crashed too. Even with older LwIP versions (I've tested the ones from SDK 2.6.0 and 2.7.0) I can reproduce this issue.

Can anyone help?

 

Labels (1)
0 Kudos
2 Replies

684 Views
FelipeGarcia
NXP Employee
NXP Employee

Hi,

Please take a look to the following community thread where the same issue has been discussed.

FRDM-K64F KSDK 1.3.0 tcp_echo demo bugs? - NXP Community

Hoe it helps!

Best regards,

Felipe

654 Views
felu
Contributor II

Hello,

thank you @FelipeGarcia  for the link. Actually I already saw this thread before but did not recognize it's use for my problem cause the code for the LPC is a bit different.

I gave it a try anyway and implemented a seperate thread to call ethernet_input(), which solves the initial problem. But even if my code runs much smoother now, after some time it seems that there are no RX interrupts anymore and my ethernet_input_thread stays blocked.

All other interrupts and the lwip independent threads work as expected.

0 Kudos