mirror of
https://github.com/arendst/Tasmota.git
synced 2025-04-24 14:57:16 +00:00
Merge pull request #13255 from s-hadinger/lvgl8
LVGL updated to v8.0.2 **breaking changes**
This commit is contained in:
commit
d82bf5fa59
@ -4,6 +4,8 @@ All notable changes to this project will be documented in this file.
|
||||
## [Unreleased] - Development
|
||||
|
||||
## [9.5.0.9]
|
||||
### Changed
|
||||
- LVGL updated to v8.0.2 **breaking changes**
|
||||
|
||||
## [9.5.0.8] 20210927
|
||||
### Added
|
||||
|
@ -34,14 +34,13 @@ int32_t bin_search_ctypes(const char * needle, const void * table, size_t elt_si
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
enum {
|
||||
ctypes_i32 = 14,
|
||||
ctypes_i16 = 12,
|
||||
ctypes_i8 = 11,
|
||||
ctypes_u32 = 4,
|
||||
ctypes_u16 = 2,
|
||||
ctypes_u8 = 1,
|
||||
ctypes_i32 = 14,
|
||||
ctypes_i16 = 12,
|
||||
ctypes_i8 = 11,
|
||||
ctypes_u32 = 4,
|
||||
ctypes_u16 = 2,
|
||||
ctypes_u8 = 1,
|
||||
|
||||
// big endian
|
||||
ctypes_be_i32 = -14,
|
||||
@ -52,10 +51,14 @@ enum {
|
||||
ctypes_be_u8 = -1,
|
||||
|
||||
// floating point
|
||||
ctypes_float = 5,
|
||||
ctypes_double = 10,
|
||||
ctypes_float = 5,
|
||||
ctypes_double = 10,
|
||||
|
||||
ctypes_bf = 0, //bif-field
|
||||
// pointer
|
||||
ctypes_ptr32 = 9,
|
||||
ctypes_ptr64 = -9,
|
||||
|
||||
ctypes_bf = 0, //bif-field
|
||||
};
|
||||
|
||||
typedef struct be_ctypes_structure_item_t {
|
||||
@ -93,12 +96,17 @@ typedef struct be_ctypes_classes_t {
|
||||
// If no arg: allocate a bytes() structure of the right size, filled with zeroes
|
||||
// Arg1 is instance self
|
||||
// If arg 2 is int or comptr (and not null): create a mapped bytes buffer to read/write at a specific location (can be copied if need a snapshot)
|
||||
// If arg 2 is a bytes object, consider it's comptr and map the buffer (it's basically casting). WARNING no size check is done so you can easily corrupt memory
|
||||
int be_ctypes_init(bvm *vm) {
|
||||
int argc = be_top(vm);
|
||||
void * src_data = NULL;
|
||||
if (argc > 1 && (be_isint(vm, 2) || be_iscomptr(vm, 2))) {
|
||||
if (argc > 1 && (be_isint(vm, 2) || be_iscomptr(vm, 2) || be_isbytes(vm, 2))) {
|
||||
if (be_iscomptr(vm, 2)) {
|
||||
src_data = be_tocomptr(vm, 2);
|
||||
} else if (be_isbytes(vm, 2)) {
|
||||
be_getmember(vm, 2, ".p");
|
||||
src_data = be_tocomptr(vm, -1);
|
||||
be_pop(vm, 1);
|
||||
} else {
|
||||
src_data = (void*) be_toint(vm, 2);
|
||||
}
|
||||
@ -213,6 +221,17 @@ int be_ctypes_member(bvm *vm) {
|
||||
be_pop(vm, 1);
|
||||
float *fval = (float*) &val; // type wizardry
|
||||
be_pushreal(vm, *fval);
|
||||
} else if (ctypes_ptr32 == member->type) {
|
||||
be_getmember(vm, 1, "geti"); // self.get or self.geti
|
||||
be_pushvalue(vm, 1); // push self
|
||||
be_pushint(vm, member->offset_bytes);
|
||||
be_pushint(vm, 4); // size is 4 bytes TODO 32 bits only supported here
|
||||
be_call(vm, 3);
|
||||
be_pop(vm, 3);
|
||||
// convert to ptr
|
||||
int32_t val = be_toint(vm, -1);
|
||||
be_pop(vm, 1);
|
||||
be_pushcomptr(vm, (void*) val);
|
||||
} else {
|
||||
// general int support
|
||||
int size = member->type; // eventually 1/2/4, positive if little endian, negative if big endian
|
||||
@ -318,6 +337,23 @@ int be_ctypes_setmember(bvm *vm) {
|
||||
be_call(vm, 4);
|
||||
be_pop(vm, 5);
|
||||
be_return_nil(vm);
|
||||
} else if (ctypes_ptr32 == member->type) {
|
||||
// Note: 64 bits pointer not supported
|
||||
int32_t ptr;
|
||||
if (be_iscomptr(vm, 3)) {
|
||||
ptr = (int32_t) be_tocomptr(vm, 3);
|
||||
} else {
|
||||
ptr = be_toint(vm, 3);
|
||||
}
|
||||
// set
|
||||
be_getmember(vm, 1, "seti");
|
||||
be_pushvalue(vm, 1); // push self
|
||||
be_pushint(vm, member->offset_bytes);
|
||||
be_pushint(vm, ptr);
|
||||
be_pushint(vm, 4); // size is 4 bytes - 64 bits not suppported
|
||||
be_call(vm, 4);
|
||||
be_pop(vm, 5);
|
||||
be_return_nil(vm);
|
||||
} else {
|
||||
// general int support
|
||||
int size = member->type; // eventually 1/2/4, positive if little endian, negative if big endian
|
||||
|
@ -16,72 +16,72 @@ const be_ctypes_structure_t be_energy_struct = {
|
||||
66, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[66]) {
|
||||
{ "active_power", 24, 0, 0, 5, 0 },
|
||||
{ "active_power_2", 28, 0, 0, 5, 0 },
|
||||
{ "active_power_3", 32, 0, 0, 5, 0 },
|
||||
{ "apparent_power", 36, 0, 0, 5, 0 },
|
||||
{ "apparent_power_2", 40, 0, 0, 5, 0 },
|
||||
{ "apparent_power_3", 44, 0, 0, 5, 0 },
|
||||
{ "command_code", 125, 0, 0, 1, 0 },
|
||||
{ "current", 12, 0, 0, 5, 0 },
|
||||
{ "current_2", 16, 0, 0, 5, 0 },
|
||||
{ "current_3", 20, 0, 0, 5, 0 },
|
||||
{ "current_available", 135, 0, 0, 1, 0 },
|
||||
{ "daily", 100, 0, 0, 5, 0 },
|
||||
{ "data_valid", 126, 0, 0, 1, 0 },
|
||||
{ "data_valid_2", 127, 0, 0, 1, 0 },
|
||||
{ "data_valid_3", 128, 0, 0, 1, 0 },
|
||||
{ "export_active", 84, 0, 0, 5, 0 },
|
||||
{ "export_active_2", 88, 0, 0, 5, 0 },
|
||||
{ "export_active_3", 92, 0, 0, 5, 0 },
|
||||
{ "fifth_second", 124, 0, 0, 1, 0 },
|
||||
{ "frequency", 72, 0, 0, 5, 0 },
|
||||
{ "frequency_2", 76, 0, 0, 5, 0 },
|
||||
{ "frequency_3", 80, 0, 0, 5, 0 },
|
||||
{ "frequency_common", 131, 0, 0, 1, 0 },
|
||||
{ "max_current_flag", 162, 0, 0, 1, 0 },
|
||||
{ "max_energy_state", 169, 0, 0, 1, 0 },
|
||||
{ "max_power_flag", 158, 0, 0, 1, 0 },
|
||||
{ "max_voltage_flag", 160, 0, 0, 1, 0 },
|
||||
{ "min_current_flag", 161, 0, 0, 1, 0 },
|
||||
{ "min_power_flag", 157, 0, 0, 1, 0 },
|
||||
{ "min_voltage_flag", 159, 0, 0, 1, 0 },
|
||||
{ "mplh_counter", 164, 0, 0, 2, 0 },
|
||||
{ "mplr_counter", 168, 0, 0, 1, 0 },
|
||||
{ "mplw_counter", 166, 0, 0, 2, 0 },
|
||||
{ "period", 120, 0, 0, 4, 0 },
|
||||
{ "phase_count", 129, 0, 0, 1, 0 },
|
||||
{ "power_factor", 60, 0, 0, 5, 0 },
|
||||
{ "power_factor_2", 64, 0, 0, 5, 0 },
|
||||
{ "power_factor_3", 68, 0, 0, 5, 0 },
|
||||
{ "power_history_0", 138, 0, 0, 2, 0 },
|
||||
{ "power_history_0_2", 140, 0, 0, 2, 0 },
|
||||
{ "power_history_0_3", 142, 0, 0, 2, 0 },
|
||||
{ "power_history_1", 144, 0, 0, 2, 0 },
|
||||
{ "power_history_1_2", 146, 0, 0, 2, 0 },
|
||||
{ "power_history_1_3", 148, 0, 0, 2, 0 },
|
||||
{ "power_history_2", 150, 0, 0, 2, 0 },
|
||||
{ "power_history_2_2", 152, 0, 0, 2, 0 },
|
||||
{ "power_history_2_3", 154, 0, 0, 2, 0 },
|
||||
{ "power_on", 137, 0, 0, 1, 0 },
|
||||
{ "power_steady_counter", 156, 0, 0, 1, 0 },
|
||||
{ "reactive_power", 48, 0, 0, 5, 0 },
|
||||
{ "reactive_power_2", 52, 0, 0, 5, 0 },
|
||||
{ "reactive_power_3", 56, 0, 0, 5, 0 },
|
||||
{ "start_energy", 96, 0, 0, 5, 0 },
|
||||
{ "stuff", 163, 0, 0, 1, 0 },
|
||||
{ "today_delta_kwh", 108, 0, 0, 4, 0 },
|
||||
{ "today_kwh", 116, 0, 0, 4, 0 },
|
||||
{ "today_offset_init_kwh", 133, 0, 0, 1, 0 },
|
||||
{ "today_offset_kwh", 112, 0, 0, 4, 0 },
|
||||
{ "total", 104, 0, 0, 5, 0 },
|
||||
{ "type_dc", 136, 0, 0, 1, 0 },
|
||||
{ "use_overtemp", 132, 0, 0, 1, 0 },
|
||||
{ "voltage", 0, 0, 0, 5, 0 },
|
||||
{ "voltage_2", 4, 0, 0, 5, 0 },
|
||||
{ "voltage_3", 8, 0, 0, 5, 0 },
|
||||
{ "voltage_available", 134, 0, 0, 1, 0 },
|
||||
{ "voltage_common", 130, 0, 0, 1, 0 },
|
||||
{ "active_power", 24, 0, 0, ctypes_float, 0 },
|
||||
{ "active_power_2", 28, 0, 0, ctypes_float, 0 },
|
||||
{ "active_power_3", 32, 0, 0, ctypes_float, 0 },
|
||||
{ "apparent_power", 36, 0, 0, ctypes_float, 0 },
|
||||
{ "apparent_power_2", 40, 0, 0, ctypes_float, 0 },
|
||||
{ "apparent_power_3", 44, 0, 0, ctypes_float, 0 },
|
||||
{ "command_code", 125, 0, 0, ctypes_u8, 0 },
|
||||
{ "current", 12, 0, 0, ctypes_float, 0 },
|
||||
{ "current_2", 16, 0, 0, ctypes_float, 0 },
|
||||
{ "current_3", 20, 0, 0, ctypes_float, 0 },
|
||||
{ "current_available", 135, 0, 0, ctypes_u8, 0 },
|
||||
{ "daily", 100, 0, 0, ctypes_float, 0 },
|
||||
{ "data_valid", 126, 0, 0, ctypes_u8, 0 },
|
||||
{ "data_valid_2", 127, 0, 0, ctypes_u8, 0 },
|
||||
{ "data_valid_3", 128, 0, 0, ctypes_u8, 0 },
|
||||
{ "export_active", 84, 0, 0, ctypes_float, 0 },
|
||||
{ "export_active_2", 88, 0, 0, ctypes_float, 0 },
|
||||
{ "export_active_3", 92, 0, 0, ctypes_float, 0 },
|
||||
{ "fifth_second", 124, 0, 0, ctypes_u8, 0 },
|
||||
{ "frequency", 72, 0, 0, ctypes_float, 0 },
|
||||
{ "frequency_2", 76, 0, 0, ctypes_float, 0 },
|
||||
{ "frequency_3", 80, 0, 0, ctypes_float, 0 },
|
||||
{ "frequency_common", 131, 0, 0, ctypes_u8, 0 },
|
||||
{ "max_current_flag", 162, 0, 0, ctypes_u8, 0 },
|
||||
{ "max_energy_state", 169, 0, 0, ctypes_u8, 0 },
|
||||
{ "max_power_flag", 158, 0, 0, ctypes_u8, 0 },
|
||||
{ "max_voltage_flag", 160, 0, 0, ctypes_u8, 0 },
|
||||
{ "min_current_flag", 161, 0, 0, ctypes_u8, 0 },
|
||||
{ "min_power_flag", 157, 0, 0, ctypes_u8, 0 },
|
||||
{ "min_voltage_flag", 159, 0, 0, ctypes_u8, 0 },
|
||||
{ "mplh_counter", 164, 0, 0, ctypes_u16, 0 },
|
||||
{ "mplr_counter", 168, 0, 0, ctypes_u8, 0 },
|
||||
{ "mplw_counter", 166, 0, 0, ctypes_u16, 0 },
|
||||
{ "period", 120, 0, 0, ctypes_u32, 0 },
|
||||
{ "phase_count", 129, 0, 0, ctypes_u8, 0 },
|
||||
{ "power_factor", 60, 0, 0, ctypes_float, 0 },
|
||||
{ "power_factor_2", 64, 0, 0, ctypes_float, 0 },
|
||||
{ "power_factor_3", 68, 0, 0, ctypes_float, 0 },
|
||||
{ "power_history_0", 138, 0, 0, ctypes_u16, 0 },
|
||||
{ "power_history_0_2", 140, 0, 0, ctypes_u16, 0 },
|
||||
{ "power_history_0_3", 142, 0, 0, ctypes_u16, 0 },
|
||||
{ "power_history_1", 144, 0, 0, ctypes_u16, 0 },
|
||||
{ "power_history_1_2", 146, 0, 0, ctypes_u16, 0 },
|
||||
{ "power_history_1_3", 148, 0, 0, ctypes_u16, 0 },
|
||||
{ "power_history_2", 150, 0, 0, ctypes_u16, 0 },
|
||||
{ "power_history_2_2", 152, 0, 0, ctypes_u16, 0 },
|
||||
{ "power_history_2_3", 154, 0, 0, ctypes_u16, 0 },
|
||||
{ "power_on", 137, 0, 0, ctypes_u8, 0 },
|
||||
{ "power_steady_counter", 156, 0, 0, ctypes_u8, 0 },
|
||||
{ "reactive_power", 48, 0, 0, ctypes_float, 0 },
|
||||
{ "reactive_power_2", 52, 0, 0, ctypes_float, 0 },
|
||||
{ "reactive_power_3", 56, 0, 0, ctypes_float, 0 },
|
||||
{ "start_energy", 96, 0, 0, ctypes_float, 0 },
|
||||
{ "stuff", 163, 0, 0, ctypes_u8, 0 },
|
||||
{ "today_delta_kwh", 108, 0, 0, ctypes_u32, 0 },
|
||||
{ "today_kwh", 116, 0, 0, ctypes_u32, 0 },
|
||||
{ "today_offset_init_kwh", 133, 0, 0, ctypes_u8, 0 },
|
||||
{ "today_offset_kwh", 112, 0, 0, ctypes_u32, 0 },
|
||||
{ "total", 104, 0, 0, ctypes_float, 0 },
|
||||
{ "type_dc", 136, 0, 0, ctypes_u8, 0 },
|
||||
{ "use_overtemp", 132, 0, 0, ctypes_u8, 0 },
|
||||
{ "voltage", 0, 0, 0, ctypes_float, 0 },
|
||||
{ "voltage_2", 4, 0, 0, ctypes_float, 0 },
|
||||
{ "voltage_3", 8, 0, 0, ctypes_float, 0 },
|
||||
{ "voltage_available", 134, 0, 0, ctypes_u8, 0 },
|
||||
{ "voltage_common", 130, 0, 0, ctypes_u8, 0 },
|
||||
}};
|
||||
|
||||
static const char * be_ctypes_instance_mappings[] = {
|
||||
|
@ -1,154 +0,0 @@
|
||||
/********************************************************************
|
||||
* Tasmota LVGL callbacks
|
||||
*
|
||||
*******************************************************************/
|
||||
#include "be_constobj.h"
|
||||
|
||||
extern int lv0_init(bvm *vm);
|
||||
extern int lvx_tostring(bvm *vm);
|
||||
extern int be_call_c_func(bvm *vm, void * func, const char * return_type, const char * arg_type);
|
||||
|
||||
|
||||
int lv_cb_call_any(bvm *vm, const char * return_type, const char * arg_type) {
|
||||
int argc = be_top(vm);
|
||||
// get pointer to callback
|
||||
be_getmember(vm, 1, ".p");
|
||||
void * cb = be_tocomptr(vm, -1);
|
||||
be_pop(vm, 1);
|
||||
// remove first argument which is the instance `self`
|
||||
for (int i=1; i<argc; i++) {
|
||||
be_moveto(vm, i+1, i);
|
||||
}
|
||||
be_pop(vm, 1);
|
||||
// call callback
|
||||
return be_call_c_func(vm, cb, return_type, arg_type);
|
||||
}
|
||||
|
||||
int lv_cb_call(bvm *vm) {
|
||||
return lv_cb_call_any(vm, "i", NULL);
|
||||
}
|
||||
|
||||
// 'lv_group_focus_cb'
|
||||
// typedef void (*lv_group_focus_cb_t)(struct _lv_group_t *);
|
||||
int lv_group_focus_cb_call(bvm *vm) {
|
||||
return lv_cb_call_any(vm, "", "(lv_group)");
|
||||
}
|
||||
|
||||
// 'lv_event_cb'
|
||||
// typedef void (*lv_event_cb_t)(struct _lv_obj_t * obj, lv_event_t event);
|
||||
int lv_event_cb_call(bvm *vm) {
|
||||
return lv_cb_call_any(vm, "", "(lv_obj)");
|
||||
}
|
||||
|
||||
// 'lv_signal_cb'
|
||||
// typedef lv_res_t (*lv_signal_cb_t)(struct _lv_obj_t * obj, lv_signal_t sign, void * param);
|
||||
int lv_signal_cb_call(bvm *vm) {
|
||||
return lv_cb_call_any(vm, "i", "(lv_obj)i.");
|
||||
}
|
||||
|
||||
// 'lv_design_cb'
|
||||
// typedef lv_design_res_t (*lv_design_cb_t)(struct _lv_obj_t * obj, const lv_area_t * clip_area, lv_design_mode_t mode);
|
||||
int lv_design_cb_call(bvm *vm) {
|
||||
return lv_cb_call_any(vm, "i", "(lv_obj)(lv_area)i");
|
||||
}
|
||||
|
||||
// 'lv_gauge_format_cb'
|
||||
// typedef void (*lv_gauge_format_cb_t)(lv_obj_t * gauge, char * buf, int bufsize, int32_t value);
|
||||
int lv_gauge_format_cb_call(bvm *vm) {
|
||||
return lv_cb_call_any(vm, "", "(lv_obj).ii");
|
||||
}
|
||||
|
||||
|
||||
#if BE_USE_PRECOMPILED_OBJECT
|
||||
#include "../generate/be_fixed_be_lvgl_cb.h"
|
||||
#endif
|
||||
|
||||
void be_load_lvgl_cb_lib(bvm *vm) {
|
||||
#if !BE_USE_PRECOMPILED_OBJECT
|
||||
static const bnfuncinfo members[] = {
|
||||
{ ".p", NULL },
|
||||
{ "init", lv0_init },
|
||||
{ "tostring", lvx_tostring },
|
||||
{ "()", lv_cb_call },
|
||||
|
||||
// { NULL, (bntvfunc) BE_CLOSURE }, /* mark section for berry closures */
|
||||
// { "get_tasmota", (bntvfunc) &get_tasmota_closure },
|
||||
// { "add_cmd", (bntvfunc) &add_cmd_closure },
|
||||
|
||||
{ NULL, NULL }
|
||||
};
|
||||
be_regclass(vm, "lv_cb", members);
|
||||
#else
|
||||
be_pushntvclass(vm, &be_lvgl_cb);
|
||||
be_setglobal(vm, "lv_cb");
|
||||
be_pop(vm, 1);
|
||||
#endif
|
||||
}
|
||||
/* @const_object_info_begin
|
||||
|
||||
class be_lvgl_cb (scope: global, name: lv_cb) {
|
||||
.p, var
|
||||
init, func(lv0_init)
|
||||
tostring, func(lvx_tostring)
|
||||
call, func(lv_cb_call)
|
||||
}
|
||||
@const_object_info_end */
|
||||
|
||||
// instanciate all callbacks as sub-classes
|
||||
// 'lv_group_focus_cb'
|
||||
// 'lv_event_cb'
|
||||
// 'lv_signal_cb'
|
||||
// 'lv_design_cb'
|
||||
// 'lv_gauge_format_cb'
|
||||
//
|
||||
|
||||
#include "../generate/be_fixed_be_lv_group_focus_cb.h"
|
||||
#include "../generate/be_fixed_be_lv_event_cb.h"
|
||||
#include "../generate/be_fixed_be_lv_signal_cb.h"
|
||||
#include "../generate/be_fixed_be_lv_design_cb.h"
|
||||
#include "../generate/be_fixed_be_lv_gauge_format_cb.h"
|
||||
|
||||
void be_load_lvgl_cb_all_lib(bvm *vm) {
|
||||
be_pushntvclass(vm, &be_lv_group_focus_cb);
|
||||
be_setglobal(vm, "lv_group_focus_cb");
|
||||
be_pop(vm, 1);
|
||||
|
||||
be_pushntvclass(vm, &be_lv_event_cb);
|
||||
be_setglobal(vm, "lv_event_cb");
|
||||
be_pop(vm, 1);
|
||||
|
||||
be_pushntvclass(vm, &be_lv_signal_cb);
|
||||
be_setglobal(vm, "lv_signal_cb");
|
||||
be_pop(vm, 1);
|
||||
|
||||
be_pushntvclass(vm, &be_lv_design_cb);
|
||||
be_setglobal(vm, "lv_design_cb");
|
||||
be_pop(vm, 1);
|
||||
|
||||
be_pushntvclass(vm, &be_lv_gauge_format_cb);
|
||||
be_setglobal(vm, "lv_gauge_format_cb");
|
||||
be_pop(vm, 1);
|
||||
}
|
||||
/* @const_object_info_begin
|
||||
|
||||
class be_lv_group_focus_cb (scope: global, name: lv_group_focus_cb, super: be_lvgl_cb) {
|
||||
call, func(lv_group_focus_cb_call)
|
||||
}
|
||||
|
||||
class be_lv_event_cb (scope: global, name: lv_event_cb, super: be_lvgl_cb) {
|
||||
call, func(lv_event_cb_call)
|
||||
}
|
||||
|
||||
class be_lv_signal_cb (scope: global, name: lv_signal_cb, super: be_lvgl_cb) {
|
||||
call, func(lv_signal_cb_call)
|
||||
}
|
||||
|
||||
class be_lv_design_cb (scope: global, name: lv_design_cb, super: be_lvgl_cb) {
|
||||
call, func(lv_design_cb_call)
|
||||
}
|
||||
|
||||
class be_lv_gauge_format_cb (scope: global, name: lv_gauge_format_cb, super: be_lvgl_cb) {
|
||||
call, func(lv_gauge_format_cb_call)
|
||||
}
|
||||
|
||||
@const_object_info_end */
|
@ -123,7 +123,7 @@ be_local_closure(every_second, /* name */
|
||||
********************************************************************/
|
||||
be_local_closure(init, /* name */
|
||||
be_nested_proto(
|
||||
13, /* nstack */
|
||||
12, /* nstack */
|
||||
3, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
@ -131,32 +131,33 @@ be_local_closure(init, /* name */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[21]) { /* constants */
|
||||
( &(const bvalue[22]) { /* constants */
|
||||
/* K0 */ be_nested_string("init", 380752755, 4),
|
||||
/* K1 */ be_nested_string("lv", 1529997255, 2),
|
||||
/* K2 */ be_nested_string("seg7_font", -195276607, 9),
|
||||
/* K3 */ be_nested_string("set_style_local_text_font", 954295699, 25),
|
||||
/* K4 */ be_nested_string("OBJ_PART_MAIN", 658062838, 13),
|
||||
/* K3 */ be_nested_string("set_style_text_font", 1028590019, 19),
|
||||
/* K4 */ be_nested_string("PART_MAIN", -1821475788, 9),
|
||||
/* K5 */ be_nested_string("STATE_DEFAULT", 712406428, 13),
|
||||
/* K6 */ be_nested_string("get_height", -723211773, 10),
|
||||
/* K7 */ be_nested_string("set_text", 1849641155, 8),
|
||||
/* K8 */ be_nested_string("--:--", 1370615441, 5),
|
||||
/* K9 */ be_nested_string("get_width", -1001549996, 9),
|
||||
/* K10 */ be_nested_string("set_y", 1866178391, 5),
|
||||
/* K11 */ be_const_int(2),
|
||||
/* K12 */ be_nested_string("get_style_pad_right", -1144679830, 19),
|
||||
/* K13 */ be_nested_string("set_x", 1849400772, 5),
|
||||
/* K14 */ be_const_int(3),
|
||||
/* K15 */ be_nested_string("set_style_local_pad_right", 1126712366, 25),
|
||||
/* K16 */ be_nested_string("set_style_local_bg_color", -498263023, 24),
|
||||
/* K17 */ be_nested_string("lv_color", 1419148319, 8),
|
||||
/* K18 */ be_nested_string("COLOR_BLACK", 264427940, 11),
|
||||
/* K19 */ be_nested_string("tasmota", 424643812, 7),
|
||||
/* K20 */ be_nested_string("add_driver", 1654458371, 10),
|
||||
/* K9 */ be_nested_string("refr_size", 1958144468, 9),
|
||||
/* K10 */ be_nested_string("get_width", -1001549996, 9),
|
||||
/* K11 */ be_nested_string("set_y", 1866178391, 5),
|
||||
/* K12 */ be_const_int(2),
|
||||
/* K13 */ be_nested_string("get_style_pad_right", -1144679830, 19),
|
||||
/* K14 */ be_nested_string("set_x", 1849400772, 5),
|
||||
/* K15 */ be_const_int(3),
|
||||
/* K16 */ be_nested_string("set_style_pad_right", -980898242, 19),
|
||||
/* K17 */ be_nested_string("set_style_bg_color", 1689513089, 18),
|
||||
/* K18 */ be_nested_string("lv_color", 1419148319, 8),
|
||||
/* K19 */ be_nested_string("COLOR_BLACK", 264427940, 11),
|
||||
/* K20 */ be_nested_string("tasmota", 424643812, 7),
|
||||
/* K21 */ be_nested_string("add_driver", 1654458371, 10),
|
||||
}),
|
||||
(be_nested_const_str("init", 380752755, 4)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[76]) { /* code */
|
||||
( &(const binstruction[82]) { /* code */
|
||||
0x600C0003, // 0000 GETGBL R3 G3
|
||||
0x5C100000, // 0001 MOVE R4 R0
|
||||
0x7C0C0200, // 0002 CALL R3 1
|
||||
@ -170,69 +171,75 @@ be_local_closure(init, /* name */
|
||||
0x7C0C0400, // 000A CALL R3 2
|
||||
0x4C100000, // 000B LDNIL R4
|
||||
0x20100604, // 000C NE R4 R3 R4
|
||||
0x78120006, // 000D JMPF R4 #0015
|
||||
0x78120007, // 000D JMPF R4 #0016
|
||||
0x8C100103, // 000E GETMET R4 R0 K3
|
||||
0xB81A0200, // 000F GETNGBL R6 K1
|
||||
0x88180D04, // 0010 GETMBR R6 R6 K4
|
||||
0xB81E0200, // 0011 GETNGBL R7 K1
|
||||
0x881C0F05, // 0012 GETMBR R7 R7 K5
|
||||
0x5C200600, // 0013 MOVE R8 R3
|
||||
0x7C100800, // 0014 CALL R4 4
|
||||
0x4C100000, // 0015 LDNIL R4
|
||||
0x20100204, // 0016 NE R4 R1 R4
|
||||
0x7812002E, // 0017 JMPF R4 #0047
|
||||
0x8C100306, // 0018 GETMET R4 R1 K6
|
||||
0x7C100200, // 0019 CALL R4 1
|
||||
0x8C140107, // 001A GETMET R5 R0 K7
|
||||
0x581C0008, // 001B LDCONST R7 K8
|
||||
0x7C140400, // 001C CALL R5 2
|
||||
0x8C140109, // 001D GETMET R5 R0 K9
|
||||
0x7C140200, // 001E CALL R5 1
|
||||
0x8C18010A, // 001F GETMET R6 R0 K10
|
||||
0x8C200306, // 0020 GETMET R8 R1 K6
|
||||
0x7C200200, // 0021 CALL R8 1
|
||||
0x8C240106, // 0022 GETMET R9 R0 K6
|
||||
0x7C240200, // 0023 CALL R9 1
|
||||
0x04201009, // 0024 SUB R8 R8 R9
|
||||
0x0C20110B, // 0025 DIV R8 R8 K11
|
||||
0x7C180400, // 0026 CALL R6 2
|
||||
0x8C18030C, // 0027 GETMET R6 R1 K12
|
||||
0xB8220200, // 0028 GETNGBL R8 K1
|
||||
0x88201104, // 0029 GETMBR R8 R8 K4
|
||||
0xB8260200, // 002A GETNGBL R9 K1
|
||||
0x88241305, // 002B GETMBR R9 R9 K5
|
||||
0x7C180600, // 002C CALL R6 3
|
||||
0x8C1C010D, // 002D GETMET R7 R0 K13
|
||||
0x8C240309, // 002E GETMET R9 R1 K9
|
||||
0x7C240200, // 002F CALL R9 1
|
||||
0x04241205, // 0030 SUB R9 R9 R5
|
||||
0x04241206, // 0031 SUB R9 R9 R6
|
||||
0x0424130E, // 0032 SUB R9 R9 K14
|
||||
0x7C1C0400, // 0033 CALL R7 2
|
||||
0x8C1C030F, // 0034 GETMET R7 R1 K15
|
||||
0xB8260200, // 0035 GETNGBL R9 K1
|
||||
0x88241304, // 0036 GETMBR R9 R9 K4
|
||||
0xB82A0200, // 0037 GETNGBL R10 K1
|
||||
0x88281505, // 0038 GETMBR R10 R10 K5
|
||||
0x002C0C05, // 0039 ADD R11 R6 R5
|
||||
0x54320005, // 003A LDINT R12 6
|
||||
0x002C160C, // 003B ADD R11 R11 R12
|
||||
0x7C1C0800, // 003C CALL R7 4
|
||||
0x8C1C0110, // 003D GETMET R7 R0 K16
|
||||
0xB8260200, // 003E GETNGBL R9 K1
|
||||
0x88241304, // 003F GETMBR R9 R9 K4
|
||||
0xB82A0200, // 0040 GETNGBL R10 K1
|
||||
0x88281505, // 0041 GETMBR R10 R10 K5
|
||||
0xB82E2200, // 0042 GETNGBL R11 K17
|
||||
0xB8320200, // 0043 GETNGBL R12 K1
|
||||
0x88301912, // 0044 GETMBR R12 R12 K18
|
||||
0x7C2C0200, // 0045 CALL R11 1
|
||||
0x7C1C0800, // 0046 CALL R7 4
|
||||
0xB8122600, // 0047 GETNGBL R4 K19
|
||||
0x8C100914, // 0048 GETMET R4 R4 K20
|
||||
0x5C180000, // 0049 MOVE R6 R0
|
||||
0x7C100400, // 004A CALL R4 2
|
||||
0x80000000, // 004B RET 0
|
||||
0x5C180600, // 000F MOVE R6 R3
|
||||
0xB81E0200, // 0010 GETNGBL R7 K1
|
||||
0x881C0F04, // 0011 GETMBR R7 R7 K4
|
||||
0xB8220200, // 0012 GETNGBL R8 K1
|
||||
0x88201105, // 0013 GETMBR R8 R8 K5
|
||||
0x301C0E08, // 0014 OR R7 R7 R8
|
||||
0x7C100600, // 0015 CALL R4 3
|
||||
0x4C100000, // 0016 LDNIL R4
|
||||
0x20100204, // 0017 NE R4 R1 R4
|
||||
0x78120033, // 0018 JMPF R4 #004D
|
||||
0x8C100306, // 0019 GETMET R4 R1 K6
|
||||
0x7C100200, // 001A CALL R4 1
|
||||
0x8C140107, // 001B GETMET R5 R0 K7
|
||||
0x581C0008, // 001C LDCONST R7 K8
|
||||
0x7C140400, // 001D CALL R5 2
|
||||
0x8C140109, // 001E GETMET R5 R0 K9
|
||||
0x7C140200, // 001F CALL R5 1
|
||||
0x8C14010A, // 0020 GETMET R5 R0 K10
|
||||
0x7C140200, // 0021 CALL R5 1
|
||||
0x8C18010B, // 0022 GETMET R6 R0 K11
|
||||
0x8C200306, // 0023 GETMET R8 R1 K6
|
||||
0x7C200200, // 0024 CALL R8 1
|
||||
0x8C240106, // 0025 GETMET R9 R0 K6
|
||||
0x7C240200, // 0026 CALL R9 1
|
||||
0x04201009, // 0027 SUB R8 R8 R9
|
||||
0x0C20110C, // 0028 DIV R8 R8 K12
|
||||
0x7C180400, // 0029 CALL R6 2
|
||||
0x8C18030D, // 002A GETMET R6 R1 K13
|
||||
0xB8220200, // 002B GETNGBL R8 K1
|
||||
0x88201104, // 002C GETMBR R8 R8 K4
|
||||
0xB8260200, // 002D GETNGBL R9 K1
|
||||
0x88241305, // 002E GETMBR R9 R9 K5
|
||||
0x30201009, // 002F OR R8 R8 R9
|
||||
0x7C180400, // 0030 CALL R6 2
|
||||
0x8C1C010E, // 0031 GETMET R7 R0 K14
|
||||
0x8C24030A, // 0032 GETMET R9 R1 K10
|
||||
0x7C240200, // 0033 CALL R9 1
|
||||
0x04241205, // 0034 SUB R9 R9 R5
|
||||
0x04241206, // 0035 SUB R9 R9 R6
|
||||
0x0424130F, // 0036 SUB R9 R9 K15
|
||||
0x7C1C0400, // 0037 CALL R7 2
|
||||
0x8C1C0310, // 0038 GETMET R7 R1 K16
|
||||
0x00240C05, // 0039 ADD R9 R6 R5
|
||||
0x542A0005, // 003A LDINT R10 6
|
||||
0x0024120A, // 003B ADD R9 R9 R10
|
||||
0xB82A0200, // 003C GETNGBL R10 K1
|
||||
0x88281504, // 003D GETMBR R10 R10 K4
|
||||
0xB82E0200, // 003E GETNGBL R11 K1
|
||||
0x882C1705, // 003F GETMBR R11 R11 K5
|
||||
0x3028140B, // 0040 OR R10 R10 R11
|
||||
0x7C1C0600, // 0041 CALL R7 3
|
||||
0x8C1C0111, // 0042 GETMET R7 R0 K17
|
||||
0xB8262400, // 0043 GETNGBL R9 K18
|
||||
0xB82A0200, // 0044 GETNGBL R10 K1
|
||||
0x88281513, // 0045 GETMBR R10 R10 K19
|
||||
0x7C240200, // 0046 CALL R9 1
|
||||
0xB82A0200, // 0047 GETNGBL R10 K1
|
||||
0x88281504, // 0048 GETMBR R10 R10 K4
|
||||
0xB82E0200, // 0049 GETNGBL R11 K1
|
||||
0x882C1705, // 004A GETMBR R11 R11 K5
|
||||
0x3028140B, // 004B OR R10 R10 R11
|
||||
0x7C1C0600, // 004C CALL R7 3
|
||||
0xB8122800, // 004D GETNGBL R4 K20
|
||||
0x8C100915, // 004E GETMET R4 R4 K21
|
||||
0x5C180000, // 004F MOVE R6 R0
|
||||
0x7C100400, // 0050 CALL R4 2
|
||||
0x80000000, // 0051 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
|
@ -22,7 +22,7 @@ void be_load_lvgl_color_lib(bvm *vm) {
|
||||
|
||||
/* @const_object_info_begin
|
||||
class be_class_lv_color (scope: global, name: lv_color) {
|
||||
.p, var
|
||||
_p, var
|
||||
init, func(lco_init)
|
||||
tostring, func(lco_tostring)
|
||||
toint, func(lco_toint)
|
||||
|
@ -18,8 +18,8 @@ const be_ctypes_structure_t be_lv_point = {
|
||||
2, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[2]) {
|
||||
{ "x", 0, 0, 0, 12, 0 },
|
||||
{ "y", 2, 0, 0, 12, 0 },
|
||||
{ "x", 0, 0, 0, ctypes_i16, 0 },
|
||||
{ "y", 2, 0, 0, ctypes_i16, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_area = {
|
||||
@ -27,60 +27,46 @@ const be_ctypes_structure_t be_lv_area = {
|
||||
4, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[4]) {
|
||||
{ "x1", 0, 0, 0, 12, 0 },
|
||||
{ "x2", 4, 0, 0, 12, 0 },
|
||||
{ "y1", 2, 0, 0, 12, 0 },
|
||||
{ "y2", 6, 0, 0, 12, 0 },
|
||||
{ "x1", 0, 0, 0, ctypes_i16, 0 },
|
||||
{ "x2", 4, 0, 0, ctypes_i16, 0 },
|
||||
{ "y1", 2, 0, 0, ctypes_i16, 0 },
|
||||
{ "y2", 6, 0, 0, ctypes_i16, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_draw_rect_dsc = {
|
||||
77, /* size in bytes */
|
||||
43, /* number of elements */
|
||||
50, /* size in bytes */
|
||||
29, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[43]) {
|
||||
{ "bg_blend_mode", 12, 0, 0, 1, 0 },
|
||||
{ "bg_color", 2, 0, 0, 2, 1 },
|
||||
{ "bg_grad_color", 4, 0, 0, 2, 1 },
|
||||
{ "bg_grad_color_stop", 9, 0, 0, 12, 0 },
|
||||
{ "bg_grad_dir", 6, 0, 0, 1, 0 },
|
||||
{ "bg_main_color_stop", 7, 0, 0, 12, 0 },
|
||||
{ "bg_opa", 11, 0, 0, 1, 0 },
|
||||
{ "border_blend_mode", 20, 0, 0, 1, 0 },
|
||||
{ "border_color", 13, 0, 0, 2, 1 },
|
||||
{ "border_opa", 19, 0, 0, 1, 0 },
|
||||
{ "border_post", 21, 0, 1, 0, 0 },
|
||||
{ "border_side", 17, 0, 0, 12, 0 },
|
||||
{ "border_width", 15, 0, 0, 12, 0 },
|
||||
{ "outline_blend_mode", 29, 0, 0, 1, 0 },
|
||||
{ "outline_color", 22, 0, 0, 2, 1 },
|
||||
{ "outline_opa", 28, 0, 0, 1, 0 },
|
||||
{ "outline_pad", 26, 0, 0, 12, 0 },
|
||||
{ "outline_width", 24, 0, 0, 12, 0 },
|
||||
{ "pattern_blend_mode", 55, 0, 0, 1, 0 },
|
||||
{ "pattern_font", 46, 0, 0, 4, 0 },
|
||||
{ "pattern_image", 42, 0, 0, 4, 0 },
|
||||
{ "pattern_opa", 52, 0, 0, 1, 0 },
|
||||
{ "pattern_recolor", 50, 0, 0, 2, 1 },
|
||||
{ "pattern_recolor_opa", 53, 0, 0, 1, 0 },
|
||||
{ "pattern_repeat", 54, 0, 1, 0, 0 },
|
||||
{ "radius", 0, 0, 0, 12, 0 },
|
||||
{ "shadow_blend_mode", 41, 0, 0, 1, 0 },
|
||||
{ "shadow_color", 30, 0, 0, 2, 1 },
|
||||
{ "shadow_ofs_x", 34, 0, 0, 12, 0 },
|
||||
{ "shadow_ofs_y", 36, 0, 0, 12, 0 },
|
||||
{ "shadow_opa", 40, 0, 0, 1, 0 },
|
||||
{ "shadow_spread", 38, 0, 0, 12, 0 },
|
||||
{ "shadow_width", 32, 0, 0, 12, 0 },
|
||||
{ "value_align", 75, 0, 0, 1, 0 },
|
||||
{ "value_blend_mode", 76, 0, 0, 1, 0 },
|
||||
{ "value_color", 65, 0, 0, 2, 1 },
|
||||
{ "value_font", 60, 0, 0, 4, 0 },
|
||||
{ "value_letter_space", 71, 0, 0, 12, 0 },
|
||||
{ "value_line_space", 73, 0, 0, 12, 0 },
|
||||
{ "value_ofs_x", 67, 0, 0, 12, 0 },
|
||||
{ "value_ofs_y", 69, 0, 0, 12, 0 },
|
||||
{ "value_opa", 64, 0, 0, 1, 0 },
|
||||
{ "value_str", 56, 0, 0, 4, 0 },
|
||||
(const be_ctypes_structure_item_t[29]) {
|
||||
{ "bg_color", 3, 0, 0, ctypes_u16, 1 },
|
||||
{ "bg_grad_color", 5, 0, 0, ctypes_u16, 1 },
|
||||
{ "bg_grad_color_stop", 8, 0, 0, ctypes_u8, 0 },
|
||||
{ "bg_grad_dir", 10, 0, 3, ctypes_bf, 0 },
|
||||
{ "bg_img_opa", 22, 0, 0, ctypes_u8, 0 },
|
||||
{ "bg_img_recolor", 20, 0, 0, ctypes_u16, 1 },
|
||||
{ "bg_img_recolor_opa", 23, 0, 0, ctypes_u8, 0 },
|
||||
{ "bg_img_src", 12, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "bg_img_symbol_font", 16, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "bg_img_tiled", 24, 0, 0, ctypes_u8, 0 },
|
||||
{ "bg_main_color_stop", 7, 0, 0, ctypes_u8, 0 },
|
||||
{ "bg_opa", 9, 0, 0, ctypes_u8, 0 },
|
||||
{ "blend_mode", 2, 0, 0, ctypes_u8, 0 },
|
||||
{ "border_color", 25, 0, 0, ctypes_u16, 1 },
|
||||
{ "border_opa", 29, 0, 0, ctypes_u8, 0 },
|
||||
{ "border_post", 30, 0, 1, ctypes_bf, 0 },
|
||||
{ "border_side", 30, 1, 5, ctypes_bf, 0 },
|
||||
{ "border_width", 27, 0, 0, ctypes_i16, 0 },
|
||||
{ "outline_color", 32, 0, 0, ctypes_u16, 1 },
|
||||
{ "outline_opa", 38, 0, 0, ctypes_u8, 0 },
|
||||
{ "outline_pad", 36, 0, 0, ctypes_i16, 0 },
|
||||
{ "outline_width", 34, 0, 0, ctypes_i16, 0 },
|
||||
{ "radius", 0, 0, 0, ctypes_i16, 0 },
|
||||
{ "shadow_color", 39, 0, 0, ctypes_u16, 1 },
|
||||
{ "shadow_ofs_x", 43, 0, 0, ctypes_i16, 0 },
|
||||
{ "shadow_ofs_y", 45, 0, 0, ctypes_i16, 0 },
|
||||
{ "shadow_opa", 49, 0, 0, ctypes_u8, 0 },
|
||||
{ "shadow_spread", 47, 0, 0, ctypes_i16, 0 },
|
||||
{ "shadow_width", 41, 0, 0, ctypes_i16, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_draw_line_dsc = {
|
||||
@ -88,53 +74,32 @@ const be_ctypes_structure_t be_lv_draw_line_dsc = {
|
||||
9, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[9]) {
|
||||
{ "blend_mode", 9, 0, 2, 0, 0 },
|
||||
{ "color", 0, 0, 0, 2, 1 },
|
||||
{ "dash_gap", 6, 0, 0, 12, 0 },
|
||||
{ "dash_width", 4, 0, 0, 12, 0 },
|
||||
{ "opa", 8, 0, 0, 1, 0 },
|
||||
{ "raw_end", 9, 4, 1, 0, 0 },
|
||||
{ "round_end", 9, 3, 1, 0, 0 },
|
||||
{ "round_start", 9, 2, 1, 0, 0 },
|
||||
{ "width", 2, 0, 0, 12, 0 },
|
||||
{ "blend_mode", 9, 0, 2, ctypes_bf, 0 },
|
||||
{ "color", 0, 0, 0, ctypes_u16, 1 },
|
||||
{ "dash_gap", 6, 0, 0, ctypes_i16, 0 },
|
||||
{ "dash_width", 4, 0, 0, ctypes_i16, 0 },
|
||||
{ "opa", 8, 0, 0, ctypes_u8, 0 },
|
||||
{ "raw_end", 9, 4, 1, ctypes_bf, 0 },
|
||||
{ "round_end", 9, 3, 1, ctypes_bf, 0 },
|
||||
{ "round_start", 9, 2, 1, ctypes_bf, 0 },
|
||||
{ "width", 2, 0, 0, ctypes_i16, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_draw_img_dsc = {
|
||||
14, /* size in bytes */
|
||||
9, /* number of elements */
|
||||
21, /* size in bytes */
|
||||
10, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[9]) {
|
||||
{ "angle", 1, 0, 0, 2, 0 },
|
||||
{ "antialias", 13, 0, 1, 0, 0 },
|
||||
{ "blend_mode", 12, 0, 0, 1, 0 },
|
||||
{ "opa", 0, 0, 0, 1, 0 },
|
||||
{ "pivot_x", 3, 0, 0, 12, 0 },
|
||||
{ "pivot_y", 5, 0, 0, 12, 0 },
|
||||
{ "recolor", 10, 0, 0, 2, 1 },
|
||||
{ "recolor_opa", 9, 0, 0, 1, 0 },
|
||||
{ "zoom", 7, 0, 0, 2, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_draw_label_dsc = {
|
||||
31, /* size in bytes */
|
||||
15, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[15]) {
|
||||
{ "bidi_dir", 27, 0, 0, 1, 0 },
|
||||
{ "blend_mode", 30, 0, 0, 1, 0 },
|
||||
{ "color", 0, 0, 0, 2, 1 },
|
||||
{ "decor", 29, 0, 0, 1, 0 },
|
||||
{ "flag", 28, 0, 0, 1, 0 },
|
||||
{ "font", 6, 0, 0, 4, 0 },
|
||||
{ "letter_space", 13, 0, 0, 12, 0 },
|
||||
{ "line_space", 11, 0, 0, 12, 0 },
|
||||
{ "ofs_x", 23, 0, 0, 12, 0 },
|
||||
{ "ofs_y", 25, 0, 0, 12, 0 },
|
||||
{ "opa", 10, 0, 0, 1, 0 },
|
||||
{ "sel_bg_color", 4, 0, 0, 2, 1 },
|
||||
{ "sel_color", 2, 0, 0, 2, 1 },
|
||||
{ "sel_end", 19, 0, 0, 4, 0 },
|
||||
{ "sel_start", 15, 0, 0, 4, 0 },
|
||||
(const be_ctypes_structure_item_t[10]) {
|
||||
{ "angle", 0, 0, 0, ctypes_u16, 0 },
|
||||
{ "antialias", 20, 0, 1, ctypes_bf, 0 },
|
||||
{ "blend_mode", 12, 0, 4, ctypes_bf, 0 },
|
||||
{ "frame_id", 16, 0, 0, ctypes_i32, 0 },
|
||||
{ "opa", 11, 0, 0, ctypes_u8, 0 },
|
||||
{ "pivot_x", 4, 0, 0, ctypes_i16, 0 },
|
||||
{ "pivot_y", 6, 0, 0, ctypes_i16, 0 },
|
||||
{ "recolor", 8, 0, 0, ctypes_u16, 1 },
|
||||
{ "recolor_opa", 10, 0, 0, ctypes_u8, 0 },
|
||||
{ "zoom", 2, 0, 0, ctypes_u16, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_draw_mask_common_dsc = {
|
||||
@ -142,8 +107,8 @@ const be_ctypes_structure_t be_lv_draw_mask_common_dsc = {
|
||||
2, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[2]) {
|
||||
{ "cb", 0, 0, 0, 4, 0 },
|
||||
{ "type", 4, 0, 0, 1, 0 },
|
||||
{ "cb", 0, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "type", 4, 0, 0, ctypes_u8, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_draw_mask_line_param_cfg = {
|
||||
@ -151,11 +116,11 @@ const be_ctypes_structure_t be_lv_draw_mask_line_param_cfg = {
|
||||
5, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[5]) {
|
||||
{ "p1_x", 0, 0, 0, 12, 0 },
|
||||
{ "p1_y", 2, 0, 0, 12, 0 },
|
||||
{ "p2_x", 4, 0, 0, 12, 0 },
|
||||
{ "p2_y", 6, 0, 0, 12, 0 },
|
||||
{ "side", 8, 0, 2, 0, 0 },
|
||||
{ "p1_x", 0, 0, 0, ctypes_i16, 0 },
|
||||
{ "p1_y", 2, 0, 0, ctypes_i16, 0 },
|
||||
{ "p2_x", 4, 0, 0, ctypes_i16, 0 },
|
||||
{ "p2_y", 6, 0, 0, ctypes_i16, 0 },
|
||||
{ "side", 8, 0, 2, ctypes_bf, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_draw_mask_line_param = {
|
||||
@ -163,21 +128,21 @@ const be_ctypes_structure_t be_lv_draw_mask_line_param = {
|
||||
15, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[15]) {
|
||||
{ "cfg_p1_x", 5, 0, 0, 12, 0 },
|
||||
{ "cfg_p1_y", 7, 0, 0, 12, 0 },
|
||||
{ "cfg_p2_x", 9, 0, 0, 12, 0 },
|
||||
{ "cfg_p2_y", 11, 0, 0, 12, 0 },
|
||||
{ "cfg_side", 13, 0, 2, 0, 0 },
|
||||
{ "dsc_cb", 0, 0, 0, 4, 0 },
|
||||
{ "dsc_type", 4, 0, 0, 1, 0 },
|
||||
{ "flat", 34, 0, 1, 0, 0 },
|
||||
{ "inv", 34, 1, 1, 0, 0 },
|
||||
{ "origo_x", 14, 0, 0, 12, 0 },
|
||||
{ "origo_y", 16, 0, 0, 12, 0 },
|
||||
{ "spx", 30, 0, 0, 14, 0 },
|
||||
{ "steep", 26, 0, 0, 14, 0 },
|
||||
{ "xy_steep", 18, 0, 0, 14, 0 },
|
||||
{ "yx_steep", 22, 0, 0, 14, 0 },
|
||||
{ "cfg_p1_x", 5, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_p1_y", 7, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_p2_x", 9, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_p2_y", 11, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_side", 13, 0, 2, ctypes_bf, 0 },
|
||||
{ "dsc_cb", 0, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "dsc_type", 4, 0, 0, ctypes_u8, 0 },
|
||||
{ "flat", 34, 0, 1, ctypes_bf, 0 },
|
||||
{ "inv", 34, 1, 1, ctypes_bf, 0 },
|
||||
{ "origo_x", 14, 0, 0, ctypes_i16, 0 },
|
||||
{ "origo_y", 16, 0, 0, ctypes_i16, 0 },
|
||||
{ "spx", 30, 0, 0, ctypes_i32, 0 },
|
||||
{ "steep", 26, 0, 0, ctypes_i32, 0 },
|
||||
{ "xy_steep", 18, 0, 0, ctypes_i32, 0 },
|
||||
{ "yx_steep", 22, 0, 0, ctypes_i32, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_draw_mask_angle_param_cfg = {
|
||||
@ -185,10 +150,10 @@ const be_ctypes_structure_t be_lv_draw_mask_angle_param_cfg = {
|
||||
4, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[4]) {
|
||||
{ "end_angle", 6, 0, 0, 12, 0 },
|
||||
{ "start_angle", 4, 0, 0, 12, 0 },
|
||||
{ "vertex_p_x", 0, 0, 0, 12, 0 },
|
||||
{ "vertex_p_y", 2, 0, 0, 12, 0 },
|
||||
{ "end_angle", 6, 0, 0, ctypes_i16, 0 },
|
||||
{ "start_angle", 4, 0, 0, ctypes_i16, 0 },
|
||||
{ "vertex_p_x", 0, 0, 0, ctypes_i16, 0 },
|
||||
{ "vertex_p_y", 2, 0, 0, ctypes_i16, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_draw_mask_angle_param = {
|
||||
@ -196,43 +161,43 @@ const be_ctypes_structure_t be_lv_draw_mask_angle_param = {
|
||||
37, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[37]) {
|
||||
{ "cfg_end_angle", 11, 0, 0, 12, 0 },
|
||||
{ "cfg_start_angle", 9, 0, 0, 12, 0 },
|
||||
{ "cfg_vertex_p_x", 5, 0, 0, 12, 0 },
|
||||
{ "cfg_vertex_p_y", 7, 0, 0, 12, 0 },
|
||||
{ "delta_deg", 83, 0, 0, 2, 0 },
|
||||
{ "dsc_cb", 0, 0, 0, 4, 0 },
|
||||
{ "dsc_type", 4, 0, 0, 1, 0 },
|
||||
{ "end_line_cfg_p1_x", 53, 0, 0, 12, 0 },
|
||||
{ "end_line_cfg_p1_y", 55, 0, 0, 12, 0 },
|
||||
{ "end_line_cfg_p2_x", 57, 0, 0, 12, 0 },
|
||||
{ "end_line_cfg_p2_y", 59, 0, 0, 12, 0 },
|
||||
{ "end_line_cfg_side", 61, 0, 2, 0, 0 },
|
||||
{ "end_line_dsc_cb", 48, 0, 0, 4, 0 },
|
||||
{ "end_line_dsc_type", 52, 0, 0, 1, 0 },
|
||||
{ "end_line_flat", 82, 0, 1, 0, 0 },
|
||||
{ "end_line_inv", 82, 1, 1, 0, 0 },
|
||||
{ "end_line_origo_x", 62, 0, 0, 12, 0 },
|
||||
{ "end_line_origo_y", 64, 0, 0, 12, 0 },
|
||||
{ "end_line_spx", 78, 0, 0, 14, 0 },
|
||||
{ "end_line_steep", 74, 0, 0, 14, 0 },
|
||||
{ "end_line_xy_steep", 66, 0, 0, 14, 0 },
|
||||
{ "end_line_yx_steep", 70, 0, 0, 14, 0 },
|
||||
{ "start_line_cfg_p1_x", 18, 0, 0, 12, 0 },
|
||||
{ "start_line_cfg_p1_y", 20, 0, 0, 12, 0 },
|
||||
{ "start_line_cfg_p2_x", 22, 0, 0, 12, 0 },
|
||||
{ "start_line_cfg_p2_y", 24, 0, 0, 12, 0 },
|
||||
{ "start_line_cfg_side", 26, 0, 2, 0, 0 },
|
||||
{ "start_line_dsc_cb", 13, 0, 0, 4, 0 },
|
||||
{ "start_line_dsc_type", 17, 0, 0, 1, 0 },
|
||||
{ "start_line_flat", 47, 0, 1, 0, 0 },
|
||||
{ "start_line_inv", 47, 1, 1, 0, 0 },
|
||||
{ "start_line_origo_x", 27, 0, 0, 12, 0 },
|
||||
{ "start_line_origo_y", 29, 0, 0, 12, 0 },
|
||||
{ "start_line_spx", 43, 0, 0, 14, 0 },
|
||||
{ "start_line_steep", 39, 0, 0, 14, 0 },
|
||||
{ "start_line_xy_steep", 31, 0, 0, 14, 0 },
|
||||
{ "start_line_yx_steep", 35, 0, 0, 14, 0 },
|
||||
{ "cfg_end_angle", 11, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_start_angle", 9, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_vertex_p_x", 5, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_vertex_p_y", 7, 0, 0, ctypes_i16, 0 },
|
||||
{ "delta_deg", 83, 0, 0, ctypes_u16, 0 },
|
||||
{ "dsc_cb", 0, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "dsc_type", 4, 0, 0, ctypes_u8, 0 },
|
||||
{ "end_line_cfg_p1_x", 53, 0, 0, ctypes_i16, 0 },
|
||||
{ "end_line_cfg_p1_y", 55, 0, 0, ctypes_i16, 0 },
|
||||
{ "end_line_cfg_p2_x", 57, 0, 0, ctypes_i16, 0 },
|
||||
{ "end_line_cfg_p2_y", 59, 0, 0, ctypes_i16, 0 },
|
||||
{ "end_line_cfg_side", 61, 0, 2, ctypes_bf, 0 },
|
||||
{ "end_line_dsc_cb", 48, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "end_line_dsc_type", 52, 0, 0, ctypes_u8, 0 },
|
||||
{ "end_line_flat", 82, 0, 1, ctypes_bf, 0 },
|
||||
{ "end_line_inv", 82, 1, 1, ctypes_bf, 0 },
|
||||
{ "end_line_origo_x", 62, 0, 0, ctypes_i16, 0 },
|
||||
{ "end_line_origo_y", 64, 0, 0, ctypes_i16, 0 },
|
||||
{ "end_line_spx", 78, 0, 0, ctypes_i32, 0 },
|
||||
{ "end_line_steep", 74, 0, 0, ctypes_i32, 0 },
|
||||
{ "end_line_xy_steep", 66, 0, 0, ctypes_i32, 0 },
|
||||
{ "end_line_yx_steep", 70, 0, 0, ctypes_i32, 0 },
|
||||
{ "start_line_cfg_p1_x", 18, 0, 0, ctypes_i16, 0 },
|
||||
{ "start_line_cfg_p1_y", 20, 0, 0, ctypes_i16, 0 },
|
||||
{ "start_line_cfg_p2_x", 22, 0, 0, ctypes_i16, 0 },
|
||||
{ "start_line_cfg_p2_y", 24, 0, 0, ctypes_i16, 0 },
|
||||
{ "start_line_cfg_side", 26, 0, 2, ctypes_bf, 0 },
|
||||
{ "start_line_dsc_cb", 13, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "start_line_dsc_type", 17, 0, 0, ctypes_u8, 0 },
|
||||
{ "start_line_flat", 47, 0, 1, ctypes_bf, 0 },
|
||||
{ "start_line_inv", 47, 1, 1, ctypes_bf, 0 },
|
||||
{ "start_line_origo_x", 27, 0, 0, ctypes_i16, 0 },
|
||||
{ "start_line_origo_y", 29, 0, 0, ctypes_i16, 0 },
|
||||
{ "start_line_spx", 43, 0, 0, ctypes_i32, 0 },
|
||||
{ "start_line_steep", 39, 0, 0, ctypes_i32, 0 },
|
||||
{ "start_line_xy_steep", 31, 0, 0, ctypes_i32, 0 },
|
||||
{ "start_line_yx_steep", 35, 0, 0, ctypes_i32, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_draw_mask_radius_param_cfg = {
|
||||
@ -240,12 +205,12 @@ const be_ctypes_structure_t be_lv_draw_mask_radius_param_cfg = {
|
||||
6, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[6]) {
|
||||
{ "outer", 10, 0, 1, 0, 0 },
|
||||
{ "radius", 8, 0, 0, 12, 0 },
|
||||
{ "rect_x1", 0, 0, 0, 12, 0 },
|
||||
{ "rect_x2", 4, 0, 0, 12, 0 },
|
||||
{ "rect_y1", 2, 0, 0, 12, 0 },
|
||||
{ "rect_y2", 6, 0, 0, 12, 0 },
|
||||
{ "outer", 10, 0, 1, ctypes_bf, 0 },
|
||||
{ "radius", 8, 0, 0, ctypes_i16, 0 },
|
||||
{ "rect_x1", 0, 0, 0, ctypes_i16, 0 },
|
||||
{ "rect_x2", 4, 0, 0, ctypes_i16, 0 },
|
||||
{ "rect_y1", 2, 0, 0, ctypes_i16, 0 },
|
||||
{ "rect_y2", 6, 0, 0, ctypes_i16, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_sqrt_res = {
|
||||
@ -253,8 +218,8 @@ const be_ctypes_structure_t be_lv_sqrt_res = {
|
||||
2, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[2]) {
|
||||
{ "f", 2, 0, 0, 2, 0 },
|
||||
{ "i", 0, 0, 0, 2, 0 },
|
||||
{ "f", 2, 0, 0, ctypes_u16, 0 },
|
||||
{ "i", 0, 0, 0, ctypes_u16, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_draw_mask_radius_param = {
|
||||
@ -262,17 +227,17 @@ const be_ctypes_structure_t be_lv_draw_mask_radius_param = {
|
||||
11, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[11]) {
|
||||
{ "cfg_outer", 15, 0, 1, 0, 0 },
|
||||
{ "cfg_radius", 13, 0, 0, 12, 0 },
|
||||
{ "cfg_rect_x1", 5, 0, 0, 12, 0 },
|
||||
{ "cfg_rect_x2", 9, 0, 0, 12, 0 },
|
||||
{ "cfg_rect_y1", 7, 0, 0, 12, 0 },
|
||||
{ "cfg_rect_y2", 11, 0, 0, 12, 0 },
|
||||
{ "dsc_cb", 0, 0, 0, 4, 0 },
|
||||
{ "dsc_type", 4, 0, 0, 1, 0 },
|
||||
{ "y_prev", 16, 0, 0, 14, 0 },
|
||||
{ "y_prev_x_f", 22, 0, 0, 2, 0 },
|
||||
{ "y_prev_x_i", 20, 0, 0, 2, 0 },
|
||||
{ "cfg_outer", 15, 0, 1, ctypes_bf, 0 },
|
||||
{ "cfg_radius", 13, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_rect_x1", 5, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_rect_x2", 9, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_rect_y1", 7, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_rect_y2", 11, 0, 0, ctypes_i16, 0 },
|
||||
{ "dsc_cb", 0, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "dsc_type", 4, 0, 0, ctypes_u8, 0 },
|
||||
{ "y_prev", 16, 0, 0, ctypes_i32, 0 },
|
||||
{ "y_prev_x_f", 22, 0, 0, ctypes_u16, 0 },
|
||||
{ "y_prev_x_i", 20, 0, 0, ctypes_u16, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_draw_mask_fade_param_cfg = {
|
||||
@ -280,14 +245,14 @@ const be_ctypes_structure_t be_lv_draw_mask_fade_param_cfg = {
|
||||
8, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[8]) {
|
||||
{ "coords_x1", 0, 0, 0, 12, 0 },
|
||||
{ "coords_x2", 4, 0, 0, 12, 0 },
|
||||
{ "coords_y1", 2, 0, 0, 12, 0 },
|
||||
{ "coords_y2", 6, 0, 0, 12, 0 },
|
||||
{ "opa_bottom", 13, 0, 0, 1, 0 },
|
||||
{ "opa_top", 12, 0, 0, 1, 0 },
|
||||
{ "y_bottom", 10, 0, 0, 12, 0 },
|
||||
{ "y_top", 8, 0, 0, 12, 0 },
|
||||
{ "coords_x1", 0, 0, 0, ctypes_i16, 0 },
|
||||
{ "coords_x2", 4, 0, 0, ctypes_i16, 0 },
|
||||
{ "coords_y1", 2, 0, 0, ctypes_i16, 0 },
|
||||
{ "coords_y2", 6, 0, 0, ctypes_i16, 0 },
|
||||
{ "opa_bottom", 13, 0, 0, ctypes_u8, 0 },
|
||||
{ "opa_top", 12, 0, 0, ctypes_u8, 0 },
|
||||
{ "y_bottom", 10, 0, 0, ctypes_i16, 0 },
|
||||
{ "y_top", 8, 0, 0, ctypes_i16, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_draw_mask_fade_param = {
|
||||
@ -295,16 +260,16 @@ const be_ctypes_structure_t be_lv_draw_mask_fade_param = {
|
||||
10, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[10]) {
|
||||
{ "cfg_coords_x1", 5, 0, 0, 12, 0 },
|
||||
{ "cfg_coords_x2", 9, 0, 0, 12, 0 },
|
||||
{ "cfg_coords_y1", 7, 0, 0, 12, 0 },
|
||||
{ "cfg_coords_y2", 11, 0, 0, 12, 0 },
|
||||
{ "cfg_opa_bottom", 18, 0, 0, 1, 0 },
|
||||
{ "cfg_opa_top", 17, 0, 0, 1, 0 },
|
||||
{ "cfg_y_bottom", 15, 0, 0, 12, 0 },
|
||||
{ "cfg_y_top", 13, 0, 0, 12, 0 },
|
||||
{ "dsc_cb", 0, 0, 0, 4, 0 },
|
||||
{ "dsc_type", 4, 0, 0, 1, 0 },
|
||||
{ "cfg_coords_x1", 5, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_coords_x2", 9, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_coords_y1", 7, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_coords_y2", 11, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_opa_bottom", 18, 0, 0, ctypes_u8, 0 },
|
||||
{ "cfg_opa_top", 17, 0, 0, ctypes_u8, 0 },
|
||||
{ "cfg_y_bottom", 15, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_y_top", 13, 0, 0, ctypes_i16, 0 },
|
||||
{ "dsc_cb", 0, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "dsc_type", 4, 0, 0, ctypes_u8, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_draw_mask_map_param_cfg = {
|
||||
@ -312,11 +277,11 @@ const be_ctypes_structure_t be_lv_draw_mask_map_param_cfg = {
|
||||
5, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[5]) {
|
||||
{ "coords_x1", 0, 0, 0, 12, 0 },
|
||||
{ "coords_x2", 4, 0, 0, 12, 0 },
|
||||
{ "coords_y1", 2, 0, 0, 12, 0 },
|
||||
{ "coords_y2", 6, 0, 0, 12, 0 },
|
||||
{ "map", 8, 0, 0, 4, 0 },
|
||||
{ "coords_x1", 0, 0, 0, ctypes_i16, 0 },
|
||||
{ "coords_x2", 4, 0, 0, ctypes_i16, 0 },
|
||||
{ "coords_y1", 2, 0, 0, ctypes_i16, 0 },
|
||||
{ "coords_y2", 6, 0, 0, ctypes_i16, 0 },
|
||||
{ "map", 8, 0, 0, ctypes_ptr32, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_draw_mask_map_param = {
|
||||
@ -324,13 +289,13 @@ const be_ctypes_structure_t be_lv_draw_mask_map_param = {
|
||||
7, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[7]) {
|
||||
{ "cfg_coords_x1", 5, 0, 0, 12, 0 },
|
||||
{ "cfg_coords_x2", 9, 0, 0, 12, 0 },
|
||||
{ "cfg_coords_y1", 7, 0, 0, 12, 0 },
|
||||
{ "cfg_coords_y2", 11, 0, 0, 12, 0 },
|
||||
{ "cfg_map", 13, 0, 0, 4, 0 },
|
||||
{ "dsc_cb", 0, 0, 0, 4, 0 },
|
||||
{ "dsc_type", 4, 0, 0, 1, 0 },
|
||||
{ "cfg_coords_x1", 5, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_coords_x2", 9, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_coords_y1", 7, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_coords_y2", 11, 0, 0, ctypes_i16, 0 },
|
||||
{ "cfg_map", 13, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "dsc_cb", 0, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "dsc_type", 4, 0, 0, ctypes_u8, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_draw_mask_saved = {
|
||||
@ -338,8 +303,135 @@ const be_ctypes_structure_t be_lv_draw_mask_saved = {
|
||||
2, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[2]) {
|
||||
{ "custom_id", 4, 0, 0, 4, 0 },
|
||||
{ "param", 0, 0, 0, 4, 0 },
|
||||
{ "custom_id", 4, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "param", 0, 0, 0, ctypes_ptr32, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_meter_scale = {
|
||||
34, /* size in bytes */
|
||||
15, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[15]) {
|
||||
{ "angle_range", 30, 0, 0, ctypes_u16, 0 },
|
||||
{ "label_color", 18, 0, 0, ctypes_i16, 0 },
|
||||
{ "label_gap", 16, 0, 0, ctypes_i16, 0 },
|
||||
{ "max", 24, 0, 0, ctypes_i32, 0 },
|
||||
{ "min", 20, 0, 0, ctypes_i32, 0 },
|
||||
{ "r_mod", 28, 0, 0, ctypes_i16, 0 },
|
||||
{ "rotation", 32, 0, 0, ctypes_i16, 0 },
|
||||
{ "tick_cnt", 2, 0, 0, ctypes_u16, 0 },
|
||||
{ "tick_color", 0, 0, 0, ctypes_u16, 1 },
|
||||
{ "tick_length", 4, 0, 0, ctypes_u16, 0 },
|
||||
{ "tick_major_color", 8, 0, 0, ctypes_u16, 1 },
|
||||
{ "tick_major_length", 12, 0, 0, ctypes_u16, 0 },
|
||||
{ "tick_major_nth", 10, 0, 0, ctypes_u16, 0 },
|
||||
{ "tick_major_width", 14, 0, 0, ctypes_u16, 0 },
|
||||
{ "tick_width", 6, 0, 0, ctypes_u16, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_meter_indicator = {
|
||||
17, /* size in bytes */
|
||||
5, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[5]) {
|
||||
{ "end_value", 13, 0, 0, ctypes_i32, 0 },
|
||||
{ "opa", 8, 0, 0, ctypes_u8, 0 },
|
||||
{ "scale", 0, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "start_value", 9, 0, 0, ctypes_i32, 0 },
|
||||
{ "type", 4, 0, 0, ctypes_i32, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_meter_indicator_needle_img = {
|
||||
25, /* size in bytes */
|
||||
8, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[8]) {
|
||||
{ "end_value", 13, 0, 0, ctypes_i32, 0 },
|
||||
{ "opa", 8, 0, 0, ctypes_u8, 0 },
|
||||
{ "pivot_x", 21, 0, 0, ctypes_i16, 0 },
|
||||
{ "pivot_y", 23, 0, 0, ctypes_i16, 0 },
|
||||
{ "scale", 0, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "src", 17, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "start_value", 9, 0, 0, ctypes_i32, 0 },
|
||||
{ "type", 4, 0, 0, ctypes_i32, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_meter_indicator_needle_line = {
|
||||
23, /* size in bytes */
|
||||
8, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[8]) {
|
||||
{ "color", 21, 0, 0, ctypes_u16, 1 },
|
||||
{ "end_value", 13, 0, 0, ctypes_i32, 0 },
|
||||
{ "opa", 8, 0, 0, ctypes_u8, 0 },
|
||||
{ "r_mod", 19, 0, 0, ctypes_i16, 0 },
|
||||
{ "scale", 0, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "start_value", 9, 0, 0, ctypes_i32, 0 },
|
||||
{ "type", 4, 0, 0, ctypes_i32, 0 },
|
||||
{ "width", 17, 0, 0, ctypes_u16, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_meter_indicator_arc = {
|
||||
27, /* size in bytes */
|
||||
9, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[9]) {
|
||||
{ "color", 23, 0, 0, ctypes_u16, 1 },
|
||||
{ "end_value", 13, 0, 0, ctypes_i32, 0 },
|
||||
{ "opa", 8, 0, 0, ctypes_u8, 0 },
|
||||
{ "r_mod", 25, 0, 0, ctypes_i16, 0 },
|
||||
{ "scale", 0, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "src", 19, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "start_value", 9, 0, 0, ctypes_i32, 0 },
|
||||
{ "type", 4, 0, 0, ctypes_i32, 0 },
|
||||
{ "width", 17, 0, 0, ctypes_u16, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_meter_indicator_scale_lines = {
|
||||
24, /* size in bytes */
|
||||
9, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[9]) {
|
||||
{ "color_end", 21, 0, 0, ctypes_u16, 1 },
|
||||
{ "color_start", 19, 0, 0, ctypes_u16, 1 },
|
||||
{ "end_value", 13, 0, 0, ctypes_i32, 0 },
|
||||
{ "local_grad", 23, 0, 1, ctypes_bf, 0 },
|
||||
{ "opa", 8, 0, 0, ctypes_u8, 0 },
|
||||
{ "scale", 0, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "start_value", 9, 0, 0, ctypes_i32, 0 },
|
||||
{ "type", 4, 0, 0, ctypes_i32, 0 },
|
||||
{ "width_mod", 17, 0, 0, ctypes_i16, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_obj_class = {
|
||||
27, /* size in bytes */
|
||||
10, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[10]) {
|
||||
{ "base_class", 0, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "constructor_cb", 4, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "destructor_cb", 8, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "editable", 24, 0, 2, ctypes_bf, 0 },
|
||||
{ "event_cb", 16, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "group_def", 24, 2, 2, ctypes_bf, 0 },
|
||||
{ "height_def", 22, 0, 0, ctypes_i16, 0 },
|
||||
{ "instance_size", 24, 4, 16, ctypes_bf, 0 },
|
||||
{ "user_data", 12, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "width_def", 20, 0, 0, ctypes_i16, 0 },
|
||||
}};
|
||||
|
||||
const be_ctypes_structure_t be_lv_event = {
|
||||
25, /* size in bytes */
|
||||
7, /* number of elements */
|
||||
be_ctypes_instance_mappings,
|
||||
(const be_ctypes_structure_item_t[7]) {
|
||||
{ "code", 8, 0, 0, ctypes_i32, 0 },
|
||||
{ "current_target", 4, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "deleted", 24, 0, 1, ctypes_bf, 0 },
|
||||
{ "param", 16, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "prev", 20, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "target", 0, 0, 0, ctypes_ptr32, 0 },
|
||||
{ "user_data", 12, 0, 0, ctypes_ptr32, 0 },
|
||||
}};
|
||||
|
||||
static const char * be_ctypes_instance_mappings[] = {
|
||||
@ -349,7 +441,6 @@ static const char * be_ctypes_instance_mappings[] = {
|
||||
|
||||
static be_define_ctypes_class(lv_area, &be_lv_area, &be_class_ctypes, "lv_area");
|
||||
static be_define_ctypes_class(lv_draw_img_dsc, &be_lv_draw_img_dsc, &be_class_ctypes, "lv_draw_img_dsc");
|
||||
static be_define_ctypes_class(lv_draw_label_dsc, &be_lv_draw_label_dsc, &be_class_ctypes, "lv_draw_label_dsc");
|
||||
static be_define_ctypes_class(lv_draw_line_dsc, &be_lv_draw_line_dsc, &be_class_ctypes, "lv_draw_line_dsc");
|
||||
static be_define_ctypes_class(lv_draw_mask_angle_param, &be_lv_draw_mask_angle_param, &be_class_ctypes, "lv_draw_mask_angle_param");
|
||||
static be_define_ctypes_class(lv_draw_mask_angle_param_cfg, &be_lv_draw_mask_angle_param_cfg, &be_class_ctypes, "lv_draw_mask_angle_param_cfg");
|
||||
@ -364,13 +455,20 @@ static be_define_ctypes_class(lv_draw_mask_radius_param, &be_lv_draw_mask_radius
|
||||
static be_define_ctypes_class(lv_draw_mask_radius_param_cfg, &be_lv_draw_mask_radius_param_cfg, &be_class_ctypes, "lv_draw_mask_radius_param_cfg");
|
||||
static be_define_ctypes_class(lv_draw_mask_saved, &be_lv_draw_mask_saved, &be_class_ctypes, "lv_draw_mask_saved");
|
||||
static be_define_ctypes_class(lv_draw_rect_dsc, &be_lv_draw_rect_dsc, &be_class_ctypes, "lv_draw_rect_dsc");
|
||||
static be_define_ctypes_class(lv_event, &be_lv_event, &be_class_ctypes, "lv_event");
|
||||
static be_define_ctypes_class(lv_meter_indicator, &be_lv_meter_indicator, &be_class_ctypes, "lv_meter_indicator");
|
||||
static be_define_ctypes_class(lv_meter_indicator_arc, &be_lv_meter_indicator_arc, &be_class_ctypes, "lv_meter_indicator_arc");
|
||||
static be_define_ctypes_class(lv_meter_indicator_needle_img, &be_lv_meter_indicator_needle_img, &be_class_ctypes, "lv_meter_indicator_needle_img");
|
||||
static be_define_ctypes_class(lv_meter_indicator_needle_line, &be_lv_meter_indicator_needle_line, &be_class_ctypes, "lv_meter_indicator_needle_line");
|
||||
static be_define_ctypes_class(lv_meter_indicator_scale_lines, &be_lv_meter_indicator_scale_lines, &be_class_ctypes, "lv_meter_indicator_scale_lines");
|
||||
static be_define_ctypes_class(lv_meter_scale, &be_lv_meter_scale, &be_class_ctypes, "lv_meter_scale");
|
||||
static be_define_ctypes_class(lv_obj_class, &be_lv_obj_class, &be_class_ctypes, "lv_obj_class");
|
||||
static be_define_ctypes_class(lv_point, &be_lv_point, &be_class_ctypes, "lv_point");
|
||||
static be_define_ctypes_class(lv_sqrt_res, &be_lv_sqrt_res, &be_class_ctypes, "lv_sqrt_res");
|
||||
|
||||
void be_load_ctypes_lvgl_definitions_lib(bvm *vm) {
|
||||
ctypes_register_class(vm, &be_class_lv_area, &be_lv_area);
|
||||
ctypes_register_class(vm, &be_class_lv_draw_img_dsc, &be_lv_draw_img_dsc);
|
||||
ctypes_register_class(vm, &be_class_lv_draw_label_dsc, &be_lv_draw_label_dsc);
|
||||
ctypes_register_class(vm, &be_class_lv_draw_line_dsc, &be_lv_draw_line_dsc);
|
||||
ctypes_register_class(vm, &be_class_lv_draw_mask_angle_param, &be_lv_draw_mask_angle_param);
|
||||
ctypes_register_class(vm, &be_class_lv_draw_mask_angle_param_cfg, &be_lv_draw_mask_angle_param_cfg);
|
||||
@ -385,6 +483,14 @@ void be_load_ctypes_lvgl_definitions_lib(bvm *vm) {
|
||||
ctypes_register_class(vm, &be_class_lv_draw_mask_radius_param_cfg, &be_lv_draw_mask_radius_param_cfg);
|
||||
ctypes_register_class(vm, &be_class_lv_draw_mask_saved, &be_lv_draw_mask_saved);
|
||||
ctypes_register_class(vm, &be_class_lv_draw_rect_dsc, &be_lv_draw_rect_dsc);
|
||||
ctypes_register_class(vm, &be_class_lv_event, &be_lv_event);
|
||||
ctypes_register_class(vm, &be_class_lv_meter_indicator, &be_lv_meter_indicator);
|
||||
ctypes_register_class(vm, &be_class_lv_meter_indicator_arc, &be_lv_meter_indicator_arc);
|
||||
ctypes_register_class(vm, &be_class_lv_meter_indicator_needle_img, &be_lv_meter_indicator_needle_img);
|
||||
ctypes_register_class(vm, &be_class_lv_meter_indicator_needle_line, &be_lv_meter_indicator_needle_line);
|
||||
ctypes_register_class(vm, &be_class_lv_meter_indicator_scale_lines, &be_lv_meter_indicator_scale_lines);
|
||||
ctypes_register_class(vm, &be_class_lv_meter_scale, &be_lv_meter_scale);
|
||||
ctypes_register_class(vm, &be_class_lv_obj_class, &be_lv_obj_class);
|
||||
ctypes_register_class(vm, &be_class_lv_point, &be_lv_point);
|
||||
ctypes_register_class(vm, &be_class_lv_sqrt_res, &be_lv_sqrt_res);
|
||||
}
|
||||
|
@ -7,8 +7,13 @@
|
||||
|
||||
#include "lvgl.h"
|
||||
|
||||
extern int lvx_init(bvm *vm); // generic function
|
||||
extern int lvx_tostring(bvm *vm); // generic function
|
||||
extern int lvx_init_ctor(bvm *vm, void * func);
|
||||
extern int be_call_c_func(bvm *vm, void * func, const char * return_type, const char * arg_type);
|
||||
|
||||
|
||||
// create font either empty or from parameter on stack
|
||||
int lvbe_font_create(bvm *vm) { return be_call_c_func(vm, NULL, "+lv_group", ""); }
|
||||
|
||||
#include "../generate/be_fixed_be_class_lv_font.h"
|
||||
|
||||
@ -20,8 +25,8 @@ void be_load_lvgl_font_lib(bvm *vm) {
|
||||
|
||||
/* @const_object_info_begin
|
||||
class be_class_lv_font (scope: global, name: lv_font) {
|
||||
.p, var
|
||||
init, func(lvx_init)
|
||||
_p, var
|
||||
init, func(lvbe_font_create)
|
||||
tostring, func(lvx_tostring)
|
||||
}
|
||||
@const_object_info_end */
|
||||
|
816
lib/libesp32/Berry/default/be_lvgl_glob_lib.c
Normal file
816
lib/libesp32/Berry/default/be_lvgl_glob_lib.c
Normal file
@ -0,0 +1,816 @@
|
||||
/********************************************************************
|
||||
* Tasmota LVGL lv_signal_bars widget
|
||||
*******************************************************************/
|
||||
#include "be_constobj.h"
|
||||
|
||||
#ifdef USE_LVGL
|
||||
|
||||
#include "lvgl.h"
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: get_object_from_ptr
|
||||
********************************************************************/
|
||||
be_local_closure(get_object_from_ptr, /* name */
|
||||
be_nested_proto(
|
||||
5, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 2]) { /* constants */
|
||||
/* K0 */ be_nested_string("cb_obj", 1195696482, 6),
|
||||
/* K1 */ be_nested_string("find", -1108310694, 4),
|
||||
}),
|
||||
(be_nested_const_str("get_object_from_ptr", -1949948095, 19)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[10]) { /* code */
|
||||
0x88080100, // 0000 GETMBR R2 R0 K0
|
||||
0x4C0C0000, // 0001 LDNIL R3
|
||||
0x20080403, // 0002 NE R2 R2 R3
|
||||
0x780A0004, // 0003 JMPF R2 #0009
|
||||
0x88080100, // 0004 GETMBR R2 R0 K0
|
||||
0x8C080501, // 0005 GETMET R2 R2 K1
|
||||
0x5C100200, // 0006 MOVE R4 R1
|
||||
0x7C080400, // 0007 CALL R2 2
|
||||
0x80040400, // 0008 RET 1 R2
|
||||
0x80000000, // 0009 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: widget_event_impl
|
||||
********************************************************************/
|
||||
be_local_closure(widget_event_impl, /* name */
|
||||
be_nested_proto(
|
||||
12, /* nstack */
|
||||
3, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 8]) { /* constants */
|
||||
/* K0 */ be_nested_string("introspect", 164638290, 10),
|
||||
/* K1 */ be_nested_string("lv_obj_class", -255311002, 12),
|
||||
/* K2 */ be_nested_string("lv_event", -1860877328, 8),
|
||||
/* K3 */ be_nested_string("target", 845187144, 6),
|
||||
/* K4 */ be_nested_string("get_object_from_ptr", -1949948095, 19),
|
||||
/* K5 */ be_nested_string("instance", 193386898, 8),
|
||||
/* K6 */ be_nested_string("get", 1410115415, 3),
|
||||
/* K7 */ be_nested_string("widget_event", 1951408186, 12),
|
||||
}),
|
||||
(be_nested_const_str("widget_event_impl", -2116536735, 17)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[28]) { /* code */
|
||||
0xA40E0000, // 0000 IMPORT R3 K0
|
||||
0xB8120200, // 0001 GETNGBL R4 K1
|
||||
0x5C140200, // 0002 MOVE R5 R1
|
||||
0x7C100200, // 0003 CALL R4 1
|
||||
0xB8160400, // 0004 GETNGBL R5 K2
|
||||
0x5C180400, // 0005 MOVE R6 R2
|
||||
0x7C140200, // 0006 CALL R5 1
|
||||
0x88180B03, // 0007 GETMBR R6 R5 K3
|
||||
0x8C1C0104, // 0008 GETMET R7 R0 K4
|
||||
0x60240009, // 0009 GETGBL R9 G9
|
||||
0x5C280C00, // 000A MOVE R10 R6
|
||||
0x7C240200, // 000B CALL R9 1
|
||||
0x7C1C0400, // 000C CALL R7 2
|
||||
0x60200004, // 000D GETGBL R8 G4
|
||||
0x5C240E00, // 000E MOVE R9 R7
|
||||
0x7C200200, // 000F CALL R8 1
|
||||
0x1C201105, // 0010 EQ R8 R8 K5
|
||||
0x78220008, // 0011 JMPF R8 #001B
|
||||
0x8C200706, // 0012 GETMET R8 R3 K6
|
||||
0x5C280E00, // 0013 MOVE R10 R7
|
||||
0x582C0007, // 0014 LDCONST R11 K7
|
||||
0x7C200600, // 0015 CALL R8 3
|
||||
0x78220003, // 0016 JMPF R8 #001B
|
||||
0x8C200F07, // 0017 GETMET R8 R7 K7
|
||||
0x5C280800, // 0018 MOVE R10 R4
|
||||
0x5C2C0A00, // 0019 MOVE R11 R5
|
||||
0x7C200600, // 001A CALL R8 3
|
||||
0x80000000, // 001B RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: lvgl_event_dispatch
|
||||
********************************************************************/
|
||||
be_local_closure(lvgl_event_dispatch, /* name */
|
||||
be_nested_proto(
|
||||
10, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 6]) { /* constants */
|
||||
/* K0 */ be_nested_string("introspect", 164638290, 10),
|
||||
/* K1 */ be_nested_string("lv_event", -1860877328, 8),
|
||||
/* K2 */ be_nested_string("toptr", -915119842, 5),
|
||||
/* K3 */ be_nested_string("target", 845187144, 6),
|
||||
/* K4 */ be_nested_string("cb_event_closure", -466699971, 16),
|
||||
/* K5 */ be_nested_string("get_object_from_ptr", -1949948095, 19),
|
||||
}),
|
||||
(be_nested_const_str("lvgl_event_dispatch", 2104396622, 19)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[17]) { /* code */
|
||||
0xA40A0000, // 0000 IMPORT R2 K0
|
||||
0xB80E0200, // 0001 GETNGBL R3 K1
|
||||
0x8C100502, // 0002 GETMET R4 R2 K2
|
||||
0x5C180200, // 0003 MOVE R6 R1
|
||||
0x7C100400, // 0004 CALL R4 2
|
||||
0x7C0C0200, // 0005 CALL R3 1
|
||||
0x88100703, // 0006 GETMBR R4 R3 K3
|
||||
0x88140104, // 0007 GETMBR R5 R0 K4
|
||||
0x94140A04, // 0008 GETIDX R5 R5 R4
|
||||
0x8C180105, // 0009 GETMET R6 R0 K5
|
||||
0x5C200800, // 000A MOVE R8 R4
|
||||
0x7C180400, // 000B CALL R6 2
|
||||
0x5C1C0A00, // 000C MOVE R7 R5
|
||||
0x5C200C00, // 000D MOVE R8 R6
|
||||
0x5C240600, // 000E MOVE R9 R3
|
||||
0x7C1C0400, // 000F CALL R7 2
|
||||
0x80000000, // 0010 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: widget_dtor_impl
|
||||
********************************************************************/
|
||||
be_local_closure(widget_dtor_impl, /* name */
|
||||
be_nested_proto(
|
||||
10, /* nstack */
|
||||
3, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 6]) { /* constants */
|
||||
/* K0 */ be_nested_string("introspect", 164638290, 10),
|
||||
/* K1 */ be_nested_string("lv_obj_class", -255311002, 12),
|
||||
/* K2 */ be_nested_string("get_object_from_ptr", -1949948095, 19),
|
||||
/* K3 */ be_nested_string("instance", 193386898, 8),
|
||||
/* K4 */ be_nested_string("get", 1410115415, 3),
|
||||
/* K5 */ be_nested_string("widget_destructor", -87578951, 17),
|
||||
}),
|
||||
(be_nested_const_str("widget_dtor_impl", 520430610, 16)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[21]) { /* code */
|
||||
0xA40E0000, // 0000 IMPORT R3 K0
|
||||
0xB8120200, // 0001 GETNGBL R4 K1
|
||||
0x5C140200, // 0002 MOVE R5 R1
|
||||
0x7C100200, // 0003 CALL R4 1
|
||||
0x8C140102, // 0004 GETMET R5 R0 K2
|
||||
0x5C1C0400, // 0005 MOVE R7 R2
|
||||
0x7C140400, // 0006 CALL R5 2
|
||||
0x60180004, // 0007 GETGBL R6 G4
|
||||
0x5C1C0A00, // 0008 MOVE R7 R5
|
||||
0x7C180200, // 0009 CALL R6 1
|
||||
0x1C180D03, // 000A EQ R6 R6 K3
|
||||
0x781A0007, // 000B JMPF R6 #0014
|
||||
0x8C180704, // 000C GETMET R6 R3 K4
|
||||
0x5C200A00, // 000D MOVE R8 R5
|
||||
0x58240005, // 000E LDCONST R9 K5
|
||||
0x7C180600, // 000F CALL R6 3
|
||||
0x781A0002, // 0010 JMPF R6 #0014
|
||||
0x8C180B05, // 0011 GETMET R6 R5 K5
|
||||
0x5C200800, // 0012 MOVE R8 R4
|
||||
0x7C180400, // 0013 CALL R6 2
|
||||
0x80000000, // 0014 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: register_obj
|
||||
********************************************************************/
|
||||
be_local_closure(register_obj, /* name */
|
||||
be_nested_proto(
|
||||
4, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 2]) { /* constants */
|
||||
/* K0 */ be_nested_string("cb_obj", 1195696482, 6),
|
||||
/* K1 */ be_nested_string("_p", 1594591802, 2),
|
||||
}),
|
||||
(be_nested_const_str("register_obj", -312352526, 12)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[13]) { /* code */
|
||||
0x88080100, // 0000 GETMBR R2 R0 K0
|
||||
0x4C0C0000, // 0001 LDNIL R3
|
||||
0x1C080403, // 0002 EQ R2 R2 R3
|
||||
0x780A0002, // 0003 JMPF R2 #0007
|
||||
0x60080013, // 0004 GETGBL R2 G19
|
||||
0x7C080000, // 0005 CALL R2 0
|
||||
0x90020002, // 0006 SETMBR R0 K0 R2
|
||||
0x60080009, // 0007 GETGBL R2 G9
|
||||
0x880C0301, // 0008 GETMBR R3 R1 K1
|
||||
0x7C080200, // 0009 CALL R2 1
|
||||
0x880C0100, // 000A GETMBR R3 R0 K0
|
||||
0x980C0401, // 000B SETIDX R3 R2 R1
|
||||
0x80000000, // 000C RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: gen_cb
|
||||
********************************************************************/
|
||||
be_local_closure(gen_cb, /* name */
|
||||
be_nested_proto(
|
||||
8, /* nstack */
|
||||
5, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
1, /* has sup protos */
|
||||
( &(const struct bproto*[ 1]) {
|
||||
be_nested_proto(
|
||||
4, /* nstack */
|
||||
1, /* argc */
|
||||
0, /* varg */
|
||||
1, /* has upvals */
|
||||
( &(const bupvaldesc[ 1]) { /* upvals */
|
||||
be_local_const_upval(1, 0),
|
||||
}),
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 1]) { /* constants */
|
||||
/* K0 */ be_nested_string("lvgl_event_dispatch", 2104396622, 19),
|
||||
}),
|
||||
(be_nested_const_str("<lambda>", 607256038, 8)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[ 5]) { /* code */
|
||||
0x68040000, // 0000 GETUPV R1 U0
|
||||
0x8C040300, // 0001 GETMET R1 R1 K0
|
||||
0x5C0C0000, // 0002 MOVE R3 R0
|
||||
0x7C040400, // 0003 CALL R1 2
|
||||
0x80040200, // 0004 RET 1 R1
|
||||
})
|
||||
),
|
||||
}),
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 8]) { /* constants */
|
||||
/* K0 */ be_nested_string("lv_event_cb", -1814236280, 11),
|
||||
/* K1 */ be_nested_string("cb_event_closure", -466699971, 16),
|
||||
/* K2 */ be_nested_string("event_cb", -1166269279, 8),
|
||||
/* K3 */ be_nested_string("tasmota", 424643812, 7),
|
||||
/* K4 */ be_nested_string("gen_cb", -1049739745, 6),
|
||||
/* K5 */ be_nested_string("register_obj", -312352526, 12),
|
||||
/* K6 */ be_nested_string("null_cb", -1961430836, 7),
|
||||
/* K7 */ be_nested_string("cb_do_nothing", 1488730702, 13),
|
||||
}),
|
||||
(be_nested_const_str("gen_cb", -1049739745, 6)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[41]) { /* code */
|
||||
0x1C140300, // 0000 EQ R5 R1 K0
|
||||
0x78160018, // 0001 JMPF R5 #001B
|
||||
0x88140101, // 0002 GETMBR R5 R0 K1
|
||||
0x4C180000, // 0003 LDNIL R6
|
||||
0x1C140A06, // 0004 EQ R5 R5 R6
|
||||
0x78160002, // 0005 JMPF R5 #0009
|
||||
0x60140013, // 0006 GETGBL R5 G19
|
||||
0x7C140000, // 0007 CALL R5 0
|
||||
0x90020205, // 0008 SETMBR R0 K1 R5
|
||||
0x88140102, // 0009 GETMBR R5 R0 K2
|
||||
0x4C180000, // 000A LDNIL R6
|
||||
0x1C140A06, // 000B EQ R5 R5 R6
|
||||
0x78160004, // 000C JMPF R5 #0012
|
||||
0xB8160600, // 000D GETNGBL R5 K3
|
||||
0x8C140B04, // 000E GETMET R5 R5 K4
|
||||
0x841C0000, // 000F CLOSURE R7 P0
|
||||
0x7C140400, // 0010 CALL R5 2
|
||||
0x90020405, // 0011 SETMBR R0 K2 R5
|
||||
0x8C140105, // 0012 GETMET R5 R0 K5
|
||||
0x5C1C0600, // 0013 MOVE R7 R3
|
||||
0x7C140400, // 0014 CALL R5 2
|
||||
0x88140101, // 0015 GETMBR R5 R0 K1
|
||||
0x98140802, // 0016 SETIDX R5 R4 R2
|
||||
0x88140102, // 0017 GETMBR R5 R0 K2
|
||||
0xA0000000, // 0018 CLOSE R0
|
||||
0x80040A00, // 0019 RET 1 R5
|
||||
0x7002000B, // 001A JMP #0027
|
||||
0x88140106, // 001B GETMBR R5 R0 K6
|
||||
0x4C180000, // 001C LDNIL R6
|
||||
0x1C140A06, // 001D EQ R5 R5 R6
|
||||
0x78160004, // 001E JMPF R5 #0024
|
||||
0xB8160600, // 001F GETNGBL R5 K3
|
||||
0x8C140B04, // 0020 GETMET R5 R5 K4
|
||||
0x881C0107, // 0021 GETMBR R7 R0 K7
|
||||
0x7C140400, // 0022 CALL R5 2
|
||||
0x90020C05, // 0023 SETMBR R0 K6 R5
|
||||
0x88140106, // 0024 GETMBR R5 R0 K6
|
||||
0xA0000000, // 0025 CLOSE R0
|
||||
0x80040A00, // 0026 RET 1 R5
|
||||
0xA0000000, // 0027 CLOSE R0
|
||||
0x80000000, // 0028 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: deregister_obj
|
||||
********************************************************************/
|
||||
be_local_closure(deregister_obj, /* name */
|
||||
be_nested_proto(
|
||||
5, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 3]) { /* constants */
|
||||
/* K0 */ be_nested_string("cb_obj", 1195696482, 6),
|
||||
/* K1 */ be_nested_string("remove", -611183107, 6),
|
||||
/* K2 */ be_nested_string("cb_event_closure", -466699971, 16),
|
||||
}),
|
||||
(be_nested_const_str("deregister_obj", -385000303, 14)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[17]) { /* code */
|
||||
0x88080100, // 0000 GETMBR R2 R0 K0
|
||||
0x4C0C0000, // 0001 LDNIL R3
|
||||
0x20080403, // 0002 NE R2 R2 R3
|
||||
0x780A0003, // 0003 JMPF R2 #0008
|
||||
0x88080100, // 0004 GETMBR R2 R0 K0
|
||||
0x8C080501, // 0005 GETMET R2 R2 K1
|
||||
0x5C100200, // 0006 MOVE R4 R1
|
||||
0x7C080400, // 0007 CALL R2 2
|
||||
0x88080102, // 0008 GETMBR R2 R0 K2
|
||||
0x4C0C0000, // 0009 LDNIL R3
|
||||
0x20080403, // 000A NE R2 R2 R3
|
||||
0x780A0003, // 000B JMPF R2 #0010
|
||||
0x88080102, // 000C GETMBR R2 R0 K2
|
||||
0x8C080501, // 000D GETMET R2 R2 K1
|
||||
0x5C100200, // 000E MOVE R4 R1
|
||||
0x7C080400, // 000F CALL R2 2
|
||||
0x80000000, // 0010 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: widget_cb
|
||||
********************************************************************/
|
||||
be_local_closure(widget_cb, /* name */
|
||||
be_nested_proto(
|
||||
4, /* nstack */
|
||||
1, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
1, /* has sup protos */
|
||||
( &(const struct bproto*[ 3]) {
|
||||
be_nested_proto(
|
||||
6, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
1, /* has upvals */
|
||||
( &(const bupvaldesc[ 1]) { /* upvals */
|
||||
be_local_const_upval(1, 0),
|
||||
}),
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 1]) { /* constants */
|
||||
/* K0 */ be_nested_string("widget_ctor_impl", 194252479, 16),
|
||||
}),
|
||||
(be_nested_const_str("<lambda>", 607256038, 8)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[ 6]) { /* code */
|
||||
0x68080000, // 0000 GETUPV R2 U0
|
||||
0x8C080500, // 0001 GETMET R2 R2 K0
|
||||
0x5C100000, // 0002 MOVE R4 R0
|
||||
0x5C140200, // 0003 MOVE R5 R1
|
||||
0x7C080600, // 0004 CALL R2 3
|
||||
0x80040400, // 0005 RET 1 R2
|
||||
})
|
||||
),
|
||||
be_nested_proto(
|
||||
6, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
1, /* has upvals */
|
||||
( &(const bupvaldesc[ 1]) { /* upvals */
|
||||
be_local_const_upval(1, 0),
|
||||
}),
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 1]) { /* constants */
|
||||
/* K0 */ be_nested_string("widget_dtor_impl", 520430610, 16),
|
||||
}),
|
||||
(be_nested_const_str("<lambda>", 607256038, 8)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[ 6]) { /* code */
|
||||
0x68080000, // 0000 GETUPV R2 U0
|
||||
0x8C080500, // 0001 GETMET R2 R2 K0
|
||||
0x5C100000, // 0002 MOVE R4 R0
|
||||
0x5C140200, // 0003 MOVE R5 R1
|
||||
0x7C080600, // 0004 CALL R2 3
|
||||
0x80040400, // 0005 RET 1 R2
|
||||
})
|
||||
),
|
||||
be_nested_proto(
|
||||
6, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
1, /* has upvals */
|
||||
( &(const bupvaldesc[ 1]) { /* upvals */
|
||||
be_local_const_upval(1, 0),
|
||||
}),
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 1]) { /* constants */
|
||||
/* K0 */ be_nested_string("widget_event_impl", -2116536735, 17),
|
||||
}),
|
||||
(be_nested_const_str("<lambda>", 607256038, 8)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[ 6]) { /* code */
|
||||
0x68080000, // 0000 GETUPV R2 U0
|
||||
0x8C080500, // 0001 GETMET R2 R2 K0
|
||||
0x5C100000, // 0002 MOVE R4 R0
|
||||
0x5C140200, // 0003 MOVE R5 R1
|
||||
0x7C080600, // 0004 CALL R2 3
|
||||
0x80040400, // 0005 RET 1 R2
|
||||
})
|
||||
),
|
||||
}),
|
||||
1, /* has constants */
|
||||
( &(const bvalue[14]) { /* constants */
|
||||
/* K0 */ be_nested_string("widget_ctor_cb", 876007560, 14),
|
||||
/* K1 */ be_nested_string("tasmota", 424643812, 7),
|
||||
/* K2 */ be_nested_string("gen_cb", -1049739745, 6),
|
||||
/* K3 */ be_nested_string("widget_dtor_cb", -1143421451, 14),
|
||||
/* K4 */ be_nested_string("widget_event_cb", 1508466754, 15),
|
||||
/* K5 */ be_nested_string("widget_struct_default", 781673633, 21),
|
||||
/* K6 */ be_nested_string("lv_obj_class", -255311002, 12),
|
||||
/* K7 */ be_nested_string("lv_obj", -37134147, 6),
|
||||
/* K8 */ be_nested_string("_class", -1562820946, 6),
|
||||
/* K9 */ be_nested_string("copy", -446502332, 4),
|
||||
/* K10 */ be_nested_string("base_class", 1107737279, 10),
|
||||
/* K11 */ be_nested_string("constructor_cb", -1805861999, 14),
|
||||
/* K12 */ be_nested_string("destructor_cb", 1930283190, 13),
|
||||
/* K13 */ be_nested_string("event_cb", -1166269279, 8),
|
||||
}),
|
||||
(be_nested_const_str("widget_cb", -1531384241, 9)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[53]) { /* code */
|
||||
0x88040100, // 0000 GETMBR R1 R0 K0
|
||||
0x4C080000, // 0001 LDNIL R2
|
||||
0x1C040202, // 0002 EQ R1 R1 R2
|
||||
0x78060004, // 0003 JMPF R1 #0009
|
||||
0xB8060200, // 0004 GETNGBL R1 K1
|
||||
0x8C040302, // 0005 GETMET R1 R1 K2
|
||||
0x840C0000, // 0006 CLOSURE R3 P0
|
||||
0x7C040400, // 0007 CALL R1 2
|
||||
0x90020001, // 0008 SETMBR R0 K0 R1
|
||||
0x88040103, // 0009 GETMBR R1 R0 K3
|
||||
0x4C080000, // 000A LDNIL R2
|
||||
0x1C040202, // 000B EQ R1 R1 R2
|
||||
0x78060004, // 000C JMPF R1 #0012
|
||||
0xB8060200, // 000D GETNGBL R1 K1
|
||||
0x8C040302, // 000E GETMET R1 R1 K2
|
||||
0x840C0001, // 000F CLOSURE R3 P1
|
||||
0x7C040400, // 0010 CALL R1 2
|
||||
0x90020601, // 0011 SETMBR R0 K3 R1
|
||||
0x88040104, // 0012 GETMBR R1 R0 K4
|
||||
0x4C080000, // 0013 LDNIL R2
|
||||
0x1C040202, // 0014 EQ R1 R1 R2
|
||||
0x78060004, // 0015 JMPF R1 #001B
|
||||
0xB8060200, // 0016 GETNGBL R1 K1
|
||||
0x8C040302, // 0017 GETMET R1 R1 K2
|
||||
0x840C0002, // 0018 CLOSURE R3 P2
|
||||
0x7C040400, // 0019 CALL R1 2
|
||||
0x90020801, // 001A SETMBR R0 K4 R1
|
||||
0x88040105, // 001B GETMBR R1 R0 K5
|
||||
0x4C080000, // 001C LDNIL R2
|
||||
0x1C040202, // 001D EQ R1 R1 R2
|
||||
0x78060013, // 001E JMPF R1 #0033
|
||||
0xB8060C00, // 001F GETNGBL R1 K6
|
||||
0xB80A0E00, // 0020 GETNGBL R2 K7
|
||||
0x88080508, // 0021 GETMBR R2 R2 K8
|
||||
0x7C040200, // 0022 CALL R1 1
|
||||
0x8C040309, // 0023 GETMET R1 R1 K9
|
||||
0x7C040200, // 0024 CALL R1 1
|
||||
0x90020A01, // 0025 SETMBR R0 K5 R1
|
||||
0x88040105, // 0026 GETMBR R1 R0 K5
|
||||
0xB80A0E00, // 0027 GETNGBL R2 K7
|
||||
0x88080508, // 0028 GETMBR R2 R2 K8
|
||||
0x90061402, // 0029 SETMBR R1 K10 R2
|
||||
0x88040105, // 002A GETMBR R1 R0 K5
|
||||
0x88080100, // 002B GETMBR R2 R0 K0
|
||||
0x90061602, // 002C SETMBR R1 K11 R2
|
||||
0x88040105, // 002D GETMBR R1 R0 K5
|
||||
0x88080103, // 002E GETMBR R2 R0 K3
|
||||
0x90061802, // 002F SETMBR R1 K12 R2
|
||||
0x88040105, // 0030 GETMBR R1 R0 K5
|
||||
0x88080104, // 0031 GETMBR R2 R0 K4
|
||||
0x90061A02, // 0032 SETMBR R1 K13 R2
|
||||
0xA0000000, // 0033 CLOSE R0
|
||||
0x80000000, // 0034 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: <anonymous>
|
||||
********************************************************************/
|
||||
be_local_closure(anonymous, /* name */
|
||||
be_nested_proto(
|
||||
2, /* nstack */
|
||||
0, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 1]) { /* constants */
|
||||
/* K0 */ be_nested_string("LVG: call to unsupported callback", 504176819, 33),
|
||||
}),
|
||||
(be_nested_const_str("<anonymous>", 1160973142, 11)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[ 4]) { /* code */
|
||||
0x60000001, // 0000 GETGBL R0 G1
|
||||
0x58040000, // 0001 LDCONST R1 K0
|
||||
0x7C000200, // 0002 CALL R0 1
|
||||
0x80000000, // 0003 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: create_custom_widget
|
||||
********************************************************************/
|
||||
be_local_closure(create_custom_widget, /* name */
|
||||
be_nested_proto(
|
||||
10, /* nstack */
|
||||
3, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[27]) { /* constants */
|
||||
/* K0 */ be_nested_string("introspect", 164638290, 10),
|
||||
/* K1 */ be_nested_string("lv_obj", -37134147, 6),
|
||||
/* K2 */ be_nested_string("value_error", 773297791, 11),
|
||||
/* K3 */ be_nested_string("arg must be a subclass of lv_obj", 1641882079, 32),
|
||||
/* K4 */ be_nested_string("widget_struct_by_class", -488593454, 22),
|
||||
/* K5 */ be_nested_string("find", -1108310694, 4),
|
||||
/* K6 */ be_nested_string("widget_cb", -1531384241, 9),
|
||||
/* K7 */ be_nested_string("widget_struct_default", 781673633, 21),
|
||||
/* K8 */ be_nested_string("copy", -446502332, 4),
|
||||
/* K9 */ be_nested_string("base_class", 1107737279, 10),
|
||||
/* K10 */ be_nested_string("_class", -1562820946, 6),
|
||||
/* K11 */ be_nested_string("get", 1410115415, 3),
|
||||
/* K12 */ be_nested_string("widget_width_def", -308888434, 16),
|
||||
/* K13 */ be_nested_string("width_def", 1143717879, 9),
|
||||
/* K14 */ be_nested_string("widget_height_def", -1163299483, 17),
|
||||
/* K15 */ be_nested_string("height_def", -1946728458, 10),
|
||||
/* K16 */ be_nested_string("widget_editable", -473174010, 15),
|
||||
/* K17 */ be_nested_string("editable", 60532369, 8),
|
||||
/* K18 */ be_nested_string("widget_group_def", 1246968785, 16),
|
||||
/* K19 */ be_nested_string("group_def", 1524213328, 9),
|
||||
/* K20 */ be_nested_string("widget_instance_size", 2055354779, 20),
|
||||
/* K21 */ be_nested_string("instance_size", -14697778, 13),
|
||||
/* K22 */ be_nested_string("lv", 1529997255, 2),
|
||||
/* K23 */ be_nested_string("obj_class_create_obj", -990576664, 20),
|
||||
/* K24 */ be_nested_string("_p", 1594591802, 2),
|
||||
/* K25 */ be_nested_string("register_obj", -312352526, 12),
|
||||
/* K26 */ be_nested_string("class_init_obj", 178410604, 14),
|
||||
}),
|
||||
(be_nested_const_str("create_custom_widget", 1140594778, 20)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[85]) { /* code */
|
||||
0xA40E0000, // 0000 IMPORT R3 K0
|
||||
0x6010000F, // 0001 GETGBL R4 G15
|
||||
0x5C140200, // 0002 MOVE R5 R1
|
||||
0xB81A0200, // 0003 GETNGBL R6 K1
|
||||
0x7C100400, // 0004 CALL R4 2
|
||||
0x74120000, // 0005 JMPT R4 #0007
|
||||
0xB0060503, // 0006 RAISE 1 K2 K3
|
||||
0x88100104, // 0007 GETMBR R4 R0 K4
|
||||
0x4C140000, // 0008 LDNIL R5
|
||||
0x1C100805, // 0009 EQ R4 R4 R5
|
||||
0x78120002, // 000A JMPF R4 #000E
|
||||
0x60100013, // 000B GETGBL R4 G19
|
||||
0x7C100000, // 000C CALL R4 0
|
||||
0x90020804, // 000D SETMBR R0 K4 R4
|
||||
0x60100005, // 000E GETGBL R4 G5
|
||||
0x5C140200, // 000F MOVE R5 R1
|
||||
0x7C100200, // 0010 CALL R4 1
|
||||
0x88140104, // 0011 GETMBR R5 R0 K4
|
||||
0x8C140B05, // 0012 GETMET R5 R5 K5
|
||||
0x5C1C0800, // 0013 MOVE R7 R4
|
||||
0x7C140400, // 0014 CALL R5 2
|
||||
0x4C180000, // 0015 LDNIL R6
|
||||
0x1C180A06, // 0016 EQ R6 R5 R6
|
||||
0x781A002F, // 0017 JMPF R6 #0048
|
||||
0x8C180106, // 0018 GETMET R6 R0 K6
|
||||
0x7C180200, // 0019 CALL R6 1
|
||||
0x88180107, // 001A GETMBR R6 R0 K7
|
||||
0x8C180D08, // 001B GETMET R6 R6 K8
|
||||
0x7C180200, // 001C CALL R6 1
|
||||
0x5C140C00, // 001D MOVE R5 R6
|
||||
0x60180003, // 001E GETGBL R6 G3
|
||||
0x5C1C0200, // 001F MOVE R7 R1
|
||||
0x7C180200, // 0020 CALL R6 1
|
||||
0x88180D0A, // 0021 GETMBR R6 R6 K10
|
||||
0x90161206, // 0022 SETMBR R5 K9 R6
|
||||
0x8C18070B, // 0023 GETMET R6 R3 K11
|
||||
0x5C200200, // 0024 MOVE R8 R1
|
||||
0x5824000C, // 0025 LDCONST R9 K12
|
||||
0x7C180600, // 0026 CALL R6 3
|
||||
0x781A0001, // 0027 JMPF R6 #002A
|
||||
0x8818030C, // 0028 GETMBR R6 R1 K12
|
||||
0x90161A06, // 0029 SETMBR R5 K13 R6
|
||||
0x8C18070B, // 002A GETMET R6 R3 K11
|
||||
0x5C200200, // 002B MOVE R8 R1
|
||||
0x5824000E, // 002C LDCONST R9 K14
|
||||
0x7C180600, // 002D CALL R6 3
|
||||
0x781A0001, // 002E JMPF R6 #0031
|
||||
0x8818030E, // 002F GETMBR R6 R1 K14
|
||||
0x90161E06, // 0030 SETMBR R5 K15 R6
|
||||
0x8C18070B, // 0031 GETMET R6 R3 K11
|
||||
0x5C200200, // 0032 MOVE R8 R1
|
||||
0x58240010, // 0033 LDCONST R9 K16
|
||||
0x7C180600, // 0034 CALL R6 3
|
||||
0x781A0001, // 0035 JMPF R6 #0038
|
||||
0x88180310, // 0036 GETMBR R6 R1 K16
|
||||
0x90162206, // 0037 SETMBR R5 K17 R6
|
||||
0x8C18070B, // 0038 GETMET R6 R3 K11
|
||||
0x5C200200, // 0039 MOVE R8 R1
|
||||
0x58240012, // 003A LDCONST R9 K18
|
||||
0x7C180600, // 003B CALL R6 3
|
||||
0x781A0001, // 003C JMPF R6 #003F
|
||||
0x88180312, // 003D GETMBR R6 R1 K18
|
||||
0x90162606, // 003E SETMBR R5 K19 R6
|
||||
0x8C18070B, // 003F GETMET R6 R3 K11
|
||||
0x5C200200, // 0040 MOVE R8 R1
|
||||
0x58240014, // 0041 LDCONST R9 K20
|
||||
0x7C180600, // 0042 CALL R6 3
|
||||
0x781A0001, // 0043 JMPF R6 #0046
|
||||
0x88180314, // 0044 GETMBR R6 R1 K20
|
||||
0x90162A06, // 0045 SETMBR R5 K21 R6
|
||||
0x88180104, // 0046 GETMBR R6 R0 K4
|
||||
0x98180805, // 0047 SETIDX R6 R4 R5
|
||||
0xB81A2C00, // 0048 GETNGBL R6 K22
|
||||
0x8C180D17, // 0049 GETMET R6 R6 K23
|
||||
0x5C200A00, // 004A MOVE R8 R5
|
||||
0x5C240400, // 004B MOVE R9 R2
|
||||
0x7C180600, // 004C CALL R6 3
|
||||
0x881C0D18, // 004D GETMBR R7 R6 K24
|
||||
0x90063007, // 004E SETMBR R1 K24 R7
|
||||
0x8C1C0119, // 004F GETMET R7 R0 K25
|
||||
0x5C240200, // 0050 MOVE R9 R1
|
||||
0x7C1C0400, // 0051 CALL R7 2
|
||||
0x8C1C031A, // 0052 GETMET R7 R1 K26
|
||||
0x7C1C0200, // 0053 CALL R7 1
|
||||
0x80000000, // 0054 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: widget_ctor_impl
|
||||
********************************************************************/
|
||||
be_local_closure(widget_ctor_impl, /* name */
|
||||
be_nested_proto(
|
||||
10, /* nstack */
|
||||
3, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 8]) { /* constants */
|
||||
/* K0 */ be_nested_string("introspect", 164638290, 10),
|
||||
/* K1 */ be_nested_string("lv_obj_class", -255311002, 12),
|
||||
/* K2 */ be_nested_string("get_object_from_ptr", -1949948095, 19),
|
||||
/* K3 */ be_nested_string("cb_obj", 1195696482, 6),
|
||||
/* K4 */ be_nested_string("find", -1108310694, 4),
|
||||
/* K5 */ be_nested_string("instance", 193386898, 8),
|
||||
/* K6 */ be_nested_string("get", 1410115415, 3),
|
||||
/* K7 */ be_nested_string("widget_constructor", -1751181362, 18),
|
||||
}),
|
||||
(be_nested_const_str("widget_ctor_impl", 194252479, 16)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[28]) { /* code */
|
||||
0xA40E0000, // 0000 IMPORT R3 K0
|
||||
0xB8120200, // 0001 GETNGBL R4 K1
|
||||
0x5C140200, // 0002 MOVE R5 R1
|
||||
0x7C100200, // 0003 CALL R4 1
|
||||
0x8C140102, // 0004 GETMET R5 R0 K2
|
||||
0x5C1C0400, // 0005 MOVE R7 R2
|
||||
0x7C140400, // 0006 CALL R5 2
|
||||
0x88180103, // 0007 GETMBR R6 R0 K3
|
||||
0x8C180D04, // 0008 GETMET R6 R6 K4
|
||||
0x5C200A00, // 0009 MOVE R8 R5
|
||||
0x7C180400, // 000A CALL R6 2
|
||||
0x781A0001, // 000B JMPF R6 #000E
|
||||
0x88180103, // 000C GETMBR R6 R0 K3
|
||||
0x94140C05, // 000D GETIDX R5 R6 R5
|
||||
0x60180004, // 000E GETGBL R6 G4
|
||||
0x5C1C0A00, // 000F MOVE R7 R5
|
||||
0x7C180200, // 0010 CALL R6 1
|
||||
0x1C180D05, // 0011 EQ R6 R6 K5
|
||||
0x781A0007, // 0012 JMPF R6 #001B
|
||||
0x8C180706, // 0013 GETMET R6 R3 K6
|
||||
0x5C200A00, // 0014 MOVE R8 R5
|
||||
0x58240007, // 0015 LDCONST R9 K7
|
||||
0x7C180600, // 0016 CALL R6 3
|
||||
0x781A0002, // 0017 JMPF R6 #001B
|
||||
0x8C180B07, // 0018 GETMET R6 R5 K7
|
||||
0x5C200800, // 0019 MOVE R8 R4
|
||||
0x7C180400, // 001A CALL R6 2
|
||||
0x80000000, // 001B RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified class: LVGL_glob
|
||||
********************************************************************/
|
||||
be_local_class(LVGL_glob,
|
||||
9,
|
||||
NULL,
|
||||
be_nested_map(20,
|
||||
( (struct bmapnode*) &(const bmapnode[]) {
|
||||
{ be_nested_key("widget_ctor_cb", 876007560, 14, 9), be_const_var(4) },
|
||||
{ be_nested_key("get_object_from_ptr", -1949948095, 19, 4), be_const_closure(get_object_from_ptr_closure) },
|
||||
{ be_nested_key("cb_obj", 1195696482, 6, 7), be_const_var(0) },
|
||||
{ be_nested_key("widget_struct_by_class", -488593454, 22, -1), be_const_var(8) },
|
||||
{ be_nested_key("widget_event_impl", -2116536735, 17, -1), be_const_closure(widget_event_impl_closure) },
|
||||
{ be_nested_key("widget_dtor_cb", -1143421451, 14, 6), be_const_var(5) },
|
||||
{ be_nested_key("cb_event_closure", -466699971, 16, -1), be_const_var(1) },
|
||||
{ be_nested_key("lvgl_event_dispatch", 2104396622, 19, 16), be_const_closure(lvgl_event_dispatch_closure) },
|
||||
{ be_nested_key("widget_dtor_impl", 520430610, 16, -1), be_const_closure(widget_dtor_impl_closure) },
|
||||
{ be_nested_key("null_cb", -1961430836, 7, -1), be_const_var(3) },
|
||||
{ be_nested_key("register_obj", -312352526, 12, 8), be_const_closure(register_obj_closure) },
|
||||
{ be_nested_key("gen_cb", -1049739745, 6, -1), be_const_closure(gen_cb_closure) },
|
||||
{ be_nested_key("widget_struct_default", 781673633, 21, -1), be_const_var(7) },
|
||||
{ be_nested_key("deregister_obj", -385000303, 14, 12), be_const_closure(deregister_obj_closure) },
|
||||
{ be_nested_key("widget_event_cb", 1508466754, 15, -1), be_const_var(6) },
|
||||
{ be_nested_key("widget_cb", -1531384241, 9, -1), be_const_closure(widget_cb_closure) },
|
||||
{ be_nested_key("cb_do_nothing", 1488730702, 13, 3), be_const_closure(anonymous_closure) },
|
||||
{ be_nested_key("event_cb", -1166269279, 8, -1), be_const_var(2) },
|
||||
{ be_nested_key("create_custom_widget", 1140594778, 20, -1), be_const_closure(create_custom_widget_closure) },
|
||||
{ be_nested_key("widget_ctor_impl", 194252479, 16, -1), be_const_closure(widget_ctor_impl_closure) },
|
||||
})),
|
||||
(be_nested_const_str("LVGL_glob", 315437079, 9))
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
void be_load_LVGL_glob_class(bvm *vm) {
|
||||
be_pushntvclass(vm, &be_class_LVGL_glob);
|
||||
be_setglobal(vm, "LVGL_glob");
|
||||
be_pop(vm, 1);
|
||||
}
|
||||
|
||||
#endif // USE_LVGL
|
@ -34,12 +34,18 @@ static int lv_get_ver_res(void) {
|
||||
/* `lv` methods */
|
||||
const lvbe_call_c_t lv_func[] = {
|
||||
|
||||
{ "clamp_height", (void*) &lv_clamp_height, "i", "iiii" },
|
||||
{ "clamp_width", (void*) &lv_clamp_width, "i", "iiii" },
|
||||
{ "color_mix", (void*) &lv_color_mix, "lv_color", "(lv_color)(lv_color)i" },
|
||||
{ "draw_arc", (void*) &lv_draw_arc, "", "iiiii(lv_area)(lv_draw_line_dsc)" },
|
||||
{ "dpx", (void*) &lv_dpx, "i", "i" },
|
||||
{ "draw_arc", (void*) &lv_draw_arc, "", "iiiii(lv_area)(lv_draw_arc_dsc)" },
|
||||
{ "draw_arc_dsc_init", (void*) &lv_draw_arc_dsc_init, "", "(lv_draw_arc_dsc)" },
|
||||
{ "draw_arc_get_area", (void*) &lv_draw_arc_get_area, "", "iiiiiib(lv_area)" },
|
||||
{ "draw_img", (void*) &lv_draw_img, "", "(lv_area)(lv_area).(lv_draw_img_dsc)" },
|
||||
{ "draw_img_dsc_init", (void*) &lv_draw_img_dsc_init, "", "(lv_draw_img_dsc)" },
|
||||
{ "draw_label", (void*) &lv_draw_label, "", "(lv_area)(lv_area)(lv_draw_label_dsc)s(lv_draw_label_hint)" },
|
||||
{ "draw_label_dsc_init", (void*) &lv_draw_label_dsc_init, "", "(lv_draw_label_dsc)" },
|
||||
{ "draw_letter", (void*) &lv_draw_letter, "", "(lv_point)(lv_area)(lv_font)i(lv_color)ii" },
|
||||
{ "draw_line", (void*) &lv_draw_line, "", "(lv_point)(lv_point)(lv_area)(lv_draw_line_dsc)" },
|
||||
{ "draw_line_dsc_init", (void*) &lv_draw_line_dsc_init, "", "(lv_draw_line_dsc)" },
|
||||
{ "draw_mask_add", (void*) &lv_draw_mask_add, "i", ".." },
|
||||
@ -53,23 +59,42 @@ const lvbe_call_c_t lv_func[] = {
|
||||
{ "draw_mask_remove_custom", (void*) &lv_draw_mask_remove_custom, ".", "." },
|
||||
{ "draw_mask_remove_id", (void*) &lv_draw_mask_remove_id, ".", "i" },
|
||||
{ "draw_polygon", (void*) &lv_draw_polygon, "", "ii(lv_area)(lv_draw_rect_dsc)" },
|
||||
{ "draw_px", (void*) &lv_draw_px, "", "(lv_point)(lv_area)(lv_style)" },
|
||||
{ "draw_rect", (void*) &lv_draw_rect, "", "(lv_area)(lv_area)(lv_draw_rect_dsc)" },
|
||||
{ "draw_rect_dsc_init", (void*) &lv_draw_rect_dsc_init, "", "(lv_draw_rect_dsc)" },
|
||||
{ "draw_triangle", (void*) &lv_draw_triangle, "", "i(lv_area)(lv_draw_rect_dsc)" },
|
||||
{ "event_get_data", (void*) &lv_event_get_data, ".", "" },
|
||||
{ "event_register_id", (void*) &lv_event_register_id, "i", "" },
|
||||
{ "event_send", (void*) &lv_event_send, "i", "(lv_obj)i." },
|
||||
{ "event_send_refresh", (void*) &lv_event_send_refresh, "i", "(lv_obj)" },
|
||||
{ "event_send_refresh_recursive", (void*) &lv_event_send_refresh_recursive, "", "(lv_obj)" },
|
||||
{ "event_set_cover_res", (void*) &lv_event_set_cover_res, "", "(lv_event)(lv_cover_res)" },
|
||||
{ "event_set_ext_draw_size", (void*) &lv_event_set_ext_draw_size, "", "(lv_event)i" },
|
||||
{ "get_hor_res", (void*) &lv_get_hor_res, "i", "" },
|
||||
{ "get_ver_res", (void*) &lv_get_ver_res, "i", "" },
|
||||
{ "group_get_default", (void*) &lv_group_get_default, "lv_group", "" },
|
||||
{ "img_src_get_type", (void*) &lv_img_src_get_type, "i", "." },
|
||||
{ "indev_get_obj_act", (void*) &lv_indev_get_obj_act, "lv_obj", "" },
|
||||
{ "indev_read_timer_cb", (void*) &lv_indev_read_timer_cb, "", "(lv_timer)" },
|
||||
{ "layer_sys", (void*) &lv_layer_sys, "lv_obj", "" },
|
||||
{ "layer_top", (void*) &lv_layer_top, "lv_obj", "" },
|
||||
{ "refr_now", (void*) &lv_refr_now, "", "" },
|
||||
{ "layout_register", (void*) &lv_layout_register, "i", "^lv_layout_update_cb^." },
|
||||
{ "obj_class_create_obj", (void*) &lv_obj_class_create_obj, "lv_obj", "(_lv_obj_class)(lv_obj)" },
|
||||
{ "obj_del_anim_ready_cb", (void*) &lv_obj_del_anim_ready_cb, "", "(lv_anim)" },
|
||||
{ "obj_draw_dsc_init", (void*) &lv_obj_draw_dsc_init, "", "(lv_obj_draw_part_dsc)(lv_area)" },
|
||||
{ "obj_enable_style_refresh", (void*) &lv_obj_enable_style_refresh, "", "b" },
|
||||
{ "obj_event_base", (void*) &lv_obj_event_base, "i", "(lv_obj_class)(lv_event)" },
|
||||
{ "obj_report_style_change", (void*) &lv_obj_report_style_change, "", "(lv_style)" },
|
||||
{ "obj_style_get_selector_part", (void*) &lv_obj_style_get_selector_part, "i", "(lv_style_selector)" },
|
||||
{ "obj_style_get_selector_state", (void*) &lv_obj_style_get_selector_state, "i", "(lv_style_selector)" },
|
||||
{ "refr_now", (void*) &lv_refr_now, "", "(lv_disp)" },
|
||||
{ "scr_act", (void*) &lv_scr_act, "lv_obj", "" },
|
||||
{ "scr_load", (void*) &lv_scr_load, "", "(lv_obj)" },
|
||||
{ "scr_load_anim", (void*) &lv_scr_load_anim, "", "(lv_obj)(lv_scr_load_anim)iib" },
|
||||
{ "signal_send", (void*) &lv_signal_send, "i", "(lv_obj)i." },
|
||||
{ "theme_apply", (void*) &lv_theme_apply, "", "(lv_obj)" },
|
||||
{ "theme_get_color_primary", (void*) &lv_theme_get_color_primary, "lv_color", "(lv_obj)" },
|
||||
{ "theme_get_color_secondary", (void*) &lv_theme_get_color_secondary, "lv_color", "(lv_obj)" },
|
||||
{ "theme_get_font_large", (void*) &lv_theme_get_font_large, "lv_font", "(lv_obj)" },
|
||||
{ "theme_get_font_normal", (void*) &lv_theme_get_font_normal, "lv_font", "(lv_obj)" },
|
||||
{ "theme_get_font_small", (void*) &lv_theme_get_font_small, "lv_font", "(lv_obj)" },
|
||||
{ "theme_set_apply_cb", (void*) &lv_theme_set_apply_cb, "", "(lv_theme)^lv_theme_apply_cb^" },
|
||||
{ "theme_set_parent", (void*) &lv_theme_set_parent, "", "(lv_theme)(lv_theme)" },
|
||||
|
||||
};
|
||||
const size_t lv_func_size = sizeof(lv_func) / sizeof(lv_func[0]);
|
||||
@ -84,15 +109,12 @@ typedef struct be_constint_t {
|
||||
|
||||
const be_constint_t lv0_constants[] = {
|
||||
|
||||
{ "ALIGN_BOTTOM_LEFT", LV_ALIGN_BOTTOM_LEFT },
|
||||
{ "ALIGN_BOTTOM_MID", LV_ALIGN_BOTTOM_MID },
|
||||
{ "ALIGN_BOTTOM_RIGHT", LV_ALIGN_BOTTOM_RIGHT },
|
||||
{ "ALIGN_CENTER", LV_ALIGN_CENTER },
|
||||
{ "ALIGN_IN_BOTTOM_LEFT", LV_ALIGN_IN_BOTTOM_LEFT },
|
||||
{ "ALIGN_IN_BOTTOM_MID", LV_ALIGN_IN_BOTTOM_MID },
|
||||
{ "ALIGN_IN_BOTTOM_RIGHT", LV_ALIGN_IN_BOTTOM_RIGHT },
|
||||
{ "ALIGN_IN_LEFT_MID", LV_ALIGN_IN_LEFT_MID },
|
||||
{ "ALIGN_IN_RIGHT_MID", LV_ALIGN_IN_RIGHT_MID },
|
||||
{ "ALIGN_IN_TOP_LEFT", LV_ALIGN_IN_TOP_LEFT },
|
||||
{ "ALIGN_IN_TOP_MID", LV_ALIGN_IN_TOP_MID },
|
||||
{ "ALIGN_IN_TOP_RIGHT", LV_ALIGN_IN_TOP_RIGHT },
|
||||
{ "ALIGN_DEFAULT", LV_ALIGN_DEFAULT },
|
||||
{ "ALIGN_LEFT_MID", LV_ALIGN_LEFT_MID },
|
||||
{ "ALIGN_OUT_BOTTOM_LEFT", LV_ALIGN_OUT_BOTTOM_LEFT },
|
||||
{ "ALIGN_OUT_BOTTOM_MID", LV_ALIGN_OUT_BOTTOM_MID },
|
||||
{ "ALIGN_OUT_BOTTOM_RIGHT", LV_ALIGN_OUT_BOTTOM_RIGHT },
|
||||
@ -105,19 +127,24 @@ const be_constint_t lv0_constants[] = {
|
||||
{ "ALIGN_OUT_TOP_LEFT", LV_ALIGN_OUT_TOP_LEFT },
|
||||
{ "ALIGN_OUT_TOP_MID", LV_ALIGN_OUT_TOP_MID },
|
||||
{ "ALIGN_OUT_TOP_RIGHT", LV_ALIGN_OUT_TOP_RIGHT },
|
||||
{ "ALIGN_RIGHT_MID", LV_ALIGN_RIGHT_MID },
|
||||
{ "ALIGN_TOP_LEFT", LV_ALIGN_TOP_LEFT },
|
||||
{ "ALIGN_TOP_MID", LV_ALIGN_TOP_MID },
|
||||
{ "ALIGN_TOP_RIGHT", LV_ALIGN_TOP_RIGHT },
|
||||
{ "ANIM_IMG_PART_MAIN", LV_ANIM_IMG_PART_MAIN },
|
||||
{ "ANIM_OFF", LV_ANIM_OFF },
|
||||
{ "ANIM_ON", LV_ANIM_ON },
|
||||
{ "ARC_PART_BG", LV_ARC_PART_BG },
|
||||
{ "ARC_PART_INDIC", LV_ARC_PART_INDIC },
|
||||
{ "ARC_PART_KNOB", LV_ARC_PART_KNOB },
|
||||
{ "ARC_TYPE_NORMAL", LV_ARC_TYPE_NORMAL },
|
||||
{ "ARC_TYPE_REVERSE", LV_ARC_TYPE_REVERSE },
|
||||
{ "ARC_TYPE_SYMMETRIC", LV_ARC_TYPE_SYMMETRIC },
|
||||
{ "BAR_PART_BG", LV_BAR_PART_BG },
|
||||
{ "BAR_PART_INDIC", LV_BAR_PART_INDIC },
|
||||
{ "BAR_TYPE_CUSTOM", LV_BAR_TYPE_CUSTOM },
|
||||
{ "BAR_TYPE_NORMAL", LV_BAR_TYPE_NORMAL },
|
||||
{ "BAR_TYPE_SYMMETRICAL", LV_BAR_TYPE_SYMMETRICAL },
|
||||
{ "ARC_MODE_NORMAL", LV_ARC_MODE_NORMAL },
|
||||
{ "ARC_MODE_REVERSE", LV_ARC_MODE_REVERSE },
|
||||
{ "ARC_MODE_SYMMETRICAL", LV_ARC_MODE_SYMMETRICAL },
|
||||
{ "BAR_MODE_NORMAL", LV_BAR_MODE_NORMAL },
|
||||
{ "BAR_MODE_RANGE", LV_BAR_MODE_RANGE },
|
||||
{ "BAR_MODE_SYMMETRICAL", LV_BAR_MODE_SYMMETRICAL },
|
||||
{ "BASE_DIR_AUTO", LV_BASE_DIR_AUTO },
|
||||
{ "BASE_DIR_LTR", LV_BASE_DIR_LTR },
|
||||
{ "BASE_DIR_NEUTRAL", LV_BASE_DIR_NEUTRAL },
|
||||
{ "BASE_DIR_RTL", LV_BASE_DIR_RTL },
|
||||
{ "BASE_DIR_WEAK", LV_BASE_DIR_WEAK },
|
||||
{ "BLEND_MODE_ADDITIVE", LV_BLEND_MODE_ADDITIVE },
|
||||
{ "BLEND_MODE_NORMAL", LV_BLEND_MODE_NORMAL },
|
||||
{ "BLEND_MODE_SUBTRACTIVE", LV_BLEND_MODE_SUBTRACTIVE },
|
||||
@ -129,46 +156,27 @@ const be_constint_t lv0_constants[] = {
|
||||
{ "BORDER_SIDE_RIGHT", LV_BORDER_SIDE_RIGHT },
|
||||
{ "BORDER_SIDE_TOP", LV_BORDER_SIDE_TOP },
|
||||
{ "BTNMATRIX_CTRL_CHECKABLE", LV_BTNMATRIX_CTRL_CHECKABLE },
|
||||
{ "BTNMATRIX_CTRL_CHECK_STATE", LV_BTNMATRIX_CTRL_CHECK_STATE },
|
||||
{ "BTNMATRIX_CTRL_CHECKED", LV_BTNMATRIX_CTRL_CHECKED },
|
||||
{ "BTNMATRIX_CTRL_CLICK_TRIG", LV_BTNMATRIX_CTRL_CLICK_TRIG },
|
||||
{ "BTNMATRIX_CTRL_CUSTOM_1", LV_BTNMATRIX_CTRL_CUSTOM_1 },
|
||||
{ "BTNMATRIX_CTRL_CUSTOM_2", LV_BTNMATRIX_CTRL_CUSTOM_2 },
|
||||
{ "BTNMATRIX_CTRL_DISABLED", LV_BTNMATRIX_CTRL_DISABLED },
|
||||
{ "BTNMATRIX_CTRL_HIDDEN", LV_BTNMATRIX_CTRL_HIDDEN },
|
||||
{ "BTNMATRIX_CTRL_NO_REPEAT", LV_BTNMATRIX_CTRL_NO_REPEAT },
|
||||
{ "BTNMATRIX_PART_BG", LV_BTNMATRIX_PART_BG },
|
||||
{ "BTNMATRIX_PART_BTN", LV_BTNMATRIX_PART_BTN },
|
||||
{ "BTN_PART_MAIN", LV_BTN_PART_MAIN },
|
||||
{ "BTN_STATE_CHECKED_DISABLED", LV_BTN_STATE_CHECKED_DISABLED },
|
||||
{ "BTN_STATE_CHECKED_PRESSED", LV_BTN_STATE_CHECKED_PRESSED },
|
||||
{ "BTN_STATE_CHECKED_RELEASED", LV_BTN_STATE_CHECKED_RELEASED },
|
||||
{ "BTN_STATE_DISABLED", LV_BTN_STATE_DISABLED },
|
||||
{ "BTN_STATE_PRESSED", LV_BTN_STATE_PRESSED },
|
||||
{ "BTN_STATE_RELEASED", LV_BTN_STATE_RELEASED },
|
||||
{ "CALENDAR_PART_BG", LV_CALENDAR_PART_BG },
|
||||
{ "CALENDAR_PART_DATE", LV_CALENDAR_PART_DATE },
|
||||
{ "CALENDAR_PART_DAY_NAMES", LV_CALENDAR_PART_DAY_NAMES },
|
||||
{ "CALENDAR_PART_HEADER", LV_CALENDAR_PART_HEADER },
|
||||
{ "CANVAS_PART_MAIN", LV_CANVAS_PART_MAIN },
|
||||
{ "CHART_AXIS_DRAW_LAST_TICK", LV_CHART_AXIS_DRAW_LAST_TICK },
|
||||
{ "CHART_AXIS_INVERSE_LABELS_ORDER", LV_CHART_AXIS_INVERSE_LABELS_ORDER },
|
||||
{ "BTNMATRIX_CTRL_RECOLOR", LV_BTNMATRIX_CTRL_RECOLOR },
|
||||
{ "CHART_AXIS_PRIMARY_X", LV_CHART_AXIS_PRIMARY_X },
|
||||
{ "CHART_AXIS_PRIMARY_Y", LV_CHART_AXIS_PRIMARY_Y },
|
||||
{ "CHART_AXIS_SECONDARY_X", LV_CHART_AXIS_SECONDARY_X },
|
||||
{ "CHART_AXIS_SECONDARY_Y", LV_CHART_AXIS_SECONDARY_Y },
|
||||
{ "CHART_AXIS_SKIP_LAST_TICK", LV_CHART_AXIS_SKIP_LAST_TICK },
|
||||
{ "CHART_CURSOR_DOWN", LV_CHART_CURSOR_DOWN },
|
||||
{ "CHART_CURSOR_LEFT", LV_CHART_CURSOR_LEFT },
|
||||
{ "CHART_CURSOR_NONE", LV_CHART_CURSOR_NONE },
|
||||
{ "CHART_CURSOR_RIGHT", LV_CHART_CURSOR_RIGHT },
|
||||
{ "CHART_CURSOR_UP", LV_CHART_CURSOR_UP },
|
||||
{ "CHART_PART_BG", LV_CHART_PART_BG },
|
||||
{ "CHART_PART_CURSOR", LV_CHART_PART_CURSOR },
|
||||
{ "CHART_PART_SERIES", LV_CHART_PART_SERIES },
|
||||
{ "CHART_PART_SERIES_BG", LV_CHART_PART_SERIES_BG },
|
||||
{ "CHART_TYPE_COLUMN", LV_CHART_TYPE_COLUMN },
|
||||
{ "CHART_TYPE_BAR", LV_CHART_TYPE_BAR },
|
||||
{ "CHART_TYPE_LINE", LV_CHART_TYPE_LINE },
|
||||
{ "CHART_TYPE_NONE", LV_CHART_TYPE_NONE },
|
||||
{ "CHART_TYPE_SCATTER", LV_CHART_TYPE_SCATTER },
|
||||
{ "CHART_UPDATE_MODE_CIRCULAR", LV_CHART_UPDATE_MODE_CIRCULAR },
|
||||
{ "CHART_UPDATE_MODE_SHIFT", LV_CHART_UPDATE_MODE_SHIFT },
|
||||
{ "CHECKBOX_PART_BG", LV_CHECKBOX_PART_BG },
|
||||
{ "CHECKBOX_PART_BULLET", LV_CHECKBOX_PART_BULLET },
|
||||
{ "COLORWHEEL_MODE_HUE", LV_COLORWHEEL_MODE_HUE },
|
||||
{ "COLORWHEEL_MODE_SATURATION", LV_COLORWHEEL_MODE_SATURATION },
|
||||
{ "COLORWHEEL_MODE_VALUE", LV_COLORWHEEL_MODE_VALUE },
|
||||
{ "COLOR_AQUA", 65535 },
|
||||
{ "COLOR_BLACK", 0 },
|
||||
{ "COLOR_BLUE", 255 },
|
||||
@ -186,33 +194,21 @@ const be_constint_t lv0_constants[] = {
|
||||
{ "COLOR_TEAL", 32896 },
|
||||
{ "COLOR_WHITE", 16777215 },
|
||||
{ "COLOR_YELLOW", 16776960 },
|
||||
{ "CONT_PART_MAIN", LV_CONT_PART_MAIN },
|
||||
{ "CPICKER_COLOR_MODE_HUE", LV_CPICKER_COLOR_MODE_HUE },
|
||||
{ "CPICKER_COLOR_MODE_SATURATION", LV_CPICKER_COLOR_MODE_SATURATION },
|
||||
{ "CPICKER_COLOR_MODE_VALUE", LV_CPICKER_COLOR_MODE_VALUE },
|
||||
{ "CPICKER_PART_KNOB", LV_CPICKER_PART_KNOB },
|
||||
{ "CPICKER_PART_MAIN", LV_CPICKER_PART_MAIN },
|
||||
{ "CPICKER_TYPE_DISC", LV_CPICKER_TYPE_DISC },
|
||||
{ "CPICKER_TYPE_RECT", LV_CPICKER_TYPE_RECT },
|
||||
{ "DESIGN_COVER_CHK", LV_DESIGN_COVER_CHK },
|
||||
{ "DESIGN_DRAW_MAIN", LV_DESIGN_DRAW_MAIN },
|
||||
{ "DESIGN_DRAW_POST", LV_DESIGN_DRAW_POST },
|
||||
{ "DESIGN_RES_COVER", LV_DESIGN_RES_COVER },
|
||||
{ "DESIGN_RES_MASKED", LV_DESIGN_RES_MASKED },
|
||||
{ "DESIGN_RES_NOT_COVER", LV_DESIGN_RES_NOT_COVER },
|
||||
{ "DESIGN_RES_OK", LV_DESIGN_RES_OK },
|
||||
{ "COVER_RES_COVER", LV_COVER_RES_COVER },
|
||||
{ "COVER_RES_MASKED", LV_COVER_RES_MASKED },
|
||||
{ "COVER_RES_NOT_COVER", LV_COVER_RES_NOT_COVER },
|
||||
{ "DIR_ALL", LV_DIR_ALL },
|
||||
{ "DIR_BOTTOM", LV_DIR_BOTTOM },
|
||||
{ "DIR_HOR", LV_DIR_HOR },
|
||||
{ "DIR_LEFT", LV_DIR_LEFT },
|
||||
{ "DIR_NONE", LV_DIR_NONE },
|
||||
{ "DIR_RIGHT", LV_DIR_RIGHT },
|
||||
{ "DIR_TOP", LV_DIR_TOP },
|
||||
{ "DIR_VER", LV_DIR_VER },
|
||||
{ "DISP_ROT_180", LV_DISP_ROT_180 },
|
||||
{ "DISP_ROT_270", LV_DISP_ROT_270 },
|
||||
{ "DISP_ROT_90", LV_DISP_ROT_90 },
|
||||
{ "DISP_ROT_NONE", LV_DISP_ROT_NONE },
|
||||
{ "DISP_SIZE_EXTRA_LARGE", LV_DISP_SIZE_EXTRA_LARGE },
|
||||
{ "DISP_SIZE_LARGE", LV_DISP_SIZE_LARGE },
|
||||
{ "DISP_SIZE_MEDIUM", LV_DISP_SIZE_MEDIUM },
|
||||
{ "DISP_SIZE_SMALL", LV_DISP_SIZE_SMALL },
|
||||
{ "DRAG_DIR_BOTH", LV_DRAG_DIR_BOTH },
|
||||
{ "DRAG_DIR_HOR", LV_DRAG_DIR_HOR },
|
||||
{ "DRAG_DIR_ONE", LV_DRAG_DIR_ONE },
|
||||
{ "DRAG_DIR_VER", LV_DRAG_DIR_VER },
|
||||
{ "DRAW_MASK_LINE_SIDE_BOTTOM", LV_DRAW_MASK_LINE_SIDE_BOTTOM },
|
||||
{ "DRAW_MASK_LINE_SIDE_LEFT", LV_DRAW_MASK_LINE_SIDE_LEFT },
|
||||
{ "DRAW_MASK_LINE_SIDE_RIGHT", LV_DRAW_MASK_LINE_SIDE_RIGHT },
|
||||
@ -226,40 +222,59 @@ const be_constint_t lv0_constants[] = {
|
||||
{ "DRAW_MASK_TYPE_LINE", LV_DRAW_MASK_TYPE_LINE },
|
||||
{ "DRAW_MASK_TYPE_MAP", LV_DRAW_MASK_TYPE_MAP },
|
||||
{ "DRAW_MASK_TYPE_RADIUS", LV_DRAW_MASK_TYPE_RADIUS },
|
||||
{ "DROPDOWN_DIR_DOWN", LV_DROPDOWN_DIR_DOWN },
|
||||
{ "DROPDOWN_DIR_LEFT", LV_DROPDOWN_DIR_LEFT },
|
||||
{ "DROPDOWN_DIR_RIGHT", LV_DROPDOWN_DIR_RIGHT },
|
||||
{ "DROPDOWN_DIR_UP", LV_DROPDOWN_DIR_UP },
|
||||
{ "DROPDOWN_PART_LIST", LV_DROPDOWN_PART_LIST },
|
||||
{ "DROPDOWN_PART_MAIN", LV_DROPDOWN_PART_MAIN },
|
||||
{ "DROPDOWN_PART_SCROLLBAR", LV_DROPDOWN_PART_SCROLLBAR },
|
||||
{ "DROPDOWN_PART_SELECTED", LV_DROPDOWN_PART_SELECTED },
|
||||
{ "EVENT_APPLY", LV_EVENT_APPLY },
|
||||
{ "EVENT_ALL", LV_EVENT_ALL },
|
||||
{ "EVENT_CANCEL", LV_EVENT_CANCEL },
|
||||
{ "EVENT_CHILD_CHANGED", LV_EVENT_CHILD_CHANGED },
|
||||
{ "EVENT_CLICKED", LV_EVENT_CLICKED },
|
||||
{ "EVENT_COVER_CHECK", LV_EVENT_COVER_CHECK },
|
||||
{ "EVENT_DEFOCUSED", LV_EVENT_DEFOCUSED },
|
||||
{ "EVENT_DELETE", LV_EVENT_DELETE },
|
||||
{ "EVENT_DRAG_BEGIN", LV_EVENT_DRAG_BEGIN },
|
||||
{ "EVENT_DRAG_END", LV_EVENT_DRAG_END },
|
||||
{ "EVENT_DRAG_THROW_BEGIN", LV_EVENT_DRAG_THROW_BEGIN },
|
||||
{ "EVENT_DRAW_MAIN", LV_EVENT_DRAW_MAIN },
|
||||
{ "EVENT_DRAW_MAIN_BEGIN", LV_EVENT_DRAW_MAIN_BEGIN },
|
||||
{ "EVENT_DRAW_MAIN_END", LV_EVENT_DRAW_MAIN_END },
|
||||
{ "EVENT_DRAW_PART_BEGIN", LV_EVENT_DRAW_PART_BEGIN },
|
||||
{ "EVENT_DRAW_PART_END", LV_EVENT_DRAW_PART_END },
|
||||
{ "EVENT_DRAW_POST", LV_EVENT_DRAW_POST },
|
||||
{ "EVENT_DRAW_POST_BEGIN", LV_EVENT_DRAW_POST_BEGIN },
|
||||
{ "EVENT_DRAW_POST_END", LV_EVENT_DRAW_POST_END },
|
||||
{ "EVENT_FOCUSED", LV_EVENT_FOCUSED },
|
||||
{ "EVENT_GESTURE", LV_EVENT_GESTURE },
|
||||
{ "EVENT_GET_SELF_SIZE", LV_EVENT_GET_SELF_SIZE },
|
||||
{ "EVENT_HIT_TEST", LV_EVENT_HIT_TEST },
|
||||
{ "EVENT_INSERT", LV_EVENT_INSERT },
|
||||
{ "EVENT_KEY", LV_EVENT_KEY },
|
||||
{ "EVENT_LAYOUT_CHANGED", LV_EVENT_LAYOUT_CHANGED },
|
||||
{ "EVENT_LEAVE", LV_EVENT_LEAVE },
|
||||
{ "EVENT_LONG_PRESSED", LV_EVENT_LONG_PRESSED },
|
||||
{ "EVENT_LONG_PRESSED_REPEAT", LV_EVENT_LONG_PRESSED_REPEAT },
|
||||
{ "EVENT_PRESSED", LV_EVENT_PRESSED },
|
||||
{ "EVENT_PRESSING", LV_EVENT_PRESSING },
|
||||
{ "EVENT_PRESS_LOST", LV_EVENT_PRESS_LOST },
|
||||
{ "EVENT_READY", LV_EVENT_READY },
|
||||
{ "EVENT_REFRESH", LV_EVENT_REFRESH },
|
||||
{ "EVENT_REFR_EXT_DRAW_SIZE", LV_EVENT_REFR_EXT_DRAW_SIZE },
|
||||
{ "EVENT_RELEASED", LV_EVENT_RELEASED },
|
||||
{ "EVENT_SCROLL", LV_EVENT_SCROLL },
|
||||
{ "EVENT_SCROLL_BEGIN", LV_EVENT_SCROLL_BEGIN },
|
||||
{ "EVENT_SCROLL_END", LV_EVENT_SCROLL_END },
|
||||
{ "EVENT_SHORT_CLICKED", LV_EVENT_SHORT_CLICKED },
|
||||
{ "EVENT_SIZE_CHANGED", LV_EVENT_SIZE_CHANGED },
|
||||
{ "EVENT_STYLE_CHANGED", LV_EVENT_STYLE_CHANGED },
|
||||
{ "EVENT_VALUE_CHANGED", LV_EVENT_VALUE_CHANGED },
|
||||
{ "FIT_MAX", LV_FIT_MAX },
|
||||
{ "FIT_NONE", LV_FIT_NONE },
|
||||
{ "FIT_PARENT", LV_FIT_PARENT },
|
||||
{ "FIT_TIGHT", LV_FIT_TIGHT },
|
||||
{ "FLEX_ALIGN_CENTER", LV_FLEX_ALIGN_CENTER },
|
||||
{ "FLEX_ALIGN_END", LV_FLEX_ALIGN_END },
|
||||
{ "FLEX_ALIGN_SPACE_AROUND", LV_FLEX_ALIGN_SPACE_AROUND },
|
||||
{ "FLEX_ALIGN_SPACE_BETWEEN", LV_FLEX_ALIGN_SPACE_BETWEEN },
|
||||
{ "FLEX_ALIGN_SPACE_EVENLY", LV_FLEX_ALIGN_SPACE_EVENLY },
|
||||
{ "FLEX_ALIGN_START", LV_FLEX_ALIGN_START },
|
||||
{ "FLEX_FLOW_COLUMN", LV_FLEX_FLOW_COLUMN },
|
||||
{ "FLEX_FLOW_COLUMN_REVERSE", LV_FLEX_FLOW_COLUMN_REVERSE },
|
||||
{ "FLEX_FLOW_COLUMN_WRAP", LV_FLEX_FLOW_COLUMN_WRAP },
|
||||
{ "FLEX_FLOW_COLUMN_WRAP_REVERSE", LV_FLEX_FLOW_COLUMN_WRAP_REVERSE },
|
||||
{ "FLEX_FLOW_ROW", LV_FLEX_FLOW_ROW },
|
||||
{ "FLEX_FLOW_ROW_REVERSE", LV_FLEX_FLOW_ROW_REVERSE },
|
||||
{ "FLEX_FLOW_ROW_WRAP", LV_FLEX_FLOW_ROW_WRAP },
|
||||
{ "FLEX_FLOW_ROW_WRAP_REVERSE", LV_FLEX_FLOW_ROW_WRAP_REVERSE },
|
||||
{ "FS_MODE_RD", LV_FS_MODE_RD },
|
||||
{ "FS_MODE_WR", LV_FS_MODE_WR },
|
||||
{ "FS_RES_BUSY", LV_FS_RES_BUSY },
|
||||
@ -275,19 +290,27 @@ const be_constint_t lv0_constants[] = {
|
||||
{ "FS_RES_OUT_OF_MEM", LV_FS_RES_OUT_OF_MEM },
|
||||
{ "FS_RES_TOUT", LV_FS_RES_TOUT },
|
||||
{ "FS_RES_UNKNOWN", LV_FS_RES_UNKNOWN },
|
||||
{ "GAUGE_PART_MAIN", LV_GAUGE_PART_MAIN },
|
||||
{ "GAUGE_PART_MAJOR", LV_GAUGE_PART_MAJOR },
|
||||
{ "GAUGE_PART_NEEDLE", LV_GAUGE_PART_NEEDLE },
|
||||
{ "GESTURE_DIR_BOTTOM", LV_GESTURE_DIR_BOTTOM },
|
||||
{ "GESTURE_DIR_LEFT", LV_GESTURE_DIR_LEFT },
|
||||
{ "GESTURE_DIR_RIGHT", LV_GESTURE_DIR_RIGHT },
|
||||
{ "GESTURE_DIR_TOP", LV_GESTURE_DIR_TOP },
|
||||
{ "FS_SEEK_CUR", LV_FS_SEEK_CUR },
|
||||
{ "FS_SEEK_END", LV_FS_SEEK_END },
|
||||
{ "FS_SEEK_SET", LV_FS_SEEK_SET },
|
||||
{ "GRAD_DIR_HOR", LV_GRAD_DIR_HOR },
|
||||
{ "GRAD_DIR_NONE", LV_GRAD_DIR_NONE },
|
||||
{ "GRAD_DIR_VER", LV_GRAD_DIR_VER },
|
||||
{ "GRID_ALIGN_CENTER", LV_GRID_ALIGN_CENTER },
|
||||
{ "GRID_ALIGN_END", LV_GRID_ALIGN_END },
|
||||
{ "GRID_ALIGN_SPACE_AROUND", LV_GRID_ALIGN_SPACE_AROUND },
|
||||
{ "GRID_ALIGN_SPACE_BETWEEN", LV_GRID_ALIGN_SPACE_BETWEEN },
|
||||
{ "GRID_ALIGN_SPACE_EVENLY", LV_GRID_ALIGN_SPACE_EVENLY },
|
||||
{ "GRID_ALIGN_START", LV_GRID_ALIGN_START },
|
||||
{ "GRID_ALIGN_STRETCH", LV_GRID_ALIGN_STRETCH },
|
||||
{ "GROUP_REFOCUS_POLICY_NEXT", LV_GROUP_REFOCUS_POLICY_NEXT },
|
||||
{ "GROUP_REFOCUS_POLICY_PREV", LV_GROUP_REFOCUS_POLICY_PREV },
|
||||
{ "IMGBTN_PART_MAIN", LV_IMGBTN_PART_MAIN },
|
||||
{ "IMGBTN_STATE_CHECKED_DISABLED", LV_IMGBTN_STATE_CHECKED_DISABLED },
|
||||
{ "IMGBTN_STATE_CHECKED_PRESSED", LV_IMGBTN_STATE_CHECKED_PRESSED },
|
||||
{ "IMGBTN_STATE_CHECKED_RELEASED", LV_IMGBTN_STATE_CHECKED_RELEASED },
|
||||
{ "IMGBTN_STATE_DISABLED", LV_IMGBTN_STATE_DISABLED },
|
||||
{ "IMGBTN_STATE_PRESSED", LV_IMGBTN_STATE_PRESSED },
|
||||
{ "IMGBTN_STATE_RELEASED", LV_IMGBTN_STATE_RELEASED },
|
||||
{ "IMG_CF_ALPHA_1BIT", LV_IMG_CF_ALPHA_1BIT },
|
||||
{ "IMG_CF_ALPHA_2BIT", LV_IMG_CF_ALPHA_2BIT },
|
||||
{ "IMG_CF_ALPHA_4BIT", LV_IMG_CF_ALPHA_4BIT },
|
||||
@ -303,24 +326,17 @@ const be_constint_t lv0_constants[] = {
|
||||
{ "IMG_CF_TRUE_COLOR_ALPHA", LV_IMG_CF_TRUE_COLOR_ALPHA },
|
||||
{ "IMG_CF_TRUE_COLOR_CHROMA_KEYED", LV_IMG_CF_TRUE_COLOR_CHROMA_KEYED },
|
||||
{ "IMG_CF_UNKNOWN", LV_IMG_CF_UNKNOWN },
|
||||
{ "IMG_PART_MAIN", LV_IMG_PART_MAIN },
|
||||
{ "IMG_SRC_FILE", LV_IMG_SRC_FILE },
|
||||
{ "IMG_SRC_SYMBOL", LV_IMG_SRC_SYMBOL },
|
||||
{ "IMG_SRC_UNKNOWN", LV_IMG_SRC_UNKNOWN },
|
||||
{ "IMG_SRC_VARIABLE", LV_IMG_SRC_VARIABLE },
|
||||
{ "INDEV_STATE_PR", LV_INDEV_STATE_PR },
|
||||
{ "INDEV_STATE_REL", LV_INDEV_STATE_REL },
|
||||
{ "INDEV_STATE_PRESSED", LV_INDEV_STATE_PRESSED },
|
||||
{ "INDEV_STATE_RELEASED", LV_INDEV_STATE_RELEASED },
|
||||
{ "INDEV_TYPE_BUTTON", LV_INDEV_TYPE_BUTTON },
|
||||
{ "INDEV_TYPE_ENCODER", LV_INDEV_TYPE_ENCODER },
|
||||
{ "INDEV_TYPE_KEYPAD", LV_INDEV_TYPE_KEYPAD },
|
||||
{ "INDEV_TYPE_NONE", LV_INDEV_TYPE_NONE },
|
||||
{ "INDEV_TYPE_POINTER", LV_INDEV_TYPE_POINTER },
|
||||
{ "KEYBOARD_MODE_NUM", LV_KEYBOARD_MODE_NUM },
|
||||
{ "KEYBOARD_MODE_SPECIAL", LV_KEYBOARD_MODE_SPECIAL },
|
||||
{ "KEYBOARD_MODE_TEXT_LOWER", LV_KEYBOARD_MODE_TEXT_LOWER },
|
||||
{ "KEYBOARD_MODE_TEXT_UPPER", LV_KEYBOARD_MODE_TEXT_UPPER },
|
||||
{ "KEYBOARD_PART_BG", LV_KEYBOARD_PART_BG },
|
||||
{ "KEYBOARD_PART_BTN", LV_KEYBOARD_PART_BTN },
|
||||
{ "KEY_BACKSPACE", LV_KEY_BACKSPACE },
|
||||
{ "KEY_DEL", LV_KEY_DEL },
|
||||
{ "KEY_DOWN", LV_KEY_DOWN },
|
||||
@ -333,42 +349,49 @@ const be_constint_t lv0_constants[] = {
|
||||
{ "KEY_PREV", LV_KEY_PREV },
|
||||
{ "KEY_RIGHT", LV_KEY_RIGHT },
|
||||
{ "KEY_UP", LV_KEY_UP },
|
||||
{ "LABEL_ALIGN_AUTO", LV_LABEL_ALIGN_AUTO },
|
||||
{ "LABEL_ALIGN_CENTER", LV_LABEL_ALIGN_CENTER },
|
||||
{ "LABEL_ALIGN_LEFT", LV_LABEL_ALIGN_LEFT },
|
||||
{ "LABEL_ALIGN_RIGHT", LV_LABEL_ALIGN_RIGHT },
|
||||
{ "LABEL_LONG_BREAK", LV_LABEL_LONG_BREAK },
|
||||
{ "LABEL_LONG_CROP", LV_LABEL_LONG_CROP },
|
||||
{ "LABEL_LONG_CLIP", LV_LABEL_LONG_CLIP },
|
||||
{ "LABEL_LONG_DOT", LV_LABEL_LONG_DOT },
|
||||
{ "LABEL_LONG_EXPAND", LV_LABEL_LONG_EXPAND },
|
||||
{ "LABEL_LONG_SROLL", LV_LABEL_LONG_SROLL },
|
||||
{ "LABEL_LONG_SROLL_CIRC", LV_LABEL_LONG_SROLL_CIRC },
|
||||
{ "LABEL_PART_MAIN", LV_LABEL_PART_MAIN },
|
||||
{ "LAYOUT_CENTER", LV_LAYOUT_CENTER },
|
||||
{ "LAYOUT_COLUMN_LEFT", LV_LAYOUT_COLUMN_LEFT },
|
||||
{ "LAYOUT_COLUMN_MID", LV_LAYOUT_COLUMN_MID },
|
||||
{ "LAYOUT_COLUMN_RIGHT", LV_LAYOUT_COLUMN_RIGHT },
|
||||
{ "LAYOUT_GRID", LV_LAYOUT_GRID },
|
||||
{ "LAYOUT_OFF", LV_LAYOUT_OFF },
|
||||
{ "LAYOUT_PRETTY_BOTTOM", LV_LAYOUT_PRETTY_BOTTOM },
|
||||
{ "LAYOUT_PRETTY_MID", LV_LAYOUT_PRETTY_MID },
|
||||
{ "LAYOUT_PRETTY_TOP", LV_LAYOUT_PRETTY_TOP },
|
||||
{ "LAYOUT_ROW_BOTTOM", LV_LAYOUT_ROW_BOTTOM },
|
||||
{ "LAYOUT_ROW_MID", LV_LAYOUT_ROW_MID },
|
||||
{ "LAYOUT_ROW_TOP", LV_LAYOUT_ROW_TOP },
|
||||
{ "LED_PART_MAIN", LV_LED_PART_MAIN },
|
||||
{ "LINEMETER_PART_MAIN", LV_LINEMETER_PART_MAIN },
|
||||
{ "LINE_PART_MAIN", LV_LINE_PART_MAIN },
|
||||
{ "LIST_PART_BG", LV_LIST_PART_BG },
|
||||
{ "LIST_PART_EDGE_FLASH", LV_LIST_PART_EDGE_FLASH },
|
||||
{ "LIST_PART_SCROLLABLE", LV_LIST_PART_SCROLLABLE },
|
||||
{ "LIST_PART_SCROLLBAR", LV_LIST_PART_SCROLLBAR },
|
||||
{ "MSGBOX_PART_BG", LV_MSGBOX_PART_BG },
|
||||
{ "MSGBOX_PART_BTN", LV_MSGBOX_PART_BTN },
|
||||
{ "MSGBOX_PART_BTN_BG", LV_MSGBOX_PART_BTN_BG },
|
||||
{ "OBJMASK_PART_MAIN", LV_OBJMASK_PART_MAIN },
|
||||
{ "OBJ_PART_ALL", LV_OBJ_PART_ALL },
|
||||
{ "OBJ_PART_MAIN", LV_OBJ_PART_MAIN },
|
||||
{ "LABEL_LONG_SCROLL", LV_LABEL_LONG_SCROLL },
|
||||
{ "LABEL_LONG_SCROLL_CIRCULAR", LV_LABEL_LONG_SCROLL_CIRCULAR },
|
||||
{ "LABEL_LONG_WRAP", LV_LABEL_LONG_WRAP },
|
||||
{ "METER_INDICATOR_TYPE_ARC", LV_METER_INDICATOR_TYPE_ARC },
|
||||
{ "METER_INDICATOR_TYPE_NEEDLE_IMG", LV_METER_INDICATOR_TYPE_NEEDLE_IMG },
|
||||
{ "METER_INDICATOR_TYPE_NEEDLE_LINE", LV_METER_INDICATOR_TYPE_NEEDLE_LINE },
|
||||
{ "METER_INDICATOR_TYPE_SCALE_LINES", LV_METER_INDICATOR_TYPE_SCALE_LINES },
|
||||
{ "OBJ_CLASS_EDITABLE_FALSE", LV_OBJ_CLASS_EDITABLE_FALSE },
|
||||
{ "OBJ_CLASS_EDITABLE_INHERIT", LV_OBJ_CLASS_EDITABLE_INHERIT },
|
||||
{ "OBJ_CLASS_EDITABLE_TRUE", LV_OBJ_CLASS_EDITABLE_TRUE },
|
||||
{ "OBJ_CLASS_GROUP_DEF_FALSE", LV_OBJ_CLASS_GROUP_DEF_FALSE },
|
||||
{ "OBJ_CLASS_GROUP_DEF_INHERIT", LV_OBJ_CLASS_GROUP_DEF_INHERIT },
|
||||
{ "OBJ_CLASS_GROUP_DEF_TRUE", LV_OBJ_CLASS_GROUP_DEF_TRUE },
|
||||
{ "OBJ_FLAG_ADV_HITTEST", LV_OBJ_FLAG_ADV_HITTEST },
|
||||
{ "OBJ_FLAG_CHECKABLE", LV_OBJ_FLAG_CHECKABLE },
|
||||
{ "OBJ_FLAG_CLICKABLE", LV_OBJ_FLAG_CLICKABLE },
|
||||
{ "OBJ_FLAG_CLICK_FOCUSABLE", LV_OBJ_FLAG_CLICK_FOCUSABLE },
|
||||
{ "OBJ_FLAG_EVENT_BUBBLE", LV_OBJ_FLAG_EVENT_BUBBLE },
|
||||
{ "OBJ_FLAG_FLOATING", LV_OBJ_FLAG_FLOATING },
|
||||
{ "OBJ_FLAG_GESTURE_BUBBLE", LV_OBJ_FLAG_GESTURE_BUBBLE },
|
||||
{ "OBJ_FLAG_HIDDEN", LV_OBJ_FLAG_HIDDEN },
|
||||
{ "OBJ_FLAG_IGNORE_LAYOUT", LV_OBJ_FLAG_IGNORE_LAYOUT },
|
||||
{ "OBJ_FLAG_LAYOUT_1", LV_OBJ_FLAG_LAYOUT_1 },
|
||||
{ "OBJ_FLAG_LAYOUT_2", LV_OBJ_FLAG_LAYOUT_2 },
|
||||
{ "OBJ_FLAG_PRESS_LOCK", LV_OBJ_FLAG_PRESS_LOCK },
|
||||
{ "OBJ_FLAG_SCROLLABLE", LV_OBJ_FLAG_SCROLLABLE },
|
||||
{ "OBJ_FLAG_SCROLL_CHAIN", LV_OBJ_FLAG_SCROLL_CHAIN },
|
||||
{ "OBJ_FLAG_SCROLL_ELASTIC", LV_OBJ_FLAG_SCROLL_ELASTIC },
|
||||
{ "OBJ_FLAG_SCROLL_MOMENTUM", LV_OBJ_FLAG_SCROLL_MOMENTUM },
|
||||
{ "OBJ_FLAG_SCROLL_ONE", LV_OBJ_FLAG_SCROLL_ONE },
|
||||
{ "OBJ_FLAG_SCROLL_ON_FOCUS", LV_OBJ_FLAG_SCROLL_ON_FOCUS },
|
||||
{ "OBJ_FLAG_SNAPABLE", LV_OBJ_FLAG_SNAPABLE },
|
||||
{ "OBJ_FLAG_USER_1", LV_OBJ_FLAG_USER_1 },
|
||||
{ "OBJ_FLAG_USER_2", LV_OBJ_FLAG_USER_2 },
|
||||
{ "OBJ_FLAG_USER_3", LV_OBJ_FLAG_USER_3 },
|
||||
{ "OBJ_FLAG_USER_4", LV_OBJ_FLAG_USER_4 },
|
||||
{ "OBJ_FLAG_WIDGET_1", LV_OBJ_FLAG_WIDGET_1 },
|
||||
{ "OBJ_FLAG_WIDGET_2", LV_OBJ_FLAG_WIDGET_2 },
|
||||
{ "OBJ_TREE_WALK_END", LV_OBJ_TREE_WALK_END },
|
||||
{ "OBJ_TREE_WALK_NEXT", LV_OBJ_TREE_WALK_NEXT },
|
||||
{ "OBJ_TREE_WALK_SKIP_CHILDREN", LV_OBJ_TREE_WALK_SKIP_CHILDREN },
|
||||
{ "OPA_0", LV_OPA_0 },
|
||||
{ "OPA_10", LV_OPA_10 },
|
||||
{ "OPA_100", LV_OPA_100 },
|
||||
@ -382,35 +405,50 @@ const be_constint_t lv0_constants[] = {
|
||||
{ "OPA_90", LV_OPA_90 },
|
||||
{ "OPA_COVER", LV_OPA_COVER },
|
||||
{ "OPA_TRANSP", LV_OPA_TRANSP },
|
||||
{ "PAGE_EDGE_BOTTOM", LV_PAGE_EDGE_BOTTOM },
|
||||
{ "PAGE_EDGE_LEFT", LV_PAGE_EDGE_LEFT },
|
||||
{ "PAGE_EDGE_RIGHT", LV_PAGE_EDGE_RIGHT },
|
||||
{ "PAGE_EDGE_TOP", LV_PAGE_EDGE_TOP },
|
||||
{ "PAGE_PART_BG", LV_PAGE_PART_BG },
|
||||
{ "PAGE_PART_EDGE_FLASH", LV_PAGE_PART_EDGE_FLASH },
|
||||
{ "PAGE_PART_SCROLLABLE", LV_PAGE_PART_SCROLLABLE },
|
||||
{ "PAGE_PART_SCROLLBAR", LV_PAGE_PART_SCROLLBAR },
|
||||
{ "PROTECT_CHILD_CHG", LV_PROTECT_CHILD_CHG },
|
||||
{ "PROTECT_CLICK_FOCUS", LV_PROTECT_CLICK_FOCUS },
|
||||
{ "PROTECT_EVENT_TO_DISABLED", LV_PROTECT_EVENT_TO_DISABLED },
|
||||
{ "PROTECT_FOLLOW", LV_PROTECT_FOLLOW },
|
||||
{ "PROTECT_NONE", LV_PROTECT_NONE },
|
||||
{ "PROTECT_PARENT", LV_PROTECT_PARENT },
|
||||
{ "PROTECT_POS", LV_PROTECT_POS },
|
||||
{ "PROTECT_PRESS_LOST", LV_PROTECT_PRESS_LOST },
|
||||
{ "PALETTE_AMBER", LV_PALETTE_AMBER },
|
||||
{ "PALETTE_BLUE", LV_PALETTE_BLUE },
|
||||
{ "PALETTE_BLUE_GREY", LV_PALETTE_BLUE_GREY },
|
||||
{ "PALETTE_BROWN", LV_PALETTE_BROWN },
|
||||
{ "PALETTE_CYAN", LV_PALETTE_CYAN },
|
||||
{ "PALETTE_DEEP_ORANGE", LV_PALETTE_DEEP_ORANGE },
|
||||
{ "PALETTE_DEEP_PURPLE", LV_PALETTE_DEEP_PURPLE },
|
||||
{ "PALETTE_GREEN", LV_PALETTE_GREEN },
|
||||
{ "PALETTE_GREY", LV_PALETTE_GREY },
|
||||
{ "PALETTE_INDIGO", LV_PALETTE_INDIGO },
|
||||
{ "PALETTE_LIGHT_BLUE", LV_PALETTE_LIGHT_BLUE },
|
||||
{ "PALETTE_LIGHT_GREEN", LV_PALETTE_LIGHT_GREEN },
|
||||
{ "PALETTE_LIME", LV_PALETTE_LIME },
|
||||
{ "PALETTE_NONE", LV_PALETTE_NONE },
|
||||
{ "PALETTE_ORANGE", LV_PALETTE_ORANGE },
|
||||
{ "PALETTE_PINK", LV_PALETTE_PINK },
|
||||
{ "PALETTE_PURPLE", LV_PALETTE_PURPLE },
|
||||
{ "PALETTE_RED", LV_PALETTE_RED },
|
||||
{ "PALETTE_TEAL", LV_PALETTE_TEAL },
|
||||
{ "PALETTE_YELLOW", LV_PALETTE_YELLOW },
|
||||
{ "PART_ANY", LV_PART_ANY },
|
||||
{ "PART_CURSOR", LV_PART_CURSOR },
|
||||
{ "PART_CUSTOM_FIRST", LV_PART_CUSTOM_FIRST },
|
||||
{ "PART_INDICATOR", LV_PART_INDICATOR },
|
||||
{ "PART_ITEMS", LV_PART_ITEMS },
|
||||
{ "PART_KNOB", LV_PART_KNOB },
|
||||
{ "PART_MAIN", LV_PART_MAIN },
|
||||
{ "PART_SCROLLBAR", LV_PART_SCROLLBAR },
|
||||
{ "PART_SELECTED", LV_PART_SELECTED },
|
||||
{ "PART_TEXTAREA_PLACEHOLDER", LV_PART_TEXTAREA_PLACEHOLDER },
|
||||
{ "PART_TICKS", LV_PART_TICKS },
|
||||
{ "RADIUS_CIRCLE", LV_RADIUS_CIRCLE },
|
||||
{ "RES_INV", LV_RES_INV },
|
||||
{ "RES_OK", LV_RES_OK },
|
||||
{ "ROLLER_MODE_INFINITE", LV_ROLLER_MODE_INFINITE },
|
||||
{ "ROLLER_MODE_NORMAL", LV_ROLLER_MODE_NORMAL },
|
||||
{ "ROLLER_PART_BG", LV_ROLLER_PART_BG },
|
||||
{ "ROLLER_PART_SELECTED", LV_ROLLER_PART_SELECTED },
|
||||
{ "SCROLLBAR_MODE_ACTIVE", LV_SCROLLBAR_MODE_ACTIVE },
|
||||
{ "SCROLLBAR_MODE_AUTO", LV_SCROLLBAR_MODE_AUTO },
|
||||
{ "SCROLLBAR_MODE_DRAG", LV_SCROLLBAR_MODE_DRAG },
|
||||
{ "SCROLLBAR_MODE_HIDE", LV_SCROLLBAR_MODE_HIDE },
|
||||
{ "SCROLLBAR_MODE_OFF", LV_SCROLLBAR_MODE_OFF },
|
||||
{ "SCROLLBAR_MODE_ON", LV_SCROLLBAR_MODE_ON },
|
||||
{ "SCROLLBAR_MODE_UNHIDE", LV_SCROLLBAR_MODE_UNHIDE },
|
||||
{ "SCROLL_SNAP_CENTER", LV_SCROLL_SNAP_CENTER },
|
||||
{ "SCROLL_SNAP_END", LV_SCROLL_SNAP_END },
|
||||
{ "SCROLL_SNAP_NONE", LV_SCROLL_SNAP_NONE },
|
||||
{ "SCROLL_SNAP_START", LV_SCROLL_SNAP_START },
|
||||
{ "SCR_LOAD_ANIM_FADE_ON", LV_SCR_LOAD_ANIM_FADE_ON },
|
||||
{ "SCR_LOAD_ANIM_MOVE_BOTTOM", LV_SCR_LOAD_ANIM_MOVE_BOTTOM },
|
||||
{ "SCR_LOAD_ANIM_MOVE_LEFT", LV_SCR_LOAD_ANIM_MOVE_LEFT },
|
||||
@ -421,256 +459,145 @@ const be_constint_t lv0_constants[] = {
|
||||
{ "SCR_LOAD_ANIM_OVER_LEFT", LV_SCR_LOAD_ANIM_OVER_LEFT },
|
||||
{ "SCR_LOAD_ANIM_OVER_RIGHT", LV_SCR_LOAD_ANIM_OVER_RIGHT },
|
||||
{ "SCR_LOAD_ANIM_OVER_TOP", LV_SCR_LOAD_ANIM_OVER_TOP },
|
||||
{ "SLIDER_PART_BG", LV_SLIDER_PART_BG },
|
||||
{ "SLIDER_PART_INDIC", LV_SLIDER_PART_INDIC },
|
||||
{ "SLIDER_PART_KNOB", LV_SLIDER_PART_KNOB },
|
||||
{ "SLIDER_TYPE_NORMAL", LV_SLIDER_TYPE_NORMAL },
|
||||
{ "SLIDER_TYPE_RANGE", LV_SLIDER_TYPE_RANGE },
|
||||
{ "SLIDER_TYPE_SYMMETRICAL", LV_SLIDER_TYPE_SYMMETRICAL },
|
||||
{ "SPINBOX_PART_BG", LV_SPINBOX_PART_BG },
|
||||
{ "SPINBOX_PART_CURSOR", LV_SPINBOX_PART_CURSOR },
|
||||
{ "SPINNER_DIR_BACKWARD", LV_SPINNER_DIR_BACKWARD },
|
||||
{ "SPINNER_DIR_FORWARD", LV_SPINNER_DIR_FORWARD },
|
||||
{ "SPINNER_PART_BG", LV_SPINNER_PART_BG },
|
||||
{ "SPINNER_PART_INDIC", LV_SPINNER_PART_INDIC },
|
||||
{ "SPINNER_TYPE_CONSTANT_ARC", LV_SPINNER_TYPE_CONSTANT_ARC },
|
||||
{ "SPINNER_TYPE_FILLSPIN_ARC", LV_SPINNER_TYPE_FILLSPIN_ARC },
|
||||
{ "SPINNER_TYPE_SPINNING_ARC", LV_SPINNER_TYPE_SPINNING_ARC },
|
||||
{ "SIZE_CONTENT", LV_SIZE_CONTENT },
|
||||
{ "SLIDER_MODE_NORMAL", LV_SLIDER_MODE_NORMAL },
|
||||
{ "SLIDER_MODE_RANGE", LV_SLIDER_MODE_RANGE },
|
||||
{ "SLIDER_MODE_SYMMETRICAL", LV_SLIDER_MODE_SYMMETRICAL },
|
||||
{ "SPAN_MODE_BREAK", LV_SPAN_MODE_BREAK },
|
||||
{ "SPAN_MODE_EXPAND", LV_SPAN_MODE_EXPAND },
|
||||
{ "SPAN_MODE_FIXED", LV_SPAN_MODE_FIXED },
|
||||
{ "SPAN_OVERFLOW_CLIP", LV_SPAN_OVERFLOW_CLIP },
|
||||
{ "SPAN_OVERFLOW_ELLIPSIS", LV_SPAN_OVERFLOW_ELLIPSIS },
|
||||
{ "STATE_ANY", LV_STATE_ANY },
|
||||
{ "STATE_CHECKED", LV_STATE_CHECKED },
|
||||
{ "STATE_DEFAULT", LV_STATE_DEFAULT },
|
||||
{ "STATE_DISABLED", LV_STATE_DISABLED },
|
||||
{ "STATE_EDITED", LV_STATE_EDITED },
|
||||
{ "STATE_FOCUSED", LV_STATE_FOCUSED },
|
||||
{ "STATE_FOCUS_KEY", LV_STATE_FOCUS_KEY },
|
||||
{ "STATE_HOVERED", LV_STATE_HOVERED },
|
||||
{ "STATE_PRESSED", LV_STATE_PRESSED },
|
||||
{ "STYLE_BG_BLEND_MODE", LV_STYLE_BG_BLEND_MODE },
|
||||
{ "STATE_SCROLLED", LV_STATE_SCROLLED },
|
||||
{ "STATE_USER_1", LV_STATE_USER_1 },
|
||||
{ "STATE_USER_2", LV_STATE_USER_2 },
|
||||
{ "STATE_USER_3", LV_STATE_USER_3 },
|
||||
{ "STATE_USER_4", LV_STATE_USER_4 },
|
||||
{ "STYLE_ALIGN", LV_STYLE_ALIGN },
|
||||
{ "STYLE_ANIM_SPEED", LV_STYLE_ANIM_SPEED },
|
||||
{ "STYLE_ANIM_TIME", LV_STYLE_ANIM_TIME },
|
||||
{ "STYLE_ARC_COLOR", LV_STYLE_ARC_COLOR },
|
||||
{ "STYLE_ARC_COLOR_FILTERED", LV_STYLE_ARC_COLOR_FILTERED },
|
||||
{ "STYLE_ARC_IMG_SRC", LV_STYLE_ARC_IMG_SRC },
|
||||
{ "STYLE_ARC_OPA", LV_STYLE_ARC_OPA },
|
||||
{ "STYLE_ARC_ROUNDED", LV_STYLE_ARC_ROUNDED },
|
||||
{ "STYLE_ARC_WIDTH", LV_STYLE_ARC_WIDTH },
|
||||
{ "STYLE_BASE_DIR", LV_STYLE_BASE_DIR },
|
||||
{ "STYLE_BG_COLOR", LV_STYLE_BG_COLOR },
|
||||
{ "STYLE_BG_COLOR_FILTERED", LV_STYLE_BG_COLOR_FILTERED },
|
||||
{ "STYLE_BG_GRAD_COLOR", LV_STYLE_BG_GRAD_COLOR },
|
||||
{ "STYLE_BG_GRAD_COLOR_FILTERED", LV_STYLE_BG_GRAD_COLOR_FILTERED },
|
||||
{ "STYLE_BG_GRAD_DIR", LV_STYLE_BG_GRAD_DIR },
|
||||
{ "STYLE_BG_GRAD_STOP", LV_STYLE_BG_GRAD_STOP },
|
||||
{ "STYLE_BG_IMG_OPA", LV_STYLE_BG_IMG_OPA },
|
||||
{ "STYLE_BG_IMG_RECOLOR", LV_STYLE_BG_IMG_RECOLOR },
|
||||
{ "STYLE_BG_IMG_RECOLOR_FILTERED", LV_STYLE_BG_IMG_RECOLOR_FILTERED },
|
||||
{ "STYLE_BG_IMG_RECOLOR_OPA", LV_STYLE_BG_IMG_RECOLOR_OPA },
|
||||
{ "STYLE_BG_IMG_SRC", LV_STYLE_BG_IMG_SRC },
|
||||
{ "STYLE_BG_IMG_TILED", LV_STYLE_BG_IMG_TILED },
|
||||
{ "STYLE_BG_MAIN_STOP", LV_STYLE_BG_MAIN_STOP },
|
||||
{ "STYLE_BG_OPA", LV_STYLE_BG_OPA },
|
||||
{ "STYLE_BORDER_BLEND_MODE", LV_STYLE_BORDER_BLEND_MODE },
|
||||
{ "STYLE_BLEND_MODE", LV_STYLE_BLEND_MODE },
|
||||
{ "STYLE_BORDER_COLOR", LV_STYLE_BORDER_COLOR },
|
||||
{ "STYLE_BORDER_COLOR_FILTERED", LV_STYLE_BORDER_COLOR_FILTERED },
|
||||
{ "STYLE_BORDER_OPA", LV_STYLE_BORDER_OPA },
|
||||
{ "STYLE_BORDER_POST", LV_STYLE_BORDER_POST },
|
||||
{ "STYLE_BORDER_SIDE", LV_STYLE_BORDER_SIDE },
|
||||
{ "STYLE_BORDER_WIDTH", LV_STYLE_BORDER_WIDTH },
|
||||
{ "STYLE_CLIP_CORNER", LV_STYLE_CLIP_CORNER },
|
||||
{ "STYLE_IMAGE_BLEND_MODE", LV_STYLE_IMAGE_BLEND_MODE },
|
||||
{ "STYLE_IMAGE_OPA", LV_STYLE_IMAGE_OPA },
|
||||
{ "STYLE_IMAGE_RECOLOR", LV_STYLE_IMAGE_RECOLOR },
|
||||
{ "STYLE_IMAGE_RECOLOR_OPA", LV_STYLE_IMAGE_RECOLOR_OPA },
|
||||
{ "STYLE_LINE_BLEND_MODE", LV_STYLE_LINE_BLEND_MODE },
|
||||
{ "STYLE_COLOR_FILTER_DSC", LV_STYLE_COLOR_FILTER_DSC },
|
||||
{ "STYLE_COLOR_FILTER_OPA", LV_STYLE_COLOR_FILTER_OPA },
|
||||
{ "STYLE_HEIGHT", LV_STYLE_HEIGHT },
|
||||
{ "STYLE_IMG_OPA", LV_STYLE_IMG_OPA },
|
||||
{ "STYLE_IMG_RECOLOR", LV_STYLE_IMG_RECOLOR },
|
||||
{ "STYLE_IMG_RECOLOR_FILTERED", LV_STYLE_IMG_RECOLOR_FILTERED },
|
||||
{ "STYLE_IMG_RECOLOR_OPA", LV_STYLE_IMG_RECOLOR_OPA },
|
||||
{ "STYLE_LAYOUT", LV_STYLE_LAYOUT },
|
||||
{ "STYLE_LINE_COLOR", LV_STYLE_LINE_COLOR },
|
||||
{ "STYLE_LINE_COLOR_FILTERED", LV_STYLE_LINE_COLOR_FILTERED },
|
||||
{ "STYLE_LINE_DASH_GAP", LV_STYLE_LINE_DASH_GAP },
|
||||
{ "STYLE_LINE_DASH_WIDTH", LV_STYLE_LINE_DASH_WIDTH },
|
||||
{ "STYLE_LINE_OPA", LV_STYLE_LINE_OPA },
|
||||
{ "STYLE_LINE_ROUNDED", LV_STYLE_LINE_ROUNDED },
|
||||
{ "STYLE_LINE_WIDTH", LV_STYLE_LINE_WIDTH },
|
||||
{ "STYLE_MARGIN_BOTTOM", LV_STYLE_MARGIN_BOTTOM },
|
||||
{ "STYLE_MARGIN_LEFT", LV_STYLE_MARGIN_LEFT },
|
||||
{ "STYLE_MARGIN_RIGHT", LV_STYLE_MARGIN_RIGHT },
|
||||
{ "STYLE_MARGIN_TOP", LV_STYLE_MARGIN_TOP },
|
||||
{ "STYLE_OPA_SCALE", LV_STYLE_OPA_SCALE },
|
||||
{ "STYLE_OUTLINE_BLEND_MODE", LV_STYLE_OUTLINE_BLEND_MODE },
|
||||
{ "STYLE_MAX_HEIGHT", LV_STYLE_MAX_HEIGHT },
|
||||
{ "STYLE_MAX_WIDTH", LV_STYLE_MAX_WIDTH },
|
||||
{ "STYLE_MIN_HEIGHT", LV_STYLE_MIN_HEIGHT },
|
||||
{ "STYLE_MIN_WIDTH", LV_STYLE_MIN_WIDTH },
|
||||
{ "STYLE_OPA", LV_STYLE_OPA },
|
||||
{ "STYLE_OUTLINE_COLOR", LV_STYLE_OUTLINE_COLOR },
|
||||
{ "STYLE_OUTLINE_COLOR_FILTERED", LV_STYLE_OUTLINE_COLOR_FILTERED },
|
||||
{ "STYLE_OUTLINE_OPA", LV_STYLE_OUTLINE_OPA },
|
||||
{ "STYLE_OUTLINE_PAD", LV_STYLE_OUTLINE_PAD },
|
||||
{ "STYLE_OUTLINE_WIDTH", LV_STYLE_OUTLINE_WIDTH },
|
||||
{ "STYLE_PAD_BOTTOM", LV_STYLE_PAD_BOTTOM },
|
||||
{ "STYLE_PAD_INNER", LV_STYLE_PAD_INNER },
|
||||
{ "STYLE_PAD_COLUMN", LV_STYLE_PAD_COLUMN },
|
||||
{ "STYLE_PAD_LEFT", LV_STYLE_PAD_LEFT },
|
||||
{ "STYLE_PAD_RIGHT", LV_STYLE_PAD_RIGHT },
|
||||
{ "STYLE_PAD_ROW", LV_STYLE_PAD_ROW },
|
||||
{ "STYLE_PAD_TOP", LV_STYLE_PAD_TOP },
|
||||
{ "STYLE_PATTERN_BLEND_MODE", LV_STYLE_PATTERN_BLEND_MODE },
|
||||
{ "STYLE_PATTERN_IMAGE", LV_STYLE_PATTERN_IMAGE },
|
||||
{ "STYLE_PATTERN_OPA", LV_STYLE_PATTERN_OPA },
|
||||
{ "STYLE_PATTERN_RECOLOR", LV_STYLE_PATTERN_RECOLOR },
|
||||
{ "STYLE_PATTERN_RECOLOR_OPA", LV_STYLE_PATTERN_RECOLOR_OPA },
|
||||
{ "STYLE_PATTERN_REPEAT", LV_STYLE_PATTERN_REPEAT },
|
||||
{ "STYLE_PROP_ALL", LV_STYLE_PROP_ALL },
|
||||
{ "STYLE_PROP_ANY", LV_STYLE_PROP_ANY },
|
||||
{ "STYLE_PROP_INV", LV_STYLE_PROP_INV },
|
||||
{ "STYLE_RADIUS", LV_STYLE_RADIUS },
|
||||
{ "STYLE_SCALE_BORDER_WIDTH", LV_STYLE_SCALE_BORDER_WIDTH },
|
||||
{ "STYLE_SCALE_END_BORDER_WIDTH", LV_STYLE_SCALE_END_BORDER_WIDTH },
|
||||
{ "STYLE_SCALE_END_COLOR", LV_STYLE_SCALE_END_COLOR },
|
||||
{ "STYLE_SCALE_END_LINE_WIDTH", LV_STYLE_SCALE_END_LINE_WIDTH },
|
||||
{ "STYLE_SCALE_GRAD_COLOR", LV_STYLE_SCALE_GRAD_COLOR },
|
||||
{ "STYLE_SCALE_WIDTH", LV_STYLE_SCALE_WIDTH },
|
||||
{ "STYLE_SHADOW_BLEND_MODE", LV_STYLE_SHADOW_BLEND_MODE },
|
||||
{ "STYLE_SHADOW_COLOR", LV_STYLE_SHADOW_COLOR },
|
||||
{ "STYLE_SHADOW_COLOR_FILTERED", LV_STYLE_SHADOW_COLOR_FILTERED },
|
||||
{ "STYLE_SHADOW_OFS_X", LV_STYLE_SHADOW_OFS_X },
|
||||
{ "STYLE_SHADOW_OFS_Y", LV_STYLE_SHADOW_OFS_Y },
|
||||
{ "STYLE_SHADOW_OPA", LV_STYLE_SHADOW_OPA },
|
||||
{ "STYLE_SHADOW_SPREAD", LV_STYLE_SHADOW_SPREAD },
|
||||
{ "STYLE_SHADOW_WIDTH", LV_STYLE_SHADOW_WIDTH },
|
||||
{ "STYLE_SIZE", LV_STYLE_SIZE },
|
||||
{ "STYLE_TEXT_BLEND_MODE", LV_STYLE_TEXT_BLEND_MODE },
|
||||
{ "STYLE_TEXT_ALIGN", LV_STYLE_TEXT_ALIGN },
|
||||
{ "STYLE_TEXT_COLOR", LV_STYLE_TEXT_COLOR },
|
||||
{ "STYLE_TEXT_COLOR_FILTERED", LV_STYLE_TEXT_COLOR_FILTERED },
|
||||
{ "STYLE_TEXT_DECOR", LV_STYLE_TEXT_DECOR },
|
||||
{ "STYLE_TEXT_FONT", LV_STYLE_TEXT_FONT },
|
||||
{ "STYLE_TEXT_LETTER_SPACE", LV_STYLE_TEXT_LETTER_SPACE },
|
||||
{ "STYLE_TEXT_LINE_SPACE", LV_STYLE_TEXT_LINE_SPACE },
|
||||
{ "STYLE_TEXT_OPA", LV_STYLE_TEXT_OPA },
|
||||
{ "STYLE_TEXT_SEL_BG_COLOR", LV_STYLE_TEXT_SEL_BG_COLOR },
|
||||
{ "STYLE_TEXT_SEL_COLOR", LV_STYLE_TEXT_SEL_COLOR },
|
||||
{ "STYLE_TRANSFORM_ANGLE", LV_STYLE_TRANSFORM_ANGLE },
|
||||
{ "STYLE_TRANSFORM_HEIGHT", LV_STYLE_TRANSFORM_HEIGHT },
|
||||
{ "STYLE_TRANSFORM_WIDTH", LV_STYLE_TRANSFORM_WIDTH },
|
||||
{ "STYLE_TRANSFORM_ZOOM", LV_STYLE_TRANSFORM_ZOOM },
|
||||
{ "STYLE_TRANSITION_DELAY", LV_STYLE_TRANSITION_DELAY },
|
||||
{ "STYLE_TRANSITION_PATH", LV_STYLE_TRANSITION_PATH },
|
||||
{ "STYLE_TRANSITION_PROP_1", LV_STYLE_TRANSITION_PROP_1 },
|
||||
{ "STYLE_TRANSITION_PROP_2", LV_STYLE_TRANSITION_PROP_2 },
|
||||
{ "STYLE_TRANSITION_PROP_3", LV_STYLE_TRANSITION_PROP_3 },
|
||||
{ "STYLE_TRANSITION_PROP_4", LV_STYLE_TRANSITION_PROP_4 },
|
||||
{ "STYLE_TRANSITION_PROP_5", LV_STYLE_TRANSITION_PROP_5 },
|
||||
{ "STYLE_TRANSITION_PROP_6", LV_STYLE_TRANSITION_PROP_6 },
|
||||
{ "STYLE_TRANSITION_TIME", LV_STYLE_TRANSITION_TIME },
|
||||
{ "STYLE_VALUE_ALIGN", LV_STYLE_VALUE_ALIGN },
|
||||
{ "STYLE_VALUE_BLEND_MODE", LV_STYLE_VALUE_BLEND_MODE },
|
||||
{ "STYLE_VALUE_COLOR", LV_STYLE_VALUE_COLOR },
|
||||
{ "STYLE_VALUE_FONT", LV_STYLE_VALUE_FONT },
|
||||
{ "STYLE_VALUE_LETTER_SPACE", LV_STYLE_VALUE_LETTER_SPACE },
|
||||
{ "STYLE_VALUE_LINE_SPACE", LV_STYLE_VALUE_LINE_SPACE },
|
||||
{ "STYLE_VALUE_OFS_X", LV_STYLE_VALUE_OFS_X },
|
||||
{ "STYLE_VALUE_OFS_Y", LV_STYLE_VALUE_OFS_Y },
|
||||
{ "STYLE_VALUE_OPA", LV_STYLE_VALUE_OPA },
|
||||
{ "STYLE_VALUE_STR", LV_STYLE_VALUE_STR },
|
||||
{ "SWITCH_PART_BG", LV_SWITCH_PART_BG },
|
||||
{ "SWITCH_PART_INDIC", LV_SWITCH_PART_INDIC },
|
||||
{ "SWITCH_PART_KNOB", LV_SWITCH_PART_KNOB },
|
||||
{ "TABLE_PART_BG", LV_TABLE_PART_BG },
|
||||
{ "TABLE_PART_CELL1", LV_TABLE_PART_CELL1 },
|
||||
{ "TABLE_PART_CELL2", LV_TABLE_PART_CELL2 },
|
||||
{ "TABLE_PART_CELL3", LV_TABLE_PART_CELL3 },
|
||||
{ "TABLE_PART_CELL4", LV_TABLE_PART_CELL4 },
|
||||
{ "TABVIEW_PART_BG", LV_TABVIEW_PART_BG },
|
||||
{ "TABVIEW_PART_BG_SCROLLABLE", LV_TABVIEW_PART_BG_SCROLLABLE },
|
||||
{ "TABVIEW_PART_INDIC", LV_TABVIEW_PART_INDIC },
|
||||
{ "TABVIEW_PART_TAB_BG", LV_TABVIEW_PART_TAB_BG },
|
||||
{ "TABVIEW_PART_TAB_BTN", LV_TABVIEW_PART_TAB_BTN },
|
||||
{ "TABVIEW_TAB_POS_BOTTOM", LV_TABVIEW_TAB_POS_BOTTOM },
|
||||
{ "TABVIEW_TAB_POS_LEFT", LV_TABVIEW_TAB_POS_LEFT },
|
||||
{ "TABVIEW_TAB_POS_NONE", LV_TABVIEW_TAB_POS_NONE },
|
||||
{ "TABVIEW_TAB_POS_RIGHT", LV_TABVIEW_TAB_POS_RIGHT },
|
||||
{ "TABVIEW_TAB_POS_TOP", LV_TABVIEW_TAB_POS_TOP },
|
||||
{ "STYLE_TRANSITION", LV_STYLE_TRANSITION },
|
||||
{ "STYLE_TRANSLATE_X", LV_STYLE_TRANSLATE_X },
|
||||
{ "STYLE_TRANSLATE_Y", LV_STYLE_TRANSLATE_Y },
|
||||
{ "STYLE_WIDTH", LV_STYLE_WIDTH },
|
||||
{ "STYLE_X", LV_STYLE_X },
|
||||
{ "STYLE_Y", LV_STYLE_Y },
|
||||
{ "TABLE_CELL_CTRL_CUSTOM_1", LV_TABLE_CELL_CTRL_CUSTOM_1 },
|
||||
{ "TABLE_CELL_CTRL_CUSTOM_2", LV_TABLE_CELL_CTRL_CUSTOM_2 },
|
||||
{ "TABLE_CELL_CTRL_CUSTOM_3", LV_TABLE_CELL_CTRL_CUSTOM_3 },
|
||||
{ "TABLE_CELL_CTRL_CUSTOM_4", LV_TABLE_CELL_CTRL_CUSTOM_4 },
|
||||
{ "TABLE_CELL_CTRL_MERGE_RIGHT", LV_TABLE_CELL_CTRL_MERGE_RIGHT },
|
||||
{ "TABLE_CELL_CTRL_TEXT_CROP", LV_TABLE_CELL_CTRL_TEXT_CROP },
|
||||
{ "TEXTAREA_CURSOR_LAST", LV_TEXTAREA_CURSOR_LAST },
|
||||
{ "TEXTAREA_PART_BG", LV_TEXTAREA_PART_BG },
|
||||
{ "TEXTAREA_PART_CURSOR", LV_TEXTAREA_PART_CURSOR },
|
||||
{ "TEXTAREA_PART_EDGE_FLASH", LV_TEXTAREA_PART_EDGE_FLASH },
|
||||
{ "TEXTAREA_PART_PLACEHOLDER", LV_TEXTAREA_PART_PLACEHOLDER },
|
||||
{ "TEXTAREA_PART_SCROLLBAR", LV_TEXTAREA_PART_SCROLLBAR },
|
||||
{ "TEXT_ALIGN_AUTO", LV_TEXT_ALIGN_AUTO },
|
||||
{ "TEXT_ALIGN_CENTER", LV_TEXT_ALIGN_CENTER },
|
||||
{ "TEXT_ALIGN_LEFT", LV_TEXT_ALIGN_LEFT },
|
||||
{ "TEXT_ALIGN_RIGHT", LV_TEXT_ALIGN_RIGHT },
|
||||
{ "TEXT_CMD_STATE_IN", LV_TEXT_CMD_STATE_IN },
|
||||
{ "TEXT_CMD_STATE_PAR", LV_TEXT_CMD_STATE_PAR },
|
||||
{ "TEXT_CMD_STATE_WAIT", LV_TEXT_CMD_STATE_WAIT },
|
||||
{ "TEXT_DECOR_NONE", LV_TEXT_DECOR_NONE },
|
||||
{ "TEXT_DECOR_STRIKETHROUGH", LV_TEXT_DECOR_STRIKETHROUGH },
|
||||
{ "TEXT_DECOR_UNDERLINE", LV_TEXT_DECOR_UNDERLINE },
|
||||
{ "TILEVIEW_PART_BG", LV_TILEVIEW_PART_BG },
|
||||
{ "TILEVIEW_PART_EDGE_FLASH", LV_TILEVIEW_PART_EDGE_FLASH },
|
||||
{ "TILEVIEW_PART_SCROLLBAR", LV_TILEVIEW_PART_SCROLLBAR },
|
||||
{ "TXT_CMD_STATE_IN", LV_TXT_CMD_STATE_IN },
|
||||
{ "TXT_CMD_STATE_PAR", LV_TXT_CMD_STATE_PAR },
|
||||
{ "TXT_CMD_STATE_WAIT", LV_TXT_CMD_STATE_WAIT },
|
||||
{ "TXT_FLAG_CENTER", LV_TXT_FLAG_CENTER },
|
||||
{ "TXT_FLAG_EXPAND", LV_TXT_FLAG_EXPAND },
|
||||
{ "TXT_FLAG_FIT", LV_TXT_FLAG_FIT },
|
||||
{ "TXT_FLAG_NONE", LV_TXT_FLAG_NONE },
|
||||
{ "TXT_FLAG_RECOLOR", LV_TXT_FLAG_RECOLOR },
|
||||
{ "TXT_FLAG_RIGHT", LV_TXT_FLAG_RIGHT },
|
||||
{ "WIN_PART_BG", LV_WIN_PART_BG },
|
||||
{ "WIN_PART_CONTENT_SCROLLABLE", LV_WIN_PART_CONTENT_SCROLLABLE },
|
||||
{ "WIN_PART_HEADER", LV_WIN_PART_HEADER },
|
||||
{ "WIN_PART_SCROLLBAR", LV_WIN_PART_SCROLLBAR },
|
||||
{ "TEXT_FLAG_EXPAND", LV_TEXT_FLAG_EXPAND },
|
||||
{ "TEXT_FLAG_FIT", LV_TEXT_FLAG_FIT },
|
||||
{ "TEXT_FLAG_NONE", LV_TEXT_FLAG_NONE },
|
||||
{ "TEXT_FLAG_RECOLOR", LV_TEXT_FLAG_RECOLOR },
|
||||
|
||||
};
|
||||
|
||||
const size_t lv0_constants_size = sizeof(lv0_constants)/sizeof(lv0_constants[0]);
|
||||
#if !BE_USE_PRECOMPILED_OBJECT
|
||||
|
||||
be_native_module_attr_table(lvgl) {
|
||||
// Symbols
|
||||
be_native_module_str("SYMBOL_AUDIO", "\xef\x80\x81"),
|
||||
be_native_module_str("SYMBOL_VIDEO", "\xef\x80\x88"),
|
||||
be_native_module_str("SYMBOL_LIST", "\xef\x80\x8b"),
|
||||
be_native_module_str("SYMBOL_OK", "\xef\x80\x8c"),
|
||||
be_native_module_str("SYMBOL_CLOSE", "\xef\x80\x8d"),
|
||||
be_native_module_str("SYMBOL_POWER", "\xef\x80\x91"),
|
||||
be_native_module_str("SYMBOL_SETTINGS", "\xef\x80\x93"),
|
||||
be_native_module_str("SYMBOL_HOME", "\xef\x80\x95"),
|
||||
be_native_module_str("SYMBOL_DOWNLOAD", "\xef\x80\x99"),
|
||||
be_native_module_str("SYMBOL_DRIVE", "\xef\x80\x9c"),
|
||||
be_native_module_str("SYMBOL_REFRESH", "\xef\x80\xa1"),
|
||||
be_native_module_str("SYMBOL_MUTE", "\xef\x80\xa6"),
|
||||
be_native_module_str("SYMBOL_VOLUME_MID", "\xef\x80\xa7"),
|
||||
be_native_module_str("SYMBOL_VOLUME_MAX", "\xef\x80\xa8"),
|
||||
be_native_module_str("SYMBOL_IMAGE", "\xef\x80\xbe"),
|
||||
be_native_module_str("SYMBOL_EDIT", "\xef\x8C\x84"),
|
||||
be_native_module_str("SYMBOL_PREV", "\xef\x81\x88"),
|
||||
be_native_module_str("SYMBOL_PLAY", "\xef\x81\x8b"),
|
||||
be_native_module_str("SYMBOL_PAUSE", "\xef\x81\x8c"),
|
||||
be_native_module_str("SYMBOL_STOP", "\xef\x81\x8d"),
|
||||
be_native_module_str("SYMBOL_NEXT", "\xef\x81\x91"),
|
||||
be_native_module_str("SYMBOL_EJECT", "\xef\x81\x92"),
|
||||
be_native_module_str("SYMBOL_LEFT", "\xef\x81\x93"),
|
||||
be_native_module_str("SYMBOL_RIGHT", "\xef\x81\x94"),
|
||||
be_native_module_str("SYMBOL_PLUS", "\xef\x81\xa7"),
|
||||
be_native_module_str("SYMBOL_MINUS", "\xef\x81\xa8"),
|
||||
be_native_module_str("SYMBOL_EYE_OPEN", "\xef\x81\xae"),
|
||||
be_native_module_str("SYMBOL_EYE_CLOSE", "\xef\x81\xb0"),
|
||||
be_native_module_str("SYMBOL_WARNING", "\xef\x81\xb1"),
|
||||
be_native_module_str("SYMBOL_SHUFFLE", "\xef\x81\xb4"),
|
||||
be_native_module_str("SYMBOL_UP", "\xef\x81\xb7"),
|
||||
be_native_module_str("SYMBOL_DOWN", "\xef\x81\xb8"),
|
||||
be_native_module_str("SYMBOL_LOOP", "\xef\x81\xb9"),
|
||||
be_native_module_str("SYMBOL_DIRECTORY", "\xef\x81\xbb"),
|
||||
be_native_module_str("SYMBOL_UPLOAD", "\xef\x82\x93"),
|
||||
be_native_module_str("SYMBOL_CALL", "\xef\x82\x95"),
|
||||
be_native_module_str("SYMBOL_CUT", "\xef\x83\x84"),
|
||||
be_native_module_str("SYMBOL_COPY", "\xef\x83\x85"),
|
||||
be_native_module_str("SYMBOL_SAVE", "\xef\x83\x87"),
|
||||
be_native_module_str("SYMBOL_CHARGE", "\xef\x83\xa7"),
|
||||
be_native_module_str("SYMBOL_PASTE", "\xef\x83\xAA"),
|
||||
be_native_module_str("SYMBOL_BELL", "\xef\x83\xb3"),
|
||||
be_native_module_str("SYMBOL_KEYBOARD", "\xef\x84\x9c"),
|
||||
be_native_module_str("SYMBOL_GPS", "\xef\x84\xa4"),
|
||||
be_native_module_str("SYMBOL_FILE", "\xef\x85\x9b"),
|
||||
be_native_module_str("SYMBOL_WIFI", "\xef\x87\xab"),
|
||||
be_native_module_str("SYMBOL_BATTERY_FULL", "\xef\x89\x80"),
|
||||
be_native_module_str("SYMBOL_BATTERY_3", "\xef\x89\x81"),
|
||||
be_native_module_str("SYMBOL_BATTERY_2", "\xef\x89\x82"),
|
||||
be_native_module_str("SYMBOL_BATTERY_1", "\xef\x89\x83"),
|
||||
be_native_module_str("SYMBOL_BATTERY_EMPTY", "\xef\x89\x84"),
|
||||
be_native_module_str("SYMBOL_USB", "\xef\x8a\x87"),
|
||||
be_native_module_str("SYMBOL_BLUETOOTH", "\xef\x8a\x93"),
|
||||
be_native_module_str("SYMBOL_TRASH", "\xef\x8B\xAD"),
|
||||
be_native_module_str("SYMBOL_BACKSPACE", "\xef\x95\x9A"),
|
||||
be_native_module_str("SYMBOL_SD_CARD", "\xef\x9F\x82"),
|
||||
be_native_module_str("SYMBOL_NEW_LINE", "\xef\xA2\xA2"),
|
||||
|
||||
be_native_module_str("SYMBOL_DUMMY", "\xEF\xA3\xBF"),
|
||||
|
||||
be_native_module_str("SYMBOL_BULLET", "\xE2\x80\xA2"),
|
||||
|
||||
|
||||
/* `lvgl` module functions */
|
||||
|
||||
|
||||
|
||||
be_native_module_function("member", lv0_member),
|
||||
be_native_module_function("start", lv0_start),
|
||||
|
||||
be_native_module_function("register_button_encoder", lv0_register_button_encoder),
|
||||
|
||||
be_native_module_function("montserrat_font", lv0_load_montserrat_font),
|
||||
be_native_module_function("seg7_font", lv0_load_seg7_font),
|
||||
be_native_module_function("load_font", lv0_load_font),
|
||||
be_native_module_function("load_freetype_font", lv0_load_freetype_font),
|
||||
|
||||
be_native_module_function("screenshot", lv0_screenshot),
|
||||
};
|
||||
|
||||
be_define_native_module(lvgl, NULL);
|
||||
|
||||
#else
|
||||
|
||||
be_define_local_const_str(SYMBOL_AUDIO, "\xef\x80\x81", 0, 3);
|
||||
be_define_local_const_str(SYMBOL_VIDEO, "\xef\x80\x88", 0, 3);
|
||||
@ -814,7 +741,6 @@ module lvgl (scope: global) {
|
||||
}
|
||||
@const_object_info_end */
|
||||
#include "../generate/be_fixed_lvgl.h"
|
||||
#endif
|
||||
|
||||
#endif // USE_LVGL
|
||||
|
||||
|
@ -8,11 +8,110 @@
|
||||
#include "lvgl.h"
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: my_design_cb
|
||||
** Solidified function: set_percentage
|
||||
********************************************************************/
|
||||
be_local_closure(my_design_cb, /* name */
|
||||
be_local_closure(set_percentage, /* name */
|
||||
be_nested_proto(
|
||||
26, /* nstack */
|
||||
5, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 3]) { /* constants */
|
||||
/* K0 */ be_nested_string("percentage", -1756136011, 10),
|
||||
/* K1 */ be_const_int(0),
|
||||
/* K2 */ be_nested_string("invalidate", -1645232368, 10),
|
||||
}),
|
||||
(be_nested_const_str("set_percentage", -1342944572, 14)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[18]) { /* code */
|
||||
0x88080100, // 0000 GETMBR R2 R0 K0
|
||||
0x540E0018, // 0001 LDINT R3 25
|
||||
0x0C080403, // 0002 DIV R2 R2 R3
|
||||
0x540E0063, // 0003 LDINT R3 100
|
||||
0x240C0203, // 0004 GT R3 R1 R3
|
||||
0x780E0000, // 0005 JMPF R3 #0007
|
||||
0x54060063, // 0006 LDINT R1 100
|
||||
0x140C0301, // 0007 LT R3 R1 K1
|
||||
0x780E0000, // 0008 JMPF R3 #000A
|
||||
0x58040001, // 0009 LDCONST R1 K1
|
||||
0x90020001, // 000A SETMBR R0 K0 R1
|
||||
0x540E0018, // 000B LDINT R3 25
|
||||
0x0C0C0203, // 000C DIV R3 R1 R3
|
||||
0x200C0403, // 000D NE R3 R2 R3
|
||||
0x780E0001, // 000E JMPF R3 #0011
|
||||
0x8C0C0102, // 000F GETMET R3 R0 K2
|
||||
0x7C0C0200, // 0010 CALL R3 1
|
||||
0x80000000, // 0011 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: init
|
||||
********************************************************************/
|
||||
be_local_closure(init, /* name */
|
||||
be_nested_proto(
|
||||
6, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[10]) { /* constants */
|
||||
/* K0 */ be_nested_string("_lvgl", -1605747813, 5),
|
||||
/* K1 */ be_nested_string("create_custom_widget", 1140594778, 20),
|
||||
/* K2 */ be_nested_string("percentage", -1756136011, 10),
|
||||
/* K3 */ be_nested_string("p1", -1605446022, 2),
|
||||
/* K4 */ be_nested_string("lv_point", -174745506, 8),
|
||||
/* K5 */ be_nested_string("p2", -1622223641, 2),
|
||||
/* K6 */ be_nested_string("area", -1693507260, 4),
|
||||
/* K7 */ be_nested_string("lv_area", -1773816895, 7),
|
||||
/* K8 */ be_nested_string("line_dsc", -200476318, 8),
|
||||
/* K9 */ be_nested_string("lv_draw_line_dsc", -1872162060, 16),
|
||||
}),
|
||||
(be_nested_const_str("init", 380752755, 4)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[20]) { /* code */
|
||||
0xB80A0000, // 0000 GETNGBL R2 K0
|
||||
0x8C080501, // 0001 GETMET R2 R2 K1
|
||||
0x5C100000, // 0002 MOVE R4 R0
|
||||
0x5C140200, // 0003 MOVE R5 R1
|
||||
0x7C080600, // 0004 CALL R2 3
|
||||
0x540A0063, // 0005 LDINT R2 100
|
||||
0x90020402, // 0006 SETMBR R0 K2 R2
|
||||
0xB80A0800, // 0007 GETNGBL R2 K4
|
||||
0x7C080000, // 0008 CALL R2 0
|
||||
0x90020602, // 0009 SETMBR R0 K3 R2
|
||||
0xB80A0800, // 000A GETNGBL R2 K4
|
||||
0x7C080000, // 000B CALL R2 0
|
||||
0x90020A02, // 000C SETMBR R0 K5 R2
|
||||
0xB80A0E00, // 000D GETNGBL R2 K7
|
||||
0x7C080000, // 000E CALL R2 0
|
||||
0x90020C02, // 000F SETMBR R0 K6 R2
|
||||
0xB80A1200, // 0010 GETNGBL R2 K9
|
||||
0x7C080000, // 0011 CALL R2 0
|
||||
0x90021002, // 0012 SETMBR R0 K8 R2
|
||||
0x80000000, // 0013 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: widget_event
|
||||
********************************************************************/
|
||||
be_local_closure(widget_event, /* name */
|
||||
be_nested_proto(
|
||||
28, /* nstack */
|
||||
3, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
@ -44,225 +143,228 @@ be_local_closure(my_design_cb, /* name */
|
||||
),
|
||||
}),
|
||||
1, /* has constants */
|
||||
( &(const bvalue[35]) { /* constants */
|
||||
/* K0 */ be_nested_string("math", -293037681, 4),
|
||||
/* K1 */ be_nested_string("get_height", -723211773, 10),
|
||||
/* K2 */ be_nested_string("get_width", -1001549996, 9),
|
||||
/* K3 */ be_const_int(2),
|
||||
/* K4 */ be_const_int(3),
|
||||
/* K5 */ be_nested_string("lv", 1529997255, 2),
|
||||
/* K6 */ be_nested_string("DESIGN_COVER_CHK", -1298406708, 16),
|
||||
/* K7 */ be_nested_string("ancestor_design", 421545719, 15),
|
||||
/* K8 */ be_nested_string("call", -1276017495, 4),
|
||||
/* K9 */ be_nested_string("DESIGN_DRAW_MAIN", -904475754, 16),
|
||||
/* K10 */ be_nested_string("get_coords", 1044089006, 10),
|
||||
/* K11 */ be_nested_string("area", -1693507260, 4),
|
||||
/* K12 */ be_nested_string("x1", 274927234, 2),
|
||||
/* K13 */ be_nested_string("y1", -1939865569, 2),
|
||||
/* K14 */ be_nested_string("draw_line_dsc_init", -428273650, 18),
|
||||
/* K15 */ be_nested_string("line_dsc", -200476318, 8),
|
||||
/* K16 */ be_nested_string("init_draw_line_dsc", -1787031256, 18),
|
||||
/* K17 */ be_nested_string("OBJ_PART_MAIN", 658062838, 13),
|
||||
/* K18 */ be_nested_string("round_start", -1345482912, 11),
|
||||
/* K19 */ be_const_int(1),
|
||||
/* K20 */ be_nested_string("round_end", 985288225, 9),
|
||||
/* K21 */ be_nested_string("width", -1786286561, 5),
|
||||
/* K22 */ be_nested_string("get_style_line_color", 805371932, 20),
|
||||
/* K23 */ be_nested_string("STATE_DEFAULT", 712406428, 13),
|
||||
/* K24 */ be_nested_string("get_style_bg_color", 964794381, 18),
|
||||
/* K25 */ be_nested_string("deg", -967213025, 3),
|
||||
/* K26 */ be_nested_string("acos", 1006755615, 4),
|
||||
/* K27 */ be_nested_string("p1", -1605446022, 2),
|
||||
/* K28 */ be_nested_string("x", -49524601, 1),
|
||||
/* K29 */ be_nested_string("y", -66302220, 1),
|
||||
/* K30 */ be_nested_string("color", 1031692888, 5),
|
||||
/* K31 */ be_nested_string("percentage", -1756136011, 10),
|
||||
/* K32 */ be_nested_string("draw_arc", 1828251676, 8),
|
||||
/* K33 */ be_const_int(0),
|
||||
/* K34 */ be_nested_string("DESIGN_RES_OK", -1265307123, 13),
|
||||
( &(const bvalue[36]) { /* constants */
|
||||
/* K0 */ be_nested_string("lv", 1529997255, 2),
|
||||
/* K1 */ be_nested_string("obj_event_base", 1624064363, 14),
|
||||
/* K2 */ be_nested_string("RES_OK", 1233817284, 6),
|
||||
/* K3 */ be_nested_string("code", -114201356, 4),
|
||||
/* K4 */ be_nested_string("math", -293037681, 4),
|
||||
/* K5 */ be_nested_string("get_height", -723211773, 10),
|
||||
/* K6 */ be_nested_string("get_width", -1001549996, 9),
|
||||
/* K7 */ be_const_int(2),
|
||||
/* K8 */ be_const_int(3),
|
||||
/* K9 */ be_nested_string("EVENT_DRAW_MAIN", 1955620614, 15),
|
||||
/* K10 */ be_nested_string("lv_area", -1773816895, 7),
|
||||
/* K11 */ be_nested_string("param", 1309554226, 5),
|
||||
/* K12 */ be_nested_string("get_coords", 1044089006, 10),
|
||||
/* K13 */ be_nested_string("area", -1693507260, 4),
|
||||
/* K14 */ be_nested_string("x1", 274927234, 2),
|
||||
/* K15 */ be_nested_string("y1", -1939865569, 2),
|
||||
/* K16 */ be_nested_string("draw_line_dsc_init", -428273650, 18),
|
||||
/* K17 */ be_nested_string("line_dsc", -200476318, 8),
|
||||
/* K18 */ be_nested_string("init_draw_line_dsc", -1787031256, 18),
|
||||
/* K19 */ be_nested_string("PART_MAIN", -1821475788, 9),
|
||||
/* K20 */ be_nested_string("round_start", -1345482912, 11),
|
||||
/* K21 */ be_const_int(1),
|
||||
/* K22 */ be_nested_string("round_end", 985288225, 9),
|
||||
/* K23 */ be_nested_string("width", -1786286561, 5),
|
||||
/* K24 */ be_nested_string("get_style_line_color", 805371932, 20),
|
||||
/* K25 */ be_nested_string("STATE_DEFAULT", 712406428, 13),
|
||||
/* K26 */ be_nested_string("get_style_bg_color", 964794381, 18),
|
||||
/* K27 */ be_nested_string("deg", -967213025, 3),
|
||||
/* K28 */ be_nested_string("acos", 1006755615, 4),
|
||||
/* K29 */ be_nested_string("p1", -1605446022, 2),
|
||||
/* K30 */ be_nested_string("x", -49524601, 1),
|
||||
/* K31 */ be_nested_string("y", -66302220, 1),
|
||||
/* K32 */ be_nested_string("color", 1031692888, 5),
|
||||
/* K33 */ be_nested_string("percentage", -1756136011, 10),
|
||||
/* K34 */ be_nested_string("draw_arc", 1828251676, 8),
|
||||
/* K35 */ be_const_int(0),
|
||||
}),
|
||||
(be_nested_const_str("my_design_cb", -1173588798, 12)),
|
||||
(be_nested_const_str("widget_event", 1951408186, 12)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[179]) { /* code */
|
||||
0xA40E0000, // 0000 IMPORT R3 K0
|
||||
0x84100000, // 0001 CLOSURE R4 P0
|
||||
0x8C140101, // 0002 GETMET R5 R0 K1
|
||||
0x7C140200, // 0003 CALL R5 1
|
||||
0x8C180102, // 0004 GETMET R6 R0 K2
|
||||
0x7C180200, // 0005 CALL R6 1
|
||||
0x5C1C0800, // 0006 MOVE R7 R4
|
||||
0x54220007, // 0007 LDINT R8 8
|
||||
0x0C200A08, // 0008 DIV R8 R5 R8
|
||||
0x7C1C0200, // 0009 CALL R7 1
|
||||
0x5C200800, // 000A MOVE R8 R4
|
||||
0x08240F03, // 000B MUL R9 R7 K3
|
||||
0x04240A09, // 000C SUB R9 R5 R9
|
||||
0x0C241304, // 000D DIV R9 R9 K4
|
||||
0x7C200200, // 000E CALL R8 1
|
||||
0x0C241103, // 000F DIV R9 R8 K3
|
||||
0xB82A0A00, // 0010 GETNGBL R10 K5
|
||||
0x88281506, // 0011 GETMBR R10 R10 K6
|
||||
0x1C28040A, // 0012 EQ R10 R2 R10
|
||||
0x782A0007, // 0013 JMPF R10 #001C
|
||||
0x88280107, // 0014 GETMBR R10 R0 K7
|
||||
0x8C281508, // 0015 GETMET R10 R10 K8
|
||||
0x5C300000, // 0016 MOVE R12 R0
|
||||
0x5C340200, // 0017 MOVE R13 R1
|
||||
0x5C380400, // 0018 MOVE R14 R2
|
||||
0x7C280800, // 0019 CALL R10 4
|
||||
0x80041400, // 001A RET 1 R10
|
||||
0x70020093, // 001B JMP #00B0
|
||||
0xB82A0A00, // 001C GETNGBL R10 K5
|
||||
0x88281509, // 001D GETMBR R10 R10 K9
|
||||
0x1C28040A, // 001E EQ R10 R2 R10
|
||||
0x782A008F, // 001F JMPF R10 #00B0
|
||||
0x8C28010A, // 0020 GETMET R10 R0 K10
|
||||
0x8830010B, // 0021 GETMBR R12 R0 K11
|
||||
0x7C280400, // 0022 CALL R10 2
|
||||
0x8828010B, // 0023 GETMBR R10 R0 K11
|
||||
0x8828150C, // 0024 GETMBR R10 R10 K12
|
||||
0x882C010B, // 0025 GETMBR R11 R0 K11
|
||||
0x882C170D, // 0026 GETMBR R11 R11 K13
|
||||
0xB8320A00, // 0027 GETNGBL R12 K5
|
||||
0x8C30190E, // 0028 GETMET R12 R12 K14
|
||||
0x8838010F, // 0029 GETMBR R14 R0 K15
|
||||
0x7C300400, // 002A CALL R12 2
|
||||
0x8C300110, // 002B GETMET R12 R0 K16
|
||||
0xB83A0A00, // 002C GETNGBL R14 K5
|
||||
0x88381D11, // 002D GETMBR R14 R14 K17
|
||||
0x883C010F, // 002E GETMBR R15 R0 K15
|
||||
0x7C300600, // 002F CALL R12 3
|
||||
0x8830010F, // 0030 GETMBR R12 R0 K15
|
||||
0x90322513, // 0031 SETMBR R12 K18 K19
|
||||
0x8830010F, // 0032 GETMBR R12 R0 K15
|
||||
0x90322913, // 0033 SETMBR R12 K20 K19
|
||||
0x8830010F, // 0034 GETMBR R12 R0 K15
|
||||
0x08341104, // 0035 MUL R13 R8 K4
|
||||
0x00341B13, // 0036 ADD R13 R13 K19
|
||||
0x543A0003, // 0037 LDINT R14 4
|
||||
0x0C341A0E, // 0038 DIV R13 R13 R14
|
||||
0x90322A0D, // 0039 SETMBR R12 K21 R13
|
||||
0x8C300116, // 003A GETMET R12 R0 K22
|
||||
0xB83A0A00, // 003B GETNGBL R14 K5
|
||||
0x88381D11, // 003C GETMBR R14 R14 K17
|
||||
0xB83E0A00, // 003D GETNGBL R15 K5
|
||||
0x883C1F17, // 003E GETMBR R15 R15 K23
|
||||
0x7C300600, // 003F CALL R12 3
|
||||
0x8C340118, // 0040 GETMET R13 R0 K24
|
||||
0xB83E0A00, // 0041 GETNGBL R15 K5
|
||||
0x883C1F11, // 0042 GETMBR R15 R15 K17
|
||||
0xB8420A00, // 0043 GETNGBL R16 K5
|
||||
0x88402117, // 0044 GETMBR R16 R16 K23
|
||||
0x7C340600, // 0045 CALL R13 3
|
||||
0x04380A08, // 0046 SUB R14 R5 R8
|
||||
0x0C3C0D03, // 0047 DIV R15 R6 K3
|
||||
0x043C1E09, // 0048 SUB R15 R15 R9
|
||||
0x60400009, // 0049 GETGBL R16 G9
|
||||
0x54460059, // 004A LDINT R17 90
|
||||
0x8C480719, // 004B GETMET R18 R3 K25
|
||||
0x8C50071A, // 004C GETMET R20 R3 K26
|
||||
0x6058000A, // 004D GETGBL R22 G10
|
||||
0x5C5C1E00, // 004E MOVE R23 R15
|
||||
0x7C580200, // 004F CALL R22 1
|
||||
0x605C000A, // 0050 GETGBL R23 G10
|
||||
0x5C601C00, // 0051 MOVE R24 R14
|
||||
0x7C5C0200, // 0052 CALL R23 1
|
||||
0x0C582C17, // 0053 DIV R22 R22 R23
|
||||
0x7C500400, // 0054 CALL R20 2
|
||||
0x7C480400, // 0055 CALL R18 2
|
||||
0x04442212, // 0056 SUB R17 R17 R18
|
||||
0x7C400200, // 0057 CALL R16 1
|
||||
0x5446002C, // 0058 LDINT R17 45
|
||||
0x24442011, // 0059 GT R17 R16 R17
|
||||
0x78460000, // 005A JMPF R17 #005C
|
||||
0x5442002C, // 005B LDINT R16 45
|
||||
0x8844011B, // 005C GETMBR R17 R0 K27
|
||||
0x0C480D03, // 005D DIV R18 R6 K3
|
||||
0x00481412, // 005E ADD R18 R10 R18
|
||||
0x90463812, // 005F SETMBR R17 K28 R18
|
||||
0x8844011B, // 0060 GETMBR R17 R0 K27
|
||||
0x00481605, // 0061 ADD R18 R11 R5
|
||||
0x04482513, // 0062 SUB R18 R18 K19
|
||||
0x04482409, // 0063 SUB R18 R18 R9
|
||||
0x90463A12, // 0064 SETMBR R17 K29 R18
|
||||
0x8844010F, // 0065 GETMBR R17 R0 K15
|
||||
0x8848011F, // 0066 GETMBR R18 R0 K31
|
||||
0x544E0018, // 0067 LDINT R19 25
|
||||
0x28482413, // 0068 GE R18 R18 R19
|
||||
0x784A0001, // 0069 JMPF R18 #006C
|
||||
0x5C481800, // 006A MOVE R18 R12
|
||||
0x70020000, // 006B JMP #006D
|
||||
0x5C481A00, // 006C MOVE R18 R13
|
||||
0x90463C12, // 006D SETMBR R17 K30 R18
|
||||
0xB8460A00, // 006E GETNGBL R17 K5
|
||||
0x8C442320, // 006F GETMET R17 R17 K32
|
||||
0x884C011B, // 0070 GETMBR R19 R0 K27
|
||||
0x884C271C, // 0071 GETMBR R19 R19 K28
|
||||
0x8850011B, // 0072 GETMBR R20 R0 K27
|
||||
0x8850291D, // 0073 GETMBR R20 R20 K29
|
||||
0x00541007, // 0074 ADD R21 R8 R7
|
||||
0x08564215, // 0075 MUL R21 K33 R21
|
||||
0x00542A09, // 0076 ADD R21 R21 R9
|
||||
0x58580021, // 0077 LDCONST R22 K33
|
||||
0x545E0167, // 0078 LDINT R23 360
|
||||
0x5C600200, // 0079 MOVE R24 R1
|
||||
0x8864010F, // 007A GETMBR R25 R0 K15
|
||||
0x7C441000, // 007B CALL R17 8
|
||||
0x8844010F, // 007C GETMBR R17 R0 K15
|
||||
0x8848011F, // 007D GETMBR R18 R0 K31
|
||||
0x544E0031, // 007E LDINT R19 50
|
||||
0x28482413, // 007F GE R18 R18 R19
|
||||
0x784A0001, // 0080 JMPF R18 #0083
|
||||
0x5C481800, // 0081 MOVE R18 R12
|
||||
0x70020000, // 0082 JMP #0084
|
||||
0x5C481A00, // 0083 MOVE R18 R13
|
||||
0x90463C12, // 0084 SETMBR R17 K30 R18
|
||||
0xB8460A00, // 0085 GETNGBL R17 K5
|
||||
0x8C442320, // 0086 GETMET R17 R17 K32
|
||||
0x884C011B, // 0087 GETMBR R19 R0 K27
|
||||
0x884C271C, // 0088 GETMBR R19 R19 K28
|
||||
0x8850011B, // 0089 GETMBR R20 R0 K27
|
||||
0x8850291D, // 008A GETMBR R20 R20 K29
|
||||
0x00541007, // 008B ADD R21 R8 R7
|
||||
0x08562615, // 008C MUL R21 K19 R21
|
||||
0x00542A09, // 008D ADD R21 R21 R9
|
||||
0x04542B13, // 008E SUB R21 R21 K19
|
||||
0x545A010D, // 008F LDINT R22 270
|
||||
0x04582C10, // 0090 SUB R22 R22 R16
|
||||
0x545E010D, // 0091 LDINT R23 270
|
||||
0x005C2E10, // 0092 ADD R23 R23 R16
|
||||
0x5C600200, // 0093 MOVE R24 R1
|
||||
0x8864010F, // 0094 GETMBR R25 R0 K15
|
||||
0x7C441000, // 0095 CALL R17 8
|
||||
0x8844010F, // 0096 GETMBR R17 R0 K15
|
||||
0x8848011F, // 0097 GETMBR R18 R0 K31
|
||||
0x544E004A, // 0098 LDINT R19 75
|
||||
0x28482413, // 0099 GE R18 R18 R19
|
||||
0x784A0001, // 009A JMPF R18 #009D
|
||||
0x5C481800, // 009B MOVE R18 R12
|
||||
0x70020000, // 009C JMP #009E
|
||||
0x5C481A00, // 009D MOVE R18 R13
|
||||
0x90463C12, // 009E SETMBR R17 K30 R18
|
||||
0xB8460A00, // 009F GETNGBL R17 K5
|
||||
0x8C442320, // 00A0 GETMET R17 R17 K32
|
||||
0x884C011B, // 00A1 GETMBR R19 R0 K27
|
||||
0x884C271C, // 00A2 GETMBR R19 R19 K28
|
||||
0x8850011B, // 00A3 GETMBR R20 R0 K27
|
||||
0x8850291D, // 00A4 GETMBR R20 R20 K29
|
||||
0x00541007, // 00A5 ADD R21 R8 R7
|
||||
0x08560615, // 00A6 MUL R21 K3 R21
|
||||
0x00542A09, // 00A7 ADD R21 R21 R9
|
||||
0x04542B03, // 00A8 SUB R21 R21 K3
|
||||
0x545A010D, // 00A9 LDINT R22 270
|
||||
0x04582C10, // 00AA SUB R22 R22 R16
|
||||
0x545E010D, // 00AB LDINT R23 270
|
||||
0x005C2E10, // 00AC ADD R23 R23 R16
|
||||
0x5C600200, // 00AD MOVE R24 R1
|
||||
0x8864010F, // 00AE GETMBR R25 R0 K15
|
||||
0x7C441000, // 00AF CALL R17 8
|
||||
0xB82A0A00, // 00B0 GETNGBL R10 K5
|
||||
0x88281522, // 00B1 GETMBR R10 R10 K34
|
||||
0x80041400, // 00B2 RET 1 R10
|
||||
( &(const binstruction[181]) { /* code */
|
||||
0xB80E0000, // 0000 GETNGBL R3 K0
|
||||
0x8C0C0701, // 0001 GETMET R3 R3 K1
|
||||
0x5C140200, // 0002 MOVE R5 R1
|
||||
0x5C180400, // 0003 MOVE R6 R2
|
||||
0x7C0C0600, // 0004 CALL R3 3
|
||||
0xB8120000, // 0005 GETNGBL R4 K0
|
||||
0x88100902, // 0006 GETMBR R4 R4 K2
|
||||
0x200C0604, // 0007 NE R3 R3 R4
|
||||
0x780E0000, // 0008 JMPF R3 #000A
|
||||
0x80000600, // 0009 RET 0
|
||||
0x880C0503, // 000A GETMBR R3 R2 K3
|
||||
0xA4120800, // 000B IMPORT R4 K4
|
||||
0x84140000, // 000C CLOSURE R5 P0
|
||||
0x8C180105, // 000D GETMET R6 R0 K5
|
||||
0x7C180200, // 000E CALL R6 1
|
||||
0x8C1C0106, // 000F GETMET R7 R0 K6
|
||||
0x7C1C0200, // 0010 CALL R7 1
|
||||
0x5C200A00, // 0011 MOVE R8 R5
|
||||
0x54260007, // 0012 LDINT R9 8
|
||||
0x0C240C09, // 0013 DIV R9 R6 R9
|
||||
0x7C200200, // 0014 CALL R8 1
|
||||
0x5C240A00, // 0015 MOVE R9 R5
|
||||
0x08281107, // 0016 MUL R10 R8 K7
|
||||
0x04280C0A, // 0017 SUB R10 R6 R10
|
||||
0x0C281508, // 0018 DIV R10 R10 K8
|
||||
0x7C240200, // 0019 CALL R9 1
|
||||
0x0C281307, // 001A DIV R10 R9 K7
|
||||
0xB82E0000, // 001B GETNGBL R11 K0
|
||||
0x882C1709, // 001C GETMBR R11 R11 K9
|
||||
0x1C2C060B, // 001D EQ R11 R3 R11
|
||||
0x782E0094, // 001E JMPF R11 #00B4
|
||||
0xB82E1400, // 001F GETNGBL R11 K10
|
||||
0x8830050B, // 0020 GETMBR R12 R2 K11
|
||||
0x7C2C0200, // 0021 CALL R11 1
|
||||
0x8C30010C, // 0022 GETMET R12 R0 K12
|
||||
0x8838010D, // 0023 GETMBR R14 R0 K13
|
||||
0x7C300400, // 0024 CALL R12 2
|
||||
0x8830010D, // 0025 GETMBR R12 R0 K13
|
||||
0x8830190E, // 0026 GETMBR R12 R12 K14
|
||||
0x8834010D, // 0027 GETMBR R13 R0 K13
|
||||
0x88341B0F, // 0028 GETMBR R13 R13 K15
|
||||
0xB83A0000, // 0029 GETNGBL R14 K0
|
||||
0x8C381D10, // 002A GETMET R14 R14 K16
|
||||
0x88400111, // 002B GETMBR R16 R0 K17
|
||||
0x7C380400, // 002C CALL R14 2
|
||||
0x8C380112, // 002D GETMET R14 R0 K18
|
||||
0xB8420000, // 002E GETNGBL R16 K0
|
||||
0x88402113, // 002F GETMBR R16 R16 K19
|
||||
0x88440111, // 0030 GETMBR R17 R0 K17
|
||||
0x7C380600, // 0031 CALL R14 3
|
||||
0x88380111, // 0032 GETMBR R14 R0 K17
|
||||
0x903A2915, // 0033 SETMBR R14 K20 K21
|
||||
0x88380111, // 0034 GETMBR R14 R0 K17
|
||||
0x903A2D15, // 0035 SETMBR R14 K22 K21
|
||||
0x88380111, // 0036 GETMBR R14 R0 K17
|
||||
0x083C1308, // 0037 MUL R15 R9 K8
|
||||
0x003C1F15, // 0038 ADD R15 R15 K21
|
||||
0x54420003, // 0039 LDINT R16 4
|
||||
0x0C3C1E10, // 003A DIV R15 R15 R16
|
||||
0x903A2E0F, // 003B SETMBR R14 K23 R15
|
||||
0x8C380118, // 003C GETMET R14 R0 K24
|
||||
0xB8420000, // 003D GETNGBL R16 K0
|
||||
0x88402113, // 003E GETMBR R16 R16 K19
|
||||
0xB8460000, // 003F GETNGBL R17 K0
|
||||
0x88442319, // 0040 GETMBR R17 R17 K25
|
||||
0x30402011, // 0041 OR R16 R16 R17
|
||||
0x7C380400, // 0042 CALL R14 2
|
||||
0x8C3C011A, // 0043 GETMET R15 R0 K26
|
||||
0xB8460000, // 0044 GETNGBL R17 K0
|
||||
0x88442313, // 0045 GETMBR R17 R17 K19
|
||||
0xB84A0000, // 0046 GETNGBL R18 K0
|
||||
0x88482519, // 0047 GETMBR R18 R18 K25
|
||||
0x30442212, // 0048 OR R17 R17 R18
|
||||
0x7C3C0400, // 0049 CALL R15 2
|
||||
0x04400C09, // 004A SUB R16 R6 R9
|
||||
0x0C440F07, // 004B DIV R17 R7 K7
|
||||
0x0444220A, // 004C SUB R17 R17 R10
|
||||
0x60480009, // 004D GETGBL R18 G9
|
||||
0x544E0059, // 004E LDINT R19 90
|
||||
0x8C50091B, // 004F GETMET R20 R4 K27
|
||||
0x8C58091C, // 0050 GETMET R22 R4 K28
|
||||
0x6060000A, // 0051 GETGBL R24 G10
|
||||
0x5C642200, // 0052 MOVE R25 R17
|
||||
0x7C600200, // 0053 CALL R24 1
|
||||
0x6064000A, // 0054 GETGBL R25 G10
|
||||
0x5C682000, // 0055 MOVE R26 R16
|
||||
0x7C640200, // 0056 CALL R25 1
|
||||
0x0C603019, // 0057 DIV R24 R24 R25
|
||||
0x7C580400, // 0058 CALL R22 2
|
||||
0x7C500400, // 0059 CALL R20 2
|
||||
0x044C2614, // 005A SUB R19 R19 R20
|
||||
0x7C480200, // 005B CALL R18 1
|
||||
0x544E002C, // 005C LDINT R19 45
|
||||
0x244C2413, // 005D GT R19 R18 R19
|
||||
0x784E0000, // 005E JMPF R19 #0060
|
||||
0x544A002C, // 005F LDINT R18 45
|
||||
0x884C011D, // 0060 GETMBR R19 R0 K29
|
||||
0x0C500F07, // 0061 DIV R20 R7 K7
|
||||
0x00501814, // 0062 ADD R20 R12 R20
|
||||
0x904E3C14, // 0063 SETMBR R19 K30 R20
|
||||
0x884C011D, // 0064 GETMBR R19 R0 K29
|
||||
0x00501A06, // 0065 ADD R20 R13 R6
|
||||
0x04502915, // 0066 SUB R20 R20 K21
|
||||
0x0450280A, // 0067 SUB R20 R20 R10
|
||||
0x904E3E14, // 0068 SETMBR R19 K31 R20
|
||||
0x884C0111, // 0069 GETMBR R19 R0 K17
|
||||
0x88500121, // 006A GETMBR R20 R0 K33
|
||||
0x54560018, // 006B LDINT R21 25
|
||||
0x28502815, // 006C GE R20 R20 R21
|
||||
0x78520001, // 006D JMPF R20 #0070
|
||||
0x5C501C00, // 006E MOVE R20 R14
|
||||
0x70020000, // 006F JMP #0071
|
||||
0x5C501E00, // 0070 MOVE R20 R15
|
||||
0x904E4014, // 0071 SETMBR R19 K32 R20
|
||||
0xB84E0000, // 0072 GETNGBL R19 K0
|
||||
0x8C4C2722, // 0073 GETMET R19 R19 K34
|
||||
0x8854011D, // 0074 GETMBR R21 R0 K29
|
||||
0x88542B1E, // 0075 GETMBR R21 R21 K30
|
||||
0x8858011D, // 0076 GETMBR R22 R0 K29
|
||||
0x88582D1F, // 0077 GETMBR R22 R22 K31
|
||||
0x005C1208, // 0078 ADD R23 R9 R8
|
||||
0x085E4617, // 0079 MUL R23 K35 R23
|
||||
0x005C2E0A, // 007A ADD R23 R23 R10
|
||||
0x58600023, // 007B LDCONST R24 K35
|
||||
0x54660167, // 007C LDINT R25 360
|
||||
0x5C681600, // 007D MOVE R26 R11
|
||||
0x886C0111, // 007E GETMBR R27 R0 K17
|
||||
0x7C4C1000, // 007F CALL R19 8
|
||||
0x884C0111, // 0080 GETMBR R19 R0 K17
|
||||
0x88500121, // 0081 GETMBR R20 R0 K33
|
||||
0x54560031, // 0082 LDINT R21 50
|
||||
0x28502815, // 0083 GE R20 R20 R21
|
||||
0x78520001, // 0084 JMPF R20 #0087
|
||||
0x5C501C00, // 0085 MOVE R20 R14
|
||||
0x70020000, // 0086 JMP #0088
|
||||
0x5C501E00, // 0087 MOVE R20 R15
|
||||
0x904E4014, // 0088 SETMBR R19 K32 R20
|
||||
0xB84E0000, // 0089 GETNGBL R19 K0
|
||||
0x8C4C2722, // 008A GETMET R19 R19 K34
|
||||
0x8854011D, // 008B GETMBR R21 R0 K29
|
||||
0x88542B1E, // 008C GETMBR R21 R21 K30
|
||||
0x8858011D, // 008D GETMBR R22 R0 K29
|
||||
0x88582D1F, // 008E GETMBR R22 R22 K31
|
||||
0x005C1208, // 008F ADD R23 R9 R8
|
||||
0x085E2A17, // 0090 MUL R23 K21 R23
|
||||
0x005C2E0A, // 0091 ADD R23 R23 R10
|
||||
0x045C2F15, // 0092 SUB R23 R23 K21
|
||||
0x5462010D, // 0093 LDINT R24 270
|
||||
0x04603012, // 0094 SUB R24 R24 R18
|
||||
0x5466010D, // 0095 LDINT R25 270
|
||||
0x00643212, // 0096 ADD R25 R25 R18
|
||||
0x5C681600, // 0097 MOVE R26 R11
|
||||
0x886C0111, // 0098 GETMBR R27 R0 K17
|
||||
0x7C4C1000, // 0099 CALL R19 8
|
||||
0x884C0111, // 009A GETMBR R19 R0 K17
|
||||
0x88500121, // 009B GETMBR R20 R0 K33
|
||||
0x5456004A, // 009C LDINT R21 75
|
||||
0x28502815, // 009D GE R20 R20 R21
|
||||
0x78520001, // 009E JMPF R20 #00A1
|
||||
0x5C501C00, // 009F MOVE R20 R14
|
||||
0x70020000, // 00A0 JMP #00A2
|
||||
0x5C501E00, // 00A1 MOVE R20 R15
|
||||
0x904E4014, // 00A2 SETMBR R19 K32 R20
|
||||
0xB84E0000, // 00A3 GETNGBL R19 K0
|
||||
0x8C4C2722, // 00A4 GETMET R19 R19 K34
|
||||
0x8854011D, // 00A5 GETMBR R21 R0 K29
|
||||
0x88542B1E, // 00A6 GETMBR R21 R21 K30
|
||||
0x8858011D, // 00A7 GETMBR R22 R0 K29
|
||||
0x88582D1F, // 00A8 GETMBR R22 R22 K31
|
||||
0x005C1208, // 00A9 ADD R23 R9 R8
|
||||
0x085E0E17, // 00AA MUL R23 K7 R23
|
||||
0x005C2E0A, // 00AB ADD R23 R23 R10
|
||||
0x045C2F07, // 00AC SUB R23 R23 K7
|
||||
0x5462010D, // 00AD LDINT R24 270
|
||||
0x04603012, // 00AE SUB R24 R24 R18
|
||||
0x5466010D, // 00AF LDINT R25 270
|
||||
0x00643212, // 00B0 ADD R25 R25 R18
|
||||
0x5C681600, // 00B1 MOVE R26 R11
|
||||
0x886C0111, // 00B2 GETMBR R27 R0 K17
|
||||
0x7C4C1000, // 00B3 CALL R19 8
|
||||
0x80000000, // 00B4 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
@ -296,135 +398,24 @@ be_local_closure(get_percentage, /* name */
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: init
|
||||
********************************************************************/
|
||||
be_local_closure(init, /* name */
|
||||
be_nested_proto(
|
||||
7, /* nstack */
|
||||
3, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[13]) { /* constants */
|
||||
/* K0 */ be_nested_string("init", 380752755, 4),
|
||||
/* K1 */ be_nested_string("ancestor_design", 421545719, 15),
|
||||
/* K2 */ be_nested_string("get_design_cb", -825649242, 13),
|
||||
/* K3 */ be_nested_string("set_design_cb", 1469311634, 13),
|
||||
/* K4 */ be_nested_string("my_design_cb", -1173588798, 12),
|
||||
/* K5 */ be_nested_string("percentage", -1756136011, 10),
|
||||
/* K6 */ be_nested_string("p1", -1605446022, 2),
|
||||
/* K7 */ be_nested_string("lv_point", -174745506, 8),
|
||||
/* K8 */ be_nested_string("p2", -1622223641, 2),
|
||||
/* K9 */ be_nested_string("area", -1693507260, 4),
|
||||
/* K10 */ be_nested_string("lv_area", -1773816895, 7),
|
||||
/* K11 */ be_nested_string("line_dsc", -200476318, 8),
|
||||
/* K12 */ be_nested_string("lv_draw_line_dsc", -1872162060, 16),
|
||||
}),
|
||||
(be_nested_const_str("init", 380752755, 4)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[28]) { /* code */
|
||||
0x600C0003, // 0000 GETGBL R3 G3
|
||||
0x5C100000, // 0001 MOVE R4 R0
|
||||
0x7C0C0200, // 0002 CALL R3 1
|
||||
0x8C0C0700, // 0003 GETMET R3 R3 K0
|
||||
0x5C140200, // 0004 MOVE R5 R1
|
||||
0x5C180400, // 0005 MOVE R6 R2
|
||||
0x7C0C0600, // 0006 CALL R3 3
|
||||
0x8C0C0102, // 0007 GETMET R3 R0 K2
|
||||
0x7C0C0200, // 0008 CALL R3 1
|
||||
0x90020203, // 0009 SETMBR R0 K1 R3
|
||||
0x8C0C0103, // 000A GETMET R3 R0 K3
|
||||
0x88140104, // 000B GETMBR R5 R0 K4
|
||||
0x7C0C0400, // 000C CALL R3 2
|
||||
0x540E0063, // 000D LDINT R3 100
|
||||
0x90020A03, // 000E SETMBR R0 K5 R3
|
||||
0xB80E0E00, // 000F GETNGBL R3 K7
|
||||
0x7C0C0000, // 0010 CALL R3 0
|
||||
0x90020C03, // 0011 SETMBR R0 K6 R3
|
||||
0xB80E0E00, // 0012 GETNGBL R3 K7
|
||||
0x7C0C0000, // 0013 CALL R3 0
|
||||
0x90021003, // 0014 SETMBR R0 K8 R3
|
||||
0xB80E1400, // 0015 GETNGBL R3 K10
|
||||
0x7C0C0000, // 0016 CALL R3 0
|
||||
0x90021203, // 0017 SETMBR R0 K9 R3
|
||||
0xB80E1800, // 0018 GETNGBL R3 K12
|
||||
0x7C0C0000, // 0019 CALL R3 0
|
||||
0x90021603, // 001A SETMBR R0 K11 R3
|
||||
0x80000000, // 001B RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: set_percentage
|
||||
********************************************************************/
|
||||
be_local_closure(set_percentage, /* name */
|
||||
be_nested_proto(
|
||||
5, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 3]) { /* constants */
|
||||
/* K0 */ be_nested_string("percentage", -1756136011, 10),
|
||||
/* K1 */ be_const_int(0),
|
||||
/* K2 */ be_nested_string("invalidate", -1645232368, 10),
|
||||
}),
|
||||
(be_nested_const_str("set_percentage", -1342944572, 14)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[18]) { /* code */
|
||||
0x88080100, // 0000 GETMBR R2 R0 K0
|
||||
0x540E0003, // 0001 LDINT R3 4
|
||||
0x0C080403, // 0002 DIV R2 R2 R3
|
||||
0x540E0063, // 0003 LDINT R3 100
|
||||
0x240C0203, // 0004 GT R3 R1 R3
|
||||
0x780E0000, // 0005 JMPF R3 #0007
|
||||
0x54060063, // 0006 LDINT R1 100
|
||||
0x140C0301, // 0007 LT R3 R1 K1
|
||||
0x780E0000, // 0008 JMPF R3 #000A
|
||||
0x58040001, // 0009 LDCONST R1 K1
|
||||
0x90020001, // 000A SETMBR R0 K0 R1
|
||||
0x540E0003, // 000B LDINT R3 4
|
||||
0x0C0C0203, // 000C DIV R3 R1 R3
|
||||
0x200C0403, // 000D NE R3 R2 R3
|
||||
0x780E0001, // 000E JMPF R3 #0011
|
||||
0x8C0C0102, // 000F GETMET R3 R0 K2
|
||||
0x7C0C0200, // 0010 CALL R3 1
|
||||
0x80000000, // 0011 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified class: lv_signal_arcs
|
||||
********************************************************************/
|
||||
extern const bclass be_class_lv_obj;
|
||||
be_local_class(lv_signal_arcs,
|
||||
6,
|
||||
5,
|
||||
&be_class_lv_obj,
|
||||
be_nested_map(10,
|
||||
be_nested_map(9,
|
||||
( (struct bmapnode*) &(const bmapnode[]) {
|
||||
{ be_nested_key("p1", -1605446022, 2, -1), be_const_var(2) },
|
||||
{ be_nested_key("my_design_cb", -1173588798, 12, -1), be_const_closure(my_design_cb_closure) },
|
||||
{ be_nested_key("get_percentage", -1414483304, 14, -1), be_const_closure(get_percentage_closure) },
|
||||
{ be_nested_key("init", 380752755, 4, 7), be_const_closure(init_closure) },
|
||||
{ be_nested_key("set_percentage", -1342944572, 14, 0), be_const_closure(set_percentage_closure) },
|
||||
{ be_nested_key("percentage", -1756136011, 10, 3), be_const_var(1) },
|
||||
{ be_nested_key("area", -1693507260, 4, -1), be_const_var(4) },
|
||||
{ be_nested_key("p2", -1622223641, 2, -1), be_const_var(3) },
|
||||
{ be_nested_key("line_dsc", -200476318, 8, 1), be_const_var(5) },
|
||||
{ be_nested_key("ancestor_design", 421545719, 15, -1), be_const_var(0) },
|
||||
{ be_nested_key("percentage", -1756136011, 10, 4), be_const_var(0) },
|
||||
{ be_nested_key("p1", -1605446022, 2, 3), be_const_var(1) },
|
||||
{ be_nested_key("p2", -1622223641, 2, -1), be_const_var(2) },
|
||||
{ be_nested_key("area", -1693507260, 4, -1), be_const_var(3) },
|
||||
{ be_nested_key("line_dsc", -200476318, 8, -1), be_const_var(4) },
|
||||
{ be_nested_key("set_percentage", -1342944572, 14, -1), be_const_closure(set_percentage_closure) },
|
||||
{ be_nested_key("init", 380752755, 4, -1), be_const_closure(init_closure) },
|
||||
{ be_nested_key("widget_event", 1951408186, 12, -1), be_const_closure(widget_event_closure) },
|
||||
{ be_nested_key("get_percentage", -1414483304, 14, 5), be_const_closure(get_percentage_closure) },
|
||||
})),
|
||||
(be_nested_const_str("lv_signal_arcs", -1455810308, 14))
|
||||
);
|
||||
|
@ -8,11 +8,110 @@
|
||||
#include "lvgl.h"
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: my_design_cb
|
||||
** Solidified function: set_percentage
|
||||
********************************************************************/
|
||||
be_local_closure(my_design_cb, /* name */
|
||||
be_local_closure(set_percentage, /* name */
|
||||
be_nested_proto(
|
||||
21, /* nstack */
|
||||
5, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 3]) { /* constants */
|
||||
/* K0 */ be_nested_string("percentage", -1756136011, 10),
|
||||
/* K1 */ be_const_int(0),
|
||||
/* K2 */ be_nested_string("invalidate", -1645232368, 10),
|
||||
}),
|
||||
(be_nested_const_str("set_percentage", -1342944572, 14)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[18]) { /* code */
|
||||
0x88080100, // 0000 GETMBR R2 R0 K0
|
||||
0x540E0013, // 0001 LDINT R3 20
|
||||
0x0C080403, // 0002 DIV R2 R2 R3
|
||||
0x540E0063, // 0003 LDINT R3 100
|
||||
0x240C0203, // 0004 GT R3 R1 R3
|
||||
0x780E0000, // 0005 JMPF R3 #0007
|
||||
0x54060063, // 0006 LDINT R1 100
|
||||
0x140C0301, // 0007 LT R3 R1 K1
|
||||
0x780E0000, // 0008 JMPF R3 #000A
|
||||
0x58040001, // 0009 LDCONST R1 K1
|
||||
0x90020001, // 000A SETMBR R0 K0 R1
|
||||
0x540E0013, // 000B LDINT R3 20
|
||||
0x0C0C0203, // 000C DIV R3 R1 R3
|
||||
0x200C0403, // 000D NE R3 R2 R3
|
||||
0x780E0001, // 000E JMPF R3 #0011
|
||||
0x8C0C0102, // 000F GETMET R3 R0 K2
|
||||
0x7C0C0200, // 0010 CALL R3 1
|
||||
0x80000000, // 0011 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: init
|
||||
********************************************************************/
|
||||
be_local_closure(init, /* name */
|
||||
be_nested_proto(
|
||||
6, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[10]) { /* constants */
|
||||
/* K0 */ be_nested_string("_lvgl", -1605747813, 5),
|
||||
/* K1 */ be_nested_string("create_custom_widget", 1140594778, 20),
|
||||
/* K2 */ be_nested_string("percentage", -1756136011, 10),
|
||||
/* K3 */ be_nested_string("p1", -1605446022, 2),
|
||||
/* K4 */ be_nested_string("lv_point", -174745506, 8),
|
||||
/* K5 */ be_nested_string("p2", -1622223641, 2),
|
||||
/* K6 */ be_nested_string("area", -1693507260, 4),
|
||||
/* K7 */ be_nested_string("lv_area", -1773816895, 7),
|
||||
/* K8 */ be_nested_string("line_dsc", -200476318, 8),
|
||||
/* K9 */ be_nested_string("lv_draw_line_dsc", -1872162060, 16),
|
||||
}),
|
||||
(be_nested_const_str("init", 380752755, 4)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[20]) { /* code */
|
||||
0xB80A0000, // 0000 GETNGBL R2 K0
|
||||
0x8C080501, // 0001 GETMET R2 R2 K1
|
||||
0x5C100000, // 0002 MOVE R4 R0
|
||||
0x5C140200, // 0003 MOVE R5 R1
|
||||
0x7C080600, // 0004 CALL R2 3
|
||||
0x540A0063, // 0005 LDINT R2 100
|
||||
0x90020402, // 0006 SETMBR R0 K2 R2
|
||||
0xB80A0800, // 0007 GETNGBL R2 K4
|
||||
0x7C080000, // 0008 CALL R2 0
|
||||
0x90020602, // 0009 SETMBR R0 K3 R2
|
||||
0xB80A0800, // 000A GETNGBL R2 K4
|
||||
0x7C080000, // 000B CALL R2 0
|
||||
0x90020A02, // 000C SETMBR R0 K5 R2
|
||||
0xB80A0E00, // 000D GETNGBL R2 K7
|
||||
0x7C080000, // 000E CALL R2 0
|
||||
0x90020C02, // 000F SETMBR R0 K6 R2
|
||||
0xB80A1200, // 0010 GETNGBL R2 K9
|
||||
0x7C080000, // 0011 CALL R2 0
|
||||
0x90021002, // 0012 SETMBR R0 K8 R2
|
||||
0x80000000, // 0013 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: widget_event
|
||||
********************************************************************/
|
||||
be_local_closure(widget_event, /* name */
|
||||
be_nested_proto(
|
||||
23, /* nstack */
|
||||
3, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
@ -44,166 +143,186 @@ be_local_closure(my_design_cb, /* name */
|
||||
),
|
||||
}),
|
||||
1, /* has constants */
|
||||
( &(const bvalue[34]) { /* constants */
|
||||
/* K0 */ be_nested_string("get_height", -723211773, 10),
|
||||
/* K1 */ be_nested_string("get_width", -1001549996, 9),
|
||||
/* K2 */ be_const_int(3),
|
||||
/* K3 */ be_const_int(2),
|
||||
/* K4 */ be_nested_string("lv", 1529997255, 2),
|
||||
/* K5 */ be_nested_string("DESIGN_COVER_CHK", -1298406708, 16),
|
||||
/* K6 */ be_nested_string("ancestor_design", 421545719, 15),
|
||||
/* K7 */ be_nested_string("call", -1276017495, 4),
|
||||
/* K8 */ be_nested_string("DESIGN_DRAW_MAIN", -904475754, 16),
|
||||
/* K9 */ be_nested_string("get_coords", 1044089006, 10),
|
||||
/* K10 */ be_nested_string("area", -1693507260, 4),
|
||||
/* K11 */ be_nested_string("x1", 274927234, 2),
|
||||
/* K12 */ be_nested_string("y1", -1939865569, 2),
|
||||
/* K13 */ be_nested_string("draw_line_dsc_init", -428273650, 18),
|
||||
/* K14 */ be_nested_string("line_dsc", -200476318, 8),
|
||||
/* K15 */ be_nested_string("init_draw_line_dsc", -1787031256, 18),
|
||||
/* K16 */ be_nested_string("OBJ_PART_MAIN", 658062838, 13),
|
||||
/* K17 */ be_nested_string("round_start", -1345482912, 11),
|
||||
/* K18 */ be_const_int(1),
|
||||
/* K19 */ be_nested_string("round_end", 985288225, 9),
|
||||
/* K20 */ be_nested_string("width", -1786286561, 5),
|
||||
/* K21 */ be_nested_string("get_style_line_color", 805371932, 20),
|
||||
/* K22 */ be_nested_string("STATE_DEFAULT", 712406428, 13),
|
||||
/* K23 */ be_nested_string("get_style_bg_color", 964794381, 18),
|
||||
/* K24 */ be_const_int(0),
|
||||
/* K25 */ be_nested_string("color", 1031692888, 5),
|
||||
/* K26 */ be_nested_string("percentage", -1756136011, 10),
|
||||
/* K27 */ be_nested_string("p1", -1605446022, 2),
|
||||
/* K28 */ be_nested_string("y", -66302220, 1),
|
||||
/* K29 */ be_nested_string("x", -49524601, 1),
|
||||
/* K30 */ be_nested_string("p2", -1622223641, 2),
|
||||
/* K31 */ be_nested_string("draw_line", 1634465686, 9),
|
||||
/* K32 */ be_nested_string("stop_iteration", -121173395, 14),
|
||||
/* K33 */ be_nested_string("DESIGN_RES_OK", -1265307123, 13),
|
||||
( &(const bvalue[38]) { /* constants */
|
||||
/* K0 */ be_nested_string("lv", 1529997255, 2),
|
||||
/* K1 */ be_nested_string("obj_event_base", 1624064363, 14),
|
||||
/* K2 */ be_nested_string("RES_OK", 1233817284, 6),
|
||||
/* K3 */ be_nested_string("code", -114201356, 4),
|
||||
/* K4 */ be_nested_string("get_height", -723211773, 10),
|
||||
/* K5 */ be_nested_string("get_width", -1001549996, 9),
|
||||
/* K6 */ be_const_int(3),
|
||||
/* K7 */ be_const_int(2),
|
||||
/* K8 */ be_nested_string("EVENT_DRAW_MAIN", 1955620614, 15),
|
||||
/* K9 */ be_nested_string("lv_area", -1773816895, 7),
|
||||
/* K10 */ be_nested_string("param", 1309554226, 5),
|
||||
/* K11 */ be_nested_string("get_coords", 1044089006, 10),
|
||||
/* K12 */ be_nested_string("area", -1693507260, 4),
|
||||
/* K13 */ be_nested_string("x1", 274927234, 2),
|
||||
/* K14 */ be_nested_string("y1", -1939865569, 2),
|
||||
/* K15 */ be_nested_string("draw_line_dsc_init", -428273650, 18),
|
||||
/* K16 */ be_nested_string("line_dsc", -200476318, 8),
|
||||
/* K17 */ be_nested_string("init_draw_line_dsc", -1787031256, 18),
|
||||
/* K18 */ be_nested_string("PART_MAIN", -1821475788, 9),
|
||||
/* K19 */ be_nested_string("round_start", -1345482912, 11),
|
||||
/* K20 */ be_const_int(1),
|
||||
/* K21 */ be_nested_string("round_end", 985288225, 9),
|
||||
/* K22 */ be_nested_string("width", -1786286561, 5),
|
||||
/* K23 */ be_nested_string("get_style_line_color", 805371932, 20),
|
||||
/* K24 */ be_nested_string("STATE_DEFAULT", 712406428, 13),
|
||||
/* K25 */ be_nested_string("get_style_bg_color", 964794381, 18),
|
||||
/* K26 */ be_nested_string("event_send", 598925582, 10),
|
||||
/* K27 */ be_nested_string("EVENT_DRAW_PART_BEGIN", -903102272, 21),
|
||||
/* K28 */ be_const_int(0),
|
||||
/* K29 */ be_nested_string("color", 1031692888, 5),
|
||||
/* K30 */ be_nested_string("percentage", -1756136011, 10),
|
||||
/* K31 */ be_nested_string("p1", -1605446022, 2),
|
||||
/* K32 */ be_nested_string("y", -66302220, 1),
|
||||
/* K33 */ be_nested_string("x", -49524601, 1),
|
||||
/* K34 */ be_nested_string("p2", -1622223641, 2),
|
||||
/* K35 */ be_nested_string("draw_line", 1634465686, 9),
|
||||
/* K36 */ be_nested_string("stop_iteration", -121173395, 14),
|
||||
/* K37 */ be_nested_string("EVENT_DRAW_PART_END", -993342004, 19),
|
||||
}),
|
||||
(be_nested_const_str("my_design_cb", -1173588798, 12)),
|
||||
(be_nested_const_str("widget_event", 1951408186, 12)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[121]) { /* code */
|
||||
0x840C0000, // 0000 CLOSURE R3 P0
|
||||
0x8C100100, // 0001 GETMET R4 R0 K0
|
||||
0x7C100200, // 0002 CALL R4 1
|
||||
0x8C140101, // 0003 GETMET R5 R0 K1
|
||||
0x7C140200, // 0004 CALL R5 1
|
||||
0x5C180600, // 0005 MOVE R6 R3
|
||||
0x541E000E, // 0006 LDINT R7 15
|
||||
0x0C1C0A07, // 0007 DIV R7 R5 R7
|
||||
0x7C180200, // 0008 CALL R6 1
|
||||
0x5C1C0600, // 0009 MOVE R7 R3
|
||||
0x08200D02, // 000A MUL R8 R6 K2
|
||||
0x04200A08, // 000B SUB R8 R5 R8
|
||||
0x54260003, // 000C LDINT R9 4
|
||||
0x0C201009, // 000D DIV R8 R8 R9
|
||||
0x7C1C0200, // 000E CALL R7 1
|
||||
0x0C200F03, // 000F DIV R8 R7 K3
|
||||
0xB8260800, // 0010 GETNGBL R9 K4
|
||||
0x88241305, // 0011 GETMBR R9 R9 K5
|
||||
0x1C240409, // 0012 EQ R9 R2 R9
|
||||
0x78260007, // 0013 JMPF R9 #001C
|
||||
0x88240106, // 0014 GETMBR R9 R0 K6
|
||||
0x8C241307, // 0015 GETMET R9 R9 K7
|
||||
0x5C2C0000, // 0016 MOVE R11 R0
|
||||
0x5C300200, // 0017 MOVE R12 R1
|
||||
0x5C340400, // 0018 MOVE R13 R2
|
||||
0x7C240800, // 0019 CALL R9 4
|
||||
0x80041200, // 001A RET 1 R9
|
||||
0x70020059, // 001B JMP #0076
|
||||
0xB8260800, // 001C GETNGBL R9 K4
|
||||
0x88241308, // 001D GETMBR R9 R9 K8
|
||||
0x1C240409, // 001E EQ R9 R2 R9
|
||||
0x78260055, // 001F JMPF R9 #0076
|
||||
0x8C240109, // 0020 GETMET R9 R0 K9
|
||||
0x882C010A, // 0021 GETMBR R11 R0 K10
|
||||
0x7C240400, // 0022 CALL R9 2
|
||||
0x8824010A, // 0023 GETMBR R9 R0 K10
|
||||
0x8824130B, // 0024 GETMBR R9 R9 K11
|
||||
0x8828010A, // 0025 GETMBR R10 R0 K10
|
||||
0x8828150C, // 0026 GETMBR R10 R10 K12
|
||||
0xB82E0800, // 0027 GETNGBL R11 K4
|
||||
0x8C2C170D, // 0028 GETMET R11 R11 K13
|
||||
0x8834010E, // 0029 GETMBR R13 R0 K14
|
||||
0x7C2C0400, // 002A CALL R11 2
|
||||
0x8C2C010F, // 002B GETMET R11 R0 K15
|
||||
0xB8360800, // 002C GETNGBL R13 K4
|
||||
0x88341B10, // 002D GETMBR R13 R13 K16
|
||||
0x8838010E, // 002E GETMBR R14 R0 K14
|
||||
0x7C2C0600, // 002F CALL R11 3
|
||||
0x882C010E, // 0030 GETMBR R11 R0 K14
|
||||
0x902E2312, // 0031 SETMBR R11 K17 K18
|
||||
0x882C010E, // 0032 GETMBR R11 R0 K14
|
||||
0x902E2712, // 0033 SETMBR R11 K19 K18
|
||||
0x882C010E, // 0034 GETMBR R11 R0 K14
|
||||
0x902E2807, // 0035 SETMBR R11 K20 R7
|
||||
0x8C2C0115, // 0036 GETMET R11 R0 K21
|
||||
0xB8360800, // 0037 GETNGBL R13 K4
|
||||
0x88341B10, // 0038 GETMBR R13 R13 K16
|
||||
0xB83A0800, // 0039 GETNGBL R14 K4
|
||||
0x88381D16, // 003A GETMBR R14 R14 K22
|
||||
0x7C2C0600, // 003B CALL R11 3
|
||||
0x8C300117, // 003C GETMET R12 R0 K23
|
||||
0xB83A0800, // 003D GETNGBL R14 K4
|
||||
0x88381D10, // 003E GETMBR R14 R14 K16
|
||||
0xB83E0800, // 003F GETNGBL R15 K4
|
||||
0x883C1F16, // 0040 GETMBR R15 R15 K22
|
||||
0x7C300600, // 0041 CALL R12 3
|
||||
0x60340010, // 0042 GETGBL R13 G16
|
||||
0x403A3102, // 0043 CONNECT R14 K24 K2
|
||||
0x7C340200, // 0044 CALL R13 1
|
||||
0xA802002C, // 0045 EXBLK 0 #0073
|
||||
0x5C381A00, // 0046 MOVE R14 R13
|
||||
0x7C380000, // 0047 CALL R14 0
|
||||
0x883C010E, // 0048 GETMBR R15 R0 K14
|
||||
0x8840011A, // 0049 GETMBR R16 R0 K26
|
||||
0x00441D12, // 004A ADD R17 R14 K18
|
||||
0x544A0013, // 004B LDINT R18 20
|
||||
0x08442212, // 004C MUL R17 R17 R18
|
||||
0x28402011, // 004D GE R16 R16 R17
|
||||
0x78420001, // 004E JMPF R16 #0051
|
||||
0x5C401600, // 004F MOVE R16 R11
|
||||
0x70020000, // 0050 JMP #0052
|
||||
0x5C401800, // 0051 MOVE R16 R12
|
||||
0x903E3210, // 0052 SETMBR R15 K25 R16
|
||||
0x883C011B, // 0053 GETMBR R15 R0 K27
|
||||
0x00401404, // 0054 ADD R16 R10 R4
|
||||
0x04402112, // 0055 SUB R16 R16 K18
|
||||
0x04402008, // 0056 SUB R16 R16 R8
|
||||
0x903E3810, // 0057 SETMBR R15 K28 R16
|
||||
0x883C011B, // 0058 GETMBR R15 R0 K27
|
||||
0x00400E06, // 0059 ADD R16 R7 R6
|
||||
0x08401C10, // 005A MUL R16 R14 R16
|
||||
0x00401210, // 005B ADD R16 R9 R16
|
||||
0x00402008, // 005C ADD R16 R16 R8
|
||||
0x903E3A10, // 005D SETMBR R15 K29 R16
|
||||
0x883C011E, // 005E GETMBR R15 R0 K30
|
||||
0x0442040E, // 005F SUB R16 K2 R14
|
||||
0x04440807, // 0060 SUB R17 R4 R7
|
||||
0x08402011, // 0061 MUL R16 R16 R17
|
||||
0x54460003, // 0062 LDINT R17 4
|
||||
0x0C402011, // 0063 DIV R16 R16 R17
|
||||
0x00401410, // 0064 ADD R16 R10 R16
|
||||
0x00402008, // 0065 ADD R16 R16 R8
|
||||
0x903E3810, // 0066 SETMBR R15 K28 R16
|
||||
0x883C011E, // 0067 GETMBR R15 R0 K30
|
||||
0x8840011B, // 0068 GETMBR R16 R0 K27
|
||||
0x8840211D, // 0069 GETMBR R16 R16 K29
|
||||
0x903E3A10, // 006A SETMBR R15 K29 R16
|
||||
0xB83E0800, // 006B GETNGBL R15 K4
|
||||
0x8C3C1F1F, // 006C GETMET R15 R15 K31
|
||||
0x8844011B, // 006D GETMBR R17 R0 K27
|
||||
0x8848011E, // 006E GETMBR R18 R0 K30
|
||||
0x5C4C0200, // 006F MOVE R19 R1
|
||||
0x8850010E, // 0070 GETMBR R20 R0 K14
|
||||
0x7C3C0A00, // 0071 CALL R15 5
|
||||
0x7001FFD2, // 0072 JMP #0046
|
||||
0x58340020, // 0073 LDCONST R13 K32
|
||||
0xAC340200, // 0074 CATCH R13 1 0
|
||||
0xB0080000, // 0075 RAISE 2 R0 R0
|
||||
0xB8260800, // 0076 GETNGBL R9 K4
|
||||
0x88241321, // 0077 GETMBR R9 R9 K33
|
||||
0x80041200, // 0078 RET 1 R9
|
||||
( &(const binstruction[137]) { /* code */
|
||||
0xB80E0000, // 0000 GETNGBL R3 K0
|
||||
0x8C0C0701, // 0001 GETMET R3 R3 K1
|
||||
0x5C140200, // 0002 MOVE R5 R1
|
||||
0x5C180400, // 0003 MOVE R6 R2
|
||||
0x7C0C0600, // 0004 CALL R3 3
|
||||
0xB8120000, // 0005 GETNGBL R4 K0
|
||||
0x88100902, // 0006 GETMBR R4 R4 K2
|
||||
0x200C0604, // 0007 NE R3 R3 R4
|
||||
0x780E0000, // 0008 JMPF R3 #000A
|
||||
0x80000600, // 0009 RET 0
|
||||
0x880C0503, // 000A GETMBR R3 R2 K3
|
||||
0x84100000, // 000B CLOSURE R4 P0
|
||||
0x8C140104, // 000C GETMET R5 R0 K4
|
||||
0x7C140200, // 000D CALL R5 1
|
||||
0x8C180105, // 000E GETMET R6 R0 K5
|
||||
0x7C180200, // 000F CALL R6 1
|
||||
0x5C1C0800, // 0010 MOVE R7 R4
|
||||
0x5422000E, // 0011 LDINT R8 15
|
||||
0x0C200C08, // 0012 DIV R8 R6 R8
|
||||
0x7C1C0200, // 0013 CALL R7 1
|
||||
0x5C200800, // 0014 MOVE R8 R4
|
||||
0x08240F06, // 0015 MUL R9 R7 K6
|
||||
0x04240C09, // 0016 SUB R9 R6 R9
|
||||
0x542A0003, // 0017 LDINT R10 4
|
||||
0x0C24120A, // 0018 DIV R9 R9 R10
|
||||
0x7C200200, // 0019 CALL R8 1
|
||||
0x0C241107, // 001A DIV R9 R8 K7
|
||||
0xB82A0000, // 001B GETNGBL R10 K0
|
||||
0x88281508, // 001C GETMBR R10 R10 K8
|
||||
0x1C28060A, // 001D EQ R10 R3 R10
|
||||
0x782A0068, // 001E JMPF R10 #0088
|
||||
0xB82A1200, // 001F GETNGBL R10 K9
|
||||
0x882C050A, // 0020 GETMBR R11 R2 K10
|
||||
0x7C280200, // 0021 CALL R10 1
|
||||
0x8C2C010B, // 0022 GETMET R11 R0 K11
|
||||
0x8834010C, // 0023 GETMBR R13 R0 K12
|
||||
0x7C2C0400, // 0024 CALL R11 2
|
||||
0x882C010C, // 0025 GETMBR R11 R0 K12
|
||||
0x882C170D, // 0026 GETMBR R11 R11 K13
|
||||
0x8830010C, // 0027 GETMBR R12 R0 K12
|
||||
0x8830190E, // 0028 GETMBR R12 R12 K14
|
||||
0xB8360000, // 0029 GETNGBL R13 K0
|
||||
0x8C341B0F, // 002A GETMET R13 R13 K15
|
||||
0x883C0110, // 002B GETMBR R15 R0 K16
|
||||
0x7C340400, // 002C CALL R13 2
|
||||
0x8C340111, // 002D GETMET R13 R0 K17
|
||||
0xB83E0000, // 002E GETNGBL R15 K0
|
||||
0x883C1F12, // 002F GETMBR R15 R15 K18
|
||||
0x88400110, // 0030 GETMBR R16 R0 K16
|
||||
0x7C340600, // 0031 CALL R13 3
|
||||
0x88340110, // 0032 GETMBR R13 R0 K16
|
||||
0x90362714, // 0033 SETMBR R13 K19 K20
|
||||
0x88340110, // 0034 GETMBR R13 R0 K16
|
||||
0x90362B14, // 0035 SETMBR R13 K21 K20
|
||||
0x88340110, // 0036 GETMBR R13 R0 K16
|
||||
0x90362C08, // 0037 SETMBR R13 K22 R8
|
||||
0x8C340117, // 0038 GETMET R13 R0 K23
|
||||
0xB83E0000, // 0039 GETNGBL R15 K0
|
||||
0x883C1F12, // 003A GETMBR R15 R15 K18
|
||||
0xB8420000, // 003B GETNGBL R16 K0
|
||||
0x88402118, // 003C GETMBR R16 R16 K24
|
||||
0x303C1E10, // 003D OR R15 R15 R16
|
||||
0x7C340400, // 003E CALL R13 2
|
||||
0x8C380119, // 003F GETMET R14 R0 K25
|
||||
0xB8420000, // 0040 GETNGBL R16 K0
|
||||
0x88402112, // 0041 GETMBR R16 R16 K18
|
||||
0xB8460000, // 0042 GETNGBL R17 K0
|
||||
0x88442318, // 0043 GETMBR R17 R17 K24
|
||||
0x30402011, // 0044 OR R16 R16 R17
|
||||
0x7C380400, // 0045 CALL R14 2
|
||||
0xB83E0000, // 0046 GETNGBL R15 K0
|
||||
0x8C3C1F1A, // 0047 GETMET R15 R15 K26
|
||||
0x5C440000, // 0048 MOVE R17 R0
|
||||
0xB84A0000, // 0049 GETNGBL R18 K0
|
||||
0x8848251B, // 004A GETMBR R18 R18 K27
|
||||
0x884C0110, // 004B GETMBR R19 R0 K16
|
||||
0x7C3C0800, // 004C CALL R15 4
|
||||
0x603C0010, // 004D GETGBL R15 G16
|
||||
0x40423906, // 004E CONNECT R16 K28 K6
|
||||
0x7C3C0200, // 004F CALL R15 1
|
||||
0xA802002C, // 0050 EXBLK 0 #007E
|
||||
0x5C401E00, // 0051 MOVE R16 R15
|
||||
0x7C400000, // 0052 CALL R16 0
|
||||
0x88440110, // 0053 GETMBR R17 R0 K16
|
||||
0x8848011E, // 0054 GETMBR R18 R0 K30
|
||||
0x004C2114, // 0055 ADD R19 R16 K20
|
||||
0x54520013, // 0056 LDINT R20 20
|
||||
0x084C2614, // 0057 MUL R19 R19 R20
|
||||
0x28482413, // 0058 GE R18 R18 R19
|
||||
0x784A0001, // 0059 JMPF R18 #005C
|
||||
0x5C481A00, // 005A MOVE R18 R13
|
||||
0x70020000, // 005B JMP #005D
|
||||
0x5C481C00, // 005C MOVE R18 R14
|
||||
0x90463A12, // 005D SETMBR R17 K29 R18
|
||||
0x8844011F, // 005E GETMBR R17 R0 K31
|
||||
0x00481805, // 005F ADD R18 R12 R5
|
||||
0x04482514, // 0060 SUB R18 R18 K20
|
||||
0x04482409, // 0061 SUB R18 R18 R9
|
||||
0x90464012, // 0062 SETMBR R17 K32 R18
|
||||
0x8844011F, // 0063 GETMBR R17 R0 K31
|
||||
0x00481007, // 0064 ADD R18 R8 R7
|
||||
0x08482012, // 0065 MUL R18 R16 R18
|
||||
0x00481612, // 0066 ADD R18 R11 R18
|
||||
0x00482409, // 0067 ADD R18 R18 R9
|
||||
0x90464212, // 0068 SETMBR R17 K33 R18
|
||||
0x88440122, // 0069 GETMBR R17 R0 K34
|
||||
0x044A0C10, // 006A SUB R18 K6 R16
|
||||
0x044C0A08, // 006B SUB R19 R5 R8
|
||||
0x08482413, // 006C MUL R18 R18 R19
|
||||
0x544E0003, // 006D LDINT R19 4
|
||||
0x0C482413, // 006E DIV R18 R18 R19
|
||||
0x00481812, // 006F ADD R18 R12 R18
|
||||
0x00482409, // 0070 ADD R18 R18 R9
|
||||
0x90464012, // 0071 SETMBR R17 K32 R18
|
||||
0x88440122, // 0072 GETMBR R17 R0 K34
|
||||
0x8848011F, // 0073 GETMBR R18 R0 K31
|
||||
0x88482521, // 0074 GETMBR R18 R18 K33
|
||||
0x90464212, // 0075 SETMBR R17 K33 R18
|
||||
0xB8460000, // 0076 GETNGBL R17 K0
|
||||
0x8C442323, // 0077 GETMET R17 R17 K35
|
||||
0x884C011F, // 0078 GETMBR R19 R0 K31
|
||||
0x88500122, // 0079 GETMBR R20 R0 K34
|
||||
0x5C541400, // 007A MOVE R21 R10
|
||||
0x88580110, // 007B GETMBR R22 R0 K16
|
||||
0x7C440A00, // 007C CALL R17 5
|
||||
0x7001FFD2, // 007D JMP #0051
|
||||
0x583C0024, // 007E LDCONST R15 K36
|
||||
0xAC3C0200, // 007F CATCH R15 1 0
|
||||
0xB0080000, // 0080 RAISE 2 R0 R0
|
||||
0xB83E0000, // 0081 GETNGBL R15 K0
|
||||
0x8C3C1F1A, // 0082 GETMET R15 R15 K26
|
||||
0x5C440000, // 0083 MOVE R17 R0
|
||||
0xB84A0000, // 0084 GETNGBL R18 K0
|
||||
0x88482525, // 0085 GETMBR R18 R18 K37
|
||||
0x884C0110, // 0086 GETMBR R19 R0 K16
|
||||
0x7C3C0800, // 0087 CALL R15 4
|
||||
0x80000000, // 0088 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
@ -237,135 +356,24 @@ be_local_closure(get_percentage, /* name */
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: init
|
||||
********************************************************************/
|
||||
be_local_closure(init, /* name */
|
||||
be_nested_proto(
|
||||
7, /* nstack */
|
||||
3, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[13]) { /* constants */
|
||||
/* K0 */ be_nested_string("init", 380752755, 4),
|
||||
/* K1 */ be_nested_string("ancestor_design", 421545719, 15),
|
||||
/* K2 */ be_nested_string("get_design_cb", -825649242, 13),
|
||||
/* K3 */ be_nested_string("set_design_cb", 1469311634, 13),
|
||||
/* K4 */ be_nested_string("my_design_cb", -1173588798, 12),
|
||||
/* K5 */ be_nested_string("percentage", -1756136011, 10),
|
||||
/* K6 */ be_nested_string("p1", -1605446022, 2),
|
||||
/* K7 */ be_nested_string("lv_point", -174745506, 8),
|
||||
/* K8 */ be_nested_string("p2", -1622223641, 2),
|
||||
/* K9 */ be_nested_string("area", -1693507260, 4),
|
||||
/* K10 */ be_nested_string("lv_area", -1773816895, 7),
|
||||
/* K11 */ be_nested_string("line_dsc", -200476318, 8),
|
||||
/* K12 */ be_nested_string("lv_draw_line_dsc", -1872162060, 16),
|
||||
}),
|
||||
(be_nested_const_str("init", 380752755, 4)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[28]) { /* code */
|
||||
0x600C0003, // 0000 GETGBL R3 G3
|
||||
0x5C100000, // 0001 MOVE R4 R0
|
||||
0x7C0C0200, // 0002 CALL R3 1
|
||||
0x8C0C0700, // 0003 GETMET R3 R3 K0
|
||||
0x5C140200, // 0004 MOVE R5 R1
|
||||
0x5C180400, // 0005 MOVE R6 R2
|
||||
0x7C0C0600, // 0006 CALL R3 3
|
||||
0x8C0C0102, // 0007 GETMET R3 R0 K2
|
||||
0x7C0C0200, // 0008 CALL R3 1
|
||||
0x90020203, // 0009 SETMBR R0 K1 R3
|
||||
0x8C0C0103, // 000A GETMET R3 R0 K3
|
||||
0x88140104, // 000B GETMBR R5 R0 K4
|
||||
0x7C0C0400, // 000C CALL R3 2
|
||||
0x540E0063, // 000D LDINT R3 100
|
||||
0x90020A03, // 000E SETMBR R0 K5 R3
|
||||
0xB80E0E00, // 000F GETNGBL R3 K7
|
||||
0x7C0C0000, // 0010 CALL R3 0
|
||||
0x90020C03, // 0011 SETMBR R0 K6 R3
|
||||
0xB80E0E00, // 0012 GETNGBL R3 K7
|
||||
0x7C0C0000, // 0013 CALL R3 0
|
||||
0x90021003, // 0014 SETMBR R0 K8 R3
|
||||
0xB80E1400, // 0015 GETNGBL R3 K10
|
||||
0x7C0C0000, // 0016 CALL R3 0
|
||||
0x90021203, // 0017 SETMBR R0 K9 R3
|
||||
0xB80E1800, // 0018 GETNGBL R3 K12
|
||||
0x7C0C0000, // 0019 CALL R3 0
|
||||
0x90021603, // 001A SETMBR R0 K11 R3
|
||||
0x80000000, // 001B RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified function: set_percentage
|
||||
********************************************************************/
|
||||
be_local_closure(set_percentage, /* name */
|
||||
be_nested_proto(
|
||||
5, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[ 3]) { /* constants */
|
||||
/* K0 */ be_nested_string("percentage", -1756136011, 10),
|
||||
/* K1 */ be_const_int(0),
|
||||
/* K2 */ be_nested_string("invalidate", -1645232368, 10),
|
||||
}),
|
||||
(be_nested_const_str("set_percentage", -1342944572, 14)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[18]) { /* code */
|
||||
0x88080100, // 0000 GETMBR R2 R0 K0
|
||||
0x540E0004, // 0001 LDINT R3 5
|
||||
0x0C080403, // 0002 DIV R2 R2 R3
|
||||
0x540E0063, // 0003 LDINT R3 100
|
||||
0x240C0203, // 0004 GT R3 R1 R3
|
||||
0x780E0000, // 0005 JMPF R3 #0007
|
||||
0x54060063, // 0006 LDINT R1 100
|
||||
0x140C0301, // 0007 LT R3 R1 K1
|
||||
0x780E0000, // 0008 JMPF R3 #000A
|
||||
0x58040001, // 0009 LDCONST R1 K1
|
||||
0x90020001, // 000A SETMBR R0 K0 R1
|
||||
0x540E0004, // 000B LDINT R3 5
|
||||
0x0C0C0203, // 000C DIV R3 R1 R3
|
||||
0x200C0403, // 000D NE R3 R2 R3
|
||||
0x780E0001, // 000E JMPF R3 #0011
|
||||
0x8C0C0102, // 000F GETMET R3 R0 K2
|
||||
0x7C0C0200, // 0010 CALL R3 1
|
||||
0x80000000, // 0011 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
/*******************************************************************/
|
||||
|
||||
|
||||
/********************************************************************
|
||||
** Solidified class: lv_signal_bars
|
||||
********************************************************************/
|
||||
extern const bclass be_class_lv_obj;
|
||||
be_local_class(lv_signal_bars,
|
||||
6,
|
||||
5,
|
||||
&be_class_lv_obj,
|
||||
be_nested_map(10,
|
||||
be_nested_map(9,
|
||||
( (struct bmapnode*) &(const bmapnode[]) {
|
||||
{ be_nested_key("p1", -1605446022, 2, -1), be_const_var(2) },
|
||||
{ be_nested_key("my_design_cb", -1173588798, 12, -1), be_const_closure(my_design_cb_closure) },
|
||||
{ be_nested_key("get_percentage", -1414483304, 14, -1), be_const_closure(get_percentage_closure) },
|
||||
{ be_nested_key("init", 380752755, 4, 7), be_const_closure(init_closure) },
|
||||
{ be_nested_key("set_percentage", -1342944572, 14, 0), be_const_closure(set_percentage_closure) },
|
||||
{ be_nested_key("percentage", -1756136011, 10, 3), be_const_var(1) },
|
||||
{ be_nested_key("area", -1693507260, 4, -1), be_const_var(4) },
|
||||
{ be_nested_key("p2", -1622223641, 2, -1), be_const_var(3) },
|
||||
{ be_nested_key("line_dsc", -200476318, 8, 1), be_const_var(5) },
|
||||
{ be_nested_key("ancestor_design", 421545719, 15, -1), be_const_var(0) },
|
||||
{ be_nested_key("percentage", -1756136011, 10, 4), be_const_var(0) },
|
||||
{ be_nested_key("p1", -1605446022, 2, 3), be_const_var(1) },
|
||||
{ be_nested_key("p2", -1622223641, 2, -1), be_const_var(2) },
|
||||
{ be_nested_key("area", -1693507260, 4, -1), be_const_var(3) },
|
||||
{ be_nested_key("line_dsc", -200476318, 8, -1), be_const_var(4) },
|
||||
{ be_nested_key("set_percentage", -1342944572, 14, -1), be_const_closure(set_percentage_closure) },
|
||||
{ be_nested_key("init", 380752755, 4, -1), be_const_closure(init_closure) },
|
||||
{ be_nested_key("widget_event", 1951408186, 12, -1), be_const_closure(widget_event_closure) },
|
||||
{ be_nested_key("get_percentage", -1414483304, 14, 5), be_const_closure(get_percentage_closure) },
|
||||
})),
|
||||
(be_nested_const_str("lv_signal_bars", -780994737, 14))
|
||||
);
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -12,87 +12,102 @@
|
||||
********************************************************************/
|
||||
be_local_closure(init, /* name */
|
||||
be_nested_proto(
|
||||
11, /* nstack */
|
||||
3, /* argc */
|
||||
10, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[16]) { /* constants */
|
||||
( &(const bvalue[18]) { /* constants */
|
||||
/* K0 */ be_nested_string("init", 380752755, 4),
|
||||
/* K1 */ be_nested_string("set_style_local_bg_color", -498263023, 24),
|
||||
/* K2 */ be_nested_string("lv", 1529997255, 2),
|
||||
/* K3 */ be_nested_string("OBJ_PART_MAIN", 658062838, 13),
|
||||
/* K4 */ be_nested_string("STATE_DEFAULT", 712406428, 13),
|
||||
/* K5 */ be_nested_string("lv_color", 1419148319, 8),
|
||||
/* K6 */ be_nested_string("COLOR_BLACK", 264427940, 11),
|
||||
/* K7 */ be_nested_string("get_height", -723211773, 10),
|
||||
/* K8 */ be_nested_string("get_style_pad_right", -1144679830, 19),
|
||||
/* K9 */ be_nested_string("set_height", 1080207399, 10),
|
||||
/* K10 */ be_const_int(3),
|
||||
/* K11 */ be_nested_string("set_width", 484671920, 9),
|
||||
/* K12 */ be_nested_string("set_x", 1849400772, 5),
|
||||
/* K13 */ be_nested_string("get_width", -1001549996, 9),
|
||||
/* K14 */ be_nested_string("set_style_local_pad_right", 1126712366, 25),
|
||||
/* K15 */ be_const_int(1),
|
||||
/* K1 */ be_nested_string("set_style_line_color", -629728320, 20),
|
||||
/* K2 */ be_nested_string("lv_color", 1419148319, 8),
|
||||
/* K3 */ be_nested_string("lv", 1529997255, 2),
|
||||
/* K4 */ be_nested_string("COLOR_WHITE", -1758096026, 11),
|
||||
/* K5 */ be_nested_string("PART_MAIN", -1821475788, 9),
|
||||
/* K6 */ be_nested_string("STATE_DEFAULT", 712406428, 13),
|
||||
/* K7 */ be_nested_string("set_style_bg_color", 1689513089, 18),
|
||||
/* K8 */ be_nested_string("COLOR_BLACK", 264427940, 11),
|
||||
/* K9 */ be_nested_string("get_height", -723211773, 10),
|
||||
/* K10 */ be_nested_string("get_style_pad_right", -1144679830, 19),
|
||||
/* K11 */ be_nested_string("set_height", 1080207399, 10),
|
||||
/* K12 */ be_const_int(3),
|
||||
/* K13 */ be_nested_string("set_width", 484671920, 9),
|
||||
/* K14 */ be_nested_string("set_x", 1849400772, 5),
|
||||
/* K15 */ be_nested_string("get_width", -1001549996, 9),
|
||||
/* K16 */ be_nested_string("set_style_pad_right", -980898242, 19),
|
||||
/* K17 */ be_const_int(1),
|
||||
}),
|
||||
(be_nested_const_str("init", 380752755, 4)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[52]) { /* code */
|
||||
0x600C0003, // 0000 GETGBL R3 G3
|
||||
0x5C100000, // 0001 MOVE R4 R0
|
||||
0x7C0C0200, // 0002 CALL R3 1
|
||||
0x8C0C0700, // 0003 GETMET R3 R3 K0
|
||||
0x5C140200, // 0004 MOVE R5 R1
|
||||
0x5C180400, // 0005 MOVE R6 R2
|
||||
0x7C0C0600, // 0006 CALL R3 3
|
||||
0x8C0C0101, // 0007 GETMET R3 R0 K1
|
||||
0xB8160400, // 0008 GETNGBL R5 K2
|
||||
0x88140B03, // 0009 GETMBR R5 R5 K3
|
||||
0xB81A0400, // 000A GETNGBL R6 K2
|
||||
0x88180D04, // 000B GETMBR R6 R6 K4
|
||||
0xB81E0A00, // 000C GETNGBL R7 K5
|
||||
0xB8220400, // 000D GETNGBL R8 K2
|
||||
0x88201106, // 000E GETMBR R8 R8 K6
|
||||
0x7C1C0200, // 000F CALL R7 1
|
||||
0x7C0C0800, // 0010 CALL R3 4
|
||||
0x4C0C0000, // 0011 LDNIL R3
|
||||
0x200C0203, // 0012 NE R3 R1 R3
|
||||
0x780E001E, // 0013 JMPF R3 #0033
|
||||
0x8C0C0307, // 0014 GETMET R3 R1 K7
|
||||
0x7C0C0200, // 0015 CALL R3 1
|
||||
0x8C100308, // 0016 GETMET R4 R1 K8
|
||||
0xB81A0400, // 0017 GETNGBL R6 K2
|
||||
0x88180D03, // 0018 GETMBR R6 R6 K3
|
||||
0xB81E0400, // 0019 GETNGBL R7 K2
|
||||
0x881C0F04, // 001A GETMBR R7 R7 K4
|
||||
0x7C100600, // 001B CALL R4 3
|
||||
0x8C140109, // 001C GETMET R5 R0 K9
|
||||
0x5C1C0600, // 001D MOVE R7 R3
|
||||
0x7C140400, // 001E CALL R5 2
|
||||
0x54160003, // 001F LDINT R5 4
|
||||
0x08140605, // 0020 MUL R5 R3 R5
|
||||
0x0C140B0A, // 0021 DIV R5 R5 K10
|
||||
0x8C18010B, // 0022 GETMET R6 R0 K11
|
||||
0x5C200A00, // 0023 MOVE R8 R5
|
||||
0x7C180400, // 0024 CALL R6 2
|
||||
0x8C18010C, // 0025 GETMET R6 R0 K12
|
||||
0x8C20030D, // 0026 GETMET R8 R1 K13
|
||||
0x7C200200, // 0027 CALL R8 1
|
||||
0x04201005, // 0028 SUB R8 R8 R5
|
||||
0x04201004, // 0029 SUB R8 R8 R4
|
||||
0x7C180400, // 002A CALL R6 2
|
||||
0x8C18030E, // 002B GETMET R6 R1 K14
|
||||
0xB8220400, // 002C GETNGBL R8 K2
|
||||
0x88201103, // 002D GETMBR R8 R8 K3
|
||||
0xB8260400, // 002E GETNGBL R9 K2
|
||||
0x88241304, // 002F GETMBR R9 R9 K4
|
||||
0x00280805, // 0030 ADD R10 R4 R5
|
||||
0x0028150F, // 0031 ADD R10 R10 K15
|
||||
0x7C180800, // 0032 CALL R6 4
|
||||
0x80000000, // 0033 RET 0
|
||||
( &(const binstruction[65]) { /* code */
|
||||
0x60080003, // 0000 GETGBL R2 G3
|
||||
0x5C0C0000, // 0001 MOVE R3 R0
|
||||
0x7C080200, // 0002 CALL R2 1
|
||||
0x8C080500, // 0003 GETMET R2 R2 K0
|
||||
0x5C100200, // 0004 MOVE R4 R1
|
||||
0x7C080400, // 0005 CALL R2 2
|
||||
0x8C080101, // 0006 GETMET R2 R0 K1
|
||||
0xB8120400, // 0007 GETNGBL R4 K2
|
||||
0xB8160600, // 0008 GETNGBL R5 K3
|
||||
0x88140B04, // 0009 GETMBR R5 R5 K4
|
||||
0x7C100200, // 000A CALL R4 1
|
||||
0xB8160600, // 000B GETNGBL R5 K3
|
||||
0x88140B05, // 000C GETMBR R5 R5 K5
|
||||
0xB81A0600, // 000D GETNGBL R6 K3
|
||||
0x88180D06, // 000E GETMBR R6 R6 K6
|
||||
0x30140A06, // 000F OR R5 R5 R6
|
||||
0x7C080600, // 0010 CALL R2 3
|
||||
0x8C080107, // 0011 GETMET R2 R0 K7
|
||||
0xB8120400, // 0012 GETNGBL R4 K2
|
||||
0xB8160600, // 0013 GETNGBL R5 K3
|
||||
0x88140B08, // 0014 GETMBR R5 R5 K8
|
||||
0x7C100200, // 0015 CALL R4 1
|
||||
0xB8160600, // 0016 GETNGBL R5 K3
|
||||
0x88140B05, // 0017 GETMBR R5 R5 K5
|
||||
0xB81A0600, // 0018 GETNGBL R6 K3
|
||||
0x88180D06, // 0019 GETMBR R6 R6 K6
|
||||
0x30140A06, // 001A OR R5 R5 R6
|
||||
0x7C080600, // 001B CALL R2 3
|
||||
0x4C080000, // 001C LDNIL R2
|
||||
0x20080202, // 001D NE R2 R1 R2
|
||||
0x780A0020, // 001E JMPF R2 #0040
|
||||
0x8C080309, // 001F GETMET R2 R1 K9
|
||||
0x7C080200, // 0020 CALL R2 1
|
||||
0x8C0C030A, // 0021 GETMET R3 R1 K10
|
||||
0xB8160600, // 0022 GETNGBL R5 K3
|
||||
0x88140B05, // 0023 GETMBR R5 R5 K5
|
||||
0xB81A0600, // 0024 GETNGBL R6 K3
|
||||
0x88180D06, // 0025 GETMBR R6 R6 K6
|
||||
0x30140A06, // 0026 OR R5 R5 R6
|
||||
0x7C0C0400, // 0027 CALL R3 2
|
||||
0x8C10010B, // 0028 GETMET R4 R0 K11
|
||||
0x5C180400, // 0029 MOVE R6 R2
|
||||
0x7C100400, // 002A CALL R4 2
|
||||
0x54120003, // 002B LDINT R4 4
|
||||
0x08100404, // 002C MUL R4 R2 R4
|
||||
0x0C10090C, // 002D DIV R4 R4 K12
|
||||
0x8C14010D, // 002E GETMET R5 R0 K13
|
||||
0x5C1C0800, // 002F MOVE R7 R4
|
||||
0x7C140400, // 0030 CALL R5 2
|
||||
0x8C14010E, // 0031 GETMET R5 R0 K14
|
||||
0x8C1C030F, // 0032 GETMET R7 R1 K15
|
||||
0x7C1C0200, // 0033 CALL R7 1
|
||||
0x041C0E04, // 0034 SUB R7 R7 R4
|
||||
0x041C0E03, // 0035 SUB R7 R7 R3
|
||||
0x7C140400, // 0036 CALL R5 2
|
||||
0x8C140310, // 0037 GETMET R5 R1 K16
|
||||
0x001C0604, // 0038 ADD R7 R3 R4
|
||||
0x001C0F11, // 0039 ADD R7 R7 K17
|
||||
0xB8220600, // 003A GETNGBL R8 K3
|
||||
0x88201105, // 003B GETMBR R8 R8 K5
|
||||
0xB8260600, // 003C GETNGBL R9 K3
|
||||
0x88241306, // 003D GETMBR R9 R9 K6
|
||||
0x30201009, // 003E OR R8 R8 R9
|
||||
0x7C140600, // 003F CALL R5 3
|
||||
0x80000000, // 0040 RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
|
@ -66,8 +66,8 @@ be_local_closure(every_second, /* name */
|
||||
********************************************************************/
|
||||
be_local_closure(init, /* name */
|
||||
be_nested_proto(
|
||||
7, /* nstack */
|
||||
3, /* argc */
|
||||
5, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
@ -83,22 +83,21 @@ be_local_closure(init, /* name */
|
||||
}),
|
||||
(be_nested_const_str("init", 380752755, 4)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[15]) { /* code */
|
||||
0x600C0003, // 0000 GETGBL R3 G3
|
||||
0x5C100000, // 0001 MOVE R4 R0
|
||||
0x7C0C0200, // 0002 CALL R3 1
|
||||
0x8C0C0700, // 0003 GETMET R3 R3 K0
|
||||
0x5C140200, // 0004 MOVE R5 R1
|
||||
0x5C180400, // 0005 MOVE R6 R2
|
||||
0x7C0C0600, // 0006 CALL R3 3
|
||||
0xB80E0200, // 0007 GETNGBL R3 K1
|
||||
0x8C0C0702, // 0008 GETMET R3 R3 K2
|
||||
0x5C140000, // 0009 MOVE R5 R0
|
||||
0x7C0C0400, // 000A CALL R3 2
|
||||
0x8C0C0103, // 000B GETMET R3 R0 K3
|
||||
0x58140004, // 000C LDCONST R5 K4
|
||||
0x7C0C0400, // 000D CALL R3 2
|
||||
0x80000000, // 000E RET 0
|
||||
( &(const binstruction[14]) { /* code */
|
||||
0x60080003, // 0000 GETGBL R2 G3
|
||||
0x5C0C0000, // 0001 MOVE R3 R0
|
||||
0x7C080200, // 0002 CALL R2 1
|
||||
0x8C080500, // 0003 GETMET R2 R2 K0
|
||||
0x5C100200, // 0004 MOVE R4 R1
|
||||
0x7C080400, // 0005 CALL R2 2
|
||||
0xB80A0200, // 0006 GETNGBL R2 K1
|
||||
0x8C080502, // 0007 GETMET R2 R2 K2
|
||||
0x5C100000, // 0008 MOVE R4 R0
|
||||
0x7C080400, // 0009 CALL R2 2
|
||||
0x8C080103, // 000A GETMET R2 R0 K3
|
||||
0x58100004, // 000B LDCONST R4 K4
|
||||
0x7C080400, // 000C CALL R2 2
|
||||
0x80000000, // 000D RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
|
@ -12,83 +12,98 @@
|
||||
********************************************************************/
|
||||
be_local_closure(init, /* name */
|
||||
be_nested_proto(
|
||||
10, /* nstack */
|
||||
3, /* argc */
|
||||
9, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
0, /* has sup protos */
|
||||
NULL, /* no sub protos */
|
||||
1, /* has constants */
|
||||
( &(const bvalue[15]) { /* constants */
|
||||
( &(const bvalue[17]) { /* constants */
|
||||
/* K0 */ be_nested_string("init", 380752755, 4),
|
||||
/* K1 */ be_nested_string("set_style_local_bg_color", -498263023, 24),
|
||||
/* K2 */ be_nested_string("lv", 1529997255, 2),
|
||||
/* K3 */ be_nested_string("OBJ_PART_MAIN", 658062838, 13),
|
||||
/* K4 */ be_nested_string("STATE_DEFAULT", 712406428, 13),
|
||||
/* K5 */ be_nested_string("lv_color", 1419148319, 8),
|
||||
/* K6 */ be_nested_string("COLOR_BLACK", 264427940, 11),
|
||||
/* K7 */ be_nested_string("get_height", -723211773, 10),
|
||||
/* K8 */ be_nested_string("get_style_pad_right", -1144679830, 19),
|
||||
/* K9 */ be_nested_string("set_height", 1080207399, 10),
|
||||
/* K10 */ be_nested_string("set_width", 484671920, 9),
|
||||
/* K11 */ be_nested_string("set_x", 1849400772, 5),
|
||||
/* K12 */ be_nested_string("get_width", -1001549996, 9),
|
||||
/* K13 */ be_nested_string("set_style_local_pad_right", 1126712366, 25),
|
||||
/* K14 */ be_const_int(1),
|
||||
/* K1 */ be_nested_string("set_style_line_color", -629728320, 20),
|
||||
/* K2 */ be_nested_string("lv_color", 1419148319, 8),
|
||||
/* K3 */ be_nested_string("lv", 1529997255, 2),
|
||||
/* K4 */ be_nested_string("COLOR_WHITE", -1758096026, 11),
|
||||
/* K5 */ be_nested_string("PART_MAIN", -1821475788, 9),
|
||||
/* K6 */ be_nested_string("STATE_DEFAULT", 712406428, 13),
|
||||
/* K7 */ be_nested_string("set_style_bg_color", 1689513089, 18),
|
||||
/* K8 */ be_nested_string("COLOR_BLACK", 264427940, 11),
|
||||
/* K9 */ be_nested_string("get_height", -723211773, 10),
|
||||
/* K10 */ be_nested_string("get_style_pad_right", -1144679830, 19),
|
||||
/* K11 */ be_nested_string("set_height", 1080207399, 10),
|
||||
/* K12 */ be_nested_string("set_width", 484671920, 9),
|
||||
/* K13 */ be_nested_string("set_x", 1849400772, 5),
|
||||
/* K14 */ be_nested_string("get_width", -1001549996, 9),
|
||||
/* K15 */ be_nested_string("set_style_pad_right", -980898242, 19),
|
||||
/* K16 */ be_const_int(1),
|
||||
}),
|
||||
(be_nested_const_str("init", 380752755, 4)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[49]) { /* code */
|
||||
0x600C0003, // 0000 GETGBL R3 G3
|
||||
0x5C100000, // 0001 MOVE R4 R0
|
||||
0x7C0C0200, // 0002 CALL R3 1
|
||||
0x8C0C0700, // 0003 GETMET R3 R3 K0
|
||||
0x5C140200, // 0004 MOVE R5 R1
|
||||
0x5C180400, // 0005 MOVE R6 R2
|
||||
0x7C0C0600, // 0006 CALL R3 3
|
||||
0x8C0C0101, // 0007 GETMET R3 R0 K1
|
||||
0xB8160400, // 0008 GETNGBL R5 K2
|
||||
0x88140B03, // 0009 GETMBR R5 R5 K3
|
||||
0xB81A0400, // 000A GETNGBL R6 K2
|
||||
0x88180D04, // 000B GETMBR R6 R6 K4
|
||||
0xB81E0A00, // 000C GETNGBL R7 K5
|
||||
0xB8220400, // 000D GETNGBL R8 K2
|
||||
0x88201106, // 000E GETMBR R8 R8 K6
|
||||
0x7C1C0200, // 000F CALL R7 1
|
||||
0x7C0C0800, // 0010 CALL R3 4
|
||||
0x4C0C0000, // 0011 LDNIL R3
|
||||
0x200C0203, // 0012 NE R3 R1 R3
|
||||
0x780E001B, // 0013 JMPF R3 #0030
|
||||
0x8C0C0307, // 0014 GETMET R3 R1 K7
|
||||
0x7C0C0200, // 0015 CALL R3 1
|
||||
0x8C100308, // 0016 GETMET R4 R1 K8
|
||||
0xB81A0400, // 0017 GETNGBL R6 K2
|
||||
0x88180D03, // 0018 GETMBR R6 R6 K3
|
||||
0xB81E0400, // 0019 GETNGBL R7 K2
|
||||
0x881C0F04, // 001A GETMBR R7 R7 K4
|
||||
0x7C100600, // 001B CALL R4 3
|
||||
0x8C140109, // 001C GETMET R5 R0 K9
|
||||
0x5C1C0600, // 001D MOVE R7 R3
|
||||
0x7C140400, // 001E CALL R5 2
|
||||
0x8C14010A, // 001F GETMET R5 R0 K10
|
||||
0x5C1C0600, // 0020 MOVE R7 R3
|
||||
0x7C140400, // 0021 CALL R5 2
|
||||
0x8C14010B, // 0022 GETMET R5 R0 K11
|
||||
0x8C1C030C, // 0023 GETMET R7 R1 K12
|
||||
0x7C1C0200, // 0024 CALL R7 1
|
||||
0x041C0E03, // 0025 SUB R7 R7 R3
|
||||
0x041C0E04, // 0026 SUB R7 R7 R4
|
||||
0x7C140400, // 0027 CALL R5 2
|
||||
0x8C14030D, // 0028 GETMET R5 R1 K13
|
||||
0xB81E0400, // 0029 GETNGBL R7 K2
|
||||
0x881C0F03, // 002A GETMBR R7 R7 K3
|
||||
0xB8220400, // 002B GETNGBL R8 K2
|
||||
0x88201104, // 002C GETMBR R8 R8 K4
|
||||
0x00240803, // 002D ADD R9 R4 R3
|
||||
0x0024130E, // 002E ADD R9 R9 K14
|
||||
0x7C140800, // 002F CALL R5 4
|
||||
0x80000000, // 0030 RET 0
|
||||
( &(const binstruction[62]) { /* code */
|
||||
0x60080003, // 0000 GETGBL R2 G3
|
||||
0x5C0C0000, // 0001 MOVE R3 R0
|
||||
0x7C080200, // 0002 CALL R2 1
|
||||
0x8C080500, // 0003 GETMET R2 R2 K0
|
||||
0x5C100200, // 0004 MOVE R4 R1
|
||||
0x7C080400, // 0005 CALL R2 2
|
||||
0x8C080101, // 0006 GETMET R2 R0 K1
|
||||
0xB8120400, // 0007 GETNGBL R4 K2
|
||||
0xB8160600, // 0008 GETNGBL R5 K3
|
||||
0x88140B04, // 0009 GETMBR R5 R5 K4
|
||||
0x7C100200, // 000A CALL R4 1
|
||||
0xB8160600, // 000B GETNGBL R5 K3
|
||||
0x88140B05, // 000C GETMBR R5 R5 K5
|
||||
0xB81A0600, // 000D GETNGBL R6 K3
|
||||
0x88180D06, // 000E GETMBR R6 R6 K6
|
||||
0x30140A06, // 000F OR R5 R5 R6
|
||||
0x7C080600, // 0010 CALL R2 3
|
||||
0x8C080107, // 0011 GETMET R2 R0 K7
|
||||
0xB8120400, // 0012 GETNGBL R4 K2
|
||||
0xB8160600, // 0013 GETNGBL R5 K3
|
||||
0x88140B08, // 0014 GETMBR R5 R5 K8
|
||||
0x7C100200, // 0015 CALL R4 1
|
||||
0xB8160600, // 0016 GETNGBL R5 K3
|
||||
0x88140B05, // 0017 GETMBR R5 R5 K5
|
||||
0xB81A0600, // 0018 GETNGBL R6 K3
|
||||
0x88180D06, // 0019 GETMBR R6 R6 K6
|
||||
0x30140A06, // 001A OR R5 R5 R6
|
||||
0x7C080600, // 001B CALL R2 3
|
||||
0x4C080000, // 001C LDNIL R2
|
||||
0x20080202, // 001D NE R2 R1 R2
|
||||
0x780A001D, // 001E JMPF R2 #003D
|
||||
0x8C080309, // 001F GETMET R2 R1 K9
|
||||
0x7C080200, // 0020 CALL R2 1
|
||||
0x8C0C030A, // 0021 GETMET R3 R1 K10
|
||||
0xB8160600, // 0022 GETNGBL R5 K3
|
||||
0x88140B05, // 0023 GETMBR R5 R5 K5
|
||||
0xB81A0600, // 0024 GETNGBL R6 K3
|
||||
0x88180D06, // 0025 GETMBR R6 R6 K6
|
||||
0x30140A06, // 0026 OR R5 R5 R6
|
||||
0x7C0C0400, // 0027 CALL R3 2
|
||||
0x8C10010B, // 0028 GETMET R4 R0 K11
|
||||
0x5C180400, // 0029 MOVE R6 R2
|
||||
0x7C100400, // 002A CALL R4 2
|
||||
0x8C10010C, // 002B GETMET R4 R0 K12
|
||||
0x5C180400, // 002C MOVE R6 R2
|
||||
0x7C100400, // 002D CALL R4 2
|
||||
0x8C10010D, // 002E GETMET R4 R0 K13
|
||||
0x8C18030E, // 002F GETMET R6 R1 K14
|
||||
0x7C180200, // 0030 CALL R6 1
|
||||
0x04180C02, // 0031 SUB R6 R6 R2
|
||||
0x04180C03, // 0032 SUB R6 R6 R3
|
||||
0x7C100400, // 0033 CALL R4 2
|
||||
0x8C10030F, // 0034 GETMET R4 R1 K15
|
||||
0x00180602, // 0035 ADD R6 R3 R2
|
||||
0x00180D10, // 0036 ADD R6 R6 K16
|
||||
0xB81E0600, // 0037 GETNGBL R7 K3
|
||||
0x881C0F05, // 0038 GETMBR R7 R7 K5
|
||||
0xB8220600, // 0039 GETNGBL R8 K3
|
||||
0x88201106, // 003A GETMBR R8 R8 K6
|
||||
0x301C0E08, // 003B OR R7 R7 R8
|
||||
0x7C100600, // 003C CALL R4 3
|
||||
0x80000000, // 003D RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
|
@ -66,8 +66,8 @@ be_local_closure(every_second, /* name */
|
||||
********************************************************************/
|
||||
be_local_closure(init, /* name */
|
||||
be_nested_proto(
|
||||
7, /* nstack */
|
||||
3, /* argc */
|
||||
5, /* nstack */
|
||||
2, /* argc */
|
||||
0, /* varg */
|
||||
0, /* has upvals */
|
||||
NULL, /* no upvals */
|
||||
@ -83,22 +83,21 @@ be_local_closure(init, /* name */
|
||||
}),
|
||||
(be_nested_const_str("init", 380752755, 4)),
|
||||
(be_nested_const_str("input", -103256197, 5)),
|
||||
( &(const binstruction[15]) { /* code */
|
||||
0x600C0003, // 0000 GETGBL R3 G3
|
||||
0x5C100000, // 0001 MOVE R4 R0
|
||||
0x7C0C0200, // 0002 CALL R3 1
|
||||
0x8C0C0700, // 0003 GETMET R3 R3 K0
|
||||
0x5C140200, // 0004 MOVE R5 R1
|
||||
0x5C180400, // 0005 MOVE R6 R2
|
||||
0x7C0C0600, // 0006 CALL R3 3
|
||||
0xB80E0200, // 0007 GETNGBL R3 K1
|
||||
0x8C0C0702, // 0008 GETMET R3 R3 K2
|
||||
0x5C140000, // 0009 MOVE R5 R0
|
||||
0x7C0C0400, // 000A CALL R3 2
|
||||
0x8C0C0103, // 000B GETMET R3 R0 K3
|
||||
0x58140004, // 000C LDCONST R5 K4
|
||||
0x7C0C0400, // 000D CALL R3 2
|
||||
0x80000000, // 000E RET 0
|
||||
( &(const binstruction[14]) { /* code */
|
||||
0x60080003, // 0000 GETGBL R2 G3
|
||||
0x5C0C0000, // 0001 MOVE R3 R0
|
||||
0x7C080200, // 0002 CALL R2 1
|
||||
0x8C080500, // 0003 GETMET R2 R2 K0
|
||||
0x5C100200, // 0004 MOVE R4 R1
|
||||
0x7C080400, // 0005 CALL R2 2
|
||||
0xB80A0200, // 0006 GETNGBL R2 K1
|
||||
0x8C080502, // 0007 GETMET R2 R2 K2
|
||||
0x5C100000, // 0008 MOVE R4 R0
|
||||
0x7C080400, // 0009 CALL R2 2
|
||||
0x8C080103, // 000A GETMET R2 R0 K3
|
||||
0x58100004, // 000B LDCONST R4 K4
|
||||
0x7C080400, // 000C CALL R2 2
|
||||
0x80000000, // 000D RET 0
|
||||
})
|
||||
)
|
||||
);
|
||||
|
@ -125,9 +125,8 @@ extern void be_load_driver_audio_lib(bvm *vm);
|
||||
extern void be_load_lvgl_color_lib(bvm *vm);
|
||||
extern void be_load_lvgl_font_lib(bvm *vm);
|
||||
extern void be_load_lv_all_lib(bvm *vm);
|
||||
extern void be_load_lvgl_cb_lib(bvm *vm);
|
||||
extern void be_load_lvgl_cb_all_lib(bvm *vm);
|
||||
extern void be_load_ctypes_lvgl_definitions_lib(bvm *vm);
|
||||
extern void be_load_LVGL_glob_class(bvm *vm);
|
||||
// custom widgets
|
||||
extern void be_load_lv_signal_bars_class(bvm *vm);
|
||||
extern void be_load_lv_wifi_bars_class(bvm *vm);
|
||||
@ -179,9 +178,8 @@ BERRY_API void be_load_custom_libs(bvm *vm)
|
||||
be_load_lvgl_font_lib(vm);
|
||||
|
||||
be_load_lv_all_lib(vm);
|
||||
be_load_lvgl_cb_lib(vm);
|
||||
be_load_lvgl_cb_all_lib(vm);
|
||||
be_load_ctypes_lvgl_definitions_lib(vm);
|
||||
be_load_LVGL_glob_class(vm);
|
||||
// custom widgets
|
||||
be_load_lv_signal_bars_class(vm);
|
||||
be_load_lv_wifi_bars_class(vm);
|
||||
|
@ -8,20 +8,21 @@ class lv_clock_icon: lv_label
|
||||
def init(parent, copy)
|
||||
super(self).init(parent, copy)
|
||||
var f_s7_16 = lv.seg7_font(16)
|
||||
if f_s7_16 != nil self.set_style_local_text_font(lv.OBJ_PART_MAIN, lv.STATE_DEFAULT, f_s7_16) end
|
||||
if f_s7_16 != nil self.set_style_text_font(f_s7_16, lv.PART_MAIN | lv.STATE_DEFAULT) end
|
||||
|
||||
if parent != nil
|
||||
var parent_height = parent.get_height()
|
||||
|
||||
self.set_text("--:--")
|
||||
self.refr_size()
|
||||
var w = self.get_width()
|
||||
self.set_y((parent.get_height() - self.get_height()) / 2) # center vertically
|
||||
|
||||
var pad_right = parent.get_style_pad_right(lv.OBJ_PART_MAIN, lv.STATE_DEFAULT)
|
||||
var pad_right = parent.get_style_pad_right(lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
self.set_x(parent.get_width() - w - pad_right - 3)
|
||||
parent.set_style_local_pad_right(lv.OBJ_PART_MAIN, lv.STATE_DEFAULT, pad_right + w + 6)
|
||||
parent.set_style_pad_right(pad_right + w + 6, lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
|
||||
self.set_style_local_bg_color(lv.OBJ_PART_MAIN, lv.STATE_DEFAULT, lv_color(lv.COLOR_BLACK))
|
||||
self.set_style_bg_color(lv_color(lv.COLOR_BLACK), lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
end
|
||||
|
||||
tasmota.add_driver(self)
|
||||
|
@ -3,16 +3,12 @@
|
||||
--#
|
||||
|
||||
class lv_signal_arcs : lv_obj
|
||||
var ancestor_design # previous design_cb
|
||||
var percentage # value to display, range 0..100
|
||||
var p1, p2, area, line_dsc # instances of objects kept to avoid re-instanciating at each call
|
||||
|
||||
def init(parent, copy)
|
||||
# init parent object
|
||||
super(self).init(parent, copy)
|
||||
# keep a copy of
|
||||
self.ancestor_design = self.get_design_cb()
|
||||
self.set_design_cb(self.my_design_cb)
|
||||
def init(parent)
|
||||
# init custom widget (don't call super constructor)
|
||||
_lvgl.create_custom_widget(self, parent)
|
||||
# own values
|
||||
self.percentage = 100
|
||||
# pre-allocate buffers
|
||||
@ -22,7 +18,11 @@ class lv_signal_arcs : lv_obj
|
||||
self.line_dsc = lv_draw_line_dsc()
|
||||
end
|
||||
|
||||
def my_design_cb(clip_area, mode)
|
||||
def widget_event(cl, event)
|
||||
# Call the ancestor's event handler
|
||||
if lv.obj_event_base(cl, event) != lv.RES_OK return end
|
||||
var code = event.code
|
||||
|
||||
import math
|
||||
def atleast1(x) if x >= 1 return x else return 1 end end
|
||||
# the model is that we have 4 bars and inter-bar (1/4 of width)
|
||||
@ -33,25 +33,23 @@ class lv_signal_arcs : lv_obj
|
||||
var bar = atleast1((height - inter_bar * 2) / 3)
|
||||
var bar_offset = bar / 2
|
||||
#print("inter_bar", inter_bar, "bar", bar, "bar_offset", bar_offset)
|
||||
if mode == lv.DESIGN_COVER_CHK
|
||||
#- Return false if the object is not covers the clip_area clip_area -#
|
||||
return self.ancestor_design.call(self, clip_area, mode)
|
||||
|
||||
elif mode == lv.DESIGN_DRAW_MAIN
|
||||
#self.ancestor_design.call(self, clip_area, mode) # commented since we don't draw a background
|
||||
if code == lv.EVENT_DRAW_MAIN
|
||||
var clip_area = lv_area(event.param)
|
||||
|
||||
# get coordinates of object
|
||||
self.get_coords(self.area)
|
||||
var x_ofs = self.area.x1
|
||||
var y_ofs = self.area.y1
|
||||
lv.draw_line_dsc_init(self.line_dsc) # initialize lv_draw_line_dsc structure
|
||||
self.init_draw_line_dsc(lv.OBJ_PART_MAIN, self.line_dsc) # copy the current values
|
||||
|
||||
lv.draw_line_dsc_init(self.line_dsc) # initialize lv_draw_line_dsc structure
|
||||
self.init_draw_line_dsc(lv.PART_MAIN, self.line_dsc) # copy the current values
|
||||
|
||||
self.line_dsc.round_start = 1
|
||||
self.line_dsc.round_end = 1
|
||||
self.line_dsc.width = (bar * 3 + 1) / 4
|
||||
var on_color = self.get_style_line_color(lv.OBJ_PART_MAIN, lv.STATE_DEFAULT)
|
||||
var off_color = self.get_style_bg_color(lv.OBJ_PART_MAIN, lv.STATE_DEFAULT)
|
||||
var on_color = self.get_style_line_color(lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
var off_color = self.get_style_bg_color(lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
|
||||
# initial calculation, but does not take into account bounding box
|
||||
# var angle = int(math.deg(math.atan2(width / 2, height)))
|
||||
@ -76,15 +74,14 @@ class lv_signal_arcs : lv_obj
|
||||
#elif mode == lv.DESIGN_DRAW_POST # commented since we don't want a frame around this object
|
||||
# self.ancestor_design.call(self, clip_area, mode)
|
||||
end
|
||||
return lv.DESIGN_RES_OK
|
||||
end
|
||||
|
||||
def set_percentage(v)
|
||||
var old_bars = self.percentage / 4
|
||||
var old_bars = self.percentage / 25
|
||||
if v > 100 v = 100 end
|
||||
if v < 0 v = 0 end
|
||||
self.percentage = v
|
||||
if old_bars != v / 4
|
||||
if old_bars != v / 25
|
||||
self.invalidate() # be frugal and avoid updating the widget if it's not needed
|
||||
end
|
||||
end
|
||||
@ -95,8 +92,8 @@ class lv_signal_arcs : lv_obj
|
||||
end
|
||||
|
||||
class lv_wifi_arcs: lv_signal_arcs
|
||||
def init(parent, copy)
|
||||
super(self).init(parent, copy)
|
||||
def init(parent)
|
||||
super(self).init(parent)
|
||||
tasmota.add_driver(self)
|
||||
self.set_percentage(0) # we generally start with 0, meaning not connected
|
||||
end
|
||||
@ -119,17 +116,18 @@ class lv_wifi_arcs: lv_signal_arcs
|
||||
end
|
||||
|
||||
class lv_wifi_arcs_icon: lv_wifi_arcs
|
||||
def init(parent, copy)
|
||||
super(self).init(parent, copy)
|
||||
self.set_style_local_bg_color(lv.OBJ_PART_MAIN, lv.STATE_DEFAULT, lv_color(lv.COLOR_BLACK))
|
||||
def init(parent)
|
||||
super(self).init(parent)
|
||||
self.set_style_line_color(lv_color(lv.COLOR_WHITE), lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
self.set_style_bg_color(lv_color(lv.COLOR_BLACK), lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
if parent != nil
|
||||
var parent_height = parent.get_height()
|
||||
var pad_right = parent.get_style_pad_right(lv.OBJ_PART_MAIN, lv.STATE_DEFAULT)
|
||||
var pad_right = parent.get_style_pad_right(lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
self.set_height(parent_height)
|
||||
var w = (parent_height*4)/3
|
||||
self.set_width(w) # 130%
|
||||
self.set_x(parent.get_width() - w - pad_right)
|
||||
parent.set_style_local_pad_right(lv.OBJ_PART_MAIN, lv.STATE_DEFAULT, pad_right + w + 1)
|
||||
parent.set_style_pad_right(pad_right + w + 1, lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
end
|
||||
end
|
||||
end
|
@ -3,16 +3,12 @@
|
||||
--#
|
||||
|
||||
class lv_signal_bars : lv_obj
|
||||
var ancestor_design # previous design_cb
|
||||
var percentage # value to display, range 0..100
|
||||
var p1, p2, area, line_dsc # instances of objects kept to avoid re-instanciating at each call
|
||||
|
||||
def init(parent, copy)
|
||||
# init parent object
|
||||
super(self).init(parent, copy)
|
||||
# keep a copy of
|
||||
self.ancestor_design = self.get_design_cb()
|
||||
self.set_design_cb(self.my_design_cb)
|
||||
def init(parent)
|
||||
# init custom widget (don't call super constructor)
|
||||
_lvgl.create_custom_widget(self, parent)
|
||||
# own values
|
||||
self.percentage = 100
|
||||
# pre-allocate buffers
|
||||
@ -22,7 +18,11 @@ class lv_signal_bars : lv_obj
|
||||
self.line_dsc = lv_draw_line_dsc()
|
||||
end
|
||||
|
||||
def my_design_cb(clip_area, mode)
|
||||
def widget_event(cl, event)
|
||||
# Call the ancestor's event handler
|
||||
if lv.obj_event_base(cl, event) != lv.RES_OK return end
|
||||
var code = event.code
|
||||
|
||||
def atleast1(x) if x >= 1 return x else return 1 end end
|
||||
# the model is that we have 4 bars and inter-bar (1/4 of width)
|
||||
var height = self.get_height()
|
||||
@ -32,27 +32,24 @@ class lv_signal_bars : lv_obj
|
||||
var bar = atleast1((width - inter_bar * 3) / 4)
|
||||
var bar_offset = bar / 2
|
||||
|
||||
if mode == lv.DESIGN_COVER_CHK
|
||||
#- Return false if the object is not covers the clip_area clip_area -#
|
||||
return self.ancestor_design.call(self, clip_area, mode)
|
||||
if code == lv.EVENT_DRAW_MAIN
|
||||
var clip_area = lv_area(event.param)
|
||||
|
||||
elif mode == lv.DESIGN_DRAW_MAIN
|
||||
#self.ancestor_design.call(self, clip_area, mode) # commented since we don't draw a background
|
||||
|
||||
# get coordinates of object
|
||||
self.get_coords(self.area)
|
||||
var x_ofs = self.area.x1
|
||||
var y_ofs = self.area.y1
|
||||
|
||||
lv.draw_line_dsc_init(self.line_dsc) # initialize lv_draw_line_dsc structure
|
||||
self.init_draw_line_dsc(lv.OBJ_PART_MAIN, self.line_dsc)
|
||||
lv.draw_line_dsc_init(self.line_dsc) # initialize lv_draw_line_dsc structure
|
||||
self.init_draw_line_dsc(lv.PART_MAIN, self.line_dsc) # copy the current values
|
||||
|
||||
self.line_dsc.round_start = 1
|
||||
self.line_dsc.round_end = 1
|
||||
self.line_dsc.width = bar
|
||||
var on_color = self.get_style_line_color(lv.OBJ_PART_MAIN, lv.STATE_DEFAULT)
|
||||
var off_color = self.get_style_bg_color(lv.OBJ_PART_MAIN, lv.STATE_DEFAULT)
|
||||
var on_color = self.get_style_line_color(lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
var off_color = self.get_style_bg_color(lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
|
||||
lv.event_send(self, lv.EVENT_DRAW_PART_BEGIN, self.line_dsc)
|
||||
for i:0..3 # 4 bars
|
||||
self.line_dsc.color = self.percentage >= (i+1)*20 ? on_color : off_color
|
||||
self.p1.y = y_ofs + height - 1 - bar_offset
|
||||
@ -61,18 +58,16 @@ class lv_signal_bars : lv_obj
|
||||
self.p2.x = self.p1.x
|
||||
lv.draw_line(self.p1, self.p2, clip_area, self.line_dsc)
|
||||
end
|
||||
#elif mode == lv.DESIGN_DRAW_POST # commented since we don't want a frame around this object
|
||||
#self.ancestor_design.call(self, clip_area, mode)
|
||||
lv.event_send(self, lv.EVENT_DRAW_PART_END, self.line_dsc)
|
||||
end
|
||||
return lv.DESIGN_RES_OK
|
||||
end
|
||||
|
||||
def set_percentage(v)
|
||||
var old_bars = self.percentage / 5
|
||||
var old_bars = self.percentage / 20
|
||||
if v > 100 v = 100 end
|
||||
if v < 0 v = 0 end
|
||||
self.percentage = v
|
||||
if old_bars != v / 5
|
||||
if old_bars != v / 20
|
||||
self.invalidate() # be frugal and avoid updating the widget if it's not needed
|
||||
end
|
||||
end
|
||||
@ -83,8 +78,8 @@ class lv_signal_bars : lv_obj
|
||||
end
|
||||
|
||||
class lv_wifi_bars: lv_signal_bars
|
||||
def init(parent, copy)
|
||||
super(self).init(parent, copy)
|
||||
def init(parent)
|
||||
super(self).init(parent)
|
||||
tasmota.add_driver(self)
|
||||
self.set_percentage(0) # we generally start with 0, meaning not connected
|
||||
end
|
||||
@ -107,16 +102,17 @@ class lv_wifi_bars: lv_signal_bars
|
||||
end
|
||||
|
||||
class lv_wifi_bars_icon: lv_wifi_bars
|
||||
def init(parent, copy)
|
||||
super(self).init(parent, copy)
|
||||
self.set_style_local_bg_color(lv.OBJ_PART_MAIN, lv.STATE_DEFAULT, lv_color(lv.COLOR_BLACK))
|
||||
def init(parent)
|
||||
super(self).init(parent)
|
||||
self.set_style_line_color(lv_color(lv.COLOR_WHITE), lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
self.set_style_bg_color(lv_color(lv.COLOR_BLACK), lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
if parent != nil
|
||||
var parent_height = parent.get_height()
|
||||
var pad_right = parent.get_style_pad_right(lv.OBJ_PART_MAIN, lv.STATE_DEFAULT)
|
||||
var pad_right = parent.get_style_pad_right(lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
self.set_height(parent_height)
|
||||
self.set_width(parent_height)
|
||||
self.set_x(parent.get_width() - parent_height - pad_right)
|
||||
parent.set_style_local_pad_right(lv.OBJ_PART_MAIN, lv.STATE_DEFAULT, pad_right + parent_height + 1)
|
||||
parent.set_style_pad_right(pad_right + parent_height + 1, lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
257
lib/libesp32/Berry/default/embedded/lvgl_glob.be
Normal file
257
lib/libesp32/Berry/default/embedded/lvgl_glob.be
Normal file
@ -0,0 +1,257 @@
|
||||
#- embedded class for LVGL globals -#
|
||||
|
||||
#- This class stores all globals used by LVGL and cannot be stored in the solidified module -#
|
||||
#- this limits the globals to a single value '_lvgl' -#
|
||||
class LVGL_glob
|
||||
# all variables are lazily initialized to reduce the memory pressure. Until they are used, they consume zero memory
|
||||
var cb_obj # map between a native C pointer (as int) and the corresponding lv_* berry object, also helps marking the objects as non-gc-able
|
||||
var cb_event_closure # mapping for event closures per LVGL native pointer (int)
|
||||
var event_cb # native callback for lv_event
|
||||
|
||||
#- below are native callbacks mapped to a closure to a method of this instance -#
|
||||
var null_cb # cb called if type is not supported
|
||||
var widget_ctor_cb
|
||||
var widget_dtor_cb
|
||||
var widget_event_cb
|
||||
|
||||
var widget_struct_default
|
||||
var widget_struct_by_class
|
||||
|
||||
#- this is the fallback callback, if the event is unknown or unsupported -#
|
||||
static cb_do_nothing = def() print("LVG: call to unsupported callback") end
|
||||
|
||||
#- register an lv_* object in the mapping -#
|
||||
def register_obj(obj)
|
||||
if self.cb_obj == nil self.cb_obj = {} end
|
||||
var native_ptr = int(obj._p)
|
||||
self.cb_obj[native_ptr] = obj
|
||||
end
|
||||
|
||||
def get_object_from_ptr(ptr)
|
||||
if self.cb_obj != nil
|
||||
return self.cb_obj.find(ptr) # raise an exception if something is wrong
|
||||
end
|
||||
end
|
||||
|
||||
def lvgl_event_dispatch(event_ptr)
|
||||
import introspect
|
||||
|
||||
var event = lv_event(introspect.toptr(event_ptr))
|
||||
|
||||
var target = event.target
|
||||
var f = self.cb_event_closure[target]
|
||||
var obj = self.get_object_from_ptr(target)
|
||||
#print('>> lvgl_event_dispatch', f, obj, event)
|
||||
f(obj, event)
|
||||
end
|
||||
|
||||
def gen_cb(name, f, obj, ptr)
|
||||
#print('>> gen_cb', name, obj, ptr)
|
||||
# record the object, whatever the callback
|
||||
|
||||
if name == "lv_event_cb"
|
||||
if self.cb_event_closure == nil self.cb_event_closure = {} end
|
||||
if self.event_cb == nil self.event_cb = tasmota.gen_cb(/ event_ptr -> self.lvgl_event_dispatch(event_ptr)) end # encapsulate 'self' in closure
|
||||
|
||||
self.register_obj(obj)
|
||||
self.cb_event_closure[ptr] = f
|
||||
return self.event_cb
|
||||
# elif name == "<other_cb>"
|
||||
else
|
||||
if self.null_cb == nil self.null_cb = tasmota.gen_cb(self.cb_do_nothing) end
|
||||
return self.null_cb
|
||||
end
|
||||
end
|
||||
|
||||
def widget_ctor_impl(cl_ptr, obj_ptr)
|
||||
import introspect
|
||||
var cl = lv_obj_class(cl_ptr)
|
||||
var obj = self.get_object_from_ptr(obj_ptr)
|
||||
if self.cb_obj.find(obj) obj = self.cb_obj[obj] end
|
||||
# print("widget_ctor_impl", cl, obj)
|
||||
if type(obj) == 'instance' && introspect.get(obj, 'widget_constructor')
|
||||
obj.widget_constructor(cl)
|
||||
end
|
||||
end
|
||||
def widget_dtor_impl(cl_ptr, obj_ptr)
|
||||
import introspect
|
||||
var cl = lv_obj_class(cl_ptr)
|
||||
var obj = self.get_object_from_ptr(obj_ptr)
|
||||
# print("widget_dtor_impl", cl, obj)
|
||||
if type(obj) == 'instance' && introspect.get(obj, 'widget_destructor')
|
||||
obj.widget_destructor(cl)
|
||||
end
|
||||
end
|
||||
def widget_event_impl(cl_ptr, e_ptr)
|
||||
import introspect
|
||||
var cl = lv_obj_class(cl_ptr)
|
||||
var event = lv_event(e_ptr)
|
||||
var obj_ptr = event.target
|
||||
var obj = self.get_object_from_ptr(int(obj_ptr))
|
||||
if type(obj) == 'instance' && introspect.get(obj, 'widget_event')
|
||||
obj.widget_event(cl, event)
|
||||
end
|
||||
# print("widget_event_impl", cl, obj_ptr, obj, event)
|
||||
end
|
||||
|
||||
|
||||
def widget_cb()
|
||||
if self.widget_ctor_cb == nil self.widget_ctor_cb = tasmota.gen_cb(/ cl, obj -> self.widget_ctor_impl(cl, obj)) end
|
||||
if self.widget_dtor_cb == nil self.widget_dtor_cb = tasmota.gen_cb(/ cl, obj -> self.widget_dtor_impl(cl, obj)) end
|
||||
if self.widget_event_cb == nil self.widget_event_cb = tasmota.gen_cb(/ cl, e -> self.widget_event_impl(cl, e)) end
|
||||
|
||||
if self.widget_struct_default == nil
|
||||
self.widget_struct_default = lv_obj_class(lv_obj._class).copy()
|
||||
self.widget_struct_default.base_class = lv_obj._class # by default, inherit from base class `lv_obj`, this can be overriden
|
||||
self.widget_struct_default.constructor_cb = self.widget_ctor_cb # set the berry cb dispatchers
|
||||
self.widget_struct_default.destructor_cb = self.widget_dtor_cb
|
||||
self.widget_struct_default.event_cb = self.widget_event_cb
|
||||
end
|
||||
end
|
||||
|
||||
#- deregister_obj all information linked to a specific LVGL native object (int) -#
|
||||
def deregister_obj(obj)
|
||||
if self.cb_obj != nil self.cb_obj.remove(obj) end
|
||||
if self.cb_event_closure != nil self.cb_event_closure.remove(obj) end
|
||||
end
|
||||
|
||||
#- initialize a custom widget -#
|
||||
#- arg must be a subclass of lv_obj -#
|
||||
def create_custom_widget(obj, parent)
|
||||
import introspect
|
||||
|
||||
if !isinstance(obj, lv_obj) raise "value_error", "arg must be a subclass of lv_obj" end
|
||||
if self.widget_struct_by_class == nil self.widget_struct_by_class = {} end
|
||||
|
||||
var obj_classname = classname(obj)
|
||||
var obj_class_struct = self.widget_struct_by_class.find(obj_classname)
|
||||
# print("classname=",obj_classname,"_class",super(obj)._class)
|
||||
#- not already built, create a new one for this class -#
|
||||
if obj_class_struct == nil
|
||||
self.widget_cb() # set up all structures
|
||||
obj_class_struct = self.widget_struct_default.copy() # get a copy of the structure with pre-defined callbacks
|
||||
obj_class_struct.base_class = super(obj)._class
|
||||
if introspect.get(obj, 'widget_width_def') obj_class_struct.width_def = obj.widget_width_def end
|
||||
if introspect.get(obj, 'widget_height_def') obj_class_struct.height_def = obj.widget_height_def end
|
||||
if introspect.get(obj, 'widget_editable') obj_class_struct.editable = obj.widget_editable end
|
||||
if introspect.get(obj, 'widget_group_def') obj_class_struct.group_def = obj.widget_group_def end
|
||||
if introspect.get(obj, 'widget_instance_size') obj_class_struct.instance_size = obj.widget_instance_size end
|
||||
|
||||
#- keep a copy of the structure to avoid GC and reuse if needed -#
|
||||
self.widget_struct_by_class[obj_classname] = obj_class_struct
|
||||
end
|
||||
|
||||
var lv_obj_ptr = lv.obj_class_create_obj(obj_class_struct, parent)
|
||||
obj._p = lv_obj_ptr._p
|
||||
self.register_obj(obj)
|
||||
obj.class_init_obj()
|
||||
end
|
||||
end
|
||||
|
||||
_lvgl = LVGL_glob()
|
||||
|
||||
# class lv_custom_widget : lv_obj
|
||||
# # static widget_width_def
|
||||
# # static widget_height_def
|
||||
# # static widget_editable
|
||||
# # static widget_group_def
|
||||
# # static widget_instance_size
|
||||
# #
|
||||
# var percentage # value to display, range 0..100
|
||||
# var p1, p2, area, line_dsc # instances of objects kept to avoid re-instanciating at each call
|
||||
|
||||
# def init(parent)
|
||||
# _lvgl.create_custom_widget(self, parent)
|
||||
# # own values
|
||||
# self.percentage = 100
|
||||
# # pre-allocate buffers
|
||||
# self.p1 = lv_point()
|
||||
# self.p2 = lv_point()
|
||||
# self.area = lv_area()
|
||||
# self.line_dsc = lv_draw_line_dsc()
|
||||
# end
|
||||
|
||||
# # def widget_constructor(cl)
|
||||
# # print("widget_constructor", cl)
|
||||
# # end
|
||||
|
||||
# # def widget_destructor(cl)
|
||||
# # print("widget_destructor", cl)
|
||||
# # end
|
||||
|
||||
# def widget_event(cl, event)
|
||||
# var res = lv.obj_event_base(cl, event)
|
||||
# if res != lv.RES_OK return end
|
||||
|
||||
# def atleast1(x) if x >= 1 return x else return 1 end end
|
||||
# # the model is that we have 4 bars and inter-bar (1/4 of width)
|
||||
# var height = self.get_height()
|
||||
# var width = self.get_width()
|
||||
|
||||
# var inter_bar = atleast1(width / 15)
|
||||
# var bar = atleast1((width - inter_bar * 3) / 4)
|
||||
# var bar_offset = bar / 2
|
||||
|
||||
# var code = event.code
|
||||
# if code == lv.EVENT_DRAW_MAIN
|
||||
# var clip_area = lv_area(event.param)
|
||||
# print("widget_event DRAW", clip_area.tomap())
|
||||
# # lv.event_send(self, lv.EVENT_DRAW_MAIN, clip_area)
|
||||
|
||||
# # get coordinates of object
|
||||
# self.get_coords(self.area)
|
||||
# var x_ofs = self.area.x1
|
||||
# var y_ofs = self.area.y1
|
||||
|
||||
# lv.draw_line_dsc_init(self.line_dsc) # initialize lv_draw_line_dsc structure
|
||||
# self.init_draw_line_dsc(lv.PART_MAIN, self.line_dsc)
|
||||
|
||||
# self.line_dsc.round_start = 1
|
||||
# self.line_dsc.round_end = 1
|
||||
# self.line_dsc.width = bar
|
||||
|
||||
# var on_color = self.get_style_line_color(lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
# var off_color = self.get_style_bg_color(lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
|
||||
# lv.event_send(self, lv.EVENT_DRAW_PART_BEGIN, self.line_dsc)
|
||||
# for i:0..3 # 4 bars
|
||||
# self.line_dsc.color = self.percentage >= (i+1)*20 ? on_color : off_color
|
||||
# self.p1.y = y_ofs + height - 1 - bar_offset
|
||||
# self.p1.x = x_ofs + i * (bar + inter_bar) + bar_offset
|
||||
# self.p2.y = y_ofs + ((3 - i) * (height - bar)) / 4 + bar_offset
|
||||
# self.p2.x = self.p1.x
|
||||
# lv.draw_line(self.p1, self.p2, clip_area, self.line_dsc)
|
||||
# end
|
||||
# lv.event_send(self, lv.EVENT_DRAW_PART_END, self.line_dsc)
|
||||
|
||||
# end
|
||||
# end
|
||||
|
||||
# def set_percentage(v)
|
||||
# var old_bars = self.percentage / 5
|
||||
# if v > 100 v = 100 end
|
||||
# if v < 0 v = 0 end
|
||||
# self.percentage = v
|
||||
# if old_bars != v / 5
|
||||
# self.invalidate() # be frugal and avoid updating the widget if it's not needed
|
||||
# end
|
||||
# end
|
||||
|
||||
# def get_percentage()
|
||||
# return self.percentage
|
||||
# end
|
||||
# end
|
||||
|
||||
# ########## ########## ########## ########## ########## ########## ########## ##########
|
||||
|
||||
# lv.start()
|
||||
|
||||
# hres = lv.get_hor_res() # should be 320
|
||||
# vres = lv.get_ver_res() # should be 240
|
||||
|
||||
# scr = lv.scr_act() # default screean object
|
||||
# f20 = lv.montserrat_font(20) # load embedded Montserrat 20
|
||||
|
||||
# scr.set_style_bg_color(lv_color(0x0000A0), lv.PART_MAIN | lv.STATE_DEFAULT)
|
||||
|
||||
# w = lv_custom_widget(scr)
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_arc_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_arc_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_arc_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_arc_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_arc_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_bar_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_bar_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_bar_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_bar_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_bar_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_btn_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_btn_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_btn_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_btn_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_btn_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_btnmatrix_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_btnmatrix_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_btnmatrix_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_btnmatrix_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_btnmatrix_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,20 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_calendar_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_calendar_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_calendar_map,
|
||||
4
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_class_lv_calendar,
|
||||
1,
|
||||
(bclass *)&be_class_lv_obj,
|
||||
lv_calendar
|
||||
);
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_canvas_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_canvas_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_canvas_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_canvas_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_canvas_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_chart_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_chart_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_chart_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_chart_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_chart_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_checkbox_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_checkbox_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_checkbox_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_checkbox_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_checkbox_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,10 +1,10 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_color_map) {
|
||||
{ be_const_key(init, -1), be_const_func(lco_init) },
|
||||
{ be_const_key(tostring, 2), be_const_func(lco_tostring) },
|
||||
{ be_const_key(toint, -1), be_const_func(lco_toint) },
|
||||
{ be_const_key(dot_p, 0), be_const_var(0) },
|
||||
{ be_const_key(tostring, 0), be_const_func(lco_tostring) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, -1), be_const_func(lco_init) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
|
@ -0,0 +1,21 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_colorwheel_map) {
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_colorwheel_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_colorwheel_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_colorwheel_map,
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_class_lv_colorwheel,
|
||||
1,
|
||||
(bclass *)&be_class_lv_obj,
|
||||
lv_colorwheel
|
||||
);
|
@ -1,20 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_cont_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_cont_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_cont_map,
|
||||
4
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_class_lv_cont,
|
||||
1,
|
||||
(bclass *)&be_class_lv_obj,
|
||||
lv_cont
|
||||
);
|
@ -1,20 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_cpicker_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_cpicker_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_cpicker_map,
|
||||
4
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_class_lv_cpicker,
|
||||
1,
|
||||
(bclass *)&be_class_lv_obj,
|
||||
lv_cpicker
|
||||
);
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_dropdown_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_dropdown_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_dropdown_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_dropdown_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_dropdown_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,9 +1,9 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_font_map) {
|
||||
{ be_const_key(init, -1), be_const_func(lvx_init) },
|
||||
{ be_const_key(tostring, 2), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, -1), be_const_func(lvbe_font_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
|
@ -1,20 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_gauge_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_gauge_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_gauge_map,
|
||||
4
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_class_lv_gauge,
|
||||
1,
|
||||
(bclass *)&be_class_lv_obj,
|
||||
lv_gauge
|
||||
);
|
@ -1,9 +1,9 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_group_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_group_create) },
|
||||
{ be_const_key(init, -1), be_const_func(lvbe_group_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
};
|
||||
|
||||
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_img_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_img_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_img_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_img_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_img_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_imgbtn_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_imgbtn_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_imgbtn_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_imgbtn_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_imgbtn_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,9 +1,9 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_indev_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lv0_init) },
|
||||
{ be_const_key(init, -1), be_const_func(lv0_init) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
};
|
||||
|
||||
|
@ -1,20 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_keyboard_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_keyboard_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_keyboard_map,
|
||||
4
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_class_lv_keyboard,
|
||||
1,
|
||||
(bclass *)&be_class_lv_obj,
|
||||
lv_keyboard
|
||||
);
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_label_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_label_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_label_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_label_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_label_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_led_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_led_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_led_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_led_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_led_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_line_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_line_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_line_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_line_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_line_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,20 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_linemeter_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_linemeter_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_linemeter_map,
|
||||
4
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_class_lv_linemeter,
|
||||
1,
|
||||
(bclass *)&be_class_lv_obj,
|
||||
lv_linemeter
|
||||
);
|
@ -1,20 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_list_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_list_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_list_map,
|
||||
4
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_class_lv_list,
|
||||
1,
|
||||
(bclass *)&be_class_lv_obj,
|
||||
lv_list
|
||||
);
|
21
lib/libesp32/Berry/generate/be_fixed_be_class_lv_meter.h
Normal file
21
lib/libesp32/Berry/generate/be_fixed_be_class_lv_meter.h
Normal file
@ -0,0 +1,21 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_meter_map) {
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_meter_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_meter_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_meter_map,
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_class_lv_meter,
|
||||
1,
|
||||
(bclass *)&be_class_lv_obj,
|
||||
lv_meter
|
||||
);
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_msgbox_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_msgbox_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_msgbox_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_msgbox_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_msgbox_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_obj_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_obj_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_obj_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_obj_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_obj_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,20 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_objmask_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_objmask_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_objmask_map,
|
||||
4
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_class_lv_objmask,
|
||||
1,
|
||||
(bclass *)&be_class_lv_obj,
|
||||
lv_objmask
|
||||
);
|
@ -1,20 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_page_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_page_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_page_map,
|
||||
4
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_class_lv_page,
|
||||
1,
|
||||
(bclass *)&be_class_lv_obj,
|
||||
lv_page
|
||||
);
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_roller_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_roller_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_roller_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_roller_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_roller_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_slider_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_slider_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_slider_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_slider_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_slider_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_spinbox_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_spinbox_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_spinbox_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_spinbox_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_spinbox_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,20 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_spinner_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_spinner_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_spinner_map,
|
||||
4
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_class_lv_spinner,
|
||||
1,
|
||||
(bclass *)&be_class_lv_obj,
|
||||
lv_spinner
|
||||
);
|
@ -1,9 +1,9 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_style_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvs_init) },
|
||||
{ be_const_key(init, -1), be_const_func(lvs_init) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvs_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
};
|
||||
|
||||
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_switch_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_switch_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_switch_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_switch_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_switch_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_table_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_table_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_table_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_table_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_table_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,20 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_tabview_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_tabview_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_tabview_map,
|
||||
4
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_class_lv_tabview,
|
||||
1,
|
||||
(bclass *)&be_class_lv_obj,
|
||||
lv_tabview
|
||||
);
|
@ -1,15 +1,16 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_textarea_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_textarea_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
{ be_const_key(tostring, 3), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(member, -1), be_const_func(lvx_member) },
|
||||
{ be_const_key(_p, -1), be_const_var(0) },
|
||||
{ be_const_key(init, 4), be_const_func(lvbe_textarea_create) },
|
||||
{ be_const_key(_class, -1), be_const_int(&lv_textarea_class) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_textarea_map,
|
||||
4
|
||||
5
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
|
@ -1,20 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_tileview_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_tileview_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_tileview_map,
|
||||
4
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_class_lv_tileview,
|
||||
1,
|
||||
(bclass *)&be_class_lv_obj,
|
||||
lv_tileview
|
||||
);
|
@ -1,20 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_class_lv_win_map) {
|
||||
{ be_const_key(init, 2), be_const_func(lvbe_win_create) },
|
||||
{ be_const_key(tostring, -1), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(member, 0), be_const_func(lvx_member) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_class_lv_win_map,
|
||||
4
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_class_lv_win,
|
||||
1,
|
||||
(bclass *)&be_class_lv_obj,
|
||||
lv_win
|
||||
);
|
@ -1,17 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_lv_design_cb_map) {
|
||||
{ be_const_key(call, -1), be_const_func(lv_design_cb_call) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_lv_design_cb_map,
|
||||
1
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_lv_design_cb,
|
||||
0,
|
||||
(bclass *)&be_lvgl_cb,
|
||||
lv_design_cb
|
||||
);
|
@ -1,17 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_lv_event_cb_map) {
|
||||
{ be_const_key(call, -1), be_const_func(lv_event_cb_call) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_lv_event_cb_map,
|
||||
1
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_lv_event_cb,
|
||||
0,
|
||||
(bclass *)&be_lvgl_cb,
|
||||
lv_event_cb
|
||||
);
|
@ -1,17 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_lv_gauge_format_cb_map) {
|
||||
{ be_const_key(call, -1), be_const_func(lv_gauge_format_cb_call) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_lv_gauge_format_cb_map,
|
||||
1
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_lv_gauge_format_cb,
|
||||
0,
|
||||
(bclass *)&be_lvgl_cb,
|
||||
lv_gauge_format_cb
|
||||
);
|
@ -1,17 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_lv_group_focus_cb_map) {
|
||||
{ be_const_key(call, -1), be_const_func(lv_group_focus_cb_call) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_lv_group_focus_cb_map,
|
||||
1
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_lv_group_focus_cb,
|
||||
0,
|
||||
(bclass *)&be_lvgl_cb,
|
||||
lv_group_focus_cb
|
||||
);
|
@ -1,17 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_lv_signal_cb_map) {
|
||||
{ be_const_key(call, -1), be_const_func(lv_signal_cb_call) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_lv_signal_cb_map,
|
||||
1
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_lv_signal_cb,
|
||||
0,
|
||||
(bclass *)&be_lvgl_cb,
|
||||
lv_signal_cb
|
||||
);
|
@ -1,20 +0,0 @@
|
||||
#include "be_constobj.h"
|
||||
|
||||
static be_define_const_map_slots(be_lvgl_cb_map) {
|
||||
{ be_const_key(dot_p, -1), be_const_var(0) },
|
||||
{ be_const_key(tostring, 2), be_const_func(lvx_tostring) },
|
||||
{ be_const_key(call, -1), be_const_func(lv_cb_call) },
|
||||
{ be_const_key(init, 0), be_const_func(lv0_init) },
|
||||
};
|
||||
|
||||
static be_define_const_map(
|
||||
be_lvgl_cb_map,
|
||||
4
|
||||
);
|
||||
|
||||
BE_EXPORT_VARIABLE be_define_const_class(
|
||||
be_lvgl_cb,
|
||||
1,
|
||||
NULL,
|
||||
lv_cb
|
||||
);
|
@ -83,7 +83,7 @@ static int m_toptr(bvm *vm)
|
||||
int top = be_top(vm);
|
||||
if (top >= 1) {
|
||||
bvalue *v = be_indexof(vm, 1);
|
||||
if (var_basetype(v) >= BE_GCOBJECT) {
|
||||
if (var_basetype(v) >= BE_FUNCTION || var_type(v) == BE_COMPTR) {
|
||||
be_pushcomptr(vm, var_toobj(v));
|
||||
be_return(vm);
|
||||
} else if (var_type(v) == BE_INT) {
|
||||
@ -126,6 +126,9 @@ be_native_module_attr_table(introspect) {
|
||||
|
||||
be_native_module_function("get", m_findmember),
|
||||
be_native_module_function("set", m_setmember),
|
||||
|
||||
be_native_module_function("toptr", m_toptr),
|
||||
be_native_module_function("fromptr", m_fromptr),
|
||||
};
|
||||
|
||||
be_define_native_module(introspect, NULL);
|
||||
|
@ -1,96 +0,0 @@
|
||||
#- introspect vcall -#
|
||||
import introspect
|
||||
|
||||
#- -#
|
||||
#- witness function dumping first 3 args -#
|
||||
#- -#
|
||||
def f(a,b,c) return [a,b,c] end
|
||||
|
||||
#- simple calls with fixed args -#
|
||||
assert(introspect.vcall(f) == [nil, nil, nil])
|
||||
assert(introspect.vcall(f, 1) == [1, nil, nil])
|
||||
assert(introspect.vcall(f, 1, 2) == [1, 2, nil])
|
||||
assert(introspect.vcall(f, 1, 2, 3, 4) == [1, 2, 3])
|
||||
|
||||
#- call with var args -#
|
||||
assert(introspect.vcall(f, []) == [nil, nil, nil])
|
||||
assert(introspect.vcall(f, [1]) == [1, nil, nil])
|
||||
assert(introspect.vcall(f, [1, 2]) == [1, 2, nil])
|
||||
assert(introspect.vcall(f, [1, 2, 3, 4]) == [1, 2, 3])
|
||||
|
||||
#- mixed args -#
|
||||
assert(introspect.vcall(f, 1, []) == [1, nil, nil])
|
||||
assert(introspect.vcall(f, 1, [2]) == [1, 2, nil])
|
||||
assert(introspect.vcall(f, 1, [2, "foo", 4]) == [1, 2, "foo"])
|
||||
|
||||
#- non terminal list -#
|
||||
assert(introspect.vcall(f, 1, [2, 3, 4], "foo") == [1, [2, 3, 4], "foo"])
|
||||
|
||||
#- -#
|
||||
#- same tests with vararg function -#
|
||||
#- -#
|
||||
def g(a, *b)
|
||||
if size(b) == 0 return [a, nil, nil]
|
||||
elif size(b) == 1 return [a, b[0], nil]
|
||||
elif size(b) > 1 return [a, b[0], b[1]]
|
||||
end
|
||||
end
|
||||
|
||||
#- simple calls with fixed args -#
|
||||
assert(introspect.vcall(g) == [nil, nil, nil])
|
||||
assert(introspect.vcall(g, 1) == [1, nil, nil])
|
||||
assert(introspect.vcall(g, 1, 2) == [1, 2, nil])
|
||||
assert(introspect.vcall(g, 1, 2, 3, 4) == [1, 2, 3])
|
||||
|
||||
#- call with var args -#
|
||||
assert(introspect.vcall(g, []) == [nil, nil, nil])
|
||||
assert(introspect.vcall(g, [1]) == [1, nil, nil])
|
||||
assert(introspect.vcall(g, [1, 2]) == [1, 2, nil])
|
||||
assert(introspect.vcall(g, [1, 2, 3, 4]) == [1, 2, 3])
|
||||
|
||||
#- mixed args -#
|
||||
assert(introspect.vcall(g, 1, []) == [1, nil, nil])
|
||||
assert(introspect.vcall(g, 1, [2]) == [1, 2, nil])
|
||||
assert(introspect.vcall(g, 1, [2, "foo", 4]) == [1, 2, "foo"])
|
||||
|
||||
#- non terminal list -#
|
||||
assert(introspect.vcall(g, 1, [2, 3, 4], "foo") == [1, [2, 3, 4], "foo"])
|
||||
|
||||
#- -#
|
||||
#- test with vararg only -#
|
||||
#- -#
|
||||
def c(*a) return size(a) end
|
||||
|
||||
#- simple calls with fixed args -#
|
||||
assert(introspect.vcall(c) == 0)
|
||||
assert(introspect.vcall(c, 1) == 1)
|
||||
assert(introspect.vcall(c, 1, 2) == 2)
|
||||
assert(introspect.vcall(c, 1, 2, 3, 4) == 4)
|
||||
|
||||
#- call with var args -#
|
||||
assert(introspect.vcall(c, []) == 0)
|
||||
assert(introspect.vcall(c, [1]) == 1)
|
||||
assert(introspect.vcall(c, [1, 2]) == 2)
|
||||
assert(introspect.vcall(c, [1, 2, 3, 4]) == 4)
|
||||
|
||||
#- mixed args -#
|
||||
assert(introspect.vcall(c, 1, []) == 1)
|
||||
assert(introspect.vcall(c, 1, [2]) == 2)
|
||||
assert(introspect.vcall(c, 1, [2, "foo", 4]) == 4)
|
||||
|
||||
#- non terminal list -#
|
||||
assert(introspect.vcall(c, 1, [2, 3, 4], "foo") == 3)
|
||||
|
||||
#- -#
|
||||
#- test with native function -#
|
||||
#- -#
|
||||
import string
|
||||
|
||||
assert(introspect.vcall(string.format, "a") == "a")
|
||||
assert(introspect.vcall(string.format, "%i", 1) == "1")
|
||||
assert(introspect.vcall(string.format, "%i - %i", 1, 2) == "1 - 2")
|
||||
|
||||
assert(introspect.vcall(string.format, "%i - %i", [1, 2]) == "1 - 2")
|
||||
assert(introspect.vcall(string.format, "%i - %i", [1, 2, 3]) == "1 - 2")
|
||||
|
||||
assert(introspect.vcall(string.format, "%i - %i", 1, [1, 2, 3]) == "1 - 1")
|
@ -28,13 +28,13 @@ static void lv_tick_handler(void) { lv_tick_inc(lv_tick_interval_ms); }
|
||||
|
||||
uint32_t Touch_Status(uint32_t sel);
|
||||
|
||||
static bool touchscreen_read(struct _lv_indev_drv_t *indev_drv, lv_indev_data_t *data) {
|
||||
static void touchscreen_read(lv_indev_drv_t *indev_drv, lv_indev_data_t *data) {
|
||||
//lv_coord_t last_x = 0, last_y = 0;
|
||||
//static uint8_t release_count = 0;
|
||||
data->point.x = Touch_Status(1); // Last-pressed coordinates
|
||||
data->point.y = Touch_Status(2);
|
||||
data->state = Touch_Status(0);
|
||||
return false; /*No buffering now so no more data read*/
|
||||
data->state = Touch_Status(0) ? LV_INDEV_STATE_PRESSED : LV_INDEV_STATE_RELEASED;
|
||||
data->continue_reading = false; /*No buffering now so no more data read*/
|
||||
}
|
||||
|
||||
// OTHER LITTLEVGL VITALS --------------------------------------------------
|
||||
@ -231,7 +231,7 @@ LvGLStatus Adafruit_LvGL_Glue::begin(Renderer *tft, void *touch, bool debug) {
|
||||
// LV_HOR_RES_MAX * LV_BUFFER_ROWS);
|
||||
|
||||
// Initialize LvGL display buffers
|
||||
lv_disp_buf_init(
|
||||
lv_disp_draw_buf_init(
|
||||
&lv_disp_buf, lv_pixel_buf, // 1st half buf
|
||||
lv_pixel_buf2, // 2nd half buf
|
||||
lvgl_buffer_size);
|
||||
@ -241,16 +241,16 @@ LvGLStatus Adafruit_LvGL_Glue::begin(Renderer *tft, void *touch, bool debug) {
|
||||
lv_disp_drv.hor_res = tft->width();
|
||||
lv_disp_drv.ver_res = tft->height();
|
||||
lv_disp_drv.flush_cb = lv_flush_callback;
|
||||
lv_disp_drv.buffer = &lv_disp_buf;
|
||||
lv_disp_drv.user_data = (lv_disp_drv_user_data_t)this;
|
||||
lv_disp_drv.draw_buf = &lv_disp_buf;
|
||||
lv_disp_drv.user_data = (void*)this;
|
||||
lv_disp_drv_register(&lv_disp_drv);
|
||||
|
||||
// Initialize LvGL input device (touchscreen already started)
|
||||
if ((touch)) { // Can also pass NULL if passive widget display
|
||||
if (touch) { // Can also pass NULL if passive widget display
|
||||
lv_indev_drv_init(&lv_indev_drv); // Basic init
|
||||
lv_indev_drv.type = LV_INDEV_TYPE_POINTER; // Is pointer dev
|
||||
lv_indev_drv.read_cb = touchscreen_read; // Read callback
|
||||
lv_indev_drv.user_data = (lv_indev_drv_user_data_t)this;
|
||||
lv_indev_drv.user_data = (void*)this;
|
||||
lv_input_dev_ptr = lv_indev_drv_register(&lv_indev_drv);
|
||||
}
|
||||
|
||||
|
@ -42,7 +42,7 @@ public:
|
||||
|
||||
private:
|
||||
lv_disp_drv_t lv_disp_drv;
|
||||
lv_disp_buf_t lv_disp_buf;
|
||||
lv_disp_draw_buf_t lv_disp_buf;
|
||||
lv_color_t *lv_pixel_buf;
|
||||
lv_color_t *lv_pixel_buf2;
|
||||
lv_indev_drv_t lv_indev_drv;
|
||||
|
@ -1,417 +0,0 @@
|
||||
# Changelog
|
||||
|
||||
## v7.11.0 (Planned for 19.02.2021)
|
||||
|
||||
### New features
|
||||
- Add better screen orientation management with software rotation support
|
||||
- Decide text animation's direction based on base_dir (when using LV_USE_BIDI)
|
||||
|
||||
### Bugfixes
|
||||
- fix(gauge) fix needle invalidation
|
||||
- fix(bar) correct symmetric handling for vertical sliders
|
||||
|
||||
## v7.10.1 (Planned for 16.02.2021)
|
||||
|
||||
### Bugfixes
|
||||
- fix(draw) overlap outline with background to prevent aliasing artifacts
|
||||
- fix(indev) clear the indev's `act_obj` in `lv_indev_reset`
|
||||
- fix(text) fix out of bounds read in `_lv_txt_get_width`
|
||||
- fix(list) scroll list when button is focused using LV_KEY_NEXT/PREV
|
||||
- fix(text) improve Arabic contextual analysis by adding hyphen processing and proper handling of lam-alef sequence
|
||||
- fix(delete) delete animation after the children are deleted
|
||||
- fix(gauge) consider paddigns for needle images
|
||||
|
||||
## v7.10.0
|
||||
|
||||
### New features
|
||||
- feat(indev) allow input events to be passed to disabled objects
|
||||
- feat(spinbox) add inline get_step function for MicroPython support
|
||||
|
||||
### Bugfixes
|
||||
- fix(btnmatrix) fix lv_btnmatrix_get_active_btn_text() when used in a group
|
||||
|
||||
## v7.9.1
|
||||
|
||||
### Bugfixes
|
||||
- fix(cpicker) fix division by zero
|
||||
- fix(dropdown) fix selecting options after the last one
|
||||
- fix(msgbox) use the animation time provided
|
||||
- fix(gpu_nxp_pxp) fix incorrect define name
|
||||
- fix(indev) don't leave edit mode if there is only one object in the group
|
||||
- fix(draw_rect) fix draw pattern stack-use-after-scope error
|
||||
|
||||
|
||||
## v7.9.0
|
||||
|
||||
### New features
|
||||
- feat(chart) add lv_chart_remove_series and lv_chart_hide_series
|
||||
- feat(img_cahce) allow disabling image caching
|
||||
- calendar: make get_day_of_week() public
|
||||
- Added support for Zephyr integration
|
||||
|
||||
### Bugfixes
|
||||
- fix(draw_rect) free buffer used for arabic processing
|
||||
- fix(win) arabic process the title of the window
|
||||
- fix(dropdown) arabic process the option in lv_dropdown_add_option
|
||||
- fix(textarea) buffer overflow in password mode with UTF-8 characters
|
||||
- fix(textarea) cursor position after hiding character in password mode
|
||||
- fix(linemeter) draw critical lines with correct color
|
||||
- fix(kconfig) handle disable sprintf float correctly.
|
||||
- fix(layout) stop layout after recursion threshold is reached
|
||||
- fix(gauge) fix redraw with image needle
|
||||
|
||||
## v7.8.1
|
||||
|
||||
### Bugfixes
|
||||
- fix(lv_scr_load_anim) fix when multiple screen are loaded at tsame time with delay
|
||||
- fix(page) fix LV_SCOLLBAR_MODE_DRAG
|
||||
|
||||
## v7.8.0 (01.12.2020)
|
||||
|
||||
### New features
|
||||
- make DMA2D non blocking
|
||||
- add unscii-16 built-in font
|
||||
- add KConfig
|
||||
- add lv_refr_get_fps_avg()
|
||||
|
||||
### Bugfixes
|
||||
- fix(btnmatrix) handle arabic texts in button matrices
|
||||
- fix(indev) disabled object shouldn't absorb clicks but let the parent to be clicked
|
||||
- fix(arabic) support processing again already processed texts with _lv_txt_ap_proc
|
||||
- fix(textarea) support Arabic letter connections
|
||||
- fix(dropdown) support Arabic letter connections
|
||||
- fix(value_str) support Arabic letter connections in value string property
|
||||
- fix(indev) in LV_INDEV_TYPE_BUTTON recognize 1 cycle long presses too
|
||||
- fix(arc) make arc work with encoder
|
||||
- fix(slider) adjusting the left knob too with encoder
|
||||
- fix reference to LV_DRAW_BUF_MAX_NUM in lv_mem.c
|
||||
- fix(polygon draw) join adjacent points if they are on the same coordinate
|
||||
- fix(linemeter) fix invalidation when setting new value
|
||||
- fix(table) add missing invalidation when changing cell type
|
||||
- refactor(roller) rename LV_ROLLER_MODE_INIFINITE -> LV_ROLLER_MODE_INFINITE
|
||||
|
||||
## v7.7.2 (17.11.2020)
|
||||
### Bugfixes
|
||||
- fix(draw_triangle): fix polygon/triangle drawing when the order of points is counter-clockwise
|
||||
- fix(btnmatrix): fix setting the same map with modified pointers
|
||||
- fix(arc) fix and improve arc dragging
|
||||
- label: Repair calculate back `dot` character logical error which cause infinite loop.
|
||||
- fix(theme_material): remove the bottom border from tabview header
|
||||
- fix(imgbtn) guess a the closest available state with valid src
|
||||
- fix(spinbox) update cursor position in lv_spinbox_set_step
|
||||
|
||||
## v7.7.1 (03.11.2020)
|
||||
### Bugfixes
|
||||
- Respect btnmatrix's `one_check` in `lv_btnmatrix_set_btn_ctrl`
|
||||
- Gauge: make the needle images to use the styles from `LV_GAUGE_PART_PART`
|
||||
- Group: fix in `lv_group_remove_obj` to handle deleting hidden obejcts correctly
|
||||
|
||||
## v7.7.0 (20.10.2020)
|
||||
|
||||
### New features
|
||||
- Add PXP GPU support (for NXP MCUs)
|
||||
- Add VG-Lite GPU support (for NXP MCUs)
|
||||
- Allow max. 16 cell types for table
|
||||
- Add `lv_table_set_text_fmt()`
|
||||
- Use margin on calendar header to set distances and padding to the size of the header
|
||||
- Add `text_sel_bg` style property
|
||||
|
||||
### Bugfixes
|
||||
- Theme update to support text selection background
|
||||
- Fix imgbtn state change
|
||||
- Support RTL in table (draw columns right to left)
|
||||
- Support RTL in pretty layout (draw columns right to left)
|
||||
- Skip objects in groups if they are in disabled state
|
||||
- Fix dropdown selection with RTL basedirection
|
||||
- Fix rectangle border drawing with large width
|
||||
- Fix `lv_win_clean()`
|
||||
|
||||
## v7.6.1 (06.10.2020)
|
||||
|
||||
### Bugfixes
|
||||
- Fix BIDI support in dropdown list
|
||||
- Fix copying base dir in `lv_obj_create`
|
||||
- Handle sub pixel rendering in font loader
|
||||
- Fix transitions with style caching
|
||||
- Fix click focus
|
||||
- Fix imgbtn image switching with empty style
|
||||
- Material theme: do not set the text font to allow easy global font change
|
||||
|
||||
## v7.6.0 (22.09.2020)
|
||||
|
||||
### New features
|
||||
- Check whether any style property has changed on a state change to decide if any redraw is required
|
||||
|
||||
### Bugfixes
|
||||
- Fix selection of options with non-ASCII letters in dropdown list
|
||||
- Fix font loader to support LV_FONT_FMT_TXT_LARGE
|
||||
|
||||
## v7.5.0 (15.09.2020)
|
||||
|
||||
### New features
|
||||
- Add `clean_dcache_cb` and `lv_disp_clean_dcache` to enable users to use their own cache management function
|
||||
- Add `gpu_wait_cb` to wait until the GPU is working. It allows to run CPU a wait only when the rendered data is needed.
|
||||
- Add 10px and 8ox built in fonts
|
||||
|
||||
### Bugfixes
|
||||
- Fix unexpected DEFOCUS on lv_page when clicking to bg after the scrollable
|
||||
- Fix `lv_obj_del` and `lv_obj_clean` if the children list changed during deletion.
|
||||
- Adjust button matrix button width to include padding when spanning multiple units.
|
||||
- Add rounding to btnmatrix line height calculation
|
||||
- Add `decmopr_buf` to GC roots
|
||||
- Fix divisioin by zero in draw_pattern (lv_draw_rect.c) if the image or letter is not found
|
||||
- Fix drawing images with 1 px height or width
|
||||
|
||||
## v7.4.0 (01.09.2020)
|
||||
|
||||
The main new features of v7.4 are run-time font loading, style caching and arc knob with value setting by click.
|
||||
|
||||
### New features
|
||||
- Add `lv_font_load()` function - Loads a `lv_font_t` object from a binary font file
|
||||
- Add `lv_font_free()` function - Frees the memory allocated by the `lv_font_load()` function
|
||||
- Add style caching to reduce access time of properties with default value
|
||||
- arc: add set value by click feature
|
||||
- arc: add `LV_ARC_PART_KNOB` similarly to slider
|
||||
- send gestures event if the object was dragged. User can check dragging with `lv_indev_is_dragging(lv_indev_act())` in the event function.
|
||||
|
||||
### Bugfixes
|
||||
- Fix color bleeding on border drawing
|
||||
- Fix using 'LV_SCROLLBAR_UNHIDE' after 'LV_SCROLLBAR_ON'
|
||||
- Fix croping of last column/row if an image is zoomed
|
||||
- Fix zooming and rotateing mosaic images
|
||||
- Fix deleting tabview with LEFT/RIGHT tab position
|
||||
- Fix btnmatrix to not send event when CLICK_TRIG = true and the cursor slid from a pressed button
|
||||
- Fix roller width if selected text is larger than the normal
|
||||
|
||||
## v7.3.1 (18.08.2020)
|
||||
|
||||
### Bugfixes
|
||||
- Fix drawing value string twice
|
||||
- Rename `lv_chart_clear_serie` to `lv_chart_clear_series` and `lv_obj_align_origo` to `lv_obj_align_mid`
|
||||
- Add linemeter's mirror feature again
|
||||
- Fix text decor (udnerline strikethrough) with older versions of font converter
|
||||
- Fix setting local style property multiple times
|
||||
- Add missing background drawing and radius handling to image button
|
||||
- Allow adding extra label to list buttons
|
||||
- Fix crash if `lv_table_set_col_cnt` is called before `lv_table_set_row_cnt` for the first time
|
||||
- Fix overflow in large image transformations
|
||||
- Limit extra button click area of button matrix's buttons. With large paddings it was counter intuitive. (Gaps are mapped to button when clicked).
|
||||
- Fix `lv_btnmatrix_set_one_check` not forcing exactly one button to be checked
|
||||
- Fix color picker invalidation in rectangle mode
|
||||
- Init disabled days to gray color in calendar
|
||||
|
||||
## v7.3.0 (04.08.2020)
|
||||
|
||||
### New features
|
||||
- Add `lv_task_get_next`
|
||||
- Add `lv_event_send_refresh`, `lv_event_send_refresh_recursive` to easily send `LV_EVENT_REFRESH` to object
|
||||
- Add `lv_tabview_set_tab_name()` function - used to change a tab's name
|
||||
- Add `LV_THEME_MATERIAL_FLAG_NO_TRANSITION` and `LV_THEME_MATERIAL_FLAG_NO_FOCUS` flags
|
||||
- Reduce code size by adding: `LV_USE_FONT_COMPRESSED` and `LV_FONT_USE_SUBPX` and applying some optimization
|
||||
- Add `LV_MEMCPY_MEMSET_STD` to use standard `memcpy` and `memset`
|
||||
|
||||
### Bugfixes
|
||||
- Do not print warning for missing glyph if its height OR width is zero.
|
||||
- Prevent duplicated sending of `LV_EVENT_INSERT` from text area
|
||||
- Tidy outer edges of cpicker widget.
|
||||
- Remove duplicated lines from `lv_tabview_add_tab`
|
||||
- btnmatrix: hadle combined states of buttons (e.g. chacked + disabled)
|
||||
- textarea: fix typo in lv_textarea_set_sscrollbar_mode
|
||||
- gauge: fix image needle drawing
|
||||
- fix using freed memory in _lv_style_list_remove_style
|
||||
|
||||
## v7.2.0 (21.07.2020)
|
||||
|
||||
### New features
|
||||
- Add screen transitions with `lv_scr_load_anim()`
|
||||
- Add display background color, wallpaper and opacity. Shown when the screen is transparent. Can be used with `lv_disp_set_bg_opa/color/image()`.
|
||||
- Add `LV_CALENDAR_WEEK_STARTS_MONDAY`
|
||||
- Add `lv_chart_set_x_start_point()` function - Set the index of the x-axis start point in the data array
|
||||
- Add `lv_chart_set_ext_array()` function - Set an external array of data points to use for the chart
|
||||
- Add `lv_chart_set_point_id()` function - Set an individual point value in the chart series directly based on index
|
||||
- Add `lv_chart_get_x_start_point()` function - Get the current index of the x-axis start point in the data array
|
||||
- Add `lv_chart_get_point_id()` function - Get an individual point value in the chart series directly based on index
|
||||
- Add `ext_buf_assigned` bit field to `lv_chart_series_t` structure - it's true if external buffer is assigned to series
|
||||
- Add `lv_chart_set_series_axis()` to assign series to primary or secondary axis
|
||||
- Add `lv_chart_set_y_range()` to allow setting range of secondary y axis (based on `lv_chart_set_range` but extended with an axis parameter)
|
||||
- Allow setting different font for the selected text in `lv_roller`
|
||||
- Add `theme->apply_cb` to replace `theme->apply_xcb` to make it compatible with the MicroPython binding
|
||||
- Add `lv_theme_set_base()` to allow easy extension of built-in (or any) themes
|
||||
- Add `lv_obj_align_x()` and `lv_obj_align_y()` functions
|
||||
- Add `lv_obj_align_origo_x()` and `lv_obj_align_origo_y()` functions
|
||||
|
||||
### Bugfixes
|
||||
- `tileview` fix navigation when not screen sized
|
||||
- Use 14px font by default to for better compatibility with smaller displays
|
||||
- `linemeter` fix conversation of current value to "level"
|
||||
- Fix drawing on right border
|
||||
- Set the cursor image non clickable by default
|
||||
- Improve mono theme when used with keyboard or encoder
|
||||
|
||||
## v7.1.0 (07.07.2020)
|
||||
|
||||
### New features
|
||||
- Add `focus_parent` attribute to `lv_obj`
|
||||
- Allow using buttons in encoder input device
|
||||
- Add lv_btnmatrix_set/get_align capability
|
||||
- DMA2D: Remove dependency on ST CubeMX HAL
|
||||
- Added `max_used` propriety to `lv_mem_monitor_t` struct
|
||||
- In `lv_init` test if the strings are UTF-8 encoded.
|
||||
- Add `user_data` to themes
|
||||
- Add LV_BIG_ENDIAN_SYSTEM flag to lv_conf.h in order to fix displaying images on big endian systems.
|
||||
- Add inline function lv_checkbox_get_state(const lv_obj_t * cb) to extend the checkbox functionality.
|
||||
- Add inline function lv_checkbox_set_state(const lv_obj_t * cb, lv_btn_state_t state ) to extend the checkbox functionality.
|
||||
|
||||
### Bugfixes
|
||||
- `lv_img` fix invalidation area when angle or zoom changes
|
||||
- Update the style handling to support Big endian MCUs
|
||||
- Change some methods to support big endian hardware.
|
||||
- remove use of c++ keyword 'new' in parameter of function lv_theme_set_base().
|
||||
- Add LV_BIG_ENDIAN_SYSTEM flag to lv_conf.h in order to fix displaying images on big endian systems.
|
||||
- Fix inserting chars in text area in big endian hardware.
|
||||
|
||||
## v7.0.2 (16.06.2020)
|
||||
|
||||
### Bugfixes
|
||||
- `lv_textarea` fix wrong cursor position when clicked after the last character
|
||||
- Change all text related indices from 16-bit to 32-bit integers throughout whole library. #1545
|
||||
- Fix gestures
|
||||
- Do not call `set_px_cb` for transparent pixel
|
||||
- Fix list button focus in material theme
|
||||
- Fix crash when the a text area is cleared with the backspace of a keyboard
|
||||
- Add version number to `lv_conf_template.h`
|
||||
- Add log in true double buffering mode with `set_px_cb`
|
||||
- `lv_dropdown`: fix missing `LV_EVENT_VALUE_CHANGED` event when used with encoder
|
||||
- `lv_tileview`: fix if not the {0;0} tile is created first
|
||||
- `lv_debug`: restructure to allow asserting in from `lv_misc` too
|
||||
- add assert if `_lv_mem_buf_get()` fails
|
||||
- `lv_textarea`: fix character delete in password mode
|
||||
- Update `LV_OPA_MIN` and `LV_OPA_MAX` to widen the opacity processed range
|
||||
- `lv_btnm` fix sending events for hidden buttons
|
||||
- `lv_gaguge` make `lv_gauge_set_angle_offset` offset the labels and needles too
|
||||
- Fix typo in the API `scrllable` -> `scrollable`
|
||||
- `tabview` by default allow auto expanding the page only to right and bottom (#1573)
|
||||
- fix crash when drawing gradient to the same color
|
||||
- chart: fix memory leak
|
||||
- `img`: improve hit test for transformed images
|
||||
|
||||
## v7.0.1 (01.06.2020)
|
||||
|
||||
### Bugfixes
|
||||
- Make the Microptyhon working by adding the required variables as GC_ROOT
|
||||
- Prefix some internal API functions with `_` to reduce the API of LVGL
|
||||
- Fix built-in SimSun CJK font
|
||||
- Fix UTF-8 encoding when `LV_USE_ARABIC_PERSIAN_CHARS` is enabled
|
||||
- Fix DMA2D usage when 32 bit images directly blended
|
||||
- Fix lv_roller in infinite mode when used with encoder
|
||||
- Add `lv_theme_get_color_secondary()`
|
||||
- Add `LV_COLOR_MIX_ROUND_OFS` to adjust color mixing to make it compatible with the GPU
|
||||
- Improve DMA2D blending
|
||||
- Remove memcpy from `lv_ll` (caused issues with some optimization settings)
|
||||
- `lv_chart` fix X tick drawing
|
||||
- Fix vertical dashed line drawing
|
||||
- Some additional minor fixes and formattings
|
||||
|
||||
## v7.0.0 (18.05.2020)
|
||||
|
||||
### Documentation
|
||||
The docs for v7 is available at https://docs.littlevgl.com/v7/en/html/index.html
|
||||
|
||||
### Legal changes
|
||||
|
||||
The name of the project is changed to LVGL and the new website is on https://lvgl.io
|
||||
|
||||
LVGL remains free under the same conditions (MIT license) and a company is created to manage LVGL and offer services.
|
||||
|
||||
### New drawing system
|
||||
Complete rework of LVGL's draw engine to use "masks" for more advanced and higher quality graphical effects.
|
||||
A possible use-case of this system is to remove the overflowing content from the rounded edges.
|
||||
It also allows drawing perfectly anti-aliased circles, lines, and arcs.
|
||||
Internally, the drawings happen by defining masks (such as rounded rectangle, line, angle).
|
||||
When something is drawn the currently active masks can make some pixels transparent.
|
||||
For example, rectangle borders are drawn by using 2 rectangle masks: one mask removes the inner part and another the outer part.
|
||||
|
||||
The API in this regard remained the same but some new functions were added:
|
||||
- `lv_img_set_zoom`: set image object's zoom factor
|
||||
- `lv_img_set_angle`: set image object's angle without using canvas
|
||||
- `lv_img_set_pivot`: set the pivot point of rotation
|
||||
|
||||
The new drawing engine brought new drawing features too. They are highlighted in the "style" section.
|
||||
|
||||
### New style system
|
||||
The old style system is replaced with a new more flexible and lightweighted one.
|
||||
It uses an approach similar to CSS: support cascading styles, inheriting properties and local style properties per object.
|
||||
As part of these updates, a lot of objects were reworked and the APIs have been changed.
|
||||
|
||||
- more shadows options: *offset* and *spread*
|
||||
- gradient stop position to shift the gradient area and horizontal gradient
|
||||
- `LV_BLEND_MODE_NORMAL/ADDITIVE/SUBTRACTIVE` blending modes
|
||||
- *clip corner*: crop the content on the rounded corners
|
||||
- *text underline* and *strikethrough*
|
||||
- dashed vertical and horizontal lines (*dash gap*, *dash_width*)
|
||||
- *outline*: a border-like part drawn out of the background. Can have spacing to the background.
|
||||
- *pattern*: display and image in the middle of the background or repeat it
|
||||
- *value* display a text which is stored in the style. It can be used e.g. as a lighweighted text on buttons too.
|
||||
- *margin*: similar to *padding* but used to keep space outside of the object
|
||||
|
||||
Read the [Style](https://docs.littlevgl.com/v7/en/html/overview/style.html) section of the documentation to learn how the new styles system works.
|
||||
|
||||
### GPU integration
|
||||
To better utilize GPUs, from this version GPU usage can be integrated into LVGL. In `lv_conf.h` any supported GPUs can be enabled with a single configuration option.
|
||||
|
||||
Right now, only ST's DMA2D (Chrom-ART) is integrated. More will in the upcoming releases.
|
||||
|
||||
### Renames
|
||||
The following object types are renamed:
|
||||
- sw -> switch
|
||||
- ta -> textarea
|
||||
- cb -> checkbox
|
||||
- lmeter -> linemeter
|
||||
- mbox -> msgbox
|
||||
- ddlist -> dropdown
|
||||
- btnm -> btnmatrix
|
||||
- kb -> keyboard
|
||||
- preload -> spinner
|
||||
- lv_objx folder -> lv_widgets
|
||||
- LV_FIT_FILL -> LV_FIT_PARENT
|
||||
- LV_FIT_FLOOD -> LV_FLOOD_MAX
|
||||
- LV_LAYOUT_COL_L/M/R -> LV_LAYOUT_COLUMN_LEFT/MID/RIGHT
|
||||
- LV_LAYOUT_ROW_T/M/B -> LV_LAYOUT_ROW_TOP/MID/BOTTOM
|
||||
|
||||
### Reworked and improved object
|
||||
- `dropdown`: Completely reworked. Now creates a separate list when opened and can be dropped to down/up/left/right.
|
||||
- `label`: `body_draw` is removed, instead, if its style has a visible background/border/shadow etc it will be drawn. Padding really makes the object larger (not just virtually as before)
|
||||
- `arc`: can draw bacground too.
|
||||
- `btn`: doesn't store styles for each state because it's done naturally in the new style system.
|
||||
- `calendar`: highlight the pressed datum. The used styles are changed: use `LV_CALENDAR_PART_DATE` normal for normal dates, checked for highlighted, focused for today, pressed for the being pressed. (checked+pressed, focused+pressed also work)
|
||||
- `chart`: only has `LINE` and `COLUMN` types because with new styles all the others can be described. LV_CHART_PART_SERIES sets the style of the series. bg_opa > 0 draws an area in LINE mode. `LV_CHART_PART_SERIES_BG` also added to set a different style for the series area. Padding in `LV_CHART_PART_BG` makes the series area smaller, and it ensures space for axis labels/numbers.
|
||||
- `linemeter`, `gauge`: can have background if the related style properties are set. Padding makes the scale/lines smaller. scale_border_width and scale_end_border_width allow to draw an arc on the outer part of the scale lines.
|
||||
- `gauge`: `lv_gauge_set_needle_img` allows use image as needle
|
||||
- `canvas`: allow drawing to true color alpha and alpha only canvas, add `lv_canvas_blur_hor/ver` and rename `lv_canvas_rotate` to `lv_canvas_transform`
|
||||
- `textarea`: If available in the font use bullet (`U+2022`) character in text area password
|
||||
|
||||
### New object types
|
||||
- `lv_objmask`: masks can be added to it. The children will be masked accordingly.
|
||||
|
||||
### Others
|
||||
- Change the built-in fonts to [Montserrat](https://fonts.google.com/specimen/Montserrat) and add built-in fonts from 12 px to 48 px for every 2nd size.
|
||||
- Add example CJK and Arabic/Persian/Hebrew built-in font
|
||||
- Add ° and "bullet" to the built-in fonts
|
||||
- Add Arabic/Persian script support: change the character according to its position in the text.
|
||||
- Add `playback_time` to animations.
|
||||
- Add `repeat_count` to animations instead of the current "repeat forever".
|
||||
- Replace `LV_LAYOUT_PRETTY` with `LV_LAYOUT_PRETTY_TOP/MID/BOTTOM`
|
||||
|
||||
### Demos
|
||||
- [lv_examples](https://github.com/littlevgl/lv_examples) was reworked and new examples and demos were added
|
||||
|
||||
### New release policy
|
||||
- Maintain this Changelog for every release
|
||||
- Save old major version in new branches. E.g. `release/v6`
|
||||
- Merge new features and fixes directly into `master` and release a patch or minor releases every 2 weeks.
|
||||
|
||||
### Migrating from v6 to v7
|
||||
- First and foremost, create a new `lv_conf.h` based on `lv_conf_template.h`.
|
||||
- To try the new version it suggested using a simulator project and see the examples.
|
||||
- If you have a running project, the most difficult part of the migration is updating to the new style system. Unfortunately, there is no better way than manually updating to the new format.
|
||||
- The other parts are mainly minor renames and refactoring as described above.
|
@ -1,67 +0,0 @@
|
||||
if(ESP_PLATFORM)
|
||||
|
||||
file(GLOB_RECURSE SOURCES src/*.c)
|
||||
|
||||
idf_component_register(SRCS ${SOURCES}
|
||||
INCLUDE_DIRS . src
|
||||
REQUIRES main)
|
||||
|
||||
target_compile_definitions(${COMPONENT_LIB} PUBLIC "-DLV_CONF_INCLUDE_SIMPLE")
|
||||
|
||||
if (CONFIG_LV_MEM_CUSTOM)
|
||||
if (CONFIG_LV_MEM_CUSTOM_ALLOC)
|
||||
target_compile_definitions(${COMPONENT_LIB} PUBLIC "-DLV_MEM_CUSTOM_ALLOC=${CONFIG_LV_MEM_CUSTOM_ALLOC}")
|
||||
endif()
|
||||
|
||||
if (CONFIG_LV_MEM_CUSTOM_FREE)
|
||||
target_compile_definitions(${COMPONENT_LIB} PUBLIC "-DLV_MEM_CUSTOM_FREE=${CONFIG_LV_MEM_CUSTOM_FREE}")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if (CONFIG_LV_TICK_CUSTOM)
|
||||
if (CONFIG_LV_TICK_CUSTOM_SYS_TIME_EXPR)
|
||||
target_compile_definitions(${COMPONENT_LIB} PUBLIC "-DLV_TICK_CUSTOM_SYS_TIME_EXPR=${CONFIG_LV_TICK_CUSTOM_SYS_TIME_EXPR}")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if (CONFIG_LV_USER_DATA_FREE)
|
||||
target_compile_definitions(${COMPONENT_LIB} PUBLIC "-DLV_USER_DATA_FREE=${CONFIG_LV_USER_DATA_FREE}")
|
||||
endif()
|
||||
|
||||
if (CONFIG_LV_ATTRIBUTE_FAST_MEM_USE_IRAM)
|
||||
target_compile_definitions(${COMPONENT_LIB} PUBLIC "-DLV_ATTRIBUTE_FAST_MEM=IRAM_ATTR")
|
||||
endif()
|
||||
|
||||
elseif(ZEPHYR_BASE)
|
||||
|
||||
if(CONFIG_LVGL)
|
||||
|
||||
zephyr_include_directories(${ZEPHYR_BASE}/lib/gui/lvgl)
|
||||
|
||||
target_include_directories(lvgl INTERFACE ${CMAKE_CURRENT_SOURCE_DIR})
|
||||
|
||||
zephyr_compile_definitions(LV_CONF_KCONFIG_EXTERNAL_INCLUDE=<autoconf.h>)
|
||||
|
||||
zephyr_compile_definitions_ifdef(CONFIG_LV_MEM_CUSTOM
|
||||
LV_MEM_CUSTOM_ALLOC=${CONFIG_LV_MEM_CUSTOM_ALLOC}
|
||||
)
|
||||
zephyr_compile_definitions_ifdef(CONFIG_LV_MEM_CUSTOM
|
||||
LV_MEM_CUSTOM_FREE=${CONFIG_LV_MEM_CUSTOM_FREE}
|
||||
)
|
||||
zephyr_compile_definitions_ifdef(CONFIG_LV_TICK_CUSTOM
|
||||
LV_TICK_CUSTOM_SYS_TIME_EXPR=${CONFIG_LV_TICK_CUSTOM_SYS_TIME_EXPR}
|
||||
)
|
||||
|
||||
zephyr_library()
|
||||
|
||||
file(GLOB_RECURSE SOURCES src/*.c)
|
||||
zephyr_library_sources(${SOURCES})
|
||||
|
||||
endif() # CONFIG_LVGL
|
||||
|
||||
else()
|
||||
|
||||
file(GLOB_RECURSE SOURCES src/*.c)
|
||||
add_library(lvgl STATIC ${SOURCES})
|
||||
|
||||
endif()
|
File diff suppressed because it is too large
Load Diff
@ -1,23 +0,0 @@
|
||||
# ESP-IDF component file for make based commands
|
||||
|
||||
COMPONENT_SRCDIRS := .
|
||||
COMPONENT_SRCDIRS += src
|
||||
COMPONENT_SRCDIRS += src/lv_core
|
||||
COMPONENT_SRCDIRS += src/lv_draw
|
||||
COMPONENT_SRCDIRS += src/lv_font
|
||||
COMPONENT_SRCDIRS += src/lv_gpu
|
||||
COMPONENT_SRCDIRS += src/lv_hal
|
||||
COMPONENT_SRCDIRS += src/lv_misc
|
||||
COMPONENT_SRCDIRS += src/lv_themes
|
||||
COMPONENT_SRCDIRS += src/lv_widgets
|
||||
|
||||
COMPONENT_ADD_INCLUDEDIRS := .
|
||||
COMPONENT_ADD_INCLUDEDIRS += src
|
||||
COMPONENT_ADD_INCLUDEDIRS += src/lv_core
|
||||
COMPONENT_ADD_INCLUDEDIRS += src/lv_draw
|
||||
COMPONENT_ADD_INCLUDEDIRS += src/lv_font
|
||||
COMPONENT_ADD_INCLUDEDIRS += src/lv_gpu
|
||||
COMPONENT_ADD_INCLUDEDIRS += src/lv_hal
|
||||
COMPONENT_ADD_INCLUDEDIRS += src/lv_misc
|
||||
COMPONENT_ADD_INCLUDEDIRS += src/lv_themes
|
||||
COMPONENT_ADD_INCLUDEDIRS += src/lv_widgets
|
@ -1,46 +0,0 @@
|
||||
# Contributor Covenant Code of Conduct
|
||||
|
||||
## Our Pledge
|
||||
|
||||
In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation.
|
||||
|
||||
## Our Standards
|
||||
|
||||
Examples of behavior that contributes to creating a positive environment include:
|
||||
|
||||
* Using welcoming and inclusive language
|
||||
* Being respectful of differing viewpoints and experiences
|
||||
* Gracefully accepting constructive criticism
|
||||
* Focusing on what is best for the community
|
||||
* Showing empathy towards other community members
|
||||
|
||||
Examples of unacceptable behavior by participants include:
|
||||
|
||||
* The use of sexualized language or imagery and unwelcome sexual attention or advances
|
||||
* Trolling, insulting/derogatory comments, and personal or political attacks
|
||||
* Public or private harassment
|
||||
* Publishing others' private information, such as a physical or electronic address, without explicit permission
|
||||
* Other conduct which could reasonably be considered inappropriate in a professional setting
|
||||
|
||||
## Our Responsibilities
|
||||
|
||||
Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.
|
||||
|
||||
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.
|
||||
|
||||
## Scope
|
||||
|
||||
This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.
|
||||
|
||||
## Enforcement
|
||||
|
||||
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at [atom@github.com](mailto:atom@github.com). All complaints will be reviewed and investigated and will result in a response that is deemed necessary and appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.
|
||||
|
||||
Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.
|
||||
|
||||
## Attribution
|
||||
|
||||
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at [http://contributor-covenant.org/version/1/4][version]
|
||||
|
||||
[homepage]: http://contributor-covenant.org
|
||||
[version]: http://contributor-covenant.org/version/1/4/
|
@ -1,89 +0,0 @@
|
||||
# Coding style
|
||||
|
||||
## File format
|
||||
Use [lv_misc/lv_templ.c](https://github.com/lvgl/lvgl/blob/master/src/lv_misc/lv_templ.c) and [lv_misc/lv_templ.h](https://github.com/lvgl/lvgl/blob/master/src/lv_misc/lv_templ.h)
|
||||
|
||||
## Naming conventions
|
||||
* Words are separated by '_'
|
||||
* In variable and function names use only lower case letters (e.g. *height_tmp*)
|
||||
* In enums and defines use only upper case letters (e.g. *e.g. MAX_LINE_NUM*)
|
||||
* Global names (API):
|
||||
* starts with *lv*
|
||||
* followed by module name: *btn*, *label*, *style* etc.
|
||||
* followed by the action (for functions): *set*, *get*, *refr* etc.
|
||||
* closed with the subject: *name*, *size*, *state* etc.
|
||||
* Typedefs
|
||||
* prefer `typedef struct` and `typedef enum` instead of `struct name` and `enum name`
|
||||
* always end `typedef struct` and `typedef enum` type names with `_t`
|
||||
* Abbreviations:
|
||||
* Only words longer or equal than 6 characters can be abbreviated.
|
||||
* Abbreviate only if it makes the word at least half as long
|
||||
* Use only very straightforward and well-known abbreviations (e.g. pos: position, def: default, btn: button)
|
||||
|
||||
## Coding guide
|
||||
* Functions:
|
||||
* Try to write function shorter than is 50 lines
|
||||
* Always shorter than 200 lines (except very straightforwards)
|
||||
* Variables:
|
||||
* One line, one declaration (BAD: char x, y;)
|
||||
* Use `<stdint.h>` (*uint8_t*, *int32_t* etc)
|
||||
* Declare variables where needed (not all at function start)
|
||||
* Use the smallest required scope
|
||||
* Variables in a file (outside functions) are always *static*
|
||||
* Do not use global variables (use functions to set/get static variables)
|
||||
|
||||
## Comments
|
||||
Before every function have a comment like this:
|
||||
|
||||
```c
|
||||
/**
|
||||
* Return with the screen of an object
|
||||
* @param obj pointer to an object
|
||||
* @return pointer to a screen
|
||||
*/
|
||||
lv_obj_t * lv_obj_get_scr(lv_obj_t * obj);
|
||||
```
|
||||
|
||||
Always use `/* Something */` format and NOT `//Something`
|
||||
|
||||
Write readable code to avoid descriptive comments like:
|
||||
`x++; /* Add 1 to x */`.
|
||||
The code should show clearly what you are doing.
|
||||
|
||||
You should write **why** have you done this:
|
||||
`x++; /*Because of closing '\0' of the string */`
|
||||
|
||||
Short "code summaries" of a few lines are accepted. E.g. `/*Calculate the new coordinates*/`
|
||||
|
||||
In comments use \` \` when referring to a variable. E.g. ``/*Update the value of `x_act`*/``
|
||||
|
||||
### Formatting
|
||||
Here is example to show bracket placing and using of white spaces:
|
||||
```c
|
||||
/**
|
||||
* Set a new text for a label. Memory will be allocated to store the text by the label.
|
||||
* @param label pointer to a label object
|
||||
* @param text '\0' terminated character string. NULL to refresh with the current text.
|
||||
*/
|
||||
void lv_label_set_text(lv_obj_t * label, const char * text)
|
||||
{ /* Main brackets of functions in new line*/
|
||||
|
||||
if(label == NULL) return; /*No bracket only if the command is inline with the if statement*/
|
||||
|
||||
lv_obj_inv(label);
|
||||
|
||||
lv_label_ext_t * ext = lv_obj_get_ext(label);
|
||||
|
||||
/*Comment before a section */
|
||||
if(text == ext->txt || text == NULL) { /*Bracket of statements start inline*/
|
||||
lv_label_refr_text(label);
|
||||
return;
|
||||
}
|
||||
|
||||
...
|
||||
}
|
||||
```
|
||||
|
||||
Use 4 spaces indentation instead of tab.
|
||||
|
||||
You can use **astyle** to format the code. Run `code-formatter.sh` from the `scrips` folder.
|
@ -1,5 +0,0 @@
|
||||
# Contributing to LVGL
|
||||
|
||||
Thank you for considering contributing to LVGL.
|
||||
|
||||
For a detailed description of contribution opportunities, please visit the [Contributing](https://docs.lvgl.io/latest/en/html/contributing/index.html) section of the documentation.
|
@ -1,63 +0,0 @@
|
||||
# Roadmap
|
||||
|
||||
This is a summary for thenew fatures of the major releases and a collection of ideas.
|
||||
|
||||
This list indicates only the current intention and can be changed.
|
||||
|
||||
## v8
|
||||
Planned to November/December 2020
|
||||
- Create an `lv_components` repository for compley widgets
|
||||
- It makes the core LVGL leaner
|
||||
- In `lv_components` we can have a lot and specific widgets
|
||||
- Good place for contribution
|
||||
- New scrolling:
|
||||
- See [feat/new-scroll](https://github.com/lvgl/lvgl/tree/feat/new-scroll) branch and [#1614](https://github.com/lvgl/lvgl/issues/1614)) issue.
|
||||
- Remove `lv_page` and support scrolling on `lv_obj`
|
||||
- Support "elastic" scrolling when scrolled in
|
||||
- Support scroll chaining among any objects types (not only `lv_pages`s)
|
||||
- Remove `lv_drag`. Similar effect can be achieved by setting the position in `LV_EVENT_PRESSING`
|
||||
- Add snapping
|
||||
- Add snap stop to scroll max 1 snap point
|
||||
- Already working
|
||||
- New layouts:
|
||||
- See [#1615](https://github.com/lvgl/lvgl/issues/1615) issue
|
||||
- [CSS Grid](https://css-tricks.com/snippets/css/a-guide-to-grid/)-like layout support
|
||||
- [CSS Flexbox](https://css-tricks.com/snippets/css/a-guide-to-flexbox/)-like layout support
|
||||
- Remove `lv_cont` and support layouts on `lv_obj`
|
||||
- Simplified File system interface ([feat/new_fs_api](https://github.com/lvgl/lvgl/tree/feat/new-fs-api) branch) to make porting easier
|
||||
- Work in progress
|
||||
- Remove the align parameter from `lv_canvas_draw_text`
|
||||
- Make the copy parameter obsolate in create functions
|
||||
- Optimize and simplifie styles [#1832](https://github.com/lvgl/lvgl/issues/1832)
|
||||
- Use a more generic inheritenace [#1919](https://github.com/lvgl/lvgl/issues/1919)
|
||||
|
||||
## v8.x
|
||||
- Add radio button widget
|
||||
- Unit testing (gtest?). See [#1658](https://github.com/lvgl/lvgl/issues/1658)
|
||||
- Benchmarking (gem5?). See [#1660](https://github.com/lvgl/lvgl/issues/1660)
|
||||
- chart: pre-delete `X` pint after the lastly set
|
||||
- chart: autoscroll to the right
|
||||
|
||||
## v9
|
||||
- Simplify `group`s. Discussion is [here](https://forum.lvgl.io/t/lv-group-tabindex/2927/3).
|
||||
- Consider direct binary font format support
|
||||
- Optimize line and circle drawing and masking
|
||||
- Reconsider color format management for run time color format setting, and custom color format usage. (Also [RGB888](https://github.com/lvgl/lvgl/issues/1722))
|
||||
- 9-patch support for `lv_imgbtn`.
|
||||
- Handle stride. See [#1858](https://github.com/lvgl/lvgl/issues/1858)
|
||||
- Make gradients more versatile
|
||||
- Make image transformations more versatile
|
||||
- Allow snapshoting object to tranfrom them to images
|
||||
|
||||
## Ideas
|
||||
- Use [generate-changelog](https://github.com/lob/generate-changelog) to automatically generate changelog
|
||||
- lv_mem_alloc_aligned(size, align)
|
||||
- Text node. See [#1701](https://github.com/lvgl/lvgl/issues/1701#issuecomment-699479408)
|
||||
- CPP binding. See [Forum](https://forum.lvgl.io/t/is-it-possible-to-officially-support-optional-cpp-api/2736)
|
||||
- Optimize font decompression
|
||||
- Switch to RGBA colors in styles
|
||||
- Need coverage report for tests
|
||||
- Need static analyze (via coverity.io or somehing else)
|
||||
- Support dot_begin and dot_middle long modes for labels
|
||||
- Add new label alignment modes. [#1656](https://github.com/lvgl/lvgl/issues/1656)
|
||||
- Support larger images: [#1892](https://github.com/lvgl/lvgl/issues/1892)
|
@ -1,102 +0,0 @@
|
||||
#include <lvgl.h>
|
||||
#include <TFT_eSPI.h>
|
||||
|
||||
TFT_eSPI tft = TFT_eSPI(); /* TFT instance */
|
||||
static lv_disp_buf_t disp_buf;
|
||||
static lv_color_t buf[LV_HOR_RES_MAX * 10];
|
||||
|
||||
#if USE_LV_LOG != 0
|
||||
/* Serial debugging */
|
||||
void my_print(lv_log_level_t level, const char * file, uint32_t line, const char * dsc)
|
||||
{
|
||||
|
||||
Serial.printf("%s@%d->%s\r\n", file, line, dsc);
|
||||
Serial.flush();
|
||||
}
|
||||
#endif
|
||||
|
||||
/* Display flushing */
|
||||
void my_disp_flush(lv_disp_drv_t *disp, const lv_area_t *area, lv_color_t *color_p)
|
||||
{
|
||||
uint32_t w = (area->x2 - area->x1 + 1);
|
||||
uint32_t h = (area->y2 - area->y1 + 1);
|
||||
|
||||
tft.startWrite();
|
||||
tft.setAddrWindow(area->x1, area->y1, w, h);
|
||||
tft.pushColors(&color_p->full, w * h, true);
|
||||
tft.endWrite();
|
||||
|
||||
lv_disp_flush_ready(disp);
|
||||
}
|
||||
|
||||
/*Read the touchpad*/
|
||||
bool my_touchpad_read(lv_indev_drv_t * indev_driver, lv_indev_data_t * data)
|
||||
{
|
||||
uint16_t touchX, touchY;
|
||||
|
||||
bool touched = tft.getTouch(&touchX, &touchY, 600);
|
||||
|
||||
if(!touched) {
|
||||
data->state = LV_INDEV_STATE_REL;
|
||||
} else {
|
||||
data->state = LV_INDEV_STATE_PR;
|
||||
|
||||
/*Set the coordinates*/
|
||||
data->point.x = touchX;
|
||||
data->point.y = touchY;
|
||||
|
||||
Serial.print("Data x");
|
||||
Serial.println(touchX);
|
||||
|
||||
Serial.print("Data y");
|
||||
Serial.println(touchY);
|
||||
}
|
||||
|
||||
return false; /*Return `false` because we are not buffering and no more data to read*/
|
||||
}
|
||||
|
||||
void setup()
|
||||
{
|
||||
Serial.begin(115200); /* prepare for possible serial debug */
|
||||
|
||||
lv_init();
|
||||
|
||||
#if USE_LV_LOG != 0
|
||||
lv_log_register_print_cb(my_print); /* register print function for debugging */
|
||||
#endif
|
||||
|
||||
tft.begin(); /* TFT init */
|
||||
tft.setRotation(1); /* Landscape orientation */
|
||||
|
||||
uint16_t calData[5] = { 275, 3620, 264, 3532, 1 };
|
||||
tft.setTouch(calData);
|
||||
|
||||
lv_disp_buf_init(&disp_buf, buf, NULL, LV_HOR_RES_MAX * 10);
|
||||
|
||||
/*Initialize the display*/
|
||||
lv_disp_drv_t disp_drv;
|
||||
lv_disp_drv_init(&disp_drv);
|
||||
disp_drv.hor_res = 320;
|
||||
disp_drv.ver_res = 240;
|
||||
disp_drv.flush_cb = my_disp_flush;
|
||||
disp_drv.buffer = &disp_buf;
|
||||
lv_disp_drv_register(&disp_drv);
|
||||
|
||||
/*Initialize the (dummy) input device driver*/
|
||||
lv_indev_drv_t indev_drv;
|
||||
lv_indev_drv_init(&indev_drv);
|
||||
indev_drv.type = LV_INDEV_TYPE_POINTER;
|
||||
indev_drv.read_cb = my_touchpad_read;
|
||||
lv_indev_drv_register(&indev_drv);
|
||||
|
||||
/* Try an example from the lv_examples repository
|
||||
* https://github.com/lvgl/lv_examples*/
|
||||
lv_ex_btn_1();
|
||||
}
|
||||
|
||||
void loop()
|
||||
{
|
||||
|
||||
lv_task_handler(); /* let the GUI do its work */
|
||||
delay(5);
|
||||
}
|
@ -1,196 +0,0 @@
|
||||
/**
|
||||
* @file lv_port_disp_templ.c
|
||||
*
|
||||
*/
|
||||
|
||||
/*Copy this file as "lv_port_disp.c" and set this value to "1" to enable content*/
|
||||
#if 0
|
||||
|
||||
/*********************
|
||||
* INCLUDES
|
||||
*********************/
|
||||
#include "lv_port_disp_template.h"
|
||||
|
||||
/*********************
|
||||
* DEFINES
|
||||
*********************/
|
||||
|
||||
/**********************
|
||||
* TYPEDEFS
|
||||
**********************/
|
||||
|
||||
/**********************
|
||||
* STATIC PROTOTYPES
|
||||
**********************/
|
||||
static void disp_init(void);
|
||||
|
||||
static void disp_flush(lv_disp_drv_t * disp_drv, const lv_area_t * area, lv_color_t * color_p);
|
||||
#if LV_USE_GPU
|
||||
static void gpu_blend(lv_disp_drv_t * disp_drv, lv_color_t * dest, const lv_color_t * src, uint32_t length, lv_opa_t opa);
|
||||
static void gpu_fill(lv_disp_drv_t * disp_drv, lv_color_t * dest_buf, lv_coord_t dest_width,
|
||||
const lv_area_t * fill_area, lv_color_t color);
|
||||
#endif
|
||||
|
||||
/**********************
|
||||
* STATIC VARIABLES
|
||||
**********************/
|
||||
|
||||
/**********************
|
||||
* MACROS
|
||||
**********************/
|
||||
|
||||
/**********************
|
||||
* GLOBAL FUNCTIONS
|
||||
**********************/
|
||||
|
||||
void lv_port_disp_init(void)
|
||||
{
|
||||
/*-------------------------
|
||||
* Initialize your display
|
||||
* -----------------------*/
|
||||
disp_init();
|
||||
|
||||
/*-----------------------------
|
||||
* Create a buffer for drawing
|
||||
*----------------------------*/
|
||||
|
||||
/* LVGL requires a buffer where it internally draws the widgets.
|
||||
* Later this buffer will passed your display drivers `flush_cb` to copy its content to your display.
|
||||
* The buffer has to be greater than 1 display row
|
||||
*
|
||||
* There are three buffering configurations:
|
||||
* 1. Create ONE buffer with some rows:
|
||||
* LVGL will draw the display's content here and writes it to your display
|
||||
*
|
||||
* 2. Create TWO buffer with some rows:
|
||||
* LVGL will draw the display's content to a buffer and writes it your display.
|
||||
* You should use DMA to write the buffer's content to the display.
|
||||
* It will enable LVGL to draw the next part of the screen to the other buffer while
|
||||
* the data is being sent form the first buffer. It makes rendering and flushing parallel.
|
||||
*
|
||||
* 3. Create TWO screen-sized buffer:
|
||||
* Similar to 2) but the buffer have to be screen sized. When LVGL is ready it will give the
|
||||
* whole frame to display. This way you only need to change the frame buffer's address instead of
|
||||
* copying the pixels.
|
||||
* */
|
||||
|
||||
/* Example for 1) */
|
||||
static lv_disp_buf_t draw_buf_dsc_1;
|
||||
static lv_color_t draw_buf_1[LV_HOR_RES_MAX * 10]; /*A buffer for 10 rows*/
|
||||
lv_disp_buf_init(&draw_buf_dsc_1, draw_buf_1, NULL, LV_HOR_RES_MAX * 10); /*Initialize the display buffer*/
|
||||
|
||||
/* Example for 2) */
|
||||
static lv_disp_buf_t draw_buf_dsc_2;
|
||||
static lv_color_t draw_buf_2_1[LV_HOR_RES_MAX * 10]; /*A buffer for 10 rows*/
|
||||
static lv_color_t draw_buf_2_2[LV_HOR_RES_MAX * 10]; /*An other buffer for 10 rows*/
|
||||
lv_disp_buf_init(&draw_buf_dsc_2, draw_buf_2_1, draw_buf_2_2, LV_HOR_RES_MAX * 10); /*Initialize the display buffer*/
|
||||
|
||||
/* Example for 3) */
|
||||
static lv_disp_buf_t draw_buf_dsc_3;
|
||||
static lv_color_t draw_buf_3_1[LV_HOR_RES_MAX * LV_VER_RES_MAX]; /*A screen sized buffer*/
|
||||
static lv_color_t draw_buf_3_2[LV_HOR_RES_MAX * LV_VER_RES_MAX]; /*An other screen sized buffer*/
|
||||
lv_disp_buf_init(&draw_buf_dsc_3, draw_buf_3_1, draw_buf_3_2, LV_HOR_RES_MAX * LV_VER_RES_MAX); /*Initialize the display buffer*/
|
||||
|
||||
/*-----------------------------------
|
||||
* Register the display in LVGL
|
||||
*----------------------------------*/
|
||||
|
||||
lv_disp_drv_t disp_drv; /*Descriptor of a display driver*/
|
||||
lv_disp_drv_init(&disp_drv); /*Basic initialization*/
|
||||
|
||||
/*Set up the functions to access to your display*/
|
||||
|
||||
/*Set the resolution of the display*/
|
||||
disp_drv.hor_res = 480;
|
||||
disp_drv.ver_res = 320;
|
||||
|
||||
/*Used to copy the buffer's content to the display*/
|
||||
disp_drv.flush_cb = disp_flush;
|
||||
|
||||
/*Set a display buffer*/
|
||||
disp_drv.buffer = &draw_buf_dsc_1;
|
||||
|
||||
#if LV_USE_GPU
|
||||
/*Optionally add functions to access the GPU. (Only in buffered mode, LV_VDB_SIZE != 0)*/
|
||||
|
||||
/*Blend two color array using opacity*/
|
||||
disp_drv.gpu_blend_cb = gpu_blend;
|
||||
|
||||
/*Fill a memory array with a color*/
|
||||
disp_drv.gpu_fill_cb = gpu_fill;
|
||||
#endif
|
||||
|
||||
/*Finally register the driver*/
|
||||
lv_disp_drv_register(&disp_drv);
|
||||
}
|
||||
|
||||
/**********************
|
||||
* STATIC FUNCTIONS
|
||||
**********************/
|
||||
|
||||
/* Initialize your display and the required peripherals. */
|
||||
static void disp_init(void)
|
||||
{
|
||||
/*You code here*/
|
||||
}
|
||||
|
||||
/* Flush the content of the internal buffer the specific area on the display
|
||||
* You can use DMA or any hardware acceleration to do this operation in the background but
|
||||
* 'lv_disp_flush_ready()' has to be called when finished. */
|
||||
static void disp_flush(lv_disp_drv_t * disp_drv, const lv_area_t * area, lv_color_t * color_p)
|
||||
{
|
||||
/*The most simple case (but also the slowest) to put all pixels to the screen one-by-one*/
|
||||
|
||||
int32_t x;
|
||||
int32_t y;
|
||||
for(y = area->y1; y <= area->y2; y++) {
|
||||
for(x = area->x1; x <= area->x2; x++) {
|
||||
/* Put a pixel to the display. For example: */
|
||||
/* put_px(x, y, *color_p)*/
|
||||
color_p++;
|
||||
}
|
||||
}
|
||||
|
||||
/* IMPORTANT!!!
|
||||
* Inform the graphics library that you are ready with the flushing*/
|
||||
lv_disp_flush_ready(disp_drv);
|
||||
}
|
||||
|
||||
/*OPTIONAL: GPU INTERFACE*/
|
||||
#if LV_USE_GPU
|
||||
|
||||
/* If your MCU has hardware accelerator (GPU) then you can use it to blend to memories using opacity
|
||||
* It can be used only in buffered mode (LV_VDB_SIZE != 0 in lv_conf.h)*/
|
||||
static void gpu_blend(lv_disp_drv_t * disp_drv, lv_color_t * dest, const lv_color_t * src, uint32_t length, lv_opa_t opa)
|
||||
{
|
||||
/*It's an example code which should be done by your GPU*/
|
||||
uint32_t i;
|
||||
for(i = 0; i < length; i++) {
|
||||
dest[i] = lv_color_mix(dest[i], src[i], opa);
|
||||
}
|
||||
}
|
||||
|
||||
/* If your MCU has hardware accelerator (GPU) then you can use it to fill a memory with a color
|
||||
* It can be used only in buffered mode (LV_VDB_SIZE != 0 in lv_conf.h)*/
|
||||
static void gpu_fill(lv_disp_drv_t * disp_drv, lv_color_t * dest_buf, lv_coord_t dest_width,
|
||||
const lv_area_t * fill_area, lv_color_t color)
|
||||
{
|
||||
/*It's an example code which should be done by your GPU*/
|
||||
int32_t x, y;
|
||||
dest_buf += dest_width * fill_area->y1; /*Go to the first line*/
|
||||
|
||||
for(y = fill_area->y1; y <= fill_area->y2; y++) {
|
||||
for(x = fill_area->x1; x <= fill_area->x2; x++) {
|
||||
dest_buf[x] = color;
|
||||
}
|
||||
dest_buf+=dest_width; /*Go to the next line*/
|
||||
}
|
||||
}
|
||||
|
||||
#endif /*LV_USE_GPU*/
|
||||
|
||||
#else /* Enable this file at the top */
|
||||
|
||||
/* This dummy typedef exists purely to silence -Wpedantic. */
|
||||
typedef int keep_pedantic_happy;
|
||||
#endif
|
@ -1,377 +0,0 @@
|
||||
/**
|
||||
* @file lv_port_fs_templ.c
|
||||
*
|
||||
*/
|
||||
|
||||
/*Copy this file as "lv_port_fs.c" and set this value to "1" to enable content*/
|
||||
#if 0
|
||||
|
||||
/*********************
|
||||
* INCLUDES
|
||||
*********************/
|
||||
#include "lv_port_fs_template.h"
|
||||
|
||||
/*********************
|
||||
* DEFINES
|
||||
*********************/
|
||||
|
||||
/**********************
|
||||
* TYPEDEFS
|
||||
**********************/
|
||||
|
||||
/* Create a type to store the required data about your file.
|
||||
* If you are using a File System library
|
||||
* it already should have a File type.
|
||||
* For example FatFS has `FIL`. In this case use `typedef FIL file_t`*/
|
||||
typedef struct {
|
||||
/*Add the data you need to store about a file*/
|
||||
uint32_t dummy1;
|
||||
uint32_t dummy2;
|
||||
}file_t;
|
||||
|
||||
/*Similarly to `file_t` create a type for directory reading too */
|
||||
typedef struct {
|
||||
/*Add the data you need to store about directory reading*/
|
||||
uint32_t dummy1;
|
||||
uint32_t dummy2;
|
||||
}dir_t;
|
||||
|
||||
/**********************
|
||||
* STATIC PROTOTYPES
|
||||
**********************/
|
||||
static void fs_init(void);
|
||||
|
||||
static lv_fs_res_t fs_open (lv_fs_drv_t * drv, void * file_p, const char * path, lv_fs_mode_t mode);
|
||||
static lv_fs_res_t fs_close (lv_fs_drv_t * drv, void * file_p);
|
||||
static lv_fs_res_t fs_read (lv_fs_drv_t * drv, void * file_p, void * buf, uint32_t btr, uint32_t * br);
|
||||
static lv_fs_res_t fs_write(lv_fs_drv_t * drv, void * file_p, const void * buf, uint32_t btw, uint32_t * bw);
|
||||
static lv_fs_res_t fs_seek (lv_fs_drv_t * drv, void * file_p, uint32_t pos);
|
||||
static lv_fs_res_t fs_size (lv_fs_drv_t * drv, void * file_p, uint32_t * size_p);
|
||||
static lv_fs_res_t fs_tell (lv_fs_drv_t * drv, void * file_p, uint32_t * pos_p);
|
||||
static lv_fs_res_t fs_remove (lv_fs_drv_t * drv, const char *path);
|
||||
static lv_fs_res_t fs_trunc (lv_fs_drv_t * drv, void * file_p);
|
||||
static lv_fs_res_t fs_rename (lv_fs_drv_t * drv, const char * oldname, const char * newname);
|
||||
static lv_fs_res_t fs_free (lv_fs_drv_t * drv, uint32_t * total_p, uint32_t * free_p);
|
||||
static lv_fs_res_t fs_dir_open (lv_fs_drv_t * drv, void * rddir_p, const char *path);
|
||||
static lv_fs_res_t fs_dir_read (lv_fs_drv_t * drv, void * rddir_p, char *fn);
|
||||
static lv_fs_res_t fs_dir_close (lv_fs_drv_t * drv, void * rddir_p);
|
||||
|
||||
/**********************
|
||||
* STATIC VARIABLES
|
||||
**********************/
|
||||
|
||||
/**********************
|
||||
* GLOBAL PROTOTYPES
|
||||
**********************/
|
||||
|
||||
/**********************
|
||||
* MACROS
|
||||
**********************/
|
||||
|
||||
/**********************
|
||||
* GLOBAL FUNCTIONS
|
||||
**********************/
|
||||
|
||||
void lv_port_fs_init(void)
|
||||
{
|
||||
/*----------------------------------------------------
|
||||
* Initialize your storage device and File System
|
||||
* -------------------------------------------------*/
|
||||
fs_init();
|
||||
|
||||
/*---------------------------------------------------
|
||||
* Register the file system interface in LVGL
|
||||
*--------------------------------------------------*/
|
||||
|
||||
/* Add a simple drive to open images */
|
||||
lv_fs_drv_t fs_drv;
|
||||
lv_fs_drv_init(&fs_drv);
|
||||
|
||||
/*Set up fields...*/
|
||||
fs_drv.file_size = sizeof(file_t);
|
||||
fs_drv.letter = 'P';
|
||||
fs_drv.open_cb = fs_open;
|
||||
fs_drv.close_cb = fs_close;
|
||||
fs_drv.read_cb = fs_read;
|
||||
fs_drv.write_cb = fs_write;
|
||||
fs_drv.seek_cb = fs_seek;
|
||||
fs_drv.tell_cb = fs_tell;
|
||||
fs_drv.free_space_cb = fs_free;
|
||||
fs_drv.size_cb = fs_size;
|
||||
fs_drv.remove_cb = fs_remove;
|
||||
fs_drv.rename_cb = fs_rename;
|
||||
fs_drv.trunc_cb = fs_trunc;
|
||||
|
||||
fs_drv.rddir_size = sizeof(dir_t);
|
||||
fs_drv.dir_close_cb = fs_dir_close;
|
||||
fs_drv.dir_open_cb = fs_dir_open;
|
||||
fs_drv.dir_read_cb = fs_dir_read;
|
||||
|
||||
lv_fs_drv_register(&fs_drv);
|
||||
}
|
||||
|
||||
/**********************
|
||||
* STATIC FUNCTIONS
|
||||
**********************/
|
||||
|
||||
/* Initialize your Storage device and File system. */
|
||||
static void fs_init(void)
|
||||
{
|
||||
/*E.g. for FatFS initialize the SD card and FatFS itself*/
|
||||
|
||||
/*You code here*/
|
||||
}
|
||||
|
||||
/**
|
||||
* Open a file
|
||||
* @param drv pointer to a driver where this function belongs
|
||||
* @param file_p pointer to a file_t variable
|
||||
* @param path path to the file beginning with the driver letter (e.g. S:/folder/file.txt)
|
||||
* @param mode read: FS_MODE_RD, write: FS_MODE_WR, both: FS_MODE_RD | FS_MODE_WR
|
||||
* @return LV_FS_RES_OK or any error from lv_fs_res_t enum
|
||||
*/
|
||||
static lv_fs_res_t fs_open (lv_fs_drv_t * drv, void * file_p, const char * path, lv_fs_mode_t mode)
|
||||
{
|
||||
lv_fs_res_t res = LV_FS_RES_NOT_IMP;
|
||||
|
||||
if(mode == LV_FS_MODE_WR)
|
||||
{
|
||||
/*Open a file for write*/
|
||||
|
||||
/* Add your code here*/
|
||||
}
|
||||
else if(mode == LV_FS_MODE_RD)
|
||||
{
|
||||
/*Open a file for read*/
|
||||
|
||||
/* Add your code here*/
|
||||
}
|
||||
else if(mode == (LV_FS_MODE_WR | LV_FS_MODE_RD))
|
||||
{
|
||||
/*Open a file for read and write*/
|
||||
|
||||
/* Add your code here*/
|
||||
}
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
/**
|
||||
* Close an opened file
|
||||
* @param drv pointer to a driver where this function belongs
|
||||
* @param file_p pointer to a file_t variable. (opened with lv_ufs_open)
|
||||
* @return LV_FS_RES_OK: no error, the file is read
|
||||
* any error from lv_fs_res_t enum
|
||||
*/
|
||||
static lv_fs_res_t fs_close (lv_fs_drv_t * drv, void * file_p)
|
||||
{
|
||||
lv_fs_res_t res = LV_FS_RES_NOT_IMP;
|
||||
|
||||
/* Add your code here*/
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
/**
|
||||
* Read data from an opened file
|
||||
* @param drv pointer to a driver where this function belongs
|
||||
* @param file_p pointer to a file_t variable.
|
||||
* @param buf pointer to a memory block where to store the read data
|
||||
* @param btr number of Bytes To Read
|
||||
* @param br the real number of read bytes (Byte Read)
|
||||
* @return LV_FS_RES_OK: no error, the file is read
|
||||
* any error from lv_fs_res_t enum
|
||||
*/
|
||||
static lv_fs_res_t fs_read (lv_fs_drv_t * drv, void * file_p, void * buf, uint32_t btr, uint32_t * br)
|
||||
{
|
||||
lv_fs_res_t res = LV_FS_RES_NOT_IMP;
|
||||
|
||||
/* Add your code here*/
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
/**
|
||||
* Write into a file
|
||||
* @param drv pointer to a driver where this function belongs
|
||||
* @param file_p pointer to a file_t variable
|
||||
* @param buf pointer to a buffer with the bytes to write
|
||||
* @param btr Bytes To Write
|
||||
* @param br the number of real written bytes (Bytes Written). NULL if unused.
|
||||
* @return LV_FS_RES_OK or any error from lv_fs_res_t enum
|
||||
*/
|
||||
static lv_fs_res_t fs_write(lv_fs_drv_t * drv, void * file_p, const void * buf, uint32_t btw, uint32_t * bw)
|
||||
{
|
||||
lv_fs_res_t res = LV_FS_RES_NOT_IMP;
|
||||
|
||||
/* Add your code here*/
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
/**
|
||||
* Set the read write pointer. Also expand the file size if necessary.
|
||||
* @param drv pointer to a driver where this function belongs
|
||||
* @param file_p pointer to a file_t variable. (opened with lv_ufs_open )
|
||||
* @param pos the new position of read write pointer
|
||||
* @return LV_FS_RES_OK: no error, the file is read
|
||||
* any error from lv_fs_res_t enum
|
||||
*/
|
||||
static lv_fs_res_t fs_seek (lv_fs_drv_t * drv, void * file_p, uint32_t pos)
|
||||
{
|
||||
lv_fs_res_t res = LV_FS_RES_NOT_IMP;
|
||||
|
||||
/* Add your code here*/
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
/**
|
||||
* Give the size of a file bytes
|
||||
* @param drv pointer to a driver where this function belongs
|
||||
* @param file_p pointer to a file_t variable
|
||||
* @param size pointer to a variable to store the size
|
||||
* @return LV_FS_RES_OK or any error from lv_fs_res_t enum
|
||||
*/
|
||||
static lv_fs_res_t fs_size (lv_fs_drv_t * drv, void * file_p, uint32_t * size_p)
|
||||
{
|
||||
lv_fs_res_t res = LV_FS_RES_NOT_IMP;
|
||||
|
||||
/* Add your code here*/
|
||||
|
||||
return res;
|
||||
}
|
||||
/**
|
||||
* Give the position of the read write pointer
|
||||
* @param drv pointer to a driver where this function belongs
|
||||
* @param file_p pointer to a file_t variable.
|
||||
* @param pos_p pointer to to store the result
|
||||
* @return LV_FS_RES_OK: no error, the file is read
|
||||
* any error from lv_fs_res_t enum
|
||||
*/
|
||||
static lv_fs_res_t fs_tell (lv_fs_drv_t * drv, void * file_p, uint32_t * pos_p)
|
||||
{
|
||||
lv_fs_res_t res = LV_FS_RES_NOT_IMP;
|
||||
|
||||
/* Add your code here*/
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete a file
|
||||
* @param drv pointer to a driver where this function belongs
|
||||
* @param path path of the file to delete
|
||||
* @return LV_FS_RES_OK or any error from lv_fs_res_t enum
|
||||
*/
|
||||
static lv_fs_res_t fs_remove (lv_fs_drv_t * drv, const char *path)
|
||||
{
|
||||
lv_fs_res_t res = LV_FS_RES_NOT_IMP;
|
||||
|
||||
/* Add your code here*/
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
/**
|
||||
* Truncate the file size to the current position of the read write pointer
|
||||
* @param drv pointer to a driver where this function belongs
|
||||
* @param file_p pointer to an 'ufs_file_t' variable. (opened with lv_fs_open )
|
||||
* @return LV_FS_RES_OK: no error, the file is read
|
||||
* any error from lv_fs_res_t enum
|
||||
*/
|
||||
static lv_fs_res_t fs_trunc (lv_fs_drv_t * drv, void * file_p)
|
||||
{
|
||||
lv_fs_res_t res = LV_FS_RES_NOT_IMP;
|
||||
|
||||
/* Add your code here*/
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
/**
|
||||
* Rename a file
|
||||
* @param drv pointer to a driver where this function belongs
|
||||
* @param oldname path to the file
|
||||
* @param newname path with the new name
|
||||
* @return LV_FS_RES_OK or any error from 'fs_res_t'
|
||||
*/
|
||||
static lv_fs_res_t fs_rename (lv_fs_drv_t * drv, const char * oldname, const char * newname)
|
||||
{
|
||||
lv_fs_res_t res = LV_FS_RES_NOT_IMP;
|
||||
|
||||
/* Add your code here*/
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
/**
|
||||
* Get the free and total size of a driver in kB
|
||||
* @param drv pointer to a driver where this function belongs
|
||||
* @param letter the driver letter
|
||||
* @param total_p pointer to store the total size [kB]
|
||||
* @param free_p pointer to store the free size [kB]
|
||||
* @return LV_FS_RES_OK or any error from lv_fs_res_t enum
|
||||
*/
|
||||
static lv_fs_res_t fs_free (lv_fs_drv_t * drv, uint32_t * total_p, uint32_t * free_p)
|
||||
{
|
||||
lv_fs_res_t res = LV_FS_RES_NOT_IMP;
|
||||
|
||||
/* Add your code here*/
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
/**
|
||||
* Initialize a 'lv_fs_dir_t' variable for directory reading
|
||||
* @param drv pointer to a driver where this function belongs
|
||||
* @param rddir_p pointer to a 'lv_fs_dir_t' variable
|
||||
* @param path path to a directory
|
||||
* @return LV_FS_RES_OK or any error from lv_fs_res_t enum
|
||||
*/
|
||||
static lv_fs_res_t fs_dir_open (lv_fs_drv_t * drv, void * rddir_p, const char *path)
|
||||
{
|
||||
lv_fs_res_t res = LV_FS_RES_NOT_IMP;
|
||||
|
||||
/* Add your code here*/
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
/**
|
||||
* Read the next filename form a directory.
|
||||
* The name of the directories will begin with '/'
|
||||
* @param drv pointer to a driver where this function belongs
|
||||
* @param rddir_p pointer to an initialized 'lv_fs_dir_t' variable
|
||||
* @param fn pointer to a buffer to store the filename
|
||||
* @return LV_FS_RES_OK or any error from lv_fs_res_t enum
|
||||
*/
|
||||
static lv_fs_res_t fs_dir_read (lv_fs_drv_t * drv, void * rddir_p, char *fn)
|
||||
{
|
||||
lv_fs_res_t res = LV_FS_RES_NOT_IMP;
|
||||
|
||||
/* Add your code here*/
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
/**
|
||||
* Close the directory reading
|
||||
* @param drv pointer to a driver where this function belongs
|
||||
* @param rddir_p pointer to an initialized 'lv_fs_dir_t' variable
|
||||
* @return LV_FS_RES_OK or any error from lv_fs_res_t enum
|
||||
*/
|
||||
static lv_fs_res_t fs_dir_close (lv_fs_drv_t * drv, void * rddir_p)
|
||||
{
|
||||
lv_fs_res_t res = LV_FS_RES_NOT_IMP;
|
||||
|
||||
/* Add your code here*/
|
||||
|
||||
return res;
|
||||
}
|
||||
|
||||
#else /* Enable this file at the top */
|
||||
|
||||
/* This dummy typedef exists purely to silence -Wpedantic. */
|
||||
typedef int keep_pedantic_happy;
|
||||
#endif
|
@ -1,423 +0,0 @@
|
||||
/**
|
||||
* @file lv_port_indev_templ.c
|
||||
*
|
||||
*/
|
||||
|
||||
/*Copy this file as "lv_port_indev.c" and set this value to "1" to enable content*/
|
||||
#if 0
|
||||
|
||||
/*********************
|
||||
* INCLUDES
|
||||
*********************/
|
||||
#include "lv_port_indev_template.h"
|
||||
|
||||
/*********************
|
||||
* DEFINES
|
||||
*********************/
|
||||
|
||||
/**********************
|
||||
* TYPEDEFS
|
||||
**********************/
|
||||
|
||||
/**********************
|
||||
* STATIC PROTOTYPES
|
||||
**********************/
|
||||
|
||||
static void touchpad_init(void);
|
||||
static bool touchpad_read(lv_indev_drv_t * indev_drv, lv_indev_data_t * data);
|
||||
static bool touchpad_is_pressed(void);
|
||||
static void touchpad_get_xy(lv_coord_t * x, lv_coord_t * y);
|
||||
|
||||
static void mouse_init(void);
|
||||
static bool mouse_read(lv_indev_drv_t * indev_drv, lv_indev_data_t * data);
|
||||
static bool mouse_is_pressed(void);
|
||||
static void mouse_get_xy(lv_coord_t * x, lv_coord_t * y);
|
||||
|
||||
static void keypad_init(void);
|
||||
static bool keypad_read(lv_indev_drv_t * indev_drv, lv_indev_data_t * data);
|
||||
static uint32_t keypad_get_key(void);
|
||||
|
||||
static void encoder_init(void);
|
||||
static bool encoder_read(lv_indev_drv_t * indev_drv, lv_indev_data_t * data);
|
||||
static void encoder_handler(void);
|
||||
|
||||
static void button_init(void);
|
||||
static bool button_read(lv_indev_drv_t * indev_drv, lv_indev_data_t * data);
|
||||
static int8_t button_get_pressed_id(void);
|
||||
static bool button_is_pressed(uint8_t id);
|
||||
|
||||
/**********************
|
||||
* STATIC VARIABLES
|
||||
**********************/
|
||||
lv_indev_t * indev_touchpad;
|
||||
lv_indev_t * indev_mouse;
|
||||
lv_indev_t * indev_keypad;
|
||||
lv_indev_t * indev_encoder;
|
||||
lv_indev_t * indev_button;
|
||||
|
||||
static int32_t encoder_diff;
|
||||
static lv_indev_state_t encoder_state;
|
||||
|
||||
/**********************
|
||||
* MACROS
|
||||
**********************/
|
||||
|
||||
/**********************
|
||||
* GLOBAL FUNCTIONS
|
||||
**********************/
|
||||
|
||||
void lv_port_indev_init(void)
|
||||
{
|
||||
/* Here you will find example implementation of input devices supported by LittelvGL:
|
||||
* - Touchpad
|
||||
* - Mouse (with cursor support)
|
||||
* - Keypad (supports GUI usage only with key)
|
||||
* - Encoder (supports GUI usage only with: left, right, push)
|
||||
* - Button (external buttons to press points on the screen)
|
||||
*
|
||||
* The `..._read()` function are only examples.
|
||||
* You should shape them according to your hardware
|
||||
*/
|
||||
|
||||
lv_indev_drv_t indev_drv;
|
||||
|
||||
/*------------------
|
||||
* Touchpad
|
||||
* -----------------*/
|
||||
|
||||
/*Initialize your touchpad if you have*/
|
||||
touchpad_init();
|
||||
|
||||
/*Register a touchpad input device*/
|
||||
lv_indev_drv_init(&indev_drv);
|
||||
indev_drv.type = LV_INDEV_TYPE_POINTER;
|
||||
indev_drv.read_cb = touchpad_read;
|
||||
indev_touchpad = lv_indev_drv_register(&indev_drv);
|
||||
|
||||
/*------------------
|
||||
* Mouse
|
||||
* -----------------*/
|
||||
|
||||
/*Initialize your touchpad if you have*/
|
||||
mouse_init();
|
||||
|
||||
/*Register a mouse input device*/
|
||||
lv_indev_drv_init(&indev_drv);
|
||||
indev_drv.type = LV_INDEV_TYPE_POINTER;
|
||||
indev_drv.read_cb = mouse_read;
|
||||
indev_mouse = lv_indev_drv_register(&indev_drv);
|
||||
|
||||
/*Set cursor. For simplicity set a HOME symbol now.*/
|
||||
lv_obj_t * mouse_cursor = lv_img_create(lv_disp_get_scr_act(NULL), NULL);
|
||||
lv_img_set_src(mouse_cursor, LV_SYMBOL_HOME);
|
||||
lv_indev_set_cursor(indev_mouse, mouse_cursor);
|
||||
|
||||
/*------------------
|
||||
* Keypad
|
||||
* -----------------*/
|
||||
|
||||
/*Initialize your keypad or keyboard if you have*/
|
||||
keypad_init();
|
||||
|
||||
/*Register a keypad input device*/
|
||||
lv_indev_drv_init(&indev_drv);
|
||||
indev_drv.type = LV_INDEV_TYPE_KEYPAD;
|
||||
indev_drv.read_cb = keypad_read;
|
||||
indev_keypad = lv_indev_drv_register(&indev_drv);
|
||||
|
||||
/* Later you should create group(s) with `lv_group_t * group = lv_group_create()`,
|
||||
* add objects to the group with `lv_group_add_obj(group, obj)`
|
||||
* and assign this input device to group to navigate in it:
|
||||
* `lv_indev_set_group(indev_keypad, group);` */
|
||||
|
||||
/*------------------
|
||||
* Encoder
|
||||
* -----------------*/
|
||||
|
||||
/*Initialize your encoder if you have*/
|
||||
encoder_init();
|
||||
|
||||
/*Register a encoder input device*/
|
||||
lv_indev_drv_init(&indev_drv);
|
||||
indev_drv.type = LV_INDEV_TYPE_ENCODER;
|
||||
indev_drv.read_cb = encoder_read;
|
||||
indev_encoder = lv_indev_drv_register(&indev_drv);
|
||||
|
||||
/* Later you should create group(s) with `lv_group_t * group = lv_group_create()`,
|
||||
* add objects to the group with `lv_group_add_obj(group, obj)`
|
||||
* and assign this input device to group to navigate in it:
|
||||
* `lv_indev_set_group(indev_encoder, group);` */
|
||||
|
||||
/*------------------
|
||||
* Button
|
||||
* -----------------*/
|
||||
|
||||
/*Initialize your button if you have*/
|
||||
button_init();
|
||||
|
||||
/*Register a button input device*/
|
||||
lv_indev_drv_init(&indev_drv);
|
||||
indev_drv.type = LV_INDEV_TYPE_BUTTON;
|
||||
indev_drv.read_cb = button_read;
|
||||
indev_button = lv_indev_drv_register(&indev_drv);
|
||||
|
||||
/*Assign buttons to points on the screen*/
|
||||
static const lv_point_t btn_points[2] = {
|
||||
{10, 10}, /*Button 0 -> x:10; y:10*/
|
||||
{40, 100}, /*Button 1 -> x:40; y:100*/
|
||||
};
|
||||
lv_indev_set_button_points(indev_button, btn_points);
|
||||
}
|
||||
|
||||
/**********************
|
||||
* STATIC FUNCTIONS
|
||||
**********************/
|
||||
|
||||
/*------------------
|
||||
* Touchpad
|
||||
* -----------------*/
|
||||
|
||||
/*Initialize your touchpad*/
|
||||
static void touchpad_init(void)
|
||||
{
|
||||
/*Your code comes here*/
|
||||
}
|
||||
|
||||
/* Will be called by the library to read the touchpad */
|
||||
static bool touchpad_read(lv_indev_drv_t * indev_drv, lv_indev_data_t * data)
|
||||
{
|
||||
static lv_coord_t last_x = 0;
|
||||
static lv_coord_t last_y = 0;
|
||||
|
||||
/*Save the pressed coordinates and the state*/
|
||||
if(touchpad_is_pressed()) {
|
||||
touchpad_get_xy(&last_x, &last_y);
|
||||
data->state = LV_INDEV_STATE_PR;
|
||||
} else {
|
||||
data->state = LV_INDEV_STATE_REL;
|
||||
}
|
||||
|
||||
/*Set the last pressed coordinates*/
|
||||
data->point.x = last_x;
|
||||
data->point.y = last_y;
|
||||
|
||||
/*Return `false` because we are not buffering and no more data to read*/
|
||||
return false;
|
||||
}
|
||||
|
||||
/*Return true is the touchpad is pressed*/
|
||||
static bool touchpad_is_pressed(void)
|
||||
{
|
||||
/*Your code comes here*/
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/*Get the x and y coordinates if the touchpad is pressed*/
|
||||
static void touchpad_get_xy(lv_coord_t * x, lv_coord_t * y)
|
||||
{
|
||||
/*Your code comes here*/
|
||||
|
||||
(*x) = 0;
|
||||
(*y) = 0;
|
||||
}
|
||||
|
||||
/*------------------
|
||||
* Mouse
|
||||
* -----------------*/
|
||||
|
||||
/* Initialize your mouse */
|
||||
static void mouse_init(void)
|
||||
{
|
||||
/*Your code comes here*/
|
||||
}
|
||||
|
||||
/* Will be called by the library to read the mouse */
|
||||
static bool mouse_read(lv_indev_drv_t * indev_drv, lv_indev_data_t * data)
|
||||
{
|
||||
/*Get the current x and y coordinates*/
|
||||
mouse_get_xy(&data->point.x, &data->point.y);
|
||||
|
||||
/*Get whether the mouse button is pressed or released*/
|
||||
if(mouse_is_pressed()) {
|
||||
data->state = LV_INDEV_STATE_PR;
|
||||
} else {
|
||||
data->state = LV_INDEV_STATE_REL;
|
||||
}
|
||||
|
||||
/*Return `false` because we are not buffering and no more data to read*/
|
||||
return false;
|
||||
}
|
||||
|
||||
/*Return true is the mouse button is pressed*/
|
||||
static bool mouse_is_pressed(void)
|
||||
{
|
||||
/*Your code comes here*/
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/*Get the x and y coordinates if the mouse is pressed*/
|
||||
static void mouse_get_xy(lv_coord_t * x, lv_coord_t * y)
|
||||
{
|
||||
/*Your code comes here*/
|
||||
|
||||
(*x) = 0;
|
||||
(*y) = 0;
|
||||
}
|
||||
|
||||
/*------------------
|
||||
* Keypad
|
||||
* -----------------*/
|
||||
|
||||
/* Initialize your keypad */
|
||||
static void keypad_init(void)
|
||||
{
|
||||
/*Your code comes here*/
|
||||
}
|
||||
|
||||
/* Will be called by the library to read the mouse */
|
||||
static bool keypad_read(lv_indev_drv_t * indev_drv, lv_indev_data_t * data)
|
||||
{
|
||||
static uint32_t last_key = 0;
|
||||
|
||||
/*Get the current x and y coordinates*/
|
||||
mouse_get_xy(&data->point.x, &data->point.y);
|
||||
|
||||
/*Get whether the a key is pressed and save the pressed key*/
|
||||
uint32_t act_key = keypad_get_key();
|
||||
if(act_key != 0) {
|
||||
data->state = LV_INDEV_STATE_PR;
|
||||
|
||||
/*Translate the keys to LVGL control characters according to your key definitions*/
|
||||
switch(act_key) {
|
||||
case 1:
|
||||
act_key = LV_KEY_NEXT;
|
||||
break;
|
||||
case 2:
|
||||
act_key = LV_KEY_PREV;
|
||||
break;
|
||||
case 3:
|
||||
act_key = LV_KEY_LEFT;
|
||||
break;
|
||||
case 4:
|
||||
act_key = LV_KEY_RIGHT;
|
||||
break;
|
||||
case 5:
|
||||
act_key = LV_KEY_ENTER;
|
||||
break;
|
||||
}
|
||||
|
||||
last_key = act_key;
|
||||
} else {
|
||||
data->state = LV_INDEV_STATE_REL;
|
||||
}
|
||||
|
||||
data->key = last_key;
|
||||
|
||||
/*Return `false` because we are not buffering and no more data to read*/
|
||||
return false;
|
||||
}
|
||||
|
||||
/*Get the currently being pressed key. 0 if no key is pressed*/
|
||||
static uint32_t keypad_get_key(void)
|
||||
{
|
||||
/*Your code comes here*/
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
/*------------------
|
||||
* Encoder
|
||||
* -----------------*/
|
||||
|
||||
/* Initialize your keypad */
|
||||
static void encoder_init(void)
|
||||
{
|
||||
/*Your code comes here*/
|
||||
}
|
||||
|
||||
/* Will be called by the library to read the encoder */
|
||||
static bool encoder_read(lv_indev_drv_t * indev_drv, lv_indev_data_t * data)
|
||||
{
|
||||
|
||||
data->enc_diff = encoder_diff;
|
||||
data->state = encoder_state;
|
||||
|
||||
/*Return `false` because we are not buffering and no more data to read*/
|
||||
return false;
|
||||
}
|
||||
|
||||
/*Call this function in an interrupt to process encoder events (turn, press)*/
|
||||
static void encoder_handler(void)
|
||||
{
|
||||
/*Your code comes here*/
|
||||
|
||||
encoder_diff += 0;
|
||||
encoder_state = LV_INDEV_STATE_REL;
|
||||
}
|
||||
|
||||
/*------------------
|
||||
* Button
|
||||
* -----------------*/
|
||||
|
||||
/* Initialize your buttons */
|
||||
static void button_init(void)
|
||||
{
|
||||
/*Your code comes here*/
|
||||
}
|
||||
|
||||
/* Will be called by the library to read the button */
|
||||
static bool button_read(lv_indev_drv_t * indev_drv, lv_indev_data_t * data)
|
||||
{
|
||||
|
||||
static uint8_t last_btn = 0;
|
||||
|
||||
/*Get the pressed button's ID*/
|
||||
int8_t btn_act = button_get_pressed_id();
|
||||
|
||||
if(btn_act >= 0) {
|
||||
data->state = LV_INDEV_STATE_PR;
|
||||
last_btn = btn_act;
|
||||
} else {
|
||||
data->state = LV_INDEV_STATE_REL;
|
||||
}
|
||||
|
||||
/*Save the last pressed button's ID*/
|
||||
data->btn_id = last_btn;
|
||||
|
||||
/*Return `false` because we are not buffering and no more data to read*/
|
||||
return false;
|
||||
}
|
||||
|
||||
/*Get ID (0, 1, 2 ..) of the pressed button*/
|
||||
static int8_t button_get_pressed_id(void)
|
||||
{
|
||||
uint8_t i;
|
||||
|
||||
/*Check to buttons see which is being pressed (assume there are 2 buttons)*/
|
||||
for(i = 0; i < 2; i++) {
|
||||
/*Return the pressed button's ID*/
|
||||
if(button_is_pressed(i)) {
|
||||
return i;
|
||||
}
|
||||
}
|
||||
|
||||
/*No button pressed*/
|
||||
return -1;
|
||||
}
|
||||
|
||||
/*Test if `id` button is pressed or not*/
|
||||
static bool button_is_pressed(uint8_t id)
|
||||
{
|
||||
|
||||
/*Your code comes here*/
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
#else /* Enable this file at the top */
|
||||
|
||||
/* This dummy typedef exists purely to silence -Wpedantic. */
|
||||
typedef int keep_pedantic_happy;
|
||||
#endif
|
@ -1,17 +0,0 @@
|
||||
{
|
||||
"name": "lvgl",
|
||||
"version": "7.11.0",
|
||||
"keywords": "graphics, gui, embedded, tft, lvgl",
|
||||
"description": "Graphics library to create embedded GUI with easy-to-use graphical elements, beautiful visual effects and low memory footprint. It offers anti-aliasing, opacity, and animations using only one frame buffer.",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/lvgl/lvgl.git"
|
||||
},
|
||||
"license": "MIT",
|
||||
"homepage": "https://lvgl.io",
|
||||
"frameworks": "*",
|
||||
"platforms": "*",
|
||||
"build": {
|
||||
"flags": [ "-I$PROJECT_DIR/tasmota/lvgl_berry" ]
|
||||
}
|
||||
}
|
@ -1,151 +0,0 @@
|
||||
/**
|
||||
* @file lvgl.h
|
||||
* Include all LittleV GL related headers
|
||||
*/
|
||||
|
||||
#ifndef LVGL_H
|
||||
#define LVGL_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
/***************************
|
||||
* CURRENT VERSION OF LVGL
|
||||
***************************/
|
||||
#define LVGL_VERSION_MAJOR 7
|
||||
#define LVGL_VERSION_MINOR 11
|
||||
#define LVGL_VERSION_PATCH 0
|
||||
#define LVGL_VERSION_INFO ""
|
||||
|
||||
/*********************
|
||||
* INCLUDES
|
||||
*********************/
|
||||
|
||||
#include "src/lv_misc/lv_log.h"
|
||||
#include "src/lv_misc/lv_task.h"
|
||||
#include "src/lv_misc/lv_math.h"
|
||||
#include "src/lv_misc/lv_async.h"
|
||||
|
||||
#include "src/lv_hal/lv_hal.h"
|
||||
|
||||
#include "src/lv_core/lv_obj.h"
|
||||
#include "src/lv_core/lv_group.h"
|
||||
#include "src/lv_core/lv_indev.h"
|
||||
|
||||
#include "src/lv_core/lv_refr.h"
|
||||
#include "src/lv_core/lv_disp.h"
|
||||
|
||||
#include "src/lv_themes/lv_theme.h"
|
||||
|
||||
#include "src/lv_font/lv_font.h"
|
||||
#include "src/lv_font/lv_font_loader.h"
|
||||
#include "src/lv_font/lv_font_fmt_txt.h"
|
||||
#include "src/lv_misc/lv_printf.h"
|
||||
|
||||
#include "src/lv_widgets/lv_btn.h"
|
||||
#include "src/lv_widgets/lv_imgbtn.h"
|
||||
#include "src/lv_widgets/lv_img.h"
|
||||
#include "src/lv_widgets/lv_label.h"
|
||||
#include "src/lv_widgets/lv_line.h"
|
||||
#include "src/lv_widgets/lv_page.h"
|
||||
#include "src/lv_widgets/lv_cont.h"
|
||||
#include "src/lv_widgets/lv_list.h"
|
||||
#include "src/lv_widgets/lv_chart.h"
|
||||
#include "src/lv_widgets/lv_table.h"
|
||||
#include "src/lv_widgets/lv_checkbox.h"
|
||||
#include "src/lv_widgets/lv_cpicker.h"
|
||||
#include "src/lv_widgets/lv_bar.h"
|
||||
#include "src/lv_widgets/lv_slider.h"
|
||||
#include "src/lv_widgets/lv_led.h"
|
||||
#include "src/lv_widgets/lv_btnmatrix.h"
|
||||
#include "src/lv_widgets/lv_keyboard.h"
|
||||
#include "src/lv_widgets/lv_dropdown.h"
|
||||
#include "src/lv_widgets/lv_roller.h"
|
||||
#include "src/lv_widgets/lv_textarea.h"
|
||||
#include "src/lv_widgets/lv_canvas.h"
|
||||
#include "src/lv_widgets/lv_win.h"
|
||||
#include "src/lv_widgets/lv_tabview.h"
|
||||
#include "src/lv_widgets/lv_tileview.h"
|
||||
#include "src/lv_widgets/lv_msgbox.h"
|
||||
#include "src/lv_widgets/lv_objmask.h"
|
||||
#include "src/lv_widgets/lv_gauge.h"
|
||||
#include "src/lv_widgets/lv_linemeter.h"
|
||||
#include "src/lv_widgets/lv_switch.h"
|
||||
#include "src/lv_widgets/lv_arc.h"
|
||||
#include "src/lv_widgets/lv_spinner.h"
|
||||
#include "src/lv_widgets/lv_calendar.h"
|
||||
#include "src/lv_widgets/lv_spinbox.h"
|
||||
|
||||
#include "src/lv_draw/lv_img_cache.h"
|
||||
|
||||
#include "src/lv_api_map.h"
|
||||
|
||||
/*********************
|
||||
* DEFINES
|
||||
*********************/
|
||||
|
||||
/**********************
|
||||
* TYPEDEFS
|
||||
**********************/
|
||||
|
||||
/**********************
|
||||
* GLOBAL PROTOTYPES
|
||||
**********************/
|
||||
|
||||
/**********************
|
||||
* MACROS
|
||||
**********************/
|
||||
|
||||
/** Gives 1 if the x.y.z version is supported in the current version
|
||||
* Usage:
|
||||
*
|
||||
* - Require v6
|
||||
* #if LV_VERSION_CHECK(6,0,0)
|
||||
* new_func_in_v6();
|
||||
* #endif
|
||||
*
|
||||
*
|
||||
* - Require at least v5.3
|
||||
* #if LV_VERSION_CHECK(5,3,0)
|
||||
* new_feature_from_v5_3();
|
||||
* #endif
|
||||
*
|
||||
*
|
||||
* - Require v5.3.2 bugfixes
|
||||
* #if LV_VERSION_CHECK(5,3,2)
|
||||
* bugfix_in_v5_3_2();
|
||||
* #endif
|
||||
*
|
||||
* */
|
||||
#define LV_VERSION_CHECK(x,y,z) (x == LVGL_VERSION_MAJOR && (y < LVGL_VERSION_MINOR || (y == LVGL_VERSION_MINOR && z <= LVGL_VERSION_PATCH)))
|
||||
|
||||
/**
|
||||
* Wrapper functions for VERSION macros
|
||||
*/
|
||||
|
||||
static inline int lv_version_major(void)
|
||||
{
|
||||
return LVGL_VERSION_MAJOR;
|
||||
}
|
||||
|
||||
static inline int lv_version_minor(void)
|
||||
{
|
||||
return LVGL_VERSION_MINOR;
|
||||
}
|
||||
|
||||
static inline int lv_version_patch(void)
|
||||
{
|
||||
return LVGL_VERSION_PATCH;
|
||||
}
|
||||
|
||||
static inline const char *lv_version_info(void)
|
||||
{
|
||||
return LVGL_VERSION_INFO;
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /*LVGL_H*/
|
File diff suppressed because it is too large
Load Diff
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -1,59 +0,0 @@
|
||||
#!/usr/bin/env python3.6
|
||||
|
||||
import argparse
|
||||
from argparse import RawTextHelpFormatter
|
||||
import os
|
||||
import sys
|
||||
|
||||
parser = argparse.ArgumentParser(description="""Create fonts for LittelvGL including the built-in symbols. lv_font_conv needs to be installed. See https://github.com/littlevgl/lv_font_conv
|
||||
Example: python built_in_font_gen.py --size 16 -o lv_font_roboto_16.c --bpp 4 -r 0x20-0x7F""", formatter_class=RawTextHelpFormatter)
|
||||
parser.add_argument('-s', '--size',
|
||||
type=int,
|
||||
metavar = 'px',
|
||||
nargs='?',
|
||||
help='Size of the font in px')
|
||||
parser.add_argument('--bpp',
|
||||
type=int,
|
||||
metavar = '1,2,4',
|
||||
nargs='?',
|
||||
help='Bit per pixel')
|
||||
parser.add_argument('-r', '--range',
|
||||
nargs='+',
|
||||
metavar = 'start-end',
|
||||
default=['0x20-0x7F,0xB0,0x2022'],
|
||||
help='Ranges and/or characters to include. Default is 0x20-7F (ASCII). E.g. -r 0x20-0x7F, 0x200, 324')
|
||||
parser.add_argument('--symbols',
|
||||
nargs='+',
|
||||
metavar = 'sym',
|
||||
default=[''],
|
||||
help=u'Symbols to include. E.g. -s ÁÉŐ'.encode('utf-8'))
|
||||
parser.add_argument('--font',
|
||||
metavar = 'file',
|
||||
nargs='?',
|
||||
default='Montserrat-Medium.ttf',
|
||||
help='A TTF or WOFF file')
|
||||
parser.add_argument('-o', '--output',
|
||||
nargs='?',
|
||||
metavar='file',
|
||||
help='Output file name. E.g. my_font_20.c')
|
||||
parser.add_argument('--compressed', action='store_true',
|
||||
help='Compress the bitmaps')
|
||||
parser.add_argument('--subpx', action='store_true',
|
||||
help='3 times wider letters for sub pixel rendering')
|
||||
|
||||
args = parser.parse_args()
|
||||
|
||||
if args.compressed == False:
|
||||
compr = "--no-compress --no-prefilter"
|
||||
else:
|
||||
compr = ""
|
||||
|
||||
if len(args.symbols[0]) != 0:
|
||||
args.symbols[0] = "--symbols " + args.symbols[0]
|
||||
|
||||
#Built in symbols
|
||||
syms = "61441,61448,61451,61452,61452,61453,61457,61459,61461,61465,61468,61473,61478,61479,61480,61502,61512,61515,61516,61517,61521,61522,61523,61524,61543,61544,61550,61552,61553,61556,61559,61560,61561,61563,61587,61589,61636,61637,61639,61671,61674,61683,61724,61732,61787,61931,62016,62017,62018,62019,62020,62087,62099,62212,62189,62810,63426,63650"
|
||||
|
||||
#Run the command (Add degree and bbullet symbol)
|
||||
cmd = "lv_font_conv {} --bpp {} --size {} --font {} -r {} {} --font FontAwesome5-Solid+Brands+Regular.woff -r {} --format lvgl -o {} --force-fast-kern-format".format(compr, args.bpp, args.size, args.font, args.range[0], args.symbols[0], syms, args.output)
|
||||
os.system(cmd)
|
@ -1,103 +0,0 @@
|
||||
#!/usr/bin/env python3.6
|
||||
|
||||
import os
|
||||
|
||||
print("Generating 8 px")
|
||||
os.system("./built_in_font_gen.py --size 8 -o lv_font_montserrat_8.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_8.c')
|
||||
|
||||
print("\nGenerating 10 px")
|
||||
os.system("./built_in_font_gen.py --size 10 -o lv_font_montserrat_10.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_10.c')
|
||||
|
||||
print("\nGenerating 12 px")
|
||||
os.system("./built_in_font_gen.py --size 12 -o lv_font_montserrat_12.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_12.c')
|
||||
|
||||
print("\nGenerating 14 px")
|
||||
os.system("./built_in_font_gen.py --size 14 -o lv_font_montserrat_14.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_14.c')
|
||||
|
||||
print("\nGenerating 16 px")
|
||||
os.system("./built_in_font_gen.py --size 16 -o lv_font_montserrat_16.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_16.c')
|
||||
|
||||
print("\nGenerating 18 px")
|
||||
os.system("./built_in_font_gen.py --size 18 -o lv_font_montserrat_18.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_18.c')
|
||||
|
||||
print("\nGenerating 20 px")
|
||||
os.system("./built_in_font_gen.py --size 20 -o lv_font_montserrat_20.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_20.c')
|
||||
|
||||
print("\nGenerating 22 px")
|
||||
os.system("./built_in_font_gen.py --size 22 -o lv_font_montserrat_22.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_22.c')
|
||||
|
||||
print("\nGenerating 24 px")
|
||||
os.system("./built_in_font_gen.py --size 24 -o lv_font_montserrat_24.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_24.c')
|
||||
|
||||
print("\nGenerating 26 px")
|
||||
os.system("./built_in_font_gen.py --size 26 -o lv_font_montserrat_26.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_26.c')
|
||||
|
||||
print("\nGenerating 28 px")
|
||||
os.system("./built_in_font_gen.py --size 28 -o lv_font_montserrat_28.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_28.c')
|
||||
|
||||
print("\nGenerating 30 px")
|
||||
os.system("./built_in_font_gen.py --size 30 -o lv_font_montserrat_30.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_30.c')
|
||||
|
||||
print("\nGenerating 32 px")
|
||||
os.system("./built_in_font_gen.py --size 32 -o lv_font_montserrat_32.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_32.c')
|
||||
|
||||
print("\nGenerating 34 px")
|
||||
os.system("./built_in_font_gen.py --size 34 -o lv_font_montserrat_34.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_34.c')
|
||||
|
||||
print("\nGenerating 36 px")
|
||||
os.system("./built_in_font_gen.py --size 36 -o lv_font_montserrat_36.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_36.c')
|
||||
|
||||
print("\nGenerating 38 px")
|
||||
os.system("./built_in_font_gen.py --size 38 -o lv_font_montserrat_38.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_38.c')
|
||||
|
||||
print("\nGenerating 40 px")
|
||||
os.system("./built_in_font_gen.py --size 40 -o lv_font_montserrat_40.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_40.c')
|
||||
|
||||
print("\nGenerating 42 px")
|
||||
os.system("./built_in_font_gen.py --size 42 -o lv_font_montserrat_42.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_42.c')
|
||||
|
||||
print("\nGenerating 44 px")
|
||||
os.system("./built_in_font_gen.py --size 44 -o lv_font_montserrat_44.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_44.c')
|
||||
|
||||
print("\nGenerating 46 px")
|
||||
os.system("./built_in_font_gen.py --size 46 -o lv_font_montserrat_46.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_46.c')
|
||||
|
||||
print("\nGenerating 48 px")
|
||||
os.system("./built_in_font_gen.py --size 48 -o lv_font_montserrat_48.c --bpp 4")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_48.c')
|
||||
|
||||
print("\nGenerating 12 px subpx")
|
||||
os.system("./built_in_font_gen.py --size 12 -o lv_font_montserrat_12_subpx.c --bpp 4 --subpx")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_12_subpx.c')
|
||||
|
||||
print("\nGenerating 28 px compressed")
|
||||
os.system("./built_in_font_gen.py --size 28 -o lv_font_montserrat_28_compressed.c --bpp 4 --compressed")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_montserrat_28_compressed.c')
|
||||
|
||||
print("\nGenerating 16 px CJK")
|
||||
os.system(u"./built_in_font_gen.py --size 16 -o lv_font_simsun_16_cjk.c --bpp 4 --font SimSun.woff -r 0x20-0x7f --symbols 一在有個我不這了他也就人都說而我們你了要會對及和與以很種的大能著她那上但年還可以最自己為來所他們兩各可為或好等又將因為於由從更被才已者每次把三什麼問題其讓此做再所以只與則台灣卻並位想去呢學生表示到公司將如果社會看小天因此新但是它中使工作全覺得使用這些裡並由於時候知道這樣一認為時間事過向可能中國美國到和幾系統政府大家國家許多生活跟已經大學研究因本二活動該世界應四希望方式內項啊下環境一些必須文化高孩子沒有不能如開始元不同仍網路日本用中心來對雖然重要地方進行關係市場太老師提供學校應該指出經濟其他家發展教育成為多非常便方面很多吃然後未發現電腦一樣而且心不過無法企業正服務較不會臺灣曾嗎空間看到五如何國內們無對於以及之後可是當人員比先產品資訊資料比較先生地除了大陸需要像在給歲請月些名另若亦地區技術至特別其實國際不要發生參加一定其中問台北包括講造成看像常即喜歡去沒出現政治話走單位一直吧是否當然整處理歷史了解那怎麼機會家聽所有只要朋友令甚至用真六呀情況還是錢方法點任何經驗藝術你們十主要媽媽增加提出為什麼以您計畫作利用東西在條設計找之間成長能夠決定學習誰見半時代完成帶相當同學件能力別人生命下來場會議容易開發民眾事情書事實有關自組織言多愛建立相關均產生多業者解決完全的話接受知約一般推動過程管理功能手打水要求小朋友教授難我國告訴內容結果調查家庭成立選擇經營然而父母寫人類至於買尤其配合進入例如得討論依作品情形資源原因啦妳運動觀念給軟體品質經過如此嗯精神影響之過好像成參與以後於是部分另外公園透過訓練努力研究具有共同所謂下行為合作經合作目標起來考慮長意見辦法音樂連受廠商隻受到一切或是中央某女性教學極獲得真的路來快國小部份工程女人舉行句只是段根據現象人民土地面對注意這裡新聞繼續相信政策變成計劃強調學人士前前存在制度意義代表課程該沒至需求人生那些成功爸爸產業負責民間雖影響直接幾乎分實際團體價值使得類形成科技這麼當七不但往本身標準似乎應用或者動物電話態度建設事業老那麼常常字坐舉辦自我有的具目的塊條件即使好十分多少放又電影科學執行邊委員會溝通開一起張針對員工引起自然那麼安全總統此外擁有並且事件設計研究所語言嚴重故事學術片設備之外車基本實在久套達到改善死結構住皆改變拿小組支持座醫院既僅值得學者八交通階段就是申請主管申請同感覺電視母親嘛香港記者壓力快樂喝敢院也許人們談生產怕就身體規定程度積極知識作為機構而是鼓勵角色狀況專家據清楚不僅比賽玩效果越保護共開放附近上父親專業經費曾經工作願意分別重視不少歡迎小孩小時中國人顯示中共出男人避免屬於實施聲音主義行動不可只有校園興趣山表現得回來主任裡面經常不再電子受思想頭終於謝謝協助除當地正式真正低性份因素推出上價格去認識方向責任說明工業大量做逐漸心理一點供須簡單運用觀察往往規劃減少重新業務報導仍然感到開放領域有效女要從事發揮人才反而行政銀行公共媒體提高代自然社區力量啊教育部愈超過維持家長結合校長通常缺乏委員特色結果有時教師之前遠控制本否則法少原則要臉通過建議工具作業達節目智慧來自而變化同樣形式站以為健康擔任人口規劃剛特殊原來道分傳統總是前往投資加強不斷對象追求加上比思考製作台北市取得出來加入台安排兒童國中範圍老人雙方牠北京年輕結束教程式婦女找到彼此全球成本回到部而已之下等變期間非小姐整體採用根本叫歐洲正在加以充滿系列隨著早等等頗不足總分析深報告不錯在於旁笑故消費者意識公尺民族為主大眾到底願度大概對方官員發表進一步自由正確豐富國民黨戰爭怎麼樣只好明顯改革表達肯定強高興哪樹適合茶別國外關心蘇聯成績人物聽到創造不必不論尚居民不管美麗伊拉克帶來有般永遠感情兒子這樣子起全部".encode('utf-8'))
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_simsun_16_cjk.c')
|
||||
|
||||
print("\nGenerating 16 px Hebrew, Persian")
|
||||
os.system("./built_in_font_gen.py --size 16 -o lv_font_dejavu_16_persian_hebrew.c --bpp 4 --font DejaVuSans.ttf -r 0x20-0x7f,0x5d0-0x5ea,0x600-0x6FF,0xFB50-0xFDFF,0xFE70-0xFEFF")
|
||||
os.system('sed -i \'s|#include "lvgl/lvgl.h"|#include "../../lvgl.h"|\' lv_font_dejavu_16_persian_hebrew.c')
|
@ -1,49 +0,0 @@
|
||||
--style=kr
|
||||
--indent=spaces=4
|
||||
--indent-classes
|
||||
--indent-switches
|
||||
--indent-cases
|
||||
--indent-preproc-block
|
||||
--indent-preproc-define
|
||||
--indent-col1-comments
|
||||
--pad-oper
|
||||
--unpad-paren
|
||||
--align-pointer=middle
|
||||
--align-reference=middle
|
||||
--convert-tabs
|
||||
--max-code-length=120
|
||||
--break-after-logical
|
||||
--break-closing-braces
|
||||
--attach-closing-while
|
||||
--min-conditional-indent=0
|
||||
--max-continuation-indent=120
|
||||
--mode=c
|
||||
--lineend=linux
|
||||
--recursive
|
||||
--suffix=none
|
||||
--preserve-date
|
||||
--formatted
|
||||
--exclude=lv_conf_internal.h
|
||||
--exclude=../src/lv_font/lv_font_montserrat_12.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_14.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_16.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_18.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_20.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_22.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_24.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_26.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_28.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_30.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_32.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_34.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_36.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_38.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_40.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_42.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_44.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_46.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_48.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_12_subpx.c
|
||||
--exclude=../src/lv_font/lv_font_montserrat_28_compressed.c
|
||||
--exclude=../src/lv_font/lv_font_simsun_16_cjk.c
|
||||
--exclude=../src/lv_font/lv_font_dejavu_16_persian_hebrew.c
|
@ -1 +0,0 @@
|
||||
astyle --options=code-format.cfg "../src/*.c,*.h"
|
@ -1 +0,0 @@
|
||||
cppcheck -j8 --template="{severity}\t{file}:{line}\t{id}: {message}" --enable=all ../src/ --output-file=cppcheck_res.txt --suppress=unusedFunction --suppress=preprocessorErrorDirective --force
|
@ -1,9 +0,0 @@
|
||||
# https://github.com/facebook/infer
|
||||
#
|
||||
# Install:
|
||||
# VERSION=0.17.0; \
|
||||
# curl -sSL "https://github.com/facebook/infer/releases/download/v$VERSION/infer-linux64-v$VERSION.tar.xz" \
|
||||
# | sudo tar -C /opt -xJ && \
|
||||
# sudoln -s "/opt/infer-linux64-v$VERSION/bin/infer" /usr/local/bin/infer
|
||||
|
||||
infer run -- make -j8
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user