From b714fa3b6fd80532b51c27bc5eb9d8b663508b29 Mon Sep 17 00:00:00 2001 From: mazocode Date: Wed, 11 Sep 2024 04:14:28 +0200 Subject: [PATCH] feat: Support register write via rpc topic --- modbus2mqtt.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/modbus2mqtt.py b/modbus2mqtt.py index 279ed10..535895f 100755 --- a/modbus2mqtt.py +++ b/modbus2mqtt.py @@ -323,7 +323,6 @@ def set_value(self, src, params): # Can't set unknown state return False - wordcount = 1 bo = Endian.BIG if self.littleendian: bo = Endian.LITTLE @@ -333,7 +332,6 @@ def set_value(self, src, params): if self.format == "float": builder.add_32bit_float(float(value)) payload = builder.to_registers() - wordcount = 2 else: payload = int(value)