I have a decently old Nexus S with a broken power button. Using the apps "Tap Tap App" and "Broken Power Button Fix" I can unlock the phone via motion sensor and volume down button.
Relatively frequently both these methods will fail to unlock the phone, but the phone is still on (I receive texts, phone vibrates etc). I assume this is because the apps stop responding or automatically close (maybe Dev Options: Background Process Limit?)
Help would be appreciated, I have to pull the battery every time these methods fail.