I want to capture the event when user put device in the ear(Ex. To hear phone call) and also when user remove device from the ear. Basically i want to capture
- start time in ear.
- end time in ear.
Please help.
I want to capture the event when user put device in the ear(Ex. To hear phone call) and also when user remove device from the ear. Basically i want to capture
Please help.
Have you tried the Android site, http://developer.android.com/guide/topics/sensors/sensors_motion.html
It sounds like you'll need to use a combo of ACCELEROMETERs and Gyroscopses to detect when the phone is lifted up and rotated to be near the ear.