From cf9bf6faa227155b66cf30d94ac9895b73d0354d Mon Sep 17 00:00:00 2001 From: andig Date: Thu, 12 May 2022 17:28:33 +0200 Subject: [PATCH] Add shadow RTU field for rtu: false --- util/modbus/modbus.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/util/modbus/modbus.go b/util/modbus/modbus.go index c7130a5fd..cddee3f3a 100644 --- a/util/modbus/modbus.go +++ b/util/modbus/modbus.go @@ -28,9 +28,12 @@ const ( ) // Settings contains the ModBus TCP settings +// RTU field is included for compatibility with modbus.tpl which renders rtu: false for TCP +// TODO remove RTU field (https://github.com/evcc-io/evcc/issues/3360) type TcpSettings struct { URI string ID uint8 + RTU *bool `mapstructure:"rtu"` } // Settings contains the ModBus settings