On 17.09.2018 18:10, Andy Pont wrote:
Hello,
I’m trying to figure out the memory settings being used by a project
that I have inherited. The lwipopts.h file contains:
#define MEM_USE_POOLS1
#define MEMP_USE_CUSTOM_POOLS1
#define MEM_USE_POOLS_TRY_BIGGER_POOL1
I think this means that it allocates the memory that is defined in
lwippools.h which is:
Right.
LWIP_MALLOC_MEMPOOL(14, 75)
LWIP_MALLOC_MEMPOOL(6, 225)
LWIP_MALLOC_MEMPOOL(1, 525)
LWIP_MALLOC_MEMPOOL(3, 1540)
I’m not clear what the LWIP_MALLOC_MEMPOOL macro does and how much RAM
lwIP is actually trying to allocate.
That macro allocates pools of X elements with Y bytes each.
It allocates (14 * 75) + (6 * 225) + (1 * 525) + (3 * 1540) bytes plus a
little offset for administration, so roughly 7,5 kB.
Simon
_______________________________________________
lwip-users mailing list
lwip-users@nongnu.org
https://lists.nongnu.org/mailman/listinfo/lwip-users