[Q] How to run android froyo in kaiser (missing system.img message) - Android Software Development

I've been a bit away from the android/kaiser scene, so I think things have changed a bit since then.
How do you start android nowadays?
In the following page, it says to extract haretinstall.zip, but it doesn't seem to be among the files on SF.
http://sourceforge.net/apps/trac/androidhtc/wiki/HowToInstall
http://sourceforge.net/projects/androidhtc/files/
I then got the the haretinstall.zip from:
http://switch.dl.sourceforge.net/project/androidhtc/2010-02-20/haretinstall.zip
I expanded the file, which gives me the andboot folder.
I then got the latest zimage and haret.exe from dzo page:
http://it029000.massey.ac.nz/vogue/files/?C=M;O=D
I configure the default.txt with the default-kaiser.txt (I have a kaiser), everything inside the andboot folder. (and does andboot stands for, btw?)
I got latest Incubus26Jc's Super FroYo RLS15 All Language.zip (link below), extracted the androidinstall.tgz and copied inside the andboot folder.
http://forum.xda-developers.com/showthread.php?t=712310
When I boot android it says "fail to reach system.img on the SD card". From what I read somewhere the system.img isn't part of the installation anymore, right?
Where can I find instructions to start from scratch? Step by step, with links for all the needed files?
I found something here, but not sure if it is updated, and also it isn't complete either:
http://www.androidonhtc.com/wiki/Installing_Android

Opps...
Seems I made the mistake of not reading carefully the instructions
I missed the install system part, pressing the central button of the dpad.
I'm in the installing process now, will get back if have more problems.
update:
it finally boots, but the screen seems to be reduced to a 1/4 on the top left corner, and I can't actually click or run anything, with the exception of the call. It asks if I want to use the launcher or the laucher pro. Using the launcher I can actually see the programs available, but most of them don't seem to work.
The console also keeps showing now and then. After the camera seem to be activated and failed, the console got enabled and the mobile froze.

Related

[Q] newb trying Dextermod 1.3

I downloaded the Dextermod 1.2 without issue to my sd card, but applying mod didn't not show android market but did erase any apps loaded from appoke market. So I found and tried to download 1.3, but it does not ask to change file name and then says download unsuccessful in the notifications bar. Tap it and get popup, "Cannot download. The content is not supported on this phone." So I try the 1.2 mod again and get the same message. Anyone else with this problem or can help me with a fix?
Downoad it on a computer and put it on your sd, android webkit browser doesnt like zip files.
Rename it Update.zip before running.
Looks like your new like me. I downloaded to sd card. (make sure card is clean. I had a problem with that first-no windows files) Also I downloaded file from my pc to the card in a dongle Then transfered card to the A7. went to file manager. found the file on the card (elocitymodv13) under sdcard\sdcard-disk0 and then press on it until menu came up and hit rename and then renamed it update.zip. finally go through the routine of powering off A7, then hit power key for 2 seconds, let off, and then hit power button again until message comes on screen about entering recovery mode.
Then use the menu key on side of screen to enter recovery menu once the android image shows up. you then need to use search key and back key on side of screen to move up and down the menu. First move highlight down to "Wipe/factory reset" and hit menu button to apply command. (Dexter recommends wiping the slate clean to ensure proper function of his mod.) When that is done, you will see the menu again and move down to "apply sdcard:update.zip" and hit menu buttom to apply command. this will then put the new mod. on the system. The only other thing that will be neccessary is to go back and download the "ElocityMod v1.3 bluetooth fix" http://forum.xda-developers.com/showthread.php?t=890042 . This update gets applied the same way as above except you dont obviously need to use the wipe/factory reset command again. This will give you bluetooth function back. I hope this is clear enough.
I have been trying since I got the thing to tether it to my windows mobile phone. Good luck with that. I still haven't found an answer. take care.
file name
as stated
download the file to your computer. then rename it to update. Just
update
You don't need to put .zip at end because its already a zip file. Then transfer it on to your sd card. Easiest way is to open your My computer drag and drop to the dir that is sd card on your computer that way it automatically goes into the root of the sd card.
then do the as stated flash update procedure.
t_sandat8 said:
as stated
download the file to your computer. then rename it to update. Just
update
You don't need to put .zip at end because its already a zip file. Then transfer it on to your sd card. Easiest way is to open your My computer drag and drop to the dir that is sd card on your computer that way it automatically goes into the root of the sd card.
then do the as stated flash update procedure.
Click to expand...
Click to collapse
Jesus, this just doesn't stop.
The file NEEDS TO BE Update.zip
Please read the writeup I just made this morning describing why people are getting screwed up on this, how to fix it, and why I rag on people like you who put out misinformation.
http://forum.xda-developers.com/showthread.php?p=11745552#post11745552

The comprehensive guide to put a custom ROM on your X8 for NOOBS! (2.3)

