Description
Barometer shield. I2C Barometric pressure and temperature sensor based on HP303B chip. It is characterized by high accuracy and low power consumption, capable of measuring both pressure and temperature. The pressure sensor element is based on a capacitive detection principle that guarantees high precision in temperature changes.
Barometer shield specifications
– I2C interface
– Two selectable I2c addresses (0x77 or 0x76)
– Measuring range: Pressure: 300 – 1200 hPa.
– Temperature measuring range: -40 – 85 ° C.
– Pressure sensor precision: ± 0,005 hPa (or ± 0,05 m) (high precision mode).
– Relative accuracy: ± 0,06 hPa (or ± 0,5 m)
– Absolute accuracy: ± 1 hPa (or ± 8 m)
– Temperature accuracy: ± 0,5 ° C.
– Φ2mm mounting holes
- Arduino Library
| D1mini |
GPIO |
Shield |
| D1 |
5 |
SCL |
| D2 |
4 |
SDA |
Arduino code example:
#include <LOLIN_HP303B.h>
LOLIN_HP303B HP303B;
void setup()
{
Serial.begin(115200);
while (!Serial)
;
//Address of the HP303B (0x77 or 0x76)
HP303B.begin(); // I2C address = 0x77
// HP303B.begin(0x76); //I2C address = 0x76
}
void loop()
{
int32_t temperature;
int32_t pressure;
int16_t oversampling = 7;
int16_t ret;
Serial.println();
//lets the HP303B perform a Single temperature measurement with the last (or standard) configuration
//The result will be written to the paramerter temperature
//ret = HP303B.measureTempOnce(temperature);
//the commented line below does exactly the same as the one above, but you can also config the precision
//oversampling can be a value from 0 to 7
//the HP303B will perform 2^oversampling internal temperature measurements and combine them to one result with higher precision
//measurements with higher precision take more time, consult datasheet for more information
ret = HP303B.measureTempOnce(temperature, oversampling);
if (ret != 0)
{
//Something went wrong.
//Look at the library code for more information about return codes
Serial.print("FAIL! ret = ");
Serial.println(ret);
}
else
{
Serial.print("Temperature: ");
Serial.print(temperature);
Serial.println(" degrees of Celsius");
}
//Pressure measurement behaves like temperature measurement
//ret = HP303B.measurePressureOnce(pressure);
ret = HP303B.measurePressureOnce(pressure, oversampling);
if (ret != 0)
{
//Something went wrong.
//Look at the library code for more information about return codes
Serial.print("FAIL! ret = ");
Serial.println(ret);
}
else
{
Serial.print("Pressure: ");
Serial.print(pressure);
Serial.println(" Pascal");
}
//Wait some time
delay(500);
}
Only logged in customers who have purchased this product may leave a review.
Shipping within the Netherlands
This product will be delivered via PostNL letter post in a bubble envelope.- €3.45 shipping costs for orders under €25.
- €2.95 shipping costs for orders between €25 - €45.
- Orders above € 45,- will be
free of charge sent by PostNL letter post.
Ordered before 16:30 PM on workdays, shipped the same day!
Click here for costs outside the Netherlands.
Reviews
There are no reviews yet.