Skip to main content

Python 3 library for the Sensirion SCD30 sensor

Project description

scd30

Python library for the Sensirion SCD30 co2, temperature, humidity sensor.

I2C Clock stretching

Master needs to support Clock Stretching up to 150ms. The default in Raspbian is too low, we have to increase it:

To set it, download from here:

https://github.com/raspihats/raspihats/tree/master/clk_stretch

Compile:

gcc -o i2c1_set_clkt_tout i2c1_set_clkt_tout.c
gcc -o i2c1_get_clkt_tout i2c1_get_clkt_tout.c

execute (add to /etc/rc.local to run on every boot):

./i2c1_set_clkt_tout 20000 # for 200ms

Thanks

I borrowed some code and ideas from these two repos:

https://github.com/UnravelTEC/Raspi-Driver-SCD30 (python code, i2c clock stretching) https://github.com/sparkfun/SparkFun_SCD30_Arduino_Library (code structure, commands)

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

scd30-0.0.1.tar.gz (1.5 kB view details)

Uploaded Source

Built Distribution

scd30-0.0.1-py3-none-any.whl (13.8 kB view details)

Uploaded Python 3

File details

Details for the file scd30-0.0.1.tar.gz.

File metadata

  • Download URL: scd30-0.0.1.tar.gz
  • Upload date:
  • Size: 1.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.4.2 requests/2.21.0 setuptools/41.1.0 requests-toolbelt/0.8.0 tqdm/4.30.0 CPython/3.7.5

File hashes

Hashes for scd30-0.0.1.tar.gz
Algorithm Hash digest
SHA256 96cfe4526a7f588c5dd34df53c84c29c31a2133587622ec24f70146a10b2cd6d
MD5 a230974e8d8c716ead2b853c8a9a9203
BLAKE2b-256 6c73ae55a218f82431827b4d746231b74004cf04ed0ac7e777d74f752be0bb0a

See more details on using hashes here.

File details

Details for the file scd30-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: scd30-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 13.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.4.2 requests/2.21.0 setuptools/41.1.0 requests-toolbelt/0.8.0 tqdm/4.30.0 CPython/3.7.5

File hashes

Hashes for scd30-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 362686df2ae6371b5edc25eb336f6d572ccce43d0fbbd0c3eca8d75fbd550c4a
MD5 59716687dd36cd9deb276791bdffc0af
BLAKE2b-256 1ab247ca8db8208ab9962eddbb0b882ec990157b43c6e4e28f0709fc05165d8b

See more details on using hashes here.

Supported by

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