Skip to main content
Associate II
Jul 3, 2024 4:27 AM UTC
Solved

Ethernet: LWIP memory issue

Whenever i am trying to post data i am facing this error this is making my system reboot everytime.

I am using STM32F417VETX controller.

Assertion "detected mem overflow in pool TCPIP_MSG_INPKT" failed at line 109 in ../Middlewares/Third_Party/LwIP/src/core/mem.c
Assertion "detected mem underflow in pool TCPIP_MSG_INPKT" failed at line 120 in ../Middlewares/Third_Party/LwIP/src/core/mem.c

This topic has been closed for replies.
VanshajKaisthaBest answer
Associate II
Feb 4, 2025 4:02 AM UTC

I just set my MEMP_MEM_MALLOC to 0 which stopped the assertion.

4 replies

ST Employee
Jul 3, 2024 3:46 PM UTC

Hello @VanshajKaistha ,

Can you give more information about your STM32CubeF4 version you are using as well as your memory configuration (buffer and descriptor placement, alignment  ..)
Also check you Lwip configuration and share it, if possible, you will find it in lwipopts.h .

If you are using RTOS make sure you are allocating the right pool, stack sizes.
Regards 

In order to give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.
Associate II
Aug 26, 2024 6:52 AM UTC

I have handled the issue thanks for the response. :)

Associate
Jan 30, 2025 10:02 AM UTC

@VanshajKaistha

Hi, could you please elaborate on how you solved this issue? I'm facing the same issue.

Thank you in advance.

Regards

VanshajKaisthaAuthorBest answer
Associate II
Feb 4, 2025 4:02 AM UTC

I just set my MEMP_MEM_MALLOC to 0 which stopped the assertion.