08-02-2010 10:34 AM
Hi, im using a read datasocket to communicate with an OPC tunneller (Matrikon). But the datasocket does not recieve any data, when changing the opc url to a local host url. Ive used 3rd party clients other than the datasocket and they work fine. What could it be??
08-03-2010
03:41 AM
- last edited on
10-27-2025
04:31 PM
by
Content Cleaner
Hi there
My first step would be to make sure you are connecting to the OPC server correctly. Please follow the below link to how you can accomplish this:
I have also linked the; DataSocket Tutorial. This is a great reference to have when using the DataSocket connection.
Make sure you enter a valid OPC URL into DataSocket Read or DataSocket Write VIs (see attached example: dsopc.vi). As the first step in accessing an OPC server, DataSocket will establish a connection by launching the relevant OPC server. If you are running Windows 2000/XP, you will see the relevant OPC server running as a process. When the VI is stopped, the process is shut down.
The appropriate URL format to subscribe to an OPC Server is opc://ServerName/OPCServer/ItemName
.
Many experienced OPC programmers also want to include certain configuration settings in their subscriptions. Therefore, National Instruments has made it possible to configure your subscription including the OPC Server Deadband and the OPC Server Update Rate. There is a simple way to include this in your URL: opc:\\ServerName\OPCServer\ItemName?updaterate=100&deadband=0.7.
This is similar to the previous URL except for the addition of the update rate and the deadband configuration. Again, similar commands are available in other programming languages.
Can I ask do you have the DSC module? Can you supply me with some more information if the above steps do not resolve your issue. Many thanks!
08-04-2010 02:56 AM
Hi, already tried what you suggested. I do have the dsc module as well. It seems the datasocket can retrieve the data from the client tunneller(localhost).
Stuart
08-13-2010 02:51 AM
Found out it was the tunneller that did work with datasocket. So i used a different tunneller and it worked fine.