From 2170497b8403f2d159917aa49f5338e388c83aac Mon Sep 17 00:00:00 2001 From: wills106 Date: Tue, 24 Dec 2024 09:47:32 +0000 Subject: [PATCH] 2025.01.1b1 --- custom_components/solax_modbus/__init__.py | 6 +++--- custom_components/solax_modbus/manifest.json | 4 ++-- hacs.json | 2 +- 3 files changed, 6 insertions(+), 6 deletions(-) diff --git a/custom_components/solax_modbus/__init__.py b/custom_components/solax_modbus/__init__.py index 8ce442b3..364778d6 100644 --- a/custom_components/solax_modbus/__init__.py +++ b/custom_components/solax_modbus/__init__.py @@ -61,7 +61,7 @@ class CoreModbusHub: from pymodbus.constants import Endian from pymodbus.exceptions import ConnectionException, ModbusIOException from pymodbus.payload import BinaryPayloadBuilder, BinaryPayloadDecoder, Endian -from pymodbus.transaction import ModbusAsciiFramer, ModbusRtuFramer +from pymodbus.framer import FramerType from .const import ( INVERTER_IDENT, @@ -259,10 +259,10 @@ def __init__( ) elif interface == "tcp": if tcp_type == "rtu": - self._client = AsyncModbusTcpClient(host=host, port=port, timeout=5, framer=ModbusRtuFramer, retries=6) + self._client = AsyncModbusTcpClient(host=host, port=port, timeout=5, framer=FramerType.Rtu, retries=6) elif tcp_type == "ascii": self._client = AsyncModbusTcpClient( - host=host, port=port, timeout=5, framer=ModbusAsciiFramer, retries=6 + host=host, port=port, timeout=5, framer=FramerType.Ascii, retries=6 ) else: self._client = AsyncModbusTcpClient(host=host, port=port, timeout=5, retries=6) diff --git a/custom_components/solax_modbus/manifest.json b/custom_components/solax_modbus/manifest.json index 4a40f41c..298fd855 100644 --- a/custom_components/solax_modbus/manifest.json +++ b/custom_components/solax_modbus/manifest.json @@ -9,6 +9,6 @@ "integration_type": "hub", "iot_class": "local_polling", "issue_tracker": "https://github.com/wills106/homsassistant-solax-modbus/issues", - "requirements": ["pymodbus==3.6.9"], - "version": "2024.12.1" + "requirements": ["pymodbus==3.7.4"], + "version": "2024.12.2" } diff --git a/hacs.json b/hacs.json index 933e5df1..d59c243a 100644 --- a/hacs.json +++ b/hacs.json @@ -1,5 +1,5 @@ { "name": "SolaX Inverter Modbus", "render_readme": true, - "homeassistant": "2024.9.0" + "homeassistant": "2025.1.0b1" }