Skip to content

Commit 7355204

Browse files
mbolivar-nordicnashif
authored andcommitted
samples: lvgl: add min_ram to adafruit_2_8_tft_touch_v2 test
Commit c79b1a3 ("samples: display: Convert driver and lvgl sample.yaml to use depends_on") started using depends_on in the sample YAML for a lvgl application instead of platform_allow. This breaks build testing with twister and overflow checking enabled on more resource constrained platforms. The test case's .config ends up with: CONFIG_LVGL_HOR_RES_MAX=320 CONFIG_LVGL_VER_RES_MAX=240 CONFIG_LVGL_VDB_SIZE=64 CONFIG_LVGL_BITS_PER_PIXEL=24 And lib/gui/lvgl/lvgl.c, where we allocate a buffer of size: (CONFIG_LVGL_BITS_PER_PIXEL * ((CONFIG_LVGL_VDB_SIZE * CONFIG_LVGL_HOR_RES_MAX * CONFIG_LVGL_VER_RES_MAX) / 100) / 8) Require 147456 bytes to build the sample, ultimately overflowing RAM if you run something along the lines of: twister -T samples -p <constrained_platform> --overflow-as-errors This is a reasonable test to be doing to make sure that sample RAM requirements do not get too big for a subset of platforms that are of interest, and it no longer works. To fix it, add a min_ram line for this case so that we can still run overflow tests on a large set of samples without fine-grained special casing or creating an ever-growing list of platform excludes for this test. Signed-off-by: Martí Bolívar <[email protected]>
1 parent cd0abb3 commit 7355204

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

samples/subsys/display/lvgl/sample.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ tests:
88
tags: samples display gui
99
sample.display.adafruit_2_8_tft_touch_v2:
1010
depends_on: arduino_gpio arduino_i2c arduino_spi
11+
# Default settings end up allocating an ~150KB sized buffer in lvgl.
12+
# This adds a bit of buffer to that for other data.
13+
min_ram: 175
1114
platform_exclude: reel_board reel_board_v2 ubx_evkannab1_nrf52832
1215
extra_args: SHIELD=adafruit_2_8_tft_touch_v2
1316
tags: shield

0 commit comments

Comments
 (0)