1
0
mirror of https://github.com/no2chem/wideq.git synced 2025-05-28 04:50:23 -07:00

Fix for Dual fan ac

ACOp.ALL_ON is right.

if none dual fan ac
than ALL_ON AND RIGHT_ON work is fine.

but dual fan ac
RIGHT_ON works only right fan.
This commit is contained in:
Wonchul Kang 2019-11-08 18:01:48 +09:00 committed by GitHub
parent b31edaf46d
commit 6ed250a16e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -106,9 +106,9 @@ class ACOp(enum.Enum):
"""Whether a device is on or off."""
OFF = "@AC_MAIN_OPERATION_OFF_W"
RIGHT_ON = "@AC_MAIN_OPERATION_RIGHT_ON_W" # This one seems to mean "on"?
LEFT_ON = "@AC_MAIN_OPERATION_LEFT_ON_W"
ALL_ON = "@AC_MAIN_OPERATION_ALL_ON_W"
RIGHT_ON = "@AC_MAIN_OPERATION_RIGHT_ON_W" #only on right fan
LEFT_ON = "@AC_MAIN_OPERATION_LEFT_ON_W" #only on left fan
ALL_ON = "@AC_MAIN_OPERATION_ALL_ON_W" #all on
class ACDevice(Device):
@ -224,7 +224,7 @@ class ACDevice(Device):
"""Turn on or off the device (according to a boolean).
"""
op = ACOp.RIGHT_ON if is_on else ACOp.OFF
op = ACOp.ALL_ON if is_on else ACOp.OFF
op_value = self.model.enum_value('Operation', op.value)
self._set_control('Operation', op_value)