Hi Divyesh,
We found a workaround to resolve this issue in the webserver project on LPC1769 , the suggested workaround is this:
In the tcp_impl.h file change the definition of TCP_MSL to the following:
#define TCP_MSL 100 //1000 //60000UL /* The maximum segment lifetime in milliseconds */
It means the memory is freed more quickly when closing connection.
I tried the value 100 and 1000 on lpcopen webserver example on lpc1788 and it can work.
We analyze the cause should be that when TCP connection is closed, the PCB is not released in time due to the long (120s) time waiting. This cause the PCB created more and more so that memory leaks due to the limited memory of MCU (SRAM).
Hope it helps!
Best Regards,
Carlos Mendoza
Technical Support Engineer