ShiftByXY

ShiftByXY 1:

Displace the components of this position.

Syntax

Definition:

METHOD ShiftByXY
VAR_INPUT
    dx : LREAL;
    dy : LREAL;
END_VAR

ShiftByXY 2: Inputs

Name

Type

Description

dx

LREAL

Shift of the x-component of this position.

dy

LREAL

Shift of the y-component of this position.

Beispiel: PositionXYC.ShiftByXY

PLC Deklaration

VAR
   position   : PositionXYC;
   dx : LREAL := 2.0;
   dy : LREAL := 0.0;
END_VAR

PLC Implementierung

position.SetValuesXYC(0, 3, 10);
position.ShiftByXY(dx, dy);

Erwartetes Ergebnis

position.x = 2
position.y = 3
position.c = 10