Understanding Tags

Where are Tags Configured?

Tags provide a consistent data model throughout Ignition, and offer the easiest way to get up and running creating realtime status and control systems. Despite their low initial learning curve, however, Tags offer a great amount of power in system design and configuration. The ability to aggregate Tags from a variety of installations means that you can build widely distributed SCADA systems more easily than ever before with a high level of performance and relatively easy configuration.

While the goal of Tags in Ignition is to create an easy yet powerful model, the variety of options and terminology can sometimes make configuration confusing. Tags are created and controlled using both the Gateway and the Designer for configuration.

  • In the Designer, you will create the Tags. There are several types of Tags such as an OPC Tags, Memory Tags, and more. Each tag has many properties and other functionality such as alarming, history, etc. Once your tags are created, you can use them in your windows, reports, and more.

  • In the Gateway, you create and modify Tag Providers. You can create these Realtime Providers to store groupings of Tags for use in your projects either internally in Ignition or in an external database. There are also Historian Providers used to store historical data for the tags, but these are automatically created for each datasource you have. These Tag Provider configurations in the Gateway apply globally to all your projects.

Creating Tags

By default, there is one Internal Tag Provider created for you when Ignition is installed. Because of this, you can get started right away with creating Tags.

Tags are created in the Designer, either manual by right-clicking in the Tag Browser and selecting New Tag, or if you already have a device set up, by opening the OPC Browser and dragging tags or folders in. See Browsing and Creating OPC Tags for more information.

On this page ...

Manually Create Tags

images/download/attachments/6034125/new_tag.png

Using the OPC Browser

images/download/attachments/6034125/browse_tags.png

Working with Tags

Once you have Tags in your Tag Browser, they will automatically start executing. The Designer is live, and you can see your Tags update in real time and write values directly to them. The most commonly used type of tag is an OPC Tag, which gets it's value from the a device like an OPC Server. You can connect to just about any type of device out there and show the data on screen, as history, and write back whenever you want. Tags make Ignition extremely flexible and easy to show data. See the Quick Start Guide to get some tags created and in your client.

There are many things you can do with Tags to keep everything organized and give you exactly what you need.

Once you have some Tags created, you can edit them to include even more features. You can:

In addition to all that, Ignition allows you to create UDTs (User Defined Types) out of your Tags to rapidly develop projects with structured objects. This gives you the ability to create a master type then quickly add many instances. UDTs allow you to make a change in one place and see it automatically propagated to every instance.

What are Tag Providers?

Tag Providers and Drivers

At the highest level of configuration is the Tag Provider. A provider is a tag database (a collection of tags) and a name. An Ignition Gateway can have any number of tag providers, and therefore the name is used to distinguish which provider a tag comes from. Tag Providers can be set up with security or even disabled independent of each other.

Every provider holds tags, but not every provider is a Tag driver, or a tag executor. Some tag providers simply make tags available to use, and the tag execution is performed by a different driving provider elsewhere. For example, the Database Provider is a Tag provider that simply watches a tag database stored in an external database. It does not execute tags, it only monitors the values of the tags present. Somewhere else there is a tag driver such as a Driving Datasource Provider or a legacy FactorySQL that is executing the tags and storing the values to the database.

Realtime vs. Historian Providers

As discussed above, all Tags reside in a tag provider and provide realtime values. Additionally, there is the concept of tag historian providers, which can store and query historical data for tags. Each tag can optionally have a historian provider assigned to it to whom it will report value changes for historical storage.

Realtime Providers - Internal vs. External

The Tags "tag database", or how Tags tag configuration is stored, can take two forms. For internal tags, the configuration is stored in the Ignition Gateway. In the external form, tags are stored in a SQL database, outside of the Ignition Gateway. The two different storage mechanisms have different pro and cons, and so it is a good idea to acquaint yourself with each of them.

Internal Tags Provider

The internal Tags provider manages the tags inside the Ignition Gateway. This is the most common method and is optimized for the best scaling and performance.

It is possible to create multiple internal providers per Gateway. The tags can be exposed to other Gateways on the network through the Gateway's OPC-UA settings.

External Tags Providers

There are two types of external Tags providers in Ignition:

  • Database Provider

  • Database Driving Provider (provided by the SQL Bridge module)

The driving provider, as mentioned above, will execute tags as well as make available tags driven by other external drivers looking at the same database, such as other Ignition Gateways using the driving provider, or legacy FactorySQL installations.

The primary benefit of external providers is that the data is stored in a central database, and is therefore accessible to other data consuming systems that do not have the capabilities to connect to Ignition's OPC-UA server as an OPC-UA client yet still require the need to consume realtime tag information.

The negative side to external providers is that all tag values must be written to the database and then polled for change, which is a less efficient method than internal provider's method. In other words the inherent architecture of the external model does not scale as well as the internal provider model. For more information about those tables and how they work, see the External Tag Provider Reference.

Configuring Realtime Providers

Realtime Tags providers are configured in the Gateway's Configure section under Tags > Realtime. After installation, the Ignition Gateway will start with an internal provider defined. You can edit its name and settings by selecting edit to the right of its entry in the table, or create new providers by selecting Create new Realtime Tag Provider below the table.

