Cubieboard2-Android-Cubie-Screen 模组调试说明 修正1可以显示了 windows ANSI.txt
CUBIEBOARD
http://cubie.cc
Fucking cool, 深刻的嵌入式技术和应用讨论社区
Cubieboard2 Android Cubie-Screen 模组调试说明 修正1可以显示了(触摸屏等待修正,反正可以用鼠标)
Cubie-Screen
Website:http://cubieboard.org/
Support: support@cubietech.com
文档版本 作者 初审 再审
V-0.1-20141226 payne A.K Parker
内容目录
1.概要 ..........................................................................................................4
2.硬件要求.......................................................................................................4
3.软件要求.......................................................................................................4
3.1 SDK 开发包 ..............................................................................................4
3.1.1 百度云下载.........................................................................................4
3.1.2 github 下载........................................................................................4
4.Cubieboard2 Cubie-Screen 移植..................................................................................4
4.1 CB2 驱动源码.............................................................................................4
4.1.1 下载源码...........................................................................................4
4.1.2 拷贝相关文件.......................................................................................5
4.2 系统配置.................................................................................................5
4.3 内核配置.................................................................................................7
4.4 编译....................................................................................................10
4.4.1 编译内核..........................................................................................10
4.4.2 编译 android......................................................................................10
4.4.3 固件生成..........................................................................................11
4.5 烧写固件................................................................................................11
1.概要
本文档是基于 Cubieboard2 的 Android 操作系统使用 Cubie-Screen 模块实现小屏显示操作功能, Cubie-Screen 小巧方便灵活,适合没有显示屏的用户使用。
2.硬件要求
? Cubieboard2
? 方糖电子 Cubie-Screen 屏
? 一个鼠标、键盘
3.软件要求
3.1 SDK 开发包
3.1.1 百度云下载
http://pan.baidu.com/s/1kTFXnPP
3.1.2 github下载
git clone https://bitbucket.org/cubietech/a20-android4.2_lichee.git
git clone https://bitbucket.org/cubietech/a20-android4.2_android.git
4.Cubieboard2 Cubie-Screen移植
4.1 CB2 驱动源码
4.1.1 下载源码
http://pan.baidu.com/s/1hquyzB2#path=%2FAdd-On%2FCubieScreen for CB1%26CB2%2F 源码
http://pan.baidu.com/s/1hquyzB2# ... 2590%25E7%25A0%2581
E:\BaiduYunDownload\cubieboard2开发板的资料\cubieboard店资料---0827\cubieboard3.5寸屏资料\CubieScreen for CB1&CB2\源码
android-cbcs-source.7z
解压:
$ 7z x android-cbcs-source.7z
4.1.2 拷贝相关文件
拷贝 touchscreen 驱动(这里有问题,编译出错!暂时不拷贝)
V:\lichee\linux-3.4\drivers\input\sw_touchscreen\ft5x
$ cp android-cbcs-source/CB2/driver/touchscreen/* a20-android/lichee/linux-3.4/drivers/input/sw_touchscreen/ft5x/
rootroot@rootroot-E400:~/wyb$ cp android-cbcs-source/CB2/driver/touchscreen/* cubieboard2_sdk_20140508/lichee/linux-3.4/drivers/input/sw_touchscreen/ft5x/
rootroot@rootroot-E400:~/wyb/android-cbcs-source/CB2/driver/touchscreen$ ll
total 104
drwxrwxr-x 2 rootroot rootroot 4096 1?. 6 14:50 ./
drwxrwxr-x 4 rootroot rootroot 4096 1?. 6 14:50 ../
-rw-rw-r-- 1 rootroot rootroot 48521 8?.16 2014 ft5x_ts.c
-rw-rw-r-- 1 rootroot rootroot 48521 12?. 8 11:07 ft5x_ts.h
拷贝 disp 相关文件
V:\lichee\linux-3.4\drivers\video\sun7i\disp
$ cp android-cbcs-source/CB2/driver/video/disp/* a20-android/lichee/linux-3.4/drivers/video/sun7i/disp
rootroot@rootroot-E400:~/wyb$ cp android-cbcs-source/CB2/driver/video/disp/* cubieboard2_sdk_20140508/lichee/linux-3.4/drivers/video/sun7i/disp/
rootroot@rootroot-E400:~/wyb/android-cbcs-source/CB2/driver/video/disp$ ll
total 60
drwxrwxr-x 2 rootroot rootroot 4096 1?. 6 14:50 ./
drwxrwxr-x 4 rootroot rootroot 4096 1?. 6 14:50 ../
-rw-rw-r-- 1 rootroot rootroot 48766 8?.16 2014 disp_lcd.c
-rw-rw-r-- 1 rootroot rootroot 2169 8?.16 2014 disp_lcd.h
拷贝 lcd 相关文件(!!!!会有替换的!!!!)
$ cp android-cbcs-source/CB2/driver/video/lcd/* a20-android/lichee/linux-3.4/drivers/video/sun7i/lcd
rootroot@rootroot-E400:~/wyb$ cp android-cbcs-source/CB2/driver/video/lcd/* cubieboard2_sdk_20140508/lichee/linux-3.4/drivers/video/sun7i/lcd
rootroot@rootroot-E400:~/wyb/android-cbcs-source/CB2/driver/video/lcd$ ll
total 24
drwxrwxr-x 2 rootroot rootroot 4096 1?. 6 14:50 ./
drwxrwxr-x 4 rootroot rootroot 4096 1?. 6 14:50 ../
-rw-rw-r-- 1 rootroot rootroot 8397 8?.16 2014 lcd0_panel_cfg.c
-rw-rw-r-- 1 rootroot rootroot 2671 8?.16 2014 lcd_panel_cfg.h
拷贝 ctp 头文件
V:\lichee\linux-3.4\include\linux
$ cp android-cbcs-source/CB2/driver/ctp.h a20-android/lichee/linux-3.4/include/linux/
rootroot@rootroot-E400:~/wyb$ cp android-cbcs-source/CB2/driver/ctp.h cubieboard2_sdk_20140508/lichee/linux-3.4/include/linux/
rootroot@rootroot-E400:~/wyb/android-cbcs-source/CB2/driver$ ll
total 20
drwxrwxr-x 4 rootroot rootroot 4096 1?. 6 14:50 ./
drwxrwxr-x 5 rootroot rootroot 4096 1?. 7 09:41 ../
-rw-rw-r-- 1 rootroot rootroot 1552 8?.16 2014 ctp.h
drwxrwxr-x 2 rootroot rootroot 4096 1?. 6 14:50 touchscreen/
drwxrwxr-x 4 rootroot rootroot 4096 1?. 6 14:50 video/
!!!!说明书不会告诉你的!!!!
还需要拷贝:
Z:\wyb\android-cbcs-source\CB2\kernel_config\cubieboard2_config (这个文件貌似不是太重要)
拷贝为:V:\lichee\linux-3.4\.config
Z:\wyb\android-cbcs-source\CB2\sys_config\sys_config.fex (这个文件重要,但是原始拷贝过去,被光亮,LCD还是不会有显示了。需要修改!确认分辨率为800*480,即为480p)
;-------------------------------------------------------------------------------
;disp init configuration
;
;disp_mode (0:screen0<screen0,fb0> 1:screen1<screen1,fb0> 2:two_diff_screen_diff_contents<screen0,screen1,fb0,fb1>
; 3:two_same_screen_diff_contets<screen0,screen1,fb0> 4:two_diff_screen_same_contents<screen0,screen1,fb0>)
;screenx_output_type (0:none; 1:lcd; 2:tv; 3:hdmi; 4:vga)
;screenx_output_mode (used for tv/hdmi output, 0:480i 1:576i 2:480p 3:576p 4:720p50 5:720p60 6:1080i50 7:1080i60 8:1080p24 9:1080p50 10:1080p60 11:pal 14:ntsc)
;screenx_output_mode (used for vga output, 0:1680*1050 1:1440*900 2:1360*768 3:1280*1024 4:1024*768 5:800*600 6:640*480 10:1920*1080 11:1280*720)
;fbx format (4:RGB655 5:RGB565 6:RGB556 7:ARGB1555 8:RGBA5551 9:RGB888 10:ARGB8888 12:ARGB4444)
;fbx pixel sequence (0:ARGB 1:BGRA 2:ABGR 3:RGBA) --- 0 for linux, 2 for android
;lcd0_bright (lcd0 init bright,the range:[0,256],default:197
;lcd1_bright (lcd1 init bright,the range:[0,256],default:197
;-------------------------------------------------------------------------------
[disp_init]
disp_init_enable = 1
disp_mode = 0
screen0_output_type = 1
;screen0_output_mode = 4
screen0_output_mode = 2
;----------------------------------------------------------------------------------
;boot display configuration
;output_type (0:none; 1:lcd; 2:tv; 3:hdmi; 4:vga)
;output_mode (used for tv/hdmi output, 0:480i 1:576i 2:480p 3:576p 4:720p50 5:720p60 6:1080i50 7:1080i60 8:1080p24 9:1080p50 10:1080p60 11:pal 14:ntsc)
;output_mode (used for vga output, 0:1680*1050 1:1440*900 2:1360*768 3:1280*1024 4:1024*768 5:800*600 6:640*480 10:1920*1080 11:1280*720)
;auto_hpd (auto detect hdmi/cvbs/ypbpr plug in)
;----------------------------------------------------------------------------------
[boot_disp]
output_type = 1
;output_mode = 4
output_mode = 2
auto_hpd = 1
4.2 系统配置
路径:lichee/tools/pack/chips/sun7i/configs/android/sugar-cubieboard2/sys_config.fex
V:\lichee\tools\pack\chips\sun7i\configs\android\sugar-cubieboard2\sys_config.fex
主要配置 disp_init ctp_para lcd0_para 部分
具体配置:
[disp_init]
[ctp_para]
[lcd0_para]
|