1
我需要與工廠機械接口,並且在我們的每個工廠都使用RSLinx與該機械進行通信。據this blog post它相對容易地從RSLinx中讀取數據:RsiOPCAuto.dll ...哪裏可以找到?
Dim OpcServer As New RsiOPCAuto.OPCServer
Dim OpcGroup As RsiOPCAuto.OPCGroup
Dim OpcItem As RsiOPCAuto.OPCItem
Dim vItem As String = ""
Try
OpcServer.Connect("RSLinx Remote OPC Server", "192.168.195.128")
' Add this group to the shared topic
OpcGroup = OpcServer.OPCGroups.Add("INDEC")
OpcGroup.IsSubscribed = False
OpcGroup.IsActive = False
OpcGroup.UpdateRate = 250
OpcGroup.OPCItems.DefaultAccessPath = "OPC_Test"
OpcGroup.OPCItems.AddItem("OPC_Bit001", 1)
OpcItem = OpcGroup.OPCItems.Item(1)
OpcItem.Read(2, vItem)
OpcItem = Nothing
OpcServer.OPCGroups.RemoveAll()
OpcGroup = Nothing
OpcServer.Disconnect()
OpcServer = Nothing
'Add and Error the list box
Catch ex As PlatformNotSupportedException
MsgBox("Error In Get Plc Data: " & ex.Message)
End Try
MsgBox(vItem)
但是......它說,我需要添加到RsiOPCAuto.dll的引用,但我不知道:
- 在哪裏可以找到它
- 什麼都可以做
- 任何有關授權它
具體來說,日ough,我很好奇,如果有人知道我能找到那個DLL。
您是否找到該問題的答案? –