Firefly Open Source Community

   Login   |   Register   |
New_Topic
Print Previous Topic Next Topic

Make your own SDcard Linux image

417

Credits

15

Prestige

16

Contribution

intermediate

Rank: 3Rank: 3

Credits
417

Make your own SDcard Linux image

Posted at 7/27/2015 10:22:00      View:3757 | Replies:5        Print      Only Author   [Copy Link] 1#
Last edited by sghazagh In 7/27/2015 10:25 Editor

Hi all,
Can anyone help what I am doing wrong that I cannot pack my own "linuxroot" into the update
image?

Here is what I am doing:
-----------------------------
1) Have downloaded the official Ubuntu 14.04 SD image and unpacked it in my Linux machine
2) unpacked "update.img" in the folder
3) modified "linux-rootfs.img" by adding additional 2GB to allow me to copy all my own rootfs stuff
4) mounted both my own rootfs and official linux-rootfs.img into the two different mount points
5) have deleted all the official rootfs contents and copied all my rootfs contents into it
6) unmount both rootfs and so the official linux-rootfs.img has my stuff in it.
7) try to pack the update.img but it does not do it properly. The new_update.img creates quickly and I believe it doesn't add the newly modified "linux-rootfs.img" into it

I had a look at "parameter" file but the size of linux-rootfs partition is mentioned with "-". I assume the size not required to be specified as when I use the original "linux-rootfs.img" file the packing procedure works again and it takes more time to generate update.img!

Any help will be appreciated.
It would be gratefull if you correct my procedure or teach me the right way to create my own Linux SD card image to be able to boot my Firefly RK3288 device.

Many many thanks...
{Busybee, I think you are the one can help me ;) }
Reply

Use props Report

417

Credits

15

Prestige

16

Contribution

intermediate

Rank: 3Rank: 3

Credits
417
Posted at 7/27/2015 17:54:46        Only Author  2#
Last edited by sghazagh In 7/27/2015 17:57 Editor

Hi All,
I can confirm that the procedure is working fine if I use the "linux-rootfs.img" upto 1024mb (1GB).
I actually tried to create the ext4 "linux-rootfs" image from scratch bu using these commands:

dd if=/dev/zero of=linux-rootfs.img bs=1M count=1024
mkfs.ext4 -F -L linuxroot linux-rootfs.img

Then I tries two different rootfs which they are less than 1GB and both worked fine.
I tried first "busybox" rootfs and second "Angstrom" linux rootfs and both could be packed and I could load the device from SD for both of them.

I do not know why 'afptool' cannot properly pack the images if the 'linux-rootfs.img' size is more than 1GB?!!!

Any clue?
Reply

Use props Report

417

Credits

15

Prestige

16

Contribution

intermediate

Rank: 3Rank: 3

Credits
417
Posted at 8/2/2015 17:00:10        Only Author  3#
Last edited by sghazagh In 8/2/2015 17:01 Editor

Finaly I found the work around.
The problem is linux "afptool".
I tried to use windows 'rockdev' tools to create the release_update image with "Linuxium" 3gb "linux-rootfs" and the tools on windows could create the update image and release_update image successfully.
I could be able to load the firmware wit in windows and Linux could successfully load from SD card.

Thanks anyone who even didn't reply !!! ;)
Reply

Use props Report

844

Credits

42

Prestige

48

Contribution

advanced

Rank: 4

Credits
844
Posted at 8/4/2015 18:29:19        Only Author  4#
sghazagh Posted at 8/2/2015 17:00
Finaly I found the work around.
The problem is linux "afptool".
I tried to use windows 'rockdev' t ...

Stumbled also into this issue... Great that you found a work-around! Tnx!
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