%global _empty_manifest_terminate_build 0 Name: python-pycoolmasternet-async Version: 0.1.6 Release: 1 Summary: A python library to control CoolMasterNet HVAC bridges over asyncio. License: MIT URL: https://github.com/OnFreund/pycoolmasternet-async Source0: https://mirrors.aliyun.com/pypi/web/packages/32/c5/38267ec08a8ae81a845dc35d81074d83aa46ffef9636fe5c73e9684c6c9c/pycoolmasternet-async-0.1.6.tar.gz BuildArch: noarch %description # pycoolmasternet-async A Python 3 library for interacting with a [CoolMasterNet](https://coolautomation.com/products/coolmasternet/) HVAC bridge. This is a fork of [pycoolmaster](https://github.com/koreth/pycoolmasternet), modified to present an async interface and some other small changes. ## Installation You can install pycoolmasternet-async from [PyPI](https://pypi.org/project/pycoolmasternet-async/): pip3 install pycoolmasternet-async Python 3.7 and above are supported. ## How to use ```python 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() ``` %package -n python3-pycoolmasternet-async Summary: A python library to control CoolMasterNet HVAC bridges over asyncio. Provides: python-pycoolmasternet-async BuildRequires: python3-devel BuildRequires: python3-setuptools BuildRequires: python3-pip %description -n python3-pycoolmasternet-async # pycoolmasternet-async A Python 3 library for interacting with a [CoolMasterNet](https://coolautomation.com/products/coolmasternet/) HVAC bridge. This is a fork of [pycoolmaster](https://github.com/koreth/pycoolmasternet), modified to present an async interface and some other small changes. ## Installation You can install pycoolmasternet-async from [PyPI](https://pypi.org/project/pycoolmasternet-async/): pip3 install pycoolmasternet-async Python 3.7 and above are supported. ## How to use ```python 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() ``` %package help Summary: Development documents and examples for pycoolmasternet-async Provides: python3-pycoolmasternet-async-doc %description help # pycoolmasternet-async A Python 3 library for interacting with a [CoolMasterNet](https://coolautomation.com/products/coolmasternet/) HVAC bridge. This is a fork of [pycoolmaster](https://github.com/koreth/pycoolmasternet), modified to present an async interface and some other small changes. ## Installation You can install pycoolmasternet-async from [PyPI](https://pypi.org/project/pycoolmasternet-async/): pip3 install pycoolmasternet-async Python 3.7 and above are supported. ## How to use ```python 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() ``` %prep %autosetup -n pycoolmasternet-async-0.1.6 %build %py3_build %install %py3_install install -d -m755 %{buildroot}/%{_pkgdocdir} if [ -d doc ]; then cp -arf doc %{buildroot}/%{_pkgdocdir}; fi if [ -d docs ]; then cp -arf docs %{buildroot}/%{_pkgdocdir}; fi if [ -d example ]; then cp -arf example %{buildroot}/%{_pkgdocdir}; fi if [ -d examples ]; then cp -arf examples %{buildroot}/%{_pkgdocdir}; fi pushd %{buildroot} if [ -d usr/lib ]; then find usr/lib -type f -printf "\"/%h/%f\"\n" >> filelist.lst fi if [ -d usr/lib64 ]; then find usr/lib64 -type f -printf "\"/%h/%f\"\n" >> filelist.lst fi if [ -d usr/bin ]; then find usr/bin -type f -printf "\"/%h/%f\"\n" >> filelist.lst fi if [ -d usr/sbin ]; then find usr/sbin -type f -printf "\"/%h/%f\"\n" >> filelist.lst fi touch doclist.lst if [ -d usr/share/man ]; then find usr/share/man -type f -printf "\"/%h/%f.gz\"\n" >> doclist.lst fi popd mv %{buildroot}/filelist.lst . mv %{buildroot}/doclist.lst . %files -n python3-pycoolmasternet-async -f filelist.lst %dir %{python3_sitelib}/* %files help -f doclist.lst %{_docdir}/* %changelog * Thu Jun 08 2023 Python_Bot - 0.1.6-1 - Package Spec generated