H
handy5876
Guest
If you are the type who needs to get the bigger picture before following detailed instructions then you may need to go through this.
Background before rooting and flashing ROMs.
Just to state the obvious the HTC desire has got the linux operating system at its core and the android virtual machine called the Dalvik virtual machine sits on top of this core. These are some of the areas you may need to get a handle on.
ROM
SDCARD
Bootloader
Radio
Rooting
SON/SOFF
Unrooting (RUU/PB99IMG.zip)
There is more detailed information in my subsequent posts if you want to know more.
Background before rooting and flashing ROMs.
Just to state the obvious the HTC desire has got the linux operating system at its core and the android virtual machine called the Dalvik virtual machine sits on top of this core. These are some of the areas you may need to get a handle on.
ROM
The desire has 572 MB RAM and 512 MB ROM space. The ROM is called so but actually is not read only and resides on NAND Flash memory which can be both read and written to. The ROM is like the hard disk of a PC and the sdcard is like a removable disk. Just like a PC which divides the hard disk into C: , D: etc Android divides the ROM into partitions. Android calls these partitions by different names like boot, system, data etc.
- The first partition 'misc' is a very sensitive area which contains carrier data among other and is normally never touched even when you root, go soff or flash ROMs.
- The 'recovery' partition contains a linux kernel specially tailored for flashing updates. During rooting this is replaced by a custom recovery from clockworkmod etc. The original recovery does not permit flashing of unofficial ROMs, backups etc and is extremely limited.
- The next partition is 'boot' which houses the actual linux kernel used by android.
- The 'system' partition houses the system apps and data. The term flashing ROMs mostly means installing a different system and boot image.
- The 'data' partition houses the user apps and their dependencies.
- The 'cache' partition houses the system cache.
- The first partition 'misc' is a very sensitive area which contains carrier data among other and is normally never touched even when you root, go soff or flash ROMs.
- The 'recovery' partition contains a linux kernel specially tailored for flashing updates. During rooting this is replaced by a custom recovery from clockworkmod etc. The original recovery does not permit flashing of unofficial ROMs, backups etc and is extremely limited.
- The next partition is 'boot' which houses the actual linux kernel used by android.
- The 'system' partition houses the system apps and data. The term flashing ROMs mostly means installing a different system and boot image.
- The 'data' partition houses the user apps and their dependencies.
- The 'cache' partition houses the system cache.
SDCARD
The sdcard can be also divided into partitions. The first partition is generally the FAT32 filesystem of Windows which can be accessed on the PC by connecting with USB cable. The second partition is generally the ext filesystem of linux. sdext is not available on original device and is basically a mod for shifting your apps to sdcard when you are running out of space which is a vexing issue for desire owners. This is because in Android all user apps are installed only on 'data' partition which is on ROM and is 147 MB only and soon you run out of space. Note that this sdext methodology is different from android supported method of shifting of apps to sdcard.
Bootloader
The bootloader or hboot is the first piece of code executed by the device. It is accessed by booting with vol dn + power pressed. The hboot is similar to the BIOS of PCs. It does some checks and hands control over to the linux kernel(boot partition) if normal booting is followed. If interactive booting is followed and recovery is selected then it hands over control to recovery kernel(recovery partition). The hboot being the first piece of code executed by the device is one of the most sensitive pieces of software and corruption bricks the device.
Radio
The radio software drives the radio of the device like 2g, 3g . The radio software is also upgradable but is equally sensitive like hboot. Problems during flashing like supply interruptions, problematic usb cables, PC problems can brick the device.
Rooting
The process of rooting is basically gaining root or priveleged access in the linux system and is the first step to any customization of the device. Typically during rooting the unofficial recovery from clockworkmod or amonra is flashed which is what unrevoked does. Once the unofficial recovery is flashed your device actually gets opened up. With this recovery you can flash custom ROMs. You can also take backups(nandroid). Nandroid takes a image of the recovery, boot, system, data, cache and sdext partitions. This can be used to restore the system exactly to that state if things do not go as planned when flashing a new ROM or some other system related operation. Note that nandroid will not touch the hboot, radio and misc and also will not restore recovery. Nandroid also gives capability to erase(wipe) partitions like /data(factory reset), /cache and dalvik cache and may be required prior to flashing a new ROM due to incompatibilities. Custom recovery can also be used to uninstall vexing system apps(bloatware) among many other things.
SON/SOFF
The hboot has a special safeguard for preventing unauthorised changes to /system partition (even with root access) called SON. This prevents you from touching the /system or system apps when android is booted up. What this means is that you cant get rid of bloatware when android is running. The process of unlocking this security feature is called soff and it is carried out with alpharev software. Alpharev flashes a modified hboot which bypasses the security feature and /system can thereafter be available for read write. Since hboot also contains partition information, the partition sizes can also be changed from original tables with alpharev hboot. The modified partition tables can give you increased space in /data partition from original 147 MB stock to more than 300 MB by rearranging space. The hboot also has a special mode called fastboot during which some extended commands for flashing hboots, radios, splash screens etc can be issued to bootloader.
Unrooting (RUU/PB99IMG.zip)
These terms which you will come across is basically for disaster recovery and you want to restore and unroot the phone back to original carrier/HTC version for all areas including radio, hboot, boot, system, data etc. RUU (ROM Upgrade utility) is a PC software and works through the USB cable. The PB99IMG.zip file can be extracted from the RUU is a special zip file which when you stick it on sdcard does the same job as RUU. One needs to know that RUU/PB99IMG software are region specific and only a few of them are available which have been leaked from OEM service centres. You also need to be aware that your phone carries region branding which is a special code inserted by manufacturer. This code called cidnum is checked by the RUU/PB99IMG before it restores the phone. So if the software is not available for your region then the only alternative is you need to make a goldcard as described in the guides hosted in the forum. The goldcard is nothing but a sdcard with a modified bootsector. With the goldcard in the phone the RUU/PB99IMG bypasses the region code checks.
There is more detailed information in my subsequent posts if you want to know more.