AndroidGood and EVO

Some advanced root actions for the HTC One M8

roottools photo for Advanced Root ActionsHere are some commands and advanced root actions that can prove useful for more advanced users. They work on more than the HTC One M8; however, as I’m writing this away from my EVOs today, and I don’t know what you’re running, these may destroy your phone and burn your crops to the ground. Probably not, but you never know. Check first whether this will work on your phone, though, if you’re not on an M8.

Back up your radio

If you’re S-OFF, chances are you’re going to flash a new radio/firmware update at some point. You also may discover that the carrier updated radio doesn’t play well with your phone, or doesn’t play well with your ROM. The solution here is to make a backup of your radio and store it someplace safe.

From a terminal session (either adb or terminal emulator):

su

dd if=/dev/block/mmcblk0p20 of=/sdcard/radio.img

exit

When you’re done, depending on what carrier you’re on, you’ll have between a 38 and 75 megabyte radio.img. You will not see the radio.img file in an explorer window if you’ve got the phone connected as a disk drive until after you unplug and plug the phone back into the computer.

You can verify that it’s there by typing:

ls /sdcard/r* -l

Flash a backed up radio

You’ve backed up that radio, or have downloaded an image. We’ll assume for these purposes it’s still in /sdcard and named radio.img. You’ll also need to be S-OFF for this to work most likely.

su

dd if=/storage/sdcard0/radio.img of=/dev/block/mmcblk0p20

exit

reboot the phone

Keep in mind this could wreck your phone, so be very careful.

(Radio info via xda-developers.)

Get the phone’s current CID

You’ll need fastboot on a computer for this.

Reboot the phone into bootloader, or power down, then press power+vol down until the bootloader comes up.

From a computer type

fastboot getvar cid

If all goes well you’ll see something like this pop up on your screen:

cid: SPCS_001

finished. total time: 0.002s

You might want to write that CID down for later use, maybe not.

Set the phone’s current CID (superCID)

You’ll need fastboot and a computer for this.

Reboot the phone into bootloader, or power down, then press power+vol down until the bootloader comes up.

From a computer, type:

fastboot.exe oem writecid 11111111

If all goes well you’ll see something like this pop up:

(bootloader) Start Verify: 0

(bootloader) Input CID is super CID

(bootloader) Start Verify: 0

OKAY [ 0.028s]

finished. total time: 0.028s

You will not see the CID change on the bootloader screen until you choose to reboot fastboot or navigate away from the bootloader and back.

You can also write your old CID back to the phone by replacing the 11111111 with your original CID.

CID info via team-nocturnal

Check an MD5 sum

So you’ve just spent the past five hours downloading a ROM for your phone, and before you flash it you want to verify that you got the thing  downloaded correctly.

Many file explorers such as ES File Explorer will handle that for you from the Android side, but let’s say you’re unable to get to the Play Store.

Open up a terminal services window, change the directory to your download folder, and run the command:

md5sum <filename>

So, for example purposes below, I’ve got a ROM called Bad_Boyz_Sprint_ONE_M8_Harman_v1.0.zip sitting in my download folder on my sd card.

If you’re already cringing at the prospect of having to type all that ROM name in in a terminal services window, here’s a shortcut:

md5sum /sdcard/download/Bad*

…will return the following:

c1ff72f6738f7184b6584d234ea79190 /sdcard/download/Bad_Boyz_Sprint_ONE_M8_Harman_v1.0.zip

Considering the massive amount of bad downloads these free Android hosting providers and your network carrier cause, most ROM developers will include an MD5 in the ROM thread.

If your sum is different, you’ve got a bad download or the ROM developer posted the wrong info.

You don’t have to be rooted to use this, but why else would you be verifying a ROM MD5?

Pocketables does not accept targeted advertising, phony guest posts, paid reviews, etc. Help us keep this way with support on Patreon!
Become a patron at Patreon!

Paul E King

Paul King started with GoodAndEVO in 2011, which merged with Pocketables, and as of 2018 he's evidently the owner. He lives in Nashville, works at a film production company, is married with two kids. Facebook | Twitter | Donate | More posts by Paul | Subscribe to Paul's posts

Avatar of Paul E King