Skip to main content

Protocol Parser for Dr. Storage Dry Air Cabinets

Project description

drstorage

GitHub Project GitHub Actions Status: CI Code Coverage pre-commit.ci status Code style: black

Using

From python

>>> import drstorage
>>> data = bytearray.fromhex("abab00471200c5120901000000000000000a10025810000000000000140d0a")
>>> result = drstorage.models.F1_600.parse(data)
>>> print(result)
Container:
    humidity = 7.1
    temperature = 19.7
    model = 600

or from command line

$ python -c 'import sys; sys.stdout.buffer.write(bytes(bytearray.fromhex("abab00471200c5120901000000000000000a10025810000000000000140d0a")))' | drstorage parse --model F1_600
Container:     humidity = 7.1    temperature = 19.7    model = 600

Supported Models

  • generic (default, the "base" Dr. Storage model)
  • F1_600
  • X2M_157

Installation

In a fresh virtual environment

$ python -m pip install "git+https://github.com/kratsg/drstorage.git"

The above is actually cloning and installing directly from the Git repository. However, if you want to, you can of course also install it directly from the Git repository "locally" by first cloning the repo and then from the top level of it running

$ python -m pip install .

Contributing

As this library is experimental contributions of all forms are welcome. You are of course also most welcome and encouraged to open PRs.

Developing

To develop, use a virtual environment. Once the environment is activated, clone the repo from GitHub

git clone git@github.com:kratsg/drstorage.git

and install all necessary packages for development

python -m pip install --ignore-installed --upgrade -e .[complete]

Then setup the Git pre-commit hooks by running

pre-commit install

Acknowledgements

  • Mike Hance
  • Noah Peake
  • Will Johansson
  • James Tranovich
  • Anja Berens
  • Paul Ingemi
  • Matthew Gignac

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

drstorage-0.2.1.tar.gz (12.5 kB view details)

Uploaded Source

Built Distribution

drstorage-0.2.1-py2.py3-none-any.whl (6.6 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file drstorage-0.2.1.tar.gz.

File metadata

  • Download URL: drstorage-0.2.1.tar.gz
  • Upload date:
  • Size: 12.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.57.0 CPython/3.8.8

File hashes

Hashes for drstorage-0.2.1.tar.gz
Algorithm Hash digest
SHA256 b9b3278267555f21a85e2aee0799647e4be5590e4e9669e53f23fe3eabbaf393
MD5 bc3196c25486fbaf608af2b136378014
BLAKE2b-256 9cef15808d483f53f86b2be66d19ad2c7b135d06bff067b5576c851dac0b8d95

See more details on using hashes here.

File details

Details for the file drstorage-0.2.1-py2.py3-none-any.whl.

File metadata

  • Download URL: drstorage-0.2.1-py2.py3-none-any.whl
  • Upload date:
  • Size: 6.6 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.57.0 CPython/3.8.8

File hashes

Hashes for drstorage-0.2.1-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 ff59ad01107d247db62ce888c204beed1c88fb5d30deff1b80b5c4a8b8dbe9f3
MD5 28b64feee8c8de6b875181faccffee05
BLAKE2b-256 75c206f4d254b8c3ca9602513bdf309c6fdefecba43e7f3368816b432889961a

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