2 smc_teachcoordinatesystem – Lenze PLC Designer PLC-Designer (R2-x) SoftMotion User Manual

Page 240

Advertising
background image

L-force | PLC Designer - SoftMotion

The SM_Trafo.lib library

Transformation function blocks

240

L

DMS 5.2 EN 03/2011 TD17

9.1.7.2

SMC_TeachCoordinateSystem
This POU of SM_Trafo.lib helps the user to calculate the vectors of a new coordinate system

which he wants to "teach". As inputs the source of the new coordinate system and a

random point are transferred to the x and y xis, respectively. As outputs the POU provides

the translation vector and the unit vectors of the new coordinate system. Furthermore it

calculates the quality of the input parameters (angle between x and y axis should be 90°).

Inputs (VAR_IN)
vOrigin: SMC_Vector3D
Source position of the new coordinate system.
vPointOnX, vPointOnY: SMC_Vector3D
Position of a point on the x or y axis.

Outputs (VAR_OUT)
vX, vY, vZ: SMC_Vector3D
Unit vectors of the new coordinate system.
vTranslation: SMC_Vector3D
Translation vector. Vector from the old coordinate origin to the new one with reference to

the old coordinate system
fQuality: LREAL
Quality of the input parameters; value from 0 to 1, where 1 = optimum (vX, vY are

orthogonal), and 0 = vX and vY are invalid.

Advertising