Hi! thank you very much!
thanks to your program I was able to confirm my doubts about the Proximity Sensor on my HTC HD2 (runing on Android). Other applications will only show the values of sensors, but values of this sensor did not changed.
in my case, your program show the value NEAR and didn't change.
I suggested that the symptoms described above are caused by the fact that the proximity sensor is blocked by something.
I've tried to shake and knock on the rear part of a phone, next to the camera in front of the sensors and tried again to check it - and voila - the sensor working again!
but I do not understand - how can I save the settings for your program? or I can only monitor the current values? After rebooting the operating system and run the program again - the settings are still -1