diff --git a/CHANGELOG.md b/CHANGELOG.md index 425d189..ed901bc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -9,7 +9,6 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - build version string in the same format as TSUN for GEN3 invterts - add graceful shutdown -- add timeout monitoring for received packets - parse Modbus values and store them in the database - add cron task to request the output power every minute - GEN3PLUS: add MQTT topics to send AT commands to the inverter diff --git a/app/src/async_stream.py b/app/src/async_stream.py index 56f475d..196a01f 100644 --- a/app/src/async_stream.py +++ b/app/src/async_stream.py @@ -1,6 +1,5 @@ import logging import traceback -import asyncio from messages import hex_dump_memory logger = logging.getLogger('conn') @@ -59,10 +58,7 @@ class AsyncStream(): while True: try: - if self.state == self.STATE_UP and self.server_side: - await asyncio.wait_for(self.__async_read(), 150) - else: - await self.__async_read() + await self.__async_read() if self.unique_id: await self.async_write() @@ -84,12 +80,6 @@ class AsyncStream(): self.close() return self - except asyncio.TimeoutError: - logger.warning(f"Timeout for {self.l_addr}") - await self.disc() - self.close() - return self - except Exception: self.inc_counter('SW_Exception') logger.error(