A python library to control CoolMasterNet HVAC bridges over asyncio.
Project description
pycoolmasternet-async
A Python 3 library for interacting with a CoolMasterNet HVAC bridge. This is a fork of pycoolmaster, modified to present an async interface and some other small changes.
Installation
You can install pycoolmasternet-async from PyPI:
pip3 install pycoolmasternet-async
Python 3.7 and above are supported.
How to use
from pycoolmasternet_async import CoolMasterNet
cool = CoolMasterNet("coolmaster")
# Supply the IP address and optional port number (default 10102).
cool = CoolMasterNet("192.168.0.123", port=12345, read_timeout=1)
# General information
info = await cool.info()
# Returns a dict of CoolMasterNetUnit objects. Keys are the unit IDs
units = await cool.status()
unit = units["L1.001"]
unit.unit_id
# Temperature unit: Imperial, Celsius
unit.temperature_unit
# Current reading of unit's thermometer
unit.temperature
# Current setting of unit's thermostat
unit.thermostat
# Setters return a new instance with updated info
unit = await unit.set_thermostat(28)
# True if unit is turned on
unit.is_on
unit = await unit.turn_on()
unit = await unit.turn_off()
# Fan speed: low, med, high, auto
unit.fan_speed
unit = await unit.set_fan_speed('med')
# Mode of operation: auto, cool, dry, fan, heat
unit.mode
unit = await unit.set_mode('cool')
# Get fresh info
unit = await unit.refresh()
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 pycoolmasternet_async-0.2.2.tar.gz
.
File metadata
- Download URL: pycoolmasternet_async-0.2.2.tar.gz
- Upload date:
- Size: 6.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | dac518bbd132642d7e58419f1da19c0c8968683ca3e050dc203c59d098e6e3ea |
|
MD5 | 31bdcf8b21f493b9ef17c5ca3ae77273 |
|
BLAKE2b-256 | bd1e25d3826a7d7efb8d75ccf8b9760598f38fad25829046e4e293ccf74f4877 |
File details
Details for the file pycoolmasternet_async-0.2.2-py3-none-any.whl
.
File metadata
- Download URL: pycoolmasternet_async-0.2.2-py3-none-any.whl
- Upload date:
- Size: 5.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.4
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | c4a35302786d24830351c57d20f72214d22283244ac12677d3cb3e5cb68d1925 |
|
MD5 | 38c6cf557f97ef8500fca2c42d67f42c |
|
BLAKE2b-256 | c49ddaf358eca4f9b0e2e0f3cbadba866dc9b50596ad32706ada9f51af71203f |