Browse Source

updated to eez-flow.cpp

master
Martin Vladic 1 month ago
parent
commit
b160027bed
  1. 2
      eez-framework
  2. 2
      lv_drivers
  3. 2
      lvgl
  4. 88
      lvgl-template-web.eez-project
  5. 10735
      src/ui/eez-flow.cpp
  6. 4757
      src/ui/eez-flow.h
  7. 33
      src/ui/screens.c
  8. 6
      src/ui/structs.h
  9. 103
      src/ui/ui.c
  10. 10
      src/ui/ui.h
  11. 7
      src/ui/ui_image_log_eez.c
  12. 7
      src/ui/ui_image_logo_lvgl.c

2
eez-framework

@ -1 +1 @@
Subproject commit c3e0ac049e0fda5a0d5518e2e00ee2f708099158 Subproject commit 30298c57c5bdb68891b585c121e403d094605478

2
lv_drivers

@ -1 +1 @@
Subproject commit be337d02ee797702f191499152db5f8c47e32d6e Subproject commit 8cdabe8d42bf798d5a31e75cbd5a2cd816c29e5c

2
lvgl

@ -1 +1 @@
Subproject commit e050f5ca156f79d752894f38f0a437c946205cb4 Subproject commit b55aad64f04867f86286651048577436e4073506

88
lvgl-template-web.eez-project

