参考老衲五木的博客http://blog.sina.com.cn/s/blog_62a85b950101am5d.html
-
如何更改lwip的最大socket数.
修改lwipopts.h中的 MEMP_NUM_NETCONN 值
/**
*MEMP_NUM_NETCONN: the number of struct netconns.
*(only needed if you use the sequential API, like api_lib.c)
*/
#
本文介绍了如何修改LwIP配置以降低内存消耗和调整最大socket数。通过在`lwipopts.h`中调整`MEMP_NUM_NETCONN`、`MEM_SIZE`、`TCP_MSS`和`PBUF_POOL_SIZE`等宏定义,可以实现LwIP的资源优化。例如,将`MEMP_NUM_NETCONN`从8增加到13,`MEM_SIZE`从120KB减小到48KB,`TCP_MSS`设置为1400字节,以及`PBUF_POOL_SIZE`从16*5改为16*3,从而减少内存占用。
参考老衲五木的博客http://blog.sina.com.cn/s/blog_62a85b950101am5d.html
如何更改lwip的最大socket数.
修改lwipopts.h中的 MEMP_NUM_NETCONN 值
/**
*MEMP_NUM_NETCONN: the number of struct netconns.
*(only needed if you use the sequential API, like api_lib.c)
*/
#

被折叠的 条评论
为什么被折叠?