A Virtual Tag is a way of defining IOW Tags using dynamic expressions. Expression can be composed using PI Tags and built-in functions like:
- +, -, *, /
- MIN, MAX, MEAN, SUM, ABS, SQRT, STD
- If then else
- ( )
Creating Virtual Tags
To create a Virtual Tag:
- First create a new IOW.
- For the Variable select "Virtual Tag".
Select the "Virtual Tag" Variable for your IOW. - Now the Expression field becomes available. You can either click the Edit button and define the Expression right away, or do this later after you have saved your IOW.
- Remember to also fill in the other fields - refer to the IOW Record.
Opening the Expression
From the CL/System Details Page
To open the Expression from the CL Details Page (PEI Equipment) or System Details Page (PLSS Equipment):
- Scroll to the IOW section.
- Find your Virtual Tag (Variable = "Virtual Tag").
- Click on the PI/Virtual Tag field.
Click in the PI/Virtual Tag field. - Then click the Edit button the becomes available.
Click the Edit button.- Now you can define the Expression.
From the IOW Details Page
To open the Expression from the IOW Details Page:
- In the Details section, click Edit.
- In the Expression field click on the Edit button.
The Virtual Tag Expression can also be opened from the IOW Details Page.Defining the Expression
Below is an example where a Virtual Tag expression is defined and verified. You can select a PI Tag from the list and click the Add button to add the Tag to the expression. When done defining the expression, you can verify it by clicking the Test button.
A PI Tag is added to the expression with the Add button. The Test button is used to verify the expression.When the Virtual Tag’s expression is verified, IMS will either show a green valid message or a red error message.
An error message is shown in case of, e.g., a syntax error in the expression. You can learn more about the Formula Editor here.
Tags search using wildcards
When adding Tags to the IOW (also when adding it to a Virtual Tag expression), you can search for the Tag name using wildcards in the search string. Valid examples are:
- *Test* (this is also default behavior when no wildcard is used)
- Test*
- *Test
- Test
Searching for a PI Tag using wildcards. 