From 95d7c9c7527a8fd45c8db54cb3f1652ad20b5b38 Mon Sep 17 00:00:00 2001 From: James Budarz Date: Mon, 2 Sep 2024 20:11:35 -0400 Subject: [PATCH] Fix spelling of Midea in all instances --- custom_components/midea_ac_lan/config_flow.py | 6 +++--- custom_components/midea_ac_lan/midea/core/device.py | 2 +- custom_components/midea_ac_lan/midea/devices/a1/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/ac/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/b0/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/b1/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/b3/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/b4/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/b6/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/bf/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/c2/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/c3/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/ca/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/cc/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/cd/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/ce/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/cf/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/da/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/db/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/dc/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/e1/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/e2/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/e3/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/e6/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/e8/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/ea/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/ec/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/ed/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/fa/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/fb/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/fc/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/fd/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/x13/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/x26/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/x34/device.py | 4 ++-- custom_components/midea_ac_lan/midea/devices/x40/device.py | 4 ++-- hacs.json | 2 +- 37 files changed, 73 insertions(+), 73 deletions(-) diff --git a/custom_components/midea_ac_lan/config_flow.py b/custom_components/midea_ac_lan/config_flow.py index 98c8b53b..5ff4850a 100644 --- a/custom_components/midea_ac_lan/config_flow.py +++ b/custom_components/midea_ac_lan/config_flow.py @@ -37,7 +37,7 @@ from homeassistant.helpers.aiohttp_client import async_create_clientsession from .midea.core.discover import discover from .midea.core.cloud import get_midea_cloud -from .midea.core.device import MiedaDevice +from .midea.core.device import MideaDevice from .midea_devices import MIDEA_DEVICES _LOGGER = logging.getLogger(__name__) @@ -264,7 +264,7 @@ async def async_step_auto(self, user_input=None, error=None): return await self.async_step_auto(error="preset_account") keys = await self.cloud.get_keys(user_input[CONF_DEVICE]) for method, key in keys.items(): - dm = MiedaDevice( + dm = MideaDevice( name="", device_id=device_id, device_type=device.get(CONF_TYPE), @@ -314,7 +314,7 @@ async def async_step_manually(self, user_input=None, error=None): return await self.async_step_manually(error="invalid_token") if user_input[CONF_PROTOCOL] == 3 and (len(user_input[CONF_TOKEN]) == 0 or len(user_input[CONF_KEY]) == 0): return await self.async_step_manually(error="invalid_token") - dm = MiedaDevice( + dm = MideaDevice( name="", device_id=user_input[CONF_DEVICE_ID], device_type=user_input[CONF_TYPE], diff --git a/custom_components/midea_ac_lan/midea/core/device.py b/custom_components/midea_ac_lan/midea/core/device.py index dc364673..55813dbc 100644 --- a/custom_components/midea_ac_lan/midea/core/device.py +++ b/custom_components/midea_ac_lan/midea/core/device.py @@ -41,7 +41,7 @@ class ParseMessageResult(IntEnum): ERROR = 99 -class MiedaDevice(threading.Thread): +class MideaDevice(threading.Thread): def __init__(self, name: str, device_id: int, diff --git a/custom_components/midea_ac_lan/midea/devices/a1/device.py b/custom_components/midea_ac_lan/midea/devices/a1/device.py index 91b83938..8f231d9e 100644 --- a/custom_components/midea_ac_lan/midea/devices/a1/device.py +++ b/custom_components/midea_ac_lan/midea/devices/a1/device.py @@ -8,7 +8,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -29,7 +29,7 @@ class DeviceAttributes(StrEnum): current_temperature = "current_temperature" -class MideaA1Device(MiedaDevice): +class MideaA1Device(MideaDevice): _modes = [ "Manual", "Continuous", "Auto", "Clothes-Dry", "Shoes-Dry" ] diff --git a/custom_components/midea_ac_lan/midea/devices/ac/device.py b/custom_components/midea_ac_lan/midea/devices/ac/device.py index 1effb0a5..b22e9af9 100644 --- a/custom_components/midea_ac_lan/midea/devices/ac/device.py +++ b/custom_components/midea_ac_lan/midea/devices/ac/device.py @@ -15,7 +15,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -56,7 +56,7 @@ class DeviceAttributes(StrEnum): realtime_power = "realtime_power" -class MideaACDevice(MiedaDevice): +class MideaACDevice(MideaDevice): _fresh_air_fan_speeds = { 0: "Off", 20: "Silent", 40: "Low", 60: "Medium", 80: "High", 100: "Full" } diff --git a/custom_components/midea_ac_lan/midea/devices/b0/device.py b/custom_components/midea_ac_lan/midea/devices/b0/device.py index 4bfee5a6..db493380 100644 --- a/custom_components/midea_ac_lan/midea/devices/b0/device.py +++ b/custom_components/midea_ac_lan/midea/devices/b0/device.py @@ -7,7 +7,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -22,7 +22,7 @@ class DeviceAttributes(StrEnum): water_shortage = "water_shortage" -class MideaB0Device(MiedaDevice): +class MideaB0Device(MideaDevice): _status = { 0x01: "Standby", 0x02: "Idle", 0x03: "Working", 0x04: "Finished", 0x05: "Delay", 0x06: "Paused" diff --git a/custom_components/midea_ac_lan/midea/devices/b1/device.py b/custom_components/midea_ac_lan/midea/devices/b1/device.py index cd030cd3..aa36451c 100644 --- a/custom_components/midea_ac_lan/midea/devices/b1/device.py +++ b/custom_components/midea_ac_lan/midea/devices/b1/device.py @@ -7,7 +7,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -22,7 +22,7 @@ class DeviceAttributes(StrEnum): water_shortage = "water_shortage" -class MideaB1Device(MiedaDevice): +class MideaB1Device(MideaDevice): _status = { 0x01: "Standby", 0x02: "Idle", 0x03: "Working", 0x04: "Finished", 0x05: "Delay", 0x06: "Paused" diff --git a/custom_components/midea_ac_lan/midea/devices/b3/device.py b/custom_components/midea_ac_lan/midea/devices/b3/device.py index 3d26da09..a6a229e7 100644 --- a/custom_components/midea_ac_lan/midea/devices/b3/device.py +++ b/custom_components/midea_ac_lan/midea/devices/b3/device.py @@ -7,7 +7,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -37,7 +37,7 @@ class DeviceAttributes(StrEnum): lock = "lock" -class MideaB2Device(MiedaDevice): +class MideaB2Device(MideaDevice): _status = { 0x00: "Off", 0x01: "Standby", 0x02: "Working", 0x03: "Delay", 0x04: "Finished" diff --git a/custom_components/midea_ac_lan/midea/devices/b4/device.py b/custom_components/midea_ac_lan/midea/devices/b4/device.py index 41b19763..e1a9d2c0 100644 --- a/custom_components/midea_ac_lan/midea/devices/b4/device.py +++ b/custom_components/midea_ac_lan/midea/devices/b4/device.py @@ -7,7 +7,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -22,7 +22,7 @@ class DeviceAttributes(StrEnum): water_shortage = "water_shortage" -class MideaB4Device(MiedaDevice): +class MideaB4Device(MideaDevice): _status = { 0x01: "Standby", 0x02: "Idle", 0x03: "Working", 0x04: "Finished", 0x05: "Delay", 0x06: "Paused" diff --git a/custom_components/midea_ac_lan/midea/devices/b6/device.py b/custom_components/midea_ac_lan/midea/devices/b6/device.py index 53a98762..42363890 100644 --- a/custom_components/midea_ac_lan/midea/devices/b6/device.py +++ b/custom_components/midea_ac_lan/midea/devices/b6/device.py @@ -9,7 +9,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -24,7 +24,7 @@ class DeviceAttributes(StrEnum): cleaning_reminder = "cleaning_reminder" -class MideaB6Device(MiedaDevice): +class MideaB6Device(MideaDevice): def __init__( self, name: str, diff --git a/custom_components/midea_ac_lan/midea/devices/bf/device.py b/custom_components/midea_ac_lan/midea/devices/bf/device.py index 2f0b5685..96c920f6 100644 --- a/custom_components/midea_ac_lan/midea/devices/bf/device.py +++ b/custom_components/midea_ac_lan/midea/devices/bf/device.py @@ -7,7 +7,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -22,7 +22,7 @@ class DeviceAttributes(StrEnum): water_shortage = "water_shortage" -class MideaBFDevice(MiedaDevice): +class MideaBFDevice(MideaDevice): _status = { 0x01: "PowerSave", 0x02: "Standby", 0x03: "Working", 0x04: "Finished", 0x05: "Delay", 0x06: "Paused" diff --git a/custom_components/midea_ac_lan/midea/devices/c2/device.py b/custom_components/midea_ac_lan/midea/devices/c2/device.py index e41bcb79..d5737636 100644 --- a/custom_components/midea_ac_lan/midea/devices/c2/device.py +++ b/custom_components/midea_ac_lan/midea/devices/c2/device.py @@ -10,7 +10,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -31,7 +31,7 @@ class DeviceAttributes(StrEnum): filter_life = "filter_life" -class MideaC2Device(MiedaDevice): +class MideaC2Device(MideaDevice): def __init__( self, name: str, diff --git a/custom_components/midea_ac_lan/midea/devices/c3/device.py b/custom_components/midea_ac_lan/midea/devices/c3/device.py index a625866d..8fc51553 100644 --- a/custom_components/midea_ac_lan/midea/devices/c3/device.py +++ b/custom_components/midea_ac_lan/midea/devices/c3/device.py @@ -10,7 +10,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -58,7 +58,7 @@ class DeviceAttributes(StrEnum): error_code = "error_code" -class MideaC3Device(MiedaDevice): +class MideaC3Device(MideaDevice): def __init__( self, name: str, diff --git a/custom_components/midea_ac_lan/midea/devices/ca/device.py b/custom_components/midea_ac_lan/midea/devices/ca/device.py index 844584e0..5a0b8d38 100644 --- a/custom_components/midea_ac_lan/midea/devices/ca/device.py +++ b/custom_components/midea_ac_lan/midea/devices/ca/device.py @@ -7,7 +7,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -33,7 +33,7 @@ class DeviceAttributes(StrEnum): flex_zone_door = "flex_zone_door" -class MideaCADevice(MiedaDevice): +class MideaCADevice(MideaDevice): def __init__( self, name: str, diff --git a/custom_components/midea_ac_lan/midea/devices/cc/device.py b/custom_components/midea_ac_lan/midea/devices/cc/device.py index 289baaf6..e7a3547b 100644 --- a/custom_components/midea_ac_lan/midea/devices/cc/device.py +++ b/custom_components/midea_ac_lan/midea/devices/cc/device.py @@ -8,7 +8,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -32,7 +32,7 @@ class DeviceAttributes(StrEnum): temp_fahrenheit = "temp_fahrenheit" -class MideaCCDevice(MiedaDevice): +class MideaCCDevice(MideaDevice): _fan_speeds_7level = { 0x01: "Level 1", 0x02: "Level 2", 0x04: "Level 3", 0x08: "Level 4", 0x10: "Level 5", 0x20: "Level 6", diff --git a/custom_components/midea_ac_lan/midea/devices/cd/device.py b/custom_components/midea_ac_lan/midea/devices/cd/device.py index 917a00b0..29241e23 100644 --- a/custom_components/midea_ac_lan/midea/devices/cd/device.py +++ b/custom_components/midea_ac_lan/midea/devices/cd/device.py @@ -9,7 +9,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -27,7 +27,7 @@ class DeviceAttributes(StrEnum): compressor_status = "compressor_status" -class MideaCDDevice(MiedaDevice): +class MideaCDDevice(MideaDevice): _modes = ["Energy-save", "Standard", "Dual", "Smart"] def __init__( diff --git a/custom_components/midea_ac_lan/midea/devices/ce/device.py b/custom_components/midea_ac_lan/midea/devices/ce/device.py index a4e394b5..ddcdf6f2 100644 --- a/custom_components/midea_ac_lan/midea/devices/ce/device.py +++ b/custom_components/midea_ac_lan/midea/devices/ce/device.py @@ -9,7 +9,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -35,7 +35,7 @@ class DeviceAttributes(StrEnum): error_code = "error_code" -class MideaCEDevice(MiedaDevice): +class MideaCEDevice(MideaDevice): _modes = [ "Normal", "Sleep mode", "ECO mode" ] diff --git a/custom_components/midea_ac_lan/midea/devices/cf/device.py b/custom_components/midea_ac_lan/midea/devices/cf/device.py index bbfad209..824d9017 100644 --- a/custom_components/midea_ac_lan/midea/devices/cf/device.py +++ b/custom_components/midea_ac_lan/midea/devices/cf/device.py @@ -8,7 +8,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -23,7 +23,7 @@ class DeviceAttributes(StrEnum): min_temperature = "min_temperature" -class MideaCFDevice(MiedaDevice): +class MideaCFDevice(MideaDevice): def __init__( self, name: str, diff --git a/custom_components/midea_ac_lan/midea/devices/da/device.py b/custom_components/midea_ac_lan/midea/devices/da/device.py index 9323bdbd..3115a11a 100644 --- a/custom_components/midea_ac_lan/midea/devices/da/device.py +++ b/custom_components/midea_ac_lan/midea/devices/da/device.py @@ -9,7 +9,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -34,7 +34,7 @@ class DeviceAttributes(StrEnum): detergent = "detergent" -class MideaDADevice(MiedaDevice): +class MideaDADevice(MideaDevice): def __init__( self, name: str, diff --git a/custom_components/midea_ac_lan/midea/devices/db/device.py b/custom_components/midea_ac_lan/midea/devices/db/device.py index 40957a04..24b499c8 100644 --- a/custom_components/midea_ac_lan/midea/devices/db/device.py +++ b/custom_components/midea_ac_lan/midea/devices/db/device.py @@ -9,7 +9,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -22,7 +22,7 @@ class DeviceAttributes(StrEnum): time_remaining = "time_remaining" -class MideaDBDevice(MiedaDevice): +class MideaDBDevice(MideaDevice): def __init__( self, name: str, diff --git a/custom_components/midea_ac_lan/midea/devices/dc/device.py b/custom_components/midea_ac_lan/midea/devices/dc/device.py index b99362a5..f1f90e4e 100644 --- a/custom_components/midea_ac_lan/midea/devices/dc/device.py +++ b/custom_components/midea_ac_lan/midea/devices/dc/device.py @@ -9,7 +9,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -22,7 +22,7 @@ class DeviceAttributes(StrEnum): time_remaining = "time_remaining" -class MideaDADevice(MiedaDevice): +class MideaDADevice(MideaDevice): def __init__( self, name: str, diff --git a/custom_components/midea_ac_lan/midea/devices/e1/device.py b/custom_components/midea_ac_lan/midea/devices/e1/device.py index 0064bfe4..b870a0b0 100644 --- a/custom_components/midea_ac_lan/midea/devices/e1/device.py +++ b/custom_components/midea_ac_lan/midea/devices/e1/device.py @@ -10,7 +10,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -42,7 +42,7 @@ class DeviceAttributes(StrEnum): bright = "bright" -class MideaE1Device(MiedaDevice): +class MideaE1Device(MideaDevice): def __init__( self, name: str, diff --git a/custom_components/midea_ac_lan/midea/devices/e2/device.py b/custom_components/midea_ac_lan/midea/devices/e2/device.py index 386a5467..ce2e4239 100644 --- a/custom_components/midea_ac_lan/midea/devices/e2/device.py +++ b/custom_components/midea_ac_lan/midea/devices/e2/device.py @@ -11,7 +11,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -30,7 +30,7 @@ class DeviceAttributes(StrEnum): heating_power = "heating_power" -class MideaE2Device(MiedaDevice): +class MideaE2Device(MideaDevice): def __init__( self, name: str, diff --git a/custom_components/midea_ac_lan/midea/devices/e3/device.py b/custom_components/midea_ac_lan/midea/devices/e3/device.py index 7340a625..1187d5b1 100644 --- a/custom_components/midea_ac_lan/midea/devices/e3/device.py +++ b/custom_components/midea_ac_lan/midea/devices/e3/device.py @@ -11,7 +11,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -27,7 +27,7 @@ class DeviceAttributes(StrEnum): target_temperature = "target_temperature" -class MideaE3Device(MiedaDevice): +class MideaE3Device(MideaDevice): def __init__( self, name: str, diff --git a/custom_components/midea_ac_lan/midea/devices/e6/device.py b/custom_components/midea_ac_lan/midea/devices/e6/device.py index 75109667..922cda94 100644 --- a/custom_components/midea_ac_lan/midea/devices/e6/device.py +++ b/custom_components/midea_ac_lan/midea/devices/e6/device.py @@ -8,7 +8,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -26,7 +26,7 @@ class DeviceAttributes(StrEnum): bathing_leaving_temperature = "bathing_leaving_temperature" -class MideaE6Device(MiedaDevice): +class MideaE6Device(MideaDevice): def __init__( self, name: str, diff --git a/custom_components/midea_ac_lan/midea/devices/e8/device.py b/custom_components/midea_ac_lan/midea/devices/e8/device.py index c479e374..c20f74d4 100644 --- a/custom_components/midea_ac_lan/midea/devices/e8/device.py +++ b/custom_components/midea_ac_lan/midea/devices/e8/device.py @@ -7,7 +7,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -23,7 +23,7 @@ class DeviceAttributes(StrEnum): water_shortage = "water_shortage" -class MideaE8Device(MiedaDevice): +class MideaE8Device(MideaDevice): _status = { 0x00: "Standby", 0x01: "Delay", 0x02: "Working", 0x03: "Paused", 0x04: "Keep-Warming", 0xFF: "Error" diff --git a/custom_components/midea_ac_lan/midea/devices/ea/device.py b/custom_components/midea_ac_lan/midea/devices/ea/device.py index 66c2a8e3..ec22deef 100644 --- a/custom_components/midea_ac_lan/midea/devices/ea/device.py +++ b/custom_components/midea_ac_lan/midea/devices/ea/device.py @@ -7,7 +7,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -23,7 +23,7 @@ class DeviceAttributes(StrEnum): progress = "progress" -class MideaEADevice(MiedaDevice): +class MideaEADevice(MideaDevice): _mode_list = [ "smart", "reserve", "cook_rice", "fast_cook_rice", "standard_cook_rice", "gruel", "cook_congee", "stew_soup", "stewing", "heat_rice", "make_cake", diff --git a/custom_components/midea_ac_lan/midea/devices/ec/device.py b/custom_components/midea_ac_lan/midea/devices/ec/device.py index 1b4429ed..e44da7a2 100644 --- a/custom_components/midea_ac_lan/midea/devices/ec/device.py +++ b/custom_components/midea_ac_lan/midea/devices/ec/device.py @@ -7,7 +7,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -23,7 +23,7 @@ class DeviceAttributes(StrEnum): with_pressure = "with_pressure" -class MideaECDevice(MiedaDevice): +class MideaECDevice(MideaDevice): _mode_list = [ "smart", "reserve", "cook_rice", "fast_cook_rice", "standard_cook_rice", "gruel", "cook_congee", "stew_soup", "stewing", "heat_rice", "make_cake", diff --git a/custom_components/midea_ac_lan/midea/devices/ed/device.py b/custom_components/midea_ac_lan/midea/devices/ed/device.py index cd0ca7d7..8a0b09a7 100644 --- a/custom_components/midea_ac_lan/midea/devices/ed/device.py +++ b/custom_components/midea_ac_lan/midea/devices/ed/device.py @@ -9,7 +9,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -28,7 +28,7 @@ class DeviceAttributes(StrEnum): child_lock = "child_lock" -class MideaEDDevice(MiedaDevice): +class MideaEDDevice(MideaDevice): def __init__( self, diff --git a/custom_components/midea_ac_lan/midea/devices/fa/device.py b/custom_components/midea_ac_lan/midea/devices/fa/device.py index 5462d689..ac45726c 100644 --- a/custom_components/midea_ac_lan/midea/devices/fa/device.py +++ b/custom_components/midea_ac_lan/midea/devices/fa/device.py @@ -9,7 +9,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -25,7 +25,7 @@ class DeviceAttributes(StrEnum): oscillation_mode = "oscillation_mode" -class MideaFADevice(MiedaDevice): +class MideaFADevice(MideaDevice): _oscillation_angles = [ "Off", "30", "60", "90", "120", "180", "360" ] diff --git a/custom_components/midea_ac_lan/midea/devices/fb/device.py b/custom_components/midea_ac_lan/midea/devices/fb/device.py index 4ac3cf1e..e7a5147e 100644 --- a/custom_components/midea_ac_lan/midea/devices/fb/device.py +++ b/custom_components/midea_ac_lan/midea/devices/fb/device.py @@ -8,7 +8,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -22,7 +22,7 @@ class DeviceAttributes(StrEnum): child_lock = "child_lock" -class MideaFBDevice(MiedaDevice): +class MideaFBDevice(MideaDevice): _modes = {0x01: "Auto", 0x02: "ECO", 0x03: "Sleep", 0x04: "Anti-freezing", 0x05: "Comfort", 0x06: "Constant-temperature", 0x07: "Normal", 0x08: "Fast-heating", 0x10: "Standby"} diff --git a/custom_components/midea_ac_lan/midea/devices/fc/device.py b/custom_components/midea_ac_lan/midea/devices/fc/device.py index 8cdf3b09..16495c19 100644 --- a/custom_components/midea_ac_lan/midea/devices/fc/device.py +++ b/custom_components/midea_ac_lan/midea/devices/fc/device.py @@ -9,7 +9,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -31,7 +31,7 @@ class DeviceAttributes(StrEnum): standby = "standby" -class MideaFCDevice(MiedaDevice): +class MideaFCDevice(MideaDevice): _modes = { 0x00: "Standby", 0x10: "Auto", 0x20: "Manual", 0x30: "Sleep", 0x40: "Fast", 0x50: "Smoke" } diff --git a/custom_components/midea_ac_lan/midea/devices/fd/device.py b/custom_components/midea_ac_lan/midea/devices/fd/device.py index 9db35daa..4ad8a56c 100644 --- a/custom_components/midea_ac_lan/midea/devices/fd/device.py +++ b/custom_components/midea_ac_lan/midea/devices/fd/device.py @@ -8,7 +8,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -26,7 +26,7 @@ class DeviceAttributes(StrEnum): disinfect = "disinfect" -class MideaFDDevice(MiedaDevice): +class MideaFDDevice(MideaDevice): _modes = [ "Manual", "Auto", "Continuous", "Living-Room", "Bed-Room", "Kitchen", "Sleep" ] diff --git a/custom_components/midea_ac_lan/midea/devices/x13/device.py b/custom_components/midea_ac_lan/midea/devices/x13/device.py index 2a4e1e11..ea8f9f70 100644 --- a/custom_components/midea_ac_lan/midea/devices/x13/device.py +++ b/custom_components/midea_ac_lan/midea/devices/x13/device.py @@ -9,7 +9,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -22,7 +22,7 @@ class DeviceAttributes(StrEnum): power = "power" -class Midea13Device(MiedaDevice): +class Midea13Device(MideaDevice): _effects = ["Manual", "Living", "Reading", "Mildly", "Cinema", "Night"] def __init__( diff --git a/custom_components/midea_ac_lan/midea/devices/x26/device.py b/custom_components/midea_ac_lan/midea/devices/x26/device.py index 5a4408f3..94bc8986 100644 --- a/custom_components/midea_ac_lan/midea/devices/x26/device.py +++ b/custom_components/midea_ac_lan/midea/devices/x26/device.py @@ -9,7 +9,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -24,7 +24,7 @@ class DeviceAttributes(StrEnum): current_temperature = "current_temperature" -class Midea26Device(MiedaDevice): +class Midea26Device(MideaDevice): _modes = ["Off", "Heat(high)", "Heat(low)", "Bath", "Blow", "Ventilation", "Dry"] _directions = ["60", "70", "80", "90", "100", "110", "120", "Oscillate"] diff --git a/custom_components/midea_ac_lan/midea/devices/x34/device.py b/custom_components/midea_ac_lan/midea/devices/x34/device.py index 6097128e..b0276f52 100644 --- a/custom_components/midea_ac_lan/midea/devices/x34/device.py +++ b/custom_components/midea_ac_lan/midea/devices/x34/device.py @@ -10,7 +10,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -42,7 +42,7 @@ class DeviceAttributes(StrEnum): bright = "bright" -class Midea34Device(MiedaDevice): +class Midea34Device(MideaDevice): def __init__( self, name: str, diff --git a/custom_components/midea_ac_lan/midea/devices/x40/device.py b/custom_components/midea_ac_lan/midea/devices/x40/device.py index b49a0bc2..315fa24c 100644 --- a/custom_components/midea_ac_lan/midea/devices/x40/device.py +++ b/custom_components/midea_ac_lan/midea/devices/x40/device.py @@ -9,7 +9,7 @@ from enum import StrEnum except ImportError: from ...backports.enum import StrEnum -from ...core.device import MiedaDevice +from ...core.device import MideaDevice _LOGGER = logging.getLogger(__name__) @@ -23,7 +23,7 @@ class DeviceAttributes(StrEnum): current_temperature = "current_temperature" -class Midea40Device(MiedaDevice): +class Midea40Device(MideaDevice): _directions = ["60", "70", "80", "90", "100", "Oscillate"] def __init__( diff --git a/hacs.json b/hacs.json index fa984084..1add49b9 100644 --- a/hacs.json +++ b/hacs.json @@ -3,5 +3,5 @@ "render_readme": true, "homeassistant": "2022.5", "zip_release": true, - "filename": "mieda_ac_lan.zip" + "filename": "midea_ac_lan.zip" }