Global variable lists and parameter lists
Topics:
Global Variable Lists
A list of global variables or constants is assigned the name "GVL" or the prefix "GVL_", followed by a description of the GVL in the name.
Examples:
- GVL
- GVL_Axis
- GVL_Subsystems
Parameter lists
A list of global parameters is given the name "Param" or the prefix "Param_", which is followed by a description of the parameter list in the name.
Examples:
- Param
- Param_Subsystems
Use attribute 'qualified_only' for GVL
When defining a global variable list or a parameter list use the attribute {attribute 'qualified_only'}, forcing the use of the GVL namespace when using the variables. By using the namespace (e.g.: GVL_Ctrl.bPaintingActive
) the global scope of the variable becomes clear.
Positive sample:
Global variable list "GVL_Ctrl":
{attribute 'qualified_only'}
VAR_GLOBAL
bPaintingActive : BOOL;
END_VAR
See also the topic Use attribute 'qualified_only' for GVL in section Programming.