Example for Using the Path Data

  1. Create an element of type MC_PATH_REF.

    path_description: MC_PATH_REF;

  2. Create an array of type MC_PATH _POINT.

    path_array: ARRAY[1..7] OF MC_PATH _POINT;

  3. Fill the MC_PATH_REF with data.

    path_description.ACCELERATION_TIME:=100;(*ms*)

    path_description.corner_mode:=0;

    path_description.CORNER_DISTANCE:=50;(*mm*)

    path_description.N:=7;

    path_description.Path:=ADR(path_array);

  4. Initialize the path_array itself.

../_images/309a7e47e83202e30a331390004edac1
../_images/6d41ebf0e4167d1f0a33139001619146
../_images/c9161527e415f1860a3313900056a378

The PathDescription has to be evaluated by MC_PathSelect. The resulting information is transferred by PathDataRef to the Function Block MC_MovePath which starts the movement. The MC_PathSelect just needs to be called once when the PathDescription has been changed. When the same data is used several times, it is enough to just call the MC_MovePath.

The MCA_PathEvent is an additional ABB specific Function Block which allows writing an “Event” value (32Bit) according to the position which is actually reached by the path interpolation. “Event” matches the respective value of EVENT as element of MC_PATH_POINT, when the group reaches this point.