Firefly Open Source Community

   Login   |   Register   |
New_Topic
Print Previous Topic Next Topic

How to build android to boot from SD card?

31

Credits

0

Prestige

0

Contribution

new registration

Rank: 1

Credits
31

How to build android to boot from SD card?

Posted at 9/10/2015 16:04:03      View:11326 | Replies:9        Print      Only Author   [Copy Link] 1#
Hi,
I am building android lollipop by myself, I want to make it boot from SD card on rk3288 board.
I build the android code, and generate images via mkimage.sh.I download the android 4.4 sd card image from firefly website, extract it and replace boot.img, kernel.img, system.img with my own version, repack these image to release_update.img, and flash to SD card, and now the board cannot start correctly, the errors are like:
Failed to mount an un-encryptable or wiped partition on/dev/block/platform/ff0f0000.rksdmmc/by-name/system at /system options: noauto_da_alloc error: No such file or directory
It seems the boot.img for emmc and sdcard are different, does anyone know how to configure/build boot.img to make it run from SD card?
Or is there any special codes/steps I have to do before building?


Reply

Use props Report

403

Credits

10

Prestige

12

Contribution

intermediate

Rank: 3Rank: 3

Credits
403
Posted at 9/12/2015 10:52:00        Only Author  2#
Please have a look at the scripts post at:
https://plus.google.com/+IanMORRISON/posts/22Vxc6Sr5Ei
Reply

Use props Report

31

Credits

0

Prestige

0

Contribution

new registration

Rank: 1

Credits
31
Posted at 9/14/2015 12:56:53        Only Author  3#
busybee Posted at 9/12/2015 10:52
Please have a look at the scripts post at:
https://plus.google.com/+IanMORRISON/posts/22Vxc6Sr5Ei

Hi
thanks for your help, I tried this tool before, I have downloaded two android package from this website, one is android4.4 sd card version, the other is android4.4 non-sd card version. the steps I tried are:
1. flash RK3288Loader_uboot_V2.17.02.bin
   ./create-android-sdcard android4.4_sd card
   this one can boot successfully from sd card
2. flash RK3288Loader_uboot_V2.17.02.bin
   ./create-android-sdcard android4.4_sd non-card
   this one cannot boot, cannot find file system
3. flash RK3288Loader_uboot_V2.17.02.bin
   extract these two images, and copy the boot.img, kernel.img, system.img from non-sd package to sd package, and then re-pack the sd package
   ./create-android-sdcard the_new_package
   the one has the same issue with 2, cannot find file system (cannot find system, userdata...)

and I also replaced with my own built images, the issues are similar.
Is there any problem with my steps?
Reply

Use props Report

403

Credits

10

Prestige

12

Contribution

intermediate

Rank: 3Rank: 3

Credits
403
Posted at 9/15/2015 10:20:15        Only Author  4#
I think you need the kernel.img & boot.img from sd package.

Normally, the kernel will only parse the MBR partition of the sd card.

I guess that kernel.img & boot.img from sd package will also parse
and handle the mtd partitions of the sd card.
Reply

Use props Report

31

Credits

0

Prestige

0

Contribution

new registration

Rank: 1

Credits
31
Posted at 9/15/2015 15:33:42        Only Author  5#
If I use the images from sd package (4.4), and replace system.img with my own built 5.1 image, the kernel can bootup and file system can be load successfully, but severicemanager cannot start:
[   24.315467] binder: 147:147 transaction failed 29189, size 0-0
[   25.299560] binder: 147:147 transaction failed 29189, size 0-0
[   26.283657] binder: 147:147 transaction failed 29189, size 0-0
[   26.591163] binder: 260:260 transaction failed 29189, size 0-0
[   26.807166] binder: send failed reply for transaction 8 to 265:265
[   26.807322] init: critical process 'servicemanager' exited 4 times in 4 minutes; rebooting into recovery mode

29189 is BR_DEAD_REPLY, I think it may be that my system.img is incompatible with 4.4_sd package, because if I replace the system.img with non-sd package (4.4), it can work.
so the problem maybe that I don't know how to configure the sd card version of boot.img (the boot.img from mkimage.sh is only about 1MB, but the boot.img from sd package is about 7MB, and if I use mkimage.sh ota and replace boot.img, then the board cannot find kernel)
Reply

Use props Report

543

Credits

19

Prestige

15

Contribution

advanced

Rank: 4

Credits
543
Posted at 9/15/2015 23:48:19        Only Author  6#
I think you need a boot.img with kernel inside, separate kernel.img I don't think will work with SD boot.
Reply

Use props Report

31

Credits

0

Prestige

0

Contribution

new registration

Rank: 1

Credits
31
Posted at 9/16/2015 10:18:24        Only Author  7#
dewet Posted at 9/15/2015 23:48
I think you need a boot.img with kernel inside, separate kernel.img I don't think will work with SD  ...

so do you know how to make boot.img work with sd card?
Reply

Use props Report

543

Credits

19

Prestige

15

Contribution

advanced

Rank: 4

Credits
543
Posted at 9/18/2015 00:06:00        Only Author  8#
Reply

Use props Report

31

Credits

0

Prestige

0

Contribution

new registration

Rank: 1

Credits
31
Posted at 9/18/2015 10:31:14        Only Author  9#
dewet Posted at 9/18/2015 00:06
Have you tried
https://bitbucket.org/T-Firefly/firenow-lollipop/src/c27bca778047567048811e9e8e17dd4 ...

I was using this tool to flash the update.img, but this tool is just used to flash images to sd card, it doesn't help to config the boot.img.
Reply

Use props Report

You need to log in before you can reply Login | Register

This forum Credits Rules

Quick Reply Back to top Back to list