Xiaomi smartphones running MIUI and HyperOS shells often face the problem of incorrect screen behavior during a conversation. Users notice that the display goes out long before the phone is brought to the ear or, conversely, does not light up when the device is removed. This causes enormous discomfort, since accidentally pressed cheek buttons can interrupt the call or turn on speakerphone.
The reason for this behavior is usually an approach sensor that is either contaminated or has a software calibration failure. In some cases, gadget owners prefer to completely deactivate this feature so that only the lock or touch button controls the screen. There are several proven methods for solving this problem, from standard settings to using an engineering menu.
In this guide, we will discuss all the current ways to control the operation of the sensor, you will learn how to accurately calibrate through a hidden menu, how to change system parameters through engineering code and what third-party utilities can help if the usual methods are powerless. It is important to understand that a complete shutdown can lead to accidental pressing, so it is worth weighing the pros and cons.
Reasons for the incorrect operation of the sensor on Xiaomi
Before we start taking radical action to shut down, we need to understand the nature of the failure. Most often, the problem is not physical failure, but programmatic conflicts or trivial pollution. Infrared sensors at the top of the screen read reflected light from nearby objects. If there is a crack, thick film or a layer of fat on the protective glass, the readings will be distorted.
Also common is the malfunction of the operating system after an update. MIUI is known for its aggressive power optimization, which sometimes leads to the sensors being turned off or calibrated incorrectly, in which cases the system "thinks" that the phone is near the ear, although it is not.
It's also worth noting the physical arrangement of the components. In many Redmi and Poco models, the sensor is hidden under the display or is in a narrow frame. Even a slight skew of the protective glass can block the beam. If you've recently changed the screen or glued the glass, this may be the problem.
โ ๏ธ Warning: Before any manipulation of system settings, be sure to back up important data. Interference with the engineering menu can lead to system instability.
For diagnosis, you can use a simple test: dial a special code in the โbell ringerโ and check the reaction of the indicators. If the indicator does not light up red or green when closing the upper part of the screen with your hand (depending on the model), then the hardware is faulty or requires serious calibration.
Basic calibration through the engineering menu
The safest and most effective way to fix the sensor is to recalibrate it. Xiaomi smartphones have a special diagnostic tool CIT, which allows you to reconfigure the sensitivity of the sensors without obtaining superuser rights, this method helps in 90% of cases of software failure.
To start, you need to go to the test menu. Open the Phone app and dial the combination ##6484##. If the code didn't work, try the alternative ##4636## or go through the About Phone menu by quickly clicking on the MIUI version. In the list that opens, find the Proximity sensor.
The calibration process is as follows:
- ๐ฑ Place your phone on a flat surface and remove your hand from the top of the screen.
- ๐ Press the Calibration button at the bottom of the screen.
- ๐ Keep an eye out for Value: it should be close to 0.0 or 5.0 (depending on the model).
- โ If the calibration is successful, the inscription โPassโ will appear, after which you need to click โBackโ and exit the menu.
If the Value value remains high after the procedure (e.g. 255.0), it indicates that the system "sees" the obstacle, in which case wipe the top of the screen with an alcohol wipe and repeat the procedure.
โ๏ธ Checklist before calibration
Disconnection through Engineering Code (CIT)
In some versions of HyperOS firmware or custom Android builds, there is the ability to programmatically disable the sensor, which is done through the same engineering menu, but requires care, and this method does not remove the driver, but only prohibits the system from polling the sensor during calls.
Log in to the engineering menu by code ##6484##. Find the Proximity sensor section. Inside there may be an Enable switch or an Off button. However, most Xiaomi stock firmware does not have such a direct button, and you have to resort to trickery through the developer menu or ADB.
If you have a switch on your menu, just switch the switch to Disable. Then restart the device. Check the result by making a test call. The screen should stop turning off when you put your hand up.
| Method | Difficulty | Risk of failure | Efficiency |
|---|---|---|---|
| Calibration of CIT | Low. | Minimum | Tall. |
| Engineering code | Medium | Medium. | Medium |
| ADB team | Tall. | High-pitched | Maximum |
| Apps from Play Market | Low. | Low. |
Remember that after the system update, all the settings of the engineering menu can be reset to factory values, in which case you will have to repeat the procedure, and some security updates can block access to hidden functions.
๐ก
If the standard code doesnโt work, try entering it in Googleโs Phone app if installed, or use the Engineering Menu app from Play Market to access hidden features.
Using ADB for Advanced Users
For those who are not afraid of the command line, the most reliable way is to use debugging on the command line. ADB (Android Debug Bridge. This method allows you to change system settings that are not available through a normal interface. You'll need a computer, USB-cable and installed drivers ADB.
First, activate the developer mode on your phone. Go to Settings โ About Phone and quickly press 7 times on the MIUI version. Then, in advanced settings, turn on โDebugging by USB.โ Connect your smartphone to your PC and allow access on the device screen.
Run the following command in the terminal on your computer to change the sensor behavior:
adb shell settings put system proximity_on_off 0Or, for a deeper disconnect:
adb shell pm disable-user --user 0 com.android.providers.settings(Be careful, the second command may affect other settings.)
Often, a team that changes sensitivity helps:
adb shell settings put system proximity_sensor_use_debounce 0Once you have the commands, be sure to restart your smartphone, and the good thing about this is that it makes changes at the system level, ignoring the limitations of the MIUI interface.
โ ๏ธ Attention: Use ADB A syntax error can lead to a bootloop (cyclic reboot) of the phone. Type commands carefully, checking each letter.
Third-party applications for sensor control
If you don't want to mess with code and your computer, Google Play apps come to the rescue, and they create a virtual layer of control by intercepting sensor signals. One of the most popular solutions is Proximity Sensor Reset/Fix or similar tools like Lesser Switches.
The way they work is simple: the app asks for permission to access the sensors and force them to change their status, or performs deep calibration that is not available with regular means. Some programs allow you to set a sensitivity threshold so that the screen will only go out when you press it to the ear completely.
Popular features of such applications:
- ๐ง Automatic calibration in one click.
- ๐ซ Forced shutdown of the sensor during calls.
- ๐ Visualization of sensor readings in real time.
- โ๏ธ Create profiles for different situations (for example, โin the pocketโ and โdrivingยป).
However, it is worth considering that such applications are constantly hanging in memory and consume battery power. On modern versions of Android (11, 12, 13, 14), the system can aggressively โkillโ such processes, so you will have to manually prohibit the energy savings for the selected application in the battery settings.
Why can applications not work?
Alternative solutions and call setting
Sometimes you don't need to shut down the sensor completely, you just need to change the logic of the screen during a conversation. There's a Mode in Your Pocket feature in the MIUI shell that often conflicts with the proximity sensor, and turning it off can solve the problem of false positives.
Go to Settings โ Lock & Protect โ Mode in your pocket and turn off the switchboard.This will prevent the screen from locking when the phone is in the bag, but can also affect the approach sensor during calls, making it less aggressive.
You can also try disabling Smart Answers or other Google Assistant features that use microphones and sensors to activate. In the Phone app, check the incoming call settings: sometimes there is an option called Turn off screen while you talk, which you can deactivate.
If nothing works, it's the "crutchy" but working method: using a headset or hands-free by default, which completely eliminates the need to bring the phone to your face, making the proximity sensor useless in the context of conversations.
๐ก
The most effective solution is a combination of high-quality calibration through CIT and disabling the "in your pocket" mode.
Possible problems after disconnection
Once you've solved the problem with the fading screen, you may encounter new inconveniences, and the main consequence is that the screen will no longer go out during the conversation, which means that you will press buttons on the display with your cheek or ear: put a hold call, turn on the microphone or even reset the call.
In addition, some applications that use the proximity sensor for energy saving (for example, alarm clocks that go silent when you pick up the phone, or gesture control functions) may stop working correctly.
Owners of models with AMOLED displays also risk pixel burnout if the static image of the call interface burns constantly. So if you turn off the sensor, try to control the conversation time or use a button lock.
In rare cases, after unsuccessful manipulation of the engineering menu, the light sensor (autobrightness) may stop working. This is treated by resetting the settings to the factory or re-firmware of the device, so always assess the risks.