check-dht


Namecheck-dht JSON
Version 0.1.5 PyPI version JSON
download
home_pagehttps://github.com/j0hax/check-dht
SummaryNagios plugin to monitor humidity and temperature data from a Raspberry Pi Pico
upload_time2023-03-30 15:17:16
maintainer
docs_urlNone
authorJohannes Arnold
requires_python>=3.6,<4.0
licenseGPL-3.0-or-later
keywords nagios monitoring
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # check-dht
![PyPI](https://img.shields.io/pypi/v/check_dht)
![PyPI - Downloads](https://img.shields.io/pypi/dm/check-dht)
![PyPI - Python Version](https://img.shields.io/pypi/pyversions/check_dht)

Nagios plugin to monitor humidity and temperature data from a Raspberry Pi Pico

```console
$ check_dht
DHT OK - temperature is 23°C | humidity=48%;60;65;0;100 onboard=23°C;30;40 temperature=23°C;30;40
```

## Format
**Notice:** This plugin works in conjuction with the [pico-dht](https://github.com/j0hax/pico-dht) project! It expects a device to be available which periodically prints JSON data to a serial port:

```json
{
   "humidity":48,
   "temperature":23,
   "onboard":23,
   "error":0
}
```

- `humidity` and `temperature` are measurements taken directly from a DHT22/DHT11 sensor
- The RP2040s built-in temperature sensor is reported in the `onboard` field.
- In case of an Issue (e.g. I/O), a POSIX errno is set in the `error` field.

## Install
The recommended installation is via `pip install check-dht`.

### Manually
Alternatively, the source module can be executed after installing needed dependencies:

1. [pySerial](https://pyserial.readthedocs.io/en/stable/)
2. [nagiosplugin](https://nagiosplugin.readthedocs.io/en/stable/)

## Usage
```console
$ poetry run check_dht --help
usage: check_dht [-h] [-p PORT] [-b BAUD] [-w TEMP] [-c TEMP]
                 [--humidity-warning PERCENT] [--humidity-critical PERCENT]

Nagios plugin to monitor humidity and temperature data

options:
  -h, --help            show this help message and exit
  -p PORT, --port PORT  the serial file to read from
  -b BAUD, --baud BAUD  baudrate of the serial port
  -w TEMP, --warning TEMP
                        return warning if air temperature is beyond TEMP
  -c TEMP, --critical TEMP
                        return critical if air temperature is beyond TEMP
  --humidity-warning PERCENT
                        return warning if humidity is beyond PERCENT
  --humidity-critical PERCENT
                        return critical if humidity is beyond PERCENT

(c) Johannes Arnold 2023. This software is published under the terms of the
GNU GPLv3. For the companion project to this plugin, see
https://github.com/j0hax/pico-dht
```

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/j0hax/check-dht",
    "name": "check-dht",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.6,<4.0",
    "maintainer_email": "",
    "keywords": "nagios,monitoring",
    "author": "Johannes Arnold",
    "author_email": "johannes.arnold@stud.uni-hannover.de",
    "download_url": "https://files.pythonhosted.org/packages/fb/03/b517547cce90d309b044ab7fbfab3ec6873eb31f5df95c7e0cdd161b87d8/check_dht-0.1.5.tar.gz",
    "platform": null,
    "description": "# check-dht\n![PyPI](https://img.shields.io/pypi/v/check_dht)\n![PyPI - Downloads](https://img.shields.io/pypi/dm/check-dht)\n![PyPI - Python Version](https://img.shields.io/pypi/pyversions/check_dht)\n\nNagios plugin to monitor humidity and temperature data from a Raspberry Pi Pico\n\n```console\n$ check_dht\nDHT OK - temperature is 23\u00b0C | humidity=48%;60;65;0;100 onboard=23\u00b0C;30;40 temperature=23\u00b0C;30;40\n```\n\n## Format\n**Notice:** This plugin works in conjuction with the [pico-dht](https://github.com/j0hax/pico-dht) project! It expects a device to be available which periodically prints JSON data to a serial port:\n\n```json\n{\n   \"humidity\":48,\n   \"temperature\":23,\n   \"onboard\":23,\n   \"error\":0\n}\n```\n\n- `humidity` and `temperature` are measurements taken directly from a DHT22/DHT11 sensor\n- The RP2040s built-in temperature sensor is reported in the `onboard` field.\n- In case of an Issue (e.g. I/O), a POSIX errno is set in the `error` field.\n\n## Install\nThe recommended installation is via `pip install check-dht`.\n\n### Manually\nAlternatively, the source module can be executed after installing needed dependencies:\n\n1. [pySerial](https://pyserial.readthedocs.io/en/stable/)\n2. [nagiosplugin](https://nagiosplugin.readthedocs.io/en/stable/)\n\n## Usage\n```console\n$ poetry run check_dht --help\nusage: check_dht [-h] [-p PORT] [-b BAUD] [-w TEMP] [-c TEMP]\n                 [--humidity-warning PERCENT] [--humidity-critical PERCENT]\n\nNagios plugin to monitor humidity and temperature data\n\noptions:\n  -h, --help            show this help message and exit\n  -p PORT, --port PORT  the serial file to read from\n  -b BAUD, --baud BAUD  baudrate of the serial port\n  -w TEMP, --warning TEMP\n                        return warning if air temperature is beyond TEMP\n  -c TEMP, --critical TEMP\n                        return critical if air temperature is beyond TEMP\n  --humidity-warning PERCENT\n                        return warning if humidity is beyond PERCENT\n  --humidity-critical PERCENT\n                        return critical if humidity is beyond PERCENT\n\n(c) Johannes Arnold 2023. This software is published under the terms of the\nGNU GPLv3. For the companion project to this plugin, see\nhttps://github.com/j0hax/pico-dht\n```\n",
    "bugtrack_url": null,
    "license": "GPL-3.0-or-later",
    "summary": "Nagios plugin to monitor humidity and temperature data from a Raspberry Pi Pico",
    "version": "0.1.5",
    "split_keywords": [
        "nagios",
        "monitoring"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "7cd9ab424e649357a13a2b9631c2cd8e8ea73b89772583258bb51a13792da420",
                "md5": "8874542ec72a8dfcf580d6d53f23aaa4",
                "sha256": "15b483360f11e6acb0dea984876ce062273f3655c6250ebee9b0cd62ca60d8fe"
            },
            "downloads": -1,
            "filename": "check_dht-0.1.5-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "8874542ec72a8dfcf580d6d53f23aaa4",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.6,<4.0",
            "size": 16327,
            "upload_time": "2023-03-30T15:17:14",
            "upload_time_iso_8601": "2023-03-30T15:17:14.796860Z",
            "url": "https://files.pythonhosted.org/packages/7c/d9/ab424e649357a13a2b9631c2cd8e8ea73b89772583258bb51a13792da420/check_dht-0.1.5-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "fb03b517547cce90d309b044ab7fbfab3ec6873eb31f5df95c7e0cdd161b87d8",
                "md5": "512bf454c4b71fd206bdd14be0a0fff7",
                "sha256": "01187198ca3e01de7f13944eceb670d761bbffc0709754591573aa766826cec9"
            },
            "downloads": -1,
            "filename": "check_dht-0.1.5.tar.gz",
            "has_sig": false,
            "md5_digest": "512bf454c4b71fd206bdd14be0a0fff7",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.6,<4.0",
            "size": 15185,
            "upload_time": "2023-03-30T15:17:16",
            "upload_time_iso_8601": "2023-03-30T15:17:16.544752Z",
            "url": "https://files.pythonhosted.org/packages/fb/03/b517547cce90d309b044ab7fbfab3ec6873eb31f5df95c7e0cdd161b87d8/check_dht-0.1.5.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-03-30 15:17:16",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "github_user": "j0hax",
    "github_project": "check-dht",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "lcname": "check-dht"
}
        
Elapsed time: 0.07740s