Introduction
This high-resolution differential pressure sensor with I2C communication is used to measure the difference in pressure across two points on a device. A high-performance MEMS pressure chip and a special conditioning chip are encapsulated inside the sensor. It will give you a comparative measurement between two points. Besides, the sensor IC adopts a unique multi-stage temperature-compensation algorithm to reduce the effect of environment on the output.
NOTE: In order to ensure the measurement resolution and the sensor life, please use the sensor in the clean air. Do not let water enter the nozzle of the sensor, or it will cause damage to the sensor.
Feature
- Multi-stage temperature-compensation algorithm
- I2C digital output
- High resolution
Application
- Home medical care equipment
- Portable medical equipment
- Medical monitoring
- Industrial control
- Central ventilation system
Specification
- Operating Voltage: 3.3V~5V
- Operating Range: ±500pa(±1.5%FS)
- Operating Current: <5mA
- Communication Mode: I2C
- I2C Address: 0x00
- Operating Temperature Range: -40℃~85℃
- Temperature-compensation Range: -5℃~65℃
- Dimension: 14.5×24mm/0.57×0.94”
Board Overview
Num | Label | Description |
---|---|---|
1 | VCC | Positive |
2 | GND | Negative |
3 | SCL | I2C data line |
4 | SDA | I2C data line |
IC Dimension
Note:
- The unit for data above is mm. The true position tolerance is not marked. The size tolerance is ±0.05mm.
- Connect B to the pipe on the bottom of the sensor, T to the top. The top pipe T is defined as high pressure connection.
Tutorial
Requirements
- Hardware
- DFRduino UNO R3 (or similar) x 1
- LWLP Differential Pressure Sensor x1
- Wires
Software
- Arduino IDE
- Download and install the Differential Pressure Sensor Library (About how to install the library?)
API Function List
/**
* @brief Get sensor data of single measurement
* @return Data of struct type
*/
sLwlp_t getData(void);
/**
* @brief filter processing function, get sensor data of filter processing
* @return Data of struct type
*/
sLwlp_t getfilterData(void);
/**
* @brief Auto calibration differential pressure drift.
*/
void autoCorDrift();
/**
* @brief Manual calibration differential pressure drift.
* @param drift
*/
void passiveCorDrift(float drift);
Connection Diagram
Sample Code 1- Data Measurement
/*!
* @file readData.ino
* @brief Read sensor pressure difference and temperature value
* @copyright Copyright (c) 2010 DFRobot Co.Ltd (http://www.dfrobot.com)
* @licence The MIT License (MIT)
* @author [fengli](li.feng@dfrobot.com)
* @version V1.0
* @date 2020-05-14
* @get from https://www.dfrobot.com
* @url https://github.com/DFRobot/DFRobot_LWLP
*/
#include <DFRobot_LWLP.h>
/*!
* @brief Construct the function
* @param pWire IC bus pointer object and construction device, can both pass or not pass parameters, Wire in default.
* @param address Chip IIC address, addresses 0x0
*/
DFRobot_LWLP lwlp;
void setup() {
Serial.begin(9600);
//Init chip
while (lwlp.begin() != 0) {
Serial.println("Failed to initialize the chip, please confirm the chip connection");
delay(1000);
}
//Auto calibration differential pressure drift
lwlp.autoCorDrift();
//Manual calibration differential pressure drift
//lwlp.passiveCorDrift(/*Drift = */8.23);
}
void loop(void){
DFRobot_LWLP::sLwlp_t data;
//Get data of single measurement
data = lwlp.getData();
//Get filter-processed data
//data = lwlp.getfilterData();
//Get temperature in unit centigrade degree
Serial.print("Temperature: ");
Serial.print(data.temperature);
Serial.println(" C");
Serial.print("Differential Pressure: ");
//Get pressure difference in unit pa
Serial.print(data.presure);
Serial.println(" pa");
delay(500);
}
Expected Results
FAQ
For any questions, advice or cool ideas to share, please visit the DFRobot Forum.