settings: fix bug when reading BACKLIGHT setting from device
This commit is contained in:
parent
7ef3059b69
commit
ad0f9ec712
|
@ -270,9 +270,9 @@ class Backlight2(_Setting):
|
||||||
def read(self, device):
|
def read(self, device):
|
||||||
backlight = device.backlight
|
backlight = device.backlight
|
||||||
if not backlight.enabled:
|
if not backlight.enabled:
|
||||||
return 0xFF
|
return b"\xFF"
|
||||||
else:
|
else:
|
||||||
return backlight.mode
|
return _int2bytes(backlight.mode, 1)
|
||||||
|
|
||||||
def write(self, device, data_bytes):
|
def write(self, device, data_bytes):
|
||||||
backlight = device.backlight
|
backlight = device.backlight
|
||||||
|
|
Loading…
Reference in New Issue