0% found this document useful (0 votes)
61 views406 pages

Rexroth MTC 200 NC Programming Instructions

The document is an application manual for the Rexroth MTC 200 NC Programming Instructions, detailing the programming of NC functions for the MTC 200 controller family. It includes comprehensive sections on general information, NC program structure, motion commands, tool compensation, and other programming aspects. The manual serves as a technical reference for users to effectively utilize the MTC 200 controller in various applications.

Uploaded by

anthonylim425
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
61 views406 pages

Rexroth MTC 200 NC Programming Instructions

The document is an application manual for the Rexroth MTC 200 NC Programming Instructions, detailing the programming of NC functions for the MTC 200 controller family. It includes comprehensive sections on general information, NC program structure, motion commands, tool compensation, and other programming aspects. The manual serves as a technical reference for users to effectively utilize the MTC 200 controller in various applications.

Uploaded by

anthonylim425
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 406

Industrial Electric Drives Linear Motion and Service Mobile

Hydraulics and Controls Assembly Technologies Pneumatics Automation Hydraulics

Rexroth MTC 200 R911296998


Edition 01

NC Programming
Instructions
Application Manual

www.EngineeringBooksPdf.com
About this Documentation NC Programming Instructions

Title
Rexroth MTC 200
NC Programming Instructions
Type of Documentation Application Manual

Document Typecode DOK-MTC200-NC**PRO*V23-AW01-EN-P

Internal File Reference Document Number, 120-1701-B303-01/EN

Purpose of Documentation This documentation describes the programming of NC functions of


MTC 200 controller family.

Record of Revisions Description Release Notes


Date
Document Number, 120-1701-B303-01/EN 02/2004 Valid from Version 23

Copyright  2004. Bosch Rexroth AG


Copying this document, giving it to others and the use or communication
of the contents thereof without express authority, are forbidden. Offenders
are liable for the payment of damages. All rights are reserved in the event
of the grant of a patent or the registration of a utility model or design
(DIN 34-1).

Validity The specified data is for product description purposes only and may not
be deemed to be guaranteed unless expressly confirmed in the contract.
All rights are reserved with respect to the content of this documentation
and the availability of the product.

Published by Bosch Rexroth AG


Bgm.-Dr.-Nebel-Str. 2 • D-97816 Lohr a. Main
Telephone +49 (0)93 52/40-0 • Tx 68 94 21 • Fax +49 (0)93 52/40-48 85
http://www.boschrexroth.de/
Dept. BRC/ESM3 (GeVa, JoLi)
Dept. BRC/ESM6 (DiHa)

Note This document has been printed on chlorine-free bleached paper.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Contents I

Contents
1 General Information 1-1
1.1 Notes............................................................................................................................................. 1-1
1.2 Program and Data Organization ................................................................................................... 1-2

2 NC Program 2-1
2.1 Organization of Setup Lists........................................................................................................... 2-1
2.2 Program Structure ........................................................................................................................ 2-2
Advance Program .................................................................................................................... 2-3
Reverse Program .................................................................................................................... 2-3
2.3 Process-Specific Programming .................................................................................................... 2-4
2.4 Elements of an NC Block.............................................................................................................. 2-5
Block Numbers ........................................................................................................................ 2-5
Skipping Blocks ....................................................................................................................... 2-6
2.5 NC Word ....................................................................................................................................... 2-7
Branch Label............................................................................................................................ 2-8
Note ......................................................................................................................................... 2-8
Comment ................................................................................................................................. 2-9
Comment in the Source Program ............................................................................................ 2-9
2.6 Available Addresses ................................................................................................................... 2-10

3 Motion Commands, Dimension Inputs 3-1


3.1 Coordinate system........................................................................................................................ 3-1
3.2 Motion commands ........................................................................................................................ 3-2
3.3 Measurements .............................................................................................................................. 3-3
Absolute Dimension Entry "G90"............................................................................................. 3-3
Incremental Dimensions "G91"................................................................................................ 3-4
3.4 Offsets .......................................................................................................................................... 3-5
3.5 Zero offsets................................................................................................................................... 3-7
Adjustable Zero Offsets "G54 - G59"....................................................................................... 3-9
Coordinate Rotation with Angle of Rotation "P" .................................................................... 3-10
Zero Offset Tables "O"........................................................................................................... 3-11
Programmable Absolute Zero Offset "G50", Programmable Incremental Zero Offset
"G51" ..................................................................................................................................... 3-13
Programmable Zero Point of Workpiece "G52"..................................................................... 3-14
Cancel Zero Offsets "G53" .................................................................................................... 3-15
Adjustable General Offset in the Zero Offset Table .............................................................. 3-15
Read/Write Zero Offset Data from the NC Program via "OTD"............................................. 3-15
3.6 Level selection ............................................................................................................................ 3-16
Axis Number, Axis Designation and Axis Meaning ............................................................... 3-16

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
II Contents NC Programming Instructions

Plane Selection "G17", "G18", "G19" .................................................................................... 3-17


Free Plane Selection "G20", "G21", "G22" ............................................................................ 3-18
Boundary conditions .............................................................................................................. 3-20
Effects.................................................................................................................................... 3-20
3.7 Radius/Diameter Programming "G15" / "G16" ........................................................................... 3-24
3.8 Measurement units ..................................................................................................................... 3-25
Measurement Unit Inch "G70" ............................................................................................... 3-25
Unit Millimeters "G71"............................................................................................................ 3-26
3.9 Mirror Imaging of Coordinate Axes "G72" / "G73" ...................................................................... 3-27
3.10 Scaling "G78" / "G79" ................................................................................................................. 3-29
3.11 Go to Axes Reference Point "G74"............................................................................................. 3-31
3.12 Feed to positive stop................................................................................................................... 3-31
Feed to Positive Stop "G75" .................................................................................................. 3-32
Cancel All Axis Preloads "G76" ............................................................................................. 3-34
3.13 Traverse Range Limits................................................................................................................ 3-34
3.14 Repositioning and NC block restart to the contour ..................................................................... 3-36
Reposition and restart in the automatic operating modes..................................................... 3-36
Repositioning and Restarting to Destination Position "G77" ................................................. 3-37
3.15 NC Program Restart with "ADJUST" and "REPOS"................................................................... 3-38
Programming ......................................................................................................................... 3-38
Special NC-Specific Features in NC Program Restart .......................................................... 3-40
3.16 Adaptive Depth "G68" / "G69" .................................................................................................... 3-43
Application ............................................................................................................................. 3-43
New Axis Parameter.............................................................................................................. 3-43
nd
G Codes to Switch to a 2 Encoder System......................................................................... 3-44

4 Motion Blocks 4-1


4.1 Axes .............................................................................................................................................. 4-1
Linear main axes ..................................................................................................................... 4-1
Rotary Main Axes .................................................................................................................... 4-1
Linear and Rotary Auxiliary Axes ............................................................................................ 4-2
4.2 Interpolation conditions................................................................................................................. 4-2
Following Error-Free Interpolation "G06"................................................................................. 4-2
Interpolation with Lag Distance "G07" ..................................................................................... 4-5
Optimal Speed Block Transition "G08".................................................................................... 4-8
Velocity-Limited Block Transition "G09" ................................................................................ 4-10
Exact Stop "G61" ................................................................................................................... 4-12
Rapid NC Block Transition "G62" .......................................................................................... 4-14
Programmable Acceleration "ACC" ....................................................................................... 4-16
4.3 Interpolation functions................................................................................................................. 4-18
Linear Interpolation, Rapid Traverse "G00"........................................................................... 4-18
Linear Interpolation, Feed "G01" ........................................................................................... 4-19
Circular Interpolation "G02" / "G03"....................................................................................... 4-20
Helical Interpolation ............................................................................................................... 4-26
Thread Cutting "G33"............................................................................................................. 4-28
Thread Sequences with "G33" .............................................................................................. 4-32

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Contents III

Tapping without Compensating Chuck "G63" / "G64"........................................................... 4-34


Tapping "G64" - Speed Reduction ........................................................................................ 4-37
Tapping "G65" - Spindle as Lead Axis .................................................................................. 4-38
4.4 feed ............................................................................................................................................. 4-40
F Word ................................................................................................................................... 4-40
Time Programming "G93"...................................................................................................... 4-41
Velocity Programming "G94" ................................................................................................. 4-42
Feed Rate per Spindle Revolution "G95" .............................................................................. 4-42
Dwell Time "G04"................................................................................................................... 4-43
Basic Connections between Programmed Path Velocity (F) and Axis Velocities ................. 4-44
Feed Limitation ...................................................................................................................... 4-46
Adaptive Feed Control "G25" / "G26" ................................................................................... 4-47
4.5 Spindle speed ............................................................................................................................. 4-52
S Word for the Spindle Speed Specification ......................................................................... 4-52
Select Main Spindle "SPF" .................................................................................................... 4-53
Constant Grinding Wheel Peripheral Speed (SUG) "G66".................................................... 4-55
Constant Surface Speed "G96" ............................................................................................. 4-56
Spindle Speed Limitation"G92" ............................................................................................. 4-57
Additional Spindle Speed Limitations .................................................................................... 4-58
Spindle Speed in RPM "G97" ................................................................................................ 4-59
4.6 Rotary Axis Programming........................................................................................................... 4-60
Effective Radii "RX", "RY", "RZ" ............................................................................................ 4-60
NC Program Changeover between Spindle and C Axis........................................................ 4-61
Start-up Logic for Endlessly Rotating Rotary Axes ............................................................... 4-61
4.7 Transformations.......................................................................................................................... 4-63
Transformation Functions...................................................................................................... 4-63
Select Face Machining "G31"................................................................................................ 4-63
Selection of Lateral Cylinder Surface Machining "G32" ........................................................ 4-67
Deselection of Transformation "G30" .................................................................................... 4-70
Select Main Spindle for Transformation "SPC" ..................................................................... 4-70
4.8 Main Spindle Synchronization .................................................................................................... 4-71
Use of Main Spindle Synchronization.................................................................................... 4-71
Functions of Main Spindle Synchronization .......................................................................... 4-71
Permissible Configurations.................................................................................................... 4-72
Sequence of a Synchronization Operation............................................................................ 4-73
NC programming ................................................................................................................... 4-74
Machine Data for Main Spindle Synchronization................................................................... 4-74
4.9 Follower and Gantry axes........................................................................................................... 4-75
Applications of Follower and Gantry Axes............................................................................. 4-75
Permissible Configurations.................................................................................................... 4-76
Steps of a Follower Operation ............................................................................................... 4-76
Auxiliary Functions for Synchronized Operation ................................................................... 4-76
NC Programming................................................................................................................... 4-77
Machine Data for Synchronized Axis Groups........................................................................ 4-77
4.10 Rounding of NC Blocks with Axis Filter "G11" / "RDI" ................................................................ 4-78
Method of Operation.............................................................................................................. 4-78

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
IV Contents NC Programming Instructions

Programming ......................................................................................................................... 4-79


Limits and Special Regulations ............................................................................................. 4-80
4.11 Test Mode ................................................................................................................................... 4-81
Purpose ................................................................................................................................. 4-81
Suppress Auxiliary Function Output ...................................................................................... 4-81
Lock Axis and Spindles ......................................................................................................... 4-81
Test Feed............................................................................................................................... 4-82
Rapid Run.............................................................................................................................. 4-83
Online Simulation................................................................................................................... 4-83
Suppress Tool Transfer and Movements .............................................................................. 4-83

5 Tool Compensation 5-1


5.1 Setup Lists and Tool Lists............................................................................................................. 5-1
Setup List................................................................................................................................. 5-1
Tool List ................................................................................................................................... 5-2
Current Tool List ...................................................................................................................... 5-2
Equipment Check .................................................................................................................... 5-2
Operation without Setup List ................................................................................................... 5-4
5.2 Elements of the Tool Data Record ............................................................................................... 5-5
Overview.................................................................................................................................. 5-5
5.3 Basic Tool Data ............................................................................................................................ 5-6
Tool Identification..................................................................................................................... 5-7
Location Data......................................................................................................................... 5-30
Units....................................................................................................................................... 5-33
Technology Data.................................................................................................................... 5-33
User Tool Data....................................................................................................................... 5-34
Tool Group Data .................................................................................................................... 5-35
Other User Tool Data ............................................................................................................ 5-42
5.4 Tool Edge Data........................................................................................................................... 5-42
Tool Edge Identification ......................................................................................................... 5-44
Tool Life Data ........................................................................................................................ 5-53
Geometry Data ...................................................................................................................... 5-56
Geometry Limit Values .......................................................................................................... 5-60
Wear Factors ......................................................................................................................... 5-61
User Tool Edge Data ............................................................................................................. 5-63
5.5 Grinding Wheel-Specific Tool Data{0><}100{> .......................................................................... 5-64
Tool Code WGD DE 18 ......................................................................................................... 5-66
Representation Type WGD DE 19 ........................................................................................ 5-68
5.6 Tool Path Compensation ............................................................................................................ 5-68
Inactive Tool Path Compensation.......................................................................................... 5-68
Active Tool Path Compensation ............................................................................................ 5-69
Contour Transitions ............................................................................................................... 5-70
Establishment of Tool Path Compensation at Start of Contour............................................. 5-74
Removal of Tool Path Compensation at End of Contour ...................................................... 5-76
Change in Direction of Compensation................................................................................... 5-78
5.7 Activating and Canceling Tool Path Compensation ................................................................... 5-78

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Contents V

Canceling Tool Path Compensation "G40" ........................................................................... 5-78


Tool Path Compensation, Left "G41"..................................................................................... 5-79
Tool Path Compensation, Right "G42" .................................................................................. 5-79
Tool Path Correction G41, G42 Behind and Before the Turning Center............................... 5-80
Inserting an Arc Transition Element "G43" ............................................................................ 5-82
Inserting a Chamfer Transition Element "G44" ..................................................................... 5-82
Constant Feed on Tool Center Line "G98"............................................................................ 5-83
Constant Feed at the Contour "G99"..................................................................................... 5-84
5.8 Tool Length Compensation......................................................................................................... 5-84
No Tool Length Compensation "G47" ................................................................................... 5-85
Tool Length Correction, Positive "G48" ................................................................................. 5-85
Tool Length Correction, Negative "G49" ............................................................................... 5-86
5.9 Access to Tool Data from NC Program "TLD"............................................................................ 5-86
5.10 D corrections............................................................................................................................... 5-88

6 Auxiliary Functions (S, M, Q) 6-1


6.1 General Information on Auxiliary Functions.................................................................................. 6-1
6.2 "M" Auxiliary Functions ................................................................................................................. 6-1
Program Control Commands................................................................................................... 6-3
Spindle Control Commands..................................................................................................... 6-3
Spindle Positioning .................................................................................................................. 6-4
Gear Changes ......................................................................................................................... 6-5
6.3 S-Word as Auxiliary Function ....................................................................................................... 6-5
6.4 Q Function .................................................................................................................................... 6-5

7 Events 7-1
7.1 Definition of NC Events................................................................................................................. 7-1
7.2 Influencing Events ........................................................................................................................ 7-2
Set NC Event "SE"................................................................................................................... 7-2
Reset NC Event "RE" .............................................................................................................. 7-3
Wait until NC Event is Set "WES"............................................................................................ 7-3
Wait until NC Event is Reset "WER" ....................................................................................... 7-4
7.3 Conditional Branches for Events .................................................................................................. 7-5
Branch if NC Event is Set "BES" ............................................................................................. 7-5
Branch if NC Event is Reset "BER" ......................................................................................... 7-5
7.4 Asynchronous Handling of NC Events ......................................................................................... 7-6
Call Subroutine if Event is Set "BEV" ...................................................................................... 7-7
Program Branching if NC Event is Set "JEV" .......................................................................... 7-8
Cancel NC Event Monitoring "CEV" ........................................................................................ 7-8
Disable NC Event Monitoring "DEV" ....................................................................................... 7-8
Enable NC Event Monitoring "EEV" ........................................................................................ 7-8
7.5 Reading Events in Variable ........................................................................................................ 7-10

8 NC Functions to Control Tool Management 8-1


8.1 Conditions ..................................................................................................................................... 8-1
Default Plane ........................................................................................................................... 8-1

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
VI Contents NC Programming Instructions

Preparation of Tools and Tool Data......................................................................................... 8-2


8.2 Tool Storage Unit Motion Commands of the NC .......................................................................... 8-9
Tool Storage to Reference Position "MRF" ........................................................................... 8-10
Move Tool Storage Unit to Home Position "MHP"................................................................. 8-10
Programmed Move Tool into Position "MTP" ........................................................................ 8-11
Programmed Move Magazine Pocket into Position "MMP"................................................... 8-13
MTP/MMP Commands and Tool Correction ......................................................................... 8-14
Freely Position Tool axis "MMA" ........................................................................................... 8-15
Move to Free Position "MFP" ................................................................................................ 8-16
Move Old Pocket in Position "MOP"...................................................................................... 8-17
Wait until Position is Approached "MRY" .............................................................................. 8-19
Enable Tool Magazine (Storage) for Manual Mode "MEN" ................................................... 8-19
Moving Tool Storage Unit with Nonuniform Pocket Distribution............................................ 8-20
8.3 Tool Changing Commands of the NC......................................................................................... 8-21
Performing a Complete Tool Change "TCH"......................................................................... 8-22
Change the Tool from the Magazine to the Spindle "TMS"................................................... 8-23
Tool Change from Spindle to Magazine "TSM"..................................................................... 8-23
Magazine Pocket Empty? "TPE" ........................................................................................... 8-24
Tool Spindle Empty? "TSE"................................................................................................... 8-24

9 Process and Program Control Commands 9-1


9.1 Process Control Commands......................................................................................................... 9-1
Define Process "DP"................................................................................................................ 9-2
Select NC Program for Process "SP" ...................................................................................... 9-2
Start Reverse Program "RP" ................................................................................................... 9-3
Start Advance Program "AP"................................................................................................... 9-3
Wait for Process "WP"............................................................................................................. 9-3
Lock Process "LP" ................................................................................................................... 9-4
Process Complete "POK" ........................................................................................................ 9-5
9.2 Axis Transfer Between Processes "FAX", GAX" .......................................................................... 9-6
9.3 Program Control Commands ........................................................................................................ 9-9
Program End with Reset "RET"............................................................................................... 9-9
Branch with Stop "BST"........................................................................................................... 9-9
Programmed Halt "HLT" .......................................................................................................... 9-9
Branch Absolute "BRA" ........................................................................................................... 9-9
Jump to Another NC Program "JMP" .................................................................................... 9-10
9.4 Subroutines................................................................................................................................. 9-10
Subroutine Technique ........................................................................................................... 9-10
Subroutine Structure.............................................................................................................. 9-11
Subroutine Nesting ................................................................................................................ 9-11
Jump to NC Subroutine "JSR"............................................................................................... 9-11
Subroutine Call "BSR" ........................................................................................................... 9-12
Return from NC Subroutine "RTS" ........................................................................................ 9-12
9.5 Reverse Vectors ......................................................................................................................... 9-13
Set Reverse Vector "REV" .................................................................................................... 9-13
9.6 Conditional Branches.................................................................................................................. 9-16

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Contents VII

Branch if Spindle is Empty "BSE".......................................................................................... 9-16


Branch if T0 Was Set "BTE" .................................................................................................. 9-16
Branch upon Reference "BRF".............................................................................................. 9-16
Branch if NC Event is Set "BES" ........................................................................................... 9-16
Branch if NC Event is Reset "BER" ....................................................................................... 9-17
9.7 Branches Depending on Arithmetic Results ............................................................................... 9-17
Branch If Equal to Zero "BEQ" .............................................................................................. 9-17
Branch If Not Equal to Zero "BNE" ........................................................................................ 9-17
Branch If Greater Than or Equal to Zero "BPL" .................................................................... 9-17
Branch If Less Than Zero "BMI" ............................................................................................ 9-17
Overview Table...................................................................................................................... 9-18

10 Variable Assignments and Arithmetic Functions 10-1


10.1 Variables ..................................................................................................................................... 10-1
Variable Assignment.............................................................................................................. 10-2
10.2 Angle Unit for Trigonometric Functions "RAD", "DEG"............................................................... 10-5
10.3 Round Distance "RDI" ................................................................................................................ 10-6
10.4 Mathematical Expressions.......................................................................................................... 10-6
Operands ............................................................................................................................... 10-7
Operators............................................................................................................................... 10-7
Parentheses........................................................................................................................... 10-8
Functions ............................................................................................................................... 10-8

11 Enhanced NC Syntax (NC Control Structures) 11-1


11.1 Overview ..................................................................................................................................... 11-1
11.2 Conditions of the Control Structures........................................................................................... 11-2
11.3 Block Instructions........................................................................................................................ 11-3
11.4 IF Instruction ............................................................................................................................... 11-3
11.5 FOR Instruction........................................................................................................................... 11-4
11.6 WHILE Instruction....................................................................................................................... 11-4
11.7 REPEAT-UNTIL Instruction ........................................................................................................ 11-4
11.8 CONTINUE Instruction ............................................................................................................... 11-5
11.9 BREAK Instruction ...................................................................................................................... 11-5
11.10 SWITCH Instruction .................................................................................................................... 11-5
11.11 Conditions of the Control Structures........................................................................................... 11-6
11.12 Indexed NC Variables................................................................................................................. 11-7

12 Special NC Functions 12-1


12.1 APR SERCOS Parameters ........................................................................................................ 12-1
Data Exchange with Digital Drives "AXD" ............................................................................. 12-1
12.2 Read/Write Zero Offset (ZO) Data from the NC Program "OTD" ............................................... 12-4
12.3 Access to Tool Data from NC Program "TLD"............................................................................ 12-6
Examples: ............................................................................................................................ 12-15
12.4 Read/Write D Corrections from the NC Program "DCD" .......................................................... 12-19
12.5 Read/Write Machine Data......................................................................................................... 12-20
Purpose of Machine Data .................................................................................................... 12-20

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
VIII Contents NC Programming Instructions

Read/Write Machine Data Elements "MTD"........................................................................ 12-21


12.6 Possible Allocations between TLD, MTD, AXD, OTD, DCD .................................................... 12-22
Handling AXD Commands................................................................................................... 12-22
Handling OTD Commands .................................................................................................. 12-23
Handling TLD Commands ................................................................................................... 12-23
Handling DCD Commands .................................................................................................. 12-24
Handling MTD Commands .................................................................................................. 12-24
Allocations Between TLD, MTD, AXD, OTD and DCD Commands .................................... 12-25

13 NC Compiler Functions 13-1


13.1 Basics ......................................................................................................................................... 13-1
13.2 Chamfers and Roundings ........................................................................................................... 13-1
13.3 Macro Technique ........................................................................................................................ 13-3
Enhancing NC Functions by Macro Technique ..................................................................... 13-5
13.4 Modal Function ........................................................................................................................... 13-7
13.5 Enhanced Look-Ahead Function ................................................................................................ 13-9
13.6 Graphic NC editor ..................................................................................................................... 13-13

14 NC Programming Practices 14-1


14.1 Time-Optimized NC Programming ............................................................................................. 14-1

15 Appendix 15-1
15.1 Table of G Code Groups............................................................................................................. 15-1
15.2 Table of M Function Groups ....................................................................................................... 15-2
15.3 Table of Functions ...................................................................................................................... 15-2
I. G00 through G19............................................................................................................... 15-3
II. G20 to G38 ....................................................................................................................... 15-4
III. G40 to G59 ...................................................................................................................... 15-5
IV. G61 to G79...................................................................................................................... 15-6
V. G90 through G99 ............................................................................................................. 15-8
VI. ACC through BTE ........................................................................................................... 15-9
VII. CEV through MMP ....................................................................................................... 15-10
VIII. MOP through RTS....................................................................................................... 15-11
IX. SE through WP ............................................................................................................. 15-12
15.4 File Header ............................................................................................................................... 15-13
Cycle Header ....................................................................................................................... 15-14

16 Index 16-1

17 Service & Support 17-1


17.1 Helpdesk ..................................................................................................................................... 17-1
17.2 Service-Hotline ........................................................................................................................... 17-1
17.3 Internet........................................................................................................................................ 17-1
17.4 Vor der Kontaktaufnahme... - Before contacting us... ................................................................ 17-1
17.5 Kundenbetreuungsstellen - Sales & Service Facilities ............................................................... 17-2

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions General Information 1-1

1 General Information

1.1 Notes
A CNC (COMPUTER NUMERICAL CONTROL) is a special computer used to
control a machine tool, robot or transfer system. Like a personal com-
puter, the CNC controller has its own operating system, which is specifi-
cally designed for numerical applications, as well as so-called controller
software installed in this operating system.
The controller software translates the CNC program into a language
which the controller can understand.
Details relating to a particular CNC machine tool, robot, or transfer system
may be found in the machine builder's manual. The machine builder's
information takes precedence over the information provided in this Pro-
gramming Manual.
The programming examples are based on DIN 66025/ISO Draft 6983/2
along with the additional features implemented by Bosch Rexroth.
All geometric values are metric.
Combinations in the NC syntax and other functions which are not de-
scribed in this programming manual may also be executed on the con-
troller. However, we do not warrant the proper functioning of these com-
binations and functions upon initial shipment and in the event of service.
We reserve the right to make changes based on technical advancements.
These programming instructions apply to the MTC 200 control system as
of version 23VRS

Note: This type of field describes a specific functional response that


depends on the parameter settings. If the instructions given in
these notes are not followed, the function cannot be started or
there will be malfunctions during execution (error message).

This type of field provides information that is mandatory


for a faultless execution of the described functions. If the
instructions given in these notes are not followed, the
execution of the function may lead to serious errors in
CAUTION CNC processing, damage the machine or, in the worst
case, lead to personal injuries.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
1-2 General Information NC Programming Instructions

1.2 Program and Data Organization


Data structure of the CNC with user interface on an IBM PC and a mini
operating device BTV0x.

Data User Interface

NC
Program Parameter Tool
List Set List
Data BTV0x
Hard Disc
6
User 5
6 6 4 6
5 5 Inter- 3 6 5
4 4 face NC-Event 2 4
3 3 Liste für 5 3
6 6 1 4 6
NC List 2 Cur. Tool List 2 5
Prozeß 0 NC Event 2 5
5 for Process 3
List for 1
Process 1 4 1 4 2
NC-VariablenProcess 4
0 0 0
3 3 Liste für 1 3
NC Variable 2 Zero Point 2 Prozeß 0 NC Variable 2
List Process 1 for Process 1 MDI List for 1
0 0 Block Process 0
Entry

CNC Memory

Parameters

System Parameters . 20
3 4 . 5 6
2 3 4
Axis Parameter Axis 1
1 2 5 6
Process Parameter Process 0 3 4
1 2 5 6
Process Parameter Process 0 3 4
1 2 5 6
NC Events Process 0 3 4
1 2 5 6
NC Variables Process 0 3 4
1 2 5 6
NC Cycle Programme Process 0 3 4
D Corrections Process 0 1 2

NC-Program Memory A NC-Program Memory B

6 6
5 5
4 4
3 3
2 2
Zero Points 1 Zero Points 1
for Process 0 6 for Process 0 6
5 5
4 4
Data for 3 Data for 3
2 2
Process 0 1 Process 0 1
Setup List Setup List
NC-Program NC-Program
Nr. 1 Nr. 1
. .
Nr. 99 Nr. 99

11Daten.FH7

Fig. 1-1: CNC data organization

Approximately 400 kB available memory is present on the basic version of


the CNC. As shown in the figure above, the CNC memory is divided into
several areas. The individual areas are described briefly in the following
sections.
The CNC controller is adapted to the given machine or system by means
of parameters. Up to 99 different parameter sets can be managed via the
user interface.
The parameters are divided into the following areas:

System parameters The system parameters define how many processes and axes need to be
managed by the CNC controller as well as what type of tool management
system is present.

Axis parameters The process-specific axes are specified in the axis parameters. The axis
is assigned to specific processes in the axis parameters and the corre-
sponding axis limit data—for example, maximum axis speed, travel lim-
its—are defined here.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions General Information 1-3

Process parameter The process-specific data, for example the default plane, programmable
and maximum displayable places to the right of the decimal point, maxi-
mum speed for contour mode, etc. are specified in the process parame-
ters.
A detailed description of the system, process and axis parameters may be
found in the parameter description
(DOK-CONTRL-PAR*DES*V23-AW0x-EN-P).

Tool List The tool list for a process contains the actual tool data for all tools as-
signed to the process; it therefore represents an image of the magazine
which is present at the station. Up to 99 different tool lists can be man-
aged via the user interface. The NC commands for tool handling are de-
scribed in the "Commands for Tool Management" chapter. A complete
description of all data and functions relating to tools is provided in the
document "Tool Management"
(DOK-MTC200-TOOLMAN*V23-PR0x-EN-P) and in the
"Tool Management" user description
(DOK-MTC200-TOOLMAN*V23-AW0x-EN-P).

NC events NC events are binary variables which can be used by the NC program. A
detailed description of NC events and event-dependent functions is pro-
vided in the "NC Events" chapter.

NC variables An NC variable represents a changeable numerical value. A total of 1792


NC variables are available in the CNC (256 NC variables for each proc-
ess). The section "Variable Assignment and Mathematical Functions"
provides a detailed description of what can be accomplished with NC
variables.

NC cycle programs A specific memory area is available in the CNC for NC cycle programs
supplied by the machine builder and Bosch Rexroth. Additional informa-
tion on NC cycle programs is provided in the manual on "NC Cycles."
(DOK-MTC200-CYC*DES*V22-AW0x-EN-P).

D corrections D corrections are additional active registers for the tool geometry data. D
corrections act in an additive manner relative to the existing geometry
registers L1, L2, L3 and R. D corrections can be used if tool management
is present, e.g. as tool reference point offset registers. 99 D corrections
are available for each of the 7 processes of the CNC. Each D correction
contains the L1, L2, L3 and R registers. The assignment of values in the
D correction register can be accomplished by using the CNC user inter-
face or the BTV0x.

NC program package An NC program package contains all necessary Tool Setup Lists (tool
specifications data) and NC programs of all processes used in the ma-
chining work. Up to 99 different NC program packages can be managed
via the user interface. Dividing the NC memory into two areas, A and B,
permits two NC program packages to be managed simultaneously in the
CNC. The decision which of the two NC program packages is to be exe-
cuted is made by the operator via the user interface or via the PLC. While
one NC program package is already running, a second NC program
package can be loaded into the controller's memory. This will overwrite
any NC program package that may already be present in the controller.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
1-4 General Information NC Programming Instructions

NC Program Package 1 ... 99


6
5
4
3
12
Data for Process 0
Setup List(Optional)
NC Program 1
NC Program 99

12Paket.FH7

Fig. 1-2: NC program package

Setup list The tool setup list contains a tool data set for each T number used in the
NC program. This tool data set defines which tool is to be used and which
specifications this tool must meet. If the machine tool builder determines
that a setup list is not required, the T number, together with its corre-
sponding data set, is used in the tool list. The setup list should be entered
before creating the program, however no later than during creation of the
program. Additional information on the setup list is provided in the docu-
mentation "Tool Management"
(DOK-MTC200-TOOLMAN*V23-PR0x-EN-P).

Offsets The CNC provides up to 60 zero points (10x G54-G59) for each process.
The zero points are assigned to the currently active 'A' or 'B' NC program
memory in the CNC memory. Entries in the zero point table in the opera-
tor interface are always assigned to the currently active NC program
memory.
See also the section "Zero Offsets".

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions NC Program 2-1

2 NC Program

2.1 Organization of Setup Lists


A tool setup list can be created for any process which uses a tool. This list
allows any tool name or tool number to be assigned to the T numbers
used in the NC program. The Setup list also contains the tool specification
data. Setup lists can be organized to be station-specific or program-spe-
cific.

Station-specific organization Up to 7 tool setup lists (1 per process) are possible (organized in the NC pro-
gram package).

Program-specific organization Up to 693 tool setup lists (7 processes x 99 tool setup lists) are possible.

NC Program Package <xx> NC Program Package <xx>

Process 6 Process 6

Process 2 Process 2

Process 1 Process 1

Process 0 Process 0
NC Program 1 Setup List 1 NC Program 1 Setup List

NC Program 2 Setup List 2 NC Program 2

NC Program 3 Setup List 3 NC Program 3

NC Program 99 Setup List 99 NC Program 99

Program specific Organization Form Station specific Organization Form


of the Setup Lists of the Setup Lists
Pakete.FH7

Fig. 2-1: Setup lists in program- and station-specific organization

When a program-specific organization of the Setup lists is used, the size


of the program memory available to NC programs is decreased!

Note: The station- or program-specific setup lists are defined in the


system parameters.
The machine builder must declare in the PLC program
whether the CNC will work with or without setup lists.

The setup list should be completed when the NC program is written, but
no later than when the NC program is transferred into the system. This is
the only way that names referencing T numbers in the NC program can
be meaningful. The final assignment of the tools which are located in the
tool magazine to the T numbers used in the program is made when the
program is initiated (optional tool check).

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
2-2 NC Program NC Programming Instructions

2.2 Program Structure


The NC program and its command set is based on DIN 66025 / ISO Draft
6983/2 and is supplemented by the specific Bosch Rexroth extensions.
Each NC program package can contain up to 99 NC programs for each
process. Thus, an NC program package can consist of 693 NC programs
(7 processes x 99 NC programs). Each NC program can consist of up to
500 NC blocks.

N C P ro g ra m Me m o ry B
N C P ro g ra m Me m o ry A

N C -P ro g ra m 0 4

Advance P rogram

N C -C yc le Me m o ry
Reverse P rogram
P ro g ra m N o . 9 9 P ro g ra m m N o . 0

Bosch Rexroth
User C ycles and and Machine
S ubroutines of the S ubroutines Builder´s
Advance and Reverse S ubroutines and
P rogram C ycles

23Ncorg.FH7

Fig. 2-2: NC program organization

An NC program can contain both


• the advance and
• the reverse program for an operation.
Only one NC program can be loaded into the CNC memory.
If subroutines for the reverse program are not found in the current NC
program, a search using the number 99 is automatically performed in the
NC program. If the subroutine for the cycle is not located in program
number 99, a search is performed in program number 0.

Program No. 99 Program number 99 is suitable for frequently used program modules such
as user cycles, the tool change subroutine or the reverse program.

Program No. 0 Program number 0 is reserved for the Bosch Rexroth machining cycles
and for the machine builder's cycles. A detailed description of the Bosch
Rexroth machining cycles is provided in the documentation "NC cycles".
NC programs are assigned to a given process:
• The NC program assigned to process number 0 (management
process) is called a parts program.
• The NC programs for processes 1 to 6 are called process programs.
If a system consists of a number of processes, the parts program in proc-
ess 0 handles the coordination of all the other processes.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions NC Program 2-3

Advance Program
An advance program consists of a complete sequence of NC blocks
needed to produce a workpiece. In addition to the path information
needed for machining, the advance program also contains all additional
auxiliary functions and branch/jump commands for subroutines and cy-
cles.
The advance program ends with the NC block in which RET (end of pro-
gram with reset) is programmed.

Example
T4 BSR .M6 Tool change SF D50
T8 MTP Next machining tool
G00 G90 G54 X0 Y0 Z50 S5000 M03 Home position
G01 X46 Y144 Z2 Pos. at safety distance
.
.
RET

Reverse Program
A reverse program consists of a complete series of NC blocks which de-
scribe an operation sequence that is to be performed to establish the ref-
erence or home position of a station, regardless of how complicated the
required traverse movement may be. As a rule, a reverse program is pro-
grammed in program number 0 or number 99 so that it can be used as a
subroutine to establish the reference point or home position of a station or
machine.
The reverse program begins with the NC block in which the label .HOME
is programmed. Other entry points for the reverse program can be de-
fined in the advance program with the assistance of reverse vectors (see
chapter 9 "Commands for controlling processes and programs").
If reverse programming is done in a systematic manner without any omis-
sions, the operator can extract the station(s) or the machine from the
most complicated machining situations and return to the initial position in
the event of errors or malfunctions or in any given EMERGENCY STOP
situation. This is done safely and without the risk of collision.

Example
.HOME Global homing
MRF Move tool magazine to reference position
D0 Cancel D corrections
G40 G47 G53 G90 Cancel corrections
G74 Z0 F1000 Move Z-axis to reference position
G74 X0 Y0 F1000 Move X and Y axis to referencing position
RET

Note: It is not necessary to program a reverse program unless the


machine builder has specified in the process parameters that a
reverse program must be programmed.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
2-4 NC Program NC Programming Instructions

2.3 Process-Specific Programming


{0><}100{>The CNC is organized into a maximum of 7 processes. Each
process has its own NC block preparation which combines the data from
the NC program with data such as zero points, setup lists, etc.
The number of processes is declared in the system parameters. If more
than 2 processes are declared, process 0 is generally used to synchro-
nize the other processes.

Example
Use of a number of processes on a double-slide single-spindle lathe with
a milling head:
• Process 0
Synchronization of processes 1 and 2. Coordinates whether the proc-
esses work simultaneously and asynchronously or synchronously.
• Process 1
Process 1 contains the X and Z axes for the upper turret head.
• Process 2
Process 2 contains the X and Z axes for the lower turret head, main
spindle S1, the C axis, and spindle S2 as the driven tool spindle.

P ro cess 1

P ro g ra m N o . 1 0
N 0000 G90 G54 G18
N 0 0 0 1 G0 0 X2 0 Z0
. X
.
N 0 0 xx M0 3 0

P ro cess 0

P ro g ra m N o . 1 0
P rocess 1
N 0 0 0 0 .S TART
N 0 0 0 1 DP 1 DP 2
N0002 SP1 10
N0003 SP2 10 C S1
N 0 0 0 4 AP 1 AP 2
.
N 0 0 78 WP 1 WP 2

P rocess 2

P ro cess 2

P ro g ra m N o . 1 0
N 0000 G90 G54 G18 Z
N 0 0 0 1 G0 0 X2 0 Z0
.
.
N 0 0 xx M0 3 0
X
S2

24Dopp.FH7

Fig. 2-3: Double-slide single-spindle lathe for milling work

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions NC Program 2-5

2.4 Elements of an NC Block


{0><}100{>An NC block contains data to perform an operating step. The
NC block consists of one or more words as well as the NC control com-
mands. The NC block length may not exceed 240 characters; it can be
split in no more than four lines.
An NC block is comprised of the following elements:
• Block number,
• Branch label,
• NC words (NC control command(s)),
• Message,
• Remark in the program, and
• Remark in the source program.

Structure of an NC block:

N0020 G54 G01 X50 Y60 F2000 S1500 M03


Program con- Correction Traverse Geometry Technology instruction Auxiliary function
trol command call statement instruction
Block No. NC words (NC control commands)
Fig. 2-4: Structure of an NC block

Note: All the elements of an NC block except for function assign-


ments must be separated by at least one space.

The priority for the processing of an NC block in the NC memory is as


follows (priority dropping from left to right):

Block Branch Axis IPO Aux. Tool Process Program


number label G codes Variables values para- F value S value function comm- Events comm- comm-
meter ands ands ands
N1234 .ENDE G01 @100=x X100 I0 F1000 S800 M03 MTP T6 SE 5 DP 1 HLT
Y100 J50

Fig. 2-5: Priority for processing an NC block

Block Numbers
Syntax N× × × × × = 0-9
Each NC block begins with the letter N followed by a signless, 4-digit
decimal integer figure as a block number. The numbering of NC blocks in
an NC program always starts with N0000. The numbering of NC blocks is
automatically generated by the user interface in steps of 1.
When NC blocks are inserted via the user interface, all subsequent NC
blocks are automatically renumbered.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
2-6 NC Program NC Programming Instructions

Skipping Blocks
In an NC-controlled machine tool, a simple way must be provided to skip
NC blocks so that certain functions such as measuring operations, part
loading and unloading and the corresponding program NC blocks can be
allowed to proceed in a controlled manner or can be skipped.
Blocks in a subprogram which are not to be processed each time the pro-
gram is executed must be identified by a slash "/" at the beginning of the
NC block.

Note: These blocks are only not processed when the user activates
the skip function by pressing the "Skip NC block" machine
control key.

Example
G01 X20 F400
; Additional measurement cross point
/ G00 X300 M03 S6500
/ G01 Z45 F100
/ G00 X370 M05
/ HLT

In cyclical mode, the CNC skips a series of NC blocks if the operator acti-
vates the skip function before the first NC block in this sequence is proc-
essed. If the user presses the "Skip NC block" machine control key while
a sequence of NC blocks containing the skip marks is being processed,
this will have no effect on processing in cyclical mode. The CNC contin-
ues to process regardless of this action.
During single-block processing mode, the CNC checks whether the skip
function is active at the beginning of each NC block. In contrast to cyclical
mode, this gives the user the opportunity to control which individual NC
blocks are skipped.

Slash marks used to skip NC blocks stop NC


block preparation.
Thus, contour mode is not possible if NC blocks are
CAUTION marked to be skipped.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions NC Program 2-7

2.5 NC Word
The NC word contains the DIN 66025 instructions and various specific
Bosch Rexroth enhanced commands.
The NC word is divided into:

Function Enhanced commands


Geometric instructions Axis positions X__ Y__
Technology instructions Spindle speed Feed S__ F__
Traverse instructions Rapid traverse, circular interpolation G__ G__
Auxiliary functions Coolants, tools M__ T__
Override calls Tool overrides, zero points G__ G__
Enhanced functions Conditional branch/jump, calculations

A word is comprised of the address letter and the numerical value of


which the specific machine motions and auxiliary functions are to be initi-
ated.

Address letter The address letter is generally a text character.

Numerical value The numerical value can have signs and decimal points. The sign is lo-
cated between the address letter and the numerical value. A positive sign
does not need to be entered.

Word Format
Address Letter Value

X 500
Extended Address Format
Address Letter No. Space Value

S 1 1000
25Wort.FH7

Fig. 2-6: Word syntax

Example:

; Enhanced address structure for an X1 and Y1 axis


G01 X1 50.45 Y1 35.456 F1000 Thread position 1
Z10 Z to safety distance
st
M103 S1 1000 1 spindle 1000 RPM

Note: There must be a blank between the address and the numeric
value to be assigned.

The decimal point is set to achieve the resolutions shown below:


X0,00001 = 0.01 µm
X0,0001 = 0.1 µm
X0,001 = 1 µm
etc.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
2-8 NC Program NC Programming Instructions

Leading or following zeros can be ignored in the decimal point format.


Decimal point entry is possible in the following addresses:
Address letters: I, J, K, P, S, F, contents of @xxx

Note: The maximum number of digits to the right of the decimal


point, which can be programmed, is set in the process pa-
rameters.

Branch Label
Syntax .× × × × × × × = 0-9 , A-Z , a-z
A branch label points to a single branch label in a destination NC block. A
branch label is always present twice, once in the NC block in which the
branch occurs and once in the destination NC block to which the branch
is to be performed. A label always marks a program branch, regardless
whether the branch is conditional or unconditional.
The single branch address (destination label) may be in the same NC
program. If the single branch address is not found, it will be searched for
at first in program No. 99 and then in program No. 0.
In terms of syntax, the label begins with a decimal point followed by at
least one and no more than six visible characters. The syntax does not
differentiate between lower-case and capital letters. When a label is pro-
grammed in an NC block, the label must be the first element in the NC
block after the number.

Note: Certain branch labels are reserved by their names for the
Bosch Rexroth fixed cycles and for those of the machine
builder. The "*" sign following the decimal point is reserved for
Bosch Rexroth fixed cycles. A branch command using a label
is considered to be a program control command and is per-
formed last based on its priority. Machine movements in an
NC block are performed before a branch label.

Example
G54 G90 G00 X0 Z0
G04 F5
BSR .END
RET
.END
M05
G04 F1
RTS

Note
Syntax [ Text ]
Each NC block can contain a message, which will be displayed in the
diagnostic menu (station window) in the user interface at the end of NC
block processing. The note in the diagnostics line remains active until it is
overwritten by a new note. A so-called blank message must be pro-
grammed in order to clear the current message in the NC diagnostics line.
The message is also cleared from the NC diagnostics line when a pro-
gram is initiated. An NC block cannot contain more than one message.
A message is written in square brackets. It may not exceed a length of 48
characters. All ASCII characters may be used. The message can be in-

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions NC Program 2-9

serted at any location in the NC block; however, with the exception of the
comment, it is always the last function to be executed.

Example:
G01 G54, G90 [ Traverse X to safety distance ] F1000
X500
[ Traverse Z to safety distance ] G01 G51 G90 F1000
Z100

Comment
Syntax ( Text )
Each NC block can contain a comment. A comment is written in paren-
theses. It may not exceed a length of 80 characters. All ASCII characters
may be used. The comment can be inserted at any desired location in the
NC block. The comment is transferred to the controller memory and is
shown in the current NC block display.
An NC block cannot contain more than one comment and one message.

Example
G00 (Move X to start position) X150
(Move Z to start position) G01 Z10

Restriction Messages and hints must not be programmed between individual G


functions.

Comment in the Source Program


Syntax ; Text
Each NC block can contain one comment in the source program; this is
introduced by a semicolon. All characters following the semicolon are
interpreted as a comment. The term "comment in the source program"
means that the comment is only present in the source program—that is,
in the user interface—and not in the controller memory. Compared to
messages and comments, this type offers the advantage of saving mem-
ory space in the controller.
If a semicolon is used at the very beginning of an NC block, the entire NC
block is marked as a comment and an NC block number is not assigned.

Example
th
G01 X250 Y100 F1000 6 drilling position
; Call centered drilling cycle
BSR .*ZENBO

Restriction Comments in the source program must not be programmed between indi-
vidual NC words.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
2-10 NC Program NC Programming Instructions

2.6 Available Addresses


Address letters available in the CNC:
A Reserved for axis name P Angle
B Reserved for axis name Q Auxiliary M function
C Reserved for axis name R Radius
D Corrections S Spindle speed / position
E Tool edge number T Tool number
F Feed U Reserved for axis name
G G Function V Reserved for axis name
H Free W Reserved for axis name
I Interpolation parameters X Reserved for axis name
J Interpolation parameters Y Reserved for axis name
K Interpolation parameters Z Reserved for axis name
L Free @ Variables
M Auxiliary M function RX Nominal radius around X
N Block number RY Nominal radius around Y
O Zero offset table RZ Nominal radius around Z

An expanded address syntax is provided for the following addresses:


A(1-3) Reserved for axis name B(1-3) Reserved for axis name
C(1-3) Reserved for axis name U(1-3) Reserved for axis name
V(1-3) Reserved for axis name W(1-3) Reserved for axis name
X(1-3) Reserved for axis name Y(1-3) Reserved for axis name
Z(1-3) Reserved for axis name S(1-3) Spindle speed / position
Fig. 2-7: Address letters available in the CNC

The NC syntax is not case sensitive; no distinction is made between up-


per and lower case. This means that "x400" can be used instead of
"X400" when programming an axis position. However, for the sake of
legibility, it is generally a good idea to write NC commands in upper case
characters.
The full ASCII character set may be used for hints and messages.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-1

3 Motion Commands, Dimension Inputs

3.1 Coordinate system


The coordinate system defines the location of a point or a series of points
in a plane or in space in relation to two or three NC axes.
As a rule, the right-hand, orthogonal Cartesian coordinate system having
the axes X, Y and Z is used in NC technology. This system relates to the
main axes of the machine.

Y B Y
+ -
R
C
-
+ + A
Z X - X
Z
31Koord.FH7

Fig. 3-1: Coordinate system

All other axes relate to these 3 main axes. A, B and C are rotary or pivot-
ing axes having X, Y or Z as their center axes.
The A axis rotates about the X axis, the B axis rotates about the Y axis,
and the C axis rotates about the Z axis. The positive direction of rotation
of rotary axes corresponds to clockwise rotation when viewed in the posi-
tive axis direction. The direction of rotation and the orientation of the axes
with respect to each other result from the right-hand rule (see Fig. "Right-
hand rule").
With milling machines, the main axes are generally named X, Y and Z.
With lathes, the names are defined as Z and X.

Note: The axis names can be freely defined via the axis parameters.

Y-Axis

Z-Axis X-Axis

positive direction
of rotation
C -Axis

Z-Axis

32Hand.FH7

Fig. 3-2: Right-hand rule

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-2 Motion Commands, Dimension Inputs NC Programming Instructions

3.2 Motion commands


The path command or movement instruction causes an axis to move. The
path command consists of the address letter of the axis address (for ex-
ample, X, Y or Z) followed by the sign (+, -) to indicate the direction of
movement, and the distance to be traveled, the coordinate value.

Syntax

Syntax :
Address Letter Coordinate Value

Z 100.5
Address Letter Equal Sign Variable

X = @80
Address Letter Space Coordinate Value

X1 245.65
32Weg.FH7

Fig. 3-3: Syntax for motion commands

Examples:
Z105.5 or
Z=105.5 or
Z105.5
X= @80
X1 245.65

The coordinate value is comprised of:


• the sign,
• 6 or 5 digits to the left of the decimal point,
• the decimal point
• 4 or 5 digits to the right of the decimal point.

If no sign is programmed, the coordinate value is considered to be posi-


tive. If the coordinate value only has digits to the left of the decimal point,
the decimal point does not need to be entered. Leading or following zeros
can be ignored.
If a decimal point is programmed, at least one digit to the right of the
decimal point must be stated.
The number of digits to the left and right of the decimal point may not
exceed 10 digits.
In the notation using four digits to the right of the decimal point, the maxi-
mum value range for coordinates is:
-214748.3648 to +214748.3647
or with five digits to the right of the decimal point:
-21474.83648 to +21474.83647

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-3

3.3 Measurements
The path commands for the axes can be entered in two different ways:
• as an absolute dimension entry (G90) or
• as an incremental dimension entry (G91).

Absolute Dimension Entry "G90"


In absolute dimension entry, all dimensions stated relate to a fixed zero
point. When the CNC program boots, the initial setting is G90. G90 re-
mains in effect until it is overwritten with G91. In the NC program, G90
only needs to be programmed to cancel G91.

Syntax G90

Example:

Y
100
[P2] [P3]
80

60
[P1] [P4]
40

20

20 40 60 80 100 120 140


X
32Absol.FH7

Fig. 3-4: Absolute dimension entry

NC program:
G00 G90 G54 X0 Y0 Z10 S1000 M03 Start position
G01 X50 Y50 F500 [P1]
BSR .DRILL Branch to drilling subroutine
Y80 [P2]
BSR .DRILL Branch to drilling subroutine
X100 [P3]
BSR .DRILL Branch to drilling subroutine
Y50 [P4]
BSR .DRILL Branch to drilling subroutine
M05 Spindle OFF
RET Program end
.DRILL Drilling subroutine
G01 Z-10 F300 Drill to depth Z
G04 F2 Dwell time 2 seconds
G00 Z3 Return to safety distance
RTS End subroutine

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-4 Motion Commands, Dimension Inputs NC Programming Instructions

Incremental Dimensions "G91"


Incremental positioning defines all subsequent dimensional entries as
differences relative to the NC block starting position.

Syntax G91
G91 remains in effect until the end of the program or until it is overwritten
by G90.

Note: The distance that has been programmed for an axis using
G91 refers to the last absolute position. If the program coordi-
nate system is altered by shifting, rotation, mirroring, tool cor-
rection changes or after axis changeovers (G30, G31, G32, C
axis) and axis transfers, the axis must be positioned absolutely
before G91 or G90 are utilized.

Example:

Y
100
[P2] [P3]
80

60
[P1] [P4]
40

20

20 40 60 80 100 120 140


X
33Inkre.FH7

Fig. 3-5: Absolute dimension entry

NC program:
G00 G90 G54 X0 Y0 Z3 S1000 M03 Start position
G01 G91 X50 Y50 F500 [P1]
BSR .DRILL Branch to drilling subroutine
Y30 [P2]
BSR .DRILL Branch to drilling subroutine
X50 [P3]
BSR .DRILL Branch to drilling subroutine
Y-30 [P4]
BSR .DRILL Branch to drilling subroutine
M05 Spindle OFF
RET Program end
.DRILL Drilling subroutine
G01 Z-13 F300 Drill to depth Z
G04 F2 Dwell time 2 seconds
G00 Z13 Return to safety distance
RTS End subroutine

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-5

3.4 Offsets
Zero points and various reference points used to establish workpiece
geometry are defined on all numerically controlled machines.

Machine zero point The machine zero point is located in a fixed position at the origin of the
machine coordinate system and cannot be moved.

Icon for the machine zero point

M
34Masch.FH7

Fig. 3-6: Icon for the machine zero point

Machine reference point The machine reference point is a defined point located within the working
range of the machine. It is used to establish a defined initial position after
the machine is powered on. The machine builder in each axis in which
incremental positioning is used establishes the machine reference point.

Icon for the reference point

R
34Refer.FH7

Fig. 3-7: Icon for the reference point

Note: The reference dimensions are set in the drive parameters.

Workpiece zero point The workpiece zero point is the origin of the workpiece coordinate system.
As the program zero point, which the programmer establishes, it is used as
the basis for all workpiece dimensions. The reference to the machine zero
point is established by the zero offset value when the machine is set up.

Icon for the workpiece zero


point

W
34Werk.FH7

Fig. 3-8: Icon for the workpiece zero point

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-6 Motion Commands, Dimension Inputs NC Programming Instructions

Examples:

Y R
Table

Workpiece

M X
34Null.FH7

Fig. 3-9: Zero points – drilling/milling machines

M W

35Nulld.FH7

Fig. 3-10: Zero points – lathe (machining ahead of the center of rotation)

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-7

3.5 Zero offsets


The zero offsets permit the origin of a coordinate axis to be offset by a
given value relative to the machine zero point. The position of the ma-
chine zero point is permanently stored in the CNC memory and is not
changed by the zero offset.

Z' Z

Z
Angle of Rotation ’P’
P for the active
Plane (G18)
Y
X'
P

’ZO’Zero X
Offset
Y

X
36Nullv.FH7

Fig. 3-11: Zero offsets

The following zero offsets are provided in the CNC:


• Programmable absolute zero offset G50,
• Programmable incremental zero offset G51,
• Programmable workpiece zero point G52,
• Adjustable zero offsets G54 - G59
• Adjustable general offset in the zero offset table.

Using zero offsets G50, G51 and G54 to G59 and workpiece zero point
G52, the coordinate zero point of every NC axis can be applied to any
desired coordinate position within or beyond the individual range of
movement. It is thereby possible to process an identical NC program at
different machine positions.
The position of the machine zero point of each axis is specified in the
drive parameters as the difference in relation to the reference point. The
value entered in the drive parameters corresponds to the coordinate value
of the reference point in the machine coordinate system.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-8 Motion Commands, Dimension Inputs NC Programming Instructions

Adjustable Zero Programmable Offset of


Offset Workpiece Offset; Maschine
Setting via NC Program Coordinate System
Memory B
9
MemoryA Nullpunkt- 8 Memory B Memory B
bank 0 bis 9
Programmable Machine
92 Memory ACoordinate System
Offset 81
Memory A WWorkpiece point
Page
0 to 9
NC- G53 Machine
2 0 G52 Setting via
Programmable
NC-Programm
Prg

G53 Coordinate
G54 bis1G59 Workpiece System
0
G52 Offset
NC-
Prg

G54 ...
G59
Allgemeiner
General Offset
Offset

Variant 1 Variant 2 Variant 3

+ G50 Absolute
Zero Offset
NC-
Prg
Programmable, absolute
and incremental
zero offset.

Setting via NC program.

+ G51 Incremental
Zero Offset
NC-
Prg Deselection via selection of a
new zero offset or via G53

Complete Zero Offset

Sum 1: Sum 2: Sum 3:


1 + G50 + G51 2 + G50 + G51 3 + G50 + G51
nullpunkt_MTC.FH7

Fig. 3-12: Sum of zero offsets

The sum of zero offsets is made up of the adjustable zero offsets G54 -
G59 or the programmable workpiece zero point G52 and the programma-
ble zero offsets G50, G51 as well as the adjustable general offsets in the
zero point table.

Note: The programmable zero offsets G50 and G51 become inactive
when G52, G53, G54 - G59 are programmed. G59 inactive.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-9

Adjustable Zero Offsets "G54 - G59"


The adjustable zero offsets are entered in the zero offset table for those
axes which are present using the user interface. The entered values func-
tion as an absolute offset relating to the machine zero point. It is included
in the same NC block after the programming of G54 - G59 if the con-
cerned axis is programmed. G54 - G59 are cancelled by G53 or G52.

Syntax G54 - G59


• Depending on the settings in the process parameters, one of the ad-
justable zero offsets G54 - G59 may be the power-on status and
default when the NC program is started. G59 default state and basic
position during the NC program start.

Example:

Y 100 Y
[P5]
80 [P4]
80 [P3]
60 [P2]
40
60 20

40
[P1] 20 40 60 80 100 120 X
Enter in the Zero Offset
Table in the User Interface
with G54: X52.1 Y48.8

20

20 40 60 80 100 120
X
38G54ein.FH7

Fig. 3-13: Adjustable zero offset G54

NC program:
G00 G90 G54 X0 Y0 Z10 S1000 M03 Starting position [P1]
G01 X50 Y50 F1000 [P2]
BSR .DRILL Branch to drilling subroutine
X70 Y60 [P3]
BSR .DRILL Branch to drilling subroutine
X90 Y70 [P4]
BSR .DRILL Branch to drilling subroutine
X110 Y80 [P5]
BSR .DRILL Branch to drilling subroutine
M05 Spindle OFF
RET Program end
.DRILL Drilling subroutine
G01 Z-10 F300 Drill to depth Z
G04 F2 Dwell time 2 seconds
G00 Z3 Return to safety distance
RTS End subroutine

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-10 Motion Commands, Dimension Inputs NC Programming Instructions

Coordinate Rotation with Angle of Rotation "P"


Coordinate rotation adapts the coordinate system of the workpiece to the
coordinate system of the machine. Rotation angle P is related to the indi-
vidual zero offsets G54 - G59, G50, G51 and the adjustable general offset.
Coordinate rotation is always active in the active plane (for example G17).
For adjustable zero offsets G54 - G59 and for the general adjustable offsets,
the rotation angle is entered via the user interface into the zero point tables by
using the expression PHI.
The angle of rotation is programmed using address Pxxx with program-
mable zero offsets G50 and G51.

Syntax G50-G51 P<angle>


• The total of all active rotational angles is subject to the same condi-
tions as with the zero offsets.
• As a rule, the angle of rotation is not active until the next active NC
block.
• The angle of rotation is calculated in the control as a modulo value
from 0° to 360°. This means that a programmed angle of, for example
540°, is calculated as 180°.
• Coordinate rotation cannot be programmed with the programmable
workpiece zero point G52.

Example:

Y
[P3]
80 Y
[P2] X
60

40 P1
Enter in the Zero Offset
Table in the
User Interface
with G54 :
20 X52.1 Y40 PHI 45°

20 40 60 80 100 120 X
39G54koor.FH7

Fig. 3-14: Adjustable zero offset G54 with coordinate rotation

NC program:
G00 G90 G54 X0 Y0 Z10 S1000 M03 Starting position [P1]
G01 X40 Y70 F800 [P2]
BSR .DRILL Branch to drilling subroutine
X80 [P3]
BSR .DRILL Branch to drilling subroutine
M05 Spindle OFF
RET
.DRILL Drilling subroutine
G01 Z-10 F300 Drill to depth Z
G04 F2 Dwell time 2 seconds
G00 Z3 Return to safety distance
RTS End subroutine

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-11

Zero Offset Tables "O"


The CNC allows adjustable zero offsets G54 - G59 to be addressed up to
ten times using different coordinate values.
The zero offset table can be present up to ten times in the CNC. These
are called zero offset tables.

Note: The number of zero point databases is specified by the ma-


chine builder in the process parameters.

The selection criterion in the NC program is the NC command O[0-9],


which together with a single-digit number – the zero offset table number –
addresses one of up to ten zero offset tables.

Syntax O <zero offset table number>


• The initial setting is zero offset table number 0.
• If only zero offset table number 0 is to be used, or if this number is the
first to be active in the NC program, the number 0 will not need to be
programmed separately.
• If the zero offset table is changed in the NC program, G53 automati-
cally becomes active.
• Selection of a zero offset table remains modally active until the end of
the program. The zero offset table selection is reset by commands
RET and BST.
• NC command O should be programmed in a separate NC block. It
must be activated in at least one NC block prior to the selection of a
new zero offset.

Adjustable Zero offsets


Entering and Changing Via User Interface

ZO
ZOTable
TableO9
O9 ZO Table O9
ZO
ZOTable
TableO8
O8 ZO Table O8
ZO
ZOTable
TableO7
O7 ZO Table O7
ZO
ZOTable
TableO6
O6 ZO Table O6
ZO Table O5
ZO Table O5 ZO Table O5
ZO
ZOTable
TableO4
O4 ZO Table O4
ZO
ZO TableO3
Table O3 ZO Table O3
ZO Table O2
ZO Table O2 ZO Table O2
ZO
ZOTable
TableO1
O1 ZO Table O1
ZO
ZOTable
TableO0
O0 ZO Table O0

G54 G59

Switch the Zero Offset Tables to Enter and Change


the Zero Offsets Via the User Interface

310bank.FH7

Fig. 3-15: Zero point tables on the user interface

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-12 Motion Commands, Dimension Inputs NC Programming Instructions

Example:

Y Y
100
80 80
Y
60 [P3] [P4] 100
40 [P2] [P5]
60 80 [P8]
20 60
[P1] [P7]
40
40 20 40 60 80 100
ZO Pt. 20
Table [P6]
No. 0
Value G54:
Zero Pt. Table No. 1 20 40 60 80 100 x
20 Entry in the ZO Table
X17.5
with G54:
Y46.5
X81.0 Y29.5

20 40 60 80 100 120 x
311Null2.FH7

Fig. 3-16: Calling 2 zero point tables with "G54"

NC program:
[Zero offset table No. 0 is active]
G00 G90 G54 X0 Y0 Z10 S1000 M03 Starting position [P1]
G01 X30 Y30 F1000 [P2]
BSR .DRILL Branch to drilling subroutine
Y70 [P3]
BSR .DRILL Branch to drilling subroutine
X70 [P4]
BSR .DRILL Branch to drilling subroutine
Y30 [P5]
BSR .DRILL Branch to drilling subroutine
[activate zero offset table no. 1]
O1
G00 G54 X0 Y0 Starting position [P6]
G01 X40 Y40 F1000 [P7]
BSR .DRILL Branch to drilling subroutine
X60 Y60 [P8]
BSR .DRILL Branch to drilling subroutine
M05 Spindle OFF
RET Program end
.DRILL Drilling subroutine
G01 Z-10 F300 Drill to depth Z
G04 F2 Dwell time 2 seconds
G00 Z3 F1000 Return to safety distance
RTS End subroutine

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-13

Programmable Absolute Zero Offset "G50", Programmable Incremental


Zero Offset "G51"
Programmable zero offsets G50 and G51 move the machining zero point with
• G50 absolute or
• G51 incremental
to the most recently programmed workpiece zero point by the offset val-
ues which were defined together with the address letters.

Syntax G50 <axis name(s)> <coordinate value(s)>


Absolute offset of the machining zero point
G51 <axis name(s)> <coordinate value(s)>
Incremental offset of the machining zero point
In addition, the machining coordinate system can be moved, using G50 (ab-
solute) or G51 (incremental), to the most recently selected workpiece co-
ordinate system in order to rotate the active plane using address letter P.
• Programmable zero offsets G50 and G51 are active according to NC
blocks. The offset remains in effect until the next change of the zero
offset or of the coordinate system.
• No further functions may be programmed in an NC block containing
G50 or G51.
Example:

X X
X 100
80 100 80
60
80
40
60
20
60
Z0
40 40 X2
20 40 60 80 100
P2 P3
Z
20 P4
P1
20 P5

G54:
Z18.0
X15.0
P0 20 40 60 80 100 Z
20 40 60 80 100 120 Z
312g50.FH7

Fig. 3-17: Programmable absolute zero offset "G50"

NC program:
G00 G90 G54 X0 Z0 [P0]
BSR .CONT Branch to the contour subroutine
G50 X2 Zero offset X by 2 mm
BSR .CONT 2. call of the contour subroutine
RET
.CONT Contour subroutine
G01 X10 Z48 F750 [P1]
X25 Z59 [P2]
Z92 F1500 [P3]
X11 Z100 F600 [P4]
Z113 F1000 [P5]
G00 X40 Return to safety distance
Z0
X0 [P0]
RTS Return to main program

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-14 Motion Commands, Dimension Inputs NC Programming Instructions

Programmable Zero Point of Workpiece "G52"


A workpiece zero point can be programmed as the axis position for all
axes which are present using programmed workpiece zero point G52.
When G52 is performed, the coordinate values to which the G52 com-
mand applies are assigned to the current position. This corresponds to
the definition of the workpiece zero point in relation to the current position.

Syntax G52 <axis>


• Axes which are not programmed using G52 work in the machine co-
ordinate system.
• Programming G52 produces a G53 when the change occurs. All zero
offsets which are already active are canceled.
• No further functions may be programmed in an NC block containing G50.
• Coordinate rotation P cannot be programmed in combination with G52.

Example:

80 Y Y
100 100
60 80 [P5] [P4] 80 [P5][P8] [P4]
60 60
40 40
40 [P2] [P3] [P2] [P3]
20 20
[P1] [P1]

G52 X0 Y0 20 40 60 80 100 x 20 40 60 80 100 x


20 ZO-Table G52 X-70 Y0
X20 Y30 Entry in the Zero Offset Table
with would be G52:
X90 Y30

20 40 60 80 100 120 x
313g52.FH7

Fig. 3-18: Call G52

NC program:
G90 G53 G00 X20 Y30
G52 X0 Y0 Call G52
BSR .CONT Branch to the subroutine
G52 X-70 Y0 Call G52
BSR .CONT Branch to the subroutine
RET
.CONT Subroutine
G00 X0 Y0 [P1]
G01 X40 Y20 F1000 [P2]
X100 [P3]
Y80 [P4]
X40 [P5]
Y20 [P2]
G00 X0 Y0
RTS Return to main program

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-15

Cancel Zero Offsets "G53"


All zero offsets are canceled by programming G53. This causes the
workpiece coordinate system to be switched to the machine coordinate
system.

Syntax G53
• Depending on the setting in the process parameters, G53 can be the
power-on default and the initial setting when the NC program starts.
• If G53 is placed in an NC block containing G91, only the position dis-
play is switched to the machine’s actual system.
• If the active zero offsets are canceled using G53 when tool path cor-
rection is active (G41, G42), a G40 (no tool path correction) is issued
internally. The tool correction is rebuilt for the following movement
blocks.

Adjustable General Offset in the Zero Offset Table


By having the general adjustable offset in the zero offset table, the CNC
can also offset the workpiece zero point in addition to the adjustable and
programmable zero offsets. The adjustable general offset functions in an
additive manner to the adjustable and programmable zero offsets. This
means that the adjustable general offset does not become active until one
of the adjustable or programmable zero offsets has been activated.
• The adjustable general offset is canceled using G53 and is not cal-
culated until a zero offset is selected again.
• An angle of rotation can be entered into the zero offset table using the
address PHI. This angle is added to the already active angles of ro-
tation.
• The adjustable general offset can never be active alone due to the
conditions described above.

Read/Write Zero Offset Data from the NC Program via "OTD"


The OTD command (Offset Table Data) can be used to read and write
the data in the zero offset table and the zero offsets which have been
activated in the NC program from the NC program.

Syntax
M P O V A
OTD([1/2],[0..6],[0..9],[0..9],[1..10])
Axis
Offset
ZO Table
Process
NC Memory

35otd.FH7

Fig. 3-19: OTD command syntax

Please refer to the section "Reading and writing ZO data from the OTD
program" for a detailed description of the OTD command.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-16 Motion Commands, Dimension Inputs NC Programming Instructions

3.6 Level selection


Plane selection is an important requirement to correctly perform all
movement commands in an NC program. It informs the control of the
plane on which machining is performed in order to permit, for example, a
correct calculation of the tool correction values. Circular interpolation is
also possible only in the selected plane.
NC commands G17, G18 and G19 suffice to select a plane that is defined
by 2 linear main axes. NC commands G20, G21 and G22 are required to
also select a plane that is partially or totally defined by rotary main axes
and/or by auxiliary axes.

Axis Number, Axis Designation and Axis Meaning


Setting axis parameters Each axis has an axis number (1 - 32), an axis designation and an axis
meaning (X, Y, Z, A, B, C, U, V, W, S).
During parameterization, an axis number, max. 2 permitted axis designa-
tions and max. 4 permitted axis meanings are specified for each axis.

Example:

Axis parameter for axis number 7


C07.001 Axis designation 1 X1
C07.075 Axis designation 2 Y3
C07.053 Axis meaning (axis functions) X,Z,W

Default state After switching on the machine or terminating the NC program, the first
permitted axis designation (X1 in the example) and the first permitted axis
meaning (X in the example) apply for each axis.

Level selection The axis designation and axis meaning of an axis can be changed using
NC commands.

Notation The following mode of writing is used:


Axis designation (axis meaning)

Example:

B(X) means: The axis with axis designation B has axis meaning X.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-17

Plane Selection "G17", "G18", "G19"


Syntax G17
G18
G19

Description The first permitted axis meaning corresponding to the axis parameters is
selected for each axis of the process in the first step.
Then the plane defined by the axes with the following axis meanings is
selected:
1. Axis 2. Axis Vertical
of the plane: of the plane: axis:
G17: X Y Z
G18: Z X Y
G19: Y Z X

Notes: The following definitions apply in this document:


1. lin. main axis (abscissa) = axis with axis meaning X
2. lin. main axis (ordinate) = axis with axis meaning Y
3. lin. main axis (applicate) = axis with axis meaning Z
G17, G18 or G19 can be called even if there is no axis with X,
Y and/or Z as the first axis meaning.

Ordinate 2nd Axis [Y]

Plane YZ
G17
G19
Plane XY Abscissa

G18 1st Axis [X]


Plane ZX

Applicate 3rd Axis [Z]


314Ebene.EPS

Fig. 3-20: Processing planes

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-18 Motion Commands, Dimension Inputs NC Programming Instructions

Free Plane Selection "G20", "G21", "G22"


Syntax G20 axis10 axis20 axis30 G20 axis10 axis20
G21 axis10 axis20 axis30 G21 axis10 axis20
G22 axis10 axis20 axis30 G22 axis10 axis20

axis10 and axis20 are mandatory parameters, axis30 is optional.

Axis1, axis2 and axis3 are axis designations. If an axis designation con-
sists of only one letter, a "0" must be added. If it consists of one letter with
a subsequent numeral, "=0" must be added.

Examples:

G20 Z0 C0 X0 , G20 X0 Y0 Z0 , G20 Y0 Z0 , G21 U0 V0 , G22 A0 C0 ,


G20 X2=0 U0 W3=0 , G21 B1=0 U3=0 V3=0 , G22 Z3=0 X0

With vertical axis G20 axis10 axis20 axis30


G21 axis10 axis20 axis30
G22 axis10 axis20 axis30
for the axes with the axis designations axis1, axis2, axis3, the following
axis meanings are selected:

axis1 axis2 axis3


G20: X Y Z
G21: Z X Y
G22: Y Z X

then the following plane is selected:


1. Axis 2. Axis Vertical
of the plane: of the plane: axis:
G20: axis1(X)axis2(Y)axis3(Z)
G21: axis1(Z) axis2(X)axis3(Z)
G22: axis1(Y)axis2(Z) axis3(X)

Without vertical axis G20 axis10 axis20


G21 axis10 axis20
G22 axis10 axis20
for the axes with the axis designations axis1, axis2, axis3, the following
axis meanings are selected:

axis1 axis2
G20: X Y
G21: Z X
G22: Y Z

then the following plane is selected:


1. Axis 2. Axis
of the plane: of the plane:
G20: axis1(X)axis2(Y)
G21: axis1(Z) axis2(X)
G22: axis1(Y)axis2(Z)

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-19

Examples:

The following axes are specified (switched-on status):


X2(X), Y(Y), Z(Z), A3(A), B(B), C(C), U(U), V(V), W(W)
Selected Vertical
plane axis
G18 Z(Z) X2(X) Y(Y)
G19 Y(Y) Z(Z) X2(X)
G20 B0 A3=0 X2=0 B(X) A3(Y) X2(Z)
G20 C0 X2=0 C(X) X2(Y) ---
G21 Z0 X2=0 Y0 Z(Z) X2(X) Y(Y)
G21 U0 C0 Z0 U(Z) C(X) Z(Y)
G22 W0 V0 W(Y) V(Z) ---
G22 X2=0 Z0 Y0 X2(Y) Z(Z) Y(X)

Permitted axis meanings For G20, G21 and G22, only permitted axis meanings may be selected for
each participating axis designation. If an axis meaning that is assigned to
one axis designation is to be selected for another axis designation, the
axis meaning is selected by exchanging the axis meanings.
The selection of the axis meanings for
G20 axis10 axis20 {axis30}
G21 axis10 axis20 {axis30}
G22 axis10 axis20 {axis30}
is carried out in the order that is prescribed by axis10, axis20 {, axis30}.
For each axis, the starting point is the first permitted axis meaning corre-
sponding to the axis parameters.

Example:

The following axes are parameterized:


Axis number 1 2 3 4
Axis designation X1 C Z X2
Axis meaning (axis functionality) X,W C,Y Z,X W,Z

G20 Z0 C0 X2=0 leads to Z(X), C(Y), X2(Z) and thus to the following axis
meanings:
Axis designation : X1 C Z X2
First permissible axis meaning: X C Z W
Axis meaning acc. to first selection: Z C X W
Axis meaning acc. to second selection: Z Y X W
Axis meaning acc. to third selection: W Y X Z

NC command G20 Z0 C0 X2=0 is thus permitted with the given axis pa-
rameters.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-20 Motion Commands, Dimension Inputs NC Programming Instructions

Boundary conditions
• An axis designation may occur only once within a G20/G21/G22
command, i.e. axis1 ≠ axis2 ≠ axis3 , axis1 ≠ axis3 .
• Tool magazine axes and spindles are excluded.
• The working plane may also be spanned by a maximum of two rotary
axes.
• If a third axis (vertical to the plane) is specified, it must be a linear
axis.
• If an NC set contains a G20/G21/G22 command, the only additional
axis designations that may be programmed are the ones used for free
plane selection.
• The G17/G18/G19/G20/G21/G22 commands form a group
(G code group 2).
• A change in the plane selection overwrites the previous plane selec-
tion and has a modal effect.
• During switching-on, in the basic status, at the end of the program
(BST, RET, JMP, M02 and M30), during a control reset and during a
transition to manual mode (if process parameter "Manual axis jogging
causes reset" has been set), the NC selects the basis system of
coordinates stored in the parameters. This means that it selects the
first axis meaning for every axis in the axis parameters under
Cxx.053. It also selects the working plane that is saved there
(process parameter Bxx.004, default plane selection).

Effects
Coordinate values Programmed coordinate values always refer to axis designations.

Effective radii (RX, RY, RZ) Effective radii are always based on axis meanings, namely the effective
radius RX on the axes with the axis meanings X and A, RY on Y and B
and RZ on Z and C.

ACC For the acceleration factor, programmed coordinate values refer to axis
designations.

G00, G01 G20, G21, G22 activate G01.

G02, G03 Circular interpolation is possible only in the selected plane.


The programmed end point refers to axis designations.
Interpolation parameter I affects the axis with the axis meaning X.
Interpolation parameter J affects the axis with the axis meaning Y.
Interpolation parameter K affects the axis with the axis meaning Z.

G16 Diameter programming G16 affects the axis with the axis meaning X.

G31 Facing machining G31 must not be active at the same time as G20, G21,
G22. The coordinate transformation associated with G31 refers to the XY
plane (G17).

G32 For lateral cylinder surface machining with G32, the effective radius RI
refers to axis meaning X. Generally, a plane selection must be carried out
with G20 before lateral cylinder surface machining is activated.

G33 The programmed end point refers to axis designations.


Thread pitch I affects the axis with the axis meaning X.
Thread pitch J affects the axis with the axis meaning Y.
Thread pitch K affects the axis with the axis meaning Z.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-21

G41, G42 Tool path compensation (radius compensation) affects the selected layer.

G48, G49 Tool length compensations L1, L2, L3 affect the following axes:
L1: 1. axis of the selected plane
L2: 2. axis of the selected plane
L3: Vertical axis
and thus the axes with the following axis meanings:
L1 L2 L3
G17/G20: X Y Z
G18/G21: Z X Y
G19/G22: Y Z X
The length correction includes the sum of length, wear, offset and D-cor-
rection. The radius correction (tool path correction) affects the selected
plane (machining plane).

G50, G51, G52, zero offsets The coordinate values that are programmed with G50, G51 and G52 refer
(ZOs) to axis designations. However, these are entered in the ZO table under
the associated active axis meanings. This must be taken into account
especially if the axis meaning of an axis has been changed using G20,
G21 or G22.
If an angle P is programmed with G50 or G51, this angle refers to the
selected plane.

G65 In the case of thread tapping with G65, only axis designations with axis
meanings X, Y, Z – but no rotary axes – may be programmed.

G74, G75, G77 The programmed coordinate values refer to axis designations.

G95 In the case of feeding per revolution (G95), the path velocity that is pro-
grammed with the F word refers to axis meanings.

G96 In addition to referring to the active spindle, constant cutting speed G96
refers to the axis meaning of X as the feed axis. If the selected plane is
modified, G96 is deselected and the spindle speed in rpm function (G97)
becomes active.

Note: Please refer to the description "Free plane selection and lateral
cylinder surface machining" for further information about free
plane selection.

Example:

A combined drilling and radial facing slide has the following axes within a
process (process 0):

Axis des- Permitted axis Comment


ignation meanings
X X,U Workpiece shift
Y Y Workpiece shift
Z1 Z,W Drill feed
Z2 W,Z Radial facing slide feed
U U,X Radial displacement of radial facing slide
S1 S1 Main spindle (drill)
S2 S2 Tool spindle for boring with radial facing slide

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-22 Motion Commands, Dimension Inputs NC Programming Instructions

First, a preliminary hole is drilled with G17 on a workpiece that can be


displaced in the XY plane (feed axis Z1, main spindle S1). This is then
bored in the same process using a radial facing slide with a constant cut-
ting speed. The radial facing slide rotates around the axis with the desig-
nation Z2 (feed axis) and is displaced in the radial direction along the axis
with the designation U. As a result, the drill hole can principally be drilled
to any cylinder-symmetric form referring to Z2. This machining is similar
to that of the lathe, requiring as the machining plane the Z2-U plane that
is selected with G21 Z2=0 U0 Y0. G96 is used to set the desired constant
cutting speed.

Linear
main Secondary axes Rotary main axes
axes
Mach-ining Vert.
G code Mean. Mean. Mean. Mean. Mean. Mean. Mean. Mean. Mean. plane Axis Remarks
X Y Z U V W A B C

Prelim. drilling
G17 X Y Z1 U - Z2 - - - XY Z
(power-up state)

Boring w/ radial
G21 Z2=0 U0 Y0 U Y Z2 X - Z1 - - - Z2 U Y
facing slide

S1 Z1 S2 Z2
U
Drill

Radial
Facing
Slide

Work-
piece
after
processing
Y
X
317Planschieber.FH7

Fig. 3-21: Boring with a radial facing slide

This machining task is not to be executed with either G20 nor G22:
If G20 Z2=0 U0 Y0 is used, a subsequent G96 refers to the axis with the
designation Z as the feed axis and does not refer to U. With G20 U0 Z0
Y0, tool correction L1 for the radial facing slide tool refers to the axis with
the designation U and L2 refers to Z, which is the opposite of what it
should be.
With G22, the desired utilization of G96 is impossible from the start be-
cause the vertical axis contains axis meaning X.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-23

Example:
A turning center possesses the following axes within a process (axes
within the turning center (process 0)):
Axis designation Axis meaning Comment
X1 X Turning slide
Y Y For milling
Z Z For turning and milling
X2 W Milling slide
C C For machining on the lateral surface
B B Swivel axis for the milling slide
U U Tailstock
S1 S1 Main spindle
S2 S2 Tool spindle for milling

X1 X2

S2
Z
U
Y
C/S1

316Lage.FH7

Fig. 3-22: Position of the axes within the turning center

Selection and axis allocation:


To perform the individual machining tasks, the planes which are defined
by the following axis designations are selected during machine operation:

Linear
main Secondary axes Rotary main axes
axes Mach-
ining Vert.
G code Mean. Mean. Mean. Mean. Mean. Mean. Mean. Mean. Mean. Axis Remarks
plane
X Y Z U V W A B C

Turning (= power-on state)


G18 X1 Y Z U - X2 - B C Z X1 Y

Milling (= G17 with X2)


G20 X2=0 Y0 Z0 X2 Y Z U - X1 - B C X2 Y Z

Milling (= G18 with X2)


G20 Z0 X2=0 Y0 Z X2 Y U - X1 - B C Z X2 Y

Milling (= G19 with X2)


G20 Y0 Z0 X2=0 Y Z X2 U - X1 - B C YZ X2

G20 Z0 C0 X2=0 G32 RI=80 Lateral cylinder surface


Z C X2 U - X1 - B Y CZ X2
machining

The following axis meanings must be permitted for the various commands
for free plane selection for each axis designation:

Free plane selection X1 Y Z X2 C B U


G20 X2=0 Y0 Z0 X,W Y Z W,X C B U
G20 Z0 X2=0 Y0 X,W Y,Z Z,X W,Y C B U
G20 Y0 Z0 X2=0 X,W Y,X Z,Y W,Z C B U
G20 Z0 C0 X2=0 X,W Y,C Z,X W,Z C,Y B U

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-24 Motion Commands, Dimension Inputs NC Programming Instructions

Fig. 3-23: Required permitted axis meanings for various NC commands for free
plane selection

The permitted axis meanings must be selected for each axis and each
process in such a way that the requirements of all the NC commands for
free plane selection that occur in the process are fulfilled.

3.7 Radius/Diameter Programming "G15" / "G16"


Workpieces that are processed on lathes usually have a circular cross-
section. For programming, the CNC offers two possibilities for entering
the dimensions of the workpiece:
• as a diameter dimension and/or
• as a radius dimension.

Syntax G15 Radius programming


G16 Diameter programming

Note: The power-on default for radius and diameter programming is


set by the machine builder in the process parameters.

Diameter programming refers exclusively to the X axis.

Example Using diameter programming:

X
[P4] [P3]

[P2] [P1]
40
50

Z
317Durch.fh7

100

317Durch.FH7

Fig. 3-24: Sample program – diameter programming

NC program:
; Lathe, G16 is home position through process parameters
G01 G90 X40 Z-8 F1000 [P1]
Z-30 [P2]
X50 Z-63 F500 [P3]
Z-100 F1000 [P4]
RET

The following conditions apply for diameter programming:


• When declaring an absolute dimension, the programmed X value is
interpreted as the diameter – negative X values (diameter) are per-
missible. For circles, circle center points as well as end points are to
be declared as the diameter.
• When declaring an incremental dimension (G91), the diameter differ-
ence to the previous position is specified. Based on the old diameter,
the tool moves to the new position according to the specified path

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-25

difference. Regarding the start point of circles, the circle center points
as well as the end points are to be specified as a diameter difference.
• The thread lead is interpreted as a radius dimension when machining
face threads on a lathe.
• Functions such as constant surface speed and feed per revolution in
the X direction are not affected by diameter programming.
• If position data are read into an NC variable for the diameter axis, this
is the diameter value.
• The zero offsets for the X axis are programmed in radius.
• The tool corrections in the X axis are interpreted as radius values.
• The diameter symbol ∅ is used in the position display to indicate the
axis in which diameter programming is active.

3.8 Measurement units


The basic unit to be used in programming is specified by the machine
builder in the process parameters. To produce workpieces which are di-
mensioned in a different dimensioning unit on this machine, the dimen-
sional units can be changed for coordinate values, speed values, and
programmable offsets by using G functions.

Note: The machine manufacturer defines the base programming unit


in process parameter Bxx.001 "Default measurement unit".

Measurement Unit Inch "G70"


Syntax G70
If millimeters are set in the process parameters as the basic programming
unit, the subsequent values are interpreted as inch data and are con-
verted to millimeters internally after G70 has been programmed.
• Motion commands (coordinate values); for example, X5.5 inches is
converted to X139.7 mm;
• interpolation parameters I, J and K and radius R;
• feed data F and G95 F – for example, F20 inch/min is internally con-
verted to F508 mm/min;
• programmable offsets G50, G51 and G52;
• movement commands assigned by means of NC variables (X=@050),
interpolation parameters (I=@051), feed rate information (F=@052) and
programmed offsets (G50 X=@053).
G70 remains in effect until the end of the program or until it is overwritten
by G71.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-26 Motion Commands, Dimension Inputs NC Programming Instructions

Unit Millimeters "G71"


Syntax G71
If inches is set in the process parameters as the basic programming unit,
the subsequent values are interpreted as millimeter data and are con-
verted to inches internally after G71 has been programmed.
• Motion commands (coordinate values); for example, X127mm is con-
verted to X5 inches.
• interpolation parameters I, J and K and radius R;
• feed data F and G95 F – for example, F1500 mm/min is internally
converted to F59.05 inches/min;
• programmable offsets G50, G51 and G52;
• movement commands assigned by means of NC variables (X=@050), in-
terpolation parameters (I=@051), feed rate information (F=@052) and
programmed offsets (G50 X=@053).
G71 remains in effect until the end of the program or until it is overwritten
by G70.

Example:

Ø X

[P4] [P3]
¼ Circle 1 inch
76,2
+K
+I
[P2] [P1]
50,8
45 [P0]

20
318G71.fh7

5 50,8 76,2 90 100 Z


318g71.FH7

Fig. 3-25: Millimeters as the basic programming unit, with change to inches
G70

NC program:
G00 G90 G54 X45 Z100 [P0]
G01 X50,8 Z90 F800 [P1]
G70 Change to inches
Z3 F35 [P2]
G02 X3 Z2 I3 K3 [P3]
G71 Change to mm
G01 Z5 [P4]
.
RET

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-27

3.9 Mirror Imaging of Coordinate Axes "G72" / "G73"


The programmable mirror function permits the mirror imaging of any de-
sired coordinate axes within a machining program. When a coordinate
axis is mirror imaged, the original contour is machined symmetrically op-
posite in the same size and at the same distance on the other side of the
mirror-imaging axis.
The activation and deactivation of mirror imaging is programmed using
the G functions in the subroutine.
The mirror function can be activated via G73. It remains modally active
until it is canceled by G72 or until it is automatically reset at the end of the
program (RET, M002/M030) or by BST. G72 sets all mirror imaging axes
back to the default position.

Syntax G73 <axis name>-1 Mirror function ON


G72 Cancel mirror function for all axes

Mirroring one axis Rule:


• The signs of the coordinates of the mirror-imaged axis are inter-
changed.
• In the case of circular interpolation, the direction of rotation is switched.
(G02 →G03, G03 →G02)
• The machining direction of the path correction is reversed.
(G41 →G42, G42 →G41)

Mirroring two axes Rule:


• The signs of the two coordinates of the mirror-imaged axis are inter-
changed (X-Y, Z-X, Y-Z).
• In the case of circular interpolation, the direction of rotation remains
the same.
• The machining direction of the path correction remains the same.
Zero offsets G54 - G59, G52 and the adjustable offset are not mirror im-
aged. The programmable zero offsets G50 and G51 are also mirrored in
programming when the mirror image function is selected.
• The G functions for mirror imaging are assigned to G function group 18.
• Selecting mirror imaging does not result in any axis movement. Tool
path correction and NC block preparation are terminated when mirror
imaging is selected. Tool lengths are not mirror imaged.
• When main axes are mirror imaged, the workpiece is always mirror
imaged.
• The position display shows the corresponding workpiece coordinates.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-28 Motion Commands, Dimension Inputs NC Programming Instructions

Example: Mirror imaging

Y
70
60
50
40
4 1
30
20
10
X
-10 10 20 30 40 50 60 70

319Spieg.fh7
3 2

319Spieg.FH7

Fig. 3-26: Correlation when mirror imaging one or more coordinate axes

NC program:
G00 G54 G90 X0 Y0 (1) No axis mirror-imaged
BSR .TRIA
G50 X50 (4) X axis is mirror-imaged
G73 X-1
BSR .TRIA
G72
G50 X-20 Y40 (3) X and Y axes are mirror-imaged
G73 X-1 Y-1
BSR .TRIA
G72
G50 X-50 Y20 (2) Y axis is mirror-imaged
G73 Y-1
BSR .TRIA
G72
RET
.TRIA Subroutine for the triangle
G90 G01 X30 Y30 F1000 Triangle starting point
X130
X30 Y90
Y30 Endpoint = starting point
G00 G54 X0 Y0
RTS

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-29

3.10 Scaling "G78" / "G79"


The scaling function provides programmable scaling factors to change the
scale used for the distance to be traveled on all machine axes.
The activation and deactivation of the scaling function is programmed
using the G functions in the subroutine.
Scaling can be activated via G79. It remains modally active until it is can-
celed by G78 or until it is automatically reset at the end of the program
(RET, M002/M030) or by BST. G78 resets all scaled axes back to the
default state.

Syntax G79 <axis name><scaling factor> Scaling ON


G78 Scaling for
all axes OFF

The following values are recalculated for scaling:


• Axis coordinates
• Interpolation parameters
• Radius
• Programmable zero offsets G50 and G51
• Thread pitch
• Effective clearances

Zero offsets G54 - G59, G52 and the adjustable offset are not mirror
scaled. The programmable zero offsets G50 and G51 are also scaled
during programming after the scaling G function has been selected.
• The G functions for scaling are assigned to G function group 19.
• The scaling factors must always be positive values.
• For circle radius programming with R using G02/G03 or with the no-
minal radii RX, RY and RZ, the scaling factors used in the active ma-
chining plane must always be quantitatively identical.
• Selecting scaling does not result in any axis movement. Tool path
correction and NC block preparation are terminated when scaling is
selected. Tool lengths are not scaled.
• With circular interpolation, an error message will be issued if the
scaling factors have different absolute values. The same applies to
rotary axis programming using nominal radii.
• The numerical value which results after recalculation using the scal-
ing factor appears in the position display. The actual value and the re-
maining distance correspond to the real axis positions.
• Scaling factor > 1 Original part is enlarged.
• Scaling factor < 1 Original part is downsized.
• In the internal calculation definition, mirror imaging is performed first
followed by scaling.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-30 Motion Commands, Dimension Inputs NC Programming Instructions

Example: Scaling

70
60
50
40
1
30
20 First Traverse Move
10
after Selecting Scaling

X
-10 10 20 30 40 50 60 70 80 90 100 110 120 130 140 150

320Skali.fh7
70
60
50
40 2
30

X
20
10

10 20 30 40 50 60 70 80 90 100 110 120

320Skali.FH7

Fig. 3-27: Sample program – scaling

NC program:
G00 G54 G90 X0 Y0
BSR .TRIA (1) Triangle without scaling
G50 X40 Y-70 Move zero point
G79 X0.5 Y0.5 Set the scaling factors
BSR .TRIA (2) Triangle with scaling
G78 Cancel scaling
G00 G54 G90 X0 Y0
RET
.TRIA Subroutine for the triangle
G90 G01 X25 Y30 F1000 Start position
X100
X25 Y70
Y30 Final position = starting position
RTS

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-31

3.11 Go to Axes Reference Point "G74"


Movement condition G74 "Go to the axes reference point" allows move-
ments to the reference point with one or more axes in an NC program or
via an MDI block entry.

Syntax G74 <[axis name][coordinate value=0]> <feed>

Example: G74 X0 Z0 F10000


G74 is active only for the NC block in which it is located. In the reference
point cycle, each programmed axis is moved at the homing speed that
has been entered in the axis parameters.

Notes for programming G74 • G74 deactivates the tool path and tool length correction using G40,
sets the machine zero point (G53), and switches to feed programming
(G94) and to absolute dimension entry (G90).
• The coordinate values of the programmed axes in a G74 NC block
must be defined as zero.
• If a number of axes are programmed in a G74 block, the axis move-
ment of the axes is not performed with interpolation.
• A feed rate programmed in a G74 NC block will also remain active for
other types of interpolation.

Note: The reference dimensions and the reference point cycle trav-
ersing speed are set by the machine builder in the drive pa-
rameters.

3.12 Feed to positive stop


The function Feed to positive stop allows one or more axes to feed to a
mechanical stop without causing a drive error. Possible applications are
to preload an axis slide at the stop position during machining or to use the
axis position at the stop as a reference position for further machining.

Festanschlag.FH7

Fig. 3-28: Feed to positive stop

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-32 Motion Commands, Dimension Inputs NC Programming Instructions

Feed to Positive Stop "G75"


Path condition G75 "Feed to positive stop" causes the axes which are
programmed together with the function in the NC block to travel in the
direction of the programmed coordinate value.

Syntax G75 <[axis name][coordinate value]> <feed>

Example: G75 X100 Z50 F500


G75 is active only for the NC block in which it is located. The axes travel
in the direction of the programmed coordinate value using the feed, which
is programmed in the G75 block. If a mechanical resistance – for exam-
ple, a mechanical stop – is detected during the travel distance, the torque
which is defined by axis parameter Cxx.044 (Reduced torque at positive
stop) is limited to a percentage of the peak current. The command value
is not increased further; the remaining distance and the torque preload
are maintained.

Notes on "Feed to positive stop":


• If a feed value is not programmed in the G75 block, travel-
ing will be performed at the speed entered in axis parame-
ter "Max. feed to positive stop".
• If the programmed final axis position value of an axis is
reached, the following error message is generated:
"Positive Stop lies beyond the defined range"
If the stop yields and wanders during operation, or if the
axis slide is forced out of position by a strong opposing
force, the axis position is updated. If this results in the NC
block start position not being reached or the NC block final
position being exceeded, then the error message:
"Positive Stop lies beyond the defined range"
is issued.
• The dimensional information in a G75 NC block can be
entered in absolute mode (G90) or incremental mode (G91).
• If a number of axes are programmed in a G75 block, the axis
movement of the axes is not performed with interpolation.
• The stop axis may not be moved between the calls of G75
and G76.
Parameters "Reduced torque at positive stop" and "Max. feed
to positive stop" are set by the machine builder in the axis pa-
rameters.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-33

Example:

0 100 170

321Fest.fh7
321Fest.FH7

Fig. 3-29: Feed to positive stop

NC program:
G00 Z100 M3 S1250 Z axis to starting position
G75 Z170 F200 Feed to positive stop
.
. Programming of movements on the
. stop axis is impossible!
G76 Cancel axis preload
G01 Z100 F1000 Z axis to starting position
G00 Z0 M5 Z axis to reference point
RET

Programmable Torque
In "Feed to positive stop G75", the torque at which the positive stop is
detected and the holding torque can be adjusted individually. The pa-
rameter settings are performed with the AXD commands.
Besides axis parameter "Cxx.044 Reduced torque at positive stop", the torque
when feeding to the positive stop can be programmed process-dependently
via the AXD parameters in the NC or PLC program.
65017 (P-7-3577) Reduced torque of the digital drive (in percent)
during movement to the positive stop The posi-
tive stop is detected at this torque.
65018 (P-7-3578) Reduced torque of the digital drive (in percent) at
the positive stop This value takes effect only if it is
less than the value that was entered in the "Re-
duced torque at positive stop" axis parameter and
less than 100%. The positive stop is held at this
torque.

NC program example
@41=AXD(X:P-7-3577) ; Save preselected values
@42=AXD(X:P-7-3578)
AXD(X:P-7-3577)=200 ; Values required for processing
AXD(X:P-7-3578)=120 ; Write (multiplication factor = 40)
G75 X200 F500 ; Drive to positive stop
...
G76 ; Cancel torque preload
AXD(X:P-7-3577)=@41 ; Saved preselected
AXD(X:P-7-3578)=@42 ; rewrite values
The torque at which the positive stop is detected is programmed with AXD
parameter "65017 (P-7-3577)". After the positive stop is detected, the axis
is held to the positive stop with the programmed torque in AXD parameter
"65018 (P-7-3578)" until the torque preload is cancelled with G76.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-34 Motion Commands, Dimension Inputs NC Programming Instructions

Cancel All Axis Preloads "G76"


Path condition G76 "Cancel all axis preloads" causes the preloads on all
preloaded axes to be canceled. The actual position value is used as the
position command value so that the axis positions can be used as refer-
ence positions for further movements. The distance-to-go is ignored.

Syntax G76

Notes for programming G76:


• G76 is active only for the NC block in which it is located.
• Path condition G76 cannot be programmed together with
axis data. G76 cancels the axis preloads on all axes which
are preloaded using G75 "Feed to positive stop".
• If a program is terminated by NC command RET, by a
branch with stop BST, when the NC program is manually
reset via Control Reset, or if there is a power failure, all
axis preloads are automatically canceled.

3.13 Traverse Range Limits


Beside the traverse range limits which are defined in axis parameter
"Cxx.011" and "Cxx.012", further traverse range limits can be pro-
grammed in the changeable software limits.

Changeable by:

- User
- NC
- PLC

Machine Data
Limit X+ 122.6000 mm
Limit X- -56.0000 mm

PLC Interface Signal

Axis Parameter
softlimit.FH7

Fig. 3-30: Changeable software limits

Note: The position values are written as machine coordinates.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-35

Machine Data
The changeable software limits are adjusted axis-specifically in page 12
of the machine data.

STRUCT 12 Programmable traverse range limits


Prog. Traverse range limits active BOOL NoNC,NoPLC,NoBOF,NoPwBOF
Prog. traverse range limits positive POS NC,PLC,BOF,PwBOF
Prog. traverse range limit negative POS NC,PLC,BOF,PwBOF
END_STRUCT
ARRAY [
Axis No. IP_AXIS 1-12
] OF STRUCT

Machine data elements "Prog. traverse range limit positive" and "Prog.
traverse range limit negative" can be modified by the user in the machine
data menu, in the NC program and in the PLC.
The element "Prog. traverse range limit active", which is intended to visu-
alize the PLC interface signal, can be accessed only in read mode.

PLC Interface Signal


AxxC.LIMIT The changeable software limits are activated with the axis control signal.

AxxS.LIMIT The axis status signal is set as soon as the control signal has reached the NC.

Boundary conditions
• The variable software limits have no influence in NC blocks which
were already calculated by block preparation when setting the
"AxxC.LIMIT" control signal.
• The changeable software limits must be less than the adjusted trav-
erse range limits in the axis parameter.
• If the axis is outside of the changeable software limits upon activation,
then the limits are active in the next traverse block.

Example:

G1 X250 F1500
X100
MTD(12,1,,2)=122.6
X200
...

The positive traverse range limit is reduced to 122.6 mm by the pro-


grammable positive traverse range limit (the limit stored in the axis pa-
rameter is larger). An error is generated when moving to X200 after the
programmable traverse range limit has been set to 122.6.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-36 Motion Commands, Dimension Inputs NC Programming Instructions

3.14 Repositioning and NC block restart to the contour


The functions:
• reposition and
• restart to the contour
automate traveling back to the contour following a program interruption.
After program interruptions in which the operator withdrew the tool from
the contour in manual mode—to check and replace the inserts on the
tool, for example—the "Reposition" function allows the operator to return
to the point of interruption; the NC block "Restart" function allows him to
travel back to the starting point of the NC block.
Both functions are available in the manual and program-driven modes. In
manual mode, the controller compensates for the difference between the
target position and the actual position in the order in which the user
presses the jog keys. In the program-driven modes, the axes are moved
to their destination positions in the order which is programmed by the
machine builder in an NC subroutine.

Reposition and restart in the automatic operating modes


Operators frequently use reposition and restart in manual mode only to
return the axes in the vicinity of the contour. Once the possibility of colli-
sions is eliminated, the operator changes to one of the automatic operat-
ing modes (automatic or semi-automatic) or executes the program in
manual mode and then continues repositioning or restart by pressing the
start key.
By changing to an automatic operating mode well enough in advance, tool
racing and tool racing marks on the workpiece can be avoided. Following
repositioning or restart, the NC resumes program execution without per-
forming an NC restart.

X X

Z In itia l P o sitio n Z
In itia l P o sitio n

F e e d Mo ve m e n t
F e e d Mo ve m e n t
Blo ck E n d
Blo ck E n d P o sitio n
P o sitio n

Blo ck S ta rtin g Ta rg e t P o sitio n = Ta rg e t P o sitio n = In te rru p t P o sitio n


P o sitio n In te rru p t P o sitio n Blo ck S ta rtin g P o sitio n
322Rueck.FH7

Fig. 3-31: Reposition and restart in the automatic operating modes

Pressing machine operating key "Reposition" or "Restart" selects the de-


sired function. Pressing the Start key starts the repositioning or restarting;
the NC axes are moved accordingly to the destination position in a fixed
order.
• The machine builder can specify the order in which the NC axes are
traversed to the contour. This order can be adapted to the given
machine configuration. This is especially necessary when additional
rotary main axes are present in addition to the spindles and the linear
main axes.
• Program execution resumes without an additional NC start as soon
as the NC has reached the destination point.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-37

Repositioning and Restarting to Destination Position "G77"


G77 causes the NC to traverse to the destination position for the pro-
grammed feed axes and, in the case of spindles, to restore the status
which existed prior to the interruption. With G77, the NC traverses the
existing distance-to-go between the destination position and the current
position for feed axes (axis meanings: X, Y, Z, U, V, W, A, B, C) by per-
forming an interpolation operation similar to the G00 interpolation. It uses
the target position in machine coordinates that was determined at the
beginning of the repositioning or restart operation as the target position
for the axes.

Syntax G77 <[axis name][coordinate value=0]> <feed>

Example:

G77 X0 Y0 Z0 F1000

Notes for programming G77:


• G77 is active only for the NC block in which it is located.
• G77 S[x] 0 ([x]=1-3) causes the NC to restore the most re-
cently active speed for the spindles or causes the NC to
traverse to the specified destination position. The NC uses
the positioning speed which was previously parameterized
for spindle positioning to move to the target position. An
additional F or S value is not needed to specify the posi-
tioning speed.
• With rotary axis-capable main spindles (C-axis), the state
upon interruption (main spindle/rotary axis mode) must be
stored in the PLC. With repositioning or restart, the rotary
axis-capable main spindle must be moved to completion in
the corresponding interruption state (main spindle/rotary
axis mode).

In itia l P o sitio n Z

F e e d Mo ve m e n t

Blo ck E n d P o sitio n
322Rück2.fh7

Ta rg e t P o sitio n = In te rru p t P o sitio n


Blo ck S ta rtin g P o sitio n
322Rueck2.FH7

Fig. 3-32: Repositioning and NC block restart to the contour

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-38 Motion Commands, Dimension Inputs NC Programming Instructions

3.15 NC Program Restart with "ADJUST" and "REPOS"

Task of NC program restart NC program restart is used to establish the states in the controller and the
machine that are required to be able to start or resume the working se-
quence from any block in the NC program.

Note: The "NC program restart" function requires cooperation be-


tween the NC controller and the PLC. The machine manufac-
turer usually makes all necessary presets.

Programming
NC program restart is divided into two sections. All processes that are
computed by the NC but not executed are programmed in the "ADJUST"
subroutine. The subroutine and, consequently, the NC program restart
are invoked using the ".ADJUST" label.
The final state after the execution of the subroutine must be the initial
state for a return to contour or repositioning process. Using the ".REPOS"
label, the "REPOS" subroutine is invoked after the "ADJUST" subroutine.
It contains all sequences and functions that enable a correct return to
contour or repositioning process to be performed.

Note: Subroutine "ADJUST" must be called before the REPOS sub-


routine (without RTS!). Thus, to be able to correctly reposition
to the contour after an NC program restart, the "REPOS" sub-
routine must immediately follow "ADJUST".

The "ADJUST" subroutine enables the machine manufacturer to establish


the states that are required for program entry on the machine. In this
subroutine, the machine manufacturer mainly provides for the output of
the necessary auxiliary functions and for the necessary tool and work-
piece changes.
If a reverse occurs during the execution of the ADJUST subroutine, the
NC branches to the related jump label and continues execution there be-
fore it branches to the ".HOME" label.
The user can store the ADJUST subroutine in the current NC program, in
the 99 program, or in the cycle memory.

Primary blocks A primary block can be used with


• an NC block restart as a start block (with calculation)

Primary blocks are used for NC program restart, in particular when tools
or workpieces are supplied from a different process or an external source
during program execution.
DIN 66025 (Part 1) defines a colon ":" as the primary block character. The
colon must be programmed as the first character within an NC block.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-39

Example:

Primary blocks were programmed in the following programming example


in order to provide the operator with a quick program entry during the NC
program restart.
:
; Section II lathing
: T12 M6
G92 S2800
G0 G6 G8 G54 G97 X50 Z20 S1500 M3
G1 X48 F2000

Note: A slash "/" must be programmed before the colon if a primary


block is also to be a skipped block. Primary blocks can also be
programmed in subroutines.
When primary blocks are programmed, it must be ensured
that the start block is located before an incremental dimension
specification (G91) and before an incremental zero point offset
(G51).

ADJUST and REPOS subroutine


.ADJUST
@127=G(3) @128=G(4) @129=G(6) ;Retain tool path correction, zero
offset and dimensions
@130=M(2) @131=M(5) ;Retain spindle commands and cool-
ant
@126=T ;Retain selected (pre-positioned) tool
T= MTD(60,,,5) BSR .M6 ;Change to required tool
T=@126 MTP ;Pre-position selected tool
G=@128 G=@129 ;Set saved zero offset and dimen-
sions
G=@127 ;Set saved tool path correction
;
Q9500 ;Go to manual mode
;
.REPOS
G77 S0 MTP ;Adjustment of spindle and magazine
(pre-position selected tool)
MRY ;Wait until magazine mvmt. is com-
plete
;
;set auxiliary functions
M=@130 M=@131
;
;Adjustment of the linear axes depending
on the selected plane
@100=G(2)-18 BEQ .REPOS1 ;Plane
@100=G(2)-19 BEQ .REPOS2
G77 X0 Y0 F2000
G77 Z0 F2000 RTS
.REPOS1
G77 Z0 X0 F2000
G77 Y0 F2000 RTS
.REPOS2
G77 Y0 Z0 F2000
G77 X0 F2000 RTS

Fig. 3-33: ADJUST and REPOS subroutine

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-40 Motion Commands, Dimension Inputs NC Programming Instructions

Special NC-Specific Features in NC Program Restart


Auxiliary function buffer The last auxiliary function output within the individual M, Q, S, T, and E
function groups during the NC block restart can be read at the end of the
computing sequence and be sent to the PLC.

Note: At the program end and after a control reset, the NC initializes
all memories of the M or Q function groups with the value "-1".
The sole exceptions are the spindle and gear step groups.

In addition to the M, Q, S, T, and E function groups, the NC stores the last


40 M functions of M function group 16 and the last 40 Q functions during
the NC program restart within the "M(16) and Q function buffer" page.

Note: M19 commands (M19, M119, M219, and M319) are not stored
within the "M(16) and Q function buffer" page.

Working principle With certain exceptions, the NC processes the NC commands during a
NC program restart in the same way as it does during automatic mode.
The exceptions are listed below:

dwell time The NC does not take any dwell times (G04) into account during the
computing run.

Transformation for facing/ The transformation for facing (G31) or lateral cylinder surface machining
lateral cylinder surface (G32) must be selected at the end of the NC program restart process
machining according to the setting of the "Transformation selection" machine data
element of the "NC program restart and REPOS" page within the
"ADJUST" subroutine.

Homing axes The drives do not execute the "Homing axes" function (G74) during the
NC program restart. Thus, the actual position is not changed when a G74
command is executed.

Feed against positive stop When the NC executes the "Feed against positive stop" (G57) command
during the computing run, it does not move the drive concerned. Thus, the
motor current is not increased due to the mechanical resistance.

Spindle Control Commands With NC-controlled spindles, the NC does not execute the spindle control
commands (Mj03, Mj04, Mj05, Mj19; with "j" equal to 1, 2, or 3) during the
computing run. It issues the auxiliary functions to the PLC (as in normal
operation) only if this has been preselected in the process parameters.
The NC retains the states of the spindles with rotary axis capability that
are required for the subsequent program entry and stores them in the "NC
program restart and REPOS" page. The states that are required for the
program entry have been established using G77 Sj=0 (with j equal to " ",
"1", "2", 3") and/or G77 C0 (C: axis designation of the rotary axis) ac-
cording to the necessary modes (same as after an interruption). Which
mode is to be selected can be obtained from machine data page 60 "NC
program restart and REPOS".

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-41

Example:

A spindle with rotary axis capability and the designation S1/C1 requires
the mode (spindle/rotary axis mode) that is necessary for further opera-
tion to be established after an interruption and/or after the NC program
restart in the REPOS subroutine.
.REPOS
:
@100=MTD(60, 0, 0,1)-1 BEQ .ADJ_5 ;Page:60, process:0,
Data element: 1 (rotary axis
mode for S1)
G77 S1=0 ;Select spindle mode
BRA .ADJ_6
.ADJ_5
G77 C1=0 ;Select rotary axis mode
.ADJ_6
:
Program control commands and The NC processes the program control commands (M00, M01, M02,
gear switching functions M30) and the gear switching functions (Mj40, Mj41, Mj42, Mj43, Mj44;
with j = "1", "2", or "3") without any restrictions, as in the normal program
mode. If the machine manufacturer has selected this feature in the proc-
ess parameters, the NC transfers them to the PLC.

Process control and During the NC program restart, the NC executes the process control
synchronization commands commands (DP, SP, RP, AP, WP, LP and POK) and the process syn-
chronization commands (WES and WER) as in normal operation. It is
required, however, that the individual programs have been started in the
individual processes as in normal operation.

Recommendation If the other processes are not to be taken into account (i.e. not to be influ-
enced) during NC program restart because they may have already
reached the required program locations in normal mode or via NC pro-
gram restart, a skip slash or a conditional jump instruction that precedes
the process control commands or process synchronization commands
can be used.

Data exchange with digital During the computer run, data exchange with digital drives (with SERCOS
drives with SERCOS Interface interface) via AXD commands is performed as in normal program opera-
tion. This also applies to APR SERCOS parameters that are processed
by the APR.

Note: AXD commands that bring about a movement must be acti-


vated via the PLC using an auxiliary function that is not issued
and/or not processed by the PLC during NC program restart

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-42 Motion Commands, Dimension Inputs NC Programming Instructions

Example:
Certain functions (such as AXD commands) are not to be issued to the
controller during the NC program restart.
There are different ways of implementing this:
1. Conditional jumps
Using an event the PLC sets during the NC program restart, specific
functions can be skipped that are not to be executed in the NC during the
NC program restart.
:
BES .BP1 1:15
AXD (X:S-0-0104)=7000 ;new KV factor for X axis
AXD (Y:S-0-0104)=7000 ;new KV factor for Y axis
AXD (Z:S-0-0104)=7000 ;new KV factor for Z axis
.BP1
:
2. Implementation in the PLC
In this solution, the PLC executes the functions that may not be proc-
essed during the NC block restart (e.g. the AXD commands). As long as
these functions were activated using an auxiliary function type (e.g. using
Q functions), their output to the PLC can easily be implemented during
the NC program restart process. To do this, just set the related process
parameter:
Bxx.057 Q function output during NC program restart Yes/No
to No.
The related NC program could then look like this:
:
Q101 ;new KV factor for X axis
Q102 ;new KV factor for Y axis
Q103 ;new KV factor for Z axis
:
Axis transfer The NC executes the axis transfer commands (GAX and FAX) as in nor-
mal program operation. If the NC comes to a FAX command during the
computing run, the NC waits until the axis is requested by a different pro-
cess (which may also be in an NC program restart process) via GAX.
Correspondingly, the NC waits during an axis request using "GAX" until
another process (which may also be in an NC program restart process)
releases the axis concerned via "FAX".

Read position value The NC does not interpret the "PMP" and "NMP" commands (which are
used to acquire the current actual position of analog drives) during the
computing run.

Detailed description Additional and supplemental information about the "NC program restart
and REPOS" function can be found in the "NC program restart" descrip-
tion
"DOC-MTC200-SATZVOR*Vxx-ANW1-EN-P".

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Commands, Dimension Inputs 3-43

3.16 Adaptive Depth "G68" / "G69"


nd
Adaptive depth assists a 2 encoder system which, for example, is used
for the compensation of workpiece fixing errors (surface sensors).

Syntax G75 <[axis name][coordinate value]> <feed> switches the motor encoder
nd
to the 2 encoder
nd
G68<[axis name][coordinate value]> <feed> switches the 2 encoder to
the motor encoder
nd
The parameters of the 2 encoder are set in axis parameters Cxx.087,
Cxx.088, Cxx.089, Cxx.090 and Cxx.091. Switching is performed with an
extended encoder using G code G69. The encoder system is switched
back with the encoder still extended using G68.

Application
Application 1
For adaptive positioning with a linear sensor. Switching is performed dur-
ing movement.

Application 2
To switch from a motor encoder to an external measuring system. The
external measuring system can either be a linear encoder, a rotation en-
coder for circular axes, or a linear sensor. Switching is performed in a
standstill condition, but under power and with controller release.

New Axis Parameter


nd
Further axis parameters are offered when switching to a 2 encoder
system if Motor encoder was preselected in the axis parameter "Position
encoder setup".
• Cxx.087 Adaptive control
nd
• Cxx.088 Reference value of the 2 encoder system
nd
• Cxx.089 Positive travel limits of the 2 encoder system
nd
• Cxx.090 Negative travel limits of the 2 encoder system
st
• Cxx.091 Permissible sensor deflection in the 1 encoder system

nd
Note: The reference value of the 2 encoder system must lie out-
side of the travel limit in order to exclude the possibility of un-
desired movements if the workpiece is not reached!

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
3-44 Motion Commands, Dimension Inputs NC Programming Instructions

G Codes to Switch to a 2nd Encoder System


Two new G codes exist to switch between the two encoder systems.
nd
• G69 switches to the 2 encoder
• G68 switches back to the motor encoder.
The G codes are modally inactive
nd
A switch to the 2 encoder is performed under a standstill condition if G
nd
code G69 is cancelled when G09 was preselected. In the 2 encoder
system, the axis coordinate value is being approached as the target posi-
tion when G08 is preselected.

Example of "Switching in a standstill condition":


nd
G69 G09 X0 ;Switch to 2 encoder system
nd
G01 X10 ;Move the axis in the 2 encoder system
st
G68 G09 X0 ;Switch to 1 encoder system
st
G01 X120 ;Move the axis in the 1 encoder system

Example of "Switching on-the-fly":


st
G01 G08 G90 X200 ;Move the axis in the 1 encoder system
nd
G69 X10 ;Switch to 2 encoder system
nd
G01 G08 X20 ;Move the axis in the 2 encoder system
st
G68 X50 ;Switch to 1 encoder system
X50 describes a position in the 2nd encoder sys-
tem

Note: Also see the documentation "Adaptive depth".

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-1

4 Motion Blocks

4.1 Axes

Linear main axes


The linear main axes span a Cartesian coordinate system.
They are identified by means of axis names:
• 1. linear main axis (symbol: X)
• 2. linear main axis (symbol: Y)
• 3. linear main axis (symbol: Z)
The axis name (address of the axis as it is to be addressed in the NC
program) is freely selectable; however, the meaning of the axis is defined
by the position of the axis in the coordinate system (see next fig. "Linear
main axes", sequence "Rotary main axes"). In the CNC, the axes are
permanently assigned to specific processes; however, they can be for-
warded to other processes. An axis cannot be addressed simultaneously
in more than one process.
Circular interpolations and the tool radius path correction can be performed
only within the machining planes spanned by the linear main axes (plane
selection with G17, G18, G19, and free plane selection with G20, G21, G22).

Rotary Main Axes


Rotary main axes rotate about the linear main axes.
The axis meanings:
• 1. rotary main axis (symbol: A)
• 2. rotary main axis (symbol: B)
• 3. rotary main axis (symbol: C)
indicate which coordinate axis the respective rotary main axis rotates
around (see next fig. "Linear main axes"). The axis name (the address of
the axis) is freely selectable; however, the axis meaning is defined by the
position of the axis in the coordinate system. With absolute positioning
(G90), the traverse range is ± 360.000 degrees. With absolute positioning
(G90), the position which is programmed in an absolute statement is trav-
ersed via the shortest possible path. With incremental positioning (G91)
the traverse range is ±999999.9999 degrees or ±99999.99999 degrees
(parameter-dependent). The sign indicates the traverse direction.
Ordinate 2nd Axis [Y]

[B]

Plane YZ
G17
G19 Plane XY
[A] Abscissa

G18 1st Axis [X]


Plane ZX

[C]

Applicate 3rd Axis [Z]


41Koor.FH7

Fig. 4-1: Linear main axes (X, Y, Z) and rotary main axes (A, B, C) in a Car-
tesian reference coordinate system

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-2 Motion Blocks NC Programming Instructions

Linear and Rotary Auxiliary Axes


Linear and rotary auxiliary axes can occupy any given position within the
spatial vicinity.
• 1. auxiliary axis (symbol: U)
• 2. auxiliary axis (symbol: V)
• 3. auxiliary axis (symbol: W)
identify this type of axis.
Axis meanings U, V and W are completely equivalent. They can be se-
lected for linear and rotary axes, as well as for rotary axis-capable main
spindles.
Like the other axes, auxiliary axes take part in positioning processes and
interpolation movements, and like these reach their programmed final
value simultaneously. However, the path feed rate (F value) specified in
the NC program does not apply to the auxiliary axes, but to the linear and
rotary main axes if they are programmed within an NC block.

4.2 Interpolation conditions

Following Error-Free Interpolation "G06"


Syntax G06
A following error-containing algorithm is activated for the axis movements
using interpolation condition G06. All of the following path movements are
performed in a real path mode. The NC block transitions are not rounded,
and they are processed free of interruptions. The path velocity is reduced
to nearly zero near contour corners (path bends). The minimized following
error mode is realized by means of a dynamic feed forward system. A
following error only occurs within the 2 ms limits of the interpolation clock.
• Virtually lag-free operation can be achieved only if Bosch Rexroth di-
gital drives are used. With analog drives, G06 results in a reduced-
following error operation.
• After it is selected, G06 remains modally active until it is canceled by G07
or until it is automatically reset at the end of the program or by BST.
• This function permits the gain factor to be increased to the machine's
maximum mechanical load limits. A higher gain factor produces a
better dynamic characteristic of the axis movements.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-3

Examples:

404Kreis.fh7
C i r c le D i a m e t e r 1 6 0 m m Ma c h i n i n g S p e e d =
F 8 0 0 0 , G a in F a c to r= 7
G06, G08

Oscilloscope Function

P o s i t i o n Va l u e s Y A x i s [ m m ]
Position Deviation:
P o s i t i o n C o m m a n d Va l u e :
Expansion Factor: 1693.7

Axis Number: 2
AxisType: Digital Linear Axis
Axis Designation: Y
Process: Master

Axis Number: 1
Axis Type: Digital Linear Axis
Axis Designation: X
Process: Master

P o s i t i o n Va l u e s X Ax i s [ m m ]

402Kreis.FH7

Fig. 4-2: Circular interpolation with F8000 mm/min and following error-free
interpolation

In the circle shown above, the following error is multiplied by an


expansion factor of 1693.7. Here is the partial program for the circle plots
(see above and following sequences):

T11 BSR .M6 Tool change SF D10


G00 G90 G54 G07 G08 X199 Y136 Z5 Start position
S5000 M03 Spindle ON
G01 Z-5 F1000 Lower cutter into material
G41 X199 Y141 F8000 [or F1000] Start point of circular machining
G03 X180 Y122 I199 J122 Start circle
G01 X180 Y100 Transition element
G02 X180 Y100 I100 J100 Full circle ∅160
G01 X180 Y77 Transition element
G03 X198 Y59 I198 J77 Exit circle
G00 Z5 Withdraw tool to safety clearance
T0 BSR .M6 Tool change
RET Program end

Due to the compensated following error, the actual contour is nearly ideal from
the NC controller point of view. A position deviation of 0.002 mm occurred only
at the transition between the quadrants. The position deviation at the transition
between the quadrants can almost be completely compensated by program-
ming a friction torque compensation.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-4 Motion Blocks NC Programming Instructions

404Kreis.fh7
Ma c h i n i n g S p e e d = F 8 0 0 0 G a in F a c to r= 7
G06, G08

Oscilloscope Function

Position Val ue Axis Y


[mm]

Position Deviation:
Position Command Value:
Expansion Factor: 1693.7

Position Value Axis X


[mm]

C i r c le S e c t i o n P o s itio n D e v ia tio n
E v a l u a t i o n i n Qu a d r a n t T r a n s i t i o n

403Kreis.FH7

Fig. 4-3: Circular interpolation with following error-free interpolation, section

The next figure shows, for comparison, the same circle at a path feed rate
of F1000 mm/min.
404Kreis.fh7

C i r c le D i a m e t e r 1 6 0 m m Ma c h i n i n g S p e e d =
F 1 0 0 0 , G a in F a c to r= 7
G06, G08
Oscilloscope Function

Position Values Axis Y [mm]

Position Deviation:
Position Command Value:
Expansion Factor: 2279.2

Axis Number: 2
Axis Type: Digital Linear Axis
Axis Designation: Y
Process: Master

Axis Number: 1
Axis Type: Digital Linear Axis
Axis Designation: X
Process: Master

P o s i t i o n V a l u e s Ax i s X [ m m ]

404Kreis.FH7

Fig. 4-4: Circular interpolation with F1000 mm/min and following error-free
interpolation

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-5

The figure below shows an evaluation of the position deviation in the tran-
sition between the quadrants.

404Kreis.fh7
Ma c h i n i n g S p e e d = F 1 0 0 0 m m / m i n G a in F a c to r= 7
G06, G08

Oscilloscope Function

Position Val ue Axis Y


[mm]

Position Deviation:
Position Command Value:
Expansion Factor: 2279.2

Position Val ue Axis X


[mm]

C i r c le S e c t i o n P o s itio n D e v ia tio n
E v a l u a t i o n i n Qu a d r a n t T r a n s i t i o n

405Kreis.FH7

Fig. 4-5: Circular interpolation with following error-free interpolation, section


F1000

Interpolation with Lag Distance "G07"


Syntax G07
A following error-containing algorithm is activated for the axis movement
using interpolation condition G07. It is active and locked until it is over-
written by G06. G07 is reset automatically at the end of the program
(RET) or by the BST command. NC block transitions which are not tan-
gential will be rounded.

Example:

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-6 Motion Blocks NC Programming Instructions

40 4K re is.fh7
C i r c le D i a m e t e r 1 6 0 m m Ma c h i n i n g S p e e d =
F 80 0 0 , G a i n F a c t o r = 7
G06, G08
Oscilloscope Function

Position Values Axis Y [mm]


Position Deviation:
Position Command Value:
Expansion Factor: 527.5

Axis Number: 2
Axis Type: Digital Linear Axis
Axis Designation: Y
Process: Master with

Axis Number: 1
Axis Type: Digital Linear Axis
Axis Designation: X
Process: Master with

Position Value Axis X [mm]

406Kreis.FH7

Fig. 4-6: Circular interpolation with F8000 mm/min and G07

In the circle shown, the following error was multiplied by an expansion


factor of 527.5. On the other hand, the expansion factor for G06 was a
multiplication factor of 1693.7, which is more than three times the value;
this explains the variations of the position deviation. Here is the partial
program for the circle plots (see above and following sequences):

T11 BSR .M6 Tool change SF D10


G00 G90 G54 G07 G08 X199 Y136 Z5 Start position
S5000 M03 Spindle ON
G01 Z-5 F1000 Lower cutter into material
G41 X199 Y141 F8000 [or F1000] Start point of circular machining
G03 X180 Y122 I199 J122 Start circle
G01 X180 Y100 Transition element
G02 X180 Y100 I100 J100 Full circle ∅160
G01 X180 Y77 Transition element
G03 X198 Y59 I198 J77 Exit circle
G00 Z5 Withdraw tool to safety clearance
T0 BSR .M6 Tool change
RET Program end

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-7

The diameter of the programmed circle becomes smaller according to the


programmed speed and the selected gain factor. The programmed con-
tour will be maintained with increasing accuracy as the programmed
speed becomes lower and the selected gain factor becomes larger.

404Kreis.fh7
Ma c h i n i n g S p e e d = F 8 0 0 0 m m / m i n G a in F a c to r= 7
G06, G08

Oscilloscope Function

Position Value Axis Y


[mm]

Position Deviation:
Position Command Val ue:
Expansion Factor: 527.5

Position Val ue Axis X


[mm]

C i r c le S e c t i o n P o s itio n D e v ia tio n
E v a l u a t i o n i n Qu a d r a n t T r a n s i t i o n

407Kreis.FH7

Fig. 4-7: Circular interpolation with G07, section

The next figure shows, for comparison, the same circle at a path feed rate
of F1000 mm/min.
40 4K re is.fh7

C i r c le D i a m e t e r 1 6 0 m m Ma c h i n i n g s p e e d =
F 10 0 0 , G a i n F a c t o r = 7
G 0 7, G 0 8
Oscilloscope Function

Position Value Axis Y [mm]

Position Deviation:
Position Command Value:
Expansion Factor: 1680.9

Axis Number: 2
Axis Type: Digital Linear Axis
Axis Designation: Y
Process: Master with

Axis Number: 1
Axis Type: Digital Linear Axis
Axis Designation: X
Process: Master with

Position Values Axis X [mm]

408Kreis.FH7

Fig. 4-8: Circular interpolation with F1000 mm/min and G07

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-8 Motion Blocks NC Programming Instructions

The figure below shows an evaluation of the position deviation in the tran-
sition between the quadrants.

404Kreis.fh7
Ma c h i n i n g S p e e d = F 1 0 0 0 m m / m i n G a in F a c to r= 7
G 0 7, G 0 8

Oscilloscope Function

Position Value Axis Y


[mm]

Position Deviation:
Position Command Val ue:
Expansion Factor: 1680.9

Position Val ue Axis X


[mm]

C i r c le S e c t i o n P o s itio n D e v ia tio n
E v a l u a t i o n i n Qu a d r a n t T r a n s i t i o n

409Kreis.FH7

Fig. 4-9: Circular interpolation with G07, partial view with F1000 mm/min

Optimal Speed Block Transition "G08"


Syntax G08
Interpolation function G08 is used to adjust the final velocity at the end of
the NC block to ensure that the transition to the next NC block occurs at
the highest possible velocity. The crucial factor is the maximum velocity
jump, which is defined in the axis parameters. In the case of a tangential
NC block transition with the same contour velocity, the transition is made
at the same velocity. The result is that workpiece surfaces are uniform; no
free-cutting marks are produced.
• In the case of a tangential transition and an active G06, e.g. a transi-
tion from a straight line to a small circle, the velocity is reduced to the
calculated starting velocity of the next NC block.
• If G61 (exact stop) is programmed with G08 Optimal speed block tran-
sition active, G09 Speed-limited block transition is automatically acti-
vated (see next page). G08 can be programmed again if G61 has
been cancelled.
• Function G08 is active with a feed override of 1%–100%. If the feed
override is set higher than 100%, the velocity is reduced to 100% in
the NC block transitions.
• The M functions stop NC block execution until they are acknowledged;
thus, G08 has no effect in NC blocks in which an M function is pro-
grammed.
• After it has been selected, G08 remains modally active until it is can-
celed by G09 or until it is automatically reset at the end of the program
or by BST.
• Intermediate NC blocks in which no interpolation movements occur do
not cause a velocity change. For example, entering an intermediate
NC block containing G01 F7000 would cause a speed drop.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-9

Note: The machine builder specifies the maximum feed rate change
in the axis parameters.

Examples:
The velocity diagram (above and following sequence) clearly shows how
the NC block transition from the first to the second area is traversed at
unreduced velocity. The NC block transition cannot be detected. The feed
rate is reduced to F7000 in the NC block transition to the third segment.
The velocity is optimally reduced to the NC block starting velocity without
overshooting.
404Kreis.fh7

3 Straigh t Lines X200 -- > X0 G06 und G08

Oscilloscope Function
Signal 1 + Signal 2
[(mm)/min * 10^3]
Axis Number: 1
Axis Type: Dig. Linear Axis
Axis Name: X
Process: Master with 4 Axes

Summed Signal Generation: Signal 1 + Signal 2


Feedrate
Signal 1: d( f( t ))/dt [(mm)/min] Change between
( f( t ) = Actual Position ) 2nd Section and
Signal 2: d( f( t ))/dt [(mm)/min] 3rd Section from
( f( t ) = Position Deviation ) F8000 to F7000
Feed

410Satz.FH7

Fig. 4-10: NC block transitions with G08 and F8000

Sample program for the displayed velocity diagrams in the figures "Block
transitions with G08 and F8000" and "Block transition with G08 from
F8000 to F7000":

G00 G54 G90 G06 G08 X200 Starting point of the X axis
G01 F8000 Feed speed
X150 1. segment
X50 2. segment
X0 F7000 3. segment with new F value
RET Program end

In the following velocity diagram, the change in velocity between the sec-
ond area with F8000 and the third area with F7000 has been magnified
using a zoom function. The optimal velocity NC block transition between
the segments can clearly be seen.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-10 Motion Blocks NC Programming Instructions

404Kreis.fh7
Block Transition from F8000 auf F7000 G06 und G08

Oscilloscope Function
Signal 1 + Signal 2
[(mm)/min * 10^3]
Axis Number: 1
Axis Type: Dig. Linear Axis
Axis Name: X
Process: Master with 4 Axes

Summed Signal Generation: Signal 1 + Signal 2

Signal 1: d( f( t ))/dt [(mm)/min]


Feedrate
( f( t ) = Actual Position )
Change between
Signal 2: d( f( t ))/dt [(mm)/min]
2nd Section and
( f( t ) = Position Deviation 3rd Section from
F8000 to F7000
Feed

411Satz.FH7

Fig. 4-11: NC block transition via G08 from F8000 to F7000

Velocity-Limited Block Transition "G09"


Syntax G09
Interpolation condition G09 is used to adapt the NC block end velocity in
such a way that the maximum velocity change defined in the axis pa-
rameters can be used for a stop.
• Position deviations can be reduced at NC block transitions by using
interpolation condition G09.
• Machining using G09 requires more time, and the surface quality can
be adversely affected with free cutting marks.
• G09 is the power-on default and remains locked and active until it is
overwritten by G08. G09 is reset automatically at the end of the pro-
gram (RET) or by the BST command.

Note: The machine builder specifies the maximum feed rate change
in the axis parameters.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-11

Examples:

40 4K re is.fh7
3 S t r a i g h t L i n e s X 2 0 0 -- > X 0 G06 und G09

Oscilloscope Function
Signal 1 + Signal 2
[(mm)/min * 10^3]
Axis Number: 1
Axis Type: Dig. Linear Axis
Axis Name: X
Process: Master with 4 Axes

Summed Signal Generation: Signal 1 + Signal 2


F eed rate
C h an g e b etw een
Signal 1: d( f( t )/dt [(mm)/min] 2 n d S e c tio n a n d
( f( t )) = Actual Position ) 3 rd S e c tio n fro m
Signal 2: d( f( t ))/dt [(mm)/min] F 8000 to F 7000
Feed ( f( t ) = Position Deviation )

412Satz.FH7

Fig. 4-12: NC block transitions with G09 and F8000

The velocity diagram (see above figure) clearly shows how the velocity of
the axis is reduced to almost 0 between the workpiece areas. The
residual velocity at which the transition to the next NC block occurs is
derived from axis parameter Cxx.017 Maximum feed rate change w/o
ramp.
Sample program for the displayed velocity diagrams in the fig. "Block
transitions with G09 and F8000" and "Block transition with G09 from
F8000 to F7000":

G00 G54 G90 G06 G09 X200 Starting point of the X axis
G01 F8000 Feed speed
X150 1. segment
X50 2. segment
X0 F7000 3. segment with new F value
RET Program end

In the following velocity diagram, the change in velocity between the sec-
ond area with F8000 and the third area with F7000 has been magnified
using a zoom function.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-12 Motion Blocks NC Programming Instructions

404K reis.fh7
Blo c k T r a n s i t i o n f r o m F 8000 au f F 7000 G06 und G09

Oscil l oscope Function


Signal 1 + Signal 2
[ ( m m ) / m i n * 10^3]
Axis Number: 1
Axis Type: Dig. Linear Axis
Axis Name: X
Process: Master with 4 Axes

Summed Signal Generation: Signal 1 + Signal 2 F eed rate


C h an g e b etw een
S i g n a l 1 : d( f( t ) ) / dt [(mm)/min] 2 n d S e c tio n a n d
( f( t ) = Actual Position ) 3 rd S e c tio n fro m
S i g n a l 2 : d( f( t ) ) / dt [(mm)/min] F 8000 to F 7000
Feed ( f( t ) = Position Deviation )

413Satz.FH7

Fig. 4-13: NC block transition via G09 from F8000 to F7000

Exact Stop "G61"


Syntax G61
With interpolation condition G61, the programmed destination position is
approached within the preset exact stop limit. The exact stop limit is de-
fined in the axis parameters by a positioning window. When the position-
ing window is reached, processing switches to the next NC block and the
next axis movement begins.
• Programming G00 (rapid traverse) automatically activates G61 (exact
stop).
• If G61 is programmed, interpolation condition G08 is reset. G08 can
be reactivated if G61 has been cancelled.
• It is recommended that G61 be selected for machining sharp con-
toured corners and not for tangential transitions.
• After it has been selected, G61 remains modally active until it is can-
celled by G62 (Rapid NC block transition) or until it is automatically re-
set at the end of the program or by BST.

Note: The machine builder specifies the positioning window in the


axis parameters.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-13

Examples:

40 4K re is.fh7
T e s t - C o n t o u r : T r a n s i t i o n f r o m S t r a i g h t L i n e -- > C i r c l e N o t T a n g e n t i a l ,
C i r c le --> C i r c le T a n g e n t i a l

O scillo sco p e Fu n ctio n

Position Values Axis Y


[mm]

Po sitio n De via tio n :


P o sitio n Co mma n d Va lu e : Feed:
Exp a n sio n Fa cto r : 6 1 3 .8 F4000
G06, G61
G a in = 7

Po sitio n Va lu e s Axis X
[mm]

Tra n s itio n S tra ig h t T r a n s i t i o n C i r c l e --> C i r c le P o s itio n D e v ia tio n


L i n e --> C i r c le Ta n g e n tia l in Tra n s itio n
N o t Ta n g e n tia l S t r a i g h t L i n e --> C i r c le

414Kontur.FH7

Fig. 4-14: Contour diagram with G61

The "Contour diagram with G61" shown here illustrates how the contour is
accurately maintained by G61 in the transitions straight line →circle and
circle → circle. The positioning window for the examples shown here is
specified as 0.010 mm in the axis parameters. The positioning deviation
in the non-tangential transition from straight line → circle is specified as
0.00249 mm. The transition accuracy could be increased accordingly if
the positioning windows axis parameters were reduced. The position
deviation is less than 0.001 mm in the tangential transition circle →circle.

Sample program for the diagrams shown in Figures "Contour diagram


with G61" and "Velocity diagram with G61":

G00 G54 G90 G06 G08 X-100 Y-100 Starting point


G01 G61 X-50 Y-50 F4000 1. straight line
G02 X50 Y-50 I0 J-50 1. semi-circle
G03 X100 Y-50 I75 J-50 2. semi-circle
RET Program end

The following velocity diagram (Fig. "Velocity diagram with G61") shows
how the velocity is reduced until the positioning window is reached. When
the positioning window is reached, processing switches to the next NC
block and the next axis movement starts.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-14 Motion Blocks NC Programming Instructions

404K reis.fh7
D i a g r a m : T r a n s i t i o n f r o m S t r a i g h t L i n e --> C i r c le N o t T a n g e n t i a l,
C i r c le --> C i r c le T a n g e n t i a l

Oscil l oscope Function


( (Signal 1)2 + ( S i g n a l 2) 2 )
[ ( m m ) / m i n * 10^3]
Axis Number: 1
Axis Name: X
Axis Number: 2
Axis Name: Y

F eed rate Summed Signal Generation: ( (Signal 1) 2 + ( S i g n a l 2) 2 )


F eed rate F 4000
S i g n a l 1 : d( f( t ) ) / dt [(mm)/min] G06, G61
( f( t ) = Actual Position ) G a in = 7
S i g n a l 2 : d( f( t ) ) / dt [(mm)/min]
( f( t ) = Actual Position )

T r a n s i t i o n S t r a i g h t L i n e --> C i r c le T r a n s i t i o n C i r c l e - -> C i r c l e
N o t Ta n g e n tia l Ta n g e n tia l

415G61.FH7

Fig. 4-15: Velocity diagram with G61

Rapid NC Block Transition "G62"


Syntax G62
With interpolation condition G62, processing switches to the next NC
block as soon as the command values for all programmed axes in the NC
block, which are issued by the interpolator, have reached their pro-
grammed final values. The machine does not wait until the actual values
have also reached their end positions. Any lag (following error) which may
be present is not reduced while the final position is being approached.
• G62 (Rapid NC block transition) is suppressed if G00 (Rapid traverse)
is programmed.
• Programming G62 rounds off sudden contour changes and non-tan-
gential transitions.
• G62 is the power-on default and is saved as active until it is overwrit-
ten by G61. G62 is reset automatically at the end of the program
(RET) or by the BST command.
• The machining time is reduced when G62 and G08 are programmed.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-15

Examples:

40 4K re is.fh7
T e s t -C o n t o u r : T r a n s i t i o n f r o m S t r a i g h t L i n e --> C i r c le N o t T a n g e n t i a l,
C i r c le --> C i r c le T a n g e n t i a l

Oscilloscope Function

Position Values Axis Y


[mm]

Positions Deviation:
Position Command Value: F eed rate:
Expansion Factor: 2444.6 F4000
G06, G62
G a in = 7

Position Values Axis X


[mm]

Tra n s itio n S tra ig h t L in e T r a n s i t i o n C i r c le P o s itio n D e v ia tio n


--> C i r c le --> C i r c le T a n g e n t i a l in Tra n s itio n
N o t Ta n g e n tia l S t r a i g h t L i n e --> C i r c le

416G62.FH7

Fig. 4-16: Contour diagram with G62

The contour diagram shown here with G62 illustrates how the non-tan-
gential transitions (straight line →circle) are slurred as a consequence of
G62. The contour is traveled at optimal velocity (via G08). At the contour
itself, the machining quality is identical to that achieved with G61. If you
compare the contour diagrams in "Contour diagram with G61" and
"Contour diagram with G62", note that the expansion factor for the posi-
tion deviation is four times as high in "Contour diagram with G62".

Sample program for the diagrams shown in Figures "Velocity diagram


with G61" and "Contour diagram with G62":

G00 G54 G90 G06 G08 X-100 Y-100 Starting point


G01 G62 X-50 Y-50 F4000 1. straight line
G02 X50 Y-50 I0 J-50 1. semi-circle
G03 X100 Y-50 I75 J-50 2. semi-circle
RET Program end

In the following velocity diagram with G62, it can be seen how the path
velocity in the non-tangential transition straight line →circle is reduced by
the change of direction. The tangential transition circle →circle is traveled
at a constant path velocity as a consequence of conditions G62 and
G08.g

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-16 Motion Blocks NC Programming Instructions

404K reis.fh7
D i a g r a m : T r a n s i t i o n f r o m S t r a i g h t L i n e --> C i r c le N o t T a n g e n t i a l,
C i r c le --> C i r c le T a n g e n t i a l

Oscil l oscope Function


( (Signal 1)2 + (Signal 2)2 )
[ ( m m ) / m i n * 10^3]
Axis Number: 1
Axis Name: X
Axis Number: 2
Axis Name: Y

Feed Summed Signal Generation: ( (Signal 1) 2 + (Signal 2)2 )


F eed rate F 4000
S i g n a l 1 : d( f( t ) ) / dt [(mm)/min] G06, G62
( f( t ) = Actual Position ) G a in = 7
S i g n a l 2 : d( f( t ) ) / dt [(mm)/min]
( f( t ) = Actual Position )

Tra n s itio n S tra ig h t L in e T r a n s i t i o n C i r c le


- -> C i r c l e N o t T a n g e n t i a l - -> C i r c l e T a n g e n t i a l

417G62.FH7

Fig. 4-17: Velocity diagram with G62

Programmable Acceleration "ACC"


Syntax ACC <constant><axis designation><value>
ACC=<variable><axis designation><value>
ACC=<arithmetic expression><axis designation><value>

An acceleration limit can be programmed in an NC program using the


function ACC (Programmable acceleration). This function is used, for
example, to reposition the workpiece holder axes according to the weight
of the workpiece. The programmable acceleration limits the maximum
path acceleration specified in the parameters. The acceleration factor is
programmed in percent of the maximum path acceleration defined in the
process parameters. It acts on all axes programmed in an NC block.
• The acceleration factor ranges from 1% to 100%.
• An acceleration factor which does not lie within the value range will
produce an error message when the program is executed.
• The acceleration factor can be programmed as a constant as well as a
mathematical expression. If the acceleration factor is defined as a
constant, it is not possible to program decimal places. If it is defined as
a mathematical expression, the value is automatically rounded to a
whole number.
• An acceleration factor programmed using the ACC command remains
modally active until it is overwritten by a newly programmed value or is
automatically reset to 100% at the end of the program or by the com-
mand BST.
• The ACC command may remain inactive if the "Maximum path accel-
eration" parameter was set to a very high value which is disproportion-
ate to the maximum possible path acceleration.

Note: The machine builder specifies the maximum path acceleration


in the process parameters.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-17

Examples:
G01 ACC 50 X100 ACC with a constant
G01 ACC=@10 X100 ACC with a variable
G01 ACC=10*@10+30 X100 ACC with a math. expression

NC program:
G00 G54 G90 G61 G06 X200 Starting point
G01 X150 F8000 1. straight line
ACC 40 X50 2. straight line acceleration factor
40%ACC 15 X-50 3. straight-line acceleration factor 15%
RET Program end

The process parameter for maximum acceleration was set to 500


mm/sec2 in the velocity diagram shown here.
The acceleration for NC block ACC 40 X50 is therefore 200 mm/sec2; for
NC block ACC 15 X-50, it is 75 mm/sec2.
404Kreis.fh7

Speed Diagram: 3 Straight Lines in X with Various Acceleration

Oscilloscope Function
( (Signal 1) 2 + (Signal 2) 2 )
[(mm)/min * 10^3]
Axis Number: 1
Axis Type: Dig. Linear Axis
Axis Name: X
Process: Master with 4 Axes

Feed Summed Signal Generation: ( (Signal 1) 2 + (Signal 2) 2 )

Signal 1: d( f( t ))/dt [(mm)/min]


( f( t ) = Actual Position )
Signal 2: d( f( t ))/dt [(mm)/min]
( f( t ) = Position Deviation )

418Besch.FH7

Fig. 4-18: Velocity diagram for programmable acceleration

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-18 Motion Blocks NC Programming Instructions

4.3 Interpolation functions

Linear Interpolation, Rapid Traverse "G00"


Syntax G00
The programmed coordinate values using path condition code G00 are
approached at maximum path velocity. If G00 applies to more than one
axis, the movement is performed with interpolation.
A feed rate can be programmed with G00 by using an F word. If a feed
rate (F value) is not programmed in the NC block, then the movement
occurs at the maximum path velocity entered in the process parameters.
The path velocity is limited to the maximum axis velocity entered in the
axis parameters, so that linear interpolation is always performed. The F
value programmed with G00 remains active for all subsequent move-
ments and interpolation types until it is overwritten by a new F value.

Note: The programmed F value for a G00 block is valid only for the
NC block in which it has been programmed. In the case of a
subsequent G00 block without an F value, the axes are moved
at maximum path velocity.

Rapid block transition (G62) is suppressed in combination with G00. A


transition to the next NC block occurs only if all programmed axes lie
within the position window of the programmed coordinate value, which is
specified in the axis parameters.
With active velocity-optimal NC block transition (G08), a change to veloc-
ity-limited NC block transition (G09) is already made in the previous NC
block. If G00 is overwritten by a different type of interpolation, G08 is
automatically reactivated.
G00 remains modally active until it is overwritten by a different code in the
same G group (G01, G02, G03).

Example:

G00 G54 G90 X40 Y40 [P1] rapid traverse at maximum path velocity
X120 Y60 F8000 [P2] rapid travel with F word

Y
60 P2

40
P1
20

20 40 60 80 100 120 140 X


419g0.FH7

Fig. 4-19: Linear interpolation, rapid travel G0

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-19

Linear Interpolation, Feed "G01"


Syntax G01
The axes programmed using code G01 are moved to their programmed
coordinate value on a straight line relating to the current coordinate sys-
tem using the current feed rate. The programmed axes are started si-
multaneously; all of them reach their programmed end point at the same
time.
If a new feed rate (F value) is programmed using code G01, the most
recently active F value is overwritten. The programmed F value functions
as a path feed rate. If a number of axes are being traveled, the velocity
component of each individual axis is less than the programmed path feed
rate. If an F word was not yet active when the controller was powered on,
then G01 must be used to program an F value.
G01 remains modally active until it is overwritten by a different code in the
same G group (G00, G02, G03).

Example: Linear interpolation in 2 axes

Y X
[P4]
100 [P3] 100
[P4]

80 80
[P2]

60 60

40 40

20 [P1] 20
[P1]

20 40 60 80 100 10 0 -10
X Z
420G01.FH7

Fig. 4-20: Linear interpolation, feed rate G01 with 2 axes

NC program:
G00 G90 G54 G06 G08 Movement commands, interpolation con-
ditions
X0 Y0 Z10 S3000 M03 Starting position, spindle ON
G01 X26.26 Y18 Z5 F2000 [P1] Machining start position
Z-5 Feed Z axis
Y80 F1200 [P2] linear interpolation, 1 axis
X41 Y93.5 [P3] linear interpolation, 2 axes
X111 [P4] linear interpolation, 1 axis
G00 Z10 M05 Z axis to safety distance
RET

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-20 Motion Blocks NC Programming Instructions

Example: Linear interpolation in 3 axes

Y X
[P3] [P2]
100 [P3] 100

80 [P2] 80

60 60
[P1]
40 40

20 [P1] 20

20 40 60 80 100 10 0 -10
X Z
421G013.FH7

Fig. 4-21: Linear interpolation, feed rate G01 with 3 axes

NC program:
G00 G90 G54 G06 G08 Movement commands, interpolation con-
ditions
X0 Y0 Z10 S3000 M03 Starting position, spindle ON
G01 X40 Y25.5 Z5 F2000 [P1] Machining start position
Z-5 Feed Z axis
X95.74 Y80 Z-10 F1200 [P2] linear interpolation, 3 axes
X100 Y100 Z10 F2000 [P3] Z axis to safety distance
M05 Spindle OFF
G00 X0 Y0 Return to starting point
RET Program end

Circular Interpolation "G02" / "G03"


Syntax • Circular movement - clockwise
G02<end point ><interpolation parameter [I,J,K]> or
G02<end point><radius [R]>
• Circular movement - counterclockwise
G03<end point ><interpolation parameter [I,J,K]> or
G03<end point><radius [R]>

The programmed path condition G02 or the programmed tool G03 is moved
along a circular path to the programmed end point using the effective or
programmed feed rate (F value). The programmed axes are started simul-
taneously; all of them reach their programmed end point at the same time.
Circular movement is activated using:
• G02 in the clockwise direction and
• G03 in the counterclockwise direction
in the direction of the programmed end point (see Fig. "Circular
programming depending on planes"). The tool is moved around the
programmed center point of the circle.
A circular motion can be performed in each plane using the correspond-
ing selection (plane selection with G17, G18, G19 and free plane selec-
tion with G20, G21, G22). The programmed center of the circle and the
end points must lie on the same machining plane as the starting point.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-21

Ordinate 2nd Axis [Y]

G02 G03
Plane YZ
G03
G17
G19 Abscissa
Plane XY
G02
G03 1st Axis [X]
G18
G02
Plane ZX

Applicate 3rd Axis [Z]

422Kreis.FH7

Fig. 4-22: Circular programming depending on planes

The radius and the starting angle of the arc are calculated from the start-
ing point and the center point. A radius which is determined based on the
end point and the center point, and that perhaps differs, is ignored. This
means that the end point can only be used to calculate the final angle.
Thus, the programmed end point may not always lie on the arc. The pro-
grammed end point can therefore differ from the traveled end point.
With incremental data input (G91), the center point and the end point are
expressed in relation to the starting point; with absolute input (G90), they
are expressed in relation to the current zero point.
When programming using absolute data input, the value of the starting
point is assigned to the coordinate value of an unprogrammed address
letter (X, Y, Z, I, J, K); with incremental input, the value 0 is assigned.
Since the starting point and end point are identical for a full circle, only the
center point needs to be entered when programming a full circle.
A circle or an arc is defined by the programmed axis commands and the
parameters for interpolation. The previous NC block defines the starting
point of the circle. The end point of the circle is defined by the axis value
data X, Y and Z in the G02/G03 NC block. The center point of the circle is
defined by the entered interpolation parameters I, J and K or directly via
radius R.

Interpolation Parameters I, J, K
Interpolation parameters are assigned to the axes which are used in a
circular interpolation. These parameters are parallel to the axes, and their
signs depend on the direction in which they are oriented in relation to the
center point of the circle. Based on DIN 66 025, interpolation parameters
I, J and K are assigned to axes X, Y and Z.
If coordinate values are not programmed using addresses I, J and K, the
corresponding starting point is assigned with absolute dimension pro-
gramming. The default value is 0 with incremental dimension program-
ming.
With G91 programming, the interpolation parameters define the distance
from the starting point of the circle to the center point; with G90 program-
ming, the distance from the current zero point to the center point is de-
fined.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-22 Motion Blocks NC Programming Instructions

Starting Point
End point Center Point
-J (G91)
+I (G90) -I (G91)
+J (G90)

X
423Kreis.FH7

Fig. 4-23: Circular interpolation with interpolation parameters

Example: Full circle in the X-Y plane with G90

Y
CP = Center Point

100

80
I=60
60 CP

40
[P1] J=60
20

20 40 60 80 100 120 140 X


424Voll.FH7

Fig. 4-24: Full circle with G90

NC program:
G00 G90 G54 G06 G08 Movement commands, interpolation con-
ditions
X0 Y0 Z10 S3000 M03 Starting position, spindle ON
G01 X40 Y37.24 F2000 Starting point of circle
Z-10 F500 Feed Z axis
G02 X40 Y37.24 I60 J60 Full circle in clockwise direction
Alternatively: G02 I60 J60 With full circle, without circle end point
G00 Z10 Z axis to safety distance
M05 Spindle OFF
X0 Y0 Return to starting point
RET Program end

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-23

Example: Full circle in the X-Y plane with G91

Y I=20
CP = Center Point
100

80

60
CP
J=22.76
40
[P1]
20

20 40 60 80 100 120 140


X
425g90.FH7

Fig. 4-25: Full circle with G91

NC program:
G00 G90 G54 G06 G08 Movement commands, interpolation condi-
tions
X0 Y0 Z10 S3000 M03 Starting position, spindle ON
G91 G01 X40 Y37.24 F2000 Starting point of circle in chain dimension
Z-20 F500 Feed Z axis
G02 X0 Y0 I20 J22.76 Full circle in clockwise direction
Alternatively: G02 I20 J22.76 With full circle, without circle end point
G00 G90 Z10 Z axis to safety distance (G90)
M05 Spindle OFF
X0 Y0 Return to starting point
RET Program end

Example: Machining on a lathe in Z-X plane

Ø X
200 C P = C irc le C e n te r P o in t
[P 5 ] [P 4 ]
160 KM
+K

120 +I

[P 3 ] [P 2 ]
80
[P 1 ]

40

20 40 60 80 1 0 0 1 2 0 1 40 Z
426Dreh.FH7

Fig. 4-26: Circular programming for lathe, behind center of rotation

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-24 Motion Blocks NC Programming Instructions

Example of programming using absolute dimension input (G90)


G00 G16 G90 G54 G06 G08 Movement commands, interpolation con-
ditions
M03 S2000 Spindle ON
X69 Z136.5 [P1] Starting position
G01 X40 Z128.5 F500 [P2] linear interpolation
Z100 [P3] circle starting point
G02 X160 Z60 I160 K100 [P4] ¼ circle in clockwise direction
G01 Z10 [P5] machining end position
G00 X200 X axis to safety distance
M05 Spindle OFF
RET Program end

Example of programming using incremental dimension input (G91):


G00 G16 G90 G54 G06 G08 Movement commands, interpolation con-
ditions
M03 S2000 Spindle ON
X69 Z136.5 [P1] Starting position
G01 G91 X11 Z-8 F500 [P2] linear interpolation
Z-28.5 [P3] circle starting point
G02 X40 Z-40 I40 K0 [P4] ¼ circle in clockwise direction
G01 Z-50 [P5] machining end position
G90 G00 X200 X axis to safety distance
M05 Spindle OFF
RET Program end

Circle Radius Programming


In order to take over dimensions directly from the workpiece drawings, an
option is provided to directly define circular paths in the NC program via
the specified radius.
A distinct circular path is produced within a semicircle (180°) only if G02
or G03 programming is used (see Fig. "Circle radius programming,
determining the sign to be used for the radius").
For this reason, it is important to indicate whether the traveling angle will
be greater or less than 180°. The radius entry must be preceded by a
minus sign for arcs with angles exceeding 180°.

Syntax for circle radius G02 R+ ... with a traveling angle to 180°
programming in the G17 plane X ... Y ...
G03 R- ... with a traveling angle > 180°

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-25

Example: Defining the arc

Ø X
R= -30
100

80
[S]
[E]
60
R= +30
40

20

20 40 60 80 100 120 140 Z


427Kvor.FH7

Fig. 4-27: Circle radius programming, determining the sign to be used for the
radius

G01 X... Z...


G02 X... Z... R±30
As can be seen in the above example, two possibilities would result for
this programmed circle. Selecting the sign (R+30 or R-30) determines
which circle is traveled.
• The direction of movement in relation to the circle end point is deter-
mined by G02 or G03.
• Circle radius programming is not permissible with a traveling angle of
0° or 360°. The axes will remain at their starting points.
• If the circle end point is missing, the axis will remain at its starting
point. No movement takes place.
• The programmed radius is active in the current machining plane (plane
selection with G17, G18, G19 and free plane selection with G20, G21,
G22).

Example: Circle radius programming in the Z-X plane

Ø X
200
[P 5] [P 4]
160 C ircle C enter Point

40 R
120 +I

[P 3] [P 2]
80
[P 1]

40

20 40 60 80 100 120 140 Z


428Dreh.FH7

Fig. 4-28: Circle radius programming on a lathe, behind center of rotation

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-26 Motion Blocks NC Programming Instructions

NC program:
G00 G90 G54 G06 G08 Movement commands, interpolation condi-
tions
M03 S2000 Spindle ON
X69 Z136.5 [P1] Starting position
G01 X40 Z128.5 F500 [P2] linear interpolation
Z100 [P3] circle starting point
G02 X160 Z60 R40 [P4] ¼ circle in clockwise direction
G01 Z10 [P5] machining end position
G00 X200 X axis to safety distance
M05 Spindle OFF
RET Program end

Helical Interpolation
Helical interpolation is a combined circular and linear interpolation which
is used to produce a spiraling tool path. Circular interpolation takes place
in the selected plane (plane selection with G17, G18, G19 and free plane
selection with G20, G21, G22) while linear interpolation occurs simultane-
ously in a third axis which is perpendicular to the plane of circular inter-
polation.
In helical interpolation, an arc and a straight line erected perpendicular to
the end point of the arc are both programmed in the same NC block. The
axis movements are coordinated in such a way that the tool moves at a
constant pitch in a helical path.

-50
25

50
Y
50

X
429Schrau.FH7

Fig. 4-29: Helical Interpolation

No more than one coil (corresponding to a full circle) can be programmed


in an NC block. Programming a corresponding number of individual coils
can only produce a number of coils in sequence.
The programmed feed rate (F value) relates to the actual tool path. All
other conditions are the same as in circular interpolation.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-27

Example: Helical interpolation in the X-Y plane with G90

Y X
100 CP = Center Point 100
[P4]
80 80

60 60
[P1]
40 CP 40
I=62.5
[P2] [P3]
20 20
[P1] J=30
[P4]

20 40 60 80 100 10 0 -10
X Z
430G90s.FH7

Fig. 4-30: Helical interpolation with G90

Example of programming using absolute dimension input (G90)


G00 G90 G54 G06 G08 Movement commands, interpolation condi-
tions
X0 Y0 Z10 S5000 M03 Starting position, spindle ON
G01 X40 Y20 Z5 F2000 [P1] Z axis to safety distance
Z-2,5 Z axis to machining depth
X40 Y30 [P2] starting point of half coil
G02 X85 Y30 I62.5 J30 Z-5 [P3] helix in clockwise direction
G01 X85 Y10 [P4] clear X and Y
G00 Z5 Z axis to safety distance
M05 Spindle OFF
X0 Y0 Z10 Return to starting position
RET Program end

Example: Helical interpolation in the X-Y plane with G91

Y X
I=22.5 CP = Center Point
100 100
[P4]
80 80

60 60
[P1]
40 40
CP
[P2] [P3] J=0
20 20
[P1]
[P4]

20 40 60 80 100 10 0 -10
X Z
431G91s.FH7

Fig. 4-31: Helical interpolation with G91

Example of programming using absolute dimension input (G91)


G00 G90 G54 G06 G08 Movement commands, interpolation con-
ditions
X0 Y0 Z10 S5000 M03 Starting position, spindle ON
G91 G01 X40 Y20 Z-5 F2000 [P1] Z axis to safety distance
Z-7.5 Z axis to machining depth
Y10 [P2] starting point of half coil
G02 X45 I22.5 J0 Z-2.5 [P3] helix in clockwise direction
G01 Y-20 [P4] clear X and Y
G00 Z10 Z axis to safety distance
M05 Spindle OFF
X-85 Y-10 Z5 Return to starting position
RET Program end

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-28 Motion Blocks NC Programming Instructions

Thread Cutting "G33"


The G33 function "Thread cutting" can be used to cut
• single or multiple point longitudinal threads,
• face threads and
• tapered threads with a constant lead.

T h r e a d L e a d 1 T h read P ass

djhhfdjhjf

L o n g itu d in al T h read
432Laeng.FH7

Fig. 4-32: Longitudinal thread

Syntax G33 <end point [X,Y,Z]> <lead [I,J,K]> <starting angle [P]>
The thread length is the difference between the starting point and the end
point that is programmed in NC block G33. The thread entering and exit-
ing path in which the feed rate is accelerated or reduced must be consid-
ered. The coordinate values can be programmed using absolute (G90) or
incremental (G91) positioning data.
The thread lead is entered in address I, J and K; however, no more than
one interpolation parameter can be programmed in a single-thread NC
block. Interpolation parameters I, J and K are programmed as incre-
mental values without sign. Interpolation parameters I, J and K are as-
signed to axes X, Y and Z.
Via address P, the thread starting angle can be programmed from 0° to
360°. By programming a thread starting angle, it is possible to cut multiple
coils without shifting the start point. If a starting angle is not programmed
via address P, it is assumed that the starting angle is 0°.
Clockwise or counterclockwise threads are produced by defining the di-
rection of rotation of the spindle: M03 or M04. If G33 is used to select a
different spindle for thread cutting, the spindle must be activated by
means of the "SPF <spindle number>" command prior to NC block G33.
The first spindle is always active in the power-on state. The spindle must
start at the desired speed prior to or in the G33 NC block.
In any case, positioning without lag G06 must always be used for thread
cutting in conjunction with G33 since this function has a positive influence
on the thread quality.
G33 belongs to the group of blockwise active G codes. G33 does not
remain active at the end of an NC block. The thread is cut from the cur-
rent starting point up to the programmed end point of the NC block, while
movements are possible in several axes (tapered threads).
• No more than 500 threads can be cut per thread NC block. If more
than 500 threads are required, these can be machined using thread
NC block sequences.
• The maximum spindle speed in a thread NC block is 13,500 rpm. The
required approach distance increases as the spindle speed and thread
lead increases.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-29

• While thread cutting, the constant surface speed G96 is ignored via
G33. The spindle speed which was programmed last via G97 is set.
• If the thread is cut using positioning with minimized lag G06, the spin-
dle speed can be changed during thread cutting by using spindle over-
ride, though this can negatively affect quality. The feed rate will adapt
accordingly. Feed rate override will not be active.
• In the case of an immediate stop (emergency stop, stop in setup
mode), the spindle speed and the feed rate are synchronously reduced
and are synchronously increased upon a restart.
• For taper threads, the thread lead is declared in relation to the main
axis. If the desired thread lead is to relate to the Z axis, then the thread
lead must be defined in interpolation parameter K. The thread lead is
programmed in interpolation parameter I if the thread lead relates to
the X axis.
• When lathing face threads, the thread lead is interpreted as a radius
dimension when programming the diameter.
• Depending on the parameter setting, the thread lead can be entered
using 3 or 4 places to the left of the decimal point and, correspond-
ingly, 5 or 4 places to the right of the decimal point.

Note: Function G33 is available only if APRB04 (axis processor) is


present.

Example: NC program for longitudinal thread

X
100

[P4] [P1]
80

60
[P3]
[P6] [P2]
40 [P5]

20

20 40 60 80 100 120 140 Z


433GLaeng.FH7

Fig. 4-33: Thread cutting – longitudinal thread

Thread lead: 3 mm
Thread depth: 4 mm Thread depth per
cut: 2 mm
NC program:
G00 G54 G90 G06 G08 X80 Z130 S2000 M03 [P1] Starting conditions
G01 X45.5 F1500 [P2] Feed for first cut
st
G33 Z30 K3 P180 [P3] 1 thread pass
G00 X80 [P4] Withdraw X axis
Z130 [P1] Starting point
nd
G01 X43.5 F1500 [P5] Feed for 2 cut
G33 Z30 K3 P180 [P6] Second thread pass
G00 X80 [P4] Withdraw X axis
M05 Spindle OFF
RET Program end

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-30 Motion Blocks NC Programming Instructions

Example: NC program for taper thread

X
100 [P4] [P1]
105mm

80 [P3] Lead

[P6]
60
17°
40 [P2]
[P5]
10mm 47.5mm
20

20 40 60 80 100 120 140 Z


434GKeg.FH7

Fig. 4-34: Thread cutting - taper thread

Thread lead: 2.5 mm


Thread depth: 3 mm Thread depth per
cut: 1.5 mm
NC program:
G00 G54 G90 G06 G08 X100 Z130 S2000 M03 [P1] Starting conditions
st
G01 X39.89 F1500 [P2] Feed for 1 cut
st
G33 X71.99 Z25 K2.5 P90 [P3] 1 thread thru hole
G00 X100 [P4] Withdraw X axis
Z130 [P1] Starting point
nd
G01 X38.39 F1500 [P5] Feed for 2 cut
nd
G33 X70.49 Z25 K2.5 P90 [P6] 2 thread pass
G00 X100 [P4] Withdraw X axis
M05 Spindle OFF
RET Program end

P5 = 47.5 - 3 = 44.5
P5 = 44.5 - 2 ∗ ( 10 ∗ TAN17° ) = 38.39
P6 = 38.39 + ( 105 ∗ TAN17° ) = 70.49

P2 = 47.5 - 1.5 = 46
P2 = 46 - 2 ∗ ( 10 ∗ TAN17° ) = 39.89
P3 = 39.89 + ( 105 ∗ TAN17° ) = 71.99
Fig. 4-35: Calculation of thread starting and end point coordinates for X axis:

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-31

Example: NC program for face thread

X
100

80 [P6] [P3]
[P4]
60

40
[P1]
20 [P5] [P2]

20 40 60 80 100 120 140 Z


435GPlan.FH7

Fig. 4-36: Thread cutting - face thread

Thread lead: 2 mm
Thread depth: 3 mm Thread
depth per cut:
1.5 mm

NC program:
G00 G54 G90 G06 G08 X27.5 Z100 S2500 M03 [P1] Starting con-
ditions
G01 Z78 F1500 [P2] Feed for
st
1 cut
st
G33 X72.5 I2 P180 [P3] 1 thread
thru hole
G00 Z100 [P4] Withdraw
Z axis
X27.5 [P1] Starting
point
G01 Z76.5 F1500 [P5] Feed for
nd
2 cut
nd
G33 X72.5 I2 P180 [P6] 2 thread
pass
G00 Z100 [P4] Withdraw
Z axis
M05 Spindle OFF
RET Program end

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-32 Motion Blocks NC Programming Instructions

Thread Sequences with "G33"


Function G33 – Thread cutting – can be used to program consecutive
chains of thread-cutting NC blocks containing different leads. A thread
sequence can consist of
• single- or multiple-thread longitudinal threads,
• face threads, or
• taper threads
in any desired order, provided that the lead during each segment of the
thread remains constant.

L o n g itu d in a l T h re a d
T h re a d L e a d 1 T h re a d P a s s

2. Segm ent 1. Segm ent

436Laeng2.FH7

Fig. 4-37: Longitudinal threads with 2 pieces with different leads

Syntax G33 <end point [X,Y,Z]> <lead [I,J,K]> <starting angle [P]>
G33 <end point [X,Y,Z]> <lead [I,J,K]>

Thread sequences are programmed as consecutive series of thread-cut-


ting NC blocks. A transition distance is calculated between two thread-
cutting NC blocks for each axis experiencing a velocity change. The ve-
locity change is performed at the maximum permissible acceleration, so
that transition parabolas result.
• G08 contouring mode (velocity-optimal NC block transition) must be
active during thread-cutting sequences. G06 positioning with mini-
mized lag should be activated to ensure that the transition parabola
between the thread NC blocks are as small as possible.
• No function may be programmed between and in the individual thread
blocks of a thread sequence, which would interrupt block preparations
(such as auxiliary functions, computations, etc.).
• If the "Single-block" operating mode is active, each thread-cutting NC
block is processed individually. In this case, a new starting distance is
required for each thread-cutting NC block. Thus, thread-cutting se-
quences are not possible in the "Single-block" operating mode.
All other conditions are the same as in thread cutting.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-33

Example: NC program for thread-cutting sequences

X
100

80
[P6]
60 [P1]

[P5] [P4]
40
[P10] [P9] [P3]
[P2]
20 [P8] [P7]
3rd Section 2nd Section 1st Section

20 40 60 80 100 120 140 Z


437GKett.FH7

Fig. 4-38: Thread-cutting sequences

Thread lead: 1: 3 mm
2: 5 mm
3: 1 mm
Thread depth: 4 mm Thread depth
per cut: 2 mm

NC program:
G00 G54 G90 G06 G08 X60 Z135 S2000 M03 [P1] Starting conditions
G01 X23 F1500 [P2] Feed for first cut
st
G33 Z90 K3 P180 [P3] 1 thread segment /
st
1 pass
nd
G33 X38 Z50 K5 [P4] 2 thread segment /
st
1 pass
rd
G33 Z10 K1 [P5] 3 thread segment /
st
1 pass
G00 X60 [P6] Withdraw X axis
Z135 [P1] Starting point
G01 X21 F1500 [P7] Feed for
nd
2 cut
st
G33 Z90 K3 P180 [P8] 1 thread segment /
nd
2 pass
nd
G33 X36 Z50 K5 [P9] 2 thread segment /
nd
2 pass
rd
G33 Z10 K1 [P10] 3 thread segment
/
nd
2 pass
G00 X60 [P6] Withdraw X axis
M05 Spindle OFF
RET Program end

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-34 Motion Blocks NC Programming Instructions

Tapping without Compensating Chuck "G63" / "G64"


With function G63, threads can be tapped without a compensating chuck.
In thread tapping without a compensating chuck, not only is the spindle
speed controlled (as would be the case in normal tapping), but also the
spindle alignment. The spindle rotation and the feed movement of the
axis, which is programmed together with G63, are linearly interpolated. A
main spindle, which can be positioned, is required for tapping without a
compensating chuck. The spindle must be driven directly (slip); the posi-
tion encoder should be located directly on the spindle.
The CNC supplies two path conditions for tapping without a compensating
chuck. These functions are active only for the duration of the NC block
containing them.
• G63 - Spindle stops at the end of movement
• G64 - Spindle continues to rotate after the end of movement.

Functions G63 and G64 differ only regarding the end of movement.

Syntax G63 <end point [X,Y,Z]> <feed per spindle revolution [F]>
G64 <end point [X,Y,Z]> <feed per spindle revolution [F]>

Two cases are possible when the feed/spindle link is established:


• The spindle is not turning (n=0)
• The spindle is already rotating (n=S)

If the spindle is not turning when the feed/spindle link is established, the
link can be activated at the start of the common acceleration phase so
that the spindle and the feed axis are already accelerating in an interpo-
lating way. The selected acceleration focuses on the weakest axis (main
spindle or feed axis).
If the spindle is already rotating when the feed/spindle link is established,
the feed axis accelerates to the required speed at its maximum accelera-
tion; then the link is activated, so that the main spindle and the feed axis
do not interpolate until the constant-speed range is reached.
• Clockwise or counterclockwise thread tapping is achieved by declaring
the direction of rotation of the spindle: M03 or M04.
• If a different spindle is to be selected for thread tapping using G63/64,
the spindle must be activated by means of the SPF <spindle number>
command prior to NC block G63. The first spindle is always active in
the power-on state.
• Tapping should be performed using function G06 "Positioning without
lag". If G06 is not active with tapping without a compensating chuck or
if analog axis cards are installed, the same gain factor must be set for
the spindle and for the feed axis for G63/G64.
• Functions G08 (Velocity-optimal NC block transition) and G61 (Exact
stop) are meaningless for tapping.
• A main spindle which is stopped at the end of the movement (G63)
can be reactivated using spindle control commands M03/M04 and by
programming the speed value (S value).
• If the tap is turned out of the thread using G64, the spindle stops briefly at
the end point of the NC block in order to change from position-controlled to
speed-controlled mode.
• Except for dwell time G04 and the auxiliary functions, no NC com-
mands can be programmed between the G63 command Tap to depth
<X, Y or Z> and the G63/G64 command Withdraw tap.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-35

• With digital drives, if the spindle is activated prior to the NC block


containing G63 tapping, the spindle will stop briefly in the G63 NC
block in order to switch from speed-controlled mode to position-con-
trolled mode.
• The lead factor feed per spindle revolution must be programmed in a
single NC block containing G63 and G64 by using the F word.
• Depending on the parameter setting, the thread lead can be entered
using 3 or 4 places to the left of the decimal point and, correspond-
ingly, 5 or 4 places to the right of the decimal point.

Example: NC program - tapping with G63

Y X
100 100
[P3]
[P4]
80 [P2] [P3] 80

60 60
[P1] [P4] [P1]
40 40
[P2]

20 20

10 0 -10
20 40 60 80 100 X Z
438g63.FH7

Fig. 4-39: Tapping with G63

NC program using G63:


Spindle stopped at the beginning of the NC block G63
Spindle stopped upon terminated movement
G00 G54 G90 G06 G08 X0 Y0 Z10 Movement commands, interpola-
tion conditions
st
G01 X40 Y50 F2000 [P1] 1 tapping position
BSR .GEBO Branch to tapping subroutine
nd
Y80 [P2] 2 tapping position
BSR .GEBO Branch to tapping subroutine
rd
X90 [P3] 3 tapping position
BSR .GEBO Branch to tapping subroutine
th
Y50 [P4] 4 tapping position
BSR .GEBO Branch to tapping subroutine
G00 X0 Y0 Return to starting point
RET Program end
.GEBO Tapping subroutine
G63 Z-7.5 F2 S500 M03 Tap to depth Z
G63 Z10 F2 S750 M04 Withdraw tap
RTS End subroutine

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-36 Motion Blocks NC Programming Instructions

Spindle is already turning at the start of the G63 block


Spindle comes to a stop when movement stops
G00 G54 G90 G06 G08 X0 Y0 Z10 Motion commands, interpolation
conditions
G01 X40 Y50 F2000 M03 S1000 [P1] 1st tapping position,
spindle ON
BSR .GEBO Branch to tapping subroutine
Y80 M03 S1000 [P2] 2nd tapping pos.,
spindle ON
BSR .GEBO Branch to tapping subroutine
rd
X90 M03 S1000 [P3] 3 tapping position,
spindle ON
BSR .GEBO Branch to tapping subroutine
th
Y50 M03 S1000 [P4] 4 tapping position,
spindle ON
BSR .GEBO Branch to tapping subroutine
G00 X0 Y0 Return to starting point
RET Program end
.GEBO Tapping subroutine
G63 Z-7.5 F2 Tap to depth Z
G63 Z10 F2 S750 M04 Withdraw tap
RTS End subroutine

Example: NC program - tapping with G63 and G64

Y X
100 100
[P4]
80 [P2] [P3] [P3] 80

60 60
[P2]
[P1] [P4]
40 [P1] 40

20 20

10 0 -10
20 40 60 80 100 X Z
439G634.FH7

Fig. 4-40: Tapping with G63 and G64

NC program using G63 and G64:


Spindle is stopped at the beginning of the NC block G63
Spindle continues to rotate upon the end of movement
G00 G54 G90 G06 G08 X0 Y0 Z10 Movement commands, interpola-
tion conditions
st
G01 X40 Y50 F2000 [P1] 1 tapping position
BSR .GEBO Branch to tapping subroutine
nd
X55 Y80 [P2] 2 tapping position
BSR .GEBO Branch to tapping subroutine
rd
X75 [P3] 3 tapping position
BSR .GEBO Branch to tapping subroutine
th
X90 Y50 [P4] 4 tapping position
BSR .GEBO Branch to tapping subroutine
M05 Spindle OFF
G00 X0 Y0 Return to starting point
RET Program end
.GEBO Tapping subroutine
G63 Z-7.5 F2 S1000 M03 Tap to depth Z
G64 Z10 F2 S800 M04 Withdraw tap
RTS End subroutine

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-37

Spindle already rotates at the beginning of the NC block G63


Spindle continues to turn after the end of the movement
G00 G54 G90 G06 G08 X0 Y0 Z10 Movement commands, interpola-
tion conditions
st
G01 X40 Y50 F2000 M03 S1000 [P1] 1 tapping position,
spindle ON
BSR .GEBO Branch to tapping subroutine
X55 Y80 M03 S1000 [P2] 2nd tapping pos.,
spindle ON
BSR .GEBO Branch to tapping subroutine
rd
X75 M03 S1000 [P3] 3 tapping position, spindle
ON
BSR .GEBO Branch to tapping subroutine
th
X90 Y50 M03 S1000 [P4] 4 tapping position,
spindle ON
BSR .GEBO Branch to tapping subroutine
M05 Spindle OFF
G00 X0 Y0 Return to starting point
RET Program end
.GEBO Tapping subroutine
G63 Z-7.5 F2 Tap to depth Z
G64 Z10 F2 S800 M04 Withdraw tap
RTS End subroutine

Tapping "G64" - Speed Reduction


G64 with running spindle If the thread length does not permit tapping at the programmed tapping
and short thread speed because the feed rate of the feed axis cannot be accelerated to the
required speed due to the length of the thread, the spindle speed is re-
duced before the feed axis is started.

Spindle speed or
feed rate
Spindle speed
Feed rate

Synchronous phase

Spindle speed
=
feed rate

Time t
440G64Vor.FH7

Fig. 4-41: Feed rate and spindle speed, tapping with G64

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-38 Motion Blocks NC Programming Instructions

Tapping "G65" - Spindle as Lead Axis


Function G65 can be used to tap threads with main spindles which can be
positioned but cannot be interpolated under position control. In addition,
G65 is used on main spindles which are driven indirectly and in cases
where the position encoders are not located directly on the spindle. A
compensating chuck is usually used for tapping via G65. The feed dis-
tance, which is programmed in conjunction with G65, is dependent on the
main spindle position. However, because of the system-related delay, the
feed will always lag behind the main spindle. This delay is twice as long
when there is a change of the direction of rotation. It is always preferable
to use the G63/G64 functions for tapping without a compensating chuck.

Syntax M05 Spindle STOP


G65 <feed distance per spindle rotation [F]> Activate tapping

Example: NC program - tapping with G65


M05 Spindle STOP
G65 F2 Activate tapping
S500 M03 Speed and direction rotation
Z-10 Tap to depth Z
Z10 S800 M04 Withdraw tap

A main spindle which can be positioned is required for tapping function G65.
• The M05 main spindle must be stopped before G65 (tapping) is acti-
vated.
• When G65 is active, it is not possible to traverse using G00; no circu-
lar and helical interpolation G02/G03 is performed, and no axis refer-
encing G74 is executed. Feed functions relating to the NC block tran-
sitions (G08, G09, G61, G62) are suppressed.
• Axis movements may not be programmed in a G65 NC block.
• The spindle must be activated after the G65 block, while the direction
of tapping (clockwise or counterclockwise), is given by the spindle di-
rection of rotation M03 or M04. The spindle remains inactive unless it
is activated by a movement command of a main axis.
• The linking factor Feed per spindle revolution must be programmed in
a single NC block containing G65 by using the F word.
• Tapping should be performed using the G06 function "Positioning
without lag".
• With main spindles, which are driven directly and in which the position
encoder is located directly on the spindle, the G65 function can also be
used to tap threads without using a compensating chuck, provided the
speed is moderate.
• If G65 is used to select a different spindle for tapping, the spindle must be
activated by means of the "SPF <spindle number>" command prior to NC
block G65. The first spindle is always active in the power-on state.
• G65 is superimposed by G93 or overwritten by G94 or G95, which
automatically stops the spindle.
• Depending on the parameter setting, the thread lead can be entered
using 3 or 4 places to the left of the decimal point and, correspond-
ingly, 5 or 4 places to the right of the decimal point.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-39

Note: If G65 is active, only the linear main axes, X, Y and Z may be
programmed. Other axis letters will result in an error message.
Using G65 together with the APR function (digital SERCOS
drives) while a KSR (combined spindle-turret axis) is used is
not possible.

Y X
100 100
[P4]
80 [P2] [P3] [P3] 80

60 60
[P2]
[P1] [P4]
40 [P1] 40

20 20

10 0 -10
20 40 60 80 100 X Z
441G65.FH7

Fig. 4-42: Tapping with G65

Example: NC program - tapping with G65

NC program using G65:


G00 G54 G90 G06 G08 X0 Y0 Z10 Motion commands, interpolation
conditions
st
G01 X40 Y50 F2000 [P1] 1 tapping position
BSR .GEBO Branch to tapping subroutine
nd
X55 Y80 [P2] 2 tapping position
BSR .GEBO Branch to tapping subroutine
rd
X75 [P3] 3 tapping position
BSR .GEBO Branch to tapping subroutine
th
X90 Y50 [P4] 4 tapping position
BSR .GEBO Branch to tapping subroutine
M05 Spindle OFF
G00 X0 Y0 Return to starting point
RET Program end
.GEBO Tapping subroutine
M05 Spindle STOP
G65 F2 Activate tapping
S500 M03 Speed and
direction rotation
Z-7.5 Tap to depth Z
Z10 S400 M04 Withdraw tap
G94 Cancel G65
RTS End subroutine

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-40 Motion Blocks NC Programming Instructions

4.4 feed

F Word
The feed rate in an NC program is expressed by a feed, which uses the
address letter F and a feed rate, which is stated directly as a constant or
by means of an expression. The programmed feed rate determines the
processing speed for each type of interpolation. The feed rate is restricted
so that the limits entered in the parameters are not exceeded. If the F
word is programmed in conjunction with a function, the meaning can
change. The corresponding type of operation is defined in the corre-
sponding functions (G00, G04, G93, G95).

Syntax F<constant> ⇒ F1000


F<expression> ⇒ F=@50

If the F word is programmed as the feed rate, it becomes the desired


value for the machining speed.

The F word interacts with the associated G code as follows:


Meaning G code Active Format Remarks
Speed programming G94 modal 6 1 Cancelled by G95, G96 or G64. The
5 2 most recent G94 F value is reacti-
before decimal after decimal vated the next time G94 is re-
point point quested.
G95 modal 4 4 Canceled by G94.
3 5 If G95 is repeated, the most recent
before decimal after decimal G95 F value is reactivated.
point point
Feed per revolution G63, G64 block- 4 4 The F value is reactivated if G63,
wise 3 5 G64 are renewed.
This has no effect on the F values
of G94.
G65 modal Condition as with G95!
Time in seconds G04 block- 3 2 Superimposed with F words that
wise were programmed by G94/G95.
Time programming G93 block- 5 2 (Overlay, no influence!)
wise

If the F word appears alone in the NC block, it is assigned to the memory


of the modally active conditions of the feed-specified group. If the F word
appears in an NC block together with one of these functions, the corre-
sponding feed is activated first, and then the F value is placed in the ap-
propriate memory.
• If G94 is active (feed rate programming), the units mm/min. or inch/min.
are used for the feed rate.
• With G63, G64, G65 (tapping), and G95 (feed per revolution), the unit
used for the feed rate is mm/spindle revolution or inches/spindle revolution.
• With G04 (dwell time) and with G93 (time programming), the time in
seconds is entered in the F word.
• The programmed feed rate can be changed via the feed rate override from
0% to 255%. The 100% position corresponds to the programmed value.

The feed values are reset after the controller has been powered on, the
program is loaded into the controller, or after a BST, RET, or control-re-
set. At the beginning of an NC program, the feed values must be pro-
grammed before or together with the first movement command.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-41

Note: The maximum path and axis speed are defined by the machine
builder in the axis parameters.

Time Programming "G93"


The machining time for a programmed path can be defined by the feed
rate function G93 (Time programming). The machining time is determined
via the F word. With the specified machining time, the controller calcu-
lates the required path velocity depending on the limit values.

Syntax G93 F<time in seconds>


G93 is active on an NC blockwise basis and must be programmed in
combination with an F word.
• In the programmed NC block, G93 superimposes G94 or G95.
• The F value which is programmed with G93 does not affect the F val-
ues that were programmed with G94 or G95.
• The F value programmed together with G93 can be programmed with
five digits to the left and two digits to the right of the decimal point.

Example: NC program using G93

Y X
[P4]

[P3] [P4]
100 100
[P2]
80 80

60 60

40 40
[P1]
[P1]
20 20

20 40 60 80 100 X Z 10 0 -10

442g012.FH7

Fig. 4-43: Linear interpolation, G01 with 2 axes and time programming

NC program:
G00 G90 G54 G06 G08 Motion commands, interpolation
conditions
X0 Y0 Z10 S3000 M03 Starting position, spindle ON
G93 G01 X26.26 Y18 Z5 F0.97 [P1] Starting position, time
programming
G93 Z-5 F0.3 Feed Z axis
G93 Y80 F1.86 [P2] linear interpolation, 1 axis
G93 X41 Y93.5 F0.6 [P3] linear interpolation, 2 axes
G93 X111 F2.1 [P4] linear interpolation, 1 axis
G00 Z10 M05 Z axis to safety distance
RET Program end

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-42 Motion Blocks NC Programming Instructions

Velocity Programming "G94"


Syntax G94 F<feed rate in mm/min>
G94 F<feed rate in inch/min>

With function G94 "Velocity programming", the programmed F word is in-


terpreted as feed in mm/min. G94 is the power-on state of the CNC. The
feed distance is programmed for linear axes in the active unit (mm/inch).
The feed distance with rotary axes is programmed in units of the feed
constant, which is programmed in the axis parameters.
• Depending on the settings in the process parameters, G94 may be the
power-on default. G94 is modally active and is canceled by G95, G96,
or G65.
• After the controller is turned on, after an NC program is loaded, or
when a BST, RET or a control-reset is executed, G94 is set automati-
cally depending on the setting in the process parameter, and the feed
values (F values) are reset.
• The special requirements that apply to the path feed rate depending on
the nominal radii when machining with the C axis are described in sec-
tion "Rotary Axis Programming".
• The F value that was programmed together with G94 can be pro-
grammed with 6 digits before and with 1 digit behind the decimal point,
or with 5 digits before and 2 digits behind the decimal point.

Feed Rate per Spindle Revolution "G95"


Function G95 "Input feed rate in inches or mm per spindle revolution"
causes the programmed F word to be interpreted in mm or inches per spin-
dle revolution. The contour feed rate depends on the value of the actual
spindle speed. If a position encoder is not located on the main spindle,
the contour feed rate depends on the spindle speed command value.

Syntax G95 F<input feed rate in inches or mm per spindle revolution>


G95 "Feed per revolution" remains modally active until it is canceled by
G94 or G65, or until a reset is performed at the end of the program (RET),
or an automatic reset is performed via BST. G93 (Time programming)
superimposes G95.
• In the power-on state, G95 always applies to the first spindle. If G95 is
to be based on a different spindle, the desired spindle must be se-
lected prior to the G95 NC block by using the SPF <Spindle number>
command.
• Depending on the settings in the process parameters, G95 may be the
power-on default. G95 (Input feed rate in inches or mm per spindle
revolution) remains modally active until it is canceled by G94 or G65.
G93 (Time programming) superimposes G95.
• After the controller is turned on, after an NC program is loaded, or
when a BST, RET or a control-reset is executed, G95 is set automati-
cally depending on the setting in the process parameter, and the feed
values (F values) are reset.
• G95 is automatically activated upon the selection of G96. If G95 was
not previously active, an error message is issued because of the
missing F value.
• If G95 is active, axis movements which were generated via G01, G02
or G03 are not performed unless the spindle is turning.
• Axis movements in rapid traverse (G00) superimpose G95 with G94
and are performed at the feed rate entered in the parameters or at the
feed rate programmed with G00 in the NC block.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-43

• Programmed axis movements occurring when the spindle is off or with


S0 prevent further program execution and result in an error message.
• The programmed F values for the functions G94 and G95 do not inter-
act with one another.
• The spindle override affects the spindle speed and the feed rate when
G95 is active.
• The F value that was programmed together with G95 can be pro-
grammed with 4 digits before and 4 digits after the decimal point, or
with 3 digits before and 5 digits after the decimal point.

Dwell Time "G04"


The function G04 "Dwell time" can be used to program a delay time in the
NC program for functions such as relief cutting, machine control func-
tions, etc.

Syntax G04 F<time in seconds>

G04 is active on an NC block-by-block basis and must be programmed in


combination with an F word. The F word will then correspond to a dwell
time in seconds.
• The maximum directly programmed dwell time is 999.99 seconds
(16.7 minutes) and the maximum resolution is 0.01 seconds.
• The F value programmed together with G04 can be programmed with
three digits before and two digits after the decimal point.
• Only functions M, S, and Q can be programmed in a dwell time-pro-
grammed NC block.
• The dwell time programmed in the F value using G04 does not affect
the modally active F values (feed rate).
• The F value programmed together with G04 can be programmed with
3 digits to the left and 2 digits to the right of the decimal point.

Example: NC program - with G04

G00 G90 G54 G06 G08 Movement commands, interpolation con-


ditions
X0 Y0 Z10 S3000 M03 Starting position, spindle ON
G04 F3.5 Delay of 3.5 sec for spindle ramp-up
G01 X26.26 Y18 Z5 F2000 Machining
.
RET Program end

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-44 Motion Blocks NC Programming Instructions

Basic Connections between Programmed Path Velocity (F) and Axis


Velocities
Under interpolation conditions, the CNC computes the path velocity as
follows:

Calculating the
path velocity F= (
X& 2 + Y& 2 + Z& 2 + A& ∗ R X )2 + (B& ∗ RY )2 + (C& ∗ RZ )2
Fig. 4-44: Calculating the path velocity

Example: Path velocity for thread cutting

Lead P

dkkfgjkd

Z=Vz
X= Vx Velocitiy in X direction
Y= VY Velocity in Y direction
C Rz = VC F Z= VZ Velocity in Z direction
A = Angle velocity of the rotary axis A
B = Angle velocity of the rotary axis B
C = Angle velocity of the rotary axis C
F = Path velocity
Rx = Radius of the axis in X direction
Ry = Radius of the axis in Y direction
Rz = Radius of the axis in Z direction

443Schneid.FH7

Fig. 4-45: Path velocity for thread cutting

In this example, the following equation results from computing the path
velocity:

(
F = Z& 2 + C& ∗ RZ )2
Fig. 4-46: Example - path velocity calculation

Basically, two possibilities to program the F value can be considered.

Without RZ The CNC interprets the F value as a velocity in the direction Z.


NC program: G01 Z... C... F...
Computation:

F = Z& 2 = P ∗ nW
nw: Velocity
P: Thread pitch
Fig. 4-47: F value as velocity

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-45

Effect:

C = Vc
F = Vz = Z

444VorO.FH7

Fig. 4-48: Feed velocity (F) without RZ

Here, the C axis is interpolated simultaneously.

With RZ The CNC interprets the F value as the resulting path velocity.
NC program: G01 Z... C... RZ... F...
Computation:

(
F = Z& 2 + C& ∗ RZ
2
)
mit Z& = P ∗ nW
&
und C ∗ RZ = 2π ∗ RZ ∗ nW

⇒ F = P 2 + (2π ∗ RZ )2 ∗ nW

Fig. 4-49: F value as resulting path velocity

Effect:

Z = Vz

C = Vc F

445VorM.FH7

Fig. 4-50: Feed velocity (F) with RZ

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-46 Motion Blocks NC Programming Instructions

Feed Limitation
Besides the maximum axis velocity that is defined in axis parameter
Cxx.016, the axis velocity can be limited with another dimension during
machining.

|v|

Max. Axis Speed (Parameter)

Safety-Technical Axis Speed

max_achsgeschw.FH7

Fig. 4-51: Axis velocity limits

The safety-related axis velocity allows the machine builder to, for exam-
ple, reduce the maximum allowable axis velocity (and thus the path veloc-
ity) while machining a heavy workpiece or to open the guard door.

Machine Data
The safety-related axis velocity is axis-specifically adjustable in the ma-
chine data, page 11.

STRUCT 11 Feed-velocity limitation


Safety velocity limit active BOOL NoNC,NoPLC,NoBOF,NoPwBOF
Max. safety-rel. velocity VELO NC,PLC,BOF,PwBOF
END_STRUCT
ARRAY [
Axis No. IP_AXIS 1-12
] OF STRUCT

Machine data element "Max. safety velocity (PLC)" can be modified in the
NC program and in the PLC by the machine builder.
Element "Safety velocity limit active", which is intended to visualize the
PLC interface signal, can only be accessed in read mode

PLC Interface Signal


AxxC.SPEED The axis control signal activates safety-related velocity limiting.

AxxS.SPEED The axis status signal is set as soon as safety-related velocity limiting is
active.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-47

Boundary conditions
• A set-up engineer can change the safety-related axis velocity in the
machine data only if he has the correct password and no NC program
is active at the time.
• The safety-related axis velocity can be modified from the PLC at any
time via MTD_WR.
• For all axes of a process, it is possible to program a safety-related axis
velocity within an NC block via the MTD command.
• With the assistance of the axis-specific control signal "AxxC.SPEED",
the PLC can turn the monitoring of the safety-technical axis velocity on
and off.
• The user can identify the effectiveness of the safety-technical axis
velocity in the machine data via data element "Safety velocity limit ac-
tive".
• After the PLC interface signal has been set, the safety-related axis
velocity will take effect in the next NC block or after an immediate stop.
• A change of the safety-related axis velocity becomes active in the next
NC block or when an emergency stop occurs.
• With each change of the limits, the PLC status signal is set to "0" for a
PLC cycle.
• The NC does not consider any changes of the desired value which
have been caused by the feed override.

Adaptive Feed Control "G25" / "G26"


Adaptive feed control permits the change of the feed velocity of an axis or
the path velocity of the interpolating axes depending on the motor cur-
rent/torque of a spindle or a feed axis, so that (when milling, lathing or
grinding) the machining power or the machining volume is kept constant.
This provides the following:
• a better surface quality,
• a shorter processing time, and
• in particular, a higher safety level against over-stressing the tool, the
workpiece and the machine.
The function is activated with parameter Bxx.062. The feed control pa-
rameters are provided in machine page 30.

Boundary conditions
• Adaptive feed control can be utilized in conjunction with digital spindles
/ feed axes with SERCOS Interface.
• All axes and spindles involved in adaptive feed control must belong to
a process. This means the reference axis must also belong to the pro-
cess of which the feed of the path is to be controlled.
• Furthermore, all axes and spindles involved in adaptive feed control
(incl. all feed axes involved in the interpolation) must be based on an
APR. (The CPU informs the APR to which axes the distribution of the
internal override is to be performed.)
• Adaptive feed control can not be used with the following functions:
• - Homing (G74),
• - Feed to positive stop (G75).
• Furthermore, adaptive feed control is available only in the operating
modes automatic, semi-automatic and MDI.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-48 Motion Blocks NC Programming Instructions

• The NC automatically cancels adaptive feed control (and sets G25) in


the case of a control reset as well as at the program end.

Syntax
G25 Adaptive feed control OFF (default)
G26 Adaptive feed control ON

Parameters
If the machine builder answers process parameter Bxx.062 "Adaptive
feed control" with "Yes", then further process parameters appear as fol-
lows:
• Bxx.063 Reference axis for adaptive feed control
• Bxx.064 Command machining torque
• Bxx.065 Minimum machining torque
• Bxx.066 Maximum idling torque
• Bxx.067 Maximum feed reduction
• Bxx.068 Amplification
• Bxx.069 Measuring period

Machine Parameters
The process-specific page "Adaptive feed control" (page 30) has the fol-
lowing structure:

MPage30.bmp

Fig. 4-52: Structure of machine data page 30

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-49

Idle Thrust Measurement "ITM"


The ITM (Idle Thrust Measurement) command is used for measuring the
idling torque of a reference axis defined according to its axis significance
in process parameter Bxx.063 Reference axis for adaptive feed con-
trol or in the machine data.

Syntax ITM
The ITM command may be carried out
• together with G26 Switch on adaptive feed control at the beginning
of the machining process as well as
• independent of adaptive feed control (G26).

The measured idling torque is stored in machine data page 30 of machine


data element 005 Current idling torque and in AXD parameter P-7-3650
Measured idling torque.

PLC Interface Signals


Two new PLC interface signals were implemented for the function "Adap-
tive feed control". These are used to evaluate the measuring results.
• PxxS.THMIS “Thrust Missing” depends on process parameter Bxx.065
and
• PxxS.EXCTH “Excessive Thrust” depends on process parameter Bxx.064.

Thrust Missing
Type Process status signal

Description PxxS.THMIS (THrust MISsing)

Meaning PxxS.THMIS = 1:
The machining torque has not exceeded the preselected minimum ma-
chining torque Bxx.065 during machining.
PxxS.THMIS = 0:
The machining torque has exceeded the preselected minimum machin-
ing torque Bxx.065 during machining.

Updating The NC updates the interface signal by turning adaptive feed control on
(G26) and off (G25). The NC resets this signal at the program end as well
as after a control reset.

Method of operation If the machining torque does not exceed adaptive feed control Bxx.065
during machining with adaptive feed control active, the NC reports this as
soon as adaptive feed control is turned off by setting interface signal
"Thrust Missing" (PxxS.THMIS).

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-50 Motion Blocks NC Programming Instructions

Excessive Thrust
Type Process status signal

Description PxxS.EXCTH (EXCessive THrust)

Meaning PxxS.EXCTH = 1:
The current feed reduction exceeds the maximum feed reduction Bxx.067.
PxxS.EXCTH = 0:
The current feed reduction does not exceed the maximum feed reduction
Bxx.067.

Updating The NC updates the interface signal by turning adaptive feed control on
(G26) and off (G25). The NC resets this signal at the program end as well
as after a control reset.

Method of operation If the current feed reduction exceeds the maximum feed reduction
Bxx.067 during machining with adaptive feed control active, the NC re-
ports this by setting interface signal "Excessive Thrust" (PxxS.EXCTH).

Note: The NC continues machining, regardless whether the current


feed reduction exceeds the maximum feed reduction or not.
Only if the current feed reduction reaches 100% (meaning the
feed velocity = 0 mm/min) and the adjusted maximum feed re-
duction Bxx.067 or machine data variable 013 is less than
100% does the NC stop the machining process and generate
error message 510 "100% feed reduction@axis".

Problem of "Inclined Axis"


In the case of an "inclined axis without counterforce", a torque for holding
the axis in position is required. This holding torque is added as an offset
to all torques that have been recorded so far. This results in a distortion of
the torques required for adaptive feed control.

Note: Adaptive feed control is not possible for a "hanging axis" as


the reference axis.

Solution The torque offset (standstill torque) required to hold the axis must be
eliminated for adaptive feed control.
A command is required that records the standstill torque.
The standstill torque can be recorded with the following AXD command:
• APR SERCOS parameter P-7-3651
This refers to the specified reference axis in the parameters or machine
data. During adaptive feed control, the standstill torque is taken into ac-
count while the torque is being generated.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-51

The machine data have been supplemented by two elements:


Adpt. feed control active
Reference axis
Amplification
NEW Measuring period of standstill torque
NEW Standstill torque
Measuring period of idling torque
Idling torque
Maximum idling torque
Current machining torque
Peak machining torque
Minimum machining torque
Limiting machining torque
Current feed reduction
Peak feed reduction
Maximum feed reduction
In the case of recording with APR SERCOS command P-7-3651, a pause
for the time specified in machine data parameter "Measuring time stand-
still torque" occurs and the standstill torque is generated. The torque de-
termined is stored in parameter "Standstill torque".
Parameters "Measuring time of standstill torque" and "Standstill torque"
have the same unit and rights as "Measuring time of idling torque" and
"Idling torque".

Parameter Value Assignment


The feed adaptation function is controlled by machine data page 30
"Adaptive feed control". If no reference axis (=0) has been yet logged in
the machine data page, the following data are used as the parameter
basis:
<Machine data element> = <Process parameter>
002 Reference axis = Bxx.063 Reference axis for adaptive
feed
003 Amplification = Bxx.068 Amplification
004 Measuring duration = Bxx.069 Measuring duration
006 Max. idling torque = Bxx.006 Max. idling torque
009 Min. machining torque = Bxx.065 Min. machining torque
010 Limit machining torque = Bxx.064 Limit machining torque
013 Max. feed reduction = Bxx.067 Max. feed reduction

Additional Documentation
A detailed description of the function is available under order number
"DOC-MTC200-AD*FEED*V19-FK01-EN-P"

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-52 Motion Blocks NC Programming Instructions

4.5 Spindle speed

S Word for the Spindle Speed Specification


The spindle speed in an NC program is expressed by a speed word that
uses the address letter S and a speed which is stated directly as a con-
stant or by means of an expression. A spindle code can also be added to
the speed word if more spindles are present. The spindle speed is re-
stricted in such a way that the limits entered in the parameters are not
exceeded. The S word is interpreted, if spindle speed G97 in rpm is ac-
tive, as the spindle speed value. G97 is the power-on state of the CNC.
The following chapters describe how the S word interacts in conjunction
with the various spindle functions (G92, G96, G97, M19).

Syntax S<constant> ⇒ S5000


S<expression> ⇒ S=@55-100
with enhanced address format:
S<index> <constant> ⇒ S2 3500
S<index> <expression> ⇒ S3=@60

The spindle speed value ranges from 0 to the maximum value entered in
the spindle parameters.
The S value acts with the associated spindle functions as follows:
Meaning G / M Code Active Format Remarks
Spindle speed in G97 with modal 5 before deci- 2 after decimal If G97 is programmed after G96 is
RPM M03/M04 mal point point active, the most recently active
Mx03 / Mx04 speed is taken on as the new speed
command value.
(x = index [1 - 3]) M19 block- 3 2 Spindle positioned in degrees
Mx19 wise
Constant cutting G96 modal 5 2 Canceled by G97.
speed
Spindle speed G92 Only ac- 5 2 Canceled by G97; the G92 value is
limitation tive with reactivated the next time G96 is
G96. Mo- used.
dally ac-
tive until
G97.
Constant grinding G66 modal 5 2 Canceled by G97/G96
wheel circumferen-
tial speed

If the S word appears alone in the NC block, it is assigned to the memory


of the modally active spindle functions. If the S word appears in an NC
block together with one of the spindle functions, the corresponding spin-
dle function is activated first; then the S value is placed into the appropri-
ate memory.
Up to 3 spindles can be used in a process. Thus, the spindle index is lim-
ited to a value range of 1 to 3. If the spindle index is not declared when
there is more than one spindle in the process, the spindle speed specifi-
cation will then apply to the first spindle. Each spindle has its own memory
for the S values. This prevents S values influencing each other.
• The programmed spindle speed can be changed via the spindle over-
ride from 0% to 255%. The 100% position corresponds to the pro-
grammed value.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-53

• The S value can be entered with 5 digits before and 2 digits behind the
decimal point.
• The spindle speed values are reset after the controller has been pow-
ered on, the program is loaded into the controller, or after a BST, RET,
or control-reset.
• If the spindle index is not declared when there is more than one spin-
dle in the process, the spindle speed specification will then apply to the
first spindle.
• The direction of rotation of the main spindle is determined by the M
function M03 (spindle clockwise) and M04 (spindle counterclockwise). It
must be programmed if more than one spindle is present in a process:
M103 / M104 for the first spindle,
M203 / M204 for the second spindle, and
M303 / M304 for the third spindle

Each spindle can be requested once in a single NC block.

Example:
M103 S1 1500 M203 S2 2500 M303 S3 3500

Note: The machine builder specifies the maximum spindle speed in


the axis parameters.

Select Main Spindle "SPF"


If several spindles are being used in a process, certain functions such as
G96 (constant surface speed) must be allowed to act on another spindle
in addition to the first spindle.

Syntax SPF <spindle number>


The following functions depend on the selected main spindle:
• G33 Thread cutting
• G63/G64 Tapping
• G65 Tapping; spindle as lead axis
• G95 Feed per rotation
• G96 Constant cutting speed

The first spindle is always active in the power-on state. If one of the above
functions acts on another spindle other than the first spindle, the refer-
ence spindle must be selected first using SPF <spindle number>.
• The reference spindle must be selected at least one NC block prior to
one of the above-mentioned function requests.
• SPF <spindle number> remains modally active until it is overwritten
with a different spindle number or is automatically set to the first spin-
dle at the end of the program (RET) or by BST.
• The programming of the spindle speed G97 in rpm is active for all
spindles present in the process. The reference spindle for one of the
above-mentioned functions must therefore be reset after G97 has
been programmed.
• SPF <spindle number> may be used only for main spindles that are in
the spindle mode. A main spindle which is in the rotary axis mode
cannot be selected as a reference spindle.
• Interrogating the reference spindle with SPF, SPT, or SPC as an oper-
and is possible in a separate NC block.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-54 Motion Blocks NC Programming Instructions

Example:

@10 = SPF The reference spindle number is programmed in variable 10.


nd
Example: NC program - longitudinal thread machining with the 2 spin-
dle

X
100

80 [P4] [P1]

60
[P3]
[P2]
[P6]
40 [P5]

20

20 40 60 80 100 120 140 Z


446Laeng2.FH7
nd
Fig. 4-53: Thread cutting - longitudinal thread with the 2 spindle

Thread lead: 3mm


Thread depth: 4mm Thread depth per cut: 2mm

G00 G54 G90 G06 G08 X80 Z130 [P1] Starting conditions
SPF 2 Reference spindle selection
S2 2000 M203 Spindle 2 ON
st
G01 X45.5 F1500 [P2] Feed for 1 cut
st
G33 Z30 K3 P180 [P3] 1 thread thru hole
G00 X80 [P4] Withdraw X axis
Z130 [P1] Starting point
nd
G01 X43.5 F1500 [P5] Feed for 2 cut
nd
G33 Z30 K3 P180 [P6] 2 thread pass
G00 X80 [P4] Withdraw X axis
M205 Spindle 2 OFF
RET Program end

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-55

Constant Grinding Wheel Peripheral Speed (SUG) "G66"


With G66, the programmed value in m/s or feet/s invokes a constant
grinding wheel peripheral speed with automatic adjustment of the spindle
speed to the individual grinding wheel diameters.

Syntax G66 S<constant grinding wheel peripheral speed>


G66 is assigned to group 8 of the G code and consequently can be can-
celled with G96 or G97.
G66 relates to the current spindle. A preceding SPF<spindle number>
permits the SUG to be selected for any spindle.

Boundary conditions • After the SUG has been selected with G66, all programmed desired
speed values for the addressed spindle are interpreted in all operating
modes as m/s or feet/s.
• The grinding wheel peripheral speed remains in effect until the tool
data record is removed from the corresponding spindle or until the
spindle is stopped by control-reset in response to PLC signal
AxxCSPRST.
• The required spindle speed is calculated after the SUG has been se-
lected.
• The corresponding tool data elements of the addressed spindle are
used for calculating and monitoring the speed.
• If SUG is selected with G66, the corresponding spindle must contain a
valid tool data record (tool codes 1, 2 and 3 [correction type ≥ 3]). Oth-
erwise, an error message will be generated.
• If SUG is selected with G66, the corresponding length registers for the
wheel diameter must be >0; an error message will be generated if this is
not the case.
• A new speed is calculated if a new S value is programmed or if a ge-
ometry register which is relevant to the wheel diameter is changed in
the next NC block.
• The data elements of the D correction are currently excluded from the
speed calculation.
• G66 is cancelled via G96 or G97 or BST, RET and M30.

Calculation formula:

SUG[ m / s ] ∗ 60000 SUG[ ft / s ] ∗ 720


S[min −1 ] = S[min −1 ] =
d AKT [ mm] ∗ π d AKT [inch ] ∗ π
S: spindle speed [rpm]
SUG: Grinding wheel peripheral speed [m/s or feet/s]
dAct : Grinding wheel diameter [mm or inch]

Note: The data elements of the basic tool data "Tool code and repre-
sentation type" that are necessary for grinding, as well as the
selection of SUG with G66, become active only if the label
"Grinding" is set in system parameter "Technology".

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-56 Motion Blocks NC Programming Instructions

Constant Surface Speed "G96"


The CNC controller uses function G96 "Constant surface speed" to de-
termine the correct spindle speed to match the current turning diameter.
G96 is a typical lathe function; face turning is the most frequent applica-
tion. The feed axis for G96 is derived from the typical G18 (ZX) axis as-
signment of a lathe, so that the X axis is defined as the feed axis. If G96
is active, the spindle speed is reciprocal to the distance between the tool
tip and the rotating axis, so that the spindle speed increases as the dis-
tance becomes smaller.

Syntax G96 S<constant surface speed in m/min>


With G00 active, the spindle speed is set independently of the current X
position to the speed which results at the end of the NC block. G96 re-
mains active; however, the link to the feed movement is temporarily un-
available. The NC block is terminated if the spindle has reached its com-
mand speed and the feed axes have reached their end points.
G95 is automatically activated if G96 is selected. If G95 was not previ-
ously active, an error message is generated because of the missing F
value.
With very small X values, the spindle speed would become too large;
therefore, the spindle speed is limited to the maximum spindle speed set
in the parameters.
When G96 is active, the S value is interpreted as the surface speed. The
spindle speed is calculated based on the relation:

vc
S=
(2 ∗ r ∗ π )
S: spindle speed [rpm]
vc: surface speed [mm/min]
r: effective radius [mm], distance to turning axis
Fig. 4-54: Calculation of spindle speed

• In the power-on state, G96 always applies to the first spindle. If G96 is
to be based on a different spindle, the desired spindle must be se-
lected prior to the G96 NC block by using the SPF <spindle number>
command.
• Depending on the settings in the process parameters, G96 may be the
power-on default. G96 (constant surface speed) remains modally ac-
tive until it is canceled by G97.
• After the controller is turned on, or after an NC program is loaded, or when
a BST, RET or control reset occurs, G96 is set automatically depending on
the setting in the process parameter and the spindle speed values (S val-
ues) are reset.
• If the S value is changed while G96 is active, the S value change must
be programmed together with G96.
• When G96 is active, the maximum spindle speed can be limited by the
command "G92 S <spindle speed>".
• The spindle override is limited to 100% when G96 is active. Reducing
the spindle override to less than 100% results in a reduction of the
surface speed.
• If G96 is cancelled by G97, then the most recent active spindle speed
is taken on as the new desired spindle speed value.
• As of version V22, process parameter Bxx.071 "Reference coordinate
system for G96" can be used to select the reference system for de-
termining the spindle speed. In the selection of the machine coordinate
system as the reference system, the NC takes the active tool length

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-57

compensation into account, so that the resulting spindle speed refers


to the tip of the tool. When the tool coordinate system is activated as
the reference system, the active zero offset is also included in the
speed calculation.

Example: NC program - face turning with G96

X
100

80 [P5] [P2]
[P1]
60

40
[P4]
20 [P6] [P3]

20 40 60 80 100 120 140 Z


447Plan.FH7

Fig. 4-55: Face turning

G00 G54 G90 G06 G08 X72.5 Z100 [P1] Starting conditions
S1 2500 M103 Spindle ON
st
G00 Z78 [P2] Feed for 1 cut
st
G96 X27.5 S1 400 [P3] 1 face turning pass
G00 Z100 [P4] Withdraw Z axis
X72.5 [P1] Starting point
nd
G00 Z76.5 [P5] Feed for 2 cut
nd
G96 X27.5 S1 400 [P6] 2 face turning pass
G00 Z100 [P4] Withdraw Z axis
M105 Spindle OFF
RET Program end

Spindle Speed Limitation"G92"


The function G92 can be used to set an upper spindle speed limitation
while G96 is active. The surface speed is kept constant while G96 is ac-
tive. In the case of face lathing or cutting down to the center of rotation,
this can theoretically lead to an infinitely high spindle speed. Due to ma-
chining-related reasons, it may be necessary to limit the maximum spindle
speed to a value which is smaller than the maximum spindle speed set in
the parameters. G92 is used to set a maximum upper limit for the spindle
speed while G96 is active.

Syntax G92 S<upper spindle speed limit>


G92 is active only for the NC block in which it is located. The limit set for the
spindle speed remains modally active until it is overwritten with a new speed
limit by programming a new G92 or is reset by programming G92 S0.
• A speed limitation programmed using G92 remains modally active until
it is canceled by programming G92 S0 or is automatically reset at the
end of the program RET or by BST.
• Due to the programming of G97, the set spindle speed limit by using
G92 becomes inactive. If G96 is reprogrammed it becomes active
again.
• No further functions may be programmed in an NC block containing G92.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-58 Motion Blocks NC Programming Instructions

Additional Spindle Speed Limitations


Besides the maximum spindle speed for HS operation, which is defined in
axis parameter Cxx.049, the maximum spindle speed can be limited dur-
ing machining via further dimensions.

|n|
Max. Machine-Specific RPM (Parameter)

Max. Safety-Technical RPM (PLC)

Max. Programmable RPM (CNC)

Max. RPM for Constant Cutting Speed (G92)

max_spindeldreh.FH7

Fig. 4-56: Spindle speed limitations

Machine Data
The maximum safety-related speed (PLC) and the maximum program-
mable speed (CNC) are axis-specifically adjusted in page 2 of the ma-
chine data.

STRUCT 2 Spindle speed limitation


Safety speed limit active BOOL NoNC,NoPLC,NoBOF,NoPwBOF
Max. safety-rel. speed (PLC) SPEED NoNC,PLC,NoBOF,NoPwBOF
Max. technol. speed (CNC) SPEED NC,PLC,BOF,PwBOF
END_STRUCT
ARRAY [
Axis No. SP_AXIS 1-12
] OF STRUCT

PLC Interface Signal


AxxC.SPEED The safety-related speed limitation is activated with the axis control signal.

AxxS.SPEED The axis status control signal is set as soon as the speed limitation is
active.

Boundary conditions
• A set-up engineer can change the programmable speed in the ma-
chine data only if he possesses the special password and if no NC
program is presently active.
• The speed limits can be modified from the PLC at any time via
MTD_WR.
• The speed limit for all spindles of a process can be programmed within
an NC block via the MTD command.
• With the assistance of the axis-specific control signal "AxxC.SPEED",
the PLC can turn the monitoring of the speed limits on and off.
• The user can identify the effectiveness of the speed limits in the ma-
chine data via the data element "Safety speed limit active" and via the
control signal "AxxS.SPEED".
• The NC monitors the spindle speed in accordance with the speed lim-
its in speed mode only if the control signal "AxxC.SPEED" is set.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-59

Changes of the speed limits as well as the activation and deactivation


of the monitoring are immediately taken into account by the NC.
• With the activation of the main spindle synchronization, the NC com-
putes, considering all transformation ratios and speed limits, the
maximum permissible speed of the master spindle. The NC recalcu-
lates the maximum speed of the leadscrew each time that the speed
limit for the leadscrew or synchronous spindles changes or each time
a safety-related speed limit is activated or deactivated. A possible
necessary limitation is performed synchronously for all spindles in-
volved in the synchronization.
• If the actual speed of the spindle lies beyond a speed limit just as the
interface signal "Activate limitation" has been activated, then the NC
stops the corresponding spindle, taking the smallest maximum speed
limit of the other speed limits into account.
• If a coupling (G33, G63, G64, G65, G95) or main spindle synchroniza-
tion is active at the moment of activation, the NC will adapt not only the
spindle speed but also the path velocity of the feed axes and/or spin-
dles involved in the coupling or synchronization.
• With each change of the limits, the PLC status signal is set to "0" for a
PLC cycle.
• Changes of the desired speed via spindle override are not considered.
• Where PLC-controlled spindles are concerned, the limited speed has
to be read and transmitted to the external spindle upon each positive
edge of this status signal.

Safety-Related Speed Limit


The safety-related speed limit allows the machine builder, for example, to
limit the spindle speed when a new chuck is to be used or if the guard
door is to be opened.

Programmable Speed Limit


The programmable speed limit allows the NC programmer to limit, from a
technological point of view, the allowable spindle speed.

Spindle Speed in RPM "G97"


With function G97 "Spindle speed in RPM", the programmed S value is
interpreted in rpm. G97 is the power-on state on the CNC; it remains
modally active until it is overwritten by G96.

Syntax G97
• Depending on the settings in the process parameters, G97 may be the
power-on default. G97 – Spindle speed in rpm – remains modally ac-
tive until it is canceled by G96.
• After the controller is turned on, or after an NC program is loaded, or
after a BST, RET or control reset, G97 is set automatically depending
on the setting in the process parameter and the spindle speed values
(S values) are reset.
• If G96 is cancelled by G97, then the most recent active spindle speed
is taken on as the new desired spindle speed value.
• The programming of G 97 is active for all spindles present in the proc-
ess. The selection of the reference spindle using SPF must therefore
be reset after G 97 has been programmed.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-60 Motion Blocks NC Programming Instructions

4.6 Rotary Axis Programming

Effective Radii "RX", "RY", "RZ"


With all interpolation movements using G00 and G01, the components of
the local vector are assumed constant during an NC block. The transla-
tion and rotation movements are performed at constant speed. The
speed, deflection-point speed and acceleration components of all axes
involved in the movement are calculated using the same method as be-
fore; however, the rotary main axes are taken into account. For the abso-
lute distances to the individual main axes, the effective distances are
specified with labels RX, RY and RZ. The CNC considers the distance
segments caused by the rotation of the rotating main axes only if the ap-
pertaining effective distances RX, RY, and RZ are specified to the associ-
ated linear main axis at which the rotation is performed.
• The effective distances RX, RY, and RZ indicate the absolute distance
to the respective linear main axis. They therefore may not be pro-
grammed using a sign in the NC program.
• Effective distances with a value of 0 are not programmed.
• The programming of the effective distances in the NC program is ac-
tive for a single NC block and must be programmed in the NC block in
which it is to be active.
• The effective distances can be programmed in any desired order in the
NC program and without reference to the rotary axes.
• Unreasonable entries for effective distances can cause the rotary main
axes to turn too quickly or too slowly, or they can result in no speed
components at all.

Note: In conjunction with the KDA main spindle drive, it is essential to


perform the C-axis movement with G06 "Low following error in-
terpolation".

Example: NC program - spiral groove

C axis

Effective
radius
RZ
50 mm

70 mm Y
30 mm

448Spira.FH7

Fig. 4-57: Spiral groove machining on end surface

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-61

NC program:
G90 G06 G17 Machining plane XY, end surface


G00 X-30 Y0 Z501 C90 Approach; positioning of C-axis
G01 Z497 F500 Lowering the cutter
[spiral groove machining]
G01 G91 X-40 C-270 RZ50 F1200 Spiral groove on the end surface


RET Program end

NC Program Changeover between Spindle and C Axis


The changeover between C axis mode and main spindle mode is per-
formed in terms of the NC syntax by programming the C axis (Cxxx.xxx)
or the main spindle (M03 Sxxxx).
If the C axis is programmed in the following NC block while the main
spindle mode is active, the CNC performs the changeover with the assis-
tance of the PLC. NC block preparation and NC block processing are
stopped until the changeover operation is completed.
The same mechanism is active when the changeover from C axis mode
to main spindle mode occurs.
• After the main spindle to C axis mode changeover, all spindles active
in the process must be traversed once with G90 (Absolute data entry
of dimensions) before G91 (Data entry as incremental values) can be
used.

Changeover with rotary axis- M19 S0 Orientate main spindle


capable main spindle drive G00 G54 G90 X100 Z200 M03 S1000 Home position, spindle
mode
• Machining
G00 G17 G06 X100 Z250 C90 Home position, C-axis
mode

G01 G91 X-40 C-270 RZ50 F1200 Machining

G00 G18 G54 G90 X120 Z200 M03 S1200 Home position, spindle
mode

RET Program end

Start-up Logic for Endlessly Rotating Rotary Axes


Modulo calculation Modulo calculation is used for positioning endlessly turning rotary axes.
Possible positioning methods:
• shortest path G36
• positive direction G37
• negative direction G38

Note: Modulo calculation can be used only with absolute program-


ming (G90). It does not have any influence on chained dimen-
sion programming (G91).

The G36, G37 and G38 commands form the G code group "Rotary axis
approach logic" (No. 21).

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-62 Motion Blocks NC Programming Instructions

Shortest path G36 In modulo calculation "Shortest path" G36, the command position is ap-
proached via the shortest path.

a ctu a l p o sitio n = 2 0 ° G9 0 G3 6
.
.
.
co m m a n d G1 C -380 F 1000
p o sitio n = -3 80 °

449g36.FH7

Fig. 4-58: Positioning using modulo calculation "Shortest path" (G36)

• G36 is the power-on state; it may be cancelled with G37 or G38.


• The power-on default G36 is restored at the end of the program (BST,
RET, JMP, M02, M30).

Positive direction G37 In modulo calculation "Positive direction" G37, the command position is
approached in the positive direction.

G90 G37
actual position = 20° .
.
.
com m and G1 C -380 F 1000
position = -380°

450g37.FH7

Fig. 4-59: Positioning using modulo calculation "Positive direction" (G37)

• G37 may be cancelled with G36 or G38.


• The power-on default G36 is restored at the end of the program (BST,
RET, JMP, M02, M30).

Negative direction G38 In modulo calculation "Negative direction" G38, the command position is
approached in the negative direction.

a ctu a l p o sitio n = 2 0 ° G9 0 G3 8
.
.
co m m a n d .
G1 C -380 F 1000
p o sitio n = -3 80 °

451g38.FH7S

Fig. 4-60: Positioning using modulo calculation "Negative direction" (G38)

• G38 may be cancelled with G36 or G37.


• The power-on default G36 is restored at the end of the program (BST,
RET, JMP, M02, M30).

Note: The machine manufacturer may change the default setting in


the Bxx.056 process parameters.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-63

4.7 Transformations
The main application of the "Transformation of Cartesian coordinates into
polar coordinates" function is facing turning parts on turning and grinding
machines.
This function is particularly useful for milling surfaces on lathes (cylinder
surface machining) and for grinding cams. It can also be used in other
applications (such as in milling machines with rotary table or rotating heads).

Transformation Functions
Coordinate transformation is available for:
• face machining and
• lateral cylinder surface machining.

Lateral cylinder surface m achining

Face m achining
452Zylin.FH7

Fig. 4-61: Face and lateral cylinder surface machining

The commands G30 (canceling coordinate transformation), G31 (face


coordinate transformation), and G32 (lateral cylinder surface coordinate
transformation) form G code group "Transformation functions" (No. 17).

Select Face Machining "G31"


Function G31 "Select face machining" is used to switch the CNC to a
fictitious Cartesian coordinate system. The defined fictitious linear axes
are used in the interpolation instead of the assigned real main axes. As
with milling, the path feed rate using the transformation function must be
specific – preselect a relative speed between the tool and the workpiece
using the F value. The programmed path feed rate is reduced in such a
way that the maximum speed of the rotary axis is not exceeded. This is
especially the case with movements near the center of rotation.

Syntax G31
X1

Z1 Y1

Face machining
453G31.EPS

Fig. 4-62: Face machining with G31

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-64 Motion Blocks NC Programming Instructions

Boundary conditions • The CNC supports the transformation function for the XY plane (G17).
The real axes involved in the transformation must have the axis
meaning X and C.
• The real Y axis (if present) becomes an auxiliary axis, which has the
meaning V. When the transformation is deactivated, the NC reestab-
lishes the original status.
• The zero point offsets are cancelled (G53) when coordinate transfor-
mation is selected (G31); tool path compensation correction and tool
length compensation are deactivated (G40, G47). The CNC switches
to radius programming (G15).
• The X axis must be in the positive area when the change to coordinate
transformation occurs.
• After the changeover to coordinate transformation, the zero offsets for
the fictitous axes become active, depending on which ones are set.
The zero offsets of the real main axes assigned to the fictitous axes
are not in effect.
• After the change to coordinate transformation, it is possible to program
directly using absolute (G90) or incremental (G91) dimensional input.
• It is possible to open a new program during coordinate transformation
by using NC block search; however, coordinate transformation (G31)
must be set with the basic settings for this function (G54, G48, etc.) in
MDI before starting the program.
• The fictitous axes cannot be passed on to other processes (FAX, GAX).
• The reference spindle for feed programming with tapping (G63, G64,
G65) must be set using the SPF command.
• In the power-on state, the coordinate transformation always applies to
the first spindle. If the transformation is to be applied to a different
spindle, the desired spindle must be selected prior to coordinate trans-
formation by using the SPC <spindle number> command.
• The real primary axes that are allocated to the fictitious axes must not
be programmed during coordinate transformation.
• G31 "Transformation" remains modally active until it is cancelled with
G30 or G32, or until it is reset automatically via BST or at the end of
the program (RET).

Note: If coordinate transformation is active, the PLC employs axis


designation 2 for the two fictitious axes that span the current
working plane, instead of axis designation 1, which is stored in
the machine parameters.
The machine manufacturer defines the axis designation of the
fictitious axes in the axis parameters.

Invalid NC commands during The following list contains all functions that may not be programmed dur-
transformation ing the transformation:
• Thread cutting "G33",
• Zero offsets "G50", "G51", "G52"
(if offsets are programmed for "R1" and "R2"),
• Tapping "G63", "G64", "G65"
(if the primary spindle that is assigned to "R2" is addressed),
• Homing "G74"
(if homing is specified for the axes "F1" and "F2"),
• Feed to positive stop "G75"
• Cancel all axis preloads "G76"

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-65

• Speed limitation "G92"


(if the speed limitation is applied to the primary spindle that is allocated
to "R2"),
• Feed Rate per Spindle Revolution "G95"
(if the feed specification concerns the primary spindle that is allocated
to "R2"),
• Constant cutting speed "G96",
• Spindle control commands "M03", "M04", "M05", "M13", "M14", "M19"
(if a spindle-specific auxiliary function is programmed for the primary
spindle that is allocated to "R2"), and
• Axis transfer commands "GAX", "FAX"
(if the commands have an effect on axes "F1", "F2", "R1" and "R2").
All these functions will lead to an interruption of execution and to an error
message when they are used during the transformation process.

Tool Compensation When the transformation function is activated and deactivated, the NC
deactivates tool length and tool radius compensation.
Tool length and tool radius compensation can be active when the trans-
formation begins. Their effect is not influenced by the transformation
function.

Note: Only tools of type 1 or 2 may be used during transformation.

If the utilization of a type 4 tool (angle head tool) is mandatory, tool length
compensations "L1" and "L2" must be taken into account in geometric
programming. The value "0" must be entered for the corresponding tool
length compensations "L1" and "L2" of the tool.

Axis meaning The facing parameter values of axis meanings and axis designations of a
lathe with a primary spindle with rotary axis capability (S1/C), an X and a
Z axis, and a PLC-controlled turret with driven tools (S2) have been set as
follows:

Axis designation 1 Axis designation 2 Axis meaning


S1/C Y1 C,X
S2 - -

Notes:
• The coordinate transformation function is an option that re-
quires a special hardware configuration. All axes that are
involved in the coordinate transformation must be on an
APR card. The real primary axes that are allocated to the
fictitious axes must not be programmed during coordinate
transformation.
• If the coordinate transformation function is executed in a
machine with a real Y axis, the corresponding process may
not contain an axis of axis meaning V.
• If the coordinate transformation function is activated, the CNC
automatically triggers a changeover to rotary axis mode.
• When face machining is activated and deactivated, the
CNC deactivates all zero point offsets and sets G53.
• If diameter programming (G16) is selected while face ma-
chining is active, the CNC interprets all position values of
the fictitious axis with axis meaning X as a diameter speci-
fication.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-66 Motion Blocks NC Programming Instructions

Detailed description Please refer to the "Coordinate transformation function V15" description
for further and supplementary information about face machining.
"DOC-MT*CNC-TRA*FKN*V15-ANW1-EN-P".

Travel limits for transformation Y'/C


G31
Point cannot be approached

Limit X+ or Limit X- X'/X

Point can be approached


453Fahr.FH7

Fig. 4-63: Travel limits for transformation G31

Function G31 "Select face machining" is used to switch the CNC to a


fictitious Cartesian coordinate system. In the new coordinate system, the
X axis becomes the X" axis and the C axis becomes the Y" axis.
In the axis parameters of the X axis, there are settings for a
• positive travel limit (Limit X+) and a
• negative travel limit (Limit X-).
Depending on the "Direction for transformation" axis parameter, the "Limit
X+" or "Limit X-" travel limit is used.
The PLC controller uses the Cartesian coordinate system for computing.
In this system, the travel limits define a square of the side length of
2• Limit X+ or 2• Limit X-. At the lathe, however, the travel limit is a circle of
the radius R = Limit X+ or R = Limit X-. A point within the square that is
outside the circle may be programmed, but cannot be approached.

Example: NC program - face machining

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-67

X1

70
[P1] [P8]

50
40
30
[P2] 20 [P7]
10

Y1 70 50 40 30 20 10

[P3] [P6]

[P4] [P5]

455STIRN.FH7

Fig. 4-64: Facing machining with transformation

NC program:
T12 M6 ;Tool change
;driven tool
M89 ;Engage driven tool
S2 3500 M203 ;Driven tool ON
G00 G17 G54 G48 Z100
X140 C0 ;Home position for the change
G31 ;Activate coordinate transformation
G54 G90 G54 G06 G08 ;Home position
G00 G42 G94 X1 60 Y1 20 ;[P1] Starting point of machining
G01 Z-0.5 F500 ;Feed Z axis
st
X1 20 Y1 60 F400 ;[P2] 1 straight line
nd
X1 -20 ;[P3] 2 straight line
rd
X1 -50 Y1 30 ;[P4] 3 straight line
G02 X1 -50 Y1 -30 I-50 J0 ;[P5] Semicircle in CW direction
th
G01 X1 -20 Y1 -60 ;[P6] 4 straight line
th
X1 20 ;[P7] 5 straight line
th
X1 60 Y1 -20 ;[P8] 6 straight line
th
Y1 20 ;[P1] 7 straight line
G00 Z10 ;Z axis to safety distance
G30 ;Cancel coordinate transformation
G54 G48 G00 X140 ;Home position
Z200 ;Withdraw Z axis
M90 ;Disengage driven tool
M30 ;End of program

Selection of Lateral Cylinder Surface Machining "G32"


With lateral cylinder surface machining G32, the CNC produces straight
lines and circles on the lateral cylinder surface according to the G00, G01,

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-68 Motion Blocks NC Programming Instructions

G02 and G03 blocks that are specified in the NC program. The straight
lines and circles on the lateral cylinder surface can be programmed on the
plane of the developed lateral cylinder surface that spans a linear axis
and a rotary axis.

Y C [mm]
X G20 Z0 C0 X0
B G32 RI 60

RI
C
0
X [mm] Z [mm]

456Zylin.FH7

Fig. 4-65: Lateral cylinder surface machining

Programming The rotary axis that is involved in lateral cylinder surface machining can
be programmed like a linear axis in [mm] or in [inch] (by specifying posi-
tions on the lateral cylinder surface).

Syntax G32 RI=w or G32 RI w w: Value of the effective radius

Effective radius • Specifying the effective radius RI is mandatory.


• Specifying an effective radius RI ≤0 is not permitted.
• The effective radius RI must not be altered when lateral cylinder sur-
face machining is active (G30 must first be used for deactivation).
• If the machining plane is spanned by two rotary axes, the CNC takes
the effective radius RI of both rotary axes into account.
• The effective radius RI has a modal effect. The NC retains the effec-
tive radius until lateral cylinder surface machining is deactivated.

Plane selection Before lateral cylinder surface machining is activated, the plane usually
must be selected with free plane selection (G20, G21, G22).

Selection and axis assignment To perform the individual machining tasks, the following planes are se-
lected during machine operation:
Linear
main Secondary axes Rotary main axes
axes
Mach Vert.
Axis Axis Axis Axis Axis Axis Axis Axis Axis ining Axis
G code mean. mean. mean. mean. mean. mean. mean. mean. mean. plane Remarks
X Y Z U V W A B C

Turning
G18 X1 Y Z U - X2 - B C Z X1 Y
(= power-on pos.)

Milling
G20 X2=0 Y0 Z0 X2 Y Z U - X1 - B C X2 Y Z
(= G17 with X2)

Milling
G20 Z0 X2=0 Y0 Z X2 Y U - X1 - B C Z X2 Y
(= G18 with X2)

Milling
G20 Y0 Z0 X2=0 Y Z X2 U - X1 - B C YZ X2
(= G19 with X2)

Lateral cylinder
G20 Z0 C0 X2=0 G32 RI=80 Z C X2 U - X1 - B C CZ X2
surface machining

Boundary conditions • During lateral cylinder surface machining, the involved rotary axis ob-
tains the functionality of a linear primary axis. Functions such as tool
radius path correction and zero point offsets, including rotations, may
also be used in the course of lateral cylinder surface machining.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-69

• During lateral cylinder surface machining, the NC monitors the limited


rotary axes (travel range limits) in the same way as during normal op-
eration.
• During lateral cylinder surface machining, rotary axes must be pro-
grammed in [mm] or [inch].
• When lateral cylinder surface machining is activated, the NC automati-
cally switches over to radius programming (G15).
• Upon cancellation, the NC restores the programming mode (radius
programming G15 or diameter programming G16) that has been
stored in the process parameters.
• G32 – Coordinate transformation – remains modally effective until it is
cancelled with G30 or G31, or until it is automatically reset at the end
of the program (BST, RET, JMP, M02, M03).

Note: Before lateral cylinder surface machining is activated, the acti-


vated machining plane must be spanned by at least one rotary
axis. This is possible using G20, G21, G22 (Free plane selec-
tion).
When lateral cylinder surface machining is activated or deacti-
vated, the NC deactivates all zero point offsets and sets G53.
If diameter programming (G16) is selected during lateral cylinder
surface machining, the NC interprets all position values of the
axis with axis meaning X as diameter specifications.

Detailed description Please refer to "Free plane selection and lateral cylinder surface machin-
ing V22" for further information about lateral cylinder surface machining.
"DOK-MTC200-FREPLAN*V22-AW01-EN-P".

Example: NC program - lateral cylinder surface machining

Y
70

50

50

-150 -100 -50 0 X


457Zyltr.FH7

Fig. 4-66: Lateral cylinder surf. machining with transformation

NC program:
:
;Milling contour "number 1"
G55 G15 G94 G97 G6 G8 S2 3000 M203
G00 C0
G20 Z0 C0 X0 ;Free plane selection
G32 RI 36.5 ;Lateral cylinder surface machining on
G55 G48 Z1-36.15

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-70 Motion Blocks NC Programming Instructions

Y1 25 Z1-36.15
X38
G01 X36 F150
G42 Y1 25 Z1-42 F297
Y1 50 Z1-42
G02 Y1 54.2426 Z1-30.7574 I-35 J50
G01 Y1 34.2426 Z1-10.7574
G02 Y1 25.7574 Z1-19.2426 I-15 J30
G01 Y1 36.5147 Z1-30
Y1 5 Z1-30
G02 Y1 5 Z1-42 I-36 J5
G01 Y1 25 Z1-42
G00 X38
G30 ;Lateral cylinder surface machining off
:

Deselection of Transformation "G30"


The CNC employs function G30 "Deselection of transformation" to dese-
lect an existing transformation (G31, G32).
The zero point offsets are cancelled (G53) when transformation is dese-
lected (G30); tool path and tool length compensation are deactivated
(G40, G47).
G30 is the power-on state; it has a modal effect. G30 are cancelled by
G31 or G32. G30 is set automatically after an NC program has been
loaded and after a BST, RET, or control reset.

Deselection of face The fictitious Cartesian coordinate system is deselected and the coordi-
transformation G31 nate system that has been defined in the process parameters is selected.
The fictitious axes are deselected and may consequently no longer be
programmed.
The plane that has been specified in the process parameters is selected
as the current machining plane; the CNC switches over to the workpiece
programming mode (radius/diameter), which has been stored in the proc-
ess parameters.
After coordinate transformation has been cancelled, programming can be
performed directly in absolute (G90) or incremental (G91) dimensions.

Note: The fictitious axes may no longer be programmed.


The zero point offsets for the real axes have already been set.
The zero point offsets of the fictitious axes that are allocated to
the real axes have no effect.

Deselection of lateral cylinder Upon cancellation, the NC restores the programming mode (radius pro-
surface coordinate gramming G15 or diameter programming G16) that has been stored in
transformation G32 the process parameters.

Note: The CNC deactivates all zero point offsets and sets G53.

Select Main Spindle for Transformation "SPC"


If a number of spindles in which a coordinate transformation could be
performed are present in a process, there must be some way to select the
main spindle for the coordinate transformation.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-71

Syntax SPC <spindle number>


The first spindle is always active in the power-on state. If the transforma-
tion is to be applied to a spindle other than the first spindle, the correct
main spindle must be selected by using "SPC <spindle number>" before
using G31 or G32 to select coordinate transformation.
The main spindle must be selected when the main spindle mode is active.
It cannot be selected during C-axis mode.
"SPC <spindle number>" remains modally active until it is overwritten with
a different spindle number or is automatically set to the first spindle at the
end of the program (RET) or by BST.
The current reference spindle for the transformation can be interrogated
(e.g. using @10=SPC).

4.8 Main Spindle Synchronization

Use of Main Spindle Synchronization


Main spindle synchronization is primarily used on lathes to transfer parts,
to recess parts, to machine shafts, for polygon lathing, and for non-round
lathing.

Functions of Main Spindle Synchronization


Up to three spindles can be operated in sync within a process on the
CNC. One spindle is used as the master spindle, while the other two
spindles are operated as synchronized spindles. The CNC always moves
the master and synchronized spindles so that they remain angularly in
sync. The following example illustrates the relationship with angular syn-
chronization between a master spindle and a synchronized spindle.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-72 Motion Blocks NC Programming Instructions

Angular
position of Comment
spindles
Prior to synchronization Master Each spindle is located in any given random position
Synchro-
nized
spindle
spindle

After synchronization step Master The synchronized spindle performs a movement to adjust
Synchro- to the given angle offset (=90°) (transf. ratio = 1).
nized
spindle
spindle

After rotation of 90° Master The synchronized spindle has rotated 90° in sync with the
Synchro- master spindle.
nized
spindle
spindle

After a change of 45° in the position Master The synchronized spindle has rotated 45° with respect to
offset Synchro- the master spindle.
nized
spindle
spindle

Fig. 4-67: Angular position of spindles

The advantage of the "absolute angle" synchronization mode is that the


angle offset between the master and the synchronized spindles can be
set in a defined manner at any time.

Permissible Configurations
The rules which define the permissible spindle configurations for the main
spindle synchronization are listed below. If one of these rules is violated at
the beginning of synchronization or during synchronization, the NC inter-
rupts the process and generates an error message.
• Only one master spindle can be used in main spindle synchronization.
• All spindles used in main spindle synchronization must belong to one
process.
− If the spindles of a different process are to participate in main
spindle synchronization, this is to be defined to the respective
process using the axis transfer commands.
• All spindles used in main spindle synchronization must be controlled
by the same APR card.
• No more than two synchronized spindles can belong to a synchroniza-
tion group in addition to the master spindle.
• The master spindle must have a lower drive number than the synchro-
nized spindles within the SERCOS drive loop.
• A single spindle cannot be both a master and a synchronized spindle
at the same time.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-73

Note: Only digital main spindle drives equipped with the SERCOS
Interface as well as digital DDS 2.2 feed drives equipped with
main spindle functions and the SERCOS Interface can be used
in main spindle synchronization.

Sequence of a Synchronization Operation


Activate main spindle Main spindle synchronization is activated in NC program-controlled mode
synchronization from the NC program by means of an auxiliary function. In manual mode,
the synchronization can be activated by means of a machine control key
or by any other key. An interface signal between the PLC and the NC al-
lows follower axis synchronization to be activated in any operating mode.
The following is to be specified via the user interface, the NC program, or
the PLC program before starting main spindle synchronization:
• the sync spindle appertaining to the main spindle,
• the existing transmission ratio between main and synchronization
spindle,
• the direction of rotation of the synchronized spindle
• the effective angle offset and position offset between both spindles, as
well as
• the tolerance limits for monitoring the actual position value differences
between the master and the synchronized spindle.

Auxiliary functions for selecting As of version 5.15.xx, Q functions Q9000 - Q9999 are reserved for Bosch
and canceling main spindle Rexroth specific functions. Q functions Q9700 - Q9764 are for main spin-
synchronization dle synchronization. We recommend that the auxiliary functions be as-
signed as follows for main spindle synchronization:
9 Reserved 7 reserved for Process
Q function for Bosch main spindle number Function Remarks
Rexroth sync x = 0-6
Q 9 7 x 0 Main spindle synchron. groups 1 & 2 OFF
Q 9 7 x 1 Main spindle synchron. group 1 ON
Q 9 7 x 2 Main spindle synchron. group 2 ON
Q 9 7 x 3 Main spindle synchron. group 1 OFF
Q 9 7 x 4 Main spindle synchron. group 2 OFF

Synchronization process If the spindles are rotating at different speeds (stopped = 0 rpm) when
spindle synchronization is activated, the NC accelerates or decelerates
the synchronized spindle at maximum acceleration/deceleration until it
reaches the synchronization speed. As soon as it reaches the synchroni-
zation speed, the NC switches to position control and rotates the syn-
chronized spindle to the set position within one revolution using the short-
est path. If the master spindle and the synchronized spindle are stopped,
the synchronized spindle simply traverses to its command position, taking
the existing translation ratio and the existing angle offset and position
offset into account.
The NC switches all spindles involved in the synchronization to position
control. If functions such as M03, M04, or G95 are active while main spin-
dle synchronization is activated, the NC continues position control mode
for these spindles. The changeover operation does not have any negative
effects on the surface of the workpiece.

Deactivate synchronization Main spindle synchronization can be cancelled independently of the oper-
ating mode by resetting the activation interface signal. All spindles in-
volved in the synchronization retain their speeds after cancellation. If the
spindles must stop after cancellation, this must be programmed by means

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-74 Motion Blocks NC Programming Instructions

of M05 or M19 after synchronization has been canceled. If synchroniza-


tion is deactivated, the NC switches the spindles which were involved in
the synchronization back to speed control if a function that normally runs
under speed control is active at this time.

NC programming
None of the synchronized spindles which participate in main spindle syn-
chronization may be programmed during synchronized operation. How-
ever, if an attempt is made to do this, the NC terminates program execu-
tion and generates an error message.
Furthermore, the master and the synchronized spindles may not be oper-
ated in the rotary axis mode; a gear change may not be performed during
synchronized operation. Any attempt to do so will result in the termination
of the program and the generation of an appropriate error message.
• Synchronized operation remains active at the end of the program
(BST, RET, M02 and M30), with control reset or with jog in manual
mode if the PLC does not cancel the synchronized spindles which are
involved in synchronized operation.
• The master spindle must be the main spindle during synchronized
operation. In synchronized operation, functions G33 (Thread cutting),
G95 (Feed per revolution) and G96 (Constant surface speed) apply
exclusively to the master spindle. For this reason, the master spindle
must be selected as the main spindle as soon as main spindle syn-
chronization is activated.
• During synchronized operation, the user must not switch the spindles
which are involved in the main spindle synchronization from one proc-
ess to another. The use of the axis transfer commands with the spin-
dles which are engaged in synchronized operation will cause the pro-
gram to terminate and an error message to be generated. Thus, spin-
dles which are part of the synchronized operation and that belong to a
different primary process must be transferred to the respective proc-
ess before synchronization mode is activated. In addition, they may not
return to the primary process until synchronization mode is cancelled.

Note: The spindle which is engaged in tapping G63, G63, or G65


must not be a master spindle or a synchronized spindle.

Machine Data for Main Spindle Synchronization


The machine data for main spindle synchronization occupy a page named
Main spindle synchronization. The following data structure is present
within the page for each process:
No. Description Value range Description
001 Sync run sync spindle 1 OK 0/1 0: Sync run not OK
1: Synchronization OK
002 Sync run sync spindle 2 OK 0/1 0: Sync run not OK
1: Synchronization OK
003 Axis meaning of master spindle 0, 10, 11, 12 0: No master spindle present;
10: Spindle S1;
11: Spindle S2;
12: Spindle S3
004 Axis meaning, sync spindle 1 0, 10, 11, 12 0: No sync spindle present;
10: Spindle S1;
11: Spindle S2;
12: Spindle S3
005 Angle offset, sync spindle 1 0.0000°-359.9999° Angle offset between main spindle and synchronized spindle 1
006 Position offset, sync spindle 1 0.0000°-359.9999° Position offset between main spindle and synchronized spindle 1.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-75

007 Main spindle speed i_LS/SS1 1 - 65536 The translation ratio is calculated by dividing the main spindle
revolutions by the synchronized spindle revolutions.
008 Sync spindle1 speed i_LS/SS1 1 - 65536 The translation ratio is calculated by dividing the main spindle
revolutions by the synchronized spindle revolutions.
009 Direction of rotation sync spindle 1 0/1 0: No change in direction
1: Opposite direction
010 Sync run window, sync. spindle 1 0.0000°-359.9999° Sync run window for interface signal PxxSSS1OK
011 Error limit, sync spindle 1 0.0000°-359.9999° Error limit window for interface signal PxxS.SS1ER
012 Axis meaning, sync spindle 2 0, 10, 11, 12 0: No sync spindle present;
10: Spindle S1;
11: Spindle S2;
12: Spindle S3
013 Angle offset, sync spindle 2 0.0000°-359.9999° Angle offset between main spindle and synchronized spindle 2
014 Position offset, sync spindle 2 0.0000°-359.9999° Position offset between main spindle and synchronized spindle 2.
015 Main spindle speed, i_LS/SS2 1 - 65536 The translation ratio is calculated by dividing the main spindle
revolutions by the synchronized spindle revolutions.
016 Sync spindle 2 speed, i_LS/SS2 1 - 65536 The translation ratio is calculated by dividing the main spindle
revolutions by the synchronized spindle revolutions.
017 Direction of rotation, sync spindle 2 0/1 0: No change in direction
1: Opposite direction
018 Sync run window, sync. spindle 2 0.0000°-359.9999° Sync run window for interface signal PxxSSS2OK
019 Error limit, sync spindle 2 0.0000°-359.9999° Error limit window for interface signal PxxSSS2ER

Fig. 4-68: Data structure

The individual data elements can be reconfigured from the PLC via the
user interface or from the NC program if the corresponding main spindle
or synchronized spindle is not active. If the user accesses the data for a
spindle which is engaged in synchronized operation from the PLC or from
the user interface, an error message will be generated. If the user at-
tempts to use the MTD command in the NC program, an error message
will be generated, and the NC will stop processing. Exceptions are data
elements 005 "Angle offset" and 006 "Position offset" of the synchronized
spindles 1 and 2. The user can modify them at any time during synchro-
nized operation, either from the PLC via the user interface or from the NC
program.

4.9 Follower and Gantry axes

Applications of Follower and Gantry Axes


The functions "Follower axis" or "Gantry axis", referred to below as syn-
chronized mode, allows up to four feed axes to be operated in sync.
Each feed axis can be defined as a main axis; up to 3 synchronized slave
axes can be assigned to it. The main axis and the slave axes together
comprise a synchronized axis group. Such groups can be activated or
deactivated depending on the operating mode, or they can be kept active
during the entire operation of the machine, including homing operations.
When they are in the inactive state, they can be reconfigured during ma-
chine operation from the PLC and the NC as well as by means of the user
interface. For each process, up to four different synchronized axis groups
can be active simultaneously.
During synchronized operation, all the slave axes in the group follow the
path traveled by the main axis, taking into account their respective trans-
lation ratios and their directions of rotation.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-76 Motion Blocks NC Programming Instructions

Permissible Configurations
The following rules describe the configurations which are permissible for
synchronized operation. If the NC detects a violation of these rules, it in-
terrupts processing and generates an error message.
• One master axis and at least one slave axes must be present in each
synchronized axis group.
• A synchronized axis group must not contain more than one master axis.
• A maximum of three slave axes may be present in each synchronized axis
group.
• All axes in a synchronized axis group must belong to the same process.
If the axis of a different process is to participate as a main or slave axis in
the synchronized axis group, then this must be specified to the respective
process using default axis transfer commands.
• All axes in a synchronized axis group must be located on a single APR.
• The master axis must have a lower drive number than the slave axes on
the SERCOS loop.
• A single axis cannot be both a master axis and at the same time a slave
axis.
• All axes in a synchronized axis group must be of the same axis type
(linear, modulo rotating rotary, or limited rotating rotary axes).
• Tool storage axes must not be part of a synchronized axis group, either as
a master axis or as a slave axis.
• If rotary axes form a synchronized axis group, they must be programmed
using the same number of divisions per revolution.
• The master and slave axes in an active synchronized axis group may not
be present as a master or as a slave axis in a different synchronized axis
group.

Steps of a Follower Operation


A synchronized axis group can be activated during program-controlled opera-
tion from the NC program by means of an auxiliary function. In manual mode,
the user can activate synchronized operation via a machine control key or
another key. An interface signal between the PLC and the NC allows follower
axis synchronization to be activated in any operating mode. It is important to
be certain that the master and slave axes are placed in their starting position
before activating synchronized operation and that the corresponding machine
data are entered properly.
Synchronized operation can be cancelled independently of the operating
mode by resetting the activation interface signal. All axes in the synchro-
nized axis group retain their position without any change after being deac-
tivated.

Auxiliary Functions for Synchronized Operation


Q functions Q9000 - Q9999 are reserved for Bosch Rexroth specific func-
tions. Q functions Q9800 - Q9868 are for synchronization operating
mode. We recommend that the auxiliary functions be assigned as follows
for synchronized operation:

9 Reserved 8 reserved for Process


Q function synchronized number Function Remarks
for Bosch
Rexroth axis opera- x = 0-6
tion
Q 9 8 x 0 Sync axis group 1 - 4 OFF
Q 9 8 x 1 Sync axis group 1 ON

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-77

Q 9 8 x 2 Sync axis group 2 ON


Q 9 8 x 3 Sync axis group 3 ON
Q 9 8 x 4 Sync axis group 4 ON
Q 9 8 x 5 Sync axis group 1 OFF
Q 9 8 x 6 Sync axis group 2 OFF
Q 9 8 x 7 Sync axis group 3 OFF
Q 9 8 x 8 Sync axis group 4 OFF

Fig. 4-69: Allocation of auxiliary functions

NC Programming
During synchronized operation, the user may not program any axis other
than the master axis of an active synchronized axis group. No other slave
axes may be programmed during synchronized mode. If the user at-
tempts to do so by, for example, mirror imaging or scaling a slave axes,
the NC interrupts program execution and generates an error message.
Zero point offsets and tool corrections (including D corrections) are taken
into account only for the master axis by the NC. During synchronized op-
eration, the slave axes receive the command values only for the master
axis, taking into account the respective translation ratio and direction of
rotation.
• The synchronized axis groups remain active at the end of the program
(BST, RET, M02 and M30), with control reset or with jog in manual mode if
the PLC does not cancel the active synchronized axis.
• During synchronized operation, the user may not switch the axis in the
synchronized axis group from one process to another. The use of the
axis transfer commands with the axes which are engaged in synchro-
nized operation will cause the program to terminate and an error mes-
sage to be generated. Axes which are operated in synchronized mode
and that belong to a different primary process must be transferred to
the respective process before the synchronized axis group is acti-
vated. In addition, they must not be returned to the primary process
until synchronized mode is cancelled.
• Feed to positive stop (G75) cannot be used with synchronized mode.
• If coordinate transformation is active via G31 and G32, the axes that
are involved in the transformation (axes labeled X and C) may not be
part of any active synchronized axis group.

Machine Data for Synchronized Axis Groups


The machine data for the follower and gantry axes occupy a page named
Follower and gantry axes. The following data structure is present in the
page for each process and for each synchronized axis group:
No. Description Value range Description
001 Axis group switched on 0/1 0: Synchronized axis group not active
1: Synchronized axis group is switched on
002 Axis meaning of lead axis 0-9 0: No master spindle present;1,2,3,4,5,6,7,8,9:
Axis meaning X,Y,Z,U,V,W,A,B,C
003 Axis meaning, follower axis 1 0-9 0: No follower axis present
1 - 9: Axis meaning X,Y,Z,U,V,W,A,B,C
004 Speed of lead axis i_LA/FA1 1 - 65536 The translation ratio is calculated by dividing the master axis
revolutions by the follower axis revolutions
005 Speed of follower axis 1i_LA/FA1 1 - 65536 The translation ratio is calculated by dividing the master axis
revolutions by the follower axis revolutions
006 Direction of rotation follower axis 1 0/1 0: No change in direction
1: Opposite direction

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-78 Motion Blocks NC Programming Instructions

007 Follower axis 1 = gantry axis 0/1 This data element currently is not evaluated.
008 Axis meaning, follower axis 2 0 -9 0: No follower axis present
1 - 9: Axis meaning X,Y,Z,U,V,W,A,B,C
009 Speed of lead axis i_LA/FA2 1 - 65536 The translation ratio is calculated by dividing the master axis
revolutions by the follower axis revolutions
010 Speed of follower axis 2 i_LA/FA2 1 - 65536 The translation ratio is calculated by dividing the master axis
revolutions by the follower axis revolutions
011 Direction of rotation follower axis 2 0/1 0: No change in direction
1: Opposite direction
012 Follower axis 2 = gantry axis 0/1 This data element currently is not evaluated.
013 Axis meaning, follower axis 3 0-9 0: No follower axis present
1 - 9: Axis meaning X,Y,Z,U,V,W,A,B,C
014 Speed of lead axis i_LA/FA3 1 - 65536 The translation ratio is calculated by dividing the master axis
revolutions by the follower axis revolutions
015 Speed of follower axis 3i_LA/FA3 1 - 65536 The translation ratio is calculated by dividing the master axis
revolutions by the follower axis revolutions
016 Direction of rotation follower axis 3 0/1 0: No change in direction
1: Opposite direction
017 Follower axis 3 = gantry axis 0/1 This data element currently is not evaluated.

Fig. 4-70: Data structure

The individual data elements can be reconfigured from the PLC via the
user interface or from the NC program if the corresponding synchronized
axis group is not active. If the user accesses the data for an active syn-
chronized axis group from the PLC or from the user interface, an error
message will be generated. If the user attempts to do this in the NC pro-
gram using the MTD command, an error message will be generated and
the NC will stop processing.

4.10 Rounding of NC Blocks with Axis Filter "G11" / "RDI"

Method of Operation
Purpose NC commands "G11", "G10" and "RDI" are used to program/switch off func-
tion "Rounding of NC blocks with axis filter". This function is used mainly to
provide fast and time-optimized positioning using rapid traversing via several
data points. Within a sequence of motion commands, the block transitions are
rounded by means of a programmable axis filter so that the end point of the
motion sequence is reached in as short a time as possible.

Definition In this case, the term motion sequence is a sequence of NC blocks of G code
group 1 (G00, G01, G02, G03). An NC block which does not belong to this
group will exit the motion sequence.

Principle Rounding of block transitions occurs only within a motion sequence. With
the exception of the last data point (target point), it is not necessary to
fully hit the data points. The path curve can pass the data point at a
parameterizable maximum distance. At the end of the block, the last block
of a motion sequence directly hits the programmed target point position
without any rounding.

Rounding with axis filter Rounding of the block transitions is effected by means of a two-step axis
filter with acceleration filter and jerk limiting filter. This axis filter follows up
the interpolator and considers the values in the Cxx.018 "Maximum
acceleration" axis parameters, as well as the jerk limiting values entered
in the Bxx.034 "Time constant or acceleration" process parameter.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-79

Axis Filter

Interpolator Acceleration Jerk Filter


Filter

AxisFilter.FH7

Fig. 4-71: Rounding using two-stage axis filter

Round distance RDI In the axis filter, an axis positioning windows delimits the maximum rounding
distance RDI (Round DIstance). The RDI value defines the maximum distan-
ce to the programmed data point for the start of the rounding process.

Pn

PnF1

PnF2

RoundDistance.FH7

RDI: Round DIstance (NC program)


Pn: programmed data point (NC program)
PnF1, PnF2: track points generated by rounding
Fig. 4-72: Rounding with rounding distance RDI

Programming
RDI programming The process of rounding block transitions is modally enabled for the cur-
rent and the following blocks by programming the rounding distance RDI
(Round DIstance). It is effective only in motion blocks of G code group 1
(G00, G01, G02, G03). In each case, the transition from the current block
to the next block is rounded.
Rounding is switched off again with the "RDI 0" command.
"RDI=0" is the default state and is saved as active until RDI is overwritten
with another value. RDI is automatically reset to the default state at the
end of the program (RET), using the BST command or control reset.

Syntax The following syntax is admissible with the RDI command:


RDI10 ;direct allocation
RDI 10 ;direct allocation, space symbol
RDI=10 ;direct allocation
RDI=@195 ;allocation by variable
RDI=10+@195 ;allocation by formula
@195=RDI ;reading of the currently effective RDI value

Example of an NC program with N012 G1 X5 Z0


RDI N013 G1 X10 Z10 RDI 5 ;rounding with 5 mm
N014 G1 X20 Z15 ;rounding with 5 mm
N015 G1 X35 Z5 RDI 2 ;rounding with 2 mm

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-80 Motion Blocks NC Programming Instructions

N016 G1 X100 Z5 RDI 0 ;rounding switched off, target point is


;attained precisely

Alternative programming with As an alternative to programming with RDI, G codes G11 and G10 (G
G10 and G11 code group 23) can be used to enable and disable the rounding function:
• G11: enables the rounding function.
The last programmed rounding distance RDI is effective. With a current
rounding distance of 0, G11 does not take effect. Programming of RDI
with a rounding distance other than 0 automatically enables G code G11.
G11 is saved as active until G10 is enabled.
• G10: disables the rounding mode.
Programming of "RDI=0" automatically enables G code G10. G10 is the
default state and is saved as active until G11 is enabled. G10 is en-
abled automatically at the end of the program (RET), by the BST com-
mand or by a control reset.

Behavior at the end of a motion Rounding of block transitions occurs only within a motion sequence. A mo-
sequence and when disabling tionless block – or, more precisely, a block outside of G code group 1 – termi-
rounding nates the motion sequence. But G11 remains enabled. At the end of the
block, the last block of a motion sequence hits the programmed target point
position without any rounding. This also applies to a motion block in which
rounding has been disabled.

Example for an NC program of a N001 G1 X5 Z0 RDI 5 ;rounding with 5 mm


motion sequence N002 G1 X10 Z10 ;rounding with 5 mm
N003 G1 X20 Z15 ;target point is attained precisely
N004 M50 ;motionless block
N005 G1 X35 Z5 RDI 2 ;rounding with 2 mm
N006 G1 X100 Z5 RDI 0 ;rounding switched off, target point is
;attained precisely
N100 G1 X200 Z30

N002
N003
N005

N006
N001 N004,
motionless

PosSequence.FH7

Fig. 4-73: Example for rounding within a motion sequence

Limits and Special Regulations


Special regulations on exact When rounding is active and exact stop (to be enabled via G61 or in G00
stop blocks) is enabled at the same time within one motion sequence, exact
stop is not effective. This behavior does not correspond to the DIN defini-
tion for the G00 rapid traverse rate block when the next block is a motion
block as well. The block transition to the next block is rounded. At the end
of the motion sequence, attainment of the positioning window is queried
once more.

Restrictions For rounding with an axis filter, there are some restrictions:
• Rounding depends on velocity. The rounded path curve at the block tran-
sition varies dependent on the velocity (override).
• Rounding to the next block does not occur in the following cases:

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-81

motionless intermediate blocks.


• Rounding is not possible when transformation is active (G31 or G32).
In these cases, an error message is indicated when G11 or RDI (other
than 0) are programmed.
• When traversing straight lines, parallel offsets are possible.
• With circles, the deviations from the original curve are greater than
with straight lines.

4.11 Test Mode

Purpose
Besides the already existing functions such as single block mode, semi-
automatic mode, feed override, rapid movement override, NC block skip-
ping, conditional and unconditional stop as well as the virtual NC, includ-
ing the (offline) simulation, the following functions allow an even quicker
startup for the user:
• suppressing assisting functions,
• disabling movement,
• test feed,
• quick run and
• graphic online simulation.
These functions – in the following named "Test mode" – allow the user to
concentrate specifically on the geometry, the process synchronization,
and collision analysis. They allow an individual examination of the overall
process, especially the parallel-running partial processes, and they permit
these to be run as often as desired and at any speed. This can be per-
formed with and without control of the I/O plane, as well as with and with-
out axis movements.

Suppress Auxiliary Function Output


With the function "Suppress auxiliary function output", the machine user
can turn off special auxiliary functions (e.g. coolant) or all auxiliary func-
tions (M, Q, S, and T/E functions) during test mode.
The user can activate the function "Suppress auxiliary function output" by
pressing an M key.

Lock Axis and Spindles


Application
In order to test the program step by step, the user can selectively activate and
deactivate axes and spindles with the function "Lock axes and spindles".

Examples
Simple milling machine On a milling machine, the test mode could, for example, be that the user
locks the feed axis (Z axis) by pressing an M key and preselects a higher
speed (test feed) for program processing.
During the adjacent test mode, the tool change is performed as in normal
program mode.

Simple lathing machine The test mode on a lathing machine is similar. All axes (X, Z, and W (tool
turret)) as well as the spindle are locked; the test feed is activated by
pressing an M key.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-82 Motion Blocks NC Programming Instructions

More complex machine For example, the following steps (test steps) are passed from the estab-
lishment of the NC program to the production of a part:
1. The user activates the following functions via M keys:
• lock all main axes (X,Z), turret and spindle (S)
• lock auxiliary axes (U (back rest)), V (tail stock),
• activate test feed, and
suppress auxiliary function output.
Before the program is started, the user also activates the online graphics.
2. If the program runs successfully, the user unlocks the main axes, the
tool turret, and the spindle by pressing an M key and reruns the NC
program (without part). Thereby the user checks, based on the path
movement, the correction data (zero offsets, tool corrections, etc.).
3. In a further step, the user also activates the auxiliary axes (U, V) and
checks their feed movements for collisions.
4. After this step has been successfully completed, the user then deacti-
vates the function "Suppress auxiliary function output" and checks the
performance of the auxiliary functions during the new run.
Then the part is machined.

Further application The axis/spindle lock is used not only for test applications, but also for
other purposes. For example, it is required for dual lathing or milling ma-
chines which can be operated alternatively as a dual machine or as two
individual machines.

Test Feed
Application The test feed permits a quick run of the NC program. This is particularly
advantageous if axes and spindles are locked. Furthermore, a continuous
run of the machining processes as well as of the feed and retract move-
ments is reached.

Method of operation The test feed is used when the function "Test feed" is selected in the op-
erating modes "automatic" and "semi-automatic" to run the program in-
stead of using the programmed feed.
When the function "Test feed" is active, the NC performs a test feed of
the axes that were programmed in conjunction with G01, G02, G03, G33,
G63, G64, G65, G74, G75 and G77. This feed value is also used as the
feed for G95 (feed per revolution), independent of the individual spindle
speed.
With G00, the NC performs a second test feed (rapid test feed) of the
axes if the function "Test feed" is active.
Independent of whether the axes or spindles are locked or not, the func-
tion "Test feed" is always available to the user during test mode.
In active test feed mode, the effect of the feed and rapid override are the
same as in normal operation. As in normal operating mode, the NC pre-
vents exceeding of the maximum axis velocity as well as the maximum
path velocity specified in the machine parameters.

Selecting test feed The machine user selects the test feed via the user interface by using an
M key.
When this has been selected and as long as it has not yet been set, the
interface signal "PxxCDRYRN" (DRY RuN) is set to the NC and machine
data element "Test feed" is set.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Motion Blocks 4-83

Note: During the projection of the function within the GBO, it is to be


ensured that sub-operating mode "Test mode" is indicated in
the GBO screens.

Entering test feeds The values for the test feeds "Test feed" and "Quick test feed" are to be
entered into the machine data on page "Test mode" by the machine
builder; if required, they can be overwritten by the end user directly into
the machine data or indirectly via the PLC. For example, the machine
builder can offer values via the M keys for the test feed as well as for the
quick test feed and have the end user select them.

Rapid Run
Application The rapid run offers the quickest possibility to check an NC program.
It can be implemented by using a block pre-run, where the user does not
have to select a start or a target block. The NC begins, as in normal op-
erating mode, with the first NC block and ends it as soon as the program
end has been reached. Thereby the axes and spindles remain stopped
and only the assisting functions within machine parameters (Bxx.058 -
Bxx.061) are performed.
The tool corrections, zero offsets, and D corrections regarding the travel range
limits or variable calculations etc. can therefore be checked in rapid run.

Online Simulation
Application Online simulation can be activated and de-activated in all operating and
subordinate operating modes and provides the user with reliable informa-
tion on the traveled path of the (moved or locked) axis within the machine.

Note: With very short NC blocks (e.g. transition radii) and at very
high path velocities, online simulation may not cover all NC
blocks. Within the graph, it can be selected to not show them
or to mark them with arrows or dots.

Suppress Tool Transfer and Movements


Application The function "Suppress tool transfer and movements" is an important
subfunction while testing an NC program, in which the process of the tool
storage axis is locked and the auxiliary functions are not generated. It
permits the machine builder to freeze or to drag along the tool list during
test mode as needed. Freezing the tool list is required especially if the
affiliated tool storage axis is locked during the test mode and the tool
change-specific auxiliary functions can not be processed by the PLC.

Note: Assure at start up that the tool change-specific auxiliary func-


tions are not processed by the PLC and that the tool list is fro-
zen when locking the tool storage axis.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
4-84 Motion Blocks NC Programming Instructions

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-1

5 Tool Compensation

5.1 Setup Lists and Tool Lists

Setup List
Purpose Using the setup list, the user can define the availability of all tools that are
required for machining and, using the equipment check, ensure their usabil-
ity for the machining processes that are to be performed. The setup list data
reflects the required data of the tools that are to be employed (e.g. geome-
try limit values).

Note: As of firmware version 23VRS, the MTC200 again supports


the full functionality of the setup lists from its MTGUI.

Handling The setup lists and NC packages are loaded into the controller and saved
together using the storage function.

Activation Using system parameter A00.053 Organization of setup lists, the user
defines whether a separate (program-specific) setup list is to be created for
each NC program or whether only one (station-specific) setup list is to be
created for a process.

NC Program Package <xx> NC Program Package <xx>

Process 6 Process 6

Process 2 Process 2

Process 1 Process 1

Process 0 Process 0
NC Program 1 Setup List 1 NC Program 1 Setup List

NC Program 2 Setup List 2 NC Program 2

NC Program 3 Setup List 3 NC Program 3

NC Program 99 Setup List 99 NC Program 99

Program specific Organization Form Station specific Organization Form


of the Setup Lists of the Setup Lists
Pakete.FH7

Fig. 5-1: Organization types of setup lists

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-2 Tool Compensation MTC 200 NC programming instruction

Tool List
Purpose Tool lists are used for preparing and saving tool data of the individual
tools. The tool data always contain the basic tool data, which consist of
the tool identification, the location data, the units, the technology data and
at least one tool edge.
Besides the basic tool data, the tool data contain the data that are re-
quired for the tool edges (tool tip identification, geometry, tool life data,
user-defined data; see section "Elements of the tool data record").

Preparation With the help of the PC user interface, tool lists can be created, modified
and saved while machining is in progress. This enables the user to load
the tool storage device for subsequent machining processes.

Loading the tool list This permits the setup time of a new tool storage unit configuration to be
reduced to a minimum. The operator loads the tool list prepared in the
user interface into the control and loads the tool magazine according to
the tool list.

Current Tool List


The tool list that is currently contained in the controller is known as the
"current tool list".
As soon as a machining process has begun, the tool list in the PC loses
its significance; solely the current tool list in the CNC reflects the current
state of the tools within the magazine.

Note: Any modifications that concern the current workpiece ar-


rangement, such as inserting, removing or moving a tool or
modifying the tool data, must be performed directly in the cur-
rent tool data.

The current tool list contains the current information about the location
and the state of the individual tools (e.g. current remaining tool life). The
current tool list is generated from the tool list while taking the setup list
into account.
During the machining process, tool management continually updates the
current tool data, such as the location data, tool life data, and wear data.

Equipment Check
The equipment check compares the required tool data (setup list) with the
actual tool data (current tool list).
The equipment check is performed automatically whenever a program is
restarted after data of the setup or tool list have been modified and
transferred to the controller or after a different NC memory (A, B) has
been selected if interface signal PxxC.MGWTC (Process xx Command
MaGazine Without ToolCheck) has been set to log. "0".
Tool management does not perform an automatic equipment check after
a restart if PxxC.MGWTC has been set to log. "1".

TID In addition, NC command TID (Tool IDentification) permits the equipment


check to be executed at any position in the NC program, regardless of in-
terface signal PxxC.MGWTC.

Syntax TID

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-3

NC command equipment check TID

Start advance program


(PxxC.ADV)
Interface signal
"Equipment check"
(PxxC.MGWTC) >= 1 Equipment check
&
new and modified setup list

new and modified tool list >= 1

Program or magazine changeover

Ausruest.EPS

Fig. 5-2: Conditions for equipment check

Each tool that has been entered in the setup list triggers the following
sequence during the equipment check:

Basic tool data • Based on the tool identification (ID), tool management searches the entire
current tool list for tools with the same name.
• Tool management first assigns the setup list-specific data to each
located tool. Any setup list-specific data that exist from a previously
made comparison will be overwritten.
• If a tool is not contained in the tool list, it is entered as missing in the
tool list of the user interface (sorted by T No.), i.e. tool status bit 1
"Tool does not exist" (⇔ "!") is set.
• Tools in the tool list to which no entry can be assigned in the setup list
are marked by tool management by setting tool status bit 2 "Tool not
required" (⇔"?").
• Depending on the tool, the tool status bits that are responsible for
location locking and location assignment are set or reset.

Tool edge data • Once the setup list-specific data have been assigned, tool manage-
ment checks the tool edge data and the basic tool data.
• For the tool edge data, the tool edge orientation, the existing geometry,
and the wear state are checked. The result is shown using the related
tool edge status bit.
• Tool status bit 5 ("Faulty tool edges" ⇔"f") indicates whether the tool
edge orientation and/or the tool geometry of at least one tool edge
does not satisfy the requirements.
• Accordingly, the wear state of the tool edges is shown in tool status
bits 17 and 18 ("Tool worn out" ⇔ "d" or "Tool below warning limit" ⇔
"w") if at least one tool edge is worn out or below the warning limit.
• From the basic tool data of the tool list, tool management checks the
correction type and the number of tool edges against the specifications
made in the setup list. According to the result, it updates tool status
bits 3 and 4 "Incorrect correction type" (⇔ "t") and "Incorrect number of
tool edges" (⇔ "e").

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-4 Tool Compensation MTC 200 NC programming instruction

Generate alternate tool chains • Tools with the same name that could be assigned to an entry in the
setup list (alternate tools) are summarized in alternate tool chains.
The tools are arranged in the following sequence in each alternate tool
chain:
− usable tools that have already been used, i.e. at least one tool edge
has a remaining tool life of less than 100%.
− usable tools that are still new, i.e. each tool edge has a remaining
tool life of 100%.
− worn tools that would otherwise be usable
− broken tools that would otherwise be usable
− unusable tools.
Within these groups, the sequence is according to increasing duplo
numbers.
The first tool of every alternate tool chain becomes the processing tool
(⇔ "p") of this chain. All other usable tools are marked as replacement
tools (⇔ "s").
• If interface signal PxxC.MGITW (Process xx Command MaGazine
Ignore Tool Worn Out) has been deleted, the NC program terminates
with an error message if there is an alternate tool chain that does not
have any usable tool. If interface signal PxxC.MGITW is set, the be-
havior is basically the same. However, tools that are worn and/or bro-
ken, but otherwise usable, are counted as usable tools.

?
NC program package setup list
(req. data) tools list 6
(actual data) 5
4
3
tool magazine 2
6 1
5 6 0 process
4 5
3 4
2 3
6 6 1 2
5 0 process 1
4 0 process
3
1
2 automatic
0 process equipment check
autoAus.FH7

Fig. 5-3: Basic method of operation of the equipment check (station-specific


organization of the setup list)

Operation without Setup List


The PxxC.MGNSL (Process xx Command No Setup List) interface signal
must be set to "1" if the setup lists are not to be used.
In this case, the NC generates (internally and invisible to the user) an
empty setup list, in which it generates an entry for each T number that
occurs at least once in the current tool list. Then the NC uses this setup
list to execute the equipment check described above; however, the as-
signment between the entry in the generated setup list and the associated
tools in the tool list is made using the T number. Any previously existing
setup list is not taken into account.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-5

5.2 Elements of the Tool Data Record

Overview
The following overview tables contain the entire tool data record. The tool
data record consists of the setup list-specific data and of the tool list-spe-
cific data.

Tool data record The tool data record of a tool consists of


• basic tool data (see section 5.3) and
• 1 to 9 tool edge data records (see section 5.4).
The number of tool edges and, therefore, of tool edge data records is set
by system parameter A00.054 "Maximum tool edge number".

Data type The "Data type in the PLC" column specifies the form in which the indi-
vidual data items are available in the PLC.

Option The data elements for which the number of a system parameter is listed
in the column "Optional datum" are available in the tool data record only if
the entered system parameter is set.

User-defined tool list data The user can administrate application-specific tool data and tool states
within tool management of the Bosch Rexroth MTC 200. For example, the
maximum speed and the weight of a tool can be stored in the user data.
Binary information, such as "Cooling lubricant required" or "Tool resharp-
ened", can be stored in the user status bits. The following system pa-
rameters permit the naming of tool data and tool status bits according to
the requirements of the corresponding application:
• A00.061-A00.069
Designation of user tool data 1-9
• A00.070-A00.074
Designation of user tool edge data 1-5
• A00.092-A00.096
Designation of user tool edge data 6-10
• A00.075-A00.082
Symbol for user tool status bit 1-8,
• A00.083-A00.086
Symbol for user tool edge status bit 1-4,

"Grinding" technology data If tool management is to be used for a grinding machine, system parameter
A00.091 Tool technology must be set to "Grinding". The first 5 tool edge
user data (data elements 31 - 35) are assigned with the following grinding-
specific data:
• Min. spindle speed S min
• Maximum spindle speed S max
• Max. grinding wheel circumferential speed SUG max
• Angle of skew
• Current grinding wheel diameter

The first 5 tool user data are not allowed to be used by the user if system
parameter A00.091 Tool technology is set to "Grinding"!

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-6 Tool Compensation MTC 200 NC programming instruction

5.3 Basic Tool Data


Each basic tool data element is present once for each tool; the elements
can be divided into the following groups:
• Tool identification,
• Location data,
• Units,
• Technology data,
• User data and
• Group data (group status exists for each tool group)

Basic tool data (per tool) V23_20030728

in the PLC
DATA
TYPE

UNIT
DESIGNATION VALUE RANGE DE OPT. SL TL

Tool identification
Index address hexadecimal double word with 32 bits - 01 X X
ID (tool name) up to 28 characters* STRG28 - 02 X
Storage 0-2 - 03 X

Location 0 - 999 - 04 X
Tool number 1 - 9999999 DINT - 05 X X

Tool duplo number 1 - 9999 INT - 06 X

Correction type 1-5 USINT - 07 X X


Number of tool edges 1-9 USINT - 08 X X
Tool status 0/1 (32 status bits) USINT - 09 X

Location data
Free half-locations 0-4 USINT - 10 X

Old pocket 1 - 999 INT - 11 X

Storage location of next setup tool 0 - 2 INT - 12 X

Loc. of next replacement tool 1 - 999 INT - 13 X

Stor. of prev. rep. tool 0-2 INT - 14 X


Loc. of prev. rep. tool 1 - 999 INT - 15 X

Units
Time unit 0/1 (0: min, 1: cycl.) USINT - 16 X

Unit of length 0/1 (0: mm, 1: inch) USINT - 17 X X

Technology data
Tool code 0- 9 USINT - 18 X X
Representation type 0 - 65535 INT - 19 X X

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-7

in the PLC
DATA
TYPE

UNIT
DESIGNATION VALUE RANGE DE OPT. SL TL

User data
User data 1 REAL any 20 A00.061 X
User data 2 REAL 21 A00.062 X
User data 3 REAL 22 A00.063 X

User data 4 REAL 23 A00.064 X


+/- 1.2 * 10-38 - +/- 3.4 * 10+38
User data 5 REAL 24 A00.065 X
and 0 (9 significant digits)
User data 6 REAL 25 A00.066 X

User data 7 REAL 26 A00.067 X

User data 8 REAL 27 A00.068 X

User data 9 REAL 28 A00.069 X

Group data
29
Group number 0 - 99 BYTE - 30 X
Group duplo number 0 - 99 BYTE - 31 X
Group status 0/1 (16 status bits) WORD - 32 X

Comment up to 5 x 76 alphanumeric characters - 99 A00.057 X


WGD_all_V23_20030728.xls

* ASCII character set 32-126, at least 1 character >32


Data element 99 ”Comment” is not loaded in the control.
DE - Data element SL - Setup list-specific datum
R.TL - Replacement tool TL - Tool list-specific datum
STRG28 - STRING28 OPT - Optional datum
Fig. 5-4: Basic tool data (per tool)

All data elements (= "DE" column) of the basic tool data are described in
the following according to the order of the previous figure.

Tool Identification
Index address
DE 01 Basic tool data V22_20021105

Date element 01 INDEX ADDRESS


Relevant for:
Setup list (SL) X
Tool list (TL) X
Location list (LL)
WGD_DE01_V22_20021105.xls

Explanation Index addresses are automatically allocated by the controller when en-
tering a tool. The index address can only be accessed in reading; it is
used for controller-internal management of the tools.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-8 Tool Compensation MTC 200 NC programming instruction

Tool name (ID)


DE 02: Basic tool data V22_20021105

Data element 02 ID (TOOL NAME)


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
WGD_DE02_V22_20021105.xls

Explanation The tool identification (also abbreviated "ID") can consist of a maximum of
28 characters (ASCII character set 32 - 126, min. 1 character >32) , pro-
viding a clear differentiation of the tools in use.
All utilized tools must be clearly named so that they can be uniquely identified
based on their tool name.
Only tools that can substitute each other (alternate tools) are grouped under
one tool name.
Such tools can be distinguished using an additional duplo number (see data
element 06 "Duplo number").
The extended tool designation permits any company-related tool designa-
tion system to be retained on the control level.

Storage
DE 03: Basic tool data V22_20021105

Data element 03 STORAGE


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
WGD_DE03_V22_20021105.xls

Explanation The "Storage" (="Tool storage type") data item is not shown directly within
the tool list. Within the data record, it indicates the type of storage location
at which the tool is located:
0:= Magazine or turret location
1:= Spindle
2:= Gripper

Example NC block for querying the tool storage location in process "P" in which tool
"T" with duplo number "D" is located:
@101=TLD(P,1,T,D,0,3,0)

Location
DE 04 Basic tool data V22_20021105

Data element 04 LOCATION


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
WGD_DE04_V22_20021105.xls

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-9

Explanation Within the tool storage unit, the "Location" data item determines the num-
ber of the tool pocket. For a spindle, it determines the number of the tool
spindle, and for a gripper the gripper location that contains the tool.
Using the tool list, all locations of the tool storage unit and all existing
spindles and grippers can be prepared asynchronously to accommodating
the real tools with respect to data processing.

Injury to operating personnel as well as damage


to the machine and workpiece due to incorrect
magazine equipping!
WARNING ⇒ Once a tool list has been loaded into the controller,
agreement between the actually existing magazine
configuration and the tool list must be ensured.

Example NC block for querying the tool storage location in process "P" in which tool
"T" with duplo number "D" is located:
@101=TLD(P,1,T,D,0,4,0)

Tool number
DE 05 Basic tool data V22_20021105

Data element 05 TOOL NUMBER


Relevant for:
Setup list (SL) X
Tool list (TL) X
Location list (LL)
WGD_DE05_V22_20021105.xls

Explanation Using the T word, which consists of a preceding address letter "T" and a
tool number (up to seven digits) or a tool location number (up to seven
digits), a tool or a location can be accessed within the NC program.
A programmed tool number initiates tool management to determine the
current location of the tool on the basis of the tool number and designa-
tion from the setup list using the designation and tool location number
from the tool list.
The assignment of the tool number (as it is used in the NC program) to
the tool (operation-specific tool name) that is made via the setup list en-
ables the NC program to access a tool.
If a setup list is not used, the current location is accessed directly via the
allocation tool number <> tool location number within the tool list.

Example 1. NC block for positioning tool T1234 on reference position "b" (b=1-4) of
the tool storage unit:
MTP b T1234
2. NC block for changing tool T123 into the spindle (e.g. "simple" milling
machine) for the case that the tool change cycle is called using branch
label "M6":
BSR .M6 T123

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-10 Tool Compensation MTC 200 NC programming instruction

Tool duplo number


DE 06 Basic tool data V22_20021105

Data element 06 DUPLO NUMBER


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
WGD_DE06_V22_20021105.xls

Explanation The tool duplo number is used for:


• an unambiguous identification of alternate tools (tools of the same tool
name and the same T number) and
• defining the utilization sequence of the alternate tools for machining.
The alternate tools are used according to their duplo numbers. Provided it is
neither worn out nor locked, an alternate tool with a lower duplo number is
used for machining before one with a higher duplo number.
The NC program employs the same T number for addressing alternate
tools.
After the previous tool (tool of the same tool number and designation, and
the next smaller duplo number) has been worn out or locked, the control-
ler selects a new alternate tool only if the same T number is invoked
again.

Note: If tools have the same T number and duplo number, tool man-
agement employs the tools by their ascending location num-
bers.

Correction type
DE 07 Basic tool data V22_20021105

Data element 07 CORRECTION TYPE


Relevant for:
Setup list (SL) X
Tool list (TL) X
Location list (LL)
WGD_DE07_V22_20021105.xls

Explanation The correction type defines the number of corrections of a tool and their
locations (see Fig. 5-5:).
• Correction type 1: (boring tool)
A tool of correction type 1 has only one length compensation value
(L3) that is always perpendicular to the current machining plane.
• Correction type 2: (milling tool)
In addition to the length compensation value (L3), which is always
perpendicular to the current machining plane, a tool of correction type
2 has a radius compensation value (R) inside the machining plane.
• Correction type 3: (turning tool)
A tool of this type includes 2 length compensation values (L1, L2) and
one radius compensation value (R) inside the current machining plane.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-11

• Correction type 4: (angle head tool)


Tools of this type are able to perform in all three main axis directions
(X, Y, Z), a length compensation (L1, L2, L3), and a radius compen-
sation (R) in the current machining plane. Length L3 is always per-
pendicular to the current machining plane, while lengths L1 and L2
always lie within the current machining plane.
• Correction type 5: (gripper)
Tools of this type are able to perform a length compensation (L1, L2,
L3) in all three main axis directions (X, Y, Z). Length L3 is always
perpendicular to the current machining plane, while lengths L1 and L2
always lie within the current machining plane.

In order for the tool to be used for the scheduled machining process, the
correction type of the related tool in the magazine must coincide with the
type requested in the setup list.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
effect of the corrections
Type effective corrections Example tool edge orient
G 17/G 20 G 18 G 19
drilling tool
1 1 correction: Y Y Y
1 length correc tion
perpendicular to machining
level L3 0

L3
L3 X X L3 X

Z Z
5-12 Tool Compensation

Z
milling tool
2 2 corrections: Y Y Y
1 length correc tion
perpendicular to machining
level R L3
0
R
L3

Radius correction on
machining level L3 X R X L3 X

R
Z Z Z
lathing tool
3 3 corrections: Y Y Y
2 length corrections on R
the machining level R
L2 L1 0-8
Radius correction on
machining level L2
L2

L1 L1
X X X
R L2

R L1
Z Z Z
angular head tool

Fig. 5-5:: Specifying the correction type


4 4 corrections: Y Y Y L1/L2
1 length correc tion
perpendicular to machining R
level L2 R L1
L3 R 0-8
2 length corrections on the L2
L3
L3

machining level L1 L1 L3
X X X
L2
Radius correction on
machining level R
Z Z Z

www.EngineeringBooksPdf.com
gripper tool
5 3 corrections: Y Y Y
L1/L2
1 length correc tion
perpendicular to machining
level L2 L3 L1
0
2 length corrections on the L2
L3 L1
L3

machining level L1 X X L3 X
L2

Z Z Z

KORR.FH7
MTC 200 NC programming instruction

DOK-MTC200-NC**PRO*V23-AW01-EN-P
MTC 200 NC programming instruction Tool Compensation 5-13

Number of tool edges


DE 08 Basic tool data
V22_20021105

Data element 08 NUMBER OF TOOL EDGES


Relevant for:
Setup list (SL) X
Tool list (TL) X
Location list (LL)
WGD_DE08_V22_20021105.xls

Explanation Each tool can have up to nine tool edge data records assigned, irrespective
of the number of tool edges the tool actually has.
To avoid wasting NC storage space, A00.054 Maximum tool edge number
can be used to reduce the maximum number of tool edges to one tool edge
per tool.
In order to be able to be used for the scheduled machining process, the
related tool must satisfy the number of tool edges that is requested in the
setup list.

Schneidenanzahl.FH7

Fig. 5-6: Examples of tools with varying number of tool edges

Tool status (bits)


DE 09 Basic tool data V22_20021105

Data element 09 TOOL STATUS


Relevant for:
Setup list (SL)
See description of the individual
Tool list (TL)
bits
Location list (LL)
WGD_DE09_V22_20021105.xls

Tool status bits provide information about the current state of the tools
and their locations.

Classification They can be subdivided into status bits that are setup list-, location- and
tool-specific:
• Setup list-specific status bits describe the status of a tool with re-
spect to the requirements of the setup list.
• Location-specific status bits reflect the status of a location.
• Tool-specific status bits describe the status of a tool.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-14 Tool Compensation MTC 200 NC programming instruction

The following table lists all tool status bits. The table is followed by a detailed
explanation of the individual bits.

Tool status bits 1 -16 from basic tool data element 09


Write
Type

Symbol
access

Value

Word
Byte
Bit
Group name Group information Comment

ASP
TM
OP

SL
TL
LL
Tool not available ! 1
1 X X X Tool is missing
Tool available 0
Presence
Tool is not required ? 1 Tool not required for proc-
2
Tool required 0 essing

Correction type wrong t 1 Correction type does not


Error:
3 X X X accord with the require-
correction type Correction type not wrong 0 ments
Incorrect number of tool edges e 1 Number of cutters does

LOW byte 0 - 7
Error:
4 X X X not accord with the re-
tool edge number Correct number of tool edges 0 quirements
Tool edge(s) incorrect f 1 Tool edge data do not
Error: tool edge 5
Tool edge(s) not incorrect 0 comply with requirements

Tool code incorrect $ 1 Does not accord with the


Error: tool code 6
Tool code correct 0 requirements

Reserved for extensions 7


LOW WORD 0 - 15

Reserved for extensions 8

Location locked B 1 ASP/OP: Location is dam-


Location locking 9 X X X X X aged, for example.
Location not locked 0 TM: Tool is entered

Reserved for extensions Upper half-location locking 10

Reserved for extensions Lower half-location locking 11


High byte 0 - 7

Upper half-location reser- Upper half-location reserved ) 1 Reserved for temp. moved
12 X X X X
vation Upper half-location not reserved 0 tools

Lower half-location reser- Lower half-location reserved ( 1 Reserved for temp. moved
13 X X X X
vation Lower half-location not reserved 0 tools

Reserved for extensions Upper half-location locking 14

Reserved for extensions Lower half-location locking 15

Location assigned + 1 There is a tool at this


Location assignment 16 X X X
Location not assigned 0 location

TM - Tool management WSB_all_V22_20030918.xls

OP - Operator
ASP - Application-specific programs in PLC or NC SL - Setup list-specific status bit
LL - Location-specific status bit TL - Tool list-specific status bit

Fig. 5-7: Tool status bits 1 -16 from basic tool data element 09

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-15

Tool status bits 17 -32 from basic tool data element 09


Write
Type
access

Symbol
Group name Group information Comment

Value

Word
Byte

ASP
TM
OP
Bit

SL
TL
LL
Tool is worn out d 1 The remaining lifetime of
17 X X the tool has elapsed (re-
Tool is not worn out 0 place)
Wear state
Warning limit is reached w 1 The remaining lifetime is
18 X X
Warning limit not reached 0 about to expire (replace)

Machining tool p 1 There is a processing tool


19 X X for every alternate tool
No machining tool 0 group
Name of alternate
Replacement tool s 1 A replacement tool is a

LOW byte 0 - 7
20 X X tool still to be used, not a
No replacement tool 0 processing tool
Tool with fixed location coding C 1 The tool may only be
Tool coding 21 X X X X changed into the prede-
Tool without fixed location coding 0 fined tool location
Tool locked L 1
Tool block 22 X X X Tool must not be used
Tool is not locked 0
Tool broken D 1 Tool is damaged: e.g.
Tool breakage 23 X X X
Tool is not broken 0 broken tool edge
High word 0 - 15

Reserved for extension 24

User tool status bit 1 1


User tool status 1 25 X X X Any meaning
A00.075 0

User tool status bit 2 1


User tool status 2 26 X X X Any meaning
A00.076 0

User tool status bit 3 1


User tool status 3 27 X X X Any meaning
A00.077 0
1
High-Byte 0 - 7

User tool status bit 4


User tool status 4 28 X X X Any meaning
A00.078 0

User tool status bit 5 1


User tool status 5 29 X X X Any meaning
A00.079 0

User tool status bit 6 1


User tool status 6 30 X X X Any meaning
A00.080 0

User tool status bit 7 1


User tool status 7 31 X X X Any meaning
A00.081 0

User tool status bit 8 1


User tool status 8 32 X X X Any meaning
A00.082 0
TM - Tool management WSB_all_V22_20030918.xls

OP - Operator SL - Setup list-specific status bit


ASP - Application-specific programs in PLC or NC TL - Tool list-specific status bit
LL - Location-specific status bit T - Tool

Fig. 5-8: Tool status bits 17 -32 from basic tool data element 09

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-16 Tool Compensation MTC 200 NC programming instruction

Note:
• The group definitions in the left column of the previous
table are only used for display (expedient reduction of the
data for the end user).
• These groups are not taken into consideration within the
CNC.
• Status bits with capital letters inform the operator that he
can change their status, if he desires, using the user
interface, the PLC or the NC user program.
• Status bits with lower case letters can not be influenced by
the user. They are administrated by NC tool management.

Setup List-Specific Tool Status Bits


If a tool cannot be used for the subsequent machining process, the setup
list-specific status bits provide detailed information about the cause.
Solely tool management updates setup list-specific status bits. Neither
CNC nor PLC nor the operator can modify the states of these bits.
The setup list-specific status bits are not loaded into the PC when the tool
list is saved.

Tool not available


DE 09 Bit 1 Basic tool data V22_20021106

Data element 09 Tool status


Tool status bit 1: Tool not available
Group information Value Symbol
Tool not available 1 !
Tool available 0
Relevant for: Write access:
Setup list (SL) X Tool management (TM) X
Tool list (TL) X Operator (OP)
Location list (LL) User-specific programs in PLC or NC
(USP)
WSB_1_V22_20021106.xls

Meaning A tool marked with such a status bit is missing; it is not contained in the
tool storage unit.

Symbol ! (request to the operator)

Updating time During the equipment check

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
Program start is not possible

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-17

Tool is not required


DE 09 Bit 2 Basic tool data V22_20021106

Data element 09 Tool status


Tool status bit 2: Tool is not required
Group information Value Symbol
Tool is not required 1 ?
Tool required 0
Relevant for: Write access:
Setup list (SL) X Tool management (TM) X
Tool list (TL) X Operator (OP)
Location list (LL) User-specific programs in PLC or
NC (USP)
WSB_2_V22_20021106.xls

Meaning A tool marked with such a status bit is not needed for the current ma-
chining process.

Symbol ? (question to the operator)

Updating time During the equipment check

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
No effects

Correction type wrong


DE 09 Bit 3 Basic tool data V22_20021106

Data element 09 Tool status


Tool status bit 3: Correction type wrong
Group information Value Symbol
Correction type wrong 1 t
Correction type not wrong 0
Relevant for: Write access:
Setup list (SL) X Tool management (TM) X
Tool list (TL) X Operator (OP)
Location list (LL) User-specific programs in PLC or
NC (USP)
WSB_3_V22_20021106.xls

Meaning A tool marked with such a status bit does not comply with the required
correction type.

Symbol t (type)

Updating time During the equipment check

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-18 Tool Compensation MTC 200 NC programming instruction

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
Program start is not possible

Incorrect number of tool edges


DE 09 Bit 4 Basic tool data V22_20021106

Data element 09 Tool status


Tool status bit 4: Incorrect number of tool edges
Group information Value Symbol
Incorrect number of tool edges 1 e
Correct number of tool edges 0
Relevant for: Write access:
Setup list (SL) X Tool management (TM) X
Tool list (TL) X Operator (OP)
Location list (LL) User-specific programs in
PLC or NC (USP)
WSB_4_V22_20021106.xls

Meaning The tool concerned does not possess the required number of tool edges.

Symbol e (edge)

Updating time During the equipment check

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
Program start is not possible

Tool edge(s) incorrect


DE 09 Bit 5 Basic tool data V22_2002110
6

Data element 09 Tool status


Tool status bit 5: Tool edge(s) incorrect
Group information Value Symbol
Tool edge(s) incorrect 1 f
Tool edge(s) not incorrect 0
Relevant for: Write access:
Setup list (SL) X Tool management (TM) X
Tool list (TL) X Operator (OP)
Location list (LL) User-specific programs in PLC or
NC (USP)
WSB_5_V22_20021106.xls

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-19

Meaning There is at least one of the following faults for at least one tool edge:
• Incorrect tool edge orientation (e)
• L1 faulty (1)
• L2 faulty (2)
• L3 faulty (3)
• R incorrect (r)

Symbol f (fault)

Updating time During the equipment check

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
Program start is not possible

Location-Specific Tool Status Bits


Location-specific status bits describe the status of a location. They are
firmly allocated to specific locations and do not move along with the tool
or the tool's data record.
They are also loaded into the PC when the tool list is saved.

Tool code incorrect


DE 09 Bit 6 Basic tool data V22_20021106

Data element 09 Tool status


Tool status bit 6: Tool code incorrect
Group information Value Symbol
Tool code incorrect 1 $
Tool code correct 0
Relevant for: Write access:
Setup list (SL) X Tool management (TM) X
Tool list (TL) X Operator (OP)
Location list (LL) User-specific programs in PLC or
NC (USP)
WSB_6_V22_20021106.xls

Meaning The entry in DE 18 Tool code in the basic tool data of the tool list does not
correspond with the one in the setup list.

Symbol $

Updating time During the equipment check

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
Program start is not possible

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-20 Tool Compensation MTC 200 NC programming instruction

Tool Status Bits 7 and 8


DE 09 Bit 7 and Bit 8 Reserved for extensions.

Location locked
DE 09 Bit 9 Basic tool data V22_2002110
6

Data element 09 Tool status


Tool status bit 9: Location locked
Group information Value Symbol
Location locked 1 B
Location not locked 0
Relevant for: Write access:
Setup list (SL) Tool management (TM) X
Tool list (TL) X Operator (OP) X
Location list (LL) X User-specific programs in PLC or NC X
(USP)
WSB_9_V22_20021106.xls

Meaning • A locked location is not available to anybody.


• No tool may be stored in it.
• If the location contains a tool when locked, then the tool next to the
location will not be available for machining.
• Tool management locks a location automatically while a tool is being
entered using the "Entering a tool" function.

Symbol B

Updating time Possible at any time

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
− Any transfer requests that concern a locked location are not
permitted (any attempt to do this will generate an error message
and the NC program will be interrupted).
− A locked location cannot be approached using MFP (the location is
not available)
− A tool in a locked location cannot be approached using MTP (the
location and the tool are not available).
− A locked location can be approached only via the tool location num-
ber using the MMP motion command or via MOP.
− In addition to the locations in the magazine, spindles and/or grip-
pers can also be locked.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-21

Tool Status Bits 10 and 11


DE 09 Bit 10 and Bit 11 Reserved for extensions.

Upper half-location reserved


DE 09 Bit 12 Basic tool data
V22_20021106

Data element 09 Tool status


Tool status bit 12: Upper half-location reserved
Group information Value Symbol
Upper half-location reserved 1 )
Upper half-location not reserved 0
Relevant for: Write access:
Setup list (SL) Tool management (TM)
Tool list (TL) X Operator (OP) X
Location list (LL) X User-specific programs in PLC or NC X
(USP)
WSB_12_V22_20021106.xls

Meaning Tool status bit 12 is provided to identify the upper half-location of the tool
location as "reserved".
This status bit is not interpreted by the CNC. It can therefore be used like
a user tool status bit.

Symbol )

Updating time Possible at any time

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
Currently no effects

Lower half-location reserved


DE 09 Bit 13 Basic tool data V22_20021106

Data element 09 Tool status


Tool status bit 13: Lower half-location reserved
Group information Value Symbol
Lower half-location reserved 1 (
Lower half-location not reserved 0
Relevant for: Write access:
Setup list (SL) Tool management (TM)
Tool list (TL) X Operator (OP) X
Location list (LL) X User-specific programs in PLC or X
NC (USP)
WSB_13_V22_20021106.xls

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-22 Tool Compensation MTC 200 NC programming instruction

Meaning Tool status bit 13 is provided to identify the lower half-location of the tool
location as "reserved".
This status bit is not interpreted by the CNC. It can therefore be used like
a user tool status bit.

Symbol (

Updating time Possible at any time

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
Currently no effects

Tool Status Bits 14 and 15


DE 09 Bit 14 and Bit 15 Reserved for extensions.

Location assigned
DE 09 Bit 16 Basic tool data V22_20021106

Data element 09 Tool status


Tool status bit 16: Location assigned
Group information Value Symbol
Location assigned 1 +
Location not assigned 0
Relevant for: Write access:
Setup list (SL) Tool management (TM) X
Tool list (TL) X Operator (OP)
Location list (LL) X User-specific programs in PLC or
NC (USP)
WSB_16_V22_20021106.xls

Meaning There is a tool in the location concerned.

Symbol +

Updating time • In the tool list upon entry.


• In the current tool list when user interface input functions Insert, Re-
move, and Relocate are called.
• During each transfer.

Effects • Restrictions for the operator:


All desktop input functions are permitted
• User program:
All data manipulations are permitted
• Tool management:
A tool transfer to such a location is not permitted.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-23

Tool-Specific Tool Status Bits


The tool-specific status bits describe the state of a tool. They move along
with the tool and/or its data record.
They are also loaded into the PC when a tool list is saved.
Each tool can have up to 8 user-related tool status bits (see the docu-
mentation "Bosch Rexroth MTC 200 parameter description, system para-
meters Axx.075 - Axx.082").

Tool is worn out


DE 09 Bit 17 Basic tool data V22_20021106

Data element 09 Tool status


Tool status bit 17: Tool is worn out
Group information Value Symbol
Tool is worn out 1 d
Tool is not worn out 0
Relevant for: Write access:
Setup list (SL) Tool management (TM) X
Tool list (TL) X Operator (OP)
Location list (LL) User-specific programs in PLC or NC
(USP)
WSB_17_V22_20021106.xls

Meaning • The remaining tool life of at least one tool edge is completely consumed
(remaining tool life ⇐0).
• This bit is also set if tool status bit D ("Tool broken") is set, even if all
tool edge remaining times of the tool are still in the positive range.

Symbol d (defective)

Updating time Tool management updates the "Tool worn out" tool status bit together
with the tool edge status bit of the existing tool edges:
• during the equipment check,
• during a transition to a different tool edge,
• when an edge is requested again
• when the tool is placed back in the magazine
(tool storage = magazine)
• when the tool is rotated out of the machining position
(tool storage = turret),
• when a tool is canceled using T0
(tool storage = turret or no tool storage present).
• if the data of the tool are modified using the interface or the PLC or if the
tool is replaced

Effects • Restrictions for the operator:


− All interface user functions are permitted,
− The remaining tool life can be reset with tool editor function "Edit".
• Restrictions for the user program:
All data manipulations are permitted.
• Restrictions for tool management:

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-24 Tool Compensation MTC 200 NC programming instruction

− The tool is no longer available for further machining.


− A worn-out tool can still be used for machining if it is a tool of the
"Machining tool" status for which no further replacement tool exists.

Warning limit is reached


DE 09 Bit 18 Basic tool data V22_20021106

Data element 09 Tool status


Tool status bit 18: Warning limit is reached
Group information Value Symbol
Warning limit is reached 1 w
Warning limit not reached 0
Relevant for: Write access:
Setup list (SL) Tool management (TM) X
Tool list (TL) X Operator (OP)
Location list (LL) User-specific programs in PLC or
NC (USP)
WSB_18_V22_20021106.xls

Meaning • The remaining tool life of at least one tool edge has reached the warning
limit.
• This bit is also set if tool status bit D ("Tool broken") is set, even if all
tool edge remaining times of the tool are still below the warning limit.
• Tools that have reached the warning limit should be replaced together
with the worn-out tools as soon as possible.

Symbol w (warning limit)

Updating time Tool management updates this tool status bit together with the "Warning
limit reached" tool edge status bit of the existing tool edges:
• during the equipment check,
• during a transition to a different tool edge,
• when an edge is requested again
• when the tool is placed back in the magazine
(tool storage = magazine)
• when the tool is rotated out of the machining position
(tool storage = turret),
• when a tool is canceled using T0
(tool storage = turret or no tool storage present).
• if the data of the tool are modified using the interface or the PLC or if the
tool is replaced

Effects • Restrictions for the operator:


− All interface user functions are permitted,
− The remaining tool life can be reset with tool editor function
"Edit".
• Restrictions for the user program:
All data manipulations are permitted.
• Restrictions for tool management:
A tool whose warning limit has been reached remains a "machining
tool" until it is worn out or locked.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-25

Note: The "w: Warning limit reached" (data element 09 / bit 18) sta-
tus signal is set towards the PLC if tool management determi-
nes that a tool has reached the warning limit and that no further
alternate tool is available.

Machining tool
DE 09 Bit 19 Basic tool data V22_20021106

Data element 09 Tool status


Tool status bit 19: Machining tool
Group information Value Symbol
Machining tool 1 p
No machining tool 0
Relevant for: Write access:
Setup list (SL) Tool management (TM) X
Tool list (TL) X Operator (OP)
Location list (LL) User-specific programs in PLC or NC
(USP)
WSB_19_V22_20021106.xls

Meaning • The "p: Machining tool" status bit characterizes a tool in a group of
alternate tools that becomes the active tool the next time T is invoked
(via the tool number that is common to them all).
• The correction values and the tool life data of this tool are used for
further machining.

p (primary tool)
Symbol
• During the equipment check
Updating time
• when the tool is brought back to the magazine
(tool storage unit = magazine),
• when the tool is rotated out of the machining position
(tool storage = turret)
• when a tool is canceled using T0
(tool storage = turret or no tool storage present).

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
in the case of MTP, the current machining tool is always used.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-26 Tool Compensation MTC 200 NC programming instruction

Replacement tool
DE 09 Bit 20
Basic tool data V22_20021106

Data element 09 Tool status


Tool status bit 20: Replacement tool
Group information Value Symbol
Replacement tool 1 s
No replacement tool 0
Relevant for: Write access:
Setup list (SL) Tool management (TM) X
Tool list (TL) X Operator (OP)
Location list (LL) User-specific programs in PLC or NC
(USP)
WSB_20_V22_20021106.xls

Meaning • A tool from a group of alternate tools is called a "replacement tool" if it


is not yet worn out and is not assigned the "p: Machining tool" status.
• The duplo number specifies the sequence in which the replacement
tools are employed.

Symbol s (secondary tool)

Updating time • during the equipment check,


• when the tool is placed back in the magazine
(tool storage = magazine)
• when the tool is rotated out of the machining position
(tool storage = turret),
• when a tool is canceled using T0
(tool storage = turret or no tool storage present).

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
in the case of "MTP", the machining tool is used first.

Example Following is an example for the selection of an active tool from an alter-
nate tool chain with 4 tools.
The illustration below shows a table for the tool with T No. 77, which is
present a total of 4 times. The activation order for the current processing
tool is displayed in the next figure.

T No. Duplo No. Status Meaning


T77 D1 p Production tool
T77 D2 d Tool is worn out
T77 D31 s Alternate tool
T77 D4 d Tool is worn out
Fig. 5-9: Table for alternate tool selection

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-27

T77 D1 T77 D3 T77 D2 T77 D4

T77 D1
Duplo Number
Tool Number (T-No.)
SchwesterWZ.FH7

Fig. 5-10: Selection of replacement tools from an alternate tool chain

Tool with fixed location coding


DE 09 Bit 21 Basic tool data
V22_20021106

Data element 09 Tool status


Tool status bit 21: Tool with fixed location coding
Group information Value Symbol
Tool with fixed location coding 1 C
Tool without fixed location coding 0
Relevant for: Write access:
Setup list (SL) Tool management (TM) X
Tool list (TL) X Operator (OP) X
Location list (LL) User-specific programs in PLC or X
NC (USP)
WSB_21_V22_20021106.xls

Meaning Tool status bit 21 is used to identify if the tool should be brought back to
the original location in the tool magazine (tool basic data, DE 11 Old loca-
tion) or not.
This status bit is not interpreted by the CNC.

Symbol C

Updating time Possible at any time

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
Currently no effects

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-28 Tool Compensation MTC 200 NC programming instruction

Tool locked
DE 09 Bit 22 Basic tool data V22_20021106

Data element 09 Tool status


Tool status bit 22: Tool locked
Group information Value Symbol
Tool locked 1 L
Tool is not locked 0
Relevant for: Write access:
Setup list (SL) Tool management (TM)
Tool list (TL) X Operator (OP) X
Location list (LL) User-specific programs in PLC or NC X
(USP)
WSB_22_V22_20021106.xls

Meaning A locked tool is no longer available for machining.

Symbol L

Updating time Possible at any time

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
− A locked tool must not be taken into account for MTP.
− It is no longer available for machining, even if no further alternate
tools exist.

Tool broken
DE 09 Bit 23 Basic tool data V22_20021106

Data element 09 Tool status


Tool status bit 23: Tool broken
Group information Value Symbol
Tool broken 1 D
Tool is not broken 0
Relevant for: Write access:
Setup list (SL) Tool management (TM)
Tool list (TL) X Operator (OP) X
Location list (LL) User-specific programs in PLC or NC X
(USP)
WSB_23_V22_20021106.xls

Meaning A broken tool is no longer available for machining.

Symbol D

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-29

Updating time Possible at any time

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
− A broken tool must not be taken into account for MTP.
− A broken tool is no longer available for machining, even if no other
replacement tool is available.
− If interface signal PxxC.MGITW (Command MaGazine Ignore Tool
Worn Out) has been set, the NC program terminates with an error
message during the equipment check if there is an alternate tool
sequence that does not have any usable tool, including a tool that
is worn or broken but otherwise usable.

Tool Status Bit 24


DE 09 Bit 24 Reserved for extensions.

User tool status bits 1 - 8


DE 09 Bit 25 to Bit 32 Basic tool data
V22_20021106

Data element 09 Tool status


Tool status bits 25 - 32: User tool status bits 1 - 8
Group information Value Symbol
User tool status bit 1 1 any
0
Relevant for: Write access:
Setup list (SL) Tool management (TM)
Tool list (TL) X Operator (OP) X
Location list (LL) User-specific programs in PLC or X
NC (USP)
WSB_25_32_V22_20021106.xls

Meaning The programmer can utilize user tool status bits 1 - 8 to record machine-
specific, tool-relevant, binary information. For example, information such as
"Tool has already been resharpened", "Tool has coolant/lubricant hole" or
"Tool requires coolant" can be entered.

Symbol any (according to the set system parameters)


A00.075 - A00.082

Updating time Possible at any time

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
Not taken into account in tool management

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-30 Tool Compensation MTC 200 NC programming instruction

Location Data
Free half-locations
DE 10 Basic tool data V22_20021105

Data element 10 Free half-locations


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
WGD_DE10_V22_20021105.xls

Meaning The datum Free half-locations is not displayed and is currently not stored
with an NC function. The programmer can use it to administrate information
concerning occupied/available half-locations in the tool magazine. As a re-
sult, it is possible, for example, to partially or totally block neighboring
magazine locations for extra-wide tools in order to prevent collisions in the
tool storage unit.

Updating time Possible at any time

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
Not taken into account in tool management

Old pocket
DE 11 Basic tool data V22_20021105

Data element 11 Old pocket


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
WGD_DE11_V22_20021105.xls

Explanation The datum Old pocket is not displayed. It is included in the data record in
order to be able to ensure the associated fixed location, in addition to the
other data items, for fixed location-encoded tools that are in a spindle.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-31

Storage of the next replacement tool


DE 12 Basic tool data V22_20021105

Data element 12 Stor. of next replacement tool


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
WGD_DE12_V22_20021105.xls

Explanation Data element 12 Storage of the next replacement tool describes the stor-
age unit in which the next tool of an alternate tool sequence can be found.
It indicates if the replacement tool is in a
• 0 = Magazine or turret location
• 1 = Spindle or
• 2 = Gripper.
Please remember that the alternate tool sequence is closed. Provided that all
tools are useable, this means that the last tool in this sequence is also the penul-
timate tool in the first sequence.

Location of the next replacement tool


DE 13 Basic tool data V22_20021105

Data element 13 Loc. of next replacement tool


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
WGD_DE13_V22_20021105.xls

Explanation Data element 13 Location of the next replacement tool describes the lo-
cation at which the next tool of an alternate tool sequence can be found.
It contains the number of magazine or turret location, spindle, or gripper.
Please remember that the alternate tool sequence is closed. Provided
that all tools are useable, this means that the last tool in this sequence is
the penultimate tool with respect to the first one (Location of the
previous replacement tool).

Storage of the previous replacement tool


DE 14 Basic tool data V22_20021105

Data element 14 Stor. of prev. rep. tool


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
WGD_DE14_V22_20021105.xls

Explanation Data element 14 Storage of the previous replacement tool describes the
storage unit in which the previous tool of an alternate tool sequence can
be found.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-32 Tool Compensation MTC 200 NC programming instruction

It indicates if the previous replacement tool is in a


• 0 = Magazine or turret location
• 1 = Spindle or
• 2 = Gripper.
Please remember that the alternate tool sequence is closed. Provided
that all tools are useable, this means that the last tool in this sequence is
also the penultimate tool in the first sequence (Location of the previous
replacement tool).

Location of the previous replacement tool


DE 15 Basic tool data V22_20021105

Data element 15 Loc. of prev. rep. tool


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
WGD_DE15_V22_20021105.xls

Explanation Data element 15 Location of the previous replacement tool describes the
location at which the previous tool of an alternate tool sequence can be
found.
It contains the number of magazine or turret location, spindle, or gripper.
Please remember that the alternate tool sequence is closed. Provided that all
tools are useable, this means that the last tool in this sequence is also the
penultimate tool in the first sequence.

T12 D1

next
spare tool
of T12 D1
previous
spare tool T12 D2
of T12 D1
T12 D3

Kette.FH7

Fig. 5-11: Display of an alternate tool sequence with three tools

Note: Data elements DE12 Storage of the next replacement tool,


DE13 Location of the next replacement tool, DE14 Storage of
the previous replacement tool and DE15 Location of the previ-
ous replacement tool can be read only via a user-specific pro-
gram in the PLC or NC with the help of the TLD_RD (PLC) or
TLD (NC) commands.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-33

Units
Time unit
DE 16 Basic tool data V22_20021105

Data element 16 Time unit


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
WGD_DE16_V22_20021105.xls

Explanation Available time units are minutes [min] or NC cycles [cycle].


All tool life data of the tool or the alternate tools (with the exception of the
remaining tool life in percent and warning limit in percent) are measured
and updated in the time unit that is selected here.
When time unit "Cycles" is selected, a single cycle is defined as the time
between tool deactivation (e.g. changing into the spindle) and deactivation
(removing from the spindle).

Unit of length
DE 17 Basic tool data V22_20021105

Data element 17 Unit of length


Relevant for:
Setup list (SL) X
Tool list (TL) X
Location list (LL)
WGD_DE17_V22_20021105.xls

Explanation All geometry data items of a tool can be entered either in millimeters [mm]
or in inches [inch].
The length unit in the setup list need not be the same as the one in the tool
list. When they are loaded into the controller, all geometry data items are
converted into the basic unit for programming that is valid for the process.

Technology Data
Tool code
DE 18 Basic tool data V22_20021105

Data element 18 Tool code


Relevant for:
Setup list (SL) X
Tool list (TL) X
Location list (LL)
WGD_DE18_V22_20021105.xls

Explanation Data element 18 Tool code is significant for "Grinding" technology, which
is set with system parameter A00.091 Tool technology.
Please refer to section "Grinding Wheel-Specific Tool Data" for details
on the tool code.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-34 Tool Compensation MTC 200 NC programming instruction

Representation type
DE 19 Basic tool data V22_20021105

Data element 19 Representation type


Relevant for:
Setup list (SL) X
Tool list (TL) X
Location list (LL)
WGD_DE19_V22_20021105.xls

Explanation Data element 19 Representation type is significant for "Grinding" technol-


ogy, which is set with system parameter A00.091 Tool technology.
Please refer to section "Grinding Wheel-Specific Tool Data" for details
on the representation type.

User Tool Data


User Tool Data 1 - 9
DE 20 to 28 Basic tool data V22_20021105

Data element 20 -28 User data 1 - 9


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
WGD_DE20_28_V22_20021105.xls

Explanation Tool user data items 1 - 9 in the basic tool data permit any user-related
status information to be allocated to a tool.
When the required designation is entered in system parameters A00.061
- A00.069, the user data are accepted in the tool data record and are dis-
played in the offline tool list and the current tool list.
In the offline tool list, the user data can be synchronously prepared in the
same way as the other data items.
Examples of user data in the basic tool data are:
• the weight of the tool (influences e.g. the velocity of the tool change),
• the maximum speed of the tool,
• the maximum dimensions of the tool (for collision checks).

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-35

Tool Group Data


Tool group data are relevant for tool group management.

Group number
DE 30 Basic tool data V23_20030206

Data element 30 Group number


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
WGD_DE30_V23_20030206.xls

Explanation The tool is allocated to a tool group. A reliable value for the group number
is "0" or higher; the higher values are limited by the contents of machine
parameter Bxx.073 "Number of tool groups" (0-99).

Group duplo number

DE 31 Basic tool data V23_20030206

Data element 31 Group duplo number


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
WGD_DE31_V23_20030206.xls

Explanation The tool duplo number is used for:


• uniquely identifying alternate groups and
• specifying the utilization sequence of the alternate groups
With one exception, the group duplo number should be in the range
[0-99]. If the group number contains the value "0", only the value "0" is
permitted for the group duplo number.

Group status
DE 32 Basic tool data V23_20030206

Data element 32 Group status


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
WGD_DE32_V23_20030206.xls

Explanation Data element "Group status" exists for each tool group. It can be acces-
sed both through tool addressing and through group addressing. The fol-
lowing table lists all group status bits. The table is followed by a detailed
explanation of the individual bits.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-36 Tool Compensation MTC 200 NC programming instruction

Tool groups: Group status (data element 32) V23_20021112

Write access Type

Value
Sym-
bol

Bit
Status Status bit Comment
TM OP ASP GL
Presence Group not available ! 1 1 X X Tool in this
group is missing
Group exists 0

Group is not required ? 1 2 X X No tool in this


group is re-
Group is required 0 quired
Group status Group disabled L 1 3 X X X User-program-
mable
Group not disabled 0

Wear state Group worn d 1 4 X X At least one


alternate tool
Group not worn 0 sequence of the
group is worn.
Warning limit is reached w 1 5 X X At least one
alternate tool
Warning limit not reached 0 sequence of the
group has
reached the
warning limit.
Name of alternate Machining group p 1 6 X X Group is ma-
chining group
Not a machining group 0

Spare group s 1 7 X X Group is alter-


nate group
Not a spare group 0

Reserved for extension 8

User group status 1 User group status bit 1 any 1 9 X X X Any meaning

User group status 2 User group status bit 2 any 1 10 X X X Any meaning

User group status 3 User group status bit 3 any 1 11 X X X Any meaning

User group status 4 User group status bit 4 any 1 12 X X X Any meaning

User group status 5 User group status bit 5 any 1 13 X X X Any meaning

User group status 6 User group status bit 6 any 1 14 X X X Any meaning

User group status 7 User group status bit 7 any 1 15 X X X Any meaning

User group status 8 User group status bit 8 any 1 16 X X X Any meaning

0
WZG_all_V23_20021112.xls
TM - Tool management SL - Setup list-specific status bit
OP - Operator TL - Tool list-specific status bit
ASP - Application-spec. programs on the PLC or NC OPT - Optional datum
LL - Location-specific status bit GL - Tool group list-specific status bit
Fig. 5-12: Tool groups: group status (data element 32)

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-37

Group not available


DE 32 Bit 1 Basic tool data V23_20030206

Data element 32 Group status


Group status bit 1: Group not available
Status information Value Symbol
Group not available 1 !
Group exists 0
Relevant for: Write access:
Setup list (SL) Tool management (TM) X
Tool list (TL) Operator (OP)
Location list (LL) User-specific programs in PLC or
NC (USP)
Group list (GL) X
WZG_1_V23_20030206.xls

Meaning A tool group indicated in this way is viewed as not existing because it
does not contain any tools.

Symbol ! (request to the operator)

Updating time During the equipment check

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted.
• Restrictions for tool management:
Currently no effects

Group is not required


DE 32 Bit 2 Basic tool data
V23_20030206

Data element 32 Group status


Group status bit 2: Group is not required
Status information Value Symbol
Group is not required 1 ?
Group is required 0
Relevant for: Write access:
Setup list (SL) Tool management (TM) X

Tool list (TL) Operator (OP)


Location list (LL) User-specific programs in PLC or NC
(USP)
Group list (GL) X
WZG_2_V23_20030206.xls

Meaning A tool group indicated in this way does not contain any of the tools pres-
ent in the setup list. If there is no setup list, all groups are automatically
considered as required.

Symbol ? (question to the operator)

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-38 Tool Compensation MTC 200 NC programming instruction

Updating time During the equipment check

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted.
• Restrictions for tool management:
No effects

Group disabled
DE 32 Bit 3 Basic tool data V23_20030206

Data element 32 Group status


Group status bit 3: Group disabled
Status information Value Symbol
Group disabled 1 L
Group not disabled 0
Relevant for: Write access:
Setup list (SL) Tool management (TM)
Tool list (TL) Operator (OP) X
Location list (LL) User-specific programs in PLC or X
NC (USP)
Group list (GL) X
WZG_3_V23_20030206.xls

Meaning A locked tool group is no longer available for machining.

Symbol L

Updating time Possible at any time

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted.
• Restrictions for tool management:
A locked tool group must not be taken into account for "MTP"
It is no longer available for machining.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-39

Group worn
DE 32 Bit 4 Basic tool data V23_20030206

Data element 32 Group status


Group status bit 4: Group worn
Status information Value Symbol
Group worn 1 d
Group not worn 0
Relevant for: Write access:
Setup list (SL) Tool management (TM) X
Tool list (TL) Operator (OP)
Location list (LL) User-specific programs in PLC or NC
(USP)
Group list (GL) X
WZG_4_V23_20030206.xls

Meaning A tool group is considered to be worn once the first alternate tool se-
quence of the group is worn.

Symbol d (defective)

Updating time During the equipment check

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted.
• Restrictions for tool management:
A worn tool group is no longer available for machining.

Note: If tool management determines that a tool group is worn and no


other alternate tool group is available, interface signal
"PxxS.MGTWO" is set.

Warning limit is reached


DE 32 Bit 5 Basic tool data V23_20030206

Data element 32 Group status


Group status bit 5: Warning limit is reached
Status information Value Symbol
Warning limit is reached 1 w
Warning limit not reached 0
Relevant for: Write access:
Setup list (SL) Tool management (TM) X
Tool list (TL) Operator (OP)
Location list (LL) User-specific programs in
PLC or NC (USP)
Group list (GL) X
WZG_5_V23_20030206.xls

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-40 Tool Compensation MTC 200 NC programming instruction

Meaning This group status bit is set as soon as the first alternate tool sequence of
the tool group has reached the warning limit.

Symbol w (warning limit)

Updating time During the equipment check

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted.
• Restrictions for tool management:
A tool group whose warning limit has been reached remains a "ma-
chining tool group" until it is worn out or locked.

Note: If tool management determines that a tool group has reached


the warning limit and no other alternate tool group is available,
interface signal PxxS.MGWRN is set.

Machining group
DE 32 Bit 6 Basic tool data V23_20030206

Data element 32 Group status


Group status bit 6: Machining group
Status information Value Symbol
Machining group 1 p
Not a machining group 0
Relevant for: Write access:
Setup list (SL) Tool management (TM) X
Tool list (TL) Operator (OP)
Location list (LL) User-specific programs in PLC or NC
(USP)
Group list (GL) X
WZG_6_V23_20030206.xls

Meaning The non-worn, non-locked tool group with the lowest group duplo number
is indicated as the machining group.

Symbol p (primary tool group)

Updating time During the equipment check

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted.
• Restrictions for tool management:
In the case of "MTPb", the tool is always taken from the machining
group.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-41

Spare group
DE 32 Bit 7 Basic tool data V23_20030206

Data element 32 Group status


Group status bit 7: Spare group
Status information Value Symbol
Spare group 1 s
Not a spare group 0
Relevant for: Write access:
Setup list (SL) Tool management (TM) X
Tool list (TL) Operator (OP)
Location list (LL) User-specific programs in PLC
or NC (USP)
Group list (GL) X
WZG_7_V23_20030206.xls

Meaning • A tool group from a group of alternate tool groups is called a "repla-
cement group" if it is not yet worn out and is not assigned the "Machi-
ning tool" status.
• The group duplo number specifies the sequence in which the replace-
ment groups are employed.

Symbol s (secondary tool group)

Updating time During the equipment check

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted.
• Restrictions for tool management:
In the case of "MTP", the tool is always taken from the machining group.

Group status bit 8


DE 32 Bit 8 Reserved for extensions.

User group status bits 1 - 8


DE 32 Bit 9 to Bit 16 Basic tool data V23_20030206

Data element 32 Group status


Group status bits 9 - 16: User group status bits 1 - 8
Status information Value Symbol
User group status bit n 1 any
0
Relevant for: Write access:
Setup list (SL) Tool management (TM)
Tool list (TL) Operator (OP) X
Location list (LL) User-specific programs in PLC or X
NC (USP)
Group list (GL) X
WZG_9-16_V23_20030206.xls

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-42 Tool Compensation MTC 200 NC programming instruction

Meaning User group status bits 1-8 permit any user-related status information to be
allocated to a tool group.

Symbol any

Updating time Possible at any time

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted.
• Restrictions for tool management:
No effects

Other User Tool Data


Comment
DE 99 Basic tool data V22_20021105

Data element 99 Comment


Relevant for:
Setup list (SL) X
Tool list (TL)
Location list (LL)
WGD_DE99_V22_20021105.xls

Explanation Each entry in the setup list can be assigned a comment of up to 5 x 76


characters, provided this has been selected in system parameter A00.057
Comment (assembly instructions).
The comment can be used for related information for each group of alter-
nate tools (assembly instructions, for example).

Note: The comment is available on the user interface only.

5.4 Tool Edge Data


Tool edge data are part of the tool data record and contain the geometry
and wear data of tools. Every tool data record can contain up to 9 tool
edge data records. The max. number of tool edge data records is deter-
mined in system parameter A00.054 Maximum tool edge number.
The data elements of tool edge data records can be subdivided into the
following groups:
• Tool edge identification,
• Tool life data,
• Geometry data,
• Geometry limit values,
• Wear factors,
• User data.
The following table contains all the data elements of a tool edge data rec-
ord:

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-43

Tool edge data (per tool edge) V22_20030317

DATA TYPE in

OPT.
PLC

DE

SL
DESIGNATION VALUE RANGE UNIT

TL
Tool edge identification

Tool edge position 0-8 USINT 01 X X


Tool edge status 0; 1 (16 status bits) WORD 02 X
Tool life data

Remaining tool life -99.9 - +100.00 REAL % 03 A00.059 X


Warning limit +0.1 - +100.00 REAL 04 A00.059 X
Max. utilization time 0 - 9999999 REAL min. or 05 A00.059 X
(0: tool life recording switched off) cycles
Time used 0 - 9999.999 REAL 06 A00.059 X
Geometry data

Length L1 DINT 07 X
Length L2 DINT 08 X
Length L3 DINT 09 X
Radius R DINT 10 X
Wear L1 -99999.9999 - +99999.9999 DINT mm 11 A00.055 X
Wear L2 or DINT or 12 A00.055 X
Wear L3 DINT 13 A00.055 X
-9999.99999 - +9999.99999 inches
Wear R DINT 14 A00.055 X
Offset L1 DINT 15 A00.056 X
Offset L2 DINT 16 A00.056 X
Offset L3 DINT 17 A00.056 X
Offset R DINT 18 A00.056 X
Geometry limit values

L1_min DINT 19 A00.060 X


L1_max DINT 20 A00.060 X
L2_min -99999.9999 - +99999.9999 DINT mm 21 A00.060 X
L2_max or DINT or 22 A00.060 X
L3_min DINT 23 A00.060 X
-9999.99999 - +9999.99999 inches
L3_max DINT 24 A00.060 X
R_min DINT 25 A00.060 X
R_max DINT 26 A00.060 X
Wear factors

Wear factor L1 DINT mm/min, 27 A00.058 X


-99999.9999 - +99999.9999 inches/min or
Wear factor L2 or DINT cycles 28 A00.058 X
Wear factor L3 -9999.99999 - +9999.99999 DINT 29 A00.058 X
Wear factor R DINT 30 A00.058 X
User data

User data 1 REAL any 31 A00.070 X


User data 2 REAL any 32 A00.071 X
+/- 1.2 * 10-38 - +/- 3.4 * 10+38
User data 3 and REAL any 33 A00.072 X
0 (9 significant digits)
User data 4 REAL any 34 A00.073 X
User data 5 REAL any 35 A00.074 X
User data 6 DINT any 36 A00.092 X
User data 7 DINT any 37 A00.093 X
-99999.9999 - +99999.9999
User data 8 or DINT any 38 A00.094 X
-9999.99999 - +9999.99999
User data 9 DINT any 39 A00.095 X
User data 10 DINT any 40 A00.096 X
SD_all_V22_20030317.xls
DE - Data element SL - Setup list-specific datum
OPT - Optional datum TL - Tool list-specific datum

Fig. 5-13: Tool edge data (per tool edge)

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-44 Tool Compensation MTC 200 NC programming instruction

All data elements of the tool edge data record will be described in groups
in the following.

Tool Edge Identification


Tool edge position
DE 01 Tool edge data V22_20021107

Date element 01 Tool edge position


Relevant for:
Setup list (SL) X
Tool list (TL) X
Location list (LL)
Optional datum
SD_DE01_V22_20021107.xls

Explanation The tool edge orientation enables the tools of correction types 3 (turning
tool) and 4 (angle head tool) to be measured with respect to the theoreti-
cal tool tip "P" so that inaccuracies do not result from future machining.

L2 Y(G17)
X(G18)
Z(G19)

8 6

4 3 1 2

S S S S S S

P P P P P P

0 L1 0 L1
5 P S 7 5 P S 7
S P=S P S P=S P
X(G17) X(G17)
Z(G18) Z(G18)
Y(G19) Y(G19)
P P P P P P

S S S S
S S

1 2 4 3
6 8

Y(G17)
L2 X(G18)
Z(G19)
SCHNEIDENLAGE.FH7

Fig. 5-14: Possible positions of a tool edge

If no edge radius/cutter radius path compensation is active, theoretical edge


tip "P" is used as the reference point for the controller.
Thus, theoretical tool tip "P" moves on the programmed contour. With
movements that are not parallel to the axis, this leads to minor inaccura-
cies.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-45

P BB P B
P B
R
P B P B
S S
S
S S
Edge orientation 3

: resulting contour
: path of theoretical Edge peak "P" (programmed contour)
: path of Edge center "S"

P : theoretical edge peak


S : edge center
B : actual touch point
UNSCHNEIDE.FH7

Fig. 5-15:: Errors that occur if machining is performed without using tool edge
radius / cutter radius path compensation

The shaded area in figure Fig. 5-15: will not be removed since the con-
troller is using theoretical edge tip "P" as its point of reference.

Note: Tool edge center "S" is the reference point for the controller if
length compensation is active and tool edge / cutter radius com-
pensation is switched off.

When tool edge radius / cutter radius compensation is active, the CNC auto-
matically moves the actual contact point "B" along the programmed contour.
Thus, the resulting contour is identical to the programmed contour.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-46 Tool Compensation MTC 200 NC programming instruction

Tool edge status bits


DE 02: Tool edge data V22_20021107

Data element 02 Tool edge status


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
Optional datum
SD_DE02_V22_20021107.xls

Explanation Tool edge status bits provide information about the current state of the re-
lated tool edge. They can be subdivided into status bits that are setup list-
specific and tool-specific.

Setup list-specific Setup list-specific status bits 1 - 5 describe the status of a tool edge with
tool edge status bits respect to the requirements of the setup list.
If a tool edge cannot be used for the subsequent machining process, the
setup list-specific status bits provide detailed information about the cause.
Exclusively tool management updates the setup list-specific status bits.
Neither the CNC nor the PLC nor the operator can modify the states of
these bits.
The setup list-specific status bits are not loaded into the PC when the tool
list is saved.

Tool-specific tool edge status Tool-specific tool edge status bits 9 - 16 describe the status of the asso-
bits ciated tool edges. They "move" along with the tool and/or its data record.
They are also loaded into the PC when a tool list is saved.
Each tool edge can have up to 4 user-related tool edge status bits (see
the documentation "Bosch Rexroth MTC 200 parameter description, sys-
tem parameters Axx.083 - Axx.086").
The following table lists all tool edge status bits. The table is followed by a
detailed explanation of the individual bits.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-47

Tool edge status bit from tool edge data element 02


Write
Type
access

Symbol
Group name Group information Comment

Value

ASP
TM
OP
Bit

SL
TL
Incorrect tool edge orientation o 1
Incorrect tool edge Tool edge data do not correspond to
Tool edge orientation is not incor- 0 1 X X
orientation the definition
rect
L1 faulty 1 1 Tool edge data do not correspond to
L1 faulty 2 X X
L1 not incorrect 0 the definition

L2 faulty 2 1 Tool edge data do not correspond to


L2 faulty 3 X X
L2 not incorrect 0 the definition

L3 faulty 3 1 Tool edge data do not correspond to


L3 faulty 4 X X
L3 not incorrect 0 the definition

R incorrect r 1 Tool edge data do not correspond to


R incorrect 5 X X
R not incorrect 0 the definition

Reserved for extensions 6

Reserved for extensions 7

Reserved for extensions 8

Tool edge worn out d 1 The tool edge can no longer be used
9 X X
Tool not worn out 0 (replace)
Wear state
Warning limit is reached w 1 The remaining tool life of the tool edge
10 X X
Warning limit not reached 0 is near its end (replace)

Reserved for extensions 11

Reserved for extensions 12

User tool edge status bit 1 1


User tool edge status 1 13 X X X Any meaning
A00.083 0

User tool edge status bit 2 1


User tool edge status 2 14 X X X Any meaning
A00.084 0
any

User tool edge status bit 3 1


User tool edge status 3 15 X X X Any meaning
A00.085 0

User tool edge status bit 4 1


User tool edge status 4 16 X X X Any meaning
A00.086 0
SSB_all_V22_20030918.xls
TM - Tool management TL - Tool list-specific status bit
OP - Operator SL - Setup list-specific status bit
ASP - Application-specific programs in PLC or NC

Fig. 5-16: Tool edge status bit from tool edge data element 02

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-48 Tool Compensation MTC 200 NC programming instruction

Incorrect tool edge orientation


DE 02 Bit 1 Tool edge data V22_20021107

Data element 02 Tool edge status


Tool edge status bit 1: Incorrect tool edge orientation
Group information Value Symbol
Incorrect tool edge orientation 1 o
Tool edge orientation is not incor- 0
rect
Relevant for: Write access:
Setup list (SL) X Tool management (TM) X
Tool list (TL) Operator (OP)
Location list (LL) User-specific programs in PLC or
NC (USP)
SSB_1_V22_20021107.xls

Meaning The existing tool edge orientation does not correspond to the tool edge
orientation that is required by the setup list.

Symbol o (orientation)

Updating time During the equipment check

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
Machining (program start) is not possible

Tool length L1 faulty


DE 02 Bit 2 Tool edge data V22_20021107

Data element 02 Tool edge status


Tool edge status bit 2: L1 faulty
Group information Value Symbol
L1 faulty 1 1
L1 not incorrect 0
Relevant for: Write access:
Setup list (SL) X Tool management (TM) X
Tool list (TL) Operator (OP)
Location list (LL) User-specific programs in PLC or
NC (USP)
SSB_2_V22_20021107.xls

Meaning The existing L1 tool length does not correspond to the required dimen-
sions (the individual tool dimensions are calculated from geometry, wear
and offset).

Symbol 1

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-49

Visualization In the tool list and in the setup list

Updating time During the equipment check

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
Machining (program start) is not possible

Tool length L2 faulty


DE 02 Bit 3 Tool edge data V22_20021107

Data element 02 Tool edge status


Tool edge status bit 3: L2 faulty
Group information Value Symbol
L2 faulty 1 2
L2 not incorrect 0
Relevant for: Write access:
Setup list (SL) X Tool management (TM) X
Tool list (TL) Operator (OP)
Location list (LL) User-specific programs in PLC or NC
(USP)
SSB_3_V22_20021107.xls

Meaning The existing L2 tool length does not correspond to the required dimen-
sions (the individual tool dimensions are calculated from geometry, wear
and offset).

Symbol 2

Visualization In the tool list and in the setup list

Updating time During the equipment check

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
Machining (program start) is not possible

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-50 Tool Compensation MTC 200 NC programming instruction

Tool length L3 faulty


DE 02 Bit 4 Tool edge data V22_20021107

Data element 02 Tool edge status


Tool edge status bit 4: L3 faulty
Group information Value Symbol
L3 faulty 1 3
L3 not incorrect 0
Relevant for: Write access:
Setup list (SL) X Tool management (TM) X
Tool list (TL) Operator (OP)
Location list (LL) User-specific programs in PLC or NC
(USP)
SSB_4_V22_20021107.xls

Meaning The existing L3 tool length does not correspond to the required dimensions
(the individual tool dimensions are calculated from geometry, wear and offset).

Symbol 3

Visualization In the tool list and in the setup list

Updating time During the equipment check

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
Machining (program start) is not possible

Tool radius R incorrect


DE 02 Bit 5 Tool edge data V22_20021107

Data element 02 Tool edge status


Tool edge status bit 5: R incorrect
Group information Value Symbol
R incorrect 1 r
R not incorrect 0
Relevant for: Write access:
Setup list (SL) X Tool management (TM) X
Tool list (TL) Operator (OP)
Location list (LL) User-specific programs in PLC or NC
(USP)
SSB_5_V22_20021107.xls

Meaning The existing tool radius R does not correspond to the required dimensions
(the individual tool dimensions are calculated from geometry, wear and offset).

Symbol r

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-51

Visualization In the tool list and in the setup list

Updating time During the equipment check

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
Machining (program start) is not possible

Tool Edge Status Bits 6, 7, and 8


DE 02 Bit 6 to 8 Reserved for extensions.

Tool edge worn out


DE 02 Bit 9 Tool edge data V22_20021107

Data element 02 Tool edge status


Tool edge status bit 9: Tool edge worn out
Group information Value Symbol
Tool edge worn out 1 d
Tool not worn out 0
Relevant for: Write access:
Setup list (SL) Tool management (TM) X
Tool list (TL) X Operator (OP)
Location list (LL) User-specific programs in PLC or
NC (USP)
SSB_9_V22_20021107.xls

Meaning The remaining tool life of the tool edge is less than or equal to zero.

Symbol d

Updating time • during the equipment check,


• during a transition to a different tool edge,
• when an edge is requested again
• when the tool is brought back to the magazine
(tool = magazine),
• when the tool is rotated out of the machining position
(tool storage = turret),
• when a tool is canceled using T0
(tool storage = turret or no tool storage present),
• if the data of the tool are modified using the interface or the PLC or if the
tool is replaced.

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
A replacement tool must be used (if there is one) when the tool num-
ber concerned is invoked again.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-52 Tool Compensation MTC 200 NC programming instruction

Warning limit is reached


DE 02 Bit 10 Tool edge data V22_20021107

Data element 02 Tool edge status


TOOL EDGE STATUS BIT 10: WARNING LIMIT IS REACHED
Group information Value Symbol
Warning limit is reached 1 w
Warning limit not reached 0
Relevant for: Write access:
Setup list (SL) Tool management (TM) X
Tool list (TL) X Operator (OP)
Location list (LL) User-specific programs in PLC or NC
(USP)
SSB_10_V22_20021107.xls

Meaning The remaining tool life is less than the warning limit.

Symbol w

Updating time • during the equipment check,


• during a transition to a different tool edge,
• when an edge is requested again
• when the tool is brought back to the magazine
(tool = magazine),
• when the tool is rotated out of the machining position
(tool storage = turret),
• when a tool is canceled using T0
(tool storage = turret or no tool storage present),
• if the data of the tool are modified using the interface or the PLC or if the
tool is replaced.

Effects • Restrictions for the operator:


All interface user functions are permitted,
• Restrictions for the user program:
All data manipulations are permitted.
• Restrictions for tool management:
No immediate effect

Tool Edge Status Bits 11 and 12


DE 02 Bit 11 and Bit 12 Reserved for extensions.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-53

User tool edge status bits 1 - 4


DE 02 Bit 13 to Bit 16 Tool edge data V22_20021107

Data element 02 Tool edge status


Tool edge status bits 13 - 16: User tool edge status bits 1 - 4
Group information Value Symbol
User tool edge status bits 1 - 4 1 any
0
Relevant for: Write access:
Setup list (SL) Tool management (TM)
Tool list (TL) X Operator (OP) X
Location list (LL) User-specific programs in PLC X
or NC (USP)
SSB_13-16_V22_20021107.xls

Meaning User tool edge status bits 1 - 4 permit any user-related status information
to be allocated to a tool edge.

Symbol any

Updating time Possible at any time

Effects • Restrictions for the operator:


All desktop input functions are permitted
• Restrictions for the user program:
All data manipulations are permitted
• Restrictions for tool management:
No effects

Tool Life Data


Remaining tool life
DE 03: Tool edge data V22_20021107

Data element 03 Remaining tool life


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
Optional datum A00.059
SD_DE03_V22_20021107.xls

Explanation The remaining tool life in percent specifies the wear state of a tool in per-
cent, irrespective of the tool / workpiece material combination and the tech-
nology data.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-54 Tool Compensation MTC 200 NC programming instruction

First entry of remaining tool life

tRest[min]
tRest[%] = *100
tUtil[min]
tRest[cycles]
tRest[%] = *100
tUtil[cycles]
tRest[%] remaining tool life in percent
tRest[min] remaining tool life in min.
tRest[cycles] remaining tool life in cycles
tUtil[min] max. utilization time in min.
tUtil[cycles] max. utilization time in cycles
Fig. 5-17: Calculation of remaining tool life in percent

A new or resharpened tool has a remaining tool life of 100%. Corre-


spondingly, a worn-out tool has a remaining tool life of 0%.
Based on the remaining tool life in percent, tool management monitors
and manages the wear state of the tool, irrespective of the tool / work-
piece material combination of the existing machining processes.

To monitor the actual remaining tool life with the theoretical tool life de-
Negative remaining tool life fined from the production planning, tool management can also determine
and manage negative remaining tool life. This allows the determination of
the actual tool life, minimizing the tool costs.

Update remaining tool life Tool management updates the remaining tool life automatically in percent:
• during the equipment check,
• during a transition to a different tool edge,
• when an edge is requested again
• when the tool is brought back to the magazine
(tool storage unit = magazine),
• when the tool is rotated out of the machining position
(tool storage = turret)
• when a tool is canceled using NC command T0
(tool storage = turret or no tool storage present).
The following requirements must be satisfied in order to permit machining
sequences to be taken into account in the calculation of the remaining
tool life for a tool:
• an interpolation with feed movement must have been programmed for
the tool (G1, G2, G3) and
• the tool must be programmed (= active).
The calculation of the remaining tool life in percent is based on the fol-
lowing formula:

tOn[min]
tRest[%] = tRest before[%] − *100
tUtil[min]
tOn[cycles]
tRest[%] = tRest before[%] − *100
tUtil[cycles]
tRest[%] remaining tool life after tool utilization
tRest before[%]remaining tool life before tool utilization
tOn[min] contact time of the tool in min.
(all programmed tool movements with feed rate)
tOn[cycles] contact time of the tool in cycles
(all programmed tool movements with feed rate)
tUtil[min] max. utilization time in min.
tUtil[cycles] max. utilization time in cycles
Fig. 5-18: Updating of remaining tool life in percent

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-55

Each time that updating occurs, tool management checks the remaining
tool life and sets the status "d" - Tool worn out (basic tool data element 09
/ bit 17) if the remaining tool life of a tool has expired or is exceeded. If no
further alternate tool that is not worn out is available for the tool whose
remaining tool life is expired, interface signal PxxS.MGTWO (MaGazine
Tool Worn Out) is set towards the PLC.
For further information, see the description "Bosch Rexroth MTC 200 tool
management", chapter "Movement control of a tool storage unit", section
"Tool life monitoring: tool worn "PxxS.MGTWO"" or the description "Bosch
Rexroth MTC 200 PLC interface description".

Warning limit
DE 04 Tool edge data V22_20021107

Data element 04 Warning limit


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
Optional datum A00.059
SD_DE04_V22_20021107.xls

Explanation The warning limit in percent is determined by the user and specifies the
remaining tool life in percent at which tool management signals the "w"
Warning limit reached status.
During every update, tool management checks the remaining tool life and
sets interface signal PxxS.MGWRN MGWRN (MaGazine WaRNing –
warning limit reached) to the PLC if the remaining tool life of a tool has
reached the warning limit and all alternate tools also have the status "Tool
warning limit reached".
For further information, see the description "Bosch Rexroth MTC 200 tool
management", chapter "Movement control of a tool storage unit", section
"Tool life monitoring: warning limit reached "PxxS.MGWRN"" or the
description "Bosch Rexroth MTC 200 PLC interface description".

Max. utilization time


DE 05 Tool edge data V22_20021107

Data element 05 Max. utilization time


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
Optional datum A00.059
SD_DE05_V22_20021107.xls

Explanation The maximum utilization time is the cutting time in minutes or NC cycles
during which a tool is used for cutting for a specific tool/material combina-
tion, from resharpening to the worn-out state, and under equal cutting con-
ditions. The Maximum utilization time is determined by the user.

Note: Entering "0" for the maximum utilization time switches off the
tool life updating process of the tool concerned.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-56 Tool Compensation MTC 200 NC programming instruction

Time used
DE 06 Tool edge data V22_20021107

Data element 06 Time used


Relevant for:
Setup list (SL) X
Tool list (TL)
Location list (LL)
Optional datum A00.059
SD_DE06_V22_20021107.xls

Explanation DE 06 Time used is not displayed and currently not interpreted in the NC.

Geometry Data
Explanation When the corresponding correction is active, the dimensions of a tool are
compensated automatically using the geometry data.
The geometry data items are subdivided as follows:
Geometry (register) Wear (register) Offset (register)
Length L1 Wear L1 Offset L1
Length L2 Wear L2 Offset L2
Length L3 Wear L3 Offset L3
Radius R Wear R Offset R

The wear and offset registers can be activated using system parameters
• A00.055 Wear register and
• A00.056 Offset register

Geometry register: Length L1 / L2 / L3 / radius R


DE 07 - 10 Tool edge data V22_20021107

Data element 07 Length L1


Data element 08 Length L2
Data element 09 Length L3
Data element 10 Radius R
Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
Optional datum
SD_DE07_10_V22_20021107.xls

The geometry registers are used as program-independent memories that


assist in compensating the tool dimensions.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-57

Wear registers: Wear L1 / L2 / L3 / radius R


DE 11 - 14 Tool edge data V22_20021107

Data element 11 Wear L1


Data element 12 Wear L2
Data element 13 Wear L3
Data element 14 Wear R
Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
Optional datum A00.055
SD_DE11_14_V22_20021107.xls

The CNC uses wear registers for compensating the time-related wear of
the tools with the help of the wear factors.
To do this, it calculates the associated wear value at certain points in time
(see "Wear factors") and adds it to the existing values in the wear regis-
ters.
As long as the wear factors (tool edge data elements 27 - 30) have not
been activated in system parameter A00.058 Wear factors or are set to
zero in the data records, the wear registers are exclusively available to the
user.
The wear registers can be influenced by
• tool editor function "Edit"
(see the documentation "Bosch Rexroth MTC 200 tool management –
user description")
and by
• user-configurable HMI function "Acknowledge tool change/ tool
breakage"
(see the WIN-HMI documentation
"Bosch Rexroth MTC 200 / ISP 200 / MTA 200 WinHMI user interface
– user description")
Besides resetting the remaining tool life in percent to 100%, all wear reg-
isters belonging to the tool will be deleted and the tool will be enabled
again for processing (basic tool data - tool status bit 22 = "0").

Note: If the wear registers in system parameter A00.055 Wear regis-


ter are not selected, they will be internally set to zero.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-58 Tool Compensation MTC 200 NC programming instruction

Offset registers: Offset L1 / L2 / L3 / radius R


DE 15 -18 Tool edge data V22_20021107

Data element 15 Offset L1


Data element 16 Offset L2
Data element 17 Offset L3
Data element 18 Offset R
Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
Optional datum A00.056
SD_DE15_18_V22_20021107.xls

The CNC does not influence the offset registers. Like the wear registers,
they may be used for compensating dimensional deviations that are deter-
mined either by the user or by a measuring control action.
The offset registers may also be used as memories for additional offsets,
such as for the compensation of adapter dimensions.

Note: If the offset registers in system parameter A00.056 Offset


register are not selected, they will be internally set to zero.

Length Compensation
The length values "L1", "L2", "L3" of a tool edge are calculated as follows:

Length correction L1 = Length L1 + Wear L1 + Offset L1 + L1 of D correction


Length correction L2 = Length L2 + Wear L2 + Offset L2 + L2 of D correction
Length correction L3 = Length L3 + Wear L3 + Offset L3 + L3 of D correction
Fig. 5-19: Calculation of tool lengths

Note: The D corrections are active only if they are programmed in


• process parameter Bxx.029 D corrections and with
• NC commands G48 Tool lengths – positive compensation
or G49 Tool lengths – negative compensation (also see the
section "Tool length compensation").

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-59

Wear L3 = -0.115 mm

L3 = 215.316 mm

Offset L3 = 20.267 mm

L3 215.316 mm
+ Wear L3 -0.115 mm
+ Offset L3 20.267 mm
Length correction L3 235.468 mm
LAENGENKORR.FH7

Fig. 5-20: Length compensation value "L3", example of a throwaway insert drill
(without D correction)

Radius Compensation
The radius compensation value "R" of a tool edge is calculated as follows:

Radius correction R = Radius R + Wear R + Offset R + R of D correction


Fig. 5-21: Calculation of radius compensation "R" L3 = 187.236 mm

Wear R = -0.084 mm

R = 40.051 mm

R 40.051 mm
+ Wear R -0.084 mm
+ Offset R 0 mm
Radius correction R 39.967 mm
RADIUSKORR.FH7

Fig. 5-22: Radius compensation "R", example of a cutter head (without D correc-
tion)

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-60 Tool Compensation MTC 200 NC programming instruction

Geometry Limit Values


Explanation Geometry limit values enable the tools in the tool storage unit to be
checked with respect to their fitness for being employed in the forthcom-
ing machining process.
Whether or not length and radius values of the related tool are suitable for
the machining process which is to be performed is verified during the
equipment check when an NC program is started. Thus, it prevents stand-
still periods during the machining process. The setup list is used for the
equipment check if the PLC interface PxxC.MGNSL (Process xx Com-
mand MaGazine No Setup List) is not set (= basic state).
Besides ensuring that tools suitable for machining are available, the spe-
cification of reasonable geometry limit values already permits collisions to
be prevented during programming.

Note: The geometry limit values of the setup list are not taken into
account in the calculation of tool compensation processes.

Maximum and minimum length / radius


DE 19 -26 Tool edge data V22_20021107

Data element 19 L1_min


Data element 20 L1_max
Data element 21 L2_min
Data element 22 L2_max
Data element 23 L3_min
Data element 24 L3_max
Data element 25 R_min
Data element 26 R_max
Relevant for:
Setup list (SL) X
Tool list (TL)
Location list (LL)
Optional datum A00.060
SD_DE19_26_V22_20021107.xls

Explanation The maximum length values "L1_max", "L2_max" and "L3_max", as well
as the minimum lengths: "L1_min", "L2_min" and "L3_min" specify the li-
mits of the corresponding length value within which the intended machi-
ning processes can still be performed.
The maximum radius "R_max" and
the minimum radius "R_min"
specify the limits of the tool radius within which the intended machining
processes can still be performed.

Example 1 A groove cutter is to be used for machining a 30 mm deep groove.


• tool name (ID) : Groove cutter D12
• maximum length (L3_max) : 60 mm
• minimum length (L3_min) : 30 mm

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-61

When it starts (start of advance program or of reverse program), the CNC


checks whether there is at least one tool with the name "Groove cutter
D12" that is not shorter than the minimum length of 30 mm and not longer
than the maximum length of 60 mm.

Example 2 A groove cutter is to be used for machining a 20 mm wide pocket


(+ 0.02 mm / - 0.04 mm).
tool name (ID) : Groove cutter D20
maximum radius (R_max): 20.02/2 = 10.01 mm
minimum radius (R_min): 19.96/2 = 9.98 mm
When it starts (start of advance program or of reverse program), the CNC
checks whether there is at least one tool with the name "Groove cutter
D20" that is not thinner than the minimum radius of 9.98 mm and not
thicker than the maximum radius of 10.01 mm.

Wear Factors
Wear factors can be used for compensating wear-related variations in tool
length and tool radius.

Length wear factors (L1, L2 and L3)


DE 27 -29 Tool edge data V22_20021107

Data element 27 WEAR FACTOR L1


Data element 28 Wear factor L2
Data element 29 Wear factor L3
Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
Optional datum A00.058
SD_DE27_29_V22_20021107.xls

Explanation Length wear compensation is activated if tool length correction is acti-


vated via G48 Tool length compensation positive or G49 Tool length
compensation negative.
The compensation value used to adjust for tool length wear is calculated in
the tool management system by multiplying the duration of the tool machin-
ing time by the length wear factor.
If the length wear factor is entered in "mm/min" or "inch/min", the tool
management system uses the total time in which the tool was active while
working motion was being carried out (all moves with the exception of
G00 Rapid traverse) as the machining time.
However, if the tool wear factor is entered in "mm/cycle" or "inch/cycle", the
tool management system uses one cycle as the machining time. Thus, the
compensation value for tool length corresponds to the tool wear factor.
The tool management system automatically updates the machining time
and, thus, the compensation value for length wear
• during a transition to a different tool edge,
• when an edge is requested again
• when the tool is placed back in the magazine
(tool storage = magazine)
• when the tool is rotated out of the machining position
(tool storage = turret)

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-62 Tool Compensation MTC 200 NC programming instruction

• when a tool is canceled using T0


(tool storage = turret or no tool storage present).

Radius wear factor (R)


DE 30 Tool edge data V22_20021107

Data element 30 Wear factor R


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
Optional datum A00.058
SD_DE30_V22_20021107.xls

Explanation Radius wear compensation is activated when tool path compensation is


activated via G41 Tool path compensation left or G42 Tool path com-
pensation right.
The compensation value used to adjust for tool radius wear is calculated
in the tool management system by multiplying the duration of the tool ma-
chining time by the radius wear factor.
If the radius wear factor is entered in "mm/min" or "inch/min", the tool
management system uses the total time in which the tool was active while
working motion was being carried out (all moves with the exception of
G00 Rapid traverse) as the machining time.
However, if the radius wear factor is entered in "mm/cycle" or "inch/cycle",
the tool management system uses one cycle as the machining time. Thus,
the compensation value for tool radius corresponds to the radius wear fac-
tor.
The tool management system automatically updates the machining time
and, thus, the compensation value for radius wear
• during a transition to a different tool edge,
• when an edge is requested again
• when the tool is placed back in the magazine
(tool storage = magazine)
• when the tool is rotated out of the machining position
(tool storage = turret)
• when a tool is canceled using T0
(tool storage = turret or no tool storage present).

Example A large number of shafts are to be produced within a machining center.


Besides other machining steps, each CK45 shaft is to be fitted with a
feather key groove that is to be machined using solid carbide tools.
From previous tests it is known that the width of the groove decrements
from one shaft to the next by an average 0.0052 mm.
To compensate this wear during production, a radius wear factor of
0.0026 mm/cycle must be entered.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-63

User Tool Edge Data


User tool edge data 1-10
DE 31 -40 Tool edge data
V22_20021107

Data element 31 -40 User data 1 -10


Relevant for:
Setup list (SL)
Tool list (TL) X
Location list (LL)
Optional datum DE 31 - 35 A00.070 - A00.074
Optional datum DE 36 - 40 A00.092 - A00.096
SD_DE31_40_V22_20021107.xls

Explanation Tool edge user data 1 - 10 permit any tool edge to have any user-specific
data items assigned.

Grinding wheel-specific tasks: see the section "Grinding wheel-spe-


cific tool data"

By entering the requested designation into the system parameters


• A00.070 Tool edge user data 1 (PLC data type = REAL)
• ...
• A00.074 Tool edge user data 5 (PLC data type = REAL) and
• A00.092 Tool edge user data 6 (PLC data type = DINT)
• ...
• A00.096 Tool edge user data 10 (PLC data type = DINT),
the user data is accepted in each tool edge data record, and is displayed in
the tool list and in the current tool list (see also "Bosch Rexroth MTC 200
parameter description").
In the tool list, the user data can be prepared in the same way as the other
data items.
Examples of user data in the tool edge data are:
• Cutting speed,
• Feed per tooth,
• Spindle speed
• Machining feed,
• Dimensional correction internal buffer,
• Average value, and
• Empirical value

Note: User tool edge data items 1-5 are returned to the PLC as REAL
values.
User tool edge data items 6-10 are specified as DINT.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-64 Tool Compensation MTC 200 NC programming instruction

5.5 Grinding Wheel-Specific Tool Data{0><}100{>


For grinding wheel-specific tasks, the first five tool user data (data ele-
ments 31 to 35 of the tool edge data) are reserved for grinding-specific
parameters if system parameter A00.091 Tool technology is set to
"Grinding". Further tool edge-specific user data can be used as required.

Note: When operating without setup lists, the user must enter the
designations of required grinding wheel-specific parameters
(data elements 31 to 35 of tool edge data) manually to activate
them.

Minimum spindle speed The data element is an editable element in the setup list and in the tool
(S min) DE 31 list. In operation with setup lists, the value from the setup list is accepted
in the tool list when the equipment check is performed. In operation with-
out setup lists, the value in the tool list is assigned a default value. After
the related data record has been activated in one of the spindles, the data
element is the minimum permissible spindle speed command value, tak-
ing the override into account. The specified minimum spindle speed is
also taken into account as the minimum permissible speed value when
the grinding wheel circumferential speed (SUG) is active. The conversion
for an active SUG is calculated according to the formula that is discussed
in conjunction with the grinding wheel circumferential speed.
• If setup lists are used for operation, the value 0 corresponds to the
state "Inactive checking".
• The data element is displayed according to the setting of system pa-
rameter A00.091 "Tool technology" in the setup list/tool list.
• If a corresponding tool data record has been activated for machining,
the value is considered as the lower spindle speed limit, below which
the value must not fall (including override). An error message is is-
sued if the command value falls below this limit speed.

Maximum spindle speed The data element is an editable element in the setup list and in the tool
(S max) DE 32 list. In operation with setup lists, the value from the setup list is accepted
in the tool list when the equipment check is performed. In operation with-
out setup lists, the value in the tool list is assigned a default value. After
the related data record has been activated in one of the spindles, the data
element is the maximum permissible spindle command value, taking the
override into account. The specified maximum spindle speed is also
taken into account as the maximum permissible speed value when the
grinding wheel circumferential speed (SUG) is active. The conversion for
an active SUG is calculated according to the formula that is discussed in
conjunction with the grinding wheel circumferential speed.
• If setup lists are used for operation, the value "0" corresponds to the
state "Inactive checking".
• The data element is displayed according to the setting of system pa-
rameter A00.091 "Tool technology" in the setup list/tool list.
• If a corresponding tool data record has been activated for machining,
the value is considered as the lower spindle speed limit that must not
be exceeded (including override). An error message is issued if the
command value exceeds this limit speed.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-65

SUG max[ m / s ] * 60000


S max[1 / min] =
dAct [ mm ] * π
SUG max[ ft / s ] * 720
S max[1 / min] =
dAct[inch ] * π
Smax : Maximum spindle speed
SUGmax : Max. grinding wheel circumferential speed
dAct : Actual grinding wheel diameter
Fig. 5-23: Calculation of maximum spindle speed

Maximum grinding wheel The data element is an editable element in the setup list and in the tool
circumferential speed list. In operation with setup lists, the value from the setup list is accepted
(SUG max) DE 33 in the tool list when the equipment check is performed. In operation with-
out setup lists, the value in the tool list is assigned a default value. After
the related data record has been activated in one of the spindles and the
SUG has been activated (G66), the data element is the maximum per-
missible spindle command value, taking the override into account.

dAct[mm] * p * Smax[1/min]
SUGmax[m/s] =
60000
dAct[inch] * p * Smax[1/min]
SUGmax[ft/s] =
720
SUGmax : Max. grinding wheel circumferential speed
dAct : Actual grinding wheel diameter
Smax : Maximum spindle speed
Fig. 5-24: Calculation of maximum grinding wheel circumferential speed

• Data element "Max. grinding wheel circumferential speed" is evaluated


only when the SUG is active.
• If setup lists are used for operation, the value 0 corresponds to the
state "Inactive checking".
• The data element is displayed only in the setup/tool list for the three
defined tool codes 1, 2, and 3.

Angle of skew The "Angle of skew" data element is an editable element in the setup list
(slant angle) DE 34 and in the tool list. The data element is available only for tool code 2. The
value is required to calculate the grinding wheel diameter. The angle of
skew is entered in degrees.

Current grinding wheel diameter The "Grinding wheel diameter" data element is a pure display element
(current grinding wheel ∅) DE 35 that cannot be edited. The data element is available only in the tool list.
The computation formula for the grinding wheel diameter depends on the
entered tool code and the existing geometry elements. The data element
is displayed only for the three defined tool codes (1, 2, and 3). A value is
not displayed if a correction type ≤3 is entered.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-66 Tool Compensation MTC 200 NC programming instruction

Tool Code WGD DE 18


If system parameter A00.091 has been set to "Grinding" technology, data
element 18 of basic tool data "Tool code" receives the following meaning:

Tool code Meaning

0 Standard tool data record


1 Straight circumferential grinding wheel
2 Inclined grinding wheel
3 Surface grinding wheel
4-9 No special function (standard tool data record)
Fig. 5-25: Table of tool codes

The tool code definition is required for grinding machines in order to be


able to calculate the grinding wheel circumferential speed. Depending on
the type of grinding wheel, geometry register L1 or L2 is needed for cal-
culating the spindle speed from the programmed circumferential speed of
the wheel.

Tool code 0 - 3 The input of tool code 1-3 is relevant and is processed only if the "Tool
technology" system parameter has been preset to "grinding". In all other
cases, the preset values of the data element are ignored.
Depending on the entered tool code, the associated tool edge data record
(tool list and setup list) is displayed on the desktop. The grinding-specific
(user) data items also depend on the selected correction type. In order to
be able to utilize the grinding-specific (user) data expediently, a correction
type ≥ 3 must be entered for the defined grinding wheels.

Tool code 1 For the straight circumferential grinding wheel, the correction type ele-
"Straight circumferential grinding ment in the tool data record must be filled in with 3, 4 or 5.
wheel" The current wheel diameter is calculated via tool length compensation L1.

dAct = (L1 + L1Offset + L1Wear)* 2


Fig. 5-26: Current wheel diameter for tool code 1
L1
R

L2
GERADE_SCHEIBE.FH7

Fig. 5-27: Straight circumferential grinding wheel

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-67

Tool code 2 For the angled grinding wheel, the correction type element in the tool data
“Inclined grinding wheel” record must be filled in with 3 or 5.
The current wheel diameter is calculated via tool length compensation L1
and the angle ϕ.

(L1 + L1Offset + L1Wear) * 2


dAct =
cosj
Fig. 5-28: Current wheel diameter for tool code 2

L1
R
L2
SCHRAEGE_SCHEIBE.FH7

Fig. 5-29: Inclined grinding wheel

Tool code 3 For the surface-grinding wheel, the correction type element in the tool
“Surface grinding wheel” data record must be filled in with 3, 4, or 5.
The current wheel diameter is calculated via tool length compensation L2.

dAct = (L2 + L2Offset + L2Wear) * 2


Fig. 5-30: Current wheel diameter for tool code 3
L1
R

L2

PLANSCHEIBE.FH7

Fig. 5-31: Surface grinding wheel

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-68 Tool Compensation MTC 200 NC programming instruction

Representation Type WGD DE 19


Representation type The representation type has a range of 0-65535. The data element can
be edited in the setup list and in the tool list. If the data element has a
value assigned in the setup list that is different than zero, the values are
checked for equality in the equipment check. In the case of a discrepancy,
bit 6 of the tool status bits is assigned the code "$". Any further process-
ing is not intended for the time being.

5.6 Tool Path Compensation

Inactive Tool Path Compensation


If no edge radius/cutter radius path compensation is active, the theoretical
edge tip P is used as the reference point for the controller. In this case,
the theoretical edge tip P will always move on to the programmed contour.
However, this will lead to errors if the movements are not parallel to the axes.

P BB PB
PB R
S S
P B P B
S E dge orientation 3
S S

: resulting contour
: path of theoretical E dge peak 'P ' (program m ed contour)
: p a th o f E dg e ce n te r 'S '
511Unohn.FH7

P: theoretical edge tip


S: edge center
B: actual touch point
Fig. 5-32: Inaccuracies that occur if machining is performed without using tool
edge radius path compensation

The shaded area in the drawing will not be removed since the controller is
using the theoretical edge tip P as its point of reference.
When tool edge radius / cutter radius compensation is active, the CNC au-
tomatically moves the actual contact point B along the programmed con-
tour. Thus, the resulting contour is identical to the programmed contour.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-69

Active Tool Path Compensation


If edge radius/cutter radius path compensation is active (G41/G42), the
CNC automatically calculates the length corrections which are active in
the working plane with respect to the center point of edge S by add-
ing/subtracting the correct radius to/from the theoretical edge tip, based
on the current position of the cutting edge.

P B PB
PB R
S S
P B P B
S

S S

: resulting contour (programmed contour)


: path of theoretical Edge peak 'P'
: path of Edge center 'S'

512Smit.FH7

P: theoretical edge tip


S: edge center
B: actual touch point
Fig. 5-33: Inaccuracy-free machining with active tool edge radius path com-
pensation

With tool path compensation active, the center point of the tool travels
along a path which is parallel to the programmed contour and is offset by
the tool radius.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-70 Tool Compensation MTC 200 NC programming instruction

Contour Transitions
Inside corners With inside corners, the corrected NC block transition point is based on
the point at which the lines parallel to the contours intersect.

R R

S ' S S'
S

R
R
R
S
S '

S' S

513Innen.FH7

R: theoretical edge tip


S: edge center
S ": actual touch point
Fig. 5-34: Inside corners

Outside corners The tool center point must travel around outside corners so that they are
not damaged.
Two methods can be used to accomplish this:
1. Insertion of an arc as the transition element by using NC command
G43, and
2. Insertion of a chamfer as the transition element by using NC com-
mand G44. The insertion of a chamfer is possible only if a straight-
line ↔ straight-line transition exists.
A chamfer is used as the transition element when the transition angle
between the two straight lines is greater than 90°. If the transition angle
is less than 90°, the NC block transition point is recalculated based on
the intersection point of the lines parallel to the contour.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-71

S2'
R S2 '
S
S1' R
S1 '

S2 '
R

R S S1 '
S2 '
514Außen.fh7

S1 '

514Aussen.FH7

R: tool radius
S: programmed NC block transition point
S1 ": corrected NC block transition point 1
S2 ": corrected NC block transition point 2
Fig. 5-35: Arc transition element with G43

Transition angle > 90° (Chamfer)

R
R S2 '
S
S1 '

ß
515Fase.fh7

Transition angle <= 90°

(corrected NC-block transition point) R = tool radius


ß = transition angle
S'
S = programmed NC-block transition
S‘ = corrected NC-block transition point
for ß<90°
S S1 ‘ = corrected NC-block transition point 1
R for ß>90°
S2 ‘ = corrected NC-block transition point 2
for ß>90°

515Fase.FH7

Fig. 5-36: Chamfer transition element and corrected block transition point

When arcs or chamfers are inserted as contour transitions, the CNC auto-
matically generates an additional transition NC block. This NC block is
considered to be an independent NC block, and as such, it must be star-
ted separately in single-block processing mode.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-72 Tool Compensation MTC 200 NC programming instruction

Note: With look-ahead calculation of the corrected tool center point


path, only the transition angle relative to the contour element of
the following motion NC block is used in the calculation and not
the length of the contour element.
The cases indicated in Fig. 5-37: are not recognized.

S'

S'

S' S'

S'

S'

S'
516Rand.fh7

516RAND.FH7

Fig. 5-37:: Boundary conditions for contour elements

Arcs can, of course, replace the contour elements which are represented
as straight lines. Any overlaps with elements other than the next contour
element are ignored.
The case shown here as a concave arc (see following fig.) is recognized
and program execution is terminated with an error message.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-73

S'

517Konk.fh7
517KONK.FH7

Fig. 5-38: Concave arc, 1 element

The cases shown below are concave arcs with contour violation.

S'
518KonkM.fh7

518KONKM.FH7

Fig. 5-39: Concave arc, several contour elements

Due to the fact that a maximum of four NC blocks are generally prepared,
one of the next three NC blocks must be a movement NC block, which
includes at least a change of one axis coordinate of an axis belonging to
the selected working plane. If this is not the case, the contour movement
is completed, and the next contour transition will not be calculated. Look-
ahead NC block processing will be interrupted with calculations in the NC
program, which leads to the completion of a contour movement. Thus, a
coherent contour move cannot be programmed according to NC vari-
ables.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-74 Tool Compensation MTC 200 NC programming instruction

Establishment of Tool Path Compensation at Start of Contour


The starting point of the contour [P1] which is to be corrected with tool
path compensation is located above the starting point [P0] of the pro-
grammed contour, perpendicular to the subsequent direction of motion.

[P1]
R

[P0]

[P0]
519WKorr.fh7

R
[P1] R

[P0] [P1]

519WKORR.FH7

R: tool radius
[P0]: programmed starting point of the contour
[P1]: corrected starting point of the contour
Fig. 5-40: Starting point for tool path compensation

The establishment of tool path compensation requires an additional


movement in the working plane, which is performed only in conjunction
with a programmed linear movement.

Traversed
Linear Movement

[Ps]
[P1]
520WKauf.fh7

R
Programmed
Linear Movement [P0]

520WKAUF.FH7

R: tool radius
[Ps]: starting point of tool path compensation
[P0]: programmed starting point of the contour
[P1]: corrected starting point of the contour
Fig. 5-41: Establishment of tool path compensation

If an attempt is made to perform tool path compensation by means of a


circular movement, an error message will be issued:
"G41/G42 activated with circular interpolation"
and the NC program will terminate.
To avoid violations of the contour starting point, the starting point of tool
path compensation must be selected in such a way that the tool is located
completely within the quadrant which is opposite the contour corner.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-75

[P1]
R
[Ps]
[P0]

521Wanf.fh7
521WANF.FH7

R: tool radius
[Ps]: starting point of tool path compensation
[P0]: programmed starting point of the contour
[P1]: corrected starting point of the contour
Fig. 5-42: Contour start for tool path compensation

If the starting point of tool path compensation is moved to an inside corner


with closed contours, a contour violation would result at the end of the
contour (see the figure below).

[P2] [P3]

Contour Violation

[Ps1]

R
522Wges.fh7

[P6]

[P1], [P7]

[P5] [P4]

522WGES.FH7

R: tool radius
[P0]: programmed starting point of the contour
[P1]: corrected starting point of the contour
Fig. 5-43: Tool path compensation with closed contours

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-76 Tool Compensation MTC 200 NC programming instruction

Removal of Tool Path Compensation at End of Contour


The end point of the contour [Pe1] which was corrected with tool path
compensation is located above the end point [Pe0] of the programmed
contour, perpendicular to the prior direction of motion.

[Pe1]

R
[Pe0]

[Pe0]

523WEnd.fh7
R
[Pe1]
[Pe0]

[Pe1]
R

523WEND.FH7

R: tool radius
[Pe0]: programmed end point of the contour
[Pe1]: corrected end point of the contour
Fig. 5-44: End point for tool path compensation

The removal of tool path compensation requires an additional move in the


working plane, which is performed only in conjunction with a programmed
linear movement (see following fig.).

Traversed
Linear Movement

[Pee]
[Pe1]

R
programmed
[Pe0]
524WAuf.fh7

Linear Movement

524WAUF.FH7

R: tool radius
[Pee]: end point of tool path compensation
[Pe0]: programmed end point of the contour
[Pe1]: corrected end point of the contour
Fig. 5-45: Removal of tool path compensation

Removing tool path compensation on an arc will not cause an error to be


issued, but it will cause unpredictable contour errors. To avoid violations
of the contour end point, the end point of tool path compensation must be
selected in such a way that the tool is located completely within the quad-
rant which is opposite the contour corner.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-77

[Pee]

[Pe1]

R
[Pe0]

525KEnde.fh7
525KENDE.FH7

R: tool radius
[Pee]: end point of tool path compensation
[Pe0]: programmed end point of the contour
[Pe1]: corrected end point of the contour
Fig. 5-46: Contour end for tool path compensation

If the end point of tool path compensation is moved to an inside corner


with closed contours, a contour violation would result at the starting point
of the contour (see following fig.).

[P2] [P3]

Contour Violation

[Pe7]

R
[P6]

[P1], [P7]
526Kgesch.fh7

[P5] [P4]

526KGESCH.FH7

R: tool radius
[P7]: programmed end point of the contour
[Pe7]: corrected end point of the contour
Fig. 5-47: Tool path compensation with closed contours

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-78 Tool Compensation MTC 200 NC programming instruction

Change in Direction of Compensation


A change in direction of compensation functions behaves as if tool path
compensations were removed and then re-established.

[Ps0]
Traversed
Linear Movement R

[Ps1]
[Pe0]

R
Programmed
527Wechs.fh7
[Pe1] Linear Movement

527WECHS.FH7

R: tool radius
[Pe0]: programmed end point of the first contour
[Pe1]: corrected end point of the first contour
[Ps0]: programmed starting point of the second contour
[Ps1]: corrected starting point of the second contour
Fig. 5-48: Change in direction of compensation

The change of tool path compensation requires an additional movement


in the working plane, which is performed only in conjunction with a pro-
grammed linear movement.

Note: If an attempt is made to perform tool path compensation by


means of a circular movement, an error message will be issued:
"G41/G42 activated with circular interpolation"
and the NC program will terminate.

The conditions described in sections "Establishment of Tool Path


Compensation at Start of Contour", page 5-74 and "Removal of Tool Path
Compensation at End of Contour", page 5-76 regarding the possibility of
violating the starting point and end point of the contour also apply here.

5.7 Activating and Canceling Tool Path Compensation

Canceling Tool Path Compensation "G40"


Function G40 is used to cancel tool path compensation that is already
active. When tool path compensation is cancelled, the center point of the
tool travels along the programmed path.
If active tool path compensation (G41 or G42) is canceled by G40, the
next anticipated movement is a linear movement along the process plane.
The axis values of both main axes must be programmed in the NC block
so that tool path compensation can be cancelled.

Syntax G40
• G40 is the power-on state; it has a modal effect. G40 is cancelled by
G41 or G42.
• G40 is automatically set after the controller has been powered on, as
well as after an NC program is loaded and after a BST, RET or control
reset.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-79

Tool Path Compensation, Left "G41"


Tool path compensation to the left of the workpiece contour is activated
by the G41 function command.
If tool path compensation to the left of the contour is active, the tool center
point moves along the left side of the programmed contour when viewed
in the direction of movement. It moves along a path opposite of and par-
allel to the contour with an offset equaling the tool radius.
If G41 is programmed after an active G40 or G42, the next anticipated
movement is a linear movement in the process plane. The axis values of
both main axes must be programmed in the NC block in order for tool
path compensation to be re-established or changed.

Syntax G41
• G41 remains modally active until it is canceled by G40 or G42 or until
a reset is automatically performed at the end of the program (RET) or
BST.
• When tool path compensation is active, no more than two NC blocks
can be programmed without programming a movement in the current
process plane. If more than two NC blocks are programmed without a
movement, tool path compensation is canceled with G40.

Note: If an attempt is made to perform tool path compensation by


means of a circular movement, an error message will be issued:
"G41/G42 activated with circular interpolation"
and the NC program will terminate.

Tool Path Compensation, Right "G42"


Tool path compensation to the right of the workpiece contour is activated
by the G42 function command.
If tool path compensation to the right of the contour is active, the tool
center point moves along the right side of the programmed contour when
viewed in the direction of movement. It moves along a path opposite of
and parallel to the contour with an offset equaling the tool radius.
If G42 is programmed after active tool path compensation (G40 or G41),
the next anticipated movement is a linear movement on the process
plane. The axis values of both main axes must be programmed in the NC
block so that tool path compensation can be activated or changed.

Syntax G42
• G42 remains modally active until it is canceled by G40 or G41 or until a
reset is automatically performed at the end of the program (RET) or BST.
• When tool path compensation is active, no more than two NC blocks
can be programmed without programming a movement in the current
process plane. If more than two NC blocks are programmed without a
movement, tool path compensation is canceled with G40.

Note: If an attempt is made to perform tool path compensation by


means of a circular movement, an error message will be issued:
"G41/G42 activated with circular interpolation"
and the NC program will terminate.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-80 Tool Compensation MTC 200 NC programming instruction

Tool Path Correction G41, G42 Behind and Before the Turning Center

Edge O rientation

Edge O rientation

Edge O rientation
Edge O rientation
G 41

G 41
G 42

G 42

G3
G3
G2

G2
G2
G2
G3

G3
before the turning center
behind the turning center
X

X
Y

Y
Z

Z
Edge O rientation

Edge O rientation
Z

Edge O rientation
Edge O rientation

G 42
G 42

G 41

G 41

G2
G2

G3
G3

G3
G3
G2

G2
X

528G4142.FH7

Fig. 5-49: Tool path correction G41, G42 with machining behind and before the
turning center

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-81

Example: NC program tool path correction using G42

Y
P6
100
P2 P1
80
P8
P11
60
P7 P12 P5
40 P10
P9
P3
20

528G42.fh7
P4

20 40 60 80 100 120 140 160 180


X
528G42.FH7

Fig. 5-50: Tool path compensation, right (G42)

NC program using G42:


(TOOL CHANGE: ID=SF D5)
T4 BSR .M6
G00 G54 G06 G08 X115 Y99.5 Z5 Movement commands, interpolation
conditions
st
G01 Z2 F1000 S2000 M0 1 start position
Z-10 F1200 Lower cutter into material
G42 X117.5 Y99.5 F1500 [P1] Establish tool path compensation
G02 X98 Y80 I98 J99.5 Move to contour with a ¼ circle
st
G01 X45 Y80 [P2] Machine 1 section
st
G03 X40 Y75 I45 J75 Machine 1 ¼ circle
nd
G01 X40 Y25 [P3] Machine 2 section
nd
G03 X45 Y20 I45 J25 Machine 2 ¼ circle
rd
G01 X135 Y20 [P4] Machine 3 section
rd
G03 X140 Y25 I135 J25 Machine 3 ¼ circle
th
G01 X140 Y75 [P5] Machine 4 section
th
G03 X135 Y80 I135 J75 Machine 4 ¼ circle
th
G01 X90 Y80 Machine 5 section
G02 X73.5 Y96.5 I90 J96.5 Withdraw from contour with a ¼ circle
G01 X73.5 Y99.5 [P6] End position of outer contour
G00 Z2 Z axis to safety distance
G40 X68 Y49.5 [P7] Starting position of inside contour
G01 Z-10 F1000 Lower cutter into material
G42 X65.5 Y49.5 F1500 Establishment of tool path compensation
X65.5 Y50.5 Linear motion
G02 X90 Y75 I90 J50,5 Move to contour with a ¼ circle
st
G01 X130 Y75 [P8] Machine 1 section
st
G02 X135 Y70 I130 J70 Machine 1 ¼ circle
nd
G01 X135 Y30 [P9] Machine 2 section
nd
G02 X130 Y25 I130 J30 Machine 2 ¼ circle
rd
G01 X50 Y25 [P10] Machine 3 section
rd
G02 X45 Y30 I50 J30 Machine 3 ¼ circle
th
G01 X45 Y70 [P11] Machine 4 section
th
G02 X50 Y75 I50 J70 Machine 4 ¼ circle
th
G01 X98 Y75 Machine 5 section
G02 X119.5 Y53.5 I98 J53.5 Withdraw from contour with a ¼ circle
G01 X119.5 Y49.5 [P12] End position inside contour
G00 Z2 Z axis to safety distance
(TOOL CHANGE: Store last tool)
T0 BSR .M6
RET Program end

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-82 Tool Compensation MTC 200 NC programming instruction

Inserting an Arc Transition Element "G43"


With tool path compensation (G41 or G42) active, G43 inserts an arc as a
transition element for outside corners.
The tool center point must travel around outside corners so that they are
not damaged. An arc should always be inserted for circle ↔ straight line
or circle ↔ circle contour transitions.

Syntax G43
• G43 is the power-on state. It is modally active until it is overwritten by G44.
• G43 can be activated only via G41 or G42. G43 has no effect if tool
path compensation (G40) is canceled. G43 is reset automatically at
the end of the program (RET) or by the BST command.
• If an arc is inserted via G43 as a contour transition, the CNC auto-
matically generates an additional transition NC block. This NC block is
considered to be an independent NC block, and must be started
separately in "Single block" processing mode.
• The conditions for the insertion of transition elements are described in
the section "Contour transitions".

R S2 ' S2 '
S R
S1 '
S1 '
529Über.fh7

529UEBER.FH7

R: tool radius
S: programmed NC block transition point
S1 ': corrected NC block transition point 1
S2 ': corrected NC block transition point 2
Fig. 5-51: Inserting an arc transition element

Inserting a Chamfer Transition Element "G44"


With tool path compensation (G41 or G42) active, G44 can be used to
insert a chamfer as a transition element for outside corners with a transi-
tion angle exceeding 90°.
In the case of outside corners with a transition angle equal to or greater
than 90°, the corrected transition point is defined as the intersection of the
lines parallel to the contour.

Syntax G44
• A chamfer as a transition element can be used only for transitions
between two straight lines. With all other transition pairs, an arc is
automatically used as a transition element, even if G44 is active.
• After it is selected, a G44 remains modally active until it is cancelled by
G43 or until it is automatically reset at the end of the program or by
BST. G44 can be activated only via G41 or G42. G44 has no effect if
tool path compensation (G40) is canceled.
• If a chamfer is inserted via G44 as a contour transition, the CNC auto-
matically generates an additional transition NC block. This NC block is
considered to be an independent NC block, and must be started
separately in "Single block" processing mode.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-83

• The conditions for the insertion of transition elements are described in


the section "Contour transitions".

Transition angle > 90°

R
R S2 '
S
S1 '

R = tool radius
S = programmed NC block point
S1 ' = corrected block transition point 1
S2 ' = corrected block transition point 2

Transition angle <= 90°

S'

S R
530FEin.fh7

R = tool radius
S = programmed NC block point
S' = corrected block transition point

530FEIN.FH7

Fig. 5-52: Inserting a chamfer transition element

Constant Feed on Tool Center Line "G98"


With tool path compensation (G41 or G42) active, no path feed rate cor-
rection is performed for arcs when G98 is programmed. Thus, the pro-
grammed path feed rate applies to the tool centerline and not the work-
piece contour.
In the case of convex arcs (outside circle), a reduction of the path feed
rate at the contour results; with concave arcs (inside circle), it results in an
increase.

Syntax G98
• G98 is the power-on state. It is modally active until it is overwritten by
G99. G98 can be activated only via G41 or G42. G98 has no effect if
tool path compensation (G40) is canceled. G98 is reset automatically
at the end of the program (RET) or by the BST command.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-84 Tool Compensation MTC 200 NC programming instruction

Constant Feed at the Contour "G99"


With tool path compensation (G41 or G42) active, a path feed rate cor-
rection is performed for arcs when G99 is programmed. If G99 is active,
the path feed rate at the contour corresponds to the programmed value.
In the case of convex arcs (outside circle), an increase of the path feed
rate along the tool centerline path results; with concave arcs (inside circle)
it results in a decrease.

Syntax G99
• After it is selected, G99 remains modally active until it is canceled by
G98 or until it is automatically reset at the end of the program (RET) or
by BST. G99 can be activated only via G41 or G42. G99 has no effect
if tool path compensation (G40) is canceled.

5.8 Tool Length Compensation


If movements are being performed in the direction of the tool axis and at
the same time tool length compensation is inactive, all declared positions
relate to the position of the nose of the spindle.

Z+
Programmed
Z-value
531inaktiv.fh7

531INAKTIV.FH7

Fig. 5-53: Inactive tool length compensation

If a movement is performed in the direction of the tool axis at the same


time that tool length compensation is active, the actual tool lengths en-
tered in the magazine list are automatically used for calculations by the
controller, so that all declared positions now apply to the position of the
tool tip.
In order to establish or remove tool length compensation, it is necessary
to perform a programmed movement in the direction of the tool axis so
that the spindle nose stops at the programmed position when the end
point is approached.
The direction of the tool axis is assumed to be the direction of the main
axis, which is perpendicular to the process (machining) plane. The posi-
tion of the tool axis must be changed if the process plane is changed
(G17, G18, G19).
The tool length compensation cancellation (G47) and the positive activa-
tion (G48) or the negative activation (49) of the tool length compensation
must be programmed in the tool change program.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-85

Tool Length

Z+

Programmed
532aktiv.fh7 Z-value

32AKTIV.FH7

Fig. 5-54: Active tool length compensation

No Tool Length Compensation "G47"


The function G47 is used to cancel tool length compensation that is al-
ready active. When movements are being performed in the direction of
the tool, all position data relate to the position of spindle nose.
If active tool length compensation (G48 or G49) is canceled with G47, a
programmed movement in the direction of the existing main axis is ex-
pected. Movements which do not involve the removal of material from the
workpiece, such as a tool change, are generally performed without tool
length correction.

Syntax G47
• Depending on the settings in the process parameters, G47 may be the
power-on default. G47 remains modally active until it is canceled by
G48 or G49.
• G47 is set automatically depending on the setting in the process pa-
rameter after the controller is turned on, after an NC program is
loaded, after a BST, RET or control reset.

Tool Length Correction, Positive "G48"


After tool length correction has been activated by G48, the CNC compen-
sates the tool lengths entered in the magazine list in the positive axis
direction beginning with the next programmed move in the direction of the
existing main axes.

Syntax G48
• Depending on the settings in the process parameters, G48 may be the
power-on default. G48 remains modally active until it is canceled by
G47 or G49.
• G48 is set automatically depending on the setting in the process pa-
rameter after the controller is turned on, after an NC program is
loaded, or after a BST, RET or control reset.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-86 Tool Compensation MTC 200 NC programming instruction

Tool Length Correction, Negative "G49"


After tool length correction has been activated by G49, the CNC compen-
sates the tool lengths entered in the magazine list in the negative axis
direction beginning with the next programmed move in the direction of the
existing main axes.

Syntax G49
• G49 remains modally active until it is canceled by G47 or G49, or until
it is automatically reset at program end (RET), by BST or by control
reset.
• G49 only acts on L3. When applied to L1 and L2, G49 acts as G48,
and thus accounts for the tool length positively.

5.9 Access to Tool Data from NC Program "TLD"


The TLD command (Tool Data) can be used to read all the tool data in
the tool list from the NC program and to write them; however, some re-
strictions apply to writing.

Syntax The individual data elements are addressed by means of codes. Depen-
ding on both types of addressing ...
• addressing via location and magazine (A=0)
• addressing via tool number and tool duplo number (A=1) ...
both variants of TLD command are possible:

P A S/T L/D E D S
TLD([0..6], [0], [0..3] ,[1...999],[0..9],[1..35],[1..32])
TLD([0..6],[1],[1..9999999],[1...999],[0..9],[1..35],[1..32])
Status
Data element
Edge
Location / Index no.

Storage [0..3] /tool number


Addressing
Process
57tld.FH7

Fig. 5-55: Syntax of the TLD command

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-87

Value range and meaning of parameters

V23_20030319
TLD addressing via location and magazine type
Designation Symbol Value range / meaning
Process P 0-6 Process number

Addressing A 0 Addressing via location and magazine type


0 1 2 3 7
Magazine / Spindle Gripper Tool change Address active tool
Storage type ST turret position
Location L 1 - 999 1-4 1-4 1-4 0

Tool edge E 0 1-9


Basic tool data Tool edge data
9 32
Data element DE 3-8 10 - 31 Group 1 2 3 - 40
Tool status
status
1 - 32 1 - 16 1 - 16
Status S --- --- Group --- ---
Tool status Tool edge status
bits status bits bits

Group No. G Not relevant Not relevant

Group duplo
GD Not relevant Not relevant
number

V23_20030319
TLD addressing via tool and duplo number
Designation Symbol Value range / meaning
Process P 0-6 Process number

Addressing A 1 Addressing via tool and tool duplo number

Tool number T 1 - 9999999 Tool number


(T)
Tool duplo No. TD 1 - 9999 Tool duplo number

Tool edge E 0 1-9


Basic tool data Tool edge data
Data element DE 3-8 9 10 - 31 32 1 2 3 - 40
Tool status Group
status
1 - 32 1 - 16 1 - 16
Status S --- --- Group --- ---
Tool status Tool edge status
bits status bits bits

0 - 99 Group association of the tool


Group No. G no information: active group

0 - 99 Group duplo association of the tool


Group duplo
GD no information: duplo No. of the active group
number
TLD_V23_20030319.xls

Fig. 5-56: Parameters of the TLD command

A detailed description of the TLD command is contained in section "NC


Special Functions".

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-88 Tool Compensation MTC 200 NC programming instruction

5.10 D corrections
D corrections are additional to the tool geometry data active registers. D
corrections act additionally to the existing geometry registers L1, L2, L3
and R. 99 D corrections are available for each of the 7 processes. Each D
correction contains the L1, L2, L3 and R registers. The values of the D
correction registers can be assigned using the CNC operator interface.

Syntax D0 ⇒ Cancel D corrections


D<D correction number[1-99]> ⇒ Select a D correction

D corrections act like the geometry data in the tool management system.
D corrections can be used when tool management is present, for example
as tool reference point offset registers. If tool management is not defined
with a CNC process, the D corrections themselves can be used in place
of tool management for simple applications. The D correction functions
like correction type 4 in tool management. An edge orientation cannot be
defined in the D corrections.

Programming If the D corrections are selected in a movement block, they will be used in
the same NC block for the calculation of the new position.

Example:

G00 X100 Y150 Z10 D20 D correction is already effective in this NC


block!

How D corrections work

G17 G18 G19


Y Y Y
R

L2 L3 L1
R
L3 L1 R L2
L1 X L2 X L3 X

R
533dkorr.fh7

Z Z Z

533Dkorr.FH7

Fig. 5-57: How D corrections work in the corresponding machining plane

Geometry registers L1, L2 and L3 are not used for compensation unless
tool length correction G48/G49 is active. Geometry register R is used for
compensation only when tool path compensation G41/G42 is active.
If tool management is active for a selected machining tool and a D cor-
rection is also active, then the tool lengths and the radius are calculated
as follows:

Length corrrection L1 = length L1 + wear L1 + Offset L1 + L1 of D correction


Length correction L2 = length L2 + wear L2 + Offset L2 + L2 of D correction
Length correction L3 = length L3 + wear L3 + Offset L3 + L3 of D correction
Radius correction R = radius R + wear R + Offset R + R of D correction

Fig. 5-58: Calculation of length and radius

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Tool Compensation 5-89

Using D corrections

Correction values :
Werkzeuggeometriewerte
Tool geometry values
Correction type 1
Edge orientation 0
Length L3 241
Wear L3 0
Offset L3 0

Length L1 70.4
Length L2 0
L1 of
D-Correction 10 Length L3 34.6
Radius 0
70.4 mm
534Dwerk.fh7

34.6 mm 241 mm

L3 of Length correctionL3
D-Correction10

534DWERK.FH7

Fig. 5-59: Definition of tool reference point using D corrections

• Geometry registers L1, L2, L3 and R of the selected D correction are


not active unless tool length correction (G48/G49) or tool radius cor-
rection (G41/G42) is active.
• D0 is active in the power-on state; thus, the D corrections do not
compensate.
• A programmed D correction is modally active. The programmed D
correction is cancelled if D0 is programmed. D0 is automatically active
after an NC program is loaded and after a BST, RET, M02, M30, or
control reset.
• If tool length correction or tool radius correction is deactivated when a
D correction is active, the geometries of the corresponding D correc-
tion once again become active if the tool length/radius correction is
reactivated.
• Geometry registers L1, L2 and L3 act in the direction of the 3 main
axes (X, Y, Z) depending on which process plane is selected. Length
L3 is always perpendicular to the current machining plane, while
lengths L1 and L2 always lie within the current machining plane.

Note: The D corrections are not available in an NC process unless


the machine builder has specified that they are available in the
process parameters.

The maximum value which can be entered via the GUI for geometry reg-
isters L1, L2, L3 and R is entered in the process parameters.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
5-90 Tool Compensation MTC 200 NC programming instruction

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Auxiliary Functions (S, M, Q) 6-1

6 Auxiliary Functions (S, M, Q)

6.1 General Information on Auxiliary Functions


Auxiliary functions are transferred to the PLC and are then executed and
acknowledged by the PLC. For this to happen, the switch functions
needed in the PLC must be defined.
A maximum of 6 auxiliary functions can be programmed for each NC
block. Of these, a maximum of 4 M functions from different groups and
one S and one Q function each may be used.
The auxiliary functions are processed in the following order in the NC
block: S, M, Q.

Note: If an auxiliary function has been output to the PLC, block proc-
essing stops until the function is acknowledged. Thus, pro-
gramming an auxiliary function which is not defined in the PLC
program will block further program execution. Programming
auxiliary functions temporarily stops block processing. Func-
tions such as G08 (velocity-optimal NC block transition) will be
interrupted.

6.2 "M" Auxiliary Functions


The M functions are instructions which are primarily used to program ma-
chine or controller switching functions (for example, spindle on/off, cool-
ant on/off, gear change, etc.). An auxiliary function is programmed via
address letter M with a code of up to 3 digits. The codes for the auxiliary
functions are partially defined in DIN 66 025 Part 2 and in part by the ma-
chine builder.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
6-2 Auxiliary Functions (S, M, Q) MTC 200 NC programming instruction

Organization of M functions in
function groups
1 Program control commands M000, M001, M002, M030
2 Spindle control commands Spindle 1 M003, M004, M005, M013, M014
2 Spindle control commands Spindle 1 M103, M104, M105, M113, M114
3 Spindle control commands Spindle 2 M203, M204, M205, M213, M214
4 Spindle control commands Spindle 3 M303, M304, M305, M313, M314
5 Coolant and lubricant Spindle 1 M007, M008, M009
5 Coolant and lubricant Spindle 1 M107, M108, M109
6 Coolant and lubricant Spindle 2 M207, M208, M209
7 Coolant and lubricant Spindle 3 M307, M308, M309
8 Clamp and unclamp Spindle 1 M010, M011
8 Clamp and unclamp Spindle 1 M110, M111
9 Clamp and unclamp Spindle 2 M210, M211
10 Clamp and unclamp Spindle 3 M310, M311
11 Gear range selection Spindle 1 M040, …, M045
11 Gear range selection Spindle 1 M140, ..., M145
12 Gear range selection Spindle 2 M240, ..., M245
13 Gear range selection Spindle 3 M340, …, M345
14 Spindle override M046, M047
15 Feed override M048, M049
16 Blockwise active M functions as well as all M func- M019, M119, M219, M319
tions defined by the machine builder Mxxx
Fig. 6-1: Organization of M functions in function groups

All M functions with the exception of spindle control commands Mx03,


Mx04, Mx05, Mx13, Mx14, program control commands Mx00, Mx01,
Mx02, Mx30, and the blockwise active M function Mx19 can be used as
desired by the machine builder since they do not trigger any internal func-
tions in the controller.
• In a given NC block, only one M function can be programmed from
each function group.
• M functions M000 to M399 can be programmed with the CNC.
• No more than four M functions can be programmed in a single NC
block.
The M functions overwrite one another.

Note: If more than one gear range is activated in the axis parameters,
the M functions will no longer be available for general use.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Auxiliary Functions (S, M, Q) 6-3

Program Control Commands


Programmed stop M000 allows a defined NC program stop to be performed – for example,
(unconditional) to inspect a tool. After completing the check, the program can be contin-
M000 ued by pressing the start key. In all program-controlled modes, M000, like
the HLT command, produces a program stop in the NC. However, in con-
trast to HLT, the NC sends the M000 auxiliary function to the PLC at the
end of motion.

Conditional stop M001 M001 acts like M000 when the interface signal "Conditional stop"
(PxxC.M01) is set by means of a machine control key. The NC evaluates
the interface signal "Conditional stop" after acknowledging the auxiliary
function.

End of NC program M002 / M030 M002/M030 act like the RET command. In addition, the NC sends the
currently programmed auxiliary function to the PLC. Both auxiliary func-
tions communicate the end of program to the PLC by resetting the NC
program to the start of the program. The NC thus establishes the power-
on state. After M002 or M030 are performed, all subroutine levels and all
reverse vectors are cleared and the NC controller is in the initial state in
the main program level.

Spindle Control Commands


The spindle is turned on or off using the spindle control commands Mx03,
Mx04, Mx05, Mx13, Mx14. The first digit in the M functions is evaluated
as the spindle index number. If the spindle index is 0 (M003), the M func-
tion is applied to the first spindle; if the spindle index is 2 (M203), the M
function is applied to the second spindle.
• Spindle control commands Mx03, Mx04, Mx13 and Mx14 take effect
as soon as an axis move is programmed in the NC block. However,
they are not output to the PLC until the motion command is comple-
ted.

Mx03 Spindle clockwise Activate spindle rotation in clockwise direction.

Mx04 Spindle counterclockwise Activate spindle in counterclockwise direction.

Mx05 Spindle stop Shut off spindle and shut off supply of coolant/lubricant.

Mx13 Spindle clockwise and Turn on spindle rotation in the clockwise direction and turn on cool-
coolant/lubricant ON ant/lubricant supply if the required switching functions are defined in the
PLC program.

Mx14 spindle counterclockwise Turn on spindle rotation in the counterclockwise direction and turn on
and coolant/lubricant ON coolant/lubricant supply if the required switching functions are defined in
the PLC program.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
6-4 Auxiliary Functions (S, M, Q) MTC 200 NC programming instruction

Spindle Positioning
Function M19 S... allows the primary spindle to be stopped in a defined
position. The angular position is programmed in degrees at address S.
The primary spindle can be positioned while not turning as well as while
turning.
• The NC block is only processed completely after Mx19 has been ac-
knowledged by the PLC, when the spindle has reached the program-
med end position.
• If Mx19 is programmed without an S word, an error will be issued
when the program is executed.
• Function Mx19 is possible only with primary spindles that are able to
be positioned.

Syntax M19 S<constant> ⇒ M19 S180


M19 S=<expression> ⇒ M19 S=@070
M<spindle index>19 S<spindle index><constant>
⇒ M219 S2 90
M<spindle index>19 S<spindle index><expression>
⇒ M319 S3=@060

With the introduction of software release 18, it became possible to pro-


gram command MQ19. This command initiates asynchronous spindle
synchronization. The NC block that contains MQ19 is terminated as soon
as all the other software functions are executed, even if the spindle has
not yet reached the programmed end position.
Via the programming of MW19 (with the same spindle position as with
MQ19), the following NC block can be interrogated and waited for until the
spindle has reached its target position.
If there are several spindles in a process, only one positioning command
can be started in each NC block. A separate NC block with the corre-
sponding positioning command (e.g. MQ219) is required for the second
and each additional spindle.
The following restrictions apply to the MQ19 command:
• May only be used with SERCOS primary spindles with SHS firmware;
parameter S-0-0152 must exist.
• MQ19 cannot be executed as long as primary spindle synchronization
is active.
• The function cannot be used for combined spindle-turret axes.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Auxiliary Functions (S, M, Q) 6-5

Gear Changes
If the quantity of gear steps is larger than 1 in the axis parameters of the
CNC for one of the spindles, then M function groups 11-13 are reserved
for control internal function of the CNC.
M functions for gear changes and their corresponding function groups:
11 Gear range selection Spindle 1 Mx40, ..., Mx44
(x=0 or 1)
12 Gear range selection Spindle 2 M240, ..., M244
13 Gear range selection Spindle 3 M340, …, M344

Meaning of the M functions:


Mx40 Automatic gear selection for spindle X
st
Mx41 1 gear range for spindle X
nd
Mx42 2 gear range for spindle X
rd
Mx43 3 gear range for spindle X
th
Mx44 4 gear range for spindle X

• Automatic gear selection (Mx40) is dependent on the corresponding


axis parameter set by the machine builder.
• If a multiple-range gear is not present, the M functions can be used
for other purposes.

6.3 S-Word as Auxiliary Function


If a process was defined without a spindle in the process parameters, the
S word has the meaning of an auxiliary function. This means that an addi-
tional address letter is available, which the user can use for self-definable
auxiliary functions in the PLC program. The S function can be entered as
an unsigned integer constant having up to 4 digits. The numerical range
for this constant is 0 to 9999.

Syntax S<constant> ⇒ S1234

There may be an expression instead of the constant.


S=<expression> ⇒ S=@123+@124

6.4 Q Function
A self-defined auxiliary function in the PLC program with address letter Q
and a whole-number constant of up to 4 digits and without a posi-
tive/negative sign can be called by the user. The numerical range for this
constant is 0 to 9999.

Syntax Q<constant> ⇒ Q1234


For this to happen, the switching functions needed in the PLC must be
defined.

Note: Q functions Q9000 to Q9999 are reserved for Bosch Rexroth-


specific auxiliary functions (S, M, Q) functions.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
6-6 Auxiliary Functions (S, M, Q) MTC 200 NC programming instruction

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Events 7-1

7 Events

7.1 Definition of NC Events

Description NC events are binary variables which can be used by the NC program
and which, like flags in the PLC program, represent any desired state
defined by the programmer. NC events can be set and reset as desired in
the NC and PLC programs. Waiting for a defined state in an NC event
can synchronize processes.
Therefore, please refer to the machine builder's information regarding
events influenced by the PLC program since the builder may have used
various NC events for synchronization purposes.
The status of the NC event is retained after powering down. Before NC
events are used in an NC program, they should be placed in a defined
state.

Note: The process-local NC events 0 to 7 are reserved for interrupt-


controlled program branches; in general, they should be kept
open for such functions.

Various NC events are used by the Bosch Rexroth standard NC cycles.


The numbers of these NC events are stated in the corresponding de-
scription.
No more than four different NC event commands and only one NC event
branch command may be programmed in one NC block.
Events are specified in the form <event type>:<event number>.
3 types of NC event are available in the CNC.

Process events (0-6) 32 events are assigned to each process. By addressing with the process
number, all 224 NC events can be used in a process, regardless of whether
the process itself is defined. An NC event is identified by the process to
which it belongs (process number) and by the NC event number. Interrupt-
controlled program branches can be performed with the assistance of proc-
ess events. These topics are described in section 7.4 "Asynchronous han-
dling of events", page 7-5. If an event type is not indicated, the process de-
faults to the process in which the NC event is programmed.

External events (X) 32 external events are available; these are exchanged with the PLC in a 2ms
cycle. These events can be used to carry out fast I/O selection of the 2ms
implementation (see "PLC Programming Instructions", section 11.3) of the
PLC. In the PLC, these events are to be addressed using process number 7
with the event functions.

Peripheral events (P) For peripheral events, 32 outputs and 32 inputs are available; these are
exchanged with the PLC in a 2ms cycle. These events are mapped on a
physical input and output area of the PLC. Write event functions set
%IBP0 peripheral inputs of the PLC, while read event functions evaluate
the %QBP0 peripheral outputs of the PLC.
The write functions are:
SE P:<ev. no.>, RE P:<ev. no.>, EVENT(P,<ev. no.>)=...

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
7-2 Events MTC 200 NC programming instruction

The following table shows how the write events are assigned to the inputs
in the PLC:

Address Event number


%IBP0.531.0 - %IBP0.531.7 0, 1, 2, 3, 4, 5, 6, 7
%IBP0.530.0 - %IBP0.530.7 8, 9, 10, 11, 12, 13, 14, 15
%IBP0.529.0 - %IBP0.529.7 16, 17, 18, 19, 20, 21, 22, 23
%IBP0.528.0 - %IBP0.528.7 24, 25, 26, 27, 28, 29, 30, 31
Fig. 7-1: PLC input addresses of events to be set

The read functions are:


WES P:<ev. no.>, WER P:<ev. no.>
BES .LABEL P:<ev. no.>, BER .LABEL P:<ev. no.>

The following table shows which PLC outputs correspond to the read
events:

Address Event number


%QBP0.531.0 - %QBP0.531.7 0, 1, 2, 3, 4, 5, 6, 7
%QBP0.530.0 - %QBP0.530.7 8, 9, 10, 11, 12, 13, 14, 15
%QBP0.529.0 - %QBP0.529.7 16, 17, 18, 19, 20, 21, 22, 23
%QBP0.528.0 - %QBP0.528.7 24, 25, 26, 27, 28, 29, 30, 31
Fig. 7-2: PLC output addresses of events to be read

Event number • If the symbol "*" is declared instead of event number 0-31, all the NC
events in the given process / event type are addressed.

7.2 Influencing Events

Set NC Event "SE"


The event defined in the command parameter is set using command SE
"Set event". If the event has already been set, this command will be ig-
nored. The event remains set until it is reset by the RE "Reset event"
command.

Syntax SE <process number[0-6]>:<event number[0-31]> ⇒ SE 01:15:00


SE <event number[0-31]> ⇒ SE 9

• If the symbol "*" is declared instead of the NC event number, all the
NC events in the given process are addressed.

Example: SE 1:* - sets all events of process 1.

• The PLC program can also influence events.


Therefore, please refer to the machine builder's information since the
builder may have used various events for synchronization purposes.
• Event though it is theoretically possible to set events in other proc-
esses, it is advisable to only change the event status in the process to
which the event belongs and to only interrogate events from other pro-
cesses.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Events 7-3

Reset NC Event "RE"


The event defined in the command parameter is reset using command
RE "Reset event". If the event is already reset, this command will be ig-
nored. The event remains reset until it is set by the SE "Set event" com-
mand.

Syntax SE <process number[0-6]>:<event number[0-31]> ⇒ RE


01:15:00
RE <event number[0-31]> ⇒ RE 9

• If the symbol "*" is declared instead of the NC event number, all the
NC events in the given process are addressed.

Example: RE 1:* - resets all events of process 1.

• The PLC program can also influence events.


Therefore, please refer to the machine builder's information since the
builder may have used various events for synchronization purposes.
• Even though it is theoretically possible to reset events in other proc-
esses, it is advisable to only change the event status in the process to
which the event belongs and to only interrogate events from other pro-
cesses.

Wait until NC Event is Set "WES"


The WES "Wait until event is set" command is used in the process in
which WES is programmed to stop program processing until the event
defined in the command parameter is set. If the event is already set, the
block continues to process without interruption.

Syntax SE <process number[0-6]>:<event number[0-31]> ⇒ WES 1:15


WES <event number[0-31]> ⇒ WES 9

• If the symbol "*" is declared instead of the NC event number, proc-


essing waits until at least one NC event in the specified process is set.

Example: WES 1:* - waits until an event in the specified process is


set to 1.

• The PLC program can also influence events.


Therefore, please refer to the machine builder's information since the
builder may have used various events for synchronization purposes.
• Since a process which is waiting for an event cannot set the same
event, it is possible to wait only for an event whose status is changed
by a different process.
• The WES command should not be programmed within a program sec-
tion in which tool path compensation is active. If this proves to be un-
avoidable, be certain that it is programmed only between linear block
transitions.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
7-4 Events MTC 200 NC programming instruction

Wait until NC Event is Reset "WER"


The WER "Wait until event is reset" command is used in the process in
which WER is programmed to stop program processing until the event
defined in the command parameter is reset. If the NC event is already
reset, the block continues to process without interruption.

Syntax WER <process number[0-6]>:<event number[0-31]> ⇒ WER 1:15


WER <event number[0-31]> ⇒ WER 9

• If the symbol "*" is declared instead of the NC event number, proc-


essing waits until at least one NC event in the specified process is re-
set.

Example: WER 1:* - waits until an event in the specified process is


reset to 1.

• The PLC program can also influence events.


Therefore, please refer to the machine builder's information since the
builder may have used various events for synchronization purposes.
• Since a process which is waiting for an event cannot reset the same
event, it is possible to wait only for an event whose status is changed
by a different process.
• The WER command should not be programmed within a program
section in which tool path compensation is active. If this proves to be
unavoidable, be certain that it is programmed only between linear
block transitions.

Example: NC program - influencing NC events

At the beginning of both NC programs, all events for the given process
are reset. NC program process 2 stops the block process in line 3 until
NC program process 1 in line 6 has set event No. 1.

NC program process 1 NC program process 2


RE 1:* ;Reset all events in pro- RE 2:* ;Reset all events in pro-
cess 1 cess 2
T1 BSR .M6 ;Tool change T1 ;Tool change
M03 S150 ;Spindle ON WES 1:1 ;Wait for event 1 of pro-
cess 1
G04 F15 ;Dwell time M03 S150 ;Spindle ON
M05 ;Spindle OFF G04 F15 ;Dwell time
SE 1:1 ;Set event 1 in process 1 M05 ;Spindle OFF
RET ;End of program RET ;End of program

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Events 7-5

7.3 Conditional Branches for Events

Branch if NC Event is Set "BES"


The BES branch command "Branch if event is set" is used to continue
program processing at the declared branch label if the NC event defined
in the command parameter is set.

Syntax BES <branch label> <process number[0-6]>:<event number[0-31]>


⇒ BES .LABEL 1:15
BES <branch label> <NC event number[0..31]>
⇒ BES .LABEL 9

• If the symbol "*" is declared instead of the NC event number, proc-


essing branches to the addressed branch label if at least one NC
event in the specified process is set.

Example:

BES .WAIT 1:* - jumps to label WAIT when all events in process 1 are set.

• The PLC program can also influence events.


Therefore, please refer to the machine builder's information since the
builder may have used various events for synchronization purposes.

Branch if NC Event is Reset "BER"


The BER branch command "Branch if event is set" is used to continue
program processing at the declared branch label if the event defined in
the command parameter is reset.

Syntax BER <branch label> <process number[0-6]>:<event number[0-31]>


⇒ BER .LABEL 1:15
BER <branch label> <NC event number[0-31]>
⇒ BER .LABEL 9
• If the symbol "*" is declared instead of the NC event number, proc-
essing branches to the addressed branch label if all the NC events in
the specified process are reset.

Example:

BER .WAIT 1:* - jumps to label WAIT when all events in process 1 are
reset.

• The PLC program can also influence events.


Therefore, please refer to the machine builder's information since the
builder may have used various events for synchronization purposes.

Example:

NC program - conditional branches for events

At the beginning of both NC programs, all events for the given process
are reset. If event 15 is set in process 1 before process 2 has reached
line 3, then process 2 continues its processing at branch label .WAIT.
Otherwise, the process is continued in line 4.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
7-6 Events MTC 200 NC programming instruction

NC program process 1 NC program process 2


RE 1:* ;Reset all events in pro- RE 2:* ;Reset all events in
cess 1 process 2
T1 BSR .M6 ;Tool change T1 ;Tool change
SE 01:15:00 ;Set event 15 in process 1 BES .WAIT 1:15 ;Branch to label
WAIT if event 15 of
process 1 has
status 1.
M03 S150 ;Spindle ON M03 S150 ;Spindle ON
G04 F15 ;Dwell time G04 F15 ;Dwell time
M05 ;Spindle OFF M05 ;Spindle OFF
RET ;End of program RET ;End of program

7.4 Asynchronous Handling of NC Events


The CNC can use NC events to influence NC program execution at any
desired time. Since the status of events can be changed by the PLC and by
other processes, the NC program can be programmed to branch condition-
ally upon certain signal changes.
The control of NC program flow consists of being able to interrupt the
execution of the active NC block, including the current axis movements,
to request a subroutine and then to return to the interrupted NC block or
to make a complete branch and continue the NC program at a different
location.
Asynchronous handling of events permits, for example, position scanning
(limit switch), gauging cycles (probe) or joining operations (force sensor).
All other kinds of conditions used to trigger the interruption of a move or
simply to modify the NC program flow are conceivable.
With the CNC, the response time to an external event is typically 50 milli-
seconds.
NC events 0 to 7 of each process are for the interrupt-controlled program
branches. If a condition is met, the corresponding event assumes the
status 1. The priority of an event increases with its number. Event "1" has
a higher priority than event "0", and event "7" has the highest priority. This
permits a response to an external event while the handling of a previously
detected low-priority event is not yet completed.
The first action taken to handle an external event is that all axis move-
ments in the process are brought to a stop as soon as possible. Spindles
are not stopped when an event is called. The position of the stop is then
calculated back into the program coordinate system so that it can be used
as the starting position for the following move. In addition, the previously
prepared motion blocks are cleared, and block processing begins again
starting at the point in the program which was defined as the start of event
handling. The branch label that was programmed with the event identifies
the start of an event.
• The monitoring of events and the appropriate response takes place
only when an advance program is running. All NC event supervision
activities are deactivated at the end of the program, when an axis is
jogged, or when the program is reset by means of a control reset.
• Event commands are processed to completion at the end of the NC
block. No more than one command for asynchronous handling of
events can be programmed in an NC block.
• The PLC program can also influence events.
Therefore, please refer to the machine builder's information since the
builder may have used various events for synchronization purposes.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Events 7-7

Example: NC program - asynchronous event monitoring

.LOOP1
JEV .LEAVE 0 ;If event 0 is set, jump to routine "Empty"
Q456 ;Message to PLC: Emptying can be initiated
CEV 0 ;Clear event monitoring
.........
.LEAVE ;Routine for emptying the machine

Since the auxiliary channel remains assigned until Q456 is acknowledged


by the PLC, the NC program continues from this point as long as no other
auxiliary function is executed.
If event 0 is set during the auxiliary function output (Q456), the NC pro-
gram branches to the specified point. The output of the auxiliary function
to the PLC remains pending, meaning that if the auxiliary function was
issued, it must also be acknowledged.

Call Subroutine if Event is Set "BEV"


The BEV command "Call subroutine if event is set (Branch on Event)" is
used to activate monitoring of the event specified in the command pa-
rameter. If the NC event assumes status "1", it branches to the subroutine
which is parameterized in the branch label of the BEV command. A
change of the status of low-parity NC events or the triggered NC event is
ignored until the end of the subroutine. However, the program may be
interrupted by higher-priority NC events.

Syntax BEV <branch label> <event number[0-7]> ⇒ BEV .LABEL 4

After the branch from the subroutine, block preparation is resumed at the
beginning of the interrupted NC block so that this block is now completely
processed to ensure that all the functions of the interrupted block are
performed. This can lead to unexpected results with incremental pro-
gramming and incremental variable programming (@01=@01+3).
• The portion of the NC program which is processed as a subroutine
must be terminated upon the branch back from the subroutine. Moni-
toring of the triggered event and lower-priority events is resumed
automatically.
• Repeating the assignment of a branch label to an event using the BEV
command overwrites the previous assignment as well as any different
branching behavior defined using the JEV command "Branch to sub-
routine if event is set".
• The PLC program can also influence events.
Therefore, please refer to the machine builder's information since the
builder may have used various events for synchronization purposes.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
7-8 Events MTC 200 NC programming instruction

Program Branching if NC Event is Set "JEV"


The JEV command "Program branching if event is set (Jump on Event)"
is used to activate monitoring of the NC event specified in the command
parameter. If the NC event assumes status "1", then processing branches
at this program point; this is parameterized via the jump label of the JEV
command. A change of status of lower priority NC events or of the trig-
gered NC events is ignored. However, the program may be interrupted by
higher-priority NC events.

Syntax JEV <branch label> <event number[0-7]> ⇒ JEV .LABEL 4

• After the interruption is triggered by the event, the program is contin-


ued at a defined location; it cannot be reset, as is the case with the
BEV command, by jumping back from a subroutine (RTS) into the in-
terrupted NC block.
• Repeating the assignment of a jump label to an event using the JEV
command overwrites the previous assignment as well as any different
branching behavior defined using the command BEV branch on an
event to an NC subroutine (interrupt).
• The PLC program can also influence events.
Therefore, please refer to the machine builder's information since the
builder may have used various events for synchronization purposes.

Cancel NC Event Monitoring "CEV"


The command CEV "Cancel NC event monitoring (interrupt)" can be used
to cancel NC event supervision when supervision is activated by means of
BEV or JEV. NC event monitoring is canceled for the NC event declared
in the command parameter.

Syntax CEV <event number[0-7]> ⇒ CEV 5

Disable NC Event Monitoring "DEV"


The command DEV "Disable NC event monitoring" can be used when NC
event monitoring has been activated by BEV or JEV to disable this NC
event monitoring for a certain portion of the NC program until NC event
monitoring is re-enabled via EEV "Enable NC event monitoring". NC event
monitoring is disabled for all events.

Syntax DEV

Enable NC Event Monitoring "EEV"


The EEV command "Enable NC event monitoring" is used to re-enable
NC event monitoring, which was disabled by means of DEV. NC event
monitoring is enabled for all events.

Syntax EEV

Example: NC program - asynchronous NC event handling


Two types appear in a prepared portion. In the first type, the holes shown
in Fig. 7-3: are present, and a thread must be tapped. The number of
holes can vary between 1 and 4; however, they are specified by their po-
sition. The given tapping position is selected via the ZO (G54 - G58). In
the second type, normal processing is performed; the holes are ignored.
An initiator located in the Z axis checks for the presence of holes. The
initiator is connected to the PLC as an input. If the 0 state is present at the
given input, the PLC sets NC event No. 6 in process 0.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Events 7-9

Y
100

80 NC block : G01 X97.5 F700


during active BEV .GEWB 0:6
60

40

71events.fh7
20

20 40 60 80 100 X
71EVENTS.FH7

Fig. 7-3:: Tapping depending on an event

NC program - tapping depending on an event


; Normal processing
CEV 6 Disable NC event monitoring
T1 BSR .M6 Tool change of first tool
G00 G90 G54 G06 G08 Movement commands, interpolation
conditions
X0 Y0 Z10 S3000 M03 Starting position for process

• Machining

T0 BSR .M6
@50=0 Variable to initialize ZO
nd
O1 Select the 2 zero offset table
M52 Swing out initiator
G00 G90 G59 G06 G08 Home position, ZO for initiator
X32.5 Y65 Start position
G01 Z2 F500 M54 Z axis to scan, activate initiator
BEV .GEWB 6 Activate NC event monitoring
G01 X97.5 F700 Check for holes
M55 M53 Deactivate initiator and swing in
st
O0 Select the 1 zero offset table
RET
.GEWB
DEV Deactivate NC event monitoring
M55 M53 Deactivate initiator and swing in
@51=X-OTD(,,,,1) @52=Y-OTD(,,,,2)
@53=Z-OTD(,,,,3) Note current position
T15 BSR .M6 Change tap
G90 G=54+@50 G06 G08 ZO establishes the tapping
nd
G01 X40 Y65 Z10 F2000 M03 S1000 [P2] 2 tapping position
G63 Z-7.5 F2 Tap to depth Z
G63 Z10 F2 S1200 M04 Withdraw tap
T0 BSR .M6 Range tool
@50=@50+1 ZO for next hole
M52 Swing out initiator
G00 G90 G59 G06 G08 Home position, ZO for initiator
X=@51+5 Y=@52 Z=@53 Reapproach position of interruption
X axis +5 mm as safety distance
M54 Activate initiator
EEV Activate NC event monitoring
RTS Return to point of interruption

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
7-10 Events MTC 200 NC programming instruction

7.5 Reading Events in Variable


NC command <Variable>=EVENT(<event type>,<event number>) can be
used to read an event or all events into a variable. The function supplies
1.0 for a set event and 0.0 for a deleted event. If all events are addressed
with *, the function supplies the binary value (see following table) over all
0 31
events (event0 * 2 + ... + event31 * 2 ) of the corresponding process or
event type. The result of the function must be stored in a variable and
must not be linked with operations.

Syntax @<Var>=EVENT([<proc.no.0-6>|@<var>],<ev.no.031>|*|expression)

• @10=EVENT(2,3) ;@10=1.0 if event 3 of


process 2 is set
;@10=0.0 if event 3 of
process 2 is cancelled
• @0:2=EVENT(,*) ;@0:2=3.0 if only event 0 and 1 of current proc-
ess are set
• @[@1]:[@2]=EVENT(@1,@2) ;@n:m = event n:m

@<variable>=EVENT(X,<event No.0-31>|*|expression)

• @2=EVENT(X,@1) ;@2=1.0 if external event


@1 is set and
;@2=0.0 if external event
@1 is cancelled

@<variable>=EVENT(P,<event No.0-31>|*|expression)

• @2=EVENT(P,*) ;@2=5.0 (event 0 and 2), if peripheral outputs


%QBP0.531.0 and
% QBP0.531.2 are set.

Writing event(s) NC command <EVENT(<event type>,<event number>)=expression can


be used to describe an event or all events. Only the rounded whole-num-
ber portion of the expression is taken into account. The function sets an
event if the expression is not equal to 0 and deletes an event if the ex-
pression is equal to 0. If all events are addressed with *, the function
writes the whole-number portion of the expression as a binary value (32-
0 31
bit) in the events (event0 * 2 + ... + event31 * 2 ) of the corresponding
process or event type.
In the case of addressing with *, the following table shows the binary
value for the corresponding event to be set. If several events are to be set
simultaneously, the binary values of the events are to be added. The bi-
nary value for setting all events can also be specified with -1.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Events 7-11

Event number Binary value Event number Binary value


0 1 16 65536
1 2 17 131072
2 4 18 262144
3 8 19 524288
4 16 20 1048576
5 32 21 2097152
6 64 22 4194304
7 128 23 8388608
8 256 24 16777216
9 512 25 33554432
10 1024 26 67108864
11 2048 27 134217728
12 4096 28 268435456
13 8192 29 536870912
14 16384 30 1073741824
15 32768 31 2147483648

Fig. 7-4: Binary values of events

Syntax EVENT([<proc.no.0-6>|@<var>],<ev.no.0-31>|*|express.)=express.

• EVENT(2,3)=@10 ;@10=1 Set event 3 of process 2


;@10=0 Cancel event 3 of process 2
• EVENT(,*)=5 ;Set events 0 and 2 of current process,
;delete all other events
;this corresponds to SE 0 and SE 2
• EVENT(@1,*)=-1 ;Set all events of process @1
;this corresponds to SE <Proc.>:*

@<variable>=EVENT(X,<event No.0-31>|*|expression)

• EVENT(X,@1)=@2 ;@2=1 set external event @1


;@2=0 set external event @1

@<variable>=EVENT(P,<event No.0-31>|*|expression)

• EVENT(P,*)=@2 ;@2=5 (event 0 and 2) sets peripheral


;outputs %IBP0.531.0 and % IBP0.531.2.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
7-12 Events MTC 200 NC programming instruction

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Functions to Control Tool Management 8-1

8 NC Functions to Control Tool Management

8.1 Conditions

Default Plane
A Cartesian coordinate system is a prerequisite to utilize the tool corrections
properly. At least one of the three primary axes must exist physically.
Depending on the application,
• one of the axes (e.g. drilling unit),
• two of the axes (e.g. lathe) or
• all three axes (e.g. milling machines) can exist physically.
Irrespectively of the actual number of axes, one of the three machining
planes
• XY (G17, G20),
• ZX (G18, G21) and
• YZ (G19, G22)
can be selected.
With the functions for free plane selection (G20, G21, G22), any axis
designation can be assigned to the axis meanings which define a machi-
ning plane.
Tool length compensation "L3" always works perpendicularly to the machi-
ning plane. Length compensations "L1" and "L2" and the tool edge radius /
cutter radius compensation always act within the machining plane.

G17/G20 G18/G21 G19/G22


Y Y Y

R
R R
L2 L3 L1
L3 X L1 X L2 X
L1 L2 L3

Z Z Z
Ebene.FH7

Fig. 8-1: Effect of tool corrections "L1", "L2", "L3" and "R" as a function of the
selected machining plane

The machining plane is selected via NC commands "G17", "G18", "G19",


"G20", "G21" or "G22" (see chapter "Motion commands, dimension in-
puts", section "Plane selection").

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
8-2 NC Functions to Control Tool Management MTC 200 NC programming instruction

Preparation of Tools and Tool Data


The preparation of tools and tool data makes a distinction between the
magazine and the turret in the sense that both a physical and a logical tool
transfer between the spindle and the magazine (in some cases also using
grippers) is necessary, and in the sense that, with most magazines, it is
necessary to preselect the tool so that the magazine can be rotated asyn-
chronously for NC program execution.
The definition whether the given tool storage unit is a magazine or a turret
is made in process parameter Bxx.015 "Type of tool storage".
The following table contains an overview of all commands for tool and tool
data preparation. A detailed description of the commands is to be found in
the following chapters.

NC tool commands (1) V23_20030122

Function Meaning Description


E Preselect tool edge Syntax: E<EDG>
Edge EDG: Tool edge number

SPT Preselect tool spindle Syntax: SPT<SPI>


Spindle for Tool SPI: Spindle number

T Preselect tool Syntax: T<TNP>


Tool TNP: Tool number or tool
location
TG Preselect tool group Syntax: TG<GRP>
Tool Group GRP: Number of tool group (or 0)

TGSM Define tool search mode Syntax: TGSM<MODE>


Tool Group Search Mode MODE: Search mode
Werkzeugbefehle_NC1_V23_20030122.xls

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Functions to Control Tool Management 8-3

Preparing Tools and Tool Data for a Magazine


Magazines can be subdivided into two different types:
• NC-controlled magazines
• PLC-controlled magazines
The difference between the two types is in the way the magazine is posi-
tioned. With NC-controlled magazines, the controller-internal tool mana-
gement provides for positioning. The movement of PLC-controlled maga-
zines is handled by the PLC.

CNC
magazine

NC TM tool preselection
NC program oll
ed T12
ntr
-co 10 9 8 7
. NC
T12 MTP PLC 11 6
. PL
C-
co
. ntr
oll 12 5
ed
. MMV
1 2 3 4
.
.
gripper
.
. MMV_Q
. : occupied
MRY : free spindle 1
.
.
.
. loading tool
.
TMS 1 12 11 10
. TMS 2 9
.
.
. 3 8
. 4 5 6 7
.
.
TMS_Q gripper
.
.
M30 : occupiedT12
: free spindle 1

cnc2.FH7

Fig. 8-2: Preselecting tools and preparing tool data for a magazine

When a magazine is employed, a distinction between a preselected tool


and an active tool in a spindle is always made.

Tool preselection Syntax


T<constant> <command> e.g. T12 MTP
T<expression> <command> e.g. T=@0:10 MMP
T=(90-37) MTP
The numeric value that is assigned to address letter "T" via a constant or an
expression specifies the tool number (1 - 9999999; 0 = tool cancellation) or
the tool location number (0 - 999). NC commands "MTP" (Move Tool Po-
sition) and "MMP" (Move Magazine Position) provide magazine positioning
(also see section "Tool storage unit motion commands of the NC").
The selected tool is moved to the specified changing position. Up to the
moment of the tool transfer, the data of this tool will not be taken into ac-
count.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
8-4 NC Functions to Control Tool Management MTC 200 NC programming instruction

The call "T0 MTP" causes an empty magazine location to be moved to


the changing position.
In the case of nonexistent magazine locations, the T command may acti-
vate an additional tool zero offset (see the "Bosch Rexroth MTC 200 tool
management" description, section 3-9).

Preparing a tool Tool changing commands "TCH" or "TMS" (see also the section "Tool
changing commands of the NC") are used for transferring the preselected
tool into the spindle and for providing the tool data. In this process, the
preselected tool becomes the active tool. In the default selection, tool
edge 1 becomes the active tool edge.

Preparing Tools and Tool Data for a Turret


Turrets can be subdivided into two different types:
• NC-controlled turrets
• PLC-controlled turrets
The difference between the two types is in the way the turret is positioned.
NC-controlled turrets are positioned by the controller-internal tool man-
agement. The movement of PLC-controlled turrets is handled by the PLC.

CNC
turret

NC TM loading tool
lled
NC program n tro
-co
. NC
T831 MTP PLC T238
reference
PL mark
. C-
co
ntr T91
. oll
ed
. MMV T125
1
2
3
T254
. 8 4
+
. T831 7 5
6
T121
.
MMV_Q
. T238

MRY
.
.
.

534DWERK.FH7

Fig. 8-3: Preparing tools for a turret

Preparing a tool Syntax:


T<constant> <command> e.g. T12 MTP
T<expression> <command> e.g. T=@0:10 MMP
T=(90-37) MTP
The numeric value that is assigned to address letter "T" via a constant or an
expression specifies the tool number (1 - 9999999; 0 = tool cancellation) or
the tool location number (0 - 999). NC commands "MTP" (Move Tool Posi-
tion) and "MMP" (Move Magazine Position) provide turret positioning (also
see section "Tool storage unit motion commands of the NC").
The selected tool is moved in the machining position and the tool data is
activated. Tool edge 1 automatically becomes the active tool edge.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Functions to Control Tool Management 8-5

The call "T0 MTP" does not bring about a turret movement; the tool data
are merely deselected.
In the case of nonexistent turret locations, the T command may activate
an additional tool zero offset (see the "Bosch Rexroth MTC 200 tool ma-
nagement" description, section 3-27).

Asynchronous turret movements The following parameter value selection is necessary for swiveling the
turret asynchronously to the NC program execution:
• A00.052 Tool management: YES
• Bxx.014 Tool management: YES
• Bxx.015 Type of tool storage: Turret
• Bxx.044 Asynchronous turret movement: YES
Furthermore, the default PLC function "REV_SYNC" (synchronous swiv-
eling of the turret; see "Bosch Rexroth MTC 200 PLC interface descrip-
tion") must not be active.
If the above-mentioned conditions are satisfied, NC command "MFP",
"MTP", "MMP", "MOP", "MHP" or "MRF" can be used for initiating the tur-
ret movements. While the turret is swiveling, the NC continues program
execution. Using the MRY command or activating the "REV_SYNC" stan-
dard PLC function permits the turret swivel movements and NC program
execution to be synchronized.
The activation of the tool compensation values depends on the setting of
parameter Bxx.057 "Activate tool correction for turret".
The following table illustrates the effect of the parameter settings. The
following NC program sequence is discussed:
• G1 - ; Axis movements with T1 E1 as the active tool
• T2 ; Preselection of the T2 tool
• MTP ; Move programmed tool into position
• E2 ; Activating tool edge E2
• MRY ; Wait until tool storage movement is terminated

Behavior
NC pro- synchronous asynchronous
gram se- Activation of tool com- Activation of tool com- Activation of tool com- Activation of tool com-
quence pensation at start pensation at end pensation at start pensation at end
Active Presel. Active Presel. Active Presel. Active Presel.
G1 - T1 E1 T1 T1 E1 T1 T1 E1 T1 T1 E1 T1
T2 T0 E0 T2 T0 E0 T2 T0 E0 T2 T0 E0 T2
MTP T2 E1 T2 T2 E1 T2 T2 E1 T2 T0 E0 T2
E2 T2 E2 T2 T2 E2 T2 T2 E2 T2 T0 E2 T2
MRY T2 E2 T2 T2 E2 T2 T2 E1 T2 T2 E1 T2
Revolver.xls (Tabelle 2)

Fig. 8-4: Effects of process parameter Bxx.057

Note: Due to the dual function (spindle and turret axis) of these
axes, asynchronous turret movements are not possible with
"Combined spindle/turret axes".

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
8-6 NC Functions to Control Tool Management MTC 200 NC programming instruction

Tool Edge Invocation


Syntax:
E<constant> e.g. E2
E<expression> e.g. E=@0:12
E=(70-67)
The active tool is selected via address letter "E" followed by a constant or
an expression.
Besides loading the tool data, each tool transfer towards the spindle cau-
ses "Tool edge 1" to become the active tool. Accordingly, a tool call for a
turret causes "Tool edge 1" to become the active tool (in addition to provi-
ding the tool data).
"Tool edge 1" is most frequently used for machining. Thus, a separate
tool edge selection is not necessary.
Internally, the tool edge invocation causes the related correction and tool
life data to be provided. Tool management accesses this data during the
subsequent machining process.

Selecting the Tool Spindle "SPT"


If there are several spindles in a process, certain functions (such as tool selec-
tion E) require an effect on a spindle that is different than the first one.
Syntax:
SPT <spindle number[1-4]>
The first spindle is always active in the power-on state. If the tool is to be
related to a spindle that is different than the first one, the tool spindle must
first be selected using "SPT <spindle number>".
• The tool spindle must be selected at least one NC block prior to a
function call.
• SPT <spindle number> has a modal effect until another spindle num-
st
ber overwrites it or until it is automatically set to the 1 spindle at the
end of the program (RET) or by BST.
• Tool life monitoring, wear factors, tool path correction and tool length
compensation are valid for the tool of the selected tool spindle.

Additional tool carrier Alternatively to the MTP command, command "SPT <spindle number>"
can also be used to select an additional tool carrier. After selection, the
st
tool with the 1 edge is active; the offset of the new machine zero point is
taken into account. This offset is also calculated when tool compensation
(G47) is inactive and is taken into account in the determination of the
spindle speed for the constant surface speed (G96).
A detailed description of the processing of additional tool carriers can be
found in the description "Bosch Rexroth MTC 200 tool management",
section 4-16.

Tool Group Management


As of firmware version 23VRS, tools required for machining one type of
workpiece can be combined in a tool group to support segmented tool
magazines.
Tool groups are identified by a group number and a group duplo number.
Groups of the same group number are linked according to ascending
duplo numbers.
NC command TG is used to preselect a tool group. The tool search mode
is defined with command TGSM. The tool that has been preselected in
association with tool group management is taken into account by tool
storage movement command MTP.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Functions to Control Tool Management 8-7

Note: A detailed description of the processing of tool group man-


agement can be found in the documentation "Bosch Rexroth
MTC 200 tool management", section 1.4.

Preselect Tool Group "TG"


TG Tool Group

Syntax TG<group number (constant)>


TG<group number (expression)>
@<variable number> = TG
The following examples illustrate the possible syntax variants:
• TG3 ;direct allocation
• TG 3 ;direct allocation, space symbol
• TG=3 ;direct allocation
• TG=@195 ;allocation by variable
• TG=3+@195 ;allocation by formula
• @195=TG ;read out active (i.e. currently effective) tool group

Value range Group number: 0 - Bxx.073 "Number of tool groups"

Meaning Use the NC command "TG <group>" to preselect a tool group as a machi-
ning group. The active group can be read with "@<var>=TG". In an unpa-
rameterized group, the CNC reports error 322 "Invalid function". Af-
ter activation or a control reset, the controller automatically preselects
group 0.

Examples N0333 TG3 T19 ;activation of tool group 3 as the current machining
group with simultaneous tool preselection
N1299 @101=TG ;read out the active tool group number

Define Tool Search Mode "TGSM"


TGSM Tool Group Search Mode

Syntax TGSM<mode (constant)>


TGSM<mode (expression)>
@<variable number> = TGSM
The following examples illustrate the possible syntax variants:
• TGSM1 ;direct allocation
• TGSM 1 ;direct allocation, space symbol
• TGSM=1 ;direct allocation
• TGSM=@196 ;allocation by variable
• TGSM=1+@196 ;allocation by formula
• @196=TGSM ;read out the currently effective tool search
;mode

Meaning The tool search mode, as well as the implicit group activation when the T
word is entered, can be influenced with NC command "TGSM=<mode>".
The mode can be reread with "@<var>=TGSM". After activation or a con-
trol reset, the controller automatically preselects tool search mode 0.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
8-8 NC Functions to Control Tool Management MTC 200 NC programming instruction

For <mode>, the following search orders are available:

Mode Search order Comment


0 Preselected group If the tool is not found in the preselected
group, the NC will indicate error 314 ”Tool
or tool location not found”.
1 Preselected group, First, the tool is sought in the preselected
group 0 group, then in group 0.
2 Preselected group, If the tool is not in the preselected group, it
groups 0-99 will be sought in ascending order in groups
0-99.
3 Groups 0-99 Irrespective of the enabled group, the tool is
sought in ascending order in groups 0-99.
Fig. 8-5: Tool search mode in tool groups

If the requested tool is found in another group than the preselec-


ted/enabled one, this group will be automatically enabled and preselected
once the tool has been enabled. If the tool search produces no hits, the
CNC reports error 314 "Tool or tool location not found".

Examples N0344 TGSM1 T19 ;Define tool search mode 1,


;preselect tool and implicitly
activate the tool group in which the
;tool was found
N1266 @2:98 = TGSM G01 X78 F1200 ;Read currently effective tool
;search mode and position axis in
;feed

Changing Tools
The process of changing tools is initiated by NC commands.
In most cases, changing tools also requires motions and activating / de-
activating G codes. Thus, the entire program sequence should be com-
bined in a subroutine or a cycle. This reduces the programming effort in
the main program to selecting the tool via the T command and invoking
the tool changing subroutine.
Using a macro provides an elegant solution of the tool changing invocation:
Macro: DEFINE M6 AS BSR .M6
Thus, invoking "T<XX> M6" initializes a tool change in the NC program. The
changing process proper is then programmed from the label ".M6" onwards.
Example: NC program:



N0047 T12 M6 ; invoke "Change tools"
N0048 G54 G0 X123 Y45 F350


"Tool change" cycle:


N0000 .M6
N0001 G40 G47 G0 X100 Y100 Z50



N0056 RTS

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Functions to Control Tool Management 8-9

Note: Please refer to the "Bosch Rexroth MTC 200 tool management"
documentation, "Sample applications" section for examples of
programming tool storage units (magazines and turrets).

8.2 Tool Storage Unit Motion Commands of the NC


All tool storage unit motion is performed asynchronously relative to the mo-
tions on the other NC axes. The NC motion commands only initiate tool
storage unit motion and do not wait until the tool storage unit has completed
the motion. In the meantime, the NC program – and thus the process – can
be continued.
The command "MRY" can be used to scan signals to determine whether the
motion which was initiated is finished. In this way, the NC program is halted
and synchronized with the tool storage unit.
The following table contains an overview of all tool magazine motion
commands of NC. The table is followed by a detailed description of com-
mands.

NC tool commands (2) V22_20030122

Function Meaning Description


MEN Tool storage enabled for Syntax: MEN
manual mode
Magazine Enable

MFP Move free pocket into change Syntax: MFP (POS, DIR)
position
POS: Position to be moved to
Move next Free Pocket in Position
DIR: Direction of rotation

MHP Tool storage to home position Syntax: MHP (DIR)


Move to Home Position DIR: Direction of rotation

MMA Freely position tool axis Syntax: MMA (POS, DIR)


POS: Position to be moved to
Move Magazine Access DIR: Direction of rotation / mode

MMP Move programmed pocket into Syntax: MMP (POS, DIR)


basic position
POS: Position to be moved to
Move Magazine Pocket in Position
DIR: Direction of rotation

MOP Move old pocket into position Syntax: MOP (POS, DIR, SPI)
POS: Position to be moved to
DIR: Direction of rotation
SPI: Spindle
Move Old Pocket in Position

MRF Move tool storage unit to Syntax: MRF


reference position
Move to Reference Position

MRY Tool storage ready? Syntax: MRY


Magazine Ready

MTP Move programmed tool into Syntax: MTP (POS, DIR)


position
POS: Position to be moved to
Move Tool Position
DIR: Direction of rotation
Werkzeugbefehle_NC2_V22_20030122.xls

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
8-10 NC Functions to Control Tool Management MTC 200 NC programming instruction

Tool Storage to Reference Position "MRF"


MRF Move to Reference Position
(homing)
The "MRF" command starts the process of returning the tool storage unit
axis to the reference position.
This command is comparable to "G74" for the NC axes of a process. After
the control is powered on, the reference position must be established for the
tool storage system before it can traverse to a particular position.
For this reason, the "MRF" command must be programmed in the reverse
program of a process which uses the tool storage system.
In the case of NC-controlled tool storage units, referencing is executed by
setting parameters (Cxx.013 for "Combined spindle/turret axis", otherwise
using the drive parameters).
In the case of PLC-controlled tool storage units, the "MRF" NC command is
transferred to the "MRF" PLC function. The PLC must ensure that the refer-
ence is established and must acknowledge the "MRF" function.
Before performing the "MRF" command, it is important to be certain that the
tool storage movement does not prevent other NC axes from referencing.

reference mark

8 7 6 5
9 reference 4
cam

10 3
11 12 1 2

: occupied

reference mark : free


MRF.FH7

Fig. 8-6: Reference position using a chain magazine as an example

Move Tool Storage Unit to Home Position "MHP"


MHP Move to Home Position

Syntax MHP
MHP(DIR)

Expression DIR: <constant>


<variable>

Value range DIR: 0, 1, 2

Meaning DIR = 0: any given direction


DIR = 1: positive direction
DIR = 2: negative direction
The "MHP" command causes the tool storage unit to move to its home po-
sition. In this way, the tool management system ensures that the storage sys-
tem is traversed to "Location 1" regardless of the type of axis or storage unit.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Functions to Control Tool Management 8-11

Optionally, you can enter the direction of the movement to the home posi-
tion. The controller chooses the shortest way if a direction is not specified.
The distance is specified using the following drive parameters:
• Reference dimension 1 (S-0-00052) with motor measuring system
• Reference dimension 2 (S-0-00054) with external measuring system
With a PLC-controlled tool storage unit, tool management transfers "Loca-
tion 1" (PLC interface signal "PxxS.MGCP Command magazine position")
to the PLC. Using the "MMV" function, the PLC then moves to the home
position and brings "Location 1" to the reference mark.
reference mark

reference cam

10 9 8 7
11 6

12 5
1 2 3 4

: occupied

reference mark : free


MHP.FH7

Fig. 8-7: Home position using a chain magazine as an example

The CNC does not wait until the tool storage unit has reached the home
position. It continues to process the NC program while the tool storage
move is being carried out.
If this is not desired, the "MRY" command can be used to halt execution
of the NC program until the tool storage motion is completed.

Programmed Move Tool into Position "MTP"


MTP Move Tool Position
Move programmed tool into position

Syntax MTP
MTP(POS)
MTP(POS,DIR)

Expression POS: <constant>


<variable>
DIR: <constant>
<variable>

Value range POS: 1, 2, 3, 4


DIR: 0, 1, 2

Meaning POS = 1: move preselected tool to position 1 (Bxx.021)


POS = 2: move preselected tool to position 2 (Bxx.022)
POS = 3: move preselected tool to position 3 (Bxx.023)
POS = 4: move preselected tool to position 4 (Bxx.024)
DIR = 0: any given direction
DIR = 1: positive direction
DIR = 2: negative direction
The "MTP" command initiates a tool storage unit move which places the
tool selected in the specified position via the T word in the NC program
(change, installation or processing position).

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
8-12 NC Functions to Control Tool Management MTC 200 NC programming instruction

Optionally, the position into which the selected tool is to be brought and the
direction to be taken when the tool is moved to the specified change posi-
tion can also be declared.
Tool management chooses the shortest way and "Position 1" if neither di-
rection nor position is specified.
"Tool edge 1" of the tool automatically becomes the active tool edge.
If the tool storage unit contains several tools of the same name and the
same "T number" (alternate tools), tool management automatically selects
the tool to which the "Machining tool" status is assigned.
With machines that feature a tool magazine, which can be positioned
during the machining process, the "MTP" command is frequently used for
prepositioning the magazine.
"MTP" is usually programmed in the NC program together with the tool
preselection "T<XX>" immediately after changing the previous required
tool. In this way, the next tool is brought into the tool changing position
while the process is running.
In particular, this command is employed for tool changers with dual arm
grippers where the previously used tool is to be stored in the magazine
pocket from which the new one is taken.
Like "MFP", the "T0 MTP" command moves the next free location to the
specified position.
The CNC does not wait until the tool storage unit has completed its motion. It
continues to process the NC program while the move is being carried out.
If this is not desired, the MRY command can be used to halt execution of
the NC program until the tool storage motion is completed.
An additional tool carrier for tool storage type "Turret" is also selected with the
T number and the MTP command; however, the turret is not positioned. After
st
selection, the tool with the 1 edge is active; the offset of the new machine ze-
ro point is taken into account. This offset is also calculated when tool compen-
sation (G47) is inactive and is taken into account in the determination of the
spindle speed for the constant surface speed (G96).
A detailed description of the processing of additional tool carriers can be
found in the documentation "Bosch Rexroth MTC 200 tool management",
section 4-18.

Example: The inside cutting tool "T91" that is located on a turret is to


be moved to the second machining position (POS2) without
running through the first machining position (POS1).
Therefore define "Position 2" for POS and, for DIR, a nega-
tive turning direction of "2".

required swivel process

T238
reference T121 reference
mark mark
T91
T254
T125 2 T91 MTP(2,2) 5
1 3 4 6
T254 + T238
POS2 8 4 POS1 POS2 3 7
+ T91 POS1
T831 7 5 2 8
6 1
T121
T831
T238 T238
T125

MTP.FH7

Fig. 8-8: Positioning a tool via MTP

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Functions to Control Tool Management 8-13

Programmed Move Magazine Pocket into Position "MMP"


MMP Move Magazine Pocket in Position

(Move programmed pocket into position)

Syntax MMP
MMP(POS)
MMP(POS,DIR)

Expression POS: <constant>


<variable>
DIR: <constant>
<variable>

Value range POS: 1, 2, 3, 4


DIR: 0, 1, 2

Meaning POS = 1: move preselected location to position 1 (Bxx.021)


POS = 2: move preselected location to position 2 (Bxx.022)
POS = 3: move preselected location to position 3 (Bxx.023)
POS = 4: move preselected location to position 4 (Bxx.024)
DIR = 0: any given direction
DIR = 1: positive direction
DIR = 2: negative direction
The "MMP" command initiates a tool storage unit move which places the
location selected via the T word in the specified position (change, installa-
tion or processing position).
Optionally, the position into which the selected pocket is to be brought
and the direction to be taken when the tool is moved to the specified posi-
tion can also be declared.
Tool management chooses the shortest way and "Position 1" if neither
direction nor position is preselected.
"Tool edge 1" of the tool in the currently selected pocket automatically be-
comes the active tool edge.
The "MMP" command is generally used for sorting work and for adding or
removing tools.

Note: When used with the T-word, the "MMP" command refers ex-
clusively to locations and not to tools. For this reason, if tools
are called according to the position using MMP, any spare
tools which are present are ignored during a process unless
they are explicitly programmed in the NC program with the aid
of the T word and the corresponding pocket number.

The CNC does not wait until the tool storage unit has completed its mo-
tion. It continues to process the NC program while the move is being car-
ried out.
If this is not desired, the MRY command can be used to halt execution of
the NC program until the tool storage motion is completed.

Example: Inside cutting tool "T91" in location 3 is to be replaced. To do


this, it must be moved to the loading/unloading position
(POS3).
This can be done either by "jogging" the turret or, for example,
using the "T3 MMP (3,0)" command in the MDI (Manual Data
Input). The pocket then moves along the shortest path possib-
le (negative direction) to the loading/unloading position.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
8-14 NC Functions to Control Tool Management MTC 200 NC programming instruction

POS3 T238
reference POS3 T254 reference
mark mark
T91 T121

T125 2 T3 MMP(3,0) T91 4


1 3 3 5
T254 +
POS2 8 4 POS1 POS2 2 6
+ POS1
T831 7 5 T238 1 7
6 8
T121 T238
T238 T125
T831

MMP.FH7

Fig. 8-9: Positioning a turret pocket using MMP

MTP/MMP Commands and Tool Correction


The two commands MTP and MMP have different time behavior in regard
to the activation of tool correction. Depending on the turret type and the
command used, tool correction must be activated before or after the turret
movement.

Interaction of Bxx.044 and REV_SYNC

Bxx.044
Turret movement "Asynchronous turret movement"

NO Yes

Input
synchronous asynchronous
ACTIVE = 0

REV_SYNC
Input
synchronous synchronous
ACTIVE = 1

Bxx044_REV_SYNC_V22_20030218.xls

Activation of tool compensation with MTP and MMP

Tool correction Point of activation MTP MMP MRY

Activate tool comp. Activate tool comp. -


Synchronous turret move- At the beginning before moving turret after moving turret
ment
Activate tool comp. Activate tool comp. -
At the end after moving turret after moving turret
When tool is in posi-
At the beginning tion then activation is Activate
performed immedi- - tool comp.
Asynchronous turret ately, otherwise at
movement first with MRY
At the end - - Activate
tool comp.
Werkzeugkorrektur_MTP_MMP_V22_20030218.xls
TC: Tool correction
T: Tool
Fig. 8-10: Activation of tool compensation with MTP and MMP

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Functions to Control Tool Management 8-15

Freely Position Tool axis "MMA"


MMA Move Magazine Axis
(Freely position tool axis)

Syntax MMA
MMA(POS)
MMA(POS,DIR)

Expression POS: <constant>


<variable>
DIR: <constant>
<variable>

Value range POS: -214748.3648 to +214748.3647 with 4


positions after the decimal point
DIR: 0, 1, 2, 3, 4

Meaning POS = axis position in mm, inches or units (default = 0)


DIR = 0: shortest path (default)
DIR = 1: positive direction
DIR = 2: negative direction
DIR = 3: longest path
DIR = 4: incremental path instructions
Tool magazine command MMA executes free positioning of the tool axis.
Here, any position (intermediate locations) can be absolutely or relatively
approached by the NC program. Direct programming of the tool axis us-
ing an axis name is not possible.
Tool management chooses the shortest way and position value 0 if nei-
ther direction nor position is specified.
The MMA command deactivates tool compensation for a tool turret and
deselects the active tool (T0 is preselected). If the tool storage unit is a
magazine, the tool that is located in the current tool spindle remains active.
The addressing of tool data using the tool axis position after free posi-
tioning using command MMA is not possible. If the tool axis is in the "Free
positioning" operating mode during a tool change using tool transfer
commands (e.g. TSM, TMS, TCH), an error message is issued.

Notes: It is mandatory that the tool axis be again positioned absolutely


on a valid magazine location before executing a tool change
using the corresponding tool storage unit movement com-
mands.

Command MMA is not supported for PLC-controlled maga-


zines/turrets and for tool magazine axes of axis type "Com-
bined spindle/turret axis".
Interface signal PxxS.MGCP (Process xx Status Magazine
Command Position) remains unchanged.

The CNC does not wait until the tool storage unit has completed its mo-
tion. It continues to process the NC program while the move is being car-
ried out.
If this is not desired, the MRY command can be used to halt execution of
the NC program until the tool storage motion is completed.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
8-16 NC Functions to Control Tool Management MTC 200 NC programming instruction

Move to Free Position "MFP"


MFP Move next Free Pocket in Position
(Move free pocket into change position)

Syntax MFP
MFP(POS)
MFP(POS,DIR)

Expression POS <constant>


<variable>
DIR: <constant>
<variable>

Value range POS: 1, 2, 3, 4


DIR: 0, 1, 2

Meaning POS = 1: move next free location to position 1 (Bxx.021)


POS = 2: move next free location to position 2 (Bxx.022)
POS = 3: move next free location to position 3 (Bxx.023)
POS = 4: move next free location to position 4 (Bxx.024)
DIR = 0: any given direction
DIR = 1: positive direction
DIR = 2: negative direction
The "MFP" command initiates a tool storage unit movement to move the
closest empty pocket to the specified position.
Optionally, the position into which the closest empty pocket is to be
brought and the direction to be taken when the tool is moved to the speci-
fied position can also be declared.
Tool management chooses the shortest way and "Position 1" if neither
direction nor position is specified.
This command is used to place the tool located in the tool spindle or in
the gripper in the closest empty pocket in the magazine. This is especially
necessary with tool changers which do not have grippers or which use
single-arm systems when the old tool needs to be stored before a new
tool can be used.
The CNC does not wait until the tool storage unit has completed its motion.
It continues to process the NC program while the move is being carried out.
If this is not desired, the MRY command can be used to halt execution of
the NC program until the tool storage motion is completed.
Example:
The tool in "Spindle 1" is to be brought back to the magazine. This re-
quires the nearest empty pocket to be moved to "POS 2". Due to the fact
that the magazine may only be turned in the positive direction, the turning
direction is declared as "1".
Therefore, "Position 2" must be selected for POS as well as a turning
direction of "1".

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Functions to Control Tool Management 8-17

loading loading
position position
10 9 8 7 1 12 11 10
11 + 6 2 + 9
POS 1 MFP(2,1) POS 1
POS 2 POS 2
12 5 3 8

1 2 3 4 4 5 6 7

gripper gripper
reference mark reference mark

: occupied
: free
spindle 1 spindle 1
MFP.FH7

Fig. 8-11: Positioning a free magazine location using MFP

Move Old Pocket in Position "MOP"


MOP Move Old Pocket in Position

Syntax MOP
MOP(POS)
MOP(POS,DIR,SPI)

Expression POS: <constant>


<variable>
DIR: <constant>
<variable>
DIR: <constant>
<variable>

Value range POS: 1, 2, 3, 4


DIR: 0, 1, 2
SPI 1, 2, 3

Meaning POS = 1: move old location to position 1 (Bxx.021)


POS = 2: move old location to position 2 (Bxx.022)
POS = 3: move old location to position 3 (Bxx.023)
POS = 4: move old location to position 4 (Bxx.024)
DIR = 0: any given direction
DIR = 1: positive direction
DIR = 2: negative direction
SPI = 1: old location of the tool in spindle 1
SPI = 2: old location of the tool in spindle 2
SPI = 3: old pocket of tool in spindle 3
The "MOP" command initiates a tool storage unit movement which moves
the old pocket of the tool located in tool spindle "SPI" to position "POS"
from which the tool was removed.
Optionally, the position, direction of rotation and the tool spindle can be
declared.
If the position, direction or tool spindle are not entered, the tool management
system selects the old pocket for the tool which is active for "Spindle 1" and
places it in "Position 1" using the shortest distance.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
8-18 NC Functions to Control Tool Management MTC 200 NC programming instruction

If this command is used consistently, all tools will be returned to the pock-
ets in which they were located before they were used in the machining
process. This keeps the tool storage unit in an orderly condition. This is
desirable, for example, when extra-wide tools always have to be stored in
the same magazine pocket.
The CNC does not wait until the tool storage unit has completed its motion. It
continues to process the NC program while the move is being carried out.
If this is not desired, the MRY command can be used to halt execution of
the NC program until the tool storage motion is completed.
Example:
The tool (T256) in "Spindle 1" is to be returned to its old pocket in the
magazine. This requires the old pocket to be moved to "POS 2". Due to
the fact that the magazine may only be turned in the positive direction, the
turning direction is declared as "1".
Declare "Position 2" for POS, a positive turning direction for DIR and the
first spindle for SPI.

old location
of T256
loading loading
position position
10 9 8 7 4 3 2 1
11 + 6 5 + 12
POS 1 MOP(2,1,1) POS 1
POS 2 POS 2
12 5 6 11

1 2 3 4 7 8 9 10

gripper gripper
reference mark reference mark

: occupied
T256
: free
spindle 1 spindle 1
MOP.FH7

Fig. 8-12: Positioning the old pocket using MOP

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Functions to Control Tool Management 8-19

Wait until Position is Approached "MRY"


MRY Magazine Ready
(Magazine movement completed ?)
If the last tool storage movement command has not yet been completed, then
the MRY command temporarily interrupts the processing of the NC program.
The NC program does not resume processing until the programmed posi-
tion has been reached. This permits the tool storage axis to be synchro-
nized with the NC program.
Example: Tool changing program:
N0000 .M6 ;Jump label for changing tools



N0012 MTP(2,0) ;Move programmed tool to position 2
• ;on the shortest path


N0037 MRY ;Wait until position 2 is reached



Example:
(NC program)

MTP (2,0) ;Move programmed tool to "POS 2" along the shortest path
MRY ;Wait until position 2 is approached

Enable Tool Magazine (Storage) for Manual Mode "MEN"


MEN Magazine Enable
(enable magazine)
The "MEN" command allows a tool magazine to be traversed manually
while the "Automatic" mode of the machine is active. For example, this
allows a worn tool to be changed while production continues.
In order for the tool magazine to run in manual mode, the MEN command
must be active in the NC program and the PLC must have selected the
"Manual" mode for the tool storage.
If the tool storage mode is changed to manual after a MEN command has
been performed, the CNC continues to execute the program for this process
until the next tool storage movement or tool change command is encountered.
It then issues the corresponding status message:
"Waiting for tool storage move cmd to be completed"
When the system switches back to program-controlled mode, the status
message in the diagnostic box is cleared and the remaining commands are
processed to completion.
All motion and tool change commands programmed in the NC program
(generally located in a tool change subroutine) request tool storage again.
If a further motion or tool change command follows before the change to
manual mode and after the tool storage system was enabled via MEM in
the NC program, the tool storage unit cannot be traversed manually while

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
8-20 NC Functions to Control Tool Management MTC 200 NC programming instruction

the program is executing and continuing to the next "MEN", "BST", "RET" or
control reset.

Moving Tool Storage Unit with Nonuniform Pocket Distribution


Tool storage unit movement NC-controlled tool magazines and tool turrets that have a nonuniform
commands of NC spacing of the tool positions can be easily operated using a machine data
(MTP, MMP, MHP, etc.) page with the tool storage movement commands of the NC (MTP, MMP,
MHP, etc.). Furthermore, additional axis positions can be specified re-
gardless of the type of spacing of the tool storage unit (uniform or non-
uniform spacing) for logical positions 1 to 4; any intermediate position can
then be approached.

Process parameter Bxx.072 In this regard:


"Page No. for variable pocket
1. the number of the machine data page (100-299) in which the variable
positions" and corresponding
positions are specified is to be entered in process parameter Bxx.072
machine data page
"Page No. for variable positions".
2. the corresponding page in the machine data is to be created and the
positions of tool locations to be entered.
The NC evaluates process parameter Bxx.072 for the runtime and the
corresponding machine data page and uses the highlighted positions to
calculate the absolute magazine positions of the tool storage axis. A
separate page must be created for every process in multiprocess opera-
tion.

Note: Process parameter Bxx.072 appears in the user interface only


if "Yes" was entered in system parameter A00.052 "Tool man-
agement" and in process parameter Bxx.014 "Tool manage-
ment".

Machine data entries The machine data page contains one absolute axis position each
• for positions P1-P4 (control variable LV1 = -1 to -4),
• for the position of home position (MHP command) (LV1 = 0),
• for all n magazine locations (LV1 = 1-n).

Detailed information regarding the setting of parameters as well as the


structure and definition of the machine data page can be found in the des-
cription of process parameter Bxx.072 "Page No. for variable positions" in
the Bosch Rexroth MTC 200/Bosch Rexroth TRANS 200 description of
parameters.

Effect on jogging the tool axis If nonuniform tool pocket distribution has been activated using process
parameter Bxx.072 "Page No. for variable positions", the jogging of tool
axes refers to one of the four change positions P1-P4. For more informa-
tion, see section "Magazine jogging operating mode in case of variable
tool pocket distribution "PxxC.MGJGn"" in the "Bosch Rexroth MTC 200
interface description".

Notes:
• The nonuniform spacing function is not available when a
combined spindle/revolver axis or PLC-controlled tool sto-
rage units are used.
• When nonuniform pocket distribution is activated for NC-
controlled tool turrets, parameters Bxx.021-Bxx.024 "Po-
sition 1-4" no longer have an effect.
• Only the magazine position approached using a tool sto-
rage movement command (e.g. MTP, MMP, jogging) is a
valid position (P1-P4) for the tool change.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Functions to Control Tool Management 8-21

8.3 Tool Changing Commands of the NC


Changing tools between magazine, spindle or gripper is initialized via the
tool changing commands of the NC. Using the tool changing commands
is permitted only when magazines are used as tool storage units.
The following figure shows the basic sequence of a tool changing process.

CNC

SPS
NC WZM PLC
NC program

TMS
TMS
.
.
XMS

tool mgmt.
checks
requested
tool transfer
of PLC

XMS_PA

XMS_NA

XMS_Q

tool mgmt.
performs XMS_CA
requested tool
transfer of PLC

tool mgmt.
aborts TMS_Q
requested tool
transfer of PLC

CNC1.FH7

Fig. 8-13: Representation of the principles of a tool change

The following table contains an overview of all tool change commands of


the NC. The table is followed by a detailed description of commands.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
8-22 NC Functions to Control Tool Management MTC 200 NC programming instruction

NC tool commands (3) V22_20030218

Function Meaning Description


TCH Complete tool change Syntax: TCH (POS, SPI)
Tool Change POS: Position to be moved to
SPI: Spindle

TMS Change tool from magazine to Syntax: TMS (POS, SPI)


spindle

Tool change from Magazine to POS: Position to be moved to


Spindle
SPI: Spindle

TPE Tool pocket empty? Syntax: TPE


Tool Magazine Pocket Empty

TSE Tool spindle empty? Syntax: TSE

Tool Spindle Empty

TSM Switch tool from spindle to Syntax: TSM (POS, SPI)


magazine
Tool change from Spindle to POS: Position to be moved to
Magazine

SPI: Spindle
Werkzeugbefehle_NC3_V22_20030122.xls

Performing a Complete Tool Change "TCH"


TCH Tool Change
(Complete tool change)

Syntax TCH
TCH(POS)
TCH(POS,SPI)

Expression POS <constant>


<variable>
DIR: <constant>
<variable>

Value range POS: 1, 2, 3, 4


SPI: 1, 2, 3

Meaning Tool exchange between spindle "SPI" and position "POS".


The "TCH" command initiates a tool exchanging process between spindle
"SPI" and the magazine location in position "POS".
The CNC stops program execution while the tool change operation is
proceeding under PLC control.
Optionally, the change position and tool spindle can be declared. If no
data are declared for the change position or tool spindle, tool manage-
ment selects "Position 1" and "Spindle 1".
The magazine must be correctly positioned before "TCH" is called.
The TCH command is used in particular with double-arm gripper systems.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Functions to Control Tool Management 8-23

Change the Tool from the Magazine to the Spindle "TMS"


TMS Tool Change from Magazine to Spindle

Syntax TMS
TMS(POS)
TMS(POS,SPI)

Expression POS: <constant>


<variable>
DIR: <constant>
<variable>

Value range POS: 1, 2, 3, 4


SPI: 1, 2, 3

Meaning Changing tools from position "POS" to spindle "SPI".


The TMS command initiates a tool changing process between the maga-
zine locations in position "POS" and spindle "SPI".
The CNC stops program execution while the tool change operation is pro-
ceeding under PLC control.
Optionally, the change position and tool spindle can be declared. If no
data are declared for the change position or tool spindle, tool manage-
ment selects "Position 1" and "Spindle 1".
Even before "TMS" is called, the magazine pocket containing the tool
which is to be exchanged must already be in the specified change posi-
tion; a tool may not be present in the tool spindle.
This command is needed for single-arm gripper systems or for gripper-
less tool changers if the change operation has to be divided into a pick-
and-place sequence.

Tool Change from Spindle to Magazine "TSM"


TSM Tool Change from Spindle to Magazine

Syntax TSM
TSM(POS)
TSM(POS,SPI)

Expression POS: <constant>


<variable>
DIR: <constant>
<variable>

Value range POS: 1, 2, 3, 4


SPI: 1, 2, 3

Meaning Changing tools from spindle "SPI" to position "POS".


The "TSM" command initiates a tool change between spindle "SPI" and
the magazine location in position "POS".
The CNC stops program execution while the tool change operation is pro-
ceeding under PLC control.
Optionally, the change position and tool spindle can be declared. If no da-
ta are declared for the change position or tool spindle, tool management
selects "Position 1" and "Spindle 1".

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
8-24 NC Functions to Control Tool Management MTC 200 NC programming instruction

Before "TSM" is called, a tool must be present in the tool spindle and the
magazine must have an empty location at the specified change position.
This command is needed for single-arm gripper systems or for gripper-
less tool changers if the change operation has to be divided into a pick-
and place-sequence.

Magazine Pocket Empty? "TPE"


TPE Tool Magazine Pocket Empty

The "TPE" command checks whether the magazine or turret location that
is currently at "Position 1" is empty.
If this is the case, tool management immediately continues program exe-
cution. Otherwise, program execution is stopped and an error message is
generated.
Using this command permits collisions to be avoided when a tool is
stored. The command must be used in the storage sequence of the tool
changing subroutine before a movement is performed.

Note: The "TPE" command always refers to the location at "Position 1".

Tool Spindle Empty? "TSE"


TSE Tool Spindle Empty

The "TSE" command checks whether the tool location that is currently in
"Spindle 1" is empty.
If this is the case, tool management immediately continues program exe-
cution. Otherwise, program execution is stopped and an error message is
generated.
Using this command permits collisions to be avoided when a tool is
stored. The command must be used in the storage sequence of the tool
changing subroutine before a movement is performed.

Note: The "TSE" command always refers to the location at "Spindle 1".

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Process and Program Control Commands 9-1

9 Process and Program Control Commands

9.1 Process Control Commands


The multiple-process structure of the CNC makes it necessary to coordi-
nate the individual processes used in the CNC. If more than two proc-
esses are present in the CNC, the process with number "0" is generally
used for program coordination. The number "0" process thus handles the
management function used to coordinate all processes which are involved
in machining. The process control commands are passed to the NC PLC
interface.

MTC200 (control station)


Process 0 Process 1 Process 2 Process 3 Process 4 Process 5 Process 6

MTC200 station 1
External External External External External
Mechanism Mechanism Mechanism Mechanism Mechanism
7 8 9 10 11

MTC200 station 2
External External External External External
Mechanism Mechanism Mechanism Mechanism Mechanism
12 13 14 15 16

MTC200 station 3
External External External External External
Mechanism Mechanism Mechanism Mechanism Mechanism
17 18 19 20 21

MTC200 station 4
External External External External External
Mechanism Mechanism Mechanism Mechanism Mechanism
22 23 24 25 26
91Proz.fh7

MTC200 station 5
External External External External External
Mechanism Mechanism Mechanism Mechanism Mechanism
27 28 29 30 31

91PROZ.FH7

Fig. 9-1: Processes and external mechanisms of CNC

In addition to the master process, the CNC can control six additional pro-
cesses and up to 25 external mechanisms.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
9-2 Process and Program Control Commands MTC 200 NC programming instruction

A master process (process 0) must always be present. This process is


responsible for synchronizing the existing processes and external mecha-
nisms, assuming this is necessary. If the system consists of a single sta-
tion, the coordination task and the axes are assigned directly to the mas-
ter process.

Note: The number and organization of the processes and external


mechanisms is set by the machine builder in the system pa-
rameters.

Define Process "DP"


The DP command uses an internal signal to inform the PLC that the pro-
cess is needed during NC program execution. The PLC uses this infor-
mation to initialize process-specific signals.

Syntax DP <process> ⇒ DP 2
DP <variable>
Process[0-6] internal processes
Process[7-31] external mechanisms

All other process control commands will not be accepted unless the cor-
responding process was previously defined using DP.
• The DP command can be used more than once in an NC block. A
number of processes can be defined simultaneously in an NC block.
• The definition of a process using DP is canceled at the end of the pro-
gram.

Select NC Program for Process "SP"


The SP command selects the program having the specified program
number from the active NC program package for the specified process.
The program number corresponds to the number which is stated in the
program directory for the given process.

Syntax SP <process> <program number> ⇒ SP 3 25


SP <variable> <variable>
Process[0-6] internal processes
Process[7-31] external mechanisms
Program number[1-99] program number in active pro-
gram package
The NC program number for the next program which is to be processed
can be selected while a process is still active. The selected program is not
activated until the next reboot.
• The SP command must not be used more than once in an NC block.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Process and Program Control Commands 9-3

Start Reverse Program "RP"


The RP command starts the subroutine which is addressed by the re-
verse vector in the declared process. Any forward program which may be
active is interrupted; the currently valid reverse vector addresses the
branch location in the reverse program.

Syntax RP <process> ⇒ RP 4
RP <variable>
Process[0-6] internal processes
Process[7-31] external mechanisms

• The subroutine addressed by the reverse vector must be located in


the program in which the reverse vector was programmed.
• The RP command can be used more than once in an NC block. A
number of reverse processes can be started simultaneously in a sin-
gle NC block.

Start Advance Program "AP"


Command AP starts the selected advance program in an inactive proc-
ess. If the process was already active, then the NC block processing in
which AP was programmed is interrupted until the process to be started is
totally completed. The declared process is then started and NC block
processing of the interrupted process is continued.

Syntax AP <process> ⇒ AP 1
AP <variable>
Process[0-6] internal processes
Process[7-31] external mechanisms

• The AP command can be used more than once in an NC block. A


number of forward programs can be started simultaneously in a single
NC block.

Wait for Process "WP"


NC block processing of the program which was called is held in the NC
block in which WP is programmed until the process selected in the com-
mand parameter has been completed.

Syntax WP <process> ⇒ WP 5
WP <variable>
Process[0-6] internal processes
Process[7-31] external mechanisms

Once the process selected in the command parameter is completed, exe-


cution of the NC program from which the call was made can continue.
• Process control command WP can be programmed more than once
in a single NC block.
• The WP command should not be programmed within a program sec-
tion in which tool path compensation is active. If this proves to be un-
avoidable, be certain that it is programmed only between linear block
transitions.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
9-4 Process and Program Control Commands MTC 200 NC programming instruction

Note: Command WP waits until the process selected has been


completed. Processes are completed by:
• successful completion of an advance program
• successful completion of a reverse program
• cancellation of the program after control reset (after pro-
gram interrupt).
The processing of the WP command does not provide any in-
formation about whether the process task has been completed
successfully.

Lock Process "LP"


The LP command specifies which processes must be in a defined state
for the NC program to be completed. This state must remain intact until
the NC program is completed.

Syntax LP <process> ⇒ LP 4
LP <variable>
Process[0-6] internal processes
Process[7-31] external mechanisms

This command can be used, for example, to specify that a station which is
not needed for machining can be turned off or that it must be in a specific
position so as not to endanger ongoing work.
• Stations which are locked using LP cannot be operated manually,
even though they might not be involved in the programmed work.
• Process control command LP is reset at the end of the program by
RET, BST or by control reset.

Example: application of process and program control commands


Management program Process 0 program number 15
.START Jump label for BST .START
DP 1 DP 2 Definition of process 1 & process 2
SP 1 15 Program preselection, program 15 in process 1
SP 2 15 Program preselection, program 15 in process 2
RE 1:0 Delete acknowledgement – processing finished
in process 1
RE 2:0 Delete acknowledgement – processing finished
in process 2
AP 1 AP 2 Start advance program in process 1 & 2
WP1 WP 2 Wait until both processes have completed their
programs
BER .FEHLP1 1:0 Error handling process, error process 1
BER .FEHLP2 2:0 Error handling process, error process 2
SP 1 16 Program preselection, program 16 in process 1
SP 2 16 Program preselection, program 15 in process 2
RE 1:0 Delete acknowledgement – processing finished
in process 1
RE 2:0 Delete acknowledgement – processing finished
in process 2
AP 1 AP 2 Start advance program in processes 1 & 2
WP1 WP 2 Wait until both processes have completed their
programs
BER .FEHLP1 1:0 Error handling process, error process 1
BER .FEHLP2 2:0 Error handling process, error process 2
BST .START Jump with stop to label .START
.FEHLP1 Error handling process, error process 1

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Process and Program Control Commands 9-5

...
.FEHLP2 Error handling process, error process 2
...
.HOME Branch label for the .HOME program
DP 1 DP 2 Definition of processes 1 & 2
SP 1 15 Program preselection, program 15 in process 1
SP 2 15 Program preselection, program 15 in process 2
RP 1 RP 2 Start reverse program in processes 1 & 2
WP1 WP 2 Wait until both processes have completed their
programs
BST .START Jump with stop to label .START
PROGRAM END

Note: If no reverse vector has been programmed in the individual


processes, then a jump to .HOME is performed in the corre-
sponding process.

Subprogram 15, process 1 Subprogram 15, process 2


G00 G90 G54 G06 G08 ;Path com- G18 G90 G54 G06 ;Path com-
mands G08 mands
G00 Y0 Z50 ;Start position G00 X0 Z0 Y70 ;Start position
M03 S1500 ;Spindle ON M03 S1500 ;Spindle ON
st st
G01 X50 Y100 F1000 ;1 mach. G01 X50 Z40 F1500 ;1 mach.
. position . position
;Machining ;Machining
M05 ;Spindle OFF M05 ;Spindle OFF
RET ;Program end RET ;Program end

Subprogram 16, process 1 Subprogram 16, process 2


G00 G90 G54 G06 G08 ;Path com- G18 G90 G54 G06 ;Path com-
mands G08 mands
X0 Y0 Z30 ;Start position G00 X0 Z0 Y55 ;Start position
M03 S1500 ;Spindle ON M03 S1500 ;Spindle ON
st st
G01 X90 Y150 F1200 ;1 mach. G01 X10 Z110 F2000 ;1 mach.
. position . position
;Machining ;Machining
M05 ;Spindle OFF M05 ;Spindle OFF
RET ;Program end RET ;Program end

Process Complete "POK"


By programming the POK (Part OK) command, the NC programmer can
determine in the NC program when the process was completed. The POK
command causes a signal to be sent to the PLC (process-specific).

Syntax POK
If the POK command is programmed in process 0, the PLC signal is not
set to 1 until all processes defined by means of DP (including the external
mechanisms) have already processed the POK command.
• The signals for the POK command are reset at the end of the pro-
gram by RET or BST or by a control reset.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
9-6 Process and Program Control Commands MTC 200 NC programming instruction

9.2 Axis Transfer Between Processes "FAX", GAX"


{0><}100{>Certain applications require that the fixed axis assignments to
the processes be canceled and that the axes be divided into a number of
interpolation groups (processes).
Each NC axis is assigned to a primary process; however, it can also be
assigned to up to three different secondary processes. The axis name
and meaning in the coordinate system is the same for all processes in
which the axis is enabled. In addition, different axes having the same
name can be called from different processes.

Syntax Free axis <axis name> in the process in which the axis is located.
FAX (<axis name>) ⇒ FAX (Y)

Get axis <axis name> from the process defined in the command pa-
rameter.
GAX (<process>:<axis name>) ⇒ GAX (1:Y)

• The primary process must always be stated when specifying the pro-
cess for the GAX command. If the axis is called from the primary pro-
cess via GAX, it is not necessary to state the process number.
An axis transfer will not occur until the process in which the axis is cur-
rently located and is called by a different process frees the axis. The pro-
cess which gets the axis (GAX) must wait until the other process frees the
axis (FAX). Likewise, the process which frees the axis waits until a differ-
ent process gets the axis. This prevents the axis from assuming a "lost"
state.
Transferable axes are displayed in the position display of each process in
which they can be present.
If a transferable axis is located in the indicated process, the complete axis
data set is displayed for this axis. On the other hand, if the axis is cur-
rently assigned to a different process, two dashes are displayed instead of
the position and speed data.
• All axes in the CNC – with the exception of the magazine and turret
axes – can be transferred between the processes.
• The transfer from one process to another can only take place at an
NC block transition. NC block processing is stopped and is not con-
tinued until it is certain that the override value for the new process is
active for the axes.
• Rotary and linear axes can be transferred between processes only
when they are stopped.
• Spindles can also be transferred between the processes at the speci-
fied spindle speed. However, spindle-dependent feed modes such as
"feed per turn" are deactivated when spindles are transferred.
• The axis continues to be assigned to the primary process, even after
the axis is transferred to a secondary process. Thus, axis errors and
their diagnostic messages are displayed in the primary process.
• All axes belonging to a different primary process are freed at the end
of the program by RET ,M02, M30 or BST or by a control reset and by
jogging axes in setup mode; all axes in a different process are re-
quested (get).

Note: The machine builder specifies the processes between which a


NC axis can be transferred in the axis parameters.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Process and Program Control Commands 9-7

Example: NC program - axis transfer

A machining center having two tables is divided into 3 NC processes.


Since the parts which are to be machined on the two tables can be identi-
cal, the machine operator wants to be able to use the same NC pro-
grams. The X axis offset is generated by overwriting the zero offset.
The process is divided as follows:
• Process 0 is the machining process, which has 3 main axes, "X," "Y"
and "Z" as well as main spindle "S." Processes "0," "1" and "2" are
started simultaneously by pressing the NC start key.
• Process 1 manages the rotary table (B axis) on the right side and ei-
ther frees or gets the B axis as needed. Process synchronization is
established by means of the programmed NC events.
• Process 2 manages the rotary table (B axis) on the right side and
either frees or gets the B axis as needed. Process synchronization is
established by means of the programmed NC events.

The necessary initializations and the corresponding reverse program are


not shown in the NC program. If the NC program is interrupted, various
mechanisms and initializations would be needed to obtain a defined state.

Z Y

B B
92achsü.fh7

X
92ACHS.FH7

Fig. 9-2: Axis transfer on a machining center having 2 machining tables

Process 1 "B axis right" Process 2 "B axis left"


BEARB Label for branch BEARB Label for branch
loop loop
FAX (B) Enable B-axis FAX (B) Enable B-axis
WES 9 Wait until B-axis is in WES 9 Wait until B-axis is in
P0 P0
RE 9 RE 9
GAX (B) Get B axis if it GAX (B) Get B axis if it
has been freed in has been freed in
machining p. machining p.
BER .BEARB 10 Loop until machining BER .BEARB 10 Loop until machining
in P0 is complete in P0 is complete
RE 10 RE 10
RET RET

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
9-8 Process and Program Control Commands MTC 200 NC programming instruction

Process 0 - Processing
RE 1:10 Reset events for jump loops in process
RE 2:10 1+2
T1 BSR .M6 Tool change, 1st tool
[right side]
GAX (1:B) Get B axis from process 1
SE 1:9 Process 1 is interrupted up to this NC
block
WER 1:9 Wait until process 1 is synchronous
BSR .BET1 Process right side
[left side]
GAX (2:B) Get B axis from process 2
SE 2:9 Process 2 is interrupted up to this NC
block
WER 2:9 Wait until process 2 is synchronous
BSR .BET1 Process left side
T2 BSR .M6 Change tool, 2nd tool
[right side]
GAX (1:B) Get B axis from process 1
SE 1:9 Process 1 is interrupted up to this NC
block
WER 1:9 Wait until process 1 is synchronous
BSR .BET2 Process right side
[left side]
GAX (2:B) Get B axis from process 2
SE 2:9 Process 2 is interrupted up to this NC
block
WER 2:9 Wait until process 2 is synchronous
BSR .BET2 Process left side

SE 1:10 End jump loops in processes 1 + 2.


SE 2:10
T0 BSR .M6 Program end
RET Process program, 1st tool
.BET1 Path commands, interpolation condi-
G00 G54 G90 X0 Y0 Z100 B0 tions

M03 S1000

;machining
Release B axis
M05 Process subroutine 1 end
FAX (B) Process program 2nd tool
RTS
.BET2 Process subroutine 2 end

RTS End of program


Machining program of 1st tool
Motion commands, interpolation condi-
tions

Enable B-axis
End of machining subroutine 1
Machining program of 2nd tool

End of machining subroutine 2

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Process and Program Control Commands 9-9

9.3 Program Control Commands

Program End with Reset "RET"


The RET command identifies the end of an NC program. The RET com-
mand acts like functions M002/M030; however, an auxiliary function is not
passed on to the PLC. When the RET command is performed, process-
ing branches to the first NC block in the active NC program, sets the se-
lected functions for the power-on state, and waits for a start signal. Tool
edge E1 is selected. After the RET command has been performed, the
current reverse vector points to branch label .HOME.

Syntax RET
After the RET command is performed, all subroutine levels and their re-
verse vectors are cleared and the controller is in the initial state of the
main program level.
• In terms of its function, RET is comparable to the M002/M030 func-
tions defined in DIN 66025.

Branch with Stop "BST"


The BST command branches to the branch label which is set in the
command parameter, sets the path conditions of the power-on state and
waits for a start signal. After a BST, the current reverse vector points to
the branch label .HOME.

Syntax BST <branch label> ⇒ BST .HALT


After a BST command, all subroutine levels and their reverse vectors are
cleared and the controller is in the initial state.
• The BST command cannot be used within a subroutine. The branch
from the subroutine will result in an error message.

Programmed Halt "HLT"


The HLT command interrupts program execution and waits for a new
start signal. The HLT command acts like function M000; however, an
auxiliary function is not passed on to the PLC.

Syntax HLT
If a message is to be output for the HLT command, note that the mes-
sage must already be programmed in an NC block before the HLT com-
mand. The reason for this is that the HLT command is executed ahead of
a message in the standard order in which NC commands are carried out
(see Chapter "Elements of an NC block").

Branch Absolute "BRA"


The BRA branch command branches to the label set in the command
parameter and continues program execution there.

Syntax BRA <branch label> ⇒ BRA .WEITER

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
9-10 Process and Program Control Commands MTC 200 NC programming instruction

Jump to Another NC Program "JMP"


The JMP jump command jumps to the NC program number set in the
command parameter and continues program execution in the first NC
block of this new NC program.

Syntax JMP <program number[1-99]> ⇒ JMP 50


JMP <variable> ⇒ JMP @100

The jump can go to any desired NC program in the active NC program


package. The reverse vectors are not changed by a jump to a different
NC program.

9.4 Subroutines

Subroutine Technique
When workpieces are being machined, it is sometimes necessary to re-
peat a given operation a number of times. This operation could be pro-
grammed as a subroutine so that similar processing sequences could be
called up repeatedly. This subroutine could be called from any point in the
NC machining program as a complete function module.
Subroutines are organized in the CNC based on the following structure.

N C P ro g ra m Me m o ry B
N C P ro g ra m Me m o ry A

N C P ro g ra m 0 4

Adva n ce P ro g ra m

N C C ycle Me m o ry
Reve rse P ro g ra m P ro g ra m N o . 9 9 P ro g ra m N o . 0

Bo sch Re xro th
Use r C ycle s a n d a n d Ma chin e
S u bro u tin e s o f the S u bro u tin e s Bu ilde r’s
Adva n ce a n d Reve rse S u bro u tin e s a n d
P ro gra m C ycle s

3NCORG.FH7

Fig. 9-3: Program organization for CNC

Subroutines which are specific to the NC program are programmed in the


current NC program. Subroutines which are specific to the NC package
are programmed in the program using number 99. They can be called
from any NC program in the package. Subroutines and process cycles
are programmed in program 0 "Cycle Memory". These NC cycle pro-
grams can be called from any NC memory, process, and NC program
package.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Process and Program Control Commands 9-11

Subroutine Structure
A subroutine consists of the:
• start of the subroutine,
• NC blocks of the subroutine, and
• end of subroutine

.LABEL Start of subroutine

NC blocks NC blocks in subroutine

RTS End of subroutine


Fig. 9-4: Subroutine structure

In terms of syntax, the jump label begins with a decimal point followed by
at least one and no more than six legal characters. The syntax is NOT
case sensitive. The "∗ " sign following the decimal point is reserved for
Bosch Rexroth fixed cycles.

Subroutine Nesting
A subroutine can be called up from an NC program as well as from a dif-
ferent subroutine. This is referred to as "subroutine nesting."
The CNC allows 10 subroutine nesting levels. This means that subrou-
tines can be nested no more than 9 levels in depth.

Program Call Levels :


1 2 3 4 5 6 7 8 9 10

9 Nesting Levels
.SR1 .SR2 .SR3 .SR4 .SR5 .SR6 .SR7 .SR8 .SR9
NC Program
Call
95Uscha.fh7

BSR .SR1 BSR .SR2 BSR .SR3 BSR .SR4 BSR .SR5 BSR .SR6 BSR .SR7 BSR .SR8 BSR .SR9

RTS RTS RTS RTS RTS RTS RTS RTS RTS

95USCHA.FH7

Fig. 9-5: Subroutine nesting

Jump to NC Subroutine "JSR"


The JSR command jumps to the NC program number set in the command
parameter and continues program execution in the first NC block of this new
NC program. In contrast to the JMP command, the called NC program returns
to the NC program from which it was called after the RTS command has been
executed. This allows entire NC programs to be used as subroutines.

Syntax JSR <program number[1-99]> ⇒ JSR 15


JSR <variable> ⇒ JSR @25

The jump can go to any desired NC program in the active NC program


package. The reverse vectors are not changed by a jump to a different
NC program.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
9-12 Process and Program Control Commands MTC 200 NC programming instruction

Subroutine Call "BSR"


The BSR command branches to the label set in the command parameter
and continues program execution there.

Syntax BSR <label> ⇒ BSR .UP1


After the return from a subroutine called using the BSR command via the
RTS command, the called program is continued at the next NC block.

Return from NC Subroutine "RTS"


The RTS command marks the end of the subroutine. After the RTS
command is finished, processing returns to the NC program from which
the call was made, and NC block processing is continued in the NC block
following BSR or JSR.

Syntax RTS
• If a subroutine call did not precede the return from a subroutine (BSR,
JSR), the program will be stopped and an error message will be gen-
erated.

.
BSR .SR1
.
.
BSR .SR1
.
.
BSR .SR1
.
.
RET

.SR1
.
96Uruf.fh7

.
RTS

96URUF.FH7

Fig. 9-6: Subroutine call

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Process and Program Control Commands 9-13

9.5 Reverse Vectors


The CNC permits flags to be defined for reverse programs based on vari-
ous program states relating to certain machine positions. These with-
drawal programs (reverse programs) are used to program how the NC
axis must withdraw from the various positions and return to a defined
state. The flags for the reverse programs, which are identified by labels,
are referred to as reverse vectors.
The label ".HOME" was defined as the basic reverse vector for the main
program after the controller is started. This basic reverse vector must be
part of every NC program (or it must be present in program No. 99 or in
the NC cycle memory), and it must mark the beginning of the basic re-
verse program.
After each end of program via RET or BST and each time after the con-
troller is reset in the power-on state, the reverse vector in the main pro-
gram points to the label ".HOME", and all reverse vectors in the subrou-
tines are cleared.

Set Reverse Vector "REV"


The NC block containing the label defined as the command parameter is
defined as the first NC block in the reverse program – in other words, a
reverse program would start processing at this label beginning at the NC
block.

Syntax REV <label> ⇒ REV .HOLE1


Reverse vectors can also be defined within subroutines. Such reverse
vectors in subroutines have the same nesting structure in the reverse
program as in the advance program. Reverse programs from subroutines
must also be terminated by the RTS command.
• When a subroutine is closed, the reverse vectors set up in the sub-
routine are automatically cleared.
• A reverse vector programmed in an NC block will not be activated
until the end of NC block execution.
• The label programmed in conjunction with REV must be located in the
NC program in which the REV command was programmed. The REV
command will not find the label in the global program identified by
number 99 or in the NC cycle memory.

Example: NC program - global homing program

.HOME Basic reverse vector


MRF Reference tool magazine
D0 Cancel D corrections
G40 G47 G53 G90 Home
G74 Z0 F1000 Go to Z axis reference point
G74 X0 Y0 F1500 Go to X and Y axis reference point
T0 BSR .M6 Tool from spindle to magazine
MRY Wait until magazine is in position
RET Program end

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
9-14 Process and Program Control Commands MTC 200 NC programming instruction

Z
Y

X
300/150/50

300/150/-200

10/150/50

Y
Z

N C P rogram S ubroutine
.BO H R RE V .U1
G00 G90 G54 X-200 Y150 Z300 RE V .M1 G0 Z2
X50 RE V .M2 G1 Z-30 F 800
Z10 G0 Z10
BS R .BO H R RTS
X75
BS R .BO H R
...... Reverse Vectors U
M30
.U1G00 Z10 RTS
9 7Re ve rs.fh7

Reverse Vectors M
Global H om ing
.M2G00 Z300
.M1G00 X-200 Y150 Z300 RE T .H O ME
......
if BS R .H O ME instead of RE T RE T
97REVERS.FH7

Fig. 9-7: NC machining using reverse vectors

Note: All reverse vectors (REV) are cleared upon a control reset.
The branch label of the reverse program points to the basic
reverse vector .HOME.
The NC blocks that are defined by the reverse vectors (REV)
are no longer processed. Merely the NC blocks of the basic
reverse vector .HOME are considered.

Example:
; Tool change program
.M6
; install new tool?
.M6_TOL
@0:00=TLD(,0,1,1,0,5,) Read tool no. spindle 1
@0:00=@0:00-T BEQ .M6_T0 Must tool be changed?
; Magazine positioning
BTE .M6_BAC T0 programmed ?
MTP move to programmed location
BRA .M6_TCH
.M6_BAC
MFP Move to free location
; Tool change
.M6_TCH
G40 G47 G53 G90 M9 tool offset OFF, machine zero
point, absolute measure
SE 0:15
G0 Z392 M19 S90 MRY REV .RM6_2 Z axis and spindle in changing pos.
Q1 REV .RM6_3 Close gripper
Q2 REV .RM6_4 Release tool

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Process and Program Control Commands 9-15

TMS REV .RM6_5


Q7 REV .RM6_6 Extend gripper
Q3 REV .RM6_7 Rotate gripper
Q8 REV .RM6_8 Retract gripper
Q6 REV .RM6_9 Spindle clamp
closed
Q5 REV .RM6_10 Open gripper
RE 00:12:00 Transfer: G1 →Spindle,
G0 →Mag.
TSM REV .RM6_12
RE 0:15
BTE .M6_T0 Was T0 programmed?
G48 [ ] RTS
;tool change not required (tool already in spindle) or
;T0 has been programmed
.M6_T0
[ ] RTS
;
; Reverse vectors for tool change
program
.RM6_6 Q3 Turn arm back
.RM6_5 Q8 Retract gripper
.RM6_4 SE 0:12 Transfer. G1 →mag.
G0 →spindle
TSM
.RM6_3 Q6 Clamp closed
.RM6_2 Q5 Open gripper
RTS
.RM6_7 Q8 Retract gripper
.RM6_8 Q6 Clamp closed
.RM6_9 Q5 Open gripper
.RM6_10 RE 0:12
TSM
.RM6_12 BTE .M6_T0
G48 [ ] RTS
RTS

Consistent reverse vector programming permits errors that occur during


program execution to be taken into account.
For example, if a malfunction occurs while processing a Q function, the
machine is returned to a non-critical state using the reverse vectors.
This is no longer possible once the reverse vectors have been cleared by
a control reset.
• Remedy:
In these situations, clearing the reverse vectors by control reset must
be prevented.
This is possible using an event (here: event 0:15) and its nesting in the
PLC program.

A control reset is not possible as long as the event is set (during the exe-
cution of the Q functions). A control reset is possible only after the event
has been reset.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
9-16 Process and Program Control Commands MTC 200 NC programming instruction

Note: If, in exceptional situations, a control reset is possible even after


an event has been set, the event can manually be reset via the
user interface.
This enables the machine manufacturer to distinguish between
authorized and non-authorized end users.
With tool changers, updating tool management must be en-
sured.

9.6 Conditional Branches


Conditional branches are not performed unless the corresponding condi-
tion is met. If this condition is not met, the program continues execution
starting at the following NC block.

Branch if Spindle is Empty "BSE"


The BSE branch command can be used to determine whether or not the
spindle is empty.

Syntax BSE <label> ⇒ BSE .SPLE


st
If the 1 spindle is empty, program execution is continued from the
branch label that is specified in the command parameter.

Branch if T0 Was Set "BTE"


The BTE command can be used to determine whether T0 was last se-
lected, in other words, whether the tool must be removed from the spindle
without loading a new tool into the spindle.

Syntax BTE <branch label> ⇒ BTE .PRT0


If T0 was programmed last, program execution continues at the branch
label defined in the command parameter.

Branch upon Reference "BRF"


The BRF branch command can be used to determine whether the NC
axes in the CNC are located at their reference points.

Syntax BRF <branch label> ⇒ BRF .NORE


If the NC axes are properly referenced, program execution continues at
the branch label defined in the command parameter.

Branch if NC Event is Set "BES"


The BES branch command is used to continue program processing at the
declared branch label if the event defined in the command parameter is
set.

Syntax BES<branch label><process number[0-6]>:<event number[0-31]>


⇒ BES .LABEL 1:15
BER <branch label> <event number[0-31]> ⇒ BER .LABEL 9
• If the symbol "∗ " is declared instead of the event number, a branch to
the addressed branch label is executed if at least one event in the
specified process is set.
• The PLC program can also influence events.
Therefore, please refer to the machine builder's information since the
builder may have used various events for synchronization purposes.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Process and Program Control Commands 9-17

Branch if NC Event is Reset "BER"


The BER branch command is used to continue program processing at the
declared branch label if the event defined in the command parameter is
reset.

Syntax BER<branch label><process number[0-6]>:<event number[0-31]>


⇒ BER.LABEL 1:15
BER <branch label> <event number[0-31]> ⇒ BER .LABEL 9
BER <branch label> <event number[1-31]> ⇒ BER .LABEL 9

• If the symbol "∗ " is declared instead of the event number, processing
branches to the addressed branch label if all the events in the speci-
fied process are reset.
• The PLC program can also influence events.
Therefore, please refer to the machine builder's information since the
builder may have used various events for synchronization purposes.

9.7 Branches Depending on Arithmetic Results


Branches which depend on arithmetic results relate to the results of the
most recently performed arithmetic operation.

Branch If Equal to Zero "BEQ"


Branch command BEQ is used to continue program execution at the
specified branch label if the result of the most recent mathematical opera-
tion was equal to zero.

Syntax BEQ <branch label> ⇒ BEQ .ZERO

Branch If Not Equal to Zero "BNE"


Branch command BNE is used to continue program execution at the
specified branch label if the result of the most recent mathematical opera-
tion was not equal to zero.

Syntax BNE <branch label> ⇒ BNE .NZERO

Branch If Greater Than or Equal to Zero "BPL"


Branch command BPL is used to continue program execution at the
specified label if the result of the most recent mathematical operation was
greater than or equal to zero (PLus).

Syntax BPL <branch label> ⇒ BPL .GZERO

Branch If Less Than Zero "BMI"


Branch command BMI is used to continue program execution at the
specified branch label if the result of the most recent mathematical opera-
tion was less than zero (MInus).

Syntax BMI <branch label> ⇒ BMI .LZERO

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
9-18 Process and Program Control Commands MTC 200 NC programming instruction

Overview Table
@10=A-B @10=B-A
A = B BEQ BEQ
A <> B BNE BNE
A < B BMI ---
A <= B --- BPL
A > B --- BMI
A >= B BPL ---

Note: Due to resolution inaccuracies, there can be malfunctions or


missing functions when BEQ or BNE is used if the arithmetic
results are decimal fractions.

Incorrect program jumps may lead to damage to


workpiece and/or machine.

WARNING

Example:

@10 = 51.8 -50-1.8 BEQ .label (result=0)


does not work!

• Remedy:
Depending on the resolution, e.g. 0.01, convert into an integer expression:
@10=INT((51.8-50-1.8)• 1000) BEQ .label works!

Example: NC program Loop construction


@51=0 Preassign the loop variables
.NEXT Loop beginning marker
@51=@51+1 Increment loop variable
@10=DCD(,1,@51) Read D correction 1 element=@51
@10=@10-25 BEQ .BREAK If D correction 1
element=25, then exit the loop
@10=@51-4 BMI .NEXT Check loop variable if loop conditions are
still given.
[no element of D correction 1
has the value 25] Output message
M00 Acknowledge programmed halt from PLC
BRA .EXIT Branch to the program end
.BREAK Loop exit label
[one element of D correction 1
has the value 25] Output message
M00 Acknowledge programmed halt from PLC
.EXIT End-of-program label
M30 Acknowledge program end from PLC
RET

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Variable Assignments and Arithmetic Functions 10-1

10 Variable Assignments and Arithmetic Functions

10.1 Variables
NC variables are used in an NC program to represent a numerical value.
A value can be assigned to an NC variable by the NC program, PLC pro-
gram or from the user interface; the value of the NC variable can be read
accordingly by these programs or by the user interface.
NC variables are identified
• by the address @,
• by optionally stating the process number followed by a colon, and
• by a 1-3-digit number.

256 variables (0 to 255) are available for each of the 7 processes in the
CNC. In theory, a total of 1792 variables are available in the CNC that can
be used regardless of how many processes are defined.

Note: Variables @100 through @199 and @236 through @248 are
already used in the Bosch Rexroth cycles. If the user employs
these variables, they may be overwritten by those cycles.

Syntax @ <process number[0-6]>:<variable number[0-255]> ⇒ @1:100

If the process number is not assigned, then the variable relates to the
process in which the variable was programmed.

Syntax for assigning a value to a @ <process number[0-6]>:<variable number[0-255]>


variable
=<arithmetic expression> ⇒ @1:100=5*100

Note: The internal data representation of a value employs the "dou-


ble real" format. The value range for entries goes from -
1.0E±300 to +1.0E±300. Only values with a maximum of 7 posi-
tions can be programmed in the NC program ("single real"
format).

Syntax for representing the data .123456789123456


123456789123456
15E+20
90E-10
If the content of an NC variable is to be negated, the NC variable must be
placed within parentheses.

Syntax for negating the contents X=-(@20)


of a variable
@12=-(@19)
-(@57)=@58
@23=X

Note: Irrespective of the display mode (workpiece or machine coor-


dinate system), machine coordinates are always output when
axis values are read.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
10-2 Variable Assignments and Arithmetic Functions MTC 200 NC programming instruction

Variable Assignment
The values of the following addresses can be assigned to the NC vari-
ables of the CNC, or the following values from the CNC addresses can be
written into the NC variables.

Coordinate values of existing The machine coordinates are read into the NC variable when the coordi-
axes nate values are read.
Valid addresses:
X, Y, Z, A, B, C, U, V, W
X[1-3], Y[1-3], Z[1-3], A[1-3], B[1-3], C[1-3], U[1-3], V[1-3], W[1-3]

@10=X Write the X axis position value to the NC variable.


X1=@20 X1 axis to the position stored in the NC variable.

Interpolation parameters Valid addresses: I, J, K


J=@22 Circle center point coordinates of Y axis from the variables.

Radius Valid addresses: R


R=@23 Radius statement via the contents of the NC variable.

Feed rate Only the current feed rate (@xx=F) can be read. However, all F values
can be defined, such as G04 F=@9 for a dwell time.

Valid address: F
@24=F Write active feed rate to the NC variable.
F=@25 F value via the contents of the NC variable.

Spindle speed Valid addresses: S, S[1-3]

@26=S Write current spindle speed to the variable.


S1=@27 Spindle speed information via the contents of the NC
variable.

Angle Only angle of rotation P of the coordinate rotation can be read.


With thread cutting, the starting angle P cannot be read.

Valid address: P
G50 Z30 P=@29 Angle of rotation P via contents of the variables.

Selecting the reference spindle Valid address: SPC


for transformation
@220=SPC Read actual spindle for the transformation
SPC=@221 Define the reference spindle for the transformation.

Selecting the reference spindle Valid address: SPF


for the spindle speed
@22=SPF Read actual reference spindle for programming the speed.
Read spindle speed
SPF=@23 Set reference spindle for programming the speed.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Variable Assignments and Arithmetic Functions 10-3

Selecting the tool spindle Valid address: SPT


@224=SPT Read actual tool spindle.
SPT=@225 Define actual tool spindle.

Acceleration factor Valid address: ACC


ACC=@211 Acceleration factor via the contents of the NC variable.

Tool number Valid address: T


@212=T Write current tool number to the variable.
T=@213 Valid address:

Tool edge number Valid address: E


@214=E Write current tool edge number to the variable.
E=@215 Tool edge selection via the contents of the NC variable.

Effective distances The effective distances RX, RY and RZ cannot be read.


Valid addresses: RX, RY, RZ
RX=@216 Effective radius distance to the X axis via the contents of
the NC variable.

Zero offset table Valid address: O


O=@217 Select zero offset table via the contents of the NC variable.
@218=O Read active zero offset table.

Auxiliary function The active auxiliary function "Q" cannot be read.


Valid address: Q
Q=@219 Output of auxiliary Q function via the contents of
the NC variables.

D correction The current D correction D cannot be read.


Valid address: D
D=@26 Select the D correction via the contents of the NC vari-
able.

G functions Valid address for reading: G(<G code group[1-23]>)


Valid address for writing: G = expression

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
10-4 Variable Assignments and Arithmetic Functions MTC 200 NC programming instruction

G function G code group Active Meaning


G00, G01, G02, G03 1 modal Interpolation functions
G17 to G22 2 modal Level selection
G40, G41, G42 3 modal Tool path compensation
G52 to G59 4 modal Zero offsets
G15, G16 5 modal Radius/diameter programming
G90, G91 6 modal Measurements
G65, G94, G95 7 modal Feed programming
G96, G97 8 modal Spindle speed programming
G70, G71 9 modal Measurement units
G43, G44 10 modal Transition elements
G61, G62 11 modal Block change
G98, G99 12 modal Speed contour/center line path
G47, G48, G49 13 modal Tool length compensation
G08, G09 14 modal Block transition speed
G06, G07 15 modal Drag error ON/OFF
G04 16 blockwise Dwell time
G33 16 blockwise Thread cutting
G50, G51 16 blockwise Programmed zero offset
G63, G64 16 blockwise Tapping
G74 16 blockwise Homing
G75 G76 16 blockwise Move to positive stop
G77 16 blockwise Repositioning and restarting
G92 16 blockwise Spindle speed limitation
G93 16 blockwise Time programming
G30, G31, G32 17 modal Transformation
G72, G73 18 modal Mirror imaging
G78, G79 19 modal Scaling
G68, G69 20 modal Adaptive depth
G36, G37, G38 21 modal Rotary axis approach logic
G25, G26 22 modal Adaptive feed control
G10, G11 23 Modal Rounding of NC blocks with axis filter
Fig. 10-1: G functions

The blockwise active G functions can be read only in the NC block in


which they were programmed. Otherwise a value of "1" is generated when
the blockwise active G functions are read.
@27=G(4) Write active G function of group 4 to the NC variable.
G=@28 Set a G function via the contents of the NC variable.

M functions The programmable M functions are subdivided into 16 M function groups.


Valid address for reading: M(<M function group[1-16]>)
Valid address for writing: M = expression

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Variable Assignments and Arithmetic Functions 10-5

M function M function group Active Meaning


M000, M001, M002, M030 1 modal Program control commands
M3, M4, M5, M13, M14 2 modal Spindle commands S
M103, M104, M105, M113, M114 2 modal Spindle commands spindle 1
M203, M204, M205, M213, M214 3 modal Spindle commands spindle 2
M303, M304, M305, M313, M314 4 modal Spindle commands spindle 3
M007, M008, M009 5 modal Coolant S
M107, M108, M109 5 modal Coolant S1
M207, M208, M209 6 modal Coolant S2
M307, M308, M309 7 modal Coolant S3
M010, M011 8 modal Clamp & unclamp S
M110, M111 8 modal Clamp & unclamp S1
M210, M211 9 modal Clamp & unclamp S2
M310, M311 10 modal Clamp & unclamp S3
M040, ..., M045 11 modal Gear selection S
M140, ..., M145 11 modal Gear selection S1
M240, ..., M245 12 modal Gear selection S2
M340, ..., M345 13 modal Gear selection S3
M046, M047 14 modal Spindle override
M048, M049 15 modal Feed override
M019, ..., M319, 16 blockwise S positioning & MH-F
Mxxx Machine-specific functions
Fig. 10-2: M functions

The blockwise active M functions can be read only in the NC block in


which they were programmed. Otherwise a value of "1" is generated when
the blockwise active M functions are read.
@29=M(13) Write the active programmed M functions of group (13)
into the variables.
M=@20 Set an M function via the contents of the NC variable.

10.2 Angle Unit for Trigonometric Functions "RAD", "DEG"


The arguments of the trigonometric functions "SIN," "COS," "TAN" and the
results of the inverse functions of these trigonometric functions "ASIN,"
"ACOS," "ATAN" can be stated or calculated in the unit "radians" as a frac-
tion or multiple of the circumference of the unit circle (radius = 1), as well as
in the unit "degrees."

Syntax RAD
DEG
• The unit RAD is the power-on condition and is modally active until the
unit DEG overwrites it. G98 is reset automatically at the end of the
program (RET) or by the BST command.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
10-6 Variable Assignments and Arithmetic Functions MTC 200 NC programming instruction

10.3 Round Distance "RDI"


In the axis filter, an axis positioning windows delimits the maximum
rounding distance RDI (Round distance). The RDI value defines the
maximum distance to the programmed data point for the start of the
rounding process. (Also see the section "Motion blocks – rounding of NC
blocks")
Syntax The following syntax is admissible with the RDI command:
RDI10 ;direct allocation
RDI 10 ;direct allocation, space symbol
RDI=10 ;direct allocation
RDI=@195 ;allocation by variable
RDI=10+@195 ;allocation by formula
@195=RDI ;reading of the currently effective RDI value
The process of rounding block transitions is modally enabled for the cur-
rent and the following blocks by programming the rounding distance RDI
(Round DIstance). It is effective only in motion blocks of G code group 1
(G00, G01, G02, G03). In each case, the transition from the current block
to the next block is rounded.
Rounding is switched off again with the "RDI 0" command.
"RDI=0" is the default state and is saved as active until RDI is overwritten
with another value. RDI is automatically reset to the default state at the
end of the program (RET), using the BST command or control reset.

10.4 Mathematical Expressions


The assignment of an expression is initiated by an equal sign and is ter-
minated by a space or the end-of-line character.
• Within an expression, a space is interpreted as the end of the expres-
sion, which therefore leads to premature termination. The following
text characters then usually result in syntax errors.
Calculation of an expression halts NC block preparation; in other words,
look-ahead interpretation of the subsequent NC blocks is not resumed
until the expression is fully calculated. This means that traverse move-
ments are stopped at the programmed end point and that steps to
achieve smooth block transitions (G06, G08) do not take place.

Expressions are comprised of:


• operands
• operators
• parentheses
• functions.

Examples: expressions

@200=X+SQRT(2)*SQRT(X*X+Z*Z)
F=0.1*PI*800
@201=TAN(@200)
@202=SQRT(@200)+F
@203=@205+@206/@207-50

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Variable Assignments and Arithmetic Functions 10-7

Operands
Operands can be:
• constants,
• system constants,
• variables,
• address letters, and
• functions.

Constants Floating decimal point constants can be comprised of the following ele-
ments:
• sign of the mantissa,
• up to 6 decimal digits,
• decimal point behind the first through sixth decimal digits,
• exponent symbol E,
• sign of the exponent, and
• up to 2 decimal digits for the exponent.

In order for internal floating decimal point calculations to be used, the


decimal point or the exponent sign must be present.

Example: valid floating-decimal-point constants


-0.
+123456.
1E0
-123456E+1
0.1E-00
+100.000E12

The numerical decimal value statement is interpreted as an integer con-


stant, both without the decimal point and without the exponent. Integer
constants can optionally consist of a sign and up to ten decimal digits.

Example: valid integer constants


-0
1
+1234567890

System constants The circle number "PI" (3.14159265...) and the conversion factor from the
inch system to the metric "KI" system (25.4) are available for use as system
constants which are programmed using their symbolic names. Because of
their higher internal accuracy, these constants should always be used.

Operators
The standard symbols for basic mathematical operations can be used as
operators.
+ Addition
− Subtraction
∗ Multiplication
/ Division
% Remainder of an integer division (modulo)
• Division by 0 will cause an error.
• Higher-order operations are implemented by functions.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
10-8 Variable Assignments and Arithmetic Functions MTC 200 NC programming instruction

Parentheses
To nest expressions and circumvent the integrated principle "multiplica-
tion/division before addition/subtraction", partial expressions can be
placed within parentheses. The number of nesting levels is unlimited.

Functions
The CNC provides the following mathematical functions:
ABS Absolute value
INT Integer component
SQRT Square root
SIN Sine
COS Cosine
TAN Tangent
ASIN Arc sine
ACOS Arc cosine
ATAN Arc cotangent
E^ Power to the base "e"
10^ Power to base 10
2^ Power to base 2
LN Logarithm to the base "e"
LG Logarithm to the base 10
LD Logarithm to the base 2
TIME Time in seconds
The mathematical functions enclose their operands in parentheses. The
operands used in functions can also be expressions – in other words, the
functions can be nested.

Absolute value - ABS The absolute value function delivers the positive value of its operand.
x < 0: ABS(x) = x
x = 0: ABS(x) = 0
x > 0: ABS(x) = x
Example:
ABS(-1.23) ⇒ 1.23

Integer - INT The INT function delivers the next smallest integer for the operand.
Example:
INT(1.99) ⇒ 1
INT(1.01) ⇒ 1
INT(-2.99) ⇒ -2
INT(-2.01) ⇒ -2

Square root - SQRT The SQRT function produces the square root of its operand.
Example:
SQRT(2) ⇒ 1.4142…
The SQRT function does not permit any negative operands.

Sine - SIN The operand for the SIN function is interpreted depending on which angle
unit is set (RAD, DEG).
Value range: -1 ⇐SIN(x) ⇒+1

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Variable Assignments and Arithmetic Functions 10-9

Example:
RAD
SIN(PI/6) ⇒ 0.5
DEG
SIN(30) ⇒ 0.5

Cosine - COS The operand for the COS function is interpreted depending on which an-
gle unit is set (RAD, DEG).
Value range: -1 ⇐COS(x) ⇒+1
Example:
RAD
COS(PI/6) ⇒ 0.866…
DEG
COS(30) ⇒ 0.866..

Tangent - TAN The operand for the TAN function is interpreted depending on which an-
gle unit is set (RAD, DEG).
Example
RAD
TAN(PI/4) ⇒ 1
DEG
TAN(45) ⇒ 1
The TAN function is not defined for π/2 and for -π/2.

Arc-sine - ASIN The operand for the ASIN function must be greater than or equal to -1 or
less than or equal to +1.
When the angle unit ”radians” is set:
Value range: -π/2 ⇐ASIN(x) ⇐+π/2
Example:
ASIN(0.5) ⇒ 0.523… = (π/6)
When angle unit "degrees" is set:
Value range: -180 ⇐ASIN(x) ⇐+180
Example:
ASIN(0.5) ⇒ 30

Arc cosine - ACOS When angle unit "degrees" is set:


less than or equal to +1
When angle unit "radians" is set:
Value range: -π/2 ⇐ACOS(x) ⇐+π/2
Example:
ACOS(0.5) ⇒ 1.047.. = (π/3)
When angle unit "degrees" is set:
Value range: -180 ⇐ACOS(x) ⇐+180
Example:
ACOS(0.5) ⇒ 60

Arc tangent - ATAN When the angle unit ”radians” is set:


Value range: -π/2 ⇐ATAN(x) ⇐+π/2

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
10-10 Variable Assignments and Arithmetic Functions MTC 200 NC programming instruction

Example

ATAN(-1) ⇒ -0.785… = (-π/4)


When the angle unit "degrees" is set:
Value range: -180 ⇐ATAN(x) ⇐+180
Example:
ATAN(-1) ⇒ -45

Power to base - E^ Example:


E^(-2.5) ⇒ 0.082...

Power to base 10 - 10^ Example:


10^(3) ⇒ 1000

Power to base 2 - 2^ Example:


2^(8) ⇒ 256

Logarithm to base e - LN The operand for the LN function must be greater than zero.
Example:
LN(10) ⇒ 2.302...

Logarithm to base 10 - LG The operand for the LG function must be greater than zero.
Example:
LG(100) ⇒ 2

Logarithm to base 2 - LD The operand for the LD function must be greater than zero.
Example
LD(8) ⇒ 3

Time in seconds - TIME The TIME function supplies a reference-free time in seconds accurate to
2 milliseconds. This time can be used to determine time differences.

Example
@50=TIME Determine active time
.
.
@60=TIME-@50 Determine time difference

The TIME function does not have an operand.


Time recording starts when the controller is powered up and runs for ap-
prox. 50 days.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Variable Assignments and Arithmetic Functions 10-11

Example: NC program - subroutine programming

100 @200=90

80
R=5
@202=5
60
@201=50
40

20

101Recht.fh7
20 40 60 80 100 120 140 160 180
X
101RECHT.FH7

Fig. 10-3: Rectangle as subroutine

NC program:
T4 BSR .M6 Tool change
G00 G54 G06 G08 X160 Y80 Z10 Start position
G01 Z-10 F1000 Infeed Z axis
G42 X135 Y80 F1500 Establishment of tool path
compensation
@200=90 @201=50 @202=5 @203=1200 Preassign variables
BSR .RE1 Subroutine call
G90 G00 Z10 Z axis to safety distance
G40 G01 X160 Y110 Removal of tool path com-
pensation
T0 BSR .M6 Store tool
RET Program end

.RE1 "Rectangle" subroutine


G01 G91 F=@203 Incremental, set feed
st
X=-(@200) 1 straight line in X
st
G03 X=-(@202) Y=-(@202) J=-(@202) 1 ¼ circle
st
G01 Y=-(@201) 1 straight line in Y
nd
G03 X=@202 Y=-(@202) I=@202 2 ¼ circle
nd
G01 X=@200 2 straight line in X
rd
G03 X=@202 Y=@202 J=@202 3 ¼ circle
nd
G01 Y=@201 2 straight line in Y
th
G03 X=-(@202) Y=@202 I=-(@202) 4 ¼ circle
G01 X=-(@201/50) Traverse X axis until clear
Y=@201/10 Traverse Y axis until clear
RTS End of subroutine

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
10-12 Variable Assignments and Arithmetic Functions MTC 200 NC programming instruction

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Enhanced NC Syntax (NC Control Structures) 11-1

11 Enhanced NC Syntax (NC Control Structures)

11.1 Overview
As of version 19, the NC syntax has been expanded by the following control
structures:
• IF-ELSE
• FOR
• WHILE
• REPEAT-UNTIL
• SWITCH-CASE
• CONTINUE
• BREAK

One instruction can be programmed for each NC block line. In turn, a


control structure can contain an instruction or a block of instructions. A
block of instructions is bracketed by "{" and "}". An NC block according to
DIN 66025 is valid as an instruction.

Example
N0001 IF(@10>X) ;control instruction
N0002 Y100 F100 ;instruction if condition is met
N0003 ELSE
N0004 { ;instruction block if condition is not met
N0005 Y=@10 ;condition
N0006 G04 F100
N0007 }

The NC program itself can now consist of an instruction or a list of in-


structions. A line feed separates the instructions.
The elements block number, enhanced block number, skip NC block,
label, and main block identification can be positioned before control in-
structions.

Note: Writing style in syntax description:


The character sequence "\n" in the syntax description means
that a line feed must occur at this point. The characters them-
selves may not be entered.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
11-2 Enhanced NC Syntax (NC Control Structures) MTC 200 NC programming instruction

11.2 Conditions of the Control Structures


The control instructions are controlled by conditions. A condition consists
of a logical expression.

Example
N0001 FOR(@10=0,@10<100,@11*0.1 )
N0002 X=@10 F100
N0003 ...
The X axis is moved from @10=0 to 100 with an increment of @11*0.1.
The condition of termination can be located in the middle section of the
FOR-instruction: "@10<100"

The following relations may be applied to mathematical expressions:


• < (less than)
• <= (less than or equal to)
• > (greater than)
• >= (greater than or equal to)
• != (not equal to)
• == (equal to)

The result of a relation can therefore be TRUE or FALSE.

The following logical operations may be applied to the relations:


• || (or)
• && (and)
• ! (not)
• == (equal to)
• != (not equal to)

Examples for valid conditions (@10 < @11*10 && @100 != G(1) )
(TLD(,0,1,2,0,5,)==1)
(!(@10<@1 && @12>100))

Note: Assure that no blank character is before the "(" character; other-
wise the bracket expression will be interpreted as a comment.

The priority of the operations is defined by the sequence of the syntax


rules and rises from top to bottom, meaning that the operation "!" is
stronger than the operation "||".

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Enhanced NC Syntax (NC Control Structures) 11-3

11.3 Block Instructions


The block instruction comprises a list of instructions for a single instruction.

Example
N0001 IF(@10<100) ;variable value smaller 100
N0002 { ;block beginning
N0003 Y=-3 ;axis movements
N0004 X=@10 Z=@11
N0005 Y=20
N0006 } ;block end and end of the IF instruction
N0007 G0 X=@100 Z=@101

Syntax description: Block instruction = "{" "\n" {instruction} "}" "\n".

11.4 IF Instruction
The following instruction is performed only if the condition is met. The
ELSE branch is optional and is alternatively performed if the condition is
not met. Nested IF instructions are solved from the inside out.

Note: The maximum boxing depth of IF instructions may not exceed


a number of 15.

Example
st
N0001 IF(@10<100) ;1 IF instruction
nd
N0002 IF(@11>10) ;2 IF instruction
N0003 Y=100
nd
N0004 ELSE ;ELSE of the 2 IF instruction
rd
N0005 IF(@11<100) ;3 IF instruction
N0006 Y=200
rd
N0007 ELSE ;ELSE of the 3 IF instruction
rd nd st
N0008 Y=300 ;End of the 3 ,2 and 1 IF instruction
N0009 X100 Z200

Syntax description: IF instruction = "IF" "(" condition ")" "\n"


Instruction
["ELSE" "\n"
instruction].

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
11-4 Enhanced NC Syntax (NC Control Structures) MTC 200 NC programming instruction

11.5 FOR Instruction


The FOR loop repeats the instruction until the condition for termination is
met. The loop variable is initialized at the beginning of the instruction; on
each loop, it is incremented according to the pitch.

Example
N0001 FOR(@10=0,@10<=100,0.1)
N0002 X=@10 Z=@10*0.25
The positions X 0.0 Z 0.0, X 0.1 Z 0.025, ... ,X 100 Z 25 are fed sequen-
tially.

Syntax description: FOR instruction = "FOR" "(" variable "," condition "," pitch ")" "\n" instruction

11.6 WHILE Instruction


The WHILE instruction repeats the following instruction until the condition
is met.

Example
N0001 WHILE( @10>0 )
N0002 {
N0003 @12=@12+@10 X@12 Y@10
N0004 @10=@10-1
N0005 }
Blocks N0003 and N0004 are repeated until @10=0 is met.

Syntax description: WHILE instruction = "WHILE" "(" condition ")" "\n" instruction.

11.7 REPEAT-UNTIL Instruction


The REPEAT-UNTIL instruction repeats the embedded instructions until
the UNTIL condition is met.

Example
N0001 REPEAT
N0002 ....
N0011 UNTIL(@10>100 || @12==@11 )
The block enclosed by REPEAT-UNTIL is executed at least once and is
repeated until @10>100 or @12=@11.

Note: There must not be any blanks between UNTIL and (condition).
Blanks are reported as format errors during the download.

Syntax description: REPEAT instruction = "REPEAT" "\n"


{ instruction }
"UNTIL" "(" condition ")" "\n".

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Enhanced NC Syntax (NC Control Structures) 11-5

11.8 CONTINUE Instruction


The CONTINUE instruction continues processing with the next loop run.
The loop counter is incremented within the FOR instruction and then the
condition is checked. With the WHILE and UNTIL instructions, processing
continues after checking the condition.
Example
N0000 @100=10
N0001 WHILE( @100 > 0 ) ;Repeat as long as @100>0
N0002 { ;Block beginning
N0003 @100=@100-1 ;Decrement loop counter
N0004 IF( OTD(,,@100,4,0) == 0 ) ;Offset in offset table = 0?
N0007 CONTINUE ;Yes, address next bank
N0010 BSR .CONTOUR ;Machine contour
N0011 } ;End of the WHILE instruction

Syntax description: CONTINUE instruction = "CONTINUE" "\n"

11.9 BREAK Instruction


The BREAK instruction interrupts a loop.
Example
N0001 FOR(@1=0,@1<10,1) ;Repeat from @1=0-@1=9
N0002 {
N0003 BSR .TSTPOS ;Subroutine
N0004 IF(@0==0) ;Termination of the loop
N0005 BREAK ;at @0=0
N0006 BSR .KONTUR
N0007 } ;End of the FOR instruction

Syntax description: BREAK instruction = "BREAK" "\n"

11.10 SWITCH Instruction


The SWITCH instruction permits the programming of a branch/jump dis-
tributor. A branch/jump to a CASE label is performed depending on the
value of the SWITCH expression. Multiple CASE labels may be located
before an instruction block. A branch/jump is performed after an instruc-
tion block and at the end of a SWITCH instruction. If none of the CASE
labels are correct, a branch/jump to the DEFAULT label is performed. If
the DEFAULT label does not exist here, then a branch/jump is performed
to the end of the SWITCH instruction.
Example
N0001 SWITCH(G(17)) ;Transformation active?
N0002 {
N0003 CASE 30: ;G30
N0004 G31 X1 10 Y2 10 F100 ;Activate Transmit
N0005 CASE 31: ;G31
N0006 BSR .KONTUR ;Machine contour
N0007 DEFAULT: ;G32

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
11-6 Enhanced NC Syntax (NC Control Structures) MTC 200 NC programming instruction

11.11 Conditions of the Control Structures


The control instructions are controlled by conditions. A condition consists
of a logical expression.
Example
N0001 FOR(@10=0,@10<100,@11*0.1 )
N0002 X=@10 F100
N0003 ...
The X axis is moved from @10=0 to 100 with an increment of @11*0.1.
The condition of termination can be located in the middle section of the
FOR instruction: "@10<100"

The following relations may be applied to mathematical expressions:


• < (less than)
• <= (less than or equal to)
• > (greater than)
• >= (greater than or equal to)
• != (not equal to)
• == (equal to)

The result of a relation can therefore be TRUE or FALSE.

The following logical operations may be applied to the relations:


• || (or)
• && (and)
• ! (not)
• == (equal to)
• != (not equal to)

Examples for valid conditions (@10 < @11*10 && @100 != G(1) )
(TLD(,0,1,2,0,5,)==1)
(!(@10<@1 && @12>100))

Note: Assure that no blank character is before the "(" character; oth-
erwise the bracket expression will be interpreted as a com-
ment.

The priority of the operations is defined by the sequence of the syntax


rules and rises from top to bottom, meaning that the operation "!" is
stronger than the operation "||".
N0008 G30 C0 F200 ;switch off transformation
N0009 }

Syntax description: SWITCH instruction = "SWITCH" "(" math. expression ")" "\n"
"{" "\n"
{{ "CASE integer number ":" "\n" }
{ instruction }}
[ "DEFAULT" ":" "\n"
instruction ]
}" "\n"

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Enhanced NC Syntax (NC Control Structures) 11-7

11.12 Indexed NC Variables


The Indirect addressing is implemented in order to able to utilize the NC
variables in conjunction with the loop instructions while, for, until as fields.

Syntax description: NC var. = @0-255


| @0-6:0-255
| @[ math. expression ] ;new
| @[ math. expression ]:[ math. expression ]. ;new

Example
N0000 G01 F1000
N0001 FOR(@1=0,@1<10,1)
N0002 X=@[ 2 ]:[ @1 ] Y=@[ 3 ]:[ @1 ]
Polygon points (X,Y)=@2:i ,@3:i are traversed.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
11-8 Enhanced NC Syntax (NC Control Structures) MTC 200 NC programming instruction

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Special NC Functions 12-1

12 Special NC Functions

12.1 APR SERCOS Parameters

Data Exchange with Digital Drives "AXD"


The "AXD" command can be used to read or write the drive data from or
to the NC program for a digital drive which is connected to the CNC by
means of a digital SERCOS interface. The drive datum which is to be
read or written is addressed using the data address defined in the com-
mand parameter.

Syntax AXD(<axis name>:<SERCOS ID number>


AXD(<axis number>:<SERCOS ID number>

The letters X, Y, Z, U, V, W, A, B, C and optionally S with the enhanced


address structure [1-3] can be used as the axis name. The axis number
[1-32] can be specified alternatively. It is essential that these axes also be
parameterized and that they be drives which are connected via the
SERCOS Interface.

SERCOS ID Number
SERCOS ID number <group letter>-<drive parameter set number>-<data block number>

Group letter The group letter differentiates between:


• standard data (S),
defined by the SERCOS standards committee, and
• product data (P),
defined by the drive manufacturer.

The meaning of the SERCOS parameters (group letter S) and their func-
tions are described by the SERCOS committee in the publication
"SERCOS Interface."
The meaning of the SERCOS parameters (group letter P) and their func-
tions are described in the documentation for the SERCOS digital drive.
The minus sign (-) is used as a delimiter character between the individual
parameters.

Parameter set number The parameter set number addresses the desired parameter set of the
drive. The parameter set number can have values from 0 to 7. Bosch
Rexroth drives are equipped with four parameter sets which can be
switched during operation. One of the four parameter sets is always ac-
tive – switching occurs due to a command from the controller. The drive
generally works with the ID numbers of parameter set 0.

Data block number The pertaining drive datum can be addressed via the data block number.
The data block number can range from 0 (also 0000) to 4095.
• The reading or writing of drive data using the "AXD command" should
be programmed in a separate NC block which does not contain any
other NC commands.
• The reading or writing of drive data using the "AXD command" always
takes place at the end of the NC block. In other words, the assign-
ment of a value to an NC variable into which the drive datum was
read cannot be used in the same NC block as the basis for deciding
whether a conditional branch/jump is to be performed.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
12-2 Special NC Functions MTC 200 NC programming instruction

• When drive data are read or written using the "AXD" command, NC
block preprocessing is interrupted. Thus if tool path compensation
(G41, G42) is active, it is considered to be finished. Likewise, "Con-
touring mode (acceleration)" (G08) is no longer possible.
• A read drive datum can be assigned to only one variable, but not to
an address letter. The assigning expression may consist of only the
AXD command. No other operands or operators are permitted.
• When the AXD command is used to write drive data, the assigned
expression can be a formula or a constant.

Note: If drive parameters are to be changed using the AXD com-


mand, we recommend that you first save the drive parameter
sets in case incorrect or critical values are accidentally entered
or programmed during NC programming. NC programs that
contain AXD commands to modify drive parameters should
have an init part, which saves the drive parameters that are to
be changed using AXD to, for example, NC variables or ma-
chine data pages; it resets the values to the original settings
after editing the program or in the homing program.

Example: NC program - AXD command


Activating friction torque compensation allows the compensation for posi-
tion deviations at circle quadrant transitions. In the example shown here,
the active gain factor is increased from 4 to 7.

NC program:
T11 BSR .M6 Tool change SF D10
G00 G90 G54 G07 G08 X199 Y136 Z5 Start position
S5000 M03 Spindle ON
@50=AXD(X:S-0-0104) Read active gain factor for X axis
@51=AXD(Y:S-0-0104) Read active gain factor for Y axis
AXD(X:S-0-0104)=7*1000 New gain factor for the X axis
AXD(Y:S-0-0104)=7*1000 New gain factor for the Y axis
AXD(X:S-0-0155)=70 Friction torque compensation for X
AXD(Y:S-0-0155)=110 Friction torque compensation for Y
G01 Z-5 F1000 Lower cutter into material
G41 X199 Y141 F8000 Start point of circular machining
G03 X180 Y122 I199 J122 Start circle
G01 X180 Y100 Transition element
G02 X180 Y100 I100 J100 Full circle ∅160
G01 X180 Y77 Transition element
G03 X198 Y59 I198 J77 Exit circle
G00 Z5 Cutter to safety distance
AXD(X:S-0-0104)=@50 Old gain factor for the X axis
AXD(Y:S-0-0104)=@51 Old gain factor for the Y axis
AXD(X:S-0-0155)=0 Friction torque compensation
OFF for X
AXD(Y:S-0-0155)=0 Friction torque compensation OFF
for Y
T0 BSR .M6 Tool change
RET Program end

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Special NC Functions 12-3

Oscilloscope Function

404Kreis.fh7
P o s i t i o n Va l u e A x i s Y [ m m ]
PPoossiittiioonn D Deevviiaattiioonn::
Desired
D e s i rD
Desired sPosition
e de Position sValue:
Pi roesdi t iPoonValue:
: ition:
Expansion Factor: 1693.7

Axis Number: 2
A x i s Ty p e : D i g i t a l L i n e a r A x i s
Axis Description: Y
P
PPrrroooccceeessssss::: M
Maaasssttteeerrrr w
M w
wwiiititth
thhh

Axis Number: 1
A x i s Ty p e : D i g i t a l L i n e a r A x i s
Axis Description: X
PProzess:
r o z e s s : MMaster
a s t e r wwith
ith

C i r c le D i a m e t e r 1 6 0 m m
P o s i t i o n Va l u e A x i s X [ m m ]

11-1.FH7

Fig. 12-1: Friction torque compensation in quadrant transitions

Oscilloscope Function

Position Value Axis Y


[mm]

Position Deviation:
Positon Command Value:
Expansion Factor: 1693.7

Position Value Axis X


[mm]

112KREIS.FH7

Fig. 12-2: Circle sector for recording position variance

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
12-4 Special NC Functions MTC 200 NC programming instruction

12.2 Read/Write Zero Offset (ZO) Data from the NC Program


"OTD"
The OTD command (Offset Table Data) can be used to read and write
the data in the zero offset table and the zero offsets which have been
activated in the NC program from the NC program.
Syntax

M P O V A
OTD([1/2],[0..6],[0..9],[0..9],[1..10])
Axis
Offset
Zero Offset Table
Process
NC Memory

113otd.FH7

Fig. 12-3: OTD command syntax

Designation Symbol Value CNC Meaning


range
NC memory M 1/2 MTC200 1: NC memory A or
(optional) 2: NC memory B
If the parameter is not declared, the active NC memory is
addressed.
Process P 0-6 MTC200 If no process number is specified, the current process is
(optional) addressed.
Zero offset table O 0-9 MTC200 If the parameter is not declared, the active zero offset table
(optional) is addressed.
Offset V 0-9 MTC200 0= active offset
(optional) TRANS200 1= value of G50/G51 offset
2= value of G52/G51 offset
3= general offset
4= G54 value
5= G55 value
6= G56 value
7= G57 value
8= G58 value
9= G59 value
If the parameter is not defined, the active zero offset table
is addressed.
Axis A 1-10 MTC200 1= Value of axis X
TRANS200 2= Value of axis Y
3= Value of axis Z
4= Value of axis U
5= Value of axis V
6= Value of axis W
7= Value of axis A
8= Value of axis B
9= Value of axis C
10 = Value of the turning angle
The axis parameter must be defined.
The axis letter correlates with the axis meaning!

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Special NC Functions 12-5

General requirements for the A variable can be inserted instead of the constant.
MTD command
• An arithmetic expression instead of a constant or variable is not per-
mitted.
• The optional parameters need not be specified.
• The commas that are used for delimiting the parameters must always
be set.
Command OTD can not be used to write to the zero offset values for
G50/G51, G52 and to the active zero offset value.

Example: NC program - reading ZO data


@20=OTD(,,,,1) Read total active X axis zero offset
.
X=OTD(1,0,2,4,1) Traverse X axis to the position which is located in
the ZO table in NC memory A for process 0 of the
nd
2 zero offset table for G54
.
@70=G(4) Read G function of zero offset
@70=@70-50 Prepare value for the OTD command
.
@20=OTD(,,,@70,1) Read active X axis zero offset for the ZO entry
corresponding to the active G function (G52 - G59)

Example: NC program - writing ZO data


OTD(,,,4,1)=INT(X) Assign the result of the specified calcula-
tion to the X axis entry for the offset cor-
responding to G54.
.
OTD(,,,4,1)=@20+OTD(,,,,1) Calculate the new X-axis zero offset
value corresponding to G54 from the
contents of the variable and the active X-
axis zero offset.

Note: The read zero point data are machine coordinates.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
12-6 Special NC Functions MTC 200 NC programming instruction

12.3 Access to Tool Data from NC Program "TLD"


The TLD command (Tool Data) can be used to read all the tool data in
the tool list from the NC program and to write them; however, some re-
strictions apply to writing.

Syntax The individual data elements are addressed by means of codes. De-
pending on both types of addressing ...
• Addressing via location and magazine (A=0)
• Addressing via tool number and tool duplo number (A=1) ...
both variants of TLD command are possible:

P A S/T L/D E D S
TLD([0..6], [0], [0..3] ,[1...999],[0..9],[1..35],[1..32])
TLD([0..6],[1],[1..9999999],[1...999],[0..9],[1..35],[1..32])
Status
Data element
Edge
Location / Index no.

Storage [0..3] /tool number


Addressing
Process

57tld.FH7

Fig. 12-4: Syntax of the TLD command

Value range and meaning of The two following figures illustrate the parameters of the TLD command in
parameters detail:
V23_20030319
TLD addressing via location and magazine type

Designation Symbol Value range / meaning


Process P 0-6 Process number
Addressing A 0 Addressing via location and magazine type
0 1 2 3 7
Magazine/ Spindle Gripper Tool Address active tool
Storage type ST turret change
position
Location L 1 - 999 1-4 1-4 1-4 0

Tool edge E 0 1-9


Basic tool data Tool edge data

Data element DE 9 32 -
3-8 Tool status 10 - 31 Group 1 2 3 - 40
status
1 - 32 1 - 16 1 - 16
Status S --- Tool status --- Group --- Tool edge status bit ---
bit status bit

Group No. G Not relevant Not relevant


Group duplo
GD Not relevant Not relevant
number

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Special NC Functions 12-7

V23_20030319
TLD addressing via tool and duplo number

Designation Symbol Value range / meaning


Process P 0-6 Process number
Addressing A 1 Addressing via tool and tool duplo number
Tool number T 1 - 9999999 Tool number
(T)
Tool duplo No. WD 1 - 9999 Tool duplo number

Tool edge E 0 1-9


Basic tool data Tool edge data

Data element 9 32 -
DE
3-8 10 - 31 Group 1 2 3 - 40
Tool status
status
1 - 32 1 - 16 1 - 16
Status S --- Tool status --- Group --- ---
bit status bit Tool edge status bit

0 - 99 Group association of the tool


Group No. G no information: active group

0 - 99 Group duplo association of the tool


Group duplo
GD no information: duplo No. of the active group
number
TLD_V23_20030319.xls

All data present in the tool list can be read. The individual data elements
are addressed by means of codes. The identifiers of the individual data
elements are represented in the following tables:
• Basic tool data
• Tool status bit from basic tool data element 09
• Group status bit from basic tool data element 32
• Tool edge data
• Tool edge status bit from tool edge data element 02

The identifiers of the individual data elements (DEL) and status bits (S)
are represented in the following tables.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
12-8 Special NC Functions MTC 200 NC programming instruction

• Data of tool list (basic tool data) for the TLD command
V23_20030319
Basic tool data (per tool)

DATA TYPE
in the PLC

UNIT
DESIGNATION VALUE RANGE DE OPT. SL TL

Tool identification

Index address hexadecimal double word with 32 bits - 01 X X


ID (tool name) up to 28 characters* STRG28 - 02 X
Storage 0-2 - 03 X
Location 0 - 999 - 04 X
Tool number 1 - 9999999 DINT - 05 X X
Tool duplo number 1 - 9999 INT - 06 X
Correction type 1-5 USINT - 07 X X
Number of tool edges 1-9 USINT - 08 X X
Tool status 0/1 (32 status bits) USINT - 09 X
Location data

Free half-locations 0-4 USINT - 10 X


Old pocket 1 - 999 INT - 11 X
Storage location of next setup tool 0-2 INT - 12 X
Loc. of next replacement tool 1 - 999 INT - 13 X
Stor. of prev. rep. tool 0-2 INT - 14 X
Loc. of prev. rep. tool 1 - 999 INT - 15 X
Units

Time unit 0/1 (0: min, 1: cycl.) USINT - 16 X


Unit of length 0/1 (0: mm, 1: inch) USINT - 17 X X
Technology data

Tool code 0- 9 USINT - 18 X X


Representation type 0 - 65535 INT - 19 X X
User data

User data 1 REAL 20 A00.061 X


User data 2 REAL 21 A00.062 X
User data 3 REAL 22 A00.063 X
User data 4 REAL 23 A00.064 X
any

+/- 1.2 * 10-38 - +/- 3.4 * 10+38


User data 5 REAL 24 A00.065 X
and 0 ( 9 significant digits)
User data 6 REAL 25 A00.066 X
User data 7 REAL 26 A00.067 X
User data 8 REAL 27 A00.068 X
User data 9 REAL 28 A00.069 X
Group data

29
Group number 0 - 99 BYTE - 30 X
Group duplo number 0 - 99 BYTE - 31 X
Group status 0/1 (16 status bits) WORD - 32 X

Comment up to 5 x 76 alphanumeric characters - 99 A00.057 X


WGD_all_V23_20030319.xls
* ASCII character set 32-126, at least 1 character >32
Data element 99 ”Comment” is not loaded in the control.
DE - Data element SL - Setup list-specific datum
R.TL - Replacement tool TL - Tool list-specific datum
STRG28 - STRING28 OPT - Optional datum

Fig. 12-5: Data of tool list (basic tool data) for the TLD command

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Special NC Functions 12-9

• Data of tool list (tool edge data) for the TLD command
Tool edge data (per tool edge) V22_20030317

DATA TYPE in

OPT.
PLC
DESIGNATION VALUE RANGE UNIT

DE

SL

TL
Tool edge identification

Tool edge position 0–8 USINT 01 X X


Tool edge status 0; 1 (16 status bits) WORD 02 X
Tool life data

Remaining tool life -99.9 - +100.00 REAL 03 A00.059 X


%
Warning limit +0.1 - +100.00 REAL 04 A00.059 X
Max. utilization time 0 - 9999999 (0: tool life recording switched off) REAL min. or 05 A00.059 X
cycles
Time used 0 - 9999.999 REAL 06 A00.059 X
Geometry data

Length L1 DINT 07 X
Length L2 DINT 08 X
Length L3 DINT 09 X
Radius R -99999.9999 - +99999.9999 DINT mm 10 X
Wear L1 DINT 11 A00.055 X
or or
Wear L2 DINT 12 A00.055 X
Wear L3 -9999.99999 - +9999.99999 DINT inches 13 A00.055 X
Wear R DINT 14 A00.055 X
Offset L1 DINT 15 A00.056 X
Offset L2 DINT 16 A00.056 X
Offset L3 DINT 17 A00.056 X
Offset R DINT 18 A00.056 X
Geometry limit values

L1_min DINT 19 A00.060 X


L1_max -99999.9999 - +99999.9999 DINT mm 20 A00.060 X
L2_min DINT 21 A00.060 X
or or
L2_max DINT 22 A00.060 X
L3_min -9999.99999 - +9999.99999 DINT inches 23 A00.060 X
L3_max DINT 24 A00.060 X
R_min DINT 25 A00.060 X
R_max DINT 26 A00.060 X
Wear factors

Wear factor L1 DINT 27 A00.058 X


-99999.9999 - +99999.9999 mm/min or
Wear factor L2 DINT 28 A00.058 X
or inch/min or
Wear factor L3 -9999.99999 - +9999.99999 DINT cycles 29 A00.058 X
Wear factor R DINT 30 A00.058 X
User data

User data 1 REAL any 31 A00.070 X


User data 2 REAL any 32 A00.071 X
+/- 1.2 * 10-38 - +/- 3.4 * 10+38
User data 3 and REAL any 33 A00.072 X
0 (9 significant digits)
User data 4 REAL any 34 A00.073 X
User data 5 REAL any 35 A00.074 X
User data 6 DINT any 36 A00.092 X
User data 7 DINT any 37 A00.093 X
-99999.9999 - +99999.9999
User data 8 or DINT any 38 A00.094 X
-9999.99999 - +9999.99999
User data 9 DINT any 39 A00.095 X
User data 10 DINT any 40 A00.096 X
DE - Data element SL - Setup list-specific datum SD_all_V22_20030317.xls
OPT - Optional datum TL - Tool list-specific datum
Fig. 12-6: Data of tool list (tool edge data) for the TLD command

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
12-10 Special NC Functions MTC 200 NC programming instruction

• Tool status bits for the TLD command


Tool status bits 1 -16 from basic tool data element 09
Write
Type
access

Symbol

Value

Word
Byte
Group

Bit
Group name Comment
information

ASP
TM

OP

SL

TL

LL
Tool not ! 1
available 1 X X X Tool is missing
Tool available 0
Presence
Tool is not ? 1
required Tool not required for
2
processing
Tool required 0
Correction type t 1
Error: wrong Correction type does not
3 X X X
correction type Correction type 0 accord with the requirements
not wrong
Incorrect number e 1

LOW byte 0 - 7
Error: of tool edges Number of cutters does not
4 X X X
tool edge number Correct number 0 accord with the requirements
of tool edges
Tool edge(s) f 1
incorrect Tool edge data do not comply
Error: tool edge 5
Tool edge(s) not 0 with requirements
incorrect
Tool code $ 1
incorrect Does not accord with the
Error: tool code 6
Tool code 0 requirements
correct

Reserved for extensions 7

Reserved for extensions 8


LOW

Location locked B 1 ASP/OP: Location is damaged,


Location locking Location not 0 9 X X X X X for example.
locked TM: Tool is entered

Upper half-
Reserved for extensions 10
location locking

Lower half-
Reserved for extensions 11
location locking

Upper half- ) 1
location
reserved Reserved for temp. moved
Upper half-location reservation 12 X X X X
Upper half- 0 tools
location not
reserved
byte

Lower half- ( 1
location
reserved Reserved for temp. moved
Lower half-location reservation 13 X X X X
Lower half- 0 tools
location not
reserved

Upper half-
Reserved for extensions 14
location locking

Lower half-
Reserved for extensions 15
location locking
Location + 1
assigned
Location assignment 16 X X X There is a tool at this location
Location not 0
assigned
WSB_all_V22_20030918.xls
TM - Tool management SL - Setup list-specific status bit
OP - Operator TL - Tool list-specific status bit
ASP - Application-specific programs in PLC or NC
LL - Location-specific status bit
Fig. 12-7: Tool status bits 1-16 for the TLD command

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Special NC Functions 12-11

Tool status bits 17 -32 from basic tool data element 09


Write
Type
access

Symbol
Group name Group information Comment

Value

Word
Byte

OP
TM

AS
Bit

SL

TL

LL
P
Tool is worn out d 1 The remaining lifetime of the
17 X X
Tool is not worn out 0 tool has elapsed (replace)
Wear state
Warning limit is reached w 1 The remaining lifetime is about
18 X X
Warning limit not reached 0 to expire (replace)

Machining tool p 1 There is a processing tool for


19 X X
No machining tool 0 every alternate tool group
Name of alternate
Replacement tool s 1 A replacement tool is a tool still

LOW byte 0 - 7
20 X X to be used, not a processing
No replacement tool 0 tool

Tool with fixed location coding C 1 The tool may only be changed
Tool coding 21 X X X X
Tool without fixed location coding 0 into the predefined tool location

Tool locked L 1
Tool block 22 X X X Tool must not be used
Tool is not locked 0

Tool broken D 1 Tool is damaged: e.g. broken


Tool breakage 23 X X X
Tool is not broken 0 tool edge

Reserved for extension 24


wo r d
User tool status bit 1 1
User tool status 1 25 X X X Any meaning
A00.075 0

User tool status bit 2 1


User tool status 2 26 X X X Any meaning
A00.076 0

User tool status bit 3 1


User tool status 3 27 X X X Any meaning
A00.077 0

User tool status bit 4 1


User tool status 4 28 X X X Any meaning
A00.078 0
byte

User tool status bit 5 1


User tool status 5 29 X X X Any meaning
A00.079 0

User tool status bit 6 1


User tool status 6 30 X X X Any meaning
A00.080 0

User tool status bit 7 1


User tool status 7 31 X X X Any meaning
A00.081 0

User tool status bit 8 1


User tool status 8 32 X X X Any meaning
A00.082 0

WSB_all_V22_20030918.xls
TM - Tool management SL - Setup list-specific status bit
OP - Operator TL - Tool list-specific status bit
ASP - Application-specific programs in PLC or NC T Tool
LL - Location-specific status bit
Fig. 12-8: Tool status bits 17-32 for the TLD command

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
12-12 Special NC Functions MTC 200 NC programming instruction

• Tool edge status bits for the TLD command


Tool edge status bit from tool edge data element 02
Write
Type
access

Symbol
Group name Group information Comment

Value

ASP
OP
TM
Bit

SL

TL
Incorrect tool edge orientation o 1 Tool edge data do not correspond to the
Incorrect tool edge orientation 1 X X
Tool edge orientation is not incorrect 0 definition

L1 faulty 1 1 Tool edge data do not correspond to the


L1 faulty 2 X X
L1 not incorrect 0 definition

L2 faulty 2 1 Tool edge data do not correspond to the


L2 faulty 3 X X
L2 not incorrect 0 definition

L3 faulty 3 1 Tool edge data do not correspond to the


L3 faulty 4 X X
L3 not incorrect 0 definition

R incorrect r 1 Tool edge data do not correspond to the


R incorrect 5 X X
R not incorrect 0 definition

Reserved for extensions 6

Reserved for extensions 7

Reserved for extensions 8

Tool edge worn out d 1 The tool edge can no longer be used
9 X X
Tool not worn out 0 (replace)
Wear state
Warning limit is reached w 1 The remaining tool life of the tool edge is
10 X X
Warning limit not reached 0 near its end (replace)

Reserved for extensions 11

Reserved for extensions 12

User tool edge status bit 1 1


User tool edge status 1 13 X X X Any meaning
A00.083 0

User tool edge status bit 2 1


User tool edge status 2 14 X X X Any meaning
A00.084 0
any

User tool edge status bit 3 1


User tool edge status 3 15 X X X Any meaning
A00.085 0

User tool edge status bit 4 1


User tool edge status 4 16 X X X Any meaning
A00.086 0
SSB_all_V22_20030918.xls
TM - Tool management TL - Tool list-specific status bit
OP - Operator SL - Setup list-specific status bit
ASP - Application-specific programs in PLC or NC

Fig. 12-9: Tool edge status bits for the TLD command

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Special NC Functions 12-13

• Tool group status bits for the TLD command


V23_20021112
Tool groups: Group status (data element 32)

Write access Type

Value
Sym-
bol

Bit
Status Status bit Comment
TM OP ASP GL

Presence Group not available ! 1 1 X X Tool in this group is


missing
Group exists 0
Group is not required ? 1 2 X X No tool in this
group is required
Group is required 0
Group status Group disabled L 1 3 X X X User-
programmable
Group not disabled 0
Wear state Group worn d 1 4 X X At least one alter-
nate tool sequence
Group not worn 0 of the group is
worn.
Warning limit is reached w 1 5 X X At least one alter-
nate tool sequence
Warning limit not reached 0 of the group has
reached the warn-
ing limit.
Name of alternate Machining group p 1 6 X X Group is machining
group
Not a machining group 0
Spare group s 1 7 X X Group is alternate
group
Not a spare group 0
Reserved for extension 8

User group status 1 User group status bit 1 any 1 9 X X X Any meaning
0
User group status 2 User group status bit 2 any 1 10 X X X Any meaning
0
User group status 3 User group status bit 3 any 1 11 X X X Any meaning
0
User group status 4 User group status bit 4 any 1 12 X X X Any meaning
0
User group status 5 User group status bit 5 any 1 13 X X X Any meaning
0
User group status 6 User group status bit 6 any 1 14 X X X Any meaning
0
User group status 7 User group status bit 7 any 1 15 X X X Any meaning
0
User group status 8 User group status bit 8 any 1 16 X X X Any meaning
0
WZG_all_V23_20021112.xls
TM - Tool management SL - Setup list-specific status bit
OP - Operator TL - Tool list-specific status bit
ASP - Application-spec. programs on the PLC or NC OPT - Optional datum
GL - Tool group list-specific status bit
LL - Location-specific status bit

Fig. 12-10: Tool group status bits for the TLD command

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
12-14 Special NC Functions MTC 200 NC programming instruction

General requirements for the • A variable can be inserted instead of constants.


TLD command
• An arithmetic expression instead of a constant or variable is not per-
mitted.
• The optional parameters need not be specified.
• The commas that are used for delimiting the parameters must always
be set.

Optional parameters for the TLD • The CNC inserts the current process if a process [0-6] is not speci-
command fied.
• If the parameter address [0/1] is not specified, the CNC inserts a va-
lue of 0 and interprets the two subsequent parameters as storage unit
and pocket.
• If the duplo number [1-9999] is not specified, the CNC inserts the
duplo number of the related machining tool.
• If the tool edge [0-9] is not specified, the CNC inserts a value of 0,
thus accessing the basic tool data.
• The parameter status [1-32] is to be specified only if a tool status bit ,
a tool edge status bit or a group status bit is accessed.
• If the group number [0..99] is not specified, the CNC inserts the
number of the enabled group.
• If the group duplo number [0..99] is not specified, the CNC inserts the
duplo number of the enabled group.

General verifications for the TLD The validity of the programmed parameter values can be checked only
command when the command is executed (i.e. at the runtime of the NC program). If
one of the parameters is incorrect or invalid, the CNC initiates an immedi-
ate stop and issues the error message:

Parameter [No. Of the faulty parameter]


during data access command faulty!

Limitations of writing with the • You cannot write to setup list-specific data elements.
TLD command
• You may not write to any tool, tool edge or group status bit that is
allocated to tool management.
• You cannot write to a pocket, storage unit or tool number data ele-
ment.
• If one of these conditions is not observed when a data element is
written, the CNC initiates an immediate stop and issues the error
message:

Invalid access to a data element!

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Special NC Functions 12-15

Examples:
Reading with the TLD command
Example:
The tool number of the tool in spindle 2 is assigned to a variable.

@55 = TLD ( , 0, 1, 2, 0, 5, )

Symbol Designation

S Status

5 →Tool number
DE Data element

0 →Basic tool data


E Tool edge

2 →2
L Location
→Spindle 2
1 →Spindle
SA Storage type

0 →Addressing via location and


A Addressing magazine

Empty →current process


P Process

TLD_Beispiel_1_lesen_V22_20021114.xls

Example:
The duplo number of tool 1 is assigned to a variable.

@200 = TLD ( , 1, 1, , 0, 6, )

Symbol Designation

S Status

DE Data element 6 →Duplo number

E Tool edge 0 →Basic tool data

Empty →duplo number of the


D Duplo number corresponding processing
tool
1 →Tool 1
T Tool No.

1 →Addressing via tool and duplo


A Addressing number

Empty →current process


P Process

TLD_Beispiel_2_lesen_V22_20021114.xls

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
12-16 Special NC Functions MTC 200 NC programming instruction

Interrogation whether a tool change is required

@ 0: 0 = TLD ( , 0, 1, 1, 0, 5, ) Reads the tool number of the first spindle and stores
it in variable 0 of the process.
@ 0: 0 = @ 0: 0 - T BEQ .M6_T0 Interrogation whether a tool change is required
TLD_Beispiel_3_lesen_V22_20021114.xls

The sum of radius, wear and offset is written into a variable

@152 = TLD ( , 1, 9, , 1, 10, ) + TLD ( , 1, 9, , 1, 14, ) + TLD ( , 1, 9, , 1, 18, )


TLD_Beispiel_4_lesen_V22_20021114.xls

Writing with the TLD command


Example:
The duplo number of tool 1 is set to 5.

TLD ( , 1, 1, , 0, 6, ) = 5

Symbol Designation

S Status

DE Data element 6 →Duplo number

E Tool edge 0 →Basic tool data

Empty →duplo number of the corre-


D Duplo number
sponding processing tool

T Tool No. 1 →Tool 1

1 →Addressing via tool and duplo number


A Addressing

P Process Empty →current process

TLD_Beispiel_1_schreiben_V22_20021114.xls

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Special NC Functions 12-17

Example:
The duplo number of tool 1 is set to 6

TLD ( , 1, 1, , 0, 6, ) = 3+1+2

Symbol Designation

S Status

DE Data element 6 →Duplo number

E Tool edge 0 →Basic tool data

D Duplo number Empty →duplo number of the corre-


sponding processing tool

T Tool No. 1 →Tool 1

A Addressing 1 →Addressing via tool and duplo number

P Process Empty →current process

TLD_Beispiel_2_schreiben_V22_20021114.xls

Example:
The last used or preselected tool is disabled

@55 = T The number or current tool is saved in a


variable
TLD ( 3, 1, @55, , 0, 9, 22 ) = 1

Symbol Designation

S Status 22 →Tool block: Value 1


→ Tool disabled

DE Data element 9 →Tool status bits

E Tool edge 0 →Basic tool data

D Duplo number Empty →Duplo number of the


corresponding processing
tool
T Tool No. @55 →Tool number = Content
of variable @55

A Addressing 1 →Addressing via tool and


duplo number

P Process 3 →Process 3

TLD_Beispiel_3_schreiben_V22_20021114.xls

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
12-18 Special NC Functions MTC 200 NC programming instruction

Example:
Duplo group 1 of tool group 5 is disabled

TLD ( 3, 1, , , , 32, 3, 5, 1 ) = 1

Symbol Designation

GD Group duplo 1 →Duplo group 1


number

G Group number 5 →Tool group 5

S Status 3 →Group status:


Value 1
→ Group disabled
DE Data element 32 →Group status

E Tool edge Empty

TD Tool duplo No. Empty

T Tool No. Empty

A Addressing 1 →Addressing via tool


and duplo number

P Process 3 →Process 3

TLD_Beispiel_4_schreiben_20030617.xls

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Special NC Functions 12-19

12.4 Read/Write D Corrections from the NC Program "DCD"


With the DCD command, D corrections can be read and written from the
NC program.
Syntax

P S W
DCD([0..6],[1..99],[1..4])

Value
Memory
Process

115dcd.FH7

Fig. 12-11: DCD command syntax

Designation Symbol Declaration CNC Meaning


range
Process P 0-6 MTC200 If no process number is specified, the current process is
addressed.
Storage S 1-99, 1-30 MTC200 If the parameter is not specified, the active memory is
TRANS200 addressed.
Value W 1-4 MTC200 1 = Value for length correction L1
TRANS200
2 = Value for length correction L2
3 = Value for length correction L3
4 = Value for radius correction R

General requirements for the • A variable can be inserted instead of a constant.


DCD command
• An arithmetic expression instead of a constant or variable is not per-
mitted.
• The optional parameters do not need to be specified.
• The commas that are used for delimiting the parameters must always
be set.

Verifications during access The declared parameters must lie within the given value range. The CNC
checks their validity first during operation. The CNC interrupts program
execution and issues an error message if a declared parameter lies out-
side of the valid value range.

Example:

@22=DCD(,3,4) Variable 22 contains radius compensation value R


of D magazine 3.
DCD(1,2,1)=Z-10 Value "Z-10" is written to length compensation
value L1 of D magazine 2 of process 1.
DCD(,,3)=DCD(,,3)+1 The value L3 of the active D magazine and of the
active process is increased by 1.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
12-20 Special NC Functions MTC 200 NC programming instruction

12.5 Read/Write Machine Data

Purpose of Machine Data


Objectives The variable machine data functions serve
• as variable machine parameters (control machine data) for specific
control functions, such as setup register, drag and Gantry axis or
main spindle synchronization,
• as secured data (OEM machine data) to, for example, manage the
machine options or to store measurement data,
• as working memory to which the machine builder saves structured
data (OEM machine data), e.g. to implement palette management or
to store axis positions, or
• to process large data pools (user machine data), e.g. to store geo-
metric data and tolerances to produce parts.

Required data structures The majority of the data required for the controller by the machine builder
and end user can be shown in the following forms:
• single structure,
• one- or two-dimensional field or
• one- or two-dimensional field on a structure.

Modifiable Machine Data

Controller Machine Data OEM Machine Data User Machine Data

Page: 001-099 Page: 100-199 Page: 200-299

Page 001: Page Label Page 100: Page Label Page 200: Page Label
Serial Index 1 Serial Index 1 Serial Index 1

L Limit 1 Limit 1 Limit 1 Limit 1 L Herst1 Herst1 Herst1 Herst1 L Anw. 1 Anw. 1 Anw. 1 Anw. 1
a Limit 2 Limit 2 Limit 2 Limit 2 a Herst2 Herst2 Herst2 Herst2 a Anw. 2 Anw. 2 Anw. 2 Anw. 2
u Limit 3 Limit 3 Limit 3 Limit 3 u Herst3 Herst3 Herst3 Herst3 u Anw. 3 Anw. 3 Anw. 3 Anw. 3
114Masch.fh7

f Limit 4 Limit 4 Limit 4 Limit 4 f Herst4 Herst4 Herst4 Herst4 f Anw. 4 Anw. 4 Anw. 4 Anw. 4
i Limit 1 Limit 1 Limit 1 Limit 1 i Herst1 Herst1 Herst1 Herst1 i
n n Anw. 1 Anw. 1 Anw. 1 Anw. 1
Limit 2 Limit 2 Limit 2 Limit 2 Herst2 Herst2 Herst2 Herst2 n Anw. 2 Anw. 2 Anw. 2 Anw. 2
d Limit 3 Limit 3 Limit 3 Limit 3 d Herst3 Herst3 Herst3 Herst3 d
e e Anw. 3 Anw. 3 Anw. 3 Anw. 3
Limit 4 Limit 4 Limit 4 Limit 4 Herst4 Herst4 Herst4 Herst4 e Anw. 4 Anw. 4 Anw. 4 Anw. 4
x x x
Limit 1 Limit 1 Limit 1 Limit 1 Herst1 Herst1 Herst1 Herst1 Anw. 1 Anw. 1 Anw. 1 Anw. 1
2 Limit 2 Limit 2 Limit 2 Limit 2 Herst2 Herst2 Herst2 Herst2 Anw. 2 Anw. 2 Anw. 2 Anw. 2
2 Herst3 Herst3 Herst3 Herst3 2
Limit 3 Limit 3 Limit 3 Limit 3 Anw. 3 Anw. 3 Anw. 3 Anw. 3
Limit 4 Limit 4 Limit 4 Limit 4 Herst4 Herst4 Herst4 Herst4 Anw. 4 Anw. 4 Anw. 4 Anw. 4
Limit 1 Limit 1 Limit 1 Limit 1 Herst1 Herst1 Herst1 Herst1 Anw. 1 Anw. 1 Anw. 1 Anw. 1
Limit 2 Limit 2 Limit 2 Limit 2 Herst2 Herst2 Herst2 Herst2 Anw. 2 Anw. 2 Anw. 2 Anw. 2
Limit 3 Limit 3 Limit 3 Limit 3 Herst3 Herst3 Herst3 Herst3 Anw. 3 Anw. 3 Anw. 3 Anw. 3
Limit 4 Limit 4 Limit 4 Limit 4 Herst4 Herst4 Herst4 Herst4 Anw. 4 Anw. 4 Anw. 4 Anw. 4

114Masch.FH7

Fig. 12-12: General structure of machine data

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Special NC Functions 12-21

Read/Write Machine Data Elements "MTD"


MTD command Using the MTD command (Machine Table Data), individual elements of
the machine data in the NC program can be read and written, but only if
write access is permitted for the individual elements.
Syntax

PG L1 L2 EL
MTD([1..299],[-1000..+1000],[-1000..+1000],[1..1000])

Element No.
Dimension 2

Dimension 1
Page No.

116mtd.FH7

Fig. 12-13: MTD command syntax

Designation Symbol Value range Meaning


Page number PG 1-299 001 - 099 Pages of the control machine data
100 - 199 Pages of OEM machine data
200 - 299 Pages of user machine data
Control variable 1 L1 min. value min. value: first value of the structure definition (≥ -1000)
- max. value second value of the structure definition (≤+1000)
(largest value – lowest value ≤1000)
Control variable 2 L2 min. value min. value: first value of the structure definition (≥ -1000)
- max. value second value of the structure definition (≤+1000)
(largest value – lowest value ≤1000)
Element No. SL 1 - max. value max. value ≤1000

General requirements for the • The individual numbers are to be separated by a comma.
MTD command
• A variable can be inserted instead of constants.
• An arithmetic expression instead of a constant or variable is not per-
mitted.
• All parameters listed above must always be indicated.

Verifications during access The declared parameters must lie within the given value range. The NC
checks their validity first during operation. The NC interrupts program execu-
tion and initiates an error message if a declared parameter lies outside of the
valid value range. The NC reacts in the same way if the user write-accesses a
write-protected data element from the NC program. The NC automatically
limits the value to the lowest or largest value of the data element if the user
declares a value outside of the valid value range for a data element.

Detailed description Further and supplementary information about the functions and the han-
dling of machine data can be found in the description "Machine data",
folder 1.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
12-22 Special NC Functions MTC 200 NC programming instruction

Example: Reading machine data

@200=MTD(250,1,2,4) Read machine data element


Page=250, L1=1, L2=2, EL=4
X=MTD(260,1,,5) Traverse X-axis to the position which is
located in the machine data element; L2
is not present
@50=MTD(270,,3,6) L1 is a PROCESS type. The elements of
the current process are read. A special
process specification is also possible.
@220=MTD(280,1,1,4)+4 Insertion in a calculation

Example: Writing machine data


MTD(250,1,2,4)=@200 Write machine data element
MTD(260,1,,5)=X Write the current X-value to the machine
data element
MTD(270,,3,6)=@210+@220 Allocate calculation

Note: Using the MTD command, any number of data elements can
be read out from the machine data within an NC block, but
only one data element can be written. (see the following sec-
tion "Possible allocations between AXD, TLD, OTD, DCD,
MTD").

12.6 Possible Allocations between TLD, MTD, AXD, OTD, DCD


Various limitations must be observed when handling TLD, MTD, AXD,
OTD and DCD commands.

Handling AXD Commands


Possible allocations - examples AXD(X:P-7-3616)=@20
AXD(X:P-7-3616)=@20+@21+@22
@20=AXD(X:P-7-3616)

Invalid allocations - examples @20=AXD(X:P-7-3616) @21=AXD(X:P-7-3616)


@20=(AXD(X:P-7-3616)+@21)+@22
AXD(X:P-7-3616)=1000 AXD(X:P-7-3616)=1
AXD(X:P-7-3616)=AXD(X:P-7-3616)

Note: Only one AXD command may be written for each NC block.
Multiple AXD allocations per line are not permitted.
AXD commands in parentheses are not permitted.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Special NC Functions 12-23

Handling OTD Commands


Possible allocations - examples @20=OTD(,,,4,1)
OTD(,,,4,1)=@21
OTD(,,,4,1)=@20+@21+@22
@20=OTD(,,,4,1)+OTD(,,,4,1)
@20=OTD(,,,4,1)+OTD(,,,4,1)+OTD(,,,4,1)
@20=OTD(,,,4,1) @210OTD(,,,4,1) @22=OTD(,,,4,1)
OTD(,,,4,1)=OTD(,,,5,1)
OTD(,,,4,1)=OTD(,,,5,1)+OTD(,,,5,1)

Invalid allocations - examples OTD(,,,4,1)=@10 OTD(,,,5,1)=@21 OTD(,,,6,1)=@22


@20=(OTD(,,,4,1)+@21)+@22

Note: Using command OTD, any number of data elements can be


read out from the zero point table within an NC block, but only
one data element can be written.
OTD commands in parentheses are not permitted.

Handling TLD Commands


Possible allocations - examples @200=TLD(,1,1,,0,6,)
TLD(,1,1,,0,6,)=5
TLD(,1,1,,0,6,)=3+1+2
@200=TLD(,1,1,,0,6,)+TLD(,1,1,,0,5,)
@200=TLD(,1,1,,0,6,)+TLD(,1,1,,0,5,)+TLD(,1,1,,0,6,)
TLD(,1,1,,0,6,)=TLD(,1,1,,0,5,)
TLD(,1,1,,0,6,)=TLD(,1,1,,0,6,)+TLD(,1,1,,0,5,)
@200=TLD(,1,1,,0,5,) @210=TLD(,1,1,,0,6,) @220=TLD(,1,1,,0,6,)

Invalid allocations - examples TLD(,1,1,,0,5,)=1 TLD(,1,1,,0,6,)=1 TLD(,1,1,,0,6,)=1


@200=(TLD(,1,1,,0,5,)+@210)+@220

Note: Using the TLD command, any number of data elements of the
tool data can be read within one NC block, but only one data
element can be written.
As opposed to the OTD and MTD commands, only one alloca-
tion in the NC block may occur (also when reading).
DCD commands in parentheses are not permitted.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
12-24 Special NC Functions MTC 200 NC programming instruction

Handling DCD Commands


Possible allocations - examples @20=DCD(,,1)
DCD(,,1)=@21
DCD(,,1)=@20+@21+@22
@20=DCD(,,1)+DCD(,,1)
@20=DCD(,,1)+DCD(,,1)+DCD(,,1)
@20=DCD(,,1) @21=DCD(,,1) @22=DCD(,,1)
DCD(,1,1)=DCD(,2,1)
DCD(,,1)=DCD(,,1)+DCD(,,1)

Invalid allocations - examples DCD(,,1)=@20 DCD(,,2)=@21 DCD(,,3)=@22


@20=(DCD(,,1)+@21)+@22

Note: Using the DCD command, any number of D corrections of the


machine data can be read within one NC block, but only one D
correction can be written.
DCD commands in parentheses are not permitted.

Handling MTD Commands


Possible allocations - examples @200=MTD(110,1,1,1)
MTD(110,1,1,1)=@210
MTD(110,1,1,1)=@200+@210+@220
@200=MTD(110,1,1,1)+MTD(110,1,1,1)
@200=MTD(110,1,1,1)+MTD(110,1,1,1)+MTD(110,1,1,1)
@200=MTD(110,1,1,1) @210=MTD(110,1,1,1) @220=MTD(110,1,1,1)
MTD(110,1,1,1)=MTD(110,1,1,2)
MTD(110,1,1,1)=MTD(110,1,1,2)+MTD(110,1,1,3)

Invalid allocations - examples MTD(110,1,1,1)=@200 MTD(110,1,1,2)=@210 MTD(110,1,1,3)=@220


@200=(MTD(110,1,1,1)+@210)+@220

Note: Using the MTD command, any number of data elements can be
read out from the machine data within an NC block, but only one
data element can be written at a time.
MTD commands in parentheses are not permitted.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction Special NC Functions 12-25

Allocations Between TLD, MTD, AXD, OTD and DCD Commands


Possible allocations - examples AXD(X:P-7-3616)=MTD(110,1,1,1)+MTD(110,1,1,1)
AXD(X:P-7-3616)=OTD(,,,4,1)+OTD(,,,4,1)
AXD(X:P-7-3616)=TLD(,1,1,,0,6,)+TLD(,1,1,,0,6,)
AXD (X:P-7-3616)=DCD(,,1)+DCD(,,1)

Invalid allocations - examples MTD(110,1,1,1)=AXD(X:P-7-3616)


TLD(,1,1,,0,6,)=AXD(X:P-7-3616)
OTD(,,,4,1)=AXD(X:P-7-3616)
DCD(,,1)=AXD(X:P-7-3616)

Note: The restrictions for the individual commands must be ob-


served when allocations are made between the TLD, MTD,
AXD, OTD and DCD commands.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
12-26 Special NC Functions MTC 200 NC programming instruction

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Compiler Functions 13-1

13 NC Compiler Functions

13.1 Basics

NC compiler The NC compiler, which is integrated into the user interface, provides a
preliminary translation of NC programs.
The functions:
• chamfers and roundings,
• enhanced look-ahead function,
• graphical NC editor (for contour and machining programming),
• macro technique and
• modal function
have been implemented using these features.

13.2 Chamfers and Roundings

Chamfers and roundings The commands:


• CF ( insert chamfer) and
• RD (insert rounding)
enable chamfers and roundings to be inserted.

Syntax CF<value> or CF=<value> ;insert chamfer


for CF: <value>=chamfer width
RD<value> or RD=<value> ;insert rounding
for RD: <value>=rounding radius

Explanation • A further linear contour (chamfer) or an arc (rounding) can be in-


serted between linear or circular contours.
RD

RD
RD

RD
121Fase.fh7

CF
CF
CF

CF
CF
CF

CF

CF

121Fase.FH7

Fig. 13-1: Inserting chamfers and roundings between linear and circular con-
tours

• Specifying the RD command tangentially inserts an arc of radius RD


between the preceding and the subsequent movement command.
• Starting from the intersection point of the movement commands in-
volved, chamfer width CF is removed from both movement blocks;
the resulting coordinate values are connected by a linear path (G1).

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
13-2 NC Compiler Functions MTC 200 NC programming instruction

• The value that follows CF specifies the chamfer width; the value after
RD specifies the rounding radius.
• The instructions CF and RD may be inserted between two movement
blocks at the end of the first block. The required chamfer or rounding
will then be inserted after the block in which it has been programmed.
Alternatively, the CF or RD command may be inserted in a separate
block between two movement blocks.
• Chamfers and roundings are always produced on the active plane.

Example:
.
.
.
G1 X.. Y.. RD =3
G01 G3 X.. Z.. I.. J..
.
.

RD
.
Y G0
122Rund.fh7

X
122RUND.FH7

Fig. 13-2: Inserting a rounding

Contiguous movement blocks • Chamfers and roundings should only be inserted between contiguous
movement blocks. A maximum of 20 blocks that do not contain a
movement may be present between two movement blocks which are
to be connected by a chamfer or a rounding.
• The preceding and subsequent movement blocks must contain either
a linear or a circular movement.
• The command for inserting a chamfer or rounding must be written
either in the first movement block or after it, but always before the
second movement block. If the compiler encounters the insertion
command for a chamfer or rounding in the second movement block, it
inserts the chamfer or rounding between the second and the subse-
quent movements.
• If the instruction for inserting a chamfer or rounding is written in a sepa-
rate NC block, the immediately preceding NC block must contain the re-
lated linear or circular movement.
• Movements that are outside the active working plane cannot be inter-
connected by chamfers or roundings.

Invalid commands Chamfers or roundings cannot be inserted between two movement blocks
if one of the following functions is selected or deselected:
• Radius/diameter programming (G15, G16),
• Changing planes (G17, G18, G19, G20, G21, G22),
• Transformation functions (G30, G31, G32),
• Zero offsets and rotations (G50 through G59),
• Dimension inch/mm (G70, G71),
• Mirror function (G72, G73),
• Homing axes (G74),
• Feeding to positive stop / canceling any axis pre-loading (G75, G76),
• Repositioning and restarting (G77),
• Scaling function (G78, G79),
• Absolute/incremental dimension (G90, G91),

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Compiler Functions 13-3

• Jump instructions and program branches (BEQ, BER, BES, BEV,


BMI, BNE, BPL, BRA, BRF, BSR, BST, BTE, JVE JMP, JSR)
• Jump labels,
• Movement blocks as skipped blocks.

No variables For the NC blocks between which a chamfer or rounding is to be inserted,


the end points that lie in the current working plane may not be specified
by variables.

Note: Inserting a specified chamfer or rounding between the pre-


ceding and the subsequent movement block must geometri-
cally be possible. If this is not possible, the compiler automati-
cally reduces the chamfer or rounding concerned to a corre-
sponding value (if necessary even to 0, without issuing an er-
ror message).

13.3 Macro Technique

Macro A macro is the combination of individual instructions that usually must be


programmed repeatedly into a comprehensive instruction with its own
name.

Syntax DEFINE ... AS ...

Explanation A macro permits instructions to be combined that must always be written in


the same sequence (for safety reasons, for example). It enables DIN G
codes (such as drilling cycles G80 through G89) or DIN auxiliary functions
(such as M6) to be simulated. Furthermore, it enables functional sequences
that cannot be accessed from the PLC (such as spindle control during pro-
gram mode) to be controlled by a single command from the NC.

Global / local macros Besides local macros, which the user may define within an NC program
and employ subsequently, the machine manufacturer can store global
macro definitions in the "NC Options menu" (in the "NC programming"
menu item). In contrast to local macro definitions, global macro definitions
are valid in all NC programs and in MDI operation of the graphic user in-
terface.

Example:
Changing tools:
:
DEFINE M860 AS M86 M3 S10 Disengage while the spindle is
slowly turning
DEFINE M6 AS BSR .WZW Reproduce DIN tool change
function M6
DEFINE QUICK AS G01 F15000 Quick process at 15 m/min
DEFINE ANPOS AS X=200 Y=100 Z=50 ;Loading pos. for changing tools
QUICK ANPOS M860 M6 Quick loading in X, Y, Z and
changing tools
:

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
13-4 NC Compiler Functions MTC 200 NC programming instruction

Notes:
• A macro name may have up to 20 characters. Blanks may
not be used.
• The instruction related to a global macro may contain up to
156 characters (consisting of 2 lines with up to 78 charac-
ters each).
• With a local macro, the compiler interprets all NC instruc-
tions that follow the AS key word as the instruction se-
quence that must be inserted instead of the macro name.
• Nesting macros is not permitted. This means that there
may not be any further macros within an instruction se-
quence that is to be inserted.
Not permitted: DEFINE M860 AS M86 M6 S10
• In contrast to the textual user interface and to the SOT, the
user may program global macros in MDI mode within the
graphic user interface.
• Key words may not be super-defined by macros.
• When using a macro in an instruction, a blank character
must be inserted before and after the macro name. There-
fore, a macro may not be contained in an instruction (e.g. x
= macro name) or in a formula/equation, because a blank
may not exist after the equal sign (=).

Reserved key words The following key words are currently in use by Bosch Rexroth. The user
should not use them in the macro technique.
• ACC_EFF
• ACD_COMP
• ADTRC
• BBTRC
• CCW
• CF
• COMPARE
• CONT
• CONT_END
• CORRECTION
• CW
• DEFINE AS
• LA_OFF
• LA_ON
• LINE
• METB
• MODF_OFF
• MODF_ON
• MOVE
• PROBE
• RD
• RELIEF
• RESTORE

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Compiler Functions 13-5

• SAVE
• SETTING
• START
• TLMON_CHK
• TLMON_OFF
• TLMON_ON
• TR_RADIUS
• TRC..
• VFBT
• COPY_XX
• CYCLE_XX
• FORM_XX
• PATERN_XX
• WINDOW_XX

• XX = 01 through 99

Note: Use the macro technique with extreme care, because it allows
the programming language to be changed to a high degree.

Enhancing NC Functions by Macro Technique


Using the macro technique enables the machine manufacturer to define cus-
tomized NC functions that may be employed by the user in the NC program.
Global macros can be created in the "NC programming" menu item ("NC
options" submenu). They are valid in all NC programs and in the MDI
mode. Please refer to the "NC compiler" description for details.

Invariably defined positions The machine manufacturer can enter several fixed positions in the macro
table (such as reference positions, tool changing positions, loading and
unloading positions, etc.). These positions can have mnemonics assigned
which the user may utilize later in the NC program.

Example:

Macro table: DEFINE P_WSW AS X... Y...


:

Spindle
Y
Z
Tool magazine

Toolchange
position

X
123Punkte.fh7

123PUNKTE.FH7

Fig. 13-3: Approaching invariably defined positions

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
13-6 NC Compiler Functions MTC 200 NC programming instruction

NC program
:
G00 P_WSW
:

Note: Entire NC blocks or subroutine calls may be programmed in the


macro table and be called by a keyword. This enables the ma-
chine manufacturer to define specific machine-related move-
ment blocks, which can be activated by the user via keywords.

Retract movement with In the process of moving to the reference position or to the tool changing
intermediate position position, the tool must frequently first be moved away from the machining
area before it can safely be retracted. Using the macro technique, both
movements can be combined in a single command.

Example:

Macro table: DEFINE RETURN AS G0 BSR .P_RT

Intermediate position
X ( 80 / 50 )
Retract position
( 80 / 75 )
124Rück.fh7

124RUECK.FH7

Fig. 13-4: Retract movement with intermediate position

NC program:
:
RETURN X80 Z50 ;Programming the intermediate position
:
M30
The following subroutine is entered in the cycle memory:
.P_RT G0 X80 Z75 RTS ;Move to retract position cycle

Note: Further DEFINE instructions and further subroutines may be


defined. This enables fixed positions to be approached via an
intermediate point. The names of the macros and subroutines
may be defined by the user.
Entire sequences can be programmed in the subroutines.
The machine manufacturer creates the subroutines and the
macros. The user merely enters NC program line "RETURN...".

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Compiler Functions 13-7

13.4 Modal Function

Modal function The MODF_ON (STRI) modal function permits repeatedly used expres-
sions to be written only once.

Syntax MODF_ON(STRI) ;Activate modal function (modal function on)


MODF_OFF ;Deactivate modal function (modal function off)

Explanation • The string STRI, transferred in parentheses with the modal function,
may contain up to 80 characters.
• It is inserted in all subsequent blocks with axis movements.
• The modal function is deselected using the MODF_OFF keyword.

Notes:
• The instruction concerned is executed immediately in the
NC blocks in which the user writes a modal instruction us-
ing MODF_ON.
• The MODF_OFF instruction deactivates the modal instruc-
tion in the block in which it is programmed.
• It must be noted that the modal function (such as
MODF_ON(RD 2)) does not have an effect on blocks with-
out axis movements (i.e. without feed axes). This is also
true for contours that were created in the graphical editor
and were saved as a function call in the NC program.

Examples:

Drilling holes

N15 N14 N13

200

N12

100
125Loch.fh7

N9 N10 N11

X
100 200 300 400
N8

125LOCH.FH7

Fig. 13-5: Example: Drilling holes

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
13-8 NC Compiler Functions MTC 200 NC programming instruction

NC program:
;
T6 M6
G54 G0 X-10 Y-10 Z50 S3500 M3
;
;******************* G83 - deep hole drilling chip removal *******************
@71=-20.0 depth (abs)
@72=6.0 chip depth (inc)
@73=2.0 safety distance (abs)
@74=0.5 cutter distance (inc)
@75=0.0 dwell time
@76=250.0 feed
;***************************************************************************
X100 Y100 Z10 MODF_ON (BSR .*G83)
X200
X300
X400
Y200
X300
X200
X100
MODF_OFF
T0 M6
G0 G53 X570 Y490
M30

Modal rounding and chamfering

180
RD
RD
160
RD RD

140
RD RD

120
RD RD CF
100
CF
80
CF
CF
60
CF
CF
40
CF
CF CF
20
126Modal.fh7

CF
Z
40 80 120 160 200 240 280 320 360 400 440

126MODAL.FH7

Fig. 13-6: Example: Modal rounding and chamfering

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Compiler Functions 13-9

(parts name: stairs)


T3 BSR .M6 (PRE-TURNING TOOL)
G18 G54 G16 G90 G71
M69
G92 S2000
[turning contour C1 without cut segmentation]
G0 G18 G54 G16 G95 G97 G9 G7 Z444 S2000 M3 M9
X0
G1 G42 Z440 F.3
X20 MODF_ON (CF2.0)
Z400
X40
Z360
X60
Z320
X80
Z280
X100
Z160 MODF_ON (RD2.5)
X120
Z120
X140
Z80
X160
Z40
X180
Z0 MODF_OFF
G0 G40 X182 Z1
X184
Z450
M5
M70
M62
G53 G90 G47 M5
M30 [ ]

13.5 Enhanced Look-Ahead Function

Enhanced The enhanced look-ahead function optimizes the velocity curve of the
look-ahead function programmed path movement during compilation and/or the program
download. If required and without modifying the programmed contour, the
look-ahead function inserts intermediate blocks in order to achieve a
steadier path velocity curve.

Using the enhanced Using the enhanced look-ahead function is always expedient if an NC
look-ahead function program that consists of very short NC blocks is to be executed and if the
internal block look-ahead function proves insufficient.
With non-tangential block transitions, the NC always reduces the velocity
to zero at transitions that are crossed with G6 or G8. In order to be able to
stop in the last block, this process frequently requires continuous decel-
eration across several blocks. With very short NC blocks, the internal
CNC look-ahead function, however, usually does not recognize the end of
the polygon blocks, or a too-short NC block, or a non-tangential block
transition in time. Consequently, the NC does not induce the deceleration
process in time, aborts NC program execution during the deceleration
process, and issues the error message
"Deceleration distance too short".
Using the enhanced look-ahead function enables the compiler to adjust
the velocity profile of certain program sequences within the NC program
to the maximum velocities and the acceleration capability of the individual

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
13-10 NC Compiler Functions MTC 200 NC programming instruction

axis. During acceleration and deceleration processes, the compiler


therefore splits the NC blocks into sub-blocks of different F values wher-
ever this is necessary.

Syntax LA_ON ;activates the enhanced look-ahead function


(Look-ahead function, on )
All axes that belong to the process exist in the process when an LA_ON-
LA_OFF block is executed.
LA_ON ;enhanced, axis-specific look-ahead function
(axis1, activate (Look-ahead function, on ) axis2,..)
Only the specified axes (linear or rotary axes, no spindles) exist in the
process when an LA_ON-LA_OFF block is executed. All the other axes
are transferred by GAX/FAX to other processes.
LA_OFF ;deactivates the enhanced look-ahead function
(Look-ahead function, off)

Global variables Global variables have been introduced that are used as transfer parame-
ters for the enhanced look-ahead function. Usually, the user can employ
these variables without modification. Some variables may be preassigned
in the NC Options menu (in the NC programming menu item).
METB ;Minimum execution time of an NC block
Explanation: Global variable Minimum execution time of an NC block
(METB) specifies the shortest execution time of an NC
block within the polygon sequence that is to be optimized.
It must be greater than the related block cycle time.

VFBT ;Velocity factor for block transition


Explanation: This variable permits the velocity changes on non-tangen-
tial block transitions to be influenced.

BBTRC ;Block buffer for tool radius compensation


Explanation: This variable specifies how many NC blocks the en-
hanced look-ahead function is to take into account in ad-
vance when it computes and checks the tool radius com-
pensation.

TL_RADIUS ;Specify tool radius


Explanation: Using the TL_RADIUS[T No., E No.] command, the tool
radii that are required for the enhanced look-ahead func-
tion may be defined centrally at the beginning of the pro-
gram. The compiler employs the current T No. or E No. if
a T No. or an E No. has not been specified.
Example:
:
TL_RADIUS[1234567.1]=24,995
TL_RADIUS[923,3]=20.31
TL_RADIUS[9,9]=29.89
:

Note: If the tool radius path correction of the enhanced look-ahead


function is employed (TRC <> 0), the tool radius that, using the
predefined TL_RADIUS[T No., E No.], has been specified in
the NC program during compilation must exist during machin-
ing.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Compiler Functions 13-11

TRC ;Tool radius correction


Explanation: TRC=0:The enhanced look-ahead function does
not perform radius correction.
TRC=1: The enhanced look-ahead function does perform
radius path correction to the left of the contour
using the radius defined under TL_RADIUS.
TRC=2: The enhanced look-ahead function does perform
radius correction to the right of the contour using
the radius defined under TL_RADIUS.

ADTRC ;Loading distance to establish the tool radius path


compensation
Explanation: ADTRC = 0
The enhanced look-ahead function does not con-
sider a positioning and retracting path to employ
the tool radius path correction.
ADTRC = 1
For TRC = 1, the enhanced look-ahead function
inserts a straight line with a tangential transition
with the length to be provided here in front of the
first polygon element (first movement block after
LA_ON) and after the last polygon element
ADTRC = 2
(last movement block in front of LA_OFF) for
TRC = 2 if the tool radius path compensation was
activated with TRC=1 or TRC=2.

Contiguous motion blocks Within the program sequence to be optimized, only those NC blocks may
exist which contain G1, G2 and G3 movements, event instructions
(SE,RE), speed definitions (F), acceleration limits (ACC_EFF) and quick
auxiliary function outputs (MQxxx, QQxxx and Sxxxxx.xx if "S" was pa-
rameterized as a quick auxiliary function).

No variables The end points may not be determined by variables in those NC blocks in
which the speed profile is to process the look-ahead function.

Tool management The tool change, including the pertaining T function and the tool edge
selection, is to be performed before the enhanced look-ahead function is
activated or after it has been deactivated.

Percentile acceleration In certain program sequences and, if applicable, depending on the tool or
correction the workpiece weight, the resulting path acceleration must be reduced.
Using
ACC_EFF ;change effective resulting path acceleration
permits the effective resulting path acceleration to be changed. This ac-
celeration factor ranges from 1% to 200%.

Note: Contrary to command ACC, command ACC_EFF does not


limit the maximum path acceleration specified by process pa-
rameters. It modifies the actual path acceleration according to
the specification.

Axis-related velocities Besides programming the path velocity via the F value, axis velocities
may also be programmed during the look-ahead function.
To specify an axis velocity, the F must immediately (without a blank) be
followed by the axis name.

Syntax F<axis name>=<axis velocity in mm/min>

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
13-12 NC Compiler Functions MTC 200 NC programming instruction

Example:
G01 X 2034 Z1 421 FZ1=4500 ;axis-related velocity for Z1
:

Note: If the user programs several velocities within a NC block, that


NC block and the subsequent NC blocks are executed with the
last velocity which has been specified until the next velocity in-
struction is received.

Access to current data Command Access Current Data ACD_COMP[...] permits access to cur-
in the controller rent controller data (currently only NC variables) during compilation.

Example: reading the tool radius during compilation


After each trimming of a grinding wheel, a trimming program updates half
the diameter of the grinding wheel in NC variable @1:220. During compi-
lation, this value must be taken into account as the tool radius.
TL_RADIUS[1,1] = ACD_COMP[@1:220]-0,2; Adopt tool radius from NC
variable @1:12 and sub-
tract 0.2 mm .

Example: grinding needles


A given polygon curve must be traversed in forward and backward alter-
nating movement at the highest velocity possible. This requires the veloc-
ity curve of the programmed path movement to be optimized using the
enhanced look-ahead function.

Y
127Poly.fh7

127POLY.FH7

Fig. 13-7: Velocity curve of a polygon that is to be optimized for grinding nee-
dles

;Grinding needles on the XY plane


;Grinding wheel radius: 2.50000
;File name: TP1
;
(part name: TP1)
T2 BSR .M6 [GRINDING WHEEL D5] Activate tool
TL_RADIUS [ ] = ACD_COMP[@200] Read current tool radius for com-
piler
G0 G17 G40 G54 G71 G48 G8 G6 G98 X-0.19306
Y3.49431 S1 3000 M3 Return to initial state
@201=200 Loop counter for number of pen-
dulum strokes = 200
.PEN @100=@101-0 BEQ .ENDPEN Terminate oscillation?
F4000 Set path velocity
;
TRC=1 Tool radius compensation to left
of contour
ADTRC=1 Loading path to generate the tool
radius compensation
ACC_EFF=90 Modify effective path acceleration

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Compiler Functions 13-13

LA_ON Enhanced look-ahead function


ON
;
G1 X0.8 Y1.2 Polygon curve
:
:
LA_OFF ;Enhanced look-ahead function
OFF
:
;
@101=@101-1 BRA .PEN ;Decrement loop counter
.ENDPEN BSR .ABRICH ;Call dressing cycle
RTS
;
PROGRAM END

Notes:
• In reverse programs, the "LA_OFF" command must be pro-
grammed when the "LA_ON" command is used.
• The compiler does not take into account any velocity changes
of the axes that are caused by a rotation of the contour.

13.6 Graphic NC editor

Function The graphic NC editor represents an efficient and highly precise tool that
supports parts programming. It enables the user to easily define geomet-
ric elements (e.g. parts contours) graphically, and to specify their ma-
chining.
At the end of the dialog box, the user may choose whether the data that is
required for machining is to be saved in the form of NC blocks or in the
form of a function call, together with the related parameters, in the NC
program.

Syntax The graphic NC editor produces the following instructions:


• WINDOW_01 (..., ..., . . .) ;Definition of the window size for lathing
• WINDOW_02 (..., ..., . . .) ;Definition of the window size for milling
• CONT (..., ..., . . .) ;Definition of the initial part contour or of
the finalpart contour
:
:
END_CONT
• FORM_20 (..., ..., . . .) ;Recess - lathing
• FORM_50 (..., ..., . . .) ;Straight elongated hole - milling
• FORM_51 (..., ..., . . .) ;Round elongated hole - milling
• FORM_52 (..., ..., . . .) ;Circle - milling
• FORM_53 (..., ..., . . .) ;Polygon - milling
• FORM_54 (..., ..., . . .) ;Straight text - milling
• FORM_55 (..., ..., . . .) ;Round text - milling
• FORM_56 (..., ..., . . .) ;Rectangle - milling
• FORM_57 (..., ..., . . .) ;Rectangle centered - milling
• CYCLE_10 (..., ..., . . .) ;Contour cut - lathing
• CYCLE_11 (..., ..., . . .) ;Roughing - lathing
• CYCLE_12 (..., ..., . . .) ;Residual cut - lathing
• CYCLE_40 (..., ..., . . .) ;Contour cut - milling

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
13-14 NC Compiler Functions MTC 200 NC programming instruction

Note: During the setup of the process program. the following data for
the pertaining tool must be available:
• cutter position,
• tool radius,
• corner angle, and
• setting angle

Detailed description Further detailed information concerning these functions of the NC com-
piler can be found in the description "NC compiler"
"DOK-MTC200-NC*COMP*V23-FK01-EN-P".

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Programming Practices 14-1

14 NC Programming Practices

14.1 Time-Optimized NC Programming


The following rules will help to ensure that the CNC operates at its maxi-
mum performance level.

Note: Whatever can be programmed in a single NC block in terms of


syntax should be in fact be programmed in a single NC block,
provided it does not violate program flow logic.

What can be programmed in an • Branch label (e.g. .HOME)


NC block?
• Motion functions (1 function each from 16 groups)
• Trigonometric arguments ∈ {RAD, DEG}
• Assigning a value to a NC variable (repeatedly) (e.g. @12=3)
• Assignment of value to a drive date (e.g. AXD(X:S-0-0405)=3)
• Position statement (one position statement for each axis)

{X,Y,Z,U,V,W,A,B,C}
• Interpolation parameters I
• Interpolation parameters J
• Interpolation parameters K
• F word
• S word
• P word
• Zero offset table (O word)
• Path acceleration as percent (ACC)
• Auxiliary Q function (Q word)
• Tool number (T word)
• Tool edge number (E word)
• Tool command
• Setting an event (SE)
• Resetting an event (RE)
• Wait until NC event is set (WES)
• Wait until NC event is reset (WER)
• Define process (DP) (repeatedly)
• Program preselection for process (SP)
• Start reverse program (RP) (repeatedly)
• Start advance program (AP) (repeatedly)
• Wait for process (WP) (repeatedly)
• Lock process (LP) (repeatedly)
• Set Complete status (POK)
• Program control command
• Note
• Comment

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
14-2 NC Programming Practices MTC 200 NC programming instruction

Example: NC program
G00
S5000
M03
F10000
X100 Y50
Time-optimized, spindle starts after movement:
G00 X100 Y50 F10000 S5000 M03
Time-optimized, spindle starts before movement:
M03 S5000
G00 X100 Y50 F10000

The priority to process an NC block in the NC memory is defined as fol-


lows:
Tool Events Process Program
Block Branch Axis IPO F value S value Auxil.
G codes Variables values comm- comm- comm-
Nos. label para- function
ands ands ands
meter
N1234 .END G01 @200=x X100 I0 F1000 S800 M03 MTP T6 SE 5 DP 1 HLT
Y100 J50

• While all of the above NC commands can, in theory, be programmed


in a single NC block, the maximum block length is limited to 240 cha-
racters.
• While auxiliary M functions can be used from all 16 groups, no more
than four auxiliary functions (S, M, Q words) can be programmed in a
single NC block.

Note: Avoid repeating functions (G codes), which are already active.


Remember which functions are modally active as a conse-
quence of the power-on status.

Example: NC program
G07 G09 G40 G43 G47 G53 G62 G90 G94 RAD
(ON states)
G00 G90 S5000 M03 F10000 X100 Y50
G00 G90 F10000 X200 Y50
G01 G90 F10000 Y100

Time-optimized:
G00 X100 Y50 F10000 S5000 M03
X200
G01 Y100

Note: Calculate all constants when you create the program, and
assign these constants without using equal signs.

Example: NC program
DEG X=100 Y=20+100*SIN(30)

Time-optimized:
X100 Y70

Notes: Avoid using NC commands that stop NC block processes.


Avoid using the formula assistant interpreter!

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
MTC 200 NC programming instruction NC Programming Practices 14-3

Example:
S2 = 1400

Time-optimized:
S2 1400

NC commands that stop block • Movement conditions


preparation ∈ {G33, G50-G59, G63, G64, G65, G73, G74, G75, G79, G95,
G96} and
• Cancellation of path conditions by G93, G94 and G97
• Assigning values to NC variables, working pallets or drive datum
• Calculating a mathematical expression
• Auxiliary functions (S, M, Q words)
• Tool number (T word)
• Tool commands
• Wait until NC event is set/reset (WES, WER)
• Wait until main spindle has reached target position (MW19)
• Switch between main spindle mode and C-axis mode (M03 Sxxxx,
Cxxx.xxx)
• Axis transfer with GAX / FAX
• Nonprocessed skipped blocks
• Process control commands
• Program control commands
∈ {BST, BES, BER , JMP, RET, BTE, BSE, BRF, HLT, JEV,
BEV, CEV, JSR}
• Process control commands: RTS, BRA, BSR, REV, BEQ, BNE, BPL,
BMI, EEV and DEV and value assignments to machine addresses do
not stop block process preparation.

Note: Use tool management as a parallel process through optimal


programming.

Example: NC program for tool changer with double gripper


T1 MTP Position magazine to tool 1
TCH Switch tools between spindle and magazine location
BSR .BEARB1 Machining process 1
T2 MTP Position magazine to tool 2
TCH Switch tools between spindle and magazine location
BSR .BEARB2 Machining process 2

Time-optimized:
T1 MTP Position magazine to tool 1TCH
TCH Switch tools between spindle and magazine location
T2 MTP Position magazine to tool 2 (parallel)
BSR .BEARB1 Machining process 1
TCH Switch tools between spindle and magazine location
BSR .BEARB2 Machining process 2

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
14-4 NC Programming Practices MTC 200 NC programming instruction

The positioning of the magazine in block N0002 takes place asynchro-


nously to the execution of the NC program – in other words, the execution
of the NC program can continue without interruption.
The TCH command will automatically wait until the unit magazine posi-
tioning is completed.

CNC time data Time data with digital drives


• Block cycle time 6 ms • Fine interpolation 0.25 ms
• Block transition time 0 ms • Posn. contr. cyc. time 0.25 ms
• Interpol. cycle time 2 ms
• Posn. contr. cyc. time 2 ms

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Appendix 15-1

15 Appendix

15.1 Table of G Code Groups

G Function G code group Active Meaning


G00, G01, G02, G03 1 modal Interpolation functions
G17 to G22 2 modal Level selection
G40, G41, G42 3 modal Tool path compensation
G52 to G59 4 modal Zero offsets
G15, G16 5 modal Radius/diameter programming
G90, G91 6 modal Measurements
G65, G94, G95 7 modal Feed programming
G96, G97, G66 8 modal Spindle speed programming
G70, G71 9 modal Measurement units
G43, G44 10 modal Transition elements
G61, G62 11 modal Block change
G98, G99 12 modal Speed contour/center line path
G47, G48, G49 13 modal Tool length compensation
G08, G09 14 modal Block transition speed
G06, G07 15 modal Drag error ON/OFF
G04 16 blockwise Dwell time
G33 16 blockwise Thread cutting programmable zero offset
G50, G51 16 blockwise Tapping
G63, G64 16 blockwise Referencing
G74 16 blockwise Traverse to fixed point
G75 G76 16 blockwise Reposition and NC block restart
G77 16 blockwise Spindle speed limit
G92 16 blockwise Time programming
G93 16 blockwise
G30, G31, G32 17 modal Transformation
G72, G73 18 modal Mirror imaging
G78, G79 19 modal Scaling
G68, G69 20 modal Adaptive depth
G36, G37, G38 21 modal Rotary axis approach logic
G25, G26 22 modal Adaptive feed control
G10, G11 23 modal Rounding of NC blocks with axis filter

The G functions which are blockwise active can be read only in the block
in which they are programmed. Otherwise a value of -1 is issued when the
blockwise active G functions are read.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
15-2 Appendix NC Programming Instructions

15.2 Table of M Function Groups


M function M function group Active Meaning
M000, M001, M002, M030 1 modal Program control commands
M3, M4, M5, M13, M14 2 modal Spindle commands S
M103, M104, M105, M113, M114 2 modal Spindle commands spindle 1
M203, M204, M205, M213, M214 3 modal Spindle commands spindle 2
M303, M304, M305, M313, M314 4 modal Spindle commands spindle 3
M007, M008, M009 5 modal Coolant S
M107, M108, M109 5 modal Coolant S1
M207, M208, M209 6 modal Coolant S2
M307, M308, M309 7 modal Coolant S3
M010, M011 8 modal Clamp & unclamp S
M110, M111 8 modal Clamp & unclamp S1
M210, M211 9 modal Clamp & unclamp S2
M310, M311 10 modal Clamp & unclamp S3
M040, ..., M045 11 modal Gear selection S
M140, ..., M145 11 modal Gear selection S1
M240, ..., M245 12 modal Gear selection S2
M340, ..., M345 13 modal Gear selection S3
M046, M047 14 modal Spindle override
M048, M049 15 modal Feed override
M019, ..., M319, 16 blockwise S positioning & MH-F
Mxxx Machine-specific functions

The M functions which are blockwise active can only be read in the block
in which they are programmed. Otherwise a value of -1 is issued when the
blockwise active M functions are read.

15.3 Table of Functions

Legend for column "Function" * Default state


P default can be defined in process parameters
S blockwise active

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Appendix 15-3

I. G00 through G19


Function G group Meaning Description Page

G00 1 Lin. interpolation, Syntax: G00 4-18


P rapid traverse ; The programmed coordinates are traversed at maximum path
* modal velocity.
G01 1 Lin. interpolation Syntax: G01 F value 4-19
P feed ; The programmed axes start and reach their end point together.
* modal
G02 1 Circular interpol., Syntax: G02 <end point> <interpolation parameter [I,J,K]> or 4-20
clockwise, <radius [R]>
* modal ; A circular movement is performed in the selected plane
(G17, G18, G19, G20, G21, G22).
G03 1 Circular interpol., Syntax: G03 <end point> <interpolation parameter [I,J,K]> or 4-20
counterclockwise, <radius [R]>
* modal ; A circular movement is performed in the selected plane
(G17, G18, G19, G20, G21, G22).
G04 16 Dwell time Syntax: G04 F<time in seconds> 4-44
P * blockwise ; The maximum dwell time is 99999.99 seconds.
G06 15 Position with mini- Syntax: G06 ; Algorithm for positioning with minimized lag for all 4-2
mized lag axis movements. Block transitions are not rounded.
* modal
G07 15 Interpol. w. lag Syntax: G07 ; Algorithm for positioning with lag for all axis move- 4-6
* * basic setting, ments. Block transitions which are not tangential will be rounded.
* modal
G08 14 Speed limited NC Syntax: G08 4-8
block transition ; The interpolation function G08 is used to adjust the final end
* modal speed to ensure that the transition to the next NC block occurs at
the highest possible speed.
G09 14 Speed limited NC Syntax: G09 4-10
* block transition ; G09 reduces position differences at block transitions.
* basic position
* modal
G10 23 Disable rounding of Syntax: G10 4-82
* NC blocks with axis ; Disables rounding mode. Programming of "RDI=0" automatically
filter enables G code G10.
* basic setting
* modal
G11 23 Enable rounding of Syntax: G11 4-82
NC blocks with axis ; Enables rounding mode. The last programmed rounding distance
filter RDI is effective. With a current rounding distance of 0, G11 does
* modal not take effect.
G15 5 Radius program- Syntax: G15 3-25
P ming ; The machine builder sets the defaults for radius/diameter pro-
* modal gramming in the process parameters.
G16 5 Diameter program- Syntax: G16 3-25
P ming ; The machine builder sets the defaults for radius/diameter pro-
* modal gramming in the process parameters.
G17 2 Plane selection XY Syntax: G17 3-17
P * modal ; The machine builder sets the default plane in the process para-
meters.
G18 2 Plane selection ZX Syntax: G18 3-17
P * modal ; The machine builder sets the default plane in the process para-
meters.
G19 2 Plane selection YZ Syntax: G19 3-17
P * modal ; The machine builder sets the default plane in the process para-
meters.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
15-4 Appendix NC Programming Instructions

II. G20 to G38


Function G group Meaning Description Page
st nd
G20 - G22 2 Free plane The 1 and 2 axes of the plane selected with one of these G 3-19
selection functions, as well as the vertical axis, receive a specified axis
* modal meaning. Furthermore, the "Constant surface speed function
(G96)" is deselected and the "Spindle speed in rpm function
(G97)" and the "Linear interpolation (G01)" functions become
active.
G20 2 Free plane Syntax: G20 [1st axis of the plane] [2nd axis of the plane] 3-18
selection {perpendic. axis}
* modal st
The 1 axis of the plane contains axis meaning X.
nd
The 2 axis of the plane contains axis meaning Y.
The vertical axis contains axis meaning Z.
G21 2 Free plane Syntax: G21 [1st axis of the plane] [2nd axis of the plane] 3-18
selection {perpendic. axis}
* modal st
The 1 axis of the plane contains axis meaning Z.
nd
The 2 axis of the plane contains axis meaning X.
The vertical axis contains axis meaning Y.
G22 2 Free plane Syntax: G22 [1st axis of the plane] [2nd axis of the plane] 3-18
selection {perpendic. axis}
* modal st
The 1 axis of the plane contains axis meaning Y.
nd
The 2 axis of the plane contains axis meaning Z.
The vertical axis contains axis meaning X.
G25 22 Adaptive feed Syntax: G25 4-49
OFF Adaptive feed control is deactivated.
* basic setting
G26 22 Adaptive feed Syntax: G26 4-49
ON Adaptive feed control is activated.
* basic setting
G30 17 Deselection of Syntax: G30 4-73
* transformation ; G30 cancels an existing coordinate transformation. The
* basic position fictitious axes may no longer be programmed.
* modal
G31 17 Facing selection Syntax: G31 4-65
* modal ; The NC activates the G17 plane and the corresponding real
axes become fictive axes.
G32 17 Selection of Syntax: G32 RI w or G32 RI=w 4-70
lateral cylinder ; The NC produces straight lines and circles on a lateral cyl-
surface inder surface. Before lateral cylinder surface machining is
machining activated, the activated machining plane must be spanned by
* modal at least one rotary axis.
G33 16 Thread cutting Syntax: G33 <end point> <lead> <starting angle> 4-32
S * blockwise ; G33 cuts single- or multiple-thread longitudinal, face and
tapered threads using a constant lead.
G36 21 Start-up logic for Syntax: G36 4-63
P endlessly rotating ; Positioning with modulo calculation “shortest distance”.
rotary axes Modulo calculation can be used only with absolute
* modal programming (G90).
G37 21 Start-up logic for Syntax: G37 4-63
P endlessly rotating ; Positioning with modulo calculation "positive direction".
rotary axes Modulo calculation can be used only with absolute
* modal programming (G90).
G38 21 Start-up logic for Syntax: G38 4-64
P endlessly rotating ; Positioning with modulo calculation "negative direction".
rotary axes Modulo calculation can be used only with absolute
* modal programming (G90).

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Appendix 15-5

III. G40 to G59


Function G group Meaning Description Page
G40 3 Cancel tool path Syntax: G40 5-80
* compensation ; If an active tool path compensation is canceled, the next
* basic setting move which is expected is a linear move lying in the plane.
* modal
G41 3 Tool path Syntax: G41 5-80
compensation, left ; If G42 is programmed after an active G40 or G41, the next
* modal anticipated movement is a linear movement in the process
plane.
G42 3 Tool path comp- Syntax: G42 5-81
ensation, right ; If G41 is programmed after an active G40 or G42, the next
* modal anticipated movement is a linear movement in the process
plane.
G43 10 Insert transition Syntax: G43 5-84
* element "arc" ; When tool path compensation is active (G41 or G42), G43
* basic setting inserts an arc as the contour transition element for outside
* modal corners.
G44 10 Insert transition Syntax: G44 5-84
element "chamfer" ; When G41 or G42 is active, a chamfer is inserted as the
* modal contour transition with outside corners whose transition angle
exceeds 90°.
G47 13 No tool length Syntax: G47 5-87
P compensation ; When movements are being performed in the direction of
* default, * modal the tool, all position data relate to the position of spindle
nose.
G48 13 Tool length comp- Syntax: G48 ; The entered tool length is corrected in the di- 5-87
P ensation positive rection of the main axes when the axis direction is positive.
* modal
G49 13 Tool length comp- Syntax: G49 ; The entered tool length is corrected in the di- 5-88
ensation negative rection of the main axes in the negative axis direction.
* modal
G50 16 Programmable Syntax: G50 <axis designation(s)><coordinate value(s)> 3-13
S absolute zero ; Absolute offset of the machining zero point by the value
offset programmed using G50 under the address letter for the axis.
* blockwise

G51 16 Programmable Syntax: G51 <axis designation(s)><coordinate value(s)> 3-13


S incremental zero ; Incremental offset of the machining zero point by the value
offset programmed using G50 under the address letter for the axis.
* blockwise

G52 4 Programmable Syntax: G52 <axis designation(s)><coordinate value(s)> 3-14


zero point of ; A workpiece zero point is programmed using the value
workpiece specified at the axis address. All zero offsets which are
* modal already active are canceled.
G53 4 Cancel zero offsets Syntax: G53 3-15
P * basic setting ; Switch from workpiece coordinate system to machine
* modal coordinate system.
G54 - G59 4 Adjustable zero Syntax: G54-G59 3-9
offsets ; Offsets are entered via the user interface. G54 - G59 are
* modal cancelled by G52 or G53.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
15-6 Appendix NC Programming Instructions

IV. G61 to G79


Function G group Meaning Description Page

G61 11 Exact stop Syntax: G61 4-12


* modal ; The programmed target position is traveled to within a specified
exact stop limit.
G62 11 Rapid NC block Syntax: G62 4-14
* transition ; Sudden contour changes and non-tangential transitions are
* basic setting rounded off by programming G62.
* modal
G63 16 Rigid tapping Syntax: G63 <end point> <feed per spindle revolution [F]> 4-34
S * blockwise ; With G63, the spindle will stop at the end of movement.
G64 16 Rigid tapping Syntax: G64 <end point> <feed per spindle revolution [F]> 4-34
S * blockwise ; With G64, the spindle continues to rotate at the end of the
movement.
G65 7 Floating tapping Syntax: G65 <feed per spindle revolution[F]> 4-38
spindle as lead ; G65 is used to tap threads using non-interpolating main
axis spindles.
* modal
G66 8 Constant grinding Syntax: G66 S <constant grinding wheel peripheral speed> 4-56
wheel peripheral ; Programming G66 causes the programmed S value to be
speed (SUG) interpreted in m/s or feet/s.
* modal
st
G68 20 Switch to 1 Syntax: G68 <[axis designation] [coordinate value = 0]> 3-44
encoder system <feed>
st
; Switch to 1 encoder system (e.g. motor encoder)
nd
G69 20 Switch to 2 Syntax: G69 <[axis designation] [coordinate value = 0]> 3-44
encoder system <feed>
nd
; Switch to 2 encoder system
G70 9 Unit: Inch Syntax: G70 3-26
P * modal ; The machine manufacturer defines the basic programming unit
in the process parameters.
G71 9 Unit: Millimeters Syntax: G71 3-27
P * modal ; The machine manufacturer defines the basic programming unit
in the process parameters.
G72 18 Mirror function Syntax: G72 3-28
* OFF ; The mirror function is canceled of all axes.
* basic setting,
* modal
G73 18 Mirror function ON Syntax: G73 <axis name>-1 3-28
* modal ; The coordinates of the axes entered in the axis name are mirror
imaged.
G74 16 Axis homing cycle Syntax: G74 <axis name> <coordinate value=0> <feed> 3-32
S * blockwise ; G74 activates G40, G47, G53, G90, G94
G75 16 Feed to positive Syntax: G75 <axis name> <coordinate value=0> <feed> 3-33
S stop ; G75 is possible with G90 or G91.
* blockwise
G76 16 Cancel all axis Syntax: G76 3-35
S preloads ; G76 cancels the axis preloads on all axes which are preloaded
* blockwise using G75 traverse to fixed stop.
G77 16 NC block restart Syntax: G77 <axis designation> <coordinate value=0> <feed> 3-38
S and repositioning ; The originally programmed coordinate value (spindle speed) is
* blockwise restored.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Appendix 15-7

G78 19 Scaling function Syntax: G78 3-30


* canceled ; The scaling function of all axes is canceled.
* basic setting
* modal
G79 19 Select scaling Syntax: G79 <axis name><scaling factor> 3-30
function ; The scale for the distance to be traversed on the specified axis
* modal is increased or decreased.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
15-8 Appendix NC Programming Instructions

V. G90 through G99


Function G group Meaning Description Page
G90 6 Input data as Syntax: G90 3-3
* absolute ; All dimensions are input relative to a specified zero point.
dimensions
* basic setting
* modal

G91 6 Input data as in- Syntax: G91 3-4


cremental values ; All subsequent dimension entries are stated as the difference
* modal in relation to the start/stop position.
G92 16 Spindle speed Syntax: G92 S<upper spindle speed limit> 4-58
S limitation ; The set speed limit remains modally active.
* blockwise

G93 16 Time Syntax: G93 F<time in seconds> 4-42


S programming ; G93 is superimposed on G94 or G95 in the NC block.
* blockwise

G94 7 Velocity Syntax: G94 4-43


P programming ; The programmed F word is interpreted as feed in mm/min.
* basic setting G94 is superimposed by G95, G96 or G65.
* modal
G95 7 Feed per Syntax: G95 F<feed per revolution> 4-43
P revolution ; The programmed F word is interpreted in mm or inches per
* modal spindle revolution.
G96 8 Constant surface Syntax: G96 S<constant surface speed in m/min> 4-57
P speed (CSS) ; The CNC determines the correct spindle speed for the current
* modal diameter.
G97 P 8 Spindle speed in Syntax: G97 4-61
rpm ; The programmed S word is interpreted in RPM.
* basic setting
* modal
G98 12 Constant feed Syntax: G98 5-85
* on tool center ; The path speed is NOT corrected in arcs if G41 or G42 is
line active.
* basic setting
* modal

G99 12 Constant feed Syntax: G99 5-86


at the contour ; The path speed is corrected in arcs if G41 or G42 is active.
* modal

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Appendix 15-9

VI. ACC through BTE


Function Meaning Description Page
ACC Programmable Syntax: ACC <constant> 4-16
acceleration ; The programmed constant limits the acceleration of the axis/axes
* modal programmed in NC block ACC.
AP Start advance Syntax: AP <process> 9-3
program ; The program preselected by the SP will be started for the specified
process.
AXD Data exchange Syntax: 12-1
with digital drives AXD(<axis name>: <SERCOS ID number>)
AXD(<axis number>: <SERCOS ID number>)
; Read and write drive data using the SERCOS.
BEQ Branch if result is Syntax: BEQ <label> 9-17
equal to zero ; The program continues execution if the last result is equal to zero.
BER Branch if NC Syntax: BER <branch label> <process number>: <event number> 7-5;
event is reset ; The program continues execution at the specified branch label if an event 9-17
is reset.
BES Branch if NC Syntax: BES <branch label> <process number>: <event number> 7-5;
event is set ; The program continues execution at the specified branch label if an event 9-16
is set.
BEV Branch on NC Syntax: BEV <label>: <event number> 7-7
event to NC sub- ; NC event monitoring is activated after executing NC command BEV. If the
routine (interrupt) NC event assumes a status of 1, NC program execution continues at the
NC block with the defined branch label.
BMI Branch if result is Syntax: BMI <branch label> 9-17
less than zero ; The program continues execution at the specified branch label if the last
result is less than zero.
BNE Branch if result is Syntax: BNE <label> 9-17
not equal to zero ; The program continues execution if the last result is not equal to zero.
BPL Branch if result is Syntax: BPL <branch label> 9-17
equal to or ; The program continues execution at the specified branch label if the last
greater than zero result is equal to or greater than zero.
BRA Branch absolute Syntax: BRA <branch label> 9-9
; Program execution continues at the NC block with the specified branch
label.
BRF Branch during Syntax: BRF <branch label> 9-16
reference ; Program execution continues at the NC block with the specified branch
label if all process axes are referenced (homed).
BSE Branch if spindle Syntax: BSE <branch label> ⇒ BSE .SPLE 9-16
is empty ; The BSE branch command is used to determine whether or not the
spindle is empty.
BSR Branch to NC Syntax: BSR <branch label> 9-12
subroutine ; Program execution continues at the NC block with the branch label
specified in the command parameter.
BST Branch with stop Syntax: BST <branch label> 9-9
; The NC program branches to the defined label; the default states are set.
BTE Branch if tool Syntax: BTE <branch label> ⇒ BTE .PRT0 9-16
T0 was ; Program execution continues at the NC block starting with the defined
programmed branch label if tool T0 has been programmed.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
15-10 Appendix NC Programming Instructions

VII. CEV through MMP


Function Meaning Description Page
CEV Cancel event Syntax: CEV <event number> 7-8
monitoring ; Active event monitoring (BEV, JEV) is canceled.
(interrupt)
D Selecting a Syntax: D<D correction number[0..99]> 5-90
D correction ; D 1-99 Selection of an additive tool geometry shift if G48/G49 or
*modal G41/G42 is active.
D0 D0 cancels active D correction offsets.
DCD Access to Syntax: DCD([process],[memory], [value] 12-19
D corrections
from NC program
DEV Deactivate event Syntax: DEV 7-8
monitoring ; Active event monitoring (BEV, JEV) is deactivated.
(interrupt)
DP Define process Syntax: DP <Process> 9-2
; DP informs the PLC via the corresponding gateway signal that the process
will be required for NC program execution.
E Tool edge Syntax: E<constant> 10-2
selection ; The tool edge defined under the constant is preselected as the active tool
*modal edge.
EEV Activate event Syntax: EEV 7-8
monitoring ; Deactivated event monitoring (BEV, JEV) is activated.
FAX, GAX Axis transfer Syntax: FAX (<axis designation>), 9-6
between the GAX (<process>: <axis designation>)
processes ; Free axis for another process
; Get axis from another process.
HLT Programmed halt Syntax: HLT 9-9
; Interrupts NC program execution; the process waits for a new start signal.
JEV Jump if NC event Syntax: JEV <branch label> <event number> 7-8
is set (interrupt) ; NC event monitoring is activated after executing NC command JEV. If the
NC event assumes a status of 1, NC program execution continues at the
NC block with the defined branch label.
JMP Jump to other Syntax: JMP <program number> or <variable> 9-10
NC program ; Program execution continues in the defined program.
JSR Call an NC Syntax: JSR <program number> or <variable> 9-11
program as a ; The specified program is executed as a subroutine.
subroutine
LP Lock process Syntax: LP <process> 9-4
; The specified process will be set to a user-defined state. State is set.
MEN Enable tool Syntax: MEN 8-23
magazine ; Enables the manual tool storage mode while continuing NC program
(storage) for execution.
manual mode
MFP Move free pocket Syntax: MFP(<position>,<direction>) { (.,.) optional } or <variable> 8-20
into change ; The tool storage axis is moved to the next free pocket.
position
MHP Tool storage to Syntax: MHP(<direction>) { (.) optional } 8-14
home position ; Causes the tool storage axis to move to its home position (pocket 1).
MMP Move pro- Syntax: MMP(<position>,<direction>) { (.,.) optional } 8-16
grammed pocket ; Causes the tool storage axis to move to the pocket specified via the
into position T word.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Appendix 15-11

VIII. MOP through RTS

Function Meaning Description Page


MOP Move old pocket Syntax: MOP(<position>,<direction>, <spindle>) { (.,., ) optional } ; 8-21
into position Causes the tool storage axis to move to the pocket from which the tool was
removed.
MRF Move tool sto- Syntax: MRF 8-13
rage unit to refe- ; Initiates the referencing sequence of the tool storage axis.
rence position
MRY Tool storage Syntax: MRY 8-22
ready? ; Stops NC program execution until the active tool storage movement is
completed.
MTD Read/write the Syntax: MTD([page No.],[control variable 1], [control variable 2], 12-21
machine data [element No.])
elements ; Within an NC block, as many data elements as desired can be read from
the machine data, but only one data element can be written at a time.
MTP Move program- Syntax: MTP(<position>,<direction>) { (.,.) optional } 8-15
med tool into ; Causes the tool storage axis to move to its home position (pocket 1).
position
NMP Negative memo- Syntax: NMP(<axis designation>) 12-1
rized position ; The NMP function is available only for analog drives.
O Select the offset Syntax: O <offset table number> 3-11
table for G54- ; Depending on the defined process parameter, offset table 0-9 can be
G59 selected. Offset table 0 is active by default.
OTD Read/write offset Syntax: OTD([NC memory],[process],[offset table], [offset],[axis]) 12-4
table data
P Active plane Syntax: G50-G51 P<angle> 3-10
rotation together ; Interpolation plane rotation. Becomes active in the next NC block.
with G50, G51,
G54 - G59
PMP Positive memo- Syntax: PMP(<axis designation>)
rized position ; PMP is possible only with analog drives.
POK Execution Syntax: POK 9-5
complete ; POK can be used to define when machining is complete.
RAD Trigonometric unit Syntax: RAD 10-5
= radians ; Arguments and reciprocal functions of the trigonometric functions SIN,
COS, TAN, and ASIN, ACOS, ATAN in the angle unit radians.
RDI Maximum roun- Syntax: RDI <rounding distance> 4-82
ding distance ; The maximum distance to the programmed data point for the start of the
rounding process.
RE Reset NC event Syntax: RE <process number>: <event number> 7-3
; The defined event is reset via the command parameter and remains reset
until it is set by the SE command.
RET Program end with Syntax: RET 9-9
reset ; The NC program jumps to the first NC block, and activates the defaults.
REV Set reverse Syntax: REV <label> 9-13
vector ; The defined label identifies the NC block where NC program execution
continues when the reverse NC program is started.
RP Start reverse Syntax: RP <process> 9-3
program ; The specified process starts the NC program addressed by the reverse
vector.
RTS Return from Syntax: RTS 9-12
subroutine ; Return to the NC program; the process is continued starting with the
following block.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
15-12 Appendix NC Programming Instructions

IX. SE through WP
Function Meaning Description Page
SE Set NC event Syntax: SE <process number>: <event number> 7-2
; The defined event is set via the command parameter and remains active
until it is reset by the RE command.
SP Program prese- Syntax: SP <process> <program number> 9-2
lection for ; The defined NC program is selected for the specified process.
process
SPC Select main Syntax: SPC <spindle number> 4-73
spindle for trans- ; SPC selects the main spindle for transformation. The selection of the main
formation spindle must take place before selecting the transformation.
* modal
SPF Select main Syntax: SPF <spindle number> 4-54
spindle ; SPF selects the main spindle for G33, G63/G64, G65, G95 and G96.
* modal
SPT Select tool Syntax: SPT <spindle number> 8-8
spindle ; SPT selects the tool spindle for tool edge selection E.
* modal
T Tool selection Syntax: T<constant> or T = <expression>
and request ; Preselects the tool number or location number specified under the
constant or contained in the expression.
TCH Complete tool Syntax: TCH(<position>,<spindle>) { (.,.) optional } 8-28
change ; Initiate complete tool change between tool spindle and magazine location.
TG Preselect tool Syntax: TG<constant>, TG=<expression>, <variable>=TG 8-9
group / read active ; Tool group management: A tool group is preselected as a machining
group group. The active group can be read.
TGSM Define/read tool Syntax: TGSM<constant>, TGSM=<expression>, <variable>=TGSM 8-10
search mode ; Tool group management: Tool search mode "TGSM" is defined. This also
results in implicit group activation when the T word is specified. The active
tool search mode can be read.
TID Equipment check Syntax: TID 5-2
; Explicit execution of the equipment check: Comparison of the command
tool data (setup list) and the actual tool data (tool list)
TLD Access to tool Syntax: TLD([process], [addressing], [storage type / tool number], 12-7
data from the NC [location / tool duplo number], [tool edge], [data element],
program [status],[group number], [group duplo number])
TMS Tool from maga- Syntax: TMS(<position>,<spindle>) { (.,.) optional } 8-28
zine to spindle ; Initiate tool transfer (physical / logical) from the magazine pocket in the
change position to the selected tool spindle.
TPE Tool pocket Syntax: TPE 8-30
empty? ; If the magazine/turret position that is currently in "Position 1" is not empty,
program execution is stopped and an error message is generated.
TSE Tool spindle Syntax: TSE 8-30
empty? ; If the tool location in "Position 1" is not empty, program execution is
stopped and an error message is generated.
TSM Tool from spindle Syntax: TSM(<position>,<spindle>) { (.,.) optional } 8-29
to magazine ; Initiate tool transfer (physical / logical) from the selected tool spindle to the
magazine pocket in the change position.
WER Wait until NC Syntax: WER <process number>: <event number> 7-4
event is reset ; Program processing is interrupted until the event is reset.
WES Wait until NC Syntax: WES <process number>: <event number> 7-3
event is set ; Program processing is interrupted until the event is set.
WP Wait for process Syntax: WP <process> 9-3
; The block processing is halted until the specified process is completed.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Appendix 15-13

15.4 File Header


The editors that are available in the user interface are not the only means
that may be used for creating an NC program. Any other external text
editor may also be used for that purpose.

Data import The NC programs created in this way can not contain a file header. When
these NC programs are read in, the designation, identified with "*", is pro-
vided as a new designation.
If the NC program does not contain a file header, it can not be checked
during import if the file to import is an NC program. During import, the file
name is offered as a new designator.

Example:

%NPG
*Progr. No. 1
%NPG

The lines of the file header have the following meaning:


Code Meaning
%NPG Identifies the file as an NC program
%MAC Identifies the file as an NC cycle
%VAR Identifies the file as an NC variable file
%EVT Identifies the file as an NC event file
%DCR Identifies the file as a D correction file
%OFT Identifies the file as an offset file
*Designator Program designator
%NPG Marks the end of the file header
%MAC Marks the end of the file header
%VAR Marks the end of the file header
%EVT Marks the end of the file header
%DCR Marks the end of the file header
%OFT Marks the end of the file header
Fig. 15-1: File header for all NC data

NC block numbers Externally created NC programs can be imported with or without an NC


block number. Renumbering is always implemented internally.
An exported NC program always contains NC block numbers.

Cycles If data is specifically transferred from an NC main program to an NC


subroutine with the assistance of variables (@xxx x= 1-9), then these
subroutines are called "NC cycles".

Detailed description Further detailed information concerning these functions of the NC cycles
can be found in the description "NC cycle description"
"DOK-MTC200-CYC*DES*V22-AW01-EN-P".

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
15-14 Appendix NC Programming Instructions

Cycle Header
Creating Input Menus for Cycles
Using an enhanced cycle header enables the user to read cycles into the
NC program in a menu-controlled and graphically supported manner.
Reading in this context means that the parameters required for the cycle
and the request are read from the enhanced cylinder header and are dis-
played in a data input menu of the MT GUI. The programmer para-
meterizes the cycle in the data entry page. Once the entry is terminated,
the data are entered into the NC program as NC program lines. Default
values and input limits can be defined; these are checked in the data en-
try menu.

G89_GER.bmp

Fig. 15-2: Entering parameters for the cycle header in the GUI

Header ID The enhanced cycle header must be identified as such. This identification
consists of a start and an end ID.

Start ID %CHBEGIN%
syntax
Explanation: CycleHeaderBEGIN

End ID %CHEND%
syntax
Explanation: CycleHeaderEND

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Appendix 15-15

NC Variables
NC variables to which the programmer is to assign a value in the input
menu are entered as follows in the enhanced file header:

Syntax %V% x:yyy


Explanation: Variable
x Process number [0-6] (optional)
y Variable number [0-255]
Optionally, a default value can be entered in the enhanced file header
when the above-mentioned command is modified as follows:

Syntax %V% x:yyy %D%n


Explanation: D Preset value
n Default value
The values of transfer parameters can be restricted in the enhanced file
header. In the data input menu of the GUI, the entry is checked against
this restriction.
Three data types are available as transfer values:
a) REAL (all numbers)

Syntax REAL [123.123..456.456] [text]

Explanation:
Input menu Text
First value: Minimum value (Min)
Second value: Maximum value (Max)
[text] Comment text
With Min < Max, the delimiter between the values is "..".
The sequence is checked and must be observed.

Example:

%V% 170 REAL Security clearance


%V% 171 INT [1,3] %D%0 Variant

b) INTEGER [integer numbers only)

Syntax INT [123-456] [text]

Explanation:
Input menu Text
First value: Minimum value (Min)
Second value: Maximum value (Max)
[text] Comment text
With Min < Max, the delimiter between the values is "..".
The sequence is checked and must be observed.

c) BOOLEAN (only numbers 1 and 0)


(corresponds to logical "Yes" (TRUE) or "No" (FALSE))

Syntax BOOL

Explanation: 1 corresponds to TRUE


0 corresponds to FALSE

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
15-16 Appendix NC Programming Instructions

Events
Events to which the programmer is to assign a certain initial state in the
input menu are entered as follows in the enhanced file header:

Syntax %E% x:yy

Explanation: Event
x Process number [0-6]
yy Event number [0-99]
Optionally, a default value can be entered in the enhanced file header
when the above-mentioned command is modified as follows:

Syntax %E% x:yy %D%n

Explanation: D Preset value


n Default value

Syntax BOOL [text, text]

Explanation:
Sequence of the parameters:
Range type Range
[text] Text for TRUE
[text] Text for FALSE
The delimiter between the texts for TRUE/FALSE is ",".

Example:

%E% 0:25 BOOL [start P0,do not start P0]


%E% 0:26 BOOL [milling at bottom, milling at top] %D%1

Standard Calls
If the cycle requires special calls, these can be integrated into the
enhanced cylinder header. These standard NC program lines are not
checked but are only copied into the request program. Several of these
lines are possible, but no NC block continuation lines.

Syntax %N%

Explanation: NC block

Example:

%N% @140=SIN(@151+@152) @141=COS(@151+@152)


%N% G0 X=@141 Y=@140
%N% BSR .UP23 [UP23 is processed to completion]
%N% []

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Appendix 15-17

Graphic File
To provide graphical support of the parameter entered in the data input
menu, graphic files can be defined in the enhanced cycle header; these
are displayed upon a corresponding operator entry.

Syntax %GF% FILE NAME TEXT

Explanation: GraphicFile
File formats: BMP or PCX
Resolution: 226 x 262 pixels
Colors: 16

During the installation of the user interface, a basic image with the name
CYCLE000.PCX is stored in the \MT-CNC\CYCLE\GRAPH directory. The
image can be edited using the graphic editor in the user interface.

Examples: cycle header for cycle G89 "Back spindles"

%CHBEGIN%
%GF%ZYKL89.PCX
%V% @171 Depth (abs)
%V% @172 Safety distance (abs)
%V% @173 Lift 1st main axis (inc)
%V% @174 Lift 3rd main axis (inc)
%V% @175 Feed
%V% @176 Dwell time
%N% BSR .*G89 ;Cycle call
%CHEND%

Example: primary block at a lathe

%CHBEGIN%
%GF% MAINBLOC.PCX
%V% @1 %D% 16 INT [ 15 - 16 ] Radius/diameter program
%V% @2 %D% 18 INT [ 17 - 19 ] Plane selection
%V% @3 %D% 48 INT [ 47 - 49 ] Tool length correction
%V% @4 %D% 54 INT [ 52 - 59 ] Zero offset
%V% @5 %D% 95 INT [ 65 - 95 ] Feed program
%V% @6 %D% 96 INT [ 96 - 97 ] Spindle speed program
%V% @7 %D% 0 INT [ 0 - 1 ] Interpolation functions
%V% @8 %D% 120 INT [ -30 - 130 ] Position of X-axis
%V% @9 %D% 50 INT [ 90 - 500 ] Position of Z-axis
%V% @10 %D% 200 INT [ 0 - 6000 ] Spindle RPM
%V% @11 %D% 4 INT [ 3 - 5 ] Spindle rotation direction
%N% G=@1 G=@2 G=@3 G=@4 G=@5 G=@6
%N% G=@7 X=@8 Z=@9 S=@10 M=@11
%CHEND%
A primary block is generated in the NC program from which reference is
made to an NC cycle.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
15-18 Appendix NC Programming Instructions

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Index 16-1

16 Index

$
$ 5-68

A
A00.052 8-5
A00.053 5-1
A00.054 5-5, 5-13, 5-42
A00.055 5-56, 5-57
A00.056 5-56, 5-58
A00.058 5-57
A00.061 5-5, 5-34
A00.069 5-5, 5-34
A00.070 5-5, 5-63
A00.074 5-5, 5-63
A00.075 5-5
A00.082 5-5
A00.083 5-5
A00.086 5-5
A00.091 5-5, 5-33, 5-34, 5-64, 5-66
A00.092 5-5, 5-63
A00.096 5-5, 5-63
ABS 10-8
Absolute value function 10-8
ACC 4-16
ACC_EFF command 13-11
Acceleration filter 4-78
Access to Tool Data from NC Program 'TLD' 5-86, 12-6
Access to tool data of NC program 'TLD'
General requirements 12-14
Optional parameters 12-14
ACD_COMP 13-12
Achsübergabe zwischen den Prozessen ‘FAX’, ‘GAX’ 9-6
ACOS 10-9
Activating and canceling tool path compensation
cancelling tool path compensation 'G40' 5-78
constant feed at contour 'G99' 5-84
constant feed on tool center line 'G98' 5-83
inserting a 'chamfer' transition element 'G44' 5-82
inserting transition element 'arc' 'G43' 5-82
tool path compensation, left 'G41' 5-79
tool path compensation, right 'G42' 5-79
Adaptive feed control 4-47
Additional spindle speed limitation 4-58
Additional tool carrier 8-4, 8-5, 8-6, 8-12
Address label
I, J, K 10-2
Address letter
Q 6-5, 10-3
R 10-2
S 4-52, 6-4
S, S[1-3] 10-2
ADJUST 3-38
ADJUST and REPOS subroutine 3-39
Adjustable zero offset - G59 3-7
Adjustable zero offsets - G54 3-7
Adressbuchstabe
ACC 10-2, 10-3
D 10-3
E 10-3
F 10-2
O 10-3
P 10-2
RX, RY, RZ 10-3
T 10-3

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
16-2 Index NC Programming Instructions

ADTRC command 13-11


Alternate tool chain 5-4
Alternate tool sequence 5-32
Alternate tools 5-10
Angle head tool 5-11
Angle of rotation P See Zero offsets
Angle of skew 5-65
Angle unit for trigonometric functions ‘RAD’, ‘DEG’ 10-5
AP command 9-3
Approach intermediate locations 8-15
APR card 4-65
APR function 4-39
APR Sercos parameters 12-1
data exchange with digital drives ‘AXD’
data block number 12-1
group letter 12-1
parameter set number 12-1
Data exchange with digital drives ‘AXD’
Data address 12-1
Data exchange with digital drives 'AXD' 12-1
SERCOS ID number 12-1
ASIN 10-9
ASIN function 10-9
ATAN 10-9
Automatic equipment check 5-2
Automatic Equipment Check 5-2
Auxiliary function buffer 3-40
Auxiliary functions ‘M’ 6-1
program control commands
conditional stop ‘M001’ 6-3
End of NC Program ‘M002 / M030’ 6-3
programmed stop (unconditional) ‘M000’ 6-3
spindle control commands
spindle counterclockwise and coolant/lubricant ON Mx14 6-3
Spindle control commands 6-3
spindle positioning 6-4
Auxiliary Functions ‘M’
Gear Changes 6-5
Available addresses 2-10
Available adresses
Address letters 2-10
AXD 3-41
AXD command 12-1
Axes 4-1
linear and rotary auxiliary axes 4-2
Linear main axes 4-1
rotary main axes 4-1
Axis filter, two-step 4-78
Restrictions 4-80
Axis meaning 4-65
Axis parameters 1-2
Axis transfer 3-42
Axis transfer between processes ‘FAX’, ‘GAX’ 9-6
free axis - FAX 9-6
get axis - GAX 9-6

B
Basic tool data 5-6
BEQ branch command 9-17
BER branch command 7-5, 9-17
BES branch command 7-5, 9-16
BEV command 7-7
Block instructions 11-3
BMI branch command 9-17
BNE branch command 9-17
Boring tool 5-10
BPL branch command 9-17
BRA branch command 9-9
Branches depending on arithmetic results
Branch If Equal to Zero 'BEQ' 9-17

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Index 16-3

Branch If Greater Than or Equal to Zero 'BPL' 9-17


Branch If Less Than Zero 'BMI' 9-17
Branch If Not Equal to Zero 'BNE' 9-17
Branches Depending on Arithmetic Results 9-17
BREAK 11-1
BREAK instruction 11-5
BRF branch command 9-16
BSE branch command 9-16
BSR command 9-12
BST command 9-9
BTE command 9-16
Bxx.014 8-5
Bxx.015 8-5
Bxx.029 5-58
Bxx.044 8-5
Bxx.057 8-5

C
Cancelling tool path compensation 'G40' See Activating and Canceling Tool
Path Compensation
Cartesian coordinate system 8-1 See Coordinate system
CEV 7-8
Chamfers 13-1
Chamfers and roundings 13-1
contiguous motion blocks 13-2
Illegal commands 13-2
No variables 13-3
Changing tools 8-8
combined circular and linear interpolation See Interpolation Functions - Helical
Interpolation
Conditional branches 9-16
Branch if NC Event is Reset 'BER' 9-17
Branch if NC Event is Set 'BES' 9-16
Branch if Spindle is Empty 'BSE' 9-16
Branch if T0 Was Set 'BTE' 9-16
Branch upon Reference 'BRF' 9-16
Conditional jumps 3-42
Constant cutting speed 8-6, 8-12
Constant feed at contour 'G99' See Activating and Canceling Tool Path
Compensation
Constant feed on tool center line 'G98' See Activating and Canceling Tool Path
Compensation
Constant surface speed 'G96' See Spindle Speed
Contact point 'B' 5-45
CONTINUE 11-1
CONTINUE instruction 11-5
Control software 1-1
Coordinate system 3-1
Coordinate transformation
face machining 4-63
lateral cylinder surface machining 4-63
COS 10-9
Current grinding wheel diameter 5-65
Current tool list 5-2
Cycle header 15-14
creating input menus for cycles 15-14
events 15-16
header ID 15-14
NC variables 15-15
standard calls 15-16
Cycle Header
graphic file 15-17

D
D corrections 1-3, 5-88
use 5-89
Data exchange with digital drives with SERCOS Interface 3-41
Default plane 8-1

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
16-4 Index NC Programming Instructions

DEG 10-5
DEV 7-8
Diameter programming 'G16' 3-24
Dimension entry
Absolute dimension entry ‘G90’ 3-3
Dimensions
incremental dimensions ‘G91’ 3-4
DIN 66025
Deviation from standard with G00 4-80
DP command 9-2
Dwell time 'G04' See Feed

E
EEV 7-8
Effective radii 'RX', 'RY', 'RZ' See Rotary Axis Programming
Elemente eines NC-Satzes 2-5
Elements of a NC Block 2-5
Elements of an NC block
skipping blocks 2-6
Enhanced look-ahead function 13-1
ACC_EFF change effective resulting path acceleration 13-11
access to current data in the controller 13-12
ADTRC loading distance to establish the tool radius path compensation 13-11
axis-related velocities 13-11
contiguous motion blocks 13-11
global variables 13-10
METB minimum execution time of an NC block 13-10
no variables 13-11
percentual acceleration correction 13-11
Possible uses 13-9
TL_RADIUS specify tool radius 13-10
Tool management 13-11
TRC tool radius compensation 13-11
Enhanced Look-Ahead Function 13-9
Equipment check 5-2
Event 3-42
Events
Asynchronous handling of NC events
Call Subroutine if Event is Set 'BEV' 7-7
Cancel NC Event Monitoring 'CEV' 7-8
Disable NC Event Monitoring 'DEV' 7-8
Enable NC Event Monitoring 'EEV' 7-8
Program Branching if NC Event is Set 'JEV' 7-8
conditional branches for events 7-5
Conditional branches for events
Branch if NC Event is Reset 'BER' 7-5
Branch if NC Event is Set 'BES' 7-5
influencing events 7-2
Influencing events
Reset Event 'RE' 7-3
Set Event 'SE' 7-2
Wait until NC Event is Reset 'WER' 7-4
Wait until NC Event is Set 'WES' 7-3
Interrupting NC events 7-6
Exact stop 4-80
Exact stop limit See Interpolation conditions – exact stop limit'G61'

F
F word See Feed
Facing 3-40
FAX 3-42, 9-6
feed 4-40
Feed
axis velocity 4-44
dwell time 'G04' 4-43
F word 4-40
feed rate per spindle revolution 'G95' 4-42
programmed path velocity (F) 4-44
for thread cutting

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Index 16-5

with RZ 4-45
without RZ 4-44
time programming 'G93' 4-41
velocity programming 'G94' 4-42
Feed against positive stop 3-40
Feed control 4-47
Feed rate per spindle revolution 'G95' See Feed
Feed to positive stop 3-31
cancel all axis preloads G76 3-34
feed to positive stop G75 3-32
Fixed location-encoded tools 5-30
Follower and Gantry axes
applications 4-75
auxiliary functions for synchronized operation 4-76
machine data for synchronized axis groups 4-77
NC programming 4-77
permissible configurations 4-76
steps of a follower operation 4-76
Follower axes and gantry axes 4-75
FOR 11-1
FOR instruction 11-4
Free plane selection 8-1
Functions 15-3

G
G00 4-18, 5-61, 5-62
G01 4-19
G02 4-20
G03 4-20
G04 4-43
G06 4-2
G07 4-5
G08 4-8
G09 4-10
G10 4-78, 4-80
G11 4-78, 4-80
G15 Radius programming 3-24
G17 8-1
G17 plane selection XY 3-17
G18 8-1
G18 plane selection ZX 3-17
G19 8-1
G19 plane selection YZ 3-17
G20 3-18, 8-1
G21 3-18, 8-1
G22 3-18, 8-1
G30 4-70
G31 4-63
G32 4-68
G33 4-28, 4-32
G36 4-61
G37 4-61
G38 4-61
G40 5-78, 8-8
G41 5-62, 5-79
G42 5-62, 5-79
G43 5-82
G44 5-82
G47 5-85, 8-8, 8-12
G48 5-58, 5-61, 5-85
G49 5-58, 5-61, 5-86
G50 3-7
G50 absolute 3-13
G51 3-7
G51 incremental 3-13
G52 3-7, 3-14
G53 3-15
G54 3-7, 8-8
G54 G59 3-9

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
16-6 Index NC Programming Instructions

G59 3-7
G61 4-80
G61 – Exact stop 4-12
G62 - Rapid NC Block Transition 4-14
G63 - Spindle stops at the end of movement 4-34
G64 - Spindle continues rotating after the end of motion 4-34
G65 4-38
G66 5-65
G66 Constant grinding wheel peripheral speed 4-55
G70 3-25
G71 3-26
G72 - Deactivate mirroring for all axes 3-27
G73 - Activate mirroring 3-25, 3-26, 3-27
G74 3-31, 8-10
G75 3-32
G76 3-34
G77 3-37
G78 - Scaling for all axes off 3-29
G90 3-3
G91 3-4
G92 4-57
G93 4-41
G94 4-42
G95 4-42
G96 4-56, 8-6, 8-12
G98 5-83
G99 5-84
GAX 3-42, 9-6
GAX command 9-6
Geometry registers 5-56
Go to axes reference point ‘G74’ 3-31
Graphic NC editor 13-13
function 13-13
Instructions 13-13
Graphical NC editor 13-1
Grinding wheel peripheral speed 4-55
Grinding wheel-specific tool data 5-64
Gripper 5-11

H
Helical interpolation See Interpolation Functions
HLT command 9-9
HMI function
Acknowledge tool change/ tool breakage 5-57
Home position 8-10
Homing axes 3-40

I
IF instruction 11-3
IF-ELSE 11-1
Inch data 3-25
Inclined axis 4-50
Inclined grinding wheel 5-67
Inserting a chamfer transition element 'G44' See Activating and canceling tool
path compensation
Inserting an arc transition element 'G43' See Activating and Canceling Tool Path
Compensation
INT 10-8
INT function 10-8
Interpolation conditions 4-2
Interpolation functions 4-18
circular interpolati 'G02' / 'G03'
Interpolation parameters I, J, K 4-21
circular interpolation 'G02' / 'G03'
circle radius programming 4-24
clockwise 'G02' 4-20
counterclockwise 'G03' 4-20
interpolation parameters I, J, K

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Index 16-7

machining on lathe in Z-X plane using absolute dimension input 4-24


machining on lathe in Z-X plane using incremental dimension input 4-24
helical interpolation 4-26
tapping 'G65' - spindle as lead axis 4-38
tapping 'G65' - spindle as master axis 4-37
tapping without compensating chuck 'G63' / 'G64' 4-34
thread cutting 'G33' 4-28
starting point and end point coordinates for X axis 4-30
taper threads 4-29
thread lead 4-28
thread length 4-28
thread starting angle 4-28
thread sequences with 'G33' 4-32
Invalid NC commands during transformation 4-64

J
Jerk filter 4-78
JEV command 7-8
JMP jump command 9-10
Jogging
With nonuniform tool pocket distribution 8-20
JSR command 9-11

L
LA_OFF 13-10
LA_ON 13-10
Lateral cylinder surf. machining
plane selection 4-68
Lateral cylinder surface machining 3-40, 4-67
LD function 10-10
Length compensation 5-58
Length wear factors 5-61
Level selection 3-16
LG function 10-10
Linear and rotary auxiliary axes See Axes
Linear Main Axes 4-1
LN function 10-10
Location data 5-30
Location-specific tool status bit 5-19
LP command 9-4

M
M functions 6-1
M000 6-3
M001 6-3
M002 / M030 6-3
M19 S... 6-4
Machine parameter
Bxx.034 Time constant for acceleration 4-78
Cxx.018 Maximumacceleration 4-78
Machining planes 8-1
Macro technique 13-1, 13-5
enhancing NC functions 13-5
macro 13-3
Main spindle synchronization 4-71
functions 4-71
Machine data for main spindle synchronization 4-74
permissible configurations 4-72
sequence of a synchronization operation
activate main spindle synchronization 4-73
deactivate synchronization 4-73
synchronization process 4-73
use 4-71
Mainspindlesynchronization
sequenceofasynchronizationoperation
auxiliaryfunctionsforselectingandcancelingmainspindlesynchronization 4-73
Mathematical expressions

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
16-8 Index NC Programming Instructions

functions
tangent - TAN 10-9
Mathematical expressions
Function
Arc-sine - ASIN
Angle unit - degrees 10-9
functions 10-8
absolute value - ABS 10-8
arc-cosine - ACOS 10-9
angle unit - radian 10-9
arc-sine - ASIN 10-9
arc-tangent - ATAN 10-9
cosine - COS 10-9
integer - INT 10-8
logarithm to base 10 - LG 10-10
logarithm to base 2 - LD 10-10
logarithm to base e - LN 10-10
power to base - E^ 10-10
power to base 10 - 10^ 10-10
power to base 2 - 2^ 10-10
sine - SIN 10-8
square root - SQRT 10-8
time in seconds - TIME 10-10
Functions
Arc-cosine ACOS
Angle unit - degrees 10-9
Inverse tangent - ATAN
Unit - degrees 10-10
operands 10-7
constants 10-7
floating-point constants 10-7
system constants 10-7
operators 10-7
addition + 10-7
division / 10-7
multiplication 10-7
remainder integer whole division (modulo) % 10-7
subtraction - 10-7
parentheses 10-8
Mathematical Expressions 10-6
Maximum grinding wheel circumferential speed 5-65
Maximum spindle speed 5-64
Measurement units 3-25
millimeters 'G71' 3-26
Measurements 3-3
MEN 8-19
METB command 13-10
MFP 8-5, 8-16
MHP 8-10
MHP 8-5, 8-20
Millimeter data 3-26
Milling tool 5-10
Minimum spindle speed (S min) 5-64
Mirror imaging of coordinate axes ‘G72’ / 'G73
mirroring one axis 3-27
Mirror imaging of coordinate axes ‘G72’ / 'G73' 3-27
MMA 8-15
MMP 8-5, 8-13, 8-20
Modal function 13-1, 13-7
drilling holes 13-7
Modal rounding and chamfering 13-8
MODF_OFF 13-7
MODF_ON 13-7
MODF_ON(STRI) - modal function ON 13-7
MOP 8-5, 8-17
Motion Blocks 4-1
Motion commands 3-2
coordinate value 3-2
Motion sequence 4-78, 4-80
MRF 8-5, 8-10
MRY 8-5, 8-19

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Index 16-9

MTD command 12-21


MTP 8-5, 8-11, 8-20
Mx05 6-3
Mx14 6-3
Mx40 6-5
Mx41 6-5
Mx42 6-5
Mx43 6-5
Mx44 6-5

N
NC compiler 13-1
NC Compiler Functions 13-1
NC control structures
Block instructions 11-3
BREAK 11-1
BREAK instruction 11-5
Conditions 11-2, 11-6
CONTINUE 11-1
CONTINUE instruction 11-5
FOR 11-1
FOR instruction 11-4
IF instruction 11-3
IF-ELSE 11-1
REPEAT-UNTIL 11-1
REPEAT-UNTIL instruction 11-4
SWITCH instruction 11-5
SWITCH-CASE 11-1
WHILE 11-1
WHILE instruction 11-4
NC cycle programs 1-3
NC events 1-3
NC program 2-1
NC program changeover between spindle and C axis See Rotary Axis
Programming
NC program package 1-3
NC program restart 3-38
NC program restart with ‘ADJUST’ and ‘REPOS’ 3-38
NC programming 14-1
NC syntax
Enhanced 11-1
NC variable 1-3
NC variables
Indexed 11-7
NC word 2-7
numerical value 2-7
NC wort
address letter 2-7
NC-specific peculiarities in NC block restart 3-40
Nonuniform spacing of tool positions 8-20
Nonuniform tool pocket distribution 8-20
Number of tool edges 5-13

O
O[0-9] 3-11
Offset register 5-56
Offsets 3-5
Operation without setup list 5-4
Organization of setup lists
program-specific organization 2-1
station-specific organization 2-1
Organization of setup lists 2-1
OTD command 3-15, 12-4

P
P 3-10
Parameters 1-2

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
16-10 Index NC Programming Instructions

PHI 3-10
PLC 3-42
POK command 9-5
Positions 1-4 8-20
Possible allocations between AXD, OTD, TLD, MTD
allocations between AXD, OTD, TLD, DCD and MTD commands
invalid allocations 12-25
Possible allocations between AXD, OTD, TLD, MTD, DCD 12-22
allocations between AXD, OTD, TLD and MTD commands 12-25
handling AXD commands
illegal allocations 12-22
possible allocations 12-22
handling DCD commands
illegal allocations 12-24
possible allocations 12-24
handling MTD commands
Invalid allocations 12-24
possible allocations 12-24
handling OTD commands
illegal allocations 12-23
possible allocations 12-23
handling TLD commands 12-23
illegal allocations 12-23
possible allocations 12-23
Preparing a tool 8-4
Preparing tools and tool data
selecting tool spindle ‘SPT’ 8-6
Preparing tools and tool data for a magazine 8-3
Preparing tools and tool data for a turret 8-4
Primary blocks 3-38
Process control commands 9-1
Define Process 'DP' 9-2
Lock Process 'LP' 9-4
Select NC Program for Process 'SP' 9-2
Start Advance Program 'AP' 9-3
Wait for Process 'WP' 9-3
Process parameter 1-3
Process-specific programming 2-4
Program control commands 9-9
Branch Absolute 'BRA' 9-9
Branch with Stop 'BST' 9-9
Jump to Another NC Program 'JMP' 9-10
Program End with Reset 'RET' 9-9
Programmed Halt 'HLT' 9-9
Program organization
program no. 99 2-2
reverse program 2-3
Program Organization
Advance program 2-3
Program No. 0 2-2
Program structure 2-2
Zero offset, absolute 3-7
Zero offset, incremental 3-7
Programmable absolute zero offset - G50 3-7
Programmable incremental zero offset - G51 3-7
Programmable work piece zero point - G52 3-7
Prozess-spezifische Programmierung 2-4
PxxC.MGITW 5-4, 5-29
PxxC.MGNSL 5-4, 5-60
PxxC.MGWTC 5-2
PxxS.MGCP 8-15
PxxS.MGTWO 5-39, 5-55
PxxS.MGWRN 5-40, 5-55

Q
Q function 6-5

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Index 16-11

R
RAD 10-5
Radius compensation 5-59
Radius programming 'G15' 3-24
Radiusverschleißfaktor 5-62
RD command 13-1
RDI 4-78, 4-79, 10-6
RE command 7-3
Read position value 3-42
Read/write D corrections from the NC program 'DCD' 12-19
Read/write machine data
purpose of machine data
required data structure 12-20
Read/write machine data elements 'MTD'
General requirements 12-21
Verifications during access 12-21
Read/Write Machine Data 12-20
Read/write zero offset data from the NC program 'OTD'
General requirements 12-5
Reading and writing ZO data to/from the NC program ‘OTD’ 12-4
Reading events in variable 7-10
Reference position 8-10
Remaining tool life in percent 5-53
REPEAT-UNTIL 11-1
REPEAT-UNTIL instruction 11-4
Replacement tool s 5-26
REPOS 3-38
Reposition and restart to the contour
reposition in the automatic operating modes 3-36
Repositioning and NC block restart to the contour 3-36
Repositioning and restarting to contour
repositioning and restarting to destination position 'G77' 3-37
RET command 9-9
REV_SYNC 8-5
Reverse vectors 9-13
set reverse vector ‘REV’
clear reverse vectors by control-reset 9-15
Set Reverse Vector 'REV' 9-13
Right-hand rule 3-1
Rotary axis programming 4-60
approach logic for endlessly rotating rotary axes
modulo calculation
negative direction ‘G38’ 4-62
positive direction ‘G37’ 4-62
shortest path ‘G36’ 4-62
effective radii 'RX', 'RY', 'RZ' 4-60
NC program changeover between spindle and C axis 4-61
changeover with rotary axis-capable main spindle drive 4-61
rotary axis start-up logic
modulo calculation 4-61
Rotary main axes 4-1 See Axes
Round distance RDI 4-79, 10-6
Rounding 13-1
Rounding of NC blocks with axis filter
enabling/disabling 4-79, 4-80, 10-6
Rounding within a motion sequence 4-80
Rounding of NC blocks with axis filter G11 / RDI 4-78
RP command 9-3
RTS command 9-12
RX 4-60
RY 4-60
RZ 4-60

S
S 4-52
S max 5-64
S min 5-64
S word 6-5

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
16-12 Index NC Programming Instructions

S word for the spindle speed specification See Spindle Speed


Scaling 'G78' / 'G79' 3-29
Schleifspezifische Werkzeugdaten 5-64
SE command 7-2
Segmented tool magazines 8-6
Select main spindle 'SPF' See Spindle Speed
Set Event 'SE' 7-2
Setup list 5-1
Setup-list-specific tool status bits 5-16
SIN 10-8
SIN function 10-8
Skipped block 3-39
Skipping blocks See Elements of an NC block
SP command 9-2
SPC <spindle nummer> 4-71
SPF <spindle number> 4-53
Spindle control commands 3-40
Spindle control commands M003, M004, M005, M013, M014 6-3
Spindle speed 4-52
constant surface speed 'G96' 4-56
S word for the spindle speed specification 4-52
select main spindle 'SPF' 4-53
spindle speed in RPM 'G97' 4-59
spindle speed limitation 'G92' 4-57
Spindle speed in RPM 'G97' See Spindle Speed
Spindle speed limitation 'G92' See Spindle Speed
SPT <spindle number> 8-6
SQRT 10-8
SQRT function 10-8
Straight circumferential grinding wheel 5-66
Subroutines 9-10
Jump to NC Subroutine 'JSR' 9-11
Return from NC Subroutine 'RTS' 9-12
Subroutine Call 'BSR' 9-12
subroutine nesting 9-11
subroutine structure 9-11
subroutine technique 9-10
SUG max 5-65
Surface grinding wheel 5-67
SWITCH instruction 11-5
SWITCH-CASE 11-1
S-Word as Auxiliary Function 6-5
System parameters 1-2

T
TAN 10-9
TAN function 10-9
Tapping 4-37
Tapping 'G65' See Interpolation Functions See Interpolation Functions
Tapping without compensating chuck 'G63' / 'G64' See Interpolation Functions
TCH 8-4, 8-22
Technology data 5-33
Theoretical edge tip 5-44
Thread cutting 'G33' See Interpolation Functions
Thread sequence 4-32
Thread Sequences with 'G33' See Interpolation Functions
TID 5-2
TIME 10-10
TIME function 10-10
Time programming 'G93' See Feed
Time-optimized NC programming
CNC time data 14-4
priorities 14-2
programming in the NC block 14-1
stopping block preparation by NC commands 14-3
time data with digital drives 14-4
Time-Optimized NC Programming 14-1
TL_RADIUS command 13-10
TLD 5-86, 12-6

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Index 16-13

TLD command 12-23


TMS 8-23
TMS 8-4, 8-23
Tool change positions 8-20
Tool changing commands of the NC 8-21
Tool Compensation 4-65
Tool data record 5-5
Tool edge data 5-42
Tool edge identification 5-44
Tool edge invocation 8-6
Tool editor
Edit 5-23, 5-24, 5-57
Tool exchange 8-22
Tool group 8-6
Tool group data 5-35
Tool group duplo number 8-6
Tool Group Management 8-6
Tool group number 8-6
Tool identification 5-7
Tool length compensation
active tool length compensation 5-85
inactive tool length compensation 5-84
no tool length compensation 'G47' 5-85
Tool length correction 5-84
tool length correction, negative 'G49' 5-86
Tool length correction, positive 'G48' 5-85
Tool life data 5-53
Tool list 1-3
Tool number 5-9
Tool path compensation 5-68
active tool path compensation 5-69
change in direction of compensation 5-78
contour transitions
inside corners 5-70
outside corners 5-70
insertion of arc as transition element with G43 5-70
insertion of chamfer as transition element with G44 5-70
Establishment of tool path compensation at start of contour 5-74
inactive tool path compensation 5-68
Removal of tool path compensation at end of contour 5-76
Tool path compensation, left 'G41' See Activating and Canceling Tool Path
Compensation
Tool path compensation, right 'G42' See Activating and Canceling Tool Path
Compensation
Tool preselection 8-3
Tool setup list 1-4
Tool status (bits) 5-13
Tool storage unit motion commands of the NC 8-9
Tool-specific tool status bit 5-23
TPE 8-24
Transformation
selecting lateral cylinder surf. machining G32 4-67
Transformations 4-63, 4-81
deselection of transformation G30 4-70
deselection of lateral cylinder surface coordinate transformation G32 4-70
deselection of transformations G30
deselection of face transformation G31 4-70
select face machining G31 4-63, 4-66
select main spindle for transformation 'SPC' 4-70
translation and rotation movements 4-60
Travel limits for transformation G31 4-66
Traverse range limits 3-34
TRC command 13-11
Trigonometric functions SIN, COS, TAN 10-5
TSE 8-24
TSM 8-23, 8-24
Turning center
selection and axis allocation 3-23
Turning tool 5-10

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
16-14 Index NC Programming Instructions

U
Units 5-33
User tool data 5-34
User tool edge data 5-63
Using the transformation function 4-63

V
Variable Assignments and Arithmetic Functions 10-1
Variables 10-1
data representation 10-1
negating the contents of a variable 10-1
value assignment 10-1
variable assignment 10-2
acceleration factor 10-2, 10-3
angle 10-2
auxiliary function 10-3
coordinate values of existing axes 10-2
D correction 10-3
effective distances 10-3
feed rate 10-2
G functions 10-3
interpolation parameters 10-2
M functions 10-4
radius 10-2
spindle speed 10-2
tool edge number 10-3
zero offset table 10-3
Variable assignment
Tool number 10-3
variable assignments
angle
angle of rotation ‘P’ 10-2
starting angle ‘P’ 10-2

W
Wear factors 5-61
Wear registers 5-57
WES 7-3
WHILE 11-1
WHILE instruction 11-4
workpiece zero point, programmable - G52 3-7
WP command 9-3

Z
Zero offset, adjustable - G59 3-7
Zero offsets 3-7
additional tool carrier 8-4, 8-5, 8-6, 8-12
adjustable general offset in the zero offset table 3-15
adjustable zero offsets ‘G54 - G59’ 3-9
cancel zero offsets 'G53' 3-15
coordinate rotation with angle of rotation 'P' 3-10
programmable absolute zero offset 'G50' 3-13
programmable incremental zero offset 'G51' 3-13
read/write zero offset data from NC program via ‘OTD’ 3-15
sum of zero offsets 3-8
zero offset tables ‘O’ 3-11
Zero Offsets
programmable zero point of workpiece 'G52' 3-14
Zero offsets, adjustable - G54 3-7
Zero points 1-4
machine reference point 3-5
machine zero point 3-5
workpiece zero point 3-5

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Service & Support 17-1

17 Service & Support

17.1 Helpdesk
Unser Kundendienst-Helpdesk im Hauptwerk Lohr Our service helpdesk at our headquarters in Lohr am
am Main steht Ihnen mit Rat und Tat zur Seite. Main, Germany can assist you in all kinds of inquiries.
Sie erreichen uns Contact us

- telefonisch - by phone: 49 (0) 9352 40 50 60


über Service Call Entry Center Mo-Fr 07:00-18:00
- via Service Call Entry Center Mo-Fr 7:00 am - 6:00 pm

- per Fax - by fax: +49 (0) 9352 40 49 41

- per e-Mail - by e-mail: [email protected]

17.2 Service-Hotline
Außerhalb der Helpdesk-Zeiten ist der Service After helpdesk hours, contact our service
direkt ansprechbar unter department directly at

+49 (0) 171 333 88 26


oder - or +49 (0) 172 660 04 06

17.3 Internet

Unter www.boschrexroth.com finden Sie At www.boschrexroth.com you may find


ergänzende Hinweise zu Service, Reparatur und additional notes about service, repairs and training
Training sowie die aktuellen Adressen *) unserer in the Internet, as well as the actual addresses *)
auf den folgenden Seiten aufgeführten Vertriebs- of our sales- and service facilities figuring on the
und Servicebüros. following pages.
Verkaufsniederlassungen sales agencies
Niederlassungen mit Kundendienst offices providing service
Außerhalb Deutschlands nehmen Sie bitte zuerst Kontakt mit Please contact our sales / service office in your area first.
unserem für Sie nächstgelegenen Ansprechpartner auf.
*) Data in the present documentation may have become
*) Die Angaben in der vorliegenden Dokumentation können obsolete since printing.
seit Drucklegung überholt sein.

17.4 Vor der Kontaktaufnahme... - Before contacting us...


Wir können Ihnen schnell und effizient helfen wenn For quick and efficient help, please have the
Sie folgende Informationen bereithalten: following information ready:
1. detaillierte Beschreibung der Störung und der 1. Detailed description of the failure and
Umstände. circumstances.
2. Angaben auf dem Typenschild der 2. Information on the type plate of the affected
betreffenden Produkte, insbesondere products, especially type codes and serial
Typenschlüssel und Seriennummern. numbers.
3. Tel.-/Faxnummern und e-Mail-Adresse, unter 3. Your phone/fax numbers and e-mail address,
denen Sie für Rückfragen zu erreichen sind. so we can contact you in case of questions.

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
17-2 Service & Support NC Programming Instructions

17.5 Kundenbetreuungsstellen - Sales & Service Facilities

Deutschland – Germany vom Ausland: (0) nach Landeskennziffer weglassen!


from abroad: don’t dial (0) after country code!

Vertriebsgebiet Mitte
Germany Centre SERVICE SERVICE SERVICE
Rexroth Indramat GmbH CALL ENTRY CENTER HOTLINE ERSATZTEILE / SPARES
Bgm.-Dr.-Nebel-Str. 2 / Postf. 1357 MO – FR MO – FR verlängerte Ansprechzeit
97816 Lohr am Main / 97803 Lohr von 07:00 - 18:00 Uhr von 17:00 - 07:00 Uhr - extended office time -
Kompetenz-Zentrum Europa
from 5 pm - 7 am ♦ nur an Werktagen
from 7 am – 6 pm + SA / SO - only on working days -
Tel.: +49 (0)9352 40-0 Tel.: +49 (0)172 660 04 06 ♦ von 07:00 - 18:00 Uhr
Tel. +49 (0) 9352 40 50 60
Fax: +49 (0)9352 40-4885 oder / or - from 7 am - 6 pm -
[email protected] Tel.: +49 (0)171 333 88 26 Tel. +49 (0) 9352 40 42 22

Vertriebsgebiet Süd Vertriebsgebiet West Gebiet Südwest


Germany South Germany West Germany South-West
Bosch Rexroth AG Bosch Rexroth AG Bosch Rexroth AG
Landshuter Allee 8-10 Regionalzentrum West Service-Regionalzentrum Süd-West
80637 München Borsigstrasse 15 Siemensstr.1
40880 Ratingen 70736 Fellbach
Tel.: +49 (0)89 127 14-0 Tel.: +49 (0)2102 409-0 Tel.: +49 (0)711 51046–0
Fax: +49 (0)89 127 14-490 Fax: +49 (0)2102 409-406 Fax: +49 (0)711 51046–248
+49 (0)2102 409-430

Vertriebsgebiet Nord Vertriebsgebiet Mitte Vertriebsgebiet Ost Vertriebsgebiet Ost


Germany North Germany Centre Germany East Germany East
Bosch Rexroth AG Bosch Rexroth AG Bosch Rexroth AG Bosch Rexroth AG
Walsroder Str. 93 Regionalzentrum Mitte Beckerstraße 31 Regionalzentrum Ost
30853 Langenhagen Waldecker Straße 13 09120 Chemnitz Walter-Köhn-Str. 4d
Tel.: +49 (0) 511 72 66 57-0 64546 Mörfelden-Walldorf 04356 Leipzig
Service: +49 (0) 511 72 66 57-256
Fax: +49 (0) 511 72 66 57-93 Tel.: +49 (0) 61 05 702-3 Tel.: +49 (0)371 35 55-0 Tel.: +49 (0)341 25 61-0
Service: +49 (0) 511 72 66 57-783 Fax: +49 (0) 61 05 702-444 Fax: +49 (0)371 35 55-333 Fax: +49 (0)341 25 61-111

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Service & Support 17-3

Europa (West) - Europe (West)


vom Ausland: (0) nach Landeskennziffer weglassen, Italien: 0 nach Landeskennziffer mitwählen
from abroad: don’t dial (0) after country code, Italy: dial 0 after country code

Austria - Österreich Austria – Österreich Belgium - Belgien Denmark - Dänemark


Bosch Rexroth GmbH Bosch Rexroth GmbH Bosch Rexroth NV/SA BEC A/S
Electric Drives & Controls Electric Drives & Controls Henri Genessestraat 1 Zinkvej 6
Stachegasse 13 Industriepark 18 1070 Bruxelles 8900 Randers
1120 Wien 4061 Pasching
Tel.: +43 (0)1 985 25 40 Tel.: +43 (0)7221 605-0 Tel: +32 (0) 2 582 31 80 Tel.: +45 (0)87 11 90 60
Fax: +43 (0)1 985 25 40-93 Fax: +43 (0)7221 605-21 Fax: +32 (0) 2 582 43 10 Fax: +45 (0)87 11 90 61
[email protected]
[email protected]

Great Britain – Großbritannien Finland - Finnland France - Frankreich France - Frankreich


Bosch Rexroth Ltd. Bosch Rexroth Oy Bosch Rexroth SAS Bosch Rexroth SAS
Electric Drives & Controls Electric Drives & Controls Electric Drives & Controls Electric Drives & Controls
Broadway Lane, South Cerney Ansatie 6 Avenue de la Trentaine ZI de Thibaud, 20 bd. Thibaud
Cirencester, Glos GL7 5UH 017 40 Vantaa (BP. 74) (BP. 1751)
77503 Chelles Cedex 31084 Toulouse
Tel.: +44 (0)1285 863000 Tel.: +358 (0)9 84 91-11 Tel.: +33 (0)164 72-70 00 Tel.: +33 (0)5 61 43 61 87
Fax: +44 (0)1285 863030 Fax: +358 (0)9 84 91-13 60 Fax: +33 (0)164 72-63 00 Fax: +33 (0)5 61 43 94 12
[email protected] Hotline: +33 (0)608 33 43 28
[email protected]

France – Frankreich Italy - Italien Italy - Italien Italy - Italien


Bosch Rexroth SAS Bosch Rexroth S.p.A. Bosch Rexroth S.p.A. Bosch Rexroth S.p.A.
Electric Drives & Controls Via G. Di Vittorio, 1 Via Paolo Veronesi, 250 Via Mascia, 1
91, Bd. Irène Joliot-Curie 20063 Cernusco S/N.MI 10148 Torino 80053 Castellamare di Stabia NA
69634 Vénissieux – Cedex Hotline: +39 02 92 365 563
Tel.: +33 (0)4 78 78 53 65 Tel.: +39 02 92 365 1 Tel.: +39 011 224 88 11 Tel.: +39 081 8 71 57 00
Fax: +33 (0)4 78 78 53 62 Service: +39 02 92 365 326 Fax: +39 011 224 88 30 Fax: +39 081 8 71 68 85
Fax: +39 02 92 365 500
Service: +39 02 92 365 503

Italy - Italien Italy - Italien Netherlands - Niederlande/Holland Netherlands – Niederlande/Holland


Bosch Rexroth S.p.A. Bosch Rexroth S.p.A. Bosch Rexroth Services B.V. Bosch Rexroth B.V.
Via del Progresso, 16 (Zona Ind.) Via Isonzo, 61 Technical Services Kruisbroeksestraat 1
35020 Padova 40033 Casalecchio di Reno (Bo) Kruisbroeksestraat 1 (P.O. Box 32)
(P.O. Box 32) 5281 RV Boxtel
5281 RV Boxtel
Tel.: +39 049 8 70 13 70 Tel.: +39 051 29 86 430 Tel.: +31 (0) 411 65 16 40 Tel.: +31 (0) 411 65 19 51
Fax: +39 049 8 70 13 77 Fax: +39 051 29 86 490 +31 (0) 411 65 17 27 Fax: +31 (0) 411 65 14 83
Fax: +31 (0) 411 67 78 14 www.boschrexroth.nl
+31 (0) 411 68 28 60
[email protected]

Norway - Norwegen Spain - Spanien Spain – Spanien Sweden - Schweden


Bosch Rexroth AS Bosch Rexroth S.A. Goimendi S.A. Bosch Rexroth AB
Electric Drives & Controls Electric Drives & Controls Electric Drives & Controls Electric Drives & Controls
Berghagan 1 or: Box 3007 Centro Industrial Santiga Parque Empresarial Zuatzu - Varuvägen 7
1405 Ski-Langhus 1402 Ski Obradors s/n C/ Francisco Grandmontagne no.2 (Service: Konsumentvägen 4, Älfsjö)
08130 Santa Perpetua de Mogoda 20018 San Sebastian 125 81 Stockholm
Tel.: +47 (0) 64 86 41 00 Barcelona
Tel.: +34 9 37 47 94 00 Tel.: +34 9 43 31 84 21 Tel.: +46 (0)8 727 92 00
Fax: +47 (0) 64 86 90 62 Fax: +34 9 37 47 94 01 - service: +34 9 43 31 84 56 Fax: +46 (0)8 647 32 77
Fax: +34 9 43 31 84 27
Hotline: +47 (0)64 86 94 82 - service: +34 9 43 31 84 60
[email protected] [email protected]

Sweden - Schweden Switzerland East - Schweiz Ost Switzerland West - Schweiz West
Bosch Rexroth AB Bosch Rexroth Schweiz AG Bosch Rexroth Suisse SA
Electric Drives & Controls Electric Drives & Controls Av. Général Guisan 26
Ekvändan 7 Hemrietstrasse 2 1800 Vevey 1
254 67 Helsingborg 8863 Buttikon
Tel.: +46 (0) 42 38 88 -50 Tel. +41 (0) 55 46 46 111 Tel.: +41 (0)21 632 84 20
Fax: +46 (0) 42 38 88 -74 Fax +41 (0) 55 46 46 222 Fax: +41 (0)21 632 84 21

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
17-4 Service & Support NC Programming Instructions

Europa (Ost) - Europe (East)


vom Ausland: (0) nach Landeskennziffer weglassen
from abroad: don’t dial (0) after country code

Czech Republic - Tschechien Czech Republic - Tschechien Hungary - Ungarn Poland – Polen
Bosch -Rexroth, spol.s.r.o. DEL a.s. Bosch Rexroth Kft. Bosch Rexroth Sp.zo.o.
Hviezdoslavova 5 Strojírenská 38 Angol utca 34 ul. Staszica 1
627 00 Brno 591 01 Zdar nad Sázavou 1149 Budapest 05-800 Pruszków
Tel.: +420 (0)5 48 126 358 Tel.: +420 566 64 3144 Tel.: +36 (1) 422 3200 Tel.: +48 22 738 18 00
Fax: +420 (0)5 48 126 112 Fax: +420 566 62 1657 Fax: +36 (1) 422 3201 – service: +48 22 738 18 46
Fax: +48 22 758 87 35
– service: +48 22 738 18 42

Poland – Polen Romania - Rumänien Romania - Rumänien Russia - Russland


Bosch Rexroth Sp.zo.o. East Electric S.R.L. Bosch Rexroth Sp.zo.o. Bosch Rexroth OOO
Biuro Poznan Bdul Basarabia no.250, sector 3 Str. Drobety nr. 4-10, app. 14 Wjatskaja ul. 27/15
ul. Dabrowskiego 81/85 73429 Bucuresti 70258 Bucuresti, Sector 2 127015 Moskau
60-529 Poznan Tel./Fax:: +40 (0)21 255 35 07 Tel.: +40 (0)1 210 48 25 Tel.: +7-095-785 74 78
Tel.: +48 061 847 64 62 /-63 +40 (0)21 255 77 13 +40 (0)1 210 29 50 +7-095 785 74 79
Fax: +48 061 847 64 02 Fax: +40 (0)21 725 61 21 Fax: +40 (0)1 210 29 52 Fax: +7 095 785 74 77
[email protected] [email protected]

Russia - Russland Turkey - Türkei Turkey - Türkei Slowenia - Slowenien


ELMIS Bosch Rexroth Otomasyon Servo Kontrol Ltd. Sti. DOMEL
10, Internationalnaya San & Tic. A..S. Perpa Ticaret Merkezi B Blok Otoki 21
246640 Gomel, Belarus Fevzi Cakmak Cad No. 3 Kat: 11 No: 1609 64 228 Zelezniki
Tel.: +375/ 232 53 42 70 34630 Sefaköy Istanbul 80270 Okmeydani-Istanbul
+375/ 232 53 21 69 Tel.: +90 212 541 60 70 Tel: +90 212 320 30 80 Tel.: +386 5 5117 152
Fax: +375/ 232 53 37 69 Fax: +90 212 599 34 07 Fax: +90 212 320 30 81 Fax: +386 5 5117 225
[email protected] [email protected] [email protected]
www.servokontrol.com

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions Service & Support 17-5

Africa, Asia, Australia – incl. Pacific Rim

Australia - Australien Australia - Australien China China


AIMS - Australian Industrial Bosch Rexroth Pty. Ltd. Shanghai Bosch Rexroth Shanghai Bosch Rexroth
Machinery Services Pty. Ltd. No. 7, Endeavour Way Hydraulics & Automation Ltd. Hydraulics & Automation Ltd.
28 Westside Drive Braeside Victoria, 31 95 Waigaoqiao, Free Trade Zone 4/f, Marine Tower
Laverton North Vic 3026 Melbourne No.122, Fu Te Dong Yi Road No.1, Pudong Avenue
Melbourne Shanghai 200131 - P.R.China Shanghai 200120 - P.R.China
Tel.: +61 3 93 14 3321 Tel.: +61 3 95 80 39 33 Tel.: +86 21 58 66 30 30 Tel: +86 21 68 86 15 88
Fax: +61 3 93 14 3329 Fax: +61 3 95 80 17 33 Fax: +86 21 58 66 55 23 Fax: +86 21 58 40 65 77
Hotlines: +61 3 93 14 3321 [email protected] [email protected]
+61 4 19 369 195 [email protected]
[email protected]

China China China China


Bosch Rexroth China Ltd. Bosch Rexroth China Ltd. Bosch Rexroth (China) Ltd. Melchers GmbH
15/F China World Trade Center Guangzhou Repres. Office A-5F., 123 Lian Shan Street BRC-SE, Tightening & Press-fit
1, Jianguomenwai Avenue Room 1014-1016, Metro Plaza, Sha He Kou District 13 Floor Est Ocean Centre
Beijing 100004, P.R.China Tian He District, 183 Tian He Bei Rd Dalian 116 023, P.R.China No.588 Yanan Rd. East
Guangzhou 510075, P.R.China 65 Yanan Rd. West
Shanghai 200001
Tel.: +86 10 65 05 03 80 Tel.: +86 20 8755-0030 Tel.: +86 411 46 78 930 Tel.: +86 21 6352 8848
Fax: +86 10 65 05 03 79 +86 20 8755-0011 Fax: +86 411 46 78 932 Fax: +86 21 6351 3138
Fax: +86 20 8755-2387

Hongkong India - Indien India - Indien India - Indien


Bosch Rexroth (China) Ltd. Bosch Rexroth (India) Ltd. Bosch Rexroth (India) Ltd. Bosch Rexroth (India) Ltd.
th
6 Floor, Electric Drives & Controls Electric Drives & Controls S-10, Green Park Extension
Yeung Yiu Chung No.6 Ind Bldg. Plot. No.96, Phase III Advance House, II Floor New Delhi – 110016
19 Cheung Shun Street Peenya Industrial Area Ark Industrial Compound
Cheung Sha Wan, Bangalore – 560058 Narol Naka, Makwana Road
Kowloon, Hongkong Andheri (East), Mumbai - 400 059
Tel.: +852 22 62 51 00 Tel.: +91 80 51 17 0-211...-218 Tel.: +91 22 28 56 32 90 Tel.: +91 11 26 56 65 25
Fax: +852 27 41 33 44 Fax: +91 80 83 94 345 +91 22 28 56 33 18 +91 11 26 56 65 27
[email protected] +91 80 83 97 374 Fax: +91 22 28 56 32 93 Fax: +91 11 26 56 68 87
[email protected] [email protected] [email protected]

Indonesia - Indonesien Japan Japan Korea


PT. Bosch Rexroth Bosch Rexroth Automation Corp. Bosch Rexroth Automation Corp. Bosch Rexroth-Korea Ltd.
Building # 202, Cilandak Service Center Japan Electric Drives & Controls Electric Drives and Controls
Commercial Estate Yutakagaoka 1810, Meito-ku, 2F, I.R. Building Bongwoo Bldg. 7FL, 31-7, 1Ga
Jl. Cilandak KKO, Jakarta 12560 NAGOYA 465-0035, Japan Nakamachidai 4-26-44, Tsuzuki-ku Jangchoong-dong, Jung-gu
YOKOHAMA 224-0041, Japan Seoul, 100-391
Tel.: +62 21 7891169 (5 lines) Tel.: +81 52 777 88 41 Tel.: +81 45 942 72 10 Tel.: +82 234 061 813
Fax: +62 21 7891170 - 71 +81 52 777 88 53 Fax: +81 45 942 03 41 Fax: +82 222 641 295
[email protected] +81 52 777 88 79
Fax: +81 52 777 89 01

Korea Malaysia Singapore - Singapur South Africa - Südafrika


Bosch Rexroth-Korea Ltd. Bosch Rexroth Sdn.Bhd. Bosch Rexroth Pte Ltd TECTRA Automation (Pty) Ltd.
1515-14 Dadae-Dong, Saha-gu 11, Jalan U8/82, Seksyen U8 15D Tuas Road 71 Watt Street, Meadowdale
Electric Drives & Controls 40150 Shah Alam Singapore 638520 Edenvale 1609
Pusan Metropolitan City, 604-050 Selangor, Malaysia
Tel.: +82 51 26 00 741 Tel.: +60 3 78 44 80 00 Tel.: +65 68 61 87 33 Tel.: +27 11 971 94 00
Fax: +82 51 26 00 747 Fax: +60 3 78 45 48 00 Fax: +65 68 61 18 25 Fax: +27 11 971 94 40
[email protected] [email protected] sanjay.nemade Hotline: +27 82 903 29 23
[email protected] @boschrexroth.com.sg [email protected]

Taiwan Thailand
Bosch Rexroth Co., Ltd. NC Advance Technology Co. Ltd.
Taichung Branch 59/76 Moo 9
1F., No. 29, Fu-Ann 5th Street, Ramintra road 34
Xi-Tun Area, Taichung City Tharang, Bangkhen,
Taiwan, R.O.C. Bangkok 10230
Tel : +886 - 4 -23580400 Tel.: +66 2 943 70 62
Fax: +886 - 4 -23580402 +66 2 943 71 21
[email protected] Fax: +66 2 509 23 62
[email protected] Hotline +66 1 984 61 52
[email protected] [email protected]

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
17-6 Service & Support NC Programming Instructions

Nordamerika – North America


USA USA Central Region - Mitte USA Southeast Region - Südwest USA SERVICE-HOTLINE
Headquarters - Hauptniederlassung
Bosch Rexroth Corporation Bosch Rexroth Corporation
Bosch Rexroth Corporation Electric Drives & Controls Electric Drives & Controls
- 7 days x 24hrs -
Electric Drives & Controls Central Region Technical Center Southeastern Technical Center
5150 Prairie Stone Parkway 1701 Harmon Road 3625 Swiftwater Park Drive
Hoffman Estates, IL 60192-3707 Auburn Hills, MI 48326 Suwanee, Georgia 30124
+1-800-REX-ROTH
Tel.: +1 847 6 45 36 00 Tel.: +1 248 3 93 33 30 Tel.: +1 770 9 32 32 00 +1 800 739 7684
Fax: +1 847 6 45 62 01 Fax: +1 248 3 93 29 06 Fax: +1 770 9 32 19 03
[email protected]
[email protected]

USA East Region – Ost USA Northeast Region – Nordost USA West Region – West
Bosch Rexroth Corporation Bosch Rexroth Corporation Bosch Rexroth Corporation
Electric Drives & Controls Electric Drives & Controls 7901 Stoneridge Drive, Suite 220
Charlotte Regional Sales Office Northeastern Technical Center Pleasant Hill, California 94588
14001 South Lakes Drive 99 Rainbow Road
Charlotte, North Carolina 28273 East Granby, Connecticut 06026
Tel.: +1 704 5 83 97 62 Tel.: +1 860 8 44 83 77 Tel.: +1 925 227 10 84
+1 704 5 83 14 86 Fax: +1 860 8 44 85 95 Fax: +1 925 227 10 81

Canada East - Kanada Ost Canada West - Kanada West Mexico Mexico
Bosch Rexroth Canada Corporation Bosch Rexroth Canada Corporation Bosch Rexroth Mexico S.A. de C.V. Bosch Rexroth S.A. de C.V.
Burlington Division 5345 Goring St. Calle Neptuno 72 Calle Argentina No 3913
3426 Mainway Drive Burnaby, British Columbia Unidad Ind. Vallejo Fracc. las Torres
Burlington, Ontario Canada V7J 1R1 07700 Mexico, D.F. 64930 Monterrey, N.L.
Canada L7M 1A8
Tel.: +1 905 335 5511 Tel. +1 604 205 5777 Tel.: +52 55 57 54 17 11 Tel.: +52 81 83 65 22 53
Fax: +1 905 335 4184 Fax +1 604 205 6944 Fax: +52 55 57 54 50 73 +52 81 83 65 89 11
Hotline: +1 905 335 5511 Hotline: +1 604 205 5777 [email protected] +52 81 83 49 80 91
[email protected] [email protected] Fax: +52 81 83 65 52 80
[email protected]

Südamerika – South America


Argentina - Argentinien Argentina - Argentinien Brazil - Brasilien Brazil - Brasilien
Bosch Rexroth S.A.I.C. NAKASE Bosch Rexroth Ltda. Bosch Rexroth Ltda.
"The Drive & Control Company" Servicio Tecnico CNC Av. Tégula, 888 R. Dr.Humberto Pinheiro Vieira, 100
Rosario 2302 Calle 49, No. 5764/66 Ponte Alta, Atibaia SP Distrito Industrial [Caixa Postal 1273]
B1606DLD Carapachay B1653AOX Villa Balester CEP 12942-440 89220-390 Joinville - SC
Provincia de Buenos Aires Provincia de Buenos Aires
Tel.: +54 11 4756 01 40 Tel.: +54 11 4768 36 43 Tel.: +55 11 4414 56 92 Tel./Fax: +55 47 473 58 33
+54 11 4756 02 40 Fax: +54 11 4768 24 13 +55 11 4414 56 84 Mobil: +55 47 9974 6645
+54 11 4756 03 40 Hotline: +54 11 155 307 6781 Fax sales: +55 11 4414 57 07 [email protected]
+54 11 4756 04 40 [email protected] Fax serv.: +55 11 4414 56 86
Fax: +54 11 4756 01 36 [email protected] [email protected]
+54 11 4721 91 53 [email protected] (Service)
[email protected]

Columbia - Kolumbien
Reflutec de Colombia Ltda.
Calle 37 No. 22-31
Santafé de Bogotá, D.C.
Colombia
Tel.: +57 1 368 82 67
+57 1 368 02 59
Fax: +57 1 268 97 37
[email protected]
[email protected]

DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com
NC Programming Instructions

Notes

DOK-MTC200-NC**PROV23-AW01-EN-P

www.EngineeringBooksPdf.com
Bosch Rexroth AG
Electric Drives and Controls
P.O. Box 13 57
97803 Lohr, Germany
Bgm.-Dr.-Nebel-Str. 2
97816 Lohr, Germany
Phone +49 93 52-40-50 60
Fax +49 93 52-40-49 4 1
[email protected]
www.boschrexroth.com

Printed in Germany
R911296998 DOK-MTC200-NC**PRO*V23-AW01-EN-P

www.EngineeringBooksPdf.com

You might also like