Set Tag List

From SysCAD Documentation
Jump to navigation Jump to search

Navigation: Models ➔ Control 2 Models ➔ Set Tag List

Get Tag List Set Tag List Noise Controller Slew Rate Controller Downtime Events Scheduled Events Profile Queue Profile Signal Waveform

General Description

The Set Tag List model can be used in both SysCAD ProBal and SysCAD Dynamic. It can be used as a fast alternative to using Excel for setting a long list of tags (usually configuration data).

The Set Tag list model reads a data file containing two or more columns. The first column must contain valid SysCAD Tags, the second and optional subsequent columns contain the corresponding tag values to be set in SysCAD models. Only one column of values can be set at a time. The column set is selected by the user.

By allowing multiple columns, the user can configure a table of values for the tags where each column represents a different scenario, case or set of inputs. Then all the user needs to do is change the current column to swap between different input sets or scenarios. The Get Tag List model also supports optional multiple columns so if the current column number for this is changed at the same time, the Get Tag List can be used to report results in a corresponding column. In a dynamic model the different columns can represent a set of values to be applied at different times during a scenario. Up to 254 tag value columns are allowed.

The model can be used to set all the tags during initialisation or after initialisation (i.e. during the first step) or the user can manually set the tags by pressing the Set Tag button.

If you wish to set tags before initialisation, then please use the SetTag List on the Plant Model. This is described in the following section: SetTagList Tab Page.

Set Tag List Format

