t * area, lv_color_t * colorp); //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); /*** * STATIC VARIABLES ***/ /*** ...
创建对象:lv_obj_t * lv_<widget>_create(lv_obj_t * parent,<other parameters if any>); 删除对象: 1. lv obj_del(lv_obj_t * obj) 2. lv_obj_del_async(lv_obj_t * obj) 3. lv_obj_clean(lv_obj_t * ...
lv_coord_t ext_click_pad成员表示控件的点击扩展板,因为有时候点击的位置可能在控件的边缘而不起作用,那么通过扩展点击的有效区域就可以解决这个问题,也就是往四周延伸一些有效距离,比如函数lv_obj_get_click_area就是通过控件的区域coords扩展ext_click_pad来实现的。 voidlv_obj_get_click_area(const lv_obj_t...
static lv_coord_t col_dsc[] = {LV_GRID_FR(1), 400, LV_GRID_FR(1),LV_GRID_TEMPLATE_LAST}; static lv_coord_t row_dsc[] = {50, 20, 20, LV_GRID_FR(1),LV_GRID_TEMPLATE_LAST}; /*Create a container with grid*/ lv_obj_t * cont = lv_obj_create(lv_scr_act()); lv_obj...
可以使用以下函数从外部数据源更新图表系列: lvgl.chart_set_ext_array(chart, ser, array, point_cnt ) ,其中array是lvgl.coord_t与point_cnt元素的外部数组。注意:更新外部数据源后,应调用 lvgl.chart_refresh(chart) 来更新图表。 获取当前图表信息# 有四个功能可获取有关图表的信息: lvgl.chart_get_type(...
LV_EVENT_REFR_EXT_DRAW_SIZE, /**< Get the required extra draw area around the object (e.g. for shadow). The event parameter is `lv_coord_t *` to store the size.*/ LV_EVENT_DRAW_MAIN_BEGIN, /**< Starting the main drawing phase*/ ...
lv_timer_handler(); /* let the GUI do its work */ vTaskDelay(10); } } 当数据堆有数据,心跳会使LVGL按照堆中数据调用多次屏幕填充函数来刷新屏幕,这个函数以及屏幕的尺寸需要使用者提供给LVGL static lv_disp_drv_t disp_drv; lv_disp_drv_init( &disp_drv ); ...
37 static void touchpad_read(lv_indev_drv_t * indev_drv, lv_indev_data_t * data) 38 { 39 static lv_coord_t last_x = 0; 40 static lv_coord_t last_y = 0; 41 42 /*Save the pressed coordinates and the state*/ 43 if(touchpad_is_pressed()) { ...
lv_coord_t uiIndex = 0; lv_coord_t uiCntCol = sizeof(col_dsc)/sizeof(lv_coord_t)-1; for(uiIndex=0; uiIndex<sizeof(row_dsc)/sizeof(lv_coord_t)-1; uiIndex++) { lv_obj_t * btn = lv_btn_create(cont); lv_obj_t * label = lv_label_create(btn); ...
lv_demos子模块的cmake脚本 6. 初始化软件配置文件 把lvgl/lv_conf_template.h模板复制到上层目录,并且改名lv_conf.h 把lv_drivers/lv_drv_conf_template.h模板复制到上层目录,并且改名lv_drv_conf.h 把lv_demos/ lv_ex_conf_template.h 模板复制到上层目录,并且改名 lv_ex_conf.h ...