From 39416a4d5b7c22f543ac2a61848b6a0f611d2849 Mon Sep 17 00:00:00 2001 From: zivillian Date: Mon, 31 Jul 2023 12:21:24 +0200 Subject: [PATCH] use core id 1 to further reduce modbus errors (#3) --- src/switch.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/switch.cpp b/src/switch.cpp index 4d4996f..53d4f90 100644 --- a/src/switch.cpp +++ b/src/switch.cpp @@ -27,7 +27,7 @@ void PhaseSwitch::beginModbus(){ RTUutils::prepareHardwareSerial(modbusSerial); modbusSerial.begin(19200, SERIAL_8E1); _client.setTimeout(500); - _client.begin(modbusSerial); + _client.begin(modbusSerial, 1); _bridge.attachServer(_serverId, _serverId, ANY_FUNCTION_CODE, &_client); _bridgeWorker = _bridge.getWorker(_serverId, ANY_FUNCTION_CODE); _bridge.start(502, 10, 30000);