mirror of
https://github.com/python-kasa/python-kasa.git
synced 2025-10-13 10:58:02 +00:00
Improve dimmer support (#62)
* discover dimmers properly * fix circular import, hopefully * add is_color to SmartDevice API * allow changing the dimming without implicitly turning the device on * Add tests for device type handling for discovery data, make sure new fixtures are added to categories inside conftest
This commit is contained in:
@@ -667,6 +667,11 @@ class SmartDevice:
|
||||
"""Return True if the device supports color temperature."""
|
||||
return False
|
||||
|
||||
@property
|
||||
def is_color(self) -> bool:
|
||||
"""Return True if the device supports color changes."""
|
||||
return False
|
||||
|
||||
def __repr__(self):
|
||||
return "<{} model {} at {} ({}), is_on: {} - dev specific: {}>".format(
|
||||
self.__class__.__name__,
|
||||
|
Reference in New Issue
Block a user