From b43270b82ef2fe53d0b90522dfeefc9076efb546 Mon Sep 17 00:00:00 2001 From: wangsr Date: Mon, 18 Dec 2023 11:31:57 +0800 Subject: [PATCH] =?UTF-8?q?=E8=BE=93=E9=80=81=E5=88=86=E6=94=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- DataBlockHelper/PlcConnect.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/DataBlockHelper/PlcConnect.cs b/DataBlockHelper/PlcConnect.cs index 8681fd3..bb8d6e7 100644 --- a/DataBlockHelper/PlcConnect.cs +++ b/DataBlockHelper/PlcConnect.cs @@ -21,8 +21,13 @@ namespace DataBlockHelper SiemensPLCS siemensPLCS = SiemensPLCS.S1500; SiemensS7Net s7 = new SiemensS7Net(siemensPLCS); s7.SetPersistentConnection(); - //s7.IpAddress = "192.168.1.110"; + + //输送IP + //s7.IpAddress = "192.168.1.110"; + + //配料IP s7.IpAddress = "127.18.4.100"; + s7.Port = 102; var su = s7.ConnectServer();