5pcs M5Stack® Temperature and Humidity Sensor Air Pressure Sensing DHT12 BMP280 I2C Interface

5pcs M5Stack® Temperature and Humidity Sensor  Air Pressure Sensing DHT12 BMP280 I2C Interface
5pcs M5Stack® Temperature and Humidity Sensor  Air Pressure Sensing DHT12 BMP280 I2C Interface 5pcs M5Stack® Temperature and Humidity Sensor  Air Pressure Sensing DHT12 BMP280 I2C Interface 5pcs M5Stack® Temperature and Humidity Sensor  Air Pressure Sensing DHT12 BMP280 I2C Interface



Description:

ENV is a environment sensor, can be used for temperature, humidity, and atmospheric pressure measurement. Build with DHT12 and BMP280.

DHT12 is a upgradation version of DHT11 humidity temperature sensor, fully downward compatible, more precise and add I2C interface. BMP280 is an absolute barometric pressure sensor especially designed for mo bile applications, offers highest flexibility to optimize the device regarding power consumption, resolution and filter performance.

Feature:

  • Temperature:
    • measuring area: -20 ~ 60 ℃
    • resolution: ±0.2℃
  • Humidity:
    • measuring area: 20 ~ 95 %RH
    • resolution: 0.1%
  • Air pressure
    • measuring area: 300 ~ 1100hPa
    • resolution: ±1hPa
  • GROVE interface, support UIFlow and for Arduino
  • Two Le go installation holes
  • Product Size: 32.2mm x 24.2mm x 8.1mm
  • Product weight: 4.2g

Package Included:

  • 5 x ENV Unit
  • 5 x Grove Cable

EasyLoader

 


2.After downloading the software, double-click to run the application, connect the M5 device to the computer via the data cable, select the port parameters, and click "Burn" to start burning.

     3.The CP210X (USB driver) needs to be installed before the EasyLoader is burned. Click here to view the driver installation tutorial

Example

1. for Arduino IDE

This is a ENV example, implemented reading temperature, humidity and atmospheric pressure function. 1, Before compiling, please install Adafruit BMP280 Library 2, copy Adafruit_Sensor.h to C:UsersDocumentsArduinolibrariesAdafruit_BMP280_Library

The code below is incomplete. To get the complete code, please click here.

/*    Install Adafruit BMP280 Library first.*/#include <M5Stack.h>#include "DHT12.h"#include <Wire.h> //The DHT12 uses I2C comunication.#include <Adafruit_Sensor.h>#include <Adafruit_BMP280.h>// new two objectsDHT12 dht12;Adafruit_BMP280 bme;// initializationM5.begin();Wire.begin();bme.begin();// read datafloat tmp = dht12.readTemperature();float hum = dht12.readHumidity();float pressure = bme.readPressure();


2. UIFlow

If you want the complete code, please click here.



Schematic:


PinMap:

M5Core(GROVE A) GPIO22 GPIO21 5V GND
ENV Unit SCL SDA 5V GND
 
















5pcs M5Stack® Temperature and Humidity Sensor Air Pressure Sensing DHT12 BMP280 I2C Interface See detail