<< Click to Display Table of Contents >> Navigation: »No topics above this level« Aliases for process variables |
mapp Services V5.16
Each element of a structure (regardless of whether it is an element of a basic type or array/structure) can be mapped and used by an alias. The type of the entire structure does not have to be declared; only the mapped element type must be known.
Mapping global variables
VAR {<Storage> AT ( PLC | '<Task name>')}
<Alias> {ACCESS '<Name of process variable>'}: <Type>;
<Alias> {ACCESS '<Name of process variable>'}: REFERENCE TO <Type>;
<Alias> {ACCESS '<Name of process variable>'}: ARRAY [<From>..<To>] OF <Type>;
END_VAR
VAR {AT PLC}
TraceRunning {ACCESS 'VariableTrace.Running'} : BOOL;
PosX {ACCESS 'UserStruct.Position[0]'} : LREAL;
END_VAR
VAR {AT 'PositionTask'}
TargetX {ACCESS 'UserStruct.Position[0]'} : LREAL;
END_VAR