General implementation notes
Most programs described below are based on the same principle. In the initialisation phase, every function block instance is assigned to an axis or axis group required for operation by a variable of the AXIS_REF or AXES_GROUP_REF type. These variables are already created as an array in the motion base library (g_array_axis_ref and gAxesGroupRef). After this phase, all function block instances are calculated in a FOR loop in every PLC cycle.
Since only one visualisation is created and instanced for each function block type, it is also possible to switch this over to the various function block instances via the visualisation (see Visualisations for function blocks). The remaining code is required in the program in order to execute this process which contains pointers to function block instances.