Calibration of the proximity sensor on Xiaomi: 5 ways to fix errors

The proximity sensor in Xiaomi smartphones is responsible for automatically turning off the screen during a call when you hold the phone to your ear. If it doesn't work properly, the screen can go out on its own, not respond to gestures, or, conversely, remain active during a conversation. Most often, the problem is solved by simple calibration, a procedure that can be performed independently without going to the service center.

In this article, we’ll take a look at all the working ways to calibrate the proximity sensor on Xiaomi, Redmi and POCO devices, from standard MIUI tools to hidden engineering menus. You’ll learn how to check the sensor’s performance, reset it, and avoid typical errors. Instructions are suitable for models based on MIUI 12/13/14 and HyperOS, including Xiaomi 13/14, Redmi Note 12/13, POCO F5/X5 and others.

Why is the proximity sensor on Xiaomi not working properly?

Before calibration, it is important to understand the cause of the failure. The proximity sensor may fail due to:

  • πŸ“± Programming errors - after updating MIUI or reset.
  • πŸ”§ Sensor contamination – dust, grease, or protective film block infrared signal.
  • πŸ”„ Incorrect calibration – factory settings are lost after the display drops or is replaced.
  • πŸ› οΈ Hardware damage – physical sensor failure (requires repair).

In 80% of cases, the problem is solved by software, and if the sensor does not respond at all (for example, the screen never goes out during a call), first check its physical condition.

  1. Turn on the flashlight and shine on the top of the screen (where the sensor is located).
  2. If you see a black spot or scratches, the sensor is damaged.
  3. Try removing a protective film or cover, which can block the signal.

A critical nuance: on some models (for example, Xiaomi 12T or Redmi Note 11 Pro+), the proximity sensor is combined with the front camera. In this case, calibration through the engineering menu can knock down the autofocus settings - be careful.

Method 1: Calibration through the engineering menu (code ##6484##)

The most reliable method is to use a hidden engineering menu, which works on most Xiaomi devices, but requires caution: incorrect settings can lead to failures.

Instructions:

  1. Open the Phone app and enter the combination: ##6484##.
  2. If the code didn’t work, try the alternative: ##4636## β†’ go to the Hardware testing β†’ Sensors tab.
  3. In the list of sensors, find Proximity Sensor.
  4. Press Calibrate and follow the hints on the screen.
  5. Once completed, restart the phone.

What to do if the engineering menu is not opened?

  • πŸ”Ή Make sure you enter the code without spaces and symbols.
  • πŸ”Ή On some firmware (e.g. HyperOS) the engineering menu is blocked – use method 3 or 4.
  • πŸ”Ή If the phone is experiencing a Connection problem, check the network connection (sometimes you need mobile internet).

Battery charge > 30%

VPN and proxy disabled

The phone is not connected to the PC

Screen covers and film removed-->

Method 2: Calibration through MIUI settings (without codes)

If the engineering menu is not available, use the built-in MIUI tools, which are safer, but not available on all models.

Step-by-step:

  1. Go to Settings. β†’ The phone.
  2. Click 5-7 times on the MIUI version until you become a developer!
  3. Return to the main settings menu and open Additional β†’ for developers.
  4. Find the option Calibration of the proximity sensor (on some firmware it is hidden - use the search by settings).
  5. Follow the instructions on the screen: You usually need to put your phone on a flat surface and wait for the process to be completed.

If you don’t have an option, try an alternative route:

Settings β†’ System and device β†’ Additional settings β†’ Special features β†’ Calibration of sensors

⚠️ Attention: MIUI 14 and HyperOS calibration point can be hidden. If it is not, use the applications from method 4 or reset the sensor settings (method 5).

Method 3: Use of applications for calibration (Proximity Sensor Reset)

If standard methods don’t work, install a third-party app. We recommend Proximity Sensor Reset (available on Google Play) – it supports most Xiaomi devices and doesn’t require root rights.

How to use:

  1. Download and install the Proximity Sensor Reset app.
  2. Run it and provide access to sensors (if requested).
  3. Press Calibrate Proximity Sensor.
  4. Place the phone with the screen up on a flat surface and wait for completion (usually 10–30 seconds).
  5. Reset the device.

Alternative annexes:

  • πŸ“Œ Sensor Calibration supports calibration of multiple sensors simultaneously.
  • πŸ“Œ Phone Doctor Plus – Checks the sensor before calibration.
  • πŸ“Œ CPU-Z β€” Shows current sensor values (useful for diagnosis).

πŸ’‘

Before using third-party applications, disable battery optimization for them in the MIUI settings. Otherwise, the application may close in the background.

Method 4: Reset sensor settings via ADB (for power users)

If the proximity sensor is completely β€œcrazy” (for example, the screen goes out at the slightest movement of the hand), resetting through the ADB (Android Debug Bridge) will help.

Instructions:

  1. Enable USB debugging in the developer settings (see Method 2).
  2. Connect your phone to your PC and install ADB drivers (you can download from the official Android website).
  3. Open the command line (Windows) or terminal (macOS/Linux) and type:
adb shell


su




echo 1 > /sys/class/sensors/proximity/prox_cal

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

adb shell am start -n com.android.settings/.DevelopmentSettings


adb shell settings put system proximity_offset 0

⚠️ Attention: su commands require root rights. If they don't exist, use only the second command. Incorrect input ADB-The commands may cause the system to fail!

What if the ADB can’t see the device?
1. Check if debugging is included on USB 2. Install drivers for your Xiaomi model (e.g. Mi) PC Suite). 3. Try another one. USB-cable (preferably original). 4. Reboot your phone and PC.

