Approximation sensor in the Xiaomi smartphone: the principle of operation, malfunction and configuration

Have you ever noticed how your Xiaomi screen goes out during a phone call, as soon as you hold it to your ear? Or why the display does not respond to random touches when you call? This β€œmagic” is the proximity sensor, a small but critical component of modern smartphones. Without it, calls would become a nightmare: random taps, a speaker turned on instead of a tube, a discharged battery due to a constantly burning screen.

In Xiaomi smartphones (including the Redmi, POCO and Mi lines), this sensor is integrated into the top of the screen and works on the basis of infrared radiation. However, many users are faced with its incorrect operation: the screen does not go out during the call, the sensor locks for no reason or, conversely, the sensor ignores the approach of the hand. In this article, we will understand how the proximity sensor works, why it can break and what to do if it ceases to function.

Xiaomi’s feature is the use of combined sensors, where the proximity sensor is often combined with the light sensor, which saves space on the board, but complicates the diagnosis: if one of the sensors fails, the second can malfunction, and in budget models (for example, the Redmi 9A or POCO M3), the sensor can be less sensitive than in flagships like Xiaomi 13 Ultra.

What is a proximity sensor and why you need it

The proximity sensor is an electronic component that detects the presence of an object (usually a user's head) near the screen of a smartphone, and its main task is to save battery power and prevent accidental taps during a call. When you hold the phone to your ear, the sensor sends a signal to the system, and it performs three key actions:

1. turns off the screen backlight - to save energy and not blind the user.

2.Blocks touch input – to avoid accidental tapping of the cheek or ear (for example, completing a call or turning on the speakerphone).

3. Activates the main speaker - if you used speakerphone, the sensor returns the sound to the tube.

In Xiaomi smartphones, the proximity sensor is usually an infrared LED (IR-LED) and a photodiode located nearby. The LED emits invisible light that reflects off an object (like your head) and is captured by a photodiode. The microcontroller analyzes the strength of the reflected signal and determines the distance to the object.

Interesting fact: in some Xiaomi models (such as the Mi 11 or Redmi Note 10 Pro), the proximity sensor works together with the light sensor in one module, which allows the smartphone not only to respond to the approach, but also automatically adjust the brightness of the screen depending on the outside light.

πŸ“Š How often do you encounter proximity sensor problems?
Never had a problem.
The screen does not go out during the call.
The sensor is working too late.
Other malfunctions

Where is the proximity sensor in Xiaomi

In most Xiaomi smartphones, the proximity sensor is located at the top of the screen, next to the front camera.

  • πŸ“± Models with a β€œmonobra” (cutout): the sensor is on the left or right of the camera (for example, the Redmi Note 11, POCO X4 Pro).
  • πŸ“± Models with a "hole" in the screen: the sensor is integrated into the upper frame next to the hole for the camera (Xiaomi 12, Redmi) K50).
  • πŸ“± Mechanical camera models (e.g. Mi Mix 3): the sensor is hidden under the top of the screen.
  • πŸ“± Budget models (e.g. Redmi) 9C): The sensor may be less accurate and be placed under a plastic frame.

To accurately determine the location of the sensor on your model, you can use the test mode of the smartphone.

1. Open the Phone app and enter the code:

##6484##

2. In the menu that opens, select Proximity Sensor.

3. Raise your hand to the top of the screen – if the sensor is working, you will see a change in values from 5.00 (no object) to 0.00 (object detected).

If the code doesn’t work, try an alternative:

##4636##

In the Testing menu, find the Sensors section and check the sensor response.

πŸ’‘

If the test mode does not open, check if the MIUI shell blocks it. In some firmware, access to the engineering menu is disabled by default.

Signs of malfunction of the proximity sensor

If your Xiaomi approximation sensor isn’t working properly, you’ll notice the following symptoms:

  • πŸ”¦ The screen doesn’t go out during the call – even when you hold the phone to your ear, the backlight remains on.
  • πŸ“΅ Sensor is blocked for no reason – the screen ceases to respond to touch, although there are no objects nearby.
  • πŸ”Š The sound is automatically switched to the speaker - instead of the tube, a speakerphone is turned on.
  • ⚑ Fast battery discharge – if the sensor constantly β€œthinks” that the object is nearby, the screen may not turn off, consuming charge.
  • 🀯 False positives – the sensor responds to random hand movements or even a case.

