|
|
@@ -16,6 +16,15 @@ namespace BPASmartClient.PLC |
|
|
|
public override void Init() |
|
|
|
{ |
|
|
|
modbusTcp.IsReconnect = true; |
|
|
|
modbusTcp.Show += new Action<string>((s) => |
|
|
|
{ |
|
|
|
if (s != null) MessageLog.GetInstance.Show(s); |
|
|
|
}); |
|
|
|
|
|
|
|
modbusTcp.ShowEx += new Action<string>((s) => |
|
|
|
{ |
|
|
|
if (s != null) MessageLog.GetInstance.ShowEx(s); |
|
|
|
}); |
|
|
|
Task.Run(new Action(() => |
|
|
|
{ |
|
|
|
modbusTcp.ConnectOk = new Action(() => |
|
|
|