Send/receive messages using OPC

C

Thread Starter

Cid Jorge

Originally OPC is used for continuous data, like temperature, pressure. But I need to send preset data and receive result data from a PC to a PLC using OPC. How can I do this?

Thanks in advance.
 
Depends on the technology you want to use.
Personally, I use Visual C++ and MFC for all my applications, including OPC.
The OPC interface IOPCSyncIO (and IOPCAsynIO but I never use it) allows a simple C++ program (and VB also, I guess but I don't like this language ...) to read and write PLC data using the Read and Write functions...

You'll find several samples on Web to help you start easily.

Thierry
 
J
I don't understand the problem. Any OPC-DA client allows the operator to enter a value (such as setpoint or batch size) which then get sent to the PLC when the operator hits enter. This is sent one-shot. Typically OPC-DA clients read from the PLC continuously.

If you must wait, and only transmit result when ready, then OPC-A&E is the way to do it.

To understand how to apply OPC-DA and OPC-A&E take a look at the book "Software for Automation: Architecture, Integration, and Security". Preview, see contents, and buy online: http://www.isa.org/autosoftware

Jonas Berge
SMAR
===========
[email protected]
www.smar.com
Learn fieldbus and Ethernet at your own pace: www.isa.org/fieldbuses
Learn OPC and automation software at your own pace: www.isa.org/autosoftware
 
VB programs in PC will wait for a list of bits in a OPC group, regarding events in process. Just after receive each event, VB program will send a bunch of data to PLC, like close control presets values, primary data or receipts. These data will send one shot and not all the time like OPC-DA does.

Also after some events, like finish processing of material, PLc will send results data to VB program. These data will be joined with others data and be stored in a SQL Server database for future analysis.

Thanks for help.
 
Top