The most common problem is that the screen doesn't go out during the call, and it's not only annoying (from random taps), it also puts the battery down quickly, and in some cases, it's not the sensor itself that's to blame, but the protective film or case that blocks the infrared signal.

Another common malfunction is that the sensor is triggered too late, for example, the screen goes out only 2-3 seconds after you put the phone to your ear.

  • Sensor contamination (dust, greasy traces).
  • Damage to the plume after falling or repairing.
  • A software glitch at MIUI.
Why can the sensor falsely trigger on the case?
The infrared sensor responds to the reflection of light from the surface. If the case has a glossy coating or metal inserts, it can reflect the IR beam back into the photodiode, mimicking the presence of an object, especially in cheap cases with shiny elements or in models with magnetic attachment (for example, for wireless charging).

How to check the proximity sensor on Xiaomi

Before you bring your phone to the service, you can diagnose the problem yourself. Here are 3 ways to check:

1. Manual testing through the engineering menu

As we mentioned earlier, use the code:

##6484##

On the Proximity Sensor menu, put your hand to the top of the screen.

  • 5:00: No object near.
  • 0.00 - Object detected (hand, head)

If the values do not change or jump chaoticly, the sensor is faulty.

2. Verification through the annex

Install one of the sensor testing apps from Google Play, for example:

  • Phone Doctor Plus
  • Sensor Test
  • CPU-Z (Sensors section)

These programs will show whether the sensor is responding to the approach of the object.

3. Visual examination

Turn on the flashlight and shine an angle on the top of the screen. Some Xiaomi models show a faint glow from an infrared LED (it looks like a dim red dot). If there's no glow, it's possible that the sensor is physically damaged.

Check the sensor response in the engineering menu|Install a test application|Check the sensor for dirt or damage|Try calling without a cover.|Reset your smartphone settings (if the problem is software-based)-->

Causes of failure of the proximity sensor

Xiaomi's proximity sensor can fail for several reasons, and can be divided into hardware and software:

Type of malfunctionReason.How it manifestsDecision
Hardware.Fall or impactThe sensor does not respond or is triggered chaoticallyReplacement of sensor or plume
Hardware.Pollution (dust, fat)False positives, slow reactionCleaning with alcohol or replacing protective glass
SoftwareMistake at MIUIThe screen does not go out in some applications only.Resetting or flashing
Hardware.Damage to the plumeSensor's working in a second.Repair or replacement of the plume
SoftwareConflict with the shellProblems after MIUI updateReverse to the previous version of the software

The most common hardware problem is damage after a fall. Even if the screen was intact, the impact could displace the sensor or damage its contacts. In budget Xiaomi models (such as the Redmi 8A), the sensor is often attached to a thin plume that easily breaks when disassembled.

Among the software reasons, the leading failures after the MIUI update. For example, after the release of MIUI 14, many users of Xiaomi 11T and POCO F3 complained about a malfunctioning proximity sensor, in such cases, a reset or rollback to the old version of the firmware helps.

Important: in models with AMOLED-screens (for example, Xiaomi 12 Pro or Redmi) K40) The proximity sensor may conflict with the always-on display function (AOD). If the sensor is triggered too often, try turning it off. AOD customized.

How to fix the proximity sensor on Xiaomi

If the sensor stops working, don’t rush to bring your phone to the service. First try these 5 ways to solve the problem:

1. Clean the sensor.

Often it's pollution. Take a cotton swab, moisten it in alcohol, and gently wipe the area around the front chamber and the top frame. Don't press hard, the sensor is fragile!

2. Take off the cover and film.

Some cases (especially those with metal elements) block the infrared signal. Try calling without a cover. Also remove the protective film - it may be too thick for the IR sensor.

3.Reboot the phone

It's a banal but effective way, and sometimes the sensor freezes because of a temporary failure in MIUI, and a simple reboot can bring it back to life.

4. Reset the settings.

