Commit Graph

48 Commits

Author SHA1 Message Date
ultratoto14
9ca3efb161 Fix brightness issues. 2020-11-17 08:42:39 +01:00
ultratoto14
352ba58336 Add RGB only scenes. 2020-11-16 14:11:42 +01:00
ultratoto14
9be72d1152 Update internal state whatever mode is. 2020-11-16 11:32:54 +01:00
ultratoto14
8d91d9278b Merge branch 'master' into light_scenes 2020-11-16 07:29:40 +00:00
ultratoto14
6e07a5581f First try to add scenes. 2020-11-09 13:39:46 +01:00
ultratoto14
a0f4fdf337 Use default home assistant behavior. Return only relevant data per mode. (#129) 2020-11-06 21:37:36 +01:00
ultratoto14
657850e39c Add support of RGB lights (#120)
* Make set_dps available.

* Adding RGB support, brightness fix, color_temp range.

* Update README for light options

* Formatting

* Formatting

* Need to force to white to ensure color picker is updated.

* Detect color mode RGB/HSV based on color length.

* Extract rgb encoded color check in method.

* Make check method private.

* Fix exception when color is not available (maybe when powered off)

* Reformat.
2020-10-28 09:54:54 +01:00
Pierre Ståhl
d783293a21 Add support for HSV encoded color lights (#90)
* Add support for HSV encoded color light

* Add debug logs for entity config

* Unset color when going to white mode
2020-10-26 12:09:31 +01:00
Kendell R
c1878f82e2 Improve GitHub Actions (#97)
* Delete hassfest.yaml

* Update and rename ci.yaml to tox.yaml

* Create combined.yaml

* Update hacs.json

* Update README.md

* Update combined.yaml

* Remove unused import

* Restored wrongly deleted line in cover.py

* Update config_flow.py

* Update __init__.py

Co-authored-by: Pierre Ståhl <pierre.staahl@gmail.com>
Co-authored-by: rospogrigio <49229287+rospogrigio@users.noreply.github.com>
2020-10-22 11:43:47 +02:00
Pierre Ståhl
98fee92c83 Return None if no color temp option 2020-10-16 12:40:06 +02:00
Pierre Ståhl
baad2cfab0 Fix review comments 2020-10-16 12:40:06 +02:00
Pierre Ståhl
15a79ec690 Re-map light brightness range
Home Assistant uses brightness range 0-255 whilst Tuya somewhere around
29-1092. This commit maps brightness between these two ranges.
2020-10-16 12:40:06 +02:00
Pierre Ståhl
44db913514 Rename set_dps to set_dp in pytuya 2020-10-15 18:54:36 +02:00
Pierre Ståhl
cad31f1ffe Convert pytuya to asyncio 2020-10-14 13:10:20 +02:00
Pierre Ståhl
1da5c2c2e1 Fix linting issues 2020-10-06 10:49:23 +02:00
danVnest
51a92da6b3 Include support for color temp instead of unfinished color 2020-10-06 10:49:23 +02:00
Pierre Ståhl
792fcc5186 Add color temp and brightness config to light 2020-10-06 10:49:23 +02:00
Pierre Ståhl
8456c6039c Add platform specific DPS to requests 2020-10-05 09:44:13 +02:00
Pierre Ståhl
8cc978a04d Refactor async_setup_entry 2020-10-05 09:44:13 +02:00
Pierre Ståhl
caaf884a7a Get status once per device instead of per platform 2020-09-27 14:19:35 +02:00
Pierre Ståhl
d22d081335 Clean up YAML examples in code files 2020-09-26 22:38:26 +02:00
rospogrigio
3259a4f654 Second part of one_device_only big merge 2020-09-26 22:38:26 +02:00
Pierre Ståhl
0048ce6d5e Move YAML config to component 2020-09-26 22:38:26 +02:00
Pierre Ståhl
fefee6944f Add shared code to a common module 2020-09-24 09:20:31 +02:00
Pierre Ståhl
4e72767b30 Fix flake8 issues and enable flake8 in tox 2020-09-23 17:50:24 +02:00
Pierre Ståhl
a18c69f8eb Fix pydocstyle issues and enable in tox 2020-09-23 16:47:08 +02:00
rospogrigio
83b3b6f21b Moved TuyaCache to __init__.py, and renamed to TuyaDevice. In pytuya, renamed TuyaDevice to TuyaInterface 2020-09-22 00:51:33 +02:00
Pierre Ståhl
dd48fc00f5 Make light entity inherit from LocalTuyaEntity 2020-09-21 23:56:54 +02:00
rospogrigio
6700e02c52 set_dpsUsed turned into add_dps_to_request ; used it when setting up entities 2020-09-19 15:59:59 +02:00
rospogrigio
c99cc1f077 Removed unneeded friendly_name fields 2020-09-15 23:31:33 +02:00
rospogrigio
386d59b497 config_entry forwarded only to proper platform; DOMAIN imported from component 2020-09-15 10:59:06 +02:00
rospogrigio
ce2461df2b Merge branch 'master' into pytuya_refactoring 2020-09-14 23:32:55 +02:00
rospogrigio
6c77ce1c38 Fixed merging conflicts 2020-09-13 14:17:52 +02:00
rospogrigio
853c1deb76 Fixed merging conflicts 2020-09-13 14:14:22 +02:00
rospogrigio
47b92b0178 Fixes suggested in PR #11 2020-09-13 14:03:08 +02:00
rospogrigio
184199ef87 Pytuya library refactoring and code cleaning 2020-09-11 11:46:01 +02:00
rospogrigio
8e9fb82304 Introduced type_0a and type_0d devices autodetection 2020-09-10 10:59:58 +02:00
Pierre Ståhl
ae64158da5 Use correct device class from pytuya 2020-09-10 10:42:44 +02:00
Pierre Ståhl
7efb3024fb Support arbitrary flow schemas for platforms 2020-09-09 23:05:42 +02:00
Pierre Ståhl
7018625f04 Add light support and clean up schemas 2020-09-09 22:59:37 +02:00
rospogrigio
3d0505ac41 Removed unnecessary dps from covers; reduced cache timeout for covers and lights 2020-09-07 12:07:20 +02:00
rospogrigio
16d8d4dcf9 Introduced pytuya 7.0.9: Unified dev_type (device20 or device22) handling for all devices 2020-09-03 21:51:27 +02:00
rospogrigio
fdefd70043 Merge branch 'djtimca-feature-light' 2020-09-03 17:10:48 +02:00
Pierre Ståhl
a0bf22cce5 Prepand unique_id with local_
Avoid collisions with the tuya integration.
2020-09-03 12:04:52 +02:00
Tim Empringham
1d80202cab Updated template for configuration.yaml and removed redundant chanage to pytuya. 2020-09-02 15:26:46 -04:00
Tim Empringham
843f556fa5 Updated to support lights with dimmable and colour_temp settings 2020-09-02 15:21:58 -04:00
Pierre Ståhl
4335507804 Add support for unique_id and available 2020-09-02 12:46:09 +02:00
rospogrigio
30c466015c Introduced cover support 2020-03-23 10:53:41 +01:00