Issues with the Proximity Sensor on

Samsung S10, S10+ and S10E devices

TL;DR: On probably all variants of the S10 series, the proximity sensor API does not work as intended and definitely not as specified anywhere in the various Android specifications. As of now there is no fix for this in sight.

The Samsung Galaxy S10 family of phones use a proximity sensor which works quite differently than on practically all other Android devices. Probably because the edge to edge screen left no room, they realized proximity detection using a so-called "Palm Proximity Sensor" which requires you to physically touch the screen with your palm. Covering the phone with a case, putting it in your pocket or laying it face down on the table won't work.

In my opinion this is a violation of the Android API specification which says this:

"The Android platform also provides a sensor that lets you determine how close the face of a device is to an object (known as the proximity sensor). "

And, in the Android system specification we find this statement:

"A proximity sensor reports the distance from the sensor to the closest visible surface. "

Finally, the Android 9 Compatibility Definition specifies:

"Device implementations MAY include a proximity sensor.

If device implementations include a proximity sensor, they:

  • [C-1-1] MUST measure the proximity of an object in the same direction as the screen. That is, the proximity sensor MUST be oriented to detect objects close to the screen, as the primary intent of this sensor type is to detect a phone in use by the user."

Note that in all of the cited sections proximity is defined as "objects" being close or far from the device. Nowhere they require that the device needs to by physically touched. Also, from the term "in use" we cannot infer that the phone needs to be either held near your ear or its screen being awkwardly palmed.

As a fun fact, Samsungs own apps -- the Phone app and the internal, hidden self-testing app you can open if you dial *#77692# -- use an internal sensor which is not exposed to 3rd party apps.

Since the Phone app uses a different sensor during calls to detect if your holding your phone near your ear, I suspect that this other sensor draws more power from the battery so they don't allow 3rd party apps to use it.

I have asked the Samsung support about this, but the response is mixed. They won't comment on the fact that their own apps use internal APIs and claim the implementation was valid. In my opinion these phones should not have received Google's Android device certification.

At this point the only hope is that Samsung releases a ROM update which fixes this in some way, but I don't expect this to happen.

Check for yourself!

If you own an S10/S10+/S10e device, you can verify this yourself. Follow these simple steps:

  1. Download my free Sensor Inspector app from Google Play
  2. Make sure the primary proximity sensor (it always has the ID #8) is selected
  3. Enable the data acquisition by toggling the switch on the top right.
  4. You should now see an initial, single FAR entry being logged
  5. Wave your hand above the the face of the device. You'll see nothing going on on the screen. (Note that any other Android phone will happily generate proximity events at this point!) However, if you do see anything just by waving, please contact me at: nullgrad.apps@gmail.com
  6. Now place your palm over the screen and actually touch it. You may need a couple of attempts, but in the end you should now see a few NEAR and FAR events being logged