Access to tool data in the NC program (V.G.WZ..)

V.G.WZ[j]...

The “WZ[j]” variables permit read access to the data of any tool. They are both available with an external tool management system (transparent access) and for use of an internal tool table (<j> then corresponds to the index of the tool (or the tool number) in the tool list [5]).

Write access is only permitted if an internal tool table is used.

WZ[j].R

Radius of the tool

Real

[mm, inch]

R/W*

WZ[j].L

Length of the tool

Real

[mm, inch]

R/W*

WZ[j].P[i]

Tool parameter where <i>: 0 … 59

Real

-

R/W*

WZ[j].V[i] or WZ[j].V.X

Offset in axis <i> or "X" of the tool where < i>: 0 … 31

Real

[mm, inch]

R/W*

WZ[j].ME

Measuring unit of radius, length and axis offsets, always supplies 0 (for [mm]) when a tool list is used, otherwise the variable has no significance

Boolean

0 , 1

R

WZ[j].OK

Validity flag of the tool;
if valid, then 1

Boolean

0 , 1

R/W*

WZ[j].SPDL_AX_NR

Logical axis number of the assigned spindle

Integer

-

R/W*

WZ[j].KIN_PARAM[i]

Kinematic parameters of the tool in internal unit where < i>: 0 … 69

Real

[0.1 µm,
10-4°]

R/W*

WZ[j].KIN_ID

Kinematics ID of the tool

Integer

-

R/W*

WZ[j].TYPE

Tool type (0: Milling tool 1: Turning tool 2: Grinding tool)

Integer

-

R

WZ[j].TOOL_FIXED

Tool is alignable or fixed

Boolean

0 , 1

R/W*

WZ[j].SRK_ID

Cutter orientation of a turning tool

Integer

-

R/W*

WZ[j].S_MIN_SPEED

Minimum rotational speed (tool dynamic data)

Real

[rpm]

R/W*

WZ[j].S_MAX_SPEED

Maximum rotational speed (tool dynamic data)

Real

[rpm]

R/W*

WZ[j].S_MAX_ACC

Maximum acceleration (tool dynamic data)

Real

[°/s2]

R/W*

WZ[j].SISTER_VALID

Validity flag of sister tool (TOOL ID)

Boolean

0 , 1

R/W*

WZ[j].SISTER

Number of valid sister tool

Integer

-

R/W*

WZ[j].VARIANT_VALID

Validity flag of variant tool (TOOL ID)

Boolean

0 , 1

R/W*

WZ[j].VARIANT

Number of valid variant tool

Integer

-

R/W*

WZ[j].GOBJECT[i].*

Access to the subelements of a specific graphical object [as of Build V3.01.3018.00] where <i>: 0 … 4

-

-

WZ[j].LINKPOINT.*

Access to the subelements of associated linkpoints [as of Build V3.01.3018.00]

-

-

...

S*: Write access to data of the internal tool management system as of CNC Build V3.1.3079.08

V.G.WZ_AKT...

The variables “WZ_AKT”, “T_AKT” and “D_AKT” permit access to the data of the currently selected tool. These variables are available both for an external tool management system and for the use of an internal tool table.

T_AKT

Number of the selected tool

Integer

-

R

D_AKT

Number of the selected tool compensation record

Integer

-

R

Notice

notice

A write access always causes the temporary change of tool data as long as this function is selected. When a new tool is selected (Dxx) or deselected (D0), the changed data are lost.

Exception:

When an external tool management system is used, the so-called additional tool data (V.G.WZ_AKT.P[i]) is adopted and saved when a new tool is selected or a tool is deselected (P-CHAN-00103).

WZ_AKT.R

Radius of the selected tool

Real

[mm, inch]

R/W

WZ_AKT.L

Length of the selected tool

Real

[mm, inch]

R/W

WZ_AKT.P[i]

Free parameters of the selected tool where <i>: 0 … 59

Real

-

R/W

WZ_AKT.V[i] or
WZ_AKT.V.X

Offset in axis <i> or "X" of the selected tool where < i>: 0 … 31

Real

