Skip to main content
Version: 8.1

Types of Tags

There are many different types of Tags in Ignition: standard Tags, System Tags, and Vision Client Tags. All these Tag types are available in the Tag Browser.

Tags executed in the Gateway support all of the primary features of Tags: scaling, alarming, history, and role-based permissions. These Tags run in the Gateway, and the values of the Tags are shared among all running sessions and clients. They are identical in their configurations, apart from defining how the value is generated. As of release 8.1, each Tag Type has its own icon in the Tag browser.

IconTag Type
Memory Tag
OPC Tag
Expression Tag
Query Tag
Reference Tag
Derived Tag
System Client Tag, Vision Client Tags

OPC Tags​

An OPC Tag is driven by an OPC Item Path and OPC server. The OPC Item Path is a string path to a particular device connection. The exact path is defined by the driver and OPC server used to communicate with the device. Many drivers support browsing, allowing you to automatically create OPC Tags by dragging-and-dropping from the OPC Browser. However, in cases where browsing isn't supported, OPC Tags can manually be created. In the

In the Tag Browser, double click on any existing OPC Tag, to see the the OPC Server name and Item Path.

Memory Tags​

Inductive University

Memory Tags

Watch the video

Memory Tags are simple Tags, that do not automatically poll or update their value. They hold the same value until some other user-created mechanism (most likely a script or binding) changes their value. They're useful in situations where a value must be stored outside of a PLC or database.

The state of memory tags are stored inside the gateway's internal database. This allows the tag and its value to be retained across Gateway restarts.

Expression Tags​

Inductive University

Expression Tags

Watch the video

Expression Tags are driven by an expression, allowing their values to be determined from a calculation.

The Expression property on Expression Tags determines their value. The expression can reference values and properties on other Gateway scoped Tag values. However, due to scoping, they can not reference property values on Vision Client and Perspective Session components.

The expression on an Expression Tag executes based off of the Execution Mode. More information on Execution Mode can be found on the Tag Properties page.

note

It may be helpful when troubleshooting or testing Expression tags to increase the default threadpool count. Refer to the Gateway Configuration File Reference - Threadpool Counts for more information.

Query Tags​

Inductive University

Query Tags

Watch the video

A Query Tag executes a SQL Query; the result of that query is returned to the value on the Tag. Query Tags can reference other Gateway-scoped Tags to build dynamic queries. The Query property dictates the query that will execute, and the Execution Mode determines how often the query will run. Furthermore, the Datasource property determines which database connection the query will execute against.

note

It may be helpful when troubleshooting or testing Query tags to increase the default threadpool count. Refer to the Gateway Configuration File Reference - Threadpool Counts for more information.

Reference and Derived Tags​

Inductive University

Reference and Derived Tags

Watch the video

Reference Tags​

A Reference Tag simply refers to an existing Tag, using the Source Tag Path property to determine which other Tag to reference. Writes targeting the Reference Tag will send a write request to the source Tag.

Derived Tags​

A Derived Tag is an abstracted Tag that refers to another Tag. They are similar conceptually to Reference Tags in that that value is dependent on the Source Tag Path property, but Derived Tags have some additional functionality. Namely, they can apply expressions to the referenced value with the Read Expression property, allowing the value on the Derived Tag to differ from the source Tag.

In addition, The Write Expression property will apply an expression to the value of any write requests targeting the Derived Tag, allowing the expression to modify the value of the incoming write before it's applied back to the source Tag.

PropertyDescription
Read ExpressionDetermines what value should appear on the Derived Tag. The current value of the source Tag may be referenced with the {source} reference.
Write ExpressionWhen writing to the Derived Tag, this expression determines what value should be written to the source Tag. The current value of the source Tag may be referenced with the {source} reference. The raw value passed to the Derived Tag may be referenced with the {value} reference.

This interface provides an opportunity to scale the written and read value. For example, if the source Tag was in Fahrenheit, and the derived Tag should be Celsius, we could use the following expressions:

//Read Expression
({source}-32)*(5/9)

//Write Expression
{value}*(9/5) + 32

Changing the Source​

Aside from editing the Tag from the Designer, the source Tag path on a Derived Tag may be modified by writing directly to the SourceTagPath property on the Tag, or using a Tag Binding on a Vision component.

Additionally, the SourceTagPath property may be changed through scripting:

#Example of writing to the SourceTagPath attribute via Python Script
system.tag.writeBlocking(["Derived Example/Derived Tag.SourceTagPath"], ["[.]Folder/New Source Tag"])

User Defined Types (UDTs)​

UDTs are created out of standard Tag types, but they offer a variety of additional features. You can think of them as a way to create "data templates", where a particular structure of Tags is defined, and can then be created as if it were a single Tag. This UDT example shows two Motor instances, the data type Motor, and all the Parameters and Tags that make up the structure (i.e., Amps and HOA). For more information, see User Defined Types - UDTs.

System Tags​

System Tags provide status about the Ignition system. They're generally cannot be modified, but provide use information about how the system is performing.

More information can be found on the System Tags page.

Vision Client Tags​

Within the Vision module, you can also have Vision Client Tags that are specific to a Vision Client. Their values are isolated to a Client runtime. For more information, see Vision Client Tags.