1.. zephyr:code-sample:: lvgl-demos 2 :name: LVGL demos 3 :relevant-api: display_interface 4 5 Run LVGL built-in demos. 6 7Overview 8******** 9 10A sample showcasing upstream LVGL demos. 11 12* Music 13 The music player demo shows what kind of modern, smartphone-like user interfaces can be created on LVGL. 14* Benchmark 15 The benchmark demo tests the performance in various cases. For example rectangle, border, shadow, text, image blending, image transformation, blending modes, etc. 16* Stress 17 A stress test for LVGL. It contains a lot of object creation, deletion, animations, styles usage, and so on. It can be used if there is any memory corruption during heavy usage or any memory leaks. 18* Widgets 19 Shows how the widgets look like out of the box using the built-in material theme. 20 21More details can be found in `LVGL demos Readme`_. 22 23Requirements 24************ 25 26* A board with display, ideally with 480x272 resolution or higher. 27* A pointer input device: touchpad, mouse, or touch screen capable display, compatible with :dtcompatible:`zephyr,lvgl-pointer-input`. 28 29Note that other input devices types are not demonstrated in these demos, namely keyboards, keypads (:dtcompatible:`zephyr,lvgl-keypad-input`), rotary encoders (:dtcompatible:`zephyr,lvgl-encoder-input`) and hardware buttons (:dtcompatible:`zephyr,lvgl-button-input`). 30 31Building and Running 32******************** 33 34Example building for :ref:`mimxrt1060_evk`: 35 36.. zephyr-app-commands:: 37 :zephyr-app: samples/modules/lvgl/demos 38 :board: mimxrt1060_evk 39 :goals: build flash 40 41These demos can be built for simulated display environment as follows: 42 43.. zephyr-app-commands:: 44 :zephyr-app: samples/modules/lvgl/demos 45 :host-os: unix 46 :board: native_sim 47 :gen-args: -DCONFIG_LV_Z_DEMO_MUSIC=y 48 :goals: run 49 :compact: 50 51.. zephyr-app-commands:: 52 :zephyr-app: samples/modules/lvgl/demos 53 :host-os: unix 54 :board: native_sim 55 :gen-args: -DCONFIG_LV_Z_DEMO_BENCHMARK=y 56 :goals: run 57 :compact: 58 59.. zephyr-app-commands:: 60 :zephyr-app: samples/modules/lvgl/demos 61 :host-os: unix 62 :board: native_sim 63 :gen-args: -DCONFIG_LV_Z_DEMO_STRESS=y 64 :goals: run 65 :compact: 66 67.. zephyr-app-commands:: 68 :zephyr-app: samples/modules/lvgl/demos 69 :host-os: unix 70 :board: native_sim 71 :gen-args: -DCONFIG_LV_Z_DEMO_WIDGETS=y 72 :goals: run 73 :compact: 74 75Alternatively, if building from a 64-bit host machine, the previous target 76board argument may also be replaced by ``native_sim/native/64``. 77 78References 79********** 80 81.. _LVGL demos Readme: https://github.com/zephyrproject-rtos/lvgl/blob/zephyr/demos/README.md 82