L_TC2P_MoveQuarterElliptical

 

 

 

L_TC2P_CmdMoveQuaterElliptical

 

 

 

 

 

 

 

 

 

 

 

L_TC2P_CoordinatedMotion

–

 

itfCmdReceiver

xCmdAccepted

 

–

BOOL

ARRAY[1..12] OF LREAL

–

 

alrPosition

 

 

 

 

L_MC4P_CoordSystem

–

 

eCoordSystem

 

 

 

 

LREAL

–

 

lrBlendingRadius

 

 

 

 

ARRAY[1..6] OF L_MC4P_AuxMode

–

 

aeAuxMode

 

 

 

 

L_MC4P_Orientation_Mode

–

 

eOrientationMode

 

 

 

 

ARRAY[1..6] OF MC_DIRECTION

–

 

aeDirection

 

 

 

 

ARRAY[1..3] OF LREAL

–

 

alrEllipticalDirection

 

 

 

 

L_TC2P_EllipticalDirection

–

 

eEllipticalDirection

 

 

 

 

 

 

 

 

 

 

 

 

Inputs

Identifier

Data type

Description

itfCmdReceiver

L_TC2P_CoordinatedMotionState

L_TX2P_PickAndPlaceBase

Connection to the technology module - which interprets the command and executes the job/driving task.

  • L_TC2P_CoordinatedMotionState

  • L_TX2P_PickAndPlaceBase

alrPosition

ARRAY[1..12] OF LREAL

Array with absolute target coordinates in [Units].

  • Reference for the absolute position is the zero position of the selected coordinate system.

Absolute target position of the movement

  • Index 1 ... 6:

    • Coordsystem = ACS: Target position of the drive axes

    • Coordsystem = WCS, MCS oder PCS: Target position of the TCP in the selected coordinate system.

  • Index 7 ... 12:

    • Target position of the optionally available auxiliary axes

eCoordSystem

L_MC4P_CoordSystem

Selection of the coordinate system to be used:

  • WCS: World Coordinate System

  • MCS: Machine Coordinate System

  • ACS: Axes Coordinate System

  • PCS_1 ... PCS_16: Product Coordinate System (1 ... 16)

lrBlendingRadius

LREAL

Blending radius for the profile. The value specifies at what distance from the target point the blending movement should start.

  • • Unit: mm

eOrientationMode

L_MC4P_Orientation_Mode

Presetting the orientation interpolation for the WCS axes.

  • ShortestSpacialWay: The target orientation is approached in such a way that the shortest possible solid angle results for the sum of the movements. For 4D kinematics this is equivalent to mcShortestWay for the C axis. (default)

  • AxisIndividual: The direction of movement can be specified independently for each orientation axis via the Direction input.

  • Initial value: ShortestSpacialWay

 

Initial value: ShortestSpacialWay

aeDirection

ARRAY[1..6] OF MC_DIRECTION

Direction specification for WCS rotary axes (A, B, C axis), which are parameterized as modulo.

The parameter is evaluated only with
eOrientationMode:= L_MC4P_Orientation_Mode.AxisIndividual.

For MoveLinear movements only the indices 4 ... 6 (main axes A, B, C) are used.

Permissible selection:

  • mcPositiveDirection: Positive direction

  • mcNegativeDirection: Negative direction

  • mcShortestWay: Shortest path (default)

The mcCurrentDirection, mcPositiveCycle and mcNegativeCycle modes are not supported.

 

See also: Direction specification for modulo axes (^ 700)

aeAuxMode

ARRAY[1..6] OF L_MC4P_AuxMode

Mode for the auxiliary axes:

  • Inactive: Auxiliary object coordinates are ignored.

  • Continuous: Looping of the auxiliary axis over several MC_Move blocks.

  • DiscreteAbsolute: Auxiliary object position is set at the end of each motion segment (similar to main axes)..

DiscreteRelative: Auxiliary object position is set at the end of each motion segment (similar to main axes).

alrEllipticalDirection

ARRAY[1..3] OF LREAL

Target direction from the start point or into the target points, depending on which mode eElliptical is selected.

  • [0,0,1] Target direction in positive Z axes

  • [1,0,0] Target direction in positive X axes

  • [0,1,0] Target direction in positive Y axes

  • [1,1,0] Target direction in positive X -Y plane

 

  • [0,0,-1] Target direction in negative Z axes

  • [-1,0,0] Target direction in negative X axes

  • [0,-1,0] Target direction in negative Y axes

eEllipticalDirection

L_TC2P_EllipticalDirection

 

