May be this tool will be usefull.
It switch off screen using proximity sensor detection.
Like alternative power button.
After proximity detected - screen switched off and proximity sensor don't used until screen will be switched on again manualy.
No screenshots
Second time running will unload program from memory, it can be used for switching on/off proximity lock feature.
All settings in registry, settings reloaded on each program run.
HKEY_CURRENT_USER\Software\Exidler\Hd2ProximityScreenOff
AfterCallReactivateSensor = dword:150 - time in ms when activate proximity sensor after call ended
SensorOffWhenProximity = dword:0 - time in ms when disabling proximity sensor on proximity detected. May be useful for disabling accident detection. This time proximity sensor is still active and if no porximity detected with this time - screen will be switched on automatically
ActiveOnlyIfLocked = dword:0 - Activate Proximity sensor only if Phone locked.
HKEY_CURRENT_USER\Software\Exidler\Hd2ProximityScreenOff\Exceptions
Create any named sub keys with values:
ClassName = string - name of windows class
WndTitle = string - title of window
ProcName = string - name of process
For exception windows proximity sensor will be disabled if this one window is active.
All criterias are optional. For example create only one value ProcName="Explorer.exe" for disabling proximity lock when Resco Explorer is active.
Proximity sensor activated only in portrait mode.
Change log
2010-01-29: v0.2
- full uninstallable cab
- add options: After Call Reactivate Sensor, Sensor Off When Proximity, Active Only If Phone Locked, Exception windows
- disbaling Proximity lock when landscape mode
2010-01-28: v0.1 Test version. Bugs possible.
Great something to get us started, did you make this yourself? Are you willing to put some time in to perfect it & create some options etc. if we bug test it?
exidler said:
May be this tool will be usefull.
It switch off screen using proximity sensor detection.
Like alternative power button.
After proximity detected - screen switched off and proximity sensor don't used until screen will be switched on again manualy.
No screenshots, not settings, just install and reboot phone (or run tool manual from Install directory)
Second time running will unload program from memory.
Test version. Bugs possible.
Click to expand...
Click to collapse
How will this effect the screen turning on after a phonecall, i wan't the screen automatically turned on after a call without having to press a button.
Will this tweak allow default function in that case?
richardirv said:
Are you willing to put some time in to perfect it & create some options etc. if we bug test it?
Click to expand...
Click to collapse
I don't know which options may be added.
I'm can't full control proximity sensor. It's only possible to enable proximity sensor, and htc drivers switching off screen by itself. The i'm disable proximity sensor again
But if it's will be possible to implement some features - i can try to do this.
Ok this is a good start, for me the following things need to be worked out for this to work good.
1. Only works when phone is upright, ie. Portrait. Reason being is if the screen goes off via Proximity in when holding the phone in landscape there will be allot of accidental activations, especially while playing games etc. It is much less likely that proximity will be detected when holding the phone upright.
2. Screen needs to come back on when proximity not detected, as to not cancel out the in call screen off feature.
Will keep thinking! Really hope you can work some magic here exidler!! Thanks
ET said:
How will this effect the screen turning on after a phonecall, i wan't the screen automatically turned on after a call without having to press a button.
Click to expand...
Click to collapse
it will handle proximity sensor to default behavior after call. so i think (and shure) - screen will blink for short time (~200ms) and will be switched off by tool.
exidler said:
it will handle proximity sensor to default behavior after call. so i think (and shure) - screen will blink for short time (~200ms) and will be switched off by tool.
Click to expand...
Click to collapse
Let me test, I assume the cab can be de-installed and everything is back to default behaviour?
richardirv said:
1. Only works when phone is upright, ie. Portrait. Reason being is if the screen goes off via Proximity in when holding the phone in landscape there will be allot of accidental activations, especially while playing games etc. It is much less likely that proximity will be detected when holding the phone upright.
2. Screen needs to come back on when proximity not detected, as to not cancel out the in call screen off feature.
Click to expand...
Click to collapse
in call screen back on when no proximity
when not in call - it switch off. or you talking about switching on screen when not in call?
about landscape and portrait. it's make easy if screen orientation really changed (if not - polling g-sensor - is not a good idea for battery i'm think)
ET said:
Let me test, I assume the cab can be de-installed and everything is back to default behaviour?
Click to expand...
Click to collapse
Cab is Uninstallable, but you must close program manually before uninstalling: run program second time, it will show message about closing
exidler said:
in call screen back on when no proximity
when not in call - it switch off. or you talking about switching on screen when not in call?
about landscape and portrait. it's make easy if screen orientation really changed (if not - polling g-sensor - is not a good idea for battery i'm think)
Click to expand...
Click to collapse
I just ment you don't want it to interfere with the in call actions the HD2 already has.
As you say g-sensor polling etc. no good for battery. I have a feeling this maybe flawed before we get started.
richardirv said:
I just ment you don't want it to interfere with the in call actions the HD2 already has.
Click to expand...
Click to collapse
program know about call and not be interferace with HD2 proximity call actions.
Landscape alternative - Programs (windows) exceptions - when it's active - promity sensor may be disabled. (but this feature need more time for apply)
Just tested the app and maid an incomming call with an other phone, the screen will automaticly turn on after moving from my ear as should be.
Great app I must say!
My fear is when using apps like fpsece etc, the screen will keep going off. Need to put our heads together and brainstorm some ideas to prevent acidental proximity.
The landscape idea with g-sensor was the first thing that came to me but hopefully there will be a better idea. Maybe only when the phone is perfectly horizontal (i.e as it goes into a pocket) The problem is keeping the g-sensor active will drain battery....
Idea's peeps!!
Hmm no way of de-installing it. If I use the app and then push the on button and then try to remove the app via start/settings, after about 10 seconds the device freezes.
Even after trying to install the app again (wich usually workes to remove apps witch can't be completely removed via start/settings) the device freezes.
Taking battery out is only way to restart. App remaines on device though.
Noticed also that the app is flawed, trying to go with my right finger to the left top of the screen to push start makes the screen turn of and that simply sucks.
HOW TO REMOVE THIS APP?
ET said:
HOW TO REMOVE THIS APP?
Click to expand...
Click to collapse
Before uninstalling go to install folder (defaul is \Program Files\Hd2ProxmityScreenOff) and run exe file inside Hd2ProxmityScreenOff.exe
You will see message about that programe closed. Tap Ok and then uninstall.
All be fine.
about freezing when uninstalling without stopping in memory process i'm know.
exidler said:
Before uninstalling go to install folder (defaul is \Program Files\Hd2ProxmityScreenOff) and run exe file inside Hd2ProxmityScreenOff.exe
You will see message about that programe closed. Tap Ok and then uninstall.
All be fine.
about freezing when uninstalling without stopping in memory process i'm know.
Click to expand...
Click to collapse
OK thanks, it's de-installed correctly. Maybe will use it in the future when it has matured a bit.
The programm should look on proximity-sensor, when i turn on my phone with the power-button.
--> if proximity detectet, screen should be staying off
--> if no proximity, phone should be wake up
Is this possible with your app? This would be a very great feature off our hd2! Perfect locking solution!
Bib_x said:
The programm should look on proximity-sensor, when i turn on my phone with the power-button.
--> if proximity detectet, screen should be staying off
--> if no proximity, phone should be wake up
Is this possible with your app? This would be a very great feature off our hd2! Perfect locking solution!
Click to expand...
Click to collapse
it's not possible until full hack of promitiy sensor.
i'm not have a fule of knowlendge fo arm assembler interpereting.
it' not difficlt for poples, how have knowledge of arm programs research.
but for me, i'm only can handle simple events
We are waiting for full promitiy API
so all of yours requests is impossimle.
Its a good start. Keep the project on.
perhaps a little bit easier to develop and to get various possibilities:
could you add 2 parameters to your app:
-activate
-deactivate
or so.
then it could be called also from other apps depend on its needs and states.
And also one scenario: It should only work if screen is locked(using notification).Then it's sure,that it should switch off because sensor detection
Keep up your great work.A really good idea,which can be very useful, if adaptable and a little configurable.
Thanx
Micha
Dear all, just want to share the simple solution in case this would bother you.
Recently I noticed that during my train commute with the Tab (3 8) in the backpack that after reaching office, the battery got more drained than expected. Checking with "Better Battery Stats" I found that "grip_wake_lock" has kept my device active for no reason - so no deep sleep as it should be. If you want to check on the sensor, call the dialer and enter *#0*# to get the test application. You find the grip sensor at the bottom of the screen. It may miss on wifi only devices (like the vibrate was on my GTab 2 7 wifi).
I have not found any application actually using this sensor, though I am not sure about the TouchWiz to increase ring volume when in a bag - but I don't care about this anyway. This function is also on phones that do NOT have a grip sensor, so it is unlikely.
So now how to switch off the sensor and get rid of the grip_wake_lock:
in a root shell enter
echo 0 > /sys/class/sensors/grip_sensor/onoff
This was also found for another device having a grip sensor with other problems as described here:
http://forum.xda-developers.com/showthread.php?t=2237946
You can put the same in an init.d script, but as the stock kernel does not support it, you need to find another way to execute that automatically at boot. There are many tools doing this, I picked "Universal Init.d"
Hey guys, I'm a new user of SG6. I just sold my LG G2, and now I'm missing the function that keeps the screen off if the proximity sensor detects something. My battery is draining too fast and I suspect that in part is because of many accidental wakes.
Is there any configuration that makes such thing? Or any app with or without root to do it?
I'm also looking for an answer to this.
On my previous devices, I could use a feature of GravityBox to accomplish this, but it doesn't work on the S6. Maybe someone with Xposed experience can port the feature to a Samsung compatible version?
Hello all,
This has been an issue since my first sony. Gravity Box - an xposed module had a handy option in which at every screen wake, it was checking the proximity sensor to see if there is something near or not - it helped avoiding accidental dials and touches while in pocket.
I tried third party apps but the functionality is problematic. I also tried automations such as MacroDroid which held wakelock on proximity sensor - thus battery drain and cpu usage.
Samsung has an option within settings that does just that.
My question is, is there an adb command or a tasker automation (or even app) that brings this functionality back?
Looking fwd for your input. I am not rooted (for now) so the options are limited. Still I hope you guys have some bright ideas on the matter.
Cheers,