Skip to main content

Read BM280 through Python3 on raspberry pi

Project description

Quality Gate Status Maintainability Rating

Lines of Code Duplicated Lines (%)

Reliability Rating Security Rating Vulnerabilities

Upload Python Package Python package

GreenPonik_BME280.py Library for Raspberry pi


This is the sample code for read light with BME280 sensor.

Table of Contents

Installation

> git clone https://github.com/GreenPonik/GreenPonik_BME280.git
cd GreenPonik_BME280
pip3 install -r requirements.txt

or 

> pip3 install greenponik-bme280
from GreenPonik_BME280.BME280 import BME280

Methods

"""
Get light data
"""
def read_bme280():

Example

import time
from GreenPonik_BME280.BME280 import BME280

if __name__ == "__main__":
    try:
        bme = BME280()
        while True:
            data = bme.read_bme280()
            print(data)
            time.sleep(1)
    except Exception as e:
        print('An exception occurred: {}'.format(e))

Credits

Write by Mickael Lehoux, from GreenPonik, 2019

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

greenponik-bme280-0.0.5.tar.gz (163.5 kB view details)

Uploaded Source

Built Distribution

greenponik_bme280-0.0.5-py3-none-any.whl (4.4 kB view details)

Uploaded Python 3

File details

Details for the file greenponik-bme280-0.0.5.tar.gz.

File metadata

  • Download URL: greenponik-bme280-0.0.5.tar.gz
  • Upload date:
  • Size: 163.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.50.0 CPython/3.8.5

File hashes

Hashes for greenponik-bme280-0.0.5.tar.gz
Algorithm Hash digest
SHA256 8f5c1905f3a530a971fc87cdaff55cfef2390721ca00cdc481284c20628b009d
MD5 03866d0d7eb0ab9dec25d028c68f2213
BLAKE2b-256 20073707fe6c8b71469abd698992cafe0593f53e1a318ddeef62f103f9e39268

See more details on using hashes here.

File details

Details for the file greenponik_bme280-0.0.5-py3-none-any.whl.

File metadata

  • Download URL: greenponik_bme280-0.0.5-py3-none-any.whl
  • Upload date:
  • Size: 4.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.50.0 CPython/3.8.5

File hashes

Hashes for greenponik_bme280-0.0.5-py3-none-any.whl
Algorithm Hash digest
SHA256 27fa83d9bef523a8ede3741570d810d755a9fca58b2a28f2057f2f8f1fce4b2e
MD5 df589114f20d69607ffd88c40cfdec1f
BLAKE2b-256 f06b14c9ff4d692db6db804ad668756a1b3ba7c7d64725d61d8e95ebd799799d

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page