diff --git a/.devcontainer/devcontainer.json b/.devcontainer/devcontainer.json index 8edc1d4d..70fff019 100644 --- a/.devcontainer/devcontainer.json +++ b/.devcontainer/devcontainer.json @@ -10,30 +10,34 @@ "-e", "GIT_EDITOR=code --wait" ], - "extensions": [ - "ms-python.vscode-pylance", - "visualstudioexptteam.vscodeintellicode" - ], - "settings": { - "python.pythonPath": "/usr/local/bin/python", - "python.defaultInterpreterPath": "/user/local/bin/python", - "python.linting.pylintEnabled": true, - "python.linting.enabled": true, - "python.formatting.provider": "black", - "python.testing.pytestArgs": [ - "--no-cov" - ], - "python.testing.unittestEnabled": false, - "python.testing.pytestEnabled": true, - "editor.formatOnPaste": false, - "editor.formatOnSave": true, - "editor.formatOnType": true, - "files.trimTrailingWhitespace": true, - "terminal.integrated.profiles.linux": { - "zsh": { - "path": "/usr/bin/zsh" - } + "customizations": { + "vscode": { + "extensions": [ + "ms-python.vscode-pylance", + "visualstudioexptteam.vscodeintellicode" + ] }, - "terminal.integrated.defaultProfile.linux": "zsh", + "settings": { + "python.pythonPath": "/usr/local/bin/python", + "python.defaultInterpreterPath": "/user/local/bin/python", + "python.linting.pylintEnabled": true, + "python.linting.enabled": true, + "python.formatting.provider": "black", + "python.testing.pytestArgs": [ + "--no-cov" + ], + "python.testing.unittestEnabled": false, + "python.testing.pytestEnabled": true, + "editor.formatOnPaste": false, + "editor.formatOnSave": true, + "editor.formatOnType": true, + "files.trimTrailingWhitespace": true, + "terminal.integrated.profiles.linux": { + "zsh": { + "path": "/usr/bin/zsh" + } + }, + "terminal.integrated.defaultProfile.linux": "zsh" + } } } diff --git a/pyproject.toml b/pyproject.toml index 1e54b360..4abbdac6 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -9,7 +9,7 @@ dynamic = ["version"] readme = "README.md" authors = [{ name = "Hugo Dupras", email = "jabesq@gmail.com" }] maintainers = [{ name = "Tobias Sauerwein", email = "cgtobi@gmail.com" }] -requires-python = ">=3.11,<3.13" +requires-python = ">=3.11,<3.14" dependencies = [ "aiohttp>=3.7.4,<4.0.0", "oauthlib~=3.1", diff --git a/src/pyatmo/modules/__init__.py b/src/pyatmo/modules/__init__.py index dc1c127d..02574267 100644 --- a/src/pyatmo/modules/__init__.py +++ b/src/pyatmo/modules/__init__.py @@ -58,6 +58,7 @@ ) from .module import Camera, Dimmer, Fan, Module, Shutter, Switch from .netatmo import ( + NAC, NCO, NDB, NHC, @@ -157,6 +158,7 @@ "NLV", "NOC", "NRV", + "NAC", "NSD", "OTH", "OTM", diff --git a/src/pyatmo/modules/device_types.py b/src/pyatmo/modules/device_types.py index f7615e98..c0014154 100644 --- a/src/pyatmo/modules/device_types.py +++ b/src/pyatmo/modules/device_types.py @@ -21,6 +21,7 @@ class DeviceType(str, Enum): NAPlug = "NAPlug" # Smart thermostat gateway NATherm1 = "NATherm1" # Smart thermostat NRV = "NRV" # Smart valve + NAC = "NAC" # Smart AC control OTH = "OTH" # OpenTherm gateway OTM = "OTM" # OpenTherm modulating thermostat @@ -150,6 +151,7 @@ class DeviceCategory(str, Enum): DEVICE_CATEGORY_MAP: dict[DeviceType, DeviceCategory] = { DeviceType.NRV: DeviceCategory.climate, + DeviceType.NAC: DeviceCategory.climate, DeviceType.NATherm1: DeviceCategory.climate, DeviceType.OTM: DeviceCategory.climate, DeviceType.NOC: DeviceCategory.camera, @@ -212,6 +214,7 @@ class DeviceCategory(str, Enum): DeviceType.NAPlug: ("Netatmo", "Smart Thermostat Gateway"), DeviceType.NATherm1: ("Netatmo", "Smart Thermostat"), DeviceType.NRV: ("Netatmo", "Smart Valve"), + DeviceType.NAC: ("Netatmo", "Smart AC Control"), DeviceType.OTH: ("Netatmo", "OpenTherm Gateway"), DeviceType.OTM: ("Netatmo", "OpenTherm Modulating Thermostat"), # Netatmo Cameras/Security diff --git a/src/pyatmo/modules/netatmo.py b/src/pyatmo/modules/netatmo.py index ac44120d..fe0813cb 100644 --- a/src/pyatmo/modules/netatmo.py +++ b/src/pyatmo/modules/netatmo.py @@ -50,6 +50,10 @@ class NRV(FirmwareMixin, RfMixin, BatteryMixin, Module): """Class to represent a Netatmo NRV.""" +class NAC(FirmwareMixin, RfMixin, BatteryMixin, Module): + """Class to represent a Netatmo NAC.""" + + class NATherm1(FirmwareMixin, RfMixin, BatteryMixin, BoilerMixin, Module): """Class to represent a Netatmo NATherm1.""" diff --git a/src/pyatmo/room.py b/src/pyatmo/room.py index 899d7424..7aaf271c 100644 --- a/src/pyatmo/room.py +++ b/src/pyatmo/room.py @@ -107,6 +107,8 @@ def evaluate_device_type(self) -> None: self.features.add("humidity") elif "NRV" in self.device_types: self.climate_type = DeviceType.NRV + elif "NAC" in self.device_types: + self.climate_type = DeviceType.NAC elif "BNTH" in self.device_types: self.climate_type = DeviceType.BNTH diff --git a/src/pyatmo/schedule.py b/src/pyatmo/schedule.py index 0d6d55ec..dd7ca271 100644 --- a/src/pyatmo/schedule.py +++ b/src/pyatmo/schedule.py @@ -25,6 +25,7 @@ class ScheduleType(StrEnum): COOLING = "cooling" ELECTRICITY = "electricity" EVENT = "event" + AUTO = "auto" @dataclass