LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Develop OPC application

Hello,

Want to develop OPC application with LW, anyone knowing the steps must be taken to reach the way ? please give an advise , thanks.

David
0 Kudos
Message 1 of 6
(3,971 Views)

Are you mentioning you write an OPC (OLE Process Control) client program with LabWindows/CVI? First it is better to read OPC specifications that can be downloaded at http://www.opcfoundation.org/

Accessing an OPC server from CVI is very similar as accessing an IVI-COM driver, because you need access COM interfaces.  However, C language is not so strong for it as the language does not have native support for v-table.  I guess VC++/MFC is the best for OPC client.

0 Kudos
Message 2 of 6
(3,965 Views)

See the following thread
http://forums.ni.com/ni/board/message?board.id=180&message.id=19138

which discusses how to access IVI-COM driver from CVI.  The generic approcah for accessing an COM server is the same for OPC cases.

0 Kudos
Message 3 of 6
(3,959 Views)
Ho David,
If you are a lucky guy and just need an OPC Client, you can use DataSocket Binding directly on the UIR controls.
See:
http://www.ni.com/opc/opcservers.htm
Regards
0 Kudos
Message 4 of 6
(3,949 Views)
Hi Makoto,

Thank you for your reply ! I've seen the web site you linked , but there are so many contents I do not know which document shoud be the first read. In my project , it needs to develop OPC client and server application , please advise how to enter into the development field . By the way , is there any suggestion to develop OPC application in Linux ? Thanks

David
0 Kudos
Message 5 of 6
(3,917 Views)

The must document is OPC Common 1.00 specification.  Although I don't know what kind of jobs your OPC server provides, the most typically used server type is DA.  Therefore you should read at least OPC DA specifications (3.0 or 2.05a).  If your client appliactions may use Windows scripting languages such as Visual Basic, you shoud also read OPC DA Auto 2.02 specification.

The OPC interfaces are all COM based, therefore a Linux implementation for OPC server will have to be a DCOM server.  Although I am not familiar with Linux DCOM, some useful information regarding Linux-based OPC and DCOM will be found at the following site, or try to google-search with Linux OPC DCOM keywords. 

http://www.opcconnect.com/

Sorry but I am not an OPC expert and have no experience other than DA clients/servers using Windows COM/DCOM environment.

Makoto

0 Kudos
Message 6 of 6
(3,913 Views)