[REQ] Toogle screen on/off with proximity sensor - Windows Mobile Software Development

Hi pals!
I've been surfing this site for long time. I've had a lot of fun with all the different applications in here and now I've got a request.
I've found some applications for proximity sensor, I've seen those that turn off the screen when detect proximity. But I haven't found the one that turns on the screen once it detects the proximity again.
I'd like to put my Leo on the table and pass my hand in front of the sensor to turn the screen off and pass it once more to turn it on.
Anyone?

Related

how to calibrate the proximity sensor?

My new defy 's proximity sensor seems cannot work correctly,when i making a call ,the screen shut off immediately,and the screen could not light on by any key,but when i touch the proximity sensor with my finger,the screen may be light on!
so i download a app to test the proximity sensor which name's"Android sensor data",this app fingue out the state of proximity sensor,"near" or "far",sometimes I just passing my finger over the proximity sensor, the reading will show 'near' and then remain 'near' even when my finger is moved away!
Can anyone else help me to calibrate the proximity sensor?google told me some android phone can do this ,such as htc, zte etc.
goole tell me android phone have some standard testcode,such as *#*#4636#*#* can show the phone statue,it works correstly in Defy,*#*#0588#*#* test the proximity sensor ,but it doesn't work in defy!!!
is in-pocket detection enabled?
it gave me lots of problems in the past

energy rom's bug?screen light off when calling

I flash energy's rom,it's good.but screen light off when calling makes me crazy.However I press the power button,the screen does not light on.every way i can do (regedit,change light sensor) does not work.
so please ,anybody knows?
You're saying that no matter what you do, the screen will not light up at all during a phone call once the proximity sensor turns turns the screen off?
yeah,you are right,but some rom can light up during a phone call,others can not.I'm crying for this
I've used Energy ROMS, and they were bullet proof, ran perfect, did everything they were supposed to do, like turn the screen off when I help the phone to my ear or had an object within proximity of the sensor, and the screen relit whenever I pulled the phone from my ear or moved an object away from the sensor...if you're saying the screen stays dark and you cant turn it on even with nothing blocking the sensor, then I recommend posting that issue in the Energy ROM thread as there could be a solution...if you're saying the proximity sensor works normally and you'd prefer to deactivate it, I searched around for that for you and didn't find a resolution...you can, however, if the sensor works properly...cover it up all the time (perhaps a small piece of black tape or something)...you'll have to hit the power button one time each time the phone takes or makes a call but the screen will stay lit til you turn it off again, even during a call
thank you Gt247. thank you so much.I think I found the way to resolve my screen's problem
I read a bunch where people were looking for a way to disable the proximity sensor...perhaps if that's what you've done, you could post the solution here in the event those peple are still looking
I have tried some apps to disabled my proximity sensor,but those all do not work,I think it's my phone's hardware problem,I have already decided to open my phone to fix it.
so before I fix this fool sensor ,any knows which app can test the proximity sensor?
just a app to test whether my proximity sensor work normally, any clue?
usomething said:
I have tried some apps to disabled my proximity sensor,but those all do not work,I think it's my phone's hardware problem,I have already decided to open my phone to fix it.
so before I fix this fool sensor ,any knows which app can test the proximity sensor?
just a app to test whether my proximity sensor work normally, any clue?
Click to expand...
Click to collapse
You don't need any app to test the proximity sensor , just turn on your screen , and cover the sensor with your finger . If your proximity sensor works normally , screen will be off . When you remove your finger in seconds , the screen will be turned on again .
I think you can disable the proximity sensor simply by removing the shortcut in the "startup" folder , and restart .
If I misunderstood your words , ignore me pls ~
thanks pcgg.I have tested my proximity sensor,it seems not notice my finger,the screen always on.
I have not found the proximity sensor shortcut in my startup folder,here is the file list in my startup folder:
DeviceLockXT.lnk
LockDevice.lnk
SpbMobileShell.lnk
so could you tell me which lnk is the proximity sensor?I can't find the file about what you say by the name
It seems that there is not priximity sensor app in your phone ....
While there is an app called "Rhodium setting tool" in mine , and it has a option under the menu "phone" named "Light Sensor" . If I turn it on , screen will auto turn off during a call .
Maybe you can try that ?
Well , I must say that I did misunderstood your words ... I thought you were complaining an app called "Proximity Sensor" . I found it in the "Jackos" ROM ... Sorry for misleading you .
You can try that app "Rhodium setting tool" . If it can not work , I will have no idea about it .
thanks pcgg.
I have already try the light sensor,I have tried many apps those can control the light sensor,but those don't work at all,at last I get a conclusion that is proximity sensor has a higher priority than the light sensor,proximity sensor can decide whether the screen can turn itself on or off.
my rom now is seeM_ZA's simplicity rom 21916,I'm now ready to flash jackos'r rom.whether it works ,I will tell you the result later
Any of the two, i suspect the first:
- you probably have some dirt inside your phone, at top left corner where the digitizer has a semi transparent glass for the proximity sensor (you hardly see it without disassembling screen)
- the proximity sensor is KO, you have to replace flex to cure it (about 35$ on eBay)
Once i replaced the digitizer on a TP2 and a little drop of glue went near the window of proximity sensor, it didn't work at all till i disassembled all again, cleared the the glue around the window letting again enough light to enter the sensor.

