Disable speeds for first gen Xiaomi_miio air purifiers (#52772)
* Disable speeds for first gen air purifiers * Remove test code line * remove OPERATION_MODES_AIRPURIFIER listpull/53335/head
parent
804499968e
commit
9753500f5e
|
@ -336,7 +336,6 @@ AVAILABLE_ATTRIBUTES_AIRFRESH = {
|
|||
ATTR_EXTRA_FEATURES: "extra_features",
|
||||
}
|
||||
|
||||
OPERATION_MODES_AIRPURIFIER = ["Auto", "Silent", "Favorite", "Idle"]
|
||||
PRESET_MODES_AIRPURIFIER = ["Auto", "Silent", "Favorite", "Idle"]
|
||||
OPERATION_MODES_AIRPURIFIER_PRO = ["Auto", "Silent", "Favorite"]
|
||||
PRESET_MODES_AIRPURIFIER_PRO = ["Auto", "Silent", "Favorite"]
|
||||
|
@ -903,10 +902,10 @@ class XiaomiAirPurifier(XiaomiGenericDevice):
|
|||
self._device_features = FEATURE_FLAGS_AIRPURIFIER
|
||||
self._available_attributes = AVAILABLE_ATTRIBUTES_AIRPURIFIER
|
||||
self._preset_modes = PRESET_MODES_AIRPURIFIER
|
||||
self._supported_features = SUPPORT_SET_SPEED | SUPPORT_PRESET_MODE
|
||||
self._speed_count = 4
|
||||
self._supported_features = SUPPORT_PRESET_MODE
|
||||
self._speed_count = 1
|
||||
# the speed_list attribute is deprecated, support will end with release 2021.7
|
||||
self._speed_list = OPERATION_MODES_AIRPURIFIER
|
||||
self._speed_list = []
|
||||
|
||||
self._state_attrs.update(
|
||||
{attribute: None for attribute in self._available_attributes}
|
||||
|
|
Loading…
Reference in New Issue