Hello,
I decided to write this because I had a hell of a time finding out how to do this - all the information is here on the forums but not all in one place so you can just read and install the custom ROM.
The ROM that is available that I have successfully tested is CM7_RC1_X8_004
You will need the following programs:
SuperOneClick - to root your phone
Busybox - from the android Market
Xrecovery
Super Manager - from the Market
X10 Flashtool
and your ROM
Rooting
~~~~~
So First we want to root the phone, we will need to set the USB debugging mode to on. Go into settings - applications - Development and click on the tick next to USB debugging to turn it on. Plug the Phone into the PC via the USB Cable.
At the end of this post are files download SuperOneclick and extract it into a folder on your desktop then run the exe file called SuperOneClick.exe and click on root, it will scroll through a load of things then come up with a message that says "Root files have been installed would you like to run a test?" To which I always say Yes then it says "A su command will now be sent to your phone please hit allow in superuser" (there were no messages on my phone so I just hit OK on that message) Then a message comes up asking you to donate, so if that utility is handy for you feel free to donate to the makers of SuperOneclick!
You can now turn off USB debugging.
Installing BusyBox
~~~~~~~~~~~~
Go to settings - sound and display and set the screen timeout to 30 mins I have found it to keep locking while installing Busybox as it takes a while to do.
Go to the market and search for Busybox and install and accept permissions on it. once this part of the application has installed you need to run it as it has only been copied to the phone - now you have to actually install it.
So run the busybox app and say OK to the message from the developer (reading it first of course) then it will ask you for permission which you say yes.
Next we see a screen saying Status: Working, Your phone is Rooted, amount of free space in system is 10128kb, Busybox not found. (we haven't installed it yet.)
The first time I did this it took ages to get anywhere and ages to install so just be patient and wait for it. Choose Busybox 1.17.1 but change the location of the install to system/xbin (the drop down box at the bottom of the page.) Then Click Install. For me this time it failed so lets try v 1.18 and the default location. back up and then relaunch busybox installer.
I found I had to change the settings a couple times when I installed before to get it to install, you might not find that. Sure enough this time it installed fine using v1.18 and the default save location.
installing Super Manager and Xrecovery
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
First you need to download the new ROM files from here:
http://forum.xda-developers.com/showthread.php?t=973753
Go to the third post and download the rom: (currently
http://hotfile.com/dl/109568508/3381b40/CM7_RC1_X8_004.rar.html)
Once it's down extract the files to another folder in your desktop and you should have the files LiveWallpapers.zip, Update.zip, changelog.txt and a BASEBAND folder.
Then connect your phone and copy the three files and the folder to a new directory on your SDcard. (I called mine ROM) Now remove the cable from the PC not forgetting to unmount it first.
Then you need to download Super Manager from the market and install it then run it - choose File explorer - click on the favourite icon at the bottom(the picture of a folder and a heart) and choose SD card, navigate to your folder where you stored the files and click on all the ticks next to the files and folder and then when they are all selected click on any file and hold it till a menu appears and choose copy (This is to copy the files)
Then Click on the favourites one again and choose root path. Then go to System and then Bin and then click on one file and hold the button till the menu appears and scroll to the bottom where you see paste and click on it and this will paste the files into this folder.
X10 Flash tool
~~~~~~~~~~
Next we need to use the X10 Flastool so download it from
http://www.multiupload.com/GYL7A7XQBT
(The thread I got this from is: http://forum.xda-developers.com/showthread.php?t=920746).
Once downloaded you need to extract the files and run X10FlashTool.exe.
Then before you plug the phone back in you need to put it into USB debugging mode again. Go into settings - applications - Development and click on the tick next to USB debugging to turn it on. Plug the phone back into the PC.
In the X10Flashtool click on the button that says ask root perms and press allow on the phone when it comes up and in the FlashTool it will say "INFO - Root Access Allowed."
Then Click Optimize and it will then reboot your phone, let the phone come back up and then in x10 Flasher click ask root perms and it should say Allowed again after a short time.
Then click on xRecovery. Power the phone off and wait for 20 seconds and then power it back on. As soon as you see the words "Sony Ericsson" appear on the screen start hammering the back button. Then the phone will boot into xRecovery.
Backup your phone
Use the sound volume up and down buttons to move up and down the menus and the home button to select the option (I think the back button is back as well). Choose the backup/restore option, then backup to backup your phone to the SD card (First the system and then the data)
Then when it's finished it will say complete and you can go ahead and put the new rom on the phone. Choose install Custom Zip, then choose custom zip from SDcard. Navigate to the directory you put your ROM in and choose update.zip it will ask you if you are sure so choose yes and it will update your phone.
Once it says Install from SDcard complete hit backup then choose the top option reboot phone.
Your Phone will then reboot into Android 2.3
Good job on this
Restoring your Phone to It's previous working state
To restore you phone back to how it was before you started all this all you need to do is Boot xRecovery by hammering the back button once you see the very first Sony Ericsson which takes you into xRecovery.
Then use the volume up and down on the side of the phone and choose backup and restore and you can choose advanced restore to restore a different component or just do a restore to do the whole phone back as it was.
I have just restored back successfully!
is there a big risk that i will damage my phone in case i will do everything in #1post step by step with instruction?
I don't really think so, but there is always the possibility when flashing your phone that you might Brick it.
I didn't break mine and I will do this to test every new firmware that comes out and because I've done it once most of the hard work is done which was installing xRecovery.
In short I offer you no guarantee this won't brick your phone what you do is at your own risk, but I had no trouble.
Yeah i know this that im doing it on my own risk, im only asking of probability of breaking phone cus i want root and install custom rom but i have a little bad luck
OK,
I don't know about failures - I haven't seen anyone complaining about destroying their phone and it didn't happen to me, that's all I know sorry.
super manager isn't copying and pasting files. i follow the guide and when i click paste, nothing happens.
edit: it just says "prepare to copy" when i try to copy the files, then nothing when i paste
stef.t97 said:
super manager isn't copying and pasting files. i follow the guide and when i click paste, nothing happens.
edit: it just says "prepare to copy" when i try to copy the files, then nothing when i paste
Click to expand...
Click to collapse
In supermanager open the folder system and then select the folder Bin, you have to change the folder from read to read and write first before u can copy anything.
thanks, realized i hadn't given super manager super user permission. what do i do differently when installing Rachts Roms because they don't come with an update.zip?
stef.t97 said:
thanks, realized i hadn't given super manager super user permission. what do i do differently when installing Rachts Roms because they don't come with an update.zip?
Click to expand...
Click to collapse
When u have Xrecovery and make an backup it will create a folder in SD card "backup" after u download the Rom from racth u put the folder on the backup folder, then in XRecovery u go to backup then restore, u will see the rom there, just press ok and it will do the rest like the zip file.
to the OP thanks a Lot i appreciate this Guide!
and on the same vein as the others i am having some problems pasting the contents of the ROM. i have given Super manager root prves. but it says not enough free desc space which seems right to me cus there is only 128Mb storage on the phone.
i feel like i am missing sumthing basic please assist me, Thanks!
skowrone said:
Yeah i know this that im doing it on my own risk, im only asking of probability of breaking phone cus i want root and install custom rom but i have a little bad luck
Click to expand...
Click to collapse
Just need to be well prepared!!!!
Based on my experience.. I didn't really know what I've done that make my phone cannot boot... it's all because not really prepared... Need to do some research and reading 1st..
Luckily, when done some reading, I manage to boot the phone after flashing with SEUS..
And after that... I prepare to do checklist... Now.. Everything seems OK...
genghisk said:
to the OP thanks a Lot i appreciate this Guide!
and on the same vein as the others i am having some problems pasting the contents of the ROM. i have given Super manager root prves. but it says not enough free desc space which seems right to me cus there is only 128Mb storage on the phone.
i feel like i am missing sumthing basic please assist me, Thanks!
Click to expand...
Click to collapse
With your phone did you get a 2GB SD card? I did with mine and that's where you need to copy the ROM files to(you need to copy the files in windows to the SD card). The only thing I was copying with super manager was the xRecovery files. (and I'm not sure I needed to do that since you kinda install xrecovery on the flash tool, I just posted exactly what I did)
mss_2212, yeah using the SE repair might get you out of a few scrapes, it's good that they offer such a utility to completely flash your phone back to the latest SE update!
Well, V6.0a is now out I am downloading that as we speak.
^^ how is it running? i see BlueTooth not working.
i realize my error you were talking about copying the files for Xrecovery i thought you were referring to the ROM files.
Thanks for the help! I hope I success for the install of the last custom rom from CM 2.3! If it's good, it will be translate for the french forums! ;-)
I'm still setting it up to how I like it but so far so good - it's nie and stable for me and WI-FI works which is a dream.
Don't forget to make a backup first of your old ROM though!
Thanks
Hi!
I tried to install the last 2.3.3 CM7 with this guide, but I get a problem with the X10 flashtool... In fact, I don't understand if I have to lauch the .exe in my phone, or in the PC. Because with the phone I can "ask root perms" but I get an error (it says me to use usb debug the phone and install...) but I think that I've followed the guide And since the PC, there is no file in the "firmware" fold...
So I install the custom ROM, without that step, and it success, even if I get another problem, but I think, because of the instability of the rom (no market, and no possibility to dl by internet)
Thanks for the help!
Hello,
Not quite sure what you're getting at, I will try to help if I can (I'm still a bit of a noob really myself)
You need to run the x10 flash tool on the PC with your phone connected in usb debugging mode before it will work.
"Then before you plug the phone back in you need to put it into USB debugging mode again. Go into settings - applications - Development and click on the tick next to USB debugging to turn it on. Plug the phone back into the PC."
The Market and other applications are included in the latest version(.6a as of this writing) in a zip file called gapps-gb-20110307-signed.zip to install them you need to boot into xRecovery and choose install custom zip and then point it to that file which is next to the install.zip. Then the market will work.
v.6a is really nice but ultimately I had to revert because I needed to take some pics but a lot of stuff is working well!

Help!! Problem hd2 dual boot (ics 4 & Wm6,5)!!!

Hello everybody!!!
I'm a very noob user, so i please a need a step by step help!
I tryed to install a dual boot on my hd2, with android ICS (MIUI) on SD, and windows mobile 6,5 on NAND.
To get that result i used this Guide: http://forum.xda-developers.com/showthread.php?t=1504369
..but, in the the guide is written:
"Instructions:
Well you know just extract everything and put the miuiics folder in your root of sd card, you know the rest.."
maybe a link to the guide is better then "you know the rest..."!
I don't Know the rest, and I proceded in this way:
1) Inistalled the MAGLDR
2) copyed the rom of android on a SD card
3) Configured the setting to make a boot to SD and Android working perfectly!!
Now I even need to use windows mobile 6.5, but I don't know to switch on it!
I think that MAGLDR is overwritten on WM6.5 rom, and now I have a phone with only android, where is impossible to make a dual boot!!!
Anyone can write me the procedure step by step to retry to install correctly the dual boot with WM6,5 and android MIUI ics? Is even good a link with a guide that I didn't found!!!
I have 2,08 HSPL.
Thanks anticipately for your explains!
Nick.sf
nick.sf said:
Hello everybody!!!
I'm a very noob user, so i please a need a step by step help!
I tryed to install a dual boot on my hd2, with android ICS (MIUI) on SD, and windows mobile 6,5 on NAND.
To get that result i used this Guide: http://forum.xda-developers.com/showthread.php?t=1504369
..but, in the the guide is written:
"Instructions:
Well you know just extract everything and put the miuiics folder in your root of sd card, you know the rest.."
maybe a link to the guide is better then "you know the rest..."!
I don't Know the rest, and I proceded in this way:
1) Inistalled the MAGLDR
2) copyed the rom of android on a SD card
3) Configured the setting to make a boot to SD and Android working perfectly!!
Now I even need to use windows mobile 6.5, but I don't know to switch on it!
I think that MAGLDR is overwritten on WM6.5 rom, and now I have a phone with only android, where is impossible to make a dual boot!!!
Anyone can write me the procedure step by step to retry to install correctly the dual boot with WM6,5 and android MIUI ics? Is even good a link with a guide that I didn't found!!!
I have 2,08 HSPL.
Thanks anticipately for your explains!
Nick.sf
Click to expand...
Click to collapse
First link explains how get Android installed and running from SD using CLRCAD.EXE and HaRet.exe = "you know the rest..."
http://forum.xda-developers.com/showthread.php?t=732380
and also a link how to get WM back on the HD2.
http://forum.xda-developers.com/showthread.php?t=609477
BTW: the link you attached is not a guide, it is the ROM itself with few instruction for people who have already some experiences
Cheers.....LinChina
Please do some more reading before flashing anything, if you didn't have an HD2 you would probably end up hard bricking your device if you didn't read. MAGLDR replaces WinMo. You need to boot into the bootloader, flash an official stock ROM via USB then run the SD build via CLRCAD and HARET.
LinChina said:
First link explains how get Android installed and running from SD using CLRCAD.EXE and HaRet.exe = "you know the rest..."
http://forum.xda-developers.com/showthread.php?t=732380
and also a link how to get WM back on the HD2.
http://forum.xda-developers.com/showthread.php?t=609477
BTW: the link you attached is not a guide, it is the ROM itself with few instruction for people who have already some experiences
Cheers.....LinChina
Click to expand...
Click to collapse
thanks a lot!
Later I will tray again! I'll let you know!!!
However in the guide you gave me, do not talk about Android ICS, but the previous version!!! "you know the rest..." continues to be a bit vague!!
Nick.sf
Nigeldg said:
Please do some more reading before flashing anything, if you didn't have an HD2 you would probably end up hard bricking your device if you didn't read. MAGLDR replaces WinMo. You need to boot into the bootloader, flash an official stock ROM via USB then run the SD build via CLRCAD and HARET.
Click to expand...
Click to collapse
Thanks, but i tryed with CLRCAD and HARET without result!!!
Mayby "Android loader V6" isn't the bootloader corretc?
when I select CLRCAD and HARET, the phone lounch first screen of android loading, but then, the phone restarts!!!
nick.sf said:
Thanks, but i tryed with CLRCAD and HARET without result!!!
Mayby "Android loader V6" isn't the bootloader corretc?
when I select CLRCAD and HARET, the phone lounch first screen of android loading, but then, the phone restarts!!!
Click to expand...
Click to collapse
OK you seem to be very confused with your terms, so I'll simplify things for you:
1. Turn the phone off
2. Boot into the bootloader (stripey screen) by holding power and volume down
3. Flash the latest 3.14 stock ROM (WinMo) for your particular device (see on HTC's official website, it has the downloads plus a guide)
4. Place the 'Android' folder on the root of your SD card. Note that the name of this folder may vary from build to build, but it is always the folder containing all of the files.
5. Boot into WinMo then find the file explorer
6. Open the 'Android' folder (or whatever it's called) and find the file 'CLRCAD.exe' and run it. You will not see any visual change
7. Find the file 'HARET.exe' and run it. Android will be booted.
8. After first boot, be patient. Give the device time to settle and then once everything seems fine (after at most 5 minutes) reboot.
9. Once you reboot, you will have WinMo again. Simply repeat steps 6 and 7 to boot into Android.
If this guide isn't simple enough for you, then in all honesty I don't think I can help you much, you'll have to find someone who's more noob-friendly
Nigeldg said:
OK you seem to be very confused with your terms, so I'll simplify things for you:
1. Turn the phone off
2. Boot into the bootloader (stripey screen) by holding power and volume down
3. Flash the latest 3.14 stock ROM (WinMo) for your particular device (see on HTC's official website, it has the downloads plus a guide)
4. Place the 'Android' folder on the root of your SD card. Note that the name of this folder may vary from build to build, but it is always the folder containing all of the files.
5. Boot into WinMo then find the file explorer
6. Open the 'Android' folder (or whatever it's called) and find the file 'CLRCAD.exe' and run it. You will not see any visual change
7. Find the file 'HARET.exe' and run it. Android will be booted.
8. After first boot, be patient. Give the device time to settle and then once everything seems fine (after at most 5 minutes) reboot.
9. Once you reboot, you will have WinMo again. Simply repeat steps 6 and 7 to boot into Android.
If this guide isn't simple enough for you, then in all honesty I don't think I can help you much, you'll have to find someone who's more noob-friendly
Click to expand...
Click to collapse
Thank you so much for the help, but i just tryed this way!!!
In my situation, at point 8 of the guide, my phone restarts after about 30 second (no 5 minute) and then go in loop...
After the restart, the phone enter in WM and ask me to run CLRCAD.exe, and HARET.exe (in this order) and i accept.
The phone starts the loading screen of android, and restarts again.
It always restarts, without going into Android! I have seen at least 10 restarts before try to install Magldr!!!
I don't know the cause, but i think that android ICS is not compatible with the "Android loader V6". I used this loader with android gingerbread without problem!
Now in the link with ROM, i read:
"Ported using Portadroid Ultimate v4.0: http://forum.xda-developers.com/show....php?t=1094372 "
but the page does not exist!!!! What is portadroid ultimate? is it the bootloader?
I'd not worry about the bootloader and other terms much if I were you, it's not important for SD Android anyway
I apologise if I can't be much more use but I haven't used SD Android in a long time . The only thing I can think of is this: EDIT: see bottom of the post first, then try this
1. Find the SD Android build which you have downloaded on your PC
2. Open the folder and find the file 'startup.txt'
3. Find the line 'Rel_path=' and make sure that the next word matches the name of the folder in which the build is stored, for example if I had an SD build with the folder name 'Android', that line in startup.txt should also say 'Rel_path=Android'.
The only other thing I can think of is that somehow the folder isn't in the root of your SD card. Make sure the folder which contains the files (so in the example I gave previously this folder would be called Android) is copied to the root of your SD card. There should be no sub-folders or anything like that, just /Android.
EDIT: I think I may have found it now, try uninstalling the automatic loader app you have (Android Loader V6) and running these files manually rather than doing it automatically. If I'm not mistaken, this app looks for a folder named 'Android' by default, but the name of the folder your ICS build is stored in may be something different.
Just to add that ICS SD builds are often in an 'ICS' folder instead of 'Android'
It shouldn't matter using CLRCAD.exe, and HARET.exe though.
Nigeldg said:
I'd not worry about the bootloader and other terms much if I were you, it's not important for SD Android anyway
I apologise if I can't be much more use but I haven't used SD Android in a long time . The only thing I can think of is this: EDIT: see bottom of the post first, then try this
1. Find the SD Android build which you have downloaded on your PC
2. Open the folder and find the file 'startup.txt'
3. Find the line 'Rel_path=' and make sure that the next word matches the name of the folder in which the build is stored, for example if I had an SD build with the folder name 'Android', that line in startup.txt should also say 'Rel_path=Android'.
The only other thing I can think of is that somehow the folder isn't in the root of your SD card. Make sure the folder which contains the files (so in the example I gave previously this folder would be called Android) is copied to the root of your SD card. There should be no sub-folders or anything like that, just /Android.
EDIT: I think I may have found it now, try uninstalling the automatic loader app you have (Android Loader V6) and running these files manually rather than doing it automatically. If I'm not mistaken, this app looks for a folder named 'Android' by default, but the name of the folder your ICS build is stored in may be something different.
Click to expand...
Click to collapse
aldaweb said:
Just to add that ICS SD builds are often in an 'ICS' folder instead of 'Android'
It shouldn't matter using CLRCAD.exe, and HARET.exe though.
Click to expand...
Click to collapse
That is correct. If I read it right, Android Loader had been set up already for a previous build. When you do this, you tell the app what folder to look for - i.e. "Android". Now that you have a different build, different folder name, the app cannot find all the associated files to boot from SD properly.
Your folder name is miuiics

[guide]how to build/modify roms for samsung devices [7.0/6.0.1/maybe more]

Firstly, by no means, I am a great developer or an expert. I have been developing ROMS for Samsung Galaxy Note 5 lately. I was also a noob before making all this. But by reading various guides on XDA, learning from many many great developers/contributors on our Note 5 Forums and talking with various friends which I made on XDA, I know quite a bit about ROMS and MODDING in general. So, here I would like to share all which I have learnt so far, and will be updating this guide regularly.
WARNING!​I am not all responsible for what you do to your device, whether you blow it up, or you got late to reach your office, coz alarm never sounded, or your girl friend dumps you for not picking her phone(boy friend never do that).. Neither me nor XDA is responsible for that.
CREDITS​
My brother, my teacher, my great friend, @andyaguilar94, who was the first I contacted ever via a PM and he was so kind to teach me stuffs and helped me learn whatever I have learnt today.... Thanks a lot bro...
@CrsMthw and @Androidwizzard, for always helping me solving my issues with the ROM and being so so so and so humble to listen to all my crap and being a constant support to me...
@karan2012, @pelpa87, @Ather, @diegonnec for being my great friends, helping me out in various things, pointing out my silly mistakes and being there for me anytime I needed them...
@ASSAYYED and @zxz0O0 for their Awesome tools (Kitchen and SamFirm)
If I forgot to mention anyone, I would love to add them to this list...
PRE-REQUISITES BEFORE GOING FURTHER​
TWRP or any other Recovery installed on a rooted Samsung device
NotePad++
WinRAR or 7-ZIP
A Good knowledge of Windows Explorer
A Samsung Device to test on
A bit of patience and a lot of time
Before beginning, I would like to tell you guys that this is not a guide to PORT some other device's ROM to your own device. This is just a guide to modify your own device's latest firmware available and making your own ROMS... Secondly, this should work on most Samsung Devices and most of the Android versions including Marshmallow (6.0.1) and Nougat (7.0) and could work on other versions as well
CONTENTS OF THE GUIDE​
Okay, now coming back to guide, this guide will be divided in 5 sections:-
Creating a very basic ROM using Kitchen
Adding Basic Mods to the ROM (using CSC and Kitchen)
Learning about updater-script syntax and adding external features to the ROM
Learning about adding AROMA and about aroma-config syntax
Last but not the least, some tips and tricks to make your ROM even awesome
CREATING A VERY BASIC ROM USING KITCHEN​
Okay so, there are two ways of developing a ROM:-
1)Without a kitchen
2)With a kitchen (RECOMMENDED)
I will cover the method using a kitchen as it is much more efficient and time saving. Futhermore, Without a kitchen method only works for already available flashable ROMS, whereas a kitchen allows making a ROM directly from the firmware zip file.
INSTALLING AND KNOWING ABOUT ASSAYYED KITCHEN
Okay so, kitchens are basically designed to make the life of ROM Developers a lot simplers. All the functions that a kitchen offers, can actually be accomplished using File Explorer as well. But, it would require whole lot of efforts and time. So, therefore, most of the devs out there, use one of many amazing kitchens available. For this guide, we will be using ASSAYYED KITCHEN (I know, that its development is stopped, but it has a great lot of features that are available in an easy to understand way...)
So, first things first, lets download and install ASSAYYED KITCHEN
Step 1:- Download the ASSAYYED KITCHEN from this official thread, by clicking here.
Step 2:- Once downloaded, then copy the 7zip file to whichever directory you want to install this kitchen on your PC.
Step 3:- Then extract the zip file using 7zip of WinRAR.
Step 4:- If you didnt change the name of the zip file, you should see a folder named "ASSAYYED_KITCHEN_V1.82_STABLE", once extraction is completed.
Step 5:- Inside this folder, you should see a folder named "TOOLS" and an exe file named "ASSAYYED". Run this exe file. Once it is loaded, you should see a black screen with a prethora of options.
Step 6:- Now go back to the ASSAYYED Directory, where you had the "TOOLS" and this exe file, and you will be surprised to see three new folders:- "PLACE", "READY" and "WORK".
Okay so, we are done setting up the kitchen, now before we begin our actual ROM Development/Modification, let me explain you what are these folders and what do they do.
"PLACE" folder contains the base ROM zip files or your firmware zip files. This folder essentially contains the base ROM/FIRMWARE, that you are going to work upon. You will need to put the firmware zip (which I will tell you where to get) in this folder. This firmware will act as the base, on which you will make modifications and make your own ROM
"READY" folder will contain your ROM zip files. This essentially has your ROM zips that you will make and flash on your device
"WORK" folder contains the ROM files. As the name suggests, this folder is the one, we will be working on. This contains the entire ROM files (which I will explain later)
"TOOLS" folder is nothing we have to worry about for now. It essentially contains some important files and applications we might need.
As you must have seen, the kitchen has various options, and I can't explain all of them in one go, so I will explain them as we proceed through the guide.
So, finally we are done with the kitchen and stuffs, now lets download the firmware for your latest device. Well, let me share with you, how I download firmware files...
Firstly, download SamFirm Tool, by clicking here and selecting the latest zip from Post #1. Again, this is a depreciated tool, but it is important for downloading firmwares at high speed, because otherwise, if you download it from any website, they might charge you, or make the zip file available at slower speeds.
Secondly, head to this website, and in the dropdown menu, select your device and check (dont download) for the latest firmware available for your Model Number and note the "Model" and "Region".
USING SAMFIRMTOOL TO DOWNLOAD FIRMWARE
Step 1:- Once downloaded, extract the SamFirm_v0.3.1.zip file (I told you to download above) in your desired directory.
Step 2:- In the extracted folder (which should be "SamFirm_v0.3.1"), you should see a few files, but dont touch any of them, just launch the "SamFirm.exe".
Step 3:- A new window will open and in that window, you should see two columns namely, "Firmware Info" and "Download".
Step 4:- Put the "Model" and "Region" (which I told you to make a note of) in their respective sections inside "Firmware Info". Tick on "Auto"(If it is unchecked)
Step 5:- Click on "Check Update". After this, it will process about the latest firmware and will eventually fill the details in the "Download" column.
Step 6:- After this, you know the obvious step, click on "Download". Now sit back and relax, till the firmware is downloaded
Step 7:- Once the firmware is downloaded, you should click on "Decrypt".
Step 8:- After this, get to the "SamFirm_v0.3.1" directory (which contained the "SamFirm.exe"), and you should see a zip file.
Step 9:- Copy and paste this zip file in "PLACE" folder of ASSAYYED kitchen (that we talked about earlier).
Now finally, we have our firmware and kitchen in place, Now lets begin ROM DEVELOPMENT
CREATING YOUR OWN VERY FIRST BOOTABLE ROM
Step 1:- Launch "ASSAYYED.exe" from your kitchen directory.
Step 2:- As you can see, from various options, we need to begin with the very first option that is, "START CREATING PROJECT". In ASSAYYED, we select options, by typing the number next to the option we want, and pressing Enter. So, for example, we need to select "START CREATING PROJECT", we know the number corresponding to it is "1", so we press 1 and then ENTER.
Step 3:- After this, it basically asks Where to Get the Firmware, now, we know it is in "PLACE" folder and we see that the corresponding to "PLACE_FOLDER" is default. Now, I would like you to remember that specifically for this guide, wherever you see the word "default" in the kitchen, you just need to press Enter keeping it blank. So, I hope you got this.
Step 4:- Now the kitchen will search in the "PLACE" folder for the necessary zip. Select the required firmware by pressing the number corresponding to it and then enter. For example, for your very first project, it will be "1", then enter.
Step 5:- Now type the NAME of your Project. You can keep it anything or even leave it blank by pressing enter. Now sit back, relax, take a break and let the kitchen do its work.
Step 6:- Once Extraction is complete, you should see something like "PRESS ENTER TO CONTINUE". So Press Enter and now minimise the kitchen and head to the "WORK" Folder.
Now, explanation time , once you open the "WORK" folder, you should be greeted with 2 folders and a file.
First would be a "META-INF" folder. This is the directory which TWRP or any other recovery looks for when you intend to flash anything. This folder is a MUST, without which no matter how good a ROM is, you will never be able to flash it using a recovery...
Next would be a "system" folder. This is the directory which contains the main ROM, this will be the folder where we will be making small edits in various files to get various mods. Essentially, you can consider this folder as the full ROM itself.
Lastly, there would a file by the name of "boot" or "boot.img". This file is essentially the stock kernel of your ROM. This is also an essential part of your ROM zip and you must tamper with this file unless you know what you are doing
Now navigate inside the system folder. Here you will see loads of subfolders.
Let me explain you about the contents of "system" folder:
"app" folder, as the name suggests, contains various apps and services which will run on your ROM. If you navigate to this app folder, you will see another a huge list of subfolders. These subfolders contains apks for the apps.
"cameradata" folder contains various files which are essential for the camera to work.
"csc" folder is a folder which would be gem for modders. Most of the mods that you want in the ROM could be just be added with a single line, by modifying a file or two in this folder.
"fonts" contains the various fonts which will be used in the ROM.
"framework" folder is a very essential part of the ROM. It includes various jars and a few apks which are very essential for a ROM to function well.
"lib" folder contains various lib files for the ROM. And one thing to keep in mind would be to NEVER tamper with "lib64" folder, because, if you do so, your ROM might never boot, however "lib" folder can be modified to some extent like deknoxing (which I will tell you about in future posts)
"media" folder contains audio files including ringtones, notification tones, alarm tones and other System sounds
"priv-app" folder contains another set of "privilaged apps". Privilaged, because, they require some special permissions to work
"build.prop" is the most important file in your ROM. Without this file, your ROM will NEVER-EVER boot.
Step 7:- Lets first start by changing your ROM NAME. Inside the system folder, head to build.prop file and open it with NotePad++. (A tip, we usually refer adresses instead of putting them in words like I just did, so from now on, I will say, for example, head to system/build.prop)
Step 8:- Find this "ro.build.display.id" in build.prop (It should be in first few lines). Then after "=", there will be a string of alpha-numeric characters. For eg, in my case, it is "N920CXXU3CQD1". You might be having something different depending on your device. You can change this string to anything you want, for example in my N-FUEL Rom, I have put it as "N-FUEL-XL1-N920CXXU3CQD1". Hope, you got the idea.
Step 9:- Now its time to flash your ROM. But hey, before flashing, you need a ROM zip, right. So head to the ASSAYYED kitchen and Look for "BUILD ROM FOR FLASHING"(Hint:- It is the 7th option). So as you know, we will type "7", then press Enter.
Step 10:- Now since, we want a zip, and the number corresponding to a "ZIP" is "3". So type 3 and then enter. After this, it will ask you to review updater-script (I will tell you about updater-script and its syntax later in the guide), for now, leave it "N0", that is "default" (You know what to do when you see default). After this, it might ask you to zipalign apks. You can select this as "YES".
Step 11:- Then, you should always keep the compress level to "5"(which is "default", as you can see). Then you will see that it is making the zip file. Then it will ask you to name your ROM zip. Once done
Step 12:- Once completed, it will ask you to sign the zip, it is optional, however, I never signed my ROM zips though.
Step 13:- Okay so, finally!! You have gone through the tough journey and are now on the verge of testing your own ROM. So, go ahead and go to the "READY" directory. You will see your very first build there.
Step 14:- Now go ahead and put this zip in your Internal Storage and go to your recovery. First backup your current ROM or data. Then wipe system, cache, dalvik and data from your Recovery and finally FLASH YOUR ROM!!!
In the next post, I will be talking about Odexed and Deodexed ROMS, Debloating stuffs and few other things... so stay tuned
Hey guys, now, coming back to the guide, I want to tell you that the sole purpose of modifying/developing a custom ROM is to remove the amazing loads of BLOAT, that Samsung has to offer us. If you downloaded the firmware, that I told you about in the first post, you must have noted the huge size of the official firmware (In my case, it was around 1.9 GB!!). On the other hand, if you see around, most of the ROMS are much less in size than the official firmware. So, let me make an equation, that you can remember for life long, till you are developing a ROM
CUSTOM ROM = OFFICIAL FIRMWARE - BLOAT​
LETS LEARN ABOUT BLOAT
So keeping this mind, the first thing you should do, while developing a ROM, is to remove this BLOAT. Now, BLOAT, you can consider it to be extra apps that you see on your device, which you NEVER-EVER use, and they just sit there on your device, taking up all the space that you need and using up your battery by keeping their background services active all the time. So, let's first recognize, what is this BLOAT.
You can consider all the Microsoft Apps (Word, Excel, PowerPoint, Skype etc etc), at least, they were a Bloat for our NOTE 5 device. Don't get me wrong, they are amazing applications, but on PC. I never used them on my Device. Furthermore, you can consider a few of Google apps as BLOAT as well. For example. Play Music, you are already getting a music app from Samsung, so why keep two? Like this, many of Samsung apps like Samsung Pay (which you probably can't use as you rooted your device) and many others. Hope you got the idea.
Now, since you recognized the BLOAT, the next step would be to know, where is this. Now, I told you above that the BLOAT is essentially the apps in the ROM. So, from Post #1, you must be knowing that apps are located in "system/app" and system/priv-app. But remember one thing, ALL THE APPS ARE NOT BLOAT. You can head to this directory and look for various folders (These folders contains the apk files for the apps, as I told you earlier), but DON'T delete anything now.
Now you know what is BLOAT and where it is, now you need to understand, how to remove this BLOAT. So, there are two ways to do this, and in actual ROM Development, I am sure, you will use both the methods.
So here are the two methods:-
1)Using a kitchen
2)Using File Explorer
Using a File Explorer is as simple as going to "system/app" (or "system/priv-app") and deleting the respective folder, but,
YOU SHOULD KNOW WHAT YOU ARE DOING... YOU SHOULD NEVER DELETE AN APK, UNLESS YOU KNOW IT IS NOT REQUIRED BY THE ANDROID SYSTEM TO RUN
REMOVING BLOAT USING KITCHEN
I consider this to be the safest method and you would also know it, just stick with me and follow the steps...
Step 1:- Launch ASSAYYED Kitchen and look for the option "DEBLOATING THE ROM". So, in order to select it, you know what to do, Press "11" and enter.
So now, explanation time.
Now, in ASSAYYED, there is a method by which the kitchen "DEBLOATS" apps from your ROM. It does it by knowing the EXACT NAME OF THE APK stored in a TEXT FILE. These text files are located in "TOOLS/txt_files"(in your kitchen directory)
I would like you to open "kushan_debloat_list" in this directory (that is "TOOLS/txt_files"). Once you open this file, you will see a huge load to names of files with an extension ".apk". So, a kitchen uses this type of files with apk names, then it searches the full ROM for the apks and delete those whose names match with those in the list. So I hope you got the idea. The kitchen has some pre-loaded debloat list, which we can use for now. However, you can create your own ones, or download a "SAFE" debloat list for your specific device, and use that. Just put, your own text file in "TOOLS/txt_files", and you will be good to go, now lets move to Step 2.
Step2:- Okay so, now we need to select out Debloat Txt file from the list. So, we will SELECT "CHOOSE_LIST" from ASSAYYED Menu.
Step 3:- Now you will see the list of available Debloat List (PRE-LOADED ONES). For now, select "ASSAYYED KITCHEN LIST". Now, sit back and relax, until the Kitchen DEBLOATS the ROM.
Step 4:- Once complete, Press Enter. and now navigate to your WORK Folder. In this, you should see a new folder namely "BLOAT". Now, I told you a lie earlier (Sorry for that). The kitchen doesnt delete the apks. It just separates the BLOAT from your ROM.
Once you open this BLOAT folder, you should see some subfolders, and you can easily guess what they contain.
Now, in order to make your ROM smaller in size, you need to remove this BLOAT folder. I would recommend moving this folder to a new directory for now, instead of fully deleting it.
Okay, so now your ROM is DEBLOATED!!
CONGRATULATIONS!!
Now, you can BUILD the ROM for flashing, like I taught you in Post #1 and flash it, you will see many apps will be removed from your app drawer, once the ROM is booted. So, now ENJOY YOUR DEBLOATED ROM
So, you have learned about Debloating your ROM, now let me tell you somethings about ODEXED AND DEODEXED ROMS
ODEXED VS DEODEXED
Well, it is essentially the apps that are ODEXED or DEODEXED and not the ROM in general.
Let's first learn about what is an ODEXED app. Well, ODEXED apps, basically are pre-optimized apps, they don't need to be optimized on every reboot, or after wiping cache or even after clean ROM install. Pre-optimized apps are also more stable as they won't get any chance of error while optimizing. When you pre-optimize an app, it's optimization details stored in a separate folder called "odex". So system accesses that and knows how an app works before opening the app or while booting the ROM. Therefore, on a fresh install, it is always noted that ODEXED ROMS boot a lot faster than DEODEXED ROMS.
On the other hand, DEODEXED apps are not pre-optimized. Once you deodex an app, the information stored in the odex folder is removed and the system has to optimize an app every time the ROM boots. This is the reason why a DEODEXED ROM boots slower in comparison with an ODEXED ROM.
But hey, that doesn't mean that ODEXED ROMS are better than DEODEXED ROMS. If you want a whole lot of MODS in your ROM, it is must that you DEODEX it. without DEODEXING an app, you cant make much modifications, and if you did, it will result in Force Closes and a whole lot of errors. I always prefer to DEODEX my ROMS. Inface, both my ROMS (N-FUEL-V4 and N-FUEL-XL1) are DEODEXED. The choice is upto you, whether you want faster boot-up times and all that speed or you want amazing MODS in your ROM.
So, I hope, you got to know a bit about ODEXED and DEODEXED ROMS. One thing, I would like to tell you is that the firmware, you downloaded, will always be ODEXED, as Samsung always keeps their firmware ODEXED for faster boot-up times and stability. So, we need to DEODEX it (if you want to have a DEODEXED Rom)
If you want to know more about ODEXED and DEODEXED, you can click here and read from this amazing guide:good: Now let me tell you, how to DEODEX a ROM
DEODEXING THE ROM USING KITCHEN
Step 1:- Launch ASSAYYED kitchen and search for "DEODEXING PROJECT". Then go ahead and select it.
Step 2:- Select Yes, if it asks for confirmation. Now sit back and relax, and let the kitchen do its work.
Pretty simple eh So you have DEODEXED your ROM. Now, for this last section of this post, I will tell you about DEKNOXING the ROM, which is essential to do, and you will know why in the next section.
LEARNING ABOUT KNOX
The newer Samsung firmwares (maybe after 5.1.1) come with a secured BOOTLOADER. Basically, if we root our device or try to tamper with the official firmware, there is a Knox warranty which gets void. And once it gets void, there is no way (at least that's what people say) to get it back.
This KNOX warranty ensures that your device is running official firmware with no modifications. Therefore, once you root your device, KNOX warranty gets voided and as a result, you pretty much can't use official firmware on your device and if you did, the system will show high battery usage or other such effects. You can learn more about this from here.
Now since you know the adverse affects of Knox, it is better to remove it from your ROM.
DEKNOXING A ROM
Step 1:- Launch ASSAYYED kitchen and select "DEKNOXING THE ROM". Let it do its work and Press Enter when completed.
But hey, that's not enough. We need to follow some additional steps to fully DEKNOX the ROM.
Step 2:- Navigate to "system/app" inside the "WORK" folder, look for any folder containing the word "Knox" and delete them.
Step 3:- Now navigate to "system/lib", and search for "libknox" and delete the files that show up (around 5 or 6 files should be there)
Remember to delete the above file from "lib" and NOT from "lib64"
Step 4:- Open the build.prop file. (It is in system folder inside WORK)
Step 5:- In the build.prop file, search for "ro.config.knox". This value should be equal to something (in my case it was v30). Change this something to 0, so that the full line becomes "ro.config.knox=0".
Step 6:- Now search for "ro.config.tima". This value should be equal to 1. Change it to 0, so that the full line becomes "ro.config.tima=0".
So that's it, you finally have DEBLOATED, DEODEXED AND DEKNOXED ROM!!
You can now go ahead and BUILD THE ROM FOR FLASHING. Then once the ROM boots, enjoy your hardwork
Now, this is it... We have fully completed the first part of the GUIDE.... that is, CREATING A VERY BASIC ROM USING KITCHEN. In the next POST, we will continue to the next part of the guide... so till then, Stay Tuned
ADDING BASIC MODS TO THE ROM​
Okay so now, let me tell you how to make your ROM, a lot more interesting and enjoyable to use. Now, the next main purpose of building a custom ROM is to add what is not there in the STOCK ROM, and that is MODS. You can add huge loads of MODS, which are already present in STOCK ROM but are disabled by Samsung. Many mods, for example, adding DATA USAGE in Notification Panel or disabling SMS TO MMS CONVERSION are as simple as adding a single line in a file, however, other MODS, like enabling VIRTUAL LOCK BUTTON in Status Bar requires few and very easy modding after decompiling apks, on the other hand, coloring stuffs in the SystemUI, requires some good modding skills and experience in decompiling stuffs.
Now, in this section, we will be discussing on adding basic mods, that is single line MODS, that I talked about earlier. So, first lets go through the easy stuffs, that is adding mods to build.prop.
ADDING MODS TO BUILD.PROP
Adding MODS to build.prop is actually very easy, and kitchen does all the stuffs. So follow the steps below and you will be good to go
Step1:- Launch "ASSAYYED KITCHEN" and search for "ADDING BUILD.PROP TWEAKS" and select it.
Step 2:- On asking for confirmation, just select "YES".
Step 3:-Now, wait for a short time and once done Press ENTER, and now your ROM is much more smooth and fast. You can head to your build.prop (its in WORK/system) and look for those mods.
Now these are some amazing mods, you can play with some values (but be sure of what you are doing)
So, you've learnt on adding build.prop mods to your ROM. However, we are not limited to this, there are many other MODS to help you enable several things. Go ahead and read on XDA, and you will be surprised to know how many things, you can get by just changing some values or adding some lines in build.prop. Not only from XDA, but from other ROMS (but give appropriate credits to respect the efforts of the developer, who found it)
Now comes the tough (well not tough but overwhelming) part of this guide, that is adding CSC Mods.
WHAT IS CSC?
The Customer Service Code (CSC) plays an important role in the operation of your Samsung mobile device. The CSC code ensures that your mobile device complies with the standards for your country, and your cell phone operator. Therefore, if we can change/add a few lines in our CSC code, we can actually get features which Samsung disables due to the standards for your country. Hope you get it. Now the main task is to find those lines, through which we can enable these features.
So, we first locate , where to add/modify these lines. Now, navigate to your "WORK/system/csc". Here you will see many files and folders(maybe). Now, it is in this folder, that we make changes and mainly in the "others.xml" file. Now, open this file WITH NOTEPAD++ and you should see a lot of lines of codes which includes some value between <CscFeature...> </CscFeature...> or something like this.
HOW TO ADD CSC MODS
So by now, you know that what is CSC, and where to we add CSC Mods. Now lets learn how to add these MODS.
Well, remember a main rule here and that is COPY AND PASTE. We basically copy a few lines from some other country's others.xml (for your particular device) to your own others.xml.
Well, you can also copy these lines from some other Developer's work, but it is "MANDATORY" to give appropriate credits to the respective developer.
Here, I am listing some (not all xD) of the CSC MODS/lines that I used in my ROM:-
ENABLE CAMERA SHUTTER SOUND TOGGLE IN CAMERA SETTINGS:-
Code:
<CscFeature_Camera_ShutterSoundMenu>TRUE</CscFeature_Camera_ShutterSoundMenu>
ENABLE REALTIME NETWORK SPEED TOGGLE IN SETTINGS:-
Code:
<CscFeature_Setting_SupportRealTimeNetworkSpeed>TRUE</CscFeature_Setting_SupportRealTimeNetworkSpeed>
ENABLE NATIVE CALL RECORDING:-
Code:
<CscFeature_VoiceCall_ConfigRecording>RecordingAllowed</CscFeature_VoiceCall_ConfigRecording>
DISABLE SMS TO MMS CONVERSION:-
Code:
<CscFeature_Message_DisableConvertingEffectBetweenSMSMMS>TRUE</CscFeature_Message_DisableConvertingEffectBetweenSMSMMS>
<CscFeature_Message_DisableSmsToMmsConversionByTextInput>TRUE</CscFeature_Message_DisableSmsToMmsConversionByTextInput>
ENABLE WHITE PAGES (YOU NEED THE REQUIRED APK WITH THIS LINE):-
Code:
<CscFeature_Common_ConfigSvcProviderForUnknownNumber>whitepages,whitepages,whitepages</CscFeature_Common_ConfigSvcProviderForUnknownNumber>
ENABLE THE NFC ICON IN STATUSBAR:-
Code:
<CscFeature_NFC_StatusBarIconType>DEFAULT</CscFeature_NFC_StatusBarIconType>
ENABLE DATA USAGE IN NOTIFICATION PANEL:-
Code:
<CscFeature_SystemUI_SupportDataUsageViewOnQuickPanel>TRUE</CscFeature_SystemUI_SupportDataUsageViewOnQuickPanel>
Here, I have mentioned a few of many CSC Mods available for your devices. It is important to note that the above given codes are just to give you an idea. However, it is not necessary that all of the above codes will work with all of the Samsung Devices out there. If your device supports it then it will enable these MODS and if it does not then there will be no effect on the ROM. This is the beauty of CSC Mods, that if they are not compatible with your device, it will not affect your ROM/device in anyway. So, keep on adding MODS by reading, learning, copying and then pasting xD from other places.
Now after this, in the next section, we will discuss about updater-script and its syntax which will help you add various zip files directly to your ROM, so stay tuned for next upcoming posts, as they will be one of the most interesting parts of this guide
LEARNING ABOUT UPDATER-SCRIPT SYNTAX AND ADDING EXTERNAL FEATURES TO THE ROM​
Now comes the most interesting part of making ROMS (at least, according to me), and that is updater-script. Now, I would like you to navigate to "WORK/META-INF/com/google/android" and there you should see two files, namely, "updater-script" and "update-binary". Now, I will explain you first, What is updater-script, what is its essence and how is it so beneficial and interesting in ROM Development.
LEARNING ALL ABOUT UPDATER-SCRIPT (PART 1)
So, first of all, what the heck is this updater-script. It is basically the file, which instructs TWRP (or any other recovery) what to do with the zip (your ROM or any other flashable zip). Without this, you cant flash anything on your device (well, this is a lie). But, in flashing ROM, this is very important. So, now lets learn about the updater-script syntax
Well, before this, I need to tell you something and that is, how a recovery actually flashes a zip file (This is what I assumed). So basically, when we flash a file, the recovery looks for update-binary inside "META-INF/com/google/android" in the zip file. This update-binary, then tells the recovery, whether the zip has to be installed with a STANDALONE INSTALLER or AROMA INSTALLER. If the recovery founds out that the zip has to be installed by a standalone installer, it then goes to the updater-script, which HAS to be in the same directory as update-binary and says, Hey dude, can you tell me, what I have to do with this zip file.
Hence, the updater-script basically instructs the recovery about what to do with the zip. So, having know about updater-script and its essence, lets now discuss about the syntax or the language in which we can write the updater-script.
NOTE:- THIS IS NOT AN UPDATER-SCRIPT GUIDE, SO I WILL ONLY LET YOU KNOW OF THE IMPORTANT KEYWORDS OR OTHER SUCH STUFFS REGARDING ROM DEVELOPMENT. HOWEVER, THIS IS WHAT I HAVE LEARNT AND SO FAR, IT IS MORE THAN ENOUGH. MOREOVER, IT IS ESSENTIAL, THAT YOU PAY FULL ATTENTION TO THE UPCOMING SECTION. LASTLY, IT WILL BE GOOD, IF YOU HAVE SOME PROGRAMMING BACKGROUND, BUT IF YOU ARE NOT, I WILL TRY TO BE AS SIMPLE AND STRAIGHTFORWARD AS POSSIBLE
LEARNING ABOUT UPDATER-SCRIPT SYNTAX
So, for this, first open the updater-script with Notepad++, and you will be astonished to see a huge loads of lines. You would be like, what the heck does this mean. I am gonna explain you most (if not all) of the stuffs here.
1) ui_print("");
So, we first begin with ui_print. So, what this does is that, anything you put inside the double quotes (" "), it will print it out directly into the installer screen. (For my programming dudes if you learned about C or C++, it is like cout<<" ")
Now, lets me explain this better with an example, here is a piece of code and its output
Code:
ui_print("Hello, I am learning about ROM Building/Modification");
And its output in the recovery:
Code:
Hello, I am learning about ROM Building/Modification
Hope you got the idea, now let's go to next one.
2) run_program("/sbin/busybox","mount","/system");
This is basically a modified command. The original command (run_program()) is used to run many in-built programs available in Recovery. You will explore many versions of this command as you head forward in ROM Development. Now, what this specific command does is that, it mounts the "system" partition of the device.
Now, a few of you may ask, why do we require mounting. Basically, without mounting a particular partition, we cannot modify (Add files or remove them) the partition altogether. So, I hope that now you understand, why mounting is so important.
In ROM building, we usually need to mount system, data, cache, and dalvik. So, you will always see the following set of code in the beginning of any updater-script of a ROM.
Code:
run_program("/sbin/busybox","mount","/system");
run_program("/sbin/busybox","mount","/data");
run_program("/sbin/busybox","mount","/cache");
run_program("/sbin/busybox","mount","/preload");
3) delete("/file_path");
As the name suggests, it deletes a file located on your device. You need to specify the exact file directory in double quotes inside the parenthesis.
For example:-
Code:
delete("/system/priv-app/SystemUI/SystemUI.apk");
Code:
The above line (when running in a recovery) will delete the SystemUI.apk
4) delete_recursive("/directory);
As the name suggests, this command deletes a directory or even format a partition. It differs from the delete(); command in its working. delete_recursive() deletes a directory while delete() command deletes a file. (Too many deletes in a line)
For example:-
Code:
delete_recursive("/system/priv-app/SystemUI");
Code:
Note that in the above command, the Recovery will delete the SystemUI folder as well its contents.
Another use of this command is in formatting the partitions. As you know, flashing a ROM basically means, we need to extract the contents of the system folder in your zip file to the system partition of your device. So, whenever we flash a new ROM, it is always advised to wipe cache, dalvik and system.
Code:
delete_recursive("/system");
delete_recursive("/cache");
delete_recursive("/data/dalvik-cache");
Code:
The above code will firmat the necessary partitions
4) package_extract_dir("zip_directory","/directory_on_phone");
This is a very simple and an important command. What it, essentially does is that, it extracts a folder in your zip file to another folder on your device. Let me explain you, with an example:-
Code:
package_extract_dir("system","/system");
{Notice in the [B]/[/B] sign in the second parameter, and this is absent in the first parameter}
Code:
What the above command essentially does is that it extracts the [B]system[/B] folder in your ROM zip to the [B]system[/B] directory of your device.
Let's understand this with a few more examples:-
Code:
package_extract_dir("system/app","/system/app");
Code:
The above command will extract the app folder in the system inside your ROM zip to the app folder in the system directory of your device.
Code:
package_extract_dir("MODS/SystemUI","/system/app/SystemUI");
Code:
Do it urself
Code:
package_extract_dir("MODS/SecSettings2","/system/priv-app/SecSettings2");
Code:
Do it urself
5) symlink("file_name1", "file_name2");
This is a piece of code, which you will never be needing! But I am explaining this here, because, a big amount of updater-script. So, we won't go, into much detail of this command, just an overview. Now, this command basically creates a symbolic link between two files. A symbolic link is where a file has one main name, but there is one extra entry in the filename table that refers any accesses back to the main name.
Code:
symlink("/system/lib/libQjpeg.so", "/system/priv-app/SelectiveFocusViewer/lib/arm/libQjpeg.so");
Code:
This command created a symbolic link between [B]"/system/lib/libQjpeg.so"[/B] and [B]"/system/priv-app/SelectiveFocusViewer/lib/arm/libQjpeg.so"[/B]
6) set_perm(uid, gid, permissions, "file_name_with_adress");
This is quite a useful command, as it helps giving necessary permissions to various files in android. Now, basically, permissions are required for a particular file, which might require some special privilege, in order for it to complete an action. For example, Android cannot allow any file on the system to format the device, formatting can only take place if a file has necessary permissions from Android itself. So, I hope, you got the point why are permissions so important in Android.
Now let's understand the syntax of the above command, which will help give permissions to various Android Files
Code:
set_perm(uid, gid, permissions, "file_name_with_adress");
Now, this statement itself has many parameters as you can see. Now, I will limit myself to only explain you the things, which is necessary for ROM development. Now the "UID" and "GID" are UserID and GroupID. (They are a little tough to explain and beyond the domain of this guide, so I will just give a brief description). They are essentially an important part of Android Permissions, and they are usually integers. Don't worry, we will look in the following example about how this works.
Secondly, permissions are like rw-r-r or rwx-rw-rw. Now, if you have been using Linux for a while, you know what these means. Lets understand this, by taking rwx-rw-rw as an example:-
Now the first section, i.e., "rwx" is the permission set given to the "Owner" of the file, the second section i.e., "rw" is the permission set given to the "Group", and the third section, "rw" is the permission given to "Global". They might seem a bit overwhelming, but bear with me, these have very little role, as far as, ROM development goes.
Now coming back to the command, the permission, there is used in an Integer form. Now, I am putting out a link here, if you want to know, how these permissions are converted to integers... (https://unix.stackexchange.com/a/39712).
Essentially, you will only need two permissions, 0644 and 0755. Out of these, 0644 will always be given to an apk, while 0755 will always be given to a folder. (0644 -> rw-r-r and 0755 -> rwx-rx-rx)
Code:
set_perm(0, 0, 0777, "/tmp/wipe.sh");
Code:
Now, the above command essentially gives the permission [B]"rwx-rwx-rwx"[/B] to the file "/tmp/wipe.sh".
7) set_perm_recursive(UID, GID, perm_directory, perm_files, "directory_name");
Now, this is very similar to set_perm(), but the only difference is that this gives permission to an entire directory and its contents. Let's look at an example...
Code:
set_perm_recursive(1000, 1000, 0775, 0644, "/system/framework");
Code:
This command gives "/system/framework" directory 0775 permissions and all its contents, 0644 permissions. (0775 -> rwx-rwx-rx).
So guys, in this post, I have tried to cover most of the essential Edify Scripting command, you will ever need in your ROM Development journey. I will be talking about a few more commands after we talk about aroma-config in the next post. I am posting out a link, which will help you find more such commands:- https://forum.xda-developers.com/wiki/Edify_script_language.
Now, we are done with Updater Script commands (Part 1). In the upcoming post, we will talk about Aroma-Config and after that, we will look at Updater Script Commands (Part 2). So stay tuned and see you guys in the next post.
one more
last one
actually one more
Great aman!!! It looks very nice!! Tonight ill be reading it!!!
congratulations....great thread...keep it high
You don't have to thanks to me bro, I'm really happy to see you over here, teaching to the rest
Congratulations bro, a lot, you will be great
Great thread man !!
congrats
This is the true meaning of:
Sharing is Caring
[emoji106] [emoji122]
Sent from my SM-N920C using Tapatalk
Wonderful .. amazing discribtion .. you made all of us developers :good::good::good:
Thanks everyone for reading the guide and giving the feedbacks.
I just updated the guide. Now, it includes Deknoxing, Debloating and Deodexing a ROM, and also some good information about each of them. So you can now move further in your ROM
Great work @AndroidSword all the best for future progress on this thread :good:
tnx very good guide simple and clear keep up good work
Awesome! greatly appreciated for making this guide. Im gonna dive into the deep now
hi in ASSAYYED_KITCHEN_V1.82_STABLE when remove bloat the kitchen just make a folder in WORK\BLOAT not change the name of app
waiting for part2 tnx
Eveything I've been doing for months manually with Rom Raider, Step Flashing, Etc. all here, its a f*&%&ing miracle. Hvaent flashed te rom yet but it's doing what I did. Knox removal could be a little more involved but I already know where all that crap is. If this gets my SE into Perm mode I'm gonna dance a jig, Thanks for the tutorial. And thanks to the Devs for the awesome crazy work put into this beautiful machine.
When I edit the build.prop with c++ note do I save it as a "properties" file? I'm assuming cause mine was fudged from accidentally making it a .txt using reg notepad a few weeks back. Dunno how my ROM was working but there's 4-5 other encrypted style build.prop files in there. I'll post example. "build.propwjO0d4" it's written in alien lingo like alot of the sec files are. I'm assuming I only need one I'm thinking copypasta my og buildprop info into one of these and renaming?
Guys, next section of the guide is there in Post#3, so go ahead and do MODS to your ROM as per your requirements​

