一、现在发展
1.Android现已能够经过NFS在FS2410开发板上运转
二、现在缺点
1.触摸屏没有校准
2.Android中时钟中止,完毕zygote进程,体系重启,时钟更新,但再次中止不动
3.串口无法与GPRS模块通讯
三、移植过程
一、移植Android内核到FS2410开发板上
1、从de.google.com/p/android/downloads/list”>http://co
2、将内核解压到用户目录,如/home/wangan/kernel.git
3、进入kernel.git文件夹,如cd ~/kernel.git/
4、修正arch/arm/plat-s3c24xx/common-smdk.c文件中的nand flash分区设置,如gedit arch/arm/plat-s3c24xx/common-smdk.c
修正static struct mtd_partition smdk_default_nand_part[]结构体为:
static struct mtd_partition smdk_default_nand_part[] = {
[0] = {
.name = “Boot Agent”,
.size = SZ_256K,
.offset = 0,
},
[1] = {
.name = “Linux Kernel”,
.offset = SZ_256K,
.size = SZ_2M – SZ_256K,
},
[2] = {
.name = “File System”,
.offset = SZ_2M,
.size = SZ_32M – SZ_2M,
},
[3] = {
.name = “Other”,
.offset = SZ_32M,
.size = SZ_32M,
}
};
5、在http://www.codesourcery.com/gnu_toolchains/arm/portal/release644网站上下载IA32 GNU/Linux TAR。
6、将文件解压到用户目录,如/home/wangan/arm-2008q3
7、进入arm-2008q3/bin文件夹,如cd ~/arm-2008q3/bin/
8、添加当时途径进入环境变量,如export PATH=$PWD:$PATH,或修正~/.bashrc文件并从头登录
9、进入内核文件夹,如cd ~/kernel.git/
10、修正Makefile文件,如gedit Makefile
更改ARCH和CROSS_COMPILE
#ARCH ?= $(SUBARCH)
ARCH ?= arm
#CROSS_COMPILE ?= arm-eabi-
CROSS_COMPILE ?= arm-none-eabi-
11、从华清远见Linux-2.6.8.1内核压缩包中提取.config文件(留意:config前面有个“.”)放入kernel.git文件夹
12、运转make menuconfig
(1) 保证System Type —> ARM system type ()中的内容为Samsung S3C2410, S3C2412, S3C2413, S3C2440, S3C2442, S3C2443
(2) 保证System Type —> S3C2410 Machines —> [*] SMDK2410/A9M2410被勾选
(3) 撤销挑选与Goldfish相关的内容
Device Drivers —> Character devices —> < > Goldfish TTY Driver
Device Drivers —> Power supply class support —> < > Goldfish battery driver (NEW)
Device Drivers —> Real Time Clock —> < > GOLDFISH (NEW)
Device Drivers —> Graphics support —> Support for frame buffer devices —> < > Goldfish Framebuffer
(4) 挑选S3C2410 LCD相关的内容
Device Drivers —> Graphics support —> Support for frame buffer devices —> <*> S3C2410 LCD framebuffer support
Device Drivers —> Graphics support —> [*] Bootup logo —> [*] Standard black and white Linux logo
Device Drivers —> Graphics support —> [*] Bootup logo —> [*] Standard 16-color Linux logo
Device Drivers —> Graphics support —> [*] Bootup logo —> [*] Standard 224-color Linux logo
(5) 选中Android内核有必要选项
Kernel Features —> [*] Use the ARM EABI to compile the kernel
General setup —> [*] Use full shmem filesystem
General setup —> [*] Enable Androids Shared Memory Subsystem
System Type —> [*] Support Thumb user binaries
Device Drivers —> Android —> [*] Android log driver
Device Drivers —> Android —> <*> Binder IPC Driver
(6) 尽量选中Android内核可选选项
Device Drivers —> Android —> [*] RAM buffer console
Device Drivers —> Android —> [*] Android timed gpio driver
Device Drivers —> Android —> [*] On
(7) 其他CONFIG选项,如体系支撑请同时挑选
CONFIG_ANDROID_POWER =y
CONFIG_ANDROID_POWER_STAT =y
CONFIG_ANDROID_POWER_ALARM =y
(能够在Kconfig文件中查找ANDROID_POWER等字段进行挑选,或许直接修正.config文件)
13、退出并保存.config
二、移植LCD驱动到Linux-2.6.25内核
1、 进入kernel.git文件夹,如cd ~/kernel.git/
2、 修正arch/arm/mach-s3c2410/mach-smdk2410.c文件,如gedit arch/arm/mach-s3c2410/mach-smdk2410.c
(1) 添加头文件#include
(2) 添加两给结构体
static struct s3c2410fb_display smdk2410_lcd_cfg __initdata = {
.lcdcon5 = S3C2410_LCDCON5_FRM565 |
S3C2410_LCDCON5_INVVLINE |
S3C2410_LCDCON5_INVVFRAME |
S3C2410_LCDCON5_PWREN |
S3C2410_LCDCON5_HWSWP,
.type = S3C2410_LCDCON1_TFT,
.width = 320,
.height = 240,
.pixclock = 174757,
.xres = 320,
.yres = 240,
.bpp = 16,
.left_margin = 16,
.right_margin = 59,
.hsync_len = 9,
.upper_margin = 2,
.lower_margin = 6,
.vsync_len = 16,
};
static struct s3c2410fb_mach_info smdk2410_fb_info __initdata = {
.displays = &smdk2410_lcd_cfg,
.num_displays = 1,
.default_display = 0,
.gpccon = 0xaa955699,
.gpccon_mask = 0xffc003cc,
.gpcup = 0x0000ffff,
.gpcup_mask = 0xffffffff,
.gpdcon = 0xaa95aaa1,
.gpdcon_mask = 0xffc0fff0,
.gpdup = 0x0000faff,
.gpdup_mask = 0xffffffff,
.lpcsel = 0xf82,
};
(3) 在smdk2410_init()函数中添加s3c24xx_fb_set_platdata(&smdk2410_fb_info);
三、移植触摸屏驱动到Linux-2.6.25内核(拜见《根据linux-2.26.5内核的FS2410开发板触摸屏驱动移植》)并制造zImage文件,如make
这儿提一下,保证现已勾选Device Drivers —> Input device support —> <*> Event interface,自己从前在这儿徜徉,感谢游教师尽心教导!
四、制造支撑ARMv4的Android根文件体系
1、从http://www.rayfile.com/files/d4660882-de04-11dd-af0d-0014221b798a/下载Android的ARMv4版别根文件
2、在/dev下添加null和console两个设备节点
mknod -m 660 null c 1 3
mknod -m 660 console c 5 1
3、在U-boot中修正发动参数init为/init,完好的指令行如:root=nfs nfsroot=169.254.7.118:/source/rootfs ip=169.254.7.119 console=ttySAC0,115200 init=/init
4、修正/init.rc文件,去除除mount tmpfs tmpfs /sqlite_stmt_journals size=4m之外的一切mount指令
体系制造完结,现在应该能够看到美丽的大表了。初次发动需求创立文件,大约17分钟。然后每次发动只需求2分钟。