I've been trying to pour through the API and find a way I can access and disable the proximity sensor with some code, but have been unsuccessful.
Does anyone know of a way, rooted or unrooted, that I can disable the proximity sensor completely?
I searched the forums and the only ways I found seem applicable to WinMo based phones.
Heck, I'll pay for a way to do it, I hate the proximity sensor that much.
Even if someone knows of a way I could disconnect it by opening my phone, I might even spring for that - but obviously a software approach would be much more appreciated...
Thanks!
redball said:
Heck, I'll pay for a way to do it, I hate the proximity sensor that much.
Click to expand...
Click to collapse
Why do you hate it, if I may ask?
larsrya8 said:
Why do you hate it, if I may ask?
Click to expand...
Click to collapse
It is unreliable, and I know it isn't just my phone because a number of people I know also have an HTC Incredible and it seems to behave just as erratically on theirs.
Based on the code I read through for Phone.apk or whatever, it seems like it is supposed to disable the proximity sensor when you're using bluetooth, just like when using the speakerphone - but it doesn't. I can't figure out why, and I noticed another thread floating around with users having the same issue.
I want to be able to use my phone while on a call and not have to worry about a shift in overhead light or something passing over the sensor and flipping the screen off while I'm trying to use it.
I would much prefer the ability to disable it entirely, and have full control of the screen off/on using the power button.
There was one app on the app store recommended in my searches that let's you lock the screen on and only go off based on orientation or something, but it doesn't seem to work for the HTC Incredible
Try screebl? Should keep your phone on based on orientation, I think even during a call? Not sure though.
Sent from my ADR6300 using XDA App
drawde said:
Try screebl? Should keep your phone on based on orientation, I think even during a call? Not sure though.
Click to expand...
Click to collapse
I tried Screebl, too...but unless I'm configuring it wrong - it doesn't seem to work while in phone calls.
I hate it too. Makes my screen turn on and off when I use my bluetooth.
Sent from my HTC Incredible
I'm right there with you on this. I really hate being on a call and having the screen turn off and have to shake the phone around to be able to end the call.
JTCGiants56 said:
I'm right there with you on this. I really hate being on a call and having the screen turn off and have to shake the phone around to be able to end the call.
Click to expand...
Click to collapse
That's the worst! It's like it gets doubly worse just when I want to be able to hang up.
If it helps anyone...I found these links. (If you google for "mProximityWakeLock", and follow the first Stack Overflow link, it also has two links in it to PhoneApp.java and InCallScreen.java)
I tried making an app that just kept calling release(), but it ended up just creating force closes.
you guys should email HTC so t hey fix it in the next OTA.
I know this is not really about droid, but what proximity sensor also does is scale down CPU speed (even despite using setcpu) making Skype completely useless without a headset.
When you initialize a call - everything is cool.
If you hold your phone on your hand and use loudspeeker - it's cool.
As soon as you put it to close to your face/ear - not cool anymore. To the point where it's absolutely impossible...
Cheers!
It does check for a headset plugged in, bluetooth audio or the speakerphone enabled. For bluetooth, it gets a code from a getState method. It only prevents the screen from turning off if it equals a specific state. All you have to do is force it to always be true.
You can also put this in the build.prop to completely disable it.
Code:
gsm.proximity.enable=false
How i do this?
ihtfp69 said:
It does check for a headset plugged in, bluetooth audio or the speakerphone enabled. For bluetooth, it gets a code from a getState method. It only prevents the screen from turning off if it equals a specific state. All you have to do is force it to always be true.
You can also put this in the build.prop to completely disable it.
Code:
gsm.proximity.enable=false
Click to expand...
Click to collapse
I m a nerd....how i do this ? where i write this code in my htc desire?
Thanks
1. you need to be rooted (if your on this forum and running miui you already are rooted) and have ES File Explorer downloaded from market.
2. open es file explorer and press menu then settings scroll all the way to the bottom and go to root options & turn on root explorer & mount file system
3. go back to the view of your sd card now on the top left there is a image of sd card click that. look for a folder named system and click there
4. in system scroll to bottom and look for a file called build.prop long press on this file and click copy now click the house at top left and paste the build.prop to your sd card
5. now go back to the system folder click on build.prop and you will get a selection of apps to pick from depending on what you have installed. pick es note editor
6. now that you in your build.prop scroll down and WHERE i put "gsm.proximity.enable=false" ? i write this code where? in the end? Where?
Thanks
I need Help please
i need help in
http://forum.xda-developers.com/showthread.php?p=15689458#post15689458
Quick fix
I had a similar problem with my phone (Samsung Galaxy S2) when I put it in a waterproof box. The display went black when someone was calling, and it didn't reappear unless I opened the box and thereby deactivated the proximity sensor reading.
My quick fix is to put a piece of black electrical insulating tape over the sensor. Since the sensor basically is a light sensitive receiver looking for tiny reflections from a coded light source, total blackness will be read as "no near object".
But of course, a nice API call would be more elegant
For the love of god, bump!
Bump....seriously.....I've been looking everywhere for a way to disable proximity sensor. I wish Tasker had a simple Disable/Enable toggle on this sensor
Follow the post at the top of this page.
Make a backup of your rom just in case.
In summary, if you have root explorer then here's how I'd do it.
1. Navigate to /system.
2. Click the button at the top that says Mount R/W.
3. Open the file called build.prop.
4. At the bottom of the file add a line that says:
gsm.proximity.enable=false.
5. Hit menu, save and exit, reboot
It should work. If it doesn't you still should be ok. If unsure go ahead and restore your backup.
have the same problem but with incredible s. the screen goes down until on other end some body will not put the phone down! iv trued the false method. it did nothing.
Disabling Proximity Sensor works!
ihtfp69 said:
It does check for a headset plugged in, bluetooth audio or the speakerphone enabled. For bluetooth, it gets a code from a getState method. It only prevents the screen from turning off if it equals a specific state. All you have to do is force it to always be true.
You can also put this in the build.prop to completely disable it.
Code:
gsm.proximity.enable=false
Click to expand...
Click to collapse
For all those who are looking for a solution to a faulty proximity sensor and nothing else works, I can tell you that modifying the build.prop as described does work!
I simply can now press the button to turn the screen on or off while on call instead of relying on faulty sensor. Very pleased.
This was done using HTC WILDFIRE S a510a running HTC Sense GingerBread 2.3.3 which has been rooted with CWM root through CWM custom recovery installed after unlocking the bootloader at the HTCDEV site. The program used was called Rom Toolbox Lite and I used the "build.prop Editor" feature to safely make the modification to the file.
I'm running AOKP and every time I place my hand near the top of the phone the proximity sensor disables the screen. Is there a way I can change this so it only does this during calls? It's driving me nuts trying to get the notification shade to appear. Thanks
fbiryujin said:
I'm running AOKP and every time I place my hand near the top of the phone the proximity sensor disables the screen. Is there a way I can change this so it only does this during calls? It's driving me nuts trying to get the notification shade to appear. Thanks
Click to expand...
Click to collapse
That's not at all normal AOKP behavior. Do you perhaps have any apps installed that may be trying to control the proximity sensor?
codesplice said:
That's not at all normal AOKP behavior. Do you perhaps have any apps installed that may be trying to control the proximity sensor?
Click to expand...
Click to collapse
I'm not sure. The only root apps i have are Titanium Backup, ROM Manager, Call Recorder, and Cerberus
Edit: Derp, my brain just kicked in, I recently told call recorder to blank the screen when it is playing. Must be a bug since turning that off fixed it. Thanks for jarring my memory.
fbiryujin said:
I'm not sure. The only root apps i have are Titanium Backup, ROM Manager, Call Recorder, and Cerberus
Edit: Derp, my brain just kicked in, I recently told call recorder to blank the screen when it is playing. Must be a bug since turning that off fixed it. Thanks for jarring my memory.
Click to expand...
Click to collapse
No problem; glad it was an easy fix!
codesplice said:
No problem; glad it was an easy fix!
Click to expand...
Click to collapse
Yup, me too.
This screen comes up every so often on my phone and I don't know how/why it does.
Does anyone know how to activate this screen?
t2technology said:
This screen comes up every so often on my phone and I don't know how/why it does.
Does anyone know how to activate this screen?
Click to expand...
Click to collapse
Goto settings, motion, un check quick glance(if u don't like it anyhow). Uses proximity sensor while off so you can quick glance messages time battery etc.
Sent from my SPH-L900 using Tapatalk 2
Dear supporter
I face this problem and I don't know how to solve it
When I make a call my screen not turning off and I should turn it off manually by press on power button
Also I tried to calibrate but always it failed
Need your help
Ibrahim Omar said:
Dear supporter
I face this problem and I don't know how to solve it
When I make a call my screen not turning off and I should turn it off manually by press on power button
Also I tried to calibrate but always it failed
Need your help
Click to expand...
Click to collapse
go to settings > my device > call > and make sure "turn off screen during calls is checked
cosmyndemeter said:
go to settings > my device > call > and make sure "turn off screen during calls is checked
Click to expand...
Click to collapse
I'm sure
Ibrahim Omar said:
I'm sure
Click to expand...
Click to collapse
there may be some third part apps that don't let your screen turn off
make sure that Proximity Sensor and Ambient Light sensor are not blocked in any way (dust/dirt)
do a factory reset / fresh install of the rom
cosmyndemeter said:
there may be some third part apps that don't let your screen turn off
make sure that Proximity Sensor and Ambient Light sensor are not blocked in any way (dust/dirt)
do a factory reset / fresh install of the rom
Click to expand...
Click to collapse
This rom is new !
Ibrahim Omar said:
This rom is new !
Click to expand...
Click to collapse
I gave myself a few solutions
ahead do what you want!!!
Can't remember the thread but there is a thread on fixing the sensor if you search for it. It's a dialler code I think. Try installing android sensor bar as well to check the sensor.
Sent from my GT-N7105 using XDA Premium 4 mobile app
New pixel 2 user and very pleased, thus far.
I'm aware of the option to turn on speaker phone prior to making a call, but us there a way to switch during a call?
I have an old Automateit routine that used to do it automatically based on proximity sensor, but thst isnt working.
Thanks in advance
Move the device away from your face so the dialer's display lights up. Tap the speaker icon in the dialer.
Badger51 said:
New pixel 2 user and very pleased, thus far.
I'm aware of the option to turn on speaker phone prior to making a call, but us there a way to switch during a call?
I have an old Automateit routine that used to do it automatically based on proximity sensor, but thst isnt working.
Thanks in advance
Click to expand...
Click to collapse
My brother from another mother! Gotta love them Badgers!
There are apps that do this. I used to have one installed but don't have it anymore. Have you tried?
https://play.google.com/store/apps/details?id=com.hanan.android.ramkol
Sent from my Pixel 2 XL using Tapatalk