Coordinate transformation between coordinate systems (#TRANSFORM)

This function is an additional option requiring a license.

The #TRANSFORM command is used to convert any coordinates of a 3D point from one stack level to another stack level in the NC program based on the current CS stack. The transformation calculation required for this consists of a combination of kinematic and Cartesian forward or backward transformation, depending on the structure of the CS stack.

Auxiliary and additional axes are only taken into account in the transformation calculation with regard to their zero point displacements between the stack planes.

The calculations in the #TRANSFORM command can always be executed between all currently valid CS stack levels, regardless of the transformations already active in the channel (#CS SELECT).

Syntax of Transformation command:

#TRANSFORM [<CS_source>] [<CS_dest> ] [POS_X>, <POS_Y>, <POS_Z> ] [ [ {<POS_aux>=..} ] ]

<CS_source>

Name of the tracked CS with maximum of 8 characters.

<CS_dest>

Name of the destination CS with maximum of 8 characters.

<POS_X, Y, Z>

3 components of the point to be transformed in [mm, inch] in the input CS.

<POS_aux>=..

Input coordinates of the auxiliary and additional axes

An error message is output if:

  • the name of a coordinate system is not defined (ID 21601)
  • 3 input coordinates are not programmed (ID 21104)

The result of the transformation calculation is supplied in special axis-specific variables (V.A.). The axis can be programmed either by name or by axis index:

Syntax of Result variables

V.A.TRANSFORM.<axis_name>      Axis-specific coordinate after calculation in [mm, inch]

or

V.A.TRANSFORM[<axis_index>]     Axis-specific coordinate after calculation in [mm, inch]

 

Programming Example

Example 1, basic configuration is a 5-axis kinematic with CS stack.

Transformation for the point (50,0,10) with tracking axis positions A10 and B20 from the ACS system to the WCS system. A kinematic Cartesian forward transformation is executed.

#TRANSFORM [ACS] [WCS] [50, 0, 10] [A10 B20]

Coordinate transformation between coordinate systems (#TRANSFORM) 1:
Example: forward transformation with #TRANSFORM

Example 2, basic configuration is a 5-axis kinematic with CS stack.

Transformation for the point (10,-10,15) with tracking axis positions A45 and B90 from the MCS system to the ACS system. A simple kinematic backward transformation is executed.

#TRANSFORM [MCS] [ACS] [10, -10, 15] [A45 B90]

Coordinate transformation between coordinate systems (#TRANSFORM) 2:
Example: backward transformation with #TRANSFORM

As of Build V3.1.3081.11, the transformation of PCS positions can also be used in the #TRANSFORM command. Here, it is sufficient if this transformation is configured in the channel parameter list (trafo_pcs.type (P-CHAN-00829) and trafo_pcs.param[i] (P-CHAN-00263); it need not be active (#TRAFO PCS ON). The PCS transformation is always placed at the topmost CS stack level and is addressed accordingly in the transformation calculation by the fixed name of TPCS in the #TRANSFORM command. If the name TPCS is used although no PCS transformation is configured, the error message ID 21630 is output.

Programming Example

The basic configuration is a 5-axis kinematic with CS stack.

Transformation for the point (0, -20,50) from the TPCS system to the ACS system. A kinematic-Cartesian-kinematic backward transformation is executed.

#TRANSFORM [TPCS] [ACS] [0, -20, 50]

Coordinate transformation between coordinate systems (#TRANSFORM) 3:
Example of TPCS backward transformation with #TRANSFORM