There are three types of Realtime Tag Providers that you can choose from:

  • Standard Tag Provider

  • Tag Consuming Provider

  • Tag Driving Provider

Standard Tag Provider

Tags are stored inside of Ignition and executed by the system.

Name

The name of the provider.

Description

The description of the provider.

Tag Editing Role (s)

Users must belong to one of these roles in order to edit this provider's tags in the Designer. Multiple roles can be specified by separating them with commas. If blank, tag editing for this provider will not be restricted in the Designer.

Default Database

The default database connection to use for expression tags that run SQL queries. All query tags with default database providers selected with run their queries against this database source.

Tag Consuming Provider

Reads tags stored in an external database and driven by a different instance. Only consumes tags provided by other systems, does not write tag values back to the database.

Name

The name of the provider.

Description

The description of the provider.

Tag Editing Role (s)

Users must belong to one of these roles in order to edit this provider's tags in the Designer. Multiple roles can be specified by separating them with commas. If blank, tag editing for this provider will not be restricted in the Designer.

Database

The database connection where the tag database resides.

Poll rate

The rate in milliseconds at which value and configuration changes will be polled.

Poll overlap

The amount of time, in milliseconds, to overlap the polling time span.

Tag Driving Provider

Stores and executes tags in an external database.

Name

The name of the provider.

Description

The description of the provider.

Tag Editing Role (s)

Users must belong to one of these roles in order to edit this provider's tags in the Designer. Multiple roles can be specified by separating them with commas. If blank, tag editing for this provider will not be restricted in the Designer.

Database

The default database connection where the tag database resides.

Driver name

The unique name of this driver. Since the tags are stored in a central database, there may be multiple providers and drivers operating on them. This name will be used to identify this driver instance, and the tags that it executes. While the driving provider will read all of the tags stored in the database, it will only execute those tags that are assigned to it.

Poll rate

The rate in milliseconds at which value and configuration changes will be polled.

Poll overlap

The amount of time to overlap polls by. If set to 0, the config scan will look for changes only since the last execution. However, on databases that do not support millisecond resolution or are performing less-than-optimally, this could result in missed changes. This setting will expand the window in order to avoid missing these changes.

Enable browsing

Allows remote browsing of the OPC servers available to this driver over TCP/IP. This allows other Gateways to remotely browse and add tags assigned to this driver into the central database.

Browse port

The port to listen on for remote connections. This port must not be in use by any other entity on the machine. Also, each driving provider that wishes to support browsing must have its own port.

Browse address

The IP address/network name that remote Gateways will use when browsing. Therefore, care must be taken that the address is available from the Gateways that will try to connect. Also, since it is used for access by remote systems, it should not be the loopback address (localhost or 127.0.0.1).
The browse address and port will be stored in the Tags database so that other Gateways can easily look them up. After the settings are configured, you should immediately see the driver name in the OPC browse list for the external provider on other systems looking at the same database.
Note: When using remote browsing, make sure that the local firewall has an exception for the port that is used to listen. Otherwise, remote machines will not be allowed to connect.

Enum Reference

Almost every property in Ignition that is a dropdown list has an enumeration that starts at 0 and counts down the list. Below are the definitions of Tag property selections:

Basic Tag fields

Tag Type

0

OPC Tag

1

DB Tag

2

Client Tag

6

Folder Tag

Data Types

0

Byte

1

Short

2

Integer

3

Long

4

Float

5

Double

6

Boolean

7

String

8

Date

9

Integer Array

10

Long Array

11

Double Array

12

Boolean Array

13

String Array

14

DataSet

Access Rights

0

Read Only

1

Read/Write

2

Custom

Scan Class Modes

0

Direct

1

Driven

2

Leased

Write Response

0

Failure

1

Success

2

Pending

Quality

Data Quality

0

Bad Data from OPC

4

CONFIG_ERROR

8

NOT_CONNECTED

12

DEVICE_FAILURE

16

SENSOR_FAILURE

20

Bad, showing last value

24

COMM_FAIL

28

OUT_OF_SERVICE

32

WAITING

64

UNCERTAIN

68

UNCERTAIN showing last value

80

SENSOR_BAD

84

LIMIT_EXCEEDED

88

SUB_NORMAL

28

SERVER_DOWN

192

Good Data

216

Good, with local override

256

OPC_UNKNOWN

300

Config Error

301

Comm Error

310

Expr Eval Error

330

Tag exec error (fsql)

340

Type conversion error

403

Access Denied

404

Not Found

410

Disabled

500

Stale

600

Unknown (loading)

700

Write Pending

Alarms

Comparison Mode

0

Equal

1

Not Equal

2

Less Than

3

Less Than Equal

4

Greater Than

5

Greater Than Equal

Alert Flags

0x01

Low Exclusive

0x02

Low Infinite

0x04

High Exclusive

0x08

High Infinite

0x10

Any Change

0x20

Low Driven

0x40

High Driven

Similar Topics ...

In This Section ...