Browse Source

update eez-framework

master
Martin Vladic 2 years ago
parent
commit
593c1c833e
  1. 2
      .gitmodules
  2. 13
      CMakeLists.txt
  3. 1
      eez
  4. 1
      eez-framework
  5. 26
      lvgl-template-web.eez-project
  6. 11
      src/conf/eez/conf.h
  7. 2
      src/ui/actions.h
  8. 2
      src/ui/fonts.h
  9. 2
      src/ui/images.h
  10. 4
      src/ui/screens.c
  11. 2
      src/ui/screens.h
  12. 5
      src/ui/styles.c
  13. 16
      src/ui/styles.h

2
.gitmodules vendored

@ -1,5 +1,5 @@
[submodule "eez"]
path = eez
path = eez-framework
url = https://github.com/eez-open/eez-framework
[submodule "lvgl"]
path = lvgl

13
CMakeLists.txt

@ -25,20 +25,17 @@ list(APPEND SOURCES ${my_src})
if (${HAS_FLOW_SUPPORT})
################################################################################
# EEZ Framework
add_definitions(-DEEZ_PLATFORM_SIMULATOR)
add_definitions(-DEEZ_FOR_LVGL)
add_definitions(-DEEZ_OPTION_GUI=0)
include_directories(
./
./eez/libs/agg
./eez/platform/simulator
./src/conf
./eez-framework/src
./eez-framework/src/eez/libs/agg
./eez-framework/src/eez/platform/simulator
)
file(GLOB_RECURSE src_eez
./eez/*.cpp
./eez/*.c
./eez-framework/src/eez/*.cpp
./eez-framework/src/eez/*.c
)
list(APPEND SOURCES ${src_eez})

1
eez

@ -1 +0,0 @@
Subproject commit 3051f99c87634240d3e7af3c58d9f7594b267519

1
eez-framework

@ -0,0 +1 @@
Subproject commit e67a5a5008f34d6d19b08131e0807438998dfdc5

26
lvgl-template-web.eez-project

@ -1,5 +1,10 @@
{
"objID": "6666cd76-f969-5646-9e7b-e39d750cc7d9",
"lvglStyles": {
"objID": "a31bd004-35c5-b3fb-5c8b-78ea5c7693b8",
"styles": [],
"defaultStyles": {}
},
"settings": {
"objID": "e007d988-9fba-797d-72e9-efc33ca6d05c",
"general": {
@ -23,7 +28,7 @@
{
"objID": "05204dce-0fc5-4c81-b733-2ccc8e6c8671",
"fileName": "screens.h",
"template": "#ifndef EEZ_LVGL_UI_SCREENS_H\r\n#define EEZ_LVGL_UI_SCREENS_H\r\n\r\n#include \"lvgl/lvgl.h\"\r\n\r\n#ifdef __cplusplus\r\nextern \"C\" {\r\n#endif\r\n\r\n//${eez-studio LVGL_SCREENS_DECL}\r\n//${eez-studio LVGL_SCREENS_DECL_EXT}\r\n\r\n#ifdef __cplusplus\r\n}\r\n#endif\r\n\r\n#endif /*EEZ_LVGL_UI_SCREENS_H*/"
"template": "#ifndef EEZ_LVGL_UI_SCREENS_H\r\n#define EEZ_LVGL_UI_SCREENS_H\r\n\r\n//${eez-studio LVGL_INCLUDE}\r\n\r\n#ifdef __cplusplus\r\nextern \"C\" {\r\n#endif\r\n\r\n//${eez-studio LVGL_SCREENS_DECL}\r\n//${eez-studio LVGL_SCREENS_DECL_EXT}\r\n\r\n#ifdef __cplusplus\r\n}\r\n#endif\r\n\r\n#endif /*EEZ_LVGL_UI_SCREENS_H*/"
},
{
"objID": "2212bc5e-cf4a-4a81-c9ab-a671066d086f",
@ -33,7 +38,7 @@
{
"objID": "19d3d573-88a3-4550-f4da-753b61d7f0c4",
"fileName": "actions.h",
"template": "#ifndef EEZ_LVGL_UI_EVENTS_H\r\n#define EEZ_LVGL_UI_EVENTS_H\r\n\r\n#include \"lvgl/lvgl.h\"\r\n\r\n//${eez-studio LVGL_ACTIONS_DECL}\r\n\r\n#endif /*EEZ_LVGL_UI_EVENTS_H*/"
"template": "#ifndef EEZ_LVGL_UI_EVENTS_H\r\n#define EEZ_LVGL_UI_EVENTS_H\r\n\r\n//${eez-studio LVGL_INCLUDE}\r\n\r\n//${eez-studio LVGL_ACTIONS_DECL}\r\n\r\n#endif /*EEZ_LVGL_UI_EVENTS_H*/"
},
{
"objID": "e95514b3-1083-49b9-a4f6-847d4792f050",
@ -53,7 +58,7 @@
{
"objID": "81fa9cb7-33e4-4272-9340-49a50037b327",
"fileName": "images.h",
"template": "#ifndef EEZ_LVGL_UI_IMAGES_H\r\n#define EEZ_LVGL_UI_IMAGES_H\r\n\r\n#include \"lvgl/lvgl.h\"\r\n\r\n//${eez-studio LVGL_IMAGES_DECL}\r\n\r\n#endif /*EEZ_LVGL_UI_IMAGES_H*/"
"template": "#ifndef EEZ_LVGL_UI_IMAGES_H\r\n#define EEZ_LVGL_UI_IMAGES_H\r\n\r\n//${eez-studio LVGL_INCLUDE}\r\n\r\n//${eez-studio LVGL_IMAGES_DECL}\r\n\r\n#endif /*EEZ_LVGL_UI_IMAGES_H*/"
},
{
"objID": "5844b3a8-54b7-4bdf-ff04-d052e689328c",
@ -63,7 +68,17 @@
{
"objID": "bad0addd-10de-48f7-e57e-b40fce3e7c45",
"fileName": "fonts.h",
"template": "#ifndef EEZ_LVGL_UI_FONTS_H\r\n#define EEZ_LVGL_UI_FONTS_H\r\n\r\n#include \"lvgl/lvgl.h\"\r\n\r\n//${eez-studio LVGL_FONTS_DECL}\r\n\r\n#endif /*EEZ_LVGL_UI_FONTS_H*/"
"template": "#ifndef EEZ_LVGL_UI_FONTS_H\r\n#define EEZ_LVGL_UI_FONTS_H\r\n\r\n//${eez-studio LVGL_INCLUDE}\r\n\r\n//${eez-studio LVGL_FONTS_DECL}\r\n\r\n#endif /*EEZ_LVGL_UI_FONTS_H*/"
},
{
"objID": "4743460c-3867-4a04-9673-213804dc3078",
"fileName": "styles.h",
"template": "#ifndef EEZ_LVGL_UI_STYLES_H\r\n#define EEZ_LVGL_UI_STYLES_H\r\n\r\n//${eez-studio LVGL_INCLUDE}\r\n\r\n#ifdef __cplusplus\r\nextern \"C\" {\r\n#endif\r\n\r\n//${eez-studio LVGL_STYLES_DECL}\r\n\r\n#ifdef __cplusplus\r\n}\r\n#endif\r\n\r\n#endif /*EEZ_LVGL_UI_STYLES_H*/"
},
{
"objID": "d6250de9-847c-4f7f-ed5c-41e7134db9f1",
"fileName": "styles.c",
"template": "#include \"styles.h\"\n#include \"images.h\"\n#include \"fonts.h\"\n\n//${eez-studio LVGL_STYLES_DEF}\n"
},
{
"objID": "7bc0152a-1716-469c-a3f8-8346707369a1",
@ -76,7 +91,8 @@
"template": "#include \"ui.h\"\n#include \"screens.h\"\n#include \"images.h\"\n#include \"flow_def.h\"\n\nvoid ui_init() {\n eez_flow_init(assets, sizeof(assets), (lv_obj_t **)&objects, sizeof(objects), images, sizeof(images));\n}\n\nvoid ui_tick() {\n eez_flow_tick();\n tick_screen(g_currentScreen);\n}\n"
}
],
"destinationFolder": "src/ui"
"destinationFolder": "src/ui",
"lvglInclude": "lvgl/lvgl.h"
}
},
"variables": {

11
src/conf/eez/conf.h

@ -1,11 +0,0 @@
#pragma once
#include <stdint.h>
#define OPTION_KEYBOARD 0
#define OPTION_MOUSE 0
#define OPTION_KEYPAD 0
#define CUSTOM_VALUE_TYPES

2
src/ui/actions.h

@ -1,7 +1,7 @@
#ifndef EEZ_LVGL_UI_EVENTS_H
#define EEZ_LVGL_UI_EVENTS_H
#include "lvgl/lvgl.h"
#include <lvgl/lvgl.h>

2
src/ui/fonts.h

@ -1,7 +1,7 @@
#ifndef EEZ_LVGL_UI_FONTS_H
#define EEZ_LVGL_UI_FONTS_H
#include "lvgl/lvgl.h"
#include <lvgl/lvgl.h>
extern const lv_font_t ui_font_small_font;

2
src/ui/images.h

@ -1,7 +1,7 @@
#ifndef EEZ_LVGL_UI_IMAGES_H
#define EEZ_LVGL_UI_IMAGES_H
#include "lvgl/lvgl.h"
#include <lvgl/lvgl.h>
extern const lv_img_dsc_t img_log_eez;
extern const lv_img_dsc_t img_logo_lvgl;

4
src/ui/screens.c

@ -103,6 +103,10 @@ void tick_screen_main() {
void create_screens() {
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_disp_set_theme(dispp, theme);
create_screen_main();
}

2
src/ui/screens.h

@ -1,7 +1,7 @@
#ifndef EEZ_LVGL_UI_SCREENS_H
#define EEZ_LVGL_UI_SCREENS_H
#include "lvgl/lvgl.h"
#include <lvgl/lvgl.h>
#ifdef __cplusplus
extern "C" {

5
src/ui/styles.c

@ -0,0 +1,5 @@
#include "styles.h"
#include "images.h"
#include "fonts.h"

16
src/ui/styles.h

@ -0,0 +1,16 @@
#ifndef EEZ_LVGL_UI_STYLES_H
#define EEZ_LVGL_UI_STYLES_H
#include <lvgl/lvgl.h>
#ifdef __cplusplus
extern "C" {
#endif
#ifdef __cplusplus
}
#endif
#endif /*EEZ_LVGL_UI_STYLES_H*/
Loading…
Cancel
Save