Chinaunix首页 | 论坛 | 博客
  • 博客访问: 38687
  • 博文数量: 25
  • 博客积分: 605
  • 博客等级: 中士
  • 技术积分: 255
  • 用 户 组: 普通用户
  • 注册时间: 2011-04-03 21:57
文章分类

全部博文(25)

文章存档

2012年(22)

2011年(3)

我的朋友

分类: LINUX

2012-05-01 11:06:02

对于2440, 目前android并未完全支持armv4t。 如要运行在2440上需要修改一些汇编相关的代码。 所幸已有很多人做过这个工作,目前我是在freerunner这个基础上做的。

主页是, 可以用git下载代码(这个网站上有地址),这里的wiki上就关于如何build的文档。

 

目前的一些问题:

1:运行无法执行linuxrc。 因为我原来移植的是busybox, kernel上的参数是init=/linuxrc.可以参照上一篇blog制作android和busybox在一起的文件系统。

2:init 上有个servicemanager error, 这是因为kernel没有编译到相应驱动。 编译内核时 device drivers->staging driver->android全选。

3:闪屏。 lcd驱动问题, 在framebuffer.cpp 中修改

mIndex = 1 - mIndex;
mInfo.activate = FB_ACTIVATE_VBL;
mInfo.yoffset = mIndex ? mInfo.yres : 0;
- if (ioctl(egl_native_window_t::fd, FBIOPUT_VSCREENINFO, &mInfo) 
== -1) {
- LOGE("FBIOPUT_VSCREENINFO failed");
+ if (ioctl(egl_native_window_t::fd, FBIOPAN_DISPLAY, &mInfo) == 
-1) {
+ LOGE("FBIOPAN_DISPLAY failed");
return 0;
}


@@ -395,10 +395,10 @@ status_t EGLDisplaySurface::mapFrameBuffer()
info.activate = FB_ACTIVATE_NOW;

uint32_t flags = PAGE_FLIP;
- if (ioctl(fd, FBIOPUT_VSCREENINFO, &info) == -1) {
+ if (ioctl(fd, FBIOPAN_DISPLAY, &info) == -1) {
info.yres_virtual = info.yres;
flags &= ~PAGE_FLIP;
- LOGW("FBIOPUT_VSCREENINFO failed, page flipping not 
supported");
+ LOGW("FBIOPAN_DISPLAY failed, page flipping not supported");
}

4: 在init.rc中有一句  mount rootfs rootfs / ro remount,改为mount rootfs rootfs / rw remount。 应为目前用的好似nfs,而用ro的话data文件夹只读,init会出错。

 

目前已可以用logcat > a.txt &。 慢慢分析错误中,还只能跑到android几个字出来。 卡在一个音频的地方。

W/AudioHardwareALSA( 1179): Unable to attach mixer to device AndroidOut: No such file or directory
E/AudioHardwareALSA( 1179): Unable to attach mixer to device default: No such file or directory
W/AudioHardwareALSA( 1179): Unable to attach mixer to device AndroidIn: No such file or directory
E/AudioHardwareALSA( 1179): Unable to attach mixer to device default: No such file or directory

 

这个问题是声卡驱动的问题。板子上的是uda1341,在内核配置中打开device driver->sound card->alsa driver->Alsa for soc support,还要打开oss驱动,因为alsa驱动不会建立dsp节点。

打开for samsung s3c24xx chip 和uda134x chip。  其中最后一项build all soc driver,如果打开会报一个oops的错误,所以就关掉了。

 

system uids inconsistent错误, 删掉data文件夹,修改了一下init.rc  删了一些蓝牙等相关的服务。

 

 

现在已经可以进去了,然后就是触摸屏了。

阅读(297) | 评论(0) | 转发(0) |
给主人留下些什么吧!~~