Barometer in Xiaomi smartphones: hidden possibilities of the pressure sensor

Have you ever wondered why your Xiaomi's sensors have a barometer? This tiny sensor, hidden inside the body, has more than just measuring atmospheric pressure. GPS-navigation to the correct display of floors in fitness trackers – barometer has become an integral part of modern smartphones, although many users do not even suspect its existence.

In this article, we will discuss in detail why Xiaomi integrates barometers into its devices (from budget Redmi to flagship Mi and other devices). POCO), How this sensor interacts with other components of the phone, and why turning it off can worsen the user experience, you will also learn how to check the performance of the barometer and whether it can be tricked into test the application.

Spoiler: Without a barometer, your smartphone won't be able to tell exactly which floor you're on in the mall, and the Mi Band fitness bracelet will show you climbing the stairs wrong, but everything in order.

What is a barometer in a smartphone and how it works

A barometer is a sensor that measures atmospheric pressure in the environment. Xiaomi smartphones use microelectromechanical (MEMS) A barometer that records pressure changes with accuracy Β±1 gPa. The principle of its operation is based on the deformation of the sensitive membrane under the influence of air: the higher the pressure, the stronger the membrane bends, and the built-in converter translates this deformation into digital data.

Unlike the classic mercury barometers, the sensors in phones consume a minimum amount of energy (about one hundred percent). 0.5 CA is active and occupies less space 3Γ—3 Like Xiaomi. 13 Pro is used by the Bosch barometer BMP388, capable of performing 200 This is critical for applications requiring high precision, such as weather services or mountain navigation.

Now, interestingly, the barometer in a smartphone is automatically calibrated every time you turn on the device, and if you notice that after you fly or you change height abruptly (like in a skyscraper elevator), the phone thinks for a while before you determine your location, that's what's happening.

  • πŸ“± Where: Usually integrated into the main board next to the accelerometer and gyroscope (Xiaomi often uses a chip). STM333 or BMP390).
  • ⚑ Energy consumption: standby mode - less than 0.1 mA, with active use - up to 1 mA.
  • πŸ“Š Accuracy: the error is Β±0.03 hPa in the range of 300–1100 hPa (equivalent to height from βˆ’500 +9,000 meters above sea level).

⚠️ Note: The barometer in a smartphone is not intended for medical measurements (for example, blood pressure monitoring), its readings depend on external conditions and can be distorted when in sealed rooms (for example, in the cabin of an aircraft or a submarine).

Why Xiaomi Set a Barometer: 5 Key Features

At first glance, it may seem that the barometer is an extra sensor that only increases the cost of a smartphone, but Xiaomi integrates it even in budget models (for example, the Redmi Note 12 or the Redmi Note 12). POCO X5) So here's the basic problem that this sensor solves:

  1. Acceleration GPS-navigation (A-GPS). A barometer helps you determine altitude, which reduces the time spent searching for satellites by 30 to 40 percent, especially in cities with tall buildings or in mountainous areas.
  2. Indoor flooring: Apps like Google Maps or Mi Fit use barometer data to show which floor you are on (such as a shopping mall or airport).
  3. Weather forecast: Services such as AccuWeather or built-in Weather app MIUI Analyze pressure changes to predict precipitation or wind changes.
  4. Fitness tracker: The barometer records the elevation differences when running, cycling or mountaineering, which allows you to count calories and route more accurately.
  5. Emergency systems: Some models (such as the Xiaomi 14 Ultra) use a barometer to detect a sharp drop in pressure, a sign of a possible collapse or avalanche in the mountains.

Without a barometer, many functions are worse, like if you turn off the pressure sensor in the developer settings, you'll have to:

  • πŸ“ Google Maps will take longer to β€œcatch” your location in multi-storey buildings.
  • πŸƒ Strava or Mi Fit won't be able to accurately calculate the height gain while running.
  • β˜” The built-in weather widget will stop showing local changes (for example, the approach of a thunderstorm).
πŸ“Š You knew about the barometer in your Xiaomi before this article?
Yes, I am actively using it.
I knew, but I didn't know why.
I just found out.
I'm not interested.

How a barometer affects accuracy GPS navigation

