-
Notifications
You must be signed in to change notification settings - Fork 8.3k
Description
Is your enhancement proposal related to a problem? Please describe.
Current configuration for Civetweb HTTP sample requires too much RAM (>230K), which prevents it from being run on wide number of targets.
This choice was deliberate at PR introduction (#17019) as described in this comment.
Civetweb is the only HTTP client sample available today for zephyr. This memory consumption makes is unavailable for many targets, so situation is like there were no Zephyr HTTP client for many Zephyr users.
Before net refactoring, I was able to run a micropython powered HTTP server on top of existing networking stack on nucleo_f429zi (192K RAM), so I would expect we could have a zephyr native alternative running on the same platform today.
samples/net/sockets/civetweb configuration shows that main factor for RAM consumption is the following setting:
CONFIG_MINIMAL_LIBC_MALLOC_ARENA_SIZE=131072
Below 92000 an illegal exception appears. At 92000 connection closes after a few history clicks.
So getting it down to an acceptable level obviously requires some fine tuning and potentially further optimisation.
Describe the solution you'd like
Rework civetweb sample configuration to fit below an acceptable RAM consumption.
Describe alternatives you've considered
Additional context