The vector alrEllipticalDirection describes the direction from the starting point or the direction into the destination point.

  • 2: DirectionAtStart:  the direction from the start point

  • 3: DirectionAtTarget: Direction to the target point

  • Initial value: 2 DirectionAtStar

Outputs

Identifier

Data type

Description

xCmdAccrepted

BOOL

TRUE

The command is valid and will be included in CmdReceiver.

Method

Identifier

Data type

Description

METHOD Execute : Bool

Release of the order for the execution of the command.

TRUE

The command is valid and will be included in CmdReceiver.

FALSE

The command is not valid because no CmdReceiver is connected.

Activate the command

Each command has the method Execute().

To execute the command, the Execute() method must be called. The method has the return value of data type BOOL. The return value = TRUE is set if a valid command receiver is connected to the itfCmdReceiver input.

The TM L_TC2P_CoordinatedMotion changes to the state MOVEELLIPTICAL when the motion task of the command is active.

If motion tasks are already executed in the TM L_TC2P_CoordinatedMotion, the motion task from the currently assigned command is added at the end of the waiting list. The waiting list is processed after the order

The target position alrPosition from the command is approached absolutely.

Blending

Via the input lrBlendingRadius > 0 the target point alrPosition of the command is slept. The blending radius belongs to the point of the command that is currently activated.

Grouping of the commands

If several commands are activated in the same PLC clock. So these are concatenated in a path as a group. The call sequence of the Execute() method of the commands decides the processing.

Determination of the quarter ellipse

The height of the quarter ellipse results from the height difference between the start point and the target point. With the input alrEllipticalDirection the normal vector (3-Dim) is set. Depending on the parameterization, the normal vector describes the start or the target direction of the quarter ellipse.

Quarter ellipse with the specification of the start direction (eEllipticalDirection := 2 DirectionAtStart)

Application example: Approach to the parking position

  • The quarter ellipse moves up in the z-direction.

  • alrEllipticalDirection := [0, 0, 1]

  • eEllipticalDirection := 2 DirectionAtStart

VAR

    /// Technology module:

    TM_CoordMotion: L_TC2P_CoordinatedMotionState;

    /// Commands:

    Cmd_ProfilePar     : L_TC2P_CmdBasicProfileParameter 
                         :=( itfCmdReceiver := TM_CoordMotion);

    Cmd_MoveQuarterEllip : L_TC2P_L_TC2P_
                           JobMoveQuarterElliptical
                           := ( itfCmdReceiver
                           := TM_CoordMotion);

    /// state

    wState : WORD;

END_VAR

CASE  wState OF

10: /// send move elliptical command

 

    /// set profile parameters

    Cmd_ProfilePar.lrPathVel  := 100;

    Cmd_ProfilePar.lrPathAcc  := 1000;

    Cmd_ProfilePar.lrPathDec  := 1000;

    Cmd_ProfilePar.lrPathJerk := 100000;

    Cmd_ProfilePar.Execute();

 

    /// execute move elliptical

    Cmd_MoveQuarterfEllip.lrBlendingRadius  := 50;

    Cmd_MoveQuarterEllip.eCoordSystem       := L_MC4P_CoordSystem.WCS;

    Cmd_MoveQuarterEllip
    .eEllipticalDirection := L_TC2P_EllipticalDirection
                             .DirectionAtStart;

 

    Cmd_MoveQuarterEllip.alrEllipticalDirection[1]  := 0;

    Cmd_MoveQuarterEllip.alrEllipticalDirection[2]  := 0;

    Cmd_MoveQuarterEllip.alrEllipticalDirection[3]  := 1;

 

    Cmd_MoveQuarterEllip.alrPosition[1]     := 75;    // x pos

    Cmd_MoveQuarterEllip.alrPosition[2]     := 0;     // y pos

    Cmd_MoveQuarterEllip.alrPosition[3]     := 200;  // z pos

    Cmd_MoveQuarterEllip.Execute();

 

    wState := 20;

 

END_CASE

Quarter ellipse with the target direction specified (eEllipticalDirection := 3 DirectionAtEnd)

Application example: Leaving the parking position

  • The quarter ellipse moves down in the z-direction.

  • alrEllipticalDirection := [0, 0 ,1]

  • eEllipticalDirection := 3 DirectionAtEnd

