Warning!

Warning. The following publications may induce intense reasoning.

Tuesday, September 9, 2014

Easily Tweak Your Android By Hand

It has been long enough, for me to feel comfortable about tweaking my Android Smartphone. This includes a certain technical risk of killing the device.

I started by rooting the device: a Tatop W858 MTK-6577 model running Android 4.0.3. I used the notorious Framaroot application, even though my device was not on the list of officially supported devices. The MTK models are very common, so I felt comfortable trying it.

A one-click operation. Super easy!

Now with SU access to my system files, I started to take interest in tweaking the system! For this, I used the free ES File Explorer app, and activated Root permissions for it, in its' settings.

First to go, was the annoying Search Button that I never use, but always accidently touch. I Googled, and found that I want to edit my "/system/usr/keylayout/mtk-kpd.kl" file. It is usually a file-name that relates to your model or chip, so you can identify it easily.

Naturally, I copied the file into my SD card, so that I have a backup! Now, I opened the file with the ES File Explorer's Note Editor, and found the line:
"key  217    SEARCH"

[For more button keycodes and function, click here.]

As you can see, it can be very easy to locate buttons by their function. This was the only line with the "SEARCH" function. By commenting that line out, I could disable it, and now it looked like this:
"#key  217    SEARCH"
(Notice the added # at the beginning of the line.)

However, when I restarted my device, there was no change! After some testing, I found out that my device used the "Generic.kl" file, instead. So, I copied it into my backup folder, and edited the exact same line, in the same way.

Now it worked! :-)

Second to go, were all these useless extra home-screens. I just do not need five screens there. Three are plenty. I Googled and found that, this time, I want to edit my "/system/app/Launcher2.apk" file.

Again, I copied the file into my SD card, and then learned how to modify it. APK files are compiled files, meaning that they cannot be edited as simple text. Luckily...

I found APK Studio, which is able to edit APK files, and then rebuild them properly.

It is quite simple, when you have a forum post to guide you.

I was not sure which part I had to edit, so I Googled, and found a forum thread about exactly what I wanted, and even some more. The instructions are super easy, and it took me exactly two minutes to do this from start to end.

You do not want to make a typo error in this step! This is a system APK file, which means errors are fatal, and are sometimes not recoverable!

I found the lines of code I wanted to or edit, carefully made the changes - rechecking them for mistakes, and then clicked File -> Save All, and then Project -> Build. I renamed the new "rebuilt.apk", under the "build" directory, into the original "Launcher2.apk" name.

Just in case, before copying the new file back, I went ahead and cleared the fourth and fifth home screens from widgets.

I then copied the file back to my Android device, and over-wrote the original file in the "/system/app" folder. This made my device freeze, so I waited about twenty seconds to make sure it is done copying, and then pressed (or held) the Power Button, to reboot the device.

Happily, the device works fine, and now I have only three home screens, just like I wanted! :-D

Be the first to comment!

Constructive, thought-out, and finely argued comments are encouraged.

All Time Popular Posts