Remapping / disabling volume button in *.kl files not working - Android Q&A, Help & Troubleshooting

Hello.
i have an HTC M8 although i think it is not a device related question.
my volume up button is damaged and the volume changes occasionally.
i want to edit the key layout files and disable the volume up button.
i followed this manual:
http://forums.androidcentral.com/lg-optimus-g-pro/284907-how-disable-side-volume-buttons.html
but each time i reset the phone the files returns to their original state and the volume up button is still enabled.
i am using es explorer with root access.
tried to mount the system folder but still no luck.
please help.
i am going crazy...

Related

Problem with home key

So far I can't post PM or message to developement board as new registered user, lets try to get answer to my problem this way
Problem and following ROM is related to Xperia GO
I downloaded, installed and started use ExtremeSecurity Stock Jelly Bean 6.2.A.1.100 European ROM http://forum.xda-developers.com/showthread.php?t=2328171. I did it as I need something to replace stock one with delays it have. I found one problem, I am unable to solve. After install and rooting I found I can't use the home key (the touch sense key under display - the one with "house"). I was trying to google and change mapping of this key and did not succeed. So I made some tests and did not move anywhere forward...
1) If I go to recovery, cwm allow me to display key numbers in some menu. Here key respond well it code as 102 (as it should)
2) If I add line like key 102 HOME WAKE to any file in /system/usr/keylayout nothing change (after editing I reboot, then put it back, so far I was not succesfull)
3) If I use any of "keypress test application" (try 3 of them) they report all keys well (back, settings, vol up/dwn power) but no report and no action for home.
There is no difference in press or long press of key. Simply no action follows.
Do you have any Idea what can be wrong?
Thanks a lot
Karel
P.S. If admins will forward it as message to munjeni or move to Developement part of forum for this ROM, please delete it here...

[MOD]i9195 Disable HOME button on lockscreen(rooted stock rom)[MOD]

