OPC Marshal Example
Jump to navigation
Jump to search
Navigation: User Guide ➔ Dynamic Example Projects ➔ OPC Marshal
This project requires you to have the SysCAD Marshal (OPC) license add-on to work correctly.
PLEASE NOTE: By opening this project, SysCAD should automatically open up two extra applications:
- If SysCAD Marshal is not opened, there maybe an issue with registry. Please follow instructions: Setting up COM to add the required files to the registry.
- If OPC is NOT opened, please install the OPC Components and then try again. (Installation file location: C:\SysCAD93\Setup\OPC Setup\OPC Core Components 3.00\Setup.exe)
Project Location
This Dynamic Transfer project is stored at:
- ..\SysCADXXX\ExamplesDynamic\OPC Marshal Example.spf
Features Demonstrated
- OPC connectivity between SysCAD, OPC Server and OPC client
- Using SysCAD Marshal as OPC Client
Brief Project Description
- The SysCAD project is very simple, it consists of a single PGM file with a few tags, representing analogue in/out, digital in/out tags. The aim of the project is demonstrating how SysCAD can communicate with another application via OPC.
Project Configuration
Setting up SysCAD Marshal
SysCAD Marshal requires two files: (File location: inside the project folder)
- Marshal.scm file
- Marshal_Tags.db3 (this is a SQLite database; alternate file formats are csv text files or MS Excel files)
- Marshal.scm file
- : File Name
- : Define where the IO slot tags are. This file contains a list of all the IO tags (slots) by specifying a "Marshal OPC Client Tag", its data type, its mapping to a tag on an OPC Server and optionally a connection mapping to a flowsheet SysCAD tag. For more information, see IO Tag List.
- : Define the OPC server. In the example above, this is defined under the [Demo] section. The section name could be any name but importantly this exact name is used later in the scdDriver field as the first parameter, for example OPC(Demo, "TheOPCTagInServer")
- Setting up the IO list:
- The IO List (Marshal OPC Client Tag List) can be edited by editing the Marshal_Tags.db3 directly.
- This is where user defines the tag matching between the two applications (SysCAD and OPC Server).
- : File Name
- : Unique Marshal Tag names. These are the Marshal OPC Client Tags.
- : Maps SysCAD tags to the Marshal Tags (and/or Marshal Tags to other Marshal Tags). Use Set for send information to SysCAD, use Get to retrieve information from SysCAD.
- : Maps OPC Server tags to the Marshal Tag. Demo is the OPC server defined in the Marshal.scm file . The OPC server tags are defined in the 3rd party OPC Server application.
- Below is an example of the SysCAD Marshal:
Setting up the SysCAD project:
- For demonstration purposes, this project is set up with PGM tag for connectivity. However, if the project contains real unit operations such as tanks and pumps etc., the SysCAD models tags can be used.
- SysCAD Marshal is switched on. To do this, go to Project - Settings - IO Connections Tab and select IO Marshal (OPC Client) ON.
- If new connectivity tags are required, they must be defined in the Marshal_Tags file first, then save, close and reload the SysCAD project.
OPC Server
- When the SysCAD project is running, user can go to the OPC server and change the values to the tags, then observe the value change inside SysCAD and vice versa.