Skip to content

Barometric Pressure Sensor Guide

I got a chance to work with a module that is capable of measuring a range of pressures!  The testing is centered around a small and inexpensive pressure sensor module called aBarometric Pressure Sensor ”.

All the modules that you require to implement this project are available on our website. Visit Probots.

What is a Pressure Sensor??

A pressure sensor works by converting pressure into an analog electrical signal. When pressure sensing technologies were first manufactured they were mechanical and used Bourdon tube gauges to move a needle and give a visual indication of pressure.

This pressure sensor module has a measurement range of 0-5.8 psi. The unit psi is an imperial measurement that stands for pounds per square inch. If the psi unit is converted to the SI unit Pascal (PA), then the measurement range of the pressure sensor denotes 0-40 kpa (1 psi is equal to about 6894.76 Pascal)

What are Pressure Sensors used for??

Pressure sensors are used in a range of industries, including the automotive industry, Biomedical Instrumentation, aviation and the marine industry, to name a few.

In Consumer applications, The things we use, carry, and wear on a daily basis are growing in intelligence. Adding a pressure sensor to a consumer device can provide new information for an improved user experience.

Take vacuum cleaners for example. By measuring suction changes, they can detect what kind of flooring is being cleaned and adjust settings accordingly, or notify their owners when a filter needs replacing.

In Automobiles, hydraulic brakes are a crucial component in passenger safety. The ability to control a vehicle using brakes is down to a complex blend of components, including pressure sensors. These can be used to monitor pressure within the chambers of the braking system, alerting drivers and engine management systems alike if pressures are too low to be effective. If the pressure inside chambers is not measured, systems can fail without the driver knowing and lead to a sudden loss of braking efficacy and accidents.

In Medical applications, Raising the air pressure in a sealed chamber containing a patient is known as hyperbaric therapy. It can be effective for treating a number of medical conditions, from skin grafts, burn injuries and carbon monoxide poisoning to decompression sickness experienced by divers.

Measuring blood pressure correctly is crucial to patient care, as errors in readings can lead to a misdiagnosis. Thanks to recent innovations, tiny pressure sensors can even be implanted into the body, known as In Vivo Blood Pressure Sensing for more accurate monitoring.

What are the different types of Pressures??

Absolute pressure

Atmospheric pressure

Differential pressure

Overpressure (Gauge pressure)

I will breeze through this section on types of pressures because it is not mandatory to know, but also would not harm you in any way for extra knowledge you get here. To sum it up, Atmospheric pressure is the pressure exerted by the atmosphere on the earth, absolute pressure is measured from absolute zero, gauge pressure is the pressure on a gauge being read from zero, and differential pressure is the difference between two pressures.

So How Do These Barometric Pressure Sensors Work??

Barometric pressure sensors measure fluctuations in the pressure exerted by the atmosphere. The sensors require protection from condensing humidity, precipitation, and water ingress. If the enclosure is airtight, the sensor’s pressure port must be vented to the atmosphere.

Barometric pressure also changes with the weather or rather, the weather changes with changes in barometric pressure. Being able to measure and analyze small changes in atmospheric pressure helps meteorologists track the weather and predict storms.

Now let us do a basic breakdown from the IC to the Sensor,

The first component in the module is the HX710B which is a precision 24-bit analog-to-digital converter (ADC) made by AVIA Semiconductor ( The HX710B comes with a built-in temperature sensor designed for weighing scales and industrial control applications to interface directly with a bridge sensor.

The Second component we will examine is the pressure sensor, at the heart of the small module is a pressure sensor MPS20N0040D-S. Internally, the 6-pin pressure sensor comprises a Wheatstone bridge tailored to work with a regulated 5VDC power supply. But the pressure sensor used is in fact a close replica of the original MPS20N0040D-S pressure sensor.


This module does not support I2C communication.

Hardware Required:

Software Tool Required:

  Arduino IDE

Library Required :

HX711 Arduino Library: HX711

Wiring Diagram:

Connection Details:

ArduinoPressure Sensor


#include <Q2HX711.h>
const byte MPS_OUT_pin = 2; // OUT data pin
const byte MPS_SCK_pin = 3; // clock data pin
int avg_size = 10; // #pts to average over
Q2HX711 MPS20N0040D(MPS_OUT_pin, MPS_SCK_pin); // start comm with the HX710B
void setup() 
   Serial.begin(9600);  // start the serial port
void loop() 
    float avg_val = 0.0; // variable for averaging
    for (int i=0; i<avg_size; i++)
       avg_val +=; // add multiple ADC readings
       delay(50); // delay between readings
        avg_val /= avg_size;
       	Serial.println(avg_val,0); // print out the average

The above code gives you the raw ADC values, when air or any atmospheric pressure is detected by the sensor you can see visible changes in the readings. For you to get the exact readings you will have to convert it to psi for more details you can follow this tutorial here.

Here to inject air or to make any fluctuations in the pressure, I am using an air pump to see any variations in the readings. As you can see in the above image, there are variations in the readings when I pump air into the barometric pressure sensor nozzle.

All the components used in this article are readily available on our website. Please visit: PROBOTS to buy any components you need to kickstart your project.

Leave a Reply

Your email address will not be published. Required fields are marked *