I’ve been playing around with the examples of the benchmark and demo widgets on a Teensy 4.1 and when I compile and upload the code to the Teensy I can see that program storage comes to around 273kb and RAM usage is around 360kb on the demo widgets example.
On a test sketch I built that includes just one screen, a gauge, an image and some labels with custom fonts the RAM usage jumps to around 672kb, and I only have 512kb available to use.
How do I keep the RAM usage low or under 500kb? I’m baffled as the demo widgets includes so much more objects yet consumes half the amount of the static memory and half the RAM.
What MCU/Processor/Board and compiler are you using?
Teensy 4.1 with 8Mb flash and 512kb RAM
What LVGL version are you using?
What do you want to achieve?
Low or fair level of RAM consumption
Code to reproduce
The main code is attached here. It does not include my custom fonts that were generated at 4bpp ranging from 10,12,14,16,18,20,22,24,26,28,30 and 32 px
gauge_lvgl_demo.zip (138 KB)