One of the most important uses of the barometer in Xiaomi smartphones is to help determine the height of the device. GPS-The thing is, the standard navigation systems GPS-chips (such as Qualcomm Snapdragon or MediaTek Helio) do not cope well with vertical positioning, with an error of up to 50-100 meters, which is critical in mountainous areas or when using drones.

The barometer solves this problem: it measures atmospheric pressure, which naturally decreases with height (about 1 gPa for every 8 meters). MIUI combine data with GPS and barometer to calculate height with precision Β±3 meters. This is particularly useful for:

  • 🚢 Hiking trails (applications like Komoot or Wikiloc use height to build a terrain profile).
  • ✈️ Drone flights (e.g, DJI Fly requires accurate altitude data to comply with legal restrictions).
  • πŸ”οΈ Mountaineering (PeakVisor or Fatmap applications show altitude in real time).

Example: if you climb a mountain, the barometer detects the pressure drop and adjusts the altitude in Google Maps. Without it, your location could "jump" between nearby slopes. 13T Pro with the barometer turned off, the height error in the mountains reached 120 meters, and with the included one - only 5 meters.

Xiaomi modelType of barometerElevation error (m)Time. GPS-fixation)
Xiaomi 14 UltraBMP390Β±2.13.2
Redmi Note 12 Pro+STM333Β±3.54.8
POCO F5BMP280Β±4.05.1
Xiaomi 12TBMP388Β±2.83.9

⚠️ Note: If you notice that GPS Xiaomi is getting worse after the update MIUI, Check if the barometer is turned off in the developer settings (Settings) β†’ The phone. β†’ Version. MIUI β€” Tap 7 times, then return to the Additional Settings β†’ Developer parameters β†’ Disable sensors).

Barometer and fitness trackers: how are floors and calories counted

If you use a Mi Band fitness bracelet or a Mi Fit app, the barometer in your Xiaomi smartphone plays a key role in calculating activity, because it's not enough to accurately measure a climb or climb a ladder with an accelerometer, you need data on changes in atmospheric pressure.

The algorithm works like this:

  1. The barometer records the drop in pressure (for example, when climbing on an elevator or stairs).
  2. The accelerometer confirms movement (steps or vibrations).
  3. The program compares the data and counts the number of floors covered.

Without a barometer, the Mi Band 8 or Watch 2 Pro will only show the climb of stairs based on the movement of the hand, which often leads to errors. For example, if you just wave your hand next to the elevator, the bracelet can count as a climb to the floor. With a barometer, the accuracy increases to 95%.

A pressure sensor is also used for:

  • πŸ‹οΈ Calorie Adjustments – Climbing a mountain requires more energy than walking on a plain.
  • πŸ§— Tracking climbing routes – apps like AlpineQuest are being built 3D-maps with elevation.
  • 🚴 Cycling – services like Strava analyze altitude to calculate average speed.

Compare the readings of the smartphone and bracelet|Walk the stairs with a known number of floors|Check the height in Google Maps (should match the sensor data)|Update the Mi Fit firmware to the latest version-->

How to check the work of the barometer on Xiaomi: step-by-step instructions

If you doubt that the barometer in your Xiaomi works correctly, it can be tested using built-in tools or third-party applications.

Method 1: Through the Engineering Menu (without root)

  1. Open the phone app and enter the code: ##4636##
  2. Select the item Information about sensors.
  3. Find the Pressure Sensor (Pressure Sensor) section.
  4. Look at the current readings in gPa or mm Hg (normal pressure at sea level is about 1013 hPa).
  5. Lift the phone up to the height. ~10 meters (for example, on the balcony) and check if the values have changed (should decrease by a maximum of 10 meters). ~1 gPa).

Method 2: Sensor Test (Play Market)

  • πŸ“² Install the Sensor Test application.
  • πŸ” Start the pressure sensor test (Barometer).
  • πŸ“ˆ Compare readings with current atmospheric pressure (you can find on the Gismeteo website).

Method 3: Through ADB (for advanced users)

If you have access to ADB, You can get raw barometer data by team:

adb shell dumpsys sensorservice | grep -A 10 "Barometer"

The answer will be a line of the type pressure=1012.3 hPa.

