Overclocking....i need some help - Droid Eris Android Development

Ok so on my adventure of overclocking the Eris i have ran into a bit of an issue.
I started with making a nandroid backup of my phone. this gives you system.img, boot.img, and data.img. I have successfully extracted everything from the image files except for one thing...the kernel.
I have taken the boot.img and split it up into the ramdisk and kernel and sorted through the garbage to get working directories and file structures.
I now have the ramdisk in a editable format but the /sys files are created from the kernel on boot and those are the ones i need to edit.
I have the kernel file on my computer, isolated, but i do not know where to begin on decrypting this jumbled mess. As far as i know it isnt compressed as i cant find magic numbers in the headers but this has baffled me.
Any devs out there wanna shed some light as i dont know much about android and i just started this yesterday.

Wait for HTC to give us the kernel source code

That would work if i had some patience. Any idea when we could get the source?

Related

How to make update.zip from boot.img, system.img, data.img (the nandroid backup)

Yes i know the fastboot trick, but can anyone guide me towards making the nandroid backup files into a update.zip that would work?
I'd like to know too ^^.
Me too.
I've successfully scripted the automated creation of a file structure into which the contents of BOOT.IMG, SYSTEM.IMG, DATA.IMG, CACHE.IMG and SD-EXT.IMG are extracted. The script also creates a valid update-script file under ./META-DATA/....
The only issue I have is that I'm using windows so the .IMG files extracted as a yaffs file system, looses the original file permissions. I need someway to recreate the permissions in the update.zip.
Thats all.
Having a way of converting a nandroid backup to an update.zip means you can very easily cook custom roms from a nandroid backup, and port ROMs across phones using a portable .ZIP format.
Maybe dsixda can help
http://forum.xda-developers.com/showthread.php?t=633246
"OR [cook a rom] from a Nandroid backup (under /sdcard/nandroid) [NOT RECOMMENDED]:
Copy the system.img and boot.img files from the backup folder to your kitchen's original_update folder
NOTE: The Nandroid-backup method of cooking is not the best way to cook, because the kitchen may not account for various advanced options that were cooked outside of this kitchen (these options are in the update-script file which was in the original ROM but is not in the backup. The kitchen needs to re-create this file and 'guess' those options). However, it will support Nandroid backups that already have basic features like root, busybox and /data/app functionality. "
You get nandroid backup images by backing up a ROM which was flashed from an update.zip package. What is then the point of recreating that update.zip package?
giant is right with the klitchen by dsixda you can make an update.zip form nandroid very easy
Guys, we're missing the point.
To clarify:
The "point of recreating the ZIP ROM file" are numerous. For example, to create a ROM where the original ROM isnt available, i.e. to create a portable ROM based on an existing set of images in a phone where the phone and/or its sdcard cannot be removed or where we do not wish to remove the card. Simple. But more importantly, the process is a learning and development activity that I want to undertake, its a personal decision, for which support would be welcome.
Secondly, dsixda issues many caveats around cooking ROMs from nadroid backups. It simply doesnt work - I've tried it - thus his caveat is correct and should be observed. Furthermore, his kitchen creates windows based ZIP files. The process is inherently flawed for creating ROMs for linux because the ZIP files contain a windows file structure which does not contain the appropriate linux based file permissions (linux being the O/S base system on android. The restore operation does not work - in stock form - because one looses the critical file permissions, UID and GID that are required in order for the ROM to function correctly, and in some instances from my experience, to even boot up! His update-script attempts to reinstate the appropriate permissions, UID and GIDs, however, and as dsixda admits, the process is not foolproof and does not cover all eventualities, combinations and scenarios. Thus, the issue of permissions, GID and UID remains outstanding.
For these reasons, in my humble view, the issue of permissions is critical in ensuring a successful ROM flash from [linux based] .IMG files. Once this is resolved, the rest of the process is trivial. Indeed, if this one issue could be resolved, then dsixda's kitchen would mature from a useful toolset, to a truly wonderous one-stop solution.
well i don't know what people have tried and got to work or not, but it can eb done and have been done before, one of my sliderom build was done froma nandroid
soo i guess it's up to how much effort you put into it and use the kitchen as a tool, but not only use it, cause then you fail, if you don't do some manual work, nothing 100% automated will ever be a big succes
I have a solution.
I am coding this up as we speak.
My solution will extract the file permission, UID and GID from the .IMG , for each contained file. My script then runs as part of the update-script (i.e. RUN_PROGRAM restore-protection) subsequent to a ROM flash. Thus, the resultant file structure after a ROM update is exactly the same as that contained within the .IMG files.
EDIT:
coding complete.
will test tomorrow on existing phone + sdcard.
The purpose of this exercise is to 'clone' an existing phone software load, as ROM file, that can then be flashed. My script takes all partition images (system, data, cache, sd-ext and so on), creates a ROM that includes functionality that will - when flashing - restore the exact permissions, GID and UID as written in the backup files (.IMG), thus cloning the phone.
I plan to update the script in future so that APK files can be added or removed, and additional low level features such as kernel pre-empting, scheduling and other features can be added --- I think they call this "a kitchen" in Android speak.??
From your description of what you're doing it sounds like you could end up with the simplest and closest to a one click kitchen that allows users with less knowledge to fully backup / restore / clone their phone (rom, personal settings, data and all). A lot of noobs might like this tool big time
Any progess made on this? I have been trying to create a rom for a nandroid backup. When I go to flash it, I get symlink errors and the flash fails.
dazxda said:
I have a solution.
I am coding this up as we speak.
My solution will extract the file permission, UID and GID from the .IMG , for each contained file. My script then runs as part of the update-script (i.e. RUN_PROGRAM restore-protection) subsequent to a ROM flash. Thus, the resultant file structure after a ROM update is exactly the same as that contained within the .IMG files.
EDIT:
coding complete.
will test tomorrow on existing phone + sdcard.
The purpose of this exercise is to 'clone' an existing phone software load, as ROM file, that can then be flashed. My script takes all partition images (system, data, cache, sd-ext and so on), creates a ROM that includes functionality that will - when flashing - restore the exact permissions, GID and UID as written in the backup files (.IMG), thus cloning the phone.
I plan to update the script in future so that APK files can be added or removed, and additional low level features such as kernel pre-empting, scheduling and other features can be added --- I think they call this "a kitchen" in Android speak.??
Click to expand...
Click to collapse
Do you have a link?
dazxda said:
I have a solution.
I am coding this up as we speak.
My solution will extract the file permission, UID and GID from the .IMG , for each contained file. My script then runs as part of the update-script (i.e. RUN_PROGRAM restore-protection) subsequent to a ROM flash. Thus, the resultant file structure after a ROM update is exactly the same as that contained within the .IMG files.
EDIT:
coding complete.
will test tomorrow on existing phone + sdcard.
The purpose of this exercise is to 'clone' an existing phone software load, as ROM file, that can then be flashed. My script takes all partition images (system, data, cache, sd-ext and so on), creates a ROM that includes functionality that will - when flashing - restore the exact permissions, GID and UID as written in the backup files (.IMG), thus cloning the phone.
I plan to update the script in future so that APK files can be added or removed, and additional low level features such as kernel pre-empting, scheduling and other features can be added --- I think they call this "a kitchen" in Android speak.??
Click to expand...
Click to collapse
Hi, could yo share your script? I'm also working on something similar, and could use a bit of help
OMG this is exactly what I need.. I read all the way to the end and then ARRGGGGGG.. no more responses in months. Have you made this script yet? If no .. does anyone else have instructions on taking a nandroid backup and creating an IMG or ?
My personal reasons.. I have a Craig CMP741E tablet that is stuck in the android logo screen after attempting the factory update.. the one that crashes EVERY1's tablet. And there is no working way that I have found to fix it. No custom roms or factory roms that can be flashed without FIRST having the tablet ON and turn on USB Debugging or already have CWM installed. So I cannot use ADB or any other method I can find to do this.
I have a buddy with the same tablet that is rooted and has GAPPS and everything on it. He gave me a copy of his nandroid backup but now I cannot find anything I can actually do with it. If I can turn it into an Update.zip or IMG I can simply put on SD Card.. restart and cross my fingers.
lilc420 said:
OMG this is exactly what I need.. I read all the way to the end and then ARRGGGGGG.. no more responses in months. Have you made this script yet? If no .. does anyone else have instructions on taking a nandroid backup and creating an IMG or ?
My personal reasons.. I have a Craig CMP741E tablet that is stuck in the android logo screen after attempting the factory update.. the one that crashes EVERY1's tablet. And there is no working way that I have found to fix it. No custom roms or factory roms that can be flashed without FIRST having the tablet ON and turn on USB Debugging or already have CWM installed. So I cannot use ADB or any other method I can find to do this.
I have a buddy with the same tablet that is rooted and has GAPPS and everything on it. He gave me a copy of his nandroid backup but now I cannot find anything I can actually do with it. If I can turn it into an Update.zip or IMG I can simply put on SD Card.. restart and cross my fingers.
Click to expand...
Click to collapse
Can you access the tablet's fastboot mode? Turn the tablet fully off, then hold the Menu button and the Power button. I don't have your tablet, but it's a standard boot mode.
Make sure you have the tablet connected to the PC. You should see it pop up in the Device Manager, or by doing "fastboot devices" from a command prompt.
If you can get there, you may be able to flash a recovery image.
Hi, does anybody knows if there is a response for this post??, i am looking for a method to convert the images files that are included in a rom stock (for using with sp flash tool) to an update.zip file. I have no way to use sp flash tool because my tablet has a hardware problem with microusb port and the only way is flashing a new rom via microSD card with an update.zip..
Maybe the solution is in another thread, please be kind and give me a link or at least give me some suggestions where to look for.