VAR

    /// Technology module:

    TM_CoordMotion: L_TC2P_CoordinatedMotionState;

    /// Commands:

    Cmd_ProfilePar     : L_TC2P_CmdBasicProfileParameter 
                         :=( itfCmdReceiver := TM_CoordMotion);

    Cmd_MoveQuarterEllip : L_TC2P_L_TC2P_
                           JobMoveHalfElliptical
                           := ( itfCmdReceiver
                           := TM_CoordMotion);

    /// state

    wState : WORD;

END_VAR

CASE  wState OF

10: /// send move elliptical command

 

    /// set profile parameters

    Cmd_ProfilePar.lrPathVel  := 100;

    Cmd_ProfilePar.lrPathAcc  := 1000;

    Cmd_ProfilePar.lrPathDec  := 1000;

    Cmd_ProfilePar.lrPathJerk := 100000;

    Cmd_ProfilePar.Execute();

 

    /// execute move elliptical

    Cmd_MoveQuarterfEllip.lrBlendingRadius := 50;

    Cmd_MoveQuarterEllip.eCoordSystem      := L_MC4P_
                                              CoordSystem.WCS;

    Cmd_MoveQuarterEllip
    .eEllipticalDirection := L_TC2P_EllipticalDirection
                             .DirectionAtEnd;

 

    Cmd_MoveQuarterEllip.alrEllipticalDirection[1]   := 0;

    Cmd_MoveQuarterEllip.alrEllipticalDirection[2]   := 0;

    Cmd_MoveQuarterEllip.alrEllipticalDirection[3]   := 1;

 

    Cmd_MoveQuarterEllip.alrPosition[1]    := 100; // x pos

   Cmd_MoveQuarterEllip.alrPosition[2]     := 0;   // y pos

   Cmd_MoveQuarterEllip.alrPosition[3]     := 100; // z pos

   Cmd_MoveQuarterEllip.Execute();

 

    wState := 20;

 

END_CASE

Concatenation of the quarter ellipse with linear segments

  • The quarter ellipse moves in the xy direction of the target position

  • The blending is set for the command of the viral ellipse lrBlending > 0

VAR

    /// Technology module:

    TM_CoordMotion: L_TC2P_CoordinatedMotionState;

    /// Commands:

    Cmd_ProfilePar : L_TC2P_CmdBasicProfileParameter 
                     :=( itfCmdReceiver := TM_CoordMotion);

    Cmd_MoveQuarterEllip: L_TC2P_L_TC2P_
                          JobMoveQuarterElliptical
                          :=( itfCmdReceiver
                          := TM_CoordMotion);

    Cmd_MoveLinAbs : L_TC2P_CmdMoveLinearAbsolute 
                     :=( itfCmdReceiver := TM_CoordMotion); 

    /// state

    wState : WORD;

END_VAR

CASE wState OF

10: /// send move elliptical command

 

    /// set profile parameters

    Cmd_ProfilePar.lrPathVel := 100;

    Cmd_ProfilePar.lrPathAcc := 1000;

    Cmd_ProfilePar.lrPathDec := 1000;

    Cmd_ProfilePar.lrPathJerk := 100000;

    Cmd_ProfilePar.Execute();

 

    /// execute move elliptical

    Cmd_MoveQuarterfEllip.lrBlendingRadius := 50;

    Cmd_MoveQuarterEllip.eCoordSystem      := L_MC4P_
                                              CoordSystem.WCS;

    Cmd_MoveQuarterEllip
    .eEllipticalDirection := L_TC2P_
                             EllipticalDirection
                             .DirectionAtStart;

 

    Cmd_MoveQuarterEllip.alrEllipticalDirection[1]  := 0;

    Cmd_MoveQuarterEllip.alrEllipticalDirection[2]  := 0;

    Cmd_MoveQuarterEllip.alrEllipticalDirection[3]  := 1;

 

    Cmd_MoveQuarterEllip.alrPosition[1]   := 75;   // x pos

    Cmd_MoveQuarterEllip.alrPosition[2]   := 0;    // y pos

    Cmd_MoveQuarterEllip.alrPosition[3]   := 200;  // z pos

    Cmd_MoveQuarterEllip.Execute();

 

    /// execute move linear abs

    Cmd_MoveLinAbs.lrBlendingRadius := 0;

    Cmd_MoveLinAbs.eCoordSystem     := L_MC4P_CoordSystem.WCS;

    Cmd_MoveLinAbs.alrPosition[1]   := 130;  // x pos

    Cmd_MoveLinAbs.alrPosition[2]   := 0;      // y pos

    Cmd_MoveLinAbs.alrPosition[3]   := 250;  // z pos

    Cmd_MoveLinAbs.Execute();

 

    wState := 20;

 

END_CASE