Ambient light sensor blinks when screen is off

So I just happened to notice that the sensor blinks on and off rapidly because I was using my webcams mirror mode and saw it flashing (invisible to the human eye). I cant help but wonder why on earth it is active while the screen is locked? Any thoughts? Or anybody actually know why?
Because it is used as a proximity sensor: the phone senses when it is in your pocket or not so it can change the ring tone volume. I think it is also used as a "mute" sensor when you lay your phone screen down on the table but I am not sure of that.

Proximity Sensor Broken - Nokia XL

Hello!
I've started to have a problem with proximity sensor. While calling, the screen get black and there is no way to turn it on (it turn if the other persone close the call only).
I tried to install a proximity sensor controller utility and it says it's always 0cm distance. By touching it I found it unlocks sometimes under pression or temporarily if I blow in it (but after a little it locks again).
I searched in settings an options to deactivate it but I really can't find it..
Can you tell me where I can find the option to turn off the proximity sensor, please?
And is there any way to fix this problem eventually? However I'd be happy if I can just deactivate the sensor..
Thanks

Question How to wake up my new phone with a wave (proximity?)

I just upgraded from an S8 to a 21 FE, I had this setup where my screen will turn off using the proximity sensor, so when I open my case cover or lift it up from the table it just turns on automatically.
Upgrading, I notice the apps I used (Gravity Screen, Smart Screen On Off) are not working as they used to. In most tests, I did seem to suggest the proximity sensor only responds when the front lens is covered by my thumb instead of just hovering over with my hand like before. I did the *#77692# test and the Proximity sensor is working fine then WHEN I enable it so I'm at a lost here, is this a technical issue, is this by design
EnigmaXtreme said:
I just upgraded from an S8 to a 21 FE, I had this setup where my screen will turn off using the proximity sensor, so when I open my case cover or lift it up from the table it just turns on automatically.
Upgrading, I notice the apps I used (Gravity Screen, Smart Screen On Off) are not working as they used to. In most tests, I did seem to suggest the proximity sensor only responds when the front lens is covered by my thumb instead of just hovering over with my hand like before. I did the *#77692# test and the Proximity sensor is working fine then WHEN I enable it so I'm at a lost here, is this a technical issue, is this by design
Click to expand...
Click to collapse
Didn't you find the gesture to double tap the screen to wake up?
ze7zez said:
Didn't you find the gesture to double tap the screen to wake up?
Click to expand...
Click to collapse
I did, but I'm used to waving my phone awake with both my hand and by opening my phone case, but it seems the more recent Galaxy phones don't allow the same use of the proximity sensor
EnigmaXtreme said:
I did, but I'm used to waving my phone awake with both my hand and by opening my phone case, but it seems the more recent Galaxy phones don't allow the same use of the proximity sensor
Click to expand...
Click to collapse
A touch sensor while the screen is locked can consume less power than a proximity sensor placed in a camera, for example.

Categories

Resources