If the problem occurs after the update, try:

1. Go to Settings β†’ About Phone β†’ Resetting.

2. Select Reset all settings (does not delete files, only settings).

3. Reset the device.

5. Update or re-flash MIUI

If the sensor does not work after the update, check if the patch has come out:

1. Open Settings β†’ About Phone β†’ System Update.

2 If no updates are available, try manually installing the latest version of MIUI via the Mi Flash Tool (instructions are available on the 4PDA forum).

If it didn't work, it's probably a hardware problem, and you're going to have to:

  • Replacement of the sensor (cost - from 500 to 1500 rubles depending on the model).
  • Repair of the plume (if it has departed after falling).
  • Replacement of the display module (in models where the sensor is soldered into the screen).

πŸ’‘

Before visiting the service, check if your model is not affected by the warranty. In official service centers Xiaomi replacement of the proximity sensor is often done free of charge, unless the defect is caused by mechanical damage.

Xiaomi models with frequent proximity sensor problems

Some Xiaomi smartphones are more prone to proximity sensor malfunctions, and here is a list of models that have this problem most often:

  • πŸ“± Redmi Note 8/8 Pro – the sensor often breaks after falls due to a fragile plume.
  • πŸ“± POCO X3 NFC β€” shell-fight MIUI 12.5, decided by a rollback MIUI 12.
  • πŸ“± Xiaomi Mi A2/A3 β€” Problems after upgrading to Android 10 (sensor stops responding).
  • πŸ“± Redmi 9/9A/9C β€” Low quality sensor in budget models, often false positives.
  • πŸ“± Xiaomi Mi 9T/9T Pro – the sensor fails after changing the screen (calibration required).

If you have one of these models, check the forums (like 4PDA or XDA-Developers) before repairing - there may be a software solution for your problem. For example, for the POCO X3 NFC, users have found a way to disable sensor optimization via ADB:

adb shell settings put global proximity_delay 0

This command resets the sensor's delay, which helps with a slow reaction.

⚠️ Please note: if you have never worked with ADB, Don't execute this command without instructions. Incorrect settings can lead to other system failures.

FAQ: Frequent questions about the proximity sensor in Xiaomi

Can I turn off the proximity sensor on Xiaomi?
Yes, but it's not recommended. Disabling the sensor will keep the screen from going out during the call and the sensor from getting locked. If you still need to turn it off (for example, for testing), use the Sensor Disabler app from Google Play or the command. ADB: adb shell settings put global proximity_sensor_enabled 0 To get it all back, replace it. 0 on 1.
Why does the approximation sensor only work in some applications?
This may be due to the settings of a particular application (e.g. WhatsApp or Telegram have their own sensor control algorithms).The problem may also lie in the resolutions: 1. Go to Settings β†’ Applications β†’ Resolution Management. 2. Find an application where the sensor does not work (e.g. Calls). 3. Make sure it has access to the Phone and Sensors.
Can I replace the sensor by myself?
Theoretically, yes, but it requires experience in electronics repair. The sensor is usually soldered into a plume or display module, and replacing it without special equipment can damage other components. If you do, you'll need: a soldering station with a thin sting. A new sensor (you can buy on AliExpress or in parts stores); Tweezers and an antistatic bracelet. For most Xiaomi models, it's easier and cheaper to turn to the service.
How to distinguish a sensor malfunction from a firmware problem?
Do the test: 1. Go to the engineering menu (##6484###) and check the sensor response. If it doesn't respond, it's a hardware problem. 2. Install custom firmware (like LineageOS or Pixel Experience). If the sensor is working, MIUI is to blame. 3. Check the sensor on another phone (if possible). For example, the Redmi Note 10 and POCO X3 use similar sensors.
How much does it cost to replace the proximity sensor in the service?
Cost depends on model and region: Xiaomi model (β‚½) Redmi's note 9A/9C 500–800 Often changed with the display POCO X3/X4 900–1200 Requires calibration after Xiaomi replacement 11/12 1200–1800 Sensor soldered into the display module Redmi Note 8/9 Pro 700–1000 In official Xiaomi service centers, the price may be higher, but you will get a warranty for repairs.