Method 5: Hardware reset (if nothing helps)

If the software methods don’t work, there are two options:

  1. Reset to factory settings (delete all data, but return the sensor to its original state).
  2. Replace the sensor at the service center (if the sensor is physically damaged).

How to reset:

  1. Create a backup copy of data (photos, contacts, messages).
  2. Go to Settings β†’ About the phone β†’ Reset settings.
  3. Select Reset all settings (does not delete files) or Delete all data (complete reset).
  4. After restarting, check the sensor.

If the reset didn’t work, the problem is the hardware. Contact Xiaomi’s service center or check the warranty (on most models, the proximity sensor is covered by a 12-month warranty).

πŸ’‘

Before resetting to factory settings, try rolling back the firmware to the previous version via MIUI bootloader. Sometimes sensor bugs appear after updates.

Table: Compatibility of calibration methods with Xiaomi models

Xiaomi modelEngineering menuMIUI settingsAnnexesADB
Xiaomi 13/14, 13Tβœ… (code ##6484##)❌ (covertly)βœ…βœ…
Redmi Note 12/13βœ…βœ… (in the section "For developers")βœ…βœ…
POCO F5/X5βœ…βŒβœ…βœ… (requires unlocking the loader)
Xiaomi 11 Lite, Redmi 10βœ…βœ…βœ…βŒ (restriction MIUI)
Older models (Redmi 5/6, Mi A2)❌ (menu blocked)βœ…βœ…βœ…

Engineering menu

MIUI settings

Third-party annex

ADB-team

Nothing helped, I turned to the service.-->

Frequent Mistakes and How to Avoid Them

When calibrating the proximity sensor, users often make mistakes that exacerbate the problem.

  • 🚫 Ignoring physical damage – if the sensor is cracked or contaminated, calibration won’t help.
  • 🚫 Use of informal firmware - on custom ROM (For example, LineageOS sensor may not work properly.
  • 🚫 Interrupting the calibration process – if you close the app or turn off the phone before completion, the settings are confused.
  • 🚫 Calibration in the case – even a thin case can block the sensor signal.

How do you check if the calibration has worked?

  1. Call the phone and hold it to your ear – the screen should go out.
  2. Move the phone, the screen should turn on.
  3. Use the Sensor Test app from Google Play to check the sensor values (normally: 0 is far, 1 is close).

FAQ: Answers to Frequent Questions

Can I calibrate the proximity sensor without root rights?
Yes, most methods (engineering menu, settings) MIUI, applications) do not require root. ADB-Teams, but they can be replaced by alternatives.
After calibration, the sensor got worse. What do we do?
Return the sensor's factory settings via the Engineering Menu (Proximity Sensor β†’ Reset) or reset the phone, and if the problem persists, the sensor may be damaged.
My Xiaomi doesn't have an engineering menu. What do I do?
Use apps from Google Play (like Proximity Sensor Reset) or calibrate via MIUI settings (if available). On HyperOS, the engineering menu is often blocked.
The sensor is working fine, but the screen doesn't go out when you call.
The problem may not be the sensor, but the call settings. Check: Is the Screen turned off when you touch your ear in the phone settings? Are there third-party call apps (like Truecaller) that block the function.
Can you calibrate the sensor on Xiaomi with a computer?
Yes, through ADB (see Method 4) or specialized programs like the Mi Flash Tool (requires an unlocked bootloader), but it's risky to use standard methods.