开发平台:飞凌113i-S开发板 113i屏幕修改需要分别修改内核以及uboot,下面我们以lvds1024*600的屏幕为例 1.进入如下路径 forlinx@ubuntu:~/work/OK113i-linux-sdk$ cd kernel/linux-5.4/arch/arm/boot/dts/ 2.打开 OK113I-C-Linux.dts forlinx@ubuntu:~/work/OK113i-linux-sdk/kernel/linux-5.4/arch/arm/boot/dts$ vi OK113I-C-Linux.dts 3.修改分辨率参数如下面所示(具体参数请参考您使用的屏幕的屏体手册): elif (DISP_TYPE == 5) // lvds 1280x800 &lcd0 {
lcd_used = <1>;
status = "okay"; lcd_driver_name = "default_lcd"; lcd_backlight = <150>; lcd_if = <3>; lcd_x = <1024>; lcd_y = <600>; lcd_width = <210>; lcd_height = <135>; lcd_dclk_freq = <71>; lcd_pwm_used = <1>; lcd_pwm_ch = <3>; lcd_pwm_freq = <20000>; lcd_pwm_pol = <1>; lcd_pwm_max_limit = <255>; 4.修改完成后保存并退出,然后开始修改uboot,进入如下路径 forlinx@ubuntu:~/work/OK113i-linux-sdk$ cd brandy/brandy-2.0/u-boot-2018/drivers/video/sunxi/bootGUI/ 5.打开display-menu.c forlinx@ubuntu:~/work/OK113i-linux-sdk/brandy/brandy-2.0/u-boot-2018/drivers/video/sunxi/bootGUI$ vi display_menu.c 6.修改分辨率参数如下方所示: void bootup_menu_setprop_by_lcd_lvds_1280_800(int kernel) { int offset_node = 0; unsigned int phandle0 = 0; unsigned int phandle1 = 0; bootup_hal_save_lcd_to_kernel("lcd_used", FDT_UINT_VALUE, 1, NULL); bootup_hal_save_lcd_to_kernel("lcd_if", FDT_UINT_VALUE, 3, NULL); bootup_hal_save_lcd_to_kernel("lcd_driver_name", FDT_STRING_VALUE, 0, "default_lcd"); bootup_hal_save_lcd_to_kernel("lcd_x", FDT_UINT_VALUE, 1024, NULL); bootup_hal_save_lcd_to_kernel("lcd_y", FDT_UINT_VALUE, 600, NULL); bootup_hal_save_lcd_to_kernel("lcd_width", FDT_UINT_VALUE, 210, NULL); bootup_hal_save_lcd_to_kernel("lcd_height", FDT_UINT_VALUE, 135, NULL); bootup_hal_save_lcd_to_kernel("lcd_dclk_freq", FDT_UINT_VALUE, 71, NULL); 7.修改完成后,在源码初始路径下编译uboot forlinx@ubuntu:~/work/OK113i-linux-sdk$ ./build.sh brandy 8. 编译成功后进行全编译./build.sh forlinx@ubuntu:~/work/OK113i-linux-sdk$ ./build.sh 9.执行成功后./build.sh pack打包镜像烧录到板子上观察现象。 |
|小黑屋| 飞凌嵌入式 ( 冀ICP备12004394号-1 )
GMT+8, 2024-11-22 04:49
Powered by Discuz! X3.4
© 2001-2013 Comsenz Inc.