How to tell SLS to load images from file in generated code?

What do you want to achieve?

We want SLS to add calls like:

lv_img_set_src(icon, “S:my_icon.bin”)

to make LVGL load bitmaps from an external file system.
We have lots of them, won’t fit in flash code area so compiling .C sources containing all the bitmaps is not an option.

Avoid linking the .C bitmap files is trivial; but we dont find a way to tell SLS to keep bitmaps on file adding the necessary lv_img_set_src() calls.

What have you tried so far?

Can manually add the necessary calls, but is very cumbersome, specially tracking each bitmap addition, and i’m not able to find a way that does’nt need re-editing after each export.

Screenshot or video

Others

SquareLine Studio version: 1.3.2

  • Operating system: Windows 10
  • Target hardware: custom STM32 board

On startup screen add event ONLOADSTART call function and here place all

and how mutch is

On startup screen add event ONLOADSTART call function and here place all

Thanks for the suggestion! im a newbie with SLS, learning now…

and how much is “we have lots”

At end of project will be 200 unique bitmaps x 4 different product brandings x 3 different display sizes and resolutions, so roughly 2400 bitmaps in sizes varying from 48x48 to 240x240, true color.

Much better storing those on external very fast NAND (eMMC 100 Mhz x 8 bit), so we can “reskin” a brand without pushing out a new code release.

I’d like to store them in raw binary (to avoid decode time), and give LVGL some image caching.