Send pro-active IAS Enroll Response (#42282)

* Send pro-active IAS Enroll Response 

Some zigbee devices require a pro-active IAS enroll response to be sent before they will send their IAS enroll request.  This PR sends a single IAS enroll response after CIE write and fixes some of these devices including the Ecolink 4655BC0-R and many others. 

This also more closely aligns with the default behavior of Smartthings and zigbee2mqtt which also send pro-active enroll requests:

b217b91bb7 (diff-6d00af5fc389c40b8c4dfc390d80e3eca3946d331dff84afdc1632cb5568bca2)

Thanks to @puddly for helping figure this all out and @tubalainen for testing.

* flake8 fixes

* flake8 again
This commit is contained in:
walthowd 2020-10-24 20:41:27 -05:00 committed by GitHub
parent 12a9504203
commit 09bd449698
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -155,6 +155,15 @@ class IASZoneChannel(ZigbeeChannel):
self._cluster.ep_attribute,
str(ex),
)
try:
self.debug("Sending pro-active IAS enroll response")
await self._cluster.enroll_response(0, 0)
except ZigbeeException as ex:
self.debug(
"Failed to send pro-active IAS enroll response: %s",
str(ex),
)
self.debug("finished IASZoneChannel configuration")
@callback