Fix brightness type (#25818)
This commit is contained in:
1 parent
5b516fc0cd
commit
6909235d8a
2 files changed
+7
-3
No files matched your search
@@ -133,7 +133,9 @@ class SmartThingsLight(SmartThingsEntity, Light):
|
||||
"""Update entity attributes when the device status has changed."""
|
||||
# Brightness and transition
|
||||
if self._supported_features & SUPPORT_BRIGHTNESS:
|
||||
self._brightness = convert_scale(self._device.status.level, 100, 255)
|
||||
self._brightness = int(
|
||||
convert_scale(self._device.status.level, 100, 255, 0)
|
||||
)
|
||||
# Color Temperature
|
||||
if self._supported_features & SUPPORT_COLOR_TEMP:
|
||||
self._color_temp = color_util.color_temperature_kelvin_to_mired(
|
||||
|
||||
Reference in new issue
Block a user