B32 SD Update Error: can't be copied because it is too large for the volume's format?

Hey everyone,
I'm trying to comply update to my device using the B32 firmware downloaded on ZTE USA Support site. The file is large, too large for FAT32, at 5.39GB.
I have tried copying it using android transfer on my mac, ejecting the microSD and using a regular SD adapter and copying it that way, and I have also tried just downloading right from the Software Update screen. The first two methods errored with (https://ibb.co/kjh4yG).
The software update fails with a message explaining that the firmware found and downloaded by the phone does not match the device...?
I have been on the old firmware for what feels like a year now. I'm hoping you all can shed some light on this.
Thanks
macboss said:
Hey everyone,
I'm trying to comply update to my device using the B32 firmware downloaded on ZTE USA Support site. The file is large, too large for FAT32, at 5.39GB.
I have tried copying it using android transfer on my mac, ejecting the microSD and using a regular SD adapter and copying it that way, and I have also tried just downloading right from the Software Update screen. The first two methods errored with (https://ibb.co/kjh4yG).
The software update fails with a message explaining that the firmware found and downloaded by the phone does not match the device...?
I have been on the old firmware for what feels like a year now. I'm hoping you all can shed some light on this.
Thanks
Click to expand...
Click to collapse
You have two ways to do this:
-If your internet is decent enough just forget about the SD card and download the update on your phone. Afterwards, download 'RAR' from the play store, find the downloaded file (in Downloads), and open the zip file. If you find a PDF and a file called 'update.zip' inside, simply select it and unzip it to the root of your sd card (put '/storage/emulated/0/ on the Destination path). So you will have an 'update.zip' file there. You don't need to unzip this one. Now go to Settings, Updates, then let it scan and it should find the file, update and voila
-Format your SD Card to exfat and pop the file right in
It's weird that the update file is that huge, since usually files for the A2017G are around 2.1 gigs
It worked my friend!!!
I installed RAR, then went inside the downloaded file, found update.zip and unzipped it to '/storage/emulated/0. Did not find any PDF file though, not sure what that would have been for..? Anyway, saw the MiFavor firmware update screen which meant we were on our way to finish line. After that it booted to a small tiny linux penguin symbol and black background. Tried rebooting by holding down the power button. Rebooted. Saw penguin again for like 5 seconds, then booted straight to the axon wavy weird startup sequence. I DID IT!! I really appreciate the help on this one. Great idea. And it worked flawlessly.
Thank you. Choose an username.. Your username might be strange but your solutions are a lifesaver.
Cheers!
macboss said:
It worked my friend!!!
I installed RAR, then went inside the downloaded file, found update.zip and unzipped it to '/storage/emulated/0. Did not find any PDF file though, not sure what that would have been for..? Anyway, saw the MiFavor firmware update screen which meant we were on our way to finish line. After that it booted to a small tiny linux penguin symbol and black background. Tried rebooting by holding down the power button. Rebooted. Saw penguin again for like 5 seconds, then booted straight to the axon wavy weird startup sequence. I DID IT!! I really appreciate the help on this one. Great idea. And it worked flawlessly.
Thank you. Choose an username.. Your username might be strange but your solutions are a lifesaver.
Cheers!
Click to expand...
Click to collapse
Lol. The signup dialog said 'Choose an username...', so i said, why not?
I think you downloaded directly the update.zip. Maybe the RAR part wasn't needed, I dunno. If there's a folder somewhere there called 'update' then just delete it, and the update.zip too
A larger than 5Gb update would have to be the file fully unzipped into a folder structure.
Update files are zipped and that's what the phone wants.
Choose an username... said:
Lol. The signup dialog said 'Choose an username...', so i said, why not?
I think you downloaded directly the update.zip. Maybe the RAR part wasn't needed, I dunno. If there's a folder somewhere there called 'update' then just delete it, and the update.zip too
Click to expand...
Click to collapse
I downloaded one of the two raw zips from the ZTE USA site that had a very long name.zip with all numbers. The "update.zip" was nestled inside after unzipping the file on the phone. I just picked that file and moved it to ther root and applied the update. It went through successfully. Did i not apply it correctly? Should i have just renamed that whole file to "update.zip" and moved the entire folder? A little confused. But i imagine if the update took and i saw the 32 in the current build of the device it took. But im not sure.
macboss said:
I downloaded one of the two raw zips from the ZTE USA site that had a very long name.zip with all numbers. The "update.zip" was nestled inside after unzipping the file on the phone. I just picked that file and moved it to ther root and applied the update. It went through successfully. Did i not apply it correctly? Should i have just renamed that whole file to "update.zip" and moved the entire folder? A little confused. But i imagine if the update took and i saw the 32 in the current build of the device it took. But im not sure.
Click to expand...
Click to collapse
Nah that's okay. I thought you downloaded the 'update.zip' directly. Happens sometimes
It’s weird the update was only about 2 GB. What do you think was the rest of the file?
Maybe in case it needed the full firmware. In this case it didn’t probably. Just a guess
macboss said:
Maybe in case it needed the full firmware. In this case it didn’t probably. Just a guess
Click to expand...
Click to collapse
No, that doesn't make sense. No idea really.
It couldn't have gone wrong so don't stress out. Your phone works. If it didn't work then yeah, something was wrong...

Categories

Resources