The input file should be a comma or tab separated text file. Typically a csv file.

  1. The first row (or line) in the Set Tag List file is ignored. The user may place column headings in the first row.
  2. The first column usually contains valid SysCAD Tags.
    • If the tag is invalid or can not be set (e.g. a result field) then SysCAD reports an error in the message window.
    • An entry which starts with a semi-colon(;), is regarded as comment and is ignored.
    • If StopOnBlankTag option is ticked, then a blank row will mean the end of the list of tags. If this option is not enabled then blank rows are ignored.
    • String and numeric tag types are allowed.
  3. The second column contains the corresponding tag values to be set.
    • Numeric values and strings are supported. See example below.
    • If on a row there is a blank (empty cell) for the value, then the tag is set to zero.
    • User can use * to denote not a number (NAN).
    • For strings containing an (,) or (') a (") must be used at start and end of string.
  4. The third and any subsequent columns are optional and have the same format as the second column described above.

Note:

  • When SysCAD reads the file, it may stop when it finds an empty row. So be careful not to leave rows blank unless the StopOnBlankTag option is disabled.
  • Some SysCAD tags can only be set when the project is not solving.

Examples

Example of different tag types:

Tag Value
XPG_086.QmReqd (t/h) 200
XPG_086.T_Reqd (C) 220
PID_CCD.Cfg.[1].On 0
PID_CCD.Cfg.[1].OutputTag CCD_WashWater.QmReqd (t/h)
PID_CCD.Cfg.[1].Tol.Abs *
PID_CCD.EqpDesc "CCD's wash, etc. controllers"


Example for feeder composition showing two columns of values:

Tag Value1 Value2
Natural_Gas.Content.MF.CH4(g) (%) 96.923 95.3845
Natural_Gas.Content.MF.CO(g) (%) 0 0
Natural_Gas.Content.MF.CO2(g) (%) 2.68 4.02
Natural_Gas.Content.MF.H2(g) (%) 0 0
Natural_Gas.Content.MF.H2O(g) (%) 0.1 0.15
Natural_Gas.Content.MF.N2(g) (%) 0.297 0.4455
Natural_Gas.Content.MF.NH3(g) (%) 0 0
Natural_Gas.Content.MF.O2(g) (%) 0 0
Natural_Gas.Content.MF.H2O(l) (%) 0 0
Natural_Gas.Content.MF.NH3(l) (%) 0 0

How to use a Set Tag List

The easiest way to create the Set Tag List is by using MS Excel. The Set Tag List format and example is given above. Once the Set Tag List is created, save it as a csv file.

Switch to SysCAD, use the browse button to load the file into the model. The LogTagSets drop down list allows the user to have the Tag Set history displayed in the message window and/or added to the Event Log.

NOTE: Some tags can only be set when SysCAD is not running, for example, turning the PID controller on/off. These types of tags can only be set when SysCAD is stopped or by selecting an appropriate option for SetWhen.

SetTaglistmodel.png

Data Sections

Summary of Data Sections

  1. TagListCon tab - Contains general information relating to the unit.
  2. Info tab - Contains general settings for the unit and allows the user to include documentation about the unit and create Hyperlinks to external documents.

Set Tag List Page

Unit Type: TagListCon - The first tab page in the access window will have this name.

Tag (Long/Short) Input / Calc Description
Tag Display This name tag may be modified with the change tag option.
Condition Display OK if no errors/warnings, otherwise lists errors/warnings.
ConditionCount Display The current number of errors/warnings. If condition is OK, returns 0.
GeneralDescription / GenDesc Display This is an automatically generated description for the unit. If the user has entered text in the 'EqpDesc' field on the Info tab (see below), this will be displayed here.
If this field is blank, then SysCAD will display the UnitType or SubClass.
On Tickbox Enables or disables the SetTagList Block.
Status Feedback The status of the SetTagList with a brief summary of the file.
Folder Feedback The full path of the Set Tag List file.
File Input The file name of the Set Tag List. Relative File Path can be used. Note: this file must be created first. File can be txt or csv format.
 
Edit Button Allow the user to edit the file.
Browse Button Use this button to Browse for the file.
LogTagSets None SysCAD will not log the tag sets.
Messages SysCAD will log the tag sets in the Messages window only.
EventLog SysCAD will log the tag sets in the Event Log only.
Messages and EventLog SysCAD will log the tag sets in both the Messages window and the Event Log.
 
SetTags Button Use this button to Set the Tags into SysCAD.
 
ColumnToSet Input This specifies which column of values will be used when the tag list is set. Default value is 1 which corresponds to the first column of values.
StopOnBlankTag Tickbox SysCAD will stop searching for tags to be set after the first blank row.
SetWhen Manual The tags will only be set into SysCAD if the Set Tags button is pressed.
Prestart This will set the tags into SysCAD during the PreStart stage, which occurs before "Initialise Solution", thus any configuration information should be set into SysCAD using this option. This is similar to the set tag list model which is part of the Plant Model.
DuringInit This will set the tags into SysCAD during the Initialise Solution stage before it solves, thus any configuration information should be set into SysCAD using this option.
Startup (Early) This will set the tags into SysCAD at the beginning of the first iteration of SysCAD solve.
Note: some tags cannot be set while SysCAD is solving, in those cases, this option should not be used.
Startup (Late) This will set the tags into SysCAD at the end of the first iteration of SysCAD solve. This option is similar to the Startup (Early) option described above except the sets occur later in the first iteration.
Note: some tags cannot be set while SysCAD is solving, in those cases, this option should not be used.

Adding this Model to a Project

Add to Configuration File

Sort either by DLL or Group:

  DLL:
Control1.dll
Units/Links Control 2: Set Tag List
or Group:
General
Units/Links Control 2: Set Tag List

See Model Selection for more information on adding models to the configuration file.


Insert into Project Flowsheet

  Insert Unit Control 2 Set Tag List

See Insert Unit for general information on inserting units.

Hints and Comments

  1. If you cannot see this model in the list when you try to Insert a Unit, that means that the model is not in the Configuration file. See above 'Adding this Model to a Project' and also Project Configuration - Model Selection.
  2. Useful model to quickly swap between multiple feed compositions or multiple scenario cases.
  3. PGM logic can be written to effectively "push the button" to set the required column of tag values.

Example Project

Command Script Example