pylywsdxx


Namepylywsdxx JSON
Version 2.6.4 PyPI version JSON
download
home_pageNone
SummaryA Python3 class to interrogate Xiaomi Mijia LYWSD* sensors.
upload_time2025-01-19 11:20:33
maintainerNone
docs_urlNone
authorMausy5043
requires_python>=3.9
licenseNone
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            
[![License](https://img.shields.io/github/license/mausy5043/pylywsdxx)](LICENSE)
[![PyPI version](https://img.shields.io/pypi/v/pylywsdxx.svg?logo=pypi&logoColor=FFE873)](https://pypi.org/project/pylywsdxx)
[![Supported Python versions](https://img.shields.io/pypi/pyversions/pylywsdxx.svg?logo=python&logoColor=FFE873)](https://pypi.org/project/pylywsdxx)
[![PyPI downloads](https://img.shields.io/pypi/dm/pylywsdxx.svg)](https://pypistats.org/packages/pylywsdxx)
[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)
[![pre-commit.ci status](https://results.pre-commit.ci/badge/github/Mausy5043/pylywsdxx/devel.svg)](https://results.pre-commit.ci/latest/github/Mausy5043/pylywsdxx/devel)

# pylywsdxx

This is a Python3 library to allow interrogation of Xiaomi Mijia LYWSD* sensors via Bluetooth Low Energy (BLE).

**Note**: This is an unofficial project, and is in no way supported or endorsed by Xiaomi.

## Requirements

This module requires [`bluepy3`](https://pypi.org/project/bluepy3/) which should be installed automagically when using the installation instructions below.

Development of this package is done in Python 3.12. The package is considered forwards compatible at least upto Python 3.12 and probably also beyond. Backwards compatibility is not guaranteed; if it works on Python 3.9 or before consider yourself lucky. [Python versions that are end-of-life](https://devguide.python.org/versions/) are not supported.

The package has been extensively tested on a Raspberry Pi 3 Model B+ (aarch64) with Debian GNU Linux 12 /w Python 3.11.*.


## Installation

```
pip install pylywsdxx
```

## Usage

```
import pylywsdxx as pyly

mac = "A4:C1:38:0D:EA:D0"

device2 = pyly.Lywsd02(mac)
data2 = device2.data
print(f"Temperature: {data2.temperature}˚C")

device3 = pyly.Lywsd03(mac)
data3 = device3.data
print(f"Temperature: {data3.temperature}˚C")
```

Please note that this module has completely and intentionally broken backwards compatibility with previous
and existing versions of `lywsd02` and `lywsd03mmc` and with v1.* versions of itself.

## Acknowledgements

Based on previous work stolen from Mikhail Baranov (`h4`) : [lywsd02](https://github.com/h4/lywsd02)
and Duncan Barclay (`uduncanu`) : [lywsd03mmc](https://github.com/uduncanu/lywsd03mmc)


## Disclaimer & License
As of September 2024 `pylywsdxx` is distributed under [AGPL-3.0-or-later](LICENSE).

            

Raw data

            {
    "_id": null,
    "home_page": null,
    "name": "pylywsdxx",
    "maintainer": null,
    "docs_url": null,
    "requires_python": ">=3.9",
    "maintainer_email": null,
    "keywords": null,
    "author": "Mausy5043",
    "author_email": null,
    "download_url": "https://files.pythonhosted.org/packages/9f/13/52f67d7d792a072c677e09cb217941fac9c65e8091604134fe5058e38100/pylywsdxx-2.6.4.tar.gz",
    "platform": null,
    "description": "\n[![License](https://img.shields.io/github/license/mausy5043/pylywsdxx)](LICENSE)\n[![PyPI version](https://img.shields.io/pypi/v/pylywsdxx.svg?logo=pypi&logoColor=FFE873)](https://pypi.org/project/pylywsdxx)\n[![Supported Python versions](https://img.shields.io/pypi/pyversions/pylywsdxx.svg?logo=python&logoColor=FFE873)](https://pypi.org/project/pylywsdxx)\n[![PyPI downloads](https://img.shields.io/pypi/dm/pylywsdxx.svg)](https://pypistats.org/packages/pylywsdxx)\n[![Code style: black](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)\n[![pre-commit.ci status](https://results.pre-commit.ci/badge/github/Mausy5043/pylywsdxx/devel.svg)](https://results.pre-commit.ci/latest/github/Mausy5043/pylywsdxx/devel)\n\n# pylywsdxx\n\nThis is a Python3 library to allow interrogation of Xiaomi Mijia LYWSD* sensors via Bluetooth Low Energy (BLE).\n\n**Note**: This is an unofficial project, and is in no way supported or endorsed by Xiaomi.\n\n## Requirements\n\nThis module requires [`bluepy3`](https://pypi.org/project/bluepy3/) which should be installed automagically when using the installation instructions below.\n\nDevelopment of this package is done in Python 3.12. The package is considered forwards compatible at least upto Python 3.12 and probably also beyond. Backwards compatibility is not guaranteed; if it works on Python 3.9 or before consider yourself lucky. [Python versions that are end-of-life](https://devguide.python.org/versions/) are not supported.\n\nThe package has been extensively tested on a Raspberry Pi 3 Model B+ (aarch64) with Debian GNU Linux 12 /w Python 3.11.*.\n\n\n## Installation\n\n```\npip install pylywsdxx\n```\n\n## Usage\n\n```\nimport pylywsdxx as pyly\n\nmac = \"A4:C1:38:0D:EA:D0\"\n\ndevice2 = pyly.Lywsd02(mac)\ndata2 = device2.data\nprint(f\"Temperature: {data2.temperature}\u02daC\")\n\ndevice3 = pyly.Lywsd03(mac)\ndata3 = device3.data\nprint(f\"Temperature: {data3.temperature}\u02daC\")\n```\n\nPlease note that this module has completely and intentionally broken backwards compatibility with previous\nand existing versions of `lywsd02` and `lywsd03mmc` and with v1.* versions of itself.\n\n## Acknowledgements\n\nBased on previous work stolen from Mikhail Baranov (`h4`) : [lywsd02](https://github.com/h4/lywsd02)\nand Duncan Barclay (`uduncanu`) : [lywsd03mmc](https://github.com/uduncanu/lywsd03mmc)\n\n\n## Disclaimer & License\nAs of September 2024 `pylywsdxx` is distributed under [AGPL-3.0-or-later](LICENSE).\n",
    "bugtrack_url": null,
    "license": null,
    "summary": "A Python3 class to interrogate Xiaomi Mijia LYWSD* sensors.",
    "version": "2.6.4",
    "project_urls": {
        "Bug Tracker": "https://github.com/Mausy5043/pylywsdxx/issues",
        "Homepage": "https://github.com/Mausy5043/pylywsdxx"
    },
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "d46bf97a3ee2978eb1989e209dbc7bec9987276dfd0725baefc6ed6fb4141be3",
                "md5": "b2456ce44633aa3caa62c7cfe6a513ac",
                "sha256": "587756250228479091400f445add4efcca84ccd929d1727d8798944da5fff114"
            },
            "downloads": -1,
            "filename": "pylywsdxx-2.6.4-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "b2456ce44633aa3caa62c7cfe6a513ac",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.9",
            "size": 25019,
            "upload_time": "2025-01-19T11:20:31",
            "upload_time_iso_8601": "2025-01-19T11:20:31.615646Z",
            "url": "https://files.pythonhosted.org/packages/d4/6b/f97a3ee2978eb1989e209dbc7bec9987276dfd0725baefc6ed6fb4141be3/pylywsdxx-2.6.4-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "9f1352f67d7d792a072c677e09cb217941fac9c65e8091604134fe5058e38100",
                "md5": "7a77cd938dc6e2d0cd1cf3a8a4d61e9e",
                "sha256": "e8ae8b03ab9d8cdd03b4dfe6681f106ef23c324422c5021357734bb69085dcbe"
            },
            "downloads": -1,
            "filename": "pylywsdxx-2.6.4.tar.gz",
            "has_sig": false,
            "md5_digest": "7a77cd938dc6e2d0cd1cf3a8a4d61e9e",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.9",
            "size": 24224,
            "upload_time": "2025-01-19T11:20:33",
            "upload_time_iso_8601": "2025-01-19T11:20:33.092121Z",
            "url": "https://files.pythonhosted.org/packages/9f/13/52f67d7d792a072c677e09cb217941fac9c65e8091604134fe5058e38100/pylywsdxx-2.6.4.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2025-01-19 11:20:33",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "Mausy5043",
    "github_project": "pylywsdxx",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": false,
    "lcname": "pylywsdxx"
}
        
Elapsed time: 0.79096s