Вы находитесь на странице: 1из 559

Electric Drives Linear Motion and

and Controls Hydraulics Assembly Technologies Pneumatics Service

Rexroth IndraMotion MTX R911309064


Edition 02
Programming Manual

Application Manual
II Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Title Rexroth IndraMotion MTX

Programming Manual

Type of Documentation Application Manual

Document Typecode DOK-MTX***-NC**PRO*V02-AW02-EN-P

Internal File Reference Document number 120-2500-B301-02/EN

Purpose of Documentation This manual provides information about:


D the standard programming of the IndraMotion MTX control.

Record of Revisions Description Release Notes


Date
120-2500-B301-01/EN 01.2005 Valid for 02VRS
120-2500-B301-02/EN 06.2005 Various changes

Copyright E Bosch Rexroth AG, 2005


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


Postfach 11 62
D-64701 Erbach, Germany
Berliner Strae 25
D-64711 Erbach, Germany
Tel.: +49 (0) 60 62/78-0
Fax: +49 (0) 60 62/78-4 28
Dept.: BRC/ESM11 (DE), BRC/ESM6 (DiHa)
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG III
and Controls

Contents

Contents
Page

1 Notes Regarding Safety . . . . . . . . . . . . . . . . . . 1-1


1.1 Proper Use . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-1
1.2 Qualified Personnel . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-3
1.3 Safety Markings on Products . . . . . . . . . . . . . . . . . . . . . . . . . 1-4
1.4 Safety Instructions in this Manual . . . . . . . . . . . . . . . . . . . . . . 1-5
1.5 Safety Instructions for the Described Product . . . . . . . . . . . 1-6

2 NC Programming Basics . . . . . . . . . . . . . . . . . 2-1


2.1 Basic Information Regarding Standard and CPL Programming
.................................................... 2-2
2.2 Linking NC programs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-5
2.3 Basic Components of an NC Program . . . . . . . . . . . . . . . . . . 2-7
2.4 Effect of Program Words . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-18
2.5 Special Program Design Elements . . . . . . . . . . . . . . . . . . . . . 2-20
2.6 Subroutines . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-25
2.7 Label Programming and Jump Instructions . . . . . . . . . . . . . 2-32
2.8 Decision and Branch Instructions . . . . . . . . . . . . . . . . . . . . . . 2-38
2.9 Repeat Instructions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-42
2.10 Variable Programming . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-45
2.11 Reserved Instruction Words . . . . . . . . . . . . . . . . . . . . . . . . . . 2-60
2.12 CPL Instructions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-61
2.13 Additional Basic CPL Elements . . . . . . . . . . . . . . . . . . . . . . . . 2-66
2.14 NC Block Synchronization Commands . . . . . . . . . . . . . . . . . 2-68

3 NC Functions with Syntax According to DIN 66025


(incl. supplements) . . . . . . . . . . . . . . . . . . . . . . . 3-1
3.1 Overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-1
3.2 G-Codes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-3
3.3 M-Codes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-85
3.4 Feedrate and Speed Programming . . . . . . . . . . . . . . . . . . . . 3-95
3.5 Tool Compensation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-99

4 NC Functions with High-Level Language Syntax


......................................... 4-1
See the appendix for an overview of all G instructions and functions.

5 CPL-Functions . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-1
5.1 Coordinate and Axis Values . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-1
5.2 Zero Offsets . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-18
5.3 Tool Compensation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-22
5.4 Tool Database . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-24
5.5 Placements (Inclined Plane) . . . . . . . . . . . . . . . . . . . . . . . . . . 5-27
5.6 General Access to XML Tables . . . . . . . . . . . . . . . . . . . . . . . . 5-30
IV Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Contents

5.7 Scaling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-35


5.8 System Data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-36
5.9 Variable Axis Address . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-50
5.10 PLC Interface . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-51
5.11 Time Recording . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-53
5.12 Errors and Error Categories . . . . . . . . . . . . . . . . . . . . . . . . . . 5-54
5.13 NCS Coupling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-57
5.14 Character String Processing . . . . . . . . . . . . . . . . . . . . . . . . . . 5-101
5.15 File Processing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-117
5.16 Communication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-142

A Appendix . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A-1
A.1 Abbreviations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A-1
A.2 Overview Tables of NC Functions . . . . . . . . . . . . . . . . . . . . . A-2
A.3 ASCII Character Set . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A-48
A.4 Additional Key Codes . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A-48
A.5 Index . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . A-49
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 1-1
and Controls

Notes Regarding Safety

1 Notes Regarding Safety


L Please read this manual before programming the IndraMotion MTX or
modifying existing programs.

L Store this documentation in a place to which all users have access at all
times.

1.1 Proper Use


This manual contains information on the proper use of the control. Ho-
wever, for reasons of clarity, it cannot contain every detail of all function
combinations possible. Likewise, it is impossible to consider every con-
ceivable case of integration or operation.

A IndraMotion MTX-control is used to


D program contours and the machining technology (path feed rate,
spindle speed, tool change) of a workpiece.
D guide a machining tool along a programmed path.
Feed drives, spindles and auxiliary axes of a machine tool are control-
led using the SERCOS interface.
Any other application is deemed improper use!

. Furthermore, a PLC with I/O components is required; in communi-


cation with the actual CNC, this controls the machine processing
cycles holistically and acts as a technical safety monitor.

. The faultless, safe functioning of the product presupposes proper


transport, storage, erection and installation as well as careful ope-
ration.

The products described


D have been developed, manufactured, tested and documented in
compliance with the safety standards. These products pose no dan-
ger to persons or property if they are used in accordance with the
handling regulations and safety notes prescribed for their configura-
tion, installation and proper operation.
D comply with the requirements of
D the EMC Directives (89/336/EEC, 93/68/EEC and 93/44/EEC)
D the Low-Voltage Directive (73/23/EEC)
D the harmonized standards EN 50081-2 and EN 50082-2
D are designed for operation in industrial environments, i.e.
D no direct connection to public low-voltage power supply,
D connection to the medium- or high-voltage system via a transfor-
mer.
1-2 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Notes Regarding Safety

In residential environments, in trade and commerce as well as small ent-


erprises, class A equipment may only be used if the following warning is
attached:

. In a residential area, this device may cause radio interference. In


such a case, the user may be required to introduce suitable coun-
termeasures and to bear the cost of the same.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 1-3
and Controls

Notes Regarding Safety

1.2 Qualified Personnel


The requirements as to qualified personnel depend on the qualification
profiles described by ZVEI (Central Association of the Electrical Indus-
try) and VDMA (Association of German Machine and Plant Builders) in:
Further Training in Automation Technology
published by: ZVEI and VDMA
MaschinenbauVerlag
Postfach 71 08 64
60498 Frankfurt, Germany

This manual is designed for NC programmers and NC project engi-


neers. These persons require special knowledge of
D the operation, syntax and commands of the IndraMotion MTX stan-
dard programming..

Programming, start and operation as well as the modification of program


parameters may be carried out only by properly trained personnel! This
personnel must be able to judge potential hazards arising from program-
ming, program changes and in general from the mechanical, electrical,
or electronic equipment.

Interventions in the hardware and software of our products, unless des-


cribed otherwise in this manual, may be carried out only by our speciali-
zed personnel.

Tampering with the hardware or software, ignoring warning signs atta-


ched to the components, or non-compliance with the warning notes gi-
ven in this manual may result in serious bodily injury or material damage.

Only electrotechnicians as recognized under IEV 826-09-01 (modified)


who are familiar with the contents of this manual may install and service
the products described.

Such personnel are


D those who, being well trained and experienced in their field and fami-
liar with the relevant standards, are able to analyze the jobs being car-
ried out and recognize any hazards which may have arisen.
D those who have acquired the same amount of expert knowledge
through years of experience that would normally be acquired through
formal technical training.

With regard to the foregoing, please note our comprehensive range of


training courses. Please visit our website at http://www.boschrexroth.de
for the latest information concerning training courses, teachware and
training systems.
Information can also be obtained from:
D our Didactic Center in Erbach,
Telephone: (+49) (0 60 62) 78-600
D out training center in Lohr-Wombach,
Telephone: (+49) (0 93 52) 40 43 25.
1-4 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Notes Regarding Safety

1.3 Safety Markings on Products

Warning of dangerous electrical voltage!

Warning of danger caused by batteries!

Components sensitive to electrostatic discharge!

Warning of hazardous light emissions (optical fiber emit-


ters)!

Disconnect mains power before opening!

Lug for connecting PE conductor only!

Connection of shield conductor only


R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 1-5
and Controls

Notes Regarding Safety

1.4 Safety Instructions in this Manual

DANGEROUS ELECTRICAL VOLTAGE


This symbol is used to warn of dangerous electrical voltage. The fai-
lure to observe the instructions in this manual in whole or in part may
result in personal injury.

DANGER
This symbol is used wherever insufficient or lacking compliance with in-
structions may result in personal injury.

CAUTION
This symbol is used wherever insufficient or lacking compliance with in-
structions may result in damage to equipment or data files.

. This symbol is used to draw the users attention to special circumstan-


ces.

L This symbol is used if user activities are required.


1-6 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Notes Regarding Safety

1.5 Safety Instructions for the Described Product

DANGER
Danger of loss of life through inadequate EMERGENCY STOP de-
vices!
EMERGENCY STOP devices must be active and within reach in all
system modes. Releasing an EMERGENCY STOP device must not
result in an uncontrolled restart of the system!
First check the EMERGENCY STOP circuit, then switch the system
on!

DANGER
Incorrect or unintentional axis movements!
Always test new programs while inhibiting axis movements. For
this purpose, as a function of the Execute mode, the control pro-
vides the option to block axis movements or auxiliary functions by
means of special softkey commands.

DANGER
Incorrect or undesired control response!
Rexroth accepts no liability for damage resulting from the execu-
tion of an NC program, an individual NC block or the manual move-
ment of axes. Furthermore, Rexroth accepts no liability for resul-
ting damage which could have been avoided by programming the
PLC appropriately.

DANGER
Retrofits or modifications may adversely affect the safety of the
products described!
The consequences may include severe injury, damage to equip-
ment, or environmental hazards. Possible retrofits or modifica-
tions to the system using third-party equipment therefore must be
approved by Rexroth.

DANGER
The high output of the LED in the fiber optic connection can en-
danger eyesight if viewed directly.
When the converter is switched on, do not look directly at the LED
or into the open end of a short connected cable.

DANGEROUS ELECTRICAL VOLTAGE


Unless described otherwise, maintenance work must be perfor-
med on systems that are switched off! The system must be protec-
ted against unauthorized or accidental restarting.
Measuring or test activities on the live system must be carried out
by qualified electrical personnel!
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 1-7
and Controls

Notes Regarding Safety

DANGER
Tool or axis movements!
Feed and spindle motors generate very powerful mechanical for-
ces and can accelerate very quickly due to their high dynamics.
D Always stay outside the danger area of a machine when the sy-
stem is on!
D Never deactivate safety-relevant functions!
D Report any malfunction of the unit to your servicing and repair
department immediately!

CAUTION
Use only spare parts approved by us!

ACHTUNG
Beim Umgang mit Baugruppen und Bauelementen alle Vorkehrun-
gen zum ESD-Schutz einhalten! Elektrostatische Entladungen
vermeiden!

The following protective measures must be observed for modules and


components sensitive to electrostatic discharge (ESD)!
D Personnel responsible for storage, transport and handling must have
been trained in ESD protection.
D ESD-sensitive components must be stored and transported in the
prescribed protective packaging.
D ESD-sensitive components may be handled only at special ESD
workplaces.
D Personnel, working surfaces, as well as all equipment and tools
which may come into contact with ESD-sensitive components must
have the same potential (e.g. by grounding).
D Wear an approved grounding bracelet. The grounding bracelet must
be connected with the working surface through a cable with an inte-
grated 1-M resistor.
D ESD-sensitive components may by no means come into contact with
chargeable objects, including most plastic materials.
D When ESD-sensitive components are installed in or removed from
equipment, the equipment must be de-energized.
1-8 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Notes Regarding Safety

Trademarks
All trademarks of software installed on our products upon delivery are
the property of the respective manufacturer.

Upon delivery, all installed software is copyright-protected. The software


may be reproduced only with our approval or in accordance with the li-
cense agreement of the respective manufacturer.

PROFIBUSr is a registered trademark of the PROFIBUS Nutzerorgani-


sation e.V.

SERCOS interfacet is a registered trademark of the of the Interessen-


gemeinschaft SERCOS interface e.V.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-1
and Controls

NC Programming Basics

2 NC Programming Basics
An NC-control contains all the information about an NC-program (parts
program) that is required to machine a workpiece on a machine tool.

The structure of such an NC-program is not fixed, so that nearly any kind
of workpiece can be machined with a wide range of technologies (mil-
ling, turning, grinding, etc.). The parts program contains information ab-
out not only movements that the path of the tool describes relative to the
workpiece, but also about technologies.

Movement information is divided into individual elementary contour


elements (straight lines, circles, spirals, splines, nurbs, etc.).
The control can then carry out the movements for each of these geome-
trically simple contour elements in one machining step if all the machi-
ning steps are specified in the NC-program in the correct sequence and
with all required boundary conditions. The required boundary conditions
consist of, among other things, technology functions (velocities, speeds,
etc.) and auxiliary machine functions (e.g. for coolants and axis clam-
ping).

. Basic guidelines regarding the structure of an NC-program can be


found in DIN 66025.
The contents of DIN 66025, Program structure for numerically
controlled machines (Parts 1 and 2) correspond to the ISO/DIS
6983 and ISO/DP 6983 international standards, Numerical control
of machines.

The IndraMotion MTX administrates NC-programs in the File System


of the control. It is also possible to connect external drives and to run pro-
grams directly from there.
You can find additional information about the file system and access
rights, as well as about creating and editing parts programs, in the MTX
Operating Instructions.

Every NC program has an NC program name which must satisfy the ge-
neral conditions for file names.
D A maximum of 28 characters is allowed as NC program name.
D All letters, numbers and special characters . and _ are permitted.
D A distinction is made between capital and lowercase letters.
D Filenames within a directory must be unique.
D . and .. are permitted as program names.
2-2 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

2.1 Basic Information Regarding Standard and CPL Programming


The control provides two ways of programming:
D Standard- or DIN-programming
D CPL-programming (CPL: Customer Programming Language).

Using standard-or DIN-programming, you describe the movement se-


quences and their boundary conditions (geometry, kinematics, dyna-
mics, corrections, etc.). Standard-programming is a pure command
language to control movements on the machine and to activate specific
machine functions.
The syntax of the IndraMotion MTX consists of commands that are spe-
cified in DIN 66025 (G- und M-codes), as well as important supplements
in the area of G-codes and additional high level language like syntax ele-
ments.
The basic elements of standard-programming are the so-called NC-
functions; a programming syntax is assigned to each NC function.
Additional parameters can be assigned to an NC-function; these are
used to set the parameters of the function.
Example:
NC-function: G2 Circular interpolation (clockwise)
Parameter: I, J, K, R Center point coordinates, radius

CPL-programming (Customer Programming Language) is similar to


the standard of the BASIC high-level language, but also contains Pa-
scal-like structure elements. As a result, it is easy to learn.
CPL is a real programming language, thus providing an alternative way
of programming. It includes program elements that lie outside the focus
of machine controls; special system functions permit access to the sy-
stem data of the control.

CPL-programming offers the following options:


D Symbolic programming with variables
D Character string processing
D File processing
D Mathematical operators: +, -, *, /,
and trigonometric functions, ...
D Comparison operators: =, <, >, ...
D Logical links: NOT, AND, OR, ...
D Control structures to control the program run: REPEAT, WHILE, FOR,
IF, CASE, GOTO, ...
D System functions to determine internal system states: positions, ac-
tive functions, tool data, interface-signals, ...
D Process services: program selection, control reset, program start,
operating mode selection

Therefore, it is possible to create and store any machining procedures in


variable notation.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-3
and Controls

NC Programming Basics

In accordance with the existing formal input stipulations, CPL-instruc-


tions are usually written in capital letters.
Using CPL leads to:
D shortening of repeat procedures in NC-programs and similar pro-
gram segments, and
D status-dependent program variants as a result of access to control
system data.

An important difference between standard-and CPL-programming is


that all CPL-portions are initiated as early as the time of block prepara-
tion, directly when reading the corresponding program line. The CPL-
portions thus no longer exist for further block preparation and at the time
of interpolation of the NC-block.

Mark CPL-elements within a


parts program!
Both CPL-and standard programming can be used within a parts pro-
gram. Due to reasons of uniqueness and, more importantly, in order to
be able to provide efficient program interpretation, the CPL-portions of
the program must be specially marked:
D Program blocks that contains solely CPL-elements are to be marked
directly at the start of the block by a whole-number value without
a positive/negative sign (line number).
Example:
20 Ax1$=U In CPL-block 20, assign a value of U to
string-variable Ax1$.

D If CPL-elements are programmed within a standard-NC-block (e.g.


due to symbolic variable programming), the CPL-portions are to be
enclosed by square brackets ([ and ]). This allows a parameteri-
zable value to be assigned to NC functions and to parameters of NC
functions. Therefore, only expressions that can be placed on the right
side of an = sign within CPL (variables, mathematic expressions, sy-
stem functions that supply a corresponding value) are permitted wit-
hin the square brackets.
Example:
N10 G1 Y[CPOS(X)] In NC block N10, the Y-axis is to be traver-
sed to the workpiece position that was last
programmed for the X-axis.
N20 In NC block N20, activate the Rotate in-
ROT([360/A+SIN(B)]) put tool. The rotation angle is defined
using the CPL expression.
30 XPOS=100.5 In CPL block 30, a value of 100.5 is first as-
signed to variable XPOS.
N40 G1 X[XPOS] Y10 In NC block N40, the content of variable
XPOS is transferred as a coordinate value
to the X-axis.
2-4 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

Pay attention to the interpretation


times between the CPL and standard language portions!
Due to the special marking of CPL language portions, the programmer
can immediately recognize which program portions have already been
initiated during block preparation.
Standard programming elements do not have an external effect on the
machine before the time of block execution.
Example:
N523 KvProg(X[@KVX]) At the time that block N523 is executed, the
CO value for the X-axis that is used is the
one that was set for permanent variable
@KVX at the time of block preparation.
Up until the time that block N523 is executed, however, variable @KVX
may be set to a totally different value (for example, one that was written
by another channel)!
To avoid uncertainties, you should use the WAIT function. The Wait
command prevents block preparation until the NC block that was pro-
grammed immediately before the block of interest has been completely
processed. Block preparation is thus synchronized with the active status
(interpolation time) of the control. Then processing continues with block
preparation of the subsequent programmed block. At this time, no other
prepared blocks exist; all have already been processed.
Example:
WAIT Synchronize block preparation
N523 KvProg(X[@KVX]) At the time that block N523 is executed, the
CO value for the X-axis that is used is the
one that was set for permanent variable
@KVX at the time of block preparation. Ho-
wever, since block preparation has now
been synchronized, it is now the active value
of the variable.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-5
and Controls

NC Programming Basics

2.2 Linking NC programs


Subsequent to program selection, a program is first checked for proper
syntax and for possible jump destinations and subroutine calls. Further-
more, corresponding administration structures that the control accesses
during runtime are created for CPL variables. This process is termed lin-
king (or preparing).

The result of a successful linking procedure is the generation of a link


table for the corresponding NC program. All the link tables of the Indra-
Motion MTX are saved to a special directory that is specified in machine
parameter 3080 00004. The name of the link-table of a program is deter-
mined by the name of the parts program plus the extension .l (l: link).

While the control is starting up, it searches the associated NC program


for all existing link tables. The search is carried out according to the
search path set in machine parameter 3080 00001. Link tables for which
no parts program is found are erased.

If an NC program that is already linked is selected again, the IndraMotion


MTX uses an existing link table, provided that the parts program has not
been modified in the interim. Linking is carried out again after a program
is changed.

Linking subroutines subsequent linkage


In the event that subroutines are called in the program to be linked, the
IndraMotion MTX checks whether valid link tables exist for the respec-
tive programs. If this is the case, such subroutines will not be linked
again. In this way, the linking procedure can be significantly shortened.

If a parts program contains no CPL portions (jumps, CPL variables, CPL


expressions, etc.), but rather only NC blocks (DIN) and subroutine calls,
the program does not need to be explicitly linked before it is executed.
In this case, the toggle softkey CPL Prog / DIN Prog can be set to DIN
Prog when selecting a program. If necessary, subroutines are then sub-
sequently linked when the program is executed; in certain cases, this
may lead to delays in the processing flow.

If subroutine calls are programmed using CPL variables (e.g. P[UP$] ),


the linking procedure for this subroutine occurs no sooner than when the
program is executed, because only then can the variable name be initia-
ted. Therefore, a subroutine that is called in this manner is always subse-
quently linked if a link table does not already exist.
2-6 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

Influencing the linkage process using DIN/CPL IDs


Under the prerequisites mentioned above, linking can also be influenced
directly using instructions in the parts program, regardless of the current
position of toggle softkey CPL Prog / DIN Prog.
To do this, the keyword (DIN) must be programmed at the beginning of
the first program line. If necessary, subroutines are subsequently linked
when the program is executed in this case also.

Each (DIN) instruction can also be programmed in the first line of a sub-
routine; as a result, a subroutine that is marked in this way is not linked.
Alternatively, key word DIN (without parentheses) can also be written
directly behind the subroutine call in the calling program (also see sec-
tion 2.6, Subroutines).

Analog to the (DIN))-instruction, there is also keyword (CPL), which is


also programmed at the beginning of the first program line. This forces
the generation of a link table for the corresponding program, even if it has
been selected using the DIN Prog setting or if it was called as a subrou-
tine with the DIN ID.

Link units
Independent link units result from subsequent linkage during the pro-
gram runtime:
D If a subroutine call is programmed using CPL-variables (e.g. P[UP$]),
the calling program and the called subroutine belong to different link
units.
D If a subroutine is programmed directly but linked subsequently (e.g.
due to a DIN-ID for subroutine call P UP DIN), the calling program and
the called subroutine belong to the same link unit, but all additional
subroutines called by the subroutine belong to another link unit.

The following applies to the validity of CPL variables between programs


that belong to different link units:
D Global variables are redefined for every link unit. Therefore, if global
variables with the same name exist in subroutines or programs that
belong to different link units, these variables are independent of one
another.
D If information regarding fixed variables is to be exchanged between
programs that belong to different link levels, this can be carried out
only with the help of permanent or structured CPL variables.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-7
and Controls

NC Programming Basics

MP:
...
N10 P UP1 SR1
... ...
N1010 P UP11 DIN UP11
... ...
N2010 P UP111 UP111
...

100 UP$=UP2
...
N200 P[UP$] SR2
... ...
...
N300 UP3 DIN UP3
...
N1010 P UP31 UP31
... ...

Limit of a link unit

2.3 Basic Components of an NC Program


An NC-program consists of at least 1 program block.
The following applies for program blocks:
D A maximum of 1 contour element (e.g. straight line, arc) may be pro-
grammed for each program block.
D Blank lines before or after a program block are permitted to improve
the organization/readability of the program code.
D A program block may not contain more than 512 characters.
D A program block is terminated by ASCII-character <LINEFEED>.
D A program block consists of at least one program word
(e.g. NC function, function parameter).
2-8 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

Instructions
Instructions are program words that directly or indirectly affect the tool
path, program run, status or mode of reaction of the control. For exam-
ple, all NC functions are typical instructions.
Available NC-functions, together with the corresponding required syntax
rules, can be found in chapter 4.

Path functions play a special role among instructions:


Path functions describe in which way a position is to be approached (e.g.
straight line, circle, with or without interpolation of the participating axes,
approach movement in feed or rapid traverse, etc.).
Examples: G0, G1, G2
Path functions are often programmed in the same block as position, path
or radius specifications. In such cases, path functions always also in-
itiate traverse movements.
Similarly, position or path specifications that are programmed in a pro-
gram block without a path function always initiate traverse movements,
because some path function is always active.

Example:
Path function with coordinate specification
G01 X40 Y50 Move at feedrate to X40/Y50

Coordinate specification
Path function

Additional conditions
Additional conditions are program words with which you can set required
technologies or processing boundary conditions for the machine.
Important program words that function as additional conditions include:
F<number> affects the feed of synchronous axes
FA<number> affects the feed of asynchronous axes
S<number> affects the spindle speed
M<number> activates M-functions (e.g. gear range selection, direc-
tion of spindle rotation subroutine call). Auxiliary functions
are also often programmed as M-functions.
T<number> selects tools

Program words are described in detail in chapter 4.


R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-9
and Controls

NC Programming Basics

Example: Path information with additional conditions


G01 G71 X40 Y50 F250 S500 T05 M03 Move at feedrate to X40,
Y50; with programmed
F-value (feedrate= 250
mm/min) and S-value
Additional conditions
(speed= 500 mm/min); with
spindle rotating clockwise
and prepare tool T05 in tool
magazine.

. Although such additional conditions are not used directly to des-


cribe the contour or the path, they can nevertheless affect or in-
itiate movements on the machine (e.g. tool magazine movements)!
2-10 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

2.3.1 Program Words


A program word is:
1. an NC function or
2. a parameter with a value or parameter list. A parameter is addres-
sed in the parts program using its syntax (address).

. NC block synchronization commands and subroutine calls are


special cases of NC functions because they can be programmed
together with a CPL parameter list.

Each program word always consists of one or two partial words which
can be combined as follows:
Program word: Partial word 1: Partial word 2: Examples:
NC function Function syntax - AxAcc
G0
G52.1
Function syntax Parameter list AxAcc(...)
G0(NIPS)
Function syntax Value D5
M777
Synchronization Command syntax - OFFSTOPA
command
Command syntax CPL parameter WPV[@9=10]
list
Subroutine SR syntax: - P UP1
SR name G4711
SR syntax CPL parameter P UP2[7,@25]
SR name list G81[Z,R1]
Parameter Parameter syntax Value X-23.45
Y=AC(40)
S250
F5000
Parameter syntax Parameter list O(0,0,1)
ROTAX(0,45)

. G- and M-codes can occur with or without partial word 2:


D For G- and M-codes with fixed internal functions, the numerical
value is a component of the syntax,
e.g. G0, G17, G54, M0, M3, M19, etc. .
D For user-defined functions (subroutine calls and auxiliary func-
tions), the numerical value is not a component of the syntax; in-
stead, it represents the value for the function. These functions
are configured within the machine parameters.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-11
and Controls

NC Programming Basics

Program words from NC functions


The following applies in general:
D The syntax of NC functions can consist of G- and M-codes as well as
high-level language elements.
Examples: G0, G41, G141, G52.0, M30, Mirror(...)
You can find all the available NC-functions, together with the corre-
sponding syntax rules, in chapter 4.
D NC functions can contain additional parameters with which the me-
thod of operation of the NC function can be controlled. Differentiation
is made between 3 possible cases:
D Parameters that are programmed as an independent program
word in the NC block, e.g. G02 X10 I1.3 J2.5 G94 F1000. These
are mainly parameters that are defined in DIN 66 025.
D Parameters that are programmed as a program word, but within a
parameter list with specific syntax elements that is enclosed in
parentheses, e.g. KvProg(X1.2,Y1.2).
D Parameters within a parameter list without specific syntax ele-
ments that is enclosed in parentheses, for which only the value at
the defined position is programmed, e.g. Coord(0,1), Ro-
tate(45), GetAxis(Z1,Z,W,REV).

D Parameter lists can be optional and contain at least one valid parame-
ter. If several parameters exist for one parameter list, they are to be
separated from one another using commas.

. In this manual, we mark existing parameters that cannot be used


simultaneously (alternative parameters) with the | symbol bet-
ween the two alternatives. The | symbol is not programmed.

D Parameters from NC functions can be optional. If they are not inclu-


ded in the programming, default settings that are permanently coded
or are stored in the machine parameters are generally used.

. In this manual, we mark


D optional parameters with curly brackets and
D wildcards for the values to be programmed by angle brak-
kets.
Curly and angle brackets are not programmed.

Example:
Syntax rule:TangToolOri({SYM<s>},{ANG<a>})
Using the syntax rule, you can see that parameters SYM and ANG
are optional parameters. For SYM, a suitable value must be pro-
grammed in place of wildcard <s> as well as in place of wildcard <a>
for ANG. The syntax rule generally specifies which values are per-
mitted for <s> and <a>.
For instance, one possible program for the syntax rule shown above
would be TangToolOri(SYM4) .
2-12 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

Parameter lists without specific syntax elements:


All the parameters in this list type are constants that are transferred di-
rectly as a numerical value or name. They must be programmed in a pre-
cisely defined sequence because the meaning of each parameter is
specified solely by its position within the list.

Changing the sequence of parameters may result in a completely diffe-


rent effect:

Example:
GetAxis(X1,X,Y3,Y) The axes with system names X1 and Y3
transferred to the channel, where they
are assigned channel names X and Y.
GetAxis(X1,Y3,X,Y) The axes with system names X1 and X
are transferred to the channel, where
they are assigned channel names Y3
and Y.

Parameters in a parameter list without specific syntax elements can be


optional. The following applies in such cases:
D Optional parameters at the start and within the list are not required;
however, the corresponding comma must be programmed. Only in
this way does the position of the parameter in the list remain unique.
D Optional parameters at the end of the list are not required; the list is
then terminated with ).

Example:
GetAxis(<Phy.Ax1> {,<Log.Ax1>} {,<Phy.Ax2} {,<Log.Ax2>} {,...})
programmed without parameters within the list: GetAxis(X,,Z)
programmed without parameters at the end: GetAxis(X)

Using CPL expressions in parameter lists without specific syntax ele-


ments:
D If individual elements are to be transferred as an CPL expression,
each element is to be enclosed by angle brackets.

Example:
Variable name as transfer parameter:
10 AX1$=U String variable AX1$ receives the
content U.
20 AX2$=V String variable AX2$ receives the
: content V.
N100 G17([AX1$],[AX2$]) G17 opens the working plane with
axes U and V.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-13
and Controls

NC Programming Basics

Parameter lists with specific syntax elements:


The sequence of all the parameters in this list type does not matter be-
cause the meaning of a parameter is determined by its programmed syn-
tax.

Example:
KvProg(X1.2,Y1.4,Z1.6) and
KvProg(Z1.6,Y1.4,X1.2)
have the same effect because the individual CO values can be uniquely
assigned using axis addresses X, Y and Z.

CPL expressions can be used for both syntax elements and numerical
values. These must be enclosed in square brackets: [ and ].

Example:
20 VALUE=1.2 Assign a value of 1.2 to variable
WERT.
N30 KvProg(Y[VALUE],X1.2) Program CO values of axes Y and X.
The Y-axis receives the value contai-
ned in variable WERT while the X-
axis receives a value of 1.2 (con-
stant).

Example:
40 ACHSB$=X:FACT%=2 Assign values of X to string variable
ACHSB$ and 2 to integer variable
FACT%.
N50 Scale([ACHSB$][FACT%]) Switch on scaling by a factor of 2 for
axis X.
In the programming: Scale(X2)

Example:
60 DIM PARAMETER$(10) Create a character field for a
string with a maximum length of
10 characters.
70 PARAMETER$=X2
N80 AxAcc([Parameter$]) Assign an axis acceleration of
2 m/s2 to axis X.

Program words as parameter


Parameter with the following value:
The following applies to program words in general:
D An address always starts with a letter and can consist of several cha-
racters.
D Program words with an address and numbers are used to program,
for example:
D axis and coordinate designations (e.g. X..., Y..., Z..., B...)
2-14 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

D radii (R...) and interpolation parameters (I..., J..., K...)


D feedrate / time values (F...)
D spindle speeds and surface speeds (S..., Si=...)
D external tool compensations (ED...)
D D-corrections (D...)
D auxiliary functions (M..., T...)

D Leading zeros must not be programmed.


D Non integers are written with a decimal point; trailing zeros may be
omitted (e.g. X100.500 corresponds to X100.5).
D If a plus sign (or none at all) is programmed, the following value is al-
ways interpreted as being positive. A negative sign declares a nega-
tive value.

Example:
Program word consisting of address letter and a number
(here: coordinate value of the X axis
X-2407.0458

Decimal value
Value left of decimal point
Sign
Address letter

Parameter with following parameter list:


The following applies to program words in general:
D As a rule, the same statements apply as for program words consisting
of an address and a number.
D The parameter list is programmed behind the address and is enclo-
sed by parentheses. The individual elements are to be separated
from one another by commas.
D The elements in the parameter list are constants that are transferred
directly as a numerical value or name. They must be programmed in a
precisely defined sequence because the meaning of each parameter
is specified solely by its position within the list.
D If individual elements are to be transferred as CPL expressions, each
element is to be enclosed by angle brackets.
D Program words with an address and parameter list are used to pro-
gram, for example:
D spline coefficients (e.g. X(...)..., Y(...)..., Z(...)..., B(...)...)
D vector orientation (O(...), ROTAX(...) )
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-15
and Controls

NC Programming Basics

Programming attributes
When programming axis and coordinate positions, it is also possible to
provide a programming attribute for the programmed position value.

Without a programming attribute, the position value is interpreted accor-


ding to the current modal machine status.
With a programming attribute, the modal status can be overridden locally
according to axes/coordinates.

The IndraMotion MTX recognizes the following attributes:


AC(...): The programmed position specification is interpreted abso-
lutely, regardless of G90/G91.
IC(...) The programmed position specification is interpreted incre-
mentally , regardless of G90/G91.
DC(...): The position programmed for an endless axis is approached
on the shortest path, regardless of the settings in the ma-
chine parameters and the programming of function Pos-
Mode.
ACP(...): The position programmed for an endless axis is approached
with a positive rotation direction, regardless of the settings in
the machine parameters and the programming of function
PosMode.
ACN(...) The position programmed for an endless axis is approached
with a negative rotation direction, regardless of the settings
in the machine parameters and the programming of function
PosMode.

Examples:
N10 G90 G1 F1000 X10 Y=IC(15) The X-axis traverses absolutely to po-
sition 10, the Y-axis incrementally 15
mm further.
N20 G91 X=AC(15) Y5 Despite G91, the X-axis traverses to
absolute position 15, the Y-axis incre-
mentally 5 mm further.
N30 B=DC(90) The B-axis (endless axis) is to traverse
to the 90-degree position following the
shortest path.
N40 B=ACP(350) The B-axis is to traverse to the
350-degree position with a positive di-
rection of rotation (working path: 260
degrees).
N50 B=ACN(0) The B-axis is to be positioned at 0 de-
grees with a negative direction of rota-
tion (working path: 350 degrees).
2-16 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

Using separators between 2 partial words


Each partial word can consists of one or more characters (character
string). Each programmable character can be classified into the follo-
wing groups:
D Letters: A -Z, a - z
D Numbers (including decimal point!): 0-9,.
D Characters that act as separators: , =, +, -, (, )
D Other special characters (will not be discussed further)

A separator is to be programmed between 2 neighboring partial words if:


D the partial word in front ends with a letter or a number and
D the partial word in back starts with a letter or a number.

For example, this is the case


D if additional syntax follows an NC function without a value and a para-
meter list, or
D if parameter syntax ends with a number and a numerical value is to be
assigned to the parameter.

Examples:
1. N10 OVE FeedForward(...) suitable separator: .
2. N20 X2=2 suitable separator: =
In the 2nd case, or + can also be used as a separator; - is also pos-
sible in the case of negative value assignment.

Using separators can also be relevant for parameter lists with syntax-
specific elements!

Special features for axis and coordinate designations


You can specify which axis and coordinate designation you desire for
your control in the machine parameters:
D MP 1003 00001 System axis designation
D MP 7010 00010 Channel-axis designation
D MP 7010 00020 Optional axis name of a channel
D MP 7080 00010 Coordinate name of the channel
D MP 7080 00020 Cartesian coordinate name of the channel

Axis and coordinate designations always start with a letter and can:
D consist of one or more letters, where the resulting character string
may not have the same appearance as an NC function.
Examples: X, PALETTE
D consist of one or more letters and end with a number.
Examples: X1, PALETTE1
D In this case, a suitable separator must be programmed between the
designation and the following value: =, +, - or a space.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-17
and Controls

NC Programming Basics

Example:
Axis designations X and X2 are defined.
N40 G1 X10 Axis X traverses to position 10
N50 G1 X20 Axis X traverses to position 20
N60 G1 X2.5 Axis X traverses to position 2.5
N70 G1 X=2.2 Axis X traverses to position 2.2
N80 G1 X 2.8 Axis X traverses to position 2.8
N90 G1 X2 Axis X traverses to position 2
N100 G1 X2 1 Axis X2 traverses to position 1
N110 G1 X2=2.8 Axis X2 traverses to position 2.8
N120 G1 X2+3 Axis X2 traverses to position 3
N130 G1 X2-2.4 Axis X2 traverses to position -2.4

2.3.2 End of Program


A program/subroutine termination occurs in the following cases:
D at the end of file or
D in a program line containing M2, M02, or M30. For details concer-
ning these M-functions, refer to section 3-86.

Example:
:
N250 ... N250 is the last program block.
M30 End of program.

At the end of a subroutine, execution returns to the calling program. All


modal states are retained (modal: see page 2-18).
At the end of a main program, the system returns to the beginning of
the program and waits for the next NC start. If M2, M02 or M30 is
used as the end of a main program, the modal states are set to the M30
portion of the init string.
2-18 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

2.4 Effect of Program Words


Program words can have a modal or non-modal effect.

Modal
Modal means that a program word remains effective in every subse-
quent program block until you
D program the same program word with a different value,
D program another program word that cancels its effect, or
D specifically switch off the function of the program word.

. Sometimes, the term self-sustaining is used as a synonym for


modal.

Example for an NC parts program:


N10 F1000 Set the feedrate to 1000 mm/min. F1000
acts modally.
N20 G0 X0 Y0 Linear interpolation in rapid traverse to posi-
tion X0/Y0. G0 acts modally.
N30 Z100 Linear interpolation in rapid traverse to posi-
tion Z100.
N40 G1(IPS1) X10 Y10 Linear interpolation (in feed; with fine-scale
positioning window) with 1000 mm/min to
position X10/Y10.
G1 cancels the effect of G0.
G1(IPS1) acts modally.
N50 X20 Linear interpolation (in feed; with fine-scale
positioning window) with 1000 mm/min to
position X20/Y10.
N60 G1(IPS2) X30 Y30 Linear interpolation (in feed; with coarse-
scale positioning window) with 1000 mm/min
to position X30/Y30.
G1 was programmed with another value
(IPS2). G1(IPS2) acts modally.
N70 X40 Y40 F500 Linear interpolation (in feed; with coarse-
scale positioning window) with 500 mm/min
to position X40/Y40.
F was programmed with another value
(500). F500 acts modally.
N80 G0 X0 Y0 Linear interpolation in rapid traverse to posi-
tion X0/Y0.
G0 cancels the effect of G1(...).
G0 acts modally.
N90 Scale(X2,Y2) Activate the scaling function. Scaling acts
modally.
: Scaling remains active.
N200 Scale() Deactivate the scaling function.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-19
and Controls

NC Programming Basics

Nonmodal
Nonmodal means that a program word has an effect only in the pro-
gram block in which it was programmed.

. Sometimes, the terms not self-sustaining or local are used as


synonyms for nonmodal.

Example for an NC parts program:


N10 G1 F1000 Activate linear interpolation. G1 acts mo-
dally.
Set the feedrate to 1000 mm/min. F1000
acts modally.
N20 G75 X100 Y100 Probe G75 acts nonmodally. In this block,
function G75 overrides the modal function
G1.
N30 Z100 Linear interpolation at feedrate to Z100. G1
remains modally active.
2-20 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

2.5 Special Program Design Elements

2.5.1 Channel Designation


You can use this to specify in which channel the corresponding program
may be used exclusively. Starting it in another channel generates a run-
time error.
The channel designation is written at the beginning of the program.

Syntax:
$<Channel number>

Example:
N10 $2 This program can run only in channel 2.
: Program instructions
M30 End of program

2.5.2 Block Numbers


D You can mark program blocks with a block number to improve the re-
adability of the program code.
As long as you assign unique block numbers, it is possible to program
jumps to these block numbers.

D Program blocks that contain solely CPL-elements must be marked


with block numbers. Such blocks are also called CPL blocks.

The following applies:


D Block numbers must always be programmed as the first NC word in a
program line.
D Block numbers of standard NC blocks consist of address letter N
and an immediately following positive number.
(Example: N10, N10.2).
Note that CPL expressions within standard NC blocks must be enclo-
sed by square brackets.
D Block numbers of pure CPL blocks consist solely of a positive num-
ber, without a positive/negative sign
(Example: 10, 11.9).
The CPL instruction or specification of the block is programmed be-
hind the block number.
D If a CPL block concludes with a :, it must be followed by another CPL
block without a line number.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-21
and Controls

NC Programming Basics

2.5.3 Blank Lines in Program Code


Blank lines can be used to structure the program, thus increasing the re-
adability. Blank lines are skipped by the control.

2.5.4 Remarks in a Parts Program


Remarks are skipped by the control when the program runs. Use re-
marks to
D document the program code or to insert explanations
D provide remarks for entire program lines or for individual parts.

Well-remarked programs facilitate and accelerate subsequent editing,


e.g. if the program needs to be changed. However, each remark charac-
ter will increase the size of the program file by 1 byte.

Providing remarks for entire program lines


You can completely hide any program line, regardless whether it is a
standard NC block or a CPL block. To provide remarks for entire lines:
D at the beginning of the block, program a semicolon ; or
D enclose the entire line in parentheses ( and ).

Remarks in a standard NC block


You can program a remark at any location within a standard NC block:
D Program a semicolon ; where the remark starts. Starting at the semi-
colon until the end of the line, the control interprets the program line
as a remark.
D Enclose completed remarks within a standard NC block with paren-
theses ( and ). This also makes it possible to program nested re-
marks, for example when you want to hide, within a program line, a
sequence that already contains a remark with parentheses.
Parentheses may not be used behind functions for which a parameter
list with parentheses can be programmed as an option (e.g. G0, G1,
G61), but the parameter list was not programmed.

Example:
N10 G0 (<Remark text<) Invalid programming!
N20 G0 (NIPS) (<Remark text<) Valid programming

D You can initiate a remark with // behind a function with a possible op-
tional parameter list if the list is missing. Such a remark can be optio-
nally terminated with \\.
2-22 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

Remarks in a CPL block


Within a CPL block, initiate a remark with REM. Starting at the REM
instruction until the end of the line, the control interprets the program line
as a remark.

Syntax:
REM <Remark text>
Example:
...
10 REM ***SR to demask the status word ***
...

Example for remarks in a parts program:


: Program code
; <Comment> Remark line
;N10 <Standard NC block> Hide standard NC block
;20 <CPL> Hide CPL block
( <Remark> ) Remark line
(N30 <Standard NC block>) Hide standard NC block
(40 <CPL>) Hide CPL block
N50 G1 X0 Y0 ; <Remark> Remark in a standard NC block
N60 G1(IPS) (<Remark>) F1000 Completed remark in a standard
NC block
N70 X10 (Y10 (<Remark>)) Nested remark in a standard NC
block
N80 G0 //<Remark> Remark behind a function for
which optional parameters could
be programmed
N90 G0 //<Remark>\\ X0 Y0 Completed remark behind a func-
tion for which optional parameters
could be programmed
100 REM <Remark> Remark in a CPL block.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-23
and Controls

NC Programming Basics

2.5.5 Notes in the User Interface


Use note programming to display note texts in the NC user interface
(max. 80 characters). In this way, you can, for example, provide the ma-
chine operator with the following while the program is running:
D information about the current program status, or
D handling instructions.

Differentiation is made between 2 possible types of notes:


D Channel-specific notes:
These are deleted when the program is deselected or the channel is
reset.
Syntax: MSG(<Note text>)
D Cross-channel notes:
These can be deleted with an overall reset.
Syntax: GMSG(<Note text>)

You can also program a note to provide the machine operator with a
handling instruction. To do this, program e.g. an M0 in the very same
line or in the following one. In this way, you ensure that the program is
interrupted immediately after the note text is output. The rest of the pro-
gram runs only after NC start is pressed .

Example:
: Program code
N60 (MSG Measure workpiece!) Output channel-spec. note.
N70 M0 Wait for NC start button.
: Program code

For reasons of compatibility, some alternative syntax variants exist for


note programming; in terms of functions, they are all equal.
D Syntax variants for channel-specific notes:
(MSG(<Note text>)
(*MSG(<Note text>)
(MSG, <Note text>)
(*MSG, <Note text>)
D Syntax variants for cross-channel notes:
(GMSG <Note text>)
(GMSG, <Note text>)
2-24 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

2.5.6 Jumps in Program Execution


A consequence of increasing program size is the increased importance
of clean programming. This mainly includes:
D structured programming,
D fault tolerance and
D software-ergonomics.

Generally speaking, structured programs tend to be clearer in their over-


all architecture. Bundling program segments that serve related purpo-
ses or containing frequently used functions into (parameterized)
subroutines or into a single jump destination, with the added identifica-
tion by a comprehensible designation (label), results in not only impro-
ved readability, but also more efficient work because these programs
can be utilized in other programs.

The following possibilities are available:


D Subroutine calls
(see section 2.6, page 2-25 ff.)
Use subroutines if a certain processing section occurs several times
in an identical or similar form within processing.
Program this section only once (if necessary, with the possibility of
transferring parameters), save it as a program and simply call it when
needed.
This will save programming code and memory space. In addition,
your programs will become clearer and easier to maintain.
D Jump instructions
(see section 2.7, page 2-32 ff.)
Use jump instructions to continue the program at other locations wit-
hin the current program depending on the defined events (e.g. calcu-
lation results).

D Decision/branch instructions
(see section 2.8, page 2-38 ff.)
Use such commands if individual program blocks, different program
sections or entire subroutines are to be executed depending on cer-
tain conditions.
D Repeat instructions
(see section 2.9, page 2-42 ff.)
Use repetition operations if program sections or entire subroutines
are to be run repeatedly. You can generally also enter how often the
repetition should take place.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-25
and Controls

NC Programming Basics

2.6 Subroutines
Subroutines (SR) are programs that are called using a subroutine call.
Once the execution of a subroutine has been concluded, the calling pro-
gram will continue to run from the point where the SR was called. A pro-
gram calling itself is called a recursive subroutine call.
The main program (MP) is the program from which execution jumps into
the first subroutine level (SR level).
Formally, no differentiation is made between main programs and sub-
routines; however, only subroutines can have transfer parameters. The
following applies:
D Subroutines can contain standard NC blocks and CPL blocks.
D Each parts program can be called by other programs as a subroutine.
However, a program is incapable of calling itself as a subroutine (re-
cursive calling is not possible).
D The calling program can transfer parameters to a subroutine.
D The maximum nesting depth is 8, i.e. the control can keep a maximum
of 8 subroutine levels open at the same time.
D Subroutine names are case-sensitive for the control.

. For information regarding the end of a subroutine, see section 2.3.2


page 2-17.

Example:
Subroutine nesting. SRx: subroutine name

MP SR1 SR2 SR7 SR8


N1 N1 N1 N1 N1
..
.
N9
N10 SR1 N23 SR2 N32 SR3 N44 SR8
N11 N24 N33 N45:
..
.

M30 M30 M30 M30 M30

1. SR level 2. SR level 7. SR level 8. SR level

Differentiation is made between local and modal subroutines:


D Generally, subroutines are local. In this case, the subroutine is called
once at the point of calling.
D On the other hand, if a modal subroutine is activated, this is called
again at every following programmed traverse movement until it is de-
selected again. This is used in, for example, drilling cycles.

The IndraMotion MTX provides the following variants for calling subrou-
tines:
D Call with P address and subroutine name from a standard NC block
(optionally with path information).
2-26 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

D Call only with subroutine name without path information and without P
address from a standard NC block.
D Subroutine as a self-defined G- or M-function in a standard NC block.
D Activation of a modal subroutine with self-defined syntax from a stan-
dard NC block.
D Call using the CALL function from a CPL block.

Subprogram call with P address


D The subroutine name is directly programmed behind the P address.
Optionally, the directory in which the subroutine is located can be inc-
luded in programming.
D To improve readability, a blank can be programmed as a separator
between the P address and the subroutine name.
D The subroutine call must be programmed at the end of the block.
Traversing movements which are programmed in the same block will
be executed prior to the subroutine call (see example).
D No more than 1 subroutine call may be programmed in a block.
D The subroutine call is local (not modal).

Syntax:
P{<Path>}<Name> {DIN}
where:
<Path> Directory in which the subroutine is located .
<Name> Name of the calling program.
DIN Optional. Prevents the subroutine from being linked.
Use this parameter only if the SR does not call any CPL
blocks or any additional SRs. Otherwise, an error message
occurs during the program runtime.
For further information, see the CALL-command on page
2-29.

Example:
:
N40 P Drill pattern Call program "Drill pattern".
N50 X100 Block N50 follows the end of the SR.
:
N140 G0 X10 Y0 PUP1 First positioning to X10/Y0 in rapid traverse.
N150 Z0 Then call of program "SR1".
: Block N150 follows the end of the SR.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-27
and Controls

NC Programming Basics

Subprogram call without P address


Subroutines can also be called directly without a preceding P address.
D Only the subroutine name is programmed directly.
D Path information is not possible.
D The subroutine call must be programmed at the end of the block.
Traversing movements which are programmed in the same block will
be executed prior to the subroutine call (see example).
D No more than 1 subroutine call may be programmed in a block.
D The subroutine call is local (not modal).

Syntax:
<Name>
where:
<Name> Name of the calling program.

. Ensure that this programming variant does not cause confusion


with normal syntax!

Therefore, always give your subroutines unique names to avoid misin-


terpretations by the control interpreter.

Examples:
:
N40 XUP Call program "XUP".
N50 X100 Block N50 follows the end of the SR.
:
N100 X1UP Caution! The SR name X1UP programmed
: here leads to a syntax error because X1 is
: interpreted as a coordinate of an axis named
: X and a program named UP does not exist.
:
:
N140 G0 X10 Y0 XUP First positioning to X10/Y0 in rapid traverse.
N150 Z0 Then call of program "XUP".
: Block N150 follows the end of the SR.
2-28 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

Self-defined subroutine calls with G and M codes


In addition to the subroutines described above, the control allows you to
define
D nonmodal subroutine calls using the M address
(see MP 3090 00003 and MP 3090 00004), and
D nonmodal subroutine calls using the G address
(see MP 3090 00001 and MP 3090 00002)
yourself.

Subroutines can be assigned for a maximum of 16 user-defined G co-


des and a maximum of 8 user-defined M codes; these subroutines are
called as local (not modal) subroutines when programming the corres-
ponding G or M code.

The G and M codes configured as subroutine calls may not collide with
permanently defined G and M codes.

. Please contact your system administrator for the subroutine calls


that are configured on your specific machine.

The following applies to the programming of self-defined SR calls:


D Only the corresponding G or M code is programmed in the parts pro-
gram. The subroutine that is called as a result is determined by the
configuration in the machine parameters.
D The subroutine call must be programmed at the end of the block.
Traversing movements which are programmed in the same block will
be executed prior to the subprogram call.
D No more than 1 subroutine call may be programmed in a block.
D The subroutine call is local (not modal).

Self-defined modal subroutine calls


Subsequent to their initial call, modal subroutines will continue to be au-
tomatically executed after each traversing movement prescribed by a
standard NC block. This will continue until they are deselected via a spe-
cial NC function.

Modal subroutine calls, including the syntax of the switch-off function,


are configured in the machine parameters (see MP 3090 00005 ff.).

A maximum of 15 modal subroutines that mutually deselect each other


can be set. The subroutine names are assigned to the freely definable
syntaxes. The maximum number of parameters that can be transferred
to the corresponding subroutine must also be entered.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-29
and Controls

NC Programming Basics

The syntaxes of the modal subroutine calls may not collide with the per-
manently defined NC functions.

. Please contact your system administrator for the subroutine calls


that are configured on your specific machine. By default, drilling
cycles G80, G81-G86 and G184 are configured.

The following applies to the programming of modal SR calls:


D Only the corresponding configured syntax of the modal subroutine is
programmed in the parts program. The subroutine that is called as a
result is determined by the configuration in the machine parameters.
D Only 1 subroutine call may be programmed in a block.
D The subroutine call is modal, i.e. the subroutine is called again after
every programmed traverse movement until it is deselected.

Subroutine call in CPL using the CALL command


The CALL command makes it possible to call subroutines from pure CPL
programs. The following applies to programming:
D The subroutine programmed after the CALL command is called di-
rectly.
D The CALL command must be programmed in its own separate CPL
block.
D The subroutine call is local.

The CALL keyword is followed by the program name. This, in turn, may
be followed by transfer parameters enclosed in square brackets and, to
conclude the instruction, the DIN identifier (to influence the link pro-
cess).

. A CPL-block that includes the CALL-command must not contain a


:. can be used. Subsequent CPL commands must be program-
med in a new CPL block.

Example:
50 IF A% = 1 THEN
%! CALL P999
% ENDIF
:

Using DIN identifier to influence the link process (Preparing)


If you conclude a subroutine-call by means of CALL terminated with the
DIN identifier, the control will exclude the subroutine thus called from
the linking process. For example, the linking process of a main program
that includes numerous SR calls can be significantly accelerated in this
manner.
2-30 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

Example:
50 IF A% = 1 THEN
51 CALL P999 DIN SR P999 is excluded from linking
52 ENDIF
M30

It is strongly recommended that you include the DIN identifier in the


program only if the called subroutine
D consists exclusively of DIN blocks, and
D does not call any additional subroutines.

In the event that a subroutine containing CPL elements was excluded


from the linking process due to the presence of the DIN identifier, the
control will return an appropriate error message at program runtime.

As an alternative, the DIN-identifier can be inserted as a remark into


the first line of the subroutine to be called. The control will respond by
excluding the program from the linking process.

Example: DIN identifier in subroutine to be called


N10 (DIN) SR P999 is excluded from linking
N20 ...
:

Parameter transfer to subroutines


Using a CPL parameter list, parameters can be transferred to a subrou-
tine. To do this, the parameters are programmed in a list enclosed by
square CPL brackets [ and ] immediately behind the subroutine call.
The individual parameters are separated by commas.

The following parameters are permitted:


D Numerals
D CPL string constants (in quote marks: <CPL string constants>
D CPL variables
D Arithmetic CPL expressions

The parameters transferred during the subroutine call are always ad-
dressed via variables P1, P2, P3, etc. in accordance with the sequence
of the parameter transfer.
The parameters may also be addressed by means of, for example,
P1TEST, P2XYZ, etc. However, the capital letters following P1, P2, etc.,
will be ignored (P1 = P1TEST = P1XYZ).

Example:
D P1 has a value of 2.75 in SR P999;
D P2 has the value of variable X% at the time of the parameter transfer
D P3 has a value of 0.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-31
and Controls

NC Programming Basics

If P2 is also to represent an INTEGER value in the subroutine, this can be


accomplished by attaching a % character to P2. This mode of identifying
the type of variable can also be used with the other types of variables.
In the subroutine, the value of the individual parameters can be assigned
to additional variables.

Main program:
50 IF A% = 1 THEN
51 CALL P999 [2.75, X%, 0] Subroutine call with parameter trans-
fer
52 ENDIF
M30
Subroutine P999:
1 FACTOR=P1 : XVALUE%=P2% : CORRTAB%=P3%
N1 G1 X[XVALUE%*FACTOR]
N2 G22 K[CORRTAB%]

If a subroutine
D is to be invoked with a string-constant as a transfer parameter and
D the invoking program is selected without linking,
the PDIM-command must be used.

Syntax:
PDIM <Parameter name>(<Field size>)
If the field size programmed is too small or missing entirely, the control
reports parts program error Invalid variable.

Example:
Main program:
N10 (DIN)
:
N50 P UP[Test]
M30

Subroutine:
10 PDIM P1$(4)
M30

String variable P1$ has the value TEST.


2-32 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

2.7 Label Programming and Jump Instructions


Jump instructions can be used to continue program execution at certain
entry points.

The IndraMotion MTX offers the following functions in terms of jump in-
structions:
D Label programming for standard NC blocks (DIN)
D Label programming for CPL blocks
D GoAhead (GOA): Forwards jump to a standard NC block
D GoBack (GOB): Backwards jump to a standard NC block
D GoCond (GOC): Conditional jump to a standard NC block
D GoTo: Unconditional jump to a standard NC block
D CPL jump (GOTO): Jump to any program block

. CPL jump GOTO is already initiated at the linking time. In the stan-
dard NC commands, on the other hand, the target for the jump is
first searched while the program is running; this has a particularly
unfavorable effect on the runtime behavior when the target for the
jump is far away from the jump call.

. It is not allowed to jump into a CASELABEL ...LABELOTHER-


WISEENDCASE instruction via CPL jump GOTO.

. The standard NC jump commands GoAhead, GoBack, GoCond and


GoTo may not be used to jump into or out of a CPL repetition or
branch instruction. This affects CPL instructions:
D REPEAT UNTIL
D WHILE DO END
D FOR STEP TO NEXT
D IF THEN ELSE ENDIF
D CASE LABEL ... LABEL OTHERWISE ENDCASE.

Labels in standard NC blocks and CPL blocks


A label is a jump marker for a jump command. The IndraMotion MTX dif-
ferentiates between labels in a standard NC block (DIN) and those in a
CPL block.

Label programming in a standard NC block (DIN)


D The target of the jump must always be programmed directly at the
start of the block.
D In the cases of blocks with a block number, the target of the jump is
located directly behind the block number, separated by a space.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-33
and Controls

NC Programming Basics

D The label name can consist of 2 to 32 characters. Letters, underlines


and numbers are allowed, but the first two characters may not be
numbers. A distinction is made between capital and lowercase let-
ters.
D At the target of the jump, a colon must be programmed behind the la-
bel name.

Label programming in a CPL block


D The target of the jump is located directly behind the block number, se-
parated by a space.
D The label name consists of a decimal point followed by ASCII charac-
ters, starting with a capital letter.
D A label may not be a variable.

GoAhead (GOA) Forwards jump to a standard NC block


Continues program execution at a jump target (label) without conditions.
Please note the following:
D The target of the jump must be defined.
D In terms of the current program block, the target of the jump must be in
the direction of the end of the file.

For the required label-programming, see page 2-32.

Syntax:
GoAhead <Label>
Abbreviation: GOA
where:
<Label> Name of target of jump.
2 to 32 characters. Letters, underlines and numbers are allo-
wed, but the first two characters may not be numbers.

Example:
:
N40 GoAhead LABEL1 Forwards jump to the target
: LABEL1.
N80 LABEL1: Label programming of the target of the jump
: LABEL1.

. The standard NC jump command GoAhead may not be used to


jump into or out of a CPL repetition or branch instruction. For the
affected CPL-instructions, see page 2-32.
2-34 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

GoBack (GOB) Backwards jump to a standard NC block


Continues program execution at a jump target (label) without conditions.
Please note the following:
D The target of the jump must be defined.
D In terms of the current program block, the target of the jump must be in
the direction of the start of the file.

For the required label-programming, see page 2-32.

Syntax:
GoBack <Label>
Abbreviation: GOB
where:
<Label> Name of target of jump.
2 to 32 characters. Letters, underlines and numbers are allo-
wed, but the first two characters may not be numbers.

. Note that it is easy to accidentally generate infinite loops when pro-


gramming backwards jumps!

Example:
:
N40 LABEL1: Label programming of jump target LA-
: BEL1.
N80 GoBack LABEL1 Backwards jump to the target
: LABEL1.
If no additional jump command is pro-
grammed between N40 and N80, the
program runs through an infinite loop
between N40 and N80!

. The standard NC jump command GoBack may not be used to jump


into or out of a CPL repetition or branch instruction. For the affec-
ted CPL-instructions, see page 2-32.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-35
and Controls

NC Programming Basics

GoCond (GOC) Conditional jump to a standard NC block


Continues program execution at an entered block number if input signal
Conditional jump was active on the channel interface at the time of
block preparation. Please note the following:
D The entered block number must exist.
D The entered block number can have any position within the program
file in terms of the current program block.

Syntax:
GoCond N<Number>
Abbreviation: GOC
where:
<Number> Block number.
D Number in integer or real format, with max. 15 digits.
D If the target block number is programmed with leading ze-
roes (e.g. N0020 ...), preceding zeroes must also be
programmed.
(GoCond N0020).

Special features and restrictions:


D Except for a possible programmed preceding block number, no addi-
tional program words are permitted in the same block.
D Changes to channel interface signal conditional jump within the time
between block preparation and block execution are not taken into ac-
count.
If this behavior is not permitted for your application, you must program
a WAIT function in the previous program line.
. Note that it is easy to accidentally generate infinite loops jumping
in the direction of the start of the file!

Example:
10 WAIT Pause block preparation until all blocks be-
N20 GoCond N090 fore N20 have been processed.
: Then jump to N090 if input signal Conditio-
: nal jump is active at the time of block pre-
: paration of N20.
:
N090 ...
:

. The standard NC jump command GoCond may not be used to jump


into or out of a CPL repetition or branch instruction. For the affec-
ted CPL-instructions, see page 2-32.
2-36 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

GoTo Unconditional jump to a standard NC block


Continues program execution at any block number without conditions.
Please note the following:
D The entered block number must exist.
D The entered block number can have any position within the program
file in terms of the current program block.

Syntax:
GoTo N<Number>
where:
<Number> Block number.
D Number in integer or real format, with max. 15 digits.
D If the target block number is programmed with leading ze-
roes (e.g. N0020 ...), preceding zeroes must also be
programmed here (GoTo N0020).

Special features and restrictions:


D Except for a possible programmed preceding block number, no addi-
tional program words are permitted in the same block.

. Note that it is easy to accidentally generate infinite loops jumping


in the direction of the start of the file!

Example:
:
N40 GoTo N080 Forwards jump to block N080.
:
N080 GoTo N40 Backwards jump to block N40.
: If no additional jump command is program-
med between N40 and N080, the program
runs through an infinite loop between N40
and N080!

. The standard NC jump command GoTo may not be used to jump


into or out of a CPL repetition or branch instruction. For the affec-
ted CPL-instructions, see page 2-32.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-37
and Controls

NC Programming Basics

CPL-Sprung (GOTO) Jump to any program block


Continues program execution at a jump target without conditions.
Please note the following:
D A specified jump destination can be a CPL block number, a standard
NC block number or a label (jump marker).
D The target of the jump can have any position within the program file in
terms of the current program block.

Syntax:
GOTO <Target>

Example:
10 GOTO N20 Jump to block N20
N20 X100
30 GOTO 120 Jump to CPL block 120
...
120 GOTO .ZIEL1 Jump to label .ZIEL1
...
150 .TARG1

. It is not allowed to jump into a CASELABEL ...LABELOTHER-


WISEENDCASE instruction via CPL jump GOTO.

For label -programming conditions, see page 2-33.


2-38 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

2.8 Decision and Branch Instructions


Decision and branch instructions are used to execute individual program
blocks and sections or entire subroutines depending on certain events.

The IndraMotion MTX provides the following possibilities:


D Skip block function for standard NC blocks (DIN)
D CPL instruction IF-THEN-ELSE-ENDIF
D CPL instruction CASE-LABEL...LABEL-OTHERWISE-ENDCASE

Skip block function


With the help of this function, individual standard NC blocks (DIN) can be
skipped by the control. To do so, program the / sign at the beginning of
the corresponding program line.

The indicated program blocks are skipped only if interface signal


qCh_BlockSlash (Block skip) is set for the bit interface of the correspon-
ding channel.

Example:
: Interface signal Skip block is activated.
:
/N100 ... Block N100 is ignored.
: Interface signal Skip block is deactivated.
:
/N300 ... Block N300 is processed.
:

. The Skip block function can be used only for standard NC blocks
(DIN)!
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-39
and Controls

NC Programming Basics

CPL instruction: IF - THEN - ELSE - ENDIF


This function is a simple conditional branch instruction:
IF a specific condition is fulfilled, THEN perform the routine, or ELSE
perform the other routine.

Syntax:
IF <Condition> THEN <Routine> [ELSE <Alternative routine>]
ENDIF

Please note the following:


D The condition is located in the same line as IF and is concluded by the
THEN in that line.
D Both the THEN- and the ELSE-routine comprise program branches
that do not have to be processed in every case.
D If the ELSE component is omitted, the program, provided that the
condition is not fulfilled, will continue to run immediately after proces-
sing the ENDIF instruction.

Similar to the abort conditions for loop instructions, the condition for the
IF instruction may contain arithmetic, trigonometric and logical links.
Here, nesting is possible too.

The IF instruction must always be concluded with an ENDIF instruction,


because otherwise the end of the routine or that of the alternative routine
will not be recognized. Since the placement of the ENDIF instruction de-
pends upon the program processing logic, the control sometimes fails to
reliably detect and interpret a missing ENDIF instruction. The result will
be confusing or misleading fault messages. It is therefore good practice
for the programmer to verify the completeness of the IF-instruction.

Example:
...
10 X = 1
20 .START
30 IF X>=100 THEN
40 GOTO .END
50 ELSE X=X+2.75
60 GOTO .START
70 ENDIF
...
90 END
...

. The standard NC jump commands GoAhead, GoBack, GoCond and


GoTo may not be used to jump into or out of an IF-THEN-ELSE-EN-
DIF instruction.
2-40 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

CPL instruction: CASE-LABEL...LABEL-OTHERWISE-ENDCASE


Within a program, it is often necessary to query more than two states of
an integer-expression or an integer-variable. In such cases, a query by
means of an IF-instruction is possible only with the use of several nested
IF -instructions. This requires additional computing time and worsens
the readability and maintainability of the program.

The attendant disadvantages can be overcome through the use of the


CASE-structure:
CASE <Integer-expression> OF
LABEL <Int.-Constant>[,<Int.-Constant>] [: <Instruction>]
<Instruction>
:
LABEL ...
:
[OTHERWISE <Instruction>
<Instruction>
:]
ENDCASE

Subsequent to the CASE-instruction, the program branches to the LA-


BEL-instruction in which one of the <integer-constants> is identical to
the value of the <Integer-expression>. Now all instructions up to the next
occurrence of the LABEL or OTHERWISE instruction will be carried out.
The program then branches directly to the ENDCASE -instruction.

If no LABEL instruction that fulfills this condition exists, the program


branches to the OTHERWISE instruction or (if OTHERWISE has not
been programmed) directly to the ENDCASE instruction.

The <instruction> area of a CASE construct can include all CPL instruc-
tions. A maximum of 10 CASE constructs can be nested.

Examples:
10 CASE A% OF
20 LABEL 0 : Y=1
30 LABEL 2
40 Y=Y*Y
50 LABEL 4 : Z=Y*Y
60 Y=Z*Z
70 OTHERWISE Y=0
80 ENDCASE
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-41
and Controls

NC Programming Basics

10 CASE (INT(X/Y)+C%) OF
20 LABEL 1.2 : X=1 : Y=2
30 LABEL 4.8
40 X=2 : Y=4
50 LABEL 0
60 X=0 : Y=1
70 OTHERWISE X=0 : Y=0
80 ENDCASE

10 CASE INTFELD%(1,2) OF
20 LABEL 1,2,3 : GOTO .MARK1
30 LABEL 4,5,6 : GOTO .MARK2
40 OTHERWISE GOTO .END
50 ENDCASE

. The standard NC jump commands GoAhead, GoBack, GoCond and


GoTo may not be used to jump into or out of a CASE-LABEL...LA-
BEL-OTHERWISE-ENDCASE instruction.

. It is not allowed to jump into a CASELABEL ...LABELOTHER-


WISEENDCASE instruction via CPL jump GOTO.
2-42 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

2.9 Repeat Instructions


If one or more program blocks are to be processed repeatedly depen-
ding on certain conditions, this can be programmed using CPL repeat
instructions. The multiple repetition of the program is known as a loop.

The IndraMotion MTX provides the following possibilities:


D CPL instruction FOR-STEP-TO_NEXT
D CPL instruction REPEAT-UNTIL
D CPL instruction WHILE_DO_END

CPL instruction: FOR-STEP-TO-NEXT


If the abort condition for the repeat instruction is to be a direct conse-
quence of the processing of the routine, a tracking counter would be re-
quired, for example.
This counter requires no specific programming for the FOR-NEXT loop.
A counting variable (INTEGER) is declared, the start- and end count of
which must be specified. If the counting increment deviates from 1, the
step size (STEP) can be specified.

Syntax:
FOR <Count var.>=<Starting value> [STEP <Step size>] TO <End
value><Routine>
NEXT [<Count.variable>]

Example:
10 FOR I%=0 TO 18
20 XSINUS(I%)=SIN(I%*10)
30 NEXT I%

After the end of the loop, the counting variable will have a value which is
larger than the end value (max. step size).
In this example, the sine values for 0 through 180 degrees are written to
the XSINUS field. The I% that was appended to the NEXT in line 30 is
for clarification purposes only and may be omitted.

It is also possible to program FOR-NEXT-loops with a variable step


size. In this case, the step size variable should possess the same type of
variable as the counting variable.

Example:
10 OPENW(1,P222,130)
20 SCHRITT%=2 : START%=1 : END%=3500 : NJUST
FOR COUNTER%=START% STEP STEP% TO END%
40 STEP%=ROUND(STEP%*SORT(STEP%))
50 PRN#(1,COUNTER: ,COUNTER%,STEP SIZE:
,STEP%)
60 NEXT
70 CLOSE(1)
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-43
and Controls

NC Programming Basics

Subsequent to program execution, the following appears in the P222


file:
COUNTER: 1 STEP SIZE: 3
COUNTER: 4 STEP SIZE: 5
COUNTER: 9 STEP SIZE: 11
COUNTER: 20 STEP SIZE: 36
COUNTER: 56 STEP SIZE: 216
COUNTER: 272 STEP SIZE: 3175
COUNTER: 3447 STEP SIZE: 178902

. The standard NC jump commands GoAhead, GoBack, GoCond and


GoTo may not be used to jump into or out of a FOR-STEP-TO-
NEXT instruction.

CPL instruction: REPEAT-UNTIL


If the abort condition for the repeat instruction is to be queried only after
the first time that the routine is processed, the REPEAT loop can be
used.

Syntax:
REPEAT <Routine> UNTIL <Condition>

Example:
:
30 REPEAT
40 X=X+1 Loop until X = 100
50 UNTIL X=100
:

. The standard NC jump commands GoAhead, GoBack, GoCond and


GoTo may not be used to jump into or out of a REPEAT-UNTIL in-
struction.
2-44 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

CPL instruction: WHILE-DO-END


If the abort condition for the repeat instruction is to be queried before the
first time that the loop is processed, the following can be formulated:
WHILE (. engl. while) the condition is fulfilled, DO execute the rou-
tine!(.engl. to do). The WHILE loop has the following structure:

Syntax:
WHILE <Condition> DO <Routine> END

Example:
:
30 WHILE SD(9)=0 DO Wait loop until SD(9) takes on a value of 0
40 I=I+1
50 END
:

. The standard NC jump commands GoAhead, GoBack, GoCond and


GoTo may not be used to jump into or out of a WHILE-DO-END in-
struction.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-45
and Controls

NC Programming Basics

2.10 Variable Programming

2.10.1 Variable Name

. Variable programming is a component of the CPL text range!

Variable programming in the CPL is used to design programs so that pa-


rameters can be set within them, thus adapting program execution to the
current conditions.
D A variable is any symbol name to which a few special boundary condi-
tions apply:
D Variable names must be unique.
D Variable names may not be identical to reserved CPL command
words.
Due to the formal separation between standard NC and CPL pro-
gramming, however, variable names can theoretically agree with
the name of NC functions or NC function parameters; for example,
a variable X could be defined although there is already an axis
with the designation X in the system.
D The variable name consists of any sequence of capital letters and
numbers; the first character must be a capital letter. A variable
name consisting of the characters N and only followed by charac-
ters is no valid variable name. This character string corresponds to
the identification of an NC block.
. Since only the first 8 characters of the name of the variable
are used to distinguish the name, only these 8 characters are
termed significant (exception: definable permanent varia-
bles).

D There is a total of 3 variable groups that specify the validity range of


the variables. The variable group is specified by appending an identi-
fier to the start of the name of the variable. This character always is
counted among the significant characters of the name! The following
variable groups, with the corresponding identifiers, exist:
D Local variables: no special identifier
D Global variables: #
D Permanent variables: @

D The type of variable is always specified by appending an identifier to


the end of the name of the variable. This also applies if the variable
name exceeds the number of significant characters. The following va-
riable types, with the corresponding identifiers, exist:
D INTEGER: %
D DOUBLE: !
D BOOLEAN: ?
D CHARACTER: $
D REAL: no special identifier
2-46 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

Examples of local, global and permanent variables:


10 NUMBER1% = 1 Local INTEGER variable
20 #NUMBER2% = 2 Global INTEGER variable
30 @36% = 3 Permanent INTEGER variable
40 @ABCD% = 4 Defined permanent INTEGER variable

2.10.2 Groups of Variables


Declarations with regard to the effective range of variables are required
due to the option of using subroutines, as well as due to the possible re-
quirement to commit the values of variables to intermediate storage in-
dependent of the respective program being executed. To this end, a
distinction is made between the following groups of variables:

Local variables
take effect only within the program for which they have been declared.
When the referred program reaches the end of program (EP), the varia-
bles are deleted, thus releasing the occupied memory. In the case of a
subroutine call, the name of a variable that is local with respect to the
main program will not be visible to the subroutine. However, the same
variable can also be declared as a local variable in the subroutine without
consequential interference due to the similarity of their respective na-
mes. Upon the return to the main program, the original local variable will
again be available, bearing the value that was current at the time the sub-
routine was invoked from within the main program.

Global variables
are identified by a leading # (number sign, gate or hash) character.
Once a value has been assigned to a global variable, it can be accessed,
read and/or modified from within all program parts for the remainder of
the entire program. Global variables are deleted subsequent to end of
program (EP).

. The validity of each global variable is limited by a link unit!


(Explanations of link units can be found in section 2.2, Linking NC
Programs, page 2-6 Link Units).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-47
and Controls

NC Programming Basics

Permanent variables
are identified by a leading @ character that is followed by the name of
the variable. They can be addressed by any active program. The varia-
ble will be permanently retained even subsequent to EP. Deletion is pos-
sible only through direct overwriting. Permanent variables are stored in a
separate memory range. As a result, clearing the entire memory will not
affect permanent variables.

Permanent variables of the INTEGER type can be addressed under de-


signations @1 through @100 (for detailed information on the INTEGER
type, see Variable Types on page 2-52). To improve program readability,
the indication of such permanent variables can also be augmented by
appending letters to the number.
In addition, the permanent one dimensional field variable @_R can be
used with 100 elements of Double. The two permanent variables
@_RES_DOUBLE and @_RES_DWORD are reserved for internal ap-
plications and should not be used.

Definable permanent variables


are also identified by a leading @ character followed by the name of a
variable.
The differences compared to permanent variables are as follows:
1. Definable permanent variables are not automatically declared as a
component of the system software but must be manually declared
via user entry in the files named wmhperm.dat (for proprietary
data supplied by the machine tool manufacturer-) and anw-
perm.dat (for end user-specific data). The declaration syntax is di-
scussed under File structure of wmhperm.dat and anwperm.dat,
below.
During system startup, the control searches for the files first in the
root directory, then in the user- FEPROM, and finally in the FEPROM.
The control interprets the file identified by the first occurrence of the
respective filename, using the entries found therein to create defina-
ble permanent variables, provided they do not already exist. Existing
definable permanent variables that are not declared in one of the
above named files will be deleted.
The maximum possible number of definable permanent variables is
dictated by the available memory capacity. In the event that no more
memory capacity is available for generating variables, the Typ3 osa/
PNC will return an appropriate error message.

2. The names of definable permanent variables always begin with the


@ character and a character string. This character string con-
sists of one capital letter, followed by any combination of capital let-
ters or numbers.
In the case of the definable permanent variables, the first 16 charac-
ters of the name of the variable are significant. If two names of varia-
bles exhibit a difference only with the 17th character or later, CPL will
interpret them as a single variable!
2-48 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

3. Defined permanent variables may be of the INTEGER, REAL,


DOUBLE, BOOLEAN or CHARACTER type.
The type of variable- is specified by appending an identifier to the end
of the name of the variable. This specification must be entered into
the parts program:
@ABCD% defined permanent variable of INTEGER type
@EFGH defined permanent variable of REAL type (without %, !,$
or ?)
@IJKL! defined permanent variable of DOUBLE type
@MNOP? defined permanent variable of BOOLEAN type
@QRST$ defined permanent variable of CHARACTER type

4. One- and two dimensional fields may be used.


The maximum field index is 65535 with field variables of the INTE-
GER, REAL, DOUBLE or BOOLEAN type. With field variables of the
CHARACTER type, the maximum field index is 1024.

Examples:
@WZNR%(1)=4 The first variable (with Index 1) of the 1-dimen-
sional field @WZNR of the INTEGER type is
assigned a value of 4.
@WZKOR(2,2)=0.2 The variable (with the indices 2,2) within the
2-dimensional field @WZKOR of the REAL type
is assigned a value of 0.2.

5. Estimating the available number of newly definable permanent va-


riables:
D Total memory space for permanent variables:
100 Kb (102,400 bytes).

Item Reserved for Memory Comment


in bytes
1 all permanent variables 102400 Total memory
of which the following are
reserved for
2 @1 - @100 800
(permanent variables)
3 administrative information 24
4 all definable 101576 (4) = (1) - (2) - (3)
permanent variables
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-49
and Controls

NC Programming Basics

Item Reserved for Memory Comment


space in by-
tes
4 all definable permanent va- 101576 (4) = (1) - (2) - (3)
riables
of which the following are
reserved for
5 @_R 823 Permanent field va-
riable with 100 ele-
ments of the type
DOUBLE
6 @_RES_DOUBLE 40 Permanent variable
of the type
DOUBLE, reserved
for internal applica-
tions
7 @_RES_DWORD 35 Permanent variable
of the type INTE-
GER, reserved for
internal applica-
tions
8 new definable 100678 (8) = (4) - (5)
permanent variables - (6) - (7)

Each definable permanent variable occupies the following memory


space:

Item Reserved for Memory Comment


space in by-
tes
9 the names of the definable max. 16 1 byte per
permanent variables character
10 the value of the definable 1, 4 or 8 Integer: 4 bytes
permanent variables Double: 8 bytes
Real: 4 bytes
Boolean: 1 byte
11 administrative information 20
12 a definable permanent varia- 44 e.g.: maximum as-
ble of the DOUBLE type with signment of memory
a name length of 16 charac- space
ters (9) + (10) + (11)
2-50 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

Number of definable permanent variables of the types DOUBLE


and INTEGER:
Variable type Number of Comment
variables
Type DOUBLE with a name 2288 100678/44=2288
length of max. 16 characters
Type INTEGER with a name 2516 100678/(16+4+20)
length of max. 16 characters =2516
Type INTEGER with a name 3146 100678/(8+4+20)
length of max. 8 characters =3146
Field variables with name 25160 (100678-16-20)/4
lengths of max.16 characters, =25160
Type INTEGER
Field variables with name 12580 (100678-16-20)/8
lengths of max.16 characters, =12580
Type DOUBLE

Structure of wmhperm.dat and anwperm.dat files:


The files may contain only declarations of definable permanent varia-
bles. Each declaration occupies a separate line and concludes with a
RETURN.

A line of declaration always exhibits the following structure:


DEF <Variable type> @<Variable name>; [<Remark>]

Examples of wmhperm.dat and anwperm.dat:


DEF INT @ABCD ;simple INTEGER variable
DEF REAL @EFGH ;simple REAL variable
DEF DOUBLE @IJKL ;simple DOUBLE variable
DEF BOOL @MNOP ;simple BOOLEAN variable
DEF CHAR @PSTR1(3) ;CHARACTER variable with a length of 3
DEF INT @WZNR(9) ;1-dimensional INTEGER field with 9 variables
DEF INT @WZKOR(9,2) ;2-dimensional REAL field with 18 variables
DEF CHAR ;2-dimensional CHARACTER field with 9 partial
@PSTR2(9,2) strings of 2 characters each

Sample applications for permanent variables:


10 @1 = 1
15 @2_COUNTER = 2
20 @ABCD% = 3
25 @EFGH = 4.1
30 @IJKL! = 5.12345
35 @MNOP? = TRUE
40 @PSTR1$ = ABC
45 @WZNR%(2) = 6
50 @WZKOR(3,2) = 7.6
55 @PSTR2$(3) = DE
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-51
and Controls

NC Programming Basics

Structured variables
can be replaced by system data (SD), but are retained for reasons of
compatibility (see section 5.8.2, System Data of Structured Types).

Structured variables are characterized by various structure levels that


are separated by a period (.) when they are represented. Structured
variables always start with SV..

All structured variables that are to be accessed in a CPL-instruction must


be declaredmanually in file machdef.datvia entry . During system star-
tup, the control searches for the files first in the root directory, then in the
user FEPROM, and finally in the FEPROM. This first found file is evalua-
ted when the NC is started up; the administration data and the memory
for the structured variable user data are created at the same time. The
memory is created again and all values are preset to 0 during every star-
tup.

File machdef.dat is used only to define structured variables. Each defi-


nition occupies a separate line and concludes with a semicolon.
A definition line always exhibits the following structure:
DEF <Variable type> SV.<Variable name>; [<Remark>]
<Variable type> and <Variable name> are strings that can consist of lo-
wercase or capital letters, numbers, a dash and an underline.

. For all variable names, the first 16 characters are significant. If two
names of variables exhibit a difference only with the 17th charac-
ter or later, CPL will interpret them as a single variable!

Example:
DEF DBT1Rec_t SV.A; Definition of a structured varia-
ble of type DBT1Rec_t

CPL instructions can access both SV.A and all the structure components
of SV.A. The various structure components are separated from one an-
other by a ..

Example:
10 SV.A.Hd=DBSEA(DBT1,-1,-1,K1=1,FOUND%)
2-52 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

2.10.3 Variable Types


INTEGER variable
An INTEGER-variable occupies 32 bits of memory space. It is identified
by a %- character appended to the name of the variable. The value
range extends from -2.147.483.647 through +2.147.483.647.

10 NUMBER% = 4

INTEGER variable

Floating-point variable (REAL)


If no special identification is appended to the name of the variable, the
variable will be interpreted as a REAL -variable of single precision.
In this case, the variable occupies 32 bits of memory space. The value
range is +/-1038. This corresponds to 7 significant positions.

10 PI = 3.141593

REAL variable with single precision

Floating-point variable (DOUBLE)


If an exclamation mark !- is appended to the name of the variable, the
variable will be interpreted as a REAL- variable with double precision.
In this case, the variable occupies 64 bits of memory space. The value
range is +/- 10308. This corresponds to 15 significant positions.

10 PI! = 3.141592653589793

REAL variable with double precision

Logical variable (BOOLEAN)


These variables are identified by a ? question mark that is appended to
the name of the variable. Logical variables (Boolean variables) can as-
sume only the values TRUE or FALSE. They are used to store logical
states or conditions that will be needed throughout the course of pro-
gram execution.

10 START? = FALSE

BOOLEAN variable
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-53
and Controls

NC Programming Basics

Field variable (ARRAY)


The use of ARRAY variables makes it possible to reserve, under a single
designation, a one- or two-dimensional field (array), consisting of one or
more variables of the same type, within the memory range.
Field definitions are possible for variables of the INTEGER, REAL,
DOUBLE, BOOLEAN and CHARACTER types. To enable access to the
individual field elements of an array, the field index and/or indices are
specified in addition to the name of the field variable.

Example:
Dimensioning an ARRAY variable
10 DIM FIELDVAR(2,3)

INTEGER constants for field sizes (index)


Name of variable (REAL variable)
DIM instruction word

Example:
Access to array variable
100 FIELDVAR(1,1) = MPOS(1)
110 FIELDVAR(2,1) = CPOS(1)
120 FIELDVAR(1.2) = MPOS(2)
130 FIELDVAR(2.2) = CPOS(2)
140 FIELDVAR(1.3) = MPOS(3)
150 FIELDVAR(2.3) = CPOS(3)

Prior to the initial access to the field variables, the index range and/or the
field size must be dimensioned with INTEGER constants:
D Field size of the field variable of types INTEGER and REAL:
max. 65536
D Field size of the field variables of type CHARACTER:
max. 1024

DIM <Variable name>(<Field size1>[,<Field size2>])

. Dimensioning with DIM may not be applied to definable perma-


nent variables. Instead, the dimensioning of these variables oc-
curs in the file wmhperm.dat or anwpwerm.dat.
2-54 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

CHARACTER- and STRING-variables


A CHARACTER-variable is identified by a trailing $ (dollar) sign. This
type of variable can accommodate a single character as well as a com-
plete character string.
However, character string instructions (see section Processing Charac-
ter Strings) are possible only if a character string is stored in a one-or
two-dimensional field (array) of CHARACTER variables. For this, the
field must be declared by means of a DIM instruction.
Each CHARACTER-variable in this field then contains only one charac-
ter of the character string.
A one-dimensional field comprised of variables of the CHARACTER
type is termed a STRING variable. No index is entered when accessing a
one-dimensional CHARACTER variable. However, when accessing a
two-dimensional CHARACTER variable, an index must be entered.

Example:
1 REM String variable AB (length = 10)
2 DIM AB$(10)
3 REM 3 string variables CD (each with a length of 5)
4 DIM CD$(3,5)
5 AB$ = Z
6 CD$(2) = ABC

Overview of variables
Variable group Variable name Variable type Fields (arrays)
possible (X=yes)
Local max. 8 significant % INTEGER X
characters REAL X
! DOUBLE X
? BOOLEAN X
$ CHARACTER X
Global# incl. #character, % INTEGER X
max. 8 significant REAL X
characters ! DOUBLE X
? BOOLEAN X
$ CHARACTER X
Permanent@ 1 - 100
Definable max. 16 signifi- % INTEGER X
permanent@ cant characters REAL X
! DOUBLE X
? BOOLEAN X
$ CHARACTER X
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-55
and Controls

NC Programming Basics

2.10.4 Variables in Standard NC Programming


It often happens that you want to set NC functions or parameters of NC
functions using variables in a parts program within standard NC pro-
gramming (DIN).
In this value assignment, note that CPL expressions within standard NC
programming must be enclosed within square brackets [ and ].

Samples for setting the parameters of standard NC blocks:


10 ANGLE = 45
20 VAL1 = 1.5
30 VAL2 = 1.5
40 XPOS = 10.2
50 YPOS = 5.73
60 FEEDRATE = 1000
N70 Rotate([ANGLE])
N80 Scale(X[VAL1],Y[VAL2])
N90 G1 X[XPOS] Y[YPOS] F[FEEDRATE]

. The block number cannot be parameterized using CPL variables!

. None of the addresses invoking a subprogram are intended for va-


riable syntax.
2-56 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

2.10.5 Variable ERRNO for Evaluating Errors in CPL Functions


CPL variable ERRNO, in which the called function returns errors, can be
transferred as a transfer parameter to a CPL function, which generates a
runtime error if an error occurs.

ERRNO
CPL variable ERRNO is an optional parameter that can be programmed
in the CPL functions in which it has been entered as a parameter. It can
be programmed at any position there.

If ERRNO is not programmed, the CPL function generates a runtime er-


ror or a warning if an error occurs.
If ERRNO is programmed, the CPL function does not generate a run-
time error or a warning. In this case, CPL variable ERRNO must be eva-
luated in the CPL program and a runtime error (using SETERR) or a
warning (using SETWARN) must be generated explicitly.

If the CPL function is executed correctly, ERRNO has a value of 0. Errors


are returned using negative values. The meaning of the negative values
is generally valid; however, not all values are relevant for every CPL
function. The error values possible for a CPL function are carried out for
the appropriate function.

List of generally valid error values:


0 : Access OK
-1 : Parameter error
-2 : Coordinate/axis does not exist.
-3 : Invalid coordinate/axis in channel.
-4 : Axis is not a pseudocoordinate.
-5 : Channel does not exist.
-6 : Function may be called only in an autonomous channel.
-7 : Data cannot be read.
-8 : Name of source file, including path, is too long
-9 : Access to source file impossible
-10 : Name of target file, including path, is too long
-11 : File name (source or target) invalid
-12 : Copying impossible.
-13 : Data could not be written.
-14 : XML table exists
-15 : XML table not found
-16 : Invalid file extension
-17 : Invalid table type
-18 : Insert position faulty
-19 : Maximum axis number exceeded
-20 : Faulty root tag
-21 : Accessing file not possible
-22 : Invalid key
-23 : Data record is locked
-24 : No read privileges for the file
-25 : No write privileges for the file
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-57
and Controls

NC Programming Basics

Example:
Read the position of channel-axis X in the first channel.
One of the following four lines (all with the same effect) can be program-
med:

10 POS = ACS(X,1,1,ERRNO)
10 POS = ACS(X,1,ERRNO,1)
10 POS = ACS(X,ERRNO,1,1)
10 POS = ACS(ERRNO,X,1,1)
2-58 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

SETERR
After ERRNO has been evaluated, CPL command SETERR can be
used to generate a runtime error. As a result, the parts program is inter-
rupted at this point.
The text entered in parameter <Error string> is always output, regard-
less of the general language setting.

Syntax:
SETERR(<Error string>[,<Channel>])
where:
<Error string> Text that is output as an error.
(under Wera error number 3371)
<Channel> Channel number in which the error is to be output.
If <Channel> is not entered, the current channel is
used as the default value.
ERRNO CPL variable that can be programmed in any position
within parentheses.
When ERRNO is programmed, no runtime error is is-
sued; the return values are:
0: Access OK
-1: Parameter error
-5: Channel does not exist.

Example:
Read the position of channel axis X in the first channel.
10 POS = ACS(X,1,1,ERRNO)
20 IF ERRNO <>0 THEN
30 SETERR(Position could not be read)
40 ENDIF
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-59
and Controls

NC Programming Basics

SETWARN
After ERRNO has been evaluated, CPL command SETWARN can be
used to generate a warning; the parts program will continue to run.
The text entered in parameter <Warning string> is always output, re-
gardless of the general language setting.

Syntax:
SETWARN(<Warning string>[,<Channel>])
where:
<Warning string> Text that is output as a warning.
(under Wera error number 3372)
<Channel> Channel number in which the warning is to be
output.
If <Channel> is not entered, the current channel
is used as the default value.
ERRNO CPL variable that can be programmed in any po-
sition within parentheses.
When ERRNO is programmed, no runtime error
is issued; the return values are:
0: Access OK
-1: Parameter error
-5: Channel does not exist.

CLRWARN
Command CLRWARN makes it possible to clear all the warnings of a
channel generated by SETWARN.

Syntax:
CLRWARN([<Channel>])
where:
<Channel> Channel number in which all the warnings generated
by SETWARN are to be cleared.
If <Channel> is not entered, the current channel is
used as the default value.
ERRNO CPL variable that can be programmed in any position
within parentheses.
When ERRNO is programmed, no runtime error is is-
sued; the return values are:
0: Access OK
-1: Parameter error
-5: Channel does not exist.

Example:
10 CLRWARN(,ERRNO)
20 IF ERRNO <>0 THEN
30 SETWARN(Warnings not cleared)
40 ENDIF
2-60 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

2.11 Reserved Instruction Words


The key terms listed below must be used in stand alone fashion or be
delimited by special characters, identifying them as instruction words.
The selection of names for variables must not encompass any reserved
instruction words!

Example:
GOTO 10 Jump to line 10
GOTO10 any symbol name (variable); if it is alone, it leads to error
message Runtime error 2167 = missing because a va-
lue assignment for variable GOTO10 is expected.

Key terms
O: ABS AXO B: BCD C: CALL COF D: DATE DIRDEL
ACOS AXP BIN CASE COS DBSEA DIRINF
AND BITIF CHR$ CPOS DBTAB DO
APOS CLOCK CPROBE DCT DPC
ASC CLOSE DIM
ASIN CLRWARN DIRCR
ATAN
I: ELSE ERRNO F: FALSE FILESIZE G: GETERR I: IF
END FILEACCESS FOR GOTO INP#
ENDIF FILECOPY FXC INSTR
ENDCASE FILEDATE FXCR INT
EOF FILENO FXDEL
ERASE FILEPOS FXINS
L: LABEL M: MCODS N: NCF O: OF
LEN MCOPS NEXT OPENR
LJUST MID$ NJUST OPENW
MMC NOT OTHERWISE
MPOS NUL OR

P: PDIM R: REM S: SCL SETERR T: TAN TRUE


PMT REPEAT SCS SETWARN TCV
PMV REWRITE SCSL SIN THEN
PPOS ROUND SD SPOS TIME
PRN# SDR SQRT TO
PROBE SEEK STEP TRIM$
STR$
U: UNTIL V: VAL W: WAIT X: XOR
VERSINF$ WHILE XTAB
WPOS

Z: ZOT
ZOV
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-61
and Controls

NC Programming Basics

2.12 CPL Instructions


Local as well as global variables can be assigned values. This is accom-
plished with the use of the = (equals) sign.

Example: Value assignment for a BOOLEAN variable


10 START? = FALSE

Value
Assignment symbol
(Logical) variable

Example: Value assignment for a REAL variable


1 X1MIN! = 2097.876

Value (max. 7 digits)


Assignment symbol
Double-precision REAL variable

Example: Value assignment between variables


1 XSET = X1MIN!

Value (double-precision REAL variable)


Assignment symbol
Single-precision REAL variable

The variable to be assigned a value must be positioned to the left of the


assignment symbol and the respective value to the right. This declara-
tion must be used with caution especially in cases where the value of one
variable is to be assigned to another variable.

NUL
If a value has not been assigned to a variable, it will have the value of
NUL. As a consequence, the statement <Variable>= NUL is true. This
signifies that the equals sign can also be used in expressions represen-
ting comparisons or conditional operations.

If the direct deletion of a local or global variable is desired, this can be


accomplished by assigning the NUL value. In contrast, a permanent va-
riable cannot be deleted but requires overwriting.

Example: Delete a variable


1 XSET = NUL
2 IF XSET = NUL THEN
3 PRN#(0,Variable not assigned.)
4 ENDIF
2-62 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

Mathematical operations
Besides the assignment of a value in the form of a constant expression
(numerical) or a variable, it is also possible to assign the value of a CPL-
expression to a variable. A CPL-expression may contain functions using
both constants and variables.

The simplest functions include the four basic arithmetical operations:


Addition +
Subtraction -
Multiplication *
Division /

As a rule, multiplication and division take priority over addition and sub-
traction. It is also possible to use parentheses, the nesting of which, to a
depth of seven, can be used with simple expressions (containing no
function calls).

Example:
1 I% = 25: XACTUAL = 10
2 XSET = 150/(100-I%)+XACTUAL XSOLL has a value of 12.

It is also possible to invoke arithmetical functions that act upon variables,


constants or CPL expressions which must be placed in parentheses im-
mediately behind the respective instruction word. The function always
refers to the internal numerical representation of the input value. This re-
presentation can be verified during program execution with the use of
Program check. In the case of nested expressions, and particularly
when these contain function calls, the maximum possible nesting depth
must be considered. It is dependent upon the memory capacity required
by the expressions within parentheses during their respective execution.

ABS
Returns the absolute value of the input value, i.e. negative values be-
come positive, while positive values remain positive.

Example:
1 I% = -125
2 XVALUE = 2*SQRT(ABS(100+I%)) XWERT has a value of 10.

INT
converts the input value (REAL) by cutting off the decimal places (roun-
ding) to a whole number (INTEGER). The input value may be a constant
or a variable.

Example:
1 XVALUE% = INT(10.9) XWERT has a value of 10.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-63
and Controls

NC Programming Basics

ROUND
converts the input value into a whole number (INTEGER) by rounding it
down or up. The input value can be a REAL-expression.

Example:
1 XVALLUE% = Round(10.9) XWERT has a value of 11.
2 XVALLUE% = Round(5.5) XWERT has a value of 6.
3 XVALUE% = Round(5.49) XWERT has a value of 5.

SQRT
This command forms the square root of an input value. The input value
must not be a negative value; this is not defined.

Example:
1 I% = 44
2 XSET = 4*SQRT(100+I%) XSOLL has a value of 48.

SIN, COS, TAN, ASIN, ACOS, ATAN


In the case of trigonometric functions that process angles in terms of
conventional degrees of arc, it is useful to identify the angles as double-
precision REAL variables. The following trigonometric functions can be
used:
D SIN Sine function
D COS Cosine function
D TAN Tangent function
D ASIN Arc-sine function
D ACOS Arc-cosine function
D ATAN Arc-tan function

Example:
1 ANGLE = 30
2 XVALUE= SIN(ANGLE) XWERT has a value of 0.5.
3 YVALUE = ASIN(XVALUE) YWERT has a value of 30.
2-64 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

Logical links
Binary logical operations can be effected by means of logical variables,
and decimal logical operations by using INTEGER variables. As depic-
ted in the diagram below, logical operations can be represented with the
usual operating symbols, i.e. the -and +-symbol (not in CPL, ho-
wever). As a consequence, multiplication/division calculations take
priority over addition/subtraction calculations, i.e. the AND operation
takes priority over the OR operation. Parentheses may be nesting up to a
depth of seven.

NOT, AND, OR, XOR


CPL provides four types of linking functions:
D NOT-Function NOT
D AND-Function AND
D OR-Function OR
D EXCLUSIVE-OR-Function XOR

E1 E1 E1
E1 1 o!A & A >1 A =1 A
E2 E2 E2

NOT!member AND!member OR!member XOR!member

E1 = A E1 . E2 = A E1 + E2 = A E1 . E2+E1 . E2=A

NOT AND OR XOR

E1 0 L 0 0 L L 0 0 L L 0 0 L L
E2 0 L 0 L 0 L 0 L 0 L 0 L
A L 0 0 0 0 L 0 L L L 0 L L 0

Logical operations can be utilized for bit masking.

Example: Is bit 0 set in @20?


...
20 IF @20 AND 1 <> 0 THEN GOTO . SET
30 ELSE GOTO . UNSET ENDIF
...
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-65
and Controls

NC Programming Basics

Conversion between numeric systems

BCD
Converts binary value into BCD-format:
<BCD-Value>=BCD(<Binary value>)
Example:
1 BCD_VALUE = BCD(49) BCD_WERT has a value of 73.

BIN
Converts BCD-coded numbers into binary value:
<Binary value>=BIN(<BCD-Value>)
Example:
1 BIN_VALUE = BCD(49) BIN_WERT has a value of 31.

Comparison operations

=, >=, >, <>, <=, <


The following comparison operators are permissible:
= equal
>= greater than or equal to
> greater than
<> not equal to
<= less than or equal to
< less than

Comparison operations are used to describe the relation (fulfilled or


not fulfilled) of a condition (e.g. for the commands REPEAT - UNTIL,
WHILE - DO - END, IF - THEN - ELSE - ENDIF).
2-66 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

2.13 Additional Basic CPL Elements

Constants
If numerical values are declared for program execution and are to re-
main unchanged (constant), such values may be entered into the in-
structions as a numerical expression.

Integer-constant (INTEGER)
Integers are written without decimal points.

Example:
NUMBER% = 4 INTEGER-constant

Floating-point constant (REAL)


Real numbers (decimal numbers- or fractions) are identified by a deci-
mal point (floating point).

Example:
PI = 3.141593 REAL constant

Double-precision constants and double-precision operations


Constants assigned to or compared with a double-precision REAL varia-
ble are represented with double precision, i.e. precise to 15 digits.

Example:
Assignment of double-precision REAL constants and comparison of va-
riables with double-precision REAL constants.

4 D5! = -1234.123456 + 12345 + 1234.234567


20 D0! = 123456789.123456
22 D1! = 1.12345678901234
24 D2! = -123456789012345
26 D3! = -1234.123456
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-67
and Controls

NC Programming Basics

The following queries produce the result E? = TRUE


28 IF D0!=123456789.123456 THEN E?=TRUE ELSE E?=FALSE ENDIF
29 IF D1!=1.12345678901234 THEN E?=TRUE ELSE E?=FALSE ENDIF
30 IF D2!=-123456789012345 THEN E?=TRUE ELSE E?=FALSE ENDIF
31 IF D3!=-1234.123456 THEN E?=TRUE ELSE E?=FALSE ENDIF
32 IF D0! + 2.1 + 3.1 = 123456789.123456 + 2.1 + 3.1 THEN
33 E? = TRUE
34 ELSE
35 E? = FALSE
36 ENDIF
37 IF (D0! + 2.1) + 3.1 = 123456789.123456 + 2.1 + 3.1 THEN
38 E? = TRUE
39 ELSE
40 E? = FALSE
41 ENDIF

Character string constant


A character string constant is limited by quotation marks ( ).

Example:
BEISPIEL$ = This is a character STRING constant
string

Code characters
CPL uses the following code characters:

# ! ? , " [ ] < / &


@ % $ : ( ) = > + *

The comma is normally used as a delimiter. It is used as a grammatical


punctuation mark only within character strings. The period is used as a
decimal point in decimal numbers and as a label identifier in jump de-
stinations. Within character strings, the period is interpreted as a gram-
matical punctuation mark.
2-68 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

2.14 NC Block Synchronization Commands

2.14.1 Overview
NC block synchronization commands can be used to:
D Synchronize NC programs to specific events.
D Synchronize block preparation with program execution.
D Limit Look-Ahead to a certain number of blocks.
D Synchronize NC programs in different channels to one another.

Synchronization functions go into effect either at the time of block prepa-


ration or at the active time of block execution.

Synchronization functions of block preparation


D WAIT(no parameter) Pauses block preparation until all previous
blocks have been processed.
D CPL function WAIT(,<Waiting time>): Block preparation is paused for
the entered time.
D CPL function WAIT(BITIF(...)): Block preparation waits for a certain
signal within the PLC-NC bit interface.
D BlkNmb: Limits Look-Ahead to the programmed number of blocks.

Synchronization functions for active time


D WAITA / WAITO: Wait for a certain status on the PLC-NC bit interface.
D WPV / WPVE: Wait for the value of a permanent CPL variable.
D SPV / SPVE: Write permanent CPL-variables
D ASTOPA / ASTOPO: Movement stop until certain axis positions have
been attained.
D BSTOPA / BSTOPO: Movement stop until certain axis positions in the
basic-workpiece coordinate system (BCS) have been attained.
D WSTOPA / WSTOPO: Movement stop until certain axis positions in
the current workpiece coordinate system (WCS) have been attained.
D OFFSTOPA / OFFSTOPO: Cancellation of stop conditions in the con-
trol channel.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-69
and Controls

NC Programming Basics

2.14.2 Synchronization Functions of Block Preparation

WAIT(no parameter)
Function WAIT stops block preparation until all the blocks that were
programmed before the WAIT block have been fully processed. It is ab-
solutely required if current machine- or process-based data are to be
subsequently accessed within the program.

Viewed in terms of elapsed time, block preparation, i.e. the operation by


which the individual program lines are analyzed and interpreted, is al-
ways carried out in advance of its execution on the machine. The period
between preparation and execution is not constant; instead, it depends
on many parameters (feedrate, distance traversed, Look-Ahead, etc.).

Therefore, if the program is to respond to a machine- or process-related


actual status (e.g. current actual-position, signal at the bit interface,
etc.), the WAIT instruction must be used to ensure that the aforementio-
ned time lag equals zero at the precise evaluation time.

Example: WAIT(no parameter)


N10 X0
N100 (MSG, still running)
N20 X150
30 WAIT Pause block execution
40 XPOS = MPOS(1)-150
50 IF XPOS < 0.0001 THEN Position reached is output to
(MSG, position reached) X=150
70 ENDIF

. Function WAIT (no parameter) can be programmed in both stan-


dard-NC-blocks (DIN) and CPL-blocks. A CPL-block that includes a
WAIT-command must not contain a :. The subsequent CPL-com-
mands must be written in a new CPL-block.
2-70 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

CPL-function: WAIT(,<Waiting time>)


Stops block preparation until the programmed waiting time has elapsed.

Syntax:
WAIT(,<Waiting time>[,<ResVar>])
where:
<Waiting time> Waiting time in milliseconds; no places to the right of
the decimal point. The waiting time may also be pro-
grammed as an arithmetic expression.
<ResVar> Optional integer variable. After the waiting time has
elapsed, <ResVar> is assigned a value of 1.

Examples of WAIT with waiting time:


10 WAIT(,1000,E%) Block processing is paused for 1000ms.
Subsequently, the E% variable is assigned
integer value 1.
10 WAIT(,TIME%) The duration that block processing is held
depends on the content of the ZEIT% inte-
ger variable. No value is returned.

CPL function: WAIT(BITIF(...))


Stops block preparation until a certain status occurs on the PLC-NC bit
interface.
A duration may be programmed as an option. Block preparation is then
paused until the status occurs on the bit interface or until the duration has
elapsed.

Syntax:
WAIT(<BITIF-Condition>[,[<Timeout>][,<Result var>]])
where:
<BITIF condition> Specifies the condition that is to be checked on
the PLC-NC bit interface. The following syntax
must be maintained:
[NOT(]BITF(<Parameter>)[)][=<Sta-
tus>]
<Parameter> Transfer parameter of the BITIF-
function (for a description,
please refer to BITIF-Function,
page 5-51).
<Status> BOOLEAN expression with
which the result of the BITIF
function is compared. If <Status>
is not programmed, the compari-
son will be made to TRUE.
If the condition is fulfilled, block preparation re-
sumes.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-71
and Controls

NC Programming Basics

<Timeout> Block preparation waits until the <BITIF condi-


tion> has been fulfilled, but not longer than until
the <Timeout> time has elapsed.
<ResVar> Optional integer variable. After the waiting time
has elapsed, <ResVar> is assigned a value of 1.

Examples for WAIT(BITIF(...):


10 WAIT(BITIF(1,1,1)=TRUE) Wait until the 2nd axis-based input signal of the 1st axis
has been set.
10 WAIT(BITIF(2,0,2)=(E1? OR E2?)) Wait until the 3rd channel-based input signal of the 2nd
channel has the value of the logical expression (E1? OR
E2?).
10 WAIT(NOT BITIF(3,2,1),,C%) Wait until the 4th spindle-based input signal of the 1st
20 IF C%=0 THEN spindle has a value of FALSE. Variable C% supplies a va-
30 DSP(10,10,BED. ALREADY OK) lue of either 0 (if the condition had already been fulfilled
40 ENDIF when WAIT was called) or 2 (if the condition was fulfilled
during the wait).
10 WAIT(BITIF(4,4,1)=E7?,250,ERG%) Wait until the 5th axis-based output signal of the 1st axis
20 IF C%=0 THEN takes on a value of variable E7? or until 250 ms have elap-
30 DSP(10,10,NOT WAIT) sed. Variable ERG% supplies a value of either 0 (if the
40 ENDIF condition had already been fulfilled when WAIT was called),
50 IF ERG%=2 THEN 1 (if the duration has elapsed) or 2 (if the condition was
60 DSP(10,10,>250ms WAITED) fulfilled during the wait).
70 ENDIF
2-72 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

BlkNmb (BNB)
Using the standard NC function BlkNmb, the maximum number of blocks
in the block preparation function can be limited.

For example, the BlkNmb function can be used to control further proces-
sing of runtime measuring results in the parts program.

Syntax:
BlkNmb(<Num>) Limit ON.
BlkNmb() or Limit OFF.
BlkNmb(0) The max. permitted number of blocks
depends on MP 7060 00110.

Abbreviation: BNB(...)
where:
<Num> Maximum desired number of blocks.
Integer.
Input range: greater than or equal to 0.
0: The number of blocks depends on
MP 7060 00110.

Special features and restrictions:


D If more than <Num> blocks have been prepared at the time that the
function is called, block preparation pauses until the number of prepa-
red blocks drops below <Num>.
D If the entry in <Num> is greater than the number of blocks that is plan-
ned within the framework of the control configuration, the effective
number of blocks is automatically reduced to the settings in
MP 7060 00110 .
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-73
and Controls

NC Programming Basics

2.14.3 Synchronization Functions for Block Execution Time


One program per channel can run in the IndraMotion MTX. If the indivi-
dual processing segments are divided into different individual programs
and if these programs run on different channels, the processing se-
quence of all individual programs can be controlled by the synchroniza-
tion functions for the block execution time.

All synchronization functions for the block execution time have CPL pa-
rameter lists (similar to subroutines). Lists of CPL expressions that
must be enclosed in square brackets: [ and ] are programmed in
these.

General rule:
D The permanent CPL-variables used in the functions WPV, WPVE,
SPV, SPVE are valid throughout the system. Therefore, the program-
mer has to make sure that incorrect use does not lead to unintended
function interaction.
D In the framework of the NC-functions offered, only the following sim-
ple types of permanent CPL-variables are permitted:
- INT
- BOOL
- REAL
- DOUBLE
In the case of arrays, only individual elements may be addressed!

Functions WAITA, WAITO, WVP, WVPE implicitly effect a downs-


lope at the end of the block. Synchronization points which have
been set incorrectly can lead to damage of the machine.
Test the program sequence for possible synchronization pro-
blems prior to the actual processing.
2-74 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

Wait for the states on the PLC-NC bit interface: WAITA / WAITO
Using function WAITA / WAITO starts the waiting process at runtime until
one or more of a maximum of 16 interface signals have reached a speci-
fied value.

The following can be programmed, depending on the link, in the case of


several interface signals:
D WAITA: AND link of the individual signals
Wait until all interface signals have taken on the specified value.
D WAITO: OR link of the individual signals
Wait until one interface signal has taken on the specified value.

Example:
Program 1 on channel 1 processes the end face of a turned part. Pro-
gram 2 in cahnnel 2 is to cut a groove into this end face and mustwait, for
program 1 to release the turned part for program 2. The release for pro-
gram 2 is effected by setting certain interface signals. When the inter-
face signals have reached the status, channel 1 transmits the release to
channel 2. While program 2 is machining, program 1 is waiting for pro-
gram 2 in order to continue its machining task.

Syntax:
Wait for each of the specified signals:
WAITA[BITIF(<Parameter>){=<Status>}, BITIF(<Parame-
ter>){=<Status>},...,{<Timeout>}]

Wait for one of the specified signals:


WAITO[BITIF(<Parameter>){=<Status>}, BITIF(<Parame-
ter>){=<Status>},...{,<Timeout>}]
where:
BITIF BITIF function queries the PLC-NC interface.
Optionally, 2 to 16 interface signals can be queried
simultaneously.
<Parameter> Transfer parameter of the BITIF-function (for a des-
cription, please refer to BITIF-Function, page 5-51).
<Status> BOOLEAN expression with which the result of the BI-
TIF function is compared. If <Status> is not program-
med, the comparison will be made to TRUE.
If the condition is fulfilled, block preparation resumes.
<Timeout> Optional time in ms; default = 0.
If <Timeout> elapses before the pertaining condition
has been fulfilled, a warning is triggered and the sy-
stem continues to wait.
If Timeout has not been programmed or is equal to 0,
no warning will be triggered.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-75
and Controls

NC Programming Basics

Examples:
N10 WAITO[BITIF(10,1,1)=FALSE, Waits actively until BI-
BITIF(11,1,2)] TIF(10,1,1) takes on a
value of 0 or BITIF(11,1,2) a
value of 1.
N10 WAITA[BITIF(10,1,1)=FALSE, Waits actively until BI-
BITIF(11,1,2)] TIF(10,1,1) takes on a value
of 0 and BITIF(11,1,2) a va-
lue of 1.

Please note for WAITA, WAITO:


D If WAITA and WAITO are programmed in one NC-block, block execu-
tion is stopped until both conditions have been fulfilled. The WAITO-
condition is evaluated first.

Functions WAITA, WAITO, WVP, WVPE implicitly effect a downs-


lope at the end of the block. Synchronization points which have
been set incorrectly can lead to damage of the machine.
Test the program sequence for possible synchronization pro-
blems prior to the actual processing.
2-76 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

Wait for the value of a permanent CPL variable. WPV / WPVE


Using the function WPV / WPVE starts the waiting process at runtime
until a permanent CPL variable has reached a certain comparison value.

The comparison value can be determined at different times:


D WPV: The comparison value is a CPL term that is determined at run-
time and is compared with the value of the permanent variable.
Due to the evaluation at runtime, only a simple CPL expression is per-
mitted.

D WPVE: The comparison value is a CPL expression which, although it


was determined at preparation time, is not compared with the value of
the permanent variable until runtime.

Syntax:
The comparison value is determined at runtime:
WPV[<Perm.CPL-Variable><Comparison operator><Simple CPL-Ex-
pression>{,<Timeout>}]

The comparison value is already determined during the preparation


time:
WPVE[<Perm.CPL-Variable><Comparison operator><CPL-Expres-
sion>{,<Timeout>}]
where:
<Perm. CPL variable> Permanent variable, marked by the @
symbol followed by a variable name.
<Comparison opera- The following comparison operators may be
tor> selected:
= Permanent CPL-variable is equal to the
value of the CPL-term. Only makes
sense in case of integer- or Boolean va-
lues.
<> Permanent CPL-variable is not equal to
the value of the CPL-term. Only makes
sense in case of integer- or Boolean va-
lues.
< Permanent CPL-variable is less than
the value of the CPL-term.
3 Permanent CPL-variable is less than or
equal to the value of the CPL-term.

> Permanent CPL-variable is greater


than the value of the CPL-term.
. Permanent CPL-variable is greater
than or equal to the value of the CPL-
term.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-77
and Controls

NC Programming Basics

<Simple To avoid impairment of movement generation,


CPL-expression> only simple CPL-terms may be evaluated at
runtime.
A simple CPL-term is a mathematical term
consisting of permanent CPL-variables, con-
stants and the mathematical operations allo-
wed in CPL.
<CPL-expression> Any mathematical term in the CPL program-
ming language.
<Timeout> Optional time in ms; default = 0.
If <Timeout> elapses before the pertaining
condition has been fulfilled, a warning is trig-
gered and the system continues to wait.
If Timeout has not been programmed or is
equal to 0, no warning will be triggered.

Examples:
N10 WPV[@9=10] The program waits at the active point in
time until the permanent variable @9 re-
aches a value of 10.
N10 WPVE[@8=(5*#VAR2%)] The term 5 * #VAR2% is evaluated at
preparation time. The value thus determi-
ned is compared to permanent variable
@8 at runtime. As long as @8 does not
correspond to the value determined, no
new NC block will become active.
2-78 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

Writing a permanent CPL variable: SPV / SPVE


Using function SPV / SPVE, a value is assigned to a permanent CPL-va-
riable by writing at runtime.

The value can be determined at different times:


D SPV: the value to be assigned to the permanent variable is only defi-
ned at runtime.
Due to the evaluation at runtime, only a simple CPL expression is per-
mitted.

D SPVE: the value to be assigned to the permanent variable is determi-


ned at preparation time (CPL interpretation time) but only assigned to
the permanent CPL variable at runtime.

Syntax:
The value to be assigned is determined at runtime:
SPV[<Perm.CPL-Variable> = <Simple CPL-Expression>]

The value to be assigned is determined at preparation time:


SPVE[<Perm.CPL-Variable> = <CPL-Expression>]
where:
<Perm. CPL variable> Permanent variable, marked by the @
symbol followed by a variable name.
<Simple To avoid impairment of movement generation,
CPL-expression> only simple CPL-terms may be evaluated at
runtime.
A simple CPL-term is a mathematical term
consisting of permanent CPL-variables, con-
stants and the mathematical operations allo-
wed in CPL.
<CPL-expression> Any mathematical term in the CPL program-
ming language.

Examples:
N10 SPV[@6=1] A value of 1 is assigned to
permanent variable @6 at
runtime.
N10 SPV[@5=(7*(@PERMVAR1% +5))] The value of the term
(7*(@PERMVAR1% + 5)) is
determined at runtime and
then assigned @6.
N10 SPVE[@5=(7*#VAR1%)] The value of the term (7 *
#VAR1%) is determined at
preparation time and assigned
@5 at runtime.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-79
and Controls

NC Programming Basics

Movement stop until an axis positions has been attained. ASTOPA / ASTOPO
Using function ASTOPA / ASTOPO, it is possible to synchronize move-
ments between channels. Depending on the position of one or more
axes of the axis coordinate system ACS on a channel, the synchro-
nous movement on another channel is stopped and resumed.

Restrictions:
D The axes used for synchronization must belong to a channel other
than the channel to be controlled; otherwise a modal interlock may
occur.
D The channel to be controlled must be in automatic or manual input
mode.
D If AND and OR conditions have been specified for the channel simul-
taneously, there will be a channel stop when the respective condition
for at least one of the two functions has been fulfilled.

One or more conditions for stopping the channel can be entered for each
channel to be controlled:
D ASTOPA: As long as all conditions are fulfilled, the synchronous
movement of the channel to be controlled will be stopped (logical
AND -link).
D ASTOPO: As long as at least one condition is fulfilled, the synchro-
nous movement of the channel to be controlled will be stopped (logi-
cal OR -link).

. If new AND- and OR- conditions are entered, all previous condi-
tions in this channel become invalid.

Syntax:
AND-conditions:
ASTOPA[<Channel num-
ber>,<Cond.1>{,<Cond.2>}{..{,<Cond.8>}.}]
OR-conditions:
ASTOPO[<Channel num-
ber>,<Cond.1>{,<Cond.2>}{..{,<Cond.8>}.}]
where:
<Channel num- Number of the channel to be controlled (1-n).
ber> Integer-value or integer-variable.
<Cond.1, Entry of 1 to 8 conditions in the form:
Cond.2... <Axis><Comparison operator><Comparison va-
Cond.8> lue>
where:
<Axis> System or channel axis name, pro-
grammed as a CPL string constant
or as a CPL string variable.
2-80 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

<Compari- permitted operators:


son opera- < , , > ,
tor>
<Compari- Real value or real CPL expression.
son value> The value is determined at prepara-
tion time and remains modally effec-
tive.

. From one channel, a maximum of 4 other channels can be stopped


by AND-/OR- conditions.

Example:
Use of axis names and numbers
10 AXISNO% = 2 Definition:
20 AXISNAME$ = X - axis number,
30 STOPCHAN% = 2 - axis name
: - channel number
N40 ASTOPO[STOPCHAN%, AXISNO%<10]
:
N90 ASTOPO[STOPCHAN%, Z>20.3]
:
N150 ASTOPO[STOPCHAN%, AXISNAME$<1.5]
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-81
and Controls

NC Programming Basics

Movement stop until a basic workpiece position has been attained. BSTOPA / BSTOPO
Using function BSTOPA / BSTOPO, it is possible to synchronize move-
ments between channels. Depending on the position of one or more
coordinates of the basic -workpiece coordinate system BCS on a
channel, the synchronous movement on another channel is stopped and
resumed.

Restrictions:
D The coordinates used for synchronization must belong to a channel
other than the channel to be controlled; otherwise a modal interlock
may occur.
D The channel to be controlled must be in automatic or manual input
mode.
D If AND- and OR- conditions have been specified for the channel si-
multaneously, there will be a channel stop when the respective condi-
tion for at least one of the two functions has been fulfilled.

One or more conditions for stopping the channel can be entered for each
channel to be controlled:
D BSTOPA: As long as all conditions are fulfilled, the synchronous
movement of the channel to be controlled will be stopped (logical
AND -link).
D BSTOPO: As long as at least one condition is fulfilled, the synchro-
nous movement of the channel to be controlled will be stopped (logi-
cal OR -link).

. If new AND- and OR- conditions are entered, all previous condi-
tions in this channel become invalid.

Syntax:
AND-conditions:
BSTOPA[<Channel num-
ber>,<Cond.1>{,<Cond.2>}{..{,<Cond.8>}.}]
OR-conditions:
BSTOPO[<Channel num-
ber>,<Cond.1>{,<Cond.2>}{..{,<Cond.8>}.}]
where:
<Channel num- Number of the channel to be controlled (1-n).
ber> Integer-value or integer-variable.
<Cond.1, Entry of 1 to 8 conditions in the form:
Cond.2... <Coordinate><Comparison operator><Compari-
Cond.8> son value>
where:
2-82 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

<Coordinate> For BCS:


Coordinate name or coordinate
index, programmed as a CPL
string constant or as a CPL string
variable.
<Comparison permitted operators:
operator> < , , > ,
<Comparison Real value or real CPL expres-
value> sion. The value is determined at
preparation time and remains
modally effective.

. From one channel, a maximum of 4 other channels can be stopped


by AND-/OR- conditions.

Example:
Activate an AND condition for basic workpiece coordinates
N10 BSTOPA[3,z<12.0,x>15] Channel 3 is stopped for as
long as the following is applica-
ble to the controlling channel:
position of basic workpiece
coordinate z < 12 mm and
position of basic workpiece
coordinate x > 15 mm

Movement stop until a workpiece position has been attained: WSTOPA / WSTOPO
Using function WSTOPA / WSTOPO, it is possible to synchronize move-
ments between channels. Depending on the position of one or more
coordinates of the workpiece coordinate system WCS on a channel,
the synchronous movement on another channel is stopped and resu-
med.

Restrictions:
D The coordinates used for synchronization must belong to a channel
other than the channel to be controlled; otherwise a modal interlock
may occur.
D The channel to be controlled must be in automatic or manual input
mode.
D If AND- and OR -conditions have been specified for the channel si-
multaneously, there will be a channel stop when the respective condi-
tion for at least one of the two functions has been fulfilled.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 2-83
and Controls

NC Programming Basics

One or more conditions for stopping the channel can be entered for each
channel to be controlled:
D WSTOPA: As long as all conditions are fulfilled, the synchronous
movement of the channel to be controlled will be stopped (logical
AND -link).
D WSTOPO: As long as at least one condition is fulfilled, the synchro-
nous movement of the channel to be controlled will be stopped (logi-
cal OR -link).

. If new AND- and OR- conditions are entered, all previous condi-
tions in this channel become invalid.

Syntax:
AND-conditions:
WSTOPA[<Channel num-
ber>,<Cond.1>{,<Cond.2>}{..{,<Cond.8>}.}]
OR-conditions:
WSTOPO[<Channel num-
ber>,<Cond.1>{,<Cond.2>}{..{,<Cond.8>}.}]
where:
<Channel num- Number of the channel to be controlled (1-n).
ber> Integer-value or integer-variable.
<Cond.1, Entry of 1 to 8 conditions in the form:
Cond.2... <Coordinate><Comparison operator><Compari-
Cond.8> son value>
where:
<Coordinate> For WCS:
Coordinate name or coordinate
index, programmed as a CPL
string constant or as a CPL string
variable.
<Comparison permitted operators:
operator> < , , > ,
<Comparison Real value or real CPL expres-
value> sion. The value is determined at
preparation time and remains
modally effective.

. From one channel, a maximum of 4 other channels can be stopped


by AND-/OR- conditions.
2-84 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Programming Basics

Example:
Activate an AND condition for workpiece coordinates
N10 WSTOPA[3,Z<12.0,X>15] Channel 3 is stopped for as
long as the following is applica-
ble to the controlling channel:
Position of workpiece coordi-
nate Z of the channel is less
than 12 mm and position of
workpiece coordinate (WCS) X
is greater than 15 mm

Canceling the stop conditions: OFFSTOPA / OFFSTOPO


Clearing the stop conditions for a control channel.

Syntax:
OFFSTOPA Clears all AND stop conditions

OFFSTOPO Clears all OR stop conditions

Please note for the synchronization functions:


D ASTOPO, BSTOPO, WSTOPO, OFFSTOPO act modally and cancel
each other mutually.
D ASTOPA, BSTOPA, WSTOPA, OFFSTOPA act modally and cancel
each other mutually.

CAUTION
Undesired traversing motion!
Many NC -functions expect the programming of axis/coordinate
addresses. Generally, only the addresses of the corresponding
axes of the channel, i.e. synchronous axes, may be programmed
in addition to the coordinate addresses.
Programming the address of an asynchronous axis within a para-
meter list generally leads to a syntax error, while programming
outside of a parameter list leads to a synchronous traversing mo-
tion!
Exceptions:
G74(Home) VA1: asynchronous axis VA approaches reference
point.
GAX(VA): asynchronous axis VA is transferred to
the channel
FsMove, FsTorque, FsReset: Function Move to positive stop
also affects asynchronous axes.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-1
and Controls

3 NC Functions with Syntax According to DIN 66025


(incl. supplements)

3.1 Overview
The control has a variety of NC-functions. In addition to the commands
that are specified within DIN 66025, this includes important supplements
in the area of G-codes and additional high-level language-type syntax
elements.
The controls NC-functions include
D 1- and 2-digit G-codes:
these are geared mainly towards the DIN 66025, providing sensible
supplements to its G-code -vocabulary to
D supplement function groups that exist in the DIN
(e.g. G52, G53, G54, ...), or
D introduce new function groups that relate to existing function
groups.
1-digit G-codes can always be written with 2-digits with a leading zero
(e.g. G0=G00, G1=G01, ...).
D 3-digit G-codes (exceptions):
such G-codes are used if an existing function from the 2D-area is ap-
plied in the same manner in the 3D-area (e.g. G41, G42 -> G141,
G142).
D G-codes with .-extension:
these are used together with zero offsets or coordinate transforma-
tions.
These functions have up to 6 pages that can be addressed/program-
med using the .-extension.
Examples:
G54.4 1st zero offset of page 4
G59.4 6th zero offset of page 4
D M-functions with defined NC-functions
e.g. M0, M30
D NC-functions with high-level language syntax:
D (see Chapter 4)

. A tabular overview of all NC-functions can be found in the Appen-


dix, A-2ff.
In addition, all NC-functions are in the index starting on page A-49.
3-2 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Used notations
The following notations are used for the syntax of NC functions in this
manual:

FontCourier bold or Courier:


Character strings in this font must be programmed as shown below.
Example: G0(POL)

Angle brackets < >


indicate a wildcard for an expression/parameter to be programmed. The
wildcard is written in italics.
Example: <Axis1>

Curly brackets { }
indicate an optional expression/parameter.
Such syntax elements may, but do not have to be specified.
Example: G0{({POL,}{<Par1>})}

Character |
separates possible parameters that cannot be used simultaneously (al-
ternative parameters).
Example: G0{({POL,}{NIPS|IPS1|IPS2|IPS3})}
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-3
and Controls

G-Codes G00

3.2 G-Codes
3.2.1 Linear interpolation at rapid traverse G00

Effect
Approaches a programmed position with interpolation on a straight line
at the maximum path speed (= in rapid travel).

The following applies:


D At least one axis travels at maximum velocity or acceleration. The ve-
locity of the axes is controlled in such a manner that they reach the
target point at the same time.
D When the function is active, the Rapid traverse active channel IF (=
interface) signal is output.
D The following distance (displacement between the command and ac-
tual values) at the end of the block can be reduced to the size of cer-
tain target windows (= Precise stop function).
D The function acts modally and cancels G1, G2, G3, G5, G6, G33.

+Y

300
Target
G0 position
200

100
Starting position
W +X
100 200 300 400 500

Programming

Basic function Syntax:


G0 Rapid traverse with precise stop (fine positioning window)
and programming of the end position in Cartesian coordi-
nates.
Example:
:
N40 X100 Y100 Starting position.
N50 G0 X500 Y300 Approach target position in rapid tra-
verse.
3-4 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G00

Optional parameters Syntax:

G0({NIPS|IPS|IPS1|IPS2|IPS3,}{POL})
where:
NIPS Precise stop OFF. No braking to v=0 at the end of a block.
IPS Precise stop ON. The Precise stop window that was last
set for the input is taken into account (default = fine positio-
ning window).
At the end of the block, the control first brakes the path
velocity to v=0. Only when this positioning window has been
reached for all axes involved will the traversing movement of
the next block be executed.
The Precise stop window for feed mode is not affected by the
Rapid traverse positioning window.
IPS1 As for IPS, but always with a fine positioning window.
IPS2 As for IPS, but always with a coarse positioning window.
IPS3 As for IPS; however, no positioning window is checked in-
stead, merely braking to a velocity v=0 occurs at the end of
the block.
For more information regarding the precise stop, see
function G61/G62.
POL Activates polar coordinate programming and sets polar
angle 1 to 0, polar angle 2 to 90 degrees.
See section 4.55.2, page 4-97 ff. on how to program polar
coordinates.

Special features and restrictions:


D The function can be programmed with or without axis addresses in
the same block.
D The corresponding velocity is determined using the machine parame-
ters for the maximum axis velocity.
D The rapid traverse velocity can be limited to the reduced value set in
the machine parameters using channel -IF -signal Reduced rapid
traverse (qCh_RedRap).
D The Rapid traverse velocity can also be limited using function Test of
rapid traverse, which is controlled using channel IF signal Test of ra-
pid traverse (qCh_TestRap).
D The velocity can be influenced using the potentiometer.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-5
and Controls

G-Codes G01

3.2.2 Linear interpolation at feedrate G01

Effect
Approaches a programmed position with interpolation on a straight line
with the effective feedrate (programmable using F-address).
The movement is coordinated in such a manner that all axes involved
arrive at the programmed end point simultaneously.
Please note the following:
D The programmed feedrate value (F) acts as path feed; this means in
the case of more than one moving axis that the portion of each indi-
vidual axis is less than F.
D The function acts modally and cancels G0, G2, G3, G5, G6, G33.

+Y

300
Target
G1 position
200

100
Starting position
W +X
100 200 300 400 500

Programming

Basic function Syntax:


G1 Movement according to active feedrate and programming
of the end position in Cartesian coordinates.
Example:
:
N40 X100 Y100 Starting position.
N50 G0 X500 Y300 F100 Approach target position with feedrate
F100.

Optional parameters Syntax:

G1({IPS|IPS1|IPS2|IPS3,}{POL})
where:
IPS Precise stop ON, regardless of G61/G62. The Precise stop
window that was last set for the feed mode is taken into
account (default = fine positioning window).
At the end of the block, the control first brakes the path
velocity to v=0. Only when this positioning window has been
reached for all axes involved will the traversing movement of
the next block be executed.
IPS1 As for IPS, but always with a fine positioning window.
3-6 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G01

IPS2 As for IPS, but always with a coarse positioning window.


IPS3 As for IPS; however, no positioning window is checked in-
stead, merely braking to a velocity v=0 occurs at the end of
the block.
For more information regarding the precise stop, see
function G61/G62.
POL Activates polar coordinate programming and sets polar
angle 1 to 0, polar angle 2 to 90 degrees.
See section 4.55.2, page 4-97 ff. on how to program polar
coordinates.

Special features and restrictions:


D The function can be programmed with or without axis addresses in
the same block.
D If no feedrate is yet active, a feedrate must be programmed in the
same line using the F-address.
This feedrate remains effective until it is overwritten by a new one.
D The programmed path velocity can be limited using machine parame-
ters.
D The path velocity can be influenced using the feedrate potentiometer.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-7
and Controls

G-Codes G02, G03

3.2.3 Circular/helical/helical-N interpolation G02, G03

Effect
Approaches the programmed target position in the active working plane
with interpolation on a circular path with the current feedrate (program-
mable using F-address).
D G2: Clockwise circular path
D G3: Counterclockwise circular path

Furthermore, additional axes outside of the working plane can be inclu-


ded in the programming; their movements are linearly interpolated.

+Y +Y
Target Target
position position

G2
G3

+X +X
W W

Circular interpolation:
Solely the axes of the active working plane participate.

Helical interpolation:
An additional synchronous axis to the axes of the active working plane
participates.
If this axis is positioned perpendicular to the active working plane (e.g.
the remaining axis of the workpiece coordinate system), a helical path
with a constant slope is generated (helical interpolation).

Helical interpolation
(Special case: helical
interpolation)
C

Y
O: Starting point
E: End point
A

X
W
3-8 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G02, G03

Helical-N interpolation:
More than one additional synchronous axis (max. 6) to the axes of the
active working plane is programmed.

Helical-N interpolation

Y O: Starting point
W A E: End point
X
U

The following applies:


D The axes traveling along a circular arc are clearly defined by the se-
lected working plane (G17, G18, G19, G20).
D The programmed feedrate value (F) acts as the path feed, generally
referring to all the axes traversing in a block; this means in the case
of more than one moving axis that the portion of each individual axis
is less than F.
D The real feedrate can be limited by the maximum possible radial ac-
celeration.
D Functions G0, G1, G2, G3, G5, G6 form a modal group and therefore
cancel each other mutually.
D The circular path can be programmed using:
D radius programming or
D center point programming.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-9
and Controls

G-Codes G02, G03

Radius programming
Using the current position as the starting point, you specify a circular mo-
vement by programming the circles
D end point and
D radius.
The circles end point can be given as an absolute or incremental posi-
tion value.

Basic function Syntax:


G2 <EP> R<Value> Clockwise circular path
G3 <EP> R<Value> Counterclockwise circular path
where:
<EP> Coordinates of the end point.
<Value> Radius of the circular path.
The radius must be at least half the distance between the
starting and the end point.
The positive/negative sign is used to specify whether the
path is to traverse with the smaller or the larger arc if two cir-
cular paths are possible:
positive radius value: arc 180 degrees
negative radius value: arc> 180 degrees.
If the radius is exactly half the distance between the starting
and the end point, a semicircle results and any positive/ne-
gative sign can be used.

G2: G3: End point


Starting +R
-R
point

+R End -R
point
Starting point

Special case for semicircle: Special case for semicircle:


any positive/negative sign for R any positive/negative sign for
R
Starting point End point
-R +R
-R +R
Starting point End point

Special features and restrictions:


D Full circles cannot be generated.
D The control automatically corrects imprecise radius entries according
to the tolerances set in the machine parameters.
Otherwise, a runtime error results.
3-10 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G02, G03

Center point programming


Using the current position as the starting point, you specify a circular mo-
vement by programming the circles
D end point and
D center point.
The circles center point is incrementally programmed, based on the cor-
responding starting point of the circle.

Basic function Syntax:


G2 <EP> <IP> Clockwise circular path
G3 <EP> <IP> Counterclockwise circular path
where:
<EP> Coordinates of the end point.
If the starting and end points within the circle plane are iden-
tical, a full circle is generated automatically.
<IP> Interpolation parameters I, J and K.
These define the distance between circle -starting point A
and circle -center point M for each axis. Their sign results
from the vector direction from A to M.
Which interpolation parameter is assigned to which axis de-
pends on the meaning of the coordinates in the machine pa-
rameters.
By default: I = M(X) - A(X) for X-coordinate
J = M(Y) - A(Y) for Y-coordinate
K = M(Z) - A(Z) for Z-coordinate

G2: O: Starting point G3: O: Starting point


E: End point +Y E: End point
+Y M: Center point M: Center point
!I
E M
E
+!J
A
!J M
+!I A

W W +X
+X

Special features and restrictions:


D If the starting and end points are identical, the control automatically
generates a full circle.
D The control automatically corrects imprecise center point entries ac-
cording to the tolerances set in the machine parameters.
To do this, it offsets the position of the center point accordingly.
D If interpolation parameters as well as a circle radius are programmed
in the same block, only the circle radius is taken into account (= radius
programming).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-11
and Controls

G-Codes G02, G03

D If interpolation parameters that are not suitable for the selected plane
are programmed, the control reports a runtime error.
Example: G17 G2 X5 I9 K7 (Error: K is not suitable for the X/Y-
plane)

Optional parameters Syntax:


G2G3(POL) <EP> R<Value> Radius programming in polar coor-
dinates
G2G3(POL) <EP> <IP> Center point programming in polar
coordinates
where:
POL Activates polar coordinate programming for the end point
coordinates and sets polar angle 1 to 0, polar angle 2 to 90
degrees.
See section 4.55.2, page 4-97 ff. on how to program polar
coordinates.

Example: Radius programming (Cartesian)


:
N40 G1 X10 Y10 F100 Traverse to starting point.
N50 G2 X38 Y20 R15 Circular interpolation.

+Y G2

20
End point
10
Starting point
W +X
10 20 30 40

Example: Center point programming (Cartesian)


:
N80 G1 X100 Y100 F100 Traverse to initial position.
N90 G90 G17 G3 X350 Y250 Counterclockwise circular interpola-
I200 J-50 tion in the X/Y-plane. Absolute dimen-
: sion programming for the end point
coordinates is active.
3-12 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G02, G03

+Y
250 E

A
100
!J M
50

100 300 350 +X


W
+!I
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-13
and Controls

G-Codes G04

3.2.4 Dwell time G04

Effect
Stops program execution. The subsequent programmed block is pro-
cessed only after the programmed dwell time has elapsed.

The dwell time starts when the previous NC block has been completely
processed.
Rotating spindles or traversing auxiliary axes is not stopped. Synchro-
nous axes can reduce their lag, if necessary.
The dwell time can be programmed in
D seconds or
D in spindle revolutions.

To determine the spindle revolutions, the current actual revolutions are


established cyclically from the main spindle, calculating the revolutions
performed on that basis. In case of highly dynamic spindles, a certain
deviation between the programmed and the actual spindle revolutions
waited may therefore occur in the acceleration- or deceleration phases.
If the configured main spindle is an analogous spindle (without speed
feedback), the rpm setpoint is used for the calculation instead of the ac-
tual rpm.

Programming
Syntax:
G4(F<Value>) Dwell time in seconds.
G4(S<Value>) Dwell time in spindle revolutions.
where:
<Value> Entry in seconds or spindle rotations.
If 0 is entered, the G4 block is discarded internally.

Special features and restrictions:


D The function must be programmed in a separate block without path
information. Only auxiliary- and special functions are permissible in
this block.
D The programmed spindle revolutions refer to the main spindle confi-
gured in the machine parameters or using the MainSp function (refer
to page 4-72).
3-14 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G05

3.2.5 Circle with tangential entry G05


Effect
Using the last-programmed traversing movement, the control automati-
cally calculates a tangential circle entry for the G5 block.
Only a transition involving no reversal of direction is referred to as tan-
gential.
. The first entry tangent determines all following G5 contour ele-
ments if several G5 movements take place consecutively.
Functions G0, G1, G2, G3, G5, G6 form a modal group and therefore
cancel each other mutually.

CAUTION
Machining marks are possible at the block transition in the case
of helical/helical-N interpolation!
The calculated tangential transition refers only to the circle plane.
The spatial tangent may jump at the block transition!

Programming
Syntax:
G5 <EP>
where:
<EP> Coordinates of the circles end point.
If the starting and end points within the circle plane are iden-
tical, a full circle is generated automatically.

Special features and restrictions:


D Programming G5 is not possible in the Manual data input operating
mode.
D A block containing a traversing movement must be programmed
ahead of G5 in the same program.
D The current plane must not be switched over directly ahead of or du-
ring an active G5.
Example
+Y +Y M +Y
120 M2 E

A T A
70 100 E 70 T
70 40
A T M1
10 M E
+X +X +X
W W W 50
50 110 50 130 15 90
G1 X20 Y70 F200 G1 X20 Y70 F200 G1 X-15 Y40 F200
X50 X50 G2 X50 Y70 R-60
G5 X110 Y10 G5 X130 Y100 G5 X90 Y120

T: Tangent. O: Starting point of the circular segment. I: End point of the circular segment. M: Center point
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-15
and Controls

G-Codes G06

3.2.6 Spline programming G06


Compared to linear interpolation, spline interpolation despite a lower
number of support points provides nearly the same surface quality and
contour precision because continuous curves are calculated between
the points.

The IndraMotion MTX supports the following spline types:


D Spline type 0: Spline with coefficient programming
(polynomial coefficients of CAD/CAM system)
D Spline-type 1: C1-continuous cubic splines with support point pro-
gramming
(tangential transitions at the support points)
D Spline-type 2: C2-continuous cubic splines with support point pro-
gramming
(continuous-curvature transitions at the support points)
D Spline type 3: B-spline with coefficient programming
(curve shape near the support points)

The desired spline-type is selected and initialized using function Spline-


Def (SDF; see page 4-136). Then spline programming can be activated
with function G6.

. For detailed information about the individual spline types, see the
Description of Functions.

Special features and restrictions:


The following functions can not be programmed with splines:
D Tensor orientation
D 2D path compensation G41/G42.
D Punching/nibbling with path separation
D Chamfers and roundings
D Tangential tool guidance
D precision programming
D G5 after a spline
D Cancel distance to go

Programming
Syntax:
G6 Activate the Spline type of path.
Depending on the required programming type, G6 can be programmed
for the various spline types with different, modally effective parameters:
3-16 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G06

3.2.7 Spline with coefficient programming (spline type 0)

Coordinate/axis programming:
Each channel coordinate may be moved if desired
D as a spline by specifying the polynomial coefficients
<Coordname>(<c0>,<c1>,....,<cn>) Programming indivi-
dual coordinates with
polynomial coeffi-
cients.
D or linearly by specifying the end positions:
<Coordname>(<Endpos>) Programming the end
position of individual
coordinates/axes.
where:
<Coordname>: Name of coordinate or axis
<c0>,<c1>,...,<cn>: Polynomial coefficients of a coordinate.
n corresponds to the spline degree de-
fined in SplineDef.
<Endpos>: End position of the coordinate.

Example:
SplineDef(3)
G6 X(0.1,1.25,0.5,0.73) Y30 B(0.0,-1.0,0.1,-0.2)

Denominator polynomial programming:


DN(<g0 >,<g1 >,...,<gn >) Common denominator-polynomial for all
spline-coordinates.
Exact description of rational Bezier-spli-
nes, rational B-splines (NURBS) and all
conics.
where:
<g0 >, <g1 >, ..., <gn >: Polynomial coefficients of the denomina-
tor polynomial.
n corresponds to the spline degree de-
fined in SplineDef.
Example:
SplineDef(3)
G6 X(0.1,1.25,0.5,0.73) B(0.0,-1.0,0.1,-0.2) DN(1,0,1)
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-17
and Controls

G-Codes G06

Orientation vector programming:


Active vector orientation-capable axis transformation (Coord(..)) is re-
quired for this programming method.
O1(<o10 >,<o11 >,...,<o1n >) x-component of the orientation vector
O2(<o20 >,<o21 >,...,<o2n >) y-component of the orientation vector
O3(<o30 >,<o31 >,...,<o3n >) z-component of the orientation vector
where:
<o10 >,<o11 >,...,<o1n >: Spline coefficients of the x-component of
the orientation vector.
<o20 >,<o21 >,...,<o2n >: Spline coefficients of the y-component of
the orientation vector.
<o30 >,<o31 >,...,<o3n >: Spline coefficients of the z-component of
the orientation vector.
n corresponds to the spline degree de-
fined in SplineDef.

Example:
N00 ;Spline coefficients for vector orientation
001 PI=3.14159:PIH=PI/2:PIHQ=PIH*PIH:PIHC=PIHQ*PIH
N10 G1 F30000 X0 Y0 Z0 B90 C0
N20 SplineDef(3)
N30 Coord(1) ;5-axis transformation with vector orienta-
tion ON
N40 G6 PL[PIH] ;PL: see spline parameter length programming
N50 O1(1,0,-3/PIHQ,2/PIHC) O3(0,1,(3-PI)/PIHQ,(-2+PIH)/PIHC)
N60 O1(0,0,3/PIHQ,-2/PIHC) O3(1,0,(-3+PIH)/PIHQ,(2-PIH)/PIHC)
N70 O(0,1,0) ;Normal vector orientation
N80 G1
N90 Coord(0)

Spline parameter length programming:


The spline-parameter length is the length of the interval defined for w,
where w is active between 0 and we.
The value we acts modally and remains valid for all NC blocks until G6 is
deselected.
PL must be programmed in the first traversing block after G6; otherwise,
a runtime error will occur.
{PL<we >} Optional programming of the spline pa-
rameter length.
where:
<we >: any value > 0

Example:
G6 X(0.1,1.25,0.5,0.73) B(0.0,-1.0,0.1,-0.2) PL0.6
3-18 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G06

(X = 0.1 + 1.25 w + 0.5 w2 + 0.75 w3 and


B = 0.0 - 1.0 w + o.1 w2 - 0.2 w3 with
w is active between 0 and 0.6)

3.2.8 C1- and C2 continuous cubic spline (spline type 1 and 2)

Coordinate/axis programming:
The end points of the channel coordinates are programmed.
All <members> listed in SplineDef move along the spline curve; the re-
maining coordinates not defined in SplineDef move on a straight line.
<Coordname>(<Endpos>) and/or Programming of indivi-
<Axisname>(<Endpos>) and/or dual coordinates/axes/
<Orientation coordinates>(<Endorient>) orientation coordinates
and their values.
where:
<Coordname>: Name of coordinate.
<Axisname>: Name of axis.
<Endpos>: End position of the coordinate/axis.
<Orientation coordinates > Orientation coordinates O or phi and
theta.
<Endorient>: End orientation in polar angles or Carte-
sian coordinates.

Example:
Coordinates x, y, z and orientation coordinates phi, theta.
SplineDef(2203,x,y,z,phi,theta)
G6 x10 y20 phi20 theta30

Example:
Axes X,Y,U
SplineDef(1213,X,Y)
G6 X10 Y10 U20 (X and Y move as spline, U linearly)

Starting- and end conditions:


Syntax:
SBC(<Type>{,<Values>}) Boundary conditions for the starting
point of a spline-sequence
C1 with 3 starting conditions
C2 with 5 starting conditions
EBC(<Type>{,<Values>}) Boundary conditions for the end point of
a spline-sequence
C1 with 3 starting conditions
C2 with 5 starting conditions
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-19
and Controls

G-Codes G06

where:
<Type> Default: 2
1: (valid for C1 and C2)
Specification of tangential direction at the starting/
end point of the spline sequence. A value must be
entered in the <Values> list for each spline member.
2: (valid for C1 and C2)
Specification of the second derivation at the starting/
end point of the spline sequence. A value must be
entered in the <Values> list for each spline member.
3: (valid for C2)
De Boors boundary condition: links the second de-
rivatives at the first/last two interpolation points.
<Values> is usually 1 here.
4: (valid for C2)
Periodic boundary condition: the last and the first
point of the spline-sequence match. SBC(4) abso-
lutely requires EBC(4) or
EBC(4) absolutely requires SBC(4).
The entire spline-sequence must be in the look-
ahead range; otherwise, a runtime error will be gen-
erated.
11: (valid for C1 and C2)
For starting condition: First spline starts tangentially
relative to the previous-linear block.
For end condition: The last spline leads tangentially
to the subsequent-linear block.
<Values> Default: 0,...,0
All information entered in <Values> taken together indi-
cates the direction and size of the starting- /end tangent
or the second derivative at the starting- /end point.
A positive or negative value may be entered for each
spline-member.
Type 11 does not need any <Values>.

Example:
SBC(1,1.0,1.0,0.2) if SplineDef(1213,X,Y,B)

Spline-parameter length:
The spline-parameter length is calculated by the NC from the specified
interpolation points. The process (parameter setting) defined in the spli-
ne-ID is used for this purpose. The spline-parameter length may also be
programmed, if necessary.
{PL<we >} Optional programming of the spline-parameter length if
the <parameterization> selection is to be overwritten
(see page 4-136 SplineDef, parameter <Id>).
where:
<we >: any value > 0
3-20 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G06

3.2.9 B-Splines (NURBS) (Spline-Typ 3)

Coordinate-/axis programming:
The end points of the channel coordinates (checkpoints) are program-
med. All <members> listed in SplineDef move along the spline-curve;
the remaining coordinates not defined in SplineDef move on a straight
line.
<Coordname>(<Endpos>) and/or Programming of indivi-
<Axisname>(<Endpos>) and/or dual checkpoints (coor-
<Orientation coordinates>(<Endorient>) dinates/axes) and their
values.
where:
<Coordname>: Name of coordinate.
<Axisname>: Name of axis.
<Endpos>: End position of the coordinate/axis.
<Orientation coordinates > Orientation coordinates O or phi and
theta.
<Endorient>: End orientation in polar angles or Carte-
sian coordinates.

Example:: Coordinates x, y, z and orientation coordinates


SplineDef(3103,X,Y)
G6 x10 y20 z30 O(0.1,0,1.0)
Example: Axes X,Y,U
SplineDef(3102,X,Y)
G6 X10 Y10 U20 (X and Y move as spline, U linearly)

Spline-parameter length:
The spline-parameter length is automatically calculated by the NC-from
the specified -checkpoints. The process (parameter setting = 1) defined
in the spline-ID is used for this purpose. The spline-parameter length
may also be programmed, if necessary.
{PL<we >} Optional programming of the spline-parameter length if
the <parameterization> selection is to be overwritten
(see page 4-136 SplineDef, parameter <Id>).
where:
<we >: any value > 0

Spline point weighting for checkpoint of B-splines:


{PW<we >} Optional programming of point weights. This can be
used to modify the spline in the vicinity of a checkpoint.
where:
<we >: Default: 1
0 < we < 1: Presses the spline away from the checkpoint
we > 1: Pulls the spline towards the checkpoint
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-21
and Controls

G-Codes G08 G09

Example: Coordinates x, y, z and orientation coordinates


SplineDef(3103,X,Y)
G6 x10 y20 z30 O(0.1,0,1.0) PW2.3

3.2.10 Path slope ON G08


Path slope OFF G09

Effect
D Without path slope, the control performs a complete up and down
slope (speed ramp) to v=0 at the start and end of a traversing block.
Although this reduces the contour deviation at the block transition, it
requires a longer processing time.
D Using path slope, the control attempts to generate a speed as con-
stant as possible within the magnitude of the programmed feedrate,
even at the block transition. This reduces the processing time.
The fact that the contour may be rounded at the contours in this case
may also be an advantage for certain processing procedures (more
uniform surface).

P7
Y
G1 Conto
P3 P4
ur
G0 P1 P2 P5 P6 P8

P0
VPath X
Rapid
travers Without
Feede path slope
(G9)

VPath t
Rapid
travers where:
Feede path slope
(G8)
t

During the determination of the optimum velocity profile, the control


takes into account not only the value for the jumping ability of the axes
(MP 1010 00011), but also the number of subsequent program blocks
(block look-ahead; MP 7060 00110 - 7060 00130) because braking
within the leeway for the dynamics of the machine must be ensured at
all times.
To limit contour deviations occurring at real corners, the maximum
step change must not be set at too high a value. On the other hand, if
the maximum step change is set too low, this will result in undesirable
deceleration at minor knees in the contour (quasicontinuous transi-
tions).
3-22 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G08 G09

Smoothing of the path acceleration can be entered for G8 as the de-


fault-setting in machine parameter 7050 00320 (SHAPE-function;
also see page 3-23).

Programming

Basic function Syntax:


G8 Path slope ON.
G9 Path slope OFF.

Optional parameters Syntax:


G8({DTT<Angle>})
where:
<Angle> Transition angle between two contour sections.
The control traverses contour knees that have transition an-
gles less than those programmed here with a constant path
velocity as long as this is permitted by the braking path provi-
ded within the framework of block look-ahead. The in-
fluence of the axis jump capability is thus limited to the
transition angle.
Range of values: 0 to 50 degrees.

Special features and restrictions:


D If Precise stop is active, the control will, despite the active G8, brake to
v=0 after each block.
D Auxiliary functions can ameliorate the effect of G8 if their execution
time (including acknowledgement) is not significantly less than the in-
terpolation time of a block. If necessary, the working path of a block
must be lengthened or the feedrate must be reduced.
D Path slope acts only on synchronous axes (machining axes).
D Functions G8 and G9 form a modal group together with the ramp
functions and therefore cancel each other mutually.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-23
and Controls

G-Codes G8(SHAPE...) G9(SHAPE...) G9(ASHAPE...) G9(X..., Y..., ...)

3.2.11 Jolt-limited velocity control G8(SHAPE...)


G9(SHAPE...)
G9(ASHAPE...)
G9(X..., Y..., ...)

Effect
Jolt-limited velocity control smoothes jumps during path acceleration
over several interpolation cycles. The number of interpolation cycles can
be programmed.
This results in gentle velocity transitions (jolt limitation).
Jolt-limited velocity control is possible in both
D contour mode (with G8 active) and
D positioning mode (with G9 active).

Jolt-limited velocity control is also known as the SHAPE function.

a(t)
without SHAPE
a1

t
a(t)
with SHAPE
a1

t
nipo: nipo:

a1: Jump height


nipo: Number of interpolation cycles over which acceleration-
jump a1 is to be distributed

Acceleration distribution with/without SHAPE


3-24 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G8(SHAPE...) G9(SHAPE...) G9(ASHAPE...) G9(X..., Y..., ...)

Shape for contour mode


Syntax:
G8{(SHAPE<Value>{,DTT})}
where:
<value> 0 or 1:
Switch off shape for contour mode.
2 to 100 (whole numbers):
Number of interpolation cycles over which the control
should divide the jump linearly (SHAPE order).
Without SHAPE parameter:
Drive with the default value for SHAPE stored in machine
parameter 7050 00320
.
{DTT} See page 3-21.

. Changing the SHAPE order always leads to a block transition velo-


city of v = 0.

Example:
N30 G8(SHAPE10) Switch on SHAPE in contour mode and divide
: the acceleration jumps over 10 IPO cycles.
:
N50 G8(SHAPE0) Switch off shape for contour mode.
:
:
N70 G8(SHAPE1) Switch off shape for contour mode.
:
:
N90 G8 Drive with the default value for SHAPE stored in
machine parameter 7050 00320.

Shape for positioning mode


Syntax:
G9(SHAPE<Value>) Switch on linear SHAPE for positioning
mode.
where:
<Value> Number of interpolation cycles over which the control should
divide the acceleration jump linearly.
Range of values: 2 ... 100 cycles (whole number).

G9(SIN<Value>) Switch on sin2-shaped SHAPE for positio-


ning mode.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-25
and Controls

G-Codes G8(SHAPE...) G9(SHAPE...) G9(ASHAPE...) G9(X..., Y..., ...)

where:
<Value> Number of interpolation cycles over which the control should
divide the acceleration jump with a sin2 shape.
The following values are permitted:
5: 5 IPO cycles
10: 10IPO cycles
15: 15IPO cycles
20: 20IPO cycles
40: 40IPO cycles

G9(ASHAPE) This assigns the corresponding axis-speci-


fic SHAPE order (number of IPO cycles)
from MP 1003 00008 to every axis of the
channel and makes a blockwise calculation
of the resulting block-specific SHAPE or-
der for the path.

G9(<Par1 > {,<Par2 >,...}) Program SHAPE order axis-by-axis. In the


case of unprogrammed axes, the SHAPE
order from MP 1003 00008 is used.
where:
<Parx > Logical axis name with the SHAPE order that is to be assi-
gned to this axis (maximum of 100).
Example:
N30 G9(X4,Y6,Z10) SHAPE order (X-axis) = 4
SHAPE order (Y-axis) = 6
SHAPE order (Z-axis) = 10

Resulting shape order


The resulting path-shape-order Sb is the maximum of the effective axis-
eff
shape-orders S i of all the axes involved in the interpolation.
eff eff
S b= max { S 1 ,..., S n }
eff
The effective axis-shape-orders S i are computed from the program-
med shape-orders using the formula:

eff p
a eff
i
Si = Si
a max
i

In this case,
p axis-shape-order programmed with G9(...).
Si
3-26 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G8(SHAPE...) G9(SHAPE...) G9(ASHAPE...) G9(X..., Y..., ...)

eff
ai effective axis acceleration in the current NC-block.
With linear interpolation, the value depends on the current path
segment of the axis. With other types of interpolation (e.g. circular,
helical), it is the axis acceleration usually programmed with Ax-
Acc.
If the functions Inclined plane or Axis coupling are used, the ef-
fective axis acceleration is generally decreased once again as
compared to the AxAcc-value!
max
ai Maximum axis acceleration (from MP 1010 00001).

. AxAcc does not change the maximum axis acceleration from


MP 1010 00001!

Relationship between shape order and jolting


eff max
With axis-shape-orders S i , a maximum jolt r i (derivative from ac-
celeration after time) is defined as a limit not to be exceeded in any mo-
vement.
This jolt is defined by:
max
max
ai
r i = p Tipo: Clock time of the interpolator
S i Tipo

Example:
Axis X has a maximum acceleration (MP 1010 00001) of 10 m/s2. The
programmed axis-shape-order is 5 and the interpolation cycle is 4 ms.
According to the formula above, a maximum jolt of 500m/s3 is thus defi-
ned for axis X.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-27
and Controls

G-Codes G16

3.2.12 No plane G16

Effect
Deactivates a plane that may be active.
The following applies:
D If a main or secondary axis is removed from a channel (e.g. in connec-
tion with function Axis transfer), the control automatically switches
off the selected plane and activates function G16.
Circular or helical interpolation cannot be performed in this channel
before a valid plane is selected.
D Some applications, types of machines, or processing functions do not
require the configuration of a plane if neither circular nor helical inter-
polation is necessary (e.g., for channels with only one machining
axis).
Classification 999 no processing function can then be entered in
MP 7010 00030 for each axis.
D If no plane function (G17, G18, G19, G20) has been entered for a
channel after power-up (MP 7060 00010 and 7060 00020), function
G16 is automatically activated for the respective channel.
D Functions G16, G17, G18, G19 and G20 form a modal group and the-
refore cancel each other mutually.

Programming
Syntax:
G16

Special features and restrictions:


D If cutter path compensation (G41/G42) is active, the active plane may
not be switched or deactivated.
3-28 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G17, G18, G19

3.2.13 Plane switching G17, G18, G19

Effect
For a typical Cartesian standard machine tool, axes X, Y and Z are
used to open a Cartesian workpiece coordinate system (WCS). Using 2
coordinate axes each of the workpiece coordinate system, a total of 3
different basic levels can be defined.

The plane switching function is used to select the active plane. It is defi-
ned using one primary and one secondary coordinate, as well as if ne-
cessary a feed axis that is positioned perpendicular to this plane.
G17, G18 or G19 is programmed without parameters for this.

G17, G18 and G19 specify these coordinates and the active plane as fol-
lows:

G17 G18 G19


+Y +Y +Y

G41
G2
G41
W/P
W/P +X G2 +X W/P
+X
G2
G41
+Z +Z +Z

X/Y plane Z/X plane Y/Z plane

Primary coordi- Secondary Feed coordi- Active plane


nate coordinate nate
G17 X Y C XY
G18 C X Y ZX
G19 Y C X YZ

Programming
Syntax:
G17

G18

G19
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-29
and Controls

G-Codes G17, G18, G19

Special features and restrictions:


D If cutter path compensation (G41/G42) is active, the active plane may
not be switched or deactivated.
D The following applies to interpolation parameters I, J, K for G02/G03
and G33:
I refers to the X-axis.
J refers to the Y-axis.
K refers to the Z-axis.
D Tool length compensation is assigned to the active plane with
G47(ActPlane) as follows:
L1: primary coordinate
L2: secondary coordinate
L3: feed coordinate.
This assignment is updated when the active plane is switched.
D Functions G16, G17, G18, G19 and G20 form a modal group and the-
refore cancel each other mutually.

Assignment independently of axis name


Axis names can be set in any manner in the IndraMotion MTX. The axes
that the workpiece coordinate system WCS are to open are thus selec-
ted using machine parameter 7010 00030 (coordinate meaning). This
specifies, independently of the configured axis name, which axes open
the X-, Y- and Z-coordinate of the workpiece coordinate system:
Axis with axis meaning X: X-coordinate of the WCS
Axis with axis meaning Y: Y-coordinate of the WCS
Axis with axis meaning Z: Z-coordinate of the WCS

In general, the following assignment results for G17, G18 and G19:
Primary coordi- Secondary Feed coordinate Active plane
nate coordinate
G17 X-coord. WCS Y-coord. WCS Z-coord. WCS XY-coord. WCS
G18 Z-coord. WCS X-coord. WCS Y-coord. WCS ZX-coord. WCS
G19 Y-coord. WCS Z-coord. WCS X-coord. WCS YZ-coord. WCS
3-30 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G17(...), G18(...), G19(...)

3.2.14 Enhanced plane switching G17(...), G18(...), G19(...)

Effect
Enhanced plane switching specifies, in addition to the selection of the
active plane, which axes are to currently cover the workpiece coordinate
system WCS.
As a result, it is possible at runtime to define a workpiece coordinate sy-
stem that deviates from the setting within the machine parameter and,
based on this, to select the current plane.

The plane is selected according to the following overview:


Primary coordi- Secondary Feed coordinate Active plane
nate coordinate
G17 X-coord. WCS Y-coord. WCS Z-coord. WCS XY-coord. WCS
G18 Z-coord. WCS X-coord. WCS Y-coord. WCS ZX-coord. WCS
G19 Y-coord. WCS Z-coord. WCS X-coord. WCS YZ-coord. WCS

Programming
Syntax:
G17(<Axis1>,<Axis2>,<Axis3>)

G18(<Axis1>,<Axis2>,<Axis3>)

G19(<Axis1>,<Axis2>,<Axis3>)
where:
<Axis1> X-coordinate of the workpiece coordinate system WCS
<Axis2> Y-coordinate of the workpiece coordinate system WCS
<Axis3> Z-coordinate of the workpiece coordinate system WCS

Special features and restrictions:


D The axes can be programmed with a logical (channel-based) or phy-
sical (system-wide) axis designation and must differ from one an-
other. Entry can be made directly or as a CPL string variable.
D The programmed axes must be currently assigned to the channel.
D In programming, only entering the axes that are to be reconfigured as
parameters is sufficient. The corresponding coordinates of the WCS
remain unchanged for all other axes.
Example:
G17(,,W)
The Z-coordinate of the WCS is defined by the W-axis. The X- and
Y-coordinates of the WCS remain unchanged.
The active plane is covered by the X- and Y-coordinates of the WCS.
D Programming an empty bracket expression restores the WCS that is
configured in MP 7010 00030 and then activates the selected plane.
Example:
G17()
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-31
and Controls

G-Codes G17(...), G18(...), G19(...)

D The function may not be programmed while cutter path compensation


(G41/G42) is active.
If cutter path compensation is active, the plane may not be switched
or deactivated as a rule.
D If axis transformation is active, enhanced plane switching may not be
programmed because the WCS is covered by the space coordinates.
D Functions G16, G17, G18, G19 and G20 form a modal group and the-
refore cancel each other mutually.
3-32 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G20

3.2.15 Free plane selection (WCS-independent) G20

Effect
Free plane selection is required for applications for which the active
plane must be decoupled from the current workpiece coordinate system
WCS. It permits covering using any axis, regardless whether they are
currently also covering the WCS.
In this way, it is possible to, among other things, calculate the tool com-
pensations (G41, G42, G47) in the primary, secondary and feed coordi-
nate of the current plane while the workpiece transformations
(placements, opening corrections) simultaneously refer to a workpiece
coordinate system that is covered by other axes.

Programming
Syntax:
G20(<Axis1>,<Axis2>{,<Axis3>})
where:
<Axis1> Primary coordinate of the plane to be opened; assigned to
interpolation parameter I.
<Axis2> Secondary coordinate of the plane to be opened; assigned
to interpolation parameter J.
<Axis3> Feed coordinate of the plane to be opened.
Can be programmed if it is necessary to arrange a feed axis
for tool compensation G47(ActPlane).

Special features and restrictions:


D The axes can be programmed with a logical (channel-based) or phy-
sical (system-wide) axis designation.
D Cutter path compensation G41/G42 refers to the selected plane. The-
refore, the active plane may be switched only when cutter path com-
pensation (G40) is not active. Otherwise, an error is reported.
D Tool length compensation is assigned to the active plane with
G47(ActPlane) as follows:
L1: primary coordinate
L2: secondary coordinate
L3: feed coordinate.
This assignment is updated when the active plane is switched.
D Functions G16, G17, G18, G19 and G20 form a modal group and the-
refore cancel each other mutually.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-33
and Controls

G-Codes G33

3.2.16 Thread cutting G33

Effect
Permits the cutting of
D longitudinal threads
(cutting motion parallel to the main axis of the active plane),
D transversal threads
(cutting motion parallel to the secondary axis of the active plane),
D tapered threads
(the main - and the secondary axis of the active plane are involved in
the cutting movement).

G33 can be programmed with a speed-controlled and position-control-


led spindle.
The cutting motion is always linked to the main spindle active on the
channel in question (refer to page 4-72).
The feedrate of the cutting motion results from the current spindle speed
and the programmed pitch portions (fixed, variable refer to Program-
ming).
Special features:
D single- and multiple threads can be produced
D constant and variable thread pitches can be programmed
D special dynamics adjustment during the cutting process
D programmable quick retraction movement
D chained threads can be produced.

. The feedrate potentiometer has no effect while G33 is active.

. As for circular interpolation (G2, G3), the tapping function is sub-


ject to the active plane (G17 - G20).

The behavior of the Thread cutting function is normally defined in ma-


chine parameter 7050 006xx.
In individual cases, or during commissioning, it may be advantageous to
adjust individual sections quickly. This requirement is satisfied by func-
tion ThreadSet (for a description, refer to page 4-151 ff.).
ThreadSet allows
D adjustment of the dynamics and retraction movement.
D switching of the spindle operating mode (speed control, position con-
trol)
D setting of a signal on the channel interface (configurable within the
Active function signals using machine parameters).
3-34 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G33

Programming
Syntax:
G33 <EP>,<Fixed pitch>{,<Var. pitch>}{,<Starting angle>}
where:
<EP> Axis coordinates of the primary and secondary axis of
the active plane. The active plane is defined by G17,
G18, G19 or G20.
Example:
The active plane for G18 is usually defined by axes Z
(primary axis) and X (secondary
axis).
<Fixed pitch> Defines the path (in mm) traveled in the direction of the
primary or secondary axis with each spindle revolu-
tion. This value is programmed by the interpolation pa-
rameter (I, J or K) valid in the respective active plane.
In the event of tapered threads, the pitch thread speci-
fied always must relate to the main cutting direction.
Example:
For G18, parameter K is assigned to the main axis,
and I to the secondary axis. For a longitudinal thread
(pitch in direction of main axis), the fixed thread pitch is
programmed with the K address.
<Var. pitch> Optional parameter with address DF.
Defines the pitch increase/decrease per spindle revo-
lution in mm.
Programming: DF<Value> with <Value> in mm.
<Starting angle> Optional parameter.
If no <Starting angle> has been programmed, it is as-
sumed to be 0 degrees.
The starting angle (-offset) is needed for multiple
threads. The interpolation parameter not assigned to
the active plane is used as the address.
Example:
Addresses I and K have been assigned to the plane for
G18. Therefore, the address of the starting angle is J.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-35
and Controls

G-Codes G33

Example: Longitudinal thread


G91 G18 G8 M3 S1000 Activate relative dimension programming.
Activate Z/X-plane.
G0 X-10 Feed motion of the cutting tool (1).
G33 Z-50,K2 Thread cutting (2). End point: incremental by
-50 mm in Z direction.
Fixed thread pitch: 2 mm/rev. Interpolation pa-
rameter: K here.
G0 X10 Move out cutting tool (3).

X
3 1
2

Example: Transversal thread


G91 G18 G8 M3 S1000 Activate relative dimension programming.
Activate Z/X-plane.
G0 Z-10 Feed motion of the cutting tool (1).
G33 X40,I2 Thread cutting (2). End point: incremental by
+40 mm in X-direction.
Fixed thread pitch: 2 mm/rev. Interpolation pa-
rameter: I here.
G0 Z10 Move out cutting tool (3).

X 3

1
C
3-36 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G33

Example: Tapered thread


G91 G18 G8 M3 S1000 Activate relative dimension programming.
Activate Z/X-plane.
G0 X-20 Feed motion of the cutting tool (1).
G33 Z-50 X15,K2 Thread cutting (2). End point: incremental by
-50 mm in Z direction and +15 mm in X direc-
tion.
Fixed thread pitch: 2 mm/rev. Interpolation pa-
rameter: I here.
G0 X5 Move out cutting tool (3).

The thread pitch (K in this case) always


3 refers to the main direction of cutting.
X
2 1
K

max. 45 degrees!

Chained thread
D These can be produced from all the types of thread described above.
D They are programmed by several consecutive G33 blocks.
With each G33-block programmed, the NC checks whether a subse-
quent G33- block has been programmed with path information. If this is
the case, the next block is processed without halting the axes.

Multiple threads
Multiple threads are produced by a starting angle offset (for starting an-
gle, refer to page 3-34).
Example:
A 4x thread is produced by four cuts displaced by 90 degrees each (0,
90, 180, 270).
1. cut 2. cut 3. cut 4. cut
Starting angle: 0 Starting angle: 90 Starting angle: 180 Starting angle: 270
degrees degrees degrees degrees
X X X
3 1 3 1 3 1 3 1
2 2 2 2

C C C C
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-37
and Controls

G-Codes G33

Dynamic behavior
At the beginning and at the end of a thread-cutting process, the axes in-
volved must be accelerated and stopped, respectively.
L Therefore, you should always provide for a sufficiently long entry path
(for accelerating the cutting axes) and discharge path (for stopping).

As a rule, a distinction is made between 2 process options:


D hard start and hard end of the cutting motion
At the beginning of the G33 movement, the axis/axes jump(s) to the
cutting speed (spindle speed * fixed pitch) when the starting angle is
reached. At the end of the G33 movement, the speed returns to 0.
D Start/end of the cutting motion with individual dynamics selection:
Since the hard solution is not always desirable, or cannot be perfor-
med due to restrictions existing in the area of axis dynamics, you may
set the dynamic behavior concerning the speed jump, starting and
deceleration speed individually.
D statically with machine parameters (7050 00610, 7050 00615 and
7050 00620)
D dynamically in the parts program using TreadSet(DYN) (see
page 4-151).
The control uses the programmed starting angle to compute a star-
ting angle offset, taking into account the slope of the acceleration
ramp. Thus, it can be ensured that the same thread is always cut, re-
gardless of the size of the acceleration.
At the end of the thread, the cutting axis/axes are uncoupled from the
spindle and initially decelerated to the jump speed, depending on the
deceleration setting, in order to be finally decelerated to stop.
However, if the G33 block is followed by another traversing block with
G8 active, the motion of this block will start at the speed that would
have resulted if the thread-cutting block had been a G1 block.

Rapid retraction
The fast retract function can be used in conjunction with G33.
If retraction data have been
D configured
(- statically with machine parameters (7050 00645, 7050 00650)
or
- dynamically in the program using TreadSet(RD...) (page
4-151))
and
D have been activated
(- statically with machine parameter (7050 00640) or
- dynamically in the program using TreadSet(RON1) (page
4-151)),
a positive edge at channel IF signal Fast retract will initiate the retrac-
tion with the following sequence:
1. The cutting motion is superimposed by a motion that is oriented verti-
cally to the main cutting direction.
3-38 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G33

2. If more than 70% of the retract path has been traveled, the cutting
axis/axes is/are uncoupled from the spindle and stopped at the confi-
gured deceleration (machine parameter 7050 00620).
. If the retract motion was initiated, this condition can only be cance-
led by Control reset or Move away from the contour.

Retract motions are always carried out perpendicularly to the main cut-
ting direction of the secondary cutting axis.
Retract motions are automatically initiated if either of the events Chan-
nel reset -, , System reset-, , or Spindle reset-, is triggered by the NC.

Example: Retraction from longitudinal thread


G18 Activate Z/X plane (G18).
TST(RON1) Activate fast retract (RON1).
TST(RD(0,5)) Retract motion (RD ...) by +5 mm in the secon-
: dary cutting direction (X in this case).
G91 G33 Z-20,K1 Incremental-programming ON (G91).
Thread tapping (G33). End point: incremental
by -20 mm in Z direction.
Fixed thread pitch: 1 mm/rev. Interpolation pa-
rameter: K here.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-39
and Controls

G-Codes G40, G41, G42

3.2.17 Cutter path compensation G40, G41, G42

Effect
The cutter path compensation function causes the tool to move along an
equidistant path parallel to the programmed path during execution of a
part-specific program (equidistant path = path with right-angled, con-
stant distance from the programmed contour). The distance between the
equidistant and the programmed path depends on the active radius
compensation value.
The following illustration shows the principle:
Cutter path compensation
G42 to the right of to the left
the of the
workpiece workpiece

G42 G41
G41
= direction of feed
= programmed contour
= equidistant

Programming
Syntax:
G40 Cutter path compensation OFF (power-up state).
If no traversing movement is programmed in the G40-block,
the control immediately deactivates cutter path
compensation vertically to the last traversing block!
If a traversing movement is programmed in the G40-block,
the control deactivates cutter path compensation linearly
while traveling to the end point of the traversing movement.
An active tool-length compensation is not influenced by G40.
G41 Cutter path compensation to left of workpiece ON
(for positive compensation values seen in the direction of
machining).
In addition to a D-address containing the required radius
compensation value, a linear traversing movement of the
axes of the active plane may be programmed in the same
block as G41. This selects the compensation while traveling
to the end of the traversing movement.
If no traversing movement is programmed in the G41-block,
the control immediately deactivates cutter path
compensation vertically to the last traversing block.
G42 Cutter path compensation to right of workpiece ON.
Otherwise identical to G41.
3-40 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G40, G41, G42

CAUTION
Compensation values may be immediately- activated or deactiva-
ted without programming a separate traversing movement. This
may result in damage to the workpiece or the tool.
Please note the information provided in this section in this con-
text!

Special features and restrictions:


D G40, G41 and G42 act modally and cancel each other mutually.
D With G2, G3 or G5 active, functions G40, G41 or G42 may only be
programmed without any traversing movement.
D The following is not allowed with G41 or G42 active:
D G17 - G20 (Plane switch)
D G70, G71 (Inch/metric change-over)
D G63 (Tapping without compensation chuck)
D G74 (Traverse to reference point coordinates)
D G75 (Probe-input)
D G76 (Traverse to fixed machine axis position)
D G54.x - G59.x (Zero offsets)
D G154.x - G159.x (Inclined plane)
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-41
and Controls

G-Codes G43 G44

3.2.18 Contour transitions for cutter path compensation:


Arc G43
Intersection point G44

Effect
Function for active cutter path compensation (G41, G42).
The control implements a contour transition on outside corners either
as an automatically generated
D arc (G43) or as an
D intersection point of the equidistant path (G44).

G43: Arc
The path gap is closed by a tangential arc with the radius r:
automatically generated
programmed points
a
r

equidistant traversing path

G44: Intersection point


The control tries to close the path gap by determining the intersection of
the two equidistants.
Depending on the distance A between contour corner KE and inter-
section point S, the control proceeds as follows:
for A 2 x r , the two equidistant paths are lengthened up to the intersection point

equidistant
traversing S
path
a

r
KE

If the distance is large, the control cuts off the tip at a distance of A =
2 x r and closes the path gap using a straight line:

r
S
A
KE
3-42 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G43 G44

. If no intersection point exists, the line is closed using an arc, as for


G43.

Programming
Syntax:
G43 Contour transition as arc
G44 Contour transition as intersection of the equidistants.

The following applies:


D G43 and G44 act modally and cancel each other mutually.
D The power-up state can be specified in the machine parameters.

Special features and restrictions:


D G43/G44 are programmed without any path conditions.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-43
and Controls

G-Codes G45 G46

3.2.19 Feedrate compensation:


Cutter contact point G45
Cutter center point G46

Effect
Function for active cutter path compensation (G41, G42).
You define whether the control should keep the programmed feedrate
D at the cutter contact point (cutter cutting path) or
D on the cutter center point path
constant.

G45 G46

FM FM
FB FB
FM FM
FB FB

FB = Feed along the cutting FM = Feed along the center


path point path

Programming
Syntax:
G45 Keep feed FB along the cutting path constant.
G46 Keep feed FM along the cutter center point path constant.

The following applies:


D G45 and G46 act modally and cancel each other mutually.
D The power-up state can be specified in the machine parameters.

Special features and restrictions:


D G45 should be used only for finish milling because the feedrate speed
can increase considerably along circular contours.
3-44 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G47, G48

3.2.20 Tool length compensation G47, G48

Effect
The function
D activates/deactivates tool length compensation
D optionally switches the assignment of length compensation values
L1, L2 and L3 to individual coordinates (method of operation as for
G78; see page 3-60).

When tool length compensation is active, the following are in effect:


D length compensation values L1, L2 and L3 of the currently selected
D-correction block (Dxx)
D plus length compensation values L1, L2 and L3 of an external tool
compensation (EDxx)
D function Static tool orientation (parameters can be set using STO;
see page 4-140)
D function Tool edge-compensation, if a tool edge has been entered in
the currently selected D-correction block (Dxx) and cutter path com-
pensation G41/G42 (see page 3-39) is active.

Programming
Syntax:
G47 Tool length compensation ON.
G47(ActPlane) Assign length compensation values L1,
L2 and L3 of the primary-, secondary-
and normal coordinates of the active
plane and then switch length compensa-
tion on. Remains modally effective and
is automatically reconfigured at every
following plane switch.
G47({{-}<L1-Coord>} Change the assignment of length com-
{,{{-}<L2-Coord>} pensation values LL1, L2 and L3 to the
{,{-}<L3-Coord>}}) individual coordinates and then switch
length compensation on.
G47() Assign length compensation values L1,
L2 and L3 according to the settings in
machine parameters 7050 01300 and
7050 01310 and then switch length
compensation on.
G48 Tool length compensation OFF.
where:
<Li-Coord> Name of the WCS-coordinate that is to be assigned
correction Li (where i = 1, 2, 3) in the active workpiece
coordinate system.
If correction Li (where i = 1, 2, 3) is to affect coordinates
in the tool coordinate system (TCS), coordinate desi-
gnators XTR, YTR and ZTR must be used and a cor-
responding axis transformation must be active.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-45
and Controls

G-Codes G47, G48

Optional negative sign in front: correction is calculated


in the negative direction.
Li-correction values to which no coordinates are assi-
gned are not taken into account.

Special features and restrictions:


D Coordinates that do not belong to the default-setting of the channel
are never taken into account in the G47() syntax.
D G47.. and G48 act modally and deselect each other.
D Whether the coordinate addresses programmed under G47 refer to
workpiece- or tool coordinates depends on the coordinate designator
that is used (see <Coordinate i> above).
D G47/G48 may be programmed with other path conditions, traversing
information or auxiliary functions.

Example:
G47(X,,ZTR) The L1-compensation is assigned to the X-coordinate of
the workpiece coordinate system (WCS), the L3-com-
pensation to the Z-axis of the tool coordinate system
(TCS). Both compensations are calculated in the positive
direction. Then tool length compensation is switched on.
The L2-compensation is not calculated because it is not
assigned to any coordinate.
3-46 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G53 G53.1-G59.1 G53.5-G59.5

3.2.21 Zero offsets (ZO) G53,


G53.1-G59.1
to G53.5-G59.5

Effect
ZO can be used to offset the machine coordinate system in space.

. If an opening compensation is required, see function BcsCorr


(workpiece transformation: workpiece length compensation; see
page 4-23).

The offset distances for the machine coordinates in the channel are sto-
red in the zero offset tables:
D A ZO table contains 5 ZO pages (groups) with 6 zero offsets (ZO)
each.
D Offsets from different ZO pages always work additively.
D Offsets within a ZO page mutually overwrite each other.

ZO table
ZO page
ZO group 1
1. ZO
ZO
ZO group 2 2. ZO ZO values of
3. ZO the
ZO group 3 machine
4. ZO
coordinates
ZO group 4 5. ZO
6. ZO
ZO group 5

. For details about editing the ZO tables, please refer to the operating
instructions.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-47
and Controls

G-Codes G53 G53.1-G59.1 G53.5-G59.5

Programming
1. Activate the desired ZO-table with ZoTSel (see page 4-160).
2. Program the required function:

Syntax:
G53 All ZOs for all compensation pages OFF
G53.<ZO page> All ZOs of the <ZO page> OFF
G54.<ZO page> 1. ZO of the <ZO page> OFF
G55.<ZO page> 2. ZO of the <ZO page> OFF
G56.<ZO page> 3. ZO of the <ZO page> OFF
G57.<ZO page> 4. ZO of the <ZO page> OFF
G58.<ZO page> 5. ZO of the <ZO page> OFF
G59.<ZO page> 6. ZO of the <ZO page> OFF
Abbreviation: G54 to G59 For the corresponding ZO of page 1
where:
<ZO page> 1 - 5, integer

The following applies:


D G53 works modally and deselects every active ZO.
G53.1 to G59.1 act modally and cancel each other mutually.
G53.2 to G59.2 act modally and cancel each other mutually.
G53.3 to G59.3 act modally and cancel each other mutually.
G53.4 to G59.4 act modally and cancel each other mutually.
G53.5 to G59.5 act modally and cancel each other mutually.
D If they are programmed by themselves, the functions cause no traver-
sing movement. All that happens is that the current machine coordi-
nate system is offset.
D Then functions may be written together with path conditions in the
same block. In such cases, the corresponding zero offset is activated
first; then traversing to the programmed position occurs.
3-48 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G53 G53.1-G59.1 G53.5-G59.5

Example:
ZO table Z01 contains the following offset values under ZO page 1:
1st ZO: X100, Y100
2nd ZO: X300, Y100
3rd ZO: X500, Y100
4th ZO: X100, Y450
5th ZO: X300, Y450
6th ZO: X500, Y450
Effect of functions G54.1 to G59.1:

+Y

500 G57.1 G58.1 G59.1

W W W
400

300

200

G54.1 G55.1 G56.1


100
W W W
M
100 200 300 400 500 600 700 +X

Example:
Additive effect of ZOs from different ZO pages.
ZO table Z01 contains the following offset values:
ZO page 1, 1st ZO: X100, Y100
ZO page 1, 2nd ZO: X300, Y100
ZO page 2, 4th ZO: X200, Y350

: Current machine position = 0.0 No ZO.


: All following coordinates are machine coor-
: dinates!
N40 ZOS(Z01) Activate ZO table Z01.
N50 G54.1 No traversing motion.
Offset to X100, Y100 activated.
N60 G55.1 X...Y... Offset to X300, Y100 activated.
Then traversing motion.
N70 G57.2 X...Y... Offset to X500, Y450 activated.
Then traversing motion.
N80 G53 All still-active offsets OFF.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-49
and Controls

G-Codes G61, G62

3.2.22 Precise stop ON/OFF G61, G62

Effect
Minimizes the following error at the end of a block.
During tool movements, a time offset between the command and the ac-
tual values of the individual axes occurs owing to the dynamics of the
machine. This lag effect causes a following error during machining, the
size of which depends on the feedrate and the CO factor (axis dyna-
mics). In the case of unsteady contour transitions (corners), this follo-
wing error becomes noticeable in the form of a slurring of the corner.
Please note the following:
D The following distance (displacement between the command and ac-
tual values) at the end of the block can be reduced to the size of cer-
tain target windows.
D G61 only acts on feed movements. It has no effect on rapid traverse
movements.
D As opposed to the Precise stop function for G1, G61 (with the excep-
tion of G0) affects all interpolation functions (i.e. also for circular/heli-
cal interpolation and spline interpolation).
D G61/G62 act modally and cancel each other mutually.

+Y With Precise
stop

Without Precise
stop

+X

. When G61 is active (Precise stop switched on), the control always
brakes to v = 0 at the end of a block.

Programming

Basic function Syntax:


G61 Precise stop ON.
G62 Precise stop OFF.
The last-activated positioning window for contour mode remains in ef-
fect for Precise stop ON. Default: fine positioning window.
3-50 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G61, G62

Optional parameters For selecting the positioning window for feed mode.

Syntax:
G61(IPS1|IPS2|IPS3)
where:
IPS1 Precise stop ON. Wait for fine positioning window.
At the end of the block, the control first brakes the path
velocity to v=0. Only when this positioning window has been
reached for all axes involved will the traversing movement of
the next block be executed.
IPS2 Precise stop ON. Wait for coarse positioning window.
Inpos range 2 active is displayed on the channel interface
(also see the PLC Interface manual).
At the end of the block, the control first brakes the path
velocity to v=0. Only when this positioning window has been
reached for all axes involved will the traversing movement of
the next block be executed.
IPS3 Precise stop ON. Braking to v=0 at the end of a block.
At the end of the block, the control brakes the path velocity to
v=0. Then the next block is traversed to a positioning window
without executing a check.

. The Positioning window fine and Positioning window rough


parameters can be determined in the SERCOS files for Phase 3.
For further details about SERCOS files, please refer to the Ma-
chine parameters manual under SERCOS initialization.

Special features and restrictions:


D At the latest, G61/G62 must be programmed in the block in which they
are to act.

Example:
:
N40 G61 Precise stop ON.
:
N50 Y200 Position.
:
N60 G62 Precise stop OFF.
:
N70 Y0 Position.
:
N80 G61 Y200 Positioning with Precise stop ON.
:
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-51
and Controls

G-Codes G63

3.2.23 Rigid tapping G63

Effect
D This synchronizes linear interpolation of the drill axis with the spindle
switched to C-axis operation. This eliminates the need for a compen-
sation chuck which would otherwise be required for taking up the
speed difference between the drill axis and the spindle.
D G63 acts only in the programmed block.
D A signal can be output on the channel interface for the duration of rigid
tapping (configurable within the Active function signals using ma-
chine parameters).
D Only the feed potentiometer acts during rigid tapping.

. During activating G63, the spindle C axis must be in spindle mode.

. For tapping with several spindles, also see chapter 4.92.


If axes need to be hidden for feedrate computing, see section 4.28.

Programming
Syntax:
G63(M<3|4>,S<Speed>|H<Thread pitch>) <Drill axis><Infeed
depth> {F<Feedrate>},

The thread pitch results from the relationship between the path feed to
the speed (F/S).

CAUTION
Different thread pitches during drilling and retraction will damage
the workpiece/tool!
Therefore, always program drilling and retraction in such a way
that the resulting thread pitch is identical!

Special features and restrictions:


D The retraction block must be programmed immediately after the dril-
ling block.
D During peck drilling, a blank line must be programmed between the
individual drilling segments.
D If no other feedrate (address F) is entered for the G63 block, the con-
trol uses the active path feedrate.
D Addresses M and S act only within the programmed G63 block.
D Neither Align spindle nor Spindle stop is required before G63.
D Switchover to C -axis- operation is done automatically. Prior to star-
ting, the control internally waits for INPOS of all axes involved. If an
axis drifts out of its INPOS range, G63 is not started.
3-52 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G63

D After the retraction block, the spindle automatically runs again in


spindle mode.

Example:
N20 G0 X20 Y15 Z10 F1000 Position.
N30 G63(M3,S500) Z-20 F500 Drilling (Z drill axis).
N40 G63(M4,S500) Z5 F500 Retraction (Z drill axis)
:
N120 G0 X20 Y15 Z10 F1000 Positioning for peck drilling.
N130 G63(M3,S500) Z-20 F500 Drilling of section 1.
N140 G63(M4,S500) Z5 F500 Retraction of section 1.
<Blank line> Program a blank line.
N150 G63(M3,S500) Z-40 F500 Drilling of section 2.
N160 G63(M4,S500) Z5 F500 Retraction of section 2.
:
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-53
and Controls

G-Codes G70

3.2.24 Inch programming G70

Effect
This permits the entry of path/feed information and accelerations in inch
units.

Programming
Syntax:
G70 Path/feed information and accelerations are
interpreted in inches.

The following applies:


D G70 works modally and deselects G71.
D The power-up state can be specified in the machine parameters.
D G70 may also be written together with other path conditions in the
same block.
D G70 refers to:
D working paths
D feeds
D accelerations
D other geometric auxiliary variables, such as interpolation parame-
ters I, J, K.

Example:
N40 G70 Starting at N40 (inclusive), all path and feed information
: is interpreted in inches
3-54 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G71

3.2.25 Metric programming G71

Effect
This permits the entry of path/feed information and accelerations in me-
tric units.

Programming
Syntax:
G71 Path/feed information and accelerations are
interpreted in metric units.

The following applies:


D G71 works modally and deselects G70.
D The power-up state can be specified in the machine parameters.
D G71 may also be written together with other path conditions in the
same block.
D G71 refers to:
D working paths
D feeds
D accelerations
D other geometric auxiliary variables, such as interpolation parame-
ters I, J, K.

Example:
N40 G71 Starting at N40 (inclusive), all path and feed information
: is interpreted in metric units
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-55
and Controls

G-Codes G74

3.2.26 Traverse to reference point coordinates G74

Effect
The axes programmed in the same block as G74 traverse simulta-
neously to their reference position.
The traverse speed occurs in rapid traverse / feed, depending on G0/G1.

With G74, neither reference point cams nor markers are taken into ac-
count. G74 is purely a positioning process for the absolute axis positions
(i.e. it also applies to axes with distance-coded encoders).

CAUTION
Possibly active compensations will remain unconsidered in the
course of this positioning process!

The following applies:


D G74 acts on a block-by-block basis and is canceled when all the ma-
chine axes programmed with G74 in the block have reached the refe-
rence point.
D When traversing to the reference point with G74, the actual axis -va-
lues are nor reset.
D Any compensations, ZOs, etc. that are still active are not taken ac-
count in the G74 block for the programmed axes.

Programming
Syntax:
G74 <Axis coordinates> Start Traverse to reference point-coor-
dinates.
where:
<Axis coordinates>: The axis addresses must be programmed toge-
ther with a numerical value (e.g. X1 Y1 Z1).
This numerical value has no effect on the posi-
tion of the reference point. It is only needed to
form a complete word.
Special features and restrictions:
D G74 is programmed in a separate block together with the axes to be
traversed. Auxiliary- and special functions may be programmed wit-
hin the same block.

Example:
N100 G74 X1 Y1 Z1 The X, Y and Z axes start the traverse to
: their reference positions simultaneously and
reach them simultaneously.
3-56 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G74(HOME)

3.2.27 Traverse to reference point G74(HOME)

. The G74(HOME) function can also be used for asynchronous axes!


Effect
This uses the parts program to trigger the homing of programmed axes.

SERCOS command Drive-controlled referencing (S-0-0148) is trigge-


red by the function for each drive of the programmed axes.
As a consequence, the drive decouples from the control and generates
its own position inputs for referencing using SERCOS-parameters
S-0-0147 (Referencing-parameter), S-0-0041 (Referencing velocity)
and S-0-0042 (Referencing-acceleration).

. For details, please refer to the Description of Functions.

The following applies:


D If several axes have been programmed in the G74(HOME) block,
these axes approach their respective reference points independently
of each other (no continuous-path operation). This means that the re-
ference points are not attained simultaneously.
D Both synchronous and asynchronous axes can be programmed.
Block processing is suspended until all axes of the control acknow-
ledge that they have reached their respective reference points.
D The function does not differentiate between Traverse to reference
points and the operation mode Manual.

Programming
Syntax:
G74(HOME) <Axis coordinates> Trigger SERCOS command
Drive-controlled referencing for
the programmed axes.
where:
<Axis coordinates>: The axis addresses must be programmed toge-
ther with a numerical value (e.g. X1 Y1 Z1).
This numerical value has no effect on the posi-
tion of the reference point. It is only needed to
form a complete word.
Example:
N1 G74(HOME) X1 Y1 Z1 Send SERCOS command Drive-con-
: trolled referencing to the drives of
axis X, Y and Z.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-57
and Controls

G-Codes G75

3.2.28 Probe G75

Effect
The control guides one or more measuring axes at feedrate to the posi-
tion programmed via G75 and checks whether the probe was triggered.
As soon as the edge defined in the machine parameters is detected, the
control reacts by:
D storing the actual position
D braking to v=0 with the maximum permitted deceleration
D canceling G75 and the distance to go
D switching to the next block.

. The G75 function should only be used in combination with a CPL


program for analysis.

. The parameters of the probe function can be set using machine pa-
rameters.

Programming
Syntax:
G75 <Axis coordinate> Activate the measurement input and tra-
verse the measurement axis to <Axis
coordinate>.

Special features and restrictions:


D G75 acts block by block.
D No auxiliary functions may be programmed in the G75-block. Howe-
ver, other path conditions are permitted.
D G75 must be programmed together with at least one <axis coordi-
nate>. This value represents the maximum search depth to which the
probe must have switched at the latest.
D Stopping block preparation after the G75 block is not required (WAIT
is not necessary).
D Evaluation of axis information, safety monitoring, generation of error
messages etc. must be realized in the CPL program.
Example:
N100 G75 Y250 F500 Traverse with F500 to position Y250.
110 IF SD(9) = 0 THEN Query whether probe was displaced.
120 YPOS=PPOS(2) Save the position in the switching torque of
: the 2nd axis (Y-axis) to the XPOS variable.
N130 (MSG, CONTACT)
140 GOTO N180
150 ENDIF
N160 (MSG, NO CONTACT)
N170 M0 Program halt
N180 ...
3-58 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G76

3.2.29 Traverse to fixed machine axis position G76

Effect
Permits the programming and linear traversing to positions in the ma-
chine coordinate system without having to separately deactivate any ac-
tive compensations and transformations in the parts program.
This can be necessary, for example, when changing the tool, checking
tools for damage or changing pallets.
G76 acts on a block-by-block basis in rapid traverse (G0) or in feed (G1),
as well as together with G93 (Time programming), G94/G95 (Feed pro-
gramming) and the F-word.
The following functions are not taken into account in G76:
D Tool compensations (G41, G42, G47 Dxx, EDxx)
D Input tools (Mirror, Scale, Rotate, Shift)
D Zero offsets (G54.1 - G59.5)
D Placements (BcsCorr, G154.1 - G159.5)
D Axis transformations based on machine coordinates,
(e.g. 5-axis transformation)
D Relative dimension programming (G91)
D Set program position (SetPos)

Programming
Syntax:
G76 <Machine coordinates>

where:
<Machine coordinates>: Machine coordinates to be approached.

Special features and restrictions:


D G76 can be written together with other path conditions (e.g. G0, G1,
G93, G94, G95, F-word)
D Local relative dimension-programming (IC(...); see page 3-69) is
not permitted in conjunction with G76, leading to a runtime error.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-59
and Controls

G-Codes G77

3.2.30 Asynchronous subroutines:


Repositioning individual coordinates G77

Effect
Traverses the defined coordinates to the point of return to path after the
end of the asynchronous subroutine in which G77 is programmed.
The point of return to path is always approached on a straight line.

. You can find extensive information regarding the use and parame-
ter settings of asynchronous subroutines in the Description of
Functions.

Programming
Syntax:
G77 <Coord 1><Mode> <Coord n><Mode> ... F<Value>
where:
<Coord i> Coordinate name (e.g. x)
<Mode> <Coord i> for point of return to path
1 take into account.
0 do not take into account. The coordinate remains at its
current value.
<Value> Feedrate with which positioning on the point of return to
path is to be executed.

Special features and restrictions:


D The function has been designed for use in an asynchronous subrou-
tine.
D All coordinates that are not programmed by G77 are automatically
traversed on a straight line to the point of return to path at the end of
the asynchronous subroutine.
D Any correction modifications made within an asynchronous subrou-
tine are automatically taken into account in the internal calculation of
the required point of return to path.
D As an alternative syntax, REPOS can be programmed instead of
G77.
3-60 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G78 G79

3.2.31 Compensation switching ON G78


Compensation switching OFF G79

Effect
This assigns the length compensationsof the geometry correction -
functions to individual coordinates. These are the coordinates:
D of the current workpiece coordinate system (WCS) or
D of the tool coordinate system (TCS).

An assignment with respect to the coordinates of the workpiece coordi-


nate system (WCS) is possible whenever the tool is aligned perpendi-
cularly to the current working plane and its orientation with regard to the
working plane remains constant during machining.

An assignment with reference to the coordinates of the tool coordinate


system (TCS) is necessary if the orientation of the tool changes during
machining, e.g. milling of freeform surfaces. An active axis transforma-
tion (e.g. 5-axis or 6-axis transformation) is necessary for this compen-
sation. The compensation values are taken into account within the axis
transformation.

Tool compensation in workpiece Tool compensation in C


coordinate- tool coordinate-
system WCS system (TCS)
L3
C Y
L2
Y C TCS
L1
L3 L2 Y

L1 X
X
WCS X WCS

. To activate the current compensation values for machining, see


G47, page 3-44 ff.

Programming
Syntax:
G78({{}<Coordinate1>},{{}<Coordi Compensation swit-
nate2>},{{}<Coordinate3>}) ching ON.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-61
and Controls

G-Codes G78 G79

where:
<Coordinate i> Name of the WCS-coordinate (logical/physical axis
name) that is to be assigned correction Li (where i = 1,
2, 3).
If correction Li is to affect coordinates in the tool coor-
dinate system (TCS), coordinate designators XTR,
YTR and ZTR must be used.
Optional negative sign in front: correction is calculated
in the negative direction.
Li corrections to which no coordinates are assigned
are not taken into account.

G78(ActPlane) Compensations L1, L2 and L3 are assigned to the


primary, secondary and normal coordinates of the
corresponding active plane.

G79 Compensation switching OFF.


The settings in the machine parameters are valid
again.

Special features and restrictions:


D G78 and G79 act modally and deselect each other.
D Coordinates that do not belong to the default setting of the channel
are never taken into account in G79.
D The coordinate addresses programmed under G78 can refer to work-
piece coordinates - or tool coordinates (see above under <Coordi-
nate i>).
D G78/G79 may be programmed with other path conditions, traversing
information or auxiliary functions.

Examples:
G78(X, ,ZTR) The L1 compensation is assigned to the X-axis of the
workpiece coordinate system (WCS), the L3 compensa-
tion to the Z axis of the tool coordinate system (TCS).
Both compensations are calculated in the positive direc-
tion.
G78( , ,-Y) The L3 compensation is assigned to the Y axis of the
workpiece coordinate system (WCS) and taken into ac-
count in the negative direction.
G78(YA,YB) The L1 compensation is assigned to the YA-axis and the
L2 compensation to the YB-axis of the workpiece coordi-
nate system (WCS). Both compensations are calculated
in the positive direction.
G79 Compensations are switched off for all default coordi-
nates of the channel.
3-62 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G80 G81

3.2.32 Switch off drilling cycle G80

Effect
Switches off an active drilling cycle (G81 - G86, G184).

Programming
Syntax:
G80

Special features and restrictions:


D No bracket expression may be programmed in a G80 block.

3.2.33 Drilling cycle: Drilling with retraction in rapid traverse G81


Application:
D Centering and simple drilling operation, facing, drilling out.

Effect
Upon reaching the Z drilling depth, an optional dwell time becomes ac-
tive. Subsequently, retraction at rapid traverse takes place.

G81 with R1 plane G81 with R2 plane

PE PE PE Positioning plane
Rx
Reference plane
R2
1.2
R1 R1
C Drilling depth
P Dwell time

P C P C
Feed
Rapid traverse

Programming
Syntax:
G81[<Z>,<R1>,{<P>},{<R2>}]

Special features and restrictions:


D This drilling cycle is executed in every new traversing block.
D Deselect with G80.
D Before switching the cycle, the current cycle must be deselected with
G80.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-63
and Controls

G-Codes G82

3.2.34 Drilling cycle: Drilling with retraction in feed G82


As for G81. However, retraction to R1 is at feedrate.

G82 with R1 plane G82 with R2 plane

PE PE PE Positioning plane
Rx
Reference plane
R2
1.2
R1 R1
C Drilling depth
P Dwell time

P C P C
Feed
Rapid traverse

Programming
Syntax:
G82[<Z>,<R1>,{<P>},{<R2>}]

Special features and restrictions:


D This drilling cycle is executed in every new traversing block.
D Deselect with G80.
D Before switching the cycle, the current cycle must be deselected with
G80.
3-64 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G83

3.2.35 Drilling cycle: Peck drilling G83


Application:
D Peck drilling with removal of drilling chips.

Effect
After the arrival at the programmed K infeed depth, a retraction move-
ment at rapid traverse to the reference R1 plane is performed.
Renewed infeed to the programmed k distance (speed-change point) is
also performed at rapid traverse. Subsequently, the control switches
back to feedrate.
Stepwise infeed with corresponding retraction to the reference plane is
executed until the programmed Z total drilling depth is reached.

G83 with R1 plane G83 with R2 plane

PE PE PE Positioning plane
R2
Rx Reference plane 1.2
R1 R1
K Infeed depth
K K
k k k Distance to
speed-switching point
C
K K Drilling depth
k k
P Dwell time
K K
: Feed
C C : Rapid traverse
P P

Programming
Syntax:
G83[<Z>,<R1>,<K>,<k>,{<P>},{<R2>}]

L The K infeed depth must be programmed without a positive/negative


sign in incremental data input, irrespective of the drilling direction.
If the max. drilling depth Z is exceeded owing to erroneous programming
of infeed depth K, the control first interrupts the drilling cycle via M0 and
displays the DRILLING DEPTH K TOO LARGE error message.
After a new start, the drilling cycle is cancelled (M30).

Special features and restrictions:


D This drilling cycle is executed in every new traversing block.
D Deselect with G80.
D Before switching the cycle, the current cycle must be deselected with
G80.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-65
and Controls

G-Codes G84

3.2.36 Drilling cycle: Tapping with compensation chuck G84


Application:
D Tapping (left and right) with compensation chuck.

Prerequisite:
D internal spindle as drilling axis. External spindles are not allowed.

Effect
Tool infeed occurs at the programmed M3 clockwise-rotating spindle or
M4 counterclockwise-rotating spindle (right- or left-handed thread).
As soon as drilling depth Z (thread depth) has been reached, the sense
of rotation is reversed, and dwell time P (if programmed) starts to run.
Subsequently, the retraction movement to the reference plane is perfor-
med at feedrate. As soon as it has been reached, the reversal of the rota-
tion direction is cancelled again.

G84 with R1 plane G84 with R2 plane


PE Positioning plane
G63 Rx Reference plane 1.2
PE PE

R2
C Thread depth
D P Dwell time
G66 R1 D R1
D Rotation direction
reversal
P C P C : Feed
D D
: Rapid traverse

Programming
Syntax:
G84[<Z>,<R1>,{<P>},{<R2>}]

CAUTION
Possible damage to tools or workpieces!
During the cycle, any active single block processing will not be
suppressed!
This means that the spindle will keep on running after a
positioning process within the cycle. This may lead to damage to
the tool and the workpiece.
You should therefore ensure that the control executes the cycle in
the Automatic mode only!

Special features and restrictions:


D This drilling cycle is executed in every new traversing block.
D Deselect with G80.
D Before switching the cycle, the current cycle must be deselected with
G80.
3-66 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G85

3.2.37 Drilling cycle: Drilling out with retraction in rapid traverse G85
Application:
D Boring

Effect
After drilling depth Z is reached,
D the spindle stops and
D a dwell time (if programmed) goes into effect.
D Subsequently, retraction at rapid traverse takes place.

G85 with R1-plane G85 with R2-plane

PE PE PE Positioning plane
M03 Rx Reference plane 1.2
R2

M03
R1 R1
C Drilling depth
P Dwell time

P C P C
: Feed
M05 M05 : Rapid traverse

Programming
Syntax:
G85[<Z>,<R1>,{<P>},{<R2>}]

Special features and restrictions:


D This drilling cycle is executed in every new traversing block.
D Deselect with G80.
D Before switching the cycle, the current cycle must be deselected with
G80.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-67
and Controls

G-Codes G86

3.2.38 Drilling cycle: Drilling out with retraction in feed G86


As for G85. However, retraction to R1 is at feedrate.

G86 with R1 plane G86 with R2 plane

PE PE PE Positioning plane
R2 Rx Reference plane 1.2
M03
R1
M03 R1
C Drilling depth
P Dwell time

P C P C
: Feed
M05 : Rapid traverse

Programming
Syntax:
G86[<Z>,<R1>,{<P>},{<R2>}]

Special features and restrictions:


D This drilling cycle is executed in every new traversing block.
D Deselect with G80.
D Before switching the cycle, the current cycle must be deselected with
G80.
3-68 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G184

3.2.39 Drilling cycle: Tapping without compensation chuck G184


Application:
D Tapping (left and right) without compensation chuck.
Prerequisites:
D controlled spindle
D G63 (Tapping without compensation chuck).
Effect
Tool infeed is calculated internally on the basis of the product of speed x
thread pitch (U1*GS). You select the direction of rotation (right- or left-
handed thread) via the positive/negative sign of the GS parameter
(thread pitch).
As soon as drilling depth Z (thread depth) is reached, the direction of ro-
tation is reversed. Subsequently, the retraction movement to the refe-
rence plane is performed at feedrate. The direction of rotation of the
spindle remains effective until you program a new drilling cycle.

G184 with R1 plane G184 with R2 plane


PE Positioning plane
G63 G63 Rx
Reference plane
PE PE
1.2
R2
C Thread depth
G66
P Dwell time
U1 R1 U1 R1
U1 Rotational speed
U1 U2 U1 U2 U2 Speed upon
P C P C retraction
TD thread pitch

TD
: Feed
: Rapid traverse

Programming
Syntax:
Clockwise thread:
G184[<Z>,<R1>,{<P>},{<R2>},<GS>,<U1>,{<U2>},{<RP *>}]
Counterclockwise thread:
G184[<Z>,<R1>,{<P>},{<R2>},-<GS>,<U1>,{<U2>},{<RP *>}]
*) RP determines the orientation position of the spindle.

. P may be programmed for reasons of compatibility, but it is not eva-


luated!

Special features and restrictions:


D This drilling cycle is executed in every new traversing block.
D Deselect with G80.
D Before switching the cycle, the current cycle must be deselected with
G80.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-69
and Controls

G-Codes G90 G91 AC(...) IC(...)

3.2.40 Absolute dimension programming G90


Relative dimension programming G91
Local absolute dimension programming AC(...)
Local relative dimension programming IC(...)

Effect
This specifies whether the control is to interpret unit information for the
axes and coordinates as absolute or relative (incremental) values.
D Absolute dimension information refers to the current zero point (in the
program coordinate system).
D Relative dimension information refers to the last-approached posi-
tion.

Relative dimension Y
Absolute dimension Y
G90 Target point
G91 Target point
Y Y

Starting pt. Starting pt.

Absolute dimension X
Relative dimension X

X X

The following applies:


D G90 and G91 act modally and cancel each other mutually.
D AC(...) and IC(...) act independently of an active G90/G91 only for the
path information of the axes whose position is programmed with
AC(...) or IC(...).
Programming
Syntax:
G90 Absolute dimension programming
G91 Relative dimension programming
<Axis>=AC(<Value>) Local absolute dimension programming.
<Axis>=IC(<Value>) Local relative dimension programming.
where:
<Axis>: Logical axis address.
<Value>: Path information for <Axis>.

Example:
N10 G1 G90 Absolute dimension programming ON.
N20 X100 Y100 Traverse to coordinates X100, Y100.
N30 G91 Relative dimension programming ON.
N40 X100 Y100 Traverse to coordinates X200, Y200.
N50 X=AC(50) Y50 Local absolute dimension programming for
X-axis. Traversing movement on the ma-
chine to X50, Y250.
3-70 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G93

3.2.41 Time programming G93

Effect
The control interprets F-words (see the description in the Auxiliary and
special functions section ) as the machining time (in seconds) for the
programmed contour (block duration).
The following applies:
D Functions G93, G94 and G95 act modally and cancel each other mu-
tually.

. The desired power-up status (G93, G94 or G95) can be specified in


the machine parameters (default: G94).

Programming
Syntax:
G93 Switch to time programming.

Example:
N5 G93 G1 X30 Y20 F20 The programmed linear interpolation lasts
: 20 seconds.

Special features and restrictions:


D An F-word programmed during G93 remains in internal memory
when switching to G94 or G95 and becomes active again when swit-
ching back to G93.
D After a power-up or control reset, the F-word specified in the machine
parameters is active (default: F0).
D The control internally calculates the required feedrate on the basis of
the path length of the corresponding traversing block and the pro-
grammed machining time.
However, the resulting effective feedrate can be limited by the control
according to the programmed contour and the maximum values of the
participating axes so that the block duration increases.
D A feed override remains in effect even in the case of G93, depending
on function OvrEna / OvrDis.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-71
and Controls

G-Codes G94

3.2.42 Feed programming (per min) G94

Effect
The control interprets F-words (see page 3-95) or Omega -words (see
page 3-96) as feed for a programmed contour.
The following applies:
D Functions G93, G94 and G95 act modally and cancel each other mu-
tually.
D The programmed feed is interpreted
D as mm/min if G71 is active
D as inches/min if G70 is active
D as degrees/min in connection with rotary axes.
. Machine parameters can be used to set the weighting of the fee-
drate for G70/G71.
. The desired power-up status (G93, G94 or G95) can be specified in
the machine parameters (default: G94).
Programming
Syntax:
G94 Switch to feed programming.

Example:
N10 G71 Switch on metric programming.
N20 G1 G94 X20 Y30 F200 Traverse with a feedrate of 200 mm/min.
N30 G4(F40) Dwell time of 40 seconds.
N40 G70 Inch programming ON.
N60 X300 Y400 Feedrate F200 (in mm/min) is again ef-
fective.
N70 F100 New feedrate: 100 inches/min.
:

Special features and restrictions:


D An F- or Omega word programmed during G94 remains in internal
memory when switching to G93 or G95 and becomes active again
when switching back to G94.
D After a power-up or control reset, the F-word specified in the machine
parameters is active (default: F0).
The Omega word is always automatically initialized to 0 after a
power-up.
D Due to configured maximum velocities of the participating axes, the
control can limit the effective feedrate.
D The feedrate is influenced by the feed override, depending on
OvrEna / OvrDis.
3-72 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G94(...)

3.2.43 Incremental speed programming G94(...)


with acceleration adaptation

Effect
Changes the feedrate or speed relative to the last actively effective va-
lue. The acceleration within the G94(...) block is adapted in such a man-
ner that the resulting speed/velocity is attained no earlier than the end of
the block. This leads to a very gentle acceleration behavior.

The following applies:


D Although function G94 is modal, the resulting feedrate is not modal for
the following blocks.
D The unit of the incremental feedrate is inches/min or mm/min, accor-
ding to G70/G71.
D The feedrate is influenced by the feed override, depending on
OvrEna / OvrDis.

Programming
Syntax:
G94(DF<F-word>) Program the path velocity incre-
mentally
G94(DS1<S-word>) Program the spindle speed for
spindle 1 incrementally
G94(DF<F-word>,DS7<S-word>) Program the path velocity and
the spindle speed for spindle 7
incrementally.
where:
<F-word>: Incremental path velocity. Positive values increase and
negative values decrease the currently effective path ve-
locity.
<S-word>: Incremental spindle speed. Positive values increase and
negative values decrease the currently effective spindle
speed.

Example:
N30 G94(DF100) X250 Y300 Increase path feedrate linearly by
: 100 mm/min to the end of the block.
N50 G94(DF-50) X300 Y200 Reduce path feedrate linearly by 50
: mm/min to the end of the block.
N70 G94(DS1=100) X25 Y30 Increase speed of spindle 1 by 100
: rpm to the end of the block.
N90 G94(DF100,DS7=150) X2 Y2 Increase path velocity linearly by 100
: mm/min and speed of spindle 2 by
150 rpm to the end of the block.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-73
and Controls

G-Codes G94(...)

Special features and restrictions:


D The existing acceleration and braking limits are monitored. It may
happen that the resulting final velocity can only be attained in the next
block.
D The calculated acceleration acts only in the G94(...) block. If the block
is cancelled, braking occurs with the calculated acceleration.
D Absolute and incremental feedrates may not be programmed simul-
taneously in the same block.
3-74 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G95

3.2.44 Feed programming (per rot.) G95

Effect
The control interprets F-words (see page 3-95) as feedrate/rotation.
This is required in conjunction with the main spindle. The following ap-
plies:
D Functions G93, G94 and G95 act modally and cancel each other mu-
tually.
D The programmed feed is interpreted
D as mm/rot. if G71 is active
D as inches/rot. if G70 is active
. Machine parameters can be used to set the weighting of the fee-
drate for G70/G71.
. The desired power-up status (G93, G94 or G95) can be specified in
the machine parameters (default: G94).
. For the definition of the main spindle, see MP 7020 00010 or func-
tion MainSp.

Programming
Syntax:
G95 Switch to rotary feed programming.

Example:
N05 G71 Switch on metric programming.
N10 S200 M4 Spindle speed 200 rpm, counterclock-
wise.
N20 G1 G95 X20 Z30 F0.2 Traverse with a feedrate of 0.2 mm/rot.
N30 G4(S20) Dwell time of 20 rotations.
N40 G70 Inch programming ON.
N60 X300 Z40 Feedrate F0.2 (in mm/rot) is again effec-
tive.
N70 F0.1 New feedrate = 0.1 inches/rot.
:

Special features and restrictions:


D G95 requires a turning main spindle.
D The effective feed is influenced by both the spindle and the feed po-
tentiometers.
D Due to configured maximum velocities of the participating axes, the
control can limit the effective feedrate.
D An F-word programmed during G95 remains in internal memory
when switching to G93 or G94 and becomes active again when swit-
ching back to G95.
D After a power-up or control reset, the F-word specified in the machine
parameters is active (default: F0).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-75
and Controls

G-Codes G96 G97

3.2.45 Constant cutting speed G96


Direct speed programming G97

Effect
During turning, the control interprets S-words as
D the command cutting speed of the tool (G96) or
D the speed of the workpiece axis of rotation (G97).

With the given spindle speed, the cutting speed depends on the distance
between the cutting tool and the workpiece axis of rotation.

To compensate for this, function G96 automatically changes the speed


of the axis of rotation depending on the distance between the cutting tool
and the workpiece axis of rotation:
D for G71:
S Akt[min 1] 
S G96  1000

m  1000
2  p   Position(Koordinate, Bezugssystem)  Werkzeugkorrektur  min  mm

D for G70:

minfeetinch
12

By default, the NC calculates the distance in the machine coordinate sy-
stem (MCS reference system):

X-axis

MCS machine zero point

G96 position
3-76 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G96 G97

If the spindle must be positioned between different tool magazine points,


G96 can include corresponding zero offsets that cover a local coordinate
system (LCS reference system):

MCS+ZO1

MCS+ZO2
X-axis
G96 position

G96 position

MCS machine zero point

In the case of tools that are not arranged axis-parallel to the spindle, off-
sets and placements of the workpiece zero point can also be taken into
account (PCS reference system):

MCS+ZO+PMT

Y-axis

G96 position

X-axis

MCS machine zero point

The cutting speed on the workpiece is thus no longer influenced by the


distance between the cutting tool and the workpieces axis of rotation.

If this behavior is not required or desired, use G97 instead. The speed of
the workpieces axis of rotation is then determined solely by the pro-
grammed S-word.

The following applies:


D The reference axis for the distance between the cutting tool and the
workpieces axis of rotation is defined by machine parameter 7010
00110 (default value).
D The programming of the reference axis can be changed at runtime.
D The reference coordinate system (point of contact) for the reference
axis is preset using machine parameter 7010 00120. The following
possibilities are available:
D PCS: Position in program coordinate system
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-77
and Controls

G-Codes G96 G97

D LCS: Position in local machine coordinate system


(offset by ZO)
D MCS: Position in machine coordinate system (default)
D The point of contact of the reference axis can be changed at runtime.
D The programmed cutting speed is interpreted as
D m/min if G71 is active
D feet/min if G70 is active.
D In addition to the spindle-override, the functions for speed limitation
(SMin, SMax; see page 4-125) are also in effect.

Programming
Syntax:
G96{({<Reference axis>{,<Point of action>}})} ... S<i>=<V>
S-words of spindles that are program-
med in the G96 block are interpreted as
command cutting speeds on the tool du-
ring turning.
All other spindles revert to direct speed
programming!
G96 The last programmed settings become
active; if none were made, the default
values apply.
G96() ... The default values for the reference axis
and the point of contact are reactivated.
G97 ... S<i>=<Speed> Only the spindles whose S-words are
programmed in the G97 block revert to
direct speed programming. For these
spindles, programmed S-words are in-
terpreted as the speed of the workpie-
ces rotation axis.
G97 All spindles revert to direct speed pro-
gramming.
where:
<Reference axis> Physical or logical name of the reference axis. Pro-
gramming remains in effect until a new value is pro-
grammed or the default value is activated.
<Point of contact> Coordinate system of the reference axis:
PCS, LCS or MCS
Programming remains in effect until a new value is
programmed or the default value is activated.
<i> Spindle index.
1: first spindle; 2: second spindle, etc.
<V> Cutting speed of the relevant spindle in m/min or feet/
min.
<Speed> Speed of the relevant spindle in rpm.
3-78 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G96 G97

Example (2 spindles are configured in the system):


N10 G71 S1=500 S2=500 Define command rotations of both spindles
: for the first time in the program.
N60 G96 S1=50 Activate G96 for the 1st spindle with a cut-
: ting speed of 50 m/min.
: The 2nd spindle is still running with speed
: programming. G96 active.
N100 S1=30 Reduce the cutting speed of the 1st spindle
: to 30 m/min.
: The 2nd spindle is still running with speed
: programming. G96 active.
N140 G96(Y,LCS) S2=100 The reference axis is Y and the point of con-
: tact is the local machine coordinate system
: LCS.
: Activate a cutting speed of 100 m/min for the
: 2nd spindle.
: The 1st spindle reverts to speed program-
ming. G96 active.
N180 G97 All spindles revert to direct speed program-
: ming, if this has not already happened. G97
: active.

Special features and restrictions:


D Several spindles can be switched together in the same block by pro-
gramming the corresponding S-words in sequence (example: G96
S1=100 S2=1000).
D To change the cutting speed of a spindle that has already been swit-
ched to G96 for the remainder of the program execution, merely the
S-word of the appropriate spindle needs to be reprogrammed.
D The currently effective cutting speed of a spindle remains in internal
memory after switching to G97. It is reactivated as soon as the corres-
ponding spindle is switched back to G96.
D If switching from G96 to G97 occurs, the control uses the current
speed as the new command speed value for all spindles whose S-
word is not programmed in the G97 block.
D A possibly desired gear-range change has to be carried out before
G96 is activated.
D When G96 is active, function Automatic gear range switching does
not switch any gear ranges.
D When G96 is active, the control checks whether the reference axis
affects the active point of contact. If this is not the case (e.g. if the axis
exits the channel), a runtime error is reported.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-79
and Controls

G-Codes G140, G141, G142

3.2.46 3D tool radius compensation G140, G141, G142

Effect
The function moves a rotation-symmetric tool to the left or right of the
programmed path, guiding its point of action to the programmed path
with feed active.
In the case of pure orientation movements, the current position of the
point of contact remains fixed and the TCP moves.
At exterior corners, the path is closed using an automatically generated
intermediate block (arc). An intersection is calculated in the case of inter-
ior corners.
The control takes the following into account for compensation:
D tool radius r (automatically taken from the active tool data D, G146 to
G846 or G147 to G847).
D insertion depth d (see syntax for INSDEP)
D an optional allowance for the path that acts additively to the tool ra-
dius (see syntax for COFFS).

The following illustration shows the principle:

Orientation vector Correction


to right of to left of
progr. path progr. path
TCP

r
d
PE

TCP
Workpiece G142 G141
= direction of feed
TCP: Tool tip r: Tool radius = programmed path
PE: Tool point of action d: Insertion depth

A change in the insertion depth (INSDEP), the allowance (COFFS), the


tool length or the milling tool radius is carried out immediately and gently
(using splines) when G141/G142 is active.

. For detailed information about this function, see the Description


of Functions.

CAUTION
Compensation values may be immediately activated or deactiva-
ted without programming a separate traversing movement. This
may result in damage to the workpiece or the tool.
Please note the information provided in this section and the Des-
cription of Functions in this context!
3-80 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G140, G141, G142

Programming
Syntax:
G140 3D tool radius compensation OFF
(start-up state after starting controller).
The compensation (radius, insertion depth) is
reduced in an interpolating manner, if necessary with
a programmed traversing movement (using
3rd-degree splines). An active tool length compensa-
tion is not influenced by G140.
G141 3-D tool radius compensation to left of path ON
(seen in the direction of machining for positive
compensation values).
Traversing movements or orientation movements
may be programmed in the same block.
The radius and insertion depth are retracted if one of
the active space coordinates is programmed in the
same block. Otherwise, the control builds up the
compensation
D no sooner than in the next traversing block if
G140 was active beforehand.
D immediately (in active feed) if G141/G142 was
active beforehand.
G142 3-D tool radius compensation to right of path ON.
Otherwise identical to G141.
INSDEP<ID> Defines insertion depth <ID>. Acts modally.
Start-up state after starting controller: 0
COFFS<KA> Defines allowance <KA>. Acts modally and additive to
tool radius r.
Start-up state after starting controller: 0

Special features and restrictions:


D G140, G141 and G142 act modally and cancel each other mutually.
D Buildup and breakdown of compensation on any contour (G2, G6,
etc.).
D The following is not allowed with G141 or G142 active:
- G17 - G20 (Plane switch)
- G70, G71 (Inch/metric switching)
- G63 (Rigid tapping)
- G74 (Traverse to reference point coordinates)
- G75 (Probe input)
- G76 (Traverse to fixed machine axis position)
- SetPos (Set program position)
- G54.x - G59.x (Zero offsets)
- G154.x - G159.x (Inclined plane)
- G40 - G42 (Tool radius compensation)
- Coord() (Axis transformation on/off/switch)
- Transfers of axes that participate in the current space coordinates
via axis/coordinate transformation.
D If G141 or G142 is active, a collision check is not carried out.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-81
and Controls

G-Codes G152 - G159.5

D If the program ends without M30, G140 must be active at this time.
The current insertion depth and allowance values are retained.
D G140 is automatically activated after a control reset, a system reset or
M30. The current insertion depth and allowance values are set to 0.

3.2.47 Placement: Inclined plane G152 - G159.5

Effect
Placement Inclined plane can shift and orientate the workpiece coordi-
nate system anywhere in space. Inclined plane has an effect on the coor-
dinates with the meanings x, y and z in the corresponding channel.
Since there are 3 degrees of freedom for orientation, every orientation
can be represented by 3 consecutive basis rotations.

1. basis rotation 2. basis rotation 3. basis rotation


(theta)
+ZB +ZW = +ZB
+YB +ZW +ZW +ZW = +ZB
+YB
+YW=+YW
+YW +YW

+XB - (psi)
BCS +XB WCS - (phi) WCS WCS
+YW
+XW +XW

+XW +XW
+XW
Rotation of the Rotation of the Rotation of the
Basis -workpiece- coordinate system by coordinate system by coordinate system by
coordinate system coordinate ZB and coordinate YW(=YW) coordinate ZW(=ZW)
the angle phi and the angle theta and the angle psi.

+ZW
Resulting workpiece coordinate system (WCS), offset by distance
DX, DY, DZ and oriented by the angles phi, theta, and psi (see
above), relative to the BCS:
WCS

+YW
+ZM
+YM DZ
+XW

DY

BCS +XM Machine

DX

BCS = basis-workpiece coordinate system, WCS = workpiece coordinate system


3-82 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G152 - G159.5

The resulting functioning of Inclined plane is affected by


D 5 pages (1 to 5), each of which acts additively to each other.
This allows up to 5 workpiece coordinate systems that build on one
another to be generated.
D 7 alternative sets per page.
Each set contains all required offset- and orientation data for a work-
piece coordinate system.
Within a page, only one single set can be active at any given time, i.e.
the sets of a page mutually deselect one another.

Inclined plane acts additively to placement Tool length compensation;


therefore, it is located behind workpiece position compensation in the
calculation chain:

+ZW2
+ZW1 WCS2
+ZB +YW2
WCS1
+YB

WCSn
+YW1
+XW2

+XW1

BCS +XB
BCS: Basic-workpiece coordinate system
WCS1:Workpiece coordinate system, generated by workpiece position
compensation
WCS2:Workpiece coordinate system, building up on WCS1 and
generated by Inclined plane
WCSn:Workpiece coordinate system, building up on WCS(n-1) and
generated by Inclined plane. Please note the following: n = 2 - 6

Programming ...
A set is all the data required for the offset and orientation of a workpiece
coordinate system.
Sets can be either
D programmed directly in the parts program as function parameters, or
D entered in a placement-table (see page 4-95).
A placement table can contain up to 30 sets (5 pages, each with 6
sets).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-83
and Controls

G-Codes G152 - G159.5

... directly in the program line as a parameter:


Syntax:
G152.<Page>({<XW -Offset>}{, Inclined plane of the desired page
{<YW -Offset>}{,{<ZW -Offset>}{, ON with programmed
{<Angle1>}{,{<Angle2>}{, offset/orientation data.
{<Angle3>}}}}}})
Abbreviation: G152 = G152.1

G153.<Stage> Inclined plane of the progr. page


OFF
G153 Inclined plane OFF (switch off all
pages).
where:
<Page>: Number of the desired page.
Range of values: 1 to 5
<XW -Offset>: Offset value in main coordinate direction
<YW -Offset>: Offset value in secondary coordinate direction
<ZW -Offset>: Offset value in normal coordinate direction
<Angle1>: Angle of rotation around the Z-coordinate.
Value range: 0 <Angle1> < 360 degrees
<Angle2>: Angle of rotation around the Y-coordinate.
Value range: 0 <Angle2> < 180 degrees
<Angle3>: Angle of rotation around the Z-coordinate.
Value range: 0 <Angle3> < 360 degrees

Example:
:
N40 G152.1(100,0,0,90) Inclined plane of page 1 ON.
: No traversing motion.
: The zero point is offset by 100 mm in the
: X-direction and the WCS is rotated by 90
: degrees around the Z-coordinate.
:
N180 G153 Switch off all pages (switch off Inclined
plane altogether).

... in conjunction with placement tables:


1. Activate the desired placement-table (see page 4-95).
2. Program the required function:

Syntax:
G154.<Page> Inclined plane of the progr. page set 1 ON.
G155.<Page> Inclined plane of the progr. page set 2 ON.
G156.<Page> Inclined plane of the progr. page set 3 ON.
G157.<Page> Inclined plane of the progr. page set 4 ON.
G158.<Page> Inclined plane of the progr. page set 5 ON.
3-84 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

G-Codes G152 - G159.5

G159.<Page> Inclined plane of the progr. page set 6 ON.


Abbreviation: G152 - G159 = G154.1 - G159.1

G153.<Page> Inclined plane of the progr. page OFF


G153 Inclined plane OFF (switch off all pages).
where:
<Page>: Number of the desired page.
Range of values: 1 to 5

. Please refer to the Operating Instructions for how to create and edit
placement tables.

Example:
N40 PMS(Tab1) Activate placement table Tab1
N50 G154.1 Switch on page 1 with set 1. No traversing
: motion.
N90 G154.2 X1 Y2 Z3 Switch on page 2 with set 1 (acts additively to
: page 1). In the resulting WCS, traverse to the
: programmed position P(1,2,3).
N120 G153.2 Switch off page 2 (page 1 remains in effect).
:
N180 G153 Switch off all pages (switch off Inclined plane
altogether).

Special features and restrictions:


D If an axis transformation is active, Inclined plane may not be program-
med in the same block as traverse movements.
D The power-up status and the behavior in case of a control reset are
configured in machine parameters 7060 00010 and 7060 00020.
D All functions are modal within each page (1 - 5) and deselect each
other mutually.
D Activating and deactivating Inclined plane interrupts block look-
ahead; therefore, it may not be programmed when cutter path com-
pensation is active (G41/G42, see page 3-39).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-85
and Controls

M-Codes M0, M00 M1, M01

3.3 M-Codes

3.3.1 Interrupt program (Program stop) M0, M00

Effect
D Interrupts the NC program,
D stops machine movements after executing the block, and
D issues the channel-based interface signal Program stop M0.

The current channel status switches to NC Ready.


Program execution is restarted by NC-Start.

. See M1/M01 to interrupt programs depending on the channel-ba-


sed interface signal Optional stop.

Programming
Syntax:
M0 or M00
Special features and restrictions:
D You may program Program stop in the same block as other NC func-
tions. Only after all other programmed functions have been executed
does Program stop become effective.

3.3.2 Interrupt program conditionally (Cond. progr.- stop) M1, M01

Effect
D Interrupts the NC program and
D stops machine movements after executing the block if the channel-
based interface signal Optional stop is active.

The current channel status switches to NC Ready.


Program execution is restarted by NC-Start.

Programming
Syntax:
M1 or M01

Special features and restrictions:


D You may program Conditional program stop in the same block as
other NC functions. Only after all other programmed functions have
been executed does Conditional program stop become effective.
3-86 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

M-Codes M2, M02, M30

3.3.3 Terminate program (End of program) M2, M02, M30

Effect
Terminates a program.
If the program is a subroutine,
D the NC issues the auxiliary function (M2, M02 or M30),
D returns to the calling program and
D processes the calling program.
. Modal states that have been changed in the subroutine are not re-
set!

If the program is a main program,


D the NC sets channel-based interface signal Program end M30,
D cancels channel-based interface signal Program running,
D selects any Automatic gear range selection that may be active (but
the current gear range remains selected)
D switches to Direct speed programming (G97)
D activates all states defined in machine parameter 7060 00020, De-
fault status, for an M30 event,
D returns to the start of the main program, and
D waits for the next NC-Start.

Program execution is restarted by NC-Start.

Programming
Syntax:
M2 or M02 or M30

Special features and restrictions:


D Program the function in a separate program line.

CAUTION
Undefined default states may cause damage!
If certain states or functions are required after terminating a main
program, it must be ensured that the parameters of the M30
events init string are set correctly in MP 7060 00020! It must con-
tain all the functions that bring the NC into the required/desired
status after a main program is terminated.
In this regard, remember that modally acting functions remain ac-
tive even after the end of the program!

. For detailed information about the power-up states, see the Des-
cription of Functions.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-87
and Controls

M-Codes M3, M103, M203 M13, M113, M213

3.3.4 Spindle, clockwise rotation M3, M103, M203


Spindle, clockwise rotation and coolant ON M13, M113, M213

CAUTION
The described syntax applies only to the default setting of
machine parameter ranges 1040 001xx and 1040 002xx.
It is freely configurable and can therefore be different on your
machine. Therefore, the documentation provided by the machine
tool manufacturer always takes priority.
To determine whether the functions described herein actually
apply to your machine, contact your system administrator.

Effect
D Starts clockwise spindle rotation based on a tool-to-workpiece per-
spective.
D Cancels a position control that was activated by Align/position
spindle.
D Reserves the corresponding spindle(s) for the current channel.
. Spindle movement starts only if an S- or SSPG-word greater than 0
was programmed for the relevant spindle/spindle group in a pre-
vious or in the same block (see page 3-97).

Programming
Syntax:
M3 Acts on the 1st spindle group.
M103 Acts on the 1st spindle.
M203 Acts on the 2nd spindle.

M13 Acts on the 1st spindle group. In addition, coolant ON.


M113 Acts on the 1st spindle. In addition, coolant ON.
M213 Acts on the 2nd spindle. In addition, coolant ON.

Special features and restrictions:


D The appropriate function automatically reserves the corresponding
spindle(s) for the current channel. Use of reserved spindle(s) by an-
other channel is permitted only if function Spindle stop (see page
3-89) or SpAdmin (SPA, see page 4-126) is used for the correspon-
ding spindle(s).
D The appropriate function acts until a new state of motion is program-
med for the same spindle(s) (e.g. another direction of rotation, with/
without coolant, Spindle stop or Align spindle).
D Competing jobs between single spindles and spindle groups that are
programmed in the same block lead to a runtime error.
(Example: M3 and M104 are not permitted in the same block.)
D After the gear range is changed, the previously programmed direction
of rotation of a spindle is automatically restored.
3-88 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

M-Codes M4, M104, M204 M14, M114, M214

3.3.5 Spindle, counterclockwise rotation M4, M104, M204


Spindle, counterclockwise rotation and coolant ON
M14, M114, M214
CAUTION
The described syntax applies only to the default setting of
machine parameter ranges 1040 001xx and 1040 002xx.
It is freely configurable and can therefore be different on your
machine. Therefore, the documentation provided by the machine
tool manufacturer always takes priority.
To determine whether the functions described herein actually
apply to your machine, contact your system administrator.

Effect
D Starts counterclockwise spindle rotation based on a tool-to-work-
piece perspective.
D Cancels a position control that was activated by Align/position
spindle.
D Reserves the corresponding spindle(s) for the current channel.
. Spindle movement starts only if an S- or SSPG-word greater than 0
was programmed for the relevant spindle/spindle group in a pre-
vious or in the same block (see page 3-97).

Programming
Syntax:
M4 Acts on the 1st spindle group.
M104 Acts on the 1st spindle.
M204 Acts on the 2nd spindle.

M14 Acts on the 1st spindle group. In addition, coolant ON.


M114 Acts on the 1st spindle. In addition, coolant ON.
M214 Acts on the 2nd spindle. In addition, coolant ON.

Special features and restrictions:


D The appropriate function automatically reserves the corresponding
spindle(s) for the current channel. Use of reserved spindle(s) by an-
other channel is permitted only if function Spindle stop (see page
3-89) or SpAdmin (SPA, see page 4-126) is used for the correspon-
ding spindle(s).
D The appropriate function acts until a new state of motion is program-
med for the same spindle(s) (e.g. another direction of rotation, with/
without coolant, Spindle stop or Align spindle).
D Competing jobs between single spindles and spindle groups that are
programmed in the same block lead to a runtime error.
(Example: M3 and M104 are not permitted in the same block.)
D After the gear range is changed, the previously programmed direction
of rotation of a spindle is automatically restored.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-89
and Controls

M-Codes M5, M105, M205

3.3.6 Spindle stop M5, M105, M205

CAUTION
The described syntax applies only to the default setting of
machine parameter ranges 1040 001xx and 1040 002xx.
It is freely configurable and can therefore be different on your
machine. Therefore, the documentation provided by the machine
tool manufacturer always takes priority.
If you are not sure whether the functions described herein actually
apply to your machine, contact your system administrator.

Effect
D Stops spindle(s).
D Cancels any possibly active reservation of the given spindle(s) by the
active channel.
D Cancels a position control that was activated by Align/position
spindle.

Programming
Syntax:
M5 Acts on spindle group 1.
M105 Acts on the 1st spindle.
M205 Acts on the 2nd spindle.

Special features and restrictions:


D The appropriate function acts until a new state of motion is program-
med for the same spindle(s) (e.g. Spindle, counterclockwise/clock-
wise rotation or Align spindle).
D Competing jobs between single spindles and spindle groups that are
programmed in the same block lead to a runtime error.
(Example: M3 and M105 are not permitted in the same block.)
3-90 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

M-Codes M19, M119, M219

3.3.7 Align spindle / Position spindle M19, M119, M219

CAUTION
The described syntax applies only to the default setting of
machine parameter ranges 1040 001xx and 1040 002xx.
It is freely configurable and can therefore be different on your
machine. Therefore, the documentation provided by the machine
tool manufacturer always takes priority.
If you are not sure whether the functions described herein actually
apply to your machine, contact your system administrator.

Effect
The spindle is reserved for the current channel and positioned in a defi-
nable position using position control.
Positioning occurs
D at a standstill: as specified in parameter S-0-0154
of the drive
D with active rotation: retaining the direction of rotation.

Programming
Syntax:
M19 Spindle group 1: position all participating
spindles on their reference angle (drive para-
meter S-0-0153).
M119 1. Position second spindle on its reference
angle (S-0-0153).
M219 2. Position second spindle on its reference
angle (S-0-0153).
M19 S<Angle> Spindle group 1: position all participating
spindles on <Angle>.
M119 S1=<Angle> 1. Position second spindle on <Angle>.
M219 S2=<Angle> 2. Position second spindle on <Angle>.
<Angle> Desired absolute spindle position, in degrees.
Value range: 0_ Spindle position < 360_.
If another value is programmed for the position, it is auto-
matically converted to the given interval.
If the spindle is already in the given position, no motion is
executed.

Special features and restrictions:


D The appropriate function must not be programmed in the same block
as a competing spindle function (Spindle, counterclockwise/clock-
wise rotation, Spindle stop).
D If the S-word is required, it must be programmed in the same block.
D After the positioning procedure, the spindle remains in position con-
trol. Position control is automatically cancelled only by Spindle, co-
unterclockwise/clockwise rotation or Spindle stop.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-91
and Controls

M-Codes M19, M119, M219

D Competing jobs between single spindles and spindle groups that are
programmed in the same block lead to a runtime error.
(Example: M3 and M1119 are not permitted in the same block.)

Examples:
N60 M19 All the spindles of the 1st spindle group
: position themselves relative to their refer-
ence angle.
N70 M219 Only the 2nd spindle positions itself relative
: to its reference angle.
N80 M19 S180 All the spindles of the 1st spindle group
: position themselves to 180 degrees.
N90 M119 S1=370 1. spindle positions itself to 10 degrees.
:
N95 M19 S1=10 S2=20 If the 1st and 2nd spindle are assigned to
: the 1st spindle group:
1. the 1st spindle positions itself to 10, and
the 2nd spindle to 20 degrees.
All other spindles of the 1st spindle group
position themselves relative to their refer-
ence angle.
3-92 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

M-Codes M40, M140, M240

3.3.8 Automatic gear range selection M40, M140, M240

CAUTION
The described syntax applies only to the default setting of
machine parameter ranges 1040 001xx and 1040 002xx.
It is freely configurable and can therefore be different on your
machine. Therefore, the documentation provided by the machine
tool manufacturer always takes priority.
If you are not sure whether the functions described herein actually
apply to your machine, contact your system administrator.

Effect
The control automatically selects the suitable gear range from the ones
available according to the active speed.
In the event of overlapping speed ranges of the various gears, the con-
trol always selects the lower gear (with the higher motor speed).

Programming
Syntax:
M40 Automatic gear range selection for spindle group 1 ON.
M140 Automatic gear range selection for 1st spindle ON.
M240 Automatic gear range selection for 2nd spindle ON.

Special features and restrictions:


D Programming 0 for the speed has the effect that the current gear
range does not change.
D M40, M41-M44, M48, M140, M141-M144 and M148 act modally and
cancel each other mutually.
D M240, M241-M244 and M248 act modally and cancel each other mu-
tually.
D M30 selects any automatic gear range selection that may be active
(but the current gear range remains selected).
D Automatic gear range selection does not affect analog spindles.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-93
and Controls

M-Codes M41 - 44, M141 - 144, M241 - 244

3.3.9 Manual gear range selection M41 - 44, M141 - 144, M241 - 244

CAUTION
The described syntax applies only to the default setting of
machine parameter ranges 1040 001xx and 1040 002xx.
It is freely configurable and can therefore be different on your
machine. Therefore, the documentation provided by the machine
tool manufacturer always takes priority.
If you are not sure whether the functions described herein actually
apply to your machine, contact your system administrator.

Effect
Selects the corresponding gear range.
If a speed outside of the corresponding gear range speed spectrum is
programmed, the control issues the minimum/maximum speed of the af-
fected gear range.
Programming
Syntax:
M4<Stage> Gear range <Stage> for spindle group 1 ON.
M14<Stage> Gear range <Stage> for 1st spindle ON.
M24<Stage> Gear range <Stage> for 2nd spindle ON.
where:
<Stage> Input range: 1 - 4.

Special features and restrictions:


D M40, M41-M44, M48, M140, M141-M144 and M148 act modally and
cancel each other mutually.
D M240, M241-M244 and M248 act modally and cancel each other mu-
tually.
D Manual gear range selection does not affect analog spindles.
3-94 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

M-Codes M48, M148, M248

3.3.10 Disengage gear range M48, M148, M248

CAUTION
The described syntax applies only to the default setting of
machine parameter ranges 1040 001xx and 1040 002xx.
It is freely configurable and can therefore be different on your
machine. Therefore, the documentation provided by the machine
tool manufacturer always takes priority.
If you are not sure whether the functions described herein actually
apply to your machine, contact your system administrator.

Effect
Disengages the gear range.
The gear is then in idling mode.

Programming
Syntax:
M48 Disengage gear range stage for spindle group 1.
M148 Disengage gear range stage for 1st spindle.
M248 Disengage gear range stage for 2nd spindle.

Special features and restrictions:


D M40, M41-M44, M48, M140, M141-M144 and M148 act modally and
cancel each other mutually.
D M240, M241-M244 and M248 act modally and cancel each other mu-
tually.
D The functions do not affect analog spindles.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-95
and Controls

Feedrate/Speed F

3.4 Feedrate and Speed Programming

3.4.1 F-address F

Effect
Depending on the currently active G-function G93, G94, G95, the control
interprets F-addresses as
D interpolation time in seconds (see G93, page 3-70)
D feedrate in mm/min or inch/min (see G94, page 3-71)
D feedrate in mm/rev (see G95, page 3-74).

The following applies:


D F acts modally for G94 and G95.

CAUTION
The last F-word may change after a power-up, control reset or re-
set!
After the events listed above, the F-word defined in machine
parameter 7060 00020 or 7060 00010 is effective (default value: F0).
The specification whether G93, G94 or G95 is to be then active is
also stored there (default value: G94).
Therefore, ensure that the required feedrate has been
programmed before starting machining.

Programming
Syntax:
F<Value>
where:
<Value> Depends on the active G-function, interpreted as interpo-
lation time, feedrate or dwell time.

Special features and restrictions:


D The programmed path velocity can be suppressed using function
Test feed. This is controlled by channel IF signal qCh_TestFeed.
3-96 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Feedrate/Speed FA Omega

3.4.2 Velocity of asynchronous axes FA

Effect
All traversing movements of asynchronous axes programmed in the FA
block are traversed with the programmed velocity instead of in rapid tra-
verse.

CAUTION
Incorrect programming may cause machine damage!
The given velocity acts only in the current FA-block!
Programming asynchronous axes without reprogramming the
FA-word in a subsequent block will let the axes traverse in rapid
mode again!

Programming
Syntax:
FA<Value>
where:
<Value> Desired velocity.

Example:
N10 G1 G94 X200 Z300 F200 Feedrate of synchronous axes:
200 mm/min
N11 UA400 VA140 FA250 Asynchronous axes UA and VA tra-
verse at 250mm/min.
N12 UA0 WA10 Asynchronous axes UA and WA tra-
verse at rapid traverse again.

3.4.3 Omega address (feed) Omega

Effect
If only axes that are hidden for feedrate computing are to be moved in a
block (see FeedAd, page 4-41), their feedrate can be set using ad-
dress Omega.

Programming
Syntax:
Omega<Value>
where:
<Value> Desired feedrate.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-97
and Controls

Feedrate/Speed S, SSPG

3.4.4 Program spindle speed S, SSPG

Effect
When G97 is active, this specifies the desired
D speed of a single spindle (S...) or
D a complete group of spindles (SSPG...).

. The spindle reaches the programmed speed only if a spindle rota-


tion command (e.g. Clockwise rotation: M3; Counterclockwise ro-
tation: M4 exists).

Programming
Syntax:
S<Number>=<Value> Program the speed for a single spindle.
SSPG<Group>=<Value> Program the speed for a complete group of
spindles.
S<Value> Abbreviated notation for programming the
speed of the 1st spindle.
Acts only on the 1st spindle if it is not assi-
gned to any group of spindles using
MP 1040 00002 .
If this is not the case, this programs the
complete group of spindles that contains
the 1st spindle.

where:
<Number> Number of the spindle (spindle index).
Input range:
1 to the number of defined spindles (defined using
MP 1040 00001). Integer.
<Group> Number of the spindle group.
Input range: 1 - 4
<Value> Desired spindle speed (default unit: rpm).
Input value: 0.

Special features and restrictions:


D When G96 is active, an S-word is interpreted as the cutting speed.
For the syntax, see page 3-75.
D In conjunction with function Align spindle, an S-word is interpreted
as a positioning angle. For the syntax, see page 3-90.
D The speeds of several spindles / groups of spindles may be program-
med in the same block.
D The resulting speed depends on the spindle-specific override.
D The resulting speed may be limited by
D function SMin or SMax (see page 4-125)
D gear range stage limit values (MP 1040 00011, 1040 00012).
3-98 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Feedrate/Speed S, SSPG

D The maximum permitted speed of a group of -coupled spindles (syn-


chronously running spindles) depends on the NC-cycle time. The fol-
lowing applies: Smax [rpm] = 14400 / (MP 9030 00001 [ms])
D The set speed is in effect until it is overwritten by a new speed setting
for the same spindle(s).
After the control is powered up, S=0.

Example:
N10 G97 Activate speed programming.
N20 SSPG1=1000 Set the speed of all the spindles of the 1st
: group of spindles to 1000 rpm.
N50 S1=2000 S2=60 Set the speed of the 1st spindle to 2000
: rpm.
Set the speed of the 2nd spindle to 60 rpm.
N80 S3=2000 Set the speed of the 3rd spindle to 2000
: rpm.
N90 S1500 Set the speed of the 1st spindle to 1500
: rpm.
If the 1st spindle has been assigned to a
group of spindles, the speed setting applies
to the complete group of spindles.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 3-99
and Controls

Tool Compensation D

3.5 Tool Compensation


3.5.1 D-correction D

Effect
The D-correction calls tool compensation values that are stored in XML-
D-correction tables in the IndraMotion MTX. A correction table can con-
tain a maximum of 99 data records.
Each data record contains the following correction values:
D 3 tool lengths L1, L2, L3,
D tool edge radius RAD,
D tool edge position ORI.

The D-correction is equally suitable for drilling, milling, lathing and


cross-staff tools. With a total of 3 offset values (L1, L2 and L3), you can
perform both constant three-dimensional tool offsets for a tool and pa-
rallel length compensations of 3 different tools as a maximum.
A D-correction table is activated using function DcTSel (DCS); then a
correction block is selected from the max. 99 data records using NC
command D.
The correction values go into effect if tool compensation G47 (tool length
and tool edge position), cutter path compensation G41/G42 or
G141/G142 (tool radius) is active. They are additively superimposed by
the active selected correction values of external tool compensation ED.

The following applies:


D The preselected tool record has a modal effect. New programming
deletes the preselected tool record that was previously active.
D A D-correction may be programmed in the same block as other path
conditions, traversing movements or auxiliary functions.
D The tool compensation is calculated only when the corresponding NC
function has been activated: G47, G41, G42, G141, G142.

Programming
Syntax:
D<No. Tool record> Preselect the tool compensation
record from the active D-correction
table
D0 Deselect the tool compensation
record without selecting a new
one.
where:
<No. Tool record> Number of the correction data record.
Input range: 1 - 99.

Example:
N10 D7 Preselect correction values for tool record 7.
:
3-100 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Tool Compensation ED

3.5.2 ED-correction ED

Effect
External tool compensation (ED-correction) calls correction values for a
maximum of 16 tool edges. The correction values can be written using
program module MT_TCorr by the PLC or using a parts program with
CPL command DCT.
Each of the 16 data records contains the following correction values:
D 3 tool lengths L1, L2, L3,
D tool edge radius RAD,
D tool edge position ORI.

The ED-correction is equally suitable for drilling, milling, lathing and


cross-staff tools. With a total of 3 offset values (L1, L2 and L3), you can
perform both constant three-dimensional tool offsets for a tool and pa-
rallel length compensations of 3 different tools as a maximum.

NC command ED is used to select a correction record from the max. 16


data records.
The correction values go into effect if tool compensation G47 (tool length
and tool edge position), cutter path compensation G41/G42 or
G141/G142 (tool radius) is active. They are additively superimposed by
the active selected correction values of the D-correction.

The following applies:


D The preselected tool edge has a modal effect. New programming de-
letes the preselected tool edge that was previously active.
D An ED-correction may be programmed in the same block as other
path conditions, traversing movements or auxiliary functions.
D The tool compensation is calculated only when the corresponding NC
function has been activated: G47, G41, G42, G141, G142.
D The preselected tool edge can be output on the PLC interface of the
corresponding channel: iCh_ActFunc1 - 24

Programming
Syntax:
ED<No. tool edge> Preselect the correction record
ED0 Deselect the correction record wi-
thout selecting a new one.
where:
<No. tool edge> Number of the tool edge.
Input range: 1 - 16.

Example:
N10 ED7 Preselect correction values for tool edge 7.
:
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-1
and Controls

NC Functions

4 NC Functions with High-Level Language Syntax


4.1 Overview
The control has a variety of NC functions. In addition to the commands
that are specified within the DIN 66025, this includes important supple-
ments in the area of G-codes and additional high-level language-type
syntax elements that are described in this chapter.

D NC-functions with high-level language syntax:


In NC-functions with high-level language syntax, the meaning of the
function can generally be seen in the name (e.g. Scale). Usually the
following variants of equal importance exist:
D Long form with no case sensitivity.
To improve readability in this manual, the first letter of the compo-
site partial words is capitalized. Example: KvProg
D Abbreviation, consisting of 3 capital letters (4 capital letters in ex-
ceptions).
Example: abbreviation of KvProg: KVP
The corresponding abbreviation is also shown in the process data
display of the active modal NC functions.
The following syntax descriptions show both variants.
. A tabular overview of all NC-functions can be found in the Appen-
dix, A-2ff.
In addition, all NC-functions are in the index starting on page A-49.

Used notations
The following notations are used for the syntax of NC functions in this
manual:
FontCourier bold or Courier:
Character strings in this font must be programmed as shown below.
Example: G0(POL)
Angle brackets < >
indicate a wildcard for an expression/parameter to be programmed. The
wildcard is written in italics.
Example: <Axis1>
Curly brackets { }
indicate an optional expression/parameter.
Such syntax elements may, but do not have to be specified.
Example: G0{({POL,}{<Par1>})}
Character |
separates possible parameters that cannot be used simultaneously (al-
ternative parameters).
Example: G0{({POL,}{NIPS|IPS1|IPS2|IPS3})}
4-2 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions Area, ARA

4.2 Area Monitoring Area, ARA

Effect
Defines, activates or deactivates up to 10 rectangular, two-dimensional
dead or working ranges with axis-parallel boundaries.
D Dead ranges:
May be neither crossed nor contacted incl. their boundaries during
a traversing movement.
D Working areas:
May not be exited incl. their boundaries during a traversing move-
ment.

. Default data of all areas are defined using machine parameter


group MP 8002.

Programming: Activate/deactivate individually or all monitoring areas


together.
Syntax:
Area(<ANo>,<Sta>)

Abbreviation: ARA(...)
where:
<ANo> Area number.
Integer. Input range: -1, 1...10.
-1: Activate/deactivate all areas.
<Sta> Desired monitoring status.
0: Deactivate monitoring.
1: Activate monitoring.

Programming: Define, activate, deactivate an individual monitoring area.


Syntax:
Area(<BNr>,<Sta>{,<Mod>,{<P1>},{<P2>},{<D1>},{<D2>}})

Abbreviation: ARA(...)
where:
<ANo> Area number.
Integer. Input range: 1...10.
<Sta> Desired monitoring status.
0: Deactivate monitoring of area <ANo>.
1: Activate monitoring of area <ANo>.
<Mod> 0: Area <ANo> is not used.
1: Area <ANo> is a dead area.
2: Area <ANo> is a working area.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-3
and Controls

NC Functions Area, ARA

<P1> Position in the machine coordinate system.


Specifies the position values of the center point of the
area, based on the first system axis participating in the
area (defined using MP 8002 00001).
See the following example.
Programming unit as for the axis coordinates.
<P2> Position in the machine coordinate system.
Specifies the position values of the center point of the
area, based on the second system axis participating in
the area (defined using MP 8002 00002). See the follo-
wing example.
Programming unit as for the axis coordinates.
<D1> Specifies the length of the area, based on the first sy-
stem axis participating in the area (defined using MP
8002 00001). See the following example.
Programming unit as for the axis coordinates.
<D2> Specifies the length of the area, based on the second
system axis participating in the area (defined using
MP 8002 00002). See the following example.
Programming unit as for the axis coordinates.

. Unprogrammed values are retained if they have been entered once


in the program execution.
If they were not yet entered during the program execution, the con-
trol uses the corresponding values from machine parameter group
8002.

Special features and restrictions:


D All system axes that participate in the individual areas must be defi-
ned in MP 8002 00001 and MP 8002 00002.
D In order to be able to influence areas using Area, MP 8002 00032
must be set accordingly.
D The function requires referenced axes.
D When an area is activated, the associated axes must lie in the current
channel.
D Influencing an area using Area has an effect only in the channel in
which Area is programmed.
If the axes of an area are transferred to another channel, this area is
assigned the default values of the target channel as preset in ma-
chine parameter group 8002 and the area is deactivated.
Any values programmed using Area in the source channel are not
transferred.
D In jog mode: axes that are moved using the handwheel are not moni-
tored.
D In jog mode: only one of the axes spanning a dead area may be jog-
ged at a time.
D Area violations in jog mode result in a warning. The affected axis does
not move and can be jogged only in the opposite direction.
4-4 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions Area, ARA

Example:
N100 Area(4,0,,100,200) Deactivate area 4 and set the center
point of the area to the given machine
coordinates (100,200).
The area lengths remain unchanged.

<D1>:
Second system Area length in
axis participating the direction of
Y
in the area the first system
(defined in MP axis
8002 00002). participating in
the area.

Area 4

<D2>:
Center point (100,200) Area length in the
direction of the
<P2>: 200 second system
Area center
axis participating
point position in
in the area.
the direction of
the second
system axis
participating in
the area.

X
M 100 First system axis
<P1>: participating in the
Area center point area (defined in
position in the direction MP 8002 00001).
of the first system axis
participating in the area.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-5
and Controls

NC Functions ASPCLR

4.3 Asynchronous Subroutines: Log off ASPCLR


Effect
Logs off an asynchronous subroutine in the current channel.
Logged-off subroutines can be neither activated nor deactivated.
. To log on asynchronous subroutines that have been logged off,
see function ASPSET, page 4-8.

. You can find extensive information regarding the use and parame-
ter settings of asynchronous subroutines in the Description of
Functions.

Programming
Syntax:
ASPCLR(<Up-Nr>)
where:
<SR No> Number of the subroutine.
Input value: 1 - 8. Integer.

Special features and restrictions:


D The corresponding subroutine must be logged on in the target chan-
nel (see ASPSET, page 4-8).
D To temporarily deactivate a subroutine, see function ASPDIS, page
4-6.
4-6 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions ASPDIS ASPENA

4.4 Asynchronous Subroutines: Switch off ASPDIS


Effect
Deactivates an asynchronous subroutine in the current channel.
A deactivated subroutine is not called if the relevant event occurs.
. You can find extensive information regarding the use and parame-
ter settings of asynchronous subroutines in the Description of
Functions.

Programming
Syntax:
ASPDIS(<Up-Nr>)
where:
<SR No> Number of the subroutine.
Input value: 1 - 8. Integer.

Special features and restrictions:


D The corresponding subroutine must be logged on in the target chan-
nel (see ASPSET, page 4-8).
D To activate a deactivated subroutine, see function ASPENA , page
4-6.

4.5 Asynchronous Subroutines: Switch on ASPENA

Effect
Activates an asynchronous subroutine in the current channel.
Only activated subroutines can be called if the relevant event occurs.
. You can find extensive information regarding the use and parame-
ter settings of asynchronous subroutines in the Description of
Functions.

Programming
Syntax:
ASPENA(<Up-Nr>)
where:
<SR No> Number of the subroutine.
Input value: 1 - 8. Integer.

Special features and restrictions:


D The corresponding subroutine must be logged on in the target chan-
nel (see ASPSET, page 4-8).
D To deactivate a subroutine, see function ASPDIS, page 4-6.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-7
and Controls

NC Functions ASPRTP

4.6 Asynchronous Subroutines:


Define Point of Return to Path ASPRTP
Effect
Defines whether the control, at the end of an asynchronous subroutine,
is to position on
D the starting point
D the end point, or
D the point of interruption
of a traversing block that may have been interrupted.
If no traversing block was active at the time of interruption, the control
always positions on the last active coordinates.
. You can find extensive information regarding the use and parame-
ter settings of asynchronous subroutines in the Description of
Functions.

Programming
Syntax:
ASPRTP(<Up-No>,<Point>)
where:
<SR No> Number of the subroutine.
Input value: -1; 1 - 8. Integer.
-1: Define the desired point of return to path for all
asynchronous subroutines of the current channel.
<Point> Desired point of return to path:
1: Starting point
2: End point
3: Interruption point

Special features and restrictions:


D The desired point of return to path that is set is cleared by a control
reset or M30.
D Any correction modifications made within an asynchronous subrou-
tine are automatically taken into account in the internal calculation of
the required point of return to path.
D Function REPOSTP (see page 4-115) can be used to temporarily sup-
press the defined point of return to path in the asynchronous subrou-
tine.
4-8 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions ASPSET

4.7 Asynchronous Subroutines: Log on ASPSET


Effect
Logs on an asynchronous subroutine in the current channel and activa-
tes it (for activation, also see function ASPENA, page 4-6).
Only subroutines that have been logged on and activated may be used.
. To log off asynchronous subroutines that have been logged on,
see function ASPCLR, page 4-5.

. You can find extensive information regarding the use and parame-
ter settings of asynchronous subroutines in the Description of
Functions.

Programming
Syntax:
ASPSET(<Up-Nr>,<Up-Name>{,<Flags>})
where:
<SR No> Number of the subroutine.
Input value: 1 - 8. Integer.
<Up-Name> Name of the subroutine; with or without path information.
If the path is missing, the file is searched according to
MP 3080 00001 (search path for subroutines).
<Flags> Switch with which the behavior after the call can be in-
fluenced:
00 neither a linking procedure nor an automatic start.
10 a linking procedure, but not an automatic start.
01 not a linking procedure, but an automatic start.
11 a linking procedure and an automatic start.
Example:
:
N30 ASPSET(1,ASUP1,10) Log on program ASUP1 as the first asyn-
: chronous subroutine in the active channel.
After it is called (e.g. via the interface sig-
nal), it is if required automatically linked
and started explicitly using NC-Start.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-9
and Controls

NC Functions ASPSTA

4.8 Asynchronous Subroutines: Triggering via Program ASPSTA


Effect
Calls an asynchronous subroutine program-controlled in any chan-
nel.
. You can find extensive information regarding the use and parame-
ter settings of asynchronous subroutines in the Description of
Functions.

Programming
Syntax:
ASPSTA(<Up-No>{,<Channel-No>})
where:
<SR No> Number of the subroutine.
Input value: 1 - 8. Integer.
<Channel-No> Target channel in which <Up-No> is to be called.
If it is not programmed,<Up-No> is called in the current
channel.

Special features and restrictions:


D Asynchronous subroutines may not be nested.
D The called subroutine must be logged on in the target channel (see
ASPSET, page 4-8).
D The called subroutine must not be deactivated in the target channel
(see ASPDIS , page 4-6 / ASPENA , page 4-6).
4-10 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions AssLogName, ALN

4.9 Assign Logical Axis Name AssLogName, ALN

Effect
Assigns a new logical axis name to a synchronous axis in the calling
channel. The old logical axis name becomes invalid.

. For detailed information about the Axis transfer function, see the
Description of Functions.

Programming
Syntax:
AssLogName(<PAN> | <PAI> | <LAN>,<LANnew>
{,<PAN> | <PAI> | <LAN>,<LANnew>}...)

Abbreviation: ALN(...)
where:
<PAN> Physical axis name.
Specifies the axis that is to be renamed in the current
channel.
<PAI> Physical axis index.
Same effect as <PAN>.
<LAN> Logical axis name.
Same effect as <PAN>.
<LANnew> New logical axis name.
The axis entered using <PAN>, <PAI> or <LAN> receives
the logical name <LANnew> in the current channel.
<LANnew> must have been defined in MP 7010 00010
(Logical axis designation) or MP 7010 00020 (Optional
axis designation).

Special features and restrictions:


D An axis to be renamed must be at a standstill. If this is not the case, the
control generates an error message and terminates the program.
D Axis positions in the same block must always be programmed accor-
ding to the expression AssLogName(...).

Example:
:
N030 ALN(YP,X,3,Y,B,Z) Physical axis YP is assigned the logical axis
: name X, the 3rd physical axis is assigned
the logical name Y, and logical axis B is as-
signed the logical name Z.
Programming B subsequently will generate
a runtime error.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-11
and Controls

NC Functions ATCAL

4.10 Calibration of Axis Kinematics: Optimize Parameters ATCAL


Effect
Combined with function Calibration of axis kinematics, this function is
used to optimize axis kinematics-specific length and angle parameters.
These data are different for every axis transformation type and are con-
tained in MP 1030 00140 for every axis transformation. As a rule, they
must be read using function ATGET (see page 4-14) before optimization
and transferred back to the NC using function ATPUT (see page 4-15)
after optimization.
. You can find extensive information regarding the calibration of axis
kinematics in the Description of Functions.

Programming
Syntax:
ATCAL(<File>,<OptData>,<Mask>{,<Info>}{,<NumIt>})
where:
<File> Name of the calibration file; with or without path information.
If the path is missing, the file is searched according to
MP 3080 00001 (search path for subroutines).
<File> contains data that are required for optimization. For
more information, see the Description of Functions.
<OptData> Permanent, global or local CPL array.
Type: double. Dimension: min. 16.
After calculation, the array contains a parameter block with
the optimized length and angle parameters.
The sequence of the individual variables (index 1 to 16) cor-
responds to the element-index of MP 1030 00140. The va-
lues have the same unit as the individual parameters in
MP 1030 00140.
<Mask> CPL variable. Type: Integer.
Bit mask which is used to determine the individual parame-
ters to be optimized. Example:
Array <OptData> before optimization
Index: 1 2 3 4 5 6 7 8 ... 15 16

Bit mask: 1 = Optimize individual parameter


1 1 1 0 1 0 0 0 ... 0 0
Priority: 1 2 4 8 16 32 64 128 ...
req. value in
<Mask>: 1 + 2+ 4 + 16 = 23

Array <OptData> after optimization


Index: 1 2 3 4 5 6 7 8 ... 15 16

: optimized individual parameter


4-12 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions ATCAL

<Info> Permanent, global or local CPL array.


Type: double. Dimension: min. 4.
After optimization, it contains the following data:
<Info>[1] Value of the criterion function (quadratic devi-
ation) before optimization. Unit: mm.
<Info>[2] Value of the criterion function (quadratic devi-
ation) after optimization. Unit: mm.
<Info>[3] Max. deviation before optimization (in mm).
<Info>[4] Max. deviation after optimization (in mm).
<NumIt> Maximum number of iteration steps to optimization.
If this is not entered, or has a value of -1, iteration is termi-
nated only if the deviation of two subsequently calculated
parameter blocks drops below a sufficiently low internal NC
threshold (a relevant deviation no longer exists).
If 1 is entered, a linear computation of adjustment is requi-
red.

Example:
01 DIM PAR!(16) Dimension a local CPL array with 16
fields of type Double (for the opti-
mized length/angle parameters).
02 DIM GA!(4) Dimension a local CPL array with 4
fields of type Double (for criterion and
deviation).
03 MASK%=2+4+32 Optimization of individual parameters
with field indices 2, 3 and 6.
N4 ATCAL(CL.TXT,[PAR!], Start optimization.
[MASK%],[GA!],-1)
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-13
and Controls

NC Functions ATFWD

4.11 Calibration of Axis Kinematics: Convert Parameters ATFWD


Effect
Together with function Calibration of axis kinematics, this function is
used to convert real axis positions to the coordinates of a coordinate sy-
stem generated by axis transformation. This procedure is also called
forwards transformation.
. You can find extensive information regarding the calibration of axis
kinematics in the Description of Functions.

Programming
Syntax:
ATFWD(<Coord>,<AxCoord>{,<ParData>})
where:
<Coord> Permanent, global or local CPL array.
Type: double. Dimension: at least as large as the number of
channel coordinates of the coordinate system generated by
axis transformation.
The individual variables of the array receive the resulting
channel coordinates in the transformed coordinate system
after conversion.
<AxCoord>Permanent, global or local CPL array.
Type: double. Dimension: at least as large as the number of
axes in the current channel.
The variables of the array must contain the real axis posi-
tions of all the channel axes participating in the axis transfor-
mation.
<ParData> Permanent, global or local CPL array.
Type: double. Dimension: min. 16.
The array must contain a parameter block with all length and
angle parameters for an axis transformation.
The sequence of the individual variables (index 1 to 16) cor-
responds to the element-index of MP 1030 00140. The va-
lues have the same unit as the corresponding individual
parameters in MP 1030 00140.
If this is not programmed, the parameter block of the cur-
rently active axis transformation is used.
If two axis transformations are active in the control at the
same time (AT1, AT2; see function Coord, page 4-30 ff.),
the AT2 data are used.

Special features and restrictions:


D If <ParData> was not programmed and no axis transformation is ac-
tive, a runtime error is issued.
4-14 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions ATGET

4.12 Calibration of Axis Kinematics: Read Parameter from NC ATGET


Effect
Combined with function Calibration of axis kinematics, this function is
used to read axis kinematics-specific length and angle parameters.
These data are different for every axis transformation type and are con-
tained in MP 1030 00140 for every axis transformation. As a rule, they
must be read before optimization (see function ATCAL, page 4-11) and
transferred back to the NC using function ATPUT (see page 4-15) after
optimization.
. You can find extensive information regarding the calibration of axis
kinematics in the Description of Functions.

Programming
Syntax:
ATGET(<ParData>{,<AxTransfNo>})
where:
<ParData> Permanent, global or local CPL array.
Type: double. Dimension: min. 16.
After the function is executed, the array contains a para-
meter block with all length and angle parameters of an
axis transformation defined using <ATrafNr>.
The sequence of the individual variables (index 1 to 16)
corresponds to the element-index of MP 1030 00140.
The values have the same unit as the individual parame-
ters in MP 1030 00140.
<AxTransfNo>Number of the axis transformation to be read.
If this is not programmed, the data of the currently active
axis transformation are read.
If two axis transformations are active in the control at the
same time (AT1, AT2; see function Coord, page 4-30
ff.), the AT2 data are used.

Special features and restrictions:


D If <ATrafNr> was not programmed and no axis transformation is ac-
tive, a runtime error is issued.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-15
and Controls

NC Functions ATPUT

4.13 Calibration of Axis Kinematics: Write Parameter to NC ATPUT


Effect
Combined with function Calibration of axis kinematics, this function is
used to overwrite all axis kinematics-specific length and angle parame-
ters of an axis transformation.
These data are different for every axis transformation type and are con-
tained in MP 1030 00140 for every axis transformation. As a rule, they
must be read before optimization (see functions ATCAL, page 4-11 and
ATGET, page 4-14) and transferred back to the NC using function AT-
PUT after optimization.
. You can find extensive information regarding the calibration of axis
kinematics in the Description of Functions.

Programming
Syntax:
ATPUT(<ParData>{,<AxTransfNo>})
where:
<ParData> Permanent, global or local CPL array.
Type: double. Dimension: min. 16.
The array must contain a parameter block with all length-
and angle parameters for an axis transformation defined
using <AxTrafoNr>.
The sequence of the individual variables (index 1 to 16)
corresponds to the element-index of MP 1030 00140.
The values have the same unit as the corresponding indi-
vidual parameters in MP 1030 00140.
<AxTransfNo>Number of the desired axis transformation whose para-
meter block is to be written to MP 1030 00140.
If this is not programmed, the data of the active axis trans-
formation are overwritten.
If two axis transformations are active in the control at the
same time (AT1, AT2; see function Coord, page 4-30
ff.), the AT2 data are modified.

Special features and restrictions:


D If <ATrafNr> was not programmed and no axis transformation is ac-
tive, a runtime error is issued.
D Executing function ATPUT requires an NC user level that permits the
overwriting of machine parameters.
D The written parameter block becomes active after
D a system reset and
D reprogramming of COORD(<ATransfNo>).
4-16 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions AUXFUNC

4.14 Execute Active Auxiliary Functions of all Groups AUXFUNC


Effect
Executes the currently active channel-specific and cross-channel auxi-
liary functions of all existing auxiliary function groups.
The function is relevant in connection with NC program restart (e.g. after
processing termination) to restore all auxiliary function states at a certain
parts program position.

For example, if a parts program is terminated during processing, it may


be possible to use NC program restart to restart processing at the block
that was being processed at the time of interruption.
Although the parts program is restarted at the beginning using NC pro-
gram restart, processing on the machine starts at the defined program
block.
Since the control neither interpolates nor issues programmed auxiliary
functions during NC program restart, all auxiliary functions states must
be restored at the end of the NC program restart.

. You can find extensive information regarding the use and parame-
ters of auxiliary functions in the Description of Functions.

Programming
Syntax:
AUXFUNC

Example:
N100 T102 Select tool T102.
N110 M6 Install tool T102.
:
N150 M3 Switch on 1st spindle / spindle group. Clockwise
: rotation.
... Program termination in N160...
- T102 and M3 were active.
- T102 is installed. The tool position is not changed.
The program is then reselected and runs via NC program restart up to
and including N150 without traversing movements. Programmed auxi-
liary functions are activated but not output.
Before N160 is processed, AUXFUNC is used now to execute the cur-
rently active channel-specific and cross-channel auxiliary functions of
all existing auxiliary function groups.
In the example, AUXFUNC has the following effects:
- Activate tool number T102 (tool is still installed).
- Switch on 1st spindle / spindle group with clockwise rotation.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-17
and Controls

NC Functions AxAcc, AAC

4.15 Change Maximum Axis Acceleration AxAcc, AAC


Save Maximum Axis Acceleration AxAccSave, AAS

Effect
D AxAcc:
temporarily changed the upper limits of the axis accelerations.
The function overrides the maximum axis acceleration values from
the machine parameters with the programmed values.
D AxAccSave:
saves the current maximum acceleration values of all axes to an inter-
nal memory.
This internal memory is preinitialized with the values from the ma-
chine parameters whenever the program is selected.

Programming
Syntax:
AxAccSave Temporarily buffers the current maximum ac-
celeration values.
Abbreviation: AAS
AxAcc(<Values>) Change the maximum axis accelerations.
AxAcc or Reactivate axis accelerations that were sa-
AxAcc(1) ved earlier using AxAccSave.
AxAcc() or Reactivate axis accelerations from the ma-
AxAcc(0) chine parameters.
Abbreviation: AAC(..)
where:
<Values> Axis name and acceleration value.
Entries for several axes are separated by commas.
Depending on the active measuring unit (G71/G70), the
control interprets the programmed data as 1000 inch/s2 or
m/s2.

Special features and restrictions:


D If both a physical and a logical axis of the active channel exist under
the same name in the system, the acceleration of the logical axis is
always influenced.
4-18 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions AxAcc, AAC

Example:
Starting situation: The value of 8.0 m/s2 is preassigned to axes X through
Z in the machine parameters.
:
N40 AAC(X1.0,Z2.1) Max. acceleration for X-axis: 1.0 m/s2,
: Max. acceleration for Z-axis: 2.1 m/s2.
: The max. acceleration of the Y-axis is unchan-
: ged (8.0 m/s2).
N80 AxAccSave Temporarily buffer all currently active maximum
: acceleration values.
N90 AxAcc() Reactivate the values from the machine para-
: meters:
: Max. acceleration for X-axis: 8.0 m/s2
: Max. acceleration for Y-axis: 8.0 m/s2
: Max. acceleration for Z-axis: 8.0 m/s2
N150 AxAcc(Y5) Max. acceleration for Y-axis: 5.0 m/s2.
: The max. accelerations of the x- and Z-axis are
: unchanged .
N200 AxAcc Reactivate the values saved using AxAc-
: cSave:
: Max. acceleration for X-axis: 1.0 m/s2
Max. acceleration for Y-axis: 8.0 m/s2
Max. acceleration for Z-axis: 2.1 m/s2
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-19
and Controls

NC Functions AxCouple, AXC

4.16 Axis Coupling AxCouple, AXC

Effect
Axis coupling is used to create a specific relationship between the move-
ment of a synchronous master axis and one or more (max. 7) synchro-
nous slave axes.
If the master axis traverses, all the slave axes move automatically accor-
ding to their own defined relationship to the master axis. The combina-
tion of the master and all participating slave axes is also called a group
of coupled axes.

Possible relationships between the master and a slave axis:


D The command positions of the master axis are transformed using a
constant offset to the corresponding command positions of the
slave axis (see formula 1).
This can be used to offset the slave axis by any constant path in the
positive or negative traversing direction compared to the master axis.
D The command positions of the master axis are transformed using a
constant coupling factor to the corresponding command positions
of the slave axis (see formula 1).
This can be used to move the slave axis in a certain relationship com-
pared to the master axis.
D The command positions of the master axis are transformed using a
(coupling) table to any corresponding command positions of the
slave axis. Here, support points that provide the corresponding slave
axis position for a master axis position and if required a master
axis offset are stored in the table (see formula 2).
The control can determine positions between individual support
points using linear interpolation or with the cubic spline function.

Formula 1 (for linear coupling):


p s = pm * k + o
Offset
Coupling factor

Formula 2 (for any coupling):


o
ps = f (p - p ) * k + o
m m

Offset
Coupling factor
Master axis offset
Coupling function (in coupling table format)

All listed relationships can be combined in any way.


In this way, parallel axes (e.g. for machining tables arranged in parallel)
as well as electronic gears (e.g. 1 rotation of the master axis = 10 rota-
tions of the slave axis) can be implemented very easily.
4-20 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions AxCouple, AXC

The following applies:


D All axes belonging to a group of coupled axes must be in the same
channel.
D Several groups of coupled axes within a channel are permitted.

. For detailed information about the Axis coupling function, see


the Description of Functions.
You can also find information about the coupling table required for
any couplings there.

Programming
Syntax:
AxCouple(<M><Variant>,<S>({<SO>},{<SF>}{,{<MO>},<Tab>}){,...})
AxCouple() or Clear all the groups of coupled
AxCouple(0) axes in the current channel.
Abbreviation: AXC(..)
where:
<M> Logical address of the master axis.
<Variant> 0 Generate a new group of coupled axes
1 Change a group of coupled axes
(add new slave axes or change a coupling-
designation)
-1 Delete slave axis or completely cancel group of cou-
pled axes
<S> Logical address of the slave axis.
<SO> Offset of the slave axis.
If this is not programmed, <SO> = 0.
<SF> Coupling factor of the slave axis.
If this is not programmed, <SF> = 1.
<MO> Master axis offset.
Relevant only for any coupling (see formula 2 above). If
this is not programmed, <MO> = 0.
<Tab> Name of the coupling table of the corresponding slave
axis. Relevant only for any coupling (see formula 2
above).

Examples:
N100 AXC(Z0,A(4,2),B(2,1)) Generate a group of coupled
: axes.
: Z: master axis,
: A/B: slave axes.
Both slave axes run with li-
near coupling.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-21
and Controls

NC Functions AxCouple, AXC

N200 AXC(X0,A(4,2),B(,0.5,,T_B)) Generate a group of coupled


: axes.
: X: master axis,
A/B: slave axes.
Slave axis A runs with linear
coupling, slave axis B with
any coupling.

: Slave axes A and B are deleted


N100 AXC(Z-1,A(),B()) from the Z group of coupled
: axes.
N200 AXC(Z-1) The entire Z group of coupled
: axes is deleted.

CAUTION
The function triggers a traversing movement of all the slave axes
programmed in this block!
They traverse to their specific coupling position (reference value)
defined by the position of the master axis and the coupling charac-
teristics.

Special features and restrictions:


D All axes participating in a group of coupled axes must be synchronous
axes, at least during the axis coupling.
Asynchronous axes or Hirth axes are not permitted.
D Programming a traversing motion of slave axes is not permitted; this
leads to an error message.
D A slave axis cannot simultaneously be a master axis in another group
of coupled axes.
D The end of program does not automatically disband a group of cou-
pled axes.
D If the master axis is a modulo axis, the slave must also be a modulo
axis in the case of a linear coupling relationship.
D To allow axis-by-axis traversing to the reference point, the group of
coupled axes must be opened.
D The permitted traversing range of the master axis can be reduced by
coupled slave axes, (e.g. if the slave axis attains its end ranges more
quickly than the master axis or if the traversing range of the slave axis
is less than that of the master axis).
D If limit switches have been suppressed for the master and/or slave
axis, no limit switches are effective for the entire group of coupled
axes.
D The maximum dynamics of the weakest axis determines the maxi-
mum dynamics of the entire group of coupled axes.
D Locking axes when a group of coupled axes is active is prohibited.
D Axes coupled in test mode must be uncoupled before test mode is
switched off.
4-22 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions AxisToSpindle, ATS

4.17 Switch off C-Axis Mode for Spindles AxisToSpindle, ATS

Effect
Switches a spindle that is in C-axis mode (see page 4-135) to spindle
mode.

. For detailed information about the Axis transfer function, see the
Description of Functions.

Programming
Syntax:
AxisToSpindle(<PAN> | <PAI>{,<PAN> | <PAI>}...)

Abbreviation: ATS(..)
where:
<PAN> Physical axis name.
Specifies the spindle that is to be switched from C-axis
mode back to spindle mode.
<PAI> Physical axis index.
Same effect as <PAN>.

Special features and restrictions:


D A given axis must be at a standstill and must not belong to an axis
group.
If this is not the case, the control generates an error message and ter-
minates the program.
D Axis positions in the same block must always be programmed accor-
ding to the expression AxisToSpindle(...).

Example:
:
N030 ATS(CH) The physical axis CH (i.e. the spindle with
: the name CH during axis operation) is swit-
ched to spindle operation.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-23
and Controls

NC Functions BcsCorr, BCR

4.18 Placement: BcsCorr, BCR


Workpiece Position Compensation
Effect
Used as a spanning compensator.
Placement Workpiece position compensation can shift and orientate
the workpiece coordinate system anywhere in space. Workpiece posi-
tion compensation has an effect on the coordinates with the meanings
x, y and z in the corresponding channel .
The set-up effort is significantly reduced because the workpiece posi-
tion is measured after spanning and taken into account using workpiece
position compensation.
Since there are 3 degrees of freedom for orientation, every orientation
can be represented by 3 consecutive basic rotations. For the sake of re-
adability, the following figure shows only the basic rotation around the
Z-coordinate:

Y X
YB Angle1
WCS
Zero offset
DY with coordinate rotation

XB
BCS DX

. Placement Inclined plane (see page 3-81) is functionally identi-


cal. A representation of all 3 basic rotations can also be found
there.

Additional placements (e.g. Inclined plane) have an additive effect.


Workpiece position compensation is located before Inclined plane in the
chain of calculation:

+ZW2
+ZW1 WCS2
+ZB +YW2
WCS1
+YB

+YW1
+XW2

+XW1

BCS +XB
BCS: Basic workpiece coordinate system
WCS1:Workpiece coordinate system, generated by workpiece position
compensation
WCS2:Workpiece coordinate system, generated by Inclined plane
4-24 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions BcsCorr, BCR

Programming
Syntax:
BcsCorr({<XW -Offset>}{,{<YW -Off- Workpiece position
set>}{,{<ZW -Offset>}{,{<Angle1>} compensation ON.
{,{<Angle2>}{,{<Angle3>}}}}}})

BcsCorr() or Workpiece position


BcsCorr(0) compensation OFF.
Abbreviation: BCR(..)

where:
<XW -Offset>: Offset value in main coordinate direction
<YW -Offset>: Offset value in secondary coordinate direction
<ZW -Offset>: Offset value in normal coordinate direction
<Angle1>: Angle of rotation around the Z-coordinate.
Value range: 0 <Angle1> < 360 degrees
<Angle2>: Angle of rotation around the Y-coordinate.
Value range: 0 <Angle2> < 180 degrees
<Angle3>: Angle of rotation around the Z-coordinate.
Value range: 0 <Angle3> < 360 degrees

Example:
N70 G40 Cutter path compensation OFF.
N80 BCR(50,300,10,1.23) Workpiece position compensation ON.
: The zero point of the new workpiece
: coordinate system lies on X50 Y300 and
: Z10 in the BCS. In terms of the BCS, the
: X- and Y-coordinate axes of the new
: workpiece coordinate systems are
: rotated counterclockwise by 1.23
: degrees around the new Z-coordinate
: axis.
N200 BCR() Workpiece position compensation OFF.

Special features and restrictions:


D Activating and deactivating workpiece position compensation inter-
rupts block look-ahead; therefore, it may not be programmed when
cutter path compensation is active (G41/G42, see page 3-39).
D The power-up status and the behavior in case of a control reset are
configured in machine parameters 7060 00010 and 7060 00020.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-25
and Controls

NC Functions ChLength, CHL ChSection, CHS

4.19 Chamfer Programming ChLength, CHL


ChSection, CHS

Effect
The function Chamfer programming inserts a transition phase between
two consecutive NC blocks of the type straight line or circle, the length of
which can be specified as absolute chamfer length or as length of the
chamfer segment. The chamfer is generated within the active working
plane.

The following chamfer transitions are possible.


D Chamfer between two abutting straight lines
The chamfer runs at a right angle to the bisector between neighboring
path segments. The length of the chamfer is automatically corrected
(reduced) when there is no intersection with the neighboring pro-
grammed path segments.

Chamfer Chamfer
length segment

Straight
Straight line
line

Bisector of the angle

D Chamfer between two abutting circle segments


In case of contour transitions involving circle segments, the dimen-
sions of the chamfers refer to the respective end- or starting tangent
of the path segments involved in the contour transition. The actual re-
sulting chamfer length is strongly dependent on, among other things,
the radii of the circles involved and thus deviates more or less from the
programmed dimensions.

Chamfer segment

Chamfer length
Tangent line 2

Circle segment 1 Circle segment 2

Bisector of the angle

Tangent line 1
4-26 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions ChLength, CHL ChSection, CHS

Programming
Syntax:
ChLength<Chamfer length> Chamfer programming ON.
Preassign the desired <chamfer
length> in the unit mm (G71) or
inches (G70).
ChLength() or Chamfer programming OFF.
ChLength(0)
Abbreviation: CHL(..)
ChSection(<Chamfer section>) Chamfer programming ON.
Preassign the desired <champfer
sequence> in the unit mm (G71) or
inches (G70).
ChSection() or Chamfer programming OFF.
ChSection(0)
Abbreviation: CHS(..)

Special features and restrictions:


D Functions ChLength, ChSection, RoundEps and Rounding act
modally and cancel each other mutually.
D The chamfer exclusively refers to the active working plane (G17,
G18, G19, G20). If additional axes are involved in the movement, the
chamfers are not influenced by this.
Since the coordinates of the programmed traversing blocks of the
axes within the working plane are manipulated by the chamfers, but
the values for the axes outside the working plane remain unchanged,
the direction of straight lines in space may change, for example.
D The function is effective only in the Execute operating mode under
Automatic, Single block and Single step.
Since Program block behaves like manual input, chamfer program-
ming is not effective here.
D The switch on-/off procedure as well as the behavior upon a control
reset is determined by the init strings in machine parameters
7060 00010 and 7060 00020 .
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-27
and Controls

NC Functions Collision, CLN

4.20 Collision Monitoring Collision, CLN

Effect
Allows collision monitoring of cutter path compensation G41/G42 to be
D switched on- or off and
D adapted to the application in terms of the look-ahead range and the
behavior in case of a collision.

The following applies:


D The collision monitor has an effect only if cutter path compensation
G41/G42 is active, even if the compensation radius has a value of 0.
D If the current radius compensation value does not permit machining
of individual contour elements, the control will try to modify the related
path so as to avoid damage to the contour.
D During the course of the contour, the collision monitor takes only the
coordinates of the active working plane into account. If collisions are
prevented using the program, e.g. by changing the tool feed depth,
the collision monitor is nevertheless activated within the current look-
ahead range.
In such cases, the collision monitor can be temporarily switched off in
the affected machining section.

. For detailed information about the Collision monitor function,


see the Description of Functions.

. We recommend that the desired power-up behavior of the collision


monitor be entered in MP 7060 00010 / MP 7060 00020.

Programming
Syntax:
Collision(1) Collision monitoring ON.
Retain the current behavior in the
case of a collision.
If the behavior has not been pro-
grammed or entered in
MP 7060 00010/MP 7060 00020 un-
til now, the behavior corresponds to
that of
Collision(CollErr 0).

Collision() or Collision monitoring OFF.


Collision(0)

Collision(DEF) Specify the preset for the look-


ahead range of the collision monitor
to 2 blocks.
4-28 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions Collision, CLN

Collision(CollErr <Type> ) Activate the collision monitor and


specify the behavior in the case of a
collision.

Collision(DLA <Blocks>) Specify the preset for the look-


ahead range of the collision monitor.

Goes into effect the next time that


G41/G42 is programmed.

Collision(LA <Blocks>) Temporarily change the look-ahead


range until the next time that
G41/G42 is programmed.

Abbreviation: CLN(...)

where:
<Type> Specifies the behavior of the control when a collision is
detected:
0: neither a runtime error nor warnings are issued.
Machining is not terminated but contour loops are
left out.
1: run-time error is issued.
Machining is terminated.
2: warning is issued.
Machining is not terminated.

<Blocks> Specifies the size (number of blocks) of the look-ahead


range.
Recommended look-ahead range: 1 to 10 blocks.

Special features and restrictions:


D The preset for the look-ahead range is 2 blocks.
D The maximum possible look-ahead range depends on machine pa-
rameters 7060 00110 to 7060 00130.
D In order to be able to traverse backwards without triggering the colli-
sion monitor when cutter path compensation has been activated for
the contour, the active compensation direction must be replaced star-
ting at the point of reversal (G42 is programmed when G41 is active
and G41 is programmed when G42 is active).
The control thus automatically terminates the look-ahead range of
the collision monitor in a G41 or G42 block and restarts look-ahead
immediately thereafter.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-29
and Controls

NC Functions Collision, CLN

Example:
:
N100 CLN(DLA 5) Preset for the look-ahead range of the collision
: monitor starting at the next G41/G42: 5 blocks.
:
N110 G41 D10 Cutter path compensation to left of workpiece.
N120 X10 Traverse forwards.
N130 X20
N140 X30
N150 G42 Switch to cutter path compensation to right of
: workpiece The look-ahead of the collision mo-
: nitor is terminated as of block 150 and then re-
: started.
N160 X20 Traverse backwards.
N170 X10
N180 X0
N190 G40 Cutter path compensation OFF. The collision
: monitor thus becomes inactive, but it is not
deactivated!
4-30 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions Coord, CRD

4.21 Select Axis Transformation Coord, CRD

Effect
Activates or deactivates axis transformations that are configured in ma-
chine parameter group 1030.

. The function is required, for example, together with spatial coordi-


nate programming (see the Description of Functions) or possibly
when calibrating axis kinematics (see pages4-14, 4-15 and 4-13).

An axis transformation may be in effect at a maximum of 2 points of ac-


tion:

WCS: Workpiece coordinate system

(e.g. for coordinate transformations such as plane


rotation or workpiece position compensation)

BCS: Basic coordinate system

Axis transformation on point of action 2


(e.g. for 5-axis transformation)

LCS: Local machine coordinate system

(e.g. for zero offsets)

MCS: Machine coordinate system

Axis transformation on point of action 1


(e.g. for rod kinematics for transformation in a
Cartesian coordinate system)

ACS: Axis coordinate system

. For every available axis transformation, it has already been inter-


nally specified on which point of action this transformation takes
effect.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-31
and Controls

NC Functions Coord, CRD

Programming
Syntax:
Coord(<AxTransfNo>) Axis transformation ON
Coord() or Axis transformation on point of
Coord (0) action 2 OFF
Coord(0{,<Point of action>}) Axis transformation on the
selected point of action OFF
Abbreviation: CRD(...)
where:
<AxTransfNo> Number of the axis transformation.
Input range: 1 - 20. Integer.
<Point of ac- Points of action of the axis transformation to be
tion> switched off.
Input:1 or 2

Special features and restrictions:


D It is possible to switch directly between different axis transformations
on point of action 2. It is not necessary to deactivate it beforehand!
D An axis transformation on point of action 1 may be activated only if no
axis transformation is active on point of action 2.

. The assignment between the axis transformation type and the


number of the axis transformation is specified in MP 1030 00110.
For detailed information about the available axis transformations,
see the Description of Functions.
4-32 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions CoupleSplineTab, CST

4.22 Spline-Axis Coupling Table CoupleSplineTab, CST


Effect
In an axis coupling, the coupling function is stored in the form of support
point pairs in a coupling table. To calculate the positions of the slave axis
between support points, block preparation generates a spline table.
Spline tables are created when the coupling syntax is being interpreted.
They are stored as a file in the link table directory.

Spline tables are created automatically. CoupleSplineTab(...) can be


used to also create a spline table in defined form:
D CST(STAB(<TabName>,1)) explicitly forces the creation of the spline
table.
D CST(STAB(<TabName>,0)) forces the creation if no spline table exi-
sts or if it is older than the coupling table.

With CoupleSplineTab(...) , you can create a spline table even without an


existing group of coupled axes (e.g. in Manual Data Input mode).

The name of the spline-table is generated from the name of the currently
active coupling table by attaching the extension .s; for example, if the
name of the coupling table is curve.fct, the name of the spline-table be-
comes curve.fct.s.

. The coupling table is searched in the current search path. The


search path is set in machine parameter 3080 00001.
The default link table directory is /usr/lnk. However, it may also be
freely defined using machine parameter 3080 00004.

Programming
Syntax:
CoupleSplineTab(STAB(<TabName>{,<1|0>})) Create a spline
table
Abbreviation: CST(...)
where:
<TabName> Name of the coupling table that is searched in the cur-
rent search path and for which a spline table is crea-
ted.
<1|0> Optional:
0: The spline table is not created, unless it does
not exist or is older than the coupling table
(default).
1: A new spline table is created.

Example:
CST(STAB(curve.fct)) Creates spline table /<Link directory>/cur-
ve.fct.s, if required
CST(STAB(curve.fct,1)) Creates the /<Link directory>/curve.fct.s
spline table irrespective of the date and
whether or not the spline table already exists
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-33
and Controls

NC Functions DcTSel, DCS

4.23 Activate D-Correction Tables DcTSel, DCS

Effect
Activates a D-correction table (geometry correction table, GEO table).
D-correction tables are stored as XML files in the file system of the con-
trol.

Programming
Syntax:
DcTSel({<Path>}<Filename>)

Abbreviation: DCS(..)
where:
<Path> Optional path information for the directory in which <File-
name> is stored.
If there is no information, the file will be searched in the /da-
tabase directory.
If <Filename> is not present there, the control uses the search
path for subroutines so that the search for <Filename> can
also be carried out in other directories.
<Filename> File name of the D-correction table, incl. the file exten-
sion.
Tables with standard names (DC<Number>.dct) can be
activated directly using the number, e.g.
DcTSel(7) activates table DC7.dct.

. Please refer to the Operating Instructions for how to create and edit
D-correction tables.

Example:
:
N030 DCS(geotab.dct) First searches for D-correction table geo-
: tab.dct in directory /database and then, if
it is not there, in the search path for subrou-
tines. The first D-correction table with the
name geotab.dct that is found is activated.
N130 DCS(/mnt/ge.dct) Searches and activates D-correction table
: ge.dct in directory /mnt. If it is not found
there, an error message appears.
4-34 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions DefAxis, DAX

4.24 Transfer Axis Setting from MP DefAxis, DAX

Effect
Cross-channel activation of the default axis configuration according to
MP 1003 00002.

. For detailed information about the Axis transfer function, see the
Description of Functions.

Programming
Syntax:
DefAxis

Abbreviation: DAX

Special features and restrictions:


D If a participating axis that is to be transferred has not been released
yet, this will cause a runtime error.

. Since it often happens that several channels take part in the axis
transfer, we recommend that the function in MP 7060 00020 be ent-
ered behind key word #SysRes.
In this way, the default axis configuration can always be regenera-
ted together with the system reset.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-35
and Controls

NC Functions DiaProg, DIA RadProg, RAD

4.25 Diameter Programming DiaProg, DIA


Radius Programming RadProg, RAD

Effect
Coordinate information for flat axes (on lathes; usually X-coordinates)
can alternatively be interpreted as a diameter or radius. In this way, any
dimensional information that may exist can be transferred directly to the
parts program without conversion.
If Diameter programming is activated, the diameter symbol is placed in
front of the axis displays of the flat axis for the workpiece position, di-
stance to go, end position and program value.
The machine position, actual axis value and coasting are always dis-
played as radius values.

CAUTION
Improper interpretation of dimension information possible!
DIA affects only the entered/configured diameter coordinates.
Diameter programming has no influence on circular interpolation
parameters I, J, K.
Always ensure that only suitable dimension information is pro-
grammed.

Programming
Syntax:
DIA{({<Coord1>{,...,<Coord8>}})} Diameter programming for
up to 8 linear
axes/coordinates ON.
Diameter programming is
switched off for all
coordinates that are not
entered.
where:
<Coordi> Max. 8 linear axes/coordinates (i = 1 - 8) whose di-
stances are to be evaluated as diameter information.

DIA Restores the last RAD status. After the control


powers up, the default values of the machine para-
meters apply.
DIA() The default values are activated. If no diameter
coordinates are defined in the machine parameters,
an axis of classification X becomes a diameter axis.
If this also does not exist, the control reports a run-
time error.
RAD Radius programming for all coordinates ON.

Special features and restrictions:


D The functions are modal and deselect each other mutually.
4-36 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions DiaProg, DIA RadProg, RAD

D If a diameter coordinate is incorporated in an axis transformation, the


NC switches off diameter programming for this axis. However, if axis
transformation is switched on, coordinates can be switched to diame-
ter programming.
D The following applies for the Manual data input and Automatic
operating modes:
In the case of dimension information for circle center coordinates, tool
lengths and zero offsets, coordinates of the flat axis are always inter-
preted as the radius value.
D The following applies for the Handwheel and Jog operating mo-
des:
Axis-interface signal Diameter incr. step (qAx_JogDia) can be used
to switch between diameter- and radius programming.

Example:
N10 DIA() Switch on configured diameter coordinates.
N20 DIA(Y1,W2) The given coordinates Y1 and W1 become
diameter coordinates and all unprogrammed
coordinates become radius coordinates.
N30 RAD Diameter programming is switched off for all
coordinates.
N40 DIA Coordinates Y1 and W1 become diameter
: coordinates (last RAD status).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-37
and Controls

NC Functions DistCtrl, DCR

4.26 Axis Distance Control for Digitizing DistCtrl, DCR

Effect
This function keeps the distance between the surface scanned and the
measuring device (e.g. laser) constant during digitizing. This is to ensure
that the available working range of the measuring device is not excee-
ded.

. For detailed information about this function, see the Description


of Functions.

Programming
Syntax:
DistCtrl(1) or Starts distance control and takes on the current
DistCtrl distance between the surface and the measuring
device as the reference value.
The configuration data defined using machine
parameter 7050 007xx are effective.
DistCtrl() or Deactivates axis distance control, stores the cur-
DistCtrl(0) rent correction value and stops axis movement.
If this is programmed in the same block as a tra-
versing movement, axis distance control will not
be turned off before the movement has been
completed.
DistCtrl(<Fct>) Suppresses certain function-specific configura-
tion data in the machine parameters.
Abbreviation: DCR(...)
where:
<Fct> DcAxis(<Axis>,<Corr>)
Overrides MP 7050 00702.
Abbreviation: DCA(...)
<Axis> Name or number of the channel axis for which
axis distance control is to be activated.
<Corr> Direction of movement in which the correction
values are to be included in the calculation:
+1 or 1:
in the positive direction of movement
-1: in the negative direction of move-
ment
DcFilter(<Time>)
Overrides MP 7050 00730.
Abbreviation: DCF(...)
<Time> Filter parameter to smooth the sensor values.
0: Filter off
>0: Filter on, smoothing time in ms
4-38 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions DistCtrl, DCR

DcLimit({<Speed>},{<Accel>})
Overrides MP 7050 00740 / MP 7050 00741.
Abbreviation: DCL(...)
<Speed> Maximum modification speed of the correction
value. Overrides MP 7050 00740.
Value input, depending on active unit of mea-
surement (G71, G70), in the unit mm/min or
inch/min.
<Accel> Maximum steepness (acceleration) of the
correction value. Overrides MP 7050 00741.
Value input, depending on active unit of mea-
surement (G71, G70), in the unit m/s2 or 1000
inch/s2.
DcMon({<Collision>},{<Hole>})
Overrides MP 7050 00750 / MP 7050 00751.
Abbreviation: DCM(...)
<Collision> Range of tolerance for collision detection.
Overrides MP 7050 00750.
Value input, depending on active unit of mea-
surement (G71, G70), in the unit mm or inch.
0: Collision detection off.
<Hole> Range of tolerance for hole detection.
Overrides MP 7050 00751.
Value input, depending on active unit of mea-
surement (G71, G70), in the unit mm or inch.
0: Hole detection off.

DcBreak Interrupts axis distance control. The current cor-


rection value remains active.
Abbreviation: DCB

DcCont Resumes axis distance control after an interrup-


tion using DCB. The NC controls the deviation
from the reference value as fast as possible.
Abbreviation: DCC
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-39
and Controls

NC Functions EndPosCouple, EPC

4.27 End Position Coupling EndPosCouple, EPC


Effect
Couples two currently synchronous coordinates within a channel accor-
ding to the following relationship:
D slave coordinate = coupling factor x master coordinate.

To calculate the resulting slave coordinate, the position values of the ma-
ster coordinates are always automatically converted into incremental
paths.

The control uses the relationship above to calculate the required end po-
sition of the slave coordinate for every NC block in which a position value
of the master coordinate is programmed.
The slave coordinate behaves based on other NC functions as if its
working path in the parts program has been written especially for it using
local relative dimension programming (IC). This means, for example,
that the current feedrate affects the resulting path movement.

Programming
Syntax:
EndPosCouple(<M-coord>, End position coupling ON.
<S-coord>,<Factor>)
EndPosCouple() or End position coupling OFF.
EndPosCouple(0)

Abbreviation: EPC(...)
where:
<M-coord> Name of the master coordinate.
<S-coord> Name of the slave coordinate.
<Factor> Relationship between slave working path and master
working path.

Special features and restrictions:


D End position coupling cannot be used together with endless coordi-
nates (coordinates whose values are automatically transformed into
the defined range of values when they exceed their range limits).
D Polar coordinate programming is not permitted if end position cou-
pling is activated.
D Master and slave coordinates may not be programmed together in
one NC block if end position coupling is active. However, program-
ming only slave coordinates in an NC block is permitted.
D Neither the master nor the slave coordinate may exit the channel if
end position coupling is active. An axis exchange and changes to the
active axis transformation are not permitted.
D Even if diameter programming is switched on for the master coordi-
nate (see page 4-35), the corresponding radius value is used for the
coupling.
4-40 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions EndPosCouple, EPC

Example:
N10 G18 G0 Z0 Active plane: z,x. Using rapid traverse to
z=0.
N20 G1 F1000 Z3 X1 Positioning to P1.
N30 EPC(Z,X,1) End position coupling ON.
: Master coordinate: Z; slave coordinate: X
: Slave working path = master working path.
N40 Z4 Positioning to P2.
N50 X1 Positioning to P3.
N60 Z5 Positioning to P4.
N70 X3 Positioning to P5.
N80 Z0 Positioning to P6.
N90 EPC() End position coupling OFF.
:

+X
P5
30

P2
20
P4
P1
10
P3

PCS
10 20 30 40 50 +Z
-10

-20
P6
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-41
and Controls

NC Functions FeedAd, FAD

4.28 Feedrate Computing: Hide Axes FeedAd, FAD

Effect
Removes all the axes that are defined in MP 1003 00020 from feedrate
computing.
The removed axes are then moved synchronously.
As a result, the real path velocity can increase in comparison with the
programmed F-value.

Programming
Syntax:
FeedAd(1) or Removes axes from feedrate com-
FeedAd puting

FeedAd(0) or Take axes into account during fee-


FeedAd() drate computing

Abbreviation: FAD(..)

Special features and restrictions:


D If only axes that are hidden for feedrate computing are to be moved in
a block, their feedrate can be set using address Omega instead of
address F (see page 3-96).

Example: (The Y-axis is entered in MP 1003 00020)


:
N100 G94 G0 X0 Y0 Positioning on P(0;0) in rapid traverse.
N110 FeedAd()
N120 X100 Y100 F100 Positioning on P(100;100).
: Progr. path velocity: 100 mm/min
: Real path velocity:
100 mm/min
N150 FeedAd
N160 X200 Y200 F100 Positioning on P(200;200).
: Progr. path velocity: 100 mm/min
: Real path velocity:
141.42 mm/min
4-42 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions FeedForward, FFW

4.29 Feed Forward Control FeedForward, FFW

Effect
This function reduces system-caused coasting by appropriately correc-
ting the command interpolator values in the drive. The result is an increa-
sed contour accuracy or operation without following errors.
. The Feed forward control function is integrated in the drive ac-
cording to the manufacturers specifications and is only activated/
deactivated by the displayed command syntax of the parts
program.
For a detailed description of the Feed forward control function,
please refer to the drive documentation.

. The possibility for activating the feed forward control must have
been released for the corresponding axes using machine parame-
ter 1003 00009.
Programming
Syntax:
FeedForward(1)or Activate the feed forward control
FeedForward for all the axes released
according to MP 1003 00009 (the
relevant drives are switched to
secondary mode 1).
FeedForward(<Addr><Value>,...) Activate/deactivate the feed
forward control for the
programmed axes (effect
depends on <Value>).
FeedForward() or Deactivate feed forward control
FeedForward(0) for all axes.
(All relevant drives are switched
to their primary modes.)
Abbreviation: FFW(..)

where:
<Addr>: Physical or logical axis address.
<Value>: Path information for <Addr>.
0: Deactivate feed forward control.
not equal to 0: Activate feed forward control.

Example:
N10 FFW Activate the feed forward control for all the axes of
: the channel released by MP 1003 00009.
N50 FFW(Z0) Deactivate the feed forward control for Z (switch Z
: to primary mode).
N90 FFW() Deactivate the feed forward control for all the axes
: of the channel (switch to primary mode).
:
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-43
and Controls

NC Functions FeedForward, FFW

Special features and restrictions:


D When the feed forward control is deactivated, all the axes of the chan-
nel are switched to their primary modes.
D The parameters of the feed forward control function can be set in the
drive only by writing the relevant drive parameters.
WriteId is available as a function for writing SERCOS-parameters
using the parts program (see page 4-157).
4-44 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions FlyMeas, FME

4.30 Measurement on-the-fly FlyMeas, FME

Effect
The Measurement on-the-fly function is used for accompanying mea-
surement during machining. The traversing movement is not terminated
when the sensor is switched on.

The measured position is transferred from the drive to the NC. It can be
queried with CPL-command PPOS.

Programming
Syntax:
FlyMeas(MpiAxis<i>)<Axis coordinates> Start measuring cycle.
Abbreviation: FME(..)

where:
<i>: Index of the physical axis that is to be used in the
measurement.
<Axis coordinate>: Position that is to be approached during the
measuring procedure.

Special features and restrictions:


D Before the first measurement, the sensor must be initialized using the
InitMeas function.
D The function acts blockwise.
D The function can be programmed together with all interpolation types
and works parallel to the active interpolation.
D If the probe does not switch on, the NC waits at the end of the block
until a measuring event appears.
D If the probe information is to be processed further in the subsequent
program blocks, pay attention to the block look-ahead. A WAIT may
have to be programmed or the look-ahead may have to be limited by
BlkNmb.
D The measuring position can be queried via PPOS.
D The function can be used for linear endless axes if the programmed
positions have a positive sign. Backward traveling using the probe
(programming of negative positions) will not provide unique values.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-45
and Controls

NC Functions FlyMeas, FME

Example:
:
N100 IME(MpiAxis 1) Initialize the probe logic of phy-
: sical axis 1 (here: X-axis).

N110 G0 X0 Y0
N120 FME(MpiAxis 1) G1 X10 Y10 Start the measuring cycle and
: positioning in feed at X10,Y10.

+Y Probe is triggered.
Current position (here:
the X-axis) is saved. Continue to traverse to
20 the progr. end point

10 Workpiece

+X
10 20
4-46 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions FsProbe, FSP

4.31 Measuring at Fixed Stop FsProbe, FSP

Effect
While the control traverses all the programmed synchronous axes using
linear interpolation and the given feedrate to the programmed end point,
the current torque is monitored for a selected axis.
If the torque of this axis exceeds a configurable limit value during the mo-
vement, the following actions occur in the control:
D Setting the axis Fixed stop reached IF-signal-
D storing the actual-position
D Braking of the path movement to v=0 with the maximum permitted de-
celeration
D Clearing of the distance to go
D Clearing of FsProbe (effective block-by-block).

The control generates an error message if no fixed stop has been re-
ached at the end of the path (specified torque threshold is exceeded).
. FsProbe should only be used in combination with a CPL-pro-
gram for analysis.

Programming
Syntax:
FsProbe(MfsAxis<i>) Measuring at fixed stop ON
<Coordinates> <Feedrate> for axis <i>and traverse program-
med coordinates with linear inter-
polation.
FsProbe(MfsAxis Measuring at fixed stop ON
(<i>,<Threshold>)) with torque threshold for axis <i>
<Coordinates> <Feedrate> and traverse programmed coordi-
nates with linear interpolation.
Abbreviation: FSP(..)

where:
<i> Index of the physical axis that is to be used in the
measurement.
<Threshold> Torque threshold
Input value: in % of maximum torque.
If <Threshold> is not programmed, machine parame-
ter 1003 00031 (Fixed stop torque limit value) is effec-
tive.
<Coordinate> Position that is to be approached during the measu-
ring procedure.
<Feedrate>: Desired path feed.
Limited by MP 1005 00030 (Maximum feedrate for
Move to fixed stop) and MP 1005 00002 (Maximum
axis - speed and- rapid velocity).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-47
and Controls

NC Functions FsProbe, FSP

Example:
N100 FSP(MfsAxis(1,30)) X100 F500 Activate Measurement at fi-
xed stop for the first physical
axis and approach position
X100 with F500. Set the tor-
que threshold as 30% of the
maximum torque.
110 IF SD(9) = 0 THEN Query whether torque thres-
hold was exceeded.
120 XPOS=PPOS(1) Save the position in the swit-
: ching torque of the 1staxis
: (X-axis) to the XPOS varia-
ble.
N130 (MSG, CONTACT)
140 GOTO N180
150 ENDIF
N160 (MSG, NO CONTACT)
N170 M0 Program halt
N180 ...

Special features and restrictions:


D The following functions are not permitted in the FsProbe block:
D G75 (Probe),
D InitMeas/FlyMeas (Measurement on-the-fly),
D RedTorque (Torque reduction)
D FsMove/FsReset/FsTorque (Move to fixed stop).
D FsProbe must be programmed together with at least one coordi-
nate. Its value represents the maximum search depth which the fixed
stop must have reached at the latest.
D FsProbe implicitly pauses the block preparation of the subsequent
blocks. WAIT therefore need not be programmed.
D Evaluation of whether the fixed stop has been reached, continuation
of program (after an error), safety monitoring, generation of error
messages, etc. must be implemented in the CPL program.
D SD(9) can be used to query whether the fixed stop was reached.
D PPOS can be used to query the fixed stop position.
4-48 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions FsMove, FSM FsTorque, FST FsReset, FSR

4.32 Move to Fixed Stop FsMove, FSM


FsTorque, FST
FsReset, FSR

. The Move to fixed stop function can also be used for asynchronous
axes!

Effect
The overall Move to fixed stop function covers the following partial
functions:
1. Torque reduction fixed stop: FsTorque, FST
Sets the maximum torque that the drive can have after switching on
Move to fixed stop.
If FsTorque is not used, MP 1003 00031 is effective.

2. Move to fixed stop: FsMove, FSM


Start movement in the direction of the fixed stop, taking into account
the maximum permitted torque.
If the max. permitted torque is attained (see 1.) during this movement,
the control triggers the following sequence of actions:
D Outputting the axis Fixed stop reached IF signal.
D Braking of the path movement to v=0 with the maximum permitted
deceleration.
D Setting the command position to:
actual position + 0.1 mm (or actual position + 0.1 degree).
D Monitoring of the axis position for:
Position of fixed stop + MP 1003 00032 (Monitoring window fixed
stop in mm or degrees)
D Stop the specified torque on the affected drive.
D Continue processing of the parts program.
The control generates an error message if no fixed stop has been re-
ached at the programmed end of the path (specified torque threshold
is attained; see FsTorque).
FsMove remains effective beyond the FsMove block and is swit-
ched off only by FsReset.

3. Cancel fixed stop: FsReset, FSR


Release the axes and, if necessary, traverse away from the fixed
stop.
D If synchronous and/or asynchronous axes have been program-
med in the FsReset block, the control will traverse all axes at the
specified feedrate to the programmed end points. The maximum
permitted torque of the individual axes applies to the movement
away from the stop.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-49
and Controls

NC Functions FsTorque, FST FsMove, FSM FsReset, FSR

D If no axes have been programmed in the FsReset block, only the


synchronous axes will released. In this case, asynchronous axes
for which Move to fixed stop is still active can only be released by
interface signal Cancel fixed stop.

. If desired and if FsReset (see 3.) is not yet programmed, an active


torque affecting the fixed stop can be changed later in the parts
program using FsTorque (see 1.).

Programming
Syntax:
FsTorque(<Addr><Torque>) Activate the maximum permitted
torque<Torque> for axis <Adr>.
Synchronous and asynchronous
axes are permitted.
Abbreviation: FST(..)

FsMove Activate Move to fixed stop.


<Coord-Syn> <Feedrate> Move synchronous and asynchro-
<Coord-Asyn> <Feedrate-Asy> nous axes to the programmed end
positions.
Abbreviation: FSM(..)

FsReset Switch off Move to fixed stop.


<Coord-Syn> <Feedrate> Move synchronous and asynchro-
<Coord-Asyn> <Feedrate-Asy> nous axes to the programmed end
positions.
Abbreviation: FSR(..)

where:
<Addr>: Physical or logical axis address; asynchronous
axes are also possible.
<Torque>: Maximum torque in % of the corresponding axis
standstill torque. Value range: 0 to 500%.
<Coord-Syn>: Desired end point coordinates of synchronous
axes (e.g. X100 Y100 Z100). Is traversed to by
linear interpolation of all axes involved, taking
<Feedrate> and MP 1010 00030 (Maximum
acceleration Move to fixed stop) into account.
<Feedrate>: Desired path feed.
Programming by F address, limited by
MP 1005 00030 (Maximum feedrate Move to fi-
xed stop) and MP 1005 00002 (Maximum axis
and rapid velocity).
4-50 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions FsTorque, FST FsMove, FSM FsReset, FSR

<Coord-Asy>: Desired end point coordinates of asynchronous


axes. The coordinates are traversed to, taking
into account <Feedrate-Asy> and
MP 1010 00030 (Maximum acceleration Move
to fixed stop).
<Feedrate-Asy>: Desired feedrate of asynchronous axes.
Programming by FA address, limited by MP
1005 00030 (Maximum feedrate Move to fixed
stop) and MP 1005 00002 (Maximum axis and
rapid velocity).

Example:
:
N100 FST(X20) Limit the torque for the axis with designation
X to 20% of the axis standstill torque.
N110 FSM X100 F200 Activate Move to fixed stop. Start move-
: ment with a feedrate of 200 mm/min to posi-
: tion X=100.
: Continue processing of parts program.
N500 FSR Switch off Move to fixed stop and release
: all synchronous axes.

Special features and restrictions:


D The following functions are not permitted in the FsReset block and
while Move to fixed stop is active:
D G75 (Probe)
D InitMeas/FlyMeas (Measurement on-the-fly)
D Torque reduction via PLC interface
D FsProbe (Measuring at fixed stop).

D FsMove must be programmed together with at least one endpoint


coordinate. Its value represents the maximum search depth which
the fixed stop must have reached at the latest.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-51
and Controls

NC Functions GetAxis, GAX

4.33 Integrate Axis GetAxis, GAX

Effect
Transfers a synchronous axis to the calling channel. This turns an asyn-
chronous axis into a synchronous axis.
The axis can then be programmed in the current channel using its physi-
cal or logical axis name.

. For detailed information about the Axis transfer function, see the
Description of Functions.

Programming
Syntax:
GetAxis(<PAN> | <PAI>,{<LAN>}{,<PAN> | <PAI>,{<LAN>}}...)

Abbreviation: GAX(..)
where:
<PAN> Physical axis name.
Specifies the axis that is to be transferred to the current
channel.
<PAI> Physical axis index.
Same effect as <PAN>.
<LAN> Logical axis name.
If this is programmed, the axis to be integrated into the
current channel receives the logical name <LAN>.
<LAN> must have been defined in MP 7010 00010 (Lo-
gical axis designation) or MP 7010 00020 (Optional
axis designation).

Special features and restrictions:


D An axis to be integrated must be at a standstill.
If this is not the case as opposed to function WaitAxis (see page
4-156) the control generates an error message and terminates the
program.
D Axis positions in the same block must always be programmed after
GetAxis(...) and may be programmed only if axis transformation is not
active.
D Axes to be transferred must not be participating in any active monito-
ring area (see page 4-2).

Example:
:
N030 GAX(YP,,ZP,Z) Physical axes YP and ZP are integrated in
: the receiving channel.
While YP is also addressed as YP in the cal-
ling channel, ZP receives address Z in the
calling channel.
4-52 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions GCT(1) GCT(0)

4.34 Straightaway and Angle Error Compensation: Switch on GCT(1)

Effect
Activates the straightaway and angle error compensation to compen-
sate geometric errors which are caused by inaccuracies of mechanic
and can not be recorded from the encoders.

. You can find extensive information regarding the use and parame-
ter settings of straightaway and angle error compensation in the
Functional description manual.

Programming
Syntax:
GCT(1) (alternative: GCT, GeoComp(1), GEOCOMP(1))

Special features and restrictions:


D The user stores the compensation data in a XML scheme.
D This files are stored in the root directory or in USRFEP of control. The
file-name. is freely selectable; the file extension must be gct.

4.35 Straightaway and Angle Error Compensation: Switch off GCT(0)

Effect
Deactivates the straightaway and angle error compensation

Programming
Syntax:
GCT(0) (alternative: GeoComp(0), GEOCOMP(0))
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-53
and Controls

NC Functions HsBlkSwitch, HSB

4.36 Block Transition on-the-fly Using High-Speed Signal


HsBlkSwitch, HSB

Effect
Permits a premature block transition using the high speed-inputs or the
customer inputs of channel interface of the control. In this way, a linear
traveling movement can be prematurely terminated, depending on ex-
ternal events.

CAUTION
Modification of the programmed path!
If the programmed end points of the HsBlkSwitch- block and the
block following it do not lie on a straight line, the occurrence of an
external event always leads to a modification of the path that can
not be precisely predicted!

. The high-speed signals can be configured using machine parame-


ters.

The following applies to on the fly block transitions:


D without Cancel distance to go in operating modes Automatic, Sin-
gle block and Single step.
D with Cancel distance to go in operating modes Program block and
Manual data input.
D usually without axis standstill. The block is exited with the current
velocity (for exceptions, see Special features and restrictions).
D no check for maximum possible axis jump capability
D effect depends on the current operating mode (Automatic-/Sin-
gle-/Program block, Single step, Manual data input). See Special
features and restrictions.

Programming
Syntax:
HsBlkSwitch(HS<x>=<y>) or Block transition on-the-fly
HsBlkSwitch(CI<x>=<y>)
Abbreviation: HSB(..)

where:
<x>: Number of high speed-signals of the customer input
(qCh_Custom<x>).
Range of values: 1-8, integer.
<y>: Logical signal status required for a block transition:
0: Low
1: High
4-54 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions HsBlkSwitch, HSB

Special features and restrictions:


D The function requires a linear traversing movement in both the
HsBlkSwitch- block and the following one.
D The function must be written with path information; it can be written
together with other path conditions.
D Under operating modes Automatic, Single block and Single step, the
endpoints of the axes that are not programmed in the following block
are transferred from the prematurely terminated block.
D Block transition on-the-fly with an axis standstill occurs in the follo-
wing cases:
D Contour knee >90 degrees between the HsBlkSwitch- block and
the following one.
D Precise stop is active, i.e. G0(IPS...) or G1(IPS...).
D Due to additional programming, the following block starts with v=0
(e.g. if CO-programming or feed forward control is active).
D Jerk-limited velocity control (G8(SHAPE...), G9(SHAPE...),
etc.) is active.
D Operating mode Single block, Single step, Program block or
Manual data input is active.

Example: Event-dependent feedrate.


The traversed feed is to be reduced, depending on an external event, on
a straight path.
Three NC-blocks in which different feed information is entered are requi-
red for this. Since braking to v=0 is not to occur at the block transition,
block transition on-the-fly is required.
Note that, due to the nature of the task (...on a straight path...), all pro-
grammed endpoints must lie on the same straight line.
. The endpoints of a following block may not be identical to those of
the preceding block. Otherwise a traversing movement is not car-
ried out in the following block!

. The programmed distance traversed of a following block influen-


ces the maximum possible feed velocity at the block transition. If
the distance traversed is too short, the path velocity may be auto-
matically reduced!
:
N20 G0 X0 Y0 Traverse to initial position.
N30 HSB(HS1=1) G1 X100 Y10 F500 Traverse with F500 until high-
speed signal 1 = High or X100
Y10 is attained.
N40 HSB(HS1=0) X110 Y11 F100 Traverse with F100 until high-
speed signal 1 = Low or X110
Y11 is attained.
N50 X120 Y12 F500 Traverse distance to go until
: X120 Y12 with F500.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-55
and Controls

NC Functions HsBlkSwitch, HSB

Y N50
N40
N30

10

V 100 110 120 X


HS1=1 HS1=0
500

100
t
N30 N40 N50
V
HS1=1 and remains
500 1

100
t
N30 N40 N50
V
HS1=0 and remains 0 (no external event)
500

100
t
N30 N50
N40: immediate block transition because HS1=0
4-56 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions HsBlkSwitch(..,HSSTOP=..), HSB(..,HSSTOP=..)

4.37 Block Transition with Cancellation Using High-Speed Signal


HsBlkSwitch(..,HSSTOP=..), HSB(..,HSSTOP=..)

Effect
Permits a premature block transition using the high speed-inputs or the
customer inputs of channel interface of the control. In this way, a linear
traveling movement can be prematurely terminated, depending on ex-
ternal events.

CAUTION
Modification of the programmed path!
If the programmed end points of the HsBlkSwitch block and the
block following it do not lie on a straight line, the occurrence of an
external event always leads to a modification of the path that can
not be precisely predicted!

. The high-speed signals can be configured using machine parame-


ters.

The following applies to block transition with cancellation:


D in all operating modes with Cancel distance to go.
D always brake to v=0, either with velocity step or downslope.
Braking to v=0 occurs at the end of the block if the external event
did not occur.

Programming
Syntax:
HsBlkSwitch(HS<x>=<y>,HSSTOP=<z>) Block transition with
or HsBlkSwitch(CI<x>=<y>,HSSTOP=<z>) cancellation
Abbreviation: HSB(..,HSSTOP=..)

where:
<x>: Number of high speed-signals of the customer input
(qCh_Custom<x>).
Range of values: 1-8, integer.
<y>: Logical signal status required for a block transition:
0: Low
1: High
<z>: Braking type if the event occurs:
0: Ramp down to v=0 with max. deceleration
-1: Velocity step to V=0.

Special features and restrictions:


D The function requires a linear traversing movement in both the
HsBlkSwitch block and the following one.
D The function must be written with path information; it can be written
together with other path conditions.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-57
and Controls

NC Functions HsBlkSwitch(..,HSSTOP=..), HSB(..,HSSTOP=..)

D If Jerk-limited velocity control (G8(SHAPE...), G9(SHAPE...), etc.)


is active, no velocity jump occurs during HSSTOP=-1 .
Example:
Event-dependent cancellation of traversing movement:
:
N20 G1 X0 Y0 F1000 Traverse to initial position.
N30 HSB(HS1=1,HSSTOP=-1) Traverse X-axis with F10 until high-speed
X10 F10 signal 1 = High or X10 is attained.
An event triggers a jump to v=0 and swit-
ches off Cancel distance to go.
N40 HSB(HS2=1,HSSTOP=0) Traverse Y-axis with F200 until high-
Y100 F200 speed signal 2 = High or Y100 is attai-
ned.
An event triggers downramping to v=0
with the max. deceleration and switches
off Cancel distance to go.
4-58 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions HWOC HWOCDIS

4.38 Online Correction in Workpiece Coordinates HWOC


HWOCDIS
Effect
Online-correction in workpiece coordinates is used to superimpose
current
D positions or orientations in the workpiece coordinate system of a
channel, or
D positions of the tool length axis in the TCS -z-direction
by a correction. The control derives the magnitude of the correction from
a connected handwheel (usual case) or drive or from the value of a CPL-
variable.
For detailed information about this function, see the Description of
Functions.

Programming
Syntax:
HWOC({CHAN<Channel No>},CRDNO Online-correction ON
<Coord No>,{STEP<Inkr>})
HWOCDIS{(CHAN<Channel No>)} Online-correction OFF;
current correction magnitude
remains in internal storage.
HWOC() od. Online-correction OFF and
HWOC(0) clear the relevant correction
values.
where:
<Channel No> Channel number in which the online correction is acti-
vated/deactivated.
If CHAN<Channel No> is not programmed, the number of the
current channel is effective.
<Coord No> Coordinate on which the online-correction is to have an
effect.
value range: 1 to 9 and 103.Integer.
1 to 8: . Coordinate number in the channel specified
9 or 103: TCS-coordinate.
<Incr> Specification of the desired increment step per 1 incr.
Effective only if MP 7050 00926 = 0.

Special features and restrictions:


D A coordinate position generated by online-correction is not analyzed
for possible travel beyond the software-limit switches.
Therefore, end limit monitoring on the drive side should be activated
when using online-correction.
D Online-correction is not possible in Manual operating mode (jogging
mode) or in Manual traverse to reference point.
D G76 approaches a position that is offset by the current correction va-
lue.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-59
and Controls

NC Functions HWOC HWOCDIS

D CPL-functions PPOS and PCSPROBE do not take the correction va-


lue of the online-correction into account.
D G75 measures the real actual-position (incl. online-correction).
D FsProbe measures the real actual-position (incl. online-correction).
4-60 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions InitMeas, IME HWOCDIS

4.39 Initialization of on-the-fly Measurement InitMeas, IME

Effect
Function InitMeas is used to initialize the probe for function Measure-
ment on-the-fly (FlyMeas). Initialization must be called before the first
measuring procedure of an axis.

Programming
Syntax:
InitMeas(MpiAxis<i>) Initializing the probe logic.
Abbreviation: IME(..)

where:
<i>: Index of the physical axis that is to be used in the
measurement.

Special features and restrictions:


D The function acts blockwise.
D The function can be programmed together with all interpolation types
and works parallel to the active interpolation.
D The function must be called before the first call of function FlyMeas
for the corresponding axis.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-61
and Controls

NC Functions JogWCSSelectHWOCDIS

4.40 Jogging in Workpiece Coordinates JogWCSSelect

Effect
For operating mode Set-up mode, jogging in workpiece coordinates,
this function defines which coordinate is to be jogged or traversed using
the handwheel.
The following coordinates can be selected for jogging:
D all the coordinates of individual machine axes (pseudocoordinates) if
no axis transformation is active
D all linear and orientation coordinates based on the active WCS if
an orientatable axis transformation is active
D TCS coordinate z if an orientatable axis transformation is active.

The setting in MP 7050 01010 determines whether the feed velocity and
increment (for incremental jogging) can be derived from the settings of
an existing machine axis or whether they must be explicitly program-
med.

. For detailed information about this function, see the Description


of Functions.

Programming
Syntax:
JogWCSSelect({JWSCHAN<Channel No>,}JWSCOORD<Coord No>,
{JWSFEED<F-value>{,JWSSTEP<Incr>}})
where:
<Channel No> Channel number in which a coordinate is to be jogged.
Default: Number of the channel in which the function is pro-
grammed.
<Coord No> Coordinate selection.
value range: 1 to 8 and 103.Integer.
1 to 8: Number of coordinate to jog
103: TCS coordinate is to be jogged.
<F-value> Jogging speed.
Entered value depends on active unit of measurement (G71,
G70), in the unit mm/min, inch/min or degrees/min.
Effective only if MP 7050 01010 = 0.
<Incr> Selects incremental jogging and specification of the desired
step size in increments.
Effective only if MP 7050 01010 = 0.

Special features and restrictions:


D The function is designed for use in a special NC program for coordi-
nate selection (also see MP 705001110).
For details, please refer to the Description of Functions.
4-62 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions KvProg, KVP

4.41 CO Programming KvProg, KVP

Effect
The function enables a program-controlled change of the CO values of
individual axes. This can be used for temporary increases of the rigidity
of axes (e.g. for milling a bore).
After the control is powered up, the NC (among other things) reads the
current CO values of all coupled drives and saves them.
During CO programming, the control loads the programmed CO values
into the relevant drives (parameter S-0-0104).
When CO programming is switched off, the control transfers the pre-
viously saved CO values back to the drives, thus restoring the initial
state.
The following applies:
D CO = (path velocity in m/min) / (coasting in mm)
D Decelerating to v=0 is performed ahead of each block containing a
CO switch, since the CO value in the drive should only be switched
over at standstill.
D After the command for the CO switchover, the control always waits
internally for the acknowledgement by all participating drives.
D The CO switchover occurs immediately before any traversing move-
ment that may also be programmed in the same block.
Example:
:
N10 G1 F1000
:
N40 X40 Positioning with default CO value.
N50 KVP(X2) X50 Transfer CO value 2 to axis X and
: then traverse.

V
Switch CO

1000

t
N40 N50
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-63
and Controls

NC Functions KvProg, KVP

Programming
Syntax:
CoProg(<Axis1>{,<Axis2>}{,...}) CO programming ON.
KvProg({0}) CO programming OFF.
Abbreviation: KVP(..)

where:
<Axis> Physical (system-wide) or logical (channel-based) axis de-
signation, incl. the desired CO value.
Max. programmable CO value: 655.35

Special features and restrictions:


D Only axes that are currently assigned to the channel may be program-
med.

Example:
: Starting point: a CO value of 1.0 is active
: in all drives.
N10 G0 X0 Y0 Z100 Positioning with CO value = 1.0
N20 KVP(Z2.1) Transfer the CO value 2.1 to the drive of
: physical axis Z.
N30 G1 Z0 Positioning with CO value = 2.1
N40 KVP() Z100 KV programming OFF.
: The NC automatically reloads the CO va-
: lue 1.0 into all the drives.
Then the Z-axis traverses.
4-64 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions LEN

4.42 Divide Traversing Block: Length of Partial Path LEN

Effect
Divides a programmed traversing block into several partial paths of
equal length.

. Works together with functions Punch (see page 4-110) and Nib-
ble (see page 4-76).

Programming
Syntax:
LEN=< Value>
where:
<Value> For linear blocks: length of partial path.
For circular blocks: length of arc.
Programming unit as for the axis coordinates.
<Value> does not have to be an integral divisor of the pro-
grammed length of path. Internally, the NC automatically
computes an effective LEN value that is less than/equal
to the programmed LEN value with the effect that the ef-
fective path segments are always integral divisors of the
programmed length of path.

Special features and restrictions:


D The motion from one stroke to the next is always linear in the case of
divided circular blocks.
D LEN works modally as long as function Punching/Nibbling is active.
However, it can be overridden on a block-by-block basis by NUM
(see page 4-78).
D Programming LEN is possible at any time when Punching/Nibbling
(MP 8001 00010) has been released. However, block splitting begins
only after Punching/Nibbling has been activated.
Example:
- G90 is active (absolute dimension programming)
- active plane: X/Y
- current position: X=0, Y=0, C=0
- punching/nibbling is switched off.
:
N20 X100 Y100 LEN=15 Divide the following traversing blocks
into identical partial paths with a maxi-
mum of 15 mm. LEN is not yet in ef-
fect because punching/nibbling is
switched off.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-65
and Controls

NC Functions LEN

N30 X200 Y200 C180 Punch(1) Punching ON. LEN is in effect. The
path length is split into 10 block seg-
ments.
Resulting stroke positions (X,Y,C):
P1 (110,110,18)
P2 (120,120,36)
:
P10 (200,200,180).
N40 Y290 C210 The path length (90 mm) is split into 6
block segments. Resulting stroke
positions (X,Y,C):
P11 (200,215,185)
P12 (200,230,190)
:
P16 (200,290,210).
N50 Punch() Punching OFF.
:

Y : No stroke
P16
290 : Stroke

275

260
Tool rotation LEN=15: results in 6
245 by 15_ each path segments of 15
mm each
230 (X200, Y200, C180
through
215 P11 X200, Y290 C210)
200
190 P10
180
170
160 LEN=15: results in 10
path segments of 10 mm
150 each
140 (X120, Y120, C18
130
through
P2 Tool rotation X200, Y200 C180)
120 P1 by 18_ each
110 P0
100

0
0 100 120 140 160 180 200 X
110 130 150 170 190
4-66 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions LFP LFConf, LFC

4.43 Path Velocity-Dependent Laser Power Control


LFP
LFConf, LFC

Effect
Controls the power of a laser using an analog voltage signal (0 - 10 V)
depending on the current path velocity vpath.
. For detailed information about this function, see the Description
of Functions.

Programming
Syntax:
LFP(1) or Laser power control ON with cur-
LFP rent parameter settings.
LFP({LL(... )}) Laser power control ON with ad-
ditional parameter settings as
described under LFCont.
LFP(0) Laser power control OFF.

LFConf({LL(<Volt>,<Vmin>)}, Set the laser power control para-


{UL(<Volt>,<Vmax>)}, meters The selection of relevant
{PL(<Mode>)}, coordinates occurs either with
{CD(<Coord 1>{,<Coord n>}...)},) PL(..) or CD(..).
Abbreviation: LFC(..)

where:
<Volt> Voltage in % of the maximum output voltage (10 V).
Together with <Vmin>: Output at a path velocity of less than
<Vmin>.
Together with <Vmax>:Output at a path velocity of greater
than <Vmax>.
<Vmin> Lower path velocity limit.
Entered value depends on active unit of measurement (G71,
G70), in the unit mm/min, inch/min or degrees/min.
<Vmax> Upper path velocity limit.
Entered value depends on active unit of measurement (G71,
G70), in the unit mm/min, inch/min or degrees/min.
<Mode> Defines which coordinates are to be used to determine vpath:
APL All coordinates of the current plane.
ASP All coordinates of the current space.
CFD Coordinates according to MP 7050 00820.
<Coord x> Defines which coordinates are to be used to determine vpath.
Input values: Name of the participating space coordinates (if
axis transformation is active) or logical axis name (pseudo-
coordinates; if axis transformation is not active).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-67
and Controls

NC Functions LFP LFConf, LFC

Examples:
LFP (LL(10,100), UL(60,700))
Laser power control ON. Additional parame-
ter settings: Output voltage to 10% (=1V) if
the path velocity drops below 100mm/min
and 60% (=6B) if the path velocity rises
above 700 mm/min.
LFP(0) Laser power control off.
LFConf (PL(APL)) Only parameter settings: The path velocity is
derived from the movement in the active le-
vel.
LFConf (CD(X , Z)) Only parameter settings: The path velocity is
derived from the movement of coordinates X
and Z.
LFConf (UL(80,500)) Only parameter settings: Limit output vol-
tage to 80% (=8V) if the path velocity rises
above 500mm/min.

Special features and restrictions:


D The available analog outputs limit the number of channels that may
use this function.
D The voltage signal for the laser control falls to 0 V in the following ca-
ses:
D Error occurs (runtime error, diagnostics class 1 error)
D Drive under control signal of a drive participating in the path is
deactivated (no enable signal, drive off)
D Feed hold signal becomes active.
4-68 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions LinUpFeed, LNU

4.44 Velocity Profile (Ramp Functions)


The function allows the definition of machining sections that are to be ex-
ecuted with separate velocity profiles. The following individual compo-
nents are available for this purpose:
D 1 constant speed interpolator,
D 3 acceleration and 3 braking interpolators
(each with a linear-, sinusoidal - and sin2-shaped velocity profile).

The following applies:


D All functions described below work modally, form a modal group with
G8 and G9, and mutually deselect each other.

Effect of acceleration interpolators LinUpFeed, LNU


SinUpFeed, SNU
Sin2UpFeed, S2U
Starting from velocity V0 (velocity at the beginning of the block), the con-
trol accelerates across the entire programmed path length to the target
velocity V1.
Depending on the programmed function, this occurs with a linear-, sinu-
soidal- or sin2-shaped velocity rise.
The target velocity V1 is reached together with the programmed end
point, and results from the programmed feedrate as a function of the cur-
rent override value. It is limited by
D the maximum path acceleration and
D the maximum permitted path velocity.
Both quantities are calculated by the control specifically for each path
segment and each NC block; a 1-block look-ahead is performed in con-
nection with the maximum permitted velocity. This prevents a violation of
the maximum axis velocities in the next block.
. If V1 is not greater then V0, the call of the acceleration interpolator in
the current block is ignored.
Behavior in the event of override-changes:
D Increasing the override results in the recalculation of the acceleration
ramp.
D An override reduction to final values below the start velocity V0
D results in a recalculation of the braking ramp in the case of LinUp-
Feed; this lasts until the programmed endpoint.
D is ignored in the case of SinUpFeed and Sin2UpFeed.
Effect of constant speed interpolator ConstFeed, CFD
The control tries to reach the programmed velocity, taking the maximum
permitted path velocity and the current override value into account.
Velocity changes during override changes are executed with the permit-
ted accelerations in each case.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-69
and Controls

NC Functions LinUpFeed, LNU LinDownFeed, LND

Effect of braking interpolators LinDownFeed, LND


SinDownFeed, SND
Sin2DownFeed, S2D
Starting from velocity V0 (velocity at the beginning of the block), the con-
trol brakes across the entire programmed path length to a standstill
(V1=0).
Depending on the programmed function, this occurs with a linear-, sinu-
soidal- or sin2-frmigem shaped velocity drop.
Override-changes have no effect, with the following exception:
If the override was set to 0% in the previous block and the command ve-
locity of 0 was reached afterwards exactly at the block transition to the
deceleration interpolator, the control maintains the deceleration interpo-
lator until the override is increased to a value > 0!
The velocity is increased by one acceleration step (depending on the
permitted path acceleration).
The control calculates the necessary deceleration ramp on the basis of
the velocity value resulting from this function. Afterwards, the actual
override-value will be of no effect until the end of the block.

Programming
Syntax:
LinUpFeed Activate acceleration interpolator with linear
Abbreviation: LNU velocity rise
SinUpFeed Activate acceleration interpolator with
Abbreviation: SNU sinusoidal velocity rise
Sin2UpFeed Activate acceleration interpolator with
Abbreviation: S2U sin2-shaped velocity rise.
ConstFeed Activate constant speed interpolator.
Abbreviation: CFD

LinDownFeed Activate acceleration interpolator with linear


Abbreviation: LND velocity drop.
SinDownFeed Activate acceleration interpolator with
Abbreviation: SND sinusoidal velocity drop.
Sin2DownFeed Activate acceleration interpolator with
Abbreviation: S2D sin2-shaped velocity drop.
4-70 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions LinUpFeed, LNU LinDownFeed, LND

Example: Velocity profile for an oscillation cycle of the U-axis.

V(t)

0
t

N5 N10 N20 N30 N40 N50 N60 N70

N5 G0 U10 U axis is traversed to starting position (U=10mm)


N10 S2U U17 F500 Sin2-shaped acceleration up to position U=17.
Feedrate setpoint at the end point: F=500 mm/min.
N20 CFD U23 Constant speed until position U=23.
N30 LND U29 Linear braking until position U=29.
End speed: 0 mm/min.
N40 G4 F0.5 Dwell time in the point of reversal.
N50 LNU U20 Linear acceleration until position U=20.
N60 CFD U17 Constant speed until position U=17.
N70 SND U10 Sinusoidal braking until position U=10. End speed:
0 mm/min.

Special features and restrictions:


D The desired end point coordinate must always be entered in the pro-
grammed block.
D All ramp functions can be used only in the Automatic operating mode.
Other operation modes (Manual data input, Single block, Single step,
or Program block) lead to a runtime error.
D When using braking interpolators in connection with extremely short
traversing paths, excessive acceleration is possible, which may lead
to a servo error.
Therefore, please note the maximum possible machine dynamics al-
ready when creating the parts program.
D Auxiliary functions or functions such as Precise stop are not permit-
ted while the constant speed and acceleration interpolators are active
(can lead to sudden speed drops). Prohibited functions include:
G0, G4, KvProg, G63, G33, G61, G1(IPS), G75, G74(HOME),
HsBlkSwitch, WriteId.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-71
and Controls

NC Functions LinModZp, LMZ

4.45 Zero-Setting of Modulo Axis (Linear Endless Axis)


LinModZp, LMZ

Effect
LinModZp can be used to define the current position of a linear endless
axis as a new program zero point.
The axis indicator then jumps to a value of 0. The resulting offset is sto-
red within the control and is internally added to all subsequent coordi-
nate information of the corresponding axis.
After a control reset, it is subtracted from the indicator value and deleted.
. For linear endless axes, see machine parameter 1003 00004.

Programming
Syntax:
LinModZp Define the current positions of all
linear endless axes configured in
MP 1003 00004 as a new program
zero point.
LinModZp(LinModAxis<i>) Define the current position of the
linear endless axes configured in
MP 1003 00004 with physical axis
index <i>as a new program zero
point coordinate of this axis.
Abbreviation: LMZ(..)

where:
<i>: Physical axis index.

Example:
N10 LMZ Define the current positions of all
: configured linear endless axes as a
: new program zero point.
N50 LMZ(LinModAxis1) X-20 Define the position of the linear
: endless axis with axis index 1 as a
: new program zero point coordinate.
Then traverse to X-20.

Special features and restrictions:


D Position values greater than the modulo value are not permitted.
D Negative position values are possible as long as the amount is less
than the modulo value.
. The modulo value is defined in the drive using SERCOS parameter
S-0-0103 when the SERCOS is powered up. A changed modulo va-
lue goes into effect only after the SERCOS is restarted!
4-72 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions MainSp, MSP

4.46 Switching the Main Spindle MainSp, MSP


Effect
Defines as opposed to the setting in MP 7020 00010 the given
spindle as a main spindle in the current channel.
In this way, you can dynamically specify on which spindle functions
D G33 (Thread cutting)
D G95 (Feedrate programming in mm/rev) and
D G4 (Dwell time)
are to have an effect.

Programming
Syntax:
MainSp(<Num>) or
MainSp(<Spindle>)

Abbreviation: MSP...
where:
<Num> Number of the spindle (spindle index).
Input value: -1; 1 - 8. Integer.
-1: Main spindle according to MP 7020 00010.
<Spindle> as for <Num>
or
spindle name (e.g. S1)
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-73
and Controls

NC Functions Mirror(...), MIR(...)

4.47 Input Tool: Mirror Mirror(...), MIR(...)

Effect
The Mirror function is one of the input tools.
The control machines a programmed contour or, for instance, a borehole
pattern as a mirror image.
Mirroring always refers to the current mirror point (see function PoleSet,
page 4-101). If this was not explicitly programmed, the current program
zero point is the mirror point.

. Mirroring is an input tool; as a result, it does not change the current


program coordinate system. An input tool merely provides another
input method for the program coordinates.
Mirror can also be used together with Scale and Rotate.

The following applies:


D The function acts modally. It remains active until it is switched off.
D It may be programmed in the same block as other path conditions and
input tools.

Programming
Syntax:
Mirror(<Axis1>1{,<Axisn>1}) Switch on mirroring for the
given axes.
Mirror(<Axis1>0{,<Axisn>0}) Switch off mirroring for the
given axes.
Mirror(0) or Switch off mirroring for all the
Mirror() axes in the channel.
Approached axis positions are
retained until they are
reprogrammed.
Abbreviation: MIR(..)

where:
<Axis 1>, <Axis n>: Axis addresses (e.g. X) combined with a value of
1 activate the function: all subsequently
programmed path commands of the
corresponding axes (e.g. X100) are multiplied
internally by a value of -1.
Mirroring does not become effective until the
next traversing information.

Special features and restrictions:


D The function takes into account the interpolation parameters in the
case of circular interpolation
D It influences the programmable contour shift. See page 4-124.
D It does not influence:
4-74 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions Mirror(...), MIR(...)

D zero offsets (G54-G59.5; see page 3-46),


D program coordinate offsets (Trans or ATrans; see page 4-153),
D setting of the program position (SetPos; see page 4-123),
D approaching reference point coordinates (G74 ; see page 3-55),
D approaching axis position coordinates (G76 ; see page 3-58),
D milling radius- and tool length correction values.

Mirroring examples:

Effect of: MIR(X1) Effect of: MIR(Y1)


Y Y

P X P X

Effect of: MIR(X1,Y1) Effect of: PLS(X10,Y13)


MIR(X1)
Y
Y
2
13
1

P X P 10 X

1: Definition of the mirror point (X10;Y13)


2: Mirroring on

Mirroring of an orientation vector


An orientation vector is only mirrored on a component-by-component
basis using the following function syntax.
Any scaling that may be active or a mirror/rotation point has no effect on
the result.

Syntax:
Mirror(O(<Sx>,<Sy>,<Sz>)) Switch on/off mirroring for the
given components of an
orientation vector.
Abbreviation: MIR(..)
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-75
and Controls

NC Functions Mirror(...), MIR(...)

where:
<Sx>,<Sy>,<Sz> Mirroring factors for the individual vector
components.
0: no mirroring
1: mirroring

Please note for the orientation vector:


D Polar coordinates and proper cannot be mirrored.
D Programming MIR(phi1,theta1) is not permitted.
4-76 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions Nibble, NIB

4.48 Nibbling Nibble, NIB

Effect
Switches the Nibbling function on or off.
If nibbling is activated, no stroke is released in the following cases:
D at the end of every partial path that is programmed or generated by
function NUM (see page 4-78) or LEN (see page 4-64), and
D at the beginning of the first partial path if no traversing movement was
programmed in the active plane or nibbling was switched off in the
previous block.
The subsequent traversing motion always starts before the stroke is fi-
nished.
. Functions to influence the stroke release time:
PtDefault (see page 4-108)
PtBlkEnd (see page 4-106)
PtInpos (see page 4-109).

Programming
Syntax:
Nibble(1) or Nibbling ON.
Nibble

Nibble(0) or Nibbling OFF.


Nibble()

Abbreviation: NIB(..)

Special features and restrictions:


D Nibbling must be released using MP 8001 00010.
D Programming function NUM or LEN is mandatory. The control thus
automatically generates partial paths from the programmed distance
traversed; a stroke is released at the end of each of these partial
paths.
D The function already has a modal effect on traversing movements
that are programmed in the same block.
D If punching is switched on (see page 4-110), the function deselects
nibbling.
D Blocks that do not contain axis coordinates from the active plane also
do not release a stroke.
D If the PLC suppresses the stroke release, processing remains at the
stroke release position until the PLC releases the stroke release.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-77
and Controls

NC Functions Nibble, NIB

Example:
- G90 is active (absolute dimension programming)
- active plane: X/Y
- current position: X=0, Y=0, C=0
:
N10 LEN=12 Divide the traversing blocks into identical
partial paths with a maximum of 12 mm.
LEN must be programmed before Nibble
is switched on!
N20 C10 Nibble(1) Nibbling ON. Modal LEN is in effect. C-
axis rotates to 10 degrees. No stroke be-
cause the X- and Y-axes are not pro-
grammed.
N30 X0 No traversing movement because the
X-axis is already located on position 0.
A stroke occurs because the X-axis is
located in the active plane.
N40 X110 The traversing block is divided into 10
identical 11-mm partial paths. Strokes
are executed in positions X11, X22, X33
... X99, X110
Additional stroke at position X0 be-
cause no traversing movement occurred
in N30.
N50 Y30 NUM=3 Overrides the modally effective LEN
(N10) for the current block.
Divide the traversing blocks into 3 identi-
cal partial paths. Strokes at Y10, Y20,
Y30.
N60 Y90 LEN from N10 is in effect again.
Strokes at Y42, Y54, Y66, Y78, Y90.
N70 X50 Y50 Nibble() Nibbling off.
: Traversing movement to X=50, Y=50.

90
LEN=12
Y42 through 78
Y90 66
(5 path
segments 54
at 12 mm each)
42
NUM=3 30
Y10 through
Y30 20
(3 path 10
segments
0
at 10 mm each)
0 11 22 33 44 55 66 77 88 99 110 X

: 1x stroke LEN=12
: 2x stroke X0 through X110
(10 path segments of 11 mm
each)
4-78 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions NUM

4.49 Divide Traversing Block: Number of Partial Paths NUM

Effect
Divides a programmed traversing block into a defined number of partial
paths of equal length.

. Works together with functions Punch (see page 4-110) and Nib-
ble (see page 4-76).

Programming
Syntax:
NUM=<Value>
where:
<Value> Number of partial paths
Input value: Integer, greater than 0.
NUM=1 does not produce any division.

Special features and restrictions:


D The motion from one stroke to the next is always linear in the case of
divided circular blocks.
D NUM has an effect only in the programmed block and suppresses an
active LEN (see page 4-64).
D Programming NUM is possible only when Punching/Nibbling has
been released (MP 8001 00010) and is active.

Example:
See example in section 4.42, page 4-64 ff.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-79
and Controls

NC Functions O(), ROTAX() phi, theta, psi

4.50 Orientation Programming O(), ROTAX()


phi, theta, psi
Orients a tool (milling machine, drill, laser, gripper) anywhere in space
based on the current program coordinate system (PCS).
. If the TCP is to be moved in addition to the tool orientation move-
ment, also see function Space Coordinate Programming in the
Description of Functions.

If a tool orientation movement is programmed without a simultaneous


TCP movement, the active feed (F) affects only the orientation move-
ment. If necessary, programmed pseudocoordinates are guided along
synchronously (pseudocoordinate movements are movements that are
caused by programming direct axis positions). Alternatively, if G94 is ac-
tive, Omega programming can be used.

The orientation vector is located along the tool symmetry axis and points
to the tool holder. Various types of orientation programming are availa-
ble:

4.50.1 Vector Orientation

Effect
Programming the tool orientation is also possible using
D orientation coordinates of the orientation vector
(e.g. phi and theta).

Orientation vector
z
P (,)

theta.
+ y

phi.
+ x
Pole
4-80 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions O(), ROTAX() phi, theta, psi

D Function O(..) with polar angles (,) or Cartesian components (x,


y, z) of the orientation vector.
Vector using angle Vector using Cartesian
components

Orientation vector Orientation vector
z z
P (,) P (x, y, z)

+ z

y y

+ x y
Pole Pole x
x

D Function ROTAX(..) for defining an axis of rotation oriented anywhere


in space so that the orientation vector can be turned around it by a
specific angle using function O(..).
The axis of rotation can be programmed both with polar angles (u,
u) and Cartesian components (ux, uy, uz).

Orientation vector e u
Axis of rotation
(final orientation)

z Angle
y


Orientation vector a
(initial orientation)

TCP
x

The following applies:


D Vector orientation can be programmed only together with an axis
transformation whose 100th position is type = 2.
D The orientation motion is carried out as a rotary movement of the
orientation vector from the programmed initial orientation to the final
orientation.
D This is suitable for rotation-symmetrical tools.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-81
and Controls

NC Functions O(), ROTAX() phi, theta, psi

Programming
1. Activate the permitted axis transformation type (type of 100-th- posi-
tion = 2) with Coord(...) (see page 4-30).
2. Use the syntax shown below.

Syntax:
{<No>} {<TCP mvmt>} {<phi><j>} {<theta><J>} or
{<No>} {<TCP mvmt>} O(<j>,<J>) or
{<No>} {<TCP mvmt>} O(<rx >,<ry >,<rz >) or
{<No>} {<TCP mvmt>} ROTAX(<ju >,<Ju >) O(<b>) or
{<No>} {<TCP mvmt>} ROTAX(<ux >,<uy >,<uz >) O(<b>)
where:
<No> Block number. See page 2-20.
<TCP mvmt> Additional TCP movement.
For the syntax, please refer to the Description
of Functions under space coordinate program-
ming.
<phi> Angle name that is entered in
MP 7080 00010[4]. Default: phi
<theta> Angle name that is entered in
MP 7080 00010[5]. Default: theta
<j>,<J>,<ju >,<Ju > Absolute angle values in degrees.
Value range: 0_ j < 360_; 0_ J 180_.
If another value is programmed for J, it is auto-
matically converted to the given interval.
O(<j>,<J>) Orientation using function O(..) and polar angles
<j> and <J> of the orientation vector.
O(<rx >,<ry >,<rz >) Orientation using function O(..) and Cartesian
components <rx >,<ry >,<rz > of the orientation
vector in absolute dimensions.
Automatic standardization to 1. As a result, the
following sample entries cause the identical
orientation: O(1,2,4), O(2,4,8)
ROTAX(<ju >,<Ju >) Define the axis of rotation using polar angles (u,
u).
ROTAX(<ux >,<uy >,<uz >) Define the axis of rotation using Cartesian
components <ux >,<uy >,<uz > in absolute di-
mensions. Automatic standardization to 1.
O(<b>) Indicates (in degrees) the incremental angle
<b> around which the orientation vector is to be
turned around the axis of rotation. Values grea-
ter than 360 degrees are allowed.
The direction of rotation can be selected using
the positive/negative sign.

Special features and restrictions:


D The initial- and final orientation of the orientation vector may not run
parallel nor antiparallel, except in the case of programming RO-
TAX(..).
4-82 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions O(), ROTAX() phi, theta, psi

4.50.2 Tensor Orientation

Effect
Tool orientation is affected by orienting the entire tool coordinate system
TCS, based on the current PCS.

z z
z
TCS TCS
TCS

x x TCP
TCP
TCP x

y
y y
z

y
Gripping tool:
PCS
x TCS permanently
coupled to tool

D Programming is also possible using


D Euler angles phi , theta and psi .
As a result of successive rotations with the Euler angles, the TCS
receives its desired orientation.
D 3x3 orientation tensor (rotation matrix that realigns the entire TCS
around the TCP). The components of its column vectors (Ox, Oy,
Oz) precisely specify the TCS orientation and can be programmed
as polar angles or Cartesian components.
D Function ROTAX(..) for defining an axis of rotation oriented anyw-
here in space so that the orientation tensor can be turned around it
by a specific angle using function O(..).
The axis of rotation can be programmed both with polar angles (u,
u) and Cartesian components (ux, uy, uz).

The following applies:


D Tensor orientation can be programmed only together with an axis
transformation whose 100th position is type = 3.
D The orientation motion is carried out as a rotary movement of the
orientation tensor from the programmed initial orientation to the final
orientation.
D This is suitable only for tools that are not rotation-symmetric because
the TCS is permanently coupled to the tool in this case.

Programming
1. Activate the permitted axis transformation type (type of 100-th- posi-
tion = 3) with Coord(...) (see page 4-30).
2. Use the syntax shown below.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-83
and Controls

NC Functions O(), ROTAX() phi, theta, psi

Syntax:
{<No>} {<TCP>} {<phi><j>} {<theta><J>} {<psi><y>} or

{<No>} {<TCP>} Ox(<jx >,<Jx >) Oy(<jy >,<Jy >) or


{<No>} {<TCP>} Ox(<jx >,<Jx >) Oz(<jz >,<Jz >) or
{<No>} {<TCP>} Oy(<jy >,<Jy >) Oz(<jz >,<Jz >) or

{<No>} {<TCP>} Ox(<O11>,<O21>,<O31>) Oy(<O12>,<O22>,<O32>)


or
{<No>} {<TCP>} Ox(<O11>,<O21>,<O31>) Oz(<O13>,<O23>,<O33>)
or
{<No>} {<TCP>} Oy(<O12>,<O22>,<O32>) Oz(<O13>,<O23>,<O33>)
or

{<No>} {<TCP>} ROTAX(<ju >,<Ju >) O(<b>) or


{<No>} {<TCP>} ROTAX(<ux >,<uy >,<uz >) O(<b>)
where:
<No> Block number. See page 2-20.
<TCP mvmt> Additional TCP movement.
For the syntax, please refer to the Description
of Functions under space coordinate program-
ming.
<phi> Angle name that is entered in
MP 7080 00010[4]. Default: phi
<theta> Angle name that is entered in
MP 7080 00010[5]. Default: theta
<psi> Angle name that is entered in
MP 7080 00010[6]. Default: psi
<j>,<J>,<y> Absolute Euler angle in degrees.
AC/IC programming is permitted.
Value range: 0_ j < 360_;
0_ J 180_;
0_ y 360_.
Values outside this range are automatically con-
verted into the corresponding interval.
<j..>,<J..> Absolute angle values in degrees.
Value range: 0_ j.. < 360_;
0_ J.. 180_.
If a value outside of the range is programmed for
J.., it is automatically converted to the given in-
terval.
4-84 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions O(), ROTAX() phi, theta, psi

Ox(<O11>,<O21>,<O31>)
Oy(<O12>,<O22>,<O32>)
Oz(<O13>,<O23>,<O33>)
Ox(<jx >,<Jx >)
Oy(<jy >,<Jy >)
Oz(<jz >,<Jz >) Orientation per function Ox(..), Oy(..), Oz(..).
For example, Ox(..) defines the direction of the
x-coordinate of the TCS in the reference coordi-
nate system. The same applies analogously to
Oy(..) and Oz(..).
The direction can be specified either by the cor-
responding polar angles <j..> and <J..> or the
Cartesian components of the orientation ten-
sors column vectors.
Only absolute dimensions are allowed.
The component values of the column vectors
(o..) are automatically standardized to 1.
ROTAX(<ju >,<Ju >) Define the axis of rotation using polar angles (u,
u).
ROTAX(<ux >,<uy >,<uz >) Define the axis of rotation using Cartesian
components <ux >,<uy >,<uz > in absolute di-
mensions. Automatic standardization to 1.
O(<b>) Indicates (in degrees) the incremental angle
<b> around which the orientation tensor is to be
turned around the axis of rotation.
Values greater than 360 degrees are allowed.
The direction of rotation can be selected using
the positive/negative sign.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-85
and Controls

NC Functions O(), ROTAX() phi, theta, psi

Example:
Settings for example:
MP 1030 00110[1] for axis transformation 2: 3333301
MP 7080 00010[1]: x
MP 7080 00010[2]: y
MP 7080 00010[3]: z
MP 7080 00010[4]: phi
MP 7080 00010[5]: theta
MP 7080 00010[6]: psi

N100 G1 X10 Y20 Z30 Ox(1,0,0) Oy(0,0.707,-0.707) or


N100 G1 X10 Y20 Z30 Ox(1,0,0) Oz(0,0.707,0.707) oder
N100 G1 X10 Y20 Z30 Oy(0,0.707,-0.707) Oz(0,0.707,0.707)

z
Tensor column vectors:

1 0 0
ext = 0 eyt = 1/2 ezt = 1/2
0 -1/2 1/2
45_
ezt zt
Orientation using Euler angle:
PCS
= 90_, = 45_, = 270_ x TCS
ext xt

45_

eyt yt
y

Special features and restrictions:


D Except when ROTAX(..) is programmed, the orientation movement
always occurs on the shortest path to the final orientation.
For ROTAX(..), the direction of rotation depends on the positive/ne-
gative sign of <b>.
D The following limitations are required to uniquely generate the orien-
tation tensor:
For = 0_: the sum of and is required to specify an orientation.
For = 180_: the difference of and is required to specify an orien-
tation.
D If programming of the tensor columns results in two column vectors
being parallel or anti-parallel, it is not possible to calculate the orienta-
tion tensor.
A runtime error is issued.
4-86 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions O(), ROTAX() phi, theta, psi

4.50.3 Linear orientation movement with axis programming

. Valid only for axis transformation type 3032101.

Effect
To program the tool orientation, the position values of two rotary axes
that act on the tool are programmed (e.g. B, C).

C-axis


Orientation vector
z
P (,)

B..
+ y
B-axis

C..
+ x
Orientation Pole
vector

TCP

The following applies:


D Only the axis kinematics for which the position values of both rotary
axes can be mapped one-to-one to the orientation coordinates of the
orientation vector (e.g. phi and theta) are permitted.
D The orientation movement is performed as a linear movement in the
rotary axes.
D This is suitable for rotation-symmetrical tools.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-87
and Controls

NC Functions O(), ROTAX() phi, theta, psi

Programming
1. Activate axis transformation type 3032101 with Coord(...) (see
page 4-30).
2. Use the syntax shown below.
Syntax:
{<No>} {<TCP mvmt>} {<B><Pos>} {<C><Pos>}
where:
<No> Block number. See page 2-20.
<TCP mvmt> Additional TCP movement.
For the syntax, please refer to the Description of
Functions under space coordinate programming.
<B>, <C> Axis addresses of the rotary axes located on the tool
<Pos> Absolute axis position in degrees.

Example:
Settings for example:
MP 1030 00110[1] for axis transformation 2: 3032101
MP 7080 00010[1]: x
MP 7080 00010[2]: y
MP 7080 00010[3]: z

N10 G1 X0 Y0 Z0 B0 C0 Programming logical/physical axis


names.
N20 Coord(2) Switch axis transformation 2 on.
Linear coordinates x, y, z and
orientation coordinates phi, theta
can now be programmed.
N30 x100 y200 z300 B20 C60 Linear coordinate interpolation with
additional orientation movement.
N40 G2 x.. y.. z.. I.. J.. B20 C60 TCP helical movement with addi-
tional orientation movement.
N50 G1 B20 C10 Pure orientation movement. TCP
remains constant.
N60 Coord(0) Axis transformation off.
:

Special features and restrictions:


D Axis transformation type 3032101 must be active.
D Special path search logic avoids rotary axis rotations of more than
180 degrees.
4-88 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions O(), ROTAX() phi, theta, psi

4.50.4 Linear orientation movement with coordinate programming

. Valid only for axis transformation type 3232101.

Effect
Programming the tool orientation is also possible using:
D orientation coordinates of the orientation vector
(e.g. phi and theta).

Orientation vector
z
P (,)

theta.
+ y

phi.
+ x
Pole

D Function O(..) with polar angles (,) or Cartesian components (x,


y, z) of the orientation vector.

Vector using Cartesian


Vector using
components
angle

Orientation vector Orientation vector
z z
P (,) P (x, y, z)

+ z

y y

+ x y
Pole Pole x
x

D The basic axis kinematics is not important.


D The orientation movement occurs as a linear interpolation in and ,
i.e. as a straight line in a theoretical /plane.
D This is suitable for rotation-symmetrical tools.

Programming
1. Activate axis transformation type 3232101 with Coord(...) (see
page 4-30).
2. Use the syntax shown below.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-89
and Controls

NC Functions O(), ROTAX() phi, theta, psi

Syntax:
{<No>} {<TCP mvmt>} {<phi><j>} {<theta><J>} or
{<No>} {<TCP mvmt>} O(<j>,<J>) or
{<No>} {<TCP mvmt>} O(<rx >,<ry >,<rz >)
where:
<No> Block number. See page 2-20.
<TCP mvmt> Additional TCP movement.
For the syntax, please refer to the Description
of Functions under space coordinate program-
ming.
<phi> Angle name that is entered in
MP 7080 00010[4]. Default: phi
<theta> Angle name that is entered in
MP 7080 00010[5]. Default: theta
<j>,<J> Absolute angle values in degrees.
Value range: 0_ j < 360_; 0_ J 180_
O(<j>,<J>) Orientation using function O(..) and polar angles
<j> and <J> of the orientation vector.
O(<rx >,<ry >,<rz >) Orientation using function O(..) and Cartesian
components <rx >,<ry >,<rz > of the orientation
vector in absolute dimensions.
Automatic standardization to 1. As a result, the
following sample entries cause the identical
orientation: O(1,2,4), O(2,4,8)

Example:
Settings for example:
MP 1030 00110[1] for axis transformation 2: 3232101
MP 7080 00010[1]: x
MP 7080 00010[2]: y
MP 7080 00010[3]: z
MP 7080 00010[4]: phi
MP 7080 00010[5]: theta
N10 G1 X0 Y0 Z0 B0 C0 Programming logical/physical axis na-
mes.
N20 Coord(2) Switch axis transformation 2 on.
Linear coordinates x, y, z and
orientation coordinates phi, theta
can now be programmed.
N30 x1 y2 z3 phi5 theta5 Linear coordinate interpolation with addi-
tional orientation movement.
N40 Coord(0) Axis transformation off.

Special features and restrictions:


D Axis transformation type 3232101 must be active.
D Special path search logic avoids rotary axis rotations of more than
180 degrees.
D Programming ROTAX(... | O(<b>) is not possible.
4-90 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions OvrDis, OVD OvrEna, OVE

4.51 Feed 100%, OvrDis, OVD,


OvrEna, OVE

Effect
The program control influences the effect of the feedrate potentiometer
for feedrate and rapid travel.
Both functions are in effect in the manual data input and automatic
operating modes.

Programming
Syntax:
OvrDis Feed potentiometer OFF
The feedrate is set to 100% of the programmed
value irrespective of the feedrate potentiometer.
Abbreviation: OVD
OvrEna Feed potentiometer ON
The feedrate depends on the position of the
feedrate potentiometer.
Abbreviation: OVE

The following applies:


D Both functions are modal and deselect each other mutually.
D The power-up state can be specified in the machine parameters.
D Both functions may be written together with other path conditions in
the same block.

Example:
: Feed potentiometer set to
100%.
N40 OVD G1 X5 Z-2 F200 S100 M4 Deactivate feed potentiometer.
: Switch feed potentiometer to
40%, feedrate stays at 100%.
N80 OVE X100 Y50 Activate feed potentiometer.
Feedrate switches to 40%.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-91
and Controls

NC Functions PathAcc, PAC

4.52 Change the Maximum Path Acceleration PathAcc, PAC

Effect
In the parts program, reduces the upper limits for
D path acceleration and
D path deceleration.
Both the acceleration and deceleration values are preset using the ma-
chine parameters and can be switched together or separately in the
parts program.

. The programmed or preset path acceleration can be limited by the


maximum permitted axis accelerations of the axes participating in
the path.

Programming
Syntax:
PathAcc(ACC<Value>) Setting of the path acceleration and
deceleration together.
PathAcc({UP<Value1>,} Setting the path-acceleration and de-
{DOWN<Value2>}) celeration separately.
PathAcc() or Reactivate the acceleration values
PathAcc(0) from MP 7030 00210 and
7030 00220.
Abbreviation: PAC(..)

where:
<Value> Acceleration value. Depending on the currently active mea-
suring units (G71/G70), the control interprets the program-
med value as 1000 inch/s2 or m/s2.
<Value1> Value for acceleration. Otherwise, the same as for <Value>.
<Value2> Value for deceleration. Otherwise, the same as for <Value>.

Special features and restrictions:


D The maximum programmable acceleration values are limited at all ti-
mes by the machine parameter values.
D We recommend that the function be programmed in a separate block.
4-92 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions PathAcc, PAC

Example:
N30 G71 Switch on metric programming.
N40 PAC(UP1.5) Set path acceleration to 1.5 m/s2.
:
N140 PAC(ACC5) Set path-acceleration and -deceleration to 5
: m/s2.
N200 PAC(UP3.5,DOWN2) Set path acceleration to 3.5 m/s2 and path-
: deceleration to 2 m/s2.
N240 PAC() Reset acceleration values to machine para-
: meter setting.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-93
and Controls

NC Functions PosDepHSOut, PHS

4.53 Position-Dependent High-Speed Output PosDepHSOut, PHS

Effect
Affects the status of a high-speed (HS) output using a programmed tra-
versing movement.
As soon as the command NC position, based on the start or end of the
current block, reaches a programmable value, the HS output is set or re-
set, depending on the programming.
How long the output is to remain set after the specified event has occur-
red can be programmed.

. Setting the parameters of available HS outputs: using MP


4075 00102.

Programming
Syntax:
PosDepHSOut(<Mode>{,{<Distance>}{,<Duration>}})

Abbreviation: PHS(..)
where:
<Mode> Desired method of operation of the function.
Input values: 0, 1 or -1.
0 Modally saves programmed data using <Distance>
and/or <Duration>.
The current status of the HS output is not changed.
1 Modally saves programmed data using <Distance>
and/or <Duration> and sets the HS output.
The relevant modal data values apply to the unpro-
grammed parameters.
-1 Resets the HS output.
If a <Distance> is programmed, it has only a local effect
for this block. If a <Duration> is programmed, it is ignored.
<Distance>Distance to the start/end of the block where, when it is
attained, the signal is to be set (in mm/inches).
Default value: 0
0: At end of block
greater than 0: Distance to start of block
less than 0:Distance to end of block
<Duration> Maximum time that the HS output is switched on (in ms).
Range of values: 0.5 - 10000.0
Programmed values are internally rounded to the next larger
integer multiple of the NC cycle time.
4-94 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions PosDepHSOut, PHS

Examples:
:
N05 G71
N10 PHS(0,-1.2,40) Configure function.
: In a subsequent call using PHS(1) syn-
: tax, the HS output is set for approx.
: 40 ms about 1.2 mm before attaining the
: end point.
N210 G1 G91 F1000
N220 X10 Y23 PHS(1) Set HS output according to configuration
: in N10.
:
N330 X10 PHS(1,0.1,900) Set HS output for max. 900 ms 0.1 mm
: after the start position.
N350 X20 PHS(-1,-0.3) Reset HS output 0.3 mm before the end
: position.

Special features and restrictions:


D 1 HS output is supported per channel.
D The function has an effect on a traversing movement only if it is pro-
grammed in the same block.
D A set HS output is reset only after the ON time has elapsed. A control
reset does not affect this time.
D <Distance> always refers to the current command position from the
NC block.
System-related delays (caused by e.g. drive functions or axis coa-
sting) are not taken into account here.
D If a new PHS job occurs during an elapsing ON time, the NC deletes
the still-active job and executes the new job.

. If no signal change occurs on the HS output in the case of two sub-


sequent PHS jobs, the external hardware is generally not capable
of recognizing the new job.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-95
and Controls

NC Functions PmTSel, PMS

4.54 Activate Placement Tables PmTSel, PMS

Effect
Activates placement tables (correction tables of the Inclined plane
placement). Such correction tables are stored as XML files in the file sy-
stem of the control.

Programming
Syntax:
PmTSel({<Path>}<Filename>)

Abbreviation: PMS(..)
where:
<Path> Optional path information for the directory in which <File-
name> is stored.
If there is no information, the file will be searched in the /da-
tabase directory.
If <Filename> is not present there, the control uses the search
path for subroutines so that the search for <Filename> can
also be carried out in other directories.
<Filename> File name of the placement table, incl. the file extension.
Tables with standard names (PM<Number>.pmt) can be
activated directly using the number, e.g.
PmTSel(3) activates table PM3.pmt.

. Please refer to the Operating Instructions for how to create and edit
placement tables.
4-96 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions PolarPol, POP

4.55 Polar Coordinate Programming

4.55.1 Define pole PolarPol, POP

Effect
D Defines the origin of the polar coordinate system based on the active
plane of the active program coordinate system.
D Sets polar angle 1 for polar coordinate programming (standard ad-
dress: A; definable in MP 8005 00001) to 0 degrees.
D Sets polar angle 2 for polar coordinate programming (standard ad-
dress: B; definable in MP 8005 00002) to 90 degrees.

Programming
Syntax:
PolarPol(<PCValue>,<SCValue>) Specify pole.
PolarPol(ACTPOS) Set pole to current position.
PolarPol() or Set pole to coordinate 0.0.
PolarPol(0)
Abbreviation: POP(..)

where:
<PCValue>Pole value for the primary coordinate.
<SCValue>Pole value for the secondary coordinate.

Special features and restrictions:


D If PolarPol is not used, the NC uses the origin of the active program
coordinate system as the pole.
D A programmed pole remains effective for the current plane only until
the next time that the plane is switched (see page 3-28).

Example:
:
N10 G18 switch to the ZX plane with Z as the primary
: and X as the secondary coordinate.
N30 G0 X10 Z25 Positioning movement in rapid traverse to
: Cartesian coordinates X10 and Z25.
N40 POP(ACTPOS) The current position values (PCValue=25,
: SCValue=10) are taken on for the pole defi-
nition.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-97
and Controls

NC Functions PolarPol, POP

4.55.2 Programming polar coordinates


The IndraMotion MTX permits the programming of polar coordinates
both in a plane (2D) and in space (3D).
The desired end point is entered using
D radius value (distance of target point P from pole)
D polar angle 1 and
D polar angle 2.

C R: Radius value (= XR=YR)


Y A: Polar angle 1.
B: Polar angle 2.

YR +
P

B R
A

Pole XR X

Example: Polar coordinates in the plane with active G17

Radius value:
An axis address is always used to program the current working plane
(e.g. X or Y for an active G17). This programmed coordinate is also
called a radius coordinate.
In the case of absolute dimension programming, it indicates the distance
of the target point from the pole; in the case of incremental programming,
it indicates the distance of the target point from the starting point.
If both possible axis addresses are programmed in a single block, a run-
time error occurs.

Polar angle 1:
D By default, this is programmed as address A; it always lies in the cur-
rent working plane.
D Each programmed polar angle 1 refers to the last-programmed ra-
dius coordinate axis. A positive value indicates rotation in the mathe-
matically positive sense; it remains in effect until a new value is
programmed.
If incremental programming is active, the programmed angle is calcu-
lated incrementally.
D When polar coordinate programming is activated with POL, polar an-
gle 1 is set to a value of 0 degrees.
4-98 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions PolarPol, POP

Polar angle 2:
D By default, this is programmed as address B; if absolute dimension
programming is active, it describes the angle between the normal
axis (to the current working plane) and the vector of the current pole to
the target point. It remains in effect until a new value is programmed.
If incremental programming is active, the programmed angle is calcu-
lated incrementally.
D When polar coordinate programming is activated with POL, polar an-
gle 2 is set to a value of 90 degrees.
In this case, the target point is located precisely in the active working
plane. Now the polar coordinates have an effect only in the plane. All
other coordinates outside of the working plane are interpreted accor-
ding to Cartesian coordinates. This applies especially to programmed
coordinate values of the current normal axis!
D Real spatial polar coordinates (spherical coordinates) occur if polar
angle 2 becomes unequal to 90 degrees. Programming coordinate
values of the current normal axis then leads to a runtime error. Howe-
ver, all coordinates outside of the 3D space may be included simulta-
neously in programming. As in the 2D case, they are also interpreted
according to Cartesian coordinates.
D If polar angle 2 is 0 degrees, the value of polar angle is unimportant
because the programmed point lies exactly vertically over the pole.

C R: Radius value (= XR=YR)


Y P A: Polar angle 1.
B: Polar angle 2.

R
YR

B +
A

Pole XR X

Example: Polar coordinates in space with active G17

. The default addresses for polar angles 1 and 2 can be changed


using machine parameters 8005 0001 and 8005 0002. Therefore,
they may be different in your system.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-99
and Controls

NC Functions PolarPol, POP

Example: Polar coordinate programming in absolute dimensions


N10 G18 Plane switch. Here: switch to the ZX plane with
: Z as the primary and X as the secondary coor-
: dinate.
N40 POP(25,10) Pole definition in the current plane (here: with
: Cartesian coordinates Z=25 and X=10).
:
N50 G1(POL) Z20 A70 Path movement in polar coordinates according
: to P2 (see Fig.): P2 is defined by the absolute
: distance from the pole (here: 20 mm) and the
: polar angle 1 (here: A=70 degrees), based on
the programmed radius axis (here: Z axis).

X P2 : Traversed path

20
20
A70

10 Z
Pole P1

C
P 10 20 30 40

N60 G1(POL) X20 A90 Path movement in polar coordinates according


: to P3 (see Fig.):
: P3 is defined by the absolute distance from the
: pole (here: 20 mm) and polar angle 1 (here:
: A=90 degrees), based on the programmed ra-
: dius axis (here: X axis).
: Alternatively, the following programming is also
: possible:
: N60 G1(POL) Z20 A180
: or
: N60 Z20 A180

X P2 : Traversed path
X
: Position vector
20
A90
P3 Pole
10 Z
P1
20
C
P 10 20 30 40
4-100 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions PolarPol, POP

Example: Polar coordinate programming in incremental dimensions


N10 G17 G90 G0 X0 Y0 Starting position: P0
N20 G1(POL) X200 A0 P1
N30 G91 Y200 A30 P2
N40 A60 P3
N50 A60 P4
N60 A60 P5
N70 A60 P6
N80 A60 P7
N90 X0 P0
N100 M30

Y Y
: Traversed path
P3 A60 P2
A30

P4 P0 P1
P7 X

P5 P6
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-101
and Controls

NC Functions PoleSet, PLS

4.56 Define Mirroring/Rotation Point PoleSet, PLS

Effect
This function specifies the absolute position of the pole for the Mirror,
Scale and Rotate input tools. The defined pole is then the reference point
of these input tools, thus providing the mirroring/rotation point.

. The function is not required if mirroring or rotation is to take place


with reference to the program zero point.

The following applies:


D PoleSet is modally effective. The position of the pole refers to the cur-
rent program coordinate system and thus remains in effect until it is
reset to the program coordinate origin or is redefined.
D The function does not cause any axis traversing.
D The function may be written in the same block as other path condi-
tions and input tools.
D The programmed pole refers to the functions Mirror, Scale and Ro-
tate.

Programming
Syntax:
PoleSet(<Coordinates>) Set pole to given coordinates. The given
coordinates are to be separated by
commas
(e.g.: PoleSet(X5,Y2)).
PoleSet(0) or reset the pole to the origin of the
PoleSet() or program coordinate system.
Abbreviation: PLS(..)

Example:
:
N30 PLS(X5,Y2) Set the mirror/rotation point to a position of
: X=5 and Y=2.
N130 PLS() Reset the mirror-/rotation point to the
: program coordinate origin.

Special features and restrictions:


D The position of the pole must be entered absolutely, i.e. based on the
current program zero point.
4-102 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions PosMode, PMD DC ACP ACN

4.57 Positioning Type for Endless Axes PosMode, PMD


Local Positioning Type for Endless Axes DC, ACP, ACN

Effect
Specifies in which direction axes of type endless are to rotate during a
positioning procedure.
The following applies:
D As opposed to PosMode, DC(...), ACP(...) and ACN(...) have a
block-by-block effect, overriding the active positioning type of the
correspondingly programmed axis in the current block.
D Position information that is programmed in combination with DC,
ACP and ACN functions are always interpreted as absolute position
values.
Programming
Syntax:
PosMode(<Adr><Type>) Activate the positioning type for the axis
with address <Addr> according to <Type>.
Several axes may be programmed in the
parentheses. Activate the positioning type
for nonprogrammed rotary/endless axes in
the current channel according to
MP 1003 00005.
PosMode() or Activate the positioning type for all axes in
PosMode(0) the current channel according to
MP 1003 00005.
Abbreviation: PMD(..)

<Addr>=DC(<Value>) Axis <Addr> approaches the absolute posi-


tion <Value> along the shortest path.
<Addr>=ACP(<Value>) Axis <Addr> approaches the absolute posi-
tion <Value> in the mathematically positive
direction (see the following note).
<Addr>=ACN(<Value>) Axis <Addr> approaches the absolute posi-
tion <Value> in the mathematically nega-
tive direction.
where:
<Addr>: Axis address.
Axes of type endless are permitted.
<Value>: Path information for <Addr>.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-103
and Controls

NC Functions PosMode, PMD DC ACP ACN

<Type>: Positioning type.


0: no positioning logic.
The direction of travel always results solely from the
difference between the old and the new position.
1: shortest path.
The maximal traverse path of the axis is no more
than half of the relevant modulo value.
2: According to programmed positive/negative sign:
+: Clockwise rotation; -: Counterclockwise rota-
tion.

. Mathematically positive direction: Counterclockwise sense of ro-


tation seen from a coordinate axis in the direction of the coordinate
origin.

Example:
N40 B=ACP(-258) Irrespective of PosMode, the physical axis desi-
: gnated B traverses in the mathematically positive
: direction to the position 258 degrees. The positive/
: negative sign is ignored.
N80 PMD(A1C2) Positioning type of
: Axis A: shortest path
: Axis B: according to MP 1003 00005
: Axis C: positive/negative sign

Special features and restrictions:


D Several DC, ACP and ACN functions (for correspondingly different
axes) can be programmed in the same block.
D DC, ACP and ACN functions are effective only for synchronous axes
of type Rotary or Endless. If they are programmed in conjunction
with other axis types, the control ignores them.
D Negative signs in the position information of DC, ACP and ACN func-
tions are ignored.
4-104 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions PrecProg, PRP

4.58 Precision Programming PrecProg, PRP


Effect
Reduces the feedrate at contour transitions and on circular path seg-
ments so that a preset precision can be maintained.
Alternatively the precision can be influenced by the information for the
D maximum permitted contour- or radius error e on the contour tran-
sition or for arcs, or the
D maximum path-overtravel d (distance from corners) that is not to be
exceeded when traversing through a contour transition.

Comm3 = command contour; command position


= actual contour; actual position with PrecProg
= actual contour; actual position
Contour error without PrecProg
Comm2 Command contour Comm4

Command contour
Act4
Actual contour with PrecProg
Act3
Act5 Actual contour
Comm1 without
Actual contour without PrecProg Comm5
PrecProg
Act6
Act2
Contour error at block transition without
PrecProg

d Comm3 e
Ract(without
e PrecProg)

Comm2 Act3 Co. 4 Ract(with PrecProg)


Act4
Act5 Rcomm
Command contour
Act2 Radius error on arc
Comm1 Comm5
(at constant path velocity)
Act6
Actual contour with PrecProg
Act1 Comm6

Contour error at block transition with


PrecProg

. In contrast to the Precision function (G61/G62; see page 3-49),


the feedrate does not have to be reduced to 0 at a block transition.
See Special features and restrictions.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-105
and Controls

NC Functions PrecProg, PRP

Programming
Syntax:
PrecProg or Precision programming ON.
PrecProg(1) Max. permitted contour-/radius error e
according to MP 8003 00001.
PrecProg(EPS<e>) Precision programming ON.
Maximum permitted contour/radius er-
ror: <e>.
PrecProg(DIST<d>) Precision programming ON.
Maximum permitted path coasting: <d>.
For circular path segments: Take e value
from MP 8003 00001 into account.
PrecProg() or Precision programming OFF.
PrecProg(0)
Abbreviation: PRP(..)

where:
<e>: Maximum permitted contour/radius error in mm/inches (de-
pending on G70/G71).
<d>: Maximum permitted path coasting in mm/inches (depending
on G70/G71).

Special features and restrictions:


D All affected axes must be set with the identical dynamics.
D If G8 and G62 are not active, braking to v=0 occurs at every block
transition.
D Precision programming supplies sensible results only if the influence
of the acceleration on coasting is ignored.
4-106 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions PtBlkEnd, PTE

4.59 Stroke Release Time (Interpolation End Point) PtBlkEnd, PTE

Effect
. Works together with functions Punch (see page 4-110) and Nib-
ble (see page 4-76).

The function
D defines time reference event NC interpolator is reaching the end
point of the traverse movement for the given axes and
D specifies the period between the time reference event and the stroke
release.

In this manner, the stroke release point based on the time reference
can be offset as far as desired. The following is possible:
D Early stroke release
(e.g. to compensate for a constant, application-dependent waiting
time that is caused by signal processing) and
D Delayed stroke release
(e.g. to increase the positioning precision for axes with lower dyna-
mics, or for punching with hold-down devices).

. Additional functions that influence the stroke release time:


PtBlkEnd (see page 4-106)
PtInpos (see page 4-109).

Programming
Syntax:
PtBlkEnd(<Axis><Time>{,<Axis><Time>}...)

Abbreviation: PTE(..)
where:
<Axis> Logical axis name.
<Time> Desired period (in ms) between the time reference event
and the stroke release.
0: stroke release at time reference event.
negative value: early stroke release
positive value: delayed stroke release

Special features and restrictions:


D Functions PTD, PTE and PTI act modally and cancel each other mu-
tually.
D Punching or nibbling must be applied in MP 8001 00010 .
D All programmed time values are rounded up to match the SERCOS
cycle time slots.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-107
and Controls

NC Functions PtBlkEnd, PTE

D In the case of traverse movements in which several axes with va-


riously defined time references and waiting times participate, the
weakest axis determines the actual stroke release behavior. Please
note the following:
D Axes where the time reference = Inpos-window (see page 4-109)
are weaker than axes where the time reference = Interpolation
end point.
D If the time reference is identical, the weakest axis is the one with
the highest waiting time.
D Function PtDefault (see page 4-108) can be used to reset the stroke
release of all axes in the system to the default values.

Example:
- Axis configuration: X, Y, C
- SERCOS cycle time: 3 ms
Setting the stroke release times:
:
N10 PTE(X-10) Time reference event for axis X:
: NC interpolator is reaching the end point of the
: traverse movement.
: Early stroke release by 10 ms.
N20 PTI(Y10,C2) Time reference event for axes Y and C: Inpos win-
: dow reached
: (For the function, see page 4-109).
: Y-Axis: Delayedstrokerelease by 10 ms.
: C-Axis: Delayedstrokerelease by 2 ms.

Effect during traverse movements:


:
N100 G1 Y20 C10 Y determines the stroke release behavior because
: a longer waiting time has been programmed with
: an identical time reference (see N20).
: Since the waiting times are rounded up to the
: SERCOS cycle time slots, an actual delayed stroke
: release of 12 ms results.
:
N110 X20 C20 C determines the stroke release behavior because
: axes where the time reference = Inpos window
: are weaker than axes where the time reference =
: Interpolation end point.
: Since the waiting times are rounded up to the
: SERCOS cycle time slots, an actual delayed stroke
: release of 3 ms results.
:
N120 X30 X determines the stroke release behavior because
: only X is moved.
: Actual early stroke release: -9 ms.
N130 PTD Set a stroke release of all axes in the system ac-
: cording to MP 8001 00020 and MP 8001 00021
: (For the function, see page 4-108).
4-108 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions PtDefault, PTD

4.60 Stroke Release Time (Set to Default) PtDefault, PTD

Effect
. Works together with functions Punch (see page 4-110) and Nib-
ble (see page 4-76).

Set the time of the stroke release of all axes in the system according to
the values defined in MP 8001 00020 and MP 8001 00021.

Programming
Syntax:
PtDefault

Abbreviation: PTD

Special features and restrictions:


D Functions PTD, PTE and PTI act modally and cancel each other mu-
tually.
D Punching or nibbling must be applied in MP 8001 00010 .

Example:
See page 4-107.

. Additional functions that influence the stroke release time:


PtBlkEnd (see page 4-106)
PtInpos (see page 4-109).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-109
and Controls

NC Functions PtInpos, PTI

4.61 Stroke Release Time (Inpos Window) PtInpos, PTI


Effect
. Works together with functions Punch (see page 4-110) and Nib-
ble (see page 4-76).

The function
D defines time reference event Inpos window reached for the given
axes and
D specifies the period between the time reference event and the stroke
release.

In this manner, the stroke release point based on the time reference
can be offset as far as desired (e.g. to increase the positioning precision
for axes with lower dynamics, or for punching with hold-down devices).

. Additional functions that influence the stroke release time:


PtBlkEnd (see page 4-106)
PtInpos (see page 4-109).

Programming
Syntax:
PtInpos(<Axis><Time>{,<Axis><Time>}...)

Abbreviation: PTI(..)
where:
<Axis> Logical axis name.
<Time> Desired period (in ms) between the time reference event
and the stroke release.

Special features and restrictions:


D Functions PTD, PTE and PTI act modally and cancel each other mu-
tually.
D Punching or nibbling must be applied in MP 8001 00010 .
D All programmed time values are rounded up to match the SERCOS
cycle time slots.
D In the case of traverse movements in which several axes with va-
riously defined time references and waiting times participate, the
weakest axis determines the actual stroke release behavior. Please
note the following:
D Axes where the time reference = Inpos-window (see page 4-109)
are weaker than axes where the time reference = Interpolation
end point.
D If the time reference is identical, the weakest axis is the one with
the highest waiting time.
D Function PtDefault (see page 4-108) can be used to reset the stroke
release of all axes in the system to the default values.
For an example, see section 4.59.
4-110 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions Punch, PUN

4.62 Punching Punch, PUN

Effect
Switches the Punching function on or off.
When punching is activated, a stroke is released
D at the end of each programmed traversing movement (individual
stroke operation), or
D at the end of every partial path generated by function NUM (see
page 4-78) or LEN (see page 4-64)
The subsequent traversing motion always starts before the stroke is
finished.
. Functions to influence the stroke release time:
PtDefault (see page 4-108)
PtBlkEnd (see page 4-106)
PtInpos (see page 4-109).

Programming
Syntax:
Punch(1) or Punching ON.
Punch

Punch(0) or Punching OFF.


Punch()

Abbreviation: PUN(..)

Special features and restrictions:


D Punching must be released using MP 8001 00010.
D The function already has a modal effect on traversing movements
that are programmed in the same block.
D The control can use function NUM or LEN to automatically gene-
rate partial paths from the programmed distance traversed; a stroke
is released at the end of each of these partial paths.
D If nibbling is switched on (see page 4-76), the function deselects pun-
ching.
D Blocks that do not contain axis coordinates from the active plane also
do not release a stroke.
D If the PLC suppresses the stroke release, processing remains at the
stroke release position until the PLC releases the stroke release.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-111
and Controls

NC Functions Punch, PUN

Example:
- G90 is active (absolute dimension programming)
- active plane: X/Y
- current position: X=0, Y=0, C=0
:
N10 C10 Punch(1) Punching ON. C-axis rotates to 10 de-
grees. No stroke because the X- and Y-
axes are not programmed.
N20 C60 C-axis rotates to 60 degrees. No stroke
because the X- and Y-axes are not pro-
grammed.
N30 X0 No traversing movement because the
X-axis is already located on position 0.
A stroke occurs because the X-axis is
located in the active plane.
N40 LEN=12 Divide the following traversing blocks into
identical partial paths with a maximum of
12 mm.
N50 X110 The traversing block is divided into 10
identical 11-mm partial paths. Strokes
are executed in positions X11, X22, X33
... X99, X110
N60 Y30 NUM=3 Overrides the modally effective LEN
(N40) for the current block.
Divide the traversing blocks into 3 identi-
cal partial paths. Strokes at Y10, Y20,
Y30.
N70 Y90 LEN from N40 is in effect again.
Strokes at Y42, Y54, Y66, Y78, Y90.
N80 X50 Y50 Punch() Punching OFF.
: Traversing movement to X=50, Y=50.

90
LEN=12 78
Y42 through
Y90 66
(5 path
segments 54
at 12 mm each) 42
NUM=3 30
Y10 through
Y30 20
(3 path 10
segments
0
at 10 mm each)
0 11 22 33 44 55 66 77 88 99 110 X

LEN=12
X0 through X110
: Stroke
(10 path segments of 11 mm
each)
4-112 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions RedTorque, RDT

4.63 Torque Reduction RedTorque, RDT


Effect
RedTorque suppresses the value of machine parameter 1003 00010
with the programmed value on an axis-to-axis basis.
The value of the machine parameter itself is not changed.
In this way, the reduced maximum torque of an axis that can go into effect
after a positive slope of axis interface signal Torque reduction
(qAx_TrqLim) is no longer permanently limited to the value of the ma-
chine, but can instead be set dynamically.
Programming
Syntax:
RedTorque(<Axis1> Set the values for the reduced maximum
{,<Axis2>{, ...}}) torque to the programmed values.
RedTorque(0) or Set the values for the reduced maximum
RedTorque() torque to the machine parameter values
(MP 1003 00010).
Abbreviation: RDT(..)

where:
<Axis i>: Physical or logical axis designation, incl. the
corresponding maximum torque as a % of the axis
standstill torque.
Range of values: 0 to 500%.

Example:
N8 RDT(X5) With the next positive edge of the relevant axis-based
: Torque reduction signal, the maximum torque for the axis
: (X in this case) will be limited to 5% of its axis -standstill tor-
que.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-113
and Controls

NC Functions RemAxis, RAX

4.64 Remove Axis from Axis Group RemAxis, RAX

Effect
Removes a synchronous axis from the calling channel. This turns a syn-
chronous axis into an asynchronous axis.
The asynchronous axis can then be programmed in any channel using
its physical axis name.

. For detailed information about the Axis transfer function, see the
Description of Functions.

Programming
Syntax:
RemAxis(<PAN> | <PAI> | <LAN>{,<PAN> | <PAI> | <LAN>}...)

Abbreviation: RAX(..)
where:
<PAN> Physical axis name.
Specifies the axis that is to be removed from the current
channel.
<PAI> Physical axis index.
Same effect as <PAN>.
<LAN> Logical axis name.
Same effect as <PAN>.

Special features and restrictions:


D Block preparation is not interrupted by removing an axis.
D Invalid axis names generate an error message.
D If an axis to be removed is defined in the system but is already no lon-
ger present in the current channel, an error message is not issued.
D Axis positions in the same block must always be programmed accor-
ding to RemAxis(...).

Example:
:
N030 RAX(XP,2,Z) Physical axis XP, the physical axis assigned
: index 2 and logical axis Z are removed from
the channel.
4-114 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions RemLogName, RLN

4.65 Remove Logical Axis Name RemLogName, RLN

Effect
Deletes the logical axis name of a synchronous axis in the calling chan-
nel.
The axis remains in the channel, but can be programmed there only
using its physical axis name or physical axis index.

. For detailed information about the Axis transfer function, see the
Description of Functions.

Programming
Syntax:
RemLogName(<PAN> | <PAI> | <LAN>{,<PAN> | <PAI> | <LAN>}...)

Abbreviation: RLN(..)
where:
<PAN> Physical axis name.
Specifies the axis whose logical axis name is to be remo-
ved from the current channel.
<PAI> Physical axis index.
Same effect as <PAN>.
<LAN> Logical axis name.
Same effect as <PAN>.

Special features and restrictions:


D A given axis must be at a standstill. If this is not the case, the control
generates an error message and terminates the program.
D Axis positions in the same block must always be programmed accor-
ding to the expression RemLogName(...).

Example:
:
N030 RLN(YP,3,Z) The logical names of physical axis YP, the
: 3rd physical axis and logical axis Z are re-
moved from the calling channel.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-115
and Controls

NC Functions REPOSTP

4.66 Asynchronous Subroutines:


Define the Point of Return to Path in Asynchronous Subroutine
REPOSTP
Effect
Defines whether the control, after the end of the asynchronous subrou-
tine in which function REPOSTP is programmed, is to position on
D the starting point
D the end point, or
D the point of interruption
of a traversing block that may have been interrupted.
If no traversing block was active at the time of interruption, the control
always positions on the last active coordinates.
REPOSTP thus suppresses a point of return to path that was set earlier
using ASPRTP for the currently running asynchronous subroutine (see
page 4-7).

. You can find extensive information regarding the use and parame-
ter settings of asynchronous subroutines in the Description of
Functions.
Programming
Syntax:
REPOSTP(<Point>)
where:
<Point> Desired point of return to path:
1: Starting point
2: End point
3: Interruption point

Special features and restrictions:


D The function has been designed for use in an asynchronous subrou-
tine.
D The point of return to path set previously using ASPRTP (see page
4-7) for the running asynchronous subroutine automatically goes
back into effect after the end of the subroutine.
D Any correction modifications made within an asynchronous subrou-
tine are automatically taken into account in the internal calculation of
the required point of return to path.
4-116 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions Rotate(...), ROT(...)

4.67 Input Tool: Rotate Rotate(...), ROT(...)

Effect
The Rotate function is one of the input tools.
The control rotates a programmed contour in the active plane (for pla-
nes, please refer to G17, G18, G19 or G20).
Rotation always refers to the current point of rotation (see function Pole-
Set, page 4-101). If this was not explicitly programmed, the current pro-
gram zero point is the point of rotation.
Using this function, you need program only once recurrent programming
steps that are rotated around a specific angle.
In addition, you do not have to convert the dimensions of angled work-
pieces to the basic workpiece coordinate system; you simply take them
over directly from a production drawing and specify the corresponding
angle of rotation. The control will do the rest.

. Rotation is an input tool; as a result, it does not change the current


program coordinate system. An input tool merely provides another
input method for the program coordinates.
Rotate can also be used together with Mirror and Scale.

The following applies:


D The function acts modally. It remains active until it is switched off.
D It may be programmed in the same block as other path conditions and
input tools.

Programming
Syntax:
Rotate(<Angle of rotation>) Switch on rotation around the desired
<angle of rotation>.
Rotate(0) or Switch off rotation for all the axes in the
Rotate() channel. Set all angles of rotation to 0.
Approached axis positions are retained
until they are reprogrammed.
Abbreviation: ROT(..)

where:
<Angle of rotation> > 0: Counterclockwise rotation
< 0: Clockwise rotation
= 0: Switch off rotation.
All following programmed coordinates of the active
plane are rotated around the rotation point (see
PoleSetpage 4-101).
Rotation does not become active until the next
traversing information.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-117
and Controls

NC Functions Rotate(...), ROT(...)

Special features and restrictions:


D The function takes into account the interpolation parameters in the
case of circular interpolation
D It influences the programmable contour shift. See page 4-124.
D It does not influence:
D zero offsets (G54-G59.5; see page 3-46),
D program coordinate offsets (Trans or ATrans; see page 4-153),
D setting of the program position (SetPos; see page 4-123),
D approaching reference point coordinates (G74 ; see page 3-55),
D approaching axis position coordinates (G76 ; see page 3-58),
D milling radius and tool length correction values.

Example:
:
N30 ROT(45) Rotation ON. All following programmed coordinates of
: the active plane are rotated counterclockwise by 45
: degrees around a possibly programmed rotation point.
:

Effect of: ROT(45) Effect of: ROT(-45)


(Rotation point is program zero point) (Rotation point is program zero point)

Y Y

P
P X X

Rotating an orientation vector


An orientation vector is rotated around the normal of the active plane.
Any scaling that may be active or a mirror/rotation point have no effect on
the result.
Syntax as described under Programming.
4-118 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions RoundEps, RNE

4.68 Rounding Corners with Specification of the Deviation


RoundEps, RNE

Effect
This function inserts tangential transition arcs between 2 linear blocks in
the main plane.
On the one hand, this leads to a minor modification of the programmed
contour at these corners, but on the other hand, continuous speed and
acceleration patterns are achieved during interpolation.
Programming
Syntax:
RoundEps(<Deviation>) Rounding corners ON between 2 li-
near blocks.
RoundEps(DEF) Rounding corners ON between 2 li-
near blockswith default deviation
from MP 7050 00110.
RoundEps(0) or Rounding corners off between 2 li-
RoundEps() near blocks.

Abbreviation: RNE(..)

where:
<Deviation> Maximum permitted deviation (in mm) between the
modified and the programmed contour. Positions after
the decimal point are allowed.
The control calculates a suitable tangential transition
arc on its own.

Special features and restrictions:


D Functions ChLength, ChSection, RoundEps and Rounding act
modally and cancel each other mutually.
D The control does not execute corner rounding if
D at least one of the two neighboring blocks is not a linear block.
D at least one of the two neighboring blocks has a path segment out-
side the selected principal plane, or
D at least one of the two neighboring blocks has a traversing path
which is smaller than the path set in MP 7050 00120 (2 to 90 mm,
default value: 10 mm), or
D the block transition is considered to be continuous according to the
machine parameters, i.e. the angle between the two blocks is
smaller than the maximum angle specified in MP 7050 00130 (de-
fault = 1 degree).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-119
and Controls

NC Functions Rounding, RND

4.69 Rounding Corners with Specification of the Radius


Rounding, RND

Effect
This function inserts tangential transition arcs between 2 linear, circular
or helical blocks in the main plane.
On the one hand, this leads to a minor modification of the programmed
contour at these corners, but on the other hand, continuous speed and
acceleration patterns are achieved during interpolation.
Programming
Syntax:
Rounding(<Radius>) Rounding corners ON between 2 linear/
circular/helical blocks.
Rounding(0) or Rounding corners OFF between 2 li-
Rounding() near-/circular-/helical blocks.
Abbreviation: RND(..)

where:
<Radius> desired radius of the transition arc; positions after the
decimal point are allowed.

Special features and restrictions:


D Functions ChLength, ChSection, RoundEps and Rounding act
modally and cancel each other mutually.
D The control does not execute corner rounding if
D at least one of the two neighboring blocks has a traversing path
which is smaller than the path set in MP 7050 00120 (2 to 90 mm,
default value: 10 mm), or
D the block transition is considered to be continuous according to the
machine parameters, i.e. the angle between the two blocks is
smaller than the maximum angle specified in MP 7050 00130 (de-
fault = 1 degree).
D Only the components of the active working plane for rounding are
taken into account. In the case of spatial straight lines, this leads to a
change in direction in space. There is a similar effect for helical path
segments.

: modified contour
: programmed contour

Radius
4-120 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions Scale(...), SCL(...)

4.70 Input Tool: Scale Scale(...), SCL(...)

Effect
The Scale function is one of the input tools.
The control scales a programmed contour up or down based on the pro-
gram zero point.
Scaling always refers to the current mirror point (see function PoleSet,
page 4-101). If this was not explicitly programmed, the current program
zero point is the mirror point.
The Scale function can be used in parts programs for programming con-
tours using one fixed size (standard size). Then, prior to calling such a
standardized parts program (e.g. as a subprogram), you use scaling
factors for each axis to determine the scale of the programmed contour.
In this way it is, for instance, easy to compensate for the contraction of
the workpieces in the manufacture of the moulds for cast and forged
parts.

. Scaling is an input tool; as a result, it does not change the current


program coordinate system. An input tool merely provides another
input method for the program coordinates.
Scale can also be used together with Mirror and Rotate.

The following applies:


D The function acts modally. It remains active until it is switched off.
D It may be programmed in the same block as other path conditions and
input tools.

Programming
Syntax:
Scale(<Axis1><Factor>{,...}) Scaling ON with the programmed
factor for the given axes.
Scale(0) or Switch off scaling for all the axes
Scale() in the channel. Set all scaling
factors to a value of 1.
Approached axis positions are
retained until they are
reprogrammed.
Abbreviation: SCL(..)

where:
<Axis1> Axis address (e.g. X) that is to be scaled.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-121
and Controls

NC Functions Scale(...), SCL(...)

<Factor> Programming the axis address with a positive factor acti-


vates the function.
By doing so, all subsequently programmed path
commands of the corresponding axis (e.g. X10) are
multiplied internally by this value:
Factor> 1: the contour will be scaled up
Factor< 1: the contour will be scaled down
Factor = 1: the contour is not changed.
Scaling itself does not release a traversing movement; it
does not become active until the next traversing
information.

Special features and restrictions:


D Negative scaling factors are not permitted.
D The scaling factors of all participating coordinates of the circle plane
must be identical for a circular/helical/helical-N interpolation! Other-
wise an error message will be generated.
D The function also affects the I, J, K interpolation parameters as well as
the amount of the R address (for radius programming).
D It influences the programmable contour shift. See page 4-124.
D It does not influence:
D feed programming or the active feedrate,
D zero offsets (G54-G59.5; see page 3-46),
D program coordinate offsets (Trans or ATrans; see page 4-153),
D setting of the program position (SetPos; see page 4-123),
D approaching reference point coordinates (G74 ; see page 3-55),
D approaching axis position coordinates (G76 ; see page 3-58),
D milling radius and tool length correction values.

Example:
:
N30 SCL(X3,Y0.5) Scaling ON. All X-coordinates programmed
: subsequently are multiplied by 3, and the
: Y-coordinates by 0.5.

+Y
P1 = before scaling
P1 P2 = scaling result

20

P2
10

P 10 20 30 40 +X
4-122 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions SelCrdCouple, SCC

4.71 Selective Additive Coordinate Coupling SelCrdCouple, SCC

Effect
Couples a workpiece coordinate of the current channel (target) to a
workpiece coordinate of another channel (source). The coordinate value
of the source thus has an additive effect for the coordinate value of the
target.
In this way, movements in the current channel can be superimposed by
movements that are programmed in another channel.
Programming
Syntax:
SelCrdCouple(SC<Channel>, Selective additive coordinate
CL(<Q1>,<Z1>{{,<Qn>,<Zn>}...})) coupling ON.

SelCrdCouple(0) or All active coordinate


SelCrdCouple() couplings OFF.
Abbreviation: SCC(..)

where:
<Channel> Channel number in which <Qn> is located.
Input value: Integer.
<Channel> must be less than the number of the active
channel.
<Qn> Source. Logical name or logical number of the coordinate in
<Channel>.
<Zn> Target. Logical name or logical number of the coordinate in
the current channel.

Examples:
SCC(SC1,CL(YA,YB)) Couples coordinate YB in the current chan-
nel to coordinate YA from channel 1.
SCC(SC1,CL(1,1,2,2)) Couples the coordinates with logical num-
bers 1 and 2 in the current channel to the
coordinates with logical numbers 1 and 2
from channel 1.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-123
and Controls

NC Functions SetPos, SPS

4.72 Set Program Position SetPos, SPS

Effect
Sets the current program zero point (based on the current program coor-
dinate system and the active zero point) to the corresponding program-
med value without triggering axis movements.
Then the new position values are displayed automatically.
Programming
Syntax:
SetPos(<Coordinates>) Set the program zero point for the axes
programmed under <Coordinates>.
SetPos Cancel all offsets triggered by SetPos.
Abbreviation: SPS(..)

where:
<Coordinates> Set the axis values to the given coordinates. The given
coordinates are to be separated by commas (e.g.:
(X0,Y0)).

Special features and restrictions:


D Whether SetPos- offsets are cleared or deleted after a control reset
can be set for each channel using the machine parameters.

Example:

Y N10 G90 F200


P0
80 P1: N20 G1 X140 Y70
N30 SetPos(X0)
70 P2: N40 G1 Y30
P10 P1 P11
60 P3: N50 G2 X-10 Y20 I-10
P4: N60 G1 X-55
50 P5: N70 X-65 Y30
P6: N80 X85
40
P7: N90 X95 Y20
P9 P6 P5 P2
30 P8: N100 X-100
P8 P7 P4 P3 SetPos(X0) P9: N110 G2 X-110 Y30 J10
20
P10: N120 G1 Y70
10 -130 -120 -110 -100 -90 -80 -70 -60 -50 -40 -30 -20 -10 0 10 P11: N130 X5
P0: N140 X0 Y80
N150 SetPos
P 10 20 30 40 50 60 70 80 90 100 110 120 130 140 150 X M30

. Alternatively, DIN command G92 can be programmed.


However, the G92 command may not be programmed in the same
block as traversing information.
4-124 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions Shift, SHT

4.73 Programmed Contour Shift Shift, SHT

Effect
The Shift function is one of the input tools.
The control shifts a programmed contour parallel to the axes of the pro-
gram coordinate system.

. Shift is an input tool; as a result, it does not change the current pro-
gram coordinate system. An input tool merely provides another in-
put method for the program coordinates.

The following applies:


D Programmed shift coordinates remain in effect until they are overwrit-
ten by a new Shift block or are switched off.
D If Shift is programmed by itself, it does not result in a traversing move-
ment; however, traversing information may be included in the pro-
gramming for the same block.

CAUTION
Incorrect programming may cause damage to the workpiece and
the machine!
Shift is influenced by Mirror, Scale and Rotate, i.e. the coordinates
of the new contour zero point which were programmed in the Shift
block will also be mirrored, scaled or rotated

Programming
Syntax:
Shift(<Coordinates>) Contour shift ON.
Shift(0) or Contour shift OFF.
Shift()
Abbreviation: SHT(..)

where:
<Coordinates> Program coordinates of the shifted contour-zero point.
If there are several coordinates, they are to be
separated by commas (e.g.: SHT(X5,Y2)).
Example:
N10 SHT(X10,Y10,Z50) New contour zero point at X10, Y10, Z50.
: Does not cause any axis traversing.
N100 G1 X...Y...Z... Traversing of axes with shift values taken
: into account.
N110 SHT(X20,Y20) New contour zero point at X10, Y10, Z50
: (Z shift is retained!). Does not cause any
: axis traversing.
N210 SHT() X...Y...Z... Switch off shift; the axes traverse to the
: programmed position.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-125
and Controls

NC Functions SMin, SMN SMax, SMX

4.74 Speed Limitation SMin, SMN,


SMax, SMX
Effect
Defines the range in which the spindle speed may be located in the case
of direct speed programming (G97) and constant surface speed (G96;
see page 3-75) during a machining section. The defined speed range
applies for all gear stages. When speed limitation is active, all speed in-
formation is limited to the programmed values.
The system executes modifications to the speed (including those that
are caused by the spindle potentiometer) only if they are located within
the given speed range.

Programming
Syntax:
SMin(S<Speed1>) Activates <Speed1 >as the lower limit of
the permitted speed range.
SMin(0)or Switches the lower limit off.
SMin() The current speed is no longer provided
a lower limit.
Abbreviation: SMN(..)

SMax(S<Speed2>) Activates <Speed2 >as the upper limit of


the permitted speed range.
SMax(0)or Switches the upper limit off.
SMax() The current speed is no longer provided
a upper limit.
Abbreviation: SMX(..)

where:
<Speed1>: Lowest permitted speed. Value range: > 0.
Must be lower than <Speed2>.
<Speed2>: Highest permitted speed. Value range: > 0.
Must be higher than <Speed1>.

Example:
N50 X.. Y.. SMN(S1500) The spindle speed must be between
N60 X.. Y.. SMX(S2500) 1500 and 2500 rpm.
:
N90 X.. Y.. SMN() SMX() Switch off the lower and upper limits (=
speed limitation OFF).

Special features and restrictions:


D Speed limitation has an effect only if the programmed speed limit va-
lues lie within the gear range limits.
4-126 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions SpAdmin, SPA

4.75 Release/Transfer Reserved Spindle SpAdmin, SPA


Effect
Permits
D the release of a spindle that is currently reserved in the current chan-
nel without stopping a turning spindle
D followed by its transfer to any channel.

. Function Spindle Stop is also used to release a spindle (see page


3-89).

Programming
Syntax:
SpAdmin(S<Num>=<Mode>{,S<Num>=<Mode>}...)

Abbreviation: SPA(...)
where:
<Num> Number of the spindle (spindle index).
Input value: 1 - 8. Integer.
<Mode:> 0 Release spindle
1: Reserve and transfer released spindle

Special features and restrictions:


D A control reset or M30 releases spindles reserved by the current
channel only if the command for Spindle Stop is entered in the cor-
rect position in MP 7060 00020.

Example:
N60 SPA(S1=0,S2=0) 1. and 2nd spindle.
:
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-127
and Controls

NC Functions SpCoupleConfig, SPCC

4.76 Define Group of Coupled Spindles (Activate)


Cancel Group of Coupled Spindles (Deactivate)
SpCoupleConfig, SPCC
Effect
D Defines a group of coupled spindles and activates its spindle cou-
pling.
The control automatically switches the participating spindle drives to
the position interface.
D Adds following spindles to an existing group of coupled spindles or
removes them from an existing group of coupled spindles.
Added spindle drives are automatically switched to the position inter-
face; removed spindle drives are switched to the speed interface (if
the speed interface was active on the affected spindles before cou-
pling).
D Deactivates spindle coupling for a group of coupled spindles and can-
cels the entire group.
All participating spindle drives are switched to the speed interface if
the speed interface was active on the affected spindles before cou-
pling.

Programming
Syntax:
SpCoupleConfig Define group of coupled spind-
(CP=<Coupling>,MA=<Master>, les.
S<Sequence>=1{{,S<Sequence>=1}...})
SpCoupleConfig Cancel group of coupled spind-
(CP=<Coupling>,MA=0) les.
SpCoupleConfig Add/remove following spindles
(CP=<Coupling>, to the group of coupled spind-
S<Following>=<Mode> les.
{{,S<Following>=<Mode>}...})

Abbreviation: SPCC(...)
where:
<Coupling> Number of the group of coupled spindles.
Input value: 1 - 8. Integer.
<Master> Number of the master spindle (spindle index).
Input value: 1 - 8. Integer.
<Following> Number of the following spindle (spindle index).
Input value: 1 - 8. Integer.
<Mode> 0: Remove following spindle from <Coupling>.
1: Add following spindle to <Coupling>.
4-128 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions SpCoupleDist, SPCD

4.77 Coupling Lag of Following Spindle SpCoupleDist, SPCD


Effect
Configures the desired position lag between the master and following
spindles at the time of coupling (when the group of coupled spindles is
created) for the Spindle coupling function.
If the function is not used for a desired following spindle, its lag difference
to the master spindle is 0 degrees (at the time of coupling).

. To retract an additive angle displacement between the master- and


the following spindle during an active spindle coupling, see func-
tion SpCouplePosOffs, page 4-130.

Programming
Syntax:
SpCoupleDist(S<Num>=<Lag>{,S<Num>=<Lag>}...)

Abbreviation: SPCD(...)
where:
<Num> Number of the following spindle (spindle index).
Input value: 1 - 8. Integer.
<Lag> Position lag between the master and the following spindle
(in degrees).
Value range: 0_ Position lag < 360_.
If another value is programmed, it is automatically con-
verted to the given interval.

Special features and restrictions:


D The function may be programmed only with spindles that currently do
not belong to a group of coupled spindles.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-129
and Controls

NC Functions SpCoupleErrWin, SPCE

4.78 Synchronous Mode Error Window SpCoupleErrWin, SPCE


Effect
Configures the maximum permitted position deviation between the com-
mand and actual values of a following spindle for the Spindle coupling
function.
If the position deviation lies within the defined interval during an active
spindle coupling, the spindle-based output signal Synchronous mode
2 is issued.
If the function is not used for a desired following spindle, its synchronous
mode error window is +/-10 degrees.

. Also see function SpCoupleSyncWin, page 4-132.

Programming
Syntax:
SpCoupleErrWin(S<Num>=<Window>{,S<Num>=<Window>}...)

Abbreviation: SPCE(...)
where:
<Num> Number of the following spindle (spindle index).
Input value: 1 - 8. Integer.
<Window> Maximum permitted position deviation from the com-
mand value (in degrees).
Input range: 0 to 359.9999.

Special features and restrictions:


D The function may be programmed only with spindles that currently do
not belong to a group of coupled spindles.
4-130 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions SpCouplePosOffs, SPCP

4.79 Angular Offset While Coupling is Active SpCouplePosOffs, SPCP


Effect
Retracts an angular offset between the master and the following spindle
while spindle coupling is active. The relative speed between the master
and the following spindle at which the angular offset is to be retracted can
be optionally programmed.
. The control resets the spindle-specific output signal Synchro-
nous mode 1 for the duration of rotation.

Programming
Syntax:
SpCouplePosOffs(S<Num>=<Displacement>{{,S<Num>=<Displa-
cement>}...}
{,POSVEL<Speed>)

Abbreviation: SPCP(...)
where:
<Num> Number of the following spindle (spindle index).
Input value: 1 - 8. Integer.
<Displacement> Absolute turning angle between the master and the
following spindle (in degrees).
Value range: -3600_ ... +3600_
<Speed> The relative speed between the master and the following
spindle at which the angular offset is to be retracted.
The unit and the default value depend on drive parameter
S-0-0222.
Once it is entered, <Speed> is stored internally until it is
modified by calling the function again.

Special features and restrictions:


D The angle displacement has an additive effect to the possibly configu-
red coupling lag (see page 4-128).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-131
and Controls

NC Functions SpCouplePosOffs_Wait, SPCP_WAIT

4.80 Wait for Angular Offset SpCouplePosOffs_Wait, SPCP_WAIT


Effect
Pauses the parts program until a programmed angular offset of a group
of coupled spindles (SPCP; see page 4-130) is actually retracted on the
machine.
Programming
Syntax:
SpCouplePosOffs_Wait(CP=<Coupling>)

Abbreviation: SPCP_WAIT(...)
where:
<Coupling> Number of the group of coupled spindles.
Input value: 1 - 8. Integer.
4-132 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions SpCoupleSyncWin, SPCS

4.81 Synchronous Mode Window SpCoupleSyncWin, SPCS


Effect
Configures the maximum permitted position deviation between the com-
mand and actual values of a following spindle for the Spindle coupling
function.
D Method of operation to create/edit a coupling (at the start of the syn-
chronization phase):
The parts program waits until the position deviation lies within the de-
fined interval.
D Method of operation during coupling:
If the position deviation lies within the defined interval, the spindle-
based output signal Synchronous mode 1 is issued.
If the function is not used for a desired following spindle, its synchroniza-
tion window is +/-1 degrees.

. For additional monitoring while coupling is active, see function


SpCoupleErrWin, page 4-129.

Programming
Syntax:
SpCoupleSyncWin(S<Num>=<Window>{,S<Num>=<Window>}...)

Abbreviation: SPCS(...)
where:
<Num> Number of the following spindle (spindle index).
Input value: 1 - 8. Integer.
<Window> Maximum permitted position deviation from the com-
mand value (in degrees).
Input range: 0 to 20.

Special features and restrictions:


D The function may be programmed only with spindles that currently do
not belong to a group of coupled spindles.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-133
and Controls

NC Functions SpCouple_Wait, SPC_WAIT

4.82 Wait for Synchronous Mode SpCouple_Wait, SPC_WAIT


Effect
The parts program waits until a group of coupled spindles is successfully
created, reconfigured or disbanded (SPCC; see page 4-127).
Programming
Syntax:
SpCouple_Wait(CP=<Coupling>)

Abbreviation: SPC_WAIT(...)
where:
<Coupling> Number of the group of coupled spindles.
Input value: 1 - 8. Integer.
4-134 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions SPG.., SPGALL

4.83 Define/Cancel Spindle Groups SPG.., SPGALL


Effect
Spindle groups (also called parallel spindles) permit the simple program-
ming of several spindles combined with the functions for gear ranges,
clockwise/counterclockwise rotation, spindle stop and spindle align-
ment. In this way, you do not have to program each individual spindle.
. The static assignment of all the spindles to individual spindle
groups can be carried out using MP 1040 00002.

. Function Spindle group is not to be confused with a group of


coupled spindles consisting of two or more spindles with position
control. While all the spindles in a spindle group can run at different
speeds, all the spindles in a group of coupled spindles run syn-
chronously as a rule.

Programming
Syntax:
SPG<Group>(<Numbers>) Specifies which spindles are to be
gathered together as a spindle group
in the current channel.
SPG<Group>(0) Restores the setting according to
MP 1040 00002 in the current chan-
nel for the corresponding spindle
group.
SPG<Group>(-1) Cancels the corresponding spindle
group in the current channel.
SPGALL(0) Restores the settings according to
MP 1040 00002 in the current chan-
nel for all the spindle groups.
where:
<Group> Number of the spindle group.
Input value: 1 - 4. Integer.
<Numbers> Numbers (separated by commas) of all the spindles
(spindle index) that are to be assigned to the correspon-
ding spindle group.
Input value: 1 - 8. Integer.

Special features and restrictions:


D Competing jobs between single spindles and spindle groups that are
programmed in the same block lead to a runtime error.
(Example: N10 M3 M104)
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-135
and Controls

NC Functions SpindleToAxis, STA

4.84 Switch on C-Axis Mode for Spindles SpindleToAxis, STA

Effect
Switches a spindle that is entered
D as a spindle/C-axis in MP 1001 00001 (Drive function type) and
D as a SERCOS spindle in MP 1040 00001 (Selection of spindle type)
to C-axis mode. In terms of machining, this turns a spindle into an asyn-
chronous axis.
It appears in the display as an asynchronous axis that is at first located
on any position between 0 and 359.9999 degrees.

. For detailed information about the Axis transfer function, see the
Description of Functions.

Programming
Syntax:
SpindleToAxis(<PAN> | <PAI>{,<PAN> | <PAI>}...)

Abbreviation: STA(..)
where:
<PAN> Physical axis name.
Specifies the spindle that is to be switched to C-axis
mode.
<PAI> Physical axis index.
Same effect as <PAN>.

Special features and restrictions:


D A given spindle must be at a standstill. If this is not the case, the con-
trol generates an error message and terminates the program.
D Axis positions in the same block must always be programmed accor-
ding to the expression SpindleToAxis(...).

Example:
:
N030 STA(CH) The physical axis CH (i.e. the spindle with
: the name CH during axis operation) is swit-
ched over to an asynchronous axis.
4-136 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions SplineDef, SDF

4.85 Definition of Spline Type SplineDef, SDF

Effect
The IndraMotion MTX supports the following spline types:
D Spline type 0: Spline with coefficient programming
(polynomial coefficients of CAD/CAM system)
D Spline-type 1: C1-continuous cubic splines with support point pro-
gramming
(tangential transitions at the support points)
D Spline-type 2: C2-continuous cubic splines with support point pro-
gramming
(continuous-curvature transitions at the support points)
D Spline-type3: B-spline with coefficient programming
(curve shape near the support points)

The desired spline type is selected and initialized using function Spline-
Def (SDF). Then spline programming can be activated with function G6.

Programming
Syntax:
SplineDef(<ID>,{<Members>}) Initialize spline type
Abbreviation: SDF(..)

where:
<ID>: Whole number (maximum of 4 digits) for the spline va-
riant:
Spline type Position
1000s 100s 10s 1s
Spline type Parameter Tangent cal- Spline
0...3 settings culation degrees
0: none 0: none 1...5
1: equidistant 1: Bessel
2: chordal 2: Akima
3: centripetal 3: Sehnen
Spline type 0 0 0 0 1...5
Spline type 1 1 1...3 0...3 1...5
Spline type 2 2 1...3 0...3 1...5
Spline type 3 3 1...3 0 1...5

<Members>: Not for spline type 0!


List with names of the coordinates/axes that are to partici-
pate in the spline movement.
Coordinates/axes that are not programmed in <Mem-
bers> are included linearly.
Orientation coordinates can also be programmed as spli-
nes. For this purpose, O for orientation, or polar coordi-
nates phi and theta, are provided under <Members>.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-137
and Controls

NC Functions SplineDef, SDF

Examples:
N10 SplineDef(5) Initialize spline type 0 with spline de-
: gree 5.
N20 SplineDef(2203,X,Y,Z) Initialize spline type 2 with spline de-
: gree 3 and chordal parameters. Coor-
dinates X, Y and Z participate.
N30 SplineDef(3103,x,y,z,O) Initialize spline type 3 with spline de-
: gree 3 and equidistant parameters.
Coordinates x, y and z, as well as the
orientation coordinates, participate.
4-138 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions Split, SPLIT

4.86 Programmable Path Split Split, SPLIT

Effect
Divides programmed movement blocks into several partial paths if they
exceed a certain length.

Programming
Syntax:
Split({<Mode>}{,<Part length>})

Abbreviation: SPLIT(...)
where:
<Mode> 0: Function has no effect.
1: Function acts modally.
2: Function acts only in the programmed block.
Not programmed: Effect as for 0.
<Part length> For linear blocks: length of partial path.
For circular blocks: length of arc.
Programming unit as for the axis coordinates.
If <Part length> is not programmed:
the effective <Part length> roughly corresponds to the
maximum path that can be traversed in 2 subsequent in-
terpolation cycles, depending on the current feedrate.

Special features and restrictions:


D The programmable path split divides a traversing block only if its
length does not exceed <Part length> .
D If <Part length> is not a whole divisor of the traversing path, the re-
mainder will also be traversed separately.
D If the programmable split is effective on a block-by-block basis
(<Mode>=2), a traversing movement must be programmed in the
same block.

Example:
:
N20 Split(2,10) X100 Blockwise effective path split for N20 ON.
: The traversing movement in N20 is split into
: partial paths, each with a length of 10 mm.
N120 Split(1) Modally effective path split starting at N120
: ON. Starting at N120, traversing movements
: are split into partial paths that can be traver-
: sed in approx. 2 interpolator cycles.
N220 Split(1,3.0) Modally effective path split starting at N220
: ON. The traversing movements starting at
: N220 are split into partial paths, each with a
length of 3 mm.
N320 Split() Programmable path split OFF.
:
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-139
and Controls

NC Functions SpMode, SPM

4.87 Spindle: Switching Between Position and Speed Interfaces


SpMode, SPM
Effect
Switches the spindle drive between the speed and position modes.
Programming
Syntax:
SpMode(S<Num>=<Mode>{,S<Num>=<Mode>}...)

Abbreviation: SPM(...)
where:
<Num> Number of the spindle (spindle index).
Input value: 1 - 8. Integer.
<Mode:> 0 Speed mode
1: Position mode

Special features and restrictions:


D Spindle alignment is terminated
D A rotating spindle is briefly stopped when a switch to position mode is
made.

Example:
N60 SPM(S1=1,S2=1) 1. and 2nd spindle to position mode.
:
4-140 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions StatToolOri, STO

4.88 Set Parameters of Static Tool Orientation StatToolOri, STO


Effect
Using G47(...) or G78, tool length corrections L1, L2 and L3 are assigned
to the L1-, L2- and L3 coordinate directions. These coordinate directions
form a coordinate system in which tool length correction vector L has
components L1, L2 and L3.
Command StatToolOri is used to rotate L around Euler angles phi, theta
and psi in this coordinate system.
With this tool orientation, vector L is rotated as follows:
D first around the L3 coordinate direction by the angle phi,
D then around the included L2 coordinate direction by the angle theta,
D and finally around the L3 coordinate direction, which was included in
both rotations, by the angle psi ().

Programming
Syntax:
StatToolOri({<j>} {,{<J>} {,<y>}})
Abbreviation: STO(..)

where:
<j>,<J>,<y> Absolute Euler angle in degrees.
AC/IC programming is permitted.
Value range:
0_ j < 360_; 0_ J 180_; 0_ y 360_.
Values outside this range are automatically con-
verted into the corresponding interval.
Special features and restrictions:
D The parameters of static tool orientation are set using STO and acti-
vated by G47 (see page 3-44).
D If G47 is already active when STO is executed, the change to the tool
orientation is effective immediately.
D If coordinate designations were not assigned to all 3 tool length cor-
rections L1, L2 and L3 using G47(...) or G78, the control takes only the
assigned coordinates during tool orientation and generates a war-
ning.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-141
and Controls

NC Functions StatToolOri, STO

4.89 Traverse in TCS TCM( , , )

Effect
Linear traveling motion in tool coordinate system TCS, also during active
axis transformation 2.
This concerns a local relative dimension programming, i.e. the program-
med position specification is interpreted incrementally, regardlessly of
G90/G91.

For extensive information regarding the use and parameters of TcsMove


please see the Description of Functions.

Programming
Syntax:
TCM({<xVal>},{<yVal>},{<zVal>})
(alternative: TcsMove(,,))
where:
<xVal>, <yVal>, <zVal> Values to be moved incrementally, related to
the tool coordinate system TCS
Example:
TCM (,,-100) ;immerse 100 [mm] in direction of the tool
TCM (,,0.200) ;withdraw 200 [mm] in direction of the tool
4-142 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions TangTool, TTL

4.90 Tangential Tool Guidance TangTool, TTL

Effect
Guides a rotary or endless axis along the programmed path in the active
plane with an adjustable angle. In this way, a tool can move at any time
during application with a required positioning angle to the programmed
path.
In order to rotate the tool axis to the corresponding required positioning
angle, the function takes any existing tool symmetry into account in the
case of tools with multiple tool edges. Furthermore, the control can auto-
matically insert an intermediate block that rotates the tool axis by the re-
quired angle if there is a knee in the contour at the block transition.

The following applies:


D At the 0-degree position of the tool axis of rotation, the default tool
edge direction of the tool is parallel to the positive traversing direction
of the main axis in the current plane.

Secondary axis of the current plane : Tool axis of rotation


(for G17: Y)
Default tool edge direction
at 0-degree position of tool axis of rotation

Main axis of current plane


(for G17: X)

D The positioning angle indicates the angular difference between the


path and the default tool edge direction.
It is 0 degrees if the default tool edge direction runs tangential to the
programmed path.
Tool position without Tool position with
activated tool correction activated tool correction

Default tool edge direction Default tool edge direction

path + Pos. positioning angle path + Pos. positioning angle

- Neg. positioning angle - Neg. positioning angle

: Tool axis of rotation

D TangTool does not produce a traversing motion after power up.


A programmed tool axis is not executed until the next traversing mo-
vement. Depending on the adaptation angle that is set, either
D an intermediate block for tool rotation is traversed previously, or
D the tool jumps to its new position at the beginning of the block.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-143
and Controls

NC Functions TangTool, TTL

D The calculation for the required rotation of the tool axis for the given
positioning angle in a circular path occurs in the interpolator clock
pulse. Consequently, the tool axis keeps turning by the respective po-
sitioning angle calculated with each interpolator clock pulse in the
case of such contour sections.
Programming
Syntax:
TangTool{({TAX{=}<Axis>} Tangential tool guidance ON.
{,SYM{=}<s>}{,ANG{=}<a>}
{,IA{=}<ada>}{,PLC{=}<p>})}
TangTool() or Tangential tool guidance OFF.
TangTool(0)
Abbreviation: TTL(..)

where:
<Axis>: Designation of the axis on which the function Tangential tool
guidance is to apply.
A logical or physical axis name or a logical axis number are
permitted.
If this is not programmed, MP 7050 00210 is effective.
<s>: Tool symmetry (generally tool edges).
Input value: Integer, not equal to 0.
A tool with symmetry value <s> attains a technologically
identical position after a rotation of 360 degrees / <s> .
Examples: Rectangle tool: <s> = 2; square tool: <s> = 4.
1: Asymmetric tool or only one tool edge exists.
>0: Symmetric tool having several, equally spaced tool
edges.
If there is a knee in the contour, the tool is rotated
just enough for the nearest tool edge to be posi-
tioned at the positioning angle with the contour.
<0: In the case of a change of direction(180-degree
knee) the tool is not rotated, regardless of the posi-
tioning angle. Otherwise, the same as for >0.
If this is not programmed, MP 7050 00220 is effective.
<a>: Positioning angle. Value range: -180 to +180 degrees.
This indicates the angular difference between the path and
the default tool edge direction.
If this is not programmed, MP 7050 00250 is effective. This
is used to specify whether the current angle of the tool axis of
rotation is to be used as a positioning angle or if the value
from MP 7050 002540 is to be used.
<ada>: Adaptation angle. Value range: 0 to 180 degrees.
This specifies from how many degrees upwards of a contour
knee angle between two blocks an intermediate block is in-
serted to rotate the tool axis.
If the angle at the contour knee is less than <ada>, no sepa-
rate block is inserted to rotate the tool axis. Instead, at the
start of the next block, the tool jumps to its new position.
If this is not programmed, MP 7050 00230 is effective.
4-144 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions TangTool, TTL

<p>: Switch NC-PLC-communication on- or off while an inter-


mediate block is being executed.
0: NC-PLC-communication OFF.
The NC executes the intermediate block uncondi-
tionally.
1: NC-PLC-communication ON.
Execution of a rotation block is controlled via NC-
PLC- communication.
If this is not programmed, MP 7050 00260 is effective.

Examples:
TTL Tangential tool guidance is
: activated with the corresponding
: machine parameter values for
: the axis entered in
: MP 7050 00210.
TTL(TAX=C,SYM1,ANG90,IA20,PLC0) Programming with logical axis
: name.
TTL(TAX3,SYM1,ANG90,IA20,PLC0) Programming with logical axis
: number.
TTL(TAX[NAME$],SYM1,ANG90,IA20) Programming with CPL-variable.
:

Special features and restrictions:


D Function Tangential tool guidance must not be active at the same
time as Tangential tool orientation and Tangential tool gui-
dance(see page 4-145) .
D Tangential tool guidance must never be programmed in combina-
tion with a traversing motion.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-145
and Controls

NC Functions TangToolOri, TTO

4.91 Tangential Tool Orientation TangToolOri, TTO

Effect
. Works together with functions Punch (see page 4-110) and Nib-
ble (see page 4-76).

When Punch/Nibble is switched on, this ensures that a punching-/nib-


bling- tool is located at a definable angle to the programmed path during
every stroke procedure.
For a stroke at the start of the block, a block for rotating the tool if requi-
red is automatically inserted.
The control automatically determines the optimum direction of rotation
(shortest path).
The axis of rotation is permanently specified by MP 7050 00210.
Programming
Syntax:
TangToolOri({SYM<s>},{ANG<a>}) or Tangential tool orientation
TangToolOri(1) ON
TangToolOri
TangToolOri() or Tangential tool orientation
TangToolOri(0) OFF
Abbreviation: TTO...

where:
<s>: Tool symmetry (generally tool edges).
Input value: Integer, greater than 0.
A tool with symmetry value <s> attains a technologically
identical position after a rotation of 360 degrees / <s> .
Examples: Rectangle tool: <s> = 2; square tool: <s> = 4.
1: Asymmetric tool or only one tool edge exists.
>1: Symmetric tool having several, equally spaced tool
edges.
If SYM is not programmed: effect as for SYM1.
<a>: Positioning angle to programmed path.
Range of values: -180 to +180 degrees.
0: Tool axis is positioned at an angle of 0 degrees to the pro-
grammed path.
If ANG is not programmed: Effect as for ANG0.

Special features and restrictions:


D The function may not be programmed together with function Tang-
Tool (Tangential tool guidance, TTL).
D When the function is active, Tangential tool guidance (TTL, see
page 4-142) is not possible.

Example:
D G90 is active (absolute dimension programming)
D active plane: X/Y
4-146 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions TangToolOri, TTO

D tool axis: C (modulo 360)


D current position: X=0, Y=0, C=0
D punching/nibbling is switched off.

:
N10 TangToolOri(1) Tangential tool orientation ON; effect as
for SYN1 and ANG0.
N20 G1 G91 X10 Y10 No orientation of the C-axis yet because
punching/nibbling is switched off.
N30 X10 Y10 Punch(1) Punching ON. C-axis rotates to 45_.
N40 Y-10 C-axis rotates to -90_. After modulo cal-
culation: C=270_.
N50 Punch(0) Punching OFF.
N60 LEN=30 Nibble(1) Nibbling ON.
Desired block segment lengths: 30 mm.
N70 G2 X114.6 I57.3 J0 Semicircle with 180 mm length of arc.
The block is divided into 6 block seg-
ments, each with an arc length of 30 mm.
N80 TTO() Tangential tool orientation OFF.
:

Y C=0_
(N70: 3rd partial path)
C=-30_=330_
(N70: 4th partial path)

C=30_ C=300_
C=45_ (N70: 2nd partial path) (N70: 5th
(N30) partial path)
C=0_
C=60_
(N20)
(N70: 1st partial path)

C=-90_=270_ C=270_
(N40) (N70: 6th partial
C=90_ path)
(N70. Automatically generated
intermediate block at start of : Actual traversing motion
block to rotate the tool)
: Programmed path
: Tool position
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-147
and Controls

NC Functions TappSp, TSP

4.92 Spindle Selection for Rigid Tapping TappSp, TSP

Effect
D Specifies the spindles to which G63 is to refer.
TappSp is in effect until it is reprogrammed. It is still in effect even
after a control reset!
D If TappSp is not programmed, G63 will always refer to the 1st
spindle.
Programming
Syntax:
TappSp(CAX<i>) Activate tapping for individual spind-
les using spindle number(s).
TappSp(GRP<j>) Activate tapping for all spindles using
a spindle group.
TappSp(GRP<j>{,CAX<i>}) Activate tapping for all spindles using
a spindle group as well as for additio-
nal spindles using spindle number(s).
Abbreviation: TSP(..)

where:
<i> Number of the Spindle to which G63 refers.
Range of values: 1 ... n, where n stands for the highest
spindle number in the system (max. 8).Whole number.
Several spindles are programmed by several CAX<i>, sepa-
rated by commas.
<i> Number of the Spindle group to which G63 refers.
Range of values: 1 ... n, where n stands for the highest
spindle group number (max. 4).Whole number.

Special features and restrictions:


D Only a single spindle group can be activated for G63.
D Spindle numbers, plus 1 spindle group if required, can be combined in
any way.

Example:
N20 TappSp(CAX2) Select the spindle with a spindle
: number of 2 for G63.
N120 TappSp(CAX2,CAX4,CAX7) Select the spindles with spindle
: numbers of 2, 4 and 7 for G63.
N220 TappSp(GRP2) Select the spindle group with a
: spindle number of 2 for G63.
N320 TappSp(GRP3,CAX4) Select the spindle group with a
: number of 3 plus the spindle with a
spindle number of 4 for G63.
4-148 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions TcsDef, TCS

4.93 TCS Definition in Program Coordinates TcsDef, TCS

Effect
When 6-axis-transformation is active, this generates a tool coordinate
system TCSp that can be offset and/or rotated compared to the last cur-
rent TCS.
The coordinate values given for TCSp are converted within the NC and
stored in the tool correction memory.

The generated TCSp can be cleared by switching off the function. In this
process, the last current TCS is reactivated.

Programming
1. If not already executed, activate axis transformation type 3333301
(see function Coord(...), page 4-30).
2. Use the syntax shown below.
Syntax:
TcsDef({<Position>},{<Orientation>}) Define and activate the
position and orientation of
TCSp. For detailed syn-
tax, see below.
TcsDef() or Delete TCSp and reacti-
TcsDef(0) vate the last current TCS.
Abbreviation: TCS(...)
Detailed syntax:
TcsDef({<x><px>},{<y><py>},{<z><pz>},{<phi><j>},{<theta><J>},{<psi><y>} or

TcsDef({<x><px>},{<y><py>},{<z><pz>},{O(<j>,<J>,<y>)} or

TcsDef({<x><px>},{<y><py>},{<z><pz>},{Ox(<jx >,<Jx >) Oy(<jy >,<Jy >)} or


TcsDef({<x><px>},{<y><py>},{<z><pz>},{Ox(<jx >,<Jx >) Oz(<jz >,<Jz >)} or
TcsDef({<x><px>},{<y><py>},{<z><pz>},{Oy(<jy >,<Jy >) Oz(<jz >,<Jz >)} or

TcsDef({<x><px>},{<y><py>},{<z><pz>},{Ox(<o11>,<o21>,<o31>) Oy(<o12>,<o22>,<o32>)} or
TcsDef({<x><px>},{<y><py>},{<z><pz>},{Ox(<o11>,<o21>,<o31>) Oz(<o13>,<o23>,<o33>)} or
TcsDef({<x><px>},{<y><py>},{<z><pz>},{Oy(<o12>,<o22>,<o32>) Oz(<o13>,<o23>,<o33>)} or

TcsDef({<x><px>},{<y><py>},{<z><pz>},{ROTAX(<ju >,<Ju >) O(<b>)} or


TcsDef({<x><px>},{<y><py>},{<z><pz>},{ROTAX(<ux >,<uy >,<uz >) O(<b>)}
where:
<x> Coordinate name that is entered in
MP 7080 00010[1]. Default: x
<y> Coordinate name that is entered in
MP 7080 00010[2]. Default: y
<z> Coordinate name that is entered in
MP 7080 00010[3]. Default: z
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-149
and Controls

NC Functions TcsDef, TCS

<px>, <py>, <pz> Absolute Cartesian coordinates of axis addres-


ses <x>, <y> and <z>, based on the current
PCS. The values define the origin of the new
TCSp.
AC/IC programming is permitted.
<phi> Angle name that is entered in
MP 7080 00010[4]. Default: phi
<theta> Angle name that is entered in
MP 7080 00010[5]. Default: theta
<psi> Angle name that is entered in
MP 7080 00010[6]. Default: psi
<j>,<J>,<y> Absolute Euler angle in degrees, based on the
current PCS. The values define the orientation
of the new TCSp.
AC/IC programming is permitted.
Value range: 0_ j < 360_;
0_ J 180_;
0_ y 360_.
Values outside this range are automatically con-
verted into the corresponding definition interval.
<j..>,<J..> Absolute angle values in degrees.
Value range: 0_ j.. < 360_;
0_ J.. 180_.
If a value outside of the range is programmed for
J.., it is automatically converted to the given in-
terval.
Ox(<o11>,<o21>,<o31>)
Oy(<o12>,<o22>,<o32>)
Oz(<o13>,<o23>,<o33>)
Ox(<jx >,<Jx >)
Oy(<jy >,<Jy >)
Oz(<jz >,<Jz >) Orientation per function Ox(..), Oy(..), Oz(..).
For example, Ox(..) defines the direction of the
x-coordinate of TCSp in the reference coordi-
nate system. The same applies analogously to
Oy(..) and Oz(..).
The direction can be specified either by the cor-
responding polar angles <j..> and <J..> or the
Cartesian components of the TCSp orientation
tensor column vectors.
Only absolute dimensions are allowed.
The component values of the column vectors
(o..) are automatically standardized to 1.
ROTAX(<ju >,<Ju >) Define the axis of rotation using polar angles (u,
u).
ROTAX(<ux >,<uy >,<uz >) Define the axis of rotation using Cartesian
components <ux >,<uy >,<uz > in absolute di-
mensions. Automatic standardization to 1.
4-150 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions TcsDef, TCS

O(<b>) Indicates (in degrees) the incremental angle


<b> around which the TCSp orientation tensor,
starting from the orientation tensor of the last
current TCS, is to be turned around the axis of
rotation.
Values greater than 360 degrees are allowed.
The direction of rotation can be selected using
the positive/negative sign.

Special features and restrictions:


D Axis transformation type 3333301 must be active.
D If function Coord(...) (see page 4-30) is reprogrammed, a pre-
viously generated TCSp is automatically cleared and the last current
TCS is reactivated.
D If programming of the tensor columns results in two column vectors
being parallel or anti-parallel, it is not possible to calculate the orienta-
tion tensor.
A runtime error is issued.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-151
and Controls

NC Functions ThreadSet, TST

4.94 Additional Tapping Functions ThreadSet, TST

Effect
Individual partial areas of G33 can be temporarily adjusted by program-
ming ThreadSet.
In this case, the control superimposes the static values stored in the ma-
chine parameters.
ThreadSet allows
D the adjustment of the dynamics and retraction movement
D switching of the spindle operating mode (speed control, position con-
trol)
D setting of a signal on the channel interface (configurable within the
Active function signals using machine parameters).

Control reset or M30


D cancels the settings superimposed by ThreadSet
D clears an IF signal that had been set by ThreadSet
D switches the main spindle back to speed-controlled operation if it had
previously changed over to position-controlled spindle operation
using ThreadSet(SPC1).

. All partial functions described below can be jointly programmed


(separated by commas) in a ThreadSet block.

Programming: Configuring the retract data


Syntax:
ThreadSet(RD(<HA-Value>,<NA-Wert>{,-1}))

Abbreviation: TST(..)
where:
<PA-value> Retract path (incremental in mm) towards the primary
axis of the currently selected plane (G17, G18, G19,
G20).
The value must always be programmed; however, it is
only relevant for longitudinal and tapered threads.
<SA-value> Retract path (incremental in mm) towards the secondary
axis of the currently selected plane.
The value must always be programmed; however, it is
only relevant for transversal and tapered threads.
-1 -1 is an optional third parameter.
In this case, the retract data from MP 7050 00645 and
MP 7050 00650 will be active again.
4-152 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions ThreadSet, TST

Programming: Activating retraction


Syntax:
ThreadSet(RON<Status>) or
TST(..)
where:
<Status> 0: Deactivate fast retract.
1: Activate fast retract.

Programming: Configuring the dynamic


Syntax:
ThreadSet(DYN({<Jump>},{<Accel>}{,<Decel>})) or
TST(..)
where:
<Jump> Max. permitted jump speed in mm/min
Entering -1 will activate MP 7050 00610 again.
<Accel> Acceleration in m/s2
Entering -1 will activate MP 7050 00615 again.
<Decel> Deceleration in m/s2
Entering -1 will activate MP 7050 00620 again.

Programming: Switching the spindle mode


Syntax:
ThreadSet(RON<Status>) or
TST(..)
where:
<Status> 0:
Switch the main spindle into speed-controlled mode.
1:
Switch the main spindle into position-controlled mode,
depending on the setting of 7050 00600 [3].

For details on main spindles, refer to page 4-72.

Programming: channel-IF-incluence signal


Syntax:
ThreadSet(TCI<Status>) or
TST(..)
where:
<Status> 0: Clears the channel IF signal
1: Sets the channel IF signal

. Which signal is influenced on the channel interface can be configu-


red within the Active function signals using machine parame-
ters.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-153
and Controls

NC Functions Trans, TRS ATrans, ATR

4.95 Program Coordinate Offset Trans, TRS


Additive Program Coordinate Offset ATrans, ATR

Effect
Trans offsets the active program coordinate system parallel to the
coordinate axes of the current workpiece coordinate system.
ATrans permits additional parallel and always additive offsets of the
program coordinate system.
In this way, a parts program can execute the programmed contour anyw-
here within the workpiece coordinate system without modifications. In-
put tools that are based on the active program coordinate system (e.g.
programmed contour offset, scaling, mirroring, rotation) are indepen-
dent of a program coordinate offset and therefore need not be adapted.

+ZW +YW
+ZP2 +YP2

+ZP1
+YP1 ATrans
Pn
P2
Trans
ATrans +XP2
W
P1
+XP1

+XW

W = Zero point of the active workpiece coordinate system


P1 = Zero point of the 1st program coordinate offset
P2 = Zero point of the 2nd program coordinate offset

The following applies:


D Programming a program coordinate offset does not trigger a traver-
sing movement.
Programming
Syntax:
Trans(<Coordinates>) Program coordinate offset ON.
The zero point of the program coordinate
system is set to the programmed <coordi-
nates> of the active workpiece coordinate
system.
Several coordinate axes, separated by
commas, may be programmed in the par-
entheses.
(Example: TRS(X100,Y50,Z50)).
Trans() or All program coordinate offsets OFF.
Trans(0)
Abbreviation: TRS(..)
4-154 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions Trans, TRS ATrans, ATR

ATrans(<Coordinates>) Additive program coordinate offset ON.


The zero point of the resulting program
coordinate system is set to the program-
med <coordinates> of the active program
coordinate system.
Several coordinate axes, separated by
commas, may be programmed in the par-
entheses.
ATrans() or Additive program coordinate offsets OFF.
ATrans(0)
Abbreviation: ATR(..)

Example:
N10 TRS(X10,Y10,Z50) Set the zero point of the program coordinate
: system to position X10 Y10 Z50 of the current
: workpiece coordinate system.
:
N50 ATR(X20,Y10) The zero point of the resulting program coordi-
: nate system lies on position X30 Y20 Z50, ba-
: sed on the original workpiece coordinate sy-
: stem.
N80 ATR() Additive program coordinate offset OFF. The
: zero point of the program coordinate system
: lies on position X10 Y10 Z50, based on the
: original workpiece coordinate system.
:
N180 TRS() All program coordinate offsets OFF.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-155
and Controls

NC Functions VirtAxisPos, VAP

4.96 Virtual Drives VirtAxisPos, VAP

Effect
Sets the axis position of virtual synchronous axes in the current channel.

. For detailed information about virtual dives, see the Description


of Functions.

Programming
Syntax:
VirtAxisPos(<Axis 1><Value>,<Axis n><Value>, ...)

Abbreviation: VAP(...)
where:
<Axis x> Address of the virtual axis.
<Value> Position information for <Axis x>.

Example:
VAP(VX150) Position axis VX to 150mm.

Special features and restrictions:


D Local incremental programming (IC...) is not permitted.
4-156 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions WaitAxis, WAX

4.97 Transfer Axis, Wait if Necessary WaitAxis, WAX

Effect
Transfers a synchronous axis to the calling channel. This turns an asyn-
chronous axis into a synchronous axis.
The axis can then be programmed in the current channel using its physi-
cal or logical axis name.

. For detailed information about the Axis transfer function, see the
Description of Functions.

Programming
Syntax:
WaitAxis(<PAN> | <PAI>,{<LAN>}{,<PAN> | <PAI>,{<LAN>}}...)

Abbreviation: WAX(..)
where:
<PAN> Physical axis name.
Specifies the axis that is to be transferred to the current
channel.
<PAI> Physical axis index.
Same effect as <PAN>.
<LAN> Logical axis name.
If this is programmed, the axis to be integrated into the
current channel receives the logical name <LAN>.
<LAN> must have been defined in MP 7010 00010 (Lo-
gical axis designation) or MP 7010 00020 (Optional
axis designation).

Special features and restrictions:


D If an axis to be transferred is not yet at a standstill, block preparation
waits for it to come to a standstill. Then the axis is transferred.
As opposed to function GetAxis (see page 4-51), no error message
appears and the program is not terminated.
D Axis positions in the same block must always be programmed after
WaitAxis(...) and may be programmed only if axis transformation is
not active.
D Axes to be transferred must not be participating in any active monito-
ring area (see page 4-2).

Example:
N030 WAX(YP,,ZP,Z) If necessary, block preparation waits for phy-
: sical axes YP and ZP to come to a standstill.
Then the axes are transferred to the calling
channel.
While YP is also addressed as YP in the cal-
ling channel, ZP receives address Z in the
calling channel.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-157
and Controls

NC Functions WriteId, WID

4.98 Writing SERCOS Parameters WriteId, WID

Effect
Writes the programmed SERCOS drive parameter (S-x-xxxx, P-x-xxxx)
to one or more drives.
For product-specific SERCOS drive parameters (P-x-xxxx), complete
value lists with a maximum of 16 values or ID lists with a maximum of 8 ID
numbers can also be written.

Prerequisites:
D The parameter must be valid and editable in SERCOS Phase 4.
D The parameter value lies within the permitted range.
D The drive is connected to the control using the SERCOS interface;
cyclic communication between the control and the drive is running.

. CPL command SCS is available to help read SERCOS drive para-


meters.

DANGER
Improper or random modifications of SERCOS drive parameters
can lead to damage to the workpiece and/or machine and to
dangerous and unpredictable machine reactions.
Information about the SERCOS drive parameters available in the
drive is required for proper use. For this, consult your drive
documentation.

Programming Write a parameter to one or more drives


(for synchronous axes):

Syntax:
WriteId(<Par>,<SA1><W1>{,<SAn><Wn>}...)

Abbreviation: WID(...)
where:
<Par> Default parameter (S-x-xxxx) or
product-specific parameter (P-x-xxxx).
<SA1>...<SAn> Logical axis address of the SERCOS drive.
<W1>...<Wn> Value that is to be written to<Par>.
Example:
N100 WID(P-0-0500,X10,Y20,Z30) Write P-0-0500:
in the drive of the X-axis: 10
in the drive of the Y-axis: 20
in the drive of the Z-axis: 30
4-158 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions WriteId, WID

Programming Write a parameter to one or more drives


(for spindles and asynchronous axes):

Syntax:
WriteId(<Par> DRIVE(<AA1>,<W1>{,<AAn>,<Wn>}...))

Abbreviation: WID(...)
where:
<Par> Default parameter (S-x-xxxx) or
product-specific parameter (P-x-xxxx).
<AA1>...<AAn> Physical axis index or physical axis name of the SER-
COS drive. A maximum of 8 drives may be defined
using DRIVE(...) syntax.
<W1>...<Wn> Value that is to be written to<Par>.

Programming Write values of a parameter list to a drive:

Syntax:
WriteId(<Par> LIST(<A1>,<W1>{,<Wn>}...))

Abbreviation: WID(...)
where:
<Par> Product-specific parameter (P-x-xxxx) containing a
value list.
(Default parameters (S-x-xxxx) are not permitted!)
<A1>...<An> Physical axis index or physical axis name of the SER-
COS drive.
<W1>...<Wn> A maximum of 16 values that are to be written to
<Par>.
Example:
N100 WID(P-0-0515 LIST(1,0.5,0.2) Write P-0-0515 in
drive 1 with 2 values

Programming Write ID numbers of an ID-list to a drive:

Syntax:
WriteId(<Par> ID_LIST(<A1>,<Id1>{,<Idn>}...))

Abbreviation: WID(...)
where:
<Par> Product-specific parameter (P-x-xxxx) containing an
ID list.
(Default parameters (S-x-xxxx) are not permitted!)
<A1>...<An> Physical axis index or physical axis name of the SER-
COS drive.
<Id1>...<Idn> A maximum of 8 ID numbers that are to be written to
<Par>.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 4-159
and Controls

NC Functions WriteId, WID

Example:
N100 WID(P-0-0417 ID_LIST(X,S-0-47,S-0-51) Write P-0-0417 in
the drive of axis X
with 2 ID num-
bers.

Special features and restrictions:


D The function may not be programmed during contour machining.
D Programmed parameters are written only after the corresponding
drive comes to a standstill.
4-160 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

NC Functions ZoTSel, ZOS

4.99 Activate Zero Offset Tables ZoTSel, ZOS

Effect
Activates a zero offset table (ZO table). ZO tables are stored as XML files
in the file system of the control.

Programming
Syntax:
ZoTSel({<Path>}<Filename>)

Abbreviation: ZOS(..)
where:
<Path> Optional path information for the directory in which <File-
name> is stored.
If there is no information, the file will be searched in the /da-
tabase directory.
If <Filename> is not present there, the control uses the search
path for subroutines so that the search for <Filename> can
also be carried out in other directories.
<Filename> File name of the ZO table, incl. the file extension.
Tables with standard names (ZO<Number>.zot) can be
activated directly using the number, e.g.
ZoTSel(5) activates the table ZO5.zot.

Special features and restrictions:


D When the table is activated, the control can optionally check whether
the current axis configuration of the channel is suitable for the table
contents (Strict assignment option; this is set using the table editor
or the first time that the table is generated).
If it is unsuitable when the Strict assignment option is activated, the
program is terminated with an error message.

. Please refer to the Operating Instructions for how to create and edit
ZO tables.

Example:
:
N030 ZOS(npvtab.zot) First searches for ZO table npvtab.zot in
: directory /database and then, if it is not
there, in the search path for subroutines.
The first ZO table with the name
npvtab.zot that is found is activated.
N130 ZOS(/mnt/np.zot) Searches and activates ZO table
: npvtab1.npv in directory /mnt. If it is not
found there, an error message appears.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-1
and Controls

Coordinate and Axis Values

5 CPL-Functions

5.1 Coordinate and Axis Values


The CPL contains functions that can be used to query various values of
coordinates and axes.

Differentiation is made among:


D Functions for reading coordinate and axis positions
(PCS, WCS, MCS, ACS, SPOS, APOS)
D Functions for reading probes
(PCSPROBE, PROBE, PPOS)
D Functions for reading offsets and placements
(AXO, COF, DPC).

In the parts program, coordinates that are interpolated during proces-


sing of the program are always programmed. The axis transformations
calculate the appropriate command values for the affected axes (spatial
and machine coordinates) from the current coordinate values.

. You can find detailed information about coordinates, axes and


transformations in the Description of Functions manual.
5-2 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Coordinate and Axis Values

Overview

Parts program
Program coordinate system: PCS Last programmed position: PCS
Probe value: PCSROBE

Block preparation
Calculation of workpiece coordinates
Program coordinate offset
Contour offset
Scaling
Tool coordinate system: WCS Probe value: PPOS

Interpolation
Tool coordinate system: WCS Interpolated workpiece position: WCS

Coordinate transformation
Basic tool coordinate system: BCS

Axis transformation 2
Local machine coordinate system: LCS LCS

Block execution
Zero offset
Machine coordinate system: MCS MCS

Axis transformation 1
Axis coordinate system: ACS Command values of system axes: A
CS

Drives (axes) Axis command values: SPOS


Axis actual values: APOS
Probe value: PROBE

Units for supplied axis and coordinate positions


Synchronous linear axes and mm or Inch;
translatory spatial coordinates: depending on the current
setting (G71, G70) in the cal-
ling channel.
Synchronous rotary axes and Degrees
rotary spatial coordinates:
Asynchronous linear axes: mm
Asynchronous rotary axes: Degrees
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-3
and Controls

Coordinate and Axis Values

Example: Configuration and assignment of axis names to channels


Index System axis name Channel assignment Channel- Channel-
System axis Machine parameter Machine parameter Axis name Axis index
1003 00001 1003 00002 Channel 1
1 ! X ! 1 X 1
2 ! Y ! 1 Y 2
3 ! Z ! 1 Z 3
4 ! X2 ! 2 U_CH1 4
5 ! Y2 ! 2
6 ! Z2 ! 2
7 ! U ! 1
8 ! A ! 3

Index Channel axis name Channel 2


Channel Machine parameter
axis 7010 00010[1] X2 1
Y2 2
1 !
Z2 3
2 !

3 !

4 ! U_CH1

5 !

6 !

7 !
8 ! Channel 3
A 1







5-4 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Coordinate and Axis Values

5.1.1 Functions for reading coordinates and axis positions


Please note:
D The coordinate index in the channel is always fixed for spatial - and
machine coordinates.
D On the other hand, coordinates can be incorporated or surrendered
by a channel using the axis transfer functions. As a result, the coordi-
nate index of the other coordinates in the channel can change.
Using the option of presetting the system- axis index, work with fixed
indices can also be carried out.
D A runtime error is issued when an unconfigured system -axis is pre-
set.

The described functions work with similar parameters; therefore, these


will be explained in the following.

<Coordinate> Index or name of a coordinate:


Aname is interpreted as a coordinate name. Only if no
corresponding coordinate name exists is it interpre-
ted as a channel or system axis name.
Anindex is interpreted according to the given <Selec-
tion type>.
Programming an unconfigured coordinate/axis leads
to a runtime error if the optional variable ERRNO is
not programmed.
<Axis> Index or name of a axis:
Aname is interpreted as a channel axis name. If none
exists, the system axis name is used.
Anindex is interpreted according to the given <Selec-
tion type>.
Programming an unconfigured axis leads to a runtime
error if the optional variable ERRNO is not program-
med.
<Selection type> optional:
Determines how an index programmed under <Coor-
dinate> or <Axis> is interpreted:
0: System axis index
1: Coordinate index or channel axis index (default)
If there is no explicit programming, <Selection type>
is set to 1.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-5
and Controls

Coordinate and Axis Values

<Channel> optional:
Channel number; permitted only when <Selection
type> = 1.
If coordinates/axes are to be read by third-party
channels, and if they can be addressed using their in-
dex or name, the number of the channel to which the
coordinate/axis is currently assigned is entered in
<Channel>.
If no channel is entered, the coordinates/axes of the
current channel are accessed. If a system -axis is ad-
dressed (with name or index) and a channel is ent-
ered at the same time, an error message is issued,
even if variable ERRNO has been programmed.
ERRNO CPL variable that can be programmed in any position.
When ERRNO is programmed, no runtime error is is-
sued; the return values are:
0 : Access OK
-1 : Parameter error
-2 : Coordinate/axis does not exist.
-3 : Invalid coordinate/axis in channel.
-4 : Axis is not a pseudocoordinate.
-5 : Channel does not exist.
-6 : Function may be called only in an autonomous
channel.
-7 : Data cannot be read.
5-6 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Coordinate and Axis Values

PCS
Supplies the last programmed value for a coordinate.

The following applies:


D If the workpiece coordinate system is switched after programming
the coordinate and before querying the position, the supplied value
already takes the new workpiece coordinate system into account.
D Only coordinates of the autonomous channel may be queried.

Syntax:
PCS(<Coordinate> [,<Selection type>])
(For the parameters, see page 5-4;
for programming ERRNO, see page 2-56)

Examples:
PCS(X,ERRNO)
PCS(X,1)

Channel 2 according to sample configuration on page 5-3:


N1 G0 G90 X2=150 Y2=100
02 X2VALUE=PCS(1,ERRNO) X2WERT is assigned the program-
03 IF ERRNO <>0 THEN med absolute position of the 1st coor-
04 PRN#(0,Error:,ERRNO) dinate in the current channel
05 ENDIF (X2WERT = 150)

N10 G91 X2=10


011 X2VALUE=PCS(1,1) X2WERT is assigned the program-
med absolute position of the 1st coor-
dinate in the current channel
(X2WERT = 160)
N12 X2=5 Y2=10
13 Y2VALUE=PCS(Y2,1) Y2WERT is assigned the program-
med absolute position of system -axis
Y2 (Y2WERT = 110)
14 X2WERT=PCS(X2) X2WERT is assigned the program-
med absolute position of the X2 coor-
dinate in the current channel
(X2WERT = 165)
15 XWERT=PCS(1,0) Runtime error: Access to the 1st sy-
stem axis in channel 2 is not permit-
ted (axis is assigned to channel 1).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-7
and Controls

Coordinate and Axis Values

WCS
Supplies the current workpiece position, without online compensation
values, for a coordinate.

The following applies:


D If the supplied value is to be determined at the time of block execu-
tion, a WAIT must be programmed first in an autonomous block
(also see section 2.14.2).
Without WAIT, no uniquely predictable values are supplied because
it is not precisely known how far block execution lags behind block
preparation.
D When accessing the coordinate values of a third-party channel, syn-
chronization measures may need to be taken to measure a defined
position.

Syntax:
WCS(<Coordinate> [,<Selection type>[,<Channel>]])
(For the parameters, see page 5-4;
for programming ERRNO, see page 2-56)

Examples:
WCS(X,ERRNO)
WCS(X,1)
WCS(X,1,1)

Channel 2 according to sample configuration on page 5-3:


10 WAIT
20 Z2POS=WCS(3,1,2,ERRNO) Z2POS is assigned the currently inter-
21 IF ERRNO <>0 THEN polated workpiece position of the 3rd
22 PRN#(0,Error:,ERRNO) coordinate of the 2nd channel
23 ENDIF (Z2-axis)

30 WAIT
110 YPOS = WCS(Y) YPOS is assigned the currently inter-
polated workpiece position of the Y-
coordinate of the current channel
120 XPOS = WCS(1) XPOS is assigned the currently inter-
polated workpiece position of the 1st
coordinate of the current channel.
5-8 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Coordinate and Axis Values

MCS
Supplies the current machine position (MCS) for a machine coordinate
without straightness- and angle error compensation.
Coordinates on other channels can also be accessed.

The following applies:


D If the supplied value is to be determined at the time of block execu-
tion, a WAIT must be programmed first in an autonomous block
(also see section 2.14.2).
Without WAIT, no uniquely predictable values are supplied because
it is not precisely known how far block execution lags behind block
preparation.
D When accessing the coordinate values of a third-party channel, syn-
chronization measures may need to be taken to measure a defined
position.

Syntax:
MCS(<Coordinate> [,<Selection type>[,<Channel>]])
(For the parameters, see page 5-4;
for programming ERRNO, see page 2-56)

Examples:
MCS(X,ERRNO)
MCS(X,1)
MCS(X,1,1)

Channel 2 according to sample configuration on page 5-3:


N10 G0 G90 X2=150 Y2=100
20 WAIT
30 X2VALUE=MCS(X2,ERRNO) X2WERT is assigned the currently in-
31 IF ERRNO <>0 THEN terpolated machine position of the
32 PRN#(0,Error:,ERRNO) X2-coordinate
33 ENDIF

N40 G91 X2=10 Y2=10


50 WAIT
60 X2VALUE=MCS(1,1) X2WERT is assigned the currently in-
terpolated machine position of the 1st
machine coordinate of the current
channel (X2-coordinate).
70 Y2VALUE=MCS(Y2,1,2) Y2WERT is assigned the currently in-
terpolated position of the Y2-coordi-
nate of the 2nd channel
80 XVALUE=MCS(1,0) XWERT is assigned the currently in-
terpolated axis position of the 1st sy-
stem axis.
This access is permitted only if the
system axis is identical to the ma-
chine coordinate.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-9
and Controls

Coordinate and Axis Values

ACS
Supplies the current command position of an axis.
Axes can be addressed using their channel axis name or their channel
axis index.
Alternatively, axes can also be addressed using their system -axis
name or their system axis index.

The following applies:


D The result of ACS always corresponds to function SPOS.
D If the supplied value is to be determined at the time of block execu-
tion, a WAIT must be programmed first in an autonomous block
(also see section 2.14.2).
Without WAIT, no uniquely predictable values are supplied because
it is not precisely known how far block execution lags behind block
preparation.
D When accessing the axis values of a different channel, synchroniza-
tion measures may need to be taken to measure a defined position.

Syntax:
ACS(<Axis>[,<Selection type>[,<Channel>]])
(For the parameters, see page 5-4;
for programming ERRNO, see page 2-56)

Examples:
ACS(X,ERRNO)
ACS(X,1)
ACS(X,1,1)

Channel 2 according to sample configuration on page 5-3:


N10 G0 G90 X2=150 Y2=100
20 WAIT
30 X2VALUE=ACS(X2,ERRNO) X2WERT is assigned the currently in-
31 IF ERRNO <>0 THEN terpolated axis position of channel
32 PRN#(0,Error:,ERRNO) axis X2
33 ENDIF

N40 G91 X2=10 Y2=10


50 WAIT
60 X2VALUE=ACS(1,1) X2WERT is assigned the currently in-
terpolated axis position of the 1st
channel axis of the current channel
(X2-axis).
70 Y2VALUE=ACS(Y2,1,2) Y2WERT is assigned the currently in-
terpolated axis position of channel
axis Y2 of the 2nd channel
80 XVALUE=ACS(1,0) XWERT is assigned the currently in-
terpolated axis position of the 1st sy-
stem axis.
5-10 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Coordinate and Axis Values

SPOS
Supplies the current command position of an axis based on the axis
coordinate system.
All system -axes can be addressed using their system -axis name or
their system -axis index.

The following applies:


D SPOS and ACS always supply identical values.
D If the supplied value is to be determined at the time of block execu-
tion, a WAIT must be programmed first in an autonomous block
(also see section 2.14.2).
Without WAIT, no uniquely predictable values are supplied because
it is not precisely known how far block execution lags behind block
preparation.
D When accessing the axis values of a different channel, synchroniza-
tion measures may need to be taken to measure a defined position.

Syntax:
SPOS(<Axis> )

<Axis> Index or name of a system axis


Programming an unconfigured axis leads to a runtime
error.
ERRNO cannot be programmed.

Example:
Channels according to sample configuration on page 5-3.
30 POS1=SPOS(1) Variable POS1 is assigned the current com-
: mand axis value of the 1st system axis (X-
axis in channel 1).
50 POS5=SPOS(Y2) Variable POS5 is assigned the current com-
: mand axis value of the 5th system axis
(Y2-axis in channel 2).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-11
and Controls

Coordinate and Axis Values

APOS
Supplies the current command position of an axis based on the axis
coordinate system.
All system -axes can be addressed using their system -axis name or
their system -axis index.

The following applies:


D If the supplied value is to be determined at the time of block execu-
tion, a WAIT must be programmed first in an autonomous block
(also see section 2.14.2).
Without WAIT, no uniquely predictable values are supplied because
it is not precisely known how far block execution lags behind block
preparation.
D When accessing the axis values of a different channel, synchroniza-
tion measures may need to be taken to measure a defined position.

Syntax:
APOS(<Axis>)
<Axis> Index or name of a system axis
Programming an unconfigured axis leads to a runtime
error.
ERRNO cannot be programmed.

Example:
Channels according to sample configuration on page 5-3.
30 AKT4=APOS(4) Variable AKT4 is assigned the current actual
: axis value of the 4th system axis (X2-axis in
channel 2).
50 AKT8=APOS(A) Variable AKT8 is assigned the current actual
: axis value of the 8th system axis (A-axis in
channel 3).
5-12 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Coordinate and Axis Values

5.1.2 Functions for reading probes

PCSPROBE
If a switching measuring probe is connected to the axes of a channel
and a measurement is launched, PCSPROBE can read the measured
value for any one coordinate.

The prerequisite for PCSPROBE is that the probe must be latched by all
the axes of the channel. The latched axis values are converted to pro-
gram coordinates using the transformation chain that was activated
last. PCSPROBE supplies the value for a coordinate.

Syntax:
PCSPROBE (<Coordinate> [,<Selection type>])
(For the parameters, see page 5-4;
for programming ERRNO, see page 2-56)

. PCSPROBE cannot be used in conjunction with the FlyMeas


(FME) on-the-fly measurement function because only one single
axis is measured during on-the-fly measurement.

Example:
Channel 1 according to sample configuration on page 5-3:
N10 G75 X100 Y100 Z50
20 IF SD(9)=1 THEN
N30 (MSG, probe has not been deflected!)
40 GOTO .FEHLER
50 ELSE
60 ZMESS=PCSPROBE(3,ERRNO) Variable ZMESS is assigned the value
61 IF ERRNO <>0 THEN of the 3rd coordinate of the measured
62 GOTO .Fehler position.
63 ENDIF
70 ENDIF
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-13
and Controls

Coordinate and Axis Values

PROBE
Supplies axis values that refer to the ASC axis coordinate system.

The following applies:


D PROBE permits access to only the axes of its own channel. As a re-
sult, the positions of asynchronous axes cannot be queried.
D Only lead screw error and cross-compensation are taken into ac-
count.
D The triggering of the probe in the channel can be checked with func-
tion SD(9).
D In FsProbe function Measurement on positive stop, the measured
values are read using functions PPOS or PROBE.

Syntax:
PROBE (<Axis> [,<Selection type>])
(For the parameters, see page 5-4; ERRNO cannot be programmed)

Example:
Channel 2 according to sample configuration on page 5-3:
N70 G75 Y2 250
80 IF SD(9)=1 THEN
N90 (MSG, probe has not been deflected!)
100 GOTO .FEHLER
110 ELSE
120 Y2MESS=PROBE(2) Variable Y2MESS is assigned to the measu-
red actual position of the 2nd channel axis
(in this case, the Y2-axis of channel-2).
130 ENDIF
5-14 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Coordinate and Axis Values

PPOS
Supplies the current actual axis position of a synchronous axis in the
switch point of the probe.

PPOS takes into account the following compensations:


D Axis zero offsets (G54 - G59)
D Tool compensations (G48, ED)
D Program coordinate offset (Trans, ATrans)
D Lead screw error and cross-compensation

The following are not taken into account:


D Axis transformation (Coord)
D Coordinate transformations (BcsCorr, G152 - G159)
D Scaling (PoleSet, Mirror, Scale, Rotate)

The following applies:


D PPOS permits access to only the axes of its own channel. As a result,
the positions of asynchronous axes cannot be queried.
D Without any axis transformation or coordinate transformation, the
supplied value refers to the WCS workpiece coordinate system that
was programmed last.
D In FSB function Measurement on positive stop, the measured va-
lues are read using functions PPOS or PROBE.
D The triggering of the probe in the channel can be checked with func-
tion SD(9).

Syntax:
PPOS(<Axis> [,<Selection type>])
(For the parameters, see page 5-4; ERRNO cannot be programmed)

Example:
Channel 3 according to sample configuration on page 5-3:
N10 G1 G75 A250 F500
20 IF SD(9)=1 THEN
N30 (MSG, probe has not been deflected!)
40 GOTO .FEHLER
50 ELSE
60 AMESS = PPOs(1,1) Variable AMESS is assigned the measured
value of the 1st channel axis of the channel.
70 ENDIF
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-15
and Controls

Coordinate and Axis Values

5.1.3 Functions for reading offsets and placements

AXO
AXO supplies the current G92 offset for a coordinate at the time of block
preparation, i.e. the offset that was last activated at the time of program
interpretation is supplied.

Syntax:
AXO(<Coordinate> [,<Selection type>])
(For the parameters, see page 5-4; ERRNO cannot be programmed)

. AXO permits access to only the offset values of its own channel.
Since asynchronous axes do not have any G92 offset, AXO is not
permitted for asynchronous axes.

Example:
Channel 1 according to sample configuration on page 5-3:
N10 G1 G90 X100 F1000
N20 G92 X75 Y125
30 XD = AXO(X) XD is assigned the G92 offset of the X-coor-
dinate of the current channel that was acti-
vated last (XD=100-75=25)
40 YD = AXO(2,0) YD is assigned the G92- offset of the 2nd
system- axis that was activated last
(YD=200-125=75)
50 X2D = AXO(4,0) Runtime error because the 4th system axis
is assigned to channel 2.
5-16 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Coordinate and Axis Values

COF
Supplies the last programmed contour shift of a coordinate.
Since the programmed contour shift acts only on the coordinates in the
current channel, selecting a nonexistent coordinate in the current chan-
nel results in an error message.
Compensation values are supplied in the active unit of the current chan-
nel, i.e. in Inch for G70 and in mm for G71. In the case of rotary axes /
rotatory spatial coordinates, the unit is always degrees.

Syntax:
COF(<Coordinate> [,<Selection type>])
(For the parameters, see page 5-4; ERRNO cannot be programmed)

Examples:
10 A=COF(3) Supplies the last-programmed contour shift of the
: coordinate with the 3rd coordinate index in the ac-
tive channel.
20 B=COF(X) Supplies the last-programmed contour -shift of the
: X-coordinate in the active channel.
30 C=COF(2.0) Supplies the last-programmed contour shift of the
: 2nd system axis in the active channel.
This access is permitted only if the system axis is
identical to the WCS coordinate.
100 C=COF(0) Runtime error because 0 is not a valid coordinate
: index.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-17
and Controls

Coordinate and Axis Values

DPC
Supplies the last-programmed parameter of the workpiece position
compensation (BCR) of a coordinate (offset values and turning angle).

Since the workpiece position compensation acts only on the coordina-


tes in the current channel, selecting a nonexistent coordinate in the cur-
rent channel results in an error message.
Compensation values are supplied in the active unit of the current chan-
nel, i.e. in Inch for G70 and in mm for G71. In the case of rotary axes /
rotatory spatial coordinates, the unit is always degrees.

Syntax:
DPC(<Coordinate> [,<Selection type>])
(For the parameters, see page 5-4; ERRNO cannot be programmed)
<Coordinate> Additional effect of the specifications:
1 to n or Name: Supplies the offset value
0 Supplies turning angle Phi.

Examples:
10 A=DPC(1) Supplies the last-programmed workpiece position
: compensation of the coordinate with the 1st coor-
dinate index in the channel.
15 B=DPC(X) Supplies the last-programmed workpiece position
: compensation of the X-axis/coordinate in the chan-
nel.
20 B=DPC(2) Supplies the last-programmed workpiece position
: compensation of the coordinate with the 2nd coor-
dinate index in the channel.
25 B=DPC(2,0) Supplies the last-programmed workpiece position
: compensation of the 2nd system axis in the active
channel.
30 WINKEL=DPC(0) Supplies the last-programmed turning angle Phi.
:
100 C=DPC(9) Runtime error because 9 is not a valid coordinate
: index if there are 8 axes in the system.
5-18 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Zero Offsets

5.2 Zero Offsets


The following CPL commands permit ZO tables to be read, created and
modified.

ZOV ZeroOffsetValue
Supplies the sum of the last-programmed and thus effective ZO values
of a machine coordinate (axis) or, optionally, the effective value of a sin-
gle ZO page.

Syntax:
ZOV(<Axis selection>[,<ZO page>])
<Axis selection> Name of the machine coordinate (axis), programmed
in turned commas, or
index of the machine coordinate (axis); values = 1-8
<ZO page> Index of the ZO page; values = 1-5

Examples:
ZOV(X) Supplies the sum of all effective (last-programmed) ZOs
for machine coordinate (axis) X.
ZOV(2,3) Supplies the effective ZO of the 3rd ZO page for the 2nd
machine coordinate (axis).

ZOT ZeroOffsetTable
Read/write access to any XML zero offset table within the IndraMotion
MTX file system. Only single elements can be accessed. During writing,
incremental modifications can also be preset.

Syntax:
ZOT(<Column selection>,<ZO-Code>[,[<ZO-Page>][,[<Ta-
ble>][,<Unit>]]])
<Column selection> Name of the machine coordinate (axis), pro-
grammed in turned commas, or
column index within the table.
The following is possible during write access:
- overwriting the table value, or
- adding the value to the table value if
<Column selection> starts with a negative
symbol.
<ZO code> 54: 1st zero offset
55: 2. Zero offset
56: 3. Zero offset
57: 4. Zero offset
58: 5. Zero offset
59: 6. Zero offset
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-19
and Controls

Zero Offsets

<ZO page> Index of the ZO page (1-5).


Default value: 1
<Table> Name of the ZO table; if required, with absolute
or incremental path information (table suffix
.zot must not be included in the programming).
If there is no path information, a search within
the configured search path is carried out.
For tables with default names such as ZO1,
ZO2, etc., only the value of the number need be
provided. If there is no table name, the last-acti-
vated table is accessed.
<Unit> 0 or MM: mm
1 or INCH: inches
During write access, the assigned value is inter-
preted in the unit provided. During read access,
the value is converted into the unit provided.
Default value: mm

Examples:
ZOT(X,54) Access to the G54 offset of axis / machine
coordinate X in the last-activated ZO table of
the channel.
ZOT(2,55,2) Access to the G55.2 offset of the 2nd entered
axis / machine coordinate in the last-activated
ZO table of the channel.
ZOT(3,57,,V1) Access to the G57 offset of the 3rd entered
axis / machine coordinate in ZO table V1.zot.
ZOT(Z,58,4,21,1) Inch access to the G58.4 offset of axis / ma-
chine coordinate Z in ZO table ZO21.zot.
ZOT(Y,59,5,/mnt/esmuser/de/HHGENIUS,MM)
Metric access to the G59.5 offset of axis / ma-
chine coordinate Y in table HHGENIUS in
directory /mnt/esmuser/de.

ZOTCR
Creates an XML zero offset table without correction blocks within the file
system of MTX.

Syntax:
ZOTCR(<Table>,<Channel/template> )
<Table> : Name of XML table if necessary with path detail.
<channel/template> : Channel number or name of XML template table if
necessary with path detail.
5-20 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Zero Offsets

ERRNO CPL variable. If the CPL variable ERRNO is entered


on any location in the parameter list, no runtime error
is created. The error is supplied via a corresponding
value of variables. The following return values are
possible
0 : Access OK
-1 : Parameter error
-13 : Data could not be written.
-14 : XML table exists
-15 : XML table not found
-16 : Invalid file extension
-17 : Invalid table type
If the CPL variable ERRNO is not indicated, a runtime
error occurs during access error.

Examples:
ZOTCR(/usr/user/zot.tst,1)
Creating a new table /usr/user/zot.tst with
columns for each axis of the first channel.

ZOCINS
Inserting a new axis into an XML zero offset table before an available
column. The new axis contains so much correction blocks like the 1.axis
of table. The values will be preassigned with 0.0.

Syntax:
ZOCINS(<Table>,<Position>,<AxisName>[,<AxisType>])
<Table> : Name of XML table if necessary with path detail.
<Position> : Axis name or column index of insert position
<AxisName> : Axis name of new table column
<AxisType> : optional axis type of the new axis
0 : Linear axis (default value)
1 : Rotary axis
ERRNO CPL variable. If the CPL variable ERRNO is entered
on any location in the parameter list, no runtime error
is created. The error is supplied via a corresponding
value of variables. The following return values are
possible
0 : Access OK
-1 : Parameter error
-13 : Data could not be written.
-15 : XML table not found
-16 : Invalid file extension
-17 : Invalid table type
-18 : Insert position faulty
-19 : Maximum axis number exceeded
If the CPL variable ERRNO is not indicated, a runtime
error occurs during access error.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-21
and Controls

Zero Offsets

Example:
ZOCINS(/usr/user/zot.tst,X,Y)
Inserting a new axis into table /usr/user/
zot.tst with column designation Y before
table column with the designation X.

ZOCDEL
Deleting an axis in an XML zero offset table.

Syntax:
ZOCDEL(<Table>,<Position>)
<Table> : Name of XML table if necessary with path detail.
<Position> : Axis name or column index of the axis to delete
ERRNO CPL variable. If the CPL variable ERRNO is entered
on any location in the parameter list, no runtime error
is created. The error is supplied via a corresponding
value of variables. The following return values are
possible
0 : Access OK
-1 : Parameter error
-13 : Data could not be written.
-15 : XML table not found
-16 : Invalid file extension
-17 : Invalid table type
-18 : Insert position faulty
If the CPL variable ERRNO is not indicated, a runtime
error occurs during access error.

Example:
ZOCDEL(/usr/user/zot.tst,X)
Deleting the axis with column designation
X in the table /usr/user/zot.tst.
5-22 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Tool Compensation

5.3 Tool Compensation


The following CPL commands permit access to internal tool compensa-
tion data (D-corrections) and external tool compensation data (ED-cor-
rections) to which the PLC has access.

TCV ToolCorrectionValue
Supplies the last-programmed tool compensation values, whether as a
sum (D-correction + external correction memory) or as a single value.

Syntax:
TCV(<Value selection>[,<Correction selection>])
<Value selection> Number of the D-/ED-correction:
0: last activated D-/ED-
corrections
1 or L1: L1-correction length
2 or L2: L2-correction length
3 or L3: L3-correction length
4 or RAD: Tool / tool edge radius
5 or ORI: Tool edge position
6 or PHI: Euler angle
(only ED-correction)
7 or THE: Euler angle
(only ED-correction)
8 or PSI: Euler angle
(only ED-correction)

<Correction selection> 1 or D: D-correction (internal)


2 or E: ED-correction (external)
Default: Sum of D- and ED-
corrections

Examples:
TCV(0,D) Supplies the last programmed D correction.
TCV(L1) Reading of the sum of L1-values of the last-pro-
grammed D- and ED-corrections.
TCV(4,1) Reading of the tool radius of the last-programmed
D-correction
TCV(2,E) Reading of the L2-tool length of the last-program-
med ED-correction
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-23
and Controls

Tool Compensation

DCT D-CorrectionTable
Read and write access to tool compensation values in any D-correction
tables as well as to external correction values (ED-correction). During
writing, incremental modifications can also be preset.

Syntax:
DCT(<Value selection>,<Data block>[,[<Table>][,<Unit>]])
<Value selection> Number of the D-/ED-correction:
1 or L1: L1-correction length
2 or L2: L2-correction length
3 or L3: L3-correction length
4 or RAD: Tool / tool edge radius
5 or ORI: Tool edge position
6 or PHI: Euler angle (only ED-correction)
7 or THE: Euler angle (only ED-correction)
8 or PSI: Euler angle (only ED-correction)
The value can be read or written.
The following is possible during write access:
- overwriting the table value, or
- adding the value to the table value if
<Value selection> starts with a negative symbol.
Incremental writing is not possible for the tool edge
position (5 or ORI).
<Data block> 1-99: for a D-correction
1..16: for an ED-correction
<Table> Name of the D-correction table;
if required, with absolute or incremental path informa-
tion (without table suffix .dct). If there is no path infor-
mation, a search within the configured search path is
carried out.
For tables with default names such as DC1, DC2, etc.,
only the value of the number need be provided.
without <Table>, the last-selected D-correction table
is accessed.
0: Access to ED-correction.
<Unit> 0 or MM: mm (default)
1 or INCH: inches
During write access, the assigned value is interpreted
in the unit provided. During read access, the value is
converted into the unit provided.

Examples:
DCT(1,10,K4) Access to the L1 correction value of data block
10 in D correction table K4.
DCT(RAD,7) Incremental writing to the tool radius of data block
7 of the last-activated table.
DCT(L2,16,0,IN Inch access to the L2 correction of data block 16
CH) of the external tool compensation.
5-24 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Tool Database

5.4 Tool Database

DBTAB
This can read a complete data block or a substructure of a tool database
table into a CPL variable or write from the variable back to the data
block.

Syntax:
DBTAB(<DbTable>,<Key1>,<Key2>[,<ResVar>])
<DbTable> Name of the database table with substructures
(Xpath string). A . or / can be used as a separator
between structure components.
<Key2> Database key 1
<Key2> Database key 2
<ResVar> Variable of type Integer.
If<ResVar> is entered, a runtime error does not result
in case of an access error. The following return values
are possible:
0: Access OK
1: Error during access
2: Not enough memory
3: Invalid variable type
If <ResVar> is not entered, a runtime error results in
case of an access error.

Example:
10 SV.A=DBTAB(DBT1.Rec,1,1)
20 D!=DBTAB(DBT1.Rec.UD.Ed.Geo.L1,1,1)
30 SV.A.UD.Ed.Geo.L1 = 10
40 DBTAB(DBT1.Rec,1,1) = SV.A
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-25
and Controls

Tool Database

DBSEA
Searches for a data block in a tool database table.

Syntax:
DBSEA(<DbTab>,<Key1>,<Key2>,<SeachCond>,
<SeachRes>[,<ResVar>])
<DbTab> Name of the database table.
<Key2> Start key 1
<Key2> Start key 2
<SearchCond> Search condition as a string (see below)
<SearchRes> Search result, variable of type Integer.
0: No data block that fits the search condition
found
1: Data block that fits the search condition found.
<ResVar>: Variable of type Integer.
If<ResVar> is entered, a runtime error does not result
in case of an access error. The following return values
are possible:
0: Access OK
1: Error during access
2: Not enough memory
3: Invalid variable type
4: Search condition faulty
If <ResVar> is not entered, a runtime error results in
case of an access error.

Search condition (<SearchCond>)


The following syntax must be maintained:
D A list of individual conditions, all of which must be fulfilled, is provi-
ded.
D The individual conditions are separated by ,.
D A normal individual condition has the form:
<Tag-name><Relational operator><Value>
where:
D <Relational operator>: = equal to
> greater than
>= greater than or equal to
< less than
<= less than or equal to
<> not equal to
D Only the following is permitted for SKQ as the relational operator:
= and <>,
e.g. SKQ=4711
5-26 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Tool Database

D A bit mask individual condition has the form:


- <Tag-name>=<Value>:<Mask>
e.g. BQ1=0x307000:0xF0FF00
where:
D <Value>: Value that the relevant bits must have
D <Mask>:Specification of the relevant bits
Values and masks are interpreted:
D as a hexadecimal number if they start with 0x or 0X
D as an octal number if they start with 0
D otherwise as a decimal number.
Within <Value>, preceding or following spaces are not evaluated. If a
string is to be specified in which these spaces are important, the sub-
string must be surrounded by turned commas (e.g.: SKQ= ).
To use a turned comma in a substring that is surrounded by turned
commas, the \ symbol bust precede the turned comma (e.g.:
SKQ=Achim\s)

Boundary conditions:
D Only predefined tag names may be used
D Only queries regarding equality are possible.

Example:
K1=1
IKQ2=3
BQ2=0x1:0x1

The CPL function returns the first data block that satisfies the search
condition. In this case, variable <SearchRes> returns a value of 1. The
search starts at the data block that is defined by the two start keys. If one
of the two start keys has a value of -1, the search starts at the first data
block of the database table.

Example:
10 SV.A.Hd=DBSEA(DBT1,-1,-1,K1=1,FOUND%)
20 WHILE FOUND%=1 DO
30 SV.A.Hd=DBSEA(DBT1,SV.A.Hd.K1,SV.A.Hd.K2,K1=1,FOUND%)
40 END
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-27
and Controls

Placements (Inclined Plane)

5.5 Placements (Inclined Plane)


The following CPL commands allow access to placement tables.

PMV PlaceMentValue
Supplies the sum of the last-programmed, and thus effective, place-
ment values for a coordinate. Optionally, the effective value of an indivi-
dual placement page can be read.

Syntax:
PMV(<Coord.selection>[,<Pl.-page>])
<Coord.selection> Index of the coordinate (1-6) or fixed identifier
X, Y, Z, PHI, THE, PSI for WCS coordi-
nates.
<Pl. page> Index of the placement page (1-5)

Examples:
PMV(Y) Supplies the sum of all effective (last-programmed)
placements for coordinate Y. Due to the possible rota-
tions, not only the sum of the individual pages is invol-
ved, but also the resulting offset in the Y-direction of
the basic workpiece coordinate system.
PMV(4,4) Supplies Euler angle PHI of the active placement of the
4th page.
5-28 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Placements (Inclined Plane)

PMT PlaceMentTable
Read/write access to any XML placement table of IndraMotion MTX;
only individual elements may be accessed. During writing, incremental
modifications can also be preset.

Syntax:
PMT(<Coord.selection>,<Pl. code>[,[<Pl. page>][,[<Table>]
[,<Unit>]]])
<Coord.selection> Index of the coordinate (1-6) or fixed identifier
X, Y, Z, PHI, THE, PSI for WCS coordi-
nates.
The value can be read or written. The following
is possible during write access:
- overwriting the table value, or
- adding the value to the table value if
<Coord.selection> starts with a negative
symbol.
<Pl. code> 154: Placement 1
155: Placement 2
156: Placement 3
157: Placement 4
158: Placement 5
159: Placement 6
<Pl. page> Index of the placement page (1-5)
Default value: 1
<Table>: Name of the placement table; if required, with
absolute or incremental path information (table
suffix .pmt must not be included in the pro-
gramming). If there is no path information, a
search within the configured search path is car-
ried out.
For tables with default names such as PM1,
PM2, etc., only the value of the number need be
provided. If there is no table name, the last-acti-
vated table is accessed.
<Unit> 0 or MM: mm
1 or INCH: inches
For the 3 translatory coordinates, the assigned
value is interpreted in the unit provided for write
access; in the case of read access, the value is
converted into the unit provided.
Default value: mm
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-29
and Controls

Placements (Inclined Plane)

Examples:
PMT(Z,155) Access to the G155 offset of coordinate Z in the
last-activated placement table of the channel.
PMT(5,157,3) Access to Euler angle of G157.3 in the last-acti-
vated placement table of the channel.
PMT(X,154,,P1) Access to the G154.1 offset of coordinate X in
placement table P1.
PMT(3,158,4,,1) Inch access to the G158.4 offset of coordinate Z
in the last-activated placement table of the chan-
nel.
PMT(Y,159,5,/mnt/esmuser/de/PL5,MM)
Metric access to the G159.5 offset of coordinate
Y in table PL5 in directory /mnt/esmuser/de.
5-30 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

XML Tables

5.6 General Access to XML Tables

XTAB
Read/write access to any XML table which can also be user-defined.
As opposed to the special functions for ZO, D-correction and placement
tables, this function also permits access to any substructures of a table
if a corresponding data type has been defined.

Syntax:
XTAB(<Table>,<Substructure>)
<Table> Name of the XML table; if necessary with path infor-
mation
<Substructure> Desired substructure, provided as an XPATH expres-
sion.

Example:
10 X!=XTAB(/database/PM1.pmt,/PMT/set[1]/G154/Corr/Trans/XWCS)
20 XTAB(/database/PM1.pmt,/PMT/set[1]/G154/Corr/Trans/XWCS)=X!+1.0
Increment the va-
lue in the table by
1.

XTABCR
Creates an XML table without data within the file system of MTX.

Syntax:
XTABCR(<Table>,<Typ>[,<Table template>])
<Table> : Name of XML table if necessary with path detail.
<Type> : Type of table (XML root tag)
<Table template> : Name of template XML table if necessary with
path detail. The indicated <type> must correspond
with the type of the <table template>.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-31
and Controls

XML Tables

ERRNO CPL variable. If the CPL variable ERRNO is entered


on any location in the parameter list, no runtime error
is created. The error is supplied via a corresponding
value of variables. The following return values are
possible
0 : Access OK
-1 : Parameter error
-13 : Data could not be written.
-14 : XML table exists
-15 : XML table not found
-16 : Invalid file extension
-17 : Invalid table type
If the CPL variable ERRNO is not indicated, a runtime
error occurs during access error.

DBMOVE
Conversion of a data record within a database table.

Syntax:
DBMOVE(<DbTab>,<SrcKey1>,<SrcKey2>,<DestKey1>,<Dest -
Key2>[,<Mode>])
<DbTab> : Root tag of XML table.
<SrcKey1> : 1. Key of source data record
<SrcKey2> : 2. Key of source data record
<DestKey1> : 1. Key of target data record
<DestKey2> : 2. Key of target data record
<Mode> : optional (default : 0)
0 : The content of the source data record is moved
into target- data record and the content of the
source data record is set to zero.
1 : The content of the source data record is copied to
target-data record and the content of the source
data record remains unchanged.
2 : The content of the source data record and the de
stination data record are reversed.
5-32 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

XML Tables

ERRNO CPL variable. If the CPL variable ERRNO is entered


on any location in the parameter list, no runtime error
is created. The error is supplied via a corresponding
value of variables. The following return values are
possible:
0 : Access OK
-1 : Parameter error
-7 : Data cannot be read
-13 : Data could not be written.
-20 : Faulty root tag
-21 : Accessing file not possible
-22 : Invalid key
-23 : Data record is locked
If the CPL variable ERRNO is not indicated, a runtime
error occurs during access error.
Example:
DBMOVE(/DBT1,1,1,2,2)
The content of data record (1,1) is moved
into data record (2,2).

DBLOAD
Via DBLOAD, parts of a database table or a complete database table
from a file can be read into the database.

Syntax:
DBLOAD(<DbTab>,<Key1>,<Key2>,<FileName> )
<DbTab> : Root tag of XML table.
<Key1> : 1. Key of data record
<Key2> : 2. Key of data record
<FileName> : File name
ERRNO CPL variable. If the CPL variable ERRNO is entered
on any location in the parameter list, no runtime error
is created. The error is supplied via a corresponding
value of variables. The following return values are
possible:
0 : Access OK
-1 : Parameter error
-7 : Data cannot be read
-13 : Data could not be written.
-20 : Faulty root tag
-21 : Accessing file not possible
-22 : Invalid key
-23 : Data record is locked
If the CPL variable ERRNO is not indicated, a runtime
error occurs during access error.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-33
and Controls

XML Tables

Only data records can be read which are already available in the data-
base table. No new data records are created.
If both keys have the value 1, all data records from the file will be read
into database table. If the 1. key has a value unequal 1 and the 2. key
the value 1, all data records whose 1. key has the entered value, will be
read into database table.

Example:
DBLOAD(/DBT1,1,1,/dbdaten.txt)
Th content of data record (1,1) will be read
from file dbdaten.txt into database table.

DBSAVE
Via DBSAVE, parts of a database table or a complete database table
can be saved into a file.

Syntax:
DBSAVE(<DbTab>,<Key1>,<Key2>,<FileName>[,<Mode>] )
<DbTab> : Root tag of XML table.
<Key1> : 1. Key of data record
<Key2> : 2. Key of data record
<FileName> : File name
<Mode> : optional (default : 0)
0 : Data will be written into file FileName
. If the file already exists, the
content is overwritten.
1 : Data will be added to the existing file File-
Name.
ERRNO CPL variable. If the CPL variable ERRNO is entered
on any location in the parameter list, no runtime error
is created. The error is supplied via a corresponding
value of variables. The following return values are
possible:
0 : Access OK
-1 : Parameter error
-7 : Data cannot be read
-13 : Data could not be written.
-20 : Faulty root tag
-21 : Accessing file not possible
-22 : Invalid key
-23 : Data record is locked
If the CPL variable ERRNO is not indicated, a runtime
error occurs during access error.
5-34 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

XML Tables

If both keys have the value 1, all data records will be written into file. If
the 1. key has a value unequal 1 and the 2. key the value 1, all data
records whose 1. key has the entered value, will be written into file.

Example:
DBSAVE(/DBT1,1,1,/dbdaten.txt)
The content of data record (1,1) is saved
into file dbdaten.txt.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-35
and Controls

Scaling

5.7 Scaling

SCL
Supplies for the current channel (here: channel in which the program
with the SCL command is running) the parameters last programmed of
the functions PLS, SCL, MIR und ROT(...) (pole coordinates, scaling
factors and rotation angles).
Since PLS, SCL, MIR and ROT(...) act only on the coordinates in the
current channel, selecting a nonexistent coordinate in the current chan-
nel results in an error message.
Position values are supplied in the active unit of the current channel, i.e.
in Inch for G70 and in mm for G71. In the case of rotary axes / rotatory
spatial coordinates, the unit is always degrees.

Syntax:
SCL(<Selection>[,<Coordinate>[,<Selection type>]])
<Selection> 0: last progr. turning angle of the main plane
1: last progr. pole of a channel axis
2: last progr. scaling factor of a channel-axis
<Coordinate> Index or name of a coordinate:
Aname is interpreted as a coordinate name. Only if no
corresponding coordinate name exists is it interpre-
ted as a channel or system axis name.
Anindex is interpreted according to the given <Selec-
tion type>.
Programming an unconfigured coordinate/axis leads
to a runtime error if the optional variable ERRNO is
not programmed.
<Selection type> optional:
Determines how an index programmed under <Coor-
dinate> is interpreted:
0: System axis index
1: Coordinate index (default)
If there is no <selection type,> the index is interpreted
as a coordinate index!

Examples:
10 W=SCL(0) Writes the last-programmed turning angle to varia-
: ble W.
20 P=SCL(1,2) Writes the pole of the coordinate with the 2nd
: coordinate index in the channel to variable P.
30 F=SCL(2,2,1) Writes the scaling factor of the coordinate with the
: 2nd coordinate index in the channel to variable F.
40 D=SCL(2,X) Writes the scaling factor of the X-coordinate in the
channel to variable D.
5-36 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

5.8 System Data


5.8.1 System data of simple types

MCA
Transfers the contents of a MACODA individual parameter. Depending
on the type of data, this value can be of the integer, float, double or
even string type. The variable in which the transferred value is to be
stored must be of the same type!Type conflicts between the value trans-
ferred and the destination variable are detected during the programs
runtime and acknowledged in the form of an error message.

Syntax:
MCA(<Block>,<Index>[,<Channel>] )
<Block> Number of a MACODA parameter. Within one MA-
CODA parameter, more than one MACODA indivi-
dual parameter (parameter list) can be contained.
If a nonexistent parameter number is programmed, a
runtime error will appear.
<Index> Index of the MACODA individual parameter, begin-
ning with 0.
If a nonexistent index number is programmed, a run-
time error will appear.
<Channel> Channel number. If not programmed, the function will
supply the MACODA individual parameter of the
channel in which the CPL program is presently being
executed.
If a nonexistent channel number is programmed, a
runtime error will appear.
Example: MCA command

MACODA No.

10 BLOCKNR%=100300004
20 ERG%=MCA(BLOCKNR%,0) !

The integer variable ERG% is


assigned to the content of single
parameter of MACODA
parameter 100300004 of the active
channel(=axis movement
type)
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-37
and Controls

System Data

NCF
Supplies the syntax of the NC-function that was programmed last within
the modal group or the auxiliary function group of <NC-functions>. All of
the modal groups of the control, as well as the auxiliary functions that
are defined in the auxiliary function groups, can be queried
The variable in which the result is to be stored must be of type Dimen-
sioned character field.
Type conflicts are detected during the running time of the program and
confirmed with an error message.

Syntax:
NCF (<NC-Function>)
<NC function> Syntax of any NC function or auxiliary function.
If a nonexistent syntax is programmed, a run-
time error is issued.

Examples:
10 DIM A$(4) Set the size of a character field for a string with a
: maximum length of 4 characters.
20 A$=NCF(G1) The syntax of the last-programmed NC function of
: the group that contains G1 as the syntax is assi-
gned to string variable A$.
N80 [A$] The previously queried NC function is programmed
again.

N10 M3 S1234 T2345


123 DIM A$(4)
20 A$=NCF(M3)
N30 [A$] The previously queried NC function is
programmed again.
50 PRN#(0,M3 group:
,A$,is active)
N30 M5
33 A$=NCF(M3)
34 PRN#(0,M3 group:
,A$,is active)
N70 M30

. The spindle syntax of the IndraMotion MTX is freely configurable


and is set in machine parameter 1040 00101 ff.
5-38 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

SCS
Permits read access to SERCOS drive parameters of the active para-
meter set.

Syntax:
SCS(<Axis selection>,<ID-Type>,<ID-No>[,<Result var>])
<Axis selection> System axis index or system axis name
<ID type> String expression.
S: S-Parameter
P: P-Parameter
<ID No> Number of the SERCOS parameter
<ResVar>: If<ResVar> is entered, a runtime error does not result
in case of an access error:
the following return values are possible:
0: Access OK
1: Access is currently impossible
If <ResVar> is not entered, a runtime error results if
access is attempted.
<ResVar> is an Integer variable.
The parameter content is supplied without a unit or scaling.

. Parameters that contain a list (several values separated by com-


mas) cannot be read. In such cases, the control issues an error
message.

If the drive data are located in the SERCOS drive telegram, they are
read out from it (see Servodyn-D Parameter Manual). Otherwise, the
drive data are read directly in the drive.
If other applications access drive data, the drive data cancurrently not
be read. Parameter <ResVar> can be used to react to this error in the
parts program. Repeating the access attempt may supply the desired
drive datum.

. Continuous access to drive data can prevent access for other ap-
plications!

Access to LAGE% FEHLER% Error message


drive data
yes New actual position 0 none
value of the i-th axis
No Retain the old actual 1 SERCOS SERVICE
position value of the CHANNEL IS OCCU-
i-th axis PIED
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-39
and Controls

System Data

A reaction to the error in the parts program can be provided by evalua-


ting integer variable FEHLER%.

Example:
10 LAGE%=SCS(1,S,51,FEHLER%) The actual position value of the
1st axis is assigned to the
LAGE% integer variable.
12 IF FEHLER% = 0 THEN Error evaluation
13 REM***Actual position value was read correctly***
14 ELSE
15 REM***Actual position value could not be read***
16 ENDIF

SCSL
Certain SERCOS parameters exist as lists that can be read using com-
mand SCSL. Since the length (required memory) for a list is not known,
the read list elements are stored in ASCII files. Then the read data can
be processed using CPL file commands.

Using the SCSL command, the file indicated in the command is regene-
rated if it does not yet exist. The content of an existing file is overwritten.

Syntax:
SCSL(<Axis index>,<ID-Art>,<ID-Nr>,<File name>[,<Result
var>])
<Axis index> System axis index or system axis name
<ID type> String expression.
S: S-Parameter
P: P-Parameter
<ID No> Number of the SERCOS parameter
<FileName> Name of the ASCII file in which the read list is to be
stored.
<ResVar> Integer variable.
If<ResVar> is entered, a runtime error does not result
in case of an access error.
The following return values are possible:
0: Access OK
1: SERCOS access is currently not
possible
2: Error accessing the file.
If <ResVar> is not entered, a runtime error results if
access is attempted.
5-40 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

It may be impossible to access drive data at certain times if other ap-


plications access drive data. Parameter <ResVar> can be used to re-
act to this error in the parts program. Repeating the access attempt may
supply the desired drive datum.

. Continuous access to drive data can prevent access for other ap-
plications!
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-41
and Controls

System Data

SD
Reads from a collection of system data IndraMotion MTX in Integer-
format.

Syntax:
SD(<Group>[,<Index1>[,<Index2>[,<Index3>]]])
The SD-function outputs INTEGER-values.

Group Index1 Index2 Index3 Affects Description


function
Active override-setting for the corresponding potentiometer
(in percent):
2 1 D Feed
2 2 D Rapid traverse
2 3 D Spindle (SD(202,1);
2 4 SD(2,3)=0 if no spindle is applied)
D 2. Spindle (SD(202,2);
(SD(2,4)=0 if no 2nd spindle is applied)
Active velocities, rounded to whole number value:
5 1 1 D Feed in entry units per minute; evaluated using
potentiometer (for OvrEna, SD supplies a value of
5 2 1 100%)
5 3 1 D Rapid traverse in mm/min or inches/min (100% value)
D Spindle speed in rpm; evaluated using potentiometer
(SD(205,1,1);
5 4 1 SD(5,3,1)=0 if no spindle is applied)
D Spindle speed of 2nd spindle in rpm; evaluated using
potentiometer
(SD(205,1,2);
SD(5,4,1)=0 if no 2nd spindle is applied)
5 1 2
Last-programmed velocities:
5 3 2
D Feed in entry units per minute
D Spindle speed in rpm; evaluated using potentiometer
5 4 2 (SD(205,2,1);
SD(5,3,2)=0 if no spindle is applied)
D Spindle speed of 2nd spindle in rpm; evaluated using
5 3 3 potentiometer
(SD(205,2,2);
5 4 3
SD(5,4,2)=0 if no 2nd spindle is applied)
Actual speed (SD(205,3,1))
Actual speed of 2nd spindle (SD(205,3,2))
* : Number of a channel:
If the given channel is not active, axes from this channel may already be assigned, i.e. they are currently
active in another channel. Nevertheless, assigned axes belong to the given channel.
Example: axis X2 belongs to channel 2 (not active) and X2 is currently being driven synchronously in channel
1. Axis X2 is taken into account in both SD instructions Number of synchronous axes of the channel of
SD(21,2,...) and SD(21,1...).
5-42 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Group Index1 Index2 Index3 Affects Description


function
8 Supplies the channel number of the calling channel.
9 G75 Probe activated: SD(9)=0 (G75 not active)
Probe not activated: SD(9)=1 (G75 active)
FsProbe Measurement at fixed stop SD(9)=0 (FSB not active)
executed:
Measurement at fixed stop SD(9)=1 (FSB active)
not yet executed:
10 1,2 1,2,3 Index 1: 1= No. of last-programmed tap
2= No. of the active tap
Index 2: 1= axis that affects the L1 correction
2= axis that affects the L2 correction
3= axis that affects the L3 correction
SD(10, i ) = SD(10, i ,3)
11 1 1 Main axis of the last-programmed plane switch
11 2 1 Secondary axis of the last-programmed plane switch
11 1 2 Main axis of the active plane
11 2 2 Secondary axis of the active plane
12 1 Active spindle direction of rotation (SD(212,1,1):
SD(12,1)= 3 Spindle rotates clockwise
SD(12,1)= 4 Spindle rotates counterclockwise
SD(12,1)= 0 Spindle stop
SD(12,1)= -1 Spindle not applied
SD(12,1)= 19 Align spindle
12 2 Last-programmed spindle direction of rotation
(SD(212,2,1); Functions as for Active direction of rota-
tion of spindle)
An active change of the direction of rotation for each inter-
face signal is not taken into account!
12 3 Active direction of rotation of spindle (2nd spindle)
(SD(212,1,2); functions as for Active direction of rotation
of spindle)
12 4 Last-programmed direction of rotation of spindle (2nd
spindle)
(SD(212,2,2); functions as for Active direction of rotation
of spindle)
* : Number of a channel:
If the given channel is not active, axes from this channel may already be assigned, i.e. they are currently
active in another channel. Nevertheless, assigned axes belong to the given channel.
Example: axis X2 belongs to channel 2 (not active) and X2 is currently being driven synchronously in channel
1. Axis X2 is taken into account in both SD instructions Number of synchronous axes of the channel of
SD(21,2,...) and SD(21,1...).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-43
and Controls

System Data

Group Index1 Index2 Index3 Affects Description


function
13 Processing types when processing at interpretation time:
SD(13)= 0 Single block, single step
SD(13)= 1 Next block
SD(13)= 2 Program block
SD(13)= 11 NC program restart with next block
(selected block not yet interpreted).
14 Number of active language
(machine parameter 6010 00010)
15 Test without movement SD(15)=0 : no
SD(15)=1 : yes
20 1, 2 Supplies the number of synchronous axes of the calling
channel:
SD(20,1) = Value (default) at time of
block preparation
SD(20,2) = Value at active time.

21 1 to n* 1, 2 Supplies the number of synchronous axes of a channel:


SD(21, <1 - n> ,1) = Value (default) at time of
block preparation
SD(21, <1 - n> ,2) = Value at active time.
1 - n = Channel number,
n= max. number of channels
22 1-m 1, 2 Supplies the channel axis number of a system axis of the
or calling channel or -1:
Channel SD(22, <1 - m>|String ,1) = Value (default) at time of
axis de- block preparation.
signa- SD(22, <m>|String ,2) = Value at active time.
tion
1 - m = System axis number;
m= max. number of system axes
String = System axis name
23 1-m 1, 2 Supplies the system axis number of a channel axis of the
or calling channel or -1:
Channel SD(23, <1 - m>|String ,1) = Value (default) at time of
axis de- block preparation.
signa- SD(23, <1 - -m>|String ,2) = Value at active time.
tion
1 - m = Channel axis number;
m= max. number of channel axes
String = Channel axis name

* : Number of a channel:
If the given channel is not active, axes from this channel may already be assigned, i.e. they are currently
active in another channel. Nevertheless, assigned axes belong to the given channel.
Example: axis X2 belongs to channel 2 (not active) and X2 is currently being driven synchronously in channel
1. Axis X2 is taken into account in both SD instructions Number of synchronous axes of the channel of
SD(21,2,...) and SD(21,1...).
5-44 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Group Index1 Index2 Index3 Affects Description


function
24 1-m 1 to n* 1, 2 Supplies the system axis number of a channel axis or -1:
or SD(24, <1 - m>|String ,<1-n>,1) = Value (default) at time
Channel of block preparation.
axis de- SD(24, <1 - m>|String ,<1 - n>,2) = Value at active
signa- time.
tion
1 - n = Channel number,
n= max. number of channels
1 - m = Channel axis number;
m= max. number of channel axes
String = Channel axis name
25 1-m Supplies the channel of a system axis:
or SD(25, <1 - m>|String) = Value at active time.
Channel
1 - m = System axis number;
axis de-
m= max. number of system axes
signa-
String = System axis name
tion
68 1 1...8 Trans, D Sum of the last-programmed program coordinate off-
ATrans sets (Trans + ATrans) for the given axis (Index2).
D Sum of the active program coordinate offsets (Trans +
68 2 1...8 ATrans) for the given axis (Index2).
D Value of the last-programmed program coordinate offset
(Trans) for the given axis (Index2).
168 1 1...8 D Value of the active program coordinate offset (Trans) for
the given axis (Index2).
D Value of the last-programmed additive program coordi-
168 2 1...8 nate offset (ATrans) for the given axis (Index2).
D Value of the active additive program coordinate offset
268 1 1...8 (ATrans) for the given axis (Index2).

268 2 1...8
77 Supplies the currently set restarting point of an asynchro-
nous subroutine:
1: Starting point
2: End point
3: Interruption point

131 1 TangTool Channel axis number of the rotating axis


131 2 Symmetry
* : Number of a channel:
If the given channel is not active, axes from this channel may already be assigned, i.e. they are currently
active in another channel. Nevertheless, assigned axes belong to the given channel.
Example: axis X2 belongs to channel 2 (not active) and X2 is currently being driven synchronously in channel
1. Axis X2 is taken into account in both SD instructions Number of synchronous axes of the channel of
SD(21,2,...) and SD(21,1...).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-45
and Controls

System Data

Group Index1 Index2 Index3 Affects Description


function
200 1 Working D Number of active ranges in the channel.
200 1 1...10 range, D Indicates whether range i (Index2) is active:
dead range 0: Range i (Index2) is not active
200 3 1...10 D Type of range i: 0: Type not defined
1: Dead range
2: Working range
200 11 1...10 D Position of the center point of range i (Index2) in pro-
gramming units (for the 1st range axis).
200 12 1...10 D Position of the center point of range i (Index2) in pro-
gramming units (for the 2nd range axis).
200 21 1...10 D Extent of range i (Index2) in programming units (for the
1st range axis).
200 22 1...10 D Extent of range i (Index2) in programming units (for the
2nd range axis).

spindles 1...8 = Spindle number Old but still valid SD


functions:
202 1...8 Current potentiometer value SD(2,3), SD(2,4)
205 1 1...8 Active command speed (incl. SD(5,3,1), SD(5,4,1)
potentiometer)
205 2 1...8 Last-progr. Command SD(5,3,2), SD(5,4,2)
205 3 1...8 speed SD(5,3,3), SD(5,4,3)
212 1 1...8 Actual speed SD(12.1), SD(12.3)
212 2 1...8 Active movement function SD(12.2), SD(12.4)
Last-progr. movement func-
tion
* : Number of a channel:
If the given channel is not active, axes from this channel may already be assigned, i.e. they are currently
active in another channel. Nevertheless, assigned axes belong to the given channel.
Example: axis X2 belongs to channel 2 (not active) and X2 is currently being driven synchronously in channel
1. Axis X2 is taken into account in both SD instructions Number of synchronous axes of the channel of
SD(21,2,...) and SD(21,1...).
5-46 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Group Index1 Index2 Index3 Affects Description


function
328 PrecProg Last-programmed precision limit of PrecProg
328 1 Last-programmed precision limit of PrecProg
328 2 Last-programmed corner spacing of PrecProg

Axis cou- m: Channel axis number of the master in the current chan-
pling nel
581 0 1...8(m) s: Channel axis number of the slave in the current channel
D Channel axis number = m if the axis is a leading axis;
0: if no leading axis exists
581 1 - 8(s) 0 D Number of the leading axis for which axis s is a following
axis
0: if s is not a following axis
581 1 - 8(s) 1 D Programmed following axis offset in programming units.
0: if s is not a following axis
D Programmed coupling factor
581 1 - 8(s) 2 0: if s is not a following axis
D Programmed leading axis offset in programming units
581 1 - 8(s) 3 0: if s is not a following axis

* : Number of a channel:
If the given channel is not active, axes from this channel may already be assigned, i.e. they are currently
active in another channel. Nevertheless, assigned axes belong to the given channel.
Example: axis X2 belongs to channel 2 (not active) and X2 is currently being driven synchronously in channel
1. Axis X2 is taken into account in both SD instructions Number of synchronous axes of the channel of
SD(21,2,...) and SD(21,1...).

Examples:
30 A% = SD(2,1) A% contains the active position of the feed
: potentiometer in percent
40 B% = SD(5,1,1) B% contains the active feed velocity
:

Sample program: SD (probe query)


N4 G75 X120
60 IF SD(9)=1 THEN
N7 (MSG, probe has not been deflected!)
80 GOTO .FEHLER
90 ELSE
100 XMESS = PPOS(1)
110 ENDIF

In the SD (probe query) example, the X-axis is driven in the direction of


the given position. If the position is attained and the probe has not been
deflected, a message (line N7) is issued and a jump to label .FEHLER
occurs. If the probe is deflected, the current position, based on the pro-
gram coordinate system in XMESS, can be saved.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-47
and Controls

System Data

SDR
Reads from a collection of system dataIndraMotion MTX in REAL-for-
mat. The format and application of the command correspond to the SD-
function.

Syntax:
SDR(<Group>[,<Index1>[,<Index2>]])

Group Index1 Index2 Affects Description


function
1 1...8 Axis positions of all processing-axes that were calculated in the NC
program restart / re-entry (Index1 = axis number).
If there is no NC program restart, 0 is returned.
If an unapplied axis or an auxiliary axis is addressed, a runtime error
occurs.

Active override-setting for the corresponding potentiometer (in per-


2 1 cent):
2 3 D Feed
2 4 D Spindle (SD(2,3)=0 if no spindle is applied)
D 2. spindle (SD(2.4)=0 if no 2nd spindle is applied)

202 1...8 Current potentiometer-value


(old but still valid SDR-function: SDR(2,3), SDR(2,4)
68 1 1...8 Trans, D Sum of the last-programmed program coordinate offsets (Trans +
ATrans ATrans) for the given axis (Index2).
68 2 1...8 D Sum of the active program coordinate offsets (Trans + ATrans) for
the given axis (Index2).
168 1 1...8 D Value of the last-programmed program coordinate offset (Trans)
for the given axis (Index1).
168 2 1...8 D Value of the active program coordinate offset (Trans) for the given
axis (Index2).
268 1 1...8 D Value of the last-programmed additive program coordinate offset
(ATrans) for the given axis (Index1).
268 2 1...8 D Value of the active additive program coordinate offset (ATrans) for
the given axis (Index2).

77 Name In asynchronous subroutine:


of ma- 0 D Supplies the current approach point according to ASPRTP/RE-
chine POSTP of a machine coordinate in the interruption block.
coordi-
1 D Supplies the starting point of a machine coordinate in the interrup-
nate
tion block.
2 D Supplies the end point of a machine coordinate in the interruption
block.
3 D Supplies the interruption point of a machine coordinate in the in-
terruption block.
The supplied position permits repositioning of the coordinates in the
vicinity of the desired approach point within an asynchronous subrou-
tine using G76.
5-48 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Group Index1 Index2 Affects Description


function
131 3 Tangential D Supplies the positioning angle in degrees (Index2).
131 4 tool gui- D Supplies the intermediate block angle in degrees (Index2).
dance

328 PrecProg D Last-programmed precision limit of PrecProg


328 1 D Last-programmed precision limit of PrecProg
328 2 D Last-programmed corner spacing of PrecProg

Axis cou- m: Channel axis number of the master in the current channel
pling s: Channel axis number of the slave in the current channel
581 0 1...8(m) D Channel axis number = m if the axis is a leading axis;
0: if no leading axis exists
D Number of the leading axis for which axis s is a following axis
581 1 - 8(s) 0 0: if s is not a following axis
D Programmed following axis offset in programming units.
0: if s is not a following axis
581 1 - 8(s) 1 D Programmed coupling factor
0: if s is not a following axis
D Programmed leading axis offset in programming units
581 1 - 8(s) 2 0: if s is not a following axis

581 1 - 8(s) 3

5.8.2 System data of structured types


Structured system data (abbreviated SD) are a class of data in the over-
all system with the following properties:
D Individual SD can be located in the volatile or the nonvolatile memory
(permanent SD), as desired.
D The number, size and structure can be freely defined within the fra-
mework of the existing memory.

You can find extensive information regarding the use and definition of
system data in the Description of Functions.

Access in the CPL is carried out with keyword SD. As opposed to XPath
addressing (standardized access to structured data), the point operator
. is used in place of the separator /. Arrays are addressed with [ ], e.g.
Xpath: /MyArrVar[2,3,4]/subcomponent
CPL: SD.MyArrVar[2,3,4].subcomponent

Example:
10 SD.MyChanVar=DBSEA(/dbt1/Rec,-1,-1,Key1=1,I%)

For channel-specific SDs, the channel index is not required, e.g.:


SD.MyArrVar[,3,4] or
SD.MyChanVar without [ ] for a one-dimensional channel SD.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-49
and Controls

System Data

Any CPL expressions that supply an integer value can be programmed


within the square brackets.
SDs with the same structure types can be assigned to one another. The
following assignment rules apply to basic types:

Name Length in bytes Description C-type IndraLogic type CPL


string 2 * maxLength + 1 string char [ ] STRING() STRING
(UTF-8 format)
IsoLatin1String maxLength + 1 string char [ ] STRING() STRING
(Latin1 format)
Byte_t 1 Signed 8-bit char SINT INT
integer
Short_t 2 Signed 16-bit short INT INT
integer
Int_t 4 Signed 32-bit int DINT INT
integer
UnsignedByte_t 1 Unsigned 8-bit unsigned char USINT INT
integer
UnsignedShort_t 2 Unsigned 16-bit unsigned UINT INT
integer short
UnsignedInt_t 4 Unsigned 32-bit unsigned int UDINT INT
integer
Float_t 4 32-bit real float REAL REAL
Double_t 8 64-bit real double LREAL DOUBLE
Boolean_t 1 true, false, 1, 0 char BOOL BOOLEAN

Permanent system data are reinitialized once while volatile system data
are reinitialized each time the system is started. The values can be spe-
cified in an initialization file. If nothing is specified there, the values are
preset to 0.
Structured variables (SV) can be replaced by SDs; however, they are
retained for reasons of compatibility.
5-50 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

5.9 Variable Axis Address

AXP
This function allows parts and measurement programs to be written re-
gardless of the plane.

AXP(<Axis number>,<Path information>[,<Axis type>])


The function is applied in an NC block. It must be between brackets [ ]
and is programmed in place of the address values.

<Axis number> Index of workpiece-coordinate or system -axis


<Path information> Variable or value of the path information
<Axis type> optional:
Determines how an index programmed under
<Axis number> is interpreted:
0: System axis index.
1: Index of the workpiece coordinate of the
channel in which the program is currently
being processed.
If there is no explicit programming, <Axis type>
is set to 1.

Example:
Subroutine:
10 A%=P1% : B%=P2% Transfer axis No. from P1%
and P2% to A% and B%
20 C=P3:D=P4:RA=P5 Transfer command values for
G2
30 E=0 Constant for pole at G20
N40 G20 [AXP(A%,E)][AXP(B%,E)] Plane switch with G20;
pole at 0.0
N50 G2 [AXP(A%,C)][AXP(B%,D)] Radius programming with G2
R[RA]] F1000

Plane definition using A% and B%. Then switch the plane using G20.
Finally, the axes move with F1000 through an arc that is defined by va-
riables C, D (end point) and RA (radius).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-51
and Controls

System Data

5.10 PLC Interface

BITIF
This function permits access to the digital interface between the NC and
the PLC.
D All inputs and outputs can be read.
D CPL customer outputs Ch_Cpl01 - 16 in the channel interface can
also be written.

BITIF(<Bit signal>[,<Index>[,<IF-Unit>]])
where:
<Bit signal> Bit offset or symbolic address.
Bit offset: 0-31 for global interface
0-111 for channel interface
0-95 for axis interface
0-95 for spindle interface
0-7 for high-speed interface
For the symbolic addresses, see the PLC Interface Ma-
nual.
<Index> Index of the axis, the spindle or the channel.
If an index is not programmed, the following applies for
the query:
- active channel for channel interface
- axis 1 for axis interface
- spindle 1 for spindle interface
<IF unit> 0 or QCH: PLC output signals (channel-based)
1 or QAX: PLC output signals (axis-based)
2 or QSP: PLC output signals (spindle-based)
3 or ICH: PLC input signals (channel-based)
(incl. CPL-customer outputs of the NC)
4 or IAX: PLC input signals (axis-based)
5 or ISP: PLC input signals (spindle-based)
6 or QGEN: PLC output signals (global)
7 or IGEN: PLC input signals (global)
8 or QHS: PLC output signals (high-speed)
9 or IHS: PLC input signals (high-speed)
5-52 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Examples:
I?=BITIF(QGEN_RESET) Reads global output signal System re-
set.
I?=BITIF(ICH_RESET,1) Reads channel input signal Channel re-
set from channel 1
I?=BITIF(0,1,IAX) Reads axis input signal Reference point
known for axis 1
I?=BITIF(88,2,5) Reads spindle input signal Status class
1 error for spindle 2
BITIF(ICH_CPL05)=1 Writes CPL customer output 5 with a va-
lue of 1
BITIF(50,1,3)=TRUE
BITIF(ICH_CPL02)=FALSE

PLC
This function permits access to the operands of the PLC.

PLC(<Type>,<Empty param.>,<Address>,<Size>)
where:
<Type> 1: Input (E)
2: Output (A)
3: Flag (M)
Read access is permitted for all the types.
Write access to flags is permitted when 2060 00200
is set to a value of 5 (= IndraLogic).
<Empty param.> (not assigned)
<Address> Relevant byte address starting at beginning of area.
The control checks the parameter according to the
active PLC.
<Size> Size of the data type:
1: Byte
2: Word
3: Double-word

Example:
:
30 REM Read 2 bytes starting at input 10
40 I% = PLC(1,,10,2)
:
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-53
and Controls

System Data

5.11 Time Recording

CLOCK
Reads out the system time within the control in milliseconds.

Example:
:
20 WAIT
30 START TIME% = CLOCK
N4 G1 X50 Y70
40 WAIT
50 END TIME%=Clock : DIFF%=END TIME%-START TIME%
:

The current clock status is assigned to variables STARTZEIT% /


ENDZEIT% before and after block N4 is executed. The block execu-
tion time of N4 (in milliseconds) can be determined from the difference
between the contents of the two variables.
Note that the WAIT command is absolutely required for this!

DATE
Supplies the current value for the date.

Example:
: The date in the form DD.MM is assigned to
30 A$ = DATE STRING variable A$.
:

TIME
Supplies the current value for the time.

Example:
: The time in the form HH.MM.SS is assigned
40 B$ = TIME to STRING variable B$.
:

. If DATE/TIME is used several times within a program, the corres-


ponding result variables must be dimensioned. Otherwise, the last
read value of the DATE/TIME function is assigned to all nondimen-
sioned variables that contain the result of a DATE/TIME assign-
ment.
5-54 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

5.12 Errors and Error Categories

GETERR
This function calls the current errors in a CPL program. It contains the
current error No., the channel No. of the error and the associated error
category.
Each error that occurs is saved, together with these elements, to an ar-
ray. The max. number of errors that fit into the array is limited by the di-
mensioning (DIM) of parameter <Error No> .

Function GETERR supplies the following return values:


D -1: Function could not be executed.
D  0: Number of errors in the <channel>.

GETERR(<Channel>,[<Category>],<Error No>[,<Number>])
<Channel> Channel No. of the queried channel
-1 : All channels
> 0: Channel No.
<Category> 0: All warnings and errors (default)
1: Low-priority system error
2: Control or drive error
3: Interpolator error
4: Hardware error
5: ICL error
6: Parts program error
7: Runtime warnings
8: MZA messages: Error
9: MZA messages: Warnings
10: MZA messages: Notes
<Error No> Result variable:
Two-dimensional integer array with at least 3 ele-
ments in the second dimension (DIM <Error-No.>%
(x,3)), default value: 0.
The function supplies the current error numbers from
the <channel> in decreasing order according to the
time they occurred.
Meaning of the 3 elements of the 2nd dimension:
<Error No>(x,1): Error No.
<Error No>(x,2): Error channel
(-1 = cross-channel)
<Error No>(x,3): Error category (if declared using
DIM
command).
0 = Unknown category
Other values = as for <Category>
Example: DIM ERRNO% (100,3).

. Only the variable name, without dimension/index,


may be entered!
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-55
and Controls

System Data

<Number> Integer variable (default value: 1 )


Specifies the number of errors to be read.
1: Default value
> 0: Parameter values are not checked for
validity; i.e. if the number of data to be read
is greater than the array dimension,
a parts program error is not issued.
Example:
<Number> =120, but DIM ERRNO% (100,3).
In this case, 20 errors are not read.

Example:
Query the last parts program error in channel 2
10 DIM ERRN=%(5,3) : REM Integer array with 5 elements
20 REM Query the last parts program error in channel 2
30CHAN%=2:CATEGORY%=6
40ERG%=GETERR(CHAN%,CATEGORY%,ERRNO%,1)
:

Example:
Result-evaluation for 5 array elements.-
10 DIM ERRNO%(5,3):REM Integer array with 5 elements
20 CHAN%=2 : CATEGORY%=0
25 REM query part progr.-error in channel 2
30 ERG%= GETERR(CHAN%, CATEGORY%, ERRNO%, 5)
40 FOR I%= 1 TO ERG%
50
50 IF ERRNO%(I%,3)=6 THEN
60 PRN#(0, Parts program error: ,ERRNO%(I%,1))
70 ENDIF
80 NEXT I%
5-56 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Criteria for selecting the errors: Result in Erg% that fulfills the
- Channel 2 criteria of GETERR(..):
- Category 6 = 2, i.e. 2 errors were
- Max. number of errors to be recorded: 5 found

DIM ERRNO%(5,3)
Latest Array-element
reported error
1 1856 Error No.
Array-index: 1 2 2 Error channel:
3 2 Error-category

1 1869
Array-index: 2 2 2
3 1

1 1938 ERRNO%(3,1)= 1938


Array-index: 3 2 2
3 6

1 1970
Array-index: 4 2 2
3 10

1 1971 ERRNO%(5.1)= 1971


Array-index: 5 2 2
3 6

1 1970 This error is no longer


2 2 taken into account
because the array can
3 6 take on only 5 elements
Earliest reported error according to the DIM
command

As the result, parts program errors 1938 and 1971 are output in the
MSG window. Variable Erg% contains a value of 2.

. Among other things, GETERR can be used to record the chronolo-


gical occurrence of one or more errors, permitting the actual
cause of the errors to be traced.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-57
and Controls

System Data

5.13 NCS Coupling


NCS coupling functions can be used to access process and data ser-
vices of the internal NCS interface using CPL.

5.13.1 Possible error return values of the functions


All function calls supply a return value for control and error handling. An
integer or real variable can be assigned to this value.

Example:
ERR_VAR% = MCOPS(...)
ERR_VAR% = MCODS(...)

CAUTION
Improper program reactions possible!
When called functions return an error code, it may happen that im-
portant actions in the remainder of the program run are carried out
incompletely or not at all.
We therefore strongly recommend that you check the program
(e.g. using CASE) after a function is called to see whether the
function could be executed without errors.
The remaining program behavior then is determined by the type
and severity of the error that occurred.

The following return values have been defined:


0: No error has occurred
1: The given channel does not exist
2: The function can not be executed because the given channel is cur-
rently occupied (the current status does not permit the action)
3: A reset that has been started in the given channel has not yet been
completed.
4: The given program name is too long (currently not in use)
5: The function requires approached reference points
6: The given program does not exist or cannot be executed
7: During buffered NC block input, writing to the buffer was interrupted. A
second instance had attempted to write to the buffer at the same time.
8: The function cannot be executed in the current operating mode
9: The channel cannot be started because the status is not READY
10: The function cannot be executed because no program has been se-
lected
11: The given program cannot be selected because the channel status
does not permit this (e.g. the status of block preparation and the inter-
polator is RUNNING)
12: currently not in use
13: The operating mode cannot be switched because the channel status
does not permit this
5-58 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

14: The target of Search block was not found


15: Search block is not possible because, although the channel status is
READY, processing of the main program has already started (e.g.
program is at M0)
16: The number of axes is too high for the presetting of external zero point
offsets
17: The number of axis ZO groups is too high for the presetting of external
zero point offsets
18: The entered syntax is unknown
19: Invalid index with specification of an ext. tool compensation
20: The number of compensations in the specification of an ext. tool com-
pensation is too high (possibly in connection with the compensation
index)
21: Improper format when entering an external tool compensation. tool
compensation
22: Invalid edge position with specification of an ext. tool compensation
23: Invalid compensation group
24: Addressed axis does not exist
25: In the case of an NC block input with automatic start, a runtime error,
e.g. a syntax error, was detected.
26: In the case of a buffered NC block input, the buffer has been ex-
ceeded.
27: The entry for the coordinate filter is not correct.
100: The magic number of the telegram is incorrect
101: NCS communication is not working properly
102: The given function is not available in this software version
103: An internal error has occurred (currently not in use)

. If the calling program also contains NC blocks, block preparation


generally occurs before processing in the machine. If a process
service is requested or a machine status queried using the MCOPS
or MCODS function at the time of block preparation, any require-
ments on the machine may not have been fulfilled.
However, this problem only occurs for functions that access preci-
sely the channel in which they are executed themselves.
In this case, use the WAIT command in the line preceding the func-
tion call. This stops block preparation until all the blocks before
WAIT have actually been processed.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-59
and Controls

System Data

5.13.2 Available functions

MCODS
Calls Motion Control data services of the NCS via CPL. This allows the
data and states to be read from the CNC.

. All read values refer to the time at which the CPL block is proces-
sed by block preparation.
If the calling program also contains NC blocks, block preparation
generally occurs before processing in the machine. If program ex-
ecution is to be affected by functions that determine current ma-
chine data or states, you must eliminate the time delay between
block preparation and the current machine status. However, this
applies only to functions that access precisely the channel in
which they are executed themselves.
In this case, use the WAIT command in the line preceding the func-
tion call. This stops block preparation until all the blocks before
WAIT have actually been processed.

The functions supply a return value (see section 5.13.1).

General syntax:
MCODS(<Type>,<Channel>,<Version>,<Buffer>,<Size>,<Axis
number>,<ID number>[,<P1>])
<Type> Integer expression. This indicates the function to be
executed.
The following table lists all the available functions.
<Channel> Integer expression. Indicates the channel which the
function is to affect.
<Version> Initialized integer- or real- variable (no constant!).
If the variable content = 0 when the function is called,
the function specified by <Type> immediately writes
the requested data to the<Buffer>.
In addition, the function returns a version ID of the
supplied data in <Version>. If this version ID is still
contained in the variable the next time that the func-
tion is called, the function does not write the reque-
sted data immediately, but rather after the next time
the data in <Buffer> are modified.
In this way, for example, a program loop can be run
until a channel has attained a certain status. Howe-
ver, you should incorporate a timeout condition (e.g.
counter or elapsed period) in the loop to prevent end-
less loops!
<Buffer> The function returns the requested data values in
<Buffer>. Depending on the type of data, <Buffer>
must be a:
5-60 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

- simple variable of type integer, real, double


- field variable of type integer, real, double
- string variable (1-dimensional character field).

. For field or string variables, only the variable


name, without dimension/index, may be entered!

<Size> Integer expression. Specifies the field size of <Buf-


fer>
If <Buffer> is not a field variable, but rather a simple
variable of type integer, real or double, enter a value
of 1 for <Size>.
<Axis number> Integer expression. Indicates the axis number of a sy-
stem axis.
<ID number> Integer expression. Supplies the value of an <ID
number> from the cyclic axis telegram for all axes.

. The size of a field variable that is used must first


be defined using the DIM-command; it may not be
exceeded in parameter <Size>!

<P1>: Optional parameter that depends on <Type>.

Function overview of MCODS(...)


Positions
Command axis position see MCODS(1..)
Command axis position see MCODS(2..)
Actual axis-position see MCODS(35..)
Actual axis-values (machine coordinate system) see MCODS(38..)
Lag see MCODS(4..)
Axis-program value (program coordinate see MCODS(37..)
system)
Programmed end positions, incl. offsets see MCODS(16..)
Programmed end positions, without offsets see MCODS(23..)
Velocity and speed
Path velocity see MCODS(3..)
Programmed path velocity see MCODS(24..)
Jog speeds see MCODS(27..)
Command spindle-speed, -surface speed see MCODS(5..)
Actual spindle-speed see MCODS(36..)
Maximum spindle speed see MCODS(19..)
Minimum spindle speed see MCODS(20..)
Programmed spindle speeds see MCODS(25..)
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-61
and Controls

System Data

States
Status InPos see MCODS(6..)
Status Test mode see MCODS(29..)
Status Traverse to reference point see MCODS(26..)
Status Dwell time active see MCODS(39..)
Status Auxiliary function which requires see MCODS(40..)
acknowledgement active
Status Reading release see MCODS(41..)
Status Travel command see MCODS(47..)
Status Feed inhibit see MCODS(49..)
SAV- and IPO-status see MCODS(32..)
Potentiometer
Value of feed-potentiometer see MCODS(7..)
Values of spindle-potentiometer see MCODS(8..)
Value of axis-potentiometer see MCODS(50..)
Corrections
Active length correction number see MCODS(9..)
Active length correction see MCODS(10..)
Active tool-radius correction number see MCODS(11..)
Active tool-radius correction see MCODS(12..)
Name of active tool-correction table see MCODS(13..)
Name of active axis-ZO-table see MCODS(14..)
Active axis-ZO-values see MCODS(15..)
Active external -correction values see MCODS(51..)
Active external axis-ZO-values see MCODS(52..)
Active universal tool correction see MCODS(54..)
Operating modes
Channel operating mode see MCODS(31..)
Axis operating mode see MCODS(48..)
System structure
Number of feed axes, auxiliary axes, spindles; see MCODS(34..)
movement types, drive types
Number of channels see MCODS(44..)
Number of axes see MCODS(45..)
Axis name see MCODS(33..)
Active channel-axis name see MCODS(59..)
Channel-axis name (default setting) see MCODS(60..)
Axis-channel assignment see MCODS(43..)
Axis-channel default-assignment see MCODS(58..)
5-62 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

ID number from cyclic axis telegram see MCODS(62..)


Measurement units
Axis units (default setting) see MCODS(61..)
Axis units see MCODS(53..)
Type of programming (inch/metric) see MCODS(18..)
Diameter-programming see MCODS(91..)
Auxiliary functions
Group numbers of auxiliary functions see MCODS(94..)
Active syntax of auxiliary function groups see MCODS(65..)
spindles
Movement functions of the spindles see MCODS(63..)
Gear ranges of the spindles see MCODS(64..)
Automatic/manual gear range selection see MCODS(66..)
Information whether gear switching is active see MCODS(67..)
Drive
Manufacturer version see MCODS(55..)
Control type see MCODS(56..)
Motor type see MCODS(57..)
Other
Messages in parts program see MCODS(28..)
Path and name of main program see MCODS(30..)
Return-to-path-strategy and recording of see MCODS(46..)
jogging movements
Customer-specific data see MCODS(42..)
Optional stop (activated) see MCODS(68..)
Skip block (activate) see MCODS(69..)
Automatic program reselection active see MCODS(70..)

. In the following table, integer constants are sometimes shown as


parameters for the syntax. In place of these constants, you can
also program integer variables; however, these must have been
assigned the given value at the time that the function is called.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-63
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Command axis position Double, Array MCODS(1,-1,<Version>,<Buffer>,<Size>)
C Supplies in increasing, channel-independent order the
command positions of all feed and auxiliary axes in the
systemto <Buffer>:
in mm for linear axes
in degrees for rotary axes
Set actual value (e.g. G92) is included in the values.
Command axis position Integer, Array MCODS(2,-1,<Version>,<Buffer>,<Size>)
C Supplies in increasing, channel-independent order the
command positions of all feed and auxiliary axes in the
systemto <Buffer>:
in 0.0001 mm for linear axes
in 0.0001 degrees for rotary axes
Set actual value (e.g. G92) is included in the values.
Path velocity Real, Array MCODS(3,<Channel>,<Version>,<Buffer>0.3)
C Supplies 3 values with current path velocities of
<Channel> (incl. the feed potentiometer) in increasing
order to <Buffer> in the unit mm/min:
1. the command velocity that is assigned externally to
the interpolator.
2. the actual interpolator velocity (= current path veloc-
ity).
3. the command internal interpolator velocity. It may
have changed compared to the externally assigned
one due to an application (e.g. Feed-Adapt function).
If feed programming is in mm/rotation (G95), it sup-
plies the path acceleration in mm/min.

Lag Real, Array MCODS(4,-1,<Version>,<Buffer>,<Size>)


C Supplies, in increasing order, the coasting of all system
axes to <Buffer>:
in mm for linear axes
in degrees for rotary axes
If transferring coasting (via SERCOS parameter) is not
supported by the drives, a value of 0.0 is returned.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
5-64 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Command spindle speed, Real, Array MCODS(5,-1,<Version>,<Buffer>,<Size>)
surface speed
C Supplies, in increasing order (S or S1, S2, S3, etc.), the
command spindle speeds or surface speeds of all the
spindles that exist in the system to <Buffer>.
If G196 is active, the surface speeds are supplied in
m/min; otherwise the current command spindle speeds
are supplied in rpm.
The potentiometer, the speed limitations (SMin, SMax)
and the limitations due to the gear range are included in
the calculation.
If a spindle does not exist , 0.0 is returned at the
corresponding position in <Buffer>.
Status InPos Integer, Array MCODS(6,-1,<Version>,<Buffer>,<Size>)
C Supplies, in increasing, channel-independent order, a
value of 0 or 1 as the InPos signal for each feed and
auxiliary axis in <Buffer>:
Axis is in position:
Axis is not in position: 0
An axis is in position if it is in the parameterized
InPos-window (MP 1015 00100) and there is no
movement command (also see MCODS(47...) ).
Value of feed-potentiometer real MCODS(7,<Channel>,<Version>,<Buffer>,1)
C Supplies the current value of the feed potentiometer of
<Channel> in 1/100 percent to <Buffer>.
Values of spindle Real, Array MCODS(8,-1,<Version>,<Buffer>,<Size>)
potentiometers
C Supplies the current values of the feed potentiometer in
1/100 percent in increasing order for all the spindles that
exist in the system (S or S1, S2, S3, etc.) to <Buffer>.

Active length correction number integer MCODS(9,<Channel>,<Version>,<Buffer>,1)


S Supplies the length correction number that is active in
<Channel>to <Buffer>. If length correction is not active,
-1 is returned.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-65
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Active length correction real MCODS(10,<Channel>,<Version>,<Buffer>,1)
S Supplies the length correction (in mm) that is active in
<Channel> to <Buffer>. If length correction is not active,
0.0 is returned.

Active tool-radius correction integer MCODS(11,<Channel>,<Version>,<Buffer>,1)


number
S Supplies the radius correction number that is active in
<Channel> to <Buffer>. If radius correction is not active,
-1 is returned.

Active tool-radius correction real MCODS(12,<Channel>,<Version>,<Buffer>,1)


S Supplies the radius correction (in mm) that is active in
<Channel> to <Buffer>. If tool-radius correction is not
active, 0.0 is returned.

Name of active tool-correction Character, MCODS(13,<Channel>,<Version>,<Buffer>,<Size>)


table Array
S Supplies the name of the tool correction table that is
active in <Channel> to <Buffer>. If none is active, 3
blanks are returned as a string.

Name of active axis ZO table Character, MCODS(14,<Channel>,<Version>,<Buffer>,<Size>)


Array
S Supplies the name of the axis ZO table that is active in
<Channel> to <Buffer>. If none is active, 3 blanks are
returned as a string.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
5-66 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Active axis ZO values Real, Array MCODS(15,<Channel>,<Version>,<Buffer>,<Size>)
S Supplies the axis ZO values of all the pages for all the
feed axes (in mm) that are active in <Channel> to
<Buffer>. If no offset is active, 0.0 is returned.
The following order applies:
D Offset of the 2nd axis in page 1
D Offset of the 2nd axis in page 2
D Offset of the nth axis in page 1
D Offset of the 1st axis in page 2
:
D Offset of the nth axis in page 2
:
D Offset of the nth axis in page 3

Programmed end positions, Real, Array MCODS(16,0,<Version>,<Buffer>,<Size>)


incl. offsets
S Supplies, in increasing, channel-independent order, the
end positions of the active blocks for all feed- and
auxiliary axis based on the workpiece coordinates to
<Buffer>:
D in mm for linear axes
D in degrees for rotary axes
All offset values have been calculated.
Set actual value (e.g. G92) is not included in the values.
Type of programming integer MCODS(18,<Channel>,<Version>,<Buffer>,1)
(inch/metric)
S Supplies the programming type of the axes that exist in
<Channel> to <Buffer>.
0: inches
1: metric
2: degrees
3: no axes present
Maximum spindle speed Real, Array MCODS(19,0,<Version>,<Buffer>,<Size>)
S Supplies the maximum permitted spindle speeds (in rpm)
of all spindles in the system to <Buffer>.
Order: S or S1, S2, etc.
The speed limitations are included in the calculation.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-67
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Minimum spindle speed Real, Array MCODS(20.0,<Version>,<Buffer>,<Size>)
S Supplies the minimum permitted spindle speeds (in rpm)
of all spindles in the system to <Buffer>.
Order: S or S1, S2, etc.
The speed limitations are included in the calculation.
Programmed end positions, Real, Array MCODS(23.0,<Version>,<Buffer>,<Size>)
without offsets
S as for MCODS(16...), but without offsets.
Programmed path velocity real MCODS(24,<Channel>,<Version>,<Buffer>,1)
S Supplies in <Buffer>the programmed path feed of
<channel> in the unit mm/min.
Programmed spindle speeds Real, Array MCODS(25,0,<Version>,<Buffer>,<Size>)
S Supplies the programmed speeds (in rpm) of all spindles
in the system to <Buffer>.
Order: S or S1, S2, etc.

Status Traverse to reference Integer, Array MCODS(26,-1,<Version>,<Buffer>,<Size>)


point
E Supplies, in increasing, channel-independent order, a
value of 0 or 1 as the Traverse to reference point signal
for each feed- and auxiliary axis to <Buffer>:
Traversed to reference point:
Not traversed to reference point: 0

Jog speeds Real, Array MCODS(27,-1,<Version>,<Buffer>,<Size>)


E Supplies in <Buffer> in increasing channel-independent
orgder the current jog speed of all feed- and auxiliary
axes in the system:
in mm/min for linear axes
in rpm for rotary axes

Messages in parts program Character, MCODS(28,<Channel>,<Version>,<Buffer>0.80)


Array
E Supplies the notes programmed using the MSG-command
in <Channel> to <Buffer>.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
5-68 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Status Test mode integer MCODS(29,0,<Version>,<Buffer>,1)
E Supplies a value of 1 to <Buffer> if test mode has been
activated. Otherwise the value is 0.
Path and name of main program Character, MCODS(30,<Channel>,<Version>,<Buffer>,<Size>)
Array
E Supplies the path, including the name, of the main
program that is selected in <Channel> to <Buffer> as a
string.
A value present in <Version> is ignored when the function
is called.
For files that are stored in the NC-internal file system, a
value of 31 must be entered in <Size> (the path, incl. the
file name, may not exceed 30 characters here).
For files that are stored in mounted file systems, the value
in <Size> depends on the maximum permitted number of
characters that is supported by the external file system for
the path and name of a file.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-69
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Channel operating mode integer MCODS(31,<Channel>,<Version>,<Buffer>,1)
E Supplies the operating mode that is active in <Channel>
to <Buffer>:

0: No operating mode, and thus no process, is active.


1: Jog mode. The axes can be jogged (+/-).
2: Traverse to reference point. The axes can be started
using signals Manual+ / Manual-.
3: reserved.
4: Manual entry. Individual NC blocks can be entered for
processing.
5: Automatic (next block). Parts programs are processed
completely.
6: Automatic (program block). Individual blocks of a parts
program are processed sequentially. Each individual
block is prepared and started with NC-Start.
7: Automatic (single step). Under certain conditions, the
NC generates and prepares several blocks from an
individual NC block in the parts program.
In this operating mode, NC-Start is always used to
pass an individual block on to the interpolator for proc-
essing.
8: reserved.
9: reserved.
10:Automatic (single block). With NC-Start, all the blocks
that were generated and prepared due to an individual
NC block in the parts program are passed on to the
interpolator for processing.
11: Restart. The axes can be moved manually away from
the contour, as well as restarted automatically or
manually.
12:CPL debugger (program block mode):
Individual blocks located in the parts program are pro-
cessed.
13:CPL debugger (following block mode):
All the blocks up to the next point of interruption are
processed.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
5-70 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
SAV and IPO status Integer, Array MCODS(32,<Channel>,<Version>,<Buffer>0.2)
E Supplies in <Buffer> from <Channel>
- the SAV-status (block preparation) snd
- the status of interpolator.

The following values are defined for the SAV status:


1: The operating mode is not active. A process can be
selected.
2: The operating mode is ready. A process can be
started.
3: The operating mode is active. A program or NC block
is being processed.
4: reserved.
5: reserved.
6: An error has occurred in the operating mode; this can
be cleared only by Control reset or Program de-
selection.
7: reserved.
8: Control reset is currently being executed.
9: A program has been selected and is currently being
prepared (e.g. linked).
10:Cancel distance to go was triggered and is not fin-
ished.
11: The operating mode is active and is reprocessing ex-
isting buffers.
12:The operating mode is ready. The process is at the
beginning of the program and may be started.
13:All the blocks of the buffered NC block input have
been executed. Waiting for the next input.
The following values are defined for the IPO status:
1: The interpolator is running.
2: The interpolator is stopping due to a feed stop.
3: The interpolator has stopped the axes.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-71
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Axis name Character, MCODS(33,<Channel>,<Version>,<Buffer>,<Size>)
Array
R In case of <channel> = -1 supplies <Buffer> the names of
all system-axes which are separated by the character 0
(0-Byte) in increasing order for 9 bytes each.
In case of <channel> = the existing channel number
<Buffer> supplies the names of all the axes in the given
channel, separated by the character 0 (0-byte) in
increasing order.
Names that are shorter than 8 characters are filled with
spaces up to the 8th character.
<size> displays the size of <Buffer>. For 16 axes, it can
be a maximum of 144 (9x16) bytes.
For an example, see section 5.13.3 page 5-96.

Number of feed axes, auxiliary Integer, Array MCODS(34,-1,<Version>,<Buffer>,<Size>)


axes, spindles;
movement types, drive types

R reserved. Instead, use MCODS(45...)


Actual axis-position Real, Array MCODS(35,-1,<Version>,<Buffer>,<Size>)
C Supplies in<Buffer> in increasing channel-independent
order of current position of allfeed- and auxiliary, which
were transmitted from the drivesper SERCOS-parameter
to the CNC:
in mm for linear axes
in degrees for rotary axes
Set actual value (e.g. G92) is not included in the values.

Actual spindle-speed Real, Array MCODS(36,-1,<Version>,<Buffer>,<Size>)


C Supplies in <Buffer> in increaing order (or S1, S2, S3
etc.) the spindle-actual speed number of all spindles
available in the system.
The potentiometer, the speed limitations (SMin, SMax)
and the limitations due to the gear range are included in
the calculation.
If a spindle does not exist , 0.0 is returned at the
corresponding position to <Buffer>.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
5-72 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Axis-program value (program Double, Array MCODS(37,-1,<Version>,<Buffer>,<Size>)
coordinate system)
C Supplies in increasing, channel-independent order the
workpiece-based command positions of the interpolator
for all feed axes in the systemto <Buffer>:
in mm for linear axes
in degrees for rotary axes
Set actual value (e.g. G92) and the axis- ZO (G54.x -
G59.x) is not included in the values.

Actual axis-values (machine Double, Array MCODS(38,-1,<Version>,<Buffer>,<Size>)


coordinate system)
C Supplies, in increasing, channel-independent order, the
actual values based on the corresponding (Cartesian)
machine coordinate system to <Buffer>.
The values are calculated from the actual axis-positions
by using the channel-by-channel machine-specific
kinematic forward transformation (axis transformation). If
no kinematic axis-transformation has been activated,
MCODS(38) supplies values identical to MCODS(35).
The prerequisite for applying MCODS(38) is a
corresponding setting of machine parameter 9030 00002,
which is used to configure whether and how often actual
values are calculated in the machine coordinate system.
Status Dwell time active integer MCODS(39,<Channel>,<Version>,<Buffer>,1)
E Supplies a value of 1 to <Buffer> if a dwell time has been
activated in <Channel>. Otherwise the value is 0.
Status Auxiliary function which integer MCODS(40,<Channel>,<Version>,<Buffer>,1)
requires acknowledgement
active

E Supplies a value of 1 to <Buffer> if an auxiliary function is


waiting for acknowledgement in <Channel>. Otherwise the
value is 0.

Status Reading release integer MCODS(41,<Channel>,<Version>,<Buffer>,1)


E Supplies a value of 1 to <Buffer> if NC input signal Block
transfer inhibit has been set for <Channel>. Otherwise
the value is 0.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-73
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Customer-specific data MCODS(42,<Channel>,<Version>,<Buffer>,<Size>,<P1>)
E Supplies customer-specific data from <Channel> to
<Buffer>.
In <P1>, an integer value in the range between 0 and
65535 can be transferred to the customers server in order
to select certain data when the function is called.
The function has been designed for customer-specific
developments in the area of the NC core.

Axis-channel assignment Integer, Array MCODS(43,-1,<Version>,<Buffer>,<Size>)


E Supplies the following information for every system -axis
to <Puffer>:
0: Channel number of the synchronous axis
-1: Axis is asynchronous
-2: Axis is a spindle
-3: Axis is not defined
Number of channels Integer, Array MCODS(44,-1,<Version>,<Buffer>,3)
R Supplies to <Buffer>, in increasing order,
D the number of usable user-channels
D the number of channels on the interface
D the number of internal and external channels
Number of axes Integer, Array MCODS(45,-1,<Version>,<Buffer>,3)
R Supplies to <Buffer>, in increasing order,
D The maximum index of the axes in the system.
This is required for grinding over all axes. If no gaps
are present, this is the number of drives in the system.
D The maximum index of the axes in the system.
This is required e.g. for the size of the axis interface. If
no gaps are present, this is the number of axes in the
system.
D The maximum number of spindles in the system.
This is required e.g. for the size of the spindle inter-
face.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
5-74 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Return-to-path strategy and Integer, Array MCODS(46,<Channel>,<Version>,<Buffer>0.3)
recording of jogging
movements

E Supplies to <Buffer> in increasing order for the given


<channel>
D the return-to-path operating mode
D the point of return-to-path
D the recording status of jog movements.

The following values are possible for the return-to-path


operating mode:
1 automatic return-to-path
2 return-to-path with individual block
3 manual return-to-path
For the point of return-to-path:
1 return-to-path at starting point
2 return-to-path at end point
3 return-to-path at point of interruption
For the recording status:
0 recording not active
1 recording active

Status Travel command Integer, Array MCODS(47,<Channel>,<Version>,<Buffer>,<Size>)


C In the case of <Channel> = -1, <Buffer> supplies the
travel command-signals of all system -axes in increasing
order.
In the case of <Channel> = the existing channel number,
<Buffer> supplies the travel command-signals of all the
axes in the given channel, followed by those of the
asynchronous axes in increasing order.
Travel command exists: 1
Travel command does not exist: 0
A travel command is always set as soon as an axis is to
execute a travel movement using manual entry or entry in
the parts program.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-75
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Axis operating mode Integer, Array MCODS(48,<Channel>,<Version>,<Buffer>,<Size>)
E In the case of <Channel> = -1, <Buffer> supplies the
operating modes of all system axes in increasing order.
In the case of <Channel> = the existing channel number,
<Buffer> supplies the operating modes of all the axes in
the given channel, followed by those of the
asynchronous axes in increasing order.
Possible return values for the operating modes:
0: No operating mode, and thus no process, is active.
1: Jog mode. The axes can be jogged (+/-).
2: Traverse to reference point. The axes can be started
using signals Manual+ / Manual-.
3: reserved.
4: Manual entry. Individual NC blocks can be entered for
processing.
5: Automatic (next block). Parts programs are processed
completely.
6: Automatic (program block). Individual blocks of a parts
program are processed sequentially. Each individual
block is prepared and started with NC-Start.
7: Automatic (single step). Under certain conditions, the
NC generates and prepares several blocks from an
individual NC block in the parts program.
In this operating mode, NC-Start is always used to
pass an individual block on to the interpolator for proc-
essing.
8: reserved.
9: reserved.
10:Automatic (single block). With NC-Start, all the blocks
that were generated and prepared due to an individual
NC block in the parts program are passed on to the
interpolator for processing.
11: Restart. The axes can be moved manually away from
the contour, as well as restarted automatically or
manually.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
5-76 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Status Feed inhibit Integer, Array MCODS(49,<Channel>,<Version>,<Buffer>,<Size>)
E In the case of <Channel> = -1, <Buffer> supplies the feed
inhibit signals of all system axes in increasing order.
In the case of <Channel> = the existing channel number,
<Buffer> supplies the feed inhibit signals of all theaxes in
the given channel, followed by those of the
asynchronous axes in increasing order.
1: Feed inhibit exists
0: Feed inhibit does not exist
Value of axis potentiometer Real, Array MCODS(50,<Channel>,<Version>,<Buffer>,<Size>)
E In the case of <Channel> = -1, <Buffer> supplies the
axis-potentiometer values of all system axes in increasing
order (in 0.01 Prozent).
In the case of <Channel> = the existing channel number,
<Buffer> supplies the channel potentiometer value for
every axis in the given channel, followed by the axis-
potentiometer values of all asynchronous axes in
increasing order (in 0.01 percent).
Active external tool correction Real, Array MCODS(51,<Channel>,<Version>,<Buffer>,<Size>)
values
S Supplies the external tool correction values that are active
in <Channel> to <Buffer>.
Order: radius correction, length correction
If external tool correction is not active, 0.0 is returned.
Active external axis ZO values Real, Array MCODS(52,<Channel>,<Version>,<Buffer>,<Size>)
S Supplies the external axis ZO values that are active in
<Channel> to <Buffer>.
Order: 1. log. axis, ... 8. log. axis
If no external offset is active, 0.0 is returned.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-77
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Axis units Integer, Array MCODS(53,<Channel>,<Version>,<Buffer>,<Size>)
E In the case of <Channel> = -1, <Buffer> supplies the
units (metric, inch, degree) of all system -axes in
increasing order.
In the case of <Channel> = the existing channel number,
<Buffer> supplies the unit for every axis in the given
channel, followed by the unit of all asynchronous
axes in increasing order.
In the case of asynchronous linear axes in the Jog and
Traverse to reference point axis operating modes, the
axis interface determines the unit. If no axis operating
mode is entered, metric is supplied.
In the case of synchronous linear axes in the Jog and
Traverse to reference point channel operating modes,
the axis interface determines the unit. In the other opera-
ting modes, it depends on the metric/inch channel unit
(G70/G71).
For rotary axes and spindles, the unit is degrees; for Hirth
axes with location programming, an appropriate unit is
supplied.
Possible return values for the units:
0: inch
1: metric
2: Degrees
3: axis does not exist
4: location-programmable Hirth axis
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
5-78 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Active universal tool correction Real, Array MCODS(54,<Channel>,<Version>,<Buffer>,<Size>)
S Supplies the universal tool correction values that are
active in <channel> to <Buffer>.
Sequence of events:
D Radius compensation
D L3 length compensation
D L1 length compensation
D L2 length compensation
D tool edge position
D Correction type
The following correction types have been defined:
0: no correction
1: drilling tool
2: milling tool
3: lathing tool
4: angle head tool
If no universal tool correction is active, 0.0 is returned.
Manufacturer version Character, MCODS(55,-1,<Version>,<Buffer>,<Size>,
Array <Axis number>)
R Outputs the manufacturer version of the drive. The axes
are selected in parameter <Axis number> by entering the
system -axis. (No. 0 also supplies the 1st axis). The
manufacturer version corresponds to SERCOS-parameter
S-0-0030. An array of max. 40 characters is supplied to
parameter <Buffer>.
Control type Character, MCODS(56,-1,<Version>,<Buffer>,<Size>,
Array <Axis number>)
R Outputs the control type of the drive. The axes are
selected in parameter <Axis number> by entering the
system -axis. (No. 0 also supplies the 1st axis). The
control type corresponds to SERCOS -parameter
S-0-0140. An array of max. 40 characters is supplied in
parameter <Buffer>.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-79
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Motor type Character, MCODS(57,-1,<Version>,<Buffer>,<Size>,
Array <Axis number>)
R Outputs the motor type of the drive. The axes are
selected in parameter <Axis number> by entering the
system -axis. (No. 0 also supplies the 1st axis). The motor
type corresponds to SERCOS-parameter S-0-0141. An
array of max. 40 characters is supplied in parameter
<Buffer>.
Axis-channel default integer MCODS(58,-1,<Version>,<Buffer>,<Size>)
assignment
R Supplies the following default assignment for every
system-axis to <Buffer>:
0: Channel number of the synchronous axis
-1: Axis is asynchronous
-2: Axis is a spindle
-3: Axis is not defined
16 axes, <Buffer> must have a <size> of 16 (integer).

Active channel axis name- Character, MCODS(59,<Channel>,<Version>,<Buffer>,<Size>)


Array
E In the case of <Channel> = -1, <Buffer> supplies the
names of all the active channel -axes, separated by the
character 0 (0-byte) in increasing order for 9 bytes each.
In case of <channel> = the existing channel number
<Buffer> supplies the names of all the axes in the given
channel, separated by the character 0 (0-byte) in
increasing order.
Names that are shorter than 8 characters are filled with
spaces up to the 8th character.
<size> displays the size of <Buffer>. For 16 axes, it can
be a maximum of 144 (9x16) bytes.
For an example, see section 5.13.3 page 5-96.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
5-80 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Channel axis name, default Character, MCODS(60,<Channel>,<Version>,<Buffer>,<Size>)
setting Array
R In the case of <channel> = -1 supplies<Buffer> the
names of allchannel-axes (in the default setting)
separated by the character 0 (0-byte) in increasing order
for 9 bytes each.
In case of <channel> = the existing channel number
<Buffer> supplies the names of all the axes in the given
channel, separated by the character 0 (0-byte) in
increasing order.
Names that are shorter than 8 characters are filled with
spaces up to the 8th character.
<size> displays the size of <Buffer>. For 16 axes, it can
be a maximum of 144 (9x16) bytes.
For an example, see section 5.13.3 page 5-96.
Axis units, default setting Integer, Array MCODS(61,<Channel>,<Version>,<Buffer>,<Size>)
R In the case of <Channel> = -1, <Buffer> supplies the
units (metric, inch, degree) of all the system-axes (in the
default setting), separated by the character 0 (0-byte) in
increasing order for 9 bytes each.
In case of <channel> = the existing channel number
<Buffer> supplies the names of all the axes in the given
channel, separated by the character 0 (0-byte) in
increasing order.
D For asynchronous linear axes, metric is supplied.
D For synchronous linear axes, the unit depends on the
power-up state after the machine is started (machine
parameter 7060 00010): Metric/Inch (G70/G71)
D For rotary axes and spindles, the unit is degrees; for
Hirth axes with location programming, an appropriate
unit is supplied.
Possible return values for the units:
0: inch
1: metric
2: degrees
3: axis does not exist
4: location-programmable Hirth axis
In the case of 16 axes, <Buffer> must have a <size> of 16
(integer)
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-81
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
ID number from cyclic axis Integer, Array MCODS(62,-1,<Version>,<Buffer>,
telegram <Size>,<ID number>)
C Supplies the value of an <ID number> from the cyclic axis
telegram for all axes.
If the <ID number> is not in the cyclic telegram, a value of
NCS_MCO_NOT_IN_CYCL_AT_C (-2147483648) is
output.
The value is Integer in SERCOS -scaling.

In the case of 16 axes, <Buffer> must have a <size> of 16


(integer)
Movement functions of the Integer, Array MCODS(63,-1,<Version>,<Buffer>,<Size>)
spindles
E Supplies the movement functions of all spindles.
Coding of the movement functions:
0: Spindle not defined
1: Clockwise movement without coolant
2: Clockwise movement with coolant
3: Counterclockwise movement without coolant
4: Counterclockwise movement with coolant
5: Spindle stop
6: Orientate spindle

In the case of 8 spindles, <Buffer> must have a <size> of


8 (integer)
Gear ranges of the spindles Integer, Array MCODS(64,-1,<Version>,<Buffer>,<Size>)
E Supplies the gear ranges of the spindles.
Coding of the gear ranges:
40:automatic gear range selection
41:gear range 1
42:gear range 2
43:gear range 3
44:gear range 4
48:Disengage gear range

In the case of 8 spindles, <Buffer> must have a <size> of


8 (integer)
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
5-82 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Automatic/manual gear range Integer, Array MCODS(66,-1,<Version>,<Buffer>,<Size>)
selection
E Supplies automatic or manual gear range selection:
0: manual
1: automatic
In the case of 8 spindles, <Buffer> must have a <size> of
8 (integer)

Information whether gear Integer, Array MCODS(67,-1,<Version>,<Buffer>,<Size>)


switching is active
E Supplies information whether gear switching is active:
0: Gear switching is not active
1: Gear switching is active
In the case of 8 spindles, <Buffer> must have a <size> of
8 (integer)

Skip block (activate) Integer, Array MCODS(68,<Channel>,<Version>,<Buffer>0.2)


E Supplies the status of NC- output signal Activate block
skip and of input signal Block skip of <Channel> to
<Buffer>.

Optional stop (activated) Integer, Array MCODS(69,<Channel>,<Version>,<Buffer>0.2)


E Supplies the status of NC-output signal Optional stop
activated and of input signal Optional stop of <Channel>
to <Buffer>.

Automatic program reselection integer MCODS(70,<Channel>,<Version>,<Buffer>,1)


active
I Supplies whether automatic program reselection is
applied in the given channel to <Buffer>>:
0: Function is not applied
1: Function is applied
Workpiece coordinates Real, Array MCODS(71,<Channel>,<Version>,<Buffer>,<Size>)
C Supplies the workpiece -coordinate (WCS) values of the
given channel to <Buffer>. First all the spatial coordinates,
then the pseudocoordinates of the channel.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-83
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Basic coordinate command Real, Array MCODS(72,<Channel>,<Version>,<Buffer>,<Size>)
values
C Supplies the basic coordinate command values (BCS) of
the given channel to <Buffer>. First all the spatial
coordinates, then the pseudocoordinates of the
channel.
Axis coordinates Real, Array MCODS(73,<Channel>,<Version>,<Buffer>,<Size>)
C Supplies the axis coordinate values (ACS) of the given
channel to <Buffer>.
Channel = -1: All axis coordinates
0< Channel Max. channel: Data of the given channel
Machine coordinates Real, Array MCODS(74,<Channel>,<Version>,<Buffer>,<Size>)
C Supplies the machine- coordinate (MCS) values of the
given channel to <Buffer>.
Channel = -1: All axis coordinates
0< Channel Max. channel: Data of the given channel
Basic coordinate actual values Real, Array MCODS(75,<Channel>,<Version>,<Buffer>,<Size>)
C Supplies the basic coordinate actual values



Programmed coordinate end Real, Array MCODS(76,<Channel>,<Version>,<Buffer>,<Size>)
points
S Supplies the programmed coordinate -end points of
the given channel to <Buffer>. First all the spatial
coordinates, then the pseudocoordinates of the channel.

Coordinate end points Real, Array MCODS(77,<Channel>,<Version>,<Buffer>,<Size>)


S Supplies the coordinate end points of the given channel,
including the offsets, to <Buffer>. First all the spatial
coordinates, then the pseudocoordinates of the
channel.
Coordinate name Character, MCODS(78,<Channel>,<Version>,<Buffer>,<Size>)
Array
E Supplies the name of the active coordinate of the given
channel to <Buffer>. First all the spatial coordinates, then
the pseudocoordinates of the channel.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
5-84 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
INPOS status coordinates Integer, Array MCODS(79,<Channel>,<Version>,<Buffer>,<Size>)
C Supplies the INPOS status of the coordinates of the
given channel to <Buffer>. First all the spatial coordinates,
then the pseudocoordinates of the channel.
The status from the AND link of the axis signals is
generated for a spatial coordinate .

Reference status of the Integer, Array MCODS(80,<Channel>,<Version>,<Buffer>,<Size>)


coordinate
E Supplies the reference point status of the coordinates
of the given channel to <Buffer>. First all the spatial
coordinates, then the pseudocoordinates of the channel.
The status from the AND link of the axis signals is
generated for a spatial coordinate .

Unit of the coordinates Integer, Array MCODS(81,<Channel>,<Version>,<Buffer>,<Size>)


E Supplies the units of the coordinates of the given
channel to <Buffer>. First all the spatial coordinates, then
the pseudocoordinates of the channel.
Possible return values for the units:
0: inch
1: metric
2: degrees
3: coordinate does not exist
Number of coordinates Integer, Array MCODS(82,<Channel>,<Version>,<Buffer>,<Size>)
E Supplies the number of coordinates/axes of the given
channel in 3 elements to <Buffer>.
1. value: the total number of axes in the channel
2. value: the number of spatial coordinates + the number
of
pseudocoordinates in the channel.
3. value: the number of pseudocoordinates in the
channel.
Distance to go of workpiece Real, Array MCODS(83,<Channel>,<Version>,<Buffer>,<Size>)
coordinates
C Supplies the distance to go of the workpiece
coordinates (WCS) of the given channel to <Buffer>.
First all the spatial coordinates, then the
pseudocoordinates of the channel.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-85
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Channel wait states integer MCODS(87,<Channel>,<Version>,<Buffer>,1)
E Supplies the wait states of a Channel to <Buffer>.
This function indicates the reasons why a channel enters
a wait state.
The active wait states are bit-coded.
The following constants define the corresponding bits of
the first integer value, starting with the lowest value:
0: dwell time
1: auxiliary function requiring acknowledgement
2: block transfer inhibit
3: feed in channel = 0
4: program stop with M0, M1
5: feed hold in channel
6: feed inhibit in channel or a channel axis
7: block transfer inhibit preset by the customer
8: synchronized movement stop between
channels (ASTOP, ...)
9: wait for axis during axis exchange (G511)
10: wait for permanent variable (WPV)
11: wait for interface signal at active time
(WAITA, ...)
12: wait for interface signal (WAIT(BITIF...)) or
a specified period (WAIT(,ZEIT%)) in
block preparation
13: Motion Control data service (MCODS(...))
See example in 5.13.3

Online correction values (WCS) Real, Array MCODS(89, <Channel>, <Version>, <Buffer>, <Size>)
E Supplies the values of the online correction (WCS) of the
given channel to <Buffer>. First all the spatial coordinates,
then the pseudocoordinates of the channel.

Status of online correction Integer, Array MCODS(90,, <Channel>, <Version>, <Buffer>, <Size>)
(WCS)
E Supplies the current status of the online correction (WCS)
of the given channel to <Buffer>. First all the spatial
coordinates, then the pseudocoordinates of the channel.
0: inactive
1: active
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
5-86 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Function supplies / <Buffer> is of Syntax /


Refresh1) type 2) description
Diameter programming Integer, Array MCODS(91,, <Channel>, <Version>, <Buffer>, <Size>)
S Supplies a value of 1 for axes with diameter programming
to <Buffer>.
If the value Ncs_MCoNoChannel_C (-1) is provided for
the channel, the values of all the system axes are
supplied.
If a channel number is provided, the values for the
channel axes are supplied.

Basic coordinates of the tool tip Real, Array MCODS(92,, <Channel>, <Version>, <Buffer>, <Size>)
(BCS-Tcp)
C If 3D-radius compensation is active, this supplies the
command values of the tool tip in the basic coordinate
system (BCS -Tcp) to <Buffer>, first the spatial
coordinates, then the pseudocoordinates of the given
channel.
If 3D radius compensation is switched off, the values are
identical with MCODS(72,...).

Group numbers of auxiliary Character, MCODS(94, <Channel>, <Version>, <GroupId>,


functions Array <Size>,<Syntax>)
C Supplies the auxiliary function group numbers to the
auxiliary function given in <Syntax> of the given channel
to <GroupId>.
<Syntax> contains the auxiliary functions, separated by
spaces and terminated with CHR$(0); see the example on
page 5-87.
Active syntax of auxiliary Character, MCODS(95, <Channel>, <Version>, <Syntax>,
function groups Array <Size>,<GroupId>)
C Supplies the active syntax to the auxiliary function group
number given in <GroupId> of the given channel to
<Syntax>.
An array (terminated with CHR$(0)) of the desired
-auxiliary function group numbers is transferred using
<GroupId>; see the example below.
1) Data that the control provides cyclically are marked by a Z.
Data that are available after every block change are marked by an S.
Data that are supplied in irregular intervals after a change are marked by an E.
Data that are supplied immediately after the request are marked by an I.
Data that never change (they must be requested only once) are marked by an R.

2) Indicates the variable type (integer, real, double, character) required for <Buffer>.
If a simple variable is not required, but rather a field variable, Array is written behind the variable type.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-87
and Controls

System Data

Example for auxiliary functions:


:
N10 M3 S1234 T5678
WAIT
10 DIM GROUPID$(64)
15 DIM SYNTAX$(256)
17 VERSION=0
18 CHAN%=1
20 REM Find the group numbers of M3 and T
25 SYNTAX$=T M3+CHR$(0)
30 ERR_VAR%=MCODS(94,CHAN%,VERSION,GROUPID$,64,SYNTAX$)
31 PRN#(0,94 Error:,ERR_VAR%)
32 PRN#(0,T M3:,ASC(MID$(GROUPID$,1,1)),
ASC(MID$(GROUPID$,2,1)))
33 REM Read groups 2 and 1
36 GROUPID$=CHR$(2)+CHR$(1)+CHR$(0) :
37 REM Query groups 2 and 1
50 VERSION=0
58 CHAN%=1
60 ERR_VAR%=MCODS(95,CHAN%,VERSION,SYNTAX$,256,GROUPID$)
65 PRN#(0,95 Error:,ERR_VAR%)
70 PRN#(0,Group 2 1 : , SYNTAX$)
71 REM SYNTAX$ contains e.g. S1234 M3
5-88 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

MCOPS
Calls Motion Control process services of the NCS via CPL. This allows
channels in the CNC to be controlled.

General syntax:
MCOPS(<Fct>,<Channel>[[,[<P1>][,[<P2>],[<P3>]]],<P4>
])
<Fct> Integer expression. This indicates the function to be
executed. The following table lists all the available
functions.
<Channel> Integer expression. Indicates the channel which the
function is to affect.
<P1> - <P1> Optional parameters that depend on <Fct>. Sequen-
ces of commas are permitted; however, a comma be-
fore a close-parentheses sign is not.

. In the following table, integer constants are sometimes shown as


parameters for the syntax. In place of these constants, you can
also program integer variables; however, these must have been
assigned the given value at the time that the function is called.

Effect Syntax/Description
Cancel distance to go MCOPS(1,<Channel>)
Initiates Cancel distance to go in the programmed <Channel>:
D Having initiated Cancel distance to go, all prepared NC blocks,
including the remainder of the current block, are cancelled and
prepared again.

. CPL-blocks or CPL-parts are not taken into consideration:


Example: CPL variable POS was given value 10 in preparation; the
X[POS] NC word is interpreted as X10 following Cancel distance to
go even though POS may have a totally different value at that time.
Any compensation values that may have been changed are taken
into account.

D In the display, the indicated end point is set to the current position,
simultaneously deleting the indicated distance to go. The <Channel>
then changes to the NC ready state (iCh_NCReady PLC input signal)
D Following the NC start (PLC output signal qCh_NCStart), the program
is continued at the point of interruption, taking into account the new
compensation values.
Example for using MCOPS(1,<Channel>): after the correction tables
have been changed if the new values are also to apply to the previously
prepared blocks.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-89
and Controls

System Data

Effect Syntax/Description
control reset MCOPS(2,<Channel>[,<Control reset-type>])
Initiates Control reset in the programmed <Channel>.
To initiate an overall control reset: <Channel> = -2

D The channel temporarily does not accept any more orders, such as
program selection or operating mode switching.
D The interpolator is stopped.
D Orders to the channel that have not yet been processed are
cancelled.
D The main program is deselected.
D Modified machine parameters that do not require that the machine be
started are accepted, e.g. machine parameter 1020 00001 (software
limit switch).
D Error and warnings that this channel initiated are deleted.
D The interpolator is restarted.
D The startup status for the control reset (machine parameter 7060
00020) is accepted, i.e. the corresponding modal states become
active.
D The channel issues interface signal 0.2 Control reset executed and
is again ready for new orders.
D <Control reset-type>: Integer-expression. Specifies the behavior of
the function.
The following list contains all the defined behavioral patterns. Each
pattern is preceded by an ID. To set a certain behavior, the
corresponding ID must be provided in <Control reset -type>. If
several behavioral patterns are to be combined, the sum of all the
corresponding IDs in <Control reset-type> must be transferred to the
function. Until now, the list has had only one element:
ID:
2: Automatic program reselection is suppressed
if it is active.
Example: ERR_VAR=MCOPS(2,2,2)
Control reset in 2nd channel without automatic
program reselection
5-90 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Effect Syntax/Description
Search block MCOPS(3,<Channel>[,[<Starting block>][,<End block>]])
Initiates Search block in the selected, but not yet started, main program
of the programmed <Channel>:

D <Starting block> and <End block> are transferred as string


expressions. The following conventions apply in the search for the
<Starting block> and <End block>:
D Space, <tab>, <LF> at the start of an NC block are ignored.
D If the <Starting block> or <End block> starts with a numeral and if
the expression is not found in the searched program, the system
restarts its search for the expression, but this time with a
preceding N character.
In this way, for example, a search term of 50 also finds NC block
N50X100.
D If the <Starting block> or <End block> ends with a numeral, the
expression in the searched program is found only if a numeral
does not occur immediately after it.
For example, G1X10 does not find NC-block G1X100.
D If the <Starting block> or <End block> ends with a letter, the
expression in the searched program is found only if a space
occurs immediately after it.
For example, 50A finds-NC block 50A =1, but not 50A=1.
D Processing starts with the <Starting block> and ends with the <End
block>.
If the <Starting block> is missing or if the block is not found,
processing starts at the start of the program. If the <End block> is
missing or if the block is not found, processing stops at the end of the
program.
D The NC status changes to READY.
Example: ERR_VAR=MCOPS(3,2,N50,N100)
Initiates Search block in channel 2. The main program is to be
processed starting at N50 until and including N100.
Select the program or MCOPS(4,<Channel>[[,[<String>][,[<Starting block>],[<Ending
the string for manual entry block>]]],<Selection type>])
In the programmed <Channel>, this selects a program for processing or
a string for processing using the manual data input operating mode.
Presets for asynchronous subroutines are possible if <Selection type> =
32768. They can be logged in, switched off, restarted, deleted and star-
ted.

D <String>: String expression. Depending on the <Selection type>, the


system interprets the parameter as
D the path name (incl. parts program name) of a parts program to be
selected (max. 100 characters), or
D if 32 is provided in <Selection type>: as an NC block (size max.
512 bytes incl. the terminating 0 byte) that is to be processed
using the manual data input operating mode, or
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-91
and Controls

System Data

Effect Syntax/Description
D if 32+4096 is provided in <Selection type>: as several NC blocks
that are to be processed using the manual data input operating
mode.
Several NC-blocks are separated by NewLine (\n, Hex 0x0A).
The max. size of all NC blocks must not exceed 4096 bytes,
including the terminating 0 byte.
D if 32768 is provided in <Selection type>: the name or path name is
provided for job SETINT for asynchronous subroutines.

D The <Starting block> and <End block> specify the starting - and end
blocks in the parts program for processing. This is treated like
MCOPS(3,..).
If the system interprets <String> as manual data input, the <Starting
block> and <End block> are ignored.
For specifications for asynchronous subroutines (<Selection type>=
32768), the number (1 number 8) is provided as a string (e.g. 1)
in <Starting block> and the job is provided in <End block>.
Jobs for asynchronous subroutines are:
SETINT log on
DISABLE switch off
ENABLE switch back on
CLRINT delete
START start

D <Selection type>: Integer-expression. Specifies the behavior of the


function. The following list contains all the defined behavioral
patterns. Each pattern is preceded by an ID.
If a certain behavior is to be set, this ID must be provided in
<Selection type>.
If several behavioral patterns are to be combined, the sum of all the
corresponding IDs in <Selection type> must be transferred to the
function.

. If <Selection type> 2 (Wait until the NC status switches to RE-


ADY) is entered and the program to be selected does not exist
or cannot be executed, error message 6 is returned. In all other
cases, no check is made whether the program can be executed.
The function supplies 0 (no error has occurred).
Only the following linking generates a corresponding runtime
error.
5-92 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Effect Syntax/Description
1 During the selection, the system carries out a link run. If one
does not already exist, a link table is generated for the
selected main program. Link tables are required if subroutine
calls or CPL instructions exist in the program.
2 The system acknowledges the validity of a selection only
after the NC status switches to READY.
Normally, the selection is acknowledged without waiting for
NC status READY.
32 The system interprets <String> as a manual data input
block. Also see ID 128.
64 Before the function selects the given program or manual
data input block, an active program or manual data input
block is deselected.
128 A manual data input block is started immediately. There are
2 cases:
<Channel> is not active: The block is processed immediately
as a normal manual data input block.
<Channel> is already active: The block is processed
immediately as a switching function. For limitations, see ID
1024.
256 Prerequisite to move axes in Jog operating mode
or
if movements are to occur in the Jog in workpiece coordi-
nates operating mode.
512 Prerequisite to start axes in Traverse to reference point
operating mode.
1024 Switch function. Works together with ID 128.
A manual data input block is processed at the same time as
the given <Channel>. However, only auxiliary functions and
asynchronous axis movements are permitted in the manual
data input block.
2048 A program that is already active is replaced by the newly
selected one. As a result, all modal states are maintained.
In manual data input, the old character sequence is replaced
by the new one.
4096 Entering buffered NC-blocks acts in connection with code
number 32. While preceding blocks are being executed, oth-
ers can already be specified.
32768 Asynchronous subroutines can be controlled using this flag
(see <Starting block> and <End block>).
Examples:
ERR_VAR=MCOPS(4,1,sekt.cnc,N50,N100,1)
Program selection of sekt.cnc in channel 1, incl. block search and
linking.

ERR_VAR=MCOPS(4,1,/usr/user/p1.cnc)
Program selection of p1.cnc in channel 1, without block search and
linking.

ERR_VAR=MCOPS(4,1,F1000G1X500,,,32)
Selects block F1000G1X500 in channel 1 using manual data input.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-93
and Controls

System Data

Effect Syntax/Description
Program deselection MCOPS(5,<Channel>,<Deselection-Type>)
Deselects a selected program or manual data input block in the
programmed<Channel> .

D <Deselection-Type>: Integer-expression. Specifies the behavior of the


function.
The following list contains all the defined behavioral patterns. Each
pattern is preceded by an ID. To set a certain behavior, the
corresponding ID must be provided in <Deselection -type>. If several
behavioral patterns are to be combined, the sum of all the
corresponding IDs in <Deselection-type> must be transferred. Until
now, the list has had only one ID:
2: If automatic program reselection is active, it can be sup-
pressed with a value of 2 in this program deselection.

Example:
ERR_VAR=MCOPS(5,2,2) Program deselection in channel 2 without
automatic program reselection.

Start program MCOPS(6,<Channel>)


Starts a selected program or manual data input block in the programmed
<Channel>.
5-94 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Effect Syntax/Description
Assign operating mode MCOPS(7,<Channel>,<Operating mode>)
Assigns an operating mode in the programmed <Channel>.

D <Operating mode>: Integer-expression. Specifies the operating mode


that is to be started.
1 Jog mode. The axes can be jogged (+/-).
Also see MCOPS(4..) under <Selection type>: ID 256.
2 Traverse to reference point. The axes can be started using
signals Manual+ / Manual-.
Also see MCOPS(4..) under <Selection type>: ID 512.
4 Manual entry. Individual NC-blocks can be entered for proc-
essing.
5 Automatic (next block). Parts programs are processed com-
pletely.
6 Automatic (program block). Individual blocks of a parts pro-
gram are processed sequentially. Each individual block is
prepared and started with NC-Start.
7 Automatic (single step). Under certain conditions, the NC
generates and prepares several blocks from an individual
NC-block in the parts program.
In this operating mode, NC-Start is always used to pass an
individual block on to the interpolator for processing.
10 Automatic (single block). With NC-Start, all the blocks that
were generated and prepared due to an individual NC block
in the parts program are passed on to the interpolator for
processing.
11 Restart. The axes can be moved manually away from the
contour, as well as restarted automatically or manually.
12 CPL-debugger: Individual blocks located in the parts pro-
gram are processed.
13 CPL-debugger: All the blocks up to the next break point are
processed.
14 Jog mode: movement in workpiece coordinates

The operating mode can be changed only under the following conditions:
D Channel-interface-signal qCh_OpModePlc (PLC operating mode) may
not be set
D No program or block is selected for the NC
- or -
Switching is to be carried out solely between automatic operating
modes Next block, Program block, Single step or Single block.

Example:
ERR_VAR=MCOPS(7,2,5)
Operating mode change in the 2nd channel to Automatic (Next block).
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-95
and Controls

System Data

Effect Syntax/Description
Change return-to-path strategy MCOPS(8,<Channel>,<How>,<Where>)
Specifies the return-to-path strategy in the programmed <Channel>.

D <How>: Integer-expression. Indicates whether


1 automatic return-to-path
2 return-to-path with individual block, or
3 manual return-to-path is desired.
D <Where> : Integer-expression. Indicates whether
1 the starting point
2 the end point, or
3 the interruption point is to be approached for the return to
path.

Terminate return-to-path recording MCOPS(9,<Channel>)


Terminates return-to-path recording in the programmed <Channel>. Jog
movements are thus no longer recorded.
5-96 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

5.13.3 Programming examples

Example 1: Immediately request the SAV and interpolator status from


channel 2
10 DIM BUF%(2) Create field
20 VERSION=0 Supply data immediately
30 ERR_VAR%=MCODS(32,2,VERSION, Function call
BUF%,2)

BUF%(1) contains the SAV status, BUF%(2) the IPO status.


VERSION contains the current version number of the data
(important for example 2).

Example 2: Wait until the SAV status of channel 2 switches to Inactive


<Code of example 1>
:
10 INAKTIVE = 1
20 WHILE BUF%(1) <> INAKTIV DO
30 ERR_VAR% = MCODS(32,2,VERSION,BUF%,2)
40 END

After it is called, the function returns to the calling program only after the
SAV status changes (VERSION still contains a value not equal to 0; for
the version number, see example 1). The loop is exited only after
BUF%(1) receives a value of 1.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-97
and Controls

System Data

Example 3: Outputting the axis name in the MSG window


:
30 VERSION=0
40 DIM AXNAME$(512)
50 REM Request all axis names
60 ERR=MCODS(33,-1,VERSION,AXNAME$,512)
70 IF ERR=0 THEN
80 REM Determine number of axes
90 DIM AXNMB%(3)
100 VERSION=0
110 ERR=MCODS(45,-1,VERSION,AXNMB%,3)
120 ANZ=AXNMB%(2)
130 ENDIF
140 IF ERR<>0 THEN
150 PRN#(0,Error occurred: ,ERR)
160 ELSE
170 REM Display axis name
180 FOR I%=0 TO (ANZ-1)
190 NAME$=MID$(AXNAME$,I%*9+1,8)
200 IF ASC(NAME$)<>0 THEN
210 REM Axis name is defined
220 PRN#(0,I%+1,. Axis name: ,NAME$)
230 ENDIF
240 NEXT
250 ENDIF
N260 M30
5-98 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Example 4: Channel / wait state

10 CHAN%=1
20 VERSION%=0
30 STATES%=0
40 ERR=MCODS(87,CHAN%,VERSION%,STATES%,1)
50 IF ERR=0 THEN
60 MASK%=1
70 WHILE MASK% <= STATES% DO
80 CASE (STATES% AND MASK%) OF
90 LABEL 1:PRN#(0,Dwell time)
100 LABEL 2:PRN#(0,Auxiliary function requiring acknowledgement)
110 LABEL 4:PRN#(0,Block transfer inhibit)
120 LABEL 8:PRN#(0,Feed in channel equals 0)
130 LABEL 16:PRN#(0,Program stop with M0/M1)
140 LABEL 32:PRN#(0,Feed stop in channel)
150 LABEL 64:PRN#(0,Feed inhibit in channel or a channel axis)
160 LABEL 128:PRN#(0,Block transfer inhibit assigned by customer)
170 LABEL 256:PRN#(0,Synchronized movement stop
between channels (ASTOP, ...))
180 LABEL 512:PRN#(0,Wait for axis in axis exchange (G511))
190 LABEL 1024:PRN#(0,Wait for permanent variable (WPV))
200 LABEL 2048:PRN#(0,Wait for interface signal at
active time (WAITA, ...))
210 LABEL 4096:PRN#(0,Wait for If signal (WAIT(BITIF(...))) or)
220 PRN#(0, (WAIT(,ZEIT%)) in block preparation)
230 LABEL 8192:PRN#(0,Motion Control data service (MCODS(...)))
240 ENDCASE
250 MASK%=MASK%*2
260 END
270 ENDIF
M30
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-99
and Controls

System Data

Example 5: Axis-channel assignment

10 REM The program queries the number of axes in the


system
15 REM and the axis numbers of the channel axes. Using
this
20 REM information, the channel axes are first traver-
sed to
30 REM position 0 and then to the <Channel number> 40
REM position.
50 CHAN%=SD(8) : REM Separate channel number
60 IDCHAX%=43 : REM Function type for axis-channel
assignment
70 IDMAXAX%=45 : REM Function type for axis number
80 DIM BUF%(16): REM Buffer for axis-channel assignment
90 SIZE%=16
100 ANZ%=0 : REM Maximum index of system- axes
120 REM Determine channel axes of active channel
130 VERSION=0
140 ERR=MCODS(IDCHAX%,CHAN%,VERSION,BUF%,SIZE%)
150 IF ERR=0 THEN
160 VERSION=0
170 ERR=MCODS(IDMAXAX%,CHAN%,VERSION,ANZ%,1)
180 IF ERR=0 THEN
190 FOR I%=1 TO ANZ%
200 IF BUF%(I%) = CHAN% THEN
N210 F1000 [AXP(I%,0,0)]; Traverse channel axes
; to 0
220 ENDIF
230 NEXT
240 FOR I%=1 TO ANZ%
250 IF BUF%(I%) = CHAN% THEN
N260 M0
N270 WAIT
N280 F1000 [AXP(I%,CHAN%,0)]; Traverse channel
; axes to CHAN%
290 ENDIF
300 NEXT
310 ENDIF
330 ENDIF
N310 M30
5-100 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

System Data

Notes:
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-101
and Controls

Character String Processing

5.14 Character String Processing


In order to process character strings in the CPL, they must be filed in a
one-dimensional field (array) of identified character variables. Each
character-variable in this field is addressed via an index and may con-
tain exactly 1 character.

CPL instructions MID$, LEN, INSTR, ASC, STR$, VAL and TRIM$ are
available for string processing.

5.14.1 Dimensioning character fields

DIM
In order to create a character field, you must index a character variable
using a DIM instruction.
In this way, character fields with a max. capacity of 1024 characters can
be created (value range of the index: 1 to 1024).

If the value range is not adhered to, the error message INVALID FIELD
LIMIT appears.

Example:
1 DIM VWX$(14)

In this example, character field VWX$, consisting of 14 individual charac-


ter variables, is created. Strings with up to 14 characters in length can
therefore be stored in VWX$.

Examples:
1 DIM ABC$(1) Character field for a string with a max. length of 1 cha-
racter.
2 DIM BCDE$(10) Character field for a string with a max. length of
10 characters.
5-102 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Character String Processing

5.14.2 Read a character in a character string

MID$
This function removes parts from a string expression.
The result can be transferred to a dimensioned or to a non-dimensioned
character variable:
D A dimensioned character variable receives the complete partial
string defined in the MID$ command.
D A non-dimensioned character variable receives only the beginning
address and length of the defined partial string. If the string-expres-
sion from which the partial-string was taken changes, then the non-
dimensioned character variable changes correspondingly.

If chaining (e.g. MID$(A$+B$,2,3) ) occurs within the MID command,


the result can be assigned only to a character field.

MID$(<STR expression>,<Starting point>[,<Number of charac-


ters>])
<STR-expression> String-expression from which parts are to be re-
moved.
<Starting point> Determines the position within the <STRING ex-
pression> character field from which the charac-
ters are to be removed.
<Number of characters> Determines the number of characters to be
removed. If <Number of characters> is not pro-
grammed, all characters up to the end of the char-
acter field length will be removed.

The range of values for the 2nd and 3rd parameters encompasses inte-
ger-values from 1 to 1024. If the range of values is not adhered to, the
fault message Invalid parameter is returned.

NUL is returned if a character field portion which has not yet been assi-
gned is accessed.

Example:
1 DIM A$(10)
2 DIM B$(5)
3 A$=ABCDEFGHIJ
4 B$=MID$(A$,2,5)
5 C$=MID$(A$,2,5)
6 REM Variables B$ and C$ both
have the content: BCDEF
7 A$=QRSTUVWXYZ
8 REM Variable B$ has the content: BCDEF
The variable C$ has the content: RSTUV
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-103
and Controls

Character String Processing

5.14.3 Modifying character strings

MID$
The MID$-instruction overwrites parts of a character field.

MID$(<Character field>,<Starting point>[,<Character number>])


<Character field> Character field in which parts are to be overwritten.
<Starting point> Determines from which position in the


  > the charac-
ters are to be overwritten.
The <Starting point> value may exceed the num-
ber of previously assigned components (length) by
a maximum of 1.
<Number of characters> Determines the number of characters which
are overwritten. If <Number of characters> is not
programmed, all assigned characters are entered
in <Character field> in so far as the dimensioning
of the character field allows.

The range of values for the 2nd and 3rd parameters is between 1 to
1024. If the range of values is not adhered to, the fault message INVA-
LID PARAMETER appears.

Example:
1 DIM A$(10)
2 A$=ABC Length of A$ is 3.
3 MID$(A$,4,3)=DEF

The 4th to 6th components of the character field are written. This is per-
missible because the first three components have already been assi-
gned.

Example:
1 DIM A$(10)
2 A$=ABC Length of A$ is 3.
3 MID$(A$,5,3)=DEF

An attempt is made to write the 5th to 7th components of the character


field. This, however, results in the error message CHARACTER FIELD
NOT ASSIGNED, because the 4th component has not yet been assi-
gned.

If more characters are assigned than permitted by the maximum cha-


racter field length, these characters will be discarded.
5-104 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Character String Processing

5.14.4 Character string length

LEN
LEN(<STRING expression>)
Returns the number of characters in a <STRING expression>. The re-
sult is an INTEGER-value.
If the <STRING expression> is empty, LEN returns a value of 0.
If the <STRING expression> is not defined, LEN returns a value of -1.

Example:
1 DIM XYZ$(10)
2 XYZ$=ABC
3 I%=LEN(XYZ$) INTEGER variable I% has a value of 3
4 XYZ$=
5 J%=LEN(XYZ$) INTEGER variable J% has a value of 0
6 XYZ$=NUL
7 K%=LEN(XYZ$) INTEGER variable K% has a value of -1

5.14.5 Searching for a character string

INSTR
INSTR(<Character string>,<String expression>[,<Starting
point>])
Beginning at the <Starting point>, INSTR searches for a <character
string> within a <string expression> and outputs the position of the first
character of the <character string> found in the <string expression> as
an INTEGER value.
A value of 0 is returned if the <character string> is not found.
The <character string> can be programmed as a STRING expression.

The range of values for the 3rd parameter is between 1 to 1024. The
following error message appears if the range of values is not adhered
to:
INVALID PARAMETER.

Example:
1 DIM A$(8)
2 DIM B$(16)
3 A$=A : MID$(A$,2)=UVWXYZ
4 B$=ABCDEF UVWXYZ GH
5 POS1%=INSTR(MID$(A$,2),B$,4) INTEGER variable POS1%
has a value of 8
6 POS2%=INSTR(MID$(A$,2,4),B$,10) INTEGER variable POS2%
has a value of 0
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-105
and Controls

Character String Processing

7 POS3%=INSTR(MID$(A$,2),B$) INTEGER variable POS3%


has a value of 8

5.14.6 Character strings and numbers

ASC
ASC(<Character string>)
Outputs the ordinal number of the first character (ASCII code) of <Cha-
racter string> as an INTEGER value.
If <Character string> is empty or not defined, ASC returns a value of -1.

<Character string> must be a STRING expression.


ASC is the reversal of CHR$.

Example:
10 DIM A$(1)
20 A$ = ABC
30 B$ = BCD
40 I% = ASC(A$) INTEGER variable I% has a value of 65
50 J% = ASC(B$) INTEGER variable J% has a value of 66
60 A$ =
70 K% = ASC(A$) INTEGER variable K% has a value of -1
80 A$ = NUL
90 L% = ASC(A$) INTEGER variable L% has a value of -1

CHR$
CHR$ is the reversal of ASC.

CHR$(<Integer expression>)
Converts an <integer expression> into the corresponding ASCII cha-
racter.
All ASCII character decimal priorities appear in the ASCII character
set table in the Appendix of this manual.

Example:
10 DIM A$(1)
20 I% = 65
40 A$ = CHR$(I%) STRING variable A$ has a value of 65
5-106 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Character String Processing

STR$
STR$([<Format string>,]<Value>)
Converts numeric expression <Value> into a character string that can
be assigned to only one character field. Assignment to a STRING-varia-
ble leads to a runtime error.

<Value> may be an INTEGER or REAL expression of single or double


precision.
If <Format string> is programmed, the string can be output in formatted
form. The symbol # indicates digits and . indicates decimal points.
Output occurs in standard format if a <Format string> entry is not made.

Standard formats:
INTEGER-number: 9 digits
Single-precision REAL number:4 digits before and 3 after the decimal
point.
Double-precision REAL number: 9 digits before and 6 after the deci-
mal point.

Example:
10 DIM A$(50)
20 DIM B$(21)
30 A$=STR$(Num- Content of character field A$:
ber=##.###,(37/3) Number = 12.333
40 B$=STR$(2.5) Content of character field B$:
2.500
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-107
and Controls

Character String Processing

VAL
VAL(<STRING expression>)
Returns the numerical value for a <STRING expression>. If the string
contains a character other than a leading space, the leading + or -
sign, the numbers 0 to 9 or the decimal point ., the conversion will be
performed up to this (other) character. Leading spaces and zeros are
ignored for purposes of value formation. If none of the characters above
appear, then NUL is returned. If the string contains a decimal point, the
result may only be assigned to a REAL or double-precision REAL-varia-
ble. Assignment to an INTEGER-variable in this case would lead to an
INVALID ASSIGNMENT error message.

Example:
1 I% = VAL(1.23DE)
2 K% = VAL(123DE)
3 J% = VAL(ABC)
4 R = VAL(-1.23DE)
5 Z = VAL(+ 000001234TEST4365)
6 X = VAL(ABC1.23DE)
7 D! = VAL(1234567.234567)

Line 1 leads to an error message because an assignment to an INTE-


GER-variable is to take place.

The value of the INTEGER variable K% is 123. The numbers 1,2,3 are
converted to an INTEGER number. The D character aborts the conver-
sion because it cannot belong to an INTEGER number. The characters
which follow it are ignored.

The value of INTEGER variable J% is NUL, i.e. the variable is not assi-
gned. The A character aborts the processing of the <STRING expres-
sion>.

The value of the REAL variable R is -1.23. The - character is recogni-


zed as a positive/negative sign for the REAL number. The digit 1, the .
character and the digits 2 and 3 are converted to a REAL number. The
D character aborts the conversion because it cannot belong to a REAL
number. The E character is not processed further.

The value of the REAL variable Z is 1234. The + character is recogni-


zed as a positive/negative sign for the REAL number. The spaces which
follow as well as the leading zeros are ignored for purposes of value for-
mation. The digits 1, 2, 3 and 4 are converted to a REAL number.
The T character aborts the conversion because it cannot belong to a
REAL number. The remaining characters are not processed further.

The REAL variable X is NUL, i.e. not assigned. The conversion is abor-
ted when the character A is recognized.

The value of the double-precision REAL variable D! is


1234567.234567.
5-108 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Character String Processing

5.14.7 Removing leading and trailing spaces

TRIM$
TRIM$(<Character string>)

TRIM$(<Character string>,L)

TRIM$(<Character string>,R)
When a character field range is assigned to a STRING variable or cha-
racter field, TRIM$() returns a string without preceding ( index L) or
trailing ( index R) spaces.
The TRIM function without index hides both preceding and concluding
spaces.
If chaining occurs within the TRIM command (e.g. TRIM$(A$+B$)), the
result may be assigned only to a character field.

Example:
1 A$ = ABCDEF
2 B$ = TRIM$(A$,L)
3 C$ = TRIM$(A$,R)
4 D$ = TRIM$(A$)
5 PRN#(1,>,A$,<)
6 PRN#(1,>,B$,<)
7 PRN#(1,>,C$,<)
8 PRN#(1,>,D$,<)

Leads to the following lines in the file with the logical number 1 opened for
write access:
> ABCDEF <
>ABCDEF <
> ABCDEF<
>ABCDEF<
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-109
and Controls

Character String Processing

5.14.8 Programming examples


A STRING-expression can be assigned to a STRING-variable.

Example:
Programming STRING variables (without prior dimensioning)
1 A$=ABCDE
2 B$=CHR$(10)

During read access, parts of the STRING variables can be accessed by


means of the MID$ command:
1 A$=ABCDEFGHIJKLMN
2 B$=MID$(A$,2,1)
3 C$=MID$(A$,4,4)

The following lines of programming will lead to errors:


4 MID$(A$,1,4)=ABCD
4 A$=MID$(A$,1,3) + MID$(A$,4,1)
4 A$=B$ + A$

To continue processing a dimensioned character field, it is necessary to


specifically access one or more connected characters. Only then will it
be possible to assign a character field or a part of the character field to a
STRING variable or to another character field.

Read and write access to a part of a character field is performed with the
MID$ command. If only the character field name is entered, the entire
character field will be addressed.

Reading a character field


If the <n>th character of the character field is to be accessed, proceed
as follows (n is less than or equal to the length of the character field and
the number of characters in the field):
Example: Reading a character field
1 DIM VWX$(13)
2 VWX$=TEST TEST TES
3 A$ = MID$(VWX$,12,1)
4 I%=12
5 A$=MID$(VWX$,I%,1)
The 12th character (E) of the VWX$ character field is assigned to the A$
string variable.

Writing a character field


If the content of a STRING variable is to be assigned to the character
field or a part of the character field, the assignment must be converted.
Example: Partial writing of the character field
1 DIM XYZ$(15)
2 B$=ABCDE
3 MID$(XYZ$,1,5)=B$
4 MID$(XYZ$,6,5)=B$
The 1st through 10th characters of the XYZ$ character field are assigned
the content of the B$ STRING variable.
5-110 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Character String Processing

The following programming would lead to the error message CHARAC-


TER AREA NOT USED because the 1st to 5th characters of the charac-
ter field are not yet assigned:
1 DIM XYZ$(15)
2 B$=ABCDE
4 MID$(XYZ$,6,5)=B$

Example: Partial writing of the character field


1 DIM XYZ$(100)
2 B$= ABCDE
3 MID$(XYZ$,1,10)=B$
Content of STRING variable B$: ABCDE
Content of field variable XYZ$: ABCDE. The field variable has a length of
5. The remaining 95 characters are not assigned.

If the length of the STRING variable is less than the character field, cha-
racter field XYZ$ is written only in the length of the STRING variable.
When allocating this character field to a STRING variable, it is not the
entire character field (defined via DIM instruction) which is assigned, but
only the range which was written previously ( length of the character
field).

Example:
1 DIM XYZ$(100)
3 MID$(XYZ$,1,10)=ABCDE
4 MID$(XYZ$,6,3)=T

The content of the XYZ$ field variable after block 3 is: ABCDE.
The field variable has a length of 5. The remaining 95 characters are not
assigned and are therefore not part of the length.
The content of the XYZ$ field variable after block 4 is: ABCDET.
The field variable now has a length of 6. The remaining 94 characters
are not assigned and are therefore not part of the length.

Example: Overwriting a character field


1 DIM XYZ$(100)
3 MID$(XYZ$,1,10)=1234567890
4 MID$(XYZ$,3,3)=T

The content of the XYZ$ field variable after block 3 is1234567890 .


The field variable has a length of 10.
The content of the XYZ$ field variable after block 4 is 12T4567890 .
The field variable has a length of 10. The character 3 is overwritten
by T. The characters 4 and 5are retained.

Example: Prohibited access to the character field


1 DIM XYZ$(100)
3 MID$(XYZ$,1,6)=ABCDEF
5 MID$(XYZ$,9,5)=TESTE
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-111
and Controls

Character String Processing

The XYZ$ field variable after block 3 contains ABCDEF.


The field variable has a length of 6.
After block 5, an attempt is made to assign a constant to the 9th to 13th
components of the character field. This, however, results in the error
message CHARACTER AREA NOT USED because the 7th and 8th
components are not assigned.
If the whole character field is to be accessed, entering the variable
name will suffice.
5-112 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Character String Processing

5.14.9 Assigning a STRING expression to a character field


If the STRING-expression contains fewer characters than the selected
range of the character field, the remaining range is regarded as not assi-
gned. This remaining range is not included in the character field length.

Example:
1 DIM XYZ$(16)
2 XYZ$=
Content of character field XYZ$:
Length of character field XYZ$: 1

If the length of the STRING expression exceeds the maximum length of


the character field during assignment, the surplus characters will be re-
jected.

Example:
1 DIM XYZ$(3)
2 XYZ$=ABCDEF
Content of character field XYZ$: ABC
Length of character field XYZ$: 3 ---> maximum length

Example:
1 DIM XYZ$(16)
2 A$=DAS
3 B$=IST EIN TEST
4 C$=EIN EI

5 MID$(XYZ$,1,4)=A$
CONTENT OF THE CHARACTER FIELD
-----------------------------------------------------------------
| 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 |10 |11 |12 |13 |14 |15 |16 |
-----------------------------------------------------------------
| | | | | | | | | | | | | | | | |
| D | A | S | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | |
-----------------------------------------------------------------
| | |
Length = 4 Area is not assigned

6 MID$(XYZ$,5,6)=B$
CONTENT OF THE CHARACTER FIELD
-----------------------------------------------------------------
| 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 |10 |11 |12 |13 |14 |15 |16 |
-----------------------------------------------------------------
| | | | | | | | | | | | | | | | |
| D | A | S | | I | S | T | | E | I | | | | | | |
| | | | | | | | | | | | | | | | |
-----------------------------------------------------------------
| | |
Length = 10 Area is not assigned
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-113
and Controls

Character String Processing

7 MID$(XYZ$,5,12)=B$
CONTENT OF THE CHARACTER FIELD
-----------------------------------------------------------------
| 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 |10 |11 |12 |13 |14 |15 |16 |
-----------------------------------------------------------------
| | | | | | | | | | | | | | | | |
| D | A | S | | I | S | T | | E | I | N | | T | E | S | T |
| | | | | | | | | | | | | | | | |
-----------------------------------------------------------------
| |
Length = 16; Range is fully assigned

8 MID$(XYZ$,9,8)=C$
CONTENT OF THE CHARACTER FIELD
-----------------------------------------------------------------
| 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 |10 |11 |12 |13 |14 |15 |16 |
-----------------------------------------------------------------
| | | | | | | | | | | | | | | | |
| D | A | S | | I | S | T | | E | I | N | | E | I | S | T |
| | | | | | | | | | | | | | | | |
-----------------------------------------------------------------
| |
Length = 16; Range is fully assigned

9 XYZ$=MID$(XYZ$,1,4)
CONTENT OF THE CHARACTER FIELD
-----------------------------------------------------------------
| 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9 |10 |11 |12 |13 |14 |15 |16 |
-----------------------------------------------------------------
| | | | | | | | | | | | | | | | |
| D | A | S | | | | | | | | | | | | | |
| | | | | | | | | | | | | | | | |
-----------------------------------------------------------------
| | |
Length = 4 Area is not assigned

The character field was cut off.


5-114 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Character String Processing

5.14.10 Comparisons of STRING expressions


It is also possible to compare STRING-expressions (STRING-con-
stants, STRING-variables and character fields) with one another.
Example:
1 DIM A$(10)
2 DIM B$(15)
3 A$=ANTON
4 B$= WILLY
5 C$=ABCDE
6 D$=VWXYZ
7 IF A$ < B$ THEN ...
8 IF MID$(A$,2,3) = MID$(B$,1,3) THEN ...
9 Z?=A$ <> TEST
10 IF A <= C THEN ...
11 IF C$ > D$ THEN ...
12 IF A$ = C$ THEN ...
13 IF TE < MID$(D$,2,2) THEN ...

The contents of the STRING-expressions are checked for alphabetical


order in accordance with the ASCII-code of the individual characters.

5.14.11 Chaining STRING expressions


Several STRING-expressions can be chained with the use of the +
plus character. The result must be assigned to a character field. The ne-
sting depth for the chaining of STRING expressions is 3. If this depth is
exceeded, the following error message is returned: RUNTIME ERROR
2153 - NESTING TOO DEEP

Example: Chaining also within CPL-instructions


1 DIM A$(3)
2 DIM B$(3)
3 A$ = ABC
4 B$ = DEF
5 C$ = GH
6 D$ = JKL
7 OPENW(1,P2,130,CHAINING TEST,10)
8 PRN#(1,A$+B$)
9 PRN#(1,A$+C$)
10 PRN#(1,C$+D$)
11 PRN#(1,A$+C$+TEST)
12 PRN#(1,UVW+XYZ)
13 CLOSE(1)

Content of P2 file:
ABCDEF <LF>
ABCGH <LF>
GHJKL <LF>
ABCGHTEST <LF>
UVWXYZ <LF><ETX><LF>

Example: Chaining texts via STRING-expressions


R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-115
and Controls

Character String Processing

10 DIM A$(100)
20 DIM B$(100)
30 DIM C$(10)
40 DIM D$(20)
51 DIM E$(30)
52 DIM F$(30)
53 DIM G$(30)
54 DIM H$(30)
55 DIM I$(30)
60 A$=DAS
70 B$=IST EIN TEST
80 MID$(C$,1,6)=A$ + B$
90 MID$(D$,1,10)=MID$(A$,1,1) + MID$(B$,1,2)
92 E$=A$ + MID$(B$,1)
93 X$=ABC
94 Y$=DE
95 F$=X$ + Y$
96 G$=X$ + A$
97 H$=X$ + A$ + TEST
98 I$=TES + T1

Content of A$: THIS Length 4


Content of B$: IS A TEST Length 9
Content of C$: THIS I Length 6
Content of D$: DIS Length 3
Content of E$: THIS IS A TEST Length 14
Content of F$: ABCDE Length 5
Content of G$: ABCTHIS Length 8
Content of H$: ABCTHIS TEST Length 12
Content of I$: TEST1 Length 5

The following lines of code will lead to faults:


1 DIM A$(3):A$ = ABC:B$ = CD:C$ = EF
2 D$ = A$ + B$
3 D$ = B$ + C$ Inadmissible assignment to a
4 D$ = A$ + B$ + TEST non-dimensioned STRING variable
5 D$ = TEST + TEST1

Example:STR$
1 DIM A$(50) : DIM B$(21)
2 A$ = STR$(A$ = ##.###,(37/3)) : B$ = STR$(2.5)

Content of character field A$:A$ = 12.333 ; character field B$:


2.500

Example:VAL
1 DIM FOLGE$(20) : FOLGE$=X-VALUE -0001.234 MM
2 XR = VAL(MID$(FOLGE$,7)) : Z% = VAL(MID$(FOLGE$,7,6))
3 Y%=VAL(MID$(FOLGE$,15,5)) : X% = VAL(MID$(FOLGE$,18))

Content of REAL-variable XR: -1.234


Content of INTEGER-variable Z%: -1
Content of INTEGER-variable Y%: 34
Content of INTEGER-variable X%: NUL
5-116 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Character String Processing

Example: LEN
1 DIM Z$(10)
2 Z$ = TEST
3 S$ = TEST
4 A% = LEN(TEST)
5 B% = LEN(Z$)
6 C% = LEN(S$)
7 D% = LEN(TEST+Z$+S$)

Content of INTEGER-variable A%: 4


Content of INTEGER-variable B%: 4
Content of INTEGER-variable C%: 4
Content of INTEGER-variable D%: 12

Example: MID$-command with read access


10 DIM A$(4)
20 DIM B$(10)
30 DIM C$(10)
40 DIM D$(10)
50 DIM E$(10)
55 DIM F$(10)
60 A$ = ABCD

70 B$ = MID$(A$,2,2) --> B$ = BC
80 C$ = MID$(A$,2,5) --> C$ = BCD
95 E$ = MID$(A$,5,1) --> E$ = NUL
97 F$ = MID$(A$,2) --> F$ = BCD
98 F$ = MID$(F$,1,1) --> F$ = B

Example: MID$-command with write access


10 DIM A$(4)
20 DIM B$(10)
30 DIM C$(10)
40 DIM D$(10)
60 A$ = ABCD
70 B$ = 1234567890
80 C$ = EFGHIJKLMN
85 D$ = A$ --> D$ = ABCD
90 MID$(D$,2,3) = B$ --> D$ = A123
95 MID$(D$,5,1) = C$ --> D$ = A123E
97 MID$(D$,4) = B$ --> D$ = A121234567

Example:TRIM$
1 DIM XYZ$(16)
2 XYZ$ = XVALUE = 0.123
3 A$ = MID$(XYZ$,8)
4 B$ = TRIM$(MID$(XYZ$,8))
5 C$ = TRIM$(MID$(XYZ$,8),L)
6 D$ = TRIM$(MID$(XYZ$,8),R)

Content of STRING variable A$: 0.123


Content of STRING-variable B$: 0.123
Content of STRING-variable C$: 0.123
Content of STRING-variable D$: 0.123
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-117
and Controls

File Processing

5.15 File Processing


Files are containers for data. During the course of a CPL program, data
can be read from files or written to files.
As a result, measured values can be first saved and then displayed or
output on a printer.

Within the CNC, files are administered in the file system. They are orga-
nized into a hierarchic structure. Individual files are accessed using di-
rectory paths.

Files can be administered using various operating modes.

To provide read or write access to data, the corresponding file must al-
ways be opened first (see OPENW, OPENR commands); as soon as
access to the data is no longer necessary, the file is closed (see CLOSE
command).

5.15.1 File names


Pay attention to the following conventions for the file name:
D Maximum length = 30 characters. There is no differentiation between
the name and any possible filename suffix. All letters, numbers and
special characters . and _ are permitted.
File names of parts programs may not exceed 28 characters be-
cause, during linking, the CNC generates a file whose name consists
of the original filename plus 2 additional characters.

. Use special character $ only for internally generated files. Filena-


mes generated externally (via the user interface or DNC) may not
contain a $.

D A distinction is made between capital and lowercase letters.


Examples: File name
P123456789.PRG
P12_Data_Dial
P12_DATA_DIAL

D Filenames . and .. are not permitted because they are already used
internally.
D Filenames within a directory must be unique.
However, files with the same name can exist in different directories.
5-118 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

File Processing

5.15.2 Sequential file structure


A sequential file contains a sequence of components (records) that
can have variable lengths. If a certain record is searched in a sequen-
tial file, the search must be carried out from the beginning of the file. Di-
rect access is not possible. When the length of a record in a sequential
file is changed, all subsequent records must be shifted.

As opposed to random files, sequential files contain records with va-


rying lengths (max. length = 1024 characters). The end of a record is
indicated by a <LF>, which does not count in the length. An <ETX><LF>
is inserted after the last record of a file, providing an EOF pointer. An
EOF pointer indicates the end of usable data (<ETX>) in a file.

5.15.3 Random-file structure


A random file contains components (records) with a fixed, definable
length. This permits random, direct access to any component in the file.
Dividing the random file into records with a fixed length permits direct
access to a certain record. As for the sequential files, the data are stored
as ASCII characters. This permits both the familiar access using the
Editor as well as reading and evaluation of random files.

The advantage of the random file is that it can be used to access the
required data more quickly. In addition, the data of a record can be pro-
cessed and/or modified without changing the structure of the rest of the
file. Records that are not completely filled with data are filled to the defi-
ned length with blanks.

If an attempt is made to insert a STRING variable whose length is longer


than that of the record into a random file, the record is filled up to the
defined length with the first characters of the STRING variable and the
remaining characters are ignored.

When the file is read, its end is marked by EOF.

The REWRITE and CLOSE instructions are used for sequential files.

Sequential access to a random-file is also possible.


R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-119
and Controls

File Processing

5.15.4 Opening a file


In order to be able to access a file by means of file management com-
mands in a CPL-program, this file must first be opened for the CPL-pro-
gram. This is accomplished with the following commands:

OPENW, OPENR
The command used to open a file is dependent on the desired type of
access:
D write access: OPENW
D read access: OPENR

If the file to be opened does not yet exist, it is created during opening
and the predetermined memory area is reserved.

Files which have already been opened can also be opened for read ac-
cess by means of the OPENR command. An open file cannot, however,
be opened again for writing to it.

To open a random-file, an additional parameter is introduced which re-


turns the length of the records in the file in bytes (1 byte = length of a
character). In all other respects, the command structure corresponds to
that of the sequential file.
After an OPENR command, the file pointer is positioned on the first file
record, which can then be read.
After an OPENW command, the file pointer is positioned on the EOF
pointer, i.e. after the last record of the file.

Syntax:
OPENW(<n>,<PGM name>,<Length>[,<PGM remark>]
[,<Record length>])

OPENR(<n>,<PGM name>[,<Record length>])


<n>: Logical number under which the file can be addres-
sed.
Values from 1 to 9 can be selected. The logical num-
ber must be programmed as an INTEGER-expres-
sion. A logical number may not be assigned for
reading and writing a file simultaneously. Therefore, a
maximum of nine different files may be opened at the
same time.
If the range of values is not adhered to, the following
error message appears: INVALID LOGICAL NUM-
BER.
<PGM name>: Must be programmed as a STRING expression.
The string must contain at least the filename (maxi-
mum of 30 characters including the suffix).
The specification of the filename, including the com-
plete prefixed path, is permitted.
5-120 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

File Processing

<Length>: Reserved length when creating the file in bytes.


A minimum length of 130 bytes is necessary since wri-
ting in a file causes at least 1 record (= 130 charac-
ters) to be created and stored. The following error
message appears if this is not observed: ILLEGAL
FILE SIZE.
<PGM remark>: Only one STRING expression is permitted for the pro-
gramming of the program remark parameter.
<Record length>: Number of bytes in a record; range of values:
1-1024. If the range of values is not adhered to, the
following error message appears: INVALID COMPO-
NENT LENGTH

Examples:
50 OPENW(1, P500,1024,This is my best
program)

40 A$=P500 : B1$=This is my best program


50 OPENW(9,A$,1024,B1$)

50 OPENW(7,PData_Mes.DAT,1024,Store measurement
data)

When the file is opened for writing, a check is made to ensure that the
random structure has been maintained.
If the structure has been damaged by the editor, the following message
appears: INVALID COMPONENT LENGTH.

Example:
10 OPENW(2,P200,1024,10)
20 FOR I% = 1 TO 3
30 PRN#(2,TESTE)
40 NEXT I%
50 CLOSE(2)

Result: P2
TESTE <LF>
TESTE <LF>
TESTE <LF>
<ETX><LF>

When the file is opened for reading, a check is made to ensure that the
random-structure has been maintained. All components must have the
identical length specified in the OPENR-command.

Example:
1 OPENW(2,P200,130,TEST,10)
2 PRN#(2,ABC)
3 CLOSE(2)
4 OPENR(1,P2,5)
5 CLOSE(1)

A check is made whether the record length of file P2 is 5. However, the


record length of this file is 10.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-121
and Controls

File Processing

Example:
P1:
N10 G1F10000X1000Y1000Z1000
1 A$=01234567890123456789
2 B$=TEST
N20 X0
M30

P2:
1 OPENW(1,PMess_PRG,500,RANDOMDATEI,10)
2 OPENR(2,P1)
3 DIM A$(30)
4 FOR I% = 1 TO 5
5 INP#(2,A$)
6 PRN#(1,A$)
7 NEXT
8 CLOSE(2)
9 CLOSE(1)

RESULT: PMeas_PRG:
N10 G1F100<LF>
1 A$=0123<LF>
2 B$=TEST<LF>
N20 X0 <LF>
M30 <LF>
<ETX><LF><LF>

If the structure was damaged by the editor, the following message ap-
pears: INVALID COMPONENT LENGTH.

FILENO
Logical file numbers are required to access files; these can have values
between 1 and 9, i.e. a maximum of 9 files can be opened at the same
time using CPL.
Command FILENO makes it possible to query the next valid logical file
number. If the function returns a value of -1, no free logical file number
is available. The function values type is integer.

Example:
10 LOG_NR%= FILENO
20 IF (LOG_NR% <> (-1)) THEN
30 OPENW(LOG_NR%,/user/usr/Test,130)
40 PRN#(LOG_NR%,Date: ,DATE)
50 CLOSE(LOG_NR%)
60 ELSE
70 PRN#(0,No free log. file number exists!)
80 ENDIF
M30
5-122 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

File Processing

VERSINF$
VERSINF$ makes it possible to query management data of the Indra-
Motion MTX in the CPL program.
The function supplies a value of type string.

Syntax:
VERSINF$(<Index1>[,<Index2>])
<Index1>: Integer constant type.
Function mode:
1: Read software version
2: Read hardware version
<Index2>: Integer type.
Auxiliary mode of the function, depending on the va-
lue of parameter <Index1>.
<Index1> = 1: No auxiliary mode exists
<Index1> = 2: Auxiliary mode:
1: Hardware type (default)
2: Vector group No.
3: Index of vector group No.

Example:
10 DIM SYS_INFO$(50)
20 SYS_INFO$ = VERSINF$(1)
30 PRN#(0,Software version: , SYS_INFO$)
M30

DIRINF
DIRINF makes it possible to query management data of the IndraMo-
tion MTX file system in the CPL program. The function supplies a value
of type Integer (for negative results, the real result is greater than the
maximum integer value, i.e. > 2,147,483,647).

The syntax changes depending on the value of parameter <Index1>.


Syntax for <Index1> = 1, 2 or 3:
DIRINF(<Index1>[,<Index2>])

Syntax for <Index1> = 4:


DIRINF(4,[<Index2>],<ResVar>[,<File number>])
<Index1>: Integer constant type. Function mode:
1: free storage space
2: occupied storage space
3: number of files present in the directory
4: filename in the directory
<Index2>: String type. Auxiliary mode:
directory name (default: current directory)
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-123
and Controls

File Processing

<ResVar>: Dimensioned string variable type, only for function


mode 4.
After the command is executed, this supplies the
name of a file in the given directory.
<File number>: Integer type, only for function mode 4.
<File number> indicates the sequential number of the
file in the directory whose name is to be supplied in
<ResVar>.
If the sequential number is invalid, NUL is supplied in
<ResVar>.

Return value:
Function mode 1: free storage space (in bytes)
Function mode 2: occupied storage space (in bytes)
Function mode 3: number of files present in the directory
Function mode 4: 0 (<ResVar> contains filename) or
1 (<ResVar> is NUL)

Example:
; Show all the file names in the /database directory
in
; the MSG window
10 DIM FILENAME$(30)
20 LJUST
30 DIR$= /database
40 ANZ_FILES%= DIRINF(3,DIR$)
50 FOR LNR%= 1 TO ANZ_FILES%
60 ERG%= DIRINF(4,DIR$,FILENAME$,LNR%)
70 PRN#(0,LNR%,: ,FILENAME$)
80 NEXT LNR%
M30

DIRCR
DIRCR makes it possible to create a new directory in the CPL program.
The function supplies a value of type integer.

Syntax:
DIRCR(<Directory>)
<Directory>: Directory name with complete path as a string expres-
sion.
If the path is not provided, the current directory is posi-
tioned in front of the string expression.

Return value:
0: Directory has been created
1: It is not possible to create a directory
5-124 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

File Processing

Example:
10 I% = DIRCR(/usr/user/test)
M30

DIRDEL
DIRDEL makes it possible to delete an empty directory in the CPL pro-
gram. The function supplies a value of type integer.

Syntax:
DIRDEL(<Directory>)
<Directory>: Directory name with complete path as a string expres-
sion.

Return value:
0: Directory has been deleted
1: Directory could not be deleted

Example:
10 I% = DIRDEL(/usr/user/test)
M30
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-125
and Controls

File Processing

5.15.5 Describing a file

LJUST, NJUST
With LJUST (= Left JUSTify), a change-over to left-justified data output
is carried out. It is effective up to the end of the program run for all data
outputs. NJUST (No JUSTify) makes it possible to return prematurely to
the formatted output.

A maximum of 7 places (4 pre-decimal and three post-decimal places)


are available for the REAL data type and a maximum of 9 places are
available for the INTEGER data type when data are output to files. Lea-
ding and trailing zeros are suppressed. This also applies to left-justified
output.

Since blanks between the NC address and the value are suppressed,
LJUST makes it possible to use CPL to directly create NC programs
which can be executed under the AUTOMATIC mode.

PRN#
Syntax:
PRN#(<n>,[<Expression>][,<Expression>][,<Expression>][,...][;])
<n>: 1 to 9: Logical number of the file to be written.
0: Output is diverted to the monitor (as in the case of
message programming with the MSG command).
<Expression>: Any alphanumeric characters (text in inverted com-
mas), format strings or variables, the content of which is
to be saved/displayed.
; Suppresses the automatic addition of a <CR><LF>.
If a record is overwritten via the PRN# command, the fol-
lowing applies:
PRN# command with semicolon:
If the length of the new data to be written is shorter than
the length of the old data, the new data are inserted and
the rest of the old data is retained.
PRN# command without semicolon:
If the length of the new data to be written is shorter than
the length of the old data, the new data are inserted and
the rest of the old data is overwritten with blanks.

The type of variable is freely selectable. Indexed variables and charac-


ter fields can also be used. Double-precision REAL expressions can
also be programmed as any definable CPL-expressions.
5-126 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

File Processing

If the result of an expression is to be output providing a format, at least


one of the expressions must be of the STRING type. The format can be
specified by using # and . in this format string. The results are ent-
ered at the place of the format instruction specified with #. The first for-
mat instruction contained in a STRING-expression refers to the first
subsequent expression which may be output with a format entry. Boo-
lean expressions cannot be formatted. The number of all programmed
format entries must be less than or equal to the number of expressions
to be output. If this condition is not fulfilled, the surplus # symbols are
displayed. An expression is output in standard format if a format entry is
not made.

If the output of an expression exceeds 1024 characters, the following


error message appears: BLOCK EXCEEDS 1024 BYTES.
If the result cannot be output in the specified format, the warning PRN
FORMAT INCORRECT is returned, and * (asterisk) characters are
output instead of the faulty format.

If #-characters are to be created in the file itself, no formattable expres-


sion may follow after the string within the PRN#-instruction.
The output of the #-character can also be performed with CHR$(35).

A line feed can be initiated during output with CHR$(13), i.e. the further
output of the PRN#- command is continued in the next line (i.e. in the
next record).
Other control characters can be transferred with the CHR$() function,
e.g. when outputting via a serial interface.

Example: PRN#- command with semicolon


1 OPENW(2,PProg123.PRG,200,35)
2 PRN#(2,TEST1 FOR PRN-COMMAND WITH SEMICOLON)
3 PRN#(2,TEST2 FOR PRN-COMMAND WITH SEMICOLON)
4 PRN#(2,TEST3 FOR PRN-COMMAND WITH SEMICOLON)
6 SEEK(2,1)
7 PRN#(2,OVERWRITE;)
8 CLOSE(2)

RESULT in PProg123.PRG:
OVERWRITE - COMMAND WITH SEMICOLON<LF>
TEST2 FOR PRN-COMMAND WITH SEMICOLON<LF>
TEST3 FOR PRN-COMMAND WITH SEMICOLON<LF>
<ETX><LF>
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-127
and Controls

File Processing

Example: PRN#- command without semicolon


1 OPENW(2,P2,1000,36)
1 REWRITE(2)
2 PRN#(2,TEST1 FOR PRN-COMMAND W/O SEMICOLON)
3 PRN#(2,TEST2 FOR PRN-COMMAND W/O SEMICOLON)
4 PRN#(2,TEST3 FOR PRN-COMMAND W/O SEMICOLON)
6 SEEK(2,1)
7 PRN#(2,OVERWRITE)
8 CLOSE(2)

RESULT in P2:
OVERWRITE <LF>
TEST2 FOR PRN-COMMAND W/O SEMICOLON<LF>
TEST3 FOR PRN-COMMAND W/O SEMICOLON<LF>
<ETX><LF>

An <ETX><LF> is inserted after the last block of the file.

The following error message appears if the length of the block exceeds
1024 characters: BLOCK EXCEEDS 1024 BYTES.

If a sequential file is written and the end of the file is reached, the file is
copied automatically and the reserved range increased by the occupied
length insofar as sufficient memory is available in the parts program me-
mory.
Since this very quickly takes up a great deal of memory, it is advisable to
reserve a sufficiently large file length when creating the file with
OPENW.

Example:
1 OPENW(1,P2,300,TEST PRN-COMMAND)
2 A$=TEST
3 B$=FOR
4 C$=PRN-COMMAND
5 PRN#(1,A$)
6 PRN#(1,B$)
7 PRN#(1,C$)
8 PRN#(1,A$;)
9 PRN#(1,B$;)
10 PRN#(1,C$;)
11 CLOSE(1)

Result:
P2:
TEST<LF>
FOR<LF>
PRN-COMMAND<LF>
TESTFORPRN-COMMAND<LF><ETX><LF>
5-128 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

File Processing

Example:
10 DIM E$(50)
20 OPENW(1,P2,300,TEST2)
30 A% = 5000
40 R = 1.231
50 B! = 4/3
60 D$ = ABCDE
70 E$ = CDEFGHI
80 PRN#(1,10;)
90 PRN#(1,#####,###.###,#.#####,A%,R,B!,D$,E$)
95 CLOSE(1)

P2:
10 5000 1.2311.33333ABCDECDEFGHI<LF>

A% R B! D$ E$

REWRITE
If data are already present in the opened file, the new data are normally
appended to the existing data when writing. An existing file can, howe-
ver, be overwritten by means of REWRITE without especially having to
delete the contents that are no longer required. When overwriting, the
range reserved in the OPENW-command remains available in the parts
program memory.

Syntax:
REWRITE(<n>)
<n>: Logical file number (range of values 1 - 9)

To overwrite a file, it must be open.


R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-129
and Controls

File Processing

5.15.6 Reading a file

INP#
With the INP# instruction, the ASCII data in an open file may be read in
record form and assigned to one or more variables. This command only
has an effect on files that were opened with OPENR(...).
INP#(<n>,<Variable>[,<Variable>][,...][;])
<n>: 1 to 9: Logical file number to be read from.
<Variable>:Variable under which the read data is stored.
; If a semicolon is programmed, the file pointer remains in the
record until the end of the record is reached. After that, the
next record is opened. Reading does not, however, auto-
matically take place there.
If no semicolon is programmed, the next record is opened
automatically.

The type of variable is freely selectable. Indexed variables and charac-


ter fields can also be used. If a value other than TRUE or FALSE is assi-
gned to a logical variable, this variable is valued at NUL.

The characters 0 to 9, leading signs -, +, leading zeros or spaces


are converted to INTEGER - or REAL- values if the variable type is IN-
TEGER or REAL (simple and double precision). If another character is
assigned to an INTEGER- or REAL- variable, the variable is assigned
NUL. If a variable is assigned NUL, the position within the file does not
change.

If the value assigned to an INTEGER or a REAL variable is too high, a


corresponding error message appears:
INVALID INTEGER-VALUE
INVALID FLOAT-VALUE

Example: INP#- instruction


P2:
ABC 123456789 ABC

P3:
1 OPENR(2,P2)
2 DIM C$(3)
3 DIM D$(3)
4 INP#(2,I%,J,L?,C$,K%,D$)
5 CLOSE(2)

RESULT:
I% = NUL
J = NUL
L? = NUL
C$ = ABC
K% = 123456789
D$ = ABC
5-130 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

File Processing

Example: Reading a record from a file


1 OPENW(1,P2,200,Test,22)
2 PRN#(1,-12TEST1.23V12ABCD2.4A)
3 PRN#(1,-12TEST1.23V12ABCD2.4A)
4 PRN#(1,-12TEST1.23V12ABCD2.4A)
5 CLOSE(1)
6 DIM A$(3)
7 DIM C$(5)
8 DIM D$(4)
9 DIM E$(4)
10 DIM G$(25)
11 DIM H$(7)
12 DIM I$(7)
13 DIM J$(25)
14 DIM R(1,2)
15 OPENR(2,P2,22)
16 INP#(2,B%,D$,R(1,1),MID$(E$,1,1),R(1,2),A$,C$)
17 INP#(2,G$)
18 INP#(2,H$;)
19 INP#(2,I$;)
20 INP#(2,J$)
21 CLOSE(2)

Result:
B% = -12
D$ = TEST ,since max. length of character field = 4
R(1.1) = 1,230
E$ = V
R(1,2) = 12.000
A$ = ABC ,since max. length of character field = 3
C$ = D2.4A
G$ = -12TEST1.23V12ABCD2.4A
H$ = -12TEST ,since max. length of character field = 7
I$ = 1.23V12 ,since max. length of character field = 7
J$ = ABCD2.4A
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-131
and Controls

File Processing

5.15.7 End-of-file recognition

EOF
The EOF function allows a query to be made as to whether the end of file
(EOF) has been reached.
The EOF function returns the logical value TRUE if the end of the file is
reached during reading. Otherwise FALSE is returned.

Example:
:
9 DIM A$(10)
10 OPENR(1,P,444) : I%=0
11 WHILE NOT (EOF(1))DO
12 INP#(1,A$)
13 I%=I%+1
14 END
15 CLOSE(1)
M30

5.15.8 Closing a file

CLOSE
Closes a file.
A maximum of 9 files can be open at the same time. If, when 9 files are
open, access to a further file is necessary, you must first close a file.
Open files should therefore as a rule be closed immediately upon com-
pletion of read- or write operations.
Syntax:
CLOSE(<n>)
<n>: 1 to 9: Logical number of the file
that is to be closed.
Example:
:
90 DIM A$(35)
100 XPOS = MPOS(1)
110 YPOS = MPOS(2)
120 OPENW(1,P5,500,ACHSPOS)
130 REWRITE(1)
140 PRN#(1,X-axis,XPOS,YPOS,Y-axis,YPOS)
150 CLOSE(1)
160 OPENR(1,P5)
170 INP#(1,A$)
180 CLOSE(1)
:
5-132 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

File Processing

In the above example, the current positions of the X- and Y- axis are
transferred to variables (lines 90 to 110). File 1 is then opened and sto-
red as parts program P5 (line 120).
The file is subsequently written or overwritten and then closed (lines
140 to 150). The file is then opened for reading and assigned the con-
tents of the A$ variable. It is closed again after read access (lines 160 to
180).

5.15.9 Reading file pointer position

FILEPOS
The FILEPOS() function returns the number of the current record of a
random file. This record can be accessed afterwards. It is also possible
to determine the record-offset within the current record of a random-file
or the offset from the current byte that can be accessed for a sequential
file. The file can therefore be a sequential or a random-file.

Offset refers to the number of bytes- from the top of the file up to the
current byte in a file. The record-offset specifies the byte at which posi-
tioning takes place within a record. The record-offset begins with the va-
lue 1 (= 1st byte in a record) and can have the maximum value of the
record-length + 1 (last byte in this record is <LF>). The value 1 is retur-
ned if you are on the EOF-pointer.

Syntax:
FILEPOS(<n>[,<mode>])
<n>: 1 to 9: Logical number of the file in which the position of
the file pointer is to be read.
If the range of values is not adhered to, the following error
message appears: INVALID FILE NUMBER
<Mode>: With random-files: Range of values = 1 to 3
<mode> = 1:
Supplies the offset to the current byte which can be read or
written.
<mode> = 2:
Supplies the record-number of the current record which can
be read or written. The result is as follows if you are on the
EOF-pointer: Number of records + 1.
<mode> = 3:
This command supplies the record-offset within the current
record which can be read or written. The record-offset be-
gins with the value 1 (. 1st byte in this record) and can have
the maximum value of the record-length + 1 (. last byte in
this record is <LF>).
The value 1 is returned if you are on the EOF-pointer and
reading from the file is not permitted.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-133
and Controls

File Processing

<Mode> not programmed:


Supplies the record-number of the current record which can
be read or written. The result is as follows if you are on the
EOF-pointer: Number of records + 1.
With sequential files: Range of values = 1
<Mode> = 1 or not programmed:
Supplies the offset to the current byte which can be read or
written.

. If the range of values of <Mode> is not adhered to, the following er-
ror message appears: INVALID PARAMETER.

Example: FILEPOS and sequential file


1 OPENW(1,P2,200,TEST)
2 FOR I% = 1 TO 10
3 PRN#(1,TEST FUER FILEPOS)
4 NEXT
5 CLOSE(1)
6 OPENR(1,P2)
7 SEEK(1.3)
8 POS% = FILEPOS(1)
9 POS1% = FILEPOS(1,1)
11 SEEK(1,0) : REM POSITIONED ON END OF FILE
12 POS2% = FILEPOS(1)
13 POS3% = FILEPOS(1,1)
14 CLOSE(1)

Result:
POS% = 3 -> byte number
POS1% = 3 -> byte number
POS2% = 171 -> byte number
POS3% = 171 -> byte number
5-134 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

File Processing

Example: FILEPOS and random-file


1 OPENW(1,P2,200,TEST,1024)
2 FOR I% = 1 TO 10
3 PRN#(1,TEST FUER FILEPOS)
4 NEXT
5 SEEK(1,3,2)
6 POS% = FILEPOS(1)
7 POS1% = FILEPOS(1,1)
8 POS2% = FILEPOS(1.2)
9 POS3% = FILEPOS(1.3)
10 PRN#(1,Overwriting of 3rd record from byte 2)
with this text)
11 SEEK(1,0) : REM Positioned on end of file
6 POS% = FILEPOS(1)
7 POS1% = FILEPOS(1,1)
8 POS2% = FILEPOS(1.2)
9 POS3% = FILEPOS(1.3)
11 CLOSE(1)

Result:
POS% = 3 > number of record of current position
POS1% = 258 > byte number
POS2% = 3 > number of record of current position
POS3% = 2 > position within 3rd record
POS% = 11 > number of record of current position
POS1% = 1281 > byte number
POS2% = 11 > number of record of current position
POS3% = 1 > position within 3rd record

5.15.10 Setting file pointer

SEEK
Positions the file pointer at a certain position of an open file. The file may
be a sequential or a random-file.
With sequential files, the file must be opened with the command
OPENR(..). For random-files, the command OPENW(..) is also per-
missible.

Syntax:
SEEK(<n>,<k>[,<o>])
<n>: Logical number of the file in which the file pointer is to be
positioned.
Range of values: 1 through 9
If the range of values is not adhered to, the following error
message appears: INVALID FILE NUMBER
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-135
and Controls

File Processing

<k>: Record-number of a random-file or byte number of a se-


quential file. The file pointer is positioned on <k>.
Range of values: 0 to last existing record or
0 to last existing byte.
The record with the EOF-pointer is taken to be the last exi-
sting record. At 0, positioning is on the EOF-pointer.
The INVALID COMPONENT error message appears if the
range of values is not adhered to or if the specified record
does not exist.
<o>: Record-Offset. Specifies at which byte within a record posi-
tioning should take place.
Range of values: 1 - record-length + 1.
If the record-offset is not programmed for random-files, po-
sitioning of the file pointer is at the 1st byte of record <k>.
If the range of values is not adhered to, the INVALID PARA-
METER error message appears.
This parameter is permitted only for random-files. The IN-
VALID PARAMETER error message appears if this para-
meter is programmed although it is a sequential file (which
has been opened for reading).

Example: SEEK and sequential file


1 DIM A$(1):LJUST:OPENW(1,P271,130,TEST):FOR I%=1 TO
10: PRN#(1,!/-!/-!/-!/-!/-!/-!/-!/-!/-!/-):NEXT:
CLOSE(1):OPENR(2,P271):FOR I%=1 TO FILESIZE(2,2)-28:
IF NOT (EOF(2)) THEN SEEK(2,I%):INP#(2,A$) ENDIF:
IF (EOF(2)) THEN PRN#(0,###,I%,. BYTE: <EOF>):
ELSE PRN#(0,###,I%,. BYTE: <,A$,>) ENDIF:
NEXT I%:CLOSE(2)
M30

Example: SEEK and random-file


1 OPENW(1,27272,200,TEST,1024):LJUST
2 FOR I%= 1 TO 10
3 PRN#(1,I%,. Record)
4 NEXT
5 SEEK(1,3,4) : REM Positioned on the 4th byte in
the 3rd record
6 PRN#(1,Overwriting of 3rd record from byte 4 with
this text)
7 SEEK(1,11):PRN#(1,11. Record)
8 SEEK(1,11,5):PRN#(1,@@)
9 SEEK(1,0):PRN#(1,<EOF>)
10 SEEK(1,0,1):PRN#(1,neues <EOF>)
11 CLOSE(1)
5-136 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

File Processing

5.15.11 Determining file size

FILESIZE
Supplies the size of a file, or the limit up to which a file has already been
written. The file can be a sequential or a random-file. This command
only has an effect on files that were opened with OPENR(...).

Syntax:
FILESIZE(<n>[,<k>])
<n>: 1 to 9
Logical number of the file of which the size is to be determi-
ned. If the range of values is not adhered to, the following
error message appears: INVALID FILE NUMBER
<k>: With random files: Range of values = 1 to 4
With sequential files: Range of values = 1 to 2
<k> = 1:
Total memory area size (in bytes) used by a file.
<k> = 2:
Memory area size (in bytes) used from the start of the data
range up to the EOF pointer (excluding the size of the EOF
pointer).
<k> = 3:
Maximum number of records in a file. This result depends
on the record-length with which the file was opened.
<k> = 4:
Number of records from the start of the file up to the EOF-
pointer. This result depends on the record-length with which
the file was opened.
<k> not programmed:
Like <k> = 1.
If the range of values for <k> is not adhered to, the following
error message appears: INVALID PARAMETER.

Example: FILESIZE and sequential file


1 OPENW(1,2,1000)
2 FOR I%= 1 TO 20
3 PRN#(1,TEST FILESIZE)
4 NEXT
5 CLOSE(1)
6 OPENR(2,2)
7 A%=FILESIZE(2)
9 B%=FILESIZE(2,1)
10 C%=FILESIZE(2,2)
11 CLOSE(2)

INTEGER variable A% has the value: 302


INTEGER variable B% has the value: 302
INTEGER variable C% has the value: 300
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-137
and Controls

File Processing

Example: FILESIZE and random-file


1 OPENW(1,P2,1000,10)
2 FOR I%= 1 TO 20
3 PRN#(1,TEST FILESIZE)
4 NEXT
5 CLOSE(1)
6 OPENR(2,2,10)
7 A%=FILESIZE(2)
9 B%=FILESIZE(2,1)
10 C%=FILESIZE(2,2)
10 D=FILESIZE(2,3)
10 E%=FILESIZE(2,4)
11 CLOSE(2)

INTEGER variable A% has the value: 222


INTEGER variable B% has the value: 222
INTEGER variable C% has the value: 220
INTEGER variable D% has the value: 20
INTEGER variable E% has the value: 20
5-138 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

File Processing

5.15.12 Erasing a file

ERASE
Erases files in the current directory.

Syntax:
ERASE(<Prog-identifier>)
<PGM identifier> STRING expression; max. 30 characters.
Otherwise the INVALID FILE NAME error message
appears.

The following values can be returned if the ERASE-function is assigned


to an INTEGER-variable or if it is used in loops or queries (WHILE, IF
etc.):
0: File erased.
1: File not erased because it does not exist.
2: File not erased because this file is erase-protected.
3: File not erased because this file is active.

If a file cannot be erased, a warning to this effect is issued and execution


of the program continues.

Examples:
10 IF ERASE(P1) <> 0 THEN ...

10 I% = ERASE(P1)

10 WHILE ERASE(P1) <> 0 DO ...

Example:
10 OPENW(1,P2,200)
11 OPENW(2,P3,200)
20 PRN#(1,TEST1 FOR ERASE)
21 PRN#(2,TEST2 FOR ERASE)
31 CLOSE(1)
32 CLOSE(2)
40 ERASE(P2)
43 A$=P3
44 ERASE(A$)
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-139
and Controls

File Processing

5.15.13 Determine file access rights

FILEACCESS
With FILEACCESS of the CPL program, it is possible to tell whether a
file exists and which access rights (privileges) it has.

Syntax:
FILEACCESS( <File name>)
<File name> File name with a complete path as a string expres-
sion.
If the file name contains no path, the file is searched in
the current directory. The CPL-function supplies the
return value as an integer-value:
-1 : file does not exist
0: : file without access rights
otherwise : binary-coded access rights:
Bit1: execution possible (X)
Bit2: writing allowed (W)
Bit3: reading allowed (R)
Bit4: file is a directory (D)
Bit5: file is an active program (A)

An active program is a file that undergoes the following in a channel:


D executed as a program
D executed as a subroutine of a program
D opened by a CPL command.

If the access rights of a zero offset or tool compensation table which is


being used in a running part program are queried by the CPL FILEAC-
CESS, Bit5 is  set.

Example:
10 I% = FILEACCESS(/usrfep/test.cnc)
5-140 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

File Processing

5.15.14 Determine file date

FILEDATE
In the CPL-program, the date of a file can be determined with FILE-
DATE.
An access error does not generate a parts program error; instead, the
function supplies an empty string.

Syntax:
FILEDATE(<File name>[,<Mode>])
where:
<File name> File name with a complete path as a string expres-
sion.
If the file name contains no path, the file is searched in
the current directory. The CPL-function supplies a
string-expression as a return value.
<Mode> Integer variable for the function mode
(default = 1):
1 = Date of the file, format: dd.mm.yy
2 = Time of the file, format: hh.mm.ss

Example:
10 DIM DATE$(10)
20 DATE$ = FILEDATE(/usr/user/Test.txt,1)
30 IF LEN(DATE$)>0 THEN
40 PRN#(0,File date: ,DATE$)
50 ENDIF
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-141
and Controls

File Processing

5.15.15 Copying files

FILECOPY
FILECOPY is used to copy a file in the CPL program.

Syntax:
FILECOPY(<Source file>,<Target file>)
where:
<Source file> File name with the complete path of the source file as
a string expression. If the file name contains no path,
the file is searched in the current directory.
<Target file> File name with the complete path of the target file as a
string expression. If the file name contains no path,
the file is created in the current directory.
ERRNO CPL variable that can be programmed in any position.
When ERRNO is programmed, no runtime error is is-
sued; the return values are:
0: Access OK
-8: name of source file, including path, is too long
-9: access to source file impossible
-10: name of target file, including path, is too long
-11: file name (source or target) invalid
-12: copying impossible.

Example:
10 FILECOPY(/usr/user/Test.txt, /usr/user/Test.bak,
ERRNO)
20 IF ERNO = 0 THEN
30 PRN#(0,Copying procedure OK)
40 ENDIF
5-142 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Communication

5.16 Communication

MMC
Sends information regarding the program running time from a subrou-
tine to a client and waits for the result from this client.
This is carried out with the aid of CPL variables, which can send values
from the parts program as well as return values to the parts program.
The parts program is stopped during runtime at the point where the
MMC command is received.

The following processing possibilities are possible:


D If no client has reported that it is able to process the MMC command,
then the corresponding return value (=1) is assigned and the proces-
sing of the parts program continues.
D If a suitable client for processing the data of the MMC command is
available, then an assignment between the parts program and the
client occurs. After the client has sent a reply, the corresponding re-
turn value is set and the execution of the parts program continues.

The MMC-command can have a maximum of 20 CPL-variables as para-


meters. The name and the values of these variables are transmitted to
the client.

Syntax:
MMC(<CPL Var1>[,<Cpl Var2>....[,<Cpl VarN>]....])

<CPL Var1>... CPL variables, N=max. 20


<CPL VarN> The client can write new values to the CPL varia-
bles stated in the MMC command. The CPL varia-
bles stated in the MMC command can be used in
the parts program.

The MMC-command supplies the following return values as a result:


0: OK
1: no client present
2: error in client
9: client terminated.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG 5-143
and Controls

Communication

Example:
10 DIM PROGNAME$ (50)
20 PROGNAME$=WinProg
30 INTPAR%=1
40 REALPAR=1.1
50 I%=MMC(PROGNAME$, CPL variables PROGNAME$, INT-
INTPAR%,REALPAR) PAR% and REALPAR are made avai-
lable, with their values, to the client.
60 IF I%=0 THEN The block preparation of the parts
70 IF INTPAR%=2 THEN program is not continued in line 60
80 ... until a corresponding finished mes-
90 ELSE sage has arrived.
100 ...
110 ENDIF
120 ENDIF
5-144 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Communication

Notes:
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-1
and Controls

Appendix

A Appendix

A.1 Abbreviations

Abbrevia- Meaning
tion
OM Operating mode
UI User interface
CSE Components sensitive to electrostatic
discharge
ESD Electrostatic discharge
Abbreviation for all designations that
are concerned with electrostatic di-
scharge, e.g. ESD protection, ESD-
sensitive.
Fx Function key with the number x
MP Main program
LSEC Lead screw error compensation
MDI Operating mode manual data input
MP Machine parameter
MSD Machine status display
NC, CNC Numerical control
PE Protective earth
SK Softkey
PLC Programmable logic control
SR Subroutine
MTB Machine tool builder
T Tool
A-2 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

A.2 Overview Tables of NC Functions


Arranged alphanumerically according to long form: page A-2 ff.
Arranged alphanumerically according to group: page A-25 ff.

Arranged alphanumerically according to long form:


NC function name Group Designation / Explanation Page Function in
Long Short (- means: PNC MTC
form form active
blockwise)
; - - Comment: skip the rest of the line 2-21

() - - Comment: skip the content within the paren- 2-21


theses
(MSG - - output message text 2-23

/ - - Skip block 2-38

// - - Comment 2-21

ABS - CPL ABS(<input value>) 2-62 ABS -


Outputs the input value as an absolute value.
AC(...) - - Local absolute dimension programming, e.g. 3-69 AC(...) -
X=AC(10)
ACOS - CPL <function value> = ACOS(<input value>) 2-63 ACOS -
Application of the arc-cosine function on the
<input value>.

AND - CPL <Expression1> AND <Expression2> 2-64 AND -


Binary link between two BOOLEAN / INTEGER
expressions

APOS - CPL APOS(<axis selection>) 5-11 APOS -


Outputs the current actual axis value, based on
the machine zero point.

Area ARA - Area(<BNr>,<Sta>{,<Mod>,{<P1>},{<P2>},{<D 4-2 - -


1>},{<D2>}})
Defines, activates or deactivates up to 10 rec-
tangular, two-dimensional dead or working
ranges with axis-parallel boundaries.

ASC - CPL ASC(<character string>) 5-105 ASC -


Outputs the ordinal number of the first charac-
ter (ASCII code) of <Character string> as an
INTEGER value.
ASIN - CPL <function value> = ASIN(<input value>) 2-63 ASIN -
Application of the arc-sine function on the <in-
put value>.

ASPCLR - - ASPCLR(<SR No>) 4-5 - -


Asynchronous subroutines: log off
ASPDIS - - ASPDIS(<SR No>) 4-6 - -
Asynchronous subroutines: switch off
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-3
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
ASPENA - - ASPENA(<SR No>) 4-6 - -
Asynchronous subroutines: switch on
ASPRTP - - ASPRTP(<SR No>,<Point>) 4-7 - -
Asynchronous subroutines: define point of re-
turn to path

ASPSET - - ASPSET(<SR No>,<SR name>{,<Flags>}) 4-8 - -


Asynchronous subroutines: log in
ASPSTA - - ASPSTA(<SR No>{,<Channel No>}) 4-9 - -
Asynchronous subroutines: trigger
AssLogName ALN - ALN(...) 4-10 G515 -
Assign logical axis name
ASTOPA - - ASTOPA[<Channel No.>, <Cond.1> 2-79 - -
{,<Cond.2>}{...{,<Cond.8>}...}]
Channel synchronization command: The chan-
nel to be controlled is stopped as long as all
the conditions are fulfilled. The conditions refer
to the axis positions, e.g. Z > 20
ASTOPO - - ASTOPO[<Channel No.>, <Cond.1> 2-79 - -
{,<Cond.2>}{...{,<Cond.8>}...}]
Channel synchronization command: The chan-
nel to be controlled is stopped as long as one
condition is fulfilled. The conditions refer to the
axis positions, e.g. Z > 20
ATAN - CPL <Function value> = ATAN(<Input value>) 2-63 ATAN -
Application of the arc-tan function on the <in-
put value>.

ATCAL - - ATCAL(<file>,<OptData>,<mask> 4-11


{,<Info>}{,<NumIt>})
Calibration of axis kinematics: optimize param-
eters.
ATFWD - - ATFWD(<Coord>,<AxCoord>{,<ParData>}) 4-13
Calibration of axis kinematics: convert parame-
ters

ATGET - - ATGET(<ParData>{,<ATrafNr>}) 4-14


Calibration of axis kinematics: read parameter
from NC

ATPUT - - ATPUT(<ParData>{,<ATrafNr>}) 4-15


Calibration of axis kinematics: write parameter
to NC

ATrans ATR Program coor- ATR(X..., Y..., Z..., ...): Additive program coordi- 4-153
dinate offset nate offset ON
ATR( ): Additive program coordinate offset OFF

AUXFUNC - - Execute active auxiliary functions of all groups 4-16


A-4 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
AxAcc AAC Axis accel. AAC(X..., Y..., Z..., ...): switch on 4-17 G6/G7 -
AAC(1): switch on with saved
setting
AAC( ): switch off
Program axis acceleration

AxAccSave AAS - Save current axis acceleration. 4-17 - -

AxCouple AXC Axis coupling AXC(<Master>,<Slave1>(...),<Slave2>(...),...): 4-19 G580/G581


Activate axis coupling
AXC( ) : Deactivate axis coupling

AxisToSpindle ATS - ATS(<axis name>) 4-22


Switch axis to spindle mode.
AXO - CPL AXO((<Axis selection>[,<Selection type>]) 5-15 AXO -
Transfers an active G92 offset for a coordinate.
AXP - CPL AXP(axis number>,<path information>) 5-50 AXP -
This function permits level-independent part
and measurement programs (program AXP in
place of the address values).
BCD - CPL <BCD value> = BCD(<binary value>) 2-65 BCD -
Convert BCD format to binary format.
BcsCorr BCR Tool length BCR({<XW-Offset>}{,{<YW-Offset>} 4-23 G138/G139 -
comp. {,{<ZW-Offset>}{,{<Angle1>} {,{<Angle2>}
{,{<Angle3>}}}}}}) : switch on
BCR( ): switch off
Placement: Tool position compensation.

BIN - CPL <Binary value> = BIN(<BCD value>) 2-65 BIN -


Convert binary format to BCD format.
BITIF - CPL BITIF(<Bit signal>[,<Index>[,<IF unit>]]) 5-51 IC -
This function permits access to the digital inter-
face between the NC and the PLC.

BlkNmb BNB - BlkNmb(<Disp>) 2-72 PREPNUM -


Limits the number of program blocks that are
read in and viewed by block preparation.

BSTOPA - - BSTOPA[<Channel No.>, <Cond.1> 2-81 - -


{,<Cond.2>}{...{,<Cond.8>}...}]
Channel synchronization command: The chan-
nel to be controlled is stopped as long as all
the conditions are fulfilled. The conditions refer
to the basic workpiece positions, e.g. Z > 20
BSTOPO - - BSTOPO[<Channel No.>, <Cond.1> 2-81 - -
{,<Cond.2>}{...{,<Cond.8>}...}]
Channel synchronization command: The chan-
nel to be controlled is stopped as long as one
condition is fulfilled. The conditions refer to the
basic workpiece positions, e.g. Z > 20
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-5
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
CALL - CPL CALL <Program number> [<Transfer parame- 2-29 CALL -
ter1>,...] [DIN]
Subroutine call from a CPL program

CASE - CPL CASE <Integer expression> OF 2-40 CASE -


LABEL <Int. constant>[,<Additional int.
constant>] [: <Instruction>]
<Instruction>
LABEL ...
OTHERWISE <Instruction>
<Instruction>
ENDCASE
Conditional selection from several alternatives.
ChLength CHL Cham./Round. CHL(<Chamfer length>): switch on 4-25 G234/G35 -
CHL( ): switch off
Insert transitional chamfers with defined cham-
fer length.
CHR$ - CPL CHR$(<Integer expression>) 5-105 CHR$ -
Supplies a character whose ordinal number in
the ASCII table equals the value transferred
using parameter <INTEGER expression>.
ChSection CHS Cham./Round. CHS(<Chamfer section>): switch on 4-25 G234/G35 -
CHS( ): switch off
Insert transitional chamfers with defined cham-
fer section.
CLOCK - CPL <Function value> = CLOCK 5-53 CLOCK -
Query of the time counter in milliseconds.
CLOSE - CPL CLOSE(<n>) 5-131 CLOSE -
Closes an opened file after reading or writing
operations are complete.

CLRWARN - CPL Delete all the warnings of a channel that were 2-59 - -
generated with SETWARN.
COF - CPL COF(<Axis selection>[,<Selection type>]) 5-16 COF -
Supplies the last-programmed contour shift of
a coordinate for the current channel.

COFFS - - Contour shift for 3D radius correction 3-79 - -

Collision CLN Collision moni- CLN(1): switch on 4-27


tor CLN(CollErr..| LA... | DLA... | DEF) :
Switch on with parameter setting
CLN( ): switch off
Collision monitor for 2D cutter path compensa-
tion.
ConstFeed CFD V profile Constant velocity 4-68 G310 -

Coord CRD Axis transfor- CRD(x): Switch axis transformation on 4-30 Coord G30ff.
mation CRD( ): Switch axis transformation off
e.g. end surface transformation
A-6 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
COS - CPL <Function value> = COS(<Input value>) 2-63 COS -
Cosine function for the <input value>.
CoupleSpline- CST Axis coupling CST(STAB(...)) 4-32 G582
Tab Generate a spline coupling table
CPROBE - CPL CPROBE(<Selection>[,<Selection type>]) 5-12 CPROBE -
Reads the measured value for a coordinate.
D D D-correction Dx: Activate D-correction (1-99 tools) 3-99 G147 -
D0: Cancel the D-correction. G847,G148
DATE - CPL <String variable> = DATE 5-53 DATE -
Assigns the date in the form DD.MM to a
<STRING variable>.

DBSEA - CPL DBSEA(<DbTab>,<Key1>,<Key2>,<Search- 5-25


Cond>,<SeachRes>[,<ResVar>])
Searches data blocks in a database table.

DBTAB - CPL DBTAB(<DbTable>,<Key1>,<Key2>[,<Res- 5-24


Var>])
Reads a complete data block or a substructure
of a database table to a CPL variable or writes
back from this variable.

DCT - CPL DCT(<Value selection>,<Data 5-23 TC -


block>[,[<Table>] [,<Unit>]])
Read/write access to any D-correction table or
to external tool correction values.
DcTSel DCS - DCS({<Path>}<File name>) 4-33 G22 K -
Activation of a D-correction table.
DefAxis DAX - Create default axis configuration 4-34 G513 -

DefTangTrans DTT Transition DTT(<Transition angle>): Activate G228 -


angle DTT( ): Deactivate
Definition of tangential contour transition

DiaProg DIA Diam./Rad. Diameter programming 4-35 DIA G16

DIM - CPL DIM <Variable name>(<Field size1>[,<Field 2-53, DIM -


size2>]) 5-101
Specification of the field size (dimensioning) of
ARRAY variables with INTEGER constants.
DIRCR - CPL DIRCR(<Directory>) 5-123
Creates a new directory.
DIRDEL - CPL DIRDEL(<Directory>) 5-124
Deletes an empty directory.
DIRINF - CPL DIRINF(4,[<Index2>],<ResVar>[,<File num- 5-122
ber])
Calls administration data of the file system.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-7
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
DistCtrl DCR - DCR(1) Height regulation for digitization, 4-37 DistCtrl -
ON acc. to machine param.
DCR(<Fct>) ON with autonomous config.
data
DCR( ) Height regulation OFF

DPC - CPL DPC(<Selection>[,<Selection type>]) 5-17 DPC -


Supplies the last-programmed parameter of
workpiece position compensation BcsCorr of a
coordinate (offset values and turning angle) for
the current channel.

SD SD ED-correction ED x: Activation of external tool compensation 3-100 G145 -


(1-16 tools / tool edges) G845,G146
ED0: Deactivation of external tool compensa-
tion
EndPosCouple EPC - EPC(<M-coord>,<S-coord>,<Factor>): 4-39 - -
End position coupling ON
EPC( ): End position coupling OFF

EOF - CPL EOF(<n>) 5-131 EOF -


Check for end of file.
ERASE - CPL ERASE(<Program ID>) 5-138 ERASE -
Deletes files.
ERRNO - CPL Error return of various CPL functions. 2-56 - -

F F - F-address for G93, G94, G95 3-95 F

FA FA - Velocity for asynchronous axes. 3-96 FA

FALSE - CPL <Boolean variable> = FALSE LEERER FALSE


MERKER -
Truth value of a BOOLEAN variable
FeedAd FAD Feed advance FAD(1) : remove axis from feed 4-41 G594/G595
display
FAD( ): Axis contained in feed display

FeedForward FFW Servo control FFW(X..., Y..., Z..., ...): switch on 4-42 G114/G115 G6/G7
FFW( ): switch off
Activate servo control

FILEACCESS - CPL FILEACCESS(<File name>) 5-139 FILEAC- -


Determines whether a file exists and what ac- CESS
cess rights it has.

FILECOPY - CPL Copy files. 5-141 - -

FILEDATE - CPL FILEDATE(<File name>[,<Mode>]) 5-140 FILEDATE -


Determines the date/time of a file.
FILENO - CPL Supplies the next valid logical file number. 5-121
A-8 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
FILEPOS - CPL FILEPOS(<n>[,<Mode>]) 5-132 FILEPOS -
Supplies the record number of the current re-
cord and the record offset of a random file.
For sequential files, supplies the current byte
position of the file indicator.

FILESIZE - CPL FILESIZE(<n>[,<k>]) 5-136 FILESIZE -


Supplies the size of a file or the limit to which a
file has already been written.
FlyMeas FME Measurement FME(MpiAxis< i>) X... Y... Z... 4-44 G275 -
on-the-fly Movement with on-the-fly measurement

FOR NEXT - CPL FOR <Count.var.>=<Start val> [STEP spac- 2-42 FOR NEXT -
ing>] TO <End val><Routine>
NEXT [<Count.variable>]
Loop construction with automatically updated
counter.

FsMove FSM - Driving against a fixed stop 4-48 G475 G75


(Fs = fixed stop)
FsProbe FSP - Measurement at fixed stop 4-46 G475 G75

FsReset FSR - Cancel fixed stop 4-48 G477 G76

FsTorque FST - Torque for fixed stop 4-48 G476 AXD

G - - User-defined local subroutines

G00 G0 Interpolation Linear interpolation (rapid travel) 3-3 G00/G10 G00

G00(..) G0(..) Interpolation Rapid travel with options 3-3


Optional parameters
NIPS: without precise stop
IPS1: Precise stop window 1
IPS2: Precise stop window 2
IPS3: Precise stop window 3 (only braking to
V=0)
POL/POLAR: with polar coordinate program-
ming, e.g. G0(POL) X50 A45 B10, with A, B =
polar angle 1/2

G01 G1 Interpolation Linear interpolation (feed) 3-5 G01/G11 G01

G02 G2 Interpolation Circular interpolation, clockwise 3-7 G02/G12 G02


(incl. helical N)
G02(POL) G2(..) Interpolation Circular interpolation, clockwise 3-11 G02/G12 G02
(incl. helical N) with polar coordinate program-
ming

G03 G3 Interpolation Circular interpolation, counterclockwise 3-7 G03/G13 G03


(incl. helical N)
G03(POL) G3(..) Interpolation Circular interpolation, counterclockwise 3-11 G02/G12 G02
(incl. helical N) with polar coordinate program-
ming
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-9
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
G04 G4 - G4(F..) Dwell time in seconds 3-13 G04/G104 G04
G4(S...) Dwell time in spindle rotations; refer-
ence spindle is the main spindle (MainSp)

G05 G5 Interpolation Tangential circle entry (incl. helical N) 3-14 G05 -

G06 G6 Interpolation Splines, nurbs 3-15 G99 -

G08 G8 Path slope Path slope on with path SHAPE according to 3-21 G08 G08
machine parameters
G08(SHAPE...) - Path slope Path slope ON with programmed path SHAPE 3-23 G108 G08

G09 G9 Path slope Path slop OFF (without SHAPE) 3-21 G09 G09

G09(..) G9(..) Path slope G9(X..., Y..., ...) 3-23 G408,


Path slope OFF with axis-wise programmed G608
SHAPE arrangement
G9(ASHAPE)
Path slope OFF with axis-wise SHAPE ar-
rangement according to machine parameters
G9(SHAPE ...)
Path slope OFF with programmed path SHAPE
G9(SIN ...)
Path slope OFF with sin2-shaped SHAPE (pos-
sible SHAPE arrangement: 5, 10, 15, 20, 40)

G140 - 3D radius corr. 3D radius correction OFF 3-79 G141

G141 - 3D radius corr. 3D radius correction to left of contour 3-79 G141

G142 - 3D radius corr. 3D radius correction to right of contour 3-79 G142

G152.1 G152 IP page 1 Placement: Inclined plane, programmable, 3-83 G352


page 1
G152.2 - - IP page 2-5 Placement: Inclined plane, programmable, 3-83 G452
G152.5 page 2-5

G153 - SE Placement: Inclined plane, all OFF 3-83, -


3-83
G153.1 - - IP page 1-5 Placement: Inclined plane page 1-5 OFF 3-83, G353
G153.5 3-83
G154.1 G154 IP page 1 Placement: 1st inclined plane, page 1 ON 3-83 G354

G154.2 - - IP page 2-5 Placement: 1st inclined plane, page 2-5 ON 3-83 G454/G554
G154.5
G155.1 G155 IP page 1 Placement: 2nd inclined plane, page 1 ON 3-83 G355

G155.2 - - IP page 2-5 Placement: 2nd inclined plane, page 2-5 ON 3-83 G455/G555
G155.5
G156.1 G156 IP page 1 Placement: 3rd inclined plane, page 1 ON 3-83 G356

G156.2 - - IP page 2-5 Placement: 3rd inclined plane, page 2-5 ON 3-83 G456/G556
G156.5
G157.1 G157 IP page 1 Placement: 4th inclined plane, page 1 ON 3-83 G357
A-10 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
G157.2 - - IP page 2-5 Placement: 4th inclined plane, page 2-5 ON 3-83 G457/G557
G157.5
G158.1 G158 IP page 1 Placement: 5th inclined plane, page 1 ON 3-83 G358

G158.2 - - IP page 2-5 Placement: 5th inclined plane, page 2-5 ON 3-83 G458/G558
G158.5
G159.1 G159 IP page 1 Placement: 6th inclined plane, page 1 ON 3-83 G359

G159.2 - - IP page 2-5 Placement: 5th inclined plane, page 2-5 ON 3-83 G459/G559
G159.5
G16 - Plane selec- no plane 3-27 G16 -
tion
G17 - Plane selec- Plane selection XY 3-28 G17/G20 G17/G20
tion
G17(...), - Plane selec- Expanded plane switching 3-30 - -
G18(...), tion G17/18/19( <Axis1>,<Axis2>,<Axis3>)
G19(...) The axes in parentheses open the WCS and
receive the meaning X, Y and Z.
Then the programmed plane is selected.
G17/18/19( )
Reset the workpiece coordinate system to the
default setting and then select the programmed
plane.

G18 - Plane selec- Plane selection ZX 3-28 G18/G20 G18/G21


tion
G184 - Drilling cycle Drilling cycle: Rigid tapping 3-68 G184

G19 - Plane selec- Plane selection YZ 3-28 G19/G20 G19/G22


tion
G20 - Plane selec- Free plane selection (WCS-independent) 3-32 - -
tion The placements have an effect on the WCS;
the plane is defined regardless of the WCS.

G33 - Thread Thread cutting 3-33 G33 G33

G40 - Path compen- Cutter path compensation OFF 3-39 G40 G40
sation
G41 - Path compen- Cutter path compensation to left of workpiece 3-39 G41 G41
sation
G42 - Path compen- Cutter path compensation to right of workpiece 3-39 G42 G42
sation
G43 - Insertion stra- Insertion strategy, arc 3-41 G68 G43
tegy
G44 - Insertion stra- Insertion strategy, intersection 3-41 G69 G44
tegy
G45 - Velocity, mil- Velocity, milling machine point of engagement 3-43 G64 G99
ling machine
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-11
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
G46 - Velocity, mil- Velocity, milling machine center 3-43 G65 G98
ling machine
G47 - Tool correction Switch on tool length correction 3-44 G146/8 G47

G47(..) - Tool correction G47(<L1 coord>,<L2 coord>,<L3 coord>) 3-44 G146/8 G47
G47(ActPlane)
Tool length correction ON with switching of
correction assignment.
G47( ): Tool length correction ON with correc-
tion assignment according to machine parame-
ters.
G48 - Tool correction Tool length correction OFF 3-44 G145/7ff. G48/G49

G53 - ZO All zero offsets OFF 3-46 -

G53.1-G53.5 - ZO page 1-5 Zero offset page 1-5 OFF 3-46 G53-G253

G54.1 G54 ZO page 1 1st zero offset, page 1 ON 3-46 G54-G254

G54.2-G54.5 - ZO page 2-5 1st zero offset, page 2-5 ON 3-46 G54-G254

G55.1 G55 ZO page 1 2nd zero offset, page 1 ON 3-46 G54-G254

G55.2-G55.5 - ZO page 2-5 2nd zero offset, page 2-5 ON 3-46 G55-G255

G56.1 G56 ZO page 1 3rd zero offset, page 1 ON 3-46 G54-G254

G56.2-G56.5 - ZO page 2-5 3rd zero offset, page 2-5 ON 3-46 G56-G256

G57.1 G57 ZO page 1 4th zero offset, page 1 ON 3-46 G54-G254

G57.2-G57.5 - ZO page 2-5 4th zero offset, page 2-5 ON 3-46 G57-G257

G58.1 G58 ZO page 1 5th zero offset, page 1 ON 3-46 G54-G254

G58.2-G58.5 - ZO page 2-5 5th zero offset, page 2-5 ON 3-46 G58-G258

G59.1 G59 ZO page 1 6th zero offset, page 1 ON 3-46 G54-G254

G59.2-G59.5 - ZO page 2-5 6th zero offset, page 2-5 ON 3-46 G59-G259

G61 Precise stop Precise stop 3-49 G61/G161 G61

G61(IPS...) - Precise stop Precise stop with precise stop window IPS1, 3-49 G61/G161 G61
IPS2 or IPS3
G62 - Precise stop Precise stop off 3-49 G62/G162 G62

G63 - Thread G63(M3/M4, S.../H...) F... Z... ... 3-51 G32 G63/G64
Rigid tapping
G70 - Inch/metric Inch programming, 3-53 G70 G70
affects the programmed path and length units,
feeds and acceleration.

G71 - Inch/metric Metric programming 3-54 G71 G71

G74 - - G74 X1 Y1 Z1 ... 3-55 G74/G374 G74


Traverse to reference point coordinates
A-12 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
G74(Home) - - G74(HOME) X1 Y1 Z1 3-55 G74/G374 G74
Traverse to reference point (real referencing,
also for asynchronous axes)

G75 - Probe Traverse to probe (cancel movement) 3-57 G75 -

G76 - - Traverse to fixed machine position (machine 3-58 G76 -


coordinates)

G77 - - G77 <Coord 1><Mode> <Coord n><Mode> 3-59 - G77


... F<Value>
Alternative syntax: REPOS
Asynchronous subroutines:
Repositioning individual coordinates

G80 - Drilling cycle Switch off drilling cycle 3-62 G80 -

G81 - Drilling cycle Drilling cycle: Drilling with retraction in rapid 3-62 G81 DEFINE
traverse
G82 - Drilling cycle Drilling cycle: Drilling with retraction in feed 3-63 G82 DEFINE

G83 - Drilling cycle Drilling cycle: Deep hole drilling 3-64 G83 DEFINE

G84 - Drilling cycle Drilling cycle: Floating tapping 3-65 G84 DEFINE

G85 - Drilling cycle Drilling cycle: Drilling out with retraction in 3-66 G85 DEFINE
rapid traverse
G86 - Drilling cycle Drilling cycle: Drilling out with retraction in feed 3-67 G86 DEFINE

G90 - Abs/Rel Absolute dimension programming 3-69 G90 G90

G91 - Abs/Rel Relative dimension programming 3-69 G91 G91

G93 - Feed prog. Time programming 3-70 G93 G93

G94 - Feed prog. Feed programming (per min) 3-71 G94 G94

G94(...) - Feed prog. G94({DF <Value>,} { DS1 <Value>, DS2 3-72 G94 G94
<Value>, ...} )
Incremental velocity programming with accel-
eration adaptation.

G95 - Feed prog. Feed programming (per rotation) 3-74 G95 G95

G96 - Spindle prog. G96{({<Reference axis>{,<Point of action>}})} 3-75 G96/G196 G96


Constant cutting speed
G97 - Spindle prog. Direct speed programming 3-75 G97 G97

GetAxis GAX - GAX(...) 4-51 G510


Get free axis in channel

GETERR - CPL GETERR(<Channel> [,<Category>],<Er- 5-54 GETERR -


ror>No> [,<Number>])
Supplies the error No., channel No. and error
category for the current errors.
GMSG - - GMSG(<Note text>) 2-23 (GMSG
Program notes in the user interface.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-13
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
GoAhead GOA - Jump forward 2-33

GoBack GOB - Jump backward 2-34

GoCond GOC - Conditional jump 2-35

GOTO - CPL GOTO <Jump target> 2-37 GOTO -


Unconditional program jumps to line number,
block number or label.
GoTo - - Branch absolute 2-36

HsBlkSwitch HSB - HSB(HS<X>=<Y>) 4-52 G575 -


Block transition on-the-fly using high-speed
signal

HsBlkSwitch(. HSB - HSB(...,HSSTOP=..) 4-56 G575 -


.HSSTOP=..) Block transition with cancellation using high-
speed signal

HWOC - - HWOC({CHAN<Channel No>},CRDNO 4-58 HWO- -


<Coord.No>,{ STEP<Incr>}) CON,
Online correction in workpiece coordinates ON HWO-
HWOCDIS({CHAN<Channel No>)} COFF
Online correction OFF; save values
HWO( )
Online correction OFF; delete values
IC(...) - - Local relative dimension programming, e.g. 3-69 IC(...) -
X=IC(5)

IF ENDIF - CPL IF <Condition> THEN <Routine> [ELSE <Alter- 2-39 IF ENDIF -


native routine>] ENDIF
Conditional jump to a routine or alternative rou-
tine.
InitMeas IME - IME(MpiAxis i) 4-44 G175 -
Initialize measurement on-the-fly.

INP# - CPL INP#(<n>,<Variable>[,<Variable>] [,...] [;]) 5-129 INP# -


Read access for a file.
INSDEP - - 3D radius correction immersion depth. 3-79 - -

INSTR - CPL INSTR(<Character string>,<String expres- 5-104 INSTR -


sion>[,<Starting point>])
Searches a <string expression>, starting at
<starting point>, for a <character string> and
outputs its starting position as an INTEGER
value.
INT - CPL <Integer number>=INT(<Real expression>) 2-62 INT -
Transforms the <real expression> to an <inte-
ger number> by cutting off the numbers after
the decimal point.
JogWCSSelect - - Selects the coordinates for jogging in work- 4-61 JogWCS- -
piece coordinates (set-up mode). Select
A-14 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
KvProg KVP CO progr. KVP(Y..., Y..., Z..., ...): CO programming ON 4-62 G14/G15 AXD
KVP( ): CO programming OFF

LEN - CPL LEN(<String expression>) 5-104 LEN -


Supplies the number of characters in a
STRING expression.

LEN - - LEN=<Value> 4-64 - -


Divides the traversing block into several partial
paths of equal length.

LFConf LFC - LFC({LL(...)}) 4-66 LFPON -


Set the laser performance control parameters
LFP LFP - LFP, LFP(1), LFP({LL(...)}) 4-66 LFPON, -
Laser performance control ON LFPOFF
LFP(0) Laser performance control OFF
LinDownFeed LND V profile Linear braking 4-69 G312 -

LinModZp LMZ - LMZ{(LinModAxis i)} 4-71 G105 -


Set linear modulo axis to zero
(Zp = zero point)

LinUpFeed LNU V profile Linear acceleration 4-68 G311 -

LJUST - CPL Switch to left-justified data output; effective 5-125 LJUST -


until the end of the program run.
M M - User-defined local subroutines

M0 M0 - Program halt 3-85 M0


M1 M1 - Conditional program halt 3-85 M1
M19, M119, - - Orientate spindle. 3-90 M19-M21
M219 9
M2 M2 - End of main program 3-86 M2
M3, M103, - - Spindle clockwise rotation, 3-87 M3 -
M203, spindle clockwise rotation with coolant ON M203,
M13, M113, M13-M21
M213 3
M30 M30 - End of main program 3-86 M30
M4, M104, - - Spindle counterclockwise rotation, 3-88 M4 -
M204, spindle counterclockwise rotation with coolant M204,
M14, M114, ON M14-M21
M214 4
M40, M140, - - Automatic gear range selection 3-92 M40-M24
M240 0
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-15
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
M41 - M44, - - Manual gear range selection 3-93 M41 -
M141 - M144, M44,
M241 - M244 M141-M14
4
M241-M24
4
M48, M148, - - Disengage gear range. 3-94 M48-M24
M248 8
M5, M105, - - Spindle stop 3-89 M5 -
M205 M205
MainSp MSP - Select main spindle, e.g. for G33 and G95 4-72 MAINSP SPF

MCODS - CPL MCODS(<Type>,<Channel>,<Ver- 5-59 MCODS -


sion>,<Buffer>,<Size>[,<P1>])
Calls Motion Control data services of the NCS.
This allows the data and states to be read from
the NC.

MCOPS - CPL MCOPS(<Fct>,<Channel>[[,[<P1>][,[<P2>], 5-88 MCOPS -


[<P3>]]],<P4>]))
Calls Motion Control process services of the
NCS. This allows channels in the NC to be
controlled.

MID$ - CPL MID$(<String expression>,<Starting point> 5-102 MID$ -


[,<No. of characters>])
Takes a part of the STRING expression and
outputs it as text. The result can be transferred
to a STRING variable or to an appropriately
sized character field.
MID$(<Character field>,<Starting point>[,<No.
of characters>])
Overwrites portions of a character field.
Mirror MIR Mirror imaging MIR(X1, Y1,Z1,...): Mirroring of coordinates 4-73 G38/G39
ON
MIR( ): Mirroring of coordinates OFF

MMC - CPL MMC(<CPL-Var1>[,<CPL-Var2>...[,<CPL- 5-142 MMC -


VarN>]...])
Sends information regarding the program run-
ning time from a subroutine to a client and
waits for the result of this client.

MPOS - CPL MPOS(<Axis selection>[,<Axis type>[,<Chan- 5-9 MPOS -


nel>]])
Transfers the current interpolated command
position, based on the zero point of the MCS
machine coordinate system.

MSG - - MSG(<Note text>) 2-23 (MSG


Program notes in the user interface.
A-16 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
NCF - CPL NCF(<NC function>) 5-37 NCF -
Transfers the syntax of the active NC function
within the NC modal group of the <NC func-
tion>.
Nibble NIB Punch NIB( NUM...): Nibble processing ON 4-76 G662/G660 -
NIB( ): Nibble processing OFF

NJUST - CPL Premature reset from left-justified data output 5-125 NJUST -
to formatted output.
NOT - CPL NOT <Expression> 2-64 NOT -
Negation of a BOOLEAN expression / bitwise
negation of an INTEGER expression.

NUL - CPL <Variable> = NUL 2-61 NUL -


Delete a variable.
NUM - - NUM=<Value> 4-78 - -
Divides the traversing block into a defined
number of partial paths of equal length.

O O - O(...) Orientation movement for a tool 4-79 O(...) -

OFFSTOPA - - Channel synchronization command: deletes 2-84


the programmed AND stop conditions in the
control channel (ASTOPA, BSTOPA,
WSTOPA).
OFFSTOPO - - Channel synchronization command: deletes 2-84
the programmed OR stop conditions in the
control channel (ASTOPO, BSTOPO,
WSTOPO).
Omega - - Omega address 3-96

OPENR - CPL OPENR(<n>,<Prog.name>[,<Record length>]) 5-119 OPENR -


Opens a file so that it can be read.
OPENW - CPL OPENW(<n>,<Prog.name>[.<Length>][,<Prog. 5-119 OPENW -
comment>][,<Record length>])
Opens a file so that it can be written.

OR - CPL <Expression> OR <Expression> 2-64 OR -


Binary link between two BOOLEAN / INTEGER
expressions using the OR function.
OvrDis OVD Feed 100% Feed potentiometer OFF 4-90 G63 -

OvrEna OVE Feed 100% Feed potentiometer ON 4-90 G66 -

P P - Subroutine call 2-26


(also possible directly, without P)
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-17
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
PathAcc PAC Path accel. PAC(ACC... | UP..., DOWN ...) : switch on 4-91 G106/G107 ACC
PAC( ): switch off
Path acceleration programming, either sepa-
rately for acceleration and braking or com-
bined.

PCS - CPL PCS(<Coordinate>[,<Selection type>]) 5-6 CPOS -


Supplies the last programmed absolute posi-
tion of a coordinate.

PDIM - CPL PDIM <Parameter name>(<Field size>) 2-31 PDIM -


This must be used if a subroutine
D is to be called using a string constant as a
transfer parameter and
D the calling program is selected without
links.

PMT - CPL PMT(<Coord.selec- 5-28 -


tion>,<Pl.code>[,[<Pl.page>][,[<Table>][,<Unit>
]]])
Read and write access to an XML placement
table.

PmTSel PMS - PMS(<Placement table name>) 4-95 G22 ID -


Placement table selection
PMV - CPL PMV(<Coord.selection>[,<Pl. page>]) 5-27 -
Supplies the effective placement value for a
coordinate.
PolarPol POP PolarPol POP(X...,Y...,Z...): Set pole 4-96 -
POP( ): Pole at origin
Pole for polar coordinate programming.

PoleSet PLS Set pole PLS(X..., Y..., Z...): Set pole 4-101 G37/G39
PLS( ): Pole at origin
Pole for help in making mirroring/rotation en-
tries.

PosDepHSOut PHS - PHS(<Mode>{,{<Distance>}{,<Duration>}}) 4-93 PDHSO -


Programmable position-dependent high-speed
output

PosMode PMD Positioning PMD(A..., B...) : switch positioning type 4-102 G151/G150 G36ff.
type PMD( ): Positioning type acc. to machine pa-
rameters
Positioning type for endless axes

PPOS - CPL PPOS(<Axis selection>[,<Axis type>]) 5-14 PPOS -


Queries the actual axis position for the switch-
ing time of the probe.
PrecProg PRP Precision PRP(DIST... | EPS...) : Precision check ON 4-104 G328/G329 -
check PRP( ): Precision check OFF
A-18 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
PRN# - CPL PRN#(<n>,[<Expression>][,<Expression][,<Ex- 5-125 PRN# -
pression>][,...][;])
Write access for a file.

PROBE - CPL PROBE(<Axis selection>[,<Axis type>]) 5-13 PROBE -


Queries the axis position for the switching time
of the probe, based on the axis zero point
coordinates of the MCS.
PtBlkEnd PTE Punching PTE(X..., Y..., Z..., ...) 4-106 G612 -
stroke Stroke trigger at end of block
PtDefault PTD Punching Stroke trigger according to parameters 4-108 G610 -
stroke
PtInpos PTI Punching PTI(X..., Y..., Z..., ...) 4-109 G611 -
stroke Stroke trigger at Inpos (Pt = punch time)
Punch PUN Punch PUN( NUM...): Punch processing ON 4-110 G661/G660 -
PUN( ): Punch processing OFF
RadProg RAD Diam./Rad. Radius programming 4-35 RAD G15

RedTorque RDT - RDT(<Axis1>{,<Axis2>{, ...}}) 4-112 G177 -


Specification of the torque for torque reduction

REM - CPL REM <Comment text> 2-22 REM -


Program comments.
RemAxis RAX - RAX(...) 4-113 G512 FAX
remove axis from channel
RemLogName RLN - RLN(...) 4-114 G516 -
Remove logical axis name

REPEAT - CPL REPEAT <Routine> UNTIL <Condition> 2-43 REPEAT -


Loop construction with query of the cancella-
tion condition after the routine has been pro-
cessed the first time.
REPOSTP - - REPOSTP(<Point>) 4-115
Asynchronous subroutines:
Define point of return to path in asynchronous
subroutine
REWRITE - CPL REWRITE(<n>) 5-128 REWRITE -
Overwrite an existing file.
Rotate RED Rotate ROT(<Angle>): Coordinate rotation ON 4-116 G38/G39
ROT( ): Coordinate rotation OFF
ROTAX - - Define the rotary axis for vector orientation 4-79 ROTAX -
ROUND - CPL <Integer number>=ROUND(<Real expres- 2-63 Round -
sion>)
Transform a REAL expression to an INTEGER
number by rounding up or down.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-19
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
RoundEps RNE Cham./Round. RNE<Value> Rounding ON 4-118 G34/G35 -
RNE( ): Rounding OFF
Rounding with defined contour shift.

Rounding RND Cham./Round. RND(<Value>): Rounding ON 4-119 G134/G35 -


RND( ): Rounding OFF
Rounding with defined rounding radius

S S - S<Number>=<Value> 3-97 S
S<Value>
Program spindle speed

Scale SCL Scaling SCL(X..., Y..., Z..., ...):


Coordinate scaling 4-120 G38/G39 G78/G79
ON
SCL( ): Coordinate scaling OFF

SCL - CPL SCL(<SCL-Selection>[,<Selection>[,<Selec- 5-35 SCL -


tion type>]])
Supplies the last-programmed parameter of
functions PLS and ROT (polar coordinates,
scaling factors and turning angle) for the cur-
rent channel.
SCS - CPL SCS(<Axis index>,<ID type>,<ID No>[,<Res- 5-38 SCS -
Var>])
Read access to SERCOS drive parameters of
the active parameter set.
SCSL - CPL SCSL(<Axis index>,<ID type>,<ID No>,<File 5-39 SCSL -
name>[,<ResVar>])
Create a file for SERCOS parameter lists.

SD - CPL SD(<Group>[,<Index1>[,<Index2>[,<In- 5-41 SD -


dex3>]]])
Read active system data of the NC control.

SDR - CPL SDR(<Group>[,<Index1>[,<Index2>]]) 5-47 SDR -


Read active system data of the NC control in
REAL format.

SEEK - CPL SEEK(<n>,<k>[,<o>]) 5-134 SEEK -


Positions the file indicator on the <k>-th record
of a random file or on the <k>-th byte of a se-
quential file.
SelCrdCouple SCC - SCC(SC<Channel>, CL(Q1>,<Z1>,{...})): 4-122 - -
Selective additive coordinate coupling ON
SCC( ): All coordinate couplings OFF

SETERR - CPL Generate a runtime error after evaluating 2-58 - -


ERRNO.
SetPos SPS - Set program position 4-123 G92 G52

SETWARN - CPL Generate a warning after evaluating ERRNO. 2-59 - -


A-20 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
Shift SHT - SHT(X..., Y ..., Z ..., ...) : Contour offset 4-124 G60/G67 -
ON
SHT( ): Contour offset OFF

SIN - CPL <Function value> = SIN(<Input value>) 2-63 SIN -


Use the sine function for the input value.
Sin2DownFeed S2D V profile Sin2-shaped braking 4-69 G316 -

Sin2UpFeed S2U V profile Sin2-shaped acceleration 4-68 G315 -

SinDownFeed SND V profile Sin-shaped braking 4-69 G314 -

SinUpFeed SNU V profile Sin-shaped acceleration 4-68 G313 -

Smax SMX - SMX(<Value>) 4-125 G192 G92


Maximum speed for the spindle.
Smin SMN - SMN(<VALUE>) 4-125 G292 -
Minimum speed for the spindle.
SpAdmin SPA - SPA(Si=0|1) 4-126 - -
Conditionally release a reserved spindle or
transfer to another channel.

SpCouple SPC_ - SPC_WAIT(CP=1-4) 4-133 - -


_Wait WAIT Wait for synchronous mode of the specified
group of coupled spindles.

SpCouple SPCC - SPCC(CP=1-4, MA=<Master>, Si=1, Sj=1, ...) 4-127 - -


Config Define group of coupled spindles,
delete or add following spindles,
cancel group of coupled spindles.

SpCouple SPCP - SPCP(S1=<Displacement>, S2=<Displace- 4-130 - -


PosOffs ment>, ...
{POSVEL<Speed>)
Define angle displacement for the active group
of coupled spindles.

SpCouple SPCP - SPCP_WAIT(CP=1-4) 4-131 - -


PosOffs_Wait _WAIT Wait for angle displacement for the pro-
grammed group of coupled spindles.

SpCoupleDist SPCD - SPCD(S1=<Distance>, S2=<Distance>, ... 4-128 - -


Define angle distance for groups of coupled
spindles.

SpCoupleErr SPCE - SPCE(S1=<Window>, S2=<Window>, ...) 4-129 - -


Win Define synchronization error window for groups
of coupled spindles.

SpCouple- SPCS - SPCS(S1=<Window>, S2=<Window>, ...) 4-132 - -


SyncWin Define synchronization error window for groups
of coupled spindles.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-21
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
SPG - - SPG<Group>(<Numbers>) 4-134
SPGALL(0)
Define/cancel spindle groups

SpindleToAxis STA - STA(...) 4-135


Switch spindle to axis mode.
SplineDef SDF - Specify a spline variant. 4-136

Split SPLI - Split({<Mode>}{,<Part length>}) 4-138


T Divides movement blocks into several partial
paths if they exceed a certain length.

SpMode SPM - SPM(S1=0|1, S2=0|1, ...) 4-139


Manually switch spindle drive interface be-
tween velocity mode and position mode

SPOS - CPL SPOS(<Axis selection>) 5-10 SPOS -


Transfers the current axis command value of a
physical axis.

SPV - - SPV [ <Perm.CPL-Var.> = <Simple CPL ex- 2-78


pression> ]
Channel synchronization command: When the
program is executed, the permanent CPL vari-
able is written.

SPVE - - SPV E[ <Perm.CPL-Var.> = <CPL expression> 2-78


]
Channel synchronization command: When the
program is executed, the permanent CPL vari-
able is written. The CPL expression can in-
clude CPL commands, but is already triggered
during the block preparation time.
SQRT - CPL <Function value> = SQRT(<Input value>) 2-63 SQRT -
Use the square root function on the <input
value>.

SSPG - - SSPG<Group>=<Value> 3-97 SSPG


Speed specification for spindle group; also see
S<value>

StatToolOri STO - STO(PHI ..., THETA ..., PSI ...) 4-140


Static tool orientation
STR$ - CPL STR$([<Format string>,]<Value>) 5-106 STR$ -
Converts numeric expression <Value> into a
character string that can be assigned to only
one character field.
<Format string> can be used to output the
character string in formatted form.
TAN - CPL <Function value> = TAN(<Input value>) 2-63 TAN -
Use the tangent function on the <input value>.
A-22 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
TangTool TTL Tool orient. TTL(TAX..., SYM..., ANG..., IA..., PLC...): 4-142 G131/G130 -
Tangential tool guidance ON
TTL( ): Tangential tool guidance OFF

TangToolOri TTO Tangential tool TTO(SYM..., ANG...): Tangential tool orienta- 4-145 G630/G631 -
orient. tion ON
TTO( ): Tangential tool orientation OFF

TappSp TSP - TSP(CAXi, ..., GRPj, ...) 4-147 G532 SPF


Spindle selection for rigid tapping.
TcsDef TCS - Explicitly specify the position of the tool coordi- 4-148 TcsDef -
nate system (implicit tool length correction
combined with corresponding axis transforma-
tion).

TCV - CPL TCV(<Value selection>[,<Correction selec- 5-22 TC -


tion>])
Supplies the last-programmed tool correction
values.
ThreadSet TST Thread Thread cutting, auxiliary functions 4-151

TIME - CPL <String variable> = TIME 5-53 TIME -


Assigns the time to a STRING variable in the
form HH.MM.SS.
Trans TRS Program coor- TRS( X ..., Y ..., Z ..., ...) : Program coordinate 4-153 G60/G67
dinate offset offset ON
TRS( ): Program coordinate offset OFF

TRIM$ - CPL TRIM$(<Character string>) 5-108 TRIM$ -


TRIM$(<Character string>,L)
TRIM$(<Character string>,R)
In the assignment of a character field range to
a STRING variable or a character field, sup-
plies a character string without a preceding
(index L) or following (index R) space. If
there is no index, both preceding and following
spaces are hidden.
TRUE - CPL <Boolean variable> = TRUE LEERER TRUE
MERKER -
Truth value of a BOOLEAN variable
VAL - CPL VAL(<String expression>) 5-107 VAL -
Returns the numeric value of the STRING ex-
pression.

VERSINF$ - CPL VERSINF$(<Index1>[,<Index2>]) 5-122


Calls administration data, e.g. the software ver-
sion.

VirtAxisPos VAP - Sets the axis position of virtual synchronous 4-155 - -


axes in the current channel.
WAIT - - WAIT in NC block (like CPL WAIT) 2-69
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-23
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
WAIT - CPL WAIT(no parameter) 2-69 WAIT -
Stops block preparation until all the blocks pro-
grammed before WAIT have been processed.
WAIT(,<Waiting time>)
Stops block processing until a specified period
has elapsed.
WAIT(BITIF(...))
Stops block processing until a certain status
occurs on the PLC-NC bit interface.
WAITA - - WAITA[BITIF(<Parameter>){=<Status>} 2-74 WAITA
{,...}{,<Timeout>}]
Channel synchronization command: When the
program is run, a wait occurs until all queried
interface signals exist or until the timeout has
elapsed.
WaitAxis WAX - WAX(...) 4-156 G511 GAX ?
Wait until the axis is released and then incor-
porate it into the channel.

WAITO - - WAITO[BITIF(<Parameter>){=<Status>} 2-74 WAITO


{,...}{,<Timeout>}]
Channel synchronization command: When the
program is run, a wait occurs until one of the
queried interface signals exists or until the
timeout has elapsed.

WHILE - CPL WHILE <Condition> DO <Routine> END 2-44 WHILE -


Loop construction with query of the cancella-
tion condition before the loop is processed the
first time.
WPOS - CPL WPOS(<Axis selection>[,<Selection 5-8 WPOS -
type>[,<Channel>]])
Transfers the interpolated command position,
based on the workpiece zero point of the cur-
rent WCS.

WPV - - WPV[<Perm.CPL-Var.><Compar.op.><Simp. 2-76


CPL-Expr.>{,<Timeout>]
Channel synchronization command: When the
program is run, a wait occurs until the expres-
sion is fulfilled or until the timeout has elapsed.

WPVE - - WPVE[<Perm.CPL-Var.><Compar.op.><CPL- 2-76


Expr.>{,<Timeout>]
Channel synchronization command: When the
program is run, a wait occurs until the expres-
sion is fulfilled or until the timeout has elapsed.
The CPL expression can include CPL com-
mands, but is already triggered during the
block preparation time.
A-24 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
WriteId WID - WID(S-0-0104, X..., Y..., Z..., ...) 4-157 G900 AXD
Writing SERCOS parameters
WSTOPA - - WSTOPA[<Channel No.>, 2-82
<Cond.1>{,<Cond.2>}
{...{,<Cond.8>}...}]
Channel synchronization command: The chan-
nel to be controlled is stopped as long as all
the conditions are fulfilled. The conditions refer
to the workpiece positions, e.g. Z > 20.
WSTOPO - - WSTOPO[<Channel No.>, 2-82
<Cond.1>{,<Cond.2>}
{...{,<Cond.8>}...}]
Channel synchronization command: The chan-
nel to be controlled is stopped as long as one
of the conditions is fulfilled. The conditions re-
fer to the workpiece positions, e.g. Z > 20.

XOR - CPL <Expression> XOR <Expression> 2-64 XOR -


Binary link between two BOOLEAN / INTEGER
expressions using the EXCLUSIVE-OR func-
tion.
XTAB - CPL XTAB(<Table>,<Substructure>) 5-30 TDA -
Read/write access to any XML table which can
also be user-defined.

ZOT - CPL ZOT(<Column selection>,<ZO code>[,[<ZO 5-18 FXC -


page>][,[<Table>][,<Unit>]]])
Read/write access to any XML zero offset
table.
ZoTSel ZOS - ZOS(<ZO name>) 4-160 G22 V O
Selection of a zero offset table.

ZOV - CPL ZOV(<Axis selection>[.<ZO page>]) 5-18 FXC -


Supplies the effective ZO values for an axis /
machine coordinate.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-25
and Controls

Appendix

Arranged alphanumerically according to group:


NC function name Group Designation / Explanation Page Function in
Long Short (- means: PNC MTC
form form active
blockwise)
; - - Comment: skip the rest of the line 2-21

() - - Comment: skip the content within the paren- 2-21


theses
(MSG - - output message text 2-23

/ - - Skip block 2-38

// - - Comment 2-21

AC(...) - - Local absolute dimension programming, e.g. 3-69 AC(...) -


X=AC(10)
Area ARA - Area(<BNr>,<Sta>{,<Mod>,{<P1>},{<P2>},{<D 4-2 - -
1>},{<D2>}})
Defines, activates or deactivates up to 10 rec-
tangular, two-dimensional dead or working
ranges with axis-parallel boundaries.

ASPCLR - - ASPCLR(<SR No>) 4-5 - -


Asynchronous subroutines: log off
ASPDIS - - ASPDIS(<SR No>) 4-6 - -
Asynchronous subroutines: switch off
ASPENA - - ASPENA(<SR No>) 4-6 - -
Asynchronous subroutines: switch on
ASPRTP - - ASPRTP(<SR No>,<Point>) 4-7 - -
Asynchronous subroutines: define point of re-
turn to path

ASPSET - - ASPSET(<SR No>,<SR name>{,<Flags>}) 4-8 - -


Asynchronous subroutines: log in
ASPSTA - - ASPSTA(<SR No>{,<Channel No>}) 4-9 - -
Asynchronous subroutines: trigger
AssLogName ALN - ALN(...) 4-10 G515 -
Assign logical axis name
ASTOPA - - ASTOPA[<Channel No.>, <Cond.1> 2-79 - -
{,<Cond.2>}{...{,<Cond.8>}...}]
Channel synchronization command: The chan-
nel to be controlled is stopped as long as all
the conditions are fulfilled. The conditions refer
to the axis positions, e.g. Z > 20
ASTOPO - - ASTOPO[<Channel No.>, <Cond.1> 2-79 - -
{,<Cond.2>}{...{,<Cond.8>}...}]
Channel synchronization command: The chan-
nel to be controlled is stopped as long as one
condition is fulfilled. The conditions refer to the
axis positions, e.g. Z > 20
A-26 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
ATCAL - - ATCAL(<File>,<OptData>,<mask> 4-11
{,<Info>}{,<NumIt>})
Calibration of axis kinematics: optimize param-
eters.
ATFWD - - ATFWD(<Coord>,<AxCoord>{,<ParData>}) 4-13
Calibration of axis kinematics: convert parame-
ters

ATGET - - ATGET(<ParData>{,<ATrafNr>}) 4-14


Calibration of axis kinematics: read parameter
from NC

ATPUT - - ATPUT(<ParData>{,<ATrafNr>}) 4-15


Calibration of axis kinematics: write parameter
to NC

AUXFUNC - - Execute active auxiliary functions of all groups 4-16

AxAccSave AAS - Save current axis acceleration. 4-17 - -

AxisToSpindle ATS - ATS(<axis name>) 4-22


Switch axis to spindle mode.
BlkNmb BNB - BlkNmb(<Disp>) 2-72 PREPNUM -
Limits the number of program blocks that are
read in and viewed by block preparation.

BSTOPA - - BSTOPA[<Channel No.>, <Cond.1> 2-81 - -


{,<Cond.2>}{...{,<Cond.8>}...}]
Channel synchronization command: The chan-
nel to be controlled is stopped as long as all
the conditions are fulfilled. The conditions refer
to the basic workpiece positions, e.g. Z > 20
BSTOPO - - BSTOPO[<Channel No.>, <Cond.1> 2-81 - -
{,<Cond.2>}{...{,<Cond.8>}...}]
Channel synchronization command: The chan-
nel to be controlled is stopped as long as one
condition is fulfilled. The conditions refer to the
basic workpiece positions, e.g. Z > 20
COFFS - - Contour shift for 3D radius correction 3-79 - -

DcTSel DCS - DCS({<Path>}<File name>) 4-33 G22 K -


Activation of a D-correction table.
DefAxis DAX - Create default axis configuration 4-34 G513 -

DistCtrl DCR - DCR(1) Height regulation for digitization, 4-37 DistCtrl -


ON acc. to machine param.
DCR(<Fct>) ON with autonomous config.
data
DCR( ) Height regulation OFF

EndPosCouple EPC - EPC(<M-coord>,<S-coord>,<Factor>): 4-39 - -


End position coupling ON
EPC( ): End position coupling OFF
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-27
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
F F - F-address for G93, G94, G95 3-95 F

FA FA - Velocity for asynchronous axes. 3-96 FA


FsMove FSM - Driving against a fixed stop 4-48 G475 G75
(Fs = fixed stop)
FsProbe FSP - Measurement at fixed stop 4-46 G475 G75

FsReset FSR - Cancel fixed stop 4-48 G477 G76

FsTorque FST - Torque for fixed stop 4-48 G476 AXD

G - - User-defined local subroutines

G04 G4 - G4(F..) Dwell time in seconds 3-13 G04/G104 G04


G4(S...) Dwell time in spindle rotations; refer-
ence spindle is the main spindle (MainSp)

G74 - - G74 X1 Y1 Z1 ... 3-55 G74/G374 G74


Traverse to reference point coordinates
G74(Home) - - G74(HOME) X1 Y1 Z1 3-55 G74/G374 G74
Traverse to reference point (real referencing,
also for asynchronous axes)

G76 - - Traverse to fixed machine position (machine 3-58 G76 -


coordinates)

G77 - - G77 <Coord 1><Mode> <Coord n><Mode> 3-59 - G77


... F<Value>
Alternative syntax: REPOS
Asynchronous subroutines:
Repositioning individual coordinates

GetAxis GAX - GAX(...) 4-51 G510


Get free axis in channel

GMSG - - GMSG(<Note text>) 2-23 (GMSG


Program notes in the user interface.
GoAhead GOA - Jump forward 2-33

GoBack GOB - Jump backward 2-34

GoCond GOC - Conditional jump 2-35

GoTo - - Branch absolute 2-36

HsBlkSwitch HSB - HSB(HS<X>=<Y>) 4-52 G575 -


Block transition on-the-fly using high-speed
signal

HsBlkSwitch(. HSB - HSB(...,HSSTOP=..) 4-56 G575 -


.HSSTOP=..) Block transition with cancellation using high-
speed signal
A-28 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
HWOC - - HWOC({CHAN<Channel No>},CRDNO 4-58 HWO- -
<Coord.No>,{ STEP<Incr>}) CON,
Online correction in workpiece coordinates ON HWO-
HWOCDIS({CHAN<Channel No>)} COFF
Online correction OFF; save values
HWO( )
Online correction OFF; delete values
IC(...) - - Local relative dimension programming, e.g. 3-69 IC(...) -
X=IC(5)
InitMeas IME - IME(MpiAxis i) 4-44 G175 -
Initialize measurement on-the-fly.

INSDEP - - 3D radius correction immersion depth. 3-79 - -

JogWCSSelect - - Selects the coordinates for jogging in work- 4-61 JogWCS- -


piece coordinates (set-up mode). Select
LEN - - LEN=<Value> 4-64 - -
Divides the traversing block into several partial
paths of equal length.

LFConf LFC - LFC({LL(...)}) 4-66 LFPON -


Set the laser performance control parameters
LFP LFP - LFP, LFP(1), LFP({LL(...)}) 4-66 LFPON, -
Laser performance control ON LFPOFF
LFP(0) Laser performance control OFF
LinModZp LMZ - LMZ{(LinModAxis i)} 4-71 G105 -
Set linear modulo axis to zero
(Zp = zero point)

M M - User-defined local subroutines

M0 M0 - Program halt 3-85 M0


M1 M1 - Conditional program halt 3-85 M1
M19, M119, - - Orientate spindle. 3-90 M19-M21
M219 9
M2 M2 - End of main program 3-86 M2
M3, M103, - - Spindle clockwise rotation, 3-87 M3 -
M203, spindle clockwise rotation with coolant ON M203,
M13, M113, M13-M21
M213 3
M30 M30 - End of main program 3-86 M30
M4, M104, - - Spindle counterclockwise rotation, 3-88 M4 -
M204, spindle counterclockwise rotation with coolant M204,
M14, M114, ON M14-M21
M214 4
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-29
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
M40, M140, - - Automatic gear range selection 3-92 M40-M24
M240 0
M41 - M44, - - Manual gear range selection 3-93 M41 -
M141 - M144, M44,
M241 - M244 M141-M14
4
M241-M24
4
M48, M148, - - Disengage gear range. 3-94 M48-M24
M248 8
M5, M105, - - Spindle stop 3-89 M5 -
M205 M205
MainSp MSP - Select main spindle, e.g. for G33 and G95 4-72 MAINSP SPF

MSG - - MSG(<Note text>) 2-23 (MSG


Program notes in the user interface.
NUM - - NUM=<Value> 4-78 - -
Divides the traversing block into a defined
number of partial paths of equal length.

O O - O(...) Orientation movement for a tool 4-79 O(...) -

OFFSTOPA - - Channel synchronization command: deletes 2-84


the programmed AND stop conditions in the
control channel (ASTOPA, BSTOPA,
WSTOPA).
OFFSTOPO - - Channel synchronization command: deletes 2-84
the programmed OR stop conditions in the
control channel (ASTOPO, BSTOPO,
WSTOPO).
Omega - - Omega address 3-96
P P - Subroutine call 2-26
(also possible directly, without P)

PmTSel PMS - PMS(<Placement table name>) 4-95 G22 ID -


Placement table selection
PosDepHSOut PHS - PHS(<Mode>{,{<Distance>}{,<Duration>}}) 4-93 PDHSO -
Programmable position-dependent high-speed
output

RedTorque RDT - RDT(<Axis1>{,<Axis2>{, ...}}) 4-112 G177 -


Specification of the torque for torque reduction
RemAxis RAX - RAX(...) 4-113 G512 FAX
remove axis from channel
RemLogName RLN - RLN(...) 4-114 G516 -
Remove logical axis name
A-30 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
REPOSTP - - REPOSTP(<Point>) 4-115
Asynchronous subroutines:
Define point of return to path in asynchronous
subroutine
ROTAX - - Define the rotary axis for vector orientation 4-79 ROTAX -
S S - S<Number>=<Value> 3-97 S
S<Value>
Program spindle speed

SelCrdCouple SCC - SCC(SC<Channel>, CL(Q1>,<Z1>,{...})): 4-122 - -


Selective additive coordinate coupling ON
SCC( ): All coordinate couplings OFF

SetPos SPS - Set program position 4-123 G92 G52

Shift SHT - SHT(X..., Y ..., Z ..., ...) : Contour offset 4-124 G60/G67 -
ON
SHT( ): Contour offset OFF

Smax SMX - SMX(<Value>) 4-125 G192 G92


Maximum speed for the spindle.
Smin SMN - SMN(<VALUE>) 4-125 G292 -
Minimum speed for the spindle.
SpAdmin SPA - SPA(Si=0|1) 4-126 - -
Conditionally release a reserved spindle or
transfer to another channel.

SpCouple SPC_ - SPC_WAIT(CP=1-4) 4-133 - -


_Wait WAIT Wait for synchronous mode of the specified
group of coupled spindles.

SpCouple SPCC - SPCC(CP=1-4, MA=<Master>, Si=1, Sj=1, ...) 4-127 - -


Config Define group of coupled spindles,
delete or add following spindles,
cancel group of coupled spindles.

SpCouple SPCP - SPCP(S1=<Displacement>, S2=<Displace- 4-130 - -


PosOffs ment>, ...
{POSVEL<Speed>)
Define angle displacement for the active group
of coupled spindles.

SpCouple SPCP - SPCP_WAIT(CP=1-4) 4-131 - -


PosOffs_Wait _WAIT Wait for angle displacement for the pro-
grammed group of coupled spindles.

SpCoupleDist SPCD - SPCD(S1=<Distance>, S2=<Distance>, ... 4-128 - -


Define angle distance for groups of coupled
spindles.

SpCoupleErr SPCE - SPCE(S1=<Window>, S2=<Window>, ...) 4-129 - -


Win Define synchronization error window for groups
of coupled spindles.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-31
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
SpCouple- SPCS - SPCS(S1=<Window>, S2=<Window>, ...) 4-132 - -
SyncWin Define synchronization error window for groups
of coupled spindles.

SPG - - SPG<Group>(<Numbers>) 4-134


SPGALL(0)
Define/cancel spindle groups

SpindleToAxis STA - STA(...) 4-135


Switch spindle to axis mode.
SplineDef SDF - Specify a spline variant. 4-136

Split SPLI - Split({<Mode>}{,<Part length>}) 4-138


T Divides movement blocks into several partial
paths if they exceed a certain length.

SpMode SPM - SPM(S1=0|1, S2=0|1, ...) 4-139


Manually switch spindle drive interface be-
tween velocity mode and position mode

SPV - - SPV [ <Perm.CPL-Var.> = <Simple CPL ex- 2-78


pression> ]
Channel synchronization command: When the
program is executed, the permanent CPL vari-
able is written.

SPVE - - SPV E[ <Perm.CPL-Var.> = <CPL expression> 2-78


]
Channel synchronization command: When the
program is executed, the permanent CPL vari-
able is written. The CPL expression can in-
clude CPL commands, but is already triggered
during the block preparation time.
SSPG - - SSPG<Group>=<Value> 3-97 SSPG
Speed specification for spindle group; also see
S<value>

StatToolOri STO - STO(PHI ..., THETA ..., PSI ...) 4-140


Static tool orientation
TappSp TSP - TSP(CAXi, ..., GRPj, ...) 4-147 G532 SPF
Spindle selection for rigid tapping.
TcsDef TCS - Explicitly specify the position of the tool coordi- 4-148 TcsDef -
nate system (implicit tool length correction
combined with corresponding axis transforma-
tion).

VirtAxisPos VAP - Sets the axis position of virtual synchronous 4-155 - -


axes in the current channel.
WAIT - - WAIT in NC block (like CPL WAIT) 2-69
A-32 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
WAITA - - WAITA[BITIF(<Parameter>){=<Status>} 2-74 WAITA
{,...}{,<Timeout>}]
Channel synchronization command: When the
program is run, a wait occurs until all queried
interface signals exist or until the timeout has
elapsed.
WaitAxis WAX - WAX(...) 4-156 G511 GAX ?
Wait until the axis is released and then incor-
porate it into the channel.

WAITO - - WAITO[BITIF(<Parameter>){=<Status>} 2-74 WAITO


{,...}{,<Timeout>}]
Channel synchronization command: When the
program is run, a wait occurs until one of the
queried interface signals exists or until the
timeout has elapsed.

WPV - - WPV[<Perm.CPL-Var.><Compar.op.><Simp. 2-76


CPL-Expr.>{,<Timeout>]
Channel synchronization command: When the
program is run, a wait occurs until the expres-
sion is fulfilled or until the timeout has elapsed.

WPVE - - WPVE[<Perm.CPL-Var.><Compar.op.><CPL- 2-76


Expr.>{,<Timeout>]
Channel synchronization command: When the
program is run, a wait occurs until the expres-
sion is fulfilled or until the timeout has elapsed.
The CPL expression can include CPL com-
mands, but is already triggered during the
block preparation time.
WriteId WID - WID(S-0-0104, X..., Y..., Z..., ...) 4-157 G900 AXD
Writing SERCOS parameters
WSTOPA - - WSTOPA[<Channel No.>, 2-82
<Cond.1>{,<Cond.2>}
{...{,<Cond.8>}...}]
Channel synchronization command: The chan-
nel to be controlled is stopped as long as all
the conditions are fulfilled. The conditions refer
to the workpiece positions, e.g. Z > 20.
WSTOPO - - WSTOPO[<Channel No.>, 2-82
<Cond.1>{,<Cond.2>}
{...{,<Cond.8>}...}]
Channel synchronization command: The chan-
nel to be controlled is stopped as long as one
of the conditions is fulfilled. The conditions re-
fer to the workpiece positions, e.g. Z > 20.
ZoTSel ZOS - ZOS(<ZO name>) 4-160 G22 V O
Selection of a zero offset table.
G140 - 3D radius corr. 3D radius correction OFF 3-79 G141
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-33
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
G141 - 3D radius corr. 3D radius correction to left of contour 3-79 G141

G142 - 3D radius corr. 3D radius correction to right of contour 3-79 G142

G90 - Abs/Rel Absolute dimension programming 3-69 G90 G90

G91 - Abs/Rel Relative dimension programming 3-69 G91 G91

AxAcc AAC Axis accel. AAC(X..., Y..., Z..., ...): switch on 4-17 G6/G7 -
AAC(1): switch on with saved
setting
AAC( ): switch off
Program axis acceleration

AxCouple AXC Axis coupling AXC(<Master>,<Slave1>(...),<Slave2>(...),...): 4-19 G590/G591


Activate axis coupling
AXC( ) : Deactivate axis coupling

CoupleSpline- CST Axis coupling CST(STAB(...)) 4-32 G582


Tab Generate a spline coupling table
Coord CRD Axis transfor- CRD(x): Switch axis transformation on 4-30 Coord G30ff.
mation CRD( ): Switch axis transformation off
e.g. end surface transformation

PathAcc PAC Path accel. PAC(ACC... | UP..., DOWN ...) : switch on 4-91 G106/G107 ACC
PAC( ): switch off
Path acceleration programming, either sepa-
rately for acceleration and braking or com-
bined.

G40 - Path compen- Cutter path compensation OFF 3-39 G40 G40
sation
G41 - Path compen- Cutter path compensation to left of workpiece 3-39 G41 G41
sation
G42 - Path compen- Cutter path compensation to right of workpiece 3-39 G42 G42
sation
G08 G8 Path slope Path slope ON with path SHAPE according to 3-21 G08 G08
machine parameters
G08(SHAPE...) - Path slope Path slope ON with programmed path SHAPE 3-23 G108 G08

G09 G9 Path slope Path slop OFF (without SHAPE) 3-21 G09 G09

G09(..) G9(..) Path slope G9(X..., Y..., ...) 3-23 G408,


Path slope OFF with axis-wise programmed G608
SHAPE arrangement
G9(ASHAPE)
Path slope OFF with axis-wise SHAPE ar-
rangement according to machine parameters
G9(SHAPE ...)
Path slope OFF with programmed path SHAPE
G9(SIN ...)
Path slope OFF with sin2-shaped SHAPE (pos-
sible SHAPE arrangement: 5, 10, 15, 20, 40)
A-34 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
G184 - Drilling cycle Drilling cycle: Rigid tapping 3-68 G184

G80 - Drilling cycle Switch off drilling cycle 3-62 G80 -

G81 - Drilling cycle Drilling cycle: Drilling with retraction in rapid 3-62 G81 DEFINE
traverse
G82 - Drilling cycle Drilling cycle: Drilling with retraction in feed 3-63 G82 DEFINE

G83 - Drilling cycle Drilling cycle: Deep hole drilling 3-64 G83 DEFINE

G84 - Drilling cycle Drilling cycle: Floating tapping 3-65 G84 DEFINE

G85 - Drilling cycle Drilling cycle: Drilling out with retraction in 3-66 G85 DEFINE
rapid traverse
G86 - Drilling cycle Drilling cycle: Drilling out with retraction in feed 3-67 G86 DEFINE

ABS - CPL ABS(<input value>) 2-62 ABS -


Outputs the input value as an absolute value.
ACOS - CPL <function value> = ACOS(<input value>) 2-63 ACOS -
Application of the arc-cosine function on the
<input value>.

AND - CPL <Expression1> AND <Expression2> 2-64 AND -


Binary link between two BOOLEAN / INTEGER
expressions

APOS - CPL APOS(<axis selection>) 5-11 APOS -


Outputs the current actual axis value, based on
the machine zero point.

ASC - CPL ASC(<Character string>) 5-105 ASC -


Outputs the ordinal number of the first charac-
ter (ASCII code) of <character string> as an
INTEGER value.
ASIN - CPL <Function value> = ASIN(<Input value>) 2-63 ASIN -
Application of the arc-sine function on the <in-
put value>.

ATAN - CPL <Function value> = ATAN(<Input value>) 2-63 ATAN -


Application of the arc-tan function on the <in-
put value>.

AXO - CPL AXO((<Axis selection>[,<Selection type>]) 5-15 AXO -


Transfers an active G92 offset for a coordinate.
AXP - CPL AXP(axis number>,<path information>) 5-50 AXP -
This function permits level-independent parts
and measurement programs (program AXP in
place of the address values).
BCD - CPL <BCD value> = BCD(<binary value>) 2-65 BCD -
Convert BCD format to binary format.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-35
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
BIN - CPL <Binary value> = BIN(<BCD value>) 2-65 BIN -
Convert binary format to BCD format.
BITIF - CPL BITIF(<Bit signal>[,<Index>[,<IF unit>]]) 5-51 IC -
This function permits access to the digital inter-
face between the NC and the PLC.

CALL - CPL CALL <Program number> [<Transfer parame- 2-29 CALL -


ter1>,...] [DIN]
Subroutine call from a CPL program

CASE - CPL CASE <Integer expression> OF 2-40 CASE -


LABEL <Int. constant>[,<Additional int.
constant>] [: <Instruction>]
<Instruction>
LABEL ...
OTHERWISE <Instruction>
<Instruction>
ENDCASE
Conditional selection from several alternatives.
CHR$ - CPL CHR$(<Integer expression>) 5-105 CHR$ -
Supplies a character whose ordinal number in
the ASCII table equals the value transferred
using parameter <INTEGER expression>.
CLOCK - CPL <Function value> = CLOCK 5-53 CLOCK -
Query of the time counter in milliseconds.
CLOSE - CPL CLOSE(<n>) 5-131 CLOSE -
Closes an opened file after reading or writing
operations are complete.

CLRWARN - CPL Delete all the warnings of a channel that were 2-59 - -
generated with SETWARN.
COF - CPL COF(<Axis selection>[,<Selection type>]) 5-16 COF -
Supplies the last-programmed contour shift of
a coordinate for the current channel.

COS - CPL <Function value> = COS(<Input value>) 2-63 COS -


Cosine function for the <input value>.
CPROBE - CPL CPROBE(<Selection>[,<Selection type>]) 5-12 CPROBE -
Reads the measured value for a coordinate.
DATE - CPL <String variable> = DATE 5-53 DATE -
Assigns the date in the form DD.MM to a
<STRING variable>.

DBSEA - CPL DBSEA(<DbTab>,<Key1>,<Key2>,<Search- 5-25


Cond>,<SeachRes>[,<ResVar>])
Searches data blocks in a database table.
A-36 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
DBTAB - CPL DBTAB(<DbTable>,<Key1>,<Key2>[,<Res- 5-24
Var>])
Reads a complete data block or a substructure
of a database table to a CPL variable or writes
back from this variable.

DCT - CPL DCT(<Value selection>,<Data 5-23 TC -


block>[,[<Table>] [,<Unit>]])
Read/write access to any D-correction table or
to external tool correction values.
DIM - CPL DIM <Variable name>(<Field size1>[,<Field 2-53, DIM -
size2>]) 5-101
Specification of the field size (dimensioning) of
ARRAY variables with INTEGER constants.
DIRCR - CPL DIRCR(<Directory>) 5-123
Creates a new directory.
DIRDEL - CPL DIRDEL(<Directory>) 5-124
Deletes an empty directory.
DIRINF - CPL DIRINF(4,[<Index2>],<ResVar>[,<File num- 5-122
ber])
Calls administration data of the file system.

DPC - CPL DPC(<Selection>[,<Selection type>]) 5-17 DPC -


Supplies the last-programmed parameter of
workpiece position compensation BcsCorr of a
coordinate (offset values and turning angle) for
the current channel.

EOF - CPL EOF(<n>) 5-131 EOF -


Check for end of file.
ERASE - CPL ERASE(<Program ID>) 5-138 ERASE -
Deletes files.
ERRNO - CPL Error return of various CPL functions. 2-56 - -

FALSE - CPL <Boolean variable> = FALSE LEERER FALSE


MERKER -
Truth value of a BOOLEAN variable
FILEACCESS - CPL FILEACCESS(<File name>) 5-139 FILEAC- -
Determines whether a file exists and what ac- CESS
cess rights it has.

FILECOPY - CPL Copy files. 5-141 - -

FILEDATE - CPL FILEDATE(<File name>[,<Mode>]) 5-140 FILEDATE -


Determines the date/time of a file.
FILENO - CPL Supplies the next valid logical file number. 5-121
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-37
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
FILEPOS - CPL FILEPOS(<n>[,<mode>]) 5-132 FILEPOS -
Supplies the record number of the current re-
cord and the record offset of a random file.
For sequential files, supplies the current byte
position of the file indicator.

FILESIZE - CPL FILESIZE(<n>[,<k>]) 5-136 FILESIZE -


Supplies the size of a file or the limit to which a
file has already been written.

FOR NEXT - CPL FOR <Count.var.>=<Start val> [STEP spac- 2-42 FOR NEXT -
ing>] TO <End val><Routine>
NEXT [<Count.variable>]
Loop construction with automatically updated
counter.

GETERR - CPL GETERR(<Channel> [,<Category>],<Er- 5-54 GETERR -


ror>No> [,<Number>])
Supplies the error No., channel No. and error
category for the current errors.
GOTO - CPL GOTO <Jump target> 2-37 GOTO -
Unconditional program jumps to line number,
block number or label.

IF ENDIF - CPL IF <Condition> THEN <Routine> [ELSE <Alter- 2-39 IF ENDIF -


native routine>] ENDIF
Conditional jump to a routine or alternative rou-
tine.
INP# - CPL INP#(<n>,<Variable>[,<Variable>] [,...] [;]) 5-129 INP# -
Read access for a file.
INSTR - CPL INSTR(<Character string>,<String expres- 5-104 INSTR -
sion>[,<Starting point>])
Searches a <string expression>, starting at
<starting point>, for a <character string> and
outputs its starting position as an INTEGER
value.
INT - CPL <Integer number>=INT(<Real expression>) 2-62 INT -
Transforms the <real expression> to an <inte-
ger number> by cutting off the numbers after
the decimal point.
LEN - CPL LEN(<String expression>) 5-104 LEN -
Supplies the number of characters in a
STRING expression.

LJUST - CPL Switch to left-justified data output; effective 5-125 LJUST -


until the end of the program run.
A-38 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
MCODS - CPL MCODS(<Type>,<Channel>,<Ver- 5-59 MCODS -
sion>,<Buffer>,<Size>[,<P1>])
Calls Motion Control data services of the NCS.
This allows the data and states to be read from
the NC.

MCOPS - CPL MCOPS(<Fct>,<Channel>[[,[<P1>][,[<P2>], 5-88 MCOPS -


[<P3>]]],<P4>]))
Calls Motion Control process services of the
NCS. This allows channels in the NC to be
controlled.

MID$ - CPL MID$(<String expression>,<Starting point> 5-102 MID$ -


[,<No. of characters>])
Takes a part of the STRING expression and
outputs it as text. The result can be transferred
to a STRING variable or to an appropriately
sized character field.
MID$(<Character field>,<Starting point>[,<No.
of characters>])
Overwrites portions of a character field.
MMC - CPL MMC(<CPL-Var1>[,<CPL-Var2>...[,<CPL- 5-142 MMC -
VarN>]...])
Sends information regarding the program run-
ning time from a subroutine to a client and
waits for the result of this client.

MPOS - CPL MPOS(<Axis selection>[,<Axis type>[,<Chan- 5-9 MPOS -


nel>]])
Transfers the current interpolated command
position, based on the zero point of the MCS
machine coordinate system.

NCF - CPL NCF(<NC function>) 5-37 NCF -


Transfers the syntax of the active NC function
within the NC modal group of <NC function>.

NJUST - CPL Premature reset from left-justified data output 5-125 NJUST -
to formatted output.
NOT - CPL NOT <Expression> 2-64 NOT -
Negation of a BOOLEAN expression / bitwise
negation of an INTEGER expression.

NUL - CPL <Variable> = NUL 2-61 NUL -


Delete a variable.
OPENR - CPL OPENR(<n>,<Prog.name>[,<Record length>]) 5-119 OPENR -
Opens a file so that it can be read.
OPENW - CPL OPENW(<n>,<Prog.name>[.<Length>][,<Prog. 5-119 OPENW -
comment>][,<Record length>])
Opens a file so that it can be written.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-39
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
OR - CPL <Expression> OR <Expression> 2-64 OR -
Binary link between two BOOLEAN / INTEGER
expressions using the OR function.

PCS - CPL PCS(<Coordinate>[,<Selection type>]) 5-6 CPOS -


Supplies the last-programmed absolute posi-
tion of a coordinate.

PDIM - CPL PDIM <Parameter name>(<Field size>) 2-31 PDIM -


This must be used if a subroutine
D is to be called using a string constant as a
transfer parameter and
D the calling program is selected without
links.

PMT - CPL PMT(<Coord.selec- 5-28 -


tion>,<Pl.code>[,[<Pl.page>][,[<Table>][,<Unit>
]]])
Read and write access to an XML placement
table.

PMV - CPL PMV(<Coord.selection>[,<Pl. page>]) 5-27 -


Supplies the effective placement value for a
coordinate.

PPOS - CPL PPOS(<Axis selection>[,<Axis type>]) 5-14 PPOS -


Queries the actual axis position for the switch-
ing time of the probe.

PRN# - CPL PRN#(<n>,[<Expression>][,<Expression][,<Ex- 5-125 PRN# -


pression>][,...][;])
Write access for a file.

PROBE - CPL PROBE(<Axis selection>[,<Axis type>]) 5-13 PROBE -


Queries the axis position for the switching time
of the probe, based on the axis zero point
coordinates of the MCS.
REM - CPL REM <Comment text> 2-22 REM -
Program comments.
REPEAT - CPL REPEAT <Routine> UNTIL <Condition> 2-43 REPEAT -
Loop construction with query of the cancella-
tion condition after the routine has been pro-
cessed the first time.
REWRITE - CPL REWRITE(<n>) 5-128 REWRITE -
Overwrite an existing file.
ROUND - CPL <Integer number>=ROUND(<Real expres- 2-63 Round -
sion>)
Transform a REAL expression to an INTEGER
number by rounding up or down.
A-40 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
SCL - CPL SCL(<SCL selection>[,<Selection>[,<Selection 5-35 SCL -
type>]])
Supplies the last-programmed parameter of
functions PLS and ROT (polar coordinates,
scaling factors and turning angle) for the cur-
rent channel.
SCS - CPL SCS(<Axis index>,<ID type>,<ID No>[,<Res- 5-38 SCS -
Var>])
Read access to SERCOS drive parameters of
the active parameter set.
SCSL - CPL SCSL(<Axis index>,<ID type>,<ID No>,<File 5-39 SCSL -
name>[,<ResVar>])
Create a file for SERCOS parameter lists.

SD - CPL SD(<Group>[,<Index1>[,<Index2>[,<In- 5-41 SD -


dex3>]]])
Read active system data of the NC control.

SDR - CPL SDR(<Group>[,<Index1>[,<Index2>]]) 5-47 SDR -


Read active system data of the NC control in
REAL format.

SEEK - CPL SEEK(<n>,<k>[,<o>]) 5-134 SEEK -


Positions the file indicator on the <k>-th record
of a random file or on the <k>-th byte of a se-
quential file.
SETERR - CPL Generate a runtime error after evaluating 2-58 - -
ERRNO.
SETWARN - CPL Generate a warning after evaluating ERRNO. 2-59 - -
SIN - CPL <Function value> = SIN(<Input value>) 2-63 SIN -
Use the sine function for the input value.
SPOS - CPL SPOS(<Axis selection>) 5-10 SPOS -
Transfers the current axis command value of a
physical axis.

SQRT - CPL <Function value> = SQRT(<Input value>) 2-63 SQRT -


Use the square root function on the <input
value>.

STR$ - CPL STR$([<Format string>,]<Value>) 5-106 STR$ -


Converts numeric expression <Value> into a
character string that can be assigned to only
one character field.
<Format string> can be used to output the
character string in formatted form.
TAN - CPL <Function value> = TAN(<Input value>) 2-63 TAN -
Use the tangent function on the <input value>.
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-41
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
TCV - CPL TCV(<Value selection>[,<Correction selec- 5-22 TC -
tion>])
Supplies the last-programmed tool correction
values.
TIME - CPL <String variable> = TIME 5-53 TIME -
Assigns the time to a STRING variable in the
form HH.MM.SS.

TRIM$ - CPL TRIM$(<Character string>) 5-108 TRIM$ -


TRIM$(<Character string>,L)
TRIM$(<Character string>,R)
In the assignment of a character field range to
a STRING variable or a character field, sup-
plies a character string without a preceding
(index L) or following (index R) space. If
there is no index, both preceding and following
spaces are hidden.
TRUE - CPL <Boolean variable> = TRUE LEERER TRUE
MERKER -
Truth value of a BOOLEAN variable
VAL - CPL VAL(<String expression>) 5-107 VAL -
Returns the numeric value of the STRING ex-
pression.

VERSINF$ - CPL VERSINF$(<Index1>[,<Index2>]) 5-122


Calls administration data, e.g. the software ver-
sion.

WAIT - CPL WAIT(no parameter) 2-69 WAIT -


Stops block preparation until all the blocks pro-
grammed before WAIT have been processed.
WAIT(,<Waiting time>)
Stops block processing until a specified period
has elapsed.
WAIT(BITIF(...))
Stops block processing until a certain status
occurs on the PLC-NC bit interface.
WHILE - CPL WHILE <Condition> DO <Routine> END 2-44 WHILE -
Loop construction with query of the cancella-
tion condition before the loop is processed the
first time.
WPOS - CPL WPOS(<Axis selection>[,<Selection 5-8 WPOS -
type>[,<Channel>]])
Transfers the interpolated command position,
based on the workpiece zero point of the cur-
rent WCS.

XOR - CPL <Expression> XOR <Expression> 2-64 XOR -


Binary link between two BOOLEAN / INTEGER
expressions using the EXCLUSIVE-OR func-
tion.
A-42 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
XTAB - CPL XTAB(<Table>,<Substructure>) 5-30 TDA -
Read/write access to any XML table which can
also be user-defined.

ZOT - CPL ZOT(<Column selection>,<ZO code>[,[<ZO 5-18 FXC -


page>][,[<Table>][,<Unit>]]])
Read/write access to any XML zero offset
table.
ZOV - CPL ZOV(<Axis selection>[.<ZO page>]) 5-18 FXC -
Supplies the effective ZO values for an axis /
machine coordinate.

D D D-correction Dx: Activate D-correction (1-99 tools) 3-99 G147 -


D0: Cancel the D correction. G847,G148
DiaProg DIA Diam./Rad. Diameter programming 4-35 DIA G16
RadProg RAD Diam./Rad. Radius programming 4-35 RAD G15

G16 - Plane selec- no plane 3-27 G16 -


tion
G17 - Plane selec- Plane selection XY 3-28 G17/G20 G17/G20
tion
G17(...), - Plane selec- Expanded plane switching 3-30 - -
G18(...), tion G17/18/19( <Axis1>,<Axis2>,<Axis3>)
G19(...) The axes in parentheses open the WCS and
receive the meaning X, Y and Z.
Then the programmed plane is selected.
G17/18/19( )
Reset the workpiece coordinate system to the
default setting and then select the programmed
plane.

G18 - Plane selec- Plane selection ZX 3-28 G18/G20 G18/G21


tion
G19 - Plane selec- Plane selection YZ 3-28 G19/G20 G19/G22
tion
G20 - Plane selec- Free plane selection (WCS-independent) 3-32 - -
tion The placements have an effect on the WCS;
the plane is defined regardless of the WCS.

SD SD ED-correction ED x: Activation of external tool compensation 3-100 G145 -


(1-16 tools / tool edges) G845,G146
ED0: Deactivation of external tool compensa-
tion
G43 - Insertion stra- Insertion strategy, arc 3-41 G68 G43
tegy
G44 - Insertion stra- Insertion strategy, intersection 3-41 G69 G44
tegy
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-43
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
ChLength CHL Cham./Round. CHL(<Chamfer length>): switch on 4-25 G234/G35 -
CHL( ): switch off
Insert transitional chamfers with defined cham-
fer length.
ChSection CHS Cham./Round. CHS(<Chamfer section>): switch on 4-25 G234/G35 -
CHS( ): switch off
Insert transitional chamfers with defined cham-
fer section.
RoundEps RNE Cham./Round. RNE<Value> Rounding ON 4-118 G34/G35 -
RNE( ): Rounding OFF
Rounding with defined contour shift.

Rounding RND Cham./Round. RND(<Value>): Rounding ON 4-119 G134/G35 -


RND( ): Rounding OFF
Rounding with defined rounding radius

FlyMeas FME Measurement FME(MpiAxis< i>) X... Y... Z... 4-44 G275 -
on-the-fly Movement with on-the-fly measurement
G61 Precise stop Precise stop 3-49 G61/G161 G61

G61(IPS...) - Precise stop Precise stop with precise stop window IPS1, 3-49 G61/G161 G61
IPS2 or IPS3
G62 - Precise stop Precise stop off 3-49 G62/G162 G62

PrecProg PRP Precision PRP(DIST... | EPS...): Precision check ON 4-104 G328/G329 -


check PRP( ): Precision check OFF
G45 - Velocity, mil- Velocity, milling machine point of engagement 3-43 G64 G99
ling machine
G46 - Velocity, mil- Velocity, milling machine center 3-43 G65 G98
ling machine
G33 - Thread Thread cutting 3-33 G33 G33

G63 - Thread G63(M3/M4, S.../H...) F... Z... ... 3-51 G32 G63/G64
Rigid tapping
ThreadSet TST Thread Thread cutting, auxiliary functions 4-151

G70 - Inch/metric Inch programming, 3-53 G70 G70


affects the programmed path and length units,
feeds and acceleration.

G71 - Inch/metric Metric programming 3-54 G71 G71

G00 G0 Interpolation Linear interpolation (rapid travel) 3-3 G00/G10 G00


A-44 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
G00(..) G0(..) Interpolation Rapid travel with options 3-3
Optional parameters
NIPS: without precise stop
IPS1: Precise stop window 1
IPS2: Precise stop window 2
IPS3: Precise stop window 3 (only braking to
V=0)
POL/POLAR: with polar coordinate program-
ming, e.g. G0(POL) X50 A45 B10, with A, B =
polar angle 1/2

G01 G1 Interpolation Linear interpolation (feed) 3-5 G01/G11 G01

G02 G2 Interpolation Circular interpolation, clockwise 3-7 G02/G12 G02


(incl. helical N)
G02(POL) G2(..) Interpolation Circular interpolation, clockwise 3-11 G02/G12 G02
(incl. helical N) with polar coordinate program-
ming

G03 G3 Interpolation Circular interpolation, counterclockwise 3-7 G03/G13 G03


(incl. helical N)
G03(POL) G3(..) Interpolation Circular interpolation, counterclockwise 3-11 G02/G12 G02
(incl. helical N) with polar coordinate program-
ming

G05 G5 Interpolation Tangential circle entry (incl. helical N) 3-14 G05 -

G06 G6 Interpolation Splines, nurbs 3-15 G99 -

Collision CLN Collision moni- CLN(1): switch on 4-27


tor CLN(CollErr..| LA... | DLA... | DEF) :
Switch on with parameter setting
CLN( ): switch off
Collision monitor for 2D cutter path compensa-
tion.
KvProg KVP CO progr. KVP(Y..., Y..., Z..., ...): CO programming ON 4-62 G14/G15 AXD
KVP( ): CO programming OFF
G75 - Probe Traverse to probe (cancel movement) 3-57 G75 -

G53 - ZO All zero offsets OFF 3-46 -

G54.1 G54 ZO page 1 1st zero offset, page 1 ON 3-46 G54-G254

G55.1 G55 ZO page 1 2nd zero offset, page 1 ON 3-46 G54-G254

G56.1 G56 ZO page 1 3rd zero offset, page 1 ON 3-46 G54-G254

G57.1 G57 ZO page 1 4th zero offset, page 1 ON 3-46 G54-G254

G58.1 G58 ZO page 1 5th zero offset, page 1 ON 3-46 G54-G254

G59.1 G59 ZO page 1 6th zero offset, page 1 ON 3-46 G54-G254

G53.1-G53.5 - ZO page 1-5 Zero offset page 1-5 OFF 3-46 G53-G253

G54.2-G54.5 - ZO page 2-5 1st zero offset, page 2-5 ON 3-46 G54-G254
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-45
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
G55.2-G55.5 - ZO page 2-5 2nd zero offset, page 2-5 ON 3-46 G55-G255

G56.2-G56.5 - ZO page 2-5 3rd zero offset, page 2-5 ON 3-46 G56-G256

G57.2-G57.5 - ZO page 2-5 4th zero offset, page 2-5 ON 3-46 G57-G257

G58.2-G58.5 - ZO page 2-5 5th zero offset, page 2-5 ON 3-46 G58-G258

G59.2-G59.5 - ZO page 2-5 6th zero offset, page 2-5 ON 3-46 G59-G259

PoleSet PLS Set pole PLS(X..., Y..., Z...): Set pole 4-101 G37/G39
PLS( ): Pole at origin
Pole for help in making mirroring/rotation en-
tries.

PolarPol POP PolarPol POP(X...,Y...,Z...): Set pole 4-96 -


POP( ): Pole at origin
Pole for polar coordinate programming.

PosMode PMD Positioning PMD(A..., B...): switch positioning type 4-102 G151/G150 G36ff.
type PMD( ): Positioning type acc. to machine pa-
rameters
Positioning type for endless axes

ATrans ATR Program coor- ATR(X..., Y..., Z..., ...): Additive program coordi- 4-153
dinate offset nate offset ON
ATR( ): Additive program coordinate offset OFF
Trans TRS Program coor- TRS( X ..., Y ..., Z ..., ...): Program coordinate 4-153 G60/G67
dinate offset offset ON
TRS( ): Program coordinate offset OFF

G153 - SE Placement: Inclined plane, all OFF 3-83, -


3-83
G152.1 G152 IP page 1 Placement: Inclined plane, programmable, 3-83 G352
page 1
G154.1 G154 IP page 1 Placement: 1st inclined plane, page 1 ON 3-83 G354

G155.1 G155 IP page 1 Placement: 2nd inclined plane, page 1 ON 3-83 G355

G156.1 G156 IP page 1 Placement: 3rd inclined plane, page 1 ON 3-83 G356

G157.1 G157 IP page 1 Placement: 4th inclined plane, page 1 ON 3-83 G357

G158.1 G158 IP page 1 Placement: 5th inclined plane, page 1 ON 3-83 G358

G159.1 G159 IP page 1 Placement: 6th inclined plane, page 1 ON 3-83 G359

G153.1-G153.5 - IP page 1-5 Placement: Inclined plane page 1-5 OFF 3-83, G353
3-83
G152.2-G152.5 - IP page 2-5 Placement: Inclined plane, programmable, 3-83 G452
page 2-5
G154.2-G154.5 - IP page 2-5 Placement: 1st inclined plane, page 2-5 ON 3-83 G454/G554

G155.2-G155.5 - IP page 2-5 Placement: 2nd inclined plane, page 2-5 ON 3-83 G455/G555

G156.2-G156.5 - IP page 2-5 Placement: 3rd inclined plane, page 2-5 ON 3-83 G456/G556
A-46 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
G157.2-G157.5 - IP page 2-5 Placement: 4th inclined plane, page 2-5 ON 3-83 G457/G557

G158.2-G158.5 - IP page 2-5 Placement: 5th inclined plane, page 2-5 ON 3-83 G458/G558

G159.2-G159.5 - IP page 2-5 Placement: 5th inclined plane, page 2-5 ON 3-83 G459/G559

Scale SCL Scaling SCL(X..., Y..., Z..., ...):


Coordinate scaling 4-120 G38/G39 G78/G79
ON
SCL( ): Coordinate scaling OFF

Mirror MIR Mirror imaging MIR(X1, Y1,Z1,...): Mirroring of coordinates 4-73 G38/G39
ON
MIR( ): Mirroring of coordinates OFF

G96 - Spindle prog. G96{({<Reference axis>{,<Point of action>}})} 3-75 G96/G196 G96


Constant cutting speed
G97 - Spindle prog. Direct speed programming 3-75 G97 G97

Nibble NIB Punch NIB( NUM...): Nibble processing ON 4-76 G662/G660 -


NIB( ): Nibble processing OFF
Punch PUN Punch PUN( NUM...): Punch processing ON 4-110 G661/G660 -
PUN( ): Punch processing OFF
PtBlkEnd PTE Punching PTE(X..., Y..., Z..., ...) 4-106 G612 -
stroke Stroke trigger at end of block
PtDefault PTD Punching Stroke trigger according to parameters 4-108 G610 -
stroke
PtInpos PTI Punching PTI(X..., Y..., Z..., ...) 4-109 G611 -
stroke Stroke trigger at Inpos (Pt = punch time)
TangToolOri TTO Tangential tool TTO(SYM..., ANG...): Tangential tool orienta- 4-145 G630/G631 -
orient. tion ON
TTO( ): Tangential tool orientation OFF

DefTangTrans DTT Transition DTT(<Transition angle>): Activate G228 -


angle DTT( ): Deactivate
Definition of tangential contour transition
ConstFeed CFD V profile Constant velocity 4-68 G310 -

LinDownFeed LND V profile Linear braking 4-69 G312 -

LinUpFeed LNU V profile Linear acceleration 4-68 G311 -

Sin2DownFeed S2D V profile Sin2-shaped braking 4-69 G316 -

Sin2UpFeed S2U V profile Sin2-shaped acceleration 4-68 G315 -

SinDownFeed SND V profile Sin-shaped braking 4-69 G314 -

SinUpFeed SNU V profile Sin-shaped acceleration 4-68 G313 -

Rotate RED Rotate ROT(<Angle>): Coordinate rotation ON 4-116 G38/G39


ROT( ): Coordinate rotation OFF
OvrDis OVD Feed 100% Feed potentiometer OFF 4-90 G63 -

OvrEna OVE Feed 100% Feed potentiometer ON 4-90 G66 -


R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-47
and Controls

Appendix

NC function name Group Designation / Explanation Page Function in


Long Short (- means: PNC MTC
form form active
blockwise)
FeedAd FAD Feed advance FAD(1) : remove axis from feed 4-41 G594/G595
display
FAD( ): Axis contained in feed display

G93 - Feed prog. Time programming 3-70 G93 G93

G94 - Feed prog. Feed programming (per min) 3-71 G94 G94

G94(...) - Feed prog. G94({DF <Value>,} { DS1 <Value>, DS2 3-72 G94 G94
<Value>, ...} )
Incremental velocity programming with accel-
eration adaptation.

G95 - Feed prog. Feed programming (per rotation) 3-74 G95 G95

FeedForward FFW Servo control FFW(X..., Y..., Z..., ...): switch on 4-42 G114/G115 G6/G7
FFW( ): switch off
Activate servo control

BcsCorr BCR Tool length BCR({<XW-Offset>}{,{<YW-Offset>} 4-23 G138/G139 -


comp. {,{<ZW-Offset>}{,{<Angle1>} {,{<Angle2>}
{,{<Angle3>}}}}}}) : switch on
BCR( ): switch off
Placement: Tool position compensation.

G47 - Tool correction Switch on tool length correction 3-44 G146/8 G47

G47(..) - Tool correction G47(<L1 coord>,<L2 coord>,<L3 coord>) 3-44 G146/8 G47
G47(ActPlane)
Tool length correction ON with switching of
correction assignment.
G47( ): Tool length correction ON with correc-
tion assignment according to machine parame-
ters.
G48 - Tool correction Tool length correction OFF 3-44 G145/7ff. G48/G49

TangTool TTL Tool orient. TTL(TAX..., SYM..., ANG..., IA..., PLC...): 4-142 G131/G130 -
Tangential tool guidance ON
TTL( ): Tangential tool guidance OFF
A-48 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

A.3 ASCII Character Set

Dec. Hex ASCII Dec. Hex ASCII Dec. Hex ASCII Dec. Hex ASCII

0 00 NUL 32 20 SP 64 40 @ 96 60
1 01 SOH 33 21 ! 65 41 A 97 61 a
2 02 STX 34 22 " 66 42 B 98 62 b
3 03 ETX 35 23 # 67 43 C 99 63 c
4 04 EOT 36 24 $ 68 44 D 100 64 d
5 05 ENQ 37 25 % 69 45 E 101 65 e
6 06 ACK 38 26 & 70 46 F 102 66 f
7 07 BEL 39 27 71 47 G 103 67 g
8 08 BS 40 28 ( 72 48 H 104 68 h
9 09 HT 41 29 ) 73 49 I 105 69 i
10 0A LF 42 2A * 74 4A J 106 6A j
11 0B VT 43 2B + 75 4B K 107 6B k
12 0C FF 44 2C , 76 4C L 108 6C l
_
13 0D CR 45 2D 77 4D M 109 6D m
14 0E SO 46 2E . 78 4E N 110 6E n
15 0F SI 47 2F / 79 4F O 111 6F o
16 10 DLE 48 30 0 80 50 P 112 70 p
17 11 DC1 49 31 1 81 51 Q 113 71 q
18 12 DC2 50 32 2 82 52 R 114 72 r
19 13 DC3 51 33 3 83 53 S 115 73 s
20 14 DC4 52 34 4 84 54 T 116 74 t
21 15 NAK 53 35 5 85 55 U 117 75 u
22 16 SYN 54 36 6 86 56 V 118 76 v
23 17 ETB 55 37 7 87 57 W 119 77 w
24 18 CAN 56 38 8 88 58 X 120 78 x
25 19 EM 57 39 9 89 59 Y 121 79 y
26 1A SUB 58 3A : 90 5A Z 122 7A z
27 1B ESC 59 3B ; 91 5B [ 123 7B {
28 1C FS 60 3C < 92 5C \ 124 7C I
29 1D GS 61 3D = 93 5D ] 125 7D }
30 1E RS 62 3E > 94 5E " (! ) 126 7E ~
31 1F US 63 3F ? 95 5F !(!_!) 127 7F DEL

:!!!Characters!that!are!skipped!by!default!when!they!are!read!in.

A.4 Additional Key Codes

Key code (dec.) Meaning


134 CURSOR UP
135 CURSOR DOWN
136 CURSOR RIGHT
137 CURSOR LEFT

139 PLANE RETURN

141 SOFTKEY1
142 SOFTKEY2
143 SOFTKEY3
144 SOFTKEY4
145 SOFTKEY5
146 SOFTKEY6
147 SOFTKEY7
148 SOFTKEY8
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-49
and Controls

Appendix

A.5 Index
Zeichen ATCAL, 4-11
; (Start remark), 2-21 ATFWD, 4-13
( (Start remark), 2-21 ATGET, 4-14
) (End remark), 2-21 ATPUT, 4-15
$ (channel designation), 2-20 ATrans, 4-154
/ (Skip block), 2-38 ATS, 4-22 , 4-154
// (Start remark), 2-21 Attributes, 2-15
| (separator for alternative parameters), 2-11 , 3-2 , AxAcc, 4-17
4-1 AxAccSave, 4-17
\\ (End remark), 2-21 AXC, 4-20
AxCouple, 4-20
Zahlen Axis acceleration
3D tool radius compensation, 3-79 change, 4-17
save, 4-17
A Axis addresses, 2-16
AAC, 4-17 variable, 5-50
AAS, 4-17 Axis coupling, 4-19
ABS, 2-62 Axis designation, 2-16
Absolute dimension programming, 3-69 Axis distance control for digitizing, 4-37
local, 3-69 Axis name, 2-16
AC (Local absolute dimension programming), 3-69 Axis positions, reading, 5-4
Acceleration Overview, 5-2
axis, 4-17 Axis transfer
path, 4-91 area monitoring, 4-3
Acceleration interpolators, 4-68 Assign logical axis name, 4-10
Access privileges to files, 2-1 Integrate axis, 4-51
ACOS, 2-63 remove an axis from an axis group, 4-113
ACS, 5-9 Remove logical axis name., 4-114
Activate D-correction tables, 4-33 switch off C-axis mode, 4-22
Activate tables, 4-33 , 4-160 switch spindle to C-axis mode, 4-135
Placement tables, 4-95 Transfer axis, wait if necessary, 4-156
Activate zero offset tables, 4-160 Transfer default axis setting from MP, 4-34
Additional conditions, 2-8 AxisToSpindle, 4-22
ALN, 4-10 AXO, 5-15
AND, 2-64 AXP, 5-50
Angle brackets, 2-11
Angular offset while coupling is active, 4-130 B
Angular offset, wait for, 4-131 Backwards jump, 2-34
APOS, 5-11 BCD, 2-65
ARA, 4-2 BCR, 4-24
Arc (contour transition), 3-41 BcsCorr, 4-24
Area, 4-2 BIN, 2-65
area monitoring, 4-2 BITIF, 5-51
ARRAY, 2-53 Blank lines, 2-7 , 2-21
ASC, 5-105 BlkNmb, 2-72
ASIN, 2-63 Block duration, 3-70
AssLogName, 4-10 Block execution, DIN - CPL differences, 2-4
ASTOPA / ASTOPO, Channel synchronization by mo- Block number
vement stop, 2-79 Block preparation limit, 2-72
Asynchronous axes, velocity, 3-96 N instruction, 2-20
ATAN, 2-63 Block preparation limit: Block number, 2-72
A-50 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

Block transition using high-speed signal Compensation switching G78, G79, 3-60
Block transition on-the-fly, 4-52 , 4-53 Components sensitive to electrostatic discharge, 1-7
Block transition with cancellation, 4-56 Conditional jump, 2-35
BNB, 2-72 Constant cutting speed, 3-75
BOOLEAN, 2-48 , 2-52 Constant speed interpolator, 4-68
Brackets Constants, 2-66
angle, 2-11 , 3-2 , 4-1 double-precision, 2-66
curly, 2-11 , 3-2 , 4-1 ConstFeed, 4-69
square, 2-3 Contour error, 4-104
Braking interpolators, 4-69 Contour offsets, 5-16
Branch instructions, 2-24 , 2-38 Contour shift, programmed, 4-124
BSTOPA / BSTOPO, Channel synchronization by mo- Contour transitions for cutter path compensation,
vement stop, 2-81 3-41
Conversion, numeric systems, 2-65
C Coolant ON, 3-87 , 3-88
Calibration of axis kinematics Coord, 4-31
convert parameters, 4-13 Coordinate coupling, in same channel, 4-39
optimize parameters, 4-11 Coordinate designator, 2-16
read parameter from NC, 4-14 Coordinate name, 2-16
write parameter to NC, 4-15 Coordinate positions, reading, 5-4
CALL, 2-29 Overview, 5-2
CASE-LABEL...LABEL-OTHERWISE-ENDCASE, Correcting the tool length, 3-44
2-40 COS, 2-63
Center point programming, 3-10 Coupled groups: defining, activating, canceling, deac-
CFD, 4-69 tivating, 4-127
Chamfer length, 4-25 CoupleSplineTab, 4-32
Chamfer programming, 4-25 coupling lag of following spindle, 4-128
Chamfer segment, 4-25 CPL instructions, 2-3 , 2-61
Change the path acceleration, 4-91 CPL jump, 2-37
Channel designation, 2-20 CPL programming, 2-2
CHARACTER, 2-48 , 2-54 CRD, 4-31 , 4-32
Character fields, dimensioning, 5-101 CSE, 1-7
Character string constant, 2-67 Curly brackets, 2-11
Character strings and numbers, 5-105 Cutter center point (feedrate compensation), 3-43
CHL, 4-26 Cutter contact point (feedrate compensation), 3-43
ChLength, 4-26 Cutter path compensation, 3-39
CHR$, 5-105 contour transitions, 3-41
CHS, 4-26 feedrate compensation, 3-43
ChSection, 4-26 Cutting speed, constant, 3-75
Circle with tangential entry, 3-14
Circular/helical interpolation, 3-7 D
CLN, 4-28 D-correction, 3-99
CLOCK, 5-53 DATE, 5-53
CLOSE, 5-131 DAX, 4-34
CLRWARN, 2-59 DBSEA, 5-25
CO programming, 4-62 DBTAB, 5-24
Code characters, 2-67 DCA, 4-37
Coefficient programming, Spline, 3-16 DcAxis, 4-37
COF, 5-16 DCB, 4-38
COFFS, 3-80 DcBreak, 4-38
Collision, 4-27 DCC, 4-38
Collision monitoring function, 4-27 DcCont, 4-38
Communication, 5-142 DCF, 4-37
Comparison operations, 2-65 DcFilter, 4-37
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-51
and Controls

Appendix

DCL, 4-38 F
DcLimit, 4-38 F-address, 3-95
DCM, 4-38 F-word, 3-95
DcMon, 4-38 F-word (feed)
DCR, 4-37 per min., 3-71
DCS, 4-33 per rot., 3-74
DCT, 5-23 F-word (time), 3-70
DcTSel, 4-33 FA address, 3-96
Deactivate plane, 3-27 FA word, 3-96
Decision instructions, 2-24 , 2-38 FAD, 4-41
DefAxis, 4-34 Feed, 3-5 , 3-96
Define mirroring point, 4-101 F-address, 3-95
Define rotation point, 4-101 synchronous axes, 3-95
Definition of spline type, 4-136 Feed 100%, 4-90
DIA, 4-35 Feed forward control, 4-42
Diameter programming, 4-35 Feed programming
Digitizing, Axis distance control, 4-37 incremental, 3-72
DIM, 5-101 per min, 3-71
DIRCR, 5-123 per rot., 3-74
DIRDEL, 5-124 FeedAd, 4-41
Direct speed programming, 3-75 FeedForward, 4-42
DIRINF, 5-122 Feedrate compensation for cutter path compensation,
DistCtrl, 4-37 3-43
Divide traversing block Feedrate computing, hide axes, 4-41
general information, 4-138 FFW, 4-42
length of partial path, 4-64 Field variable, 2-53
number of partial paths, 4-78 File
DN, 3-16 closing, 5-131
DOUBLE, 2-48 , 2-52 copy, 5-141
DPC, 5-17 describing, 5-125
Drives, virtual, 4-155 determine access rights, 5-139
Dwell time, 3-13 determine date, 5-140
determining size, 5-136
E erasing, 5-138
EBC, 3-18 name, 5-117
ED-correction, 3-100 pointer position, 5-132
EMC Directive, 1-1 opening, 5-119
EMERGENCY STOP devices, 1-6 reading, 5-129
End of main program, 3-86 recognition of end, 5-131
End of program, 2-17 , 3-86 setting pointer, 5-134
End of subroutine, 2-17 File processing, 5-117
End position coupling, 4-39 File structure
Endless axes, switch positioning type, 4-102 random, 5-118
EndPosCouple, 4-39 sequential, 5-118
EOF, 5-131 File system and file protection, 2-1
ERASE, 5-138 FILEACCESS, 5-139
ERRNO, 2-56 FILECOPY, 5-141
Error return values, 5-57 FILEDATE, 5-140
Errors and error categories, 5-54 FILENO, 5-121
ESD FILEPOS, 5-132
protection, 1-7 FILESIZE, 5-136
workplace, 1-7 Fixed stop
measuring at, 4-46
move to, 4-48
A-52 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

FlyMeas, 4-44 G44, 3-42


FME, 4-44 G45, 3-43
Following distance, 3-3 , 3-49 G46, 3-43
Following error, 3-49 G47, 3-44
Following spindle G48, 3-44
changing the angular offset while coupling is ac- G5, 3-14
tive, 4-130 G53 to G59.5, 3-47
coupling lag, 4-128 G53-G59, 3-46
FOR - STEP - TO - NEXT, 2-42 G6, 3-15
Forwards jump, 2-33 G61, 3-49
Forwards transformation, 4-13 G62, 3-49
Free plane selection, 3-32 G63, 3-51
FSM, 4-49 G70, 3-53
FsMove, 4-49 G71, 3-54
FSP, 4-46 G74, 3-55
FsProbe, 4-46 G74(HOME), 3-56
FSR, 4-49 G75, 3-57
FsReset, 4-49 G76, 3-58
FST, 4-49 G8, 3-22
FsTorque, 4-49 G80, 3-62
Function overview, MCODS, 5-60 G81, 3-62
Functions, for NCS coupling, 5-59 G82, 3-63
G83, 3-64
G G84, 3-65
G0, 3-3 G85, 3-66
G1, 3-5 G86, 3-67
G2, 3-9 , 3-10 G9, 3-22
G3, 3-9 , 3-10 G90, 3-69
G4, 3-13 G91, 3-69
G140, 3-80 G93, 3-70
G141, 3-80 G94, 3-71
G142, 3-80 G94(...), 3-72
G152, 3-83 G95, 3-74
G153, 3-83 , 3-84 G96, 3-77
G154, 3-83 G97, 3-77
G155, 3-83 GAX, 4-51
G156, 3-83 GetAxis, 4-51
G157, 3-83 GETERR, 5-54
G158, 3-83 GOA, 2-33
G159, 3-84 GoAhead, 2-33
G16, 3-27 GOB, 2-34
G17, 3-28 GoBack, 2-34
G17(...), 3-30 GOC, 2-35
G18, 3-28 GoCond, 2-35
G18(...), 3-30 GOTO, 2-37
G184, 3-68 GoTo, 2-36
G19, 3-28 Grounding bracelet, 1-7
G19(...), 3-30 Groups of variables, 2-46
G20, 3-32
G33, 3-34 H
G40, 3-39 Helical interpolation, 3-7
G41, 3-39 High-speed output, position-dependent, 4-93
G42, 3-39 High-speed signal, block transition with cancellation,
G43, 3-42 4-56
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-53
and Controls

Appendix

High-speed signal, on-the-fly block transition, 4-52 , K


4-53 Key terms, 2-60
HSB, 4-53 , 4-56 KVP, 4-63
HsBlkSwitch, 4-53 KvProg, 4-63
HWOC, 4-58
HWOCDEL, 4-58 L
HWOCOFF, 4-58 Label programming, 2-32
Laser power control, 4-66
I LEN, 5-104
IC (Local relative dimension programming), 3-69 LEN (for punching/nibbling), 4-64
IF - THEN - ELSE - ENDIF, 2-39 LFC, 4-66
IME, 4-60 LFConf, 4-66
Inch programming, 3-53 LFP, 4-66
Inclined plane, 3-81 , 5-27 Limitation of speed, 4-125
Incremental data input programming, 3-69 LinDownFeed, 4-69
Incremental programming, 3-69 Linear interpolation
Incremental speed programming, 3-72 feedrate (G01), 3-5
InitMeas, 4-60 rapid traverse (G00), 3-3
INP#, 5-129 Link, 2-5
INSDEP, 3-80 Link table, 2-5
INSTR, 5-104 Links, logical, 2-64
Instruction words, reserved, 2-60 LinModZp, 4-71
Instructions, 2-8 LinUpFeed, 4-69
Instructions (CPL), 2-61 LJUST, 5-125
INT, 2-62 LMZ, 4-71
INTEGER, 2-52 , 2-66 LND, 4-69
Integrate axis, 4-51 LNU, 4-69
Interpolation parameters, 3-29 Local, 2-19
Interpolator Logical links, 2-64
Acceleration, 4-68 Low-Voltage Directive, 1-1
braking, 4-69
constant speed, 4-68 M
Intersection (contour transition), 3-41 M00, 3-85
IPS, 3-4 , 3-5 M01, 3-85
IPS1, 3-4 , 3-5 , 3-50 M02, 3-86
IPS2, 3-4 , 3-6 , 3-50 M103, 3-87
IPS3, 3-4 , 3-6 , 3-50 M104, 3-88
M105, 3-89
J M113, 3-87
Jogging in workpiece coordinates, 4-61 M114, 3-88
JogWCSSelect, 4-61 M13, 3-87
Jolt, 3-26 M14, 3-88
Jolt-limited speed guidance, 3-23 M2, 3-86
for contour mode, 3-24 M203, 3-87
for positioning mode, 3-24 M204, 3-88
Jump M205, 3-89
backwards, 2-34 M213, 3-87
conditional, 2-35 M214, 3-88
forwards, 2-33 M3, 3-87
unconditional, 2-36 M30, 3-86
unconditional with CPL, 2-37 M4, 3-88
Jump instructions, 2-24 , 2-32 M5, 3-89
Machining time, time programming, 3-70
MCODS, Motion Control data services, 5-59
A-54 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

MCOPS, 5-88 On-the-fly measurement, 4-44


MCS, 5-8 initialization, 4-60
Measurement on-the-fly, 4-44 Online correction in workpiece coordinates, 4-58
initialization, 4-60 OPENR, 5-119
Measurement units, supplied axis and coordinate OPENW, 5-119
positions, 5-2 Operations
Measuring at fixed stop, 4-46 double-precision, 2-66
Measuring unit mathematical, 2-62
inch, 3-53 OR, 2-64
metric, 3-54 Orientation programming, 4-79
Metric programming, 3-54 OVD, 4-90
MID$, 5-102 , 5-103 OVE, 4-90
MIR, 4-73 , 4-74 OvrDis, 4-90
Mirror, 4-73 OvrEna, 4-90
Mirroring, 4-73
MMC, 5-142 P
modal, 2-18 P address, 2-26
Modulo axis zero-setting, 4-71 PAC, 4-91
Monitoring of certain area, 4-2 Parts program, 2-1
Motion Control data services, MCODS, 5-59 Path compensation, 3-39
Motion Control process services, 5-88 Path functions, 2-8
Move to fixed stop, 4-48 Path overtravel, 4-104
Path slope, 3-21
N Path split, programmable, 4-138
N (block numbers), 2-20 PathAcc, 4-91
NC program, 2-1 PCS, 5-6
NC programming, 2-2 PCSPROBE, 5-12
NCF, 5-37 PDIM, 2-31
NCS coupling, 5-57 phi, 4-79
NCS coupling via MCODS, 5-59 PHS, 4-93
NIB, 4-76 PL, 3-17 , 3-19 , 3-20
Nibble, 4-76 Placement
Nibbling, 4-76 Inclined plane, 3-81
NIPS, 3-4 Workpiece position compensation, 4-23
NJUST, 5-125 Activate placement tables, 4-95
No plane, 3-27 Placements, 5-27
Nonmodal, 2-19 Plane selection, free, 3-32
NOT, 2-64 Plane switching, 3-28 , 3-30
Not self-sustaining, 2-19 PLC, 5-52
Notations, 3-2 , 4-1 PLC interface, 5-51
Notes regarding safety, 1-5 PLS, 4-101
NUL, 2-61 PMD, 4-102
NUM (for punching/nibbling), 4-78 PMS, 4-95
Numerals, 5-105 PMT, 5-28
NURBS, 3-20 PmTSel, 4-95
PMV, 5-27
O POL
O(), 4-79 for G0, 3-4
Offsets and placements, reading, 5-15 for G1, 3-6
OFFSTOPA / OFFSTOPO, 2-84 for G2, G3, 3-11
Omega, 3-96 programming example, 4-99
Omega address, 3-96 Polar coordinate programming, 4-97
Omega word, 3-96 define pole, 4-96
Omega word (feed), per min., 3-71 PolarPol, 4-96
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-55
and Controls

Appendix

PoleSet, 4-101 R
POP, 4-96 RAD, 4-35
PosDepHSOut, 4-93 Radius programming, 3-9 , 4-35
Position-dependent high-speed output, 4-93 Ramp functions, 4-68
Positioning type for endless axes, 4-102 Rapid traverse, 3-3
PosMode, 4-102 RAX, 4-113
PPOS, 5-14 RDT, 4-112
Precise stop REAL, 2-52 , 2-66
ON/OFF (G61,G62), 3-49 RED, 4-116
rapid traverse (G00), 3-3 RedTorque, 4-112
precision programming, 4-104 Reduction of maximum torque, 4-112
PrecProg, 4-105 Relative dimension programming, 3-69
PRN#, 5-125 local, 3-69
PROBE, 5-13 REM, 2-22
Probe, 3-57 Remarks, 2-21
reading, 5-12 nested, 2-21
Program RemAxis, 4-113
interrupt, 3-85 RemLogName, 4-114
interrupt conditionally, 3-85 remove an axis from an axis group, 4-113
terminate, 3-86 Remove axis name (log.), 4-114
Program blocks, 2-7 Rename axis (log. axis name), 4-10
Program design, 2-20 Repeat instructions, 2-24 , 2-42
Program execution, 2-24 REPEAT-UNTIL, 2-43
Program remarks, 2-21 REPOSTP, 4-115
Program speed (spindle), 3-97 Reserved instruction words, 2-60
Program stop, 3-85 REWRITE , 5-128
conditional, 3-85 Rigid tapping, 3-51
Program words, 2-10 Spindle selection, 4-147
as parameter, 2-13 RLN, 4-114
from NC functions, 2-11 RND, 4-119
Programmable path split, 4-138 RNE, 4-118
Programmed contour shift, 4-124 Rotate, 4-116
Programming attributes, 2-15 Rotating a contour, 4-116
Programming Examples ROTAX(), 4-79
character strings, 5-109 ROUND, 2-63
NCS functions, 5-96 RoundEps, 4-118
Programming notes, 2-23 Rounding, 4-119
Proper use, 1-1 Rounding corners
Providing handling instructions, 2-23 with deviation information, 4-118
PRP, 4-105 with radius information, 4-119
psi, 4-79
PtBlkEnd, 4-106 S
PTD, 4-108 S-word, 3-97
PtDefault, 4-108 S2D, 4-69
PTE, 4-106 S2U, 4-69
PTI, 4-109 SBC, 3-18
PtInpos, 4-109 Scale, 4-120
PUN, 4-110 Scaling, 4-120 , 5-35
Punch, 4-110 SCC, 4-122
Punching, 4-110 SCL, 4-120 , 5-35
PW, 3-20 SCS, 5-38
SCSL, 5-39
Q SD, 5-41
Qualified personnel, 1-3 SDF, 4-136
A-56 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

SDR, 5-47 Spindle


SEEK, 5-134 align/position, 3-90
SelCrdCouple, 4-122 cancel reservation, 3-89 , 4-126
Select axis transformation, 4-30 Clockwise rotation, 3-87
Selective additive coordinate coupling, 4-122 Counterclockwise rotation, 3-88
Self-sustaining, 2-18 stop, 3-89
Separator, between partial words, 2-16 switching between position and speed modes,
SERCOS parameters, writing, 4-157 4-139
Set actual value, 4-123 switching the main spindle, 4-72
Set parameters of static tool orientation, 4-140 Spindle coupling
Set program position (G92), 4-123 changing the angular offset while coupling is ac-
SETERR, 2-58 tive, 4-130
SetPos, 4-123 Coupled groups: defining, activating, canceling,
SETWARN, 2-59 deactivating, 4-127
Shape. Siehe Jolt-limited speed guidance coupling lag of following spindle, 4-128
Shift, 4-124 synchronization window, 4-132
SHT, 4-124 synchronous mode error window, 4-129
SIN, 2-63 wait for angular offset, 4-131
Sin2DownFeed, 4-69 wait for synchronous mode, 4-133
Sin2UpFeed, 4-69 Spindle speed, 3-97
SinDownFeed, 4-69 SpindleToAxis, 4-135
SinUpFeed, 4-69 Spline
SMax, 4-125 B splines (NURBS), 3-20
SMin, 4-125 C1 continuous cubic, 3-18
SMN, 4-125 C2 continuous cubic, 3-18
SMX, 4-125 Coefficient programming, 3-16
SND, 4-69 Spline programming, 3-15
SNU, 4-69 definition of spline type, 4-136
Space, removing, 5-108 SplineDef, 4-136
Spanning compensator, 4-23 SPLIT, 4-138
Spare parts, 1-7 SPOS, 5-10
SPC_WAIT, 4-133 SPS, 4-123
SPCC, 4-127 SPV, SPVE, Writing of permanent CPL variables,
SPCD, 4-128 2-78
SPCE, 4-129 SQRT, 2-63
SpCouple_Wait, 4-133 Square brackets, 2-3
SpCoupleConfig, 4-127 SSPG, 3-97
SpCoupleDist, 4-128 STA, 4-135
SpCoupleErrWin, 4-129 Standard programming, 2-2
SpCouplePosOffs, 4-130 StatToolOri, 4-140
SpCouplePosOffs_Wait, 4-131 STO, 4-140
SpCoupleSyncWin, 4-132 Stop processing, 3-85 , 3-86
SPCP, 4-130 STR$, 5-106
SPCP_WAIT, 4-131 STRING, 2-54
SPCS, 4-132 String, 5-101
Speed limitation, 4-125 length, 5-104
Speed programming, direct, 3-75 modifying, 5-103
SPG, 4-134 reading, 5-102
SPGALL, 4-134 searching, 5-104
String expressions
assigning, 5-112
chaining, 5-114
comparisons, 5-114
R911309064 / 02 IndraMotion MTX Electric Drives Bosch Rexroth AG A-57
and Controls

Appendix

Stroke release time Tool database, 5-24


Inpos window, 4-109 Tool guidance, tangential, 4-142
Interpolation end point, 4-106 Tool length compensation, 3-44
set to default, 4-108 Tool orientation, static, 4-140
Subprograms, 2-25 , 2-68 Tool radius compensation, 3D, 3-79
call using CALL command (CPL), 2-29 Torque reduction, 4-112
call with P address, 2-26 Trademarks, 1-8
call with parameter transfer, 2-30 Trans, 4-153
call without P address, 2-27 Transfer axis setting from MP, 4-34
call, self-defined modal, 2-28 Transfer axis, wait if necessary, 4-156
call, self-defined with G/M codes, 2-28 Transfer default axis setting from MP, 4-34
local, 2-25 Traverse to axis position, fixed machine, 3-58
modal, 2-25 Traverse to fixed machine axis position, 3-58
Subroutine calls, 2-24 Traverse to Reference Point, 3-56
with M address, 2-28 Traverse to reference point coordinates, 3-55
Switch off C-axis mode for spindles, 4-22 TRIM$, 5-108
Switching the main spindle, 4-72 TRS, 4-153
Synchronization functions TSP, 4-147
for block execution time, 2-73 TST, 4-151
of block preparation, 2-69 TTL, 4-143
Synchronous mode, wait for (spindle coupling), 4-133 TTO, 4-145

System data U
simple types, 5-36 Unconditional jump, 2-36
structured types, 5-48 Unconditional jump with CPL, 2-37

T V
TAN, 2-63 VAL, 5-107
Tangential circle entry, 3-14 Variable programming, 2-45
Tangential tool guidance, 4-142 Variable types, 2-52
Tangential tool orientation, 4-145 Variables
TangTool, 4-143 CHARACTER, 2-54
TangToolOri, 4-145 definable permanent, 2-47
Tapping, rigid, 3-51 global, 2-46
Spindle selection, 4-147 local, 2-46
TappSp, 4-147 Overview, 2-54
TCS, 4-148 permanent, 2-47
TCS definition in program coordinates, 4-148 STRING, 2-54
TcsDef, 4-148 structured, 2-51
TCV, 5-22 Velocity of asynchronous axes, FA address, 3-96
terminate a program, 3-86 Velocity profiles, definition of separate, 4-68
Test activities, 1-6 VERSINF$, 5-122
theta, 4-79 VirtAxisPos, 4-155
Thread Virtual drives, 4-155
chained, 3-36
multiple, 3-36 W
Thread cutting, 3-33 WAIT, 2-69
additional functions, 4-151 WAITA, WAITO, States on the digital interface, 2-74
thread pitch, 3-51 WaitAxis, 4-156
ThreadSet, 4-151 WAX, 4-156
TIME, 5-53 WCS, 5-7
time programming, 3-70 WHILE-DO-END, 2-44
Time recording, 5-53 WID, 4-157 , 4-158
Tool compensation, 5-22
A-58 Bosch Rexroth AG Electric Drives IndraMotion MTX R911309064 / 02
and Controls

Appendix

Workpiece coordinates
jogging, 4-61
Online correction, 4-58
Workpiece position compensation, 4-23 , 5-17
WPV, WPVE, Value of a permanent CPL variable,
2-76
WriteId, 4-157 , 4-158
Writing SERCOS parameters, 4-157
WSTOPA / WSTOPO, Channel synchronization by
movement stop, 2-82

X
XML tables, general access, 5-30
XOR, 2-64
XTAB, 5-30

Z
Zero offsets, 3-46 , 5-18
Zero-setting of modulo axis, 4-71
ZO, 3-46
ZO groups, 3-46
ZO pages, 3-46
ZOS, 4-160
ZOT, 5-18
ZoTSel, 4-160
ZOV, 5-18
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 (0)93 52-40-50 60
Fax +49 (0)93 52-40-49 41
service.svc@boschrexroth.de
www.boschrexroth.com

Printed in Germany
R911309064 DOK-MTX***-NC**PRO*V02-AW02-EN-P

Вам также может понравиться