@ -1,9 +1,4 @@
{ {
"lvglStyles": {
"objID": "a31bd004-35c5-b3fb-5c8b-78ea5c7693b8",
"styles": [],
"defaultStyles": {}
},
"objID": "6666cd76-f969-5646-9e7b-e39d750cc7d9", "objID": "6666cd76-f969-5646-9e7b-e39d750cc7d9",
"settings": { "settings": {
"objID": "e007d988-9fba-797d-72e9-efc33ca6d05c", "objID": "e007d988-9fba-797d-72e9-efc33ca6d05c",
@ -17,12 +12,15 @@
"flowSupport": true, "flowSupport": true,
"displayWidth": 800, "displayWidth": 800,
"displayHeight": 480, "displayHeight": 480,
"displayBorderRadius": 0,
"colorFormat": "BGR", "colorFormat": "BGR",
"description": "LVGL project template for the web browser using emscripten", "description": "LVGL project template for the web browser using emscripten",
"keywords": "emscripten WebAssembly", "keywords": "emscripten WebAssembly",
"targetPlatform": "Emscripten is a complete compiler toolchain to WebAssembly, using LLVM, with a special focus on speed, size, and the Web platform.", "targetPlatform": "Emscripten is a complete compiler toolchain to WebAssembly, using LLVM, with a special focus on speed, size, and the Web platform.",
"targetPlatformLink": "https://emscripten.org/", "targetPlatformLink": "https://emscripten.org/",
"resourceFiles": [] "resourceFiles": [],
"hiddenWidgetLines": "dimmed",
"dimmedLinesOpacity": "20"
}, },
"build": { "build": {
"objID": "72794a43-a0fc-13c2-7eb5-67dd952141a4", "objID": "72794a43-a0fc-13c2-7eb5-67dd952141a4",
@ -41,7 +39,7 @@
{ {
"objID": "858cb4ca-4c93-4e70-eb13-b00319a7a8fe", "objID": "858cb4ca-4c93-4e70-eb13-b00319a7a8fe",
"fileName": "screens.c", "fileName": "screens.c",
"template": "#include \"screens.h\"\n#include \"images.h\"\n#include \"fonts.h\"\n#include \"actions.h\"\n#include \"vars.h\"\n#include \"styles.h\"\n#include \"ui.h\"\n\n//${eez-studio LVGL_SCREENS_DEF}\n//${eez-studio LVGL_SCREENS_DEF_EXT}" "template": "#include <string.h>\n\n#include \"screens.h\"\n#include \"images.h\"\n#include \"fonts.h\"\n#include \"actions.h\"\n#include \"vars.h\"\n#include \"styles.h\"\n#include \"ui.h\"\n\n//${eez-studio LVGL_SCREENS_DEF}\n//${eez-studio LVGL_SCREENS_DEF_EXT}"
}, },
{ {
"objID": "14c9d28d-8ac9-4833-fd9a-14c140afd98a", "objID": "14c9d28d-8ac9-4833-fd9a-14c140afd98a",
@ -95,7 +93,11 @@
} }
], ],
"destinationFolder": "src/ui", "destinationFolder": "src/ui",
"lvglInclude": "lvgl/lvgl.h" "lvglInclude": "lvgl/lvgl.h",
"generateSourceCodeForEezFramework": true,
"compressFlowDefinition": false,
"executionQueueSize": 1000,
"expressionEvaluatorStackSize": 20
} }
}, },
"variables": { "variables": {
@ -187,22 +189,23 @@
"widthUnit": "content", "widthUnit": "content",
"heightUnit": "content", "heightUnit": "content",
"children": [], "children": [],
"flags": "PRESS_LOCK|ADV_HITTEST|CLICK_FOCUSABLE|GESTURE_BUBBLE|SNAPPABLE|SCROLL_ELASTIC|SCROLL_MOMENTUM|SCROLL_CHAIN", "widgetFlags": "ADV_HITTEST|CLICK_FOCUSABLE|GESTURE_BUBBLE|PRESS_LOCK|SCROLLABLE|SCROLL_CHAIN_HOR|SCROLL_CHAIN_VER|SCROLL_ELASTIC|SCROLL_MOMENTUM|SCROLL_WITH_ARROW|SNAPPABLE",
"hiddenFlagType": "literal", "hiddenFlagType": "literal",
"clickableFlagType": "literal", "clickableFlagType": "literal",
"scrollbarMode": "auto",
"scrollDirection": "all",
"checkedStateType": "literal", "checkedStateType": "literal",
"disabledStateType": "literal", "disabledStateType": "literal",
"states": "", "states": "",
"localStyles": { "localStyles": {
"objID": "8a592882-0d02-46a5-80c3-df72553ddc61" "objID": "8a592882-0d02-46a5-80c3-df72553ddc61"
}, },
"groupIndex": 0,
"image": "log_eez", "image": "log_eez",
"setPivot": true,
"pivotX": 0, "pivotX": 0,
"pivotY": 0, "pivotY": 0,
"zoom": 256, "zoom": 256,
"angle": 0 "angle": 0,
"innerAlign": "CENTER"
}, },
{ {
"objID": "c3b00b12-28c7-4c95-d54a-bbe58f0c3104", "objID": "c3b00b12-28c7-4c95-d54a-bbe58f0c3104",
@ -226,22 +229,23 @@
"widthUnit": "content", "widthUnit": "content",
"heightUnit": "content", "heightUnit": "content",
"children": [], "children": [],
"flags": "PRESS_LOCK|ADV_HITTEST|CLICK_FOCUSABLE|GESTURE_BUBBLE|SNAPPABLE|SCROLL_ELASTIC|SCROLL_MOMENTUM|SCROLL_CHAIN", "widgetFlags": "ADV_HITTEST|CLICK_FOCUSABLE|GESTURE_BUBBLE|PRESS_LOCK|SCROLLABLE|SCROLL_CHAIN_HOR|SCROLL_CHAIN_VER|SCROLL_ELASTIC|SCROLL_MOMENTUM|SCROLL_WITH_ARROW|SNAPPABLE",
"hiddenFlagType": "literal", "hiddenFlagType": "literal",
"clickableFlagType": "literal", "clickableFlagType": "literal",
"scrollbarMode": "auto",
"scrollDirection": "all",
"checkedStateType": "literal", "checkedStateType": "literal",
"disabledStateType": "literal", "disabledStateType": "literal",
"states": "", "states": "",
"localStyles": { "localStyles": {
"objID": "2b4ba950-0529-413b-d378-02dd4fa19b30" "objID": "2b4ba950-0529-413b-d378-02dd4fa19b30"
}, },
"groupIndex": 0,
"image": "logo_lvgl", "image": "logo_lvgl",
"setPivot": true,
"pivotX": 0, "pivotX": 0,
"pivotY": 0, "pivotY": 0,
"zoom": 256, "zoom": 256,
"angle": 0 "angle": 0,
"innerAlign": "CENTER"
}, },
{ {
"objID": "1c46cbe3-936f-468e-d4d0-6b93e194ec80", "objID": "1c46cbe3-936f-468e-d4d0-6b93e194ec80",
@ -265,11 +269,9 @@
"widthUnit": "content", "widthUnit": "content",
"heightUnit": "content", "heightUnit": "content",
"children": [], "children": [],
"flags": "PRESS_LOCK|CLICK_FOCUSABLE|GESTURE_BUBBLE|SNAPPABLE|SCROLLABLE|SCROLL_ELASTIC|SCROLL_MOMENTUM|SCROLL_CHAIN", "widgetFlags": "CLICK_FOCUSABLE|GESTURE_BUBBLE|PRESS_LOCK|SCROLLABLE|SCROLL_CHAIN_HOR|SCROLL_CHAIN_VER|SCROLL_ELASTIC|SCROLL_MOMENTUM|SCROLL_WITH_ARROW|SNAPPABLE",
"hiddenFlagType": "literal", "hiddenFlagType": "literal",
"clickableFlagType": "literal", "clickableFlagType": "literal",
"scrollbarMode": "auto",
"scrollDirection": "all",
"checkedStateType": "literal", "checkedStateType": "literal",
"disabledStateType": "literal", "disabledStateType": "literal",
"states": "", "states": "",
@ -284,6 +286,7 @@
} }
} }
}, },
"groupIndex": 0,
"text": "counter", "text": "counter",
"textType": "expression", "textType": "expression",
"longMode": "WRAP", "longMode": "WRAP",
@ -309,7 +312,8 @@
{ {
"objID": "c43f76ad-7561-46e4-f050-34a8422526cb", "objID": "c43f76ad-7561-46e4-f050-34a8422526cb",
"eventName": "PRESSED", "eventName": "PRESSED",
"handlerType": "flow" "handlerType": "flow",
"userData": 0
} }
], ],
"leftUnit": "px", "leftUnit": "px",
@ -339,11 +343,9 @@
"widthUnit": "content", "widthUnit": "content",
"heightUnit": "content", "heightUnit": "content",
"children": [], "children": [],
"flags": "PRESS_LOCK|CLICK_FOCUSABLE|GESTURE_BUBBLE|SNAPPABLE|SCROLLABLE|SCROLL_ELASTIC|SCROLL_MOMENTUM|SCROLL_CHAIN", "widgetFlags": "CLICK_FOCUSABLE|GESTURE_BUBBLE|PRESS_LOCK|SCROLLABLE|SCROLL_CHAIN_HOR|SCROLL_CHAIN_VER|SCROLL_ELASTIC|SCROLL_MOMENTUM|SCROLL_WITH_ARROW|SNAPPABLE",
"hiddenFlagType": "literal", "hiddenFlagType": "literal",
"clickableFlagType": "literal", "clickableFlagType": "literal",
"scrollbarMode": "auto",
"scrollDirection": "all",
"checkedStateType": "literal", "checkedStateType": "literal",
"disabledStateType": "literal", "disabledStateType": "literal",
"states": "", "states": "",
@ -358,24 +360,24 @@
} }
} }
}, },
"groupIndex": 0,
"text": "+", "text": "+",
"textType": "literal", "textType": "literal",
"longMode": "WRAP", "longMode": "WRAP",
"recolor": false "recolor": false
} }
], ],
"flags": "PRESS_LOCK|CLICK_FOCUSABLE|GESTURE_BUBBLE|SNAPPABLE|SCROLL_ELASTIC|SCROLL_ON_FOCUS|SCROLL_MOMENTUM|SCROLL_CHAIN", "widgetFlags": "CLICKABLE|CLICK_FOCUSABLE|GESTURE_BUBBLE|PRESS_LOCK|SCROLL_CHAIN_HOR|SCROLL_CHAIN_VER|SCROLL_ELASTIC|SCROLL_MOMENTUM|SCROLL_ON_FOCUS|SCROLL_WITH_ARROW|SNAPPABLE",
"hiddenFlagType": "literal", "hiddenFlagType": "literal",
"clickableFlag": true, "clickableFlag": true,
"clickableFlagType": "literal", "clickableFlagType": "literal",
"scrollbarMode": "auto",
"scrollDirection": "all",
"checkedStateType": "literal", "checkedStateType": "literal",
"disabledStateType": "literal", "disabledStateType": "literal",
"states": "", "states": "",
"localStyles": { "localStyles": {
"objID": "77010546-38ab-4a5e-a04f-f3e55ab58dd2" "objID": "77010546-38ab-4a5e-a04f-f3e55ab58dd2"
} },
"groupIndex": 0
}, },
{ {
"objID": "e6c88623-2256-4771-f786-b5e6d356f35b", "objID": "e6c88623-2256-4771-f786-b5e6d356f35b",
@ -397,7 +399,8 @@
{ {
"objID": "c3538efb-e5bb-431b-9494-bc1c52dfc06d", "objID": "c3538efb-e5bb-431b-9494-bc1c52dfc06d",
"eventName": "PRESSED", "eventName": "PRESSED",
"handlerType": "flow" "handlerType": "flow",
"userData": 0
} }
], ],
"leftUnit": "px", "leftUnit": "px",
@ -427,11 +430,9 @@
"widthUnit": "content", "widthUnit": "content",
"heightUnit": "content", "heightUnit": "content",
"children": [], "children": [],
"flags": "PRESS_LOCK|CLICK_FOCUSABLE|GESTURE_BUBBLE|SNAPPABLE|SCROLLABLE|SCROLL_ELASTIC|SCROLL_MOMENTUM|SCROLL_CHAIN", "widgetFlags": "CLICK_FOCUSABLE|GESTURE_BUBBLE|PRESS_LOCK|SCROLLABLE|SCROLL_CHAIN_HOR|SCROLL_CHAIN_VER|SCROLL_ELASTIC|SCROLL_MOMENTUM|SCROLL_WITH_ARROW|SNAPPABLE",
"hiddenFlagType": "literal", "hiddenFlagType": "literal",
"clickableFlagType": "literal", "clickableFlagType": "literal",
"scrollbarMode": "auto",
"scrollDirection": "all",
"checkedStateType": "literal", "checkedStateType": "literal",
"disabledStateType": "literal", "disabledStateType": "literal",
"states": "", "states": "",
@ -446,38 +447,37 @@
} }
} }
}, },
"groupIndex": 0,
"text": "-", "text": "-",
"textType": "literal", "textType": "literal",
"longMode": "WRAP", "longMode": "WRAP",
"recolor": false "recolor": false
} }
], ],
"flags": "PRESS_LOCK|CLICK_FOCUSABLE|GESTURE_BUBBLE|SNAPPABLE|SCROLL_ELASTIC|SCROLL_ON_FOCUS|SCROLL_MOMENTUM|SCROLL_CHAIN", "widgetFlags": "CLICKABLE|CLICK_FOCUSABLE|GESTURE_BUBBLE|PRESS_LOCK|SCROLL_CHAIN_HOR|SCROLL_CHAIN_VER|SCROLL_ELASTIC|SCROLL_MOMENTUM|SCROLL_ON_FOCUS|SCROLL_WITH_ARROW|SNAPPABLE",
"hiddenFlagType": "literal", "hiddenFlagType": "literal",
"clickableFlag": true, "clickableFlag": true,
"clickableFlagType": "literal", "clickableFlagType": "literal",
"scrollbarMode": "auto",
"scrollDirection": "all",
"checkedStateType": "literal", "checkedStateType": "literal",
"disabledStateType": "literal", "disabledStateType": "literal",
"states": "", "states": "",
"localStyles": { "localStyles": {
"objID": "77010546-38ab-4a5e-a04f-f3e55ab58dd2" "objID": "77010546-38ab-4a5e-a04f-f3e55ab58dd2"
} },
"groupIndex": 0
} }
], ],
"flags": "PRESS_LOCK|CLICK_FOCUSABLE|GESTURE_BUBBLE|SNAPPABLE|SCROLL_ELASTIC|SCROLL_MOMENTUM|SCROLL_CHAIN", "widgetFlags": "CLICKABLE|PRESS_LOCK|CLICK_FOCUSABLE|GESTURE_BUBBLE|SNAPPABLE|SCROLLABLE|SCROLL_ELASTIC|SCROLL_MOMENTUM|SCROLL_CHAIN_HOR|SCROLL_CHAIN_VER",
"hiddenFlagType": "literal", "hiddenFlagType": "literal",
"clickableFlag": true, "clickableFlag": true,
"clickableFlagType": "literal", "clickableFlagType": "literal",
"scrollbarMode": "auto",
"scrollDirection": "all",
"checkedStateType": "literal", "checkedStateType": "literal",
"disabledStateType": "literal", "disabledStateType": "literal",
"states": "", "states": "",
"localStyles": { "localStyles": {
"objID": "a7b31582-66ef-c8bd-2d0d-602f921469e6" "objID": "a7b31582-66ef-c8bd-2d0d-602f921469e6"
} },
"groupIndex": 0
} }
], ],
"connectionLines": [ "connectionLines": [
@ -505,6 +505,7 @@
"persistent": false "persistent": false
} }
], ],
"userProperties": [],
"name": "Main", "name": "Main",
"left": 0, "left": 0,
"top": 0, "top": 0,
@ -513,6 +514,15 @@
} }
], ],
"userWidgets": [], "userWidgets": [],
"lvglStyles": {
"objID": "a31bd004-35c5-b3fb-5c8b-78ea5c7693b8",
"styles": [],
"defaultStyles": {}
},
"lvglGroups": {
"objID": "f2f79c21-8769-ed90-c624-7405d4136ec9",
"groups": []
},
"fonts": [ "fonts": [
{ {
"objID": "7a6ac63f-a101-4881-f6d7-0cd31cf44392", "objID": "7a6ac63f-a101-4881-f6d7-0cd31cf44392",

10735
src/ui/eez-flow.cpp

File diff suppressed because it is too large Load Diff

4757
src/ui/eez-flow.h

File diff suppressed because it is too large Load Diff

33
src/ui/screens.c

@ -1,3 +1,5 @@
#include <string.h>
#include "screens.h" #include "screens.h"
#include "images.h" #include "images.h"
#include "fonts.h" #include "fonts.h"
@ -6,22 +8,28 @@
#include "styles.h" #include "styles.h"
#include "ui.h" #include "ui.h"
#include <string.h>
objects_t objects; objects_t objects;
lv_obj_t *tick_value_change_obj; lv_obj_t *tick_value_change_obj;
static void event_handler_cb_main_obj1(lv_event_t *e) { static void event_handler_cb_main_obj1(lv_event_t *e) {
lv_event_code_t event = lv_event_get_code(e); lv_event_code_t event = lv_event_get_code(e);
void *flowState = e->user_data; void *flowState = lv_event_get_user_data(e);
if (event == LV_EVENT_PRESSED) { if (event == LV_EVENT_PRESSED) {
flowPropagateValue(flowState, 6, 0); e->user_data = (void *)0;
flowPropagateValueLVGLEvent(flowState, 6, 0, e);
} }
} }
static void event_handler_cb_main_obj2(lv_event_t *e) { static void event_handler_cb_main_obj2(lv_event_t *e) {
lv_event_code_t event = lv_event_get_code(e); lv_event_code_t event = lv_event_get_code(e);
void *flowState = e->user_data; void *flowState = lv_event_get_user_data(e);
if (event == LV_EVENT_PRESSED) { if (event == LV_EVENT_PRESSED) {
flowPropagateValue(flowState, 8, 0); e->user_data = (void *)0;
flowPropagateValueLVGLEvent(flowState, 8, 0, e);
} }
} }
@ -31,7 +39,6 @@ void create_screen_main() {
objects.main = obj; objects.main = obj;
lv_obj_set_pos(obj, 0, 0); lv_obj_set_pos(obj, 0, 0);
lv_obj_set_size(obj, 800, 480); lv_obj_set_size(obj, 800, 480);
lv_obj_clear_flag(obj, LV_OBJ_FLAG_SCROLLABLE);
{ {
lv_obj_t *parent_obj = obj; lv_obj_t *parent_obj = obj;
{ {
@ -39,16 +46,14 @@ void create_screen_main() {
lv_obj_set_pos(obj, 130, 79); lv_obj_set_pos(obj, 130, 79);
lv_obj_set_size(obj, LV_SIZE_CONTENT, LV_SIZE_CONTENT); lv_obj_set_size(obj, LV_SIZE_CONTENT, LV_SIZE_CONTENT);
lv_img_set_src(obj, &img_log_eez); lv_img_set_src(obj, &img_log_eez);
lv_obj_add_flag(obj, LV_OBJ_FLAG_ADV_HITTEST); lv_img_set_pivot(obj, 0, 0);
lv_obj_clear_flag(obj, LV_OBJ_FLAG_SCROLLABLE);
} }
{ {
lv_obj_t *obj = lv_img_create(parent_obj); lv_obj_t *obj = lv_img_create(parent_obj);
lv_obj_set_pos(obj, 457, 79); lv_obj_set_pos(obj, 457, 79);
lv_obj_set_size(obj, LV_SIZE_CONTENT, LV_SIZE_CONTENT); lv_obj_set_size(obj, LV_SIZE_CONTENT, LV_SIZE_CONTENT);
lv_img_set_src(obj, &img_logo_lvgl); lv_img_set_src(obj, &img_logo_lvgl);
lv_obj_add_flag(obj, LV_OBJ_FLAG_ADV_HITTEST); lv_img_set_pivot(obj, 0, 0);
lv_obj_clear_flag(obj, LV_OBJ_FLAG_SCROLLABLE);
} }
{ {
lv_obj_t *obj = lv_label_create(parent_obj); lv_obj_t *obj = lv_label_create(parent_obj);
@ -65,8 +70,6 @@ void create_screen_main() {
lv_obj_set_pos(obj, 268, 348); lv_obj_set_pos(obj, 268, 348);
lv_obj_set_size(obj, 100, 40); lv_obj_set_size(obj, 100, 40);
lv_obj_add_event_cb(obj, event_handler_cb_main_obj1, LV_EVENT_ALL, flowState); lv_obj_add_event_cb(obj, event_handler_cb_main_obj1, LV_EVENT_ALL, flowState);
lv_obj_add_flag(obj, LV_OBJ_FLAG_SCROLL_ON_FOCUS);
lv_obj_clear_flag(obj, LV_OBJ_FLAG_SCROLLABLE);
{ {
lv_obj_t *parent_obj = obj; lv_obj_t *parent_obj = obj;
{ {
@ -85,8 +88,6 @@ void create_screen_main() {
lv_obj_set_pos(obj, 408, 348); lv_obj_set_pos(obj, 408, 348);
lv_obj_set_size(obj, 100, 40); lv_obj_set_size(obj, 100, 40);
lv_obj_add_event_cb(obj, event_handler_cb_main_obj2, LV_EVENT_ALL, flowState); lv_obj_add_event_cb(obj, event_handler_cb_main_obj2, LV_EVENT_ALL, flowState);
lv_obj_add_flag(obj, LV_OBJ_FLAG_SCROLL_ON_FOCUS);
lv_obj_clear_flag(obj, LV_OBJ_FLAG_SCROLLABLE);
{ {
lv_obj_t *parent_obj = obj; lv_obj_t *parent_obj = obj;
{ {
@ -116,7 +117,13 @@ void tick_screen_main() {
} }
static const char *screen_names[] = { "Main" };
static const char *object_names[] = { "main", "obj0", "obj1", "obj2" };
void create_screens() { void create_screens() {
eez_flow_init_screen_names(screen_names, sizeof(screen_names) / sizeof(const char *));
eez_flow_init_object_names(object_names, sizeof(object_names) / sizeof(const char *));
lv_disp_t *dispp = lv_disp_get_default(); lv_disp_t *dispp = lv_disp_get_default();
lv_theme_t *theme = lv_theme_default_init(dispp, lv_palette_main(LV_PALETTE_BLUE), lv_palette_main(LV_PALETTE_RED), false, LV_FONT_DEFAULT); lv_theme_t *theme = lv_theme_default_init(dispp, lv_palette_main(LV_PALETTE_BLUE), lv_palette_main(LV_PALETTE_RED), false, LV_FONT_DEFAULT);
lv_disp_set_theme(dispp, theme); lv_disp_set_theme(dispp, theme);

6
src/ui/structs.h

@ -1,15 +1,11 @@
#ifndef EEZ_LVGL_UI_STRUCTS_H #ifndef EEZ_LVGL_UI_STRUCTS_H
#define EEZ_LVGL_UI_STRUCTS_H #define EEZ_LVGL_UI_STRUCTS_H
#if !defined(EEZ_FOR_LVGL) #include "eez-flow.h"
#warning "EEZ_FOR_LVGL is not enabled"
#define EEZ_FOR_LVGL
#endif
#if defined(EEZ_FOR_LVGL) #if defined(EEZ_FOR_LVGL)
#include <eez/flow/flow.h>
#include <stdint.h> #include <stdint.h>
#include <stdbool.h> #include <stdbool.h>

103
src/ui/ui.c

@ -9,68 +9,69 @@
#include "vars.h" #include "vars.h"
// ASSETS DEFINITION // ASSETS DEFINITION
const uint8_t assets[972] = { const uint8_t assets[980] = {
0x7E, 0x45, 0x45, 0x5A, 0x03, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00, 0x7E, 0x45, 0x45, 0x5A, 0x03, 0x00, 0x06, 0x00, 0x00, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00,
0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x20, 0x03, 0xE0, 0x01, 0x01, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x20, 0x03, 0xE0, 0x01, 0x01, 0x00, 0x00, 0x00, 0x24, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00,
0x20, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x1C, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x20, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x1C, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00,
0x3C, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00, 0x44, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00,
0x00, 0x00, 0xFF, 0xFF, 0x10, 0x00, 0x00, 0x00, 0x34, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x10, 0x00, 0x00, 0x00, 0x3C, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00,
0x34, 0x00, 0x00, 0x00, 0x0A, 0x00, 0x00, 0x00, 0x30, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x3C, 0x00, 0x00, 0x00, 0x0A, 0x00, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
0x50, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x10, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x58, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x18, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x64, 0x65, 0x66, 0x61, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x75, 0x6C, 0x74, 0x00, 0xFF, 0xFF, 0x08, 0x42, 0x2C, 0x00, 0x00, 0x00, 0x50, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x64, 0x65, 0x66, 0x61, 0x75, 0x6C, 0x74, 0x00, 0xFF, 0xFF, 0x08, 0x42,
0x74, 0x00, 0x00, 0x00, 0x90, 0x00, 0x00, 0x00, 0xAC, 0x00, 0x00, 0x00, 0xC8, 0x00, 0x00, 0x00, 0x2C, 0x00, 0x00, 0x00, 0x50, 0x00, 0x00, 0x00, 0x74, 0x00, 0x00, 0x00, 0x90, 0x00, 0x00, 0x00,
0xE4, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x1C, 0x01, 0x00, 0x00, 0x38, 0x01, 0x00, 0x00, 0xAC, 0x00, 0x00, 0x00, 0xC8, 0x00, 0x00, 0x00, 0xE4, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00,
0x54, 0x01, 0x00, 0x00, 0xEF, 0x03, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x58, 0x01, 0x00, 0x00, 0x1C, 0x01, 0x00, 0x00, 0x38, 0x01, 0x00, 0x00, 0x54, 0x01, 0x00, 0x00, 0xEF, 0x03, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x4C, 0x01, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x58, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0xFF, 0xFF, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x44, 0x01, 0x00, 0x00, 0xEF, 0x03, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x4C, 0x01, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
0x01, 0x00, 0x00, 0x00, 0x3C, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x44, 0x01, 0x00, 0x00, 0xEF, 0x03, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x3C, 0x01, 0x00, 0x00,
0x01, 0x00, 0x00, 0x00, 0x30, 0x01, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x30, 0x01, 0x00, 0x00,
0x28, 0x01, 0x00, 0x00, 0x20, 0x4E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x28, 0x01, 0x00, 0x00, 0x20, 0x4E, 0x00, 0x00,
0x03, 0x00, 0x00, 0x00, 0x18, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x18, 0x01, 0x00, 0x00,
0xFF, 0xFF, 0x00, 0x00, 0x21, 0x4E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x21, 0x4E, 0x00, 0x00,
0x03, 0x00, 0x00, 0x00, 0x04, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x04, 0x01, 0x00, 0x00,
0xFF, 0xFF, 0x00, 0x00, 0x21, 0x4E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x21, 0x4E, 0x00, 0x00,
0x03, 0x00, 0x00, 0x00, 0xF0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0xF0, 0x00, 0x00, 0x00,
0xFF, 0xFF, 0x00, 0x00, 0x22, 0x4E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x22, 0x4E, 0x00, 0x00,
0x04, 0x00, 0x00, 0x00, 0xDC, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0x00, 0x00, 0x00, 0xDC, 0x00, 0x00, 0x00,
0xFF, 0xFF, 0x00, 0x00, 0x23, 0x4E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x23, 0x4E, 0x00, 0x00,
0x03, 0x00, 0x00, 0x00, 0xCC, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0xD0, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0xCC, 0x00, 0x00, 0x00,
0xFF, 0xFF, 0x00, 0x00, 0x22, 0x4E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0xD0, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x22, 0x4E, 0x00, 0x00,
0x03, 0x00, 0x00, 0x00, 0xBC, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0xBC, 0x00, 0x00, 0x00,
0xFF, 0xFF, 0x00, 0x00, 0x23, 0x4E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x23, 0x4E, 0x00, 0x00,
0x03, 0x00, 0x00, 0x00, 0xA8, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0xAC, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0xA8, 0x00, 0x00, 0x00,
0xFF, 0xFF, 0x00, 0x00, 0x22, 0x4E, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0xAC, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x22, 0x4E, 0x00, 0x00,
0x03, 0x00, 0x00, 0x00, 0x98, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x00, 0x00, 0x98, 0x00, 0x00, 0x00,
0xFF, 0xFF, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x88, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x01, 0x00, 0x00, 0x00, 0x88, 0x00, 0x00, 0x00, 0x90, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0x00, 0x88, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x88, 0x00, 0x00, 0x00,
0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x90, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00,
0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00,
0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00,
0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00,
0x94, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x9C, 0x00, 0x00, 0x00, 0x9C, 0x00, 0x00, 0x00,
0x9C, 0x00, 0x00, 0x00, 0x9C, 0x00, 0x00, 0x00, 0x9C, 0x00, 0x00, 0x00, 0x9C, 0x00, 0x00, 0x00, 0x9C, 0x00, 0x00, 0x00, 0x9C, 0x00, 0x00, 0x00, 0x9C, 0x00, 0x00, 0x00, 0x9C, 0x00, 0x00, 0x00,
0x9C, 0x00, 0x00, 0x00, 0x9C, 0x00, 0x00, 0x00, 0x9C, 0x00, 0x00, 0x00, 0xA4, 0x00, 0x00, 0x00, 0x9C, 0x00, 0x00, 0x00, 0xA4, 0x00, 0x00, 0x00, 0xA4, 0x00, 0x00, 0x00, 0xA4, 0x00, 0x00, 0x00,
0xA4, 0x00, 0x00, 0x00, 0xA4, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x98, 0x00, 0x00, 0x00,
0x01, 0x00, 0x00, 0x00, 0x98, 0x00, 0x00, 0x00, 0x9C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x9C, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x98, 0x00, 0x00, 0x00, 0x94, 0x00, 0x00, 0x00, 0x98, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00,
0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00,
0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00,
0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00,
0x00, 0x40, 0x00, 0xE0, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00,
0x01, 0x00, 0x00, 0x00, 0x58, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00,
0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00,
0x00, 0xE0, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0x40, 0x00, 0xE0, 0x00, 0xE0, 0x00, 0x00,
0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0x40, 0x00, 0xF0, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x58, 0x00, 0x00, 0x00,
0x07, 0x00, 0x00, 0x00, 0x00, 0x40, 0x02, 0x00, 0x01, 0xC0, 0x00, 0xE0, 0x00, 0x40, 0x00, 0xF0, 0x00, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00,
0x07, 0x00, 0x00, 0x00, 0x00, 0x40, 0x02, 0x00, 0x00, 0xC0, 0x00, 0xE0, 0x08, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
0x08, 0x00, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x38, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00,
0x1C, 0x00, 0x00, 0x00, 0x28, 0x00, 0x00, 0x00, 0x03, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00, 0x40, 0x00, 0xF0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x40, 0x02, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x01, 0xC0, 0x00, 0xE0, 0x00, 0x40, 0x00, 0xF0, 0x07, 0x00, 0x00, 0x00, 0x00, 0x40, 0x02, 0x00,
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0xC0, 0x00, 0xE0, 0x08, 0x00, 0x00, 0x00, 0x08, 0x00, 0x00, 0x00, 0x01, 0x00, 0x01, 0x00,
0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x1C, 0x00, 0x00, 0x00, 0x28, 0x00, 0x00, 0x00,
0x03, 0x03, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, 0x07, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00
}; };
native_var_t native_vars[] = { native_var_t native_vars[] = {

10
src/ui/ui.h

@ -3,15 +3,9 @@
#include <lvgl/lvgl.h> #include <lvgl/lvgl.h>
#if !defined(EEZ_FOR_LVGL) #include "eez-flow.h"
#warning "EEZ_FOR_LVGL is not enabled"
#define EEZ_FOR_LVGL
#endif
#if defined(EEZ_FOR_LVGL)
#include <eez/flow/lvgl_api.h>
#endif
#if !defined(EEZ_FOR_LVGL) #if !defined(EEZ_FOR_LVGL)
#include "screens.h" #include "screens.h"
@ -21,7 +15,7 @@
extern "C" { extern "C" {
#endif #endif
extern const uint8_t assets[972]; extern const uint8_t assets[980];
void ui_init(); void ui_init();
void ui_tick(); void ui_tick();

7
src/ui/ui_image_log_eez.c

@ -5,6 +5,13 @@
#endif #endif
#endif #endif
#endif #endif
#ifdef __has_include
#if __has_include("lvgl.h")
#ifndef LV_LVGL_H_INCLUDE_SIMPLE
#define LV_LVGL_H_INCLUDE_SIMPLE
#endif
#endif
#endif
#if defined(LV_LVGL_H_INCLUDE_SIMPLE) #if defined(LV_LVGL_H_INCLUDE_SIMPLE)
#include "lvgl.h" #include "lvgl.h"

7
src/ui/ui_image_logo_lvgl.c

@ -5,6 +5,13 @@
#endif #endif
#endif #endif
#endif #endif
#ifdef __has_include
#if __has_include("lvgl.h")
#ifndef LV_LVGL_H_INCLUDE_SIMPLE
#define LV_LVGL_H_INCLUDE_SIMPLE
#endif
#endif
#endif
#if defined(LV_LVGL_H_INCLUDE_SIMPLE) #if defined(LV_LVGL_H_INCLUDE_SIMPLE)
#include "lvgl.h" #include "lvgl.h"

Loading…
Cancel
Save