Hi
The main goal: disabling the home button wake on the lockscreen and every other home fuction remain the same
this solution based on this tutorial:
http://forum.xda-developers.com/showthread.php?t=2224688
you need root acces:
http://forum.xda-developers.com/showthread.php?t=2364980
Download Total Commander from Play (it's better bcose there is automatic moun/remount function )
https://play.google.com/store/apps/details?id=com.ghisler.android.TotalCommander
- allow root acces to TC
- navigate to /system/usr/keylayout
- locate and copy to safe place gpio-keys.kl and sec_keys.kl
- open the original files with TC editor (press once on the filename and choose "Edit")
- Search the following lines in gpio-keys.kl:
Code:
key 102 HOME WAKE
key 172 HOME WAKE
and delete the WAKE world and all spaces after HOME!
it should be looking:
Code:
key 102 HOME
key 172 HOME
- save gpio-keys.kl (TC do all mount-remount thing)
- Search the following line in sec_keys.kl:
Code:
key 172 HOME WAKE
and delete the WAKE world and all spaces after HOME!
it should be looking:
Code:
key 172 HOME
- save sec_keys.kl (TC do all mount-remount thing)
restart the phone and enjoy
If you're using CM, go to Settings - Display and Uncheck the second last option to achieve the same effect in a much simpler way
Whosat said:
If you're using CM, go to Settings - Display and Uncheck the second last option to achieve the same effect in a much simpler way
Click to expand...
Click to collapse
Not in 10.2?
Sent from my GT-I9195 using xda app-developers app
shayne77 said:
Not in 10.2?
Sent from my GT-I9195 using xda app-developers app
Click to expand...
Click to collapse
In 10,2 it is found in Settings - Buttons - Home button wake.
How to disable HOME button on Kitkat 4.4.2? This solution doesnt work on Kitkat anymore
Whosat said:
In 10,2 it is found in Settings - Buttons - Home button wake.
Click to expand...
Click to collapse
Same is in CM 11
Very useful tutorial. Thank you a lot. My phone used to unlock itself in my pocket and then make a call or mess up settings... S4 mini reacts to touches trough thin cloth. This wasn't problem on HTC.
Wanam xposed module can do it ss well. Obviously you need to have xposed framework installed.
Sent from my GT-P3110 using XDA Free mobile app
Not working with my AT&T S3 with stock 4.4.2 android. This is driving my nuts. There has to be a way to disable this. HELP!!!
Hi,
I've rooted my Galaxy S4 mini because the home button is turning on the screen continiously draining my battery. The root was succesfull, but i cant edit the files with Total commander. I get a 're-mount error'. Anyone know how to solve this? I'm running stock android 4.2.2.
I also tried installing Wanam Xposed and found the option, but it didn't work.
Thanks
Removing WAKE didn't help my either. I had to comment out (#) the whole line in gpio-keys.kl.
Now HOME is completely disabled and I installed Auto Hide Soft Keys to create a virtual nav bar.
On the other hand, who needs HOME
no-idea said:
Removing WAKE didn't help my either. I had to comment out (#) the whole line in gpio-keys.kl.
Now HOME is completely disabled and I installed Auto Hide Soft Keys to create a virtual nav bar.
On the other hand, who needs HOME
Click to expand...
Click to collapse
Thanks for your reaction! My problem is that i cant change the gpio-keys.kl file. I get a 're-mount error'. But maybe i will need your suggestion further on.
Hmmm, phone is rooted?
I used ES File Explorer in Root Mode, changed gpio-keys.kl file permissions to rx-rx-rx, edited the file and restored permissions to rx-r-r. After a reboot, HOME was disabled.
no-idea said:
Hmmm, phone is rooted?
I used ES File Explorer in Root Mode, changed gpio-keys.kl file permissions to rx-rx-rx, edited the file and restored permissions to rx-r-r. After a reboot, HOME was disabled.
Click to expand...
Click to collapse
Yes the phone is rooted. I checked it with root checker. Maybe i need to change the the file permissions. How can i do this? With ES file explorer?
Do you use stock android ?
Yes I'm on stock rom.
Open ES Explorer and go to Tools. Switch on Root Explorer. Mark the file and change the permissions via More > Properties. Just add the middle and lower check on the right side.
Now edit the file and change the permissions back.
I am able to save the file now, but the home button is still functioning. I commented out the lines with HOME in gpio-keys.kl and rebooted. But still the screen keeps turning on because of the home button.:crying:
In reverse?
Anyone know if the opposite variation on this is possible?
I.e., I'd like to be able to use the home button to wake my phone up, but not to take me to the home screen, simply to turn the screen on so I can continue with whatever app I'm currently using, such as gps... (if it can carry on working as home button when the screen is already on, that would be fine).
Using the side power button can sometimes be a hassle and I'd like a way to simply turn the screen on quickly. I'm also on CM not stock though...
Thanks!

Fix for old headsets (earphones with one button) (non-Android dedicated) in Lollipop

Hi all,
i recently upgraded to Lollipop 5.0.2 (big mistake, I prefered KitKat, but I don't know how to downgrade).
One of the major problems for me was the fact that my headsets did not work with Headset Button Controller (or any other headset control app).
They worked just fine in Kit Kat.
I must mention that this headset earphones were from another Samsung phone (non-smartphone). But I am very satisfied with them and don't want to buy other ones.
( I also have Android-dedicated earphones, but they do not deliver the same quality (but they worked with Lollipop). I just don't want to use them)
Every time I pressed the button in order to stop/pause/volume control/answer phone, the mother****ing Google search would pop up.
I finally managed to fix this by re-mapping the keys on the keyboard layout, in order for HEADSETHOOK to be "perceived" instead of VOICE_ASSIST
First you need to root your phone (I used the King Root method, and then did a factory reset and installed SuperUser).
Then I installed SdCard fix, (which fixes the writing permissions on SD on KitKat and Lollipop) https://play.google.com/store/apps/details?id=nextapp.sdfix
After that I used the thread http://forum.xda-developers.com/nexus-4/general/guide-headset-controls-t1997277
From there I downloaded the Keytest App, and saw that my old headphones' clicks were perceived as key 582 VOICE_ASSIST instead of 226 HEADSETHOOK
The file you need to modify is in Root folder/system/usr/keylayout/Generic.kl
You will find many *.kl files there, but Generic.kl id the only one you need to modify
I sent it to my PC and modified it using WordPad.
What you need to do it find the the line for key 582 (towards the end of the file) and replace VOICE_ASSIST with HEADSETHOOK.
(Me personally I also replaced key 226 from HEADSETHOOK to VOICE_ASSIST, probably a bad decision )
Then you need to send it back to your phone and use a file explorer app to replace the one in your system.
I used Xplore (fell inlove with it since I had a Symbian Nokia). You need to give it superuser rights with write permission on read-only locations. ->Configuration -> Root access -> Superuser + mount writable (4th option). Now you can over-write the Generic.kl in /system/usr/keylayout/
After that I rebooted my phone and everything works fine.
On short presses Headset Button Controller kicks in and does what I need and on long press Google search pops up.
Hope it helps.
Delete

recent app softkey goes crazy

in the last month, i have g925f rooted , 5.1.1, sometimes (offten!) ) recent app softkey start random and open double window, recent apps.... i try to hibernate some apk but nothing.... i try also to clear cache...but nothing. In safe mode everithng works fine. i have only the last chance to clean all my data, but i read that this don't fix the problem.
it's very annoyng when you write and random the left soft key start to work itself......
any solution?
thank U!
i made all kind of reset, but nothing change, sometime i have a "crazy" soft button that start to work like a spirit! or stop to work.
i tried also "safe mode" and a little less, but same (random) problem!
The only way, i find, before to go to assistance (or to put in the garbage!!!) is to disable the softkey.
i find this on xda:
Use a root explorer (I used X-plore with root enabled).
Go to
/system/usr/keylayout/Generic.kl
Backup file Generic.kl ( copy it as a .bk or something )
Then open the file Generic.kl using the text editor within X-plore.
Then find the word APP_SWITCH linking with the code number (mine is key 254), change APP_SWITCH to MENU. Then reboot and your are done. The Recent Apps button is now back to being a Menu button. Life is great.
http://forum.xda-developers.com/gala...t3084638/page4
put"#" before key 254 and the key stop to exist, and stop to crash my balls
if someone has a different way to fix is wellcome for me.
thanks!

ALCATEL ONE TOUCH - Change Power button to Volume button

Hi all,
I really am no expert about anything to do with Android but I'm trying to change the power button to the volume button (power button is faulty). I was following this procedure that I found but I cannot locate this file:
Open root browser/ADB, go system/usr/keylayout. Look for file (like) mtk-kpd.kl The file name varies from device to device, but it normally ends with -kpd.kl/-keypad.kl.
I've got as far as the system/usr/keylayout file but there is nothing in there that looks like -kpd.kl/-keypad.kl
Anyone got any tips (or another way of doing this?). Advice much appreciated.

Categories

Resources