status on rooting cliq

I found this on http://cliq-development.com/forums/viewtopic.php?f=5&t=13
hopefully this can help anyone who is trying to develop a way for root on the cliq.
To get where we are at in development you must learn about a few things
.SHX = A re-flashing file similar to a .nbh on the HTC brand. It is a full re-flash of everything on the phone, full stock. When extracted it creates three files the main one is the CG2
CG2 = A file extracted from the shx that hold the main partitions that will be flashed to the phone.
-----------------------------------------------------------------------------------------------------------------------
How to extract a shx
(http://modmymoto.com/forums/showthread.php?t=525344)
A developer by the name of Meiner Einer created a program named SbfRecalc. With this program we can extract three files and as i stated above the most important one is the CG2
How to extract a CG2
(http://modmymoto.com/forums/showthread.php?t=525477)
A developer by the name of Skrilax_CZ created a program named CG2 Parser. With this program we can extract all of the files within the CG2.
-----------------------------------------------------------------------------------------------------------------------
After you extract all of the files from the CG2 you will find that some of the names were similer to the partitions of the cliq. With a little file manipulation i recreated a boot.img and a recovery.img from some of the files. The guys over at modmymoto dumped a full system partition.
(http://android-dls.com/wiki/index.php?t ... oot_Images)
To recreate both the boot.img and the recovery.img just do these simple steps
1. Create a directory and put either bootsec.mbn or recoverysec.mbn from the CG2 dump inside it
2. Download the split_bootimg.pl from the link above and run it with the file in the directory to get both a kernel and a ramdisk file.
3. Using the mkbootimg from the android source code you can recombine the kernel and the ramdisk files to create your boot.img/recovery.img strait from the re-flash file
------------------------------------------------------------------------------------------------------------------------
With the system dump from modmymoto and my boot.img(+a little root) I created an update.zip file with root ready to be flashed when the keys are ready.
This is where we are at any help would be greatly appreciated.
Wow, nice work!
This could really so with a sticky...
Thanks for the update! The cliq goes hard. Once rooted its ova, best android phone on tmo!
Nice! It would be really great if you could repost this at android-devs.org over in the cliq development section of the forum
Since XDA is only for HTC phones and most people here most likely don't have the cliq and there really isn't a correct forum to have this posted in..
I'd reccomend using android-devs.org forums

Need a smaller boot.img

Hi All
Thank you for the great work however in order to enjoy the ROMS I will need to have a smaller boot.img in order to flash the roms.
The image must be 2.35 MB at most, A good example is the Enomther ROM that is flashable.
However the CM6 roms are not (except KANG O RAMA).
Since I dont think that someone is going to do it for me, can you at least explain how can I do that?
There are at least 10 more people that check this forum regulary looking for a solution.
Thank you.
CM6 boot image is just 2.25MB!!!
OHH yea.... checked it out on his site yesterday, then how come rodriguez's image is bigger?
He's most probably using another kernel for CM6, just like MicroMod uses another kernel for TheOfficial.
OK. How can I use those features with a smaller kernel? Is there a way?
1) Ask the kernel / ROM creator to "pack" it to fit in 2.5MB of space.
2) Compile your own kernel and make your own boot.img.
3) Try to mix your desired ROM (for example, Micromod's) with the kernel that fits your limited boot space (for example, Enomther's original). Or you could try to use rodriguez's ROM with CM kernel. To do that mix, replace the boot.img and the WiFi driver - bcm4329.ko - in their locations in the original ROM zip and resign the zip, then flash it.
Why the need for a smaller boot.img?
Sent from my Nexus One using XDA App
HTCinToronto said:
Why the need for a smaller boot.img?
Sent from my Nexus One using XDA App
Click to expand...
Click to collapse
Many N1s do not allow kernels later than 2.4MB (or something like that)... the kernel does not flash because of bad MTD blocks...
Jack_R1 said:
1) Ask the kernel / ROM creator to "pack" it to fit in 2.5MB of space.
2) Compile your own kernel and make your own boot.img.
3) Try to mix your desired ROM (for example, Micromod's) with the kernel that fits your limited boot space (for example, Enomther's original). Or you could try to use rodriguez's ROM with CM kernel. To do that mix, replace the boot.img and the WiFi driver - bcm4329.ko - in their locations in the original ROM zip and resign the zip, then flash it.
Click to expand...
Click to collapse
OK. Thanks.
Can you send me a link with the instructions on how to change and resign roms?
[sorry for being a noob]
Unfortunately, I don't have any instructions available anywhere, but you can use some Google searching.
The boot.img resides in the root of the ZIP, the bcm4329.ko is in /system/lib/modules/.
Changing the files in the ROM is easy - ROM is just a ZIP file, you take a ROM you want to change, open it in WinZip / WinRar / your favorite freeware archiver, find the files you want to replace (the ones I've mentioned above), download the original ROM which is the base (Enomther for MicroMod, CM6 for Rodriguez), extract those files from there, drag&drop them into the ROM you're modifying, that's it.
Then you search Google for "android sign zip apk", and you get a couple of guides that show you how to sign ZIPs.
Then you load the ROM and hope it works.
does not sound complicated
thanks.... I will try that.
Yes, what you need is:
boot.img and everything in /system/lib/modules
It's important that you replace everything in /system/lib/modules with the correct content for the specific boot.img you're using and delete everything else.
My boot.img which is based on Wildmonks BFS 950 kernel supports apps2ext and 720p and should be sufficient for any CM6 rom. It's worth noting that the current one in Kang-o-rama 1.0 Final is not as stable as I would like and I'll be updating it soon.
Since this seems a bit challenging for some rom devs an alternative approach could be:
Create update.zip for small boot image (I can help with this)
Rom dev creates rom update.zip without a kernel (may not boot properly)
Install rom without kernel
Install small kernel update.zip
Or everyone could use Kang-o-rama...

[Q] Converting SD build to Nand problem

Im having an issue with a project i have been playing with. Im not a dev just someone who is experimenting with roms and i have been trying to convert the hyperdroidsense build into a nand rom. I keep getting a kernel error after i flash the system.img and boot.img. Could someone offer me incite into this problem? I think the problem is the boot.img, specifically the init.rc. All i did was convert all the orginal files into the .img. Do i need to edit something in order for it to work on NAND?
nobody knows nothing??????????????

[Q] Need help modifying system.img

Hello everybody... I was off for a few weeks and now when I'm back I suddenly felt like doing something new... and when i was looking into some folders that i had from my Android SDK i noticed something named system.img in my level 8 android platform... previously i was enthusiastic to install first google apps in virtual android in my windows then try to install a Custom ROM such az OxyGen or CM7.0.3.... so i guessed that system image must contain the files to do this... over a lot of search i found the tool to extract it.. I extracted it with UnYaffs... the i injected(!) the google apps APK from the latest zip (20110613) file... and something i wondered about is that you can extract from an Yaffs archive but you cannot create one in Windows.. SO I FIRED UP MY UBUNTU....(!!!) and created the image... then transferred it to windows made a backup of the original system.img and replaced mine... before that having all my virtual android machines deletd(I mean wiped from my system!!!)...As normal i created a AVD(Android Virtual Device) from my modified platform... everything went right and it created successfully but when I was starting my AVD everything suddenly changed into bad... It's stuck on the TEXT saying ANDROID... i mean the first text not the second graphic that is Android's name in iron like gray-blue color....
I don't know what has caused the problem.. anyone got his hand dirty on this system.img file?
I guess it might be from that it must be Yaffs1 but i created a Yaffs2 archive... didn't I??? but since I haven't got any Yaffs1 archive maker for ubuntu I can't test...
And I'm sure that the system.img is created fully and not partly... because I UnYaffs-ed it many times and the files do contain in it...
AnY HeLp??

Categories

Resources