MC_PATH_REF

This structure is used for moving a Cartesian group on a path. It is evaluated by MC_PathSelect, which creates the structure MC_PATH_DATA_REF to be used for the path movement.

A path movement can be done with the following Function Blocks:

  • MC_MovePath: Move on a path with a defined velocity/in a defined time.
  • MC_MovePathPos: Move on a path with a defined velocity/in a defined time including the movement to the path start position.
  • MC_SyncGroupToAxis: Move on a path following a master axis.
../_images/982d21a00a6ce6440a33139001ca0668

For PathMovement and BufferedMovement, the TMConstantVelocity can be used as TransitionMode and will influence the path-movement in a way that the velocity is kept constant, no matter the angle, as described with buffered movement. It is applied in combination with mode CORNER_MODE=0 (use CORNER_DISTANCE). This special TransitionMode is added to MC_PATH_REF. Any other value at TRANSITION_MODE will result in default behavior, which means a deceleration during a corner, depending on the angle MCA_MoveBuffered.

CORNER_DISTANCE

Data type: LREAL, unit: u

Distance at which the velocity vector start to leave the actual direction and turning towards the next point. The value has to be >=0.

ACCELERATION_TIME

Data type: LREAL, unit: ms

Time which is used to reach the path-velocity.

pPATHPOINTS

Data type: POINTER TO MC_PATH _POINT

Pointer to an array which hold the points on the path.

NUMBER_OF_POINTS

Data type: DINT

Number of points.

CORNER_MODE

Data type: DWORD

=0 => use CORNER_DISTANCE.

=1 => use CORNER Interpolation.

=0x100 => use CORNER_DISTANCE, but related to MASTER_POSITION (ignore V_PATH).

=0x101 => use CORNER Interpolation, but related to MASTER_POSITION (ignore V_PATH).

Available options
CORNER_MODE MC_MovePath/MCA_MovePathPos MC_SyncGroupToAxis
0,1 The movement is executed by time, calculated based on V_PATH. The movement is executed by synchronizing to a master axis. The master positions are calculated based on V_PATH which means V_PATH gives the relation from slave/master velocity [u(slave)/u(master)] instead of [u/s].
0x100, 0x101 The movement is executed by time, calculated based on MASTER_POSITION. The given values are interpreted as [s]. The movement is executed by synchronizing to a master axis. MASTER_POSITION is used. The group will reach the given X/Y/Z point when the master axis reaches MASTER_POSITION. The points are not reached exactly but modified by CORNER_DISTANCE or the CORNER algorithm.