summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDamien George <damien@micropython.org>2025-06-11 13:31:40 +1000
committerDamien George <damien@micropython.org>2025-07-08 16:25:14 +1000
commit959e910366d0109f959a1ecbb91d5fbd92b9be2f (patch)
tree5704eda8dd61b31a9826f40c18f75329be118e8b
parenteaed2518fab968362d15745c4f1f3d39bd60ad38 (diff)
stm32/lwip_inc: Increase lwIP memory on N6.
Signed-off-by: Damien George <damien@micropython.org>
-rw-r--r--ports/stm32/lwip_inc/lwipopts.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/ports/stm32/lwip_inc/lwipopts.h b/ports/stm32/lwip_inc/lwipopts.h
index 9e2402c8d..ad1143845 100644
--- a/ports/stm32/lwip_inc/lwipopts.h
+++ b/ports/stm32/lwip_inc/lwipopts.h
@@ -10,6 +10,15 @@
#define LWIP_RAND() rng_get()
+// Increase memory for lwIP to get better performance.
+#if defined(STM32N6)
+#define MEM_SIZE (16 * 1024)
+#define TCP_MSS (1460)
+#define TCP_WND (8 * TCP_MSS)
+#define TCP_SND_BUF (8 * TCP_MSS)
+#define MEMP_NUM_TCP_SEG (32)
+#endif
+
// Include common lwIP configuration.
#include "extmod/lwip-include/lwipopts_common.h"