What if the barometer shows the wrong values?
If the sensor overstates or lowers the pressure, try: 1. Reboot the phone (sometimes the calibration is lost). 2. Update the firmware (in newer versions). MIUI Check the tightness of the case – if the phone fell or disassembled, the sensor could be damaged. 4. Reset the sensor settings through the engineering menu (#4636## β†’ If nothing helps, it is possible that the barometer is physically damaged (for example, after moisture is ingested).

Can a barometer be fooled and why?

In some cases, users are required to simulate pressure changes, such as testing height-related apps or tricking fitness trackers, but with reservations:

Method 1: Software emulation (requires root)

  • πŸ“± Install the Sensor Simulator application from XDA Developers.
  • πŸ”§ Select a pressure sensor (TYPE_PRESSURE) and set the values.
  • ⚠️ Risk: Some applications (e.g, PokΓ©mon GO) Blocking accounts for manipulating sensors.

Method 2: Physical impact

  • 🧊 Place the phone in a sealed bag and pump out the air (pressure will drop, simulating a climb uphill).
  • πŸ’¨ Or vice versa, compress the package - the pressure will increase (imitation of descent).
  • ⚠️ Dangerous: sudden pressure drops can damage the microphone or speakers.

Method 3: Using a Barochamber (for developers)

Professional testers use pressure chambers where they can accurately monitor pressure, such as in Xiaomi’s labs, smartphones are tested in the range of 100-1,100 hPa (from the top of the range). βˆ’1500 +9,000 meters).

πŸ’‘

If you need to test an app that depends on height (like a drone navigator), use an Android Studio emulator with a virtual pressure sensor.

⚠️ Warning: Deception of the barometer can cause system services to malfunction, for example, if you artificially lower the pressure, Google Maps can show that you are on the 30th floor, when in fact you are on the first. This can cause errors in navigation or emergency services (for example, when calling rescuers in the mountains).

Problems with the barometer in Xiaomi: causes and solutions

Sometimes the barometer in Xiaomi smartphones starts to work incorrectly, here are the typical symptoms and ways to eliminate them:

Problem.Possible causeDecision
Pressure readings are unchangedA jammed sensor or software failureRestart your phone or reset sensor settings through the engineering menu
GPS has been searching for satellites for a long timeBarometer turned off in the developer settingsInclude pressure sensor in Settings β†’ For developers β†’ Disable sensors
Fitness tracker doesn't count floorsConflict with another sensor (accelometer)Update the firmware MIUI Or calibrate the sensors manually.
Pressure jumps for no reason.Moisture or mechanical damageContact the service center (the sensor may require replacement)

If none of these methods worked, check to see if the core barometer is turned off. In some custom firmwares (like LineageOS), the pressure sensor can be deactivated to save battery power, and you'll need to return it:

  1. Install a kernel with support for all sensors (e.g. FrancoKernel for Xiaomi).
  2. Or return the stock firmware through the Mi Flash Tool.

πŸ’‘

If the barometer stops working after the update MIUI, Try to roll back to the previous version via Fastboot. Often, sensor bugs are fixed in the following patches.

FAQ: Frequent questions about the barometer in Xiaomi

Can I turn off the barometer to save battery power?
Technically yes, through the developer settings (Disable sensors) β†’ Pressure) However, the savings will be minimal (~0.5% charge per day, but here's the GPS And the fitness trackers will start to work worse.
Why does the barometer show a pressure of 0 GPa?
It's a sign of hardware failure. Possible causes: Sensor damage after falling or getting moisture; disconnection of the barometer plume from the motherboard; software failure (try resetting through the engineering menu); If the reboot doesn't work, contact the service center.
How does a barometer help in photography?
Some Xiaomi models (such as the 13 Ultra) use a barometer to adjust white balance in mountainous conditions. Camera algorithms analyze pressure and altitude to better determine lighting (at high altitude, the spectrum of light differs).
Can you use a barometer in Xiaomi as an altimeter for flights?
No, aviation requires certified altimeters with an error of no more than Β±1 meter. the barometer in the smartphone has an error Β±3-5 meters and does not take into account the temperature corrections critical for piloting, but for paragliding or drone racing, its accuracy may be sufficient.
Why is my Xiaomi not listed in the barometer, but it is?
Xiaomi sometimes does not advertise the presence of a barometer in budget models (for example, Redmi). 10C or POCO M5), You can check for it through the engineering menu (#4636##) or the app. CPU-Z (sensors).