0

I am developing a client / server applicatiod based on opc using OPC Net API. My server is an OPC Client that provides process data to clients via WCF service infrastructure. Depending on what tags are connected by my clients I want to react on my server and only subscribe to those opc items.

Now my question: Is it possible to activate or deactivate opc items in an active subscription without recreating the subscription all the time?

Another question: Does anybody here have experience with that API and how many opc items can be in an subscription so that it still works with good performance?

Chetter Hummin
  • 6,687
  • 8
  • 32
  • 44

1 Answers1

2

Yes every item has an Active state, which you should be able to change via the API. Look for the SetActiveState() method in the IOPCItemMgt interface.

You can typically use hundreds or even thousands of items in a subscription without a problem, but the performance may vary depending on the server capabilities.

The bottleneck is often AddItems, which takes long on some servers. You can try to add all items at one AddItems call or you may need to break the call to several smaller once, if it takes too long for the server to process.

Jouni Aro
  • 2,099
  • 14
  • 30