Using The BME280 I2C Temperature and Pressure Sensor in Python
Using The BME280 I2C Temperature and Pressure Sensor in Python
uk/2016/07/using-bme280-i2c-temperature-pressure-sensor-in-python/
1 of 8 5/4/17, 10:00 PM
Using the BME280 I2C Temperature and Pressure Sensor in Python http://www.raspberrypi-spy.co.uk/2016/07/using-bme280-i2c-temperature-pressure-sensor-in-python/
2 of 8 5/4/17, 10:00 PM
Using the BME280 I2C Temperature and Pressure Sensor in Python http://www.raspberrypi-spy.co.uk/2016/07/using-bme280-i2c-temperature-pressure-sensor-in-python/
wgethttps://bitbucket.org/MattHawkinsUK/rpispy-misc/raw/master/python/bme280.py
python bme280.py
3 of 8 5/4/17, 10:00 PM
Using the BME280 I2C Temperature and Pressure Sensor in Python http://www.raspberrypi-spy.co.uk/2016/07/using-bme280-i2c-temperature-pressure-sensor-in-python/
1 import bme280
2
3 (chip_id, chip_version) = bme280.readBME280ID()
4 print "Chip ID :", chip_id
5 print "Version :", chip_version
6
7 temperature,pressure,humidity = bme280.readBME280All()
8 Select Month
9 print "Temperature : ", temperature, "C"
10 print "Pressure : ", pressure, "hPa"
11 print "Humidity : ", humidity, "%"
4 of 8 5/4/17, 10:00 PM
Using the BME280 I2C Temperature and Pressure Sensor in Python http://www.raspberrypi-spy.co.uk/2016/07/using-bme280-i2c-temperature-pressure-sensor-in-python/
5 of 8 5/4/17, 10:00 PM
Using the BME280 I2C Temperature and Pressure Sensor in Python http://www.raspberrypi-spy.co.uk/2016/07/using-bme280-i2c-temperature-pressure-sensor-in-python/
6 of 8 5/4/17, 10:00 PM
Using the BME280 I2C Temperature and Pressure Sensor in Python http://www.raspberrypi-spy.co.uk/2016/07/using-bme280-i2c-temperature-pressure-sensor-in-python/
7 of 8 5/4/17, 10:00 PM
Using the BME280 I2C Temperature and Pressure Sensor in Python http://www.raspberrypi-spy.co.uk/2016/07/using-bme280-i2c-temperature-pressure-sensor-in-python/
8 of 8 5/4/17, 10:00 PM