[mm, inch]

R/W

WZ_AKT.ME

Measuring unit of radius, length and axis offsets of the selected tool, always supplies 0 (for [mm]) when a tool list is used, otherwise the variable has no significance

Boolean

0 , 1

R

WZ_AKT.OK

Validity flag of the selected tool;
is always 1 since only data of valid tools are adopted. An error message is output if invalid tools are requested

Boolean

0 , 1

R/W*

WZ_AKT.SPDL_AX_NR

Logical axis number of the assigned spindle

Integer

-

R/W*

WZ_AKT.KIN_PARAM[i]

CAUTION: Note on write access: Value must be programmed in internal units.

Kinematic parameters of the selected tool where < i>: 0 … 69

Real

[0.1 µm,
10-4°]

R/W

WZ_AKT.KIN_ID

Kinematic ID of the selected tool

Integer

-

R/W*

WZ_AKT.TYPE

Tool type of the selected tool
(0: Milling tool 1: Turning tool 2: Grinding tool)

Integer

-

R

WZ_AKT.TOOL_FIXED

Tool is alignable or fixed

Boolean

0 , 1

R/W

WZ_AKT.SRK_ID

Cutter orientation of the selected turning tool

Integer

-

R/W*

WZ_AKT.S_MIN_SPEED

Minimum rotational speed (tool dynamic data)

Real

[rpm]

R/W*

WZ_AKT.S_MAX_SPEED

Maximum rotational speed (tool dynamic data)

Real

[rpm]

R/W*

WZ_AKT.S_MAX_ACC

Maximum acceleration (tool dynamic data)

Real

[°/s2]

R/W*

WZ_AKT.SISTER_VALID

Validity flag of sister tool (TOOL ID)

Boolean

0 , 1

R/W*

WZ_AKT.SISTER

Number of valid sister tool

Integer

-

R/W*

WZ_AKT.VARIANT_VALID

Validity flag of variant tool (TOOL ID)

Boolean

0 , 1

R/W*

WZ_AKT.VARIANT

Number of valid variant tool

Integer

-

R/W*

WZ_AKT.WEAR_RADIUS

Total radius wear with radius compensation (OTC) (sum of discrete + continuous wear)

Real

[mm, inch]

R

WZ_AKT.WEAR_RADIUS_CONT

Continuous radius wear with radius compensation (OTC)

Real

[mm, inch]

R

WZ_AKT.WEAR[i] or
WZ_AKT.WEAR.X

Wear in axis <i> or "X" with length compensation (OTC) where < i>: 0 … 31

Real

[mm, inch]

R

WZ_AKT.WEAR_CONST

Wear constant (OTC)

Real

[0.1 µm/m]

R/W

WZ_AKT.GOBJECT[i].*

Access to the subelements of a specific graphic object (see FCT-C15) [as of V3.01.3018.00] where < i>: 0 … 4

-

-

-

WZ_AKT.LINKPOINT.*

Access to the subelements of associated link points (see FCT-C15) [as of V3.01.3018.00]

-

-

-

S*: Write access to these current tool data as of CNC Build V3.1.3079.08

As an alternative to V.G.WZ_AKT.P[i], the following variables can also be used to access additional tool parameters. It is only available for an external tool management system:

V.G.WZ_INFO[i]

Parameters of the selected tool

L

Programing Example

prg_example

NC program with tool requesting

In the example below, the CNC replaces various tools and the data is requested by the external tool management system. The request always contains the free tool parameters of the last active tool for return transfer of updated values to the PLC.

%ext_wzv.nc

N10 X0 Y0 G91 G01 F1000

N20 T0 D0;report back free parameters by T<?>D<?>

;with request D0

N30 T1 D1;report back free parameters by T0&D0

;with request D1

N32 V.G.WZ_AKT.P[0] = 123

N40 T2

N50 T3

N60 T4

N70 D2;report back free parameters by T1&D1

;with request D2

N080 V.G.WZ_AKT.P[0] = 1

N090 V.G.WZ_AKT.P[1] = 2

N100 V.G.WZ_AKT.P[2] = 3

M30