您尚未登录。

#1 2021-03-09 11:47:28

xiaohua4758
会员
注册时间: 2021-02-24
已发帖子: 9
积分: 9

f1c200(板子widora tiny200-r3)的lvgl7.11.0移植例程(屏是800x480的电容屏)

上传到这里做个笔记^^

重新编辑原因:原来的LVGL刷屏速度太慢了,下午调试发现把lv_tick_inc(5)新开一线程更新,速度上来了,重新上传修改后的代码

源码是:lvgl7110_f1c_demo.7z,自己下载解压

1. 改lvgl及makefile
(1)lvgl
东西都是现成了,下了当前最新的lvgl 7.11.0版本,
主要改了lv_conf.h,lv_drv_conf.h,lv_ex_conf.h三个配置文件,以及main函数修改了一下。
具体忘记改哪些了,都是make的时候,哪里报错就改哪里的,直接看我的例程源文件

(2)
参考网上把makefile文件改了一下,主要是把交叉编译链的目录改成自己的目录就可以了,比如我的是
CC = /home/myway/f1c200/buildroot-tiny200/output/host/bin/arm-buildroot-linux-gnueabi-gcc-8.4.0
然后就可以make 生成执行文件 lvgl_7110_demo

2. 运行
将编译出来的lvgl_7110_demo放在tiny200-r3的文件系统,比如我的放在root文件夹下,运行如下
# pwd
/root
# ls
lvgl_7110_demo
# chmod 777 lvgl_7110_demo
# ./lvgl_7110_demo 3
lvgl version:7.11.0
demo num:3
The framebuffer device was opened successfully.
800x480, 32bpp
The framebuffer device was mapped to memory successfully.

总共51个demo,运行第几个demo就加相应的数字,如运行第3个就是
./lvgl_7110_demo 3

demo数字对应的数字如下,参考main函数:

	switch(demo_num)
	{
		case 0:
		case 1: lv_demo_widgets(); break;
		case 2: lv_demo_music(); break;
		case 3: lv_demo_printer(); break;
		case 4: lv_demo_keypad_encoder(); break;
		case 5: lv_demo_benchmark(); break;
		case 6: lv_ex_get_started_1(); break;
		case 7: lv_ex_get_started_2(); break;
		case 8: lv_ex_get_started_3(); break;
		case 9: lv_ex_style_1(); break;
		case 10:  lv_ex_style_2(); break;
		case 11:  lv_ex_style_3(); break;
		case 12:  lv_ex_style_4(); break;
		case 13:  lv_ex_style_5(); break;
		case 14:  lv_ex_style_6(); break;
		case 15:  lv_ex_style_7(); break;
		case 16:  lv_ex_style_8(); break;
		case 17:  lv_ex_style_10(); break;
		case 18:  lv_ex_style_11(); break;
		case 19:  lv_ex_arc_1(); break;
		case 20:  lv_ex_tileview_1(); break;
		case 21:  lv_ex_spinner_1(); break;
		case 22:  lv_ex_spinbox_1(); break;
		case 23:  lv_ex_slider_1(); break;
		case 24:  lv_ex_roller_1(); break;
		case 25:  lv_ex_page_1(); break;
		case 26:  lv_ex_objmask_1(); break;
		case 27:  lv_ex_objmask_2(); break;
		case 28:  lv_ex_msgbox_2(); break;
		case 29:  lv_ex_list_1(); break;
		case 30:  lv_ex_linemeter_1(); break;
		case 31:  lv_ex_line_1(); break;
		case 32:  lv_ex_imgbtn_1(); break;
		case 33:  lv_ex_img_1(); break;
		case 34:  lv_ex_gauge_1(); break;
		case 35:  lv_ex_gauge_2(); break;
		case 36:  lv_ex_dropdown_1(); break;
		case 37:  lv_ex_dropdown_2(); break;
		case 38:  lv_ex_cpicker_1(); break;
		case 39:  lv_ex_cpicker_2(); break;
		case 40:  lv_ex_cont_1(); break;
		case 41:  lv_ex_checkbox_1(); break;
		case 42:  lv_ex_chart_1(); break;
		case 43:  lv_ex_chart_2(); break;
		case 44:  lv_ex_canvas_1(); break;
		case 45:  lv_ex_canvas_2(); break;
		case 46:  lv_ex_calendar_1(); break;
		case 47:  lv_ex_btnmatrix_1(); break;
		case 48:  lv_ex_btn_1(); break;
		case 49:  lv_ex_btn_2(); break;
		case 50:  lv_ex_bar_1(); break;
		case 51:  lv_ex_arc_1(); break;
		case 52:  lv_ex_arc_2(); break;[video]https://whycan.com/files/members/6042/printf1.mp4[/video]

		default:
			lv_demo_printer(); break;
	}

源码:lvgl7110_f1c_demo_v1.0.7z

printer.jpgmusic.jpg


最近编辑记录 xiaohua4758 (2021-03-09 16:48:27)

离线

#2 2021-03-09 14:54:47

xrff_z
会员
注册时间: 2019-10-10
已发帖子: 25
积分: 25

Re: f1c200(板子widora tiny200-r3)的lvgl7.11.0移植例程(屏是800x480的电容屏)

谢谢分享。

离线

#3 2021-04-02 17:05:16

buliaoqq
会员
注册时间: 2019-03-15
已发帖子: 16
积分: 15.5

Re: f1c200(板子widora tiny200-r3)的lvgl7.11.0移植例程(屏是800x480的电容屏)

用楼主的demo不知道为什么触屏不能用,用ts_test已经能正常测试触屏了。

离线

页脚

工信部备案:粤ICP备20025096号 Powered by FluxBB

感谢为中文互联网持续输出优质内容的各位老铁们。 QQ: 516333132, 微信(wechat): whycan_cn (哇酷网/挖坑网/填坑网) service@whycan.cn