01-16-2016 05:20 PM
Hi,
I have some trouble with OPC UA client. I have one variable at the server which is incremented every 100 ms, and I made subscription to it.
I set update rate input in create subscription vi to 3000 ms. In this case, with every notification I should receive more or less 30 data change events. I set also queue size of monitored items to 500 (much more than I need, just to be sure)
In vi I write all notifications to tdms file, but unfortunately, when I look into the file after my test, I see only one data change event every 3 s. It seems that client reads only last data change and doesn’t retrieve the rest of them. I'm using LabVIEW 2015 with DSC Module and I run the vi in development environment
Where I made mistake?
Cheers,
Thomas
01-17-2016 08:39 PM
Hi Thomas,
Have you tried to specify the "queue size" other than the default value "1" in the termnal "notification queue settings" of NI OPC UA Client.lvlib:Add Monitored Nodes.vi? The default queue size is "1" so you only get 1 value returned for each notification.
Thanks,
Yan
01-18-2016 01:11 AM
Hi Thomas,
I'm not using LabVIEW anymore since a few years but I saw your message, and perhaps I can give a clue from a purely OPC UA point-of-view.
OPC UA has two interval settings to configure, to do what you want:
Perhaps you forgot the second setting, as you didn't mention this? I think if the sampling interval is 0, the server must sample at maximum speed, though I'd need to look that up. But beware, there may be a minimum sampling interval set by the server, so the server may "revise" your requested sampling interval. When the client creates the monitored item, the server responds by sending the "revised sampling time" to the client.
Besides that, also (as you say) set the queue size to a value > 30, and you may also want to set the "discard oldest" setting to True in case the buffer would overflow (which cannot happen in theory of course, since your buffer > publishing interval / sampling interval).
HTH
03-08-2016 10:07 AM
HI Carlos,
We are currently looking at implementing an OPC UA server in our windows based LabVIEW application software and are weighing up the options.
The current OPC UA functionality in the DSC Module looks quite basic in comparison to that defined in the OPC UA specifications.
Would you be able to tell me if the ability to define methods and events (Address Space) will be included anytime soon (say within the next year?) and if the Historical Data Access (HDA) and Alarms & Conditions (A&C) updates you mentioned might also be available in a similar time frame?
I don't want to ask you to commit to any particular time but if you could provide any kind of ball park figure that would be much appreciated. We'd much prefer to use the native LabVIEW API if things are going to progress soon(ish)!!
Thanks,
Lee
03-08-2016 11:51 AM
Hi Lee!
The goal is to have the capabilities you mention added to our API in our 2017 release cycle. I will keep you informed if there is any change to this plan.
Regards,
Carlos Pazos
04-07-2016 01:51 AM
Hello,
I am new here, also new with using OPC UA with Labview. I hope I can get some tips and help on some issues. I am sorry if its nt the suitable place to post here But I need to start somewhere:D..
As I said I am new to OPC UA Labview. I am reading about its capabilities but I am not sure if can do what I am thinking of. I have two questions.
1) Is there any time difference between calculations done in the OPC UA server and the information to be displayed at the OPC UA client? Can we use the timestamp to display the timing for each reading? and is there any data loss if there is a time difference?
2) If we had all data for Folders/Items/Properties arranged in an excel sheet or any kind of file, is it possible to read from that file through OPC UA and generate internally in some kind of array or any other way the whole structure of all folders and items? instead of placing the folder/item/properties Palletes manually for each folder and item in the list?
Regards,
Elias
04-26-2016 02:37 AM
Hello Carlos,
Thank you for your reply.
So far i was able to exctract data as cluster of array of strings. I know there is an OPC UA vi that tranform node name array to node path but I am not able to reach a compatible data type input for it. I am stuck there. And I want to know if that VI can be used in a loop to enter the data and save the node paths generated. For example, I want my program to read information of 20 folders from the excel sheet and creat a data structure for them as listed in the excel. And do you have any tip for entering the node attributes also dynamically from the excel sheet or at least how to integrate it in parallel while creating the folders/items/properties. This is a screenshot for my code, I didnt find the option to upload the VI file.
Any help would be highly appreciated.
Thank you
ELias
06-17-2016 04:20 AM
Is there something wrong with the OPC UA support installed with the DSC Run-Time? We have built an application with OPC UA server that runs fine on computers with the development environment, but when you make an installer (including the DSC Run-Time) the application will complain about missing dlls. This seems to be caused by the fact that none of the files supposed to be in C:\Program Files (x86)\National Instruments\Shared\OPCUA are installed...(even though the DSC Run-Time is included in the installer). If that folder is copied to the machine, then the application is able to run.
Now as it turns out the folder *is* installed if we use the DSC Run-Time CD that we get when we buy a run-time license...(but until we opened up the firewall we could not get that one to install properly, even though all other NI software is able to license OK).
I would expect that the DSC Run-Time as it is when included as part of an application installer would still install all necessary files if run as part of an application installer, but that the OPC functionality itself would not allow connections until a run-time *license* was installed. Perhaps it would show a warning about this at startup (not practical though if the app is actually run as a service for exampåle), but not actually break the execution - without any sensible explanation.
What is the intended behaviour? Is there a known bug/limitation in the DSC installer we can bundle with the application installers, or?
06-19-2016 08:02 PM
This is the desired behavior. The "DSC Run-Time" in the applicaiton/installer build, and the "DSC Run-Time System" CD are different things. The one in applicaiton/installer build is a minimal set of DSC funtionality support that doesn't require a license to run on a deployment environment, and the CD installs the full support of DSC funtionality to a deployment environment which requires a valid license. We know it's a little bit confusing, and we are looking into how to improve that.
07-04-2016 10:28 AM
Yayuan,
I'm having trouble with an application that creates an OPCUA server in a dll, when it is run the runtime environment.
I have a main application which calls a labview dll that uses various DSC VIs and is responsible for creating the OPCUA Server and configuring nodes to be either read or read/write access. The dll creates both an OPCUA Server and an OPC Client (the latter is used to register for Server Data Change events so I can tell when other Clients are modifying the read/write nodes).
When the main application is run from the development environment the dll works fine and the OPC Client Data Change Events fire. However, when I build the main application into an executable, although the server is created and I can see all the nodes from third party OPCUA clients, any writes that third-party clients make do not result in my local OPCUA Client firing the Data Change Events?
In a similar way, the dll application also creates an OPC Classic server by dynamically creating shared variables. I register for Data Change events for these shared variables and when the main application is run in the development environment these events fire. However, when I run the main application as an executable, these events do not fire either?
I've read that the DSC runtime is required for shared variable data change events to work correctly - is this the same for the OPCUA Client Data Change events?
Note that these tests have been performed on my development machine which has the DSC module installed (LabVIEW 2014).