Disable long-press power button
The Thing:
when walking or placing the N900 in a pocket of trousers or a jacket somehow it goes down, probably by unknowingly pressing the power button. It happens sometimes, there's no pattern nor probable bug causing this. I can't find any log of power on/off. Potential solution: disable the long-press on power button through file in (not sure about this) /sys/devices/platform/gpio-switch/ Advantages: N900 won't turn off anymore by incidental long-press. Disadvantages: When stuck or in need to do a hard restart you will have to remove battery. Does anyone have an idea how to debug or just disable the button? |
Re: Disable long-press power button
How do you know it was the power button press and not, for example, a dodgy battery?
The simplest solution is a hardware mod: glue a small ring (for example, a washer) to the case around the power button. You will still be able to press it with a tool but not by accident. |
Re: Disable long-press power button
Quote:
|
Re: Disable long-press power button
Quote:
|
Re: Disable long-press power button
Checked in another pocket and there was no such accident.
Back to the question: how to disable this functionality with some software edit? |
Re: Disable long-press power button
Quote:
|
Re: Disable long-press power button
...all of which brings us back neatly to the weak battery contacts.
|
Re: Disable long-press power button
Quote:
Quote:
|
Re: Disable long-press power button
I seriously doubt that this should not be configurable somehow.
Linux is in basics just configs in file system . Even hardware. Just, no one have been told where it's hidden. |
Re: Disable long-press power button
Quote:
|
Re: Disable long-press power button
Quote:
|
Re: Disable long-press power button
For monitoring PwrButton
$ evkey -d -t -1 /dev/input/event0 or there is a counter $ cat /proc/interrupts 376: 8 twl4030 PwrButton here says 8, but there was 4 pushed the pwrbutton For "disable" it: in /etc/mce/mce.ini you can change PowerKeyLongDelay=1500 value to some big number. |
Re: Disable long-press power button
Quote:
A story of my Jolla phone. A true story. My Jolla phone started randomly rebooting at some point. I only noticed it when I enabled a SIM card PIN: at least once, sometimes more times per day, when I pulled the phone out of the pocket, I found it waiting on the "enter SIM card PIN" screen. I could not think of anything that might have caused that other than an OS update I did just a few days before, so I naturally blamed that OS update. I noticed that the random reboots were a bit less frequent when I carried the phone in the shirt pocket than when it was in the trousers pocket. This is when I started suspecting that maybe, just maybe, the battery may have something to do with it: the phone experiences more vibrations from walking when in the trousers pocket. On the other hand, I witnessed quite a few random reboots when there were seemingly no vibrations at all, like for example while typing a reply to an SMS. So I went back to suspecting the software and, like you, I ignored the good advice to do something with the battery. I spent at least three months in this state, trying in vain to find the package responsible. Eventually I gave up and added a folded piece of paper under the battery to push it more hardly against the contacts, as the people had been suggesting to me all this time. And guess what? Random reboots stopped immediately and completely. End of story. |
All times are GMT. The time now is 21:23. |
vBulletin® Version 3.8.8