From f3ca3bdc06b3fd07a74324301ebc5bb31e04220a Mon Sep 17 00:00:00 2001 From: Maikel Punie Date: Fri, 17 May 2024 16:57:18 +0200 Subject: [PATCH] add small timeout after loading, we should not send any messages to the control box in this timeframe --- duotecno/controller.py | 1 + 1 file changed, 1 insertion(+) diff --git a/duotecno/controller.py b/duotecno/controller.py index 183770e..874ba68 100644 --- a/duotecno/controller.py +++ b/duotecno/controller.py @@ -134,6 +134,7 @@ async def _do_connect(self, testOnly: bool = False, skipLoad: bool = False) -> N for unit in node.get_units(): self._log.debug(f"Unit: {unit}") await unit.requestStatus() + await asyncio.sleep(5) self.hbTask = asyncio.Task(self.heartbeatTask()) await self.enableAllUnits()