Skip to content

Commit da28ca5

Browse files
committed
Bump zcc-helper with cover open/close tolerance in the helper.
1 parent 5476ee9 commit da28ca5

File tree

3 files changed

+6
-15
lines changed

3 files changed

+6
-15
lines changed

custom_components/zimi/cover.py

Lines changed: 4 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -54,10 +54,6 @@ def __init__(self, device: ControlPointDevice, api: ControlPoint) -> None:
5454

5555
super().__init__(device, api)
5656

57-
_LOGGER.debug(
58-
"Initialising ZimiCover %s in %s", self._entity.name, self._entity.room
59-
)
60-
6157
async def async_close_cover(self, **kwargs: Any) -> None:
6258
"""Close the cover/door."""
6359
_LOGGER.debug("Sending close_cover() for %s", self.name)
@@ -73,10 +69,9 @@ def current_cover_position(self) -> int | None:
7369
@property
7470
def is_closed(self) -> bool | None:
7571
"""Return true if cover is closed."""
76-
result = self._entity.is_closed or self._entity.percentage < 10
7772
_LOGGER.debug("is_closed() = %d (%d) for %s",
78-
result, self._entity.percentage, self.name)
79-
return result
73+
self._entity.is_closed, self._entity.percentage, self.name)
74+
return self._entity.is_closed
8075

8176
@property
8277
def is_closing(self) -> bool | None:
@@ -95,10 +90,9 @@ def is_opening(self) -> bool | None:
9590
@property
9691
def is_open(self) -> bool | None:
9792
"""Return true if cover is open."""
98-
result = self._entity.is_open or self._entity.percentage > 90
9993
_LOGGER.debug("is_open() = %d (%d) for %s",
100-
result, self._entity.percentage, self.name)
101-
return result
94+
self._entity.is_open, self._entity.percentage, self.name)
95+
return self._entity.is_open
10296

10397
async def async_open_cover(self, **kwargs: Any) -> None:
10498
"""Open the cover/door."""

custom_components/zimi/entity.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,4 @@ def notify(self, _observable: object):
6060
No data is fetched for the notification but schedule_update_ha_state is called.
6161
"""
6262

63-
_LOGGER.debug(
64-
"Received notification() for %s in %s", self._entity.name, self._entity.room
65-
)
6663
self.schedule_update_ha_state(force_refresh=True)

custom_components/zimi/manifest.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@
44
"codeowners": [
55
"@markhannon"
66
],
7-
"version": "2.0.2-dev4",
7+
"version": "2.0.2-dev5",
88
"config_flow": true,
99
"documentation": "https://www.home-assistant.io/integrations/zimi",
1010
"iot_class": "local_push",
1111
"quality_scale": "bronze",
1212
"requirements": [
13-
"zcc-helper==3.4.1"
13+
"zcc-helper==3.4.2-dev1"
1414
]
1515
}

0 commit comments

Comments
 (0)