denonavr 1.2.0__py3-none-any.whl → 1.3.1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- denonavr/__init__.py +1 -1
- denonavr/api.py +7 -5
- denonavr/appcommand.py +48 -12
- denonavr/audyssey.py +26 -23
- denonavr/const.py +426 -141
- denonavr/decorators.py +2 -3
- denonavr/denonavr.py +140 -101
- denonavr/dirac.py +5 -5
- denonavr/foundation.py +382 -294
- denonavr/input.py +57 -24
- denonavr/soundmode.py +46 -32
- denonavr/volume.py +33 -36
- {denonavr-1.2.0.dist-info → denonavr-1.3.1.dist-info}/METADATA +1 -1
- denonavr-1.3.1.dist-info/RECORD +20 -0
- {denonavr-1.2.0.dist-info → denonavr-1.3.1.dist-info}/WHEEL +1 -1
- denonavr-1.2.0.dist-info/RECORD +0 -20
- {denonavr-1.2.0.dist-info → denonavr-1.3.1.dist-info}/licenses/LICENSE +0 -0
- {denonavr-1.2.0.dist-info → denonavr-1.3.1.dist-info}/top_level.txt +0 -0
denonavr/dirac.py
CHANGED
|
@@ -15,7 +15,7 @@ import attr
|
|
|
15
15
|
from .const import (
|
|
16
16
|
DENON_ATTR_SETATTR,
|
|
17
17
|
DIRAC_FILTER_MAP,
|
|
18
|
-
|
|
18
|
+
DIRAC_FILTER_MAP_REVERSE,
|
|
19
19
|
DiracFilters,
|
|
20
20
|
)
|
|
21
21
|
from .exceptions import AvrCommandError
|
|
@@ -29,7 +29,7 @@ class DenonAVRDirac(DenonAVRFoundation):
|
|
|
29
29
|
"""Dirac Settings."""
|
|
30
30
|
|
|
31
31
|
_dirac_filter: Optional[str] = attr.ib(
|
|
32
|
-
converter=attr.converters.optional(
|
|
32
|
+
converter=attr.converters.optional(DIRAC_FILTER_MAP.get), default=None
|
|
33
33
|
)
|
|
34
34
|
_dirac_filters = get_args(DiracFilters)
|
|
35
35
|
|
|
@@ -40,8 +40,8 @@ class DenonAVRDirac(DenonAVRFoundation):
|
|
|
40
40
|
|
|
41
41
|
def _dirac_filter_callback(self, zone: str, event: str, parameter: str) -> None:
|
|
42
42
|
"""Handle Dirac filter change event."""
|
|
43
|
-
if
|
|
44
|
-
self._dirac_filter =
|
|
43
|
+
if zone == self._device.zone and parameter[0:5] == "DIRAC":
|
|
44
|
+
self._dirac_filter = parameter[6:]
|
|
45
45
|
|
|
46
46
|
##############
|
|
47
47
|
# Properties #
|
|
@@ -66,7 +66,7 @@ class DenonAVRDirac(DenonAVRFoundation):
|
|
|
66
66
|
if dirac_filter not in self._dirac_filters:
|
|
67
67
|
raise AvrCommandError("Invalid Dirac filter")
|
|
68
68
|
|
|
69
|
-
mapped_filter =
|
|
69
|
+
mapped_filter = DIRAC_FILTER_MAP_REVERSE[dirac_filter]
|
|
70
70
|
if self._device.telnet_available:
|
|
71
71
|
await self._device.telnet_api.async_send_commands(
|
|
72
72
|
self._device.telnet_commands.command_dirac_filter.format(
|