Lean MES Open Source Manufacturing Execution System
Flexible Manufacturing Solutions through Open Standards and Free Software....
ICONICS GENESIS 64 v.10.6+ Global Expressions Revealed

What is Global Expression?

Global Expression resembles an instance methods in OOP languages, it has a return value, input parameter(s) and implementation.

Global expressions can return value in two different ways: back to a client instance that invoked a read action on expression and/or push value to another non-client entity e.g. tag, or register (it cannot return value back to itself), if client instance invoked a write action on that expression. While former is defined and controlled through the “Read Expression” feature, latter uses the “Write Expression”.

In WorkBench go to Global Expressions: UDM > Config(Active) > Expressions > ... > expression

Example of data source for Gdfx client read access: @exp64:Class.PumpXFlow("A").Value

,where Class – is folder, PumpXFlow – expression, ("A") – parameter.

In other words, Global Expression is a template for the client's dynamic link data source.


Expression Properties (Fig.1) - definitions for: input parameter(s), expression'; data type, evaluation rate(ms)

input parameter(s) applicable to both Read and Write Expressions and denoted as <<some parameter>>.

Read Expression (Fig.2) - value to be return to the reading client(s),

x= IF ({{@ICONICS.IconicsOPCUAServer.V5\Simulate.Class.Pump<<PumpID>>.Running.Value}}

&& {{@ICONICS.IconicsOPCUAServer.V5\Simulate.Class.Pump<<PumpID>>.ValveOpen.Value}})

THEN {{@ICONICS.IconicsOPCUAServer.V5\Simulate.Class.Pump<<PumpID>>.Flow.Value}}


Important! The above read expression has the <<PumpID>> string which reference the input parameter (Fig.1) for this expression.

When an instance of client app. reads the expression e.g. @exp64:Class.PumpXFlow("A").Value , the <<PumpID>> gets resolved to "A". Example of the above resolved expression as seen by the client who passed "A" value to the <<PumpID>> parameter:

x= IF ({{@ICONICS.IconicsOPCUAServer.V5\Simulate.Class.PumpA.Running.Value}}

&& {{@ICONICS.IconicsOPCUAServer.V5\Simulate.Class.PumpA.ValveOpen.Value}})

THEN {{@ICONICS.IconicsOPCUAServer.V5\Simulate.Class.PumpA.Flow.Value}}


Each instance of a client application e.g. GraphWorX, receives it's own instance of expression, thus 2 or more clients accessing the same expression do not interfere with each other. This rule may not by applied to a Write Expression(s), since Write Expession(s) sets value(s) to a non-client entity, e.g. OPC Tag or UDM Register.

Important! Further level of flexibility and reuse may be reached through parameterizing the OPC-DA(UA) path, thus enabling to tap into pure abstract realm(s). Concider the following example:


<<OPCSrv>> - reference to an instance of OPC server application (local or remote relative to a current Framework Server).

<<OPCpath>> - hierarchical path within the referenced instance of OPC server (optional).

<<PumpID>> - reference to a common data source (OPC tag) “physical” entity.

Read Expression:

x= IF ({{@<<OPCSrv>>\<<OPCpath>><<PumpID>>.Running.Value}}

&& {{@<<OPCSrv>>\<<OPCpath>><<PumpID>>.ValveOpen.Value}})

THEN {{@<<OPCSrv>>\<<OPCpath>><<PumpID>>.Flow.Value}}


In conjunction with Smart Symbols, global expressions provide mechanisms for design and implementation of truly flexible automation solutions. Once again strong emphasis is made on design to interface approach.

Where to use: Visualization and control of solution' common building blocks; pumps, motors, wells, RTUs, HVAC units, generators and much more.