Control devices connected to your Rademacher Homepilot (or Start2Smart) hub
Project description
pyrademacher
Python Library to read/control devices connected to your Rademacher HomePilot (or Start2Smart) hub.
This library uses the latest REST API, so you must update your hub to the latest firmware if you want to use this library.
Installation
Use pip to install pyrademacher lib:
pip install pyrademacher
Usage
API Class
With the HomePilotApi class you can acess the REST API directly:
from homepilot.api import HomePilotApi
api = HomePilotApi("hostname", "password") # password can be empty if not defined ("")
print(asyncio.run(asyncio.run(api.get_devices()))) # get all devices
asyncio.run(api.async_open_cover(did=1)) # open cover for device id 1 (assuming it's a cover device)
Manager Class
You can use the HomePilotManager helper class to more easily manage the devices:
import asyncio
from homepilot.manager import HomePilotManager
from homepilot.api import HomePilotApi
api = HomePilotApi("hostname", "password") # password can be empty if not defined ("")
manager = asyncio.run(HomePilotManager.async_build_manager(api))
asyncio.run(manager.update_states())
print(manager.devices["1"].is_closed)
print(manager.devices["1"].cover_position)
print(manager.devices["-1"].fw_version) # ID -1 is reserved for the hub itself
Each device in manager.devices is an instance of the specific device class.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file pyrademacher-0.14.3.tar.gz
.
File metadata
- Download URL: pyrademacher-0.14.3.tar.gz
- Upload date:
- Size: 34.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.9.20
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6fde320ee72456d0a07da1271c75c9810ed405ce72f45476f086414dea61b770 |
|
MD5 | a9f67e26423ff784f375ad384327bd74 |
|
BLAKE2b-256 | 2eb415d09b0d29ea153a0428ce3106b7ac6dc763c3a5515403745d7e5855c8d6 |
File details
Details for the file pyrademacher-0.14.3-py3-none-any.whl
.
File metadata
- Download URL: pyrademacher-0.14.3-py3-none-any.whl
- Upload date:
- Size: 42.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.9.20
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | cde3f3c55db2f6f7f125f566670d6f4edc03bf5abc9ca2b5d57a6ee0079f650d |
|
MD5 | 2c330daa1f0ae436c2b757f459778cab |
|
BLAKE2b-256 | 23124a138bfca04eeb8a1a31e6972fae96ad858ea18dd36558ed9377ce530442 |