diff --git a/tests/test_network_state.py b/tests/test_network_state.py index 9fa381e..ee03c9b 100644 --- a/tests/test_network_state.py +++ b/tests/test_network_state.py @@ -234,7 +234,7 @@ async def write_parameter(param, *args): command=None, ) }, - {"network_key.tx_counter": 0}, + {"network_key.tx_counter": 1073741824}, {}, ), ( diff --git a/zigpy_deconz/zigbee/application.py b/zigpy_deconz/zigbee/application.py index ae9766e..c5a8a79 100644 --- a/zigpy_deconz/zigbee/application.py +++ b/zigpy_deconz/zigbee/application.py @@ -365,6 +365,11 @@ async def load_network_info(self, *, load_devices=False): ) except zigpy_deconz.exception.CommandError as ex: assert ex.status == Status.UNSUPPORTED + LOGGER.debug( + "Conbee firmware is too old and does not support reading the frame" + " counter, picking a large value instead" + ) + network_info.network_key.tx_counter = 2**30 network_info.tc_link_key = zigpy.state.Key() network_info.tc_link_key.partner_ieee = await self._api.read_parameter(