Book 4 – Programming Guide

Transcription

Book 4 – Programming Guide
Menu
Book 4 – Programming Guide
A2100Di Control
Cincinnati Machine U.K. Limited,
PO. Box 505 Kingsbury Road, Birmingham B24 0QU UK.
Cincinnati Machine, CINCINNATI and FTV are the trademarks of Cincinnati Machine,
a division of UNOVA Industrial Automation Systems, Inc.
Publication No 91204426A001
ALL RIGHTS RESERVED
Printed in England – Issue 1A – October 2002
© 2002 Cincinnati Machine, a Division of UNOVA Industrial Automation Systems, Inc.
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204426A001
ii
Prelims
October 2002
Menu
FTV Series 600 and 800 Machining Centres
Book 4
Programming Guide
Contents
Page
Contents page (this page)
iii
General
v
Manual Content and Use
v
Patents and Copyright Notice
vi
Service and Spares
vi
Cincinnati Machine World Representation
vii
Warranty
vii
Labour and Parts
vii
Way Covers
vii
Safety
Vii
Chapter
NC Program Format
1
NC Program Elements
2
Preparatory Function Codes (G Codes)
3
Offsetting Co-ordinates
4
Mechanism Control
5
Hole Making Fixed Cycles
6
Arithmetic Expressions and Variables
7
Program Logic Flow Control
8
Sub Routines and Program Chaining
9
Print Message and File Blocks
10
Data Acquisition
11
Program Translation
12
Position Contouring Rotary Axis
13
Quick Reference
14
System Configuration
15
A2100Di Programming Manual
Publication 91204426A001
iii
Prelims
October 2002
Menu
Cincinnati Machine UK Ltd has a policy of continuous product improvement. They reserve the right
to apply design changes at any time, without notice and without any obligations to equipment
previously sold.
No part of this manual may be reproduced, transmitted, transcribed, translated into any language
human or electronic, stored in any electronic retrieval system, in any form, without prior permission
of Cincinnati Machine UK Limited (the Company).
This Manual has been compiled and published by:
Cincinnati Machine UK Limited
PO Box 505 Kingsbury Road
Birmingham
B24 0QU UK.
Telephone: + 44 (0) 121-351 3821
Facsimile: + 44 (0) 121-313 1459
A2100Di Programming Manual
Publication 91204426A001
iv
Prelims
October 2002
Menu
1
General
This Manual is intended as a guide to the correct installation and preparation for use of
your Cincinnati V-CNC Machining Centre. Every care is taken in the design, development
and manufacture of the machine to ensure that efficient and trouble-free equipment is
supplied. Best results will be obtained if care is taken during installation, use and servicing.
Cincinnati Machine Tools Limited (the Company) have made every reasonable effort to
ensure the accuracy of this Manual, but nothing shown, described, implied or referred to in
this Manual should be regarded as an infallible guide to the procedures, materials,
specification, design or availability of any particular system or sub-system. Nor does this
Manual constitute an offer for sale of any particular equipment.
No liability can be accepted by the Company for any mechanical, electrical or electronic
malfunction, damage, loss, injury or death caused by the use of incorrect or
misrepresented information, omissions or errors that may have arisen during the
preparation of this Manual.
The Company will not be held responsible for any incidental or consequential damages or
costs resulting from any abuse or misapplication of the supplied machine, nor will they be
responsible for any damages resulting from unauthorised modifications to the machine.
The instructions contained in this Manual are provided as a guide for customer’s personnel,
and are intended to cover normal installations and tasks. The Manual is set out in Chapters
and Sections to ease information retrieval, and should be made available to relevant
personnel. If any work, repairs or modifications become necessary (and are not included in
this Manual) contact the Company immediately. Further copies of this Manual may be
obtained by quoting the publication reference on the title page.
This Manual should be read in conjunction with any third party documentation supplied with
the machine.
2
Manual Content and Use
Carefully read all the instructions and safety precautions contained in this Manual. Do not
attempt to install this machine until you are thoroughly conversant with the material
contained in this and all other associated Manuals, drawings, third party documents and
datasheets.
This is a Cincinnati Machine Manual, applicable only to the FTV 600 and 800 series
machines. It should be used in conjunction with the drawings and documentation supplied
with the equipment. This Manual, whilst complete and up-to-date when published, is
subject to amendment at the discretion of the Company.
If you have any difficulty with your equipment, Cincinnati technical staff are always
available with expert advice and assistance. When communicating with Cincinnati Machine
UK Limited, always quote the equipment type and serial number.
This Manual has been prepared by Cincinnati Machine UK Limited in connection with a
contract to supply goods and/or services and is submitted only on the basis of strict
confidentiality. The contents must not be disclosed to third parties other than in accordance
with the terms of the contract.
A2100Di Programming Manual
Publication 91204426A001
v
Prelims
October 2002
Menu
The Manual Suite comprises the following four guides covering all aspects of the
equipment from installation, commissioning and basic operating procedures to the correct
maintenance and repair of the installed machine:
Book 1 User Guide
Contains all the information necessary to take delivery, position and connect the
machine to workshop or factory services and set it to work. Effectively a-step-by step
guide to installing and using the machine. Guidance to correct rigging and lifting
techniques and equipment is also included.
Book 2 Service and Spares Guide
Contains detailed recommendations for correct maintenance. Planned preventive and
defect maintenance procedures are included, as well as first line fault finding and
diagnostic operations. Parts lists and illustrations are also included.
Book 3 Operation and Probing Guide
Contains information necessary to carry out competent operation of the equipment.
Book 4 Programming Guide
Contains information necessary to carry out competent programming of the equipment.
3
Patents and Copyright Notice
The machine and attachments and parts thereof illustrated and described in this Manual
are manufactured under and protected by issued and pending British and Foreign Patents,
and copyright is reserved in any original design feature thereof and in the contents of this
Manual.
The Company reserve the copyright of all information and illustrations in this Manual, which
is supplied in confidence and may not be used for any other purpose other than that for
which it was supplied. The Manual may not be reproduced in part or in whole without the
consent in writing of the Company.
4
Service and Spares
To maintain the accuracy and serviceability of your machine, Cincinnati Machine
recommend an annual service by a Cincinnati Machine engineer.
For details of service arrangements, and to obtain spare parts for Cincinnati Machine UK
Limited equipment, address all inquiries to:
Cincinnati Machine UK Limited.
P.O. Box 505 Kingsbury Road
Birmingham B24 0QU UK.
Telephone: + 44 (0) 121-351 3821
Facsimile: + 44 (0) 121-313 1459
When ordering spare parts, please quote the model and serial number of the machine, and
the equipment type and serial number.
A2100Di Programming Manual
Publication 91204426A001
vi
Prelims
October 2002
Menu
5
Cincinnati Machine World Representation
United States of America:
Cincinnati Machine Marketing Company,
Cincinnati,
Ohio, 45209-9988,
USA.
Tel (Main):
(513) 841-8100
Tel (Service): (513) 841-3000
Fax (Service): (513) 841-8871
6
Warranty
Conditions of warranty are generally as stated in our standard conditions of sale. Details of
the warranty may be obtained from Cincinnati Machine UK Limited.
6.1
Labour and Parts
As new, the machine is guaranteed for twelve months against faulty materials and
workmanship from the date of final acceptance in the customers works, or fifteen months
from the date of shipping from Cincinnati Machine, whichever is the earlier.
The warranty does not cover damage to the machine or associated equipment caused by
operator error, or by misuse of the machine.
Where this Manual indicates 'contact Cincinnati Machine service', specialist assistance is
required. The warranty will be invalidated if any repairs are attempted or any item is
tampered with when not specifically authorised to do so by Cincinnati Machine.
To gain full benefit from the warranty, all routine servicing specified in the Service and
Spares Manual should be undertaken and the completed check sheets retained for
Cincinnati Machine’s inspection in the event of a claim.
6.2
Way Covers
Units being repaired under New Machine Warranty must be administered by the Cincinnati
Machine Field Service department.
Way covers damaged under the following circumstances will not be replaced free of charge
under the terms of the New Machine Warranty:
G Dropping tools or parts onto the way cover.
G Damage caused by walking or climbing on the way cover.
G Improper or inadequate housekeeping procedures.
A2100Di Programming Manual
Publication 91204426A001
vii
Prelims
October 2002
Menu
7
Safety
Books 1 and 2 contain a Chapter concerning Health and Safety. In addition, supplementary
comments may be inserted in the text to emphasise specific safety points, as follows:
WARNING
Information to prevent causing death or a danger to yourself or to others
CAUTION
Information to prevent causing damage to equipment
Most accidents involving equipment installation and operation are caused by the failure of
personnel to observe basic safety rules or precautions. An accident can often by avoided
by recognising potentially hazardous situations beforehand, and taking appropriate
precautions.
A2100Di Programming Manual
Publication 91204426A001
viii
Prelims
October 2002
Menu
Chapter 1
NUMERIC CONTROL PROGRAM FORMAT
Contents
1
1.1
1.2
1.3
1.4
1.5
1.6
1.7
1.8
1.9
1.10
1.11
1.12
1.13
1.14
1.15
1.16
1.17
NC Program Format...................................................................... 3
Introduction................................................................................... 3
NC Compatibility with Previous Acramatic Controls ................. 3
Compatibility with NC Tape Devices ........................................... 3
NC Program Comments ............................................................... 3
Sequence Number ........................................................................ 4
Program Storage........................................................................... 4
NC Program Block Formats ......................................................... 5
NC Program Word Values ............................................................ 5
Decimal Point Programming ........................................................ 5
Resolution ..................................................................................... 5
Negative Numbers ........................................................................ 6
Block Delete .................................................................................. 6
Program Management .................................................................. 6
Directory Services (Registry, Import, Export)............................. 6
Continuous Load .......................................................................... 7
Program Search and Positioning................................................. 8
Program Import/Export................................................................. 8
A2100Di Programming Manual
Publication 91204451- 001
1
Chapter 1
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204451- 001
2
Chapter 1
May 2002
Menu
1
NC Program Format
1.1
Introduction
A numeric control (NC) part program is a series of numeric command instructions which
the machine control interprets for machining the workpiece. During automatic cycle, NC
program commands control of all machine functions including:
G
Machine slide positioning.
G
Feed-rate selection.
G
Spindle direction (rotation) selection.
G
Spindle speed selection.
G
Spindle start and stop selection.
G
Auxiliary equipment control.
An NC program consists of a series of blocks. Generally, each block contains the
commands required to perform a single step in the machining operation, such as feeding
the tool at the specified feed rate from one point to another. The workpiece is machined
by executing one block after another, in sequence, until the entire workpiece is complete.
To minimize programming effort, a single block may cause execution of a series of
events by calling-up a subroutine or an automatic cycle.
1.2
NC Compatibility with Previous Acramatic Controls
Although the control NC programming language is based on the Acramatic 850 and
Acramatic 950 NC programming language, there are differences in G code values,
specific meanings of word values in some fixed cycles, and significant changes in the
way that variables are referenced and program flow control is implemented. The
changes are such that an A850 or A950 program can be translated simply into a machine
control program.
A850 and A950 NC programs that do not use M registers, T registers, or access to
tables, and that consist largely of linear and circular interpolation moves, require only
minimal changes (if any). Programs that use the advanced programming capabilities of
A850 or A950 may require more extensive translation.
The machine control will provide translators for A850 and A950 NC programs.
1.3
Compatibility with NC Tape Devices
The machine control supports programs that have been generated with NC tape using
the RS-358-B character set, however, tapes cannot be directly read into the control with
an NC tape reader, as the control will not accept any input program data containing nonASCII characters.
1.4
NC Program Comments
NC program comments (text that is ignored by machine control) may be placed following
a semicolon (;). All characters between the semicolon and the end of block are ignored.
A2100Di Programming Manual
Publication 91204451- 001
3
Chapter 1
May 2002
Menu
White space characters (space, tab, carriage return) may be included in an NC program
between words in a block, and between elements of expressions. White space
characters are not permitted within numbers or symbols. White space characters are
ignored by machine control.
The general organization of an NC program begins with a program identification block.
As a number of programs may be stored at the same time in the control’s memory, the
identification block is used as an index to select the program required for operation. The
program identification block is discussed in the chapter titled Numeric Control Program
Elements.
1.5
Sequence Number
Sequence number words are specified by a colon (:) and N, are used to identify the
blocks of an NC program. Use of sequence numbers is not required, and the machine
control places no restrictions on the order of the numbers. As sequence numbers are
primarily block identifiers, the use of expressions, decimal points, and minus signs, is not
allowed.
The sequence number format is an unsigned, one through eleven digit number of the
form:
N6
:6
Sequence numbers with a colon (:) designate alignment blocks. An alignment block is a
block that is a planned program restart point. An alignment block should re-establish all
modal values, such as G code states, as it is intended for use as a program start point.
The machine control automatically resets all G code groups to the configured default
state when an alignment block is encountered, so only those G code states different from
the default state need to be programmed.
Sequence numbers beginning with an N are ignored by A2100 during program execution.
They serve to identify program blocks for the programmer and operator, they are also
useful as search targets, and are displayed for the operator. In general, it is good
practice to use unique, increasing value, sequence numbers, but this is not a
programming requirement. Sequence numbers beginning with N require a numerical
value; those beginning with a colon (:) can have either a numerical value or just the
colon.
1.6
Program Storage
Machine control allows up to 500 NC programs to be stored or registered within the
program directory. The program directory provides a tabular display of all the programs
known to the control, it also contains a list of all the NC programs together with their
attributes.
Program storage for the control is 4MB, with additional storage increments up to a total of
500MB.
A2100Di Programming Manual
Publication 91204451- 001
4
Chapter 1
May 2002
Menu
1.7
NC Program Block Formats
Machine control supports variable block format in accordance with EIA-274D. Both Type
I (NC program blocks) and Type II (parenthetic blocks) are supported, and both Type I
and Type II blocks are terminated by an end of block character (ASCII LF or Line Feed).
Space, tab, and carriage return (CR) characters are allowed for program formatting, but
they are ignored by the control during program execution. The white space characters
are not permitted within numbers or within a variable name, but may appear between
words of a block, and between the operators of an expression and the operands.
1.8
NC Program Word Values
Each NC program word consists of a single character address (a letter or a colon or an
equal sign) and a value. The value of a program word is usually simply a number, but
may be a reference to a variable, or an arithmetic expression.
Some word addresses, generally for words that add a modifier to the block’s action, are
specified by a comma (,) followed by a letter. For example, a radius blend is specified by
, R followed by the radius dimension.
1.9
Decimal Point Programming
Machine control treats all numeric data as floating point numbers. If a number does not
have an explicit decimal point, the number is assumed to be a whole number. Any
number representing a fractional value must contain a decimal point. As the decimal
point is explicitly programmed, it is never necessary to program leading or trailing zeros.
Explicit formats are not given, as all words are treated as decimal fractions. Some values
must be positive, or have specific numeric values (such as preparatory functions [G
codes]) and these are noted where appropriate.
1.10
Resolution
The program representation of any dimensional data (axis commands, feed rates, etc.)
may contain a total of 15 digits, with the decimal point anywhere in the number. Some
program word values are restricted to whole numbers or positive numbers.
Machine control treats all input data as floating point data, that is, data that has a decimal
point and a fixed number of significant digits as well as a magnitude. Internally, in the
motion generation process, all dimensional data are represented with a fixed linear
resolution of 0.02 microns (0.00002 mm), which is approximately one microinch
(0.000001 inch).
The corresponding rotary axis resolution is 0.00005 degrees (0.18 arc seconds).
Optionally, a lower resolution of 0.2 micron (0.0002 mm) and 0.005 degrees (1.8 arc
seconds) is available for an extended range of motion for very large machines. Each
axis has its own individual feedback resolution, which is determined by mechanical
factors such as the gearing between the motor and the axis, and the resolution of the
feedback device.
Even though extremely small increments of motion can be specified in an NC program,
no motion actually occurs until a commanded motion of at least one internal bit (0.02
A2100Di Programming Manual
Publication 91204451- 001
5
Chapter 1
May 2002
Menu
micron) results from a commanded move or an accumulation of smaller motions.
Machine motion cannot occur until the commanded motion exceeds one feedback bit, the
value of which depends on the mechanical configuration of each axis.
1.11
Negative Numbers
Where permitted, negative numbers are indicated by a minus sign (-). In all cases, a plus
sign (+) is permitted for positive numbers, but is never required.
1.12
Block Delete
Block Delete provides the capability to program blocks that may be optionally executed or
skipped, based on the state of an operator input. Up to nine separate operator input
selections, specified by /1 through /9, are supported. The NC program specifies full
blocks to be skipped by a slash (/) followed by an optional single digit as the first item in
the block. If the digit is omitted, /1 is assumed.
Multiple block delete control allows an NC program to provide for several independent
operator selectable options, such as skipping roughing passes and skipping part
inspection using the spindle probe. In this case, /1 could be used to skip the roughing
pass and /2 to skip the probe operations.
Part of a block may be deleted by placing a double slash (//) followed by a single digit
anywhere in the block. The double slash is needed to distinguish the 'delete remainder
of block' code from the arithmetic divide operation. If the operator input corresponding to
the selection is 'on' when the block is encountered during program execution, the portion
of the block to the right of the '// n' code is skipped.
Note that the remaining portion of the block must form a legal NC program block in the
case that the block delete code is not the first item in the block.
1.13
Program Management
Machine control provides comprehensive program and file handling capabilities.
Program directory services, edit capabilities, loading and saving, activation, and Manual
Data Input are described in this topic.
1.14
Directory Services (Registry, Import, Export)
Machine control allows up to 500 NC programs to be stored or registered within the
program directory. The program directory provides a tabular display of all the programs
known to the control, it also contains a list of all NC programs, together with their
attributes. Program storage for the control is 144 kB with additional storage up to a total
of 40MB. The program attributes are provided to give more specific information on the
programs and how they are to be used. The program directory fields are shown in the
table below.
The registered program capability provides the user with the capability to notify the
machine control of the existence of a NC program and its associated attributes, without
the need to load the program into the machine control. This is particularly useful when
connected to network drives where the network drives store the program to be executed.
In this case the user is able to register the program and its attributes, thus allowing the
A2100Di Programming Manual
Publication 91204451- 001
6
Chapter 1
May 2002
Menu
program to be selected to run in the same manner as a NC program stored within the
control.
Program Directory
Program Name
32 character alphanumeric name.
Program Identifier
5 digit program ID.
Program Type
Specifies the type of program: EIA-274, A850, A950, FANUC, SFP,
ASCII, BMP, DXF, TIF, UNKNOWN.
Program Size
Number of characters in the program.
Modify Date
Date the program was last modified.
Creation Date
Date the program was created.
Program Path
Program path this programmed is allowed to run on.
Group
User defined name of group for the NC program. Used for search and
filter capabilities.
Program Validation
Indicates if the program has been syntax checked.
Run Limited Count
Indicates the number of times the program may be run, if the Program
Access field has a value of ’Limited Release’.
Provides selection of access privileges for edits, deletes and execution
of the program.
Provides selection of access privileges for edits, deletes and execution
of the program.
Program Status
Program Access
1.15
Description
Continuous Load
The continuous load feature provides the capability to execute extremely large programs
from a host computer, or other external source that will not fit in the machine control.
Individual programs that are too large to execute can be labeled Continuous in the
controls program directory.
However, continuous load is automatically invoked if machine control determines that the
program size is too big to fit in the control, or if an attempt is made to run a program from
a data line without first loading it. The following restrictions exist when running in
continuous load mode:
G
Program jumps are not permitted.
G
Inline subroutine calls are not permitted.
G
Program loops are not permitted (see DO LOOP).
While running in continuous load, if an edit to the program is required, machine control
permits editing of the current program segment. At any point during program execution,
the program can be stopped (feed-hold, data reset) and the user can select to edit the
program. In this case the current segment appears in the editor and edits are permitted.
A2100Di Programming Manual
Publication 91204451- 001
7
Chapter 1
May 2002
Menu
1.16
Program Search and Positioning
Program search and positioning can be used to change position in the program up to the
end of the current program segment. If the user attempts to search or position beyond
the end of the current program segment he is prompted with a message asking him if he
wishes to go beyond the current segment, and notifying him that he will lose his current
program section if he does. If the user selects to advance beyond the end of the current
program section, the current segment is overwritten by a new segment and the old
segment is lost.
1.17
Program Import/Export
Machine control allows NC programs to be transferred in and out of the control using the
import/export functions. These functions allow programs to be transferred to or from any
I/O device that can transfer NC programs, including data line, tape reader, floppy disk
(optional) and networks.
The user is presented with a dialog box that allows him to select the appropriate device
and directory tree. The dialog box presents the user with a display of directories of the
device (if they are present) and allows navigation through the directory tree of the
remote device.
Any program can be transferred into the machine control providing sufficient disk space
and read privileges exist on the remote device. When the program is read into machine
control, it recognizes the optional (PGM) block, which is used to update the program
attributes.
A2100Di Programming Manual
Publication 91204451- 001
8
Chapter 1
May 2002
Menu
Chapter 2
NUMERIC CONTROL PROGRAM ELEMENTS
Contents
1
2
3
4
5
6
7
8
9
10
11
Introduction ..........................................................................................3
PGM (Program Identification Block)....................................................3
Block Labels .........................................................................................5
Sequence Number ................................................................................5
Initialisation ..........................................................................................6
Type I Block Word Formats .................................................................7
Format Error Detection ........................................................................7
Type I Block Format Rules...................................................................7
Type II NC Program Block Format.......................................................8
Flow Control Statements .....................................................................8
Assignment Statements.......................................................................9
A2100Di Programming Manual
Publication 91204426-001
1
Chapter 2
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204426-001
2
Chapter 2
May 2002
Menu
1
Introduction
This Chapter describes the elements of a program block and NC features controlled by
the various codes.
FIRST BLOCK
IN PROGRAM
TYPE II BLOCK
N0010 (PGM, NAME="TEST")
BLOCK LABEL
ASSIGNMENT
STATEMENT
[OPERATION 1]}
N0020 G0 X5 Y2 Z3
N0030 [#TEST_TYPE]=0
N0040 (IF [#TEST3]=5 THEN)
N0050 M06
N0060 (ENDIF)
N0060 M30
VARIABLE
IDENTIFIER
TYPE I BLOCK
FLOW CONTROL
STATEMENTS
Figure 1.1 NC Program Elements
2
PGM (Program Identification Block)
The control NC programs writes to external files by attaching a PGM Type II block to the
beginning of the program. The PGM block may also be used by the NC programmer to
specify information about the program to the control. When a program containing a
PGM block is read, the PGM block is removed and the program attributes contained
within the PGM block are used to fill-in the program directory entries.
The format of the data within the parentheses of the PGM Type II block does not follow
the usual word address format, but consists instead of a set of keywords and values.
Each keyword is followed by an equal sign (=) and a value, which must be enclosed in
double quotation marks (“”). Keyword “<value>” sets are separated by commas. The
keywords can appear in any order within the PGM block, but a keyword may appear
only once.
Comments can be placed between keyword value pairs and unlike all other blocks,
embedded End of Block Characters are allowed between keyword value pairs. The
PGM block is terminated by a close parenthesis followed by an End of Block character.
The format of the PGM block is:
[Nxxxx] (PGM, <keyword>=“<value>”[,<keyword>=“<value>”]...)
where:
Nxxxx is the optional sequence number for the PGM block.
<keyword> is one of the following: NAME, ID, TYPE, CREATED, MODIFIED,
GROUP, EXEMODE, ACCESS, RELEASEMODE. The keywords may be either the
full word or just the initial letter. If the keyword is spelled out, it must be spelled
exactly as shown, and must all be in uppercase letters.
<value> depends on the keyword, and the following paragraphs define the contents
of <value> for each keyword.
A2100Di Programming Manual
Publication 91204426-001
3
Chapter 2
May 2002
Menu
G
* NAME=“<program name>” - or N = “<program name>” - <program name> is a
string of from one to 32 alphabetic or numeric characters. The string is permitted to
contain blanks, and can contain either uppercase or lowercase letters. This is the
name that appears in the A2100 program directory and can be used to refer to the
program from a CLS (Call Subroutine) block or CHN (Chain To Program). The Name
field is required in a PGM block.
G
* ID=“<program identifier>” or I=“<program identifier>” - <program identifier> is a
number between 1 and 99999. This is the programs identification number, and it is
used in CLS and CHN blocks, and in the Multiple Setup table. The default identifier
is a null identifier, meaning that the program cannot be referenced by its identifier.
G
* TYPE=“<program type>” or T=“<program type>” - <program type> specifies the
language of the NC program. The valid program types are “A2100_274” for A2100
programs, “A850_274” for Acramatic 850 programs, and “FANUC_274” for programs
written for a Fanuc 0 control. A2100 uses this field to determine whether the
program requires translation into the native A2100 language before the program is
run. The default type is “A2100_274”.
G
* CREATED=“<creation date>” or C=“<creation date>” - <creation date> is the date
that the program was created. <creation date> is a 24 character string containing the
creation date in the form ”ddd mmm dd yyyy hh:mm:ss”. ddd must be SUN, MON,
TUE, WED, THU, FRI, or SAT. mmm must be JAN, FEB, MAR, APR, MAY, JUN,
JUL, AUG, SEP, OCT, NOV, or DEC. dd is the day of the month, yyyy is the year, hh
is the hour of the day (between 00 and 23), mm is the minute, and ss is the second.
The spaces and colons are required, and all 24 characters must be present. If
CREATED is not specified, the current date is assigned when the program is
registered. Note: that hours are expressed in Greenwich means time (GMT).
G
* MODIFIED=“<last modified date>” or M=“<last modified date>” - <last modified
date> is the date the program was last modified. This field is usually maintained by
the control but may be present in the PGM block. The format is as described under
<creation date>. If MODIFIED is not specified, the default is the creation date. Note:
that hours are expressed in Greenwich means time (GMT).
G
* GROUP=“<group>” or G=“<group>” - <group> is a string of from 1 to 32 alphabetic
or numeric characters ,which may include blanks, and that describes an arbitrary
grouping of programs. The field is used in sorting or filtering program directory
displays. If GROUP is present, a group name of blank is used.
G
* EXEMODE=-”“<execution mode>” - <execution mode> is the mode in which the
program is to be run. The values for <execution mode> are STANDARD and
CONTINUOUS:
STANDARD execution mode loads the program in its entirety before execution
begins. Programs executed in STANDARD mode can use all of the advanced
programming control constructs. If a program with STANDARD execution mode will
not fit into the available memory, the operator is presented with a dialog screen that
allows the program to be executed in continuous mode.
CONTINUOUS execution mode loads the program in segments, and can run
programs of any length. However, programs executed in CONTINUOUS mode may
not use any backward branches or loops, and have other restrictions on such
functions as editing the program and continuing execution.
G
* ACCESS=”<access>” or A=”<access>” - <access> defines the status of the
program, which in turn, determines the operations permitted on the program based
A2100Di Programming Manual
Publication 91204426-001
4
Chapter 2
May 2002
Menu
on the current password level. The permitted operations are configurable. The valid
values for <access> are OPEN, EXPERIMENTAL, LIMITED_REL, PRODUCTION
and DO_NOT_RUN.
Briefly, the usual settings are as follow:
An OPEN program is unrestricted.
A PRODUCTION program can be run from either Operator or Setup levels, but
cannot be edited or copied.
An EXPERIMENTAL program can be executed at Setup password level, but not
at OPERATOR password level.
A LIMITED_REL (limited release) program can be executed only a specified
number of times (the number specified by the Count keyword); once the number
of program executions is reached, the program is automatically deleted.
The DO_NOT_RUN access prevents the program from being executed under
any password level. The default access is OPEN.
G
3
* RELEASE=”<count>” or R=”<count>” - <count> is a number between 1 and 99999,
specifying the number of times a program is designated as Access = ”LIMITED_REL”
is permitted to be executed. The number assigned to the keyword “RELEASE”
appears in the “RUN COUNT” field of the program directory. Data entry to the “RUN
COUNT” field is only possible through a (PGM,) block, keyboard entry is not possible.
Block Labels
A Block Label may be applied to any block, however, the Block Label must be the first
item in the block, except for the Block Delete word. The Block Label immediately follows
the preceding End of Block or the Block Delete code. The Block Label has no address,
but consists of an identifier contained in square brackets. Label identifiers are limited to
12 characters, and must follow the rules for variable identifiers.
The Block Label can be the target of a NC program branch command (for example, GO
TO). A separate Block Label is used instead of the Sequence Number as the Sequence
Number may be changed if the program is re-sequenced.
For example:
[START]
[L123]
[23]
[OPERATION 003]
4
Sequence Number
The Sequence Number words, specified by a colon (:) and N, are used to identify the
blocks of an NC program. Use of Sequence Numbers is not required, and the control
places no restrictions on the order of the numbers. As Sequence Numbers are primarily
block identifiers, the use of expressions, decimal points, and minus signs is not allowed.
A2100Di Programming Manual
Publication 91204426-001
5
Chapter 2
May 2002
Menu
The sequence number is an unsigned, one through eleven-digit number as follows:
N6
:6
Sequence Numbers with a colon (:) designate Alignment Blocks, which are blocks that
are planned program restart points. An alignment block should re-establish all modal
values, such as G code states, as it is intended for use as a program start point.
The control automatically resets all G code groups to the configured default state when
an alignment block is encountered, so only those G code states different from the
default state need be programmed.
Sequence Numbers beginning with an N are ignored by the A2100 during program
execution. They serve to identify program blocks for the programmer and operator, are
useful as search targets, and are displayed for the operator.
In general, it is good practice to use unique, increasing value sequence numbers, but
this is not required. Sequence numbers beginning with N require a numerical value,
those beginning with a colon (:) can have either a numeric value or just the colon.
5
Initialisation
When power to the NC control is switched on, the control assumes its initialised state by
automatically activating default selections for modal functions. These functions are:
G40 CDC Off
G45 ACC/DEC On
*G1 Linear Interpolation
*G90 Absolute
*G71 Metric
*G15.1 Bolt Circle Polar Coordinates
*G17 X,Y Plane
*G61 Contouring
*G94 Feed per Minute
*G97 Spindle RPM mode
*G150 Scaling Off
Span Control is normal
G37 No Pattern is Active
Functions shown * are configurable
In addition to control power on, the following also activate default selections for modal
functions:
G
Pressing the DATA RESET button.
G
The control executes M02 or M30 (End of Program).
G
The control executes a Reference Rewind Stop code (:).
A2100Di Programming Manual
Publication 91204426-001
6
Chapter 2
May 2002
Menu
6
Type I Block Word Formats
Each Type I Block word is a specific command or piece of data, and the Preparatory
Codes (G Codes) supported by the control are shown in Chapter 5.
Each NC program block can contain:
G
One Block Label.
G
One Sequence Number (: or N word).
G
One Preparatory Function (G word) from each of the groups.
G
One Miscellaneous Functions (M word) from each group.
G
One of each of the other words as appropriate for the block.
Certain Type I blocks allow additional modifier words, to specify geometric modifications
such as radius or chamfer blends. Additional modifier words are preceded by a comma
followed by a letter. For example:
A block may contain both a C word (specifying a C axis command) and a ,C word
(specifying a chamfer).
Each program word has a format that defines:
G
Whether-or-not a sign is permitted.
G
Whether-or-not a decimal point is allowed.
The formats of the words depend on the address, usage, and the active preparatory
functions (G codes).
7
Format Error Detection
The control checks each word for format errors. Cycle stops when the control detects
either of the following errors:
G
More than one decimal point.
G
A minus sign in a word whose format does not allow a sign.
Further checks are made on some word values. For example, an S word (spindle
speed) value must specify a speed within the range of the transmission.
8
Type I Block Format Rules
Type I blocks use the following sequence:
G
Block delete code, (/, /1 through /9)(must be the first character, if used).
G
Block Label (if used).
G
Sequence number, N or :,
G
G, X, Y, Z, U, V, W, A, B, C, E, L, I, J, K, P, Q, R, F, H, D, O, M, S, T (in any order).
G
End of Block (line feed) character.
A2100Di Programming Manual
Publication 91204426-001
7
Chapter 2
May 2002
Menu
Notes
G Only G and M words may appear more than once within a block. Conflicting G and
M codes, however, are not allowed in the same block.
9
G
Partial Block delete code (// followed by single digit, when on, will skip block
information to the right of the code.
G
Blocks shown as examples in this Manual have spaces between words to facilitate
readability.
Type II NC Program Block Format
The control supports some extensions to EIA-274D that require additional programming
information. This is done using parentheses ( ) to enclose Type II blocks. A Type II
block contains a three-character command followed by a variable number of program
words specifying the additional information needed by the command.
Type II block formats are controlled by the blocks function. The mnemonic designates
the function and determines which word addresses are allowed in the block. The format
of the Type II block is:
[/n] [label] [Nxxx] // (ABC, );
where:
10
G
Block delete code (/, /1 through /9) must be the first character, if used.
G
Block Label (if used).
G
Sequence number (N); (if used).
G
Open parenthesis.
G
Mnemonic - the three letter function (exactly three characters) designator must be
programmed.
G
Words as required.
G
The comma following the function designator must be programmed for most Type
II blocks. Each Type II description defines whether-or-not the comma is required.
G
The close parenthesis is required.
G
A comment, prefixed by a semicolon, may be placed after the close parenthesis.
Flow Control Statements
Flow control statements are a special form of Type II block. All type II block rules apply
with the following exceptions:
G
The mnemonic can contain more than three characters.
G
A comma is not required
Flow control statements are described in depth in Chapter 10.
A2100Di Programming Manual
Publication 91204426-001
8
Chapter 2
May 2002
Menu
11
Assignment Statements
Assignment statements are a means of setting a variable identifier to a certain value.
The format of an assignment statement is:
[/n] [label] [Nxxx] [variable_identifier] = [nnnnn] or [variable_identifier]
where:
G
Block delete code (/, /1 through /9)(must be the first character, if used).
G
Block Label (if used).
G
Sequence number, N or :,
G
Open bracket.
G
Variable identifier.
G
Close bracket.
G
Equal sign.
If a numeric value, or second variable identifier is used, its name must also be enclosed
in brackets.
A2100Di Programming Manual
Publication 91204426-001
9
Chapter 2
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204426-001
10
Chapter 2
May 2002
Menu
Chapter 3
PREPARATORY FUNCTION CODES (G CODES)
Contents
1
2
2.1
2.2
2.3
2.4
2.5
2.6
2.7
2.8
3
3.1
3.2
3.3
4
4.1
4.2
4.3
4.3.1
4.3.2
4.3.3
4.3.4
5
5.1
5.2
5.3
5.4
5.5
5.6
5.7
5.8
5.9
6
6.1
7
7.1
7.2
7.3
Overview............................................................................................... 5
Interpolation ......................................................................................... 5
G0 Rapid Traverse (G0) ....................................................................... 5
G1 Linear Interpolation (G1)................................................................ 6
Chamfer Blending (,C Word) ............................................................... 7
Radius and Fillet Blending (,R Word or R Word) ............................... 8
Circular (G2, G3) .................................................................................. 9
Helical (G2, G3) .................................................................................. 13
Helical Example (CAM) ...................................................................... 15
Cornering ........................................................................................... 17
Exact Stop G9, Positioning/Contouring Modes G60/61................... 18
G 09 Exact Stop G9............................................................................ 18
G60 Positioning Mode G60................................................................ 18
G 61 Contouring Mode G61............................................................... 18
G61.1, G61.2, G61.3 Auto Corner Speed Override (Option) ............ 19
G61.3 Block Parameters.................................................................... 19
Scaling (G150, G151) ......................................................................... 20
Scaling Examples .............................................................................. 22
Example 1........................................................................................... 22
Example 2........................................................................................... 23
Example 3........................................................................................... 24
Example 4........................................................................................... 25
Nonmodal Commands....................................................................... 26
Dwell G4 ............................................................................................. 26
G8 Suppress Interpolation ................................................................ 27
G8 Programming Example ................................................................ 27
Contouring Rotary Axis Unwind (G12) ............................................. 27
Plane Select G17, G18, G19............................................................... 28
Automatic Return to/G29 from Reference Point Return.................. 28
Automatic Return To Reference Point (G28).................................... 30
Automatic Return From Reference Point (G29) ............................... 30
Machine Unload Position (G28 P4) ................................................... 30
Co-ordinates....................................................................................... 30
Rectangular (Cartesian) Co-ordinates.............................................. 31
Plus and Minus Programming .......................................................... 33
G70 Inch/G71 Metric Programming (G70, G71)................................ 34
Polar Co-ordinate Programming (G15.1, G15.2) (E and L words)... 35
Bolt Circle Programming (G15.1)...................................................... 35
A2100Di Programming Manual
Publication 91204451- 001
1
Chapter 3
May 2002
Menu
7.4
7.5
7.6
7.7
7.8
7.9
7.10
8
8.1
8.2
8.3
8.3.1
8.4
8.5
8.6
9
10
10.1
10.2
10.3
10.3.1
10.4
10.5
10.6
10.7
10.8
10.9
10.10
10.11
11
11.1
11.2
11.3
11.3.1
11.3.2
11.3.3
12
12.1
12.2
12.3
12.4
13
13.1
13.2
G15.2 Part Contour Programming..................................................... 36
G13.1 Cylindrical Interpolation Off (Option) ..................................... 38
G7.1 Cylindrical Interpolation (Option) ............................................. 38
G7.1 Cylindrical Interpolation Programming Example .................... 41
Absolute Input G90 ............................................................................ 42
Incremental Input G91........................................................................ 44
Set High Limits (SHI) and Set Low Limits (SLO) Blocks.................. 45
Feedrate Programming ...................................................................... 48
G94 - Feed Per Minute Feedrate ........................................................ 48
G95 - Feed Per Tooth Feedrate ......................................................... 49
G93 - I/T Feedrate (Inverse Time) ...................................................... 49
Feedrate - Circular Interpolation ....................................................... 52
G45 Automatic Acceleration/G46 Deceleration (G45, G46) ............. 53
Selectable ACC/DEC Profiles (G45) .................................................. 54
Automatic Acceleration/Deceleration ............................................... 54
Selectable Velocity Control Profiles ................................................. 54
Configuration Parameters ................................................................. 55
Explanation of G45, G45.1, G45.2 Codes.......................................... 56
General Machining (G45) ................................................................... 56
High Speed Contour Roughing (G45.1) ............................................ 56
High Speed Contour Finishing (G45.2) ............................................. 56
User Specified (G45.01, G45.02, G45.03) .......................................... 57
Acceleration/Deceleration OFF (G46) ............................................... 57
Rapid Transverse (G0) ....................................................................... 57
Z Axis Feedrate Limiting.................................................................... 57
Spindle Control (Spindle Speeds)..................................................... 58
G97 Spindle Speed in RPM (G97)...................................................... 58
G97.1 Constant Spindle Speed in SFM (G97.1) ................................ 58
G96 Constant Surface Speed (G96) Operation................................. 59
Spiral Interpolation (G2, G3).............................................................. 59
Introduction ........................................................................................ 59
Spiral Interpolation Example ............................................................. 60
Multi-revolution Spiral ....................................................................... 60
Multi-revolution Spiral Interpolation Example.................................. 60
Conical Interpolation (G2, G3) ........................................................... 62
Multi-revolution Conical Interpolation Example............................... 62
Spline Interpolation (G5.X) ................................................................ 63
Spline Programming .......................................................................... 64
Default Values and Limits for Spline Parameters ............................ 65
Corner Blend – G5.2/G5.3 .................................................................. 65
Curve Fitting Details .......................................................................... 65
Tilt Spindle G Codes .......................................................................... 68
G52.1 Spindle Normal Co-ordinate System ...................................... 68
G44/G44.1 Multi-axis Tool Length Compensation............................ 69
A2100Di Programming Manual
Publication 91204451- 001
2
Chapter 3
May 2002
Menu
13.3
13.3.1
G44 Apply Tool Length Deviation and Tool Offset .......................... 69
G44.1 Apply Total Tool Length ......................................................... 69
A2100Di Programming Manual
Publication 91204451- 001
3
Chapter 3
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204451- 001
4
Chapter 3
May 2002
Menu
1
Overview
Preparatory function codes are used to command some action or to select a mode of
operation, and are programmed using the G word. The G word consists of a whole
number of up to three digits and may in some cases contain a decimal point followed by
one or two digits.
G code leading zeros are valid, but not recommended, as they increase the time
required to execute a program block.
The G word value is used to select the command to execute, or the mode to set,
therefore the G word value must be one of the recognised codes. There are several
groups of codes, as shown in the table in the Chapter 14.
Any program block can only contain one code from each group. All codes except those
in the Nonmodal and Nonmodal modifier group are modal, i.e., once a value is
programmed it is effective until it is changed by programming another code from the
same group. Each modal group has a default state, most of which are configurable.
Codes marked ”*” in the Appendix table are configurable reset states. Groups whose
reset state is not configurable (such as CDC, which must default to ”off” or G40, have the
fixed default state shown with a double asterisk, ”**”).
The default state is activated at control power on, by a Data Reset, and also at End of
Program. Additionally, each modal group is reset to its default state when an Alignment
Block (: word) is encountered.
Nonmodal codes marked ”Nonmodal modifier” are permitted in blocks containing motion
and modify the motion (G9) or the interpretation of the axis word values (G50, G98, and
G98.1).
A complete list of G codes is given in Chapter 14.
2
Interpolation
2.1
G0 Rapid Traverse (G0)
A rapid traverse G0 block moves the machine axes from the current position to the
commanded position at the machines maximum rate, as shown in Fig 2.1. Selection of
G0 causes the motion to be made at the rapid traverse rate, which is determined by the
maximum speed of the axes that are moving. The rate is selected such that at least one
axis is moving at its maximum speed.
The G0 preparatory function is subject to the following programming rules and
conventions:
G
The command position may be expressed in rectangular or polar co-ordinates.
G
The G0 code is modal and remains effective until replaced by another interpolation
G code, or the control is initialised.
G
The G0 code cannot be programmed in the same block with any other of the
preparatory functions from the Interpolation groups and some nonmodal G codes.
A2100Di Programming Manual
Publication 91204451- 001
5
Chapter 3
May 2002
Menu
G
Feedrate commands (F words) programmed in the G0 block are retained by the
control, but do not become effective until the next interpolation preparatory function
requiring a feed rate is acted upon.
G
At least one zero of the G0 code must be programmed (G0).
Fi
1
Figure 2.1 Rapid Traverse
2.2
G1 Linear Interpolation (G1)
A linear interpolation G1 block moves all programmed axes from the current position,
along a straight line vector, to the commanded position at the programmed feedrate, as
shown in Fig 2.2.
If a servo controlled indexing rotary axis is fitted, it typically completes its movements
before any linear axis motion from the same block is started. In contrast, a contouring
rotary axis moves simultaneously, with linear axes programmed in the same block.
The G1 code is subject to the following programming rules and conventions:
G The command position may be expressed in rectangular or polar co-ordinates.
G The G1 code is modal and remains in effect until replaced by another interpolation G
code.
G The feedrate command may be expressed in terms of feed distance per minute
(G94), feed distance per tooth (G95), or inverse time (G93).
Figure 2.2 Linear Interpolation
A2100Di Programming Manual
Publication 91204451- 001
6
Chapter 3
May 2002
Menu
2.3
Chamfer Blending (,C Word)
This control provides a means for generating a chamfer blend between any two
successive linear (G1) and circular (G2 or G3) programmed motions, as shown in Fig
2.3. A chamfer blend is specified by programming a ”,C” word whose value is the size of
the chamfer. The control automatically inserts a linear move to break the corner formed
by the block containing the ,C word and the next motion block. The size of the chamfer
is the distance from the end of the block containing the ,C word to the point at which the
chamfer starts.
For a linear span, the chamfer distance is simply the distance from the chamfered corner
to the beginning or end of the chamfer. For a circular span, the chamfer distance is
measured along the chord from the intersection of the arc and the other block, to the end
of the chamfer.
Figure 2.3 Chamfer Blending ,C Word
The size of the chamfer is the absolute value of the ,C word, and the chamfer must be
smaller than the block in which it appears and the subsequent motion block. Chamfer
blends are valid between any combination of linear (G1) and major plane circular (G2 or
G3) blocks.
A block containing a ,C chamfer blend word can be separated from the next motion block
by a number of non-motion blocks. The exact number depends on the total look ahead
allowed by the system configuration. No programmed motion is permitted in any axis not
in the selected plane in either the block containing the ,C word or the following motion
block.
Non-motion blocks include Type I blocks with a non-modal preparatory function such as
G4, (excluding G9, G50, G98, G98.1).
The blocks listed below prevent the program from looking ahead, and cannot be
programmed between the motion spans joined by automatic radius or filetfillet insertion:
G
A block containing G12, G92.1 G98, G98.1, G99 codes.
G
A block containing a tool change.
A2100Di Programming Manual
Publication 91204451- 001
7
Chapter 3
May 2002
Menu
2.4
G
(SHI,
G
(SLO,
Radius and Fillet Blending (,R Word or R Word)
The control provides a means for generating a circular arc blend between any two
successive linear (G1) and circular (G2 or G3) programmed motions. The blend occurs
in the selected plane only, as shown in Fig 2.4.
A radius blend is selected by programming an ,R word whose value is the radius of the
blend radius or fillet required. The control automatically inserts a circular arc of the
specified radius tangent to the block containing the ,R word and the subsequent motion
block. The radius blend must be small enough to ensure that the tangent point between
the blend arc and the block exists in the block.
Radius blends are valid between any combination of linear (G1) and major plane circular
(G2 or G3) blocks. This feature permits a number of non-motion blocks to separate the
two moves to be blended. The exact number depends on the total look ahead allowed
by the system configuration. No programmed motion is permitted in any axis not in the
selected plane in either the block containing the ,R word or the following motion block.
Recommended programming practice is to use the ”,R” form for specifying radius blends.
However, radius blends may be specified by using just ”R” for the radius word address
for compatibility with Release 1 software. If the R address without the comma is used,
radius blend cannot be used in a block with PQR CDC turned on because of the address
conflict.
The ,R word value is always a positive radius and is unaffected by the state of the
absolute/incremental mode.
Non-motion blocks include Type I blocks with a non-modal preparatory function such as
G4, (excluding G9, G50, G98, G98.1).
The blocks listed below prevent the program from looking ahead, and cannot be
programmed between the motion spans joined by automatic radius or filetfillet insertion:
G
A block containing G12, G92.1 G98, G98.1, G99 codes.
G
A block containing a tool change.
G
(SHI,
G
(SLO,
The program below is an example of automatic radius and filetfillet insertion. Notice that
absolute inch dimensions are used, and G1 linear interpolation mode is used throughout
the machining example. Control calculations for radii and fillets are based on the ,R
word programmed:
G
:001
G
N810 G0 G90 X6 Y2.1875
G
N820 G1 X5.1875 R.0625 F10
G
N830 Y2.9375 R.4375
G
N840 X4.1875 R.0625
G
N850 Y4.0625 R.4375
A2100Di Programming Manual
Publication 91204451- 001
8
Chapter 3
May 2002
Menu
G
N860 X3
G
N870 M2
Figure 2.4 Automatic Blend Radii and Filefillet Insertion
2.5
Circular (G2, G3)
A Circular Interpolation G2/G3 block moves the machine from its current position to the
commanded position along a circular arc, as shown in Fig. 2.5. The rate of travel is
uniform around the arc with tangential vector feedrate equal to the programmed
feedrate.
A circular path may be generated in any of the major planes by programming the
appropriate plane select code, G17 for XY, G18 for ZX or G19 for YZ. The arc may be
specified by programming the centre point using the I, J, and K words to specify the
centre co-ordinates in X or U, Y, or V, and Z or W respectively. Only the centre point
values for the axes that lie in the selected plane are used.
Alternatively, the circle arc can be specified by programming the circle radius using the P
word. In this case, the control computes the location of circle centre so that an arc of the
specified radius connects the current position and the commanded endpoint.
Programming a positive radius specifies the shorter of the two possible arcs connecting
the current position and the commanded position; programming a negative radius
selects the longer arc.
The centre point specification words (I, J, and K) can be configured to be always
absolute, always incremental distances from the start point of the arc, or
absolute/incremental switchable using G90/G91. G2.01 and G3.01, these are identical to
G2 and G3 except that centre point specification words (I, J and K) are always absolute
co-ordinates. G2.02 and G3.02 are identical to G2 and G3 except that centre point
specification words (I, J and K) are always incremental co-ordinates.
A2100Di Programming Manual
Publication 91204451- 001
9
Chapter 3
May 2002
Menu
Circular interpolation may be programmed in two ways:
G
Programming G2 or G3 preparatory functions together with I, J, K, words to define
the centre point of the arc.
G
Programming G2 or G3 preparatory functions, together with a P word, to define the
radius of the arc.
Any arc length up to one full circle can be programmed in one block. A complete circle is
specified by programming the endpoint to be the same as the current position. In this
case, the centre point must be specified as the radius and one point does not uniquely
determine the circle.
Preparatory function codes G2 and G3 are used for programming circular interpolation.
These codes determine the direction of the circular path as viewed from the positive end
of the axis that is perpendicular to the plane of the interpolation:
G
G2 code causes the tool to proceed in a clockwise (CW) path.
G
G3 code causes the tool to proceed in a counter clockwise (CCW) path.
These codes are programmed in the block where circular interpolation becomes
effective, and remains effective, until a new interpolation mode preparatory function code
is programmed.
Figure 2.5 Circular Interpolation
Starting Point
The starting point (X or U, Y or V, Z or W co-ordinate) is the result of a previous block of
information, either the end point of a previous arc (circular interpolation), or the end point
of a line (linear interpolation).
A2100Di Programming Manual
Publication 91204451- 001
10
Chapter 3
May 2002
Menu
Centre Point
The centre point (X or U, Y or V, or Z or W co-ordinate) is the centre of the circular arc,
as shown in Fig. 2.6:
G
I word describes X or U co-ordinate value.
G
J word describes Y or V co-ordinate value.
G
K word describes Z or W co-ordinate value.
Figure 2.6 Circular G2 and G3
End Point
The end point, (X or U, Y or V, and/or Z (or W) co-ordinate) is the final point where the
centreline of the cutter path completes the circular arc. The end point is always
described by X or U, Y or V, and/or Z (or W) words, and must be programmed in every
block using circular interpolation.
Radius
The radius is the distance from the centre point to any position on the arc. The P word
may be used to define the radius of the arc, rather than using the I, J, K words to define
the centre point of the arc.
A2100Di Programming Manual
Publication 91204451- 001
11
Chapter 3
May 2002
Menu
Figure 2.7 Arc G2 and G3
END POINT B
P WORD GREATER
THAN 180 DEGREE
P WORD LESS THAN
OR = TO 180 DEGREE
TWO POSSIBLE ARCS
BETWEEN POINTS A & B
IN CCW DIRECTION
START POINT A
Figure 2.8 Arc G2 and G3
Unless the length of the arc from the start point to the command point is exactly 180
degrees, there are two arcs with the same radius and direction connecting the two
points, as shown in Figs. 2.7 and 2.8. A positive P word selects the arc less than 180
degrees, and a negative P word selects the arc greater than 180 degrees. The P word is
not modal, but it does establish modal centre points in the same way as the I, J and K
words.
General Programming Considerations
G
Either the arc radius or centre point method may be programmed, however, only one
method, may be programmed in a block.
If the centre location of the arc is the most critical dimension, the I, J, K method is
preferable.
A2100Di Programming Manual
Publication 91204451- 001
12
Chapter 3
May 2002
Menu
If the radius of the arc, or the location of the endpoint of the arc is the most critical
dimension, the P word method is preferable.
G
Arcs up to 360 degrees can be programmed in a single block when the centre point
method is used.
G
Arcs less than 360 degrees may be programmed in a single block when the radius
specification method is used. The radius method is not recommended for arcs of
greater than 359 degrees.
G
An arc does not have to start or end on a quadrant line.
G
Either the absolute or incremental modes may be used. The radius (P word) is not
affected by which mode is active. The I, J, K words may be affected by the
absolute/incremental state, depending on the configurations selected. See Chapter 9
to set default.
G
If an I, J, and/or K word is programmed together with a P word, an alarm will be
posted.
G
An error condition results with P word radius programming if the current position and
the command position are more than twice the radius apart.
G
An error results with I/J/K word centre point programming if the current position and
the command position are different distances from the centre of the circle centre.
An alarm results if the starting radius (the distance from the initial point to the circle
centre) and the ending radius (the distance from the circle centre to the command
point) differ by more than 0.25 mm (0.010 inch).
2.6
G
The feedrate is measured along the tool path in the direction of the arc. The
maximum and minimum feedrates are the same as allowed for linear movements.
G
G2.01 and G3.01 are identical to G2 and G3 except that centre point specification
words (I, J and K) are always absolute co-ordinates.
G
G2.02 and G3.02 are identical to G2 and G3 except that centre point specification
words (I, J and K) are always incremental co-ordinates.
Helical (G2, G3)
Helical interpolation may be considered a special type of circular interpolation, and many
of the same rules apply to both. Centre point specification words (I, J and K) can be
configured to be always absolute, always incremental distances from the start point of
the arc, or absolute/incremental switchable using G90/G91. G2.01 and G3.01. These
codes are identical to G2 and G3 except that centre point specification words (I, J and K)
are always absolute co-ordinates. G2.02 and G3.02 are identical to G2 and G3 except
that centre point specification words (I, J and K) are always incremental co-ordinates.
Whenever a circular interpolation block contains a command for the third axis (ie. one
that is not in the plane selected by G17, G18, or G19) helical interpolation occurs. In this
case the following information is required:
G Direction of the helix (G2 CW, G3 CCW).
G Centre point of the arc (I, J, K, or P).
G Lead of the helix (I or J or K).
G End point of the move (X or U, Y or V, Z or W).
A2100Di Programming Manual
Publication 91204451- 001
13
Chapter 3
May 2002
Menu
Direction Of the Helix
This is defined as clockwise or counterclockwise in the selected circular interpolation
plane (in normal circular programming).
Centre Point of the Arc
This is programmed using I, J, K or P words (as in normal circular programming).
Lead of Helix
This is programmed using I or J or K words corresponding to the non-circular axis, and is
defined as the feed along the third axis to be made for each 360 degrees of circular
motion in the other two axes.
End Point of Move
This is programmed using X or U, Y or V, and Z or W words. The two words
representing the selected circular plane define the circular arc end point, (as in normal
circular programming).
The third axis word defines the end point of the helical move in that axis, and is treated
according to special rules to ensure compatibility with the helical lead.
Cutter Diameter Compensation
This is defined as for normal circular programming.
Rules Governing the Helical Axis End Point Co-ordinate
When the control detects that a helical move has been programmed, it performs the
following sequence:
1. Calculates the total distance to be moved in the non-circular axis.
2. Divides this distance by the programmed helix lead, and uses the integer part of the
result to determine the number of complete circles to be interpolated.
3. Helically interpolates the calculated number of complete circles and continues until
the circular end point is reached.
Note that the helix axis dimension must be consistent with the distance along the helix
axis determined by the helix lead, and with the angle between the starting and ending
points.
A2100Di Programming Manual
Publication 91204451- 001
14
Chapter 3
May 2002
Menu
2.7
Helical Example (CAM)
SET TOP OF PART=11"
HELIX .5" DEEP AT END POINT
TOOLING = 1" DIA. END MILL
X=15"
A=32.5
O
Y
1.5
R=2
Y=10"
CAM
X
Figure 2.9 Helical Example (Cam)
Start point of helix -- X, Y, Z
Centre of circle -- I, J
X=15 - R (R=radius)
Y=10” Z=11” I=15” J=10”
X=15 - 2
X=13
End point of helix -- X, Y, Z
X =15 + (R x cos A)
Y =10 +(R x sin A) Z = 10.5”
X =15 + (2 x cos 32.5)
Y =10 +(2 x sin 32.5)
X =15 + (2 x .8434)
Y =10 +(2 x sin .5373)
X =15 + 1.6868
Y =10 +1.0746
X =16.6868”
Y =11.0746”
Lead of helix -- K = Z motion for 360 degrees (same rate of descent)
K =angle ratio 360 / (180 +32.5) x Z move distance (11.0 - 10.5)
K =1.6941 x .5
K =.8471”
NC Part Program:
: 00010 G0 X18 Y16 Z18 M6 T1
N00030 X13 Y10 Z11.2 S2674 M3
N00040 G1 F10 Z11
N00045 (MSG, CUT HELIX--212.5 DEGREE ARC CCW, DESCEND .5 INCH INTO
PART)
N00050 G3 G17 X16.6868 Y11.0746 Z10.5 F50 K.8471 I15 J10
N00055 (MSG, HELICAL INTERPOLATION COMPLETED)
N00060 G1 Z11.2
N00070 G0 X18 Y16 Z18
N00080 M2
A2100Di Programming Manual
Publication 91204451- 001
15
Chapter 3
May 2002
Menu
Alternates
G
The alternate N00050 uses the controls mathematical facility to calculate values for
the endpoint and lead (X, Y, K).
N00050 G3 G17 X15+(2*COS(32.5))Y10+(2*SIN(32.5)) Z10.5
F50 K360/212.5*(11-10.5) I15 J10
G
The alternate N00050 uses polar co-ordinates to specify values for the endpoint (X,
Y, E, L)
N00050 G3 G17 X15 Y10 E32.5 L2 Z10.5 F50 K.8471 I15 J10
Helical Example (5 Revolutions)
Fig 2.10 and the following example of helical interpolation show the concept and the
programming techniques for performing a helical cut consisting of multiple revolutions.
Many different uses can be found including thread milling, rough boring of holes, cutting
an oil grove or cam etc. using single point tooling or multi tooth cutters.
The example gives the details of how to produce the required machine movement
without regard to specific tooling and operation.
G
Centre of circle X =15, Y =10
G
Diameter of helix =4”
G
Let top of move be Z =11”
G
Total linear axis move =6.7”
G
(Z move in negative direction)
G
Number of revolutions =5
Start point of helix -- X, Y, Z
X =centre + radius
X =15 +2
X =17”
Y =10”
Z =11”
End point of helix -- X, Y, Z
X =17”
Y =10”
Z = 11 - 6.7
Z =4.3”
Lead of helix -- K =Z motion for 360 degrees of circular motion
K =Z move distance/number of revolutions
K =6.7/5
K =1.34”
Centre of circle
I =15” J =10”
A2100Di Programming Manual
Publication 91204451- 001
16
Chapter 3
May 2002
Menu
Z Move
distance
K
+Z
+Y
+X
Figure 2.10 Helical Example: 5 Revolutions
NC Part Program:
:00010 G0 X18 Y16 Z18 M6 T1
N00030 X17 Y10 Z11.2 S1500 M3
N00040 G1 F10 Z11
N00045 (MSG, CUT HELIX-- 5 REVOLUTIONS DESCEND 6.7 INCH)
N00050 G3 G17 X17 Y10 Z4.3 F50 K1.34 I15 J10
N00055 (MSG, HELICAL INTERPOLATION COMPLETED)
N00060 G1 X15
N00070 G0 X18 Y16 Z18
N00080 M2
Alternately, block N00050 written as shown below would allow the control to calculate
the value for K to cut the helix.
N00050 G3 G17 X17 Y10 Z4.3 F50 K6.7/5 I15 J10
2.8
Cornering
Machine tool servo controls normally operate such that the machine position lags the
instantaneous command position. The amount of lag is referred to as the following error.
The following error is generally along the cutter path during straight line moves, and
therefore does not cause any geometric error in the workpiece. However, when there is
a sudden change of direction, such as a right angle turn, the following error may cause
the actual tool path to round the corner.
In some instances this is desirable, for example when continuous contour machining is
being performed. However, on other occasions, it is important to make an accurate
corner with minimum error. This accuracy may be required when machining a sharp
A2100Di Programming Manual
Publication 91204451- 001
17
Chapter 3
May 2002
Menu
corner, or to ensure that a tool has cleared the workpiece before moving to another
operation in drilling or boring operations.
The control supports both positioning and contouring modes of operation, and also
provides a nonmodal single block exact stop capability. Positioning mode, selected by
G60, causes the axis motion to stop at each end of block until the following error has
dropped below a configurable threshold value. Contouring mode, selected by G61,
allows the commanded motion to continue smoothly without pause from one block to the
next block. G60 and G61 are mutually exclusive, and selecting either of these codes
cancels any other member of the group.
3
Exact Stop G9, Positioning/Contouring Modes G60/61
3.1
G 09 Exact Stop G9
Exact stop is a nonmodal preparatory function that causes the control to treat the block
containing the G9 as a positioning mode block (see positioning mode G60). The effect
of a G9 in any block is to cause the machine to decelerate to a stop, and pause until the
following error is reduced to a configurable value thus ensuring a sharp corner. If the
control is already in positioning mode (G60), a G9 has no effect.
3.2
G60 Positioning Mode G60
Positioning mode ensures sharp corners and minimises undershoot or corner rounding.
Axis motion decelerates to a stop and further motion is inhibited until the following error
is below the configurable tolerance value.
3.3
G 61 Contouring Mode G61
Contouring mode maintains the programmed feedrate (unless limited by automatic
acceleration/deceleration to stay within the axis acceleration limits). Motion between
blocks is blended (no pause between blocks).
When contouring mode is used, the control detects the end of span as soon as the
command signal reaches its final position. When high feedrates are programmed with
abrupt changes in direction, as shown in Fig. 3.1, corner rounding can result.
Figure 3.1 Corner Rounding due to Feed Error
A2100Di Programming Manual
Publication 91204451- 001
18
Chapter 3
May 2002
Menu
Program Considerations
Programmed codes G60 and G61 remain active until replaced by the opposing code and
only one of these codes can be programmed in a block. The positioning/contouring
mode is reset to a configured selection at control power on, data reset, and by a colon
block.
4
G61.1, G61.2, and G61.3 Automatic Corner Speed Override
(Option)
This feature provides a programmable percent feedrate decrease on exit and entry to an
inside corner. The distance over which the decreased feedrate is effective is also
programmable for both entry and exit by using G61.3. Also, Automatic corner speed
override must know where the work surface is with respect to the cutter path, and two G
codes are provided for this purpose:
G61.1 selects cutter to the left of the work
G61.2 selects cutter to the right of the work
Note that automatic corner speed override operates in the machine plane selected by
the active plane select code (G17 for XY, G18 for ZX, G19 for YZ).
4.1
G61.3 Block Parameters
Word Description
Comments
Entry Span
I word = Modal entry span length
(default is zero)
J word = Modal exit span length
(default is zero)
K word = Modal maximum inside
corner angle (default is 135
degree)
P word
R word
I
Exit Span
J
K = Maximum Angle
for inside corner
Modal percent feedrate override for entry span (default is
100%)
Modal percent feedrate override for exit span (default is
100%)
Programming Considerations
G
Automatic corner speed override is active only for linear and major plane circular
and helical motion in the selected machine plane; it is not active for rapid moves
(G0).
G
The diameter of the cutter, and the amount of material being removed determine the
distance from the corner at which the increased load begins.
G
If the angle between the entry move and exit move spans is less than the K word
value then:
During the entry span the feedrate is decreased from the programmed feedrate to the
corner feedrate (P * Programmed feedrate) proportionally over the entire entry span.
A2100Di Programming Manual
Publication 91204451- 001
19
Chapter 3
May 2002
Menu
During the exit span the feedrate is increased from the corner feedrate to the exit
corner feedrate (R * Programmed feedrate) proportionally over the entire exit span.
When the exit span end is reached, programmed feedrate is resumed.
I, J, and K words must all be positive values. P and R words must be between 1%
and 100%. K word values must be between 0 and 180 degrees.
Automatic Corner Speed Programming Example (Fig. 4.1)
: G0 G17 G70 G90
N01 T03 M6 ;CSO XY linear to linear
;
;
Automatic Corner Speed Override test
;
I = entry span length
;
J = exit span length
;
K = maximum inside corner angle
;
P = entry span feedrate override percent
;
R = exit span feedrate override percent
;
N10 G1 X2.82842 Y0 Z5 F800 S500 M3 ; position axeN11 Z-.1 ; position Z axis
N12 G61.3 I0.6 J0.4 K91 P10 ; Establish entry and exit span and feedrate override
N13 G61.1 F50 M49 ; set cutter path left
N14 X1.41421 Y1.41421 ; set axis feed move
N15 X0 Y0 ; set axis end move
N16 G61 M48 ; set contouring mode
N17 G0 Z10 ; position Z axis
N18 M02 ; end program
Figure 4.1 Automatic Corner Speed Programming
4.2
Scaling (G150, G151)
All. or any part of an NC program can be scaled by programming a scale factor, and the
co-ordinates from which the scaled positions are computed, in the G151 block.
A2100Di Programming Manual
Publication 91204451- 001
20
Chapter 3
May 2002
Menu
The I, J, and K words specify the co-ordinates from which the scaled dimensions are
computed, and the P word specifies the scale factor. If the I, J, and K words are not
programmed, the current program position is used as the scaling centre.
No motion may be programmed in a G151 block.
When scaling is active, all command points and circle centre points in subsequent blocks
are scaled by moving the programmed points along a vector from the scaling centre
through the programmed point. In helical mode, the lead of the helix is also scaled by
the scale factor.
Scale factors (P words, see Fig. 4.2) less than one, move the programmed points closer
to the scaling centre, scale factors greater than one move the programmed points away
from the scaling centre.
Scaling is turned off by programming a G150, which turns off the scaling without causing
machine motion.
No movement can be commanded in a G150 block. Scaling cannot be turned on (G151)
or off (G150) with cutter diameter compensation active.
Scaling cannot be turned on or off if in G2 or G3 circular mode.
Figure 4.2 Scaling
The following tool-related values in fixed cycles are not scaled:
G
The U and V word tip offsets in G86, G87, and G88.
G
The K word tool nose extension dimension in G80 and G87.
G
The K word peck feed increment in G83 and G84.1.
G
The finish stock amounts in the milling cycles.
A2100Di Programming Manual
Publication 91204451- 001
21
Chapter 3
May 2002
Menu
Reference Point Calculation
During normal programming the scaling factor, and X, Y, Z co-ordinates of the scaled
workpiece that is to be machined are known. What is not known are the I, J, and K
scaling reference points, the following formula can be used to calculate these points:
I for X axis
=
J for Y axis
=
K for Z axis
=
PS–P0
P0– P–1
PS–P0
P0–
P–1
PS–P0
P0–
P–1
Where:
P0 = The original programmed point.
Ps = The programmed scaled point where you want to go.
P = The scaling factor.
4.3
Scaling Examples
4.3.1
Example 1
The sample program and Fig. 4.3 show how scaling is used to modify a rectangular
pattern. In the G151 block, note how I2 and J1.5 are used as the scaling reference
points, while P.5 dictates scaling the original rectangular pattern to half size.
To calculate scaling reference points:
PS–P0
I or J or K = P0– P–1
1–0
I=0–.5–1 or I = 2
.75-0
J=0- .5-1 or J = 1.5
(MSG, ”SCALING WITH I=2, J=1.5 AND P=.5”)
(MSG, ”INCH, ABSOLUTE AND POSITIONING MODES”)
:1000 G0 T6 M6
N0010 G90 G70 G60 G0 X-0.5 Y0 Z1 S200 M3
N0020 G151 I2 J1.5 P.5
N0030 G1 F150 X0 Y0
N0040 X4 Y0
N0050 X4 Y3
N0060 X0 Y3
N0070 X0 Y0
N0080 G150
N0090 X-.5 Y0
N0100 M2
A2100Di Programming Manual
Publication 91204451- 001
22
Chapter 3
May 2002
Menu
HALF SCALE REFERENCE I = 2 inches J = 1.5 inches P = .5
SCALED
RECTANGLE
ORGINAL
RECTANGLE
SCALING
REFERENCE
POINT
(I2, J1.5)
(X0, Y3)
SCALED
PROGRAMMED
POINT
ORIGINAL
PROGRAMMED
POINT
(X4, Y3)
(X3, Y2.25)
(X1, Y2.25)
(X1, Y.75)
CUTTING
DIRECTION
(X3, Y.75)
(X0, Y0)
(X4, Y0)
Figure 4.3 Scaling Example 1
4.3.2
Example 2
The sample program and Fig.4.4 show how the scaling reference point shifts the scaled
rectangle. In the G151 block, note how I5 and J4 are used as the scaling reference
points, while P.5 dictates scaling the original rectangular pattern to half size.
To calculate scaling reference points:
PS–P0
I or J or K = P0– P–1
2.5–0
I=0– .5–1 or I = 5
2.0–0
J=0– .5–1 or J = 4
(MSG, ”SCALING WITH I=5, J=4 AND P=.5”)
(MSG, ”INCH, ABSOLUTE AND POSITIONING MODES”)
:1000 G0 T6 M6
N0010 G90 G70 G60 G0 X-0.5 Y0 Z1 S200 M3
N0020 G151 I5 J4 P.5
N0030 G1 F150 X0 Y0
N0040 X4 Y0
N0050 X4 Y3
N0060 X0 Y3
N0070 X0 Y0
A2100Di Programming Manual
Publication 91204451- 001
23
Chapter 3
May 2002
Menu
N0080 G150
N0090 X-.5 Y0
N0100 M2
(X2.5, Y2.0)
ORIGINAL
PROGRAMMED
POINT
SCALED
PROGRAMMED
POINT
Figure 4.4 Scaling Example 2
4.3.3
Example 3
The sample program and Fig.4.5 show how scaling is used to modify a circular part
feature. In the G151 block, note how I100 and J100 are used as the scaling reference
points, while P.5 dictates scaling the original circle to half size.
To calculate scaling reference points:
PS–P0
I or J or K = P0– P–1
50 – 0
I=0– .5–1 or I = 100
100 – 100
J=100– .5–1
or J = 100
:101009 G71 G0 X0 Y50 T6 M6 S200 M3
N001 G151 I100 J100 P.5
N005 G0 X0 Y100
N010 G17 G02 X0 Y100 I100 J100 F5080
N015 G00 X0 Y100
N016 G150
N020 G0 X0 Y50
N030 M2
A2100Di Programming Manual
Publication 91204451- 001
24
Chapter 3
May 2002
Menu
HALF SCALED REFERENCE I = 100mm J = 100mm P = .5
ORIGINAL
PROGRAMMED
START AND
END POINT
OF CIRCLE
(X0, Y100)
SCALED AND ORIGINAL
PROGRAMMED
POINT
(X100, Y100)
SCALING
REFERENCE
POINTS
(I 100, J100)
DIREC
TION OF
CUTTING
SCALED
PROGRAMMED
START AND
END POINT
OF CIRCLE
(X50, Y100)
ORIGINAL
CIRCLE
START POINT
AND END
POINT OF
PROGRAM
(X0, Y50)
SCALED
CIRCLE
Figure 4.5 Scaling Example 3
4.3.4
Example 4
The sample program and Fig. 4.6 below show how the scaling reference point shifts the
circle pattern. In the G151 block, note how I200 and J200 are used as the scaling
reference points, while P2 dictates scaling the original circle pattern to twice the size.
To calculate scaling reference points:
PS–P0
I or J or K = P0– P–1
–200 – 0
I=0– 2–1 or I = 200
0 – 100
J=100– 2–1 or J = 200
:101009 G71 G0 X0 Y50 T6 M6 S200 M3
N001 G151 I200 J200 P2
N005 G0 X0 Y100
N010 G17 G02 X0 Y100 I100 J100 F5080
N015 G00 X0 Y100
N016 G150
N020 G0 X0 Y50
N030 M2
A2100Di Programming Manual
Publication 91204451- 001
25
Chapter 3
May 2002
Menu
DOUBLE SCALED REFERENCE I = 200mm J = 200mm P = 2
ORIGINAL
ORGINAL
PROGRAMMED
PROGRAMMED
POINTS
START AND
(X100, Y100)
END POINT
OF CIRCLE
(X0, Y100)
DIREC
TION OF
CUTTING
START AND
END POINT
OF PRO
GRAM
(X0, Y50)
SCALED
PROGRAMMED
START AND
END POINT
OF CIRCLE
(X-200, Y0)
SCALING
REFERENCE
POINTS
(I 200, J200)
ORIGINAL
CIRCLE
SCALED
PROGRAMMED
POINTS
(X0, Y0)
SCALED
CIRCLE
Figure 4.6 Scaling Example 4
5
Nonmodal Commands
5.1
Dwell G4
Programmable dwell (G4) provides the capability to delay program execution for a
specified period.
Dwell is programmed using a G4 preparatory function and either an F or S word. The F
or S word specifies the duration of the dwell in seconds or spindle revolutions
respectively. Both words cannot be programmed in the same block. A negative or zero
F word or S word results in no dwell.
The S word is used to specify the dwell period in terms of spindle revolutions.
If neither F or S is programmed, a fixed 0.5 second dwell is performed.
Previously established spindle speeds and feedrates are not affected by the F and S
words programmed in the G4 block. The G4 preparatory function and the accompanying
F and S words are nonmodal.
A block containing a G4 code may not contain any other G codes. The only other words
that may appear are F, S, in sequence. No others are permitted.
A2100Di Programming Manual
Publication 91204451- 001
26
Chapter 3
May 2002
Menu
Examples:
N011 G4 S5 - Dwell for 5 spindle revolutions.
N013 G4 F1.5 - Dwell for 1.5 seconds.
N015 G4 - Dwell for .5 seconds.
5.2
G8 Suppress Interpolation
G8 allows the NC program to suppress the normal modal interpolation for one block.
This code can be used to allow a tool change or other M code to be executed in a
sequence of fixed cycle blocks without either executing the fixed cycle, or cancelling the
modal interpolation code.
Programming Considerations
5.3
5.4
G
G8 is nonmodal, and as such cannot appear in a block with a preparatory code from
the interpolation group or another nonmodal preparatory code.
G
G8 itself uses no words from the block. Any words required by M codes in the block
have the meaning required by the M code. For example, the T word may be
required for a tool change.
G8 Programming Example
:G70 G90 G17
; Start of program, absolute, XY plane selected.
N010 T4 M6
; Tool T4 is selected.
N020 G97 S500 M3
; Constant spindle speed clockwise direction
selected.
N030 G0 X0 Y0 Z1
; Position axis.
N040 G1 Z0.25 F50
; Position Z axis.
N050 G83 X0 Y0 Z-0.5 R0 W1
K0.125 J11 F10
; Deep hole drill cycle selected.
N060 X1 Y0
; Position axis and repeat drill cycle.
N070 G8 T5 M6
; Suppression turned on, Tool T5 is selected.
N090 X2 Y0 S500 M3
; Spindle speed activated clockwise direction Axis
position repeat drill cycle.
N100 M2 M26
; End program full retract.
Contouring Rotary Axis Unwind (G12)
During some machining operations, a contouring rotary axis can achieve large positive
or negative absolute positions as a result of continuous rotation. At the end of such
operations, or at the beginning of a new program, it is often desirable to replace the axis
position with its corresponding value in the 0 to 360 degree range.
The contouring rotary axis unwind G12 feature does this operation without requiring nonproductive motion of the rotary axis through one or more 360 degree rotations. The
result of a G12 operation is to set both the program and machine co-ordinate values of
rotary axis current position to their modulo 360 values.
A2100Di Programming Manual
Publication 91204451- 001
27
Chapter 3
May 2002
Menu
A contouring rotary axis is unwound by programming a G12 in a block with the axis word
for the axis or axes to be unwound. The presence of the axis word specifies the axis,
and the word value is ignored by the G12 operation.
The only words that may appear in a G12 block are a sequence number and the axis
words for the axis or axes to be unwound.
Example:
:002 G0 X10 Y15 Z10 A0 T1 M6
N0010 G1 X12 A810 S400 F10 M3
N0020 Z12 M5
N0030 G12 A1
Blocks :002, N0010, and N0020 machine a helical groove using the X and A axes in a
co-ordinated move. Block N0010 results in the A axis rotating two full turns (720_) plus
an additional 90 degrees.
Block N0030 causes no motion but results in the A axis position being changed from
A810 to A90.
5.5
Plane Select G17, G18, G19
The plane select function allows the program to specify the major machine plane to be
used for:
G
G
G
G
G
G
G
G
G
Major Plane Circular Interpolation.
Major Plane Helical Interpolation.
Radius and Fillet Blending.
Co-ordinate Rotation.
Polar Co-ordinate Programming.
Automatic Cutter Diameter Compensation.
G17 selects XY plane.
G18 selects ZX plane.
G19 selects YZ plane.
The selected plane also determines the spindle axis for the G80 series fixed cycles for
machines that are configured for right angle heads.
All plane select G codes are modal.
Plane select G17 is normally the default condition of the control, and can be configured
as required. The default plane selection is activated by Data Reset, Power On, or a
colon block.
5.6
Automatic Return to/G29 from Reference Point Return
The reference point functions make use of one of a set of reference points, which are
fixed points in the machine volume that are set when the machine is configured. These
points represent fixed operation points such as pallet shuttle or tool change positions.
The control defines the first reference point as the automatic tool change position, the
second reference point as the manual tool change position, the third reference point as
the spindle axis full retract position (as used by M26, see Chapter 7) and the fourth
A2100Di Programming Manual
Publication 91204451- 001
28
Chapter 3
May 2002
Menu
reference point as the unload position. The fourth reference point is also used as the
pallet shuttle position for machines equipped with an automatic workchanger).
Additional reference points are defined as needed for specific machines.
P Word Reference Point
1
2
3
4
Reference Point Turning Center
Auto Tool Change
Manual Tool Change
M26 Full Retract
Unload Position
Normally, the move to the reference point is made automatically by the tool change,
M26, or pallet change operation. The automatic return to reference point (G28)
operation can also be used to cause this motion independent of a tool change or pallet
change.
Programming a G28, in any block defines an intermediate point using the axis word
values from the G28 block.
The G28 causes the machine to move to the intermediate point at rapid traverse and
then move to the reference point specified by the P word, see Fig. 5.1 . The location of
the intermediate point is retained for subsequent use by G28 blocks that do not specify
axis dimensions, and for automatic return from reference point (G29) blocks.
P3 FULL RETRACT
POSITION
G29 X10 Y14.5 Z20.5
AUTOMATIC RETURN
FROM REFERENCE
POINT
CURRENT
POSITION
G28 X5 Y4.5 Z10.25 P3
INTERMEDIATE
REFERENCE POINT
Figure 5.1 Reference Point Return
Note
Only one intermediate point is retained, and this point is used for all G28 and G29 blocks
regardless of which reference point is specified by the G28 P word. A G29 is generally
programmed in the block immediately following a G28. The G29 causes the machine to
position at rapid traverse to the intermediate point and then execute the axis motion
programmed in the G29 block.
Example
N20 G28 X5 Y4.5 Z10.25 P3
N30 G29 X10 Y14.5 Z20.5
A2100Di Programming Manual
Publication 91204451- 001
29
Chapter 3
May 2002
Menu
5.7
Automatic Return To Reference Point (G28)
The automatic return to reference point (G28) provides the ability to move to the one of
the predefined reference points, via a second NC program specified point, to provide
control over the path to avoid obstacles.
The automatic return to reference point causes the machine to position at rapid traverse
to the reference point specified by the P word via an intermediate position. The first
reference point, specified by P1 or no P word, is the automatic tool change position. The
second reference point, specified by P2, is the manual tool change position. The third
reference point, specified by P3, is the M26 spindle axis full retract position.
In all cases, the intermediate point is defined by the axis commands in the G28 block. If
any axis words are present in the G28 block, they define the intermediate point. In this
case, any axis not programmed is not part of the intermediate point definition and does
not move when this or subsequent G28 and G29 blocks use the intermediate point. If no
axis words are present in a G28 block, the previously defined intermediate point is used.
When a new program is loaded, the intermediate point is set to undefined. In this state,
the first G28 executed must define at least one axis position. Data reset and end of
program do not affect the intermediate point.
On most machines, programming a tool change (M6), or end of program (M2 or M30)
causes a rapid traverse move directly to the tool change position. Inclusion of a G28 in
the tool change or end of program block causes the motion to be via the programmed
intermediate position.
5.8
Automatic Return From Reference Point (G29)
This function is a companion to the automatic return to reference point (G28). The
intended use is to return from a reference point (tool change position, pallet shuttle
position, etc.) via the intermediate point defined in the most recently executed G28 block,
to the position commanded in the G29 block
5.9
Machine Unload Position (G28 P4)
The fourth reference point, P4, is defined as the unload position. This is intended to be a
safe clearance point, set by the operator, to be used by the programmer as a location for
part loading and unloading and other manual intervention. Note that programming G28
P4 does not cause the NC program to stop. If the NC program requires a cycle stop, an
M0 program stop or M1 optional stop must be included in the G28 P4 block.
6
Co-ordinates
The command to move a tool from one point to another can be stated in a number of
ways. Distances may be stated using rectangular or polar co-ordinates, and the control
may be programmed to use inch or metric measurement. Movement commands may be
stated in terms of absolute program co-ordinates, incremental distances, or absolute
machine co-ordinates. The co-ordinate system used for the NC program may be shifted
in relation to the machines co-ordinate system.
The control system, using program instructions, has the capability to switch from one
command method to another. Choose the program that best fits the requirements.
A2100Di Programming Manual
Publication 91204451- 001
30
Chapter 3
May 2002
Menu
6.1
Rectangular (Cartesian) Co-ordinates
The location of any point lying in a plane may be stated by giving two co-ordinate
dimensions which are measured along lines parallel to two reference axis lines. The axis
reference lines are perpendicular, and intersect at a point named the origin. This is the
zero reference point at which other measurements are made. The co-ordinate
dimensions are given an algebraic sign (+ or -) to indicate the side of the reference line
at which the point is located.
Fig.6.1 shows three points, A, B, and C.
Point A: X + 2 Y + 1
Point B: X + 3 Y + 2
Point C: X + 2 Y - 1
Note
The Y co-ordinate of point A is positive and the Y co-ordinate of point C is negative. This
indicates that point A lies above zero of the Y axis and point C lies below. Two separate
locations are specified, even through the numeric value of the co-ordinates are the
same.
The Y co-ordinate of point A is positive and the Y co-ordinate of point C is negative this
indicates that point A lies above zero of the Y axis and point C lies below. Two separate
locations are specified, even through the numeric value of the co-ordinates are the
same.
Figure 6.1 Rectangular Co-ordinates
To locate a point in three-dimensional space, a third axis is introduced. Arrangement of
the three axes is in accordance with the Cartesian system.
The Cartesian co-ordinate system consists of three perpendicular planes that intersect at
one common point called the origin. The intersecting planes construct, in space, eight
parts called octants as shown in Fig. 6.2
A2100Di Programming Manual
Publication 91204451- 001
31
Chapter 3
May 2002
Menu
When selecting which octant to program, keep the following in mind:
G
G
The control assumes a plus value if no sign is programmed for a co-ordinate word.
It is necessary to program the minus sign for every word of minus value.
Figure 6.2 Rectangular Co-ordinate Octants
Fig. 6.3 illustrates the 'right hand co-ordinate system' used to show the relationship of
the axes.
+Y
+B
+Z
+A
+X
Figure 6.3 Right Hand Co-ordinate System
A2100Di Programming Manual
Publication 91204451- 001
32
Chapter 3
May 2002
Menu
The right hand co-ordinate system establishes the direction the cutter moves with
respect to the workpiece. For consistency of reference, visualise the workpiece as
stationary and the cutter in motion. When reference is made to the part, visualise it as
viewed through the tool from the machine spindle as shown in Fig. 6.4.
Figure 6.4 Applying the Right Hand Co-ordinate System
7
Plus and Minus Programming
The control system has the capability of accepting absolute co-ordinates of plus or minus
values. All dimensional input can be programmed plus and minus to allow operation in
any of the quadrants of the Cartesian co-ordinate system.
In Fig.7.1 the locating hole in the centre of the part was designated as X0, Y0, therefore
to program the entire part it will be necessary to use the plus and minus values. The
control system assumes plus (+), so it is not necessary to program this sign.
A2100Di Programming Manual
Publication 91204451- 001
33
Chapter 3
May 2002
Menu
Figure 7.1 Using Plus and Minus Values
On parts similar to those shown in Fig. 7.1, which are symmetrical, it is only necessary to
calculate the dimensions of the positions in the first quadrant, then simply change the
signs of the dimensions to program the remaining quadrants.
The X and Y dimensions for this part are:
Pos. 1 X3.75 Y1.5
Pos. 2 X1.5
Y1.5
Pos. 3 X-1.5
Y1.5
Pos. 4 X-3.75 Y1.5
Pos. 5 X-3.75 Y-1.5
Pos. 6 X-1.5
Y-1.5
Pos. 7 X1.5
Y-1.5
7.1
G70 Inch/G71 Metric Programming (G70, G71)
This feature allows the NC program to specify linear dimensional data in either
millimetres (G71) or inches (G70). All of the linear dimensions in a block containing a
G71 are treated as millimetres, and in a G70 block as inches. The inch/metric state can
be switched as required during a program, but all of the data in any one block must be
either all inch or all metric.
Information is entered into the control and displayed on the display screen with the
designated measurement units. The selected state remains active until changed by
manually programming the opposite G code, or is returned to the initialised state by a
data reset. It is recommended that a G70 or G71 code is programmed in each alignment
block (a block having a sequence number with a Colon (:) address).
A2100Di Programming Manual
Publication 91204451- 001
34
Chapter 3
May 2002
Menu
The inch or metric mode is set to the initialised state when a colon block is executed.
The G70 or G71 code must be programmed when the required state is different.
Linear dimensions are entered and displayed in inches when the inch state is selected.
Feedrate is expressed in inches per minute or inches per tooth. Spindle speeds
specified in surface speed are in surface feet per minute.
Linear dimensions are entered and displayed in millimetres when the metric state is
selected. Feedrate is expressed in millimetres per minute or millimetres per tooth.
Spindle speeds specified in surface speed are in surface meters per minute.
Spindle speeds programmed in surface speeds are:
Inch - Feet/min
Metric - Metric/min
Stored information is automatically converted to the active measurement state.
Pos. 8 X3.75 Y-1.5
7.2
Polar Co-ordinate Programming (G15.1, G15.2) (E and L words)
The control supports two modes of NC programming using polar co-ordinates. In either
mode, the programmed endpoint is specified by an angle (in degrees and decimal
degrees) and by a linear dimension. The two polar co-ordinate programming modes are
bolt circle (G15.1) and part contour (G15.2).
In both modes the polar co-ordinate specification applies to the plane selected by the
plane select preparatory codes G17, G18, or G19. The polar co-ordinate angle is
specified by the non-modal E word, and is the angle measured counterclockwise (+) or
clockwise (-) in the range ± 359.999 from the first axis in the selected plane (X for the XY
plane, Y for the YZ plane, Z for the ZX plane). This distance to move is specified by the
L-word. The two modes of polar co-ordinate programming differ in the way the distance
is specified.
7.3
Bolt Circle Programming (G15.1)
Note
This feature is mainly used by machining centre applications or turning centres with
rotating tools.
The bolt circle form of polar co-ordinate programming is selected by programming a
G15.1. In this mode, the move is specified as a distance to move at the angle specified
by the E word. The distance to move is specified in the modal L word.
The Cartesian axis identifiers for the selected plane can be programmed in a polar coordinate from which the E and L words are measured. If the Cartesian words are not
programmed, the polar move is measured from the command position at the start of the
polar co-ordinate block.
This mode of polar co-ordinate programming is best suited to specifying a set of points
disposed around a common centre, such as a bolt hole circle. The Cartesian axis words
are used to specify the centre of a circle of operations. This mode is generally the
default mode for machining centre applications.
A2100Di Programming Manual
Publication 91204451- 001
35
Chapter 3
May 2002
Menu
The following example shows multiple moves using polar co-ordinates. This program
drills 5 holes equally spaced 72_ apart, around a circle of radius 0.8 inches with a centre
at X4.5 Y-1.5:
[OP1008]: 1008 G0 G61 G70 T1008 M6
N0970 (MSG, “T1008 - .656 DIA. DRILL. VSD-656-075-262”)
N0980 (MSG, “ - 300 SFM / .010 IPR”)
N0990 G15.1
N1000 M1
N1010 G81 X4.5 Y-1.5 E0 L.8 Z-1.5 R0 F17.5 S1747 M3 M8
N1020 X4.5 Y-1.5 E72
N1030 X4.5 Y-1.5 E144
N1040 X4.5 Y-1.5 E216
N1050 X4.5 Y-1.5 E288
N1060 X1 Y-1
N1070 G0 M2
Figure 7.6 Bolt Circle Programming
7.4
G15.2 Part Contour Programming
The Part Contour form of polar co-ordinate programming is selected by programming a
G15.2. In this mode, the move is specified by the:
G Cartesian co-ordinates of the endpoint in the selected plane.
G An angle (the E word) and a distance either along the line (L word), or in one of the
axes in the selected plane.
G
or
The distance along the line and one co-ordinate of the endpoint.
For example, in the XY plane (G17), a move can be specified as E and L, E and X, E
and Y, L and X, or L and Y. This form of polar co-ordinate programming is best suited
A2100Di Programming Manual
Publication 91204451- 001
36
Chapter 3
May 2002
Menu
for programming a part contour where points may be specified as an angle, and either a
distance along the angled surface, or an in-axis distance to travel.
Note that, in part contour mode, the l word is not modal.
The following program segment, and Fig. 7.7 show the use of G15.2 Part Contour
Programming:
N040 G15.2 G90 G0 X3.0 Y3.0
N050 G1 X1.0
N060 X.9 E180 + 45
or
72.4 E180 + 45
or
L .1414 E180 + 45
or
L .1414 E180 + 45
Figure 7.7 Part Contour Programming
A2100Di Programming Manual
Publication 91204451- 001
37
Chapter 3
May 2002
Menu
7.5
G13.1 Cylindrical Interpolation Off (Option)
G13.1 is used to turn off cylindrical interpolation.
When cylindrical interpolation is turned off (by programming G13.1) logical axes revert to
X, Y, and Z linear motion. The position of the axis normal to the plane of the rotary axis
is unchanged.
7.6
G7.1 Cylindrical Interpolation (Option)
This feature provides a simple method for programming geometry on the surface of a
cylindrical part. The part surface is programmed using two linear axes, one axis is
parallel to the cylinder axis, and the other axis is perpendicular to the cylinder axis and to
the spindle axis. Motion programmed in the axis perpendicular to the cylinder axis is
automatically converted to motion of the rotary axis that rotates the cylinder.
For example, to machine a cylindrical cam on a machine having an A axis (which rotates
about the X axis) cylindrical interpolation allows the profile to be programmed in the X
and Y dimensions. The Y axis motion is converted to A axis motion such that the Y axis
dimensions are machined on the surface of the cylinder.
Fig.7.8 shows the machine configuration, and an example of how a profile is
programmed in the XY plane.
A2100Di Programming Manual
Publication 91204451- 001
38
Chapter 3
May 2002
Menu
VERTICAL MACHINE
Z
Z
X
A
R
Y
Y
X
HORIZONTAL MACHINE
Y
R
Z
X
Y
X
B
Z
Figure 7.8 Cylindrical Interpolation Parts
Parameters
G The rotary axis word (A, or B) specifies the rotary axis of the cylinder.
G The selection of the linear axis is restricted as follows:
If the rotary axis is A, Y or Z can be wrapped
If the rotary axis is B, X or Z can be wrapped
G The R word - specifies cylinder radius.
Note that the numeric value of the rotary and wrap axes is ignored in the G7.1 block.
Programming Considerations
G Cylindrical interpolation is turned on by programming a G7.1 block specifying the
rotary axis to be used, the linear axis to wrap around the cylinder, and the radius of
the cylinder.
A2100Di Programming Manual
Publication 91204451- 001
39
Chapter 3
May 2002
Menu
G
The axis to be wrapped must be the non-spindle axis.
G
For example, specifying A in a G7.1 block selects the A axis as the rotary axis. Either
the Y or Z may be specified as the linear axis wrapped around the cylinder. For a
vertical machining centre, the Z axis would normally be the spindle, therefore Y would
be specified as the axis to wrap. The wrap axis co-ordinate is always at zero after a
G7.1 block.
G
The cylinder radius is specified by the R word in the G7.1 block. This is the radius at
which cylinder interpolation produces the wrap axis geometry. That is, if Y is
wrapped around a cylinder rotating about X at radius R, any programmed Y motion is
converted to the amount of A axis rotation required to produce Y axis motion at radius
R.
G
Before turning cylindrical interpolation on, the NC program must position the tool at
the starting point of the profile, that is, the tool centreline must be directly over the
centre of rotation of the workpiece, as shown in Fig. 7.9. The G7.1 block then defines
the cylinder radius and axis configuration to be used.
Tool
Tool
OK
WRONG
Figure 7.9 Correct and Incorrect Tool Positioning
G
Once cylindrical interpolation is on, any motion commanded on the wrapped linear
axis is converted to an angular motion. The amount of angular motion is computed
and occurs at the specified cylinder radius.
G
Cylindrical interpolation is turned off by programming a G13.1.
G
On the transition into (G7.1), or out of (G13.1) cylindrical interpolation mode, an alarm
is reported if any of the following are active. Once the mode is activated all but fixture
offsets and pallet co-ordinates can be used:
Axis Invert (INV)
Co-ordinate Rotation (ROT)
Corner Speed Override (G61.1, G61.2)
Cutter Diameter Compensation (G41, G42, G43)
Fixture Offsets (H word)
Local Co-ordinates (G52)
Pallet Co-ordinates (G50)
Programmable Co-ordinate Offsets (D word)
Scaling (G151)
A2100Di Programming Manual
Publication 91204451- 001
40
Chapter 3
May 2002
Menu
G
The following are not permitted when cylindrical interpolation mode is active:
Fixture Offsets (H word)
Pallet Co-ordinates (G50)
Set-up Position Set (G92.1)
Pallet Position Set (G92.2)
Cylindrical rotary axis commands i.e. G0 A,B or G92 A,B (the rotary axis is
permitted when programmed with G98)
SHI, SLO blocks
G
The following offsets are used to qualify the tool to the cutting position. They are
always applied to machine axes and never to wrap axes:
Tool Length
Set-up Offsets
G
Co-ordinate offsets (G92) are also used to qualify the tool to a cutting position, but coordinate offsets for a machine axis are not applied to the wrap axes. On the transition
into cylindrical interpolation mode the active co-ordinate offsets for the machine axis
are saved and the co-ordinate offsets for the new wrap axis is zeroed.
Once cylindrical interpolation is active, G92 is allowed for the wrap axis. On the
transition out of cylindrical interpolation mode the saved co-ordinate offsets are
restored for the machine axes.
G
7.7
Machine co-ordinate programming (G98, G98.1) is permitted while in polar/cylindrical
interpolation mode, but the machine axes are the ones programmed and are the ones
that move. The movement of the machine axes may also affect the display positions
of the wrap axes.
G7.1 Cylindrical Interpolation Programming Example
The sample program below, and Fig. 7.10 show cylinder interpolation using a rotary A
axis with Y axis used for cylinder wrap motion. In this example Z axis is the spindle axis
used to cut the cam profile.
Note that part circumference is 5.18 inch.
: G17 G70 G90 G0 T1 M6
; establish program modes and select tool
N01 G0 X2 Y0 Z1 S1500 M3 ; position axes turn spindle on clockwise
N02 A0
; position A axis
N03 G7.1 A0 Y0 R1.650/2
; activate cylinder interpolation
N04 G1 Z-.01 F10.
; feed Z axis to cut depth
N05 Y-1 ,R.25
; rotate axis cut radius
N06 X1.25 ,R.25
; position axis cut radius
N07 Y-2.5
; rotate axis
N08 X2 Y-4.5782
; position axes
N09 Y-5.18362
; rotate axis
N10 G0 Z.1
; retract Z axis
N11G13.1
; turn off cylindrical interpolation
N12 M26 M2
; end program, full retract
A2100Di Programming Manual
Publication 91204451- 001
41
Chapter 3
May 2002
Menu
N01
19.05mm
(.75")
Z
25.4mm
(1.0")
R 6.35mm
(.25)
N06
X
N05
R 6.35mm
(.25)
Y
38.1mm
(1.5")
N07
R
A
131.572mm
(5.18")
68.072mm
(2.68")
N08
15.377mm
(.605")
19.05mm
(.75")
N09
Figure 7.10 Cylinder Interpolation Example
7.8
Absolute Input G90
Program commands for movement of the axes may be programmed in incremental
commands or absolute co-ordinates The mode may be changed by programming:
G90 - Absolute
In the absolute mode all axis dimensions are referenced from a single program zero
point. The algebraic signs (+ or -) of absolute co-ordinates denote the position of the
axis relative to program zero and do not directly specify the direction of travel. Absolute
co-ordinates may be programmed using either rectangular or polar co-ordinates.
In Example 1 (Fig.7.11) the part was programmed with the centre of the locating hole
designated as X0, Y0. In an example such as this the reference point will always be on
the table.
Example 2 (Fig 7.11) shows the same part with centre of the locating hole designated as
X10, Y10. As both parts were set-up at the same location on the table, the zero
reference point is now a theoretical position in space. Both methods of programming are
acceptable as there is no need to move to the zero point shown in Example 2.
A2100Di Programming Manual
Publication 91204451- 001
42
Chapter 3
May 2002
Menu
Figure 7.11 Absolute Input G90
The reference point is a programmer designated position on the part. The dimensions of
the reference point are also assigned by the programmer. The position and dimensions
selected are usually the most convenient with which to calculate all the necessary
positions to be machined on the part.
The example below, and Fig. 7.12 shows the method by which positions are specified
using absolute dimensional input. With the left front edge of the part designated as X0,
Y0, the dimensions are picked-up directly from the drawing.
Figure 7.12 Absolute Input G90
Example:
Pos. 1
Pos. 2
Pos. 3
X3
X5.75
X8.5
A2100Di Programming Manual
Publication 91204451- 001
Y3
Y6
Y3
43
Chapter 3
May 2002
Menu
Had the reference point been assigned values of X10, Y10, a value of 10 inches would
have to be added to each dimension on the drawing.
Example:
Pos. 1
X13
Y13
Pos. 2
X15.75 Y16
Pos. 3
X18.5 Y13
On some parts it may be easier to use both absolute and incremental dimensional input
on the same program. This can be done at the programmers discretion simply by
programming the proper code, G90 for absolute or G91 for incremental.
Programming Considerations
G The current positions of the axes are displayed on the display screen in absolute
rectangular co-ordinates regardless of which mode is active.
7.9
G
The R word, used with fixed cycles, is always absolute.
G
The axis words in a G92 G92.1 or G92.2 position set block are always absolute.
G
The axis words using the G98 or G98.1 mode for programming in machine coordinates are always absolute.
G
The axis words using the G50 mode for programming in pallet co-ordinates are
always absolute.
G
The L word, used when specifying polar co-ordinates, is always the incremental
displacement from the command position.
Incremental Input G91
Incremental input (G91) mode allows the dimensional input to the control to be
increments from the present position to the next. The G91 code is modal and is
changed by programming the absolute input (G90) code.
In incremental mode, the axis word dimensions are referenced from the current position
of the axes. The input dimensions denote the distance to be moved. The algebraic sign
(+ or -) specifies the direction of travel. Incremental movements may be programmed
using either rectangular or polar co-ordinates.
A2100Di Programming Manual
Publication 91204451- 001
44
Chapter 3
May 2002
Menu
Figure 7.13 Incremental Input G91
The information required to move from Pos. 1 to Pos. 2 is an X2 incremental dimension.
The move from Pos. 2 to Pos. 3 requires a Y1 incremental dimension.
Note the direction of the theoretical tool movement as opposed to the actual table
movement. Minus (-) signs create a movement in the opposite direction. For
simplification and ease of programming the programmer should visualise the tool moving
rather than the table.
Since the control assumes a plus sign when no sign is programmed, a minus (-) sign
must be programmed in every block of information in which it is needed. Every program
must start with absolute co-ordinates to establish the co-ordinate system. Once each
axis position has been programmed in absolute the remainder of the program can be
incremental.
7.10
Set High Limits (SHI) and Set Low Limits (SLO) Blocks
Set High Limits (SHI) and Set Low Limits (SLO) blocks contain axis dimensions which
can define the high and low limits for the machining zone or for a forbidden zone.
If SHI and SLO blocks define the machining zone they can restrict the maximum axis
travel to a smaller, more restrictive envelope than the full axis travel range.
If the SHI and SLO blocks define a forbidden zone, they define a region that the tool tip
is forbidden to enter. A forbidden zone can be used to protect clamps, fixtures, and the
part itself. For the linear axes, the high and low limits define a zone into which the
machine may not place all axes simultaneously.
Note that changing tools, or programming H, D, or O words, does not affect the SHI,
SLO limits. Limits are calculated only once when SHI SLO is programmed.
SHI and SLO blocks can be used to define both the machine limits and one forbidden
zone.
SHI blocks can also be used to specify the maximum feedrate and spindle speed to
further constrain the range of allowable feeds and speeds.
A2100Di Programming Manual
Publication 91204451- 001
45
Chapter 3
May 2002
Menu
Note that these limits are ignored if they are higher or lower than the machines
configured limits. SHI F and S limits bound the amount of feedrate and spindle speed
override that are permitted, in addition to limiting the maximum programmable speeds.
The SHI block defines the upper limit for each axis, and the SLO block defines the lower
limit. The G word of the SHI and SLO blocks defines what kind of limit is being defined.
The axis words (X, Y, Z, U, V, W, A, B, and C) define the axis position defined as the
limit. Any axis not programmed retains its previous limit which could be either the
configured axis limit or a previously programmed SHI limit. The F and S words specify
the feedrate and spindle speed limits respectively.
Note that the active new axis limits can be read using the system variables
[$HIGH_LIMIT ()] and [$LOW_LIMIT ()]
The G word in a SHI or SLO block defines what the axis dimensions represent. G3 in an
SHI block resets the high limits for the axis words programmed with a non-zero value.
Similarly, G3 in an SLO block resets the low limits for all axis words programmed with a
non-zero value. Axis limits that are reset are set to the default (full axis travel, no
forbidden zone) state. A G3 word in a SHI or SLO block with no axis words present
resets all axes.
In either a SHI or SLO block, G1 specifies that the axis dimensions are the axis high or
low limit in program co-ordinates. G11 specifies that the axis dimensions are the axis
high or low limit in machine co-ordinates. G2 specifies that the axis dimensions are the
axis high or low bound of a forbidden zone in program co-ordinates. G12 specifies that
the axis dimensions are the axis high or low bound of a forbidden zone in machine coordinates.
In machines with slave axes, forbidden zones defined using machine co-ordinates are
stationary and relative to machine zero. They are intended to protect a location on the
machine, such as a part of the machine itself or a fixture. Forbidden zones defined
using program co-ordinates are assumed to be relative to the part, and appear on each
part if the machine has multiple spindle heads. Only one forbidden zone can exist at any
time.
In both SHI and SLO blocks, the mandatory G word selects which type of limit is being
set. Feed limits are set by:
G1 using program co-ordinates
G11 using machine co-ordinates
Forbidden zones are set by:
G2 using program co-ordinates
G12 using machine co-ordinates
The G3 restores data values for all axes programmed with a non-zero value.
In general, new limits should be specified using program co-ordinates (G1 or G2) if the
limit is relative to the part being machined, such as clamps and fixtures. Limits related to
machine structures, such as a fixed probe or a rotary axis mounted on the table, are best
specified using machine co-ordinates (G11 or G12).
Regardless of how the limits are specified they represent fixed positions on the machine,
and are unaffected by subsequent position set, offset changes, or zero shift operations.
The X, Y, Z, U, V, W, A, B, and C words specify the high or low limit (depending on the
block function designator) of the allowed (G1/G11) or the forbidden (G2/G12) zone.
A2100Di Programming Manual
Publication 91204451- 001
46
Chapter 3
May 2002
Menu
They have the range values of type I block axis words, are affected by inch/metric
programming, and are absolute values only. When an axis word is omitted with G1/G11,
the corresponding limit is not changed.
All of the default G2/G12 limits are the axis high limits effectively resulting in no
forbidden zone. For most forbidden zones all six limits will need to be specified.
Switching from G1 to G2 co-ordinates or G2 to G1 causes any non-programmed axis to
default to the machine configured limits.
Switching between G11 and G12 causes any non-programmed axis to be in an
interference condition.
A G3 in an SHI or SLO block returns values of all boundaries for the specified axes to
their permanent values. If both a temporary boundary and a forbidden zone had been
previously established, programming a (SHI, G3) and a (SLO, G3) specifying the axis or
axes to be reset cancels both temporary zones. If no axis words are present, all axis
limits are reset.
Once the boundaries have been established, they remain active until:
G They are changed by programming new SHI and SLO blocks.
G They are cancelled by programming SHI and SLO blocks containing a G3 word.
G A program is loaded or cleared.
Note that a reference rewind stop code (:), end of program, or data reset does not cancel
the temporary boundaries.
Refer to Fig.7.14 for examples of forbidden and interference zones.
Defined by the high and low limits of
each axis, default values from configu
ration data. May be programmed with
SHI and SLO using G1 or G11.
Figure 7.14 Forbidden and Interference Zones
A2100Di Programming Manual
Publication 91204451- 001
47
Chapter 3
May 2002
Menu
8
Feedrate Programming
Feedrate Programming control (see Fig. 8.1) provides three feedrate modes, selectable
by G code. The feedrate may be specified in feed (inches or millimetres) per minute
(G94), in feed per tooth (G95), or by the inverse of the required block execution time in
seconds (G93).
In all three cases, the feedrate is specified by the F word. In feed per minute (G94) and
feed per tooth (G95) modes, the F word is modal; in inverse time (G93) mode, the F
word is nonmodal and must be programmed in each block.
The programmed feedrate can be overridden by an operator override, generally in the
form of a potentiometer control. The A2100 tool data table also contains a per tool
feedrate override that can alter the programmed feedrate. Both of these overrides can
be program-blocked by the Feedrate Override Disable (M49) or program-enabled by
feedrate override enable (M48).
The programmed feedrate can be replaced by a constant dry run feedrate feature, if the
feature is active. Dry run is used to exercise a NC program for a non-cutting check at a
high feedrate, and can be activated or deactivated at any time. When activated, the
fastest rate (dry run rate or program rate) is used. If dry run is deselected while the NC
program is executing, the control immediately decelerates to the programmed feedrate.
Figure 8.1 Feedrate Programming
8.1
G94 - Feed Per Minute Feedrate
In this mode, the F word specifies the velocity of the tool along the tool path in inches or
millimetres per minute. Only linear axes are considered in computing the feedrate. If
rotary axes are programmed to move in combination with linear axes, their motion is
distributed evenly through the motion. If this is not satisfactory for the required move
(i.e. if the rotary axis contribution to the actual tool velocity is large relative to the linear
axis contribution), 1/T feedrate mode (G93) must be used.
The feedrate specified by the F word is the velocity along the tool path, either along the
straight line specified or along the tangent to a circle, arc, or helix. The F word is modal
in G94, that is, a programmed feedrate remains active until another feedrate is
A2100Di Programming Manual
Publication 91204451- 001
48
Chapter 3
May 2002
Menu
programmed, or the feedrate mode is changed. In all motions, the control automatically
limits the feedrate such that no axis exceeds its maximum allowable feedrate.
8.2
G95 - Feed Per Tooth Feedrate
In this mode, the F word specifies the desired feed distance per tooth, or chip per tooth.
The feed per spindle revolution is the programmed F word value multiplied by the
number of teeth on the cutter, obtained from the tool table.
The actual feedrate is derived from the actual spindle position if spindle feedback is
present. If spindle feedback is not present, the programmed spindle speed is used as an
approximation of the actual spindle speed.
In either case, feedrates specified in G95 mode are assumed to be related to the
process, and therefore acceleration/deceleration is disabled as it would directly affect the
chip per tooth.
The F word is modal in G95, so once a feedrate is established, it remains in effect until
another F word is programmed or the feedrate mode is changed.
In G95 mode, if the number of teeth in the tool database is not set, the default is one,
which results in G95 feedrates being expressed in feed per spindle revolution.
G95 feedrate is useful when the cutting process requires accurate chip per tooth. In G95
mode, the feedrate is determined by actual spindle speed so spindle speed changes
caused by overrides or spindle acceleration or deceleration are all reflected in the
feedrate to maintain constant chip per tooth.
8.3
G93 - I/T Feedrate (Inverse Time)
Inverse time feedrate mode, sometimes referred to as velocity over distance (V/D) mode,
defines the feedrate for a block by specifying the inverse of the time in seconds for the
block execution. G93 is primarily used in situations where the point of contact between
the tool and the work, relative to the machine, is not known by the control (as in many
four or five axis machining situations).
Note that I/T feedrate programming cannot be used for fixed cycles G81 through G89, it
should be used when linear and rotary motion are combined in one move.
The operator may modify the programmed feedrate by:
G
The feedrate override control.
G
The feedrate override which is assigned to the active tool.
G
Selecting Dry Run, which replaces the programmed rate with the constant dry run
feedrate if the dry run rate is higher than the programmed rate.
The actual feedrate is the product of all these factors. If the resulting feedrate exceeds
the maximum allowable, cycle continues, and the control adjusts the feedrate to the
maximum allowable rate.
Note that all axis motion stops if the feedrate override percent is set to zero.
A2100Di Programming Manual
Publication 91204451- 001
49
Chapter 3
May 2002
Menu
In inverse time mode, each block requires an F word. The value of the F word is
computed as:
V
F = SL x 60
1
V inch
F=
min
x SL inch
Where:
1 min
1
x 60 sec = Sec
V = velocity in inches/minute
SL = span length of distance travelled
The key to the above formula is in finding the span length:
Linear span length (one axis)
The span length would be the distance of slide travel
Linear span length (two axis)
The span l ength =
x 2 + y2
In circular interpolation or helical interpolation (G2 and G3), the G93 F word specifies the
time in seconds for an arc length of one radian. The F word is computed by dividing the
feedrate by the radius of the circle for circular interpolation. For helical interpolation the
F word is given by:
F=
V
r2+L/2p2
Where:
V = Velocity in inches or mm per minute
r = Helix radius in inches or mm.
L = The helix lead in inches or mm.
Example:
Assume that a helical cut is being made using a rotary table (B axis) and the Y axis
movement (that is, along the axis of the rotary table). The required velocity V along the
cutter path is 5 inches per minute. The cutter tip is seven inches from the centre of
rotation of B.
To calculate the F word value we must determine the span length (SL) from the formula.
Assuming that only the Y and B axes are moving:
SL =
y2 + BSL 2
Where:
Y = Y Axis Span Length
BSL = B Axis Span Length
The Y axis span length is found by taking the difference between the point where the
move starts in Y and where the move stops.
The B axis span length is the arc length for the distance travelled at the seven inch
radius from the centre of rotation. This length may be found by using the following
formula:
BSL = R(0.01745 B 1 )
A2100Di Programming Manual
Publication 91204451- 001
50
Chapter 3
May 2002
Menu
Where:
BSL = B axis equivalent Span Length in mm or inches
0.01745 = Constant to Convert Degrees to Radians
R = Radius of Cut in mm or inches
B1 = Rotation Angle in Degrees
In the following example, the numeric values are inserted in the above formulas:
Example:
Tool tip Co-ordinates when cutting at 7.00 in. radius:
Pos. No. 1:
X2.2500 Y0.0000
B0.000
Pos. No. 2:
X2.2500 Y5.0000
B20.000
Tool Tip Movement X0.0 in. Y5.00 in. B20.0 deg
Z7.0000
Z7.0000
Z0.00 in.
B Axis Span Length Calculation:
BSL = R(0.01745 B 1 )
= 7(0.01745 x 20)
= 7 x 0.349
= 2.443 inch
Span Length Calculation:
∆ y2 + ∆ BSL 2
SL =
=
5 2 + 2.443 2
=
25 + 5.968
SL = 5.5649
Using this value, when moving from Position 1 to Position 2 at a feedrate of 5 inch per
minute we can determine the programmed F word in the following calculation.
Feedrate Number Calculation:
F =
=
V
60SL
5
60 x 5.564 9
= 0.01497
Execution Time Calculation:
=
=
1
F
1
0.015
= 66.7 seco nds for en tire span
The following Table and example show how to convert minutes and seconds to
thousandths of a degree.
A2100Di Programming Manual
Publication 91204451- 001
51
Chapter 3
May 2002
Menu
Minutes or Seconds
Degree Equivalent
Minutes
0.83333
0.66667
0.50000
0.33333
0.16667
0.15003
0.13336
0.11669
0.10002
0.08333
0.06667
0.05000
0.03333
0.01667
50
40
30
20
10
9
8
7
6
5
4
3
2
1
Seconds
0.01389
0.01111
0.00833
0.00556
0.00278
0.00252
0.00224
0.00196
0.00168
0.00139
0.00111
0.00083
0.00056
0.00028
Example:
Convert an index of 8º 17’ 23” to thousandth of a degree input:
8º
= B 8.000
17’ = +10’ = 0.16667
+ 5’ = 0.08333
+ 2’ = 0.03333
17’ = 0.28333 = 0.28333
23” = +20”= 0.00556
= + 3”= .00083
23”= 0.00639 = 0.00639
0.28972
= B .290
8º 17’ 23” = B 8.290
8.3.1
Feedrate - Circular Interpolation
Programming feedrates for peripheral milling with circular interpolation apply to the
centreline of the cutter. When milling in a circular path, the cutter edge is feeding at a
different rate to that of the cutter centreline. To obtain the required feedrate for circular
interpolation at the cutter edge, the following feedrate calculation must be made:
FPM =
Circle Diameter
+ / - * Cutter Diameter x Desired FP M
Circle Diameter
The feedrate for circular interpolation may also be calculated using chip/tooth.
FPT =
(Circle Diameter
+ / - * Cutter Diameter x Desired FP T)
Circle Diameter
*Use a plus (+) sign when cutter is outside the circle, and a minus (-) sign when cutter is
inside the circle.
A2100Di Programming Manual
Publication 91204451- 001
52
Chapter 3
May 2002
Menu
Example (Inch) (Fig. 8.2):
Cutter diameter = 1 in. (25.4 mm)
Workpiece hole size = 2 in. (50.8 mm)
Required IPM at the part surface = 2 in/min. (50.8 mm/min)
Feed Rate (ipm) =
(2" - 1" ) x 2 in / min.
2"
= 1 in./min.
Metric (Millimetre)
Feed Rate (mm / min) =
(50.8mm - 25.4mm) x 50.8mm / min.
50.8mm
=25.4 mm/min
Figure 8.2 Feedrate Circular Interpolation
8.4
G45 Automatic Acceleration/G46 Deceleration (G45, G46)
Automatic acceleration/deceleration monitors the programmed feedrate and the feedrate
overrides, and smoothly changes the vector velocity to ensure that no axis experiences a
sudden change in commanded velocity. It also monitors changes in direction and
circular arc curvature to limit the axis accelerations required by changes in direction.
When automatic acceleration/deceleration is enabled, it is not necessary to program
explicit feedrate changes for cornering or small radius arcs. Furthermore, any change in
the commanded feedrate, either because of changes in the F word or because of
changes in the amount of feedrate override, are monitored and the vector velocity is
changed at a smooth ramp, limited by the axis acceleration capability. The smooth ramp
is further modified to a ”bell curve” shape by controlling the jerk, or rate of change of
acceleration. The jerk limitation produces smoother machine motion and minimises the
generation of higher frequency machine vibration and movement.
When automatic acceleration/deceleration is off, all commanded feedrate changes take
place immediately. This is useful in certain special cases, such as probing. Normally,
however, automatic acceleration/deceleration is on (G45). In this case, the control
examines all programmed moves, and automatically performs controlled feedrate
A2100Di Programming Manual
Publication 91204451- 001
53
Chapter 3
May 2002
Menu
changes such that no machine axis is required to accelerate or decelerate faster than its
capability allows.
Whenever automatic acceleration/deceleration is off, velocity feed forward is
automatically disabled.
Automatic acceleration/deceleration can be turned on or off by the NC program using the
acceleration/deceleration mode preparatory codes. Automatic acceleration/deceleration
is automatically turned off when the feedrate mode is feed per tooth (G95, see feedrate
mode). In this case, the control derives the feedrate from the spindle speed in order to
maintain a constant chip load, and this would be defeated by the automatic
acceleration/deceleration feature.
8.5
Selectable ACC/DEC Profiles (G45)
A2100Di provides the ability to select, via the program, from among various sets of
configuration parameters which define the type of velocity profile used. This feature
allows the programmer to optimise the configuration for a specific type of machining
process.
Selection of a process optimised configuration is accomplished using an extension of the
G45 ACC/DEC on modal G-code. The G-codes involved are G46, G45, G45.1, G45.2,
G45.01, G45.02, and G45.03. G46 turns automatic acceleration/deceleration off for feed
moves, but A2100 still provides acceleration/deceleration for all rapid traverse moves
(G0).
The G45.xx codes turn the automatic acceleration/deceleration feature on, and select a
set of velocity related configuration parameters optimised for a particular process.
8.6
Automatic Acceleration/Deceleration
Normally, automatic acceleration/deceleration is on (G45). If so, the control examines all
programmed moves and automatically performs controlled feedrate changes such that
no machine axis is required to accelerate or decelerate faster than its capability allows.
The control of the vector feedrate accomplishes this, using a ’bell curve’ that provides
constant jerk (rate of change of acceleration) at the beginning and end of each
acceleration, for a smooth change in feedrate. A2100 provides controlled acceleration
and deceleration for all feedrate moves in G93 (inverse time) or G94 (feed per minute)
modes.
The system automatically selects the acceleration rate based on the limiting value of
acceleration for each axis involved in the move and the configured vector acceleration.
When automatic acceleration/deceleration is off, velocity feed forward control is
automatically disabled.
9
Selectable Velocity Control Profiles
Different machining processes make different dynamic demands on the machine tool
and servo drive system. A2100 provides a selection of NC program selectable velocity
control profiles for optimisation to different machining processes.
Selection of a velocity control profile automatically selects several related parameters,
including the acceleration along the path, the jerk, whether-or- not to apply feed forward
A2100Di Programming Manual
Publication 91204451- 001
54
Chapter 3
May 2002
Menu
of acceleration (for digital servo systems) and velocity.
profiles (more may be added in the future):
A2100 currently provides three
G
G45 selects a general machining profile
G
G45.1 selects a profile for high speed contour roughing
G
G45.2 selects a profile suitable for high speed contour finishing
Three other profiles are provided, that are selected by G45.01, G45.02 and G45.03.
10
Configuration Parameters
The ACC/DEC process modes parameter configuration table is displayed by touch
selection of Axes/Servo under Configuration. This table contains six columns with the
following titles:
G
Heading.
G
Maximum Feedrate.
G
Maximum Acceleration.
G
Maximum Jerk Step Velocity Override.
G
Apply Rate Feed forward.
Note that units of the table entries may be inches or metric, depending on a previous
selection of the measurement button.
The maximum values for acceleration and jerk should be interpreted as target numbers,
or values to be aimed for or achieved for optimised efficiency in the process. The control
program will not allow these numbers to be exceeded.
Heading
Heading entries can be changed by the machine tool builder for the purpose of
customising ACC/DEC profile entries to specific machines or machine lines.
Maximum Feedrate
This is the maximum feedrate that can be used. The actual feedrate of the process
move is the lesser of the programmed feedrate and this maximum feedrate.
Maximum Acceleration
This is the target value of the path acceleration.
Maximum Jerk
This is the target number of the path jerk.
Step Velocity Override
Step velocity override applies a scaling factor (percentage multiplier) to all axis step
velocity settings. Applying the step velocity override scaling factor reduces the step
velocity of every axis.
Apply Rate Feed forward
The entry in this column of yes or no controls whether-or-not velocity and acceleration
feed forward are used in the process.
A2100Di Programming Manual
Publication 91204451- 001
55
Chapter 3
May 2002
Menu
10.1
Explanation of G45, G45.1, G45.2 Codes
The G45, G45.1, and G45.2 codes relate to the selection of a factory predetermined set
of parameters that are expected, based on development and experience, to make the
machine perform well for a particular type of machining process. The parameter set-up
associated with each of these codes is a pre-programmed optimisation for a particular
process.
Note that the set-up of the A2100 control parameters with the G45, G45.1 and G45.2
codes is optimised, based on experience, but these predetermined values are not fixed.
The purpose of the codes and the associated parameter values is to relieve the load on
the machine tool builder or user of the effort to optimise the A2100 for the particular
process. The numbers associated with these codes can be changed as necessary,
especially from knowledge of the machine capabilities and of the end results to be
achieved.
10.2
General Machining (G45)
G45 mode is intended for most machining operations, and optimises the time required
for hole making, milling of simple geometry, and turning, etc. The selected acceleration
and jerk rates are relatively high to minimise the total machining time. Cornering
feedrates are relatively high to minimise machining time.
Note that feed forward is not used in this mode of operation.
10.3
High Speed Contour Roughing (G45.1)
G45.1 mode is intended for roughing of contoured surfaces at relatively high feedrates.
This mode is useful for operations such as roughing a die or mould where contour
accuracies are not critical. The operation is similar to the G45 general machining mode,
but the path acceleration and jerk rates are lowered to provide smoother operation when
machining a contour composed of multiple lines and arcs.
In G45.1 mode cornering feedrates are lowered and jerk rates are low to smooth out
transitions between adjacent linear moves. The acceleration parameter is selected to
allow for smooth operation at high feedrates in the presence of relatively large
discontinuities in the surface.
10.3.1
High Speed Contour Finishing (G45.2)
G45.2 mode is intended for finishing contoured surfaces at relatively high feedrates.
This mode is useful for operations such as finishing a die or mould where contour
accuracy is important and smooth operation is also required. The operation is similar to
the G45.1 contour roughing mode, but the path acceleration and jerk rates are lowered
further to provide smoother operation and improved contour accuracy when machining a
contour composed of multiples lines and arcs.
In G45.2 mode, feed forward is used to reduce the path errors that occur when corners
are encountered. Cornering feedrates are lower than in G45.1 and the jerk rate is low to
smooth out transitions between adjacent linear moves and to minimise transient path
error at the intersections. The feed forward and acceleration parameters are selected to
allow for smooth operation at high feedrates, assuming that the contour points are
selected for low chordal error and a generally smooth contour.
A2100Di Programming Manual
Publication 91204451- 001
56
Chapter 3
May 2002
Menu
10.4
User Specified (G45.01, G45.02, G45.03)
These modes are provided to allow the machine tool builder or end user to create
machining modes with a path velocity profile other than those provided by A2100. There
are configuration pages available to allow the path acceleration, maximum feedrate, jerk,
corner feedrates, and feed forward gains to be selected to optimise performance for a
particular class of machining operations. Codes G45.01, G45.02, and G45.03 default to
having the same values used by G45.
10.5
Acceleration/Deceleration OFF (G46)
The NC program can turn all cutting feed acceleration/deceleration control off by
programming G46. When G46 is active, all programmed feedrate changes take effect
immediately.
As the mechanical and electrical components of the axis drive train may not be able to
handle large step changes in velocity commands, when G46 is active a configurable
maximum feedrate value is used to allow the machine tool builder to limit the feedrates
to the capability of the machine.
As a rule, programs should not use G46 except for special operations such as probing or
in applications where the programmed feedrate must be maintained regardless of path
geometry.
10.6
Rapid Traverse (G0)
G0 has its own velocity profile that is separate from G45. The rapid traverse mode of G0
uses its own set of rates that can be different from those associated with the modal
G45.xx. If G0 is specified, a separate set of configuration parameters is used, even
when G45 (modal) is on. G0 specifies:
G
Linear path.
G
A certain feedrate.
G
Velocity profile.
and includes all of these in one.
G45, which applies to feed modes, is concerned with the types of velocity profile for use
with G1, G2 and G3. For example, if G45.1 is specified, the rates associated with it are
used only if in G1, G2 or G3. Rates associated with G0 are found in the Rapid Rates
Table.
10.7
Z Axis Feedrate Limiting
There are situations in contour milling where the feedrate must be limited when cutting in
the negative Z direction because of cutter geometry limitations. The control provides a
means of limiting (by program) negative Z axis feedrates for cutting motions (that is,
excluding rapid moves).
The Z axis plunge feedrate limit is controlled by system variable [$PLUNGE_PCT]. This
variable contains a value between 1 and 100, representing one percent to 100 percent of
the programmed feedrate. For all linear (G1) and helical moves in the XY plane (G17)
the vector feedrate is constrained such that the negative Z axis component of the
feedrate is less than or equal to [$PLUNGE_PCT] times the programmed rate.
A2100Di Programming Manual
Publication 91204451- 001
57
Chapter 3
May 2002
Menu
For example, if [$PLUNGE_PCT]=10 and the programmed feedrate is 1500mm/min, the
negative Z axis feedrate component will not exceed 150mm/min. Note that the plunge
feedrate limited is not active in either rapid (G0) moves or in (G19) YZ and (G18) ZX
circular interpolation moves.
[$PLUNGE_PCT] is set to 100% by data reset, and by end of program (M2 and M30).
Values of [$PLUNGE_PCT] that are less than 1% or greater than 100% are ignored; that
is, the plunge feedrate is limit is not active.
10.8
Spindle Control (Spindle Speeds)
This control allows the spindle speed to be specified directly in RPM or indirectly by
programming the required cutting speed in surface meters per minute or surface feet per
minute.
For rotating tools such as milling cutters, the spindle speed required for a given cut
speed is determined by the diameter of the cutter, and is constant. This mode of
operation is specified by G97 (speed in RPM) and G97.1 (speed in surface meters or
feed per minute). In these cases, the S word specifies the spindle speed, and the speed
remains constant during the cutting process unless specifically changed by programming
a new S word.
When a single point tool is used to generate a contour of varying diameter, either by
rotating the workpiece, or by using a variable radius boring tool, the surface speed
(speed of the work relative to the tool cutting edge) varies depending on the diameter
being machined for a given spindle speed.
The constant surface speed (CSS) feature, specified by G97.1, automatically adjusts the
spindle speed to maintain a constant cut speed as the distance from the tool point to the
centre of rotation changes. In this mode, the S word is always the surface speed.
10.9
G97 Spindle Speed in RPM (G97)
In this mode, the spindle speed is specified by the S word in RPM. The programmed
spindle speed may be overridden by a spindle override potentiometer (or other control
device) depending on the machine application, and by the per tool spindle speed
override.
When resuming G97 (RPM) mode after operating in G96 (CSS) it is not necessary to
reprogram the spindle speed. If no S word is present, the spindle RPM at the time the
G97 block begins is used as the current spindle speed in RPM.
10.10
G97.1 Constant Spindle Speed in SFM (G97.1)
In this mode, the spindle speed is specified by the S word in surface feed per minute
(surface meters per minute or surface feet per minute).
Use of G97.1 in conjunction with feed per tooth feedrate programming (G95) allows the
NC program to specify the parameters of cut speed and chip per tooth directly. The
control computes the spindle RPM from the specified cut speed and the cutter diameter
(determined using the nominal diameter, diameter offset, and programmable tool offset),
and generates the actual feedrate based on the programmed chip per tooth and the
number of teeth on the cutter.
A2100Di Programming Manual
Publication 91204451- 001
58
Chapter 3
May 2002
Menu
If the actual tool differs from the tool assumed by the NC program in diameter or number
of teeth, the control automatically adjusts for the new tool with no program changes.
To use G97.1 the tools nominal diameter in the Tool Table must be greater than zero to
allow the control to determine the spindle speed.
10.11
G96 Constant Surface Speed (G96) Operation
When the system is in CSS mode (G97.1), the control continuously updates the spindle
speed based on the location of the tool point with reference to the centre of rotation. In
this mode, the S word specifies the required surface speed (cut speed) in surface feet
per minute or surface meters per minute. A block containing a G96 code may contain an
S word specifying the surface speed, and an R word specifying the distance from the
point of tool contact with the work to the centre of rotation.
The S word value, if present, specifies the desired surface speed to be maintained. If no
S word is present, the current surface speed determined by the current spindle speed
and the current distance between the tool and the centre of rotation is used as the
surface speed to be maintained.
The R word value, if present, sets the initial distance, which is thereafter monitored by
the control and updated whenever the tool radius axis changes. The R word is a
diameter if the control is in diameter mode (G62), and a radius value if the control is in
radius value (G63) If the R word is omitted, the current tool radius axis position is
assumed to be the distance from the centre of rotation.
In CSS mode, as the tool tip approaches the centre of rotation the spindle speed must
increase to maintain the surface speed. The required spindle speed becomes infinite at
the centre of rotation. To prevent commanding too large a spindle speed, the control
limits the commanded speed to the maximum spindle speed, or to the value specified by
the S word of a G92 block.
During G0 rapid traverse moves, the spindle speed is held at the speed at the start of the
block. The spindle speed is brought to the correct value to maintain the surface speed
when the next feed block is encountered. This prevents unnecessary spindle
acceleration and deceleration when the cross axis is moved to a clearance diameter and
back to the cutting diameter.
11
Spiral Interpolation (G2, G3)
11.1
Introduction
Spiral interpolation is a special type of circular interpolation, where the circle radius is
constantly increasing or decreasing. A spiral is commanded by programming an arc
and additionally programming a Q or an L word.
The Q word specifies the change in radius per 360º of circular motion. A positive Q word
indicates that the radius of the spiral is increasing and a negative Q word indicates the
radius is decreasing.
The L word specifies the number of complete and/or partial revolutions of circular
motion. The actual number of revolutions will be less than or equal to the L word value.
For example, to specify 4 revolutions plus 90º (4¼ revolutions), program either L4.25 or
L5. The L word value must be positive.
A2100Di Programming Manual
Publication 91204451- 001
59
Chapter 3
May 2002
Menu
If the spiral is programmed using radius specification, the starting and ending radii are
specified using P and R words, respectively. The P and R word values must be positive
and must be programmed with a Q word.
11.2
Spiral Interpolation Example
This example of spiral interpolation shows the concept and the programming techniques
for performing a simple spiral move.
The details of the spiral are:
G The centre of the spiral is at X = 0” and Y = 0”
G The start radius of the spiral = 10”
G The end radius of the spiral = 2.5”
G The number of revolutions = 180º + 360º = ½
G
The radius is decreasing, therefore the Q word must be negative.
G
The change in radius per 360º (Q word) is defined as:
Q = (End radius – Start radius) + Number of revolutions
Q = (2.5” – 10”) + ½
Q = - 7.5” x 2 = -15
The part program blocks for this example are:
N080 GO X-10 YO Z8.2
N090 G1 Z8 F10
N100 (MSG, CUT SPIRAL)
N110 G2 G17 X 2.5 YO 10 JO Q-15 F50
N115 (MSG, SPIRAL COMPLETED)
N120 GO Z8.2
Alternatively, block N110 could be written to use radius specification programming:
N110 G2 G17 X2.5 YO P10 R2.5 Q-15 F50
11.3
Multi-revolution Spiral
A multi-revolution spiral may be programmed in one block by specifying the appropriate
end point in the selected plane. The centre point of the spiral may be specified using the
I, J, and/or K words as described in Section 12.1, or by programming a starting radius
using the P word and an ending radius using the R word. The P and R word values
must be positive and must be programmed with a Q word. The L word cannot be used in
multi-revolution spiral blocks programmed using P and R words.
11.3.1
Multi-revolution Spiral Interpolation Example
The following example of spiral interpolation, see Fig. 11.1, shows the concept and the
programming techniques for performing a spiral move consisting of multiple revolutions.
The details of the spiral are:
G The centre of the spiral is at X = 0” and Y = 0”
2
2
G The start radius of the spiral = √2 = √2 = 2.8284”
A2100Di Programming Manual
Publication 91204451- 001
60
Chapter 3
May 2002
Menu
G
G
G
The end radius of the spiral = 10”
The number of revolutions = 4
Radius is increasing, therefore the Q word must be positive.
The change in radius per 360º (Q word) is defined as:
Q = (End radius – Start radius) + Number of revolutions
Q = (10” – 2.8284”) + (3 x 360º) + 315º) + 360º)
Q = 7.1716” + 3.875 = 1.8507
Figure 11.1 Multi-revolution Spiral Example
The part program blocks for this example are:
N080 G0 X-2 Y-2 Z8.2
N090 G1 Z8 F10
N100 (MSG, CUT SPIRAL)
N110 G2 G17 X-10 Y0 10 J0 Q.18507 F50
N115 (MSG, SPIRAL COMPLETED)
N120 G0 Z8.2
Alternatively, block N110 could be rewritten:
G To use the L word to directly specify the number of revolutions:
N110 G2 G17 X-10 Y0 10 J0 L3.875 F50
G To use radius specification programming:
N110 G2 G17 X-10 Y0 P1. 7929 R10 Q1.8507 F50
The word could also be programmed with a value of 4 in this example.
Note that the L word cannot be used in multi-revolution spiral blocks that use P and R
words.
A2100Di Programming Manual
Publication 91204451- 001
61
Chapter 3
May 2002
Menu
11.3.2
Conical Interpolation (G2, G3)
Conical Interpolation is a special combination of helical and spiral interpolation.
Conical motion is commanded by programming a helix, see, Section2.6, and additionally
programming a Q or an L word. The Q word is the change in radius (inches or
millimetres) per 360º of helical motion. A positive Q word value indicates that the radius
is decreasing. The L word is the number of revolutions of helical motion and must be a
positive value.
A multi-revolution conical move may be programmed in one block by specifying the
appropriate end point. The centre may be specified using the I, J and/or K words or by
programming a start radius using the P word and an end radius using the R word. The P
and R word values must be positive and must be programmed with a Q word.
The L word cannot be used in multi-revolution spiral blocks programmed using P and R
words. The lead is the I, J, or K word corresponding to the third axis and is the distance
(in inches or millimetres) to move per 360 degrees.
11.3.3
Multi-revolution Conical Interpolation Example
The following example, and Fig. 11.2, of conical interpolation shows the concept and the
programming techniques for performing a conical move consisting of multiple
revolutions:
G The centre of the spiral is at X = 0” and Y = 0”
G The start radius of the spiral = 10”
G The end radius of the spiral = 2”
G Assume top of conical move to be at Z = 10”
G Total linear axis move in Z = 8” (moves in –Z direction)
G The number of revolutions = 4
G Radius is decreasing, therefore the Q word must be negative.
G The change in radius per 360º (Q word) is defined as:
Q = (End radius – Start radius) + Number of revolutions
Q = (2” – 10”) + 4
Q = - 8” + 4 = -2
The helical lead is the unsigned distance the third axis moves for 360º of circular planar
motion. In this example, Z moves 8” while X and Y make 4 revolutions. Calculate how
much Z would move for one revolution of XY motion:
K = 8” + 4 revolutions
K = 2”/rev
A2100Di Programming Manual
Publication 91204451- 001
62
Chapter 3
May 2002
Menu
Figure 11.2 Multi-revolution Conical Example
The Part Program blocks for this example are:
N080 G0 X-10 Y0 Z10.2
N090 G1 Z10 F10
N100 (MSG, CUT CONICAL)
N110 G3 G17 X-2 Y0 10 J0 Q-2 Z2 K2 F50
N115 (MSG, CONICAL COMPLETED)
N120 G0 Z10.2
Alternatively, block N110 could be rewritten to use the L word to directly specify the
number of revolutions:
N110 G3 G17 X-2 Y0 P10 R2 Q-2 Z2 K2 F50
Note that the L word cannot be used in multi-revolution conical blocks that use P and R
words.
12
Spline Interpolation (G5.X)
Spline interpolation is a method of fitting a smooth curve, called a spline, through a
series of Cartesian points in a part program. This feature is most beneficial when
machining complex curves such as those found in part programs for producing dies,
moulds and other sculptured surfaces.
Spline interpolation is different from an interpolation mode that interpolates axis motion
along a curve that is programmed explicitly in a part program. With Spline interpolation,
the part program blocks use the same programming method as linear interpolation with
each block programmed with the X, Y, and Z end point co-ordinates. The programmed
end points are achieved by offsets, scaling, rotation, CDC, spindle normal system,
cylindrical system, and polar system. Spline interpolation derives smooth curves by
A2100Di Programming Manual
Publication 91204451- 001
63
Chapter 3
May 2002
Menu
fitting mathematical functions through programmed end points. Fig.12.1 shows an
example of a spline fitted through a series of linear points.
Figure 12.1 Spline Interpolation
12.1
Spline Programming
The G codes used to activate spline interpolation are modal and must be programmed in
a block without axis motion. Once activated, all linear interpolation (G1) blocks that
follow the spline G code become part of a set of points through which a spline is
interpolated. The modal G code G5 cancels spline interpolation, and all subsequent
linear interpolation blocks are handled in the usual way. The spline G codes are:
G G5 - Spline Off
G G5.1- Spline Curves Only
G G5.2 - Spline Corner Blends Only
G G5.3 - Both Spline Curves and Spline Corner Blends
For this release, these spline interpolation G codes must be programmed in a block that
does not cause axis motion.
Three optional parameters (I, J, and K) may be programmed in a block together with the
G5.x codes, these are:
G I, which specifies the 'length ratio threshold' and is used to distinguish between
curved and flat contours (used with G.51 and G5.3)
G J, which specifies the 'angle threshold' and is used to distinguish between smooth
curves and sharp corners (used with G5.1 and G5.3)
G K, which specifies the 'corner blend tolerance' and is used in cases where corner
blends are inserted between the locks that spline interpolation has determined
should be interpolated as normal linear blocks (used with G5.2 and G5.3)
Each optional parameters values are active until new values are programmed, or a data
reset occurs. The length ratio threshold, and the angle threshold have system-defined
limits for maximum and minimum values, and system defined values which are applied
A2100Di Programming Manual
Publication 91204451- 001
64
Chapter 3
May 2002
Menu
when modal states are reset. If programmed beyond a limit, the limit is used, and an
alert message is displayed to indicate that limiting has occurred.
The default values and range for the I, J, and K spline optional parameters are:
Program
Spline Parameter
Word
I
Length Ratio Threshold
J
K
12.2
Angle Threshold
Corner Blend Tolerance
Reset/Default
Value
2.5
Maximum
Value
5
20
Configured
35
none
Minimum
Value
1.5
5
0
Reset to
Default
-1
-1
-1
Default Values and Limits for Spline Parameters
The G2 and G3 group of interpolation blocks are always treated in the usual way
regardless of whether spline interpolation mode is active. Spline mode will transition into
and out of linear blocks and non-linear blocks (such as circular, helical, spiral, or conical)
by interpolating smooth curves whose tangent vectors at the point of transition are equal
to the tangent vectors of the non-linear or linear blocks. Tangent transitions are not
implemented in cases where there is a large direction change at the span boundary.
12.3
Corner Blend – G5.2/G5.3
Corner blend is a feature in which the control automatically inserts smooth curved spans
(splines) between two linear interpolation spans to eliminate sharp corners in the cutter
path. It is desirable to eliminate these sharp corners because they result in either a
velocity step in one or more axes, or a full stop in path speed in order to avoid the axis
velocity step.
The part program can specify the corner blend tolerance (K word) which indicates the
maximum amount that the executed tool path will vary from the original programmed
path.
A large value for blend tolerance results in less slow-down of the path speed at the
corner, but also causes a larger deviation from the programmed path. A small blend
tolerance value results in a closer reproduction of the original corner, but could cause
greater slow-down of path speed at the corner.
If the part program does not specify the corner blend tolerance, the default value will be
used.
12.4
Curve Fitting Details
A series of spline blocks refers to a series of contiguous blocks, all of which are
interpolated as splines (with the exception of the G2/G3 family), and do not cause the
axes to stop at the end of the block.
A series can only include blocks with programmed axes that are contained within the
same 3-dimensional linear Cartesian co-ordinate system. This means that a series will
be ended by programming an axis that is parallel to an axis that has already been
programmed within the series.
Programming motion on a rotary axis will also end a series.
A2100Di Programming Manual
Publication 91204451- 001
65
Chapter 3
May 2002
Menu
The geometry of the spline curve is not influenced by the geometry of the block following
the final block. Likewise, the first block of a series begins from a full stop (or nearly full
stop) and its geometry is not affected by the geometry of the previous block.
A G9 (non-modal positioning G code) may be used to separate two series of spline
blocks that describe different smooth contours. Programming a G9 indicates that the
feedrate should be reduced to zero by the end of the block and that the blocks that follow
describe a contour that is not a continuation of the previous contour.
Therefore, spline does not join the two contours with coincident tangent vectors. A G9
may also be used to apply a contour break where the 3-D co-ordinate system will be
changed without requiring that the first series ends with a linear interpolation block.
Using a G60 (positioning mode G code) in spline mode will result in all following blocks
being interpolated as linear blocks until the next G61 (contouring mode G code) see Fig
12.2.
A block that creates a 'wait for steady-state condition' is treated as the last block of a
series, just as a block with a G9. single-block and dry-run modes result in the identical
interpolation path that would have been obtained without these features active.
Start-of-span-requests do not cause the series to be broken, even if the block may
involve a deceleration to zero velocity at its endpoint.
Spline makes the following decisions about how to interpret a local portion of a program:
G
Spline does not attempt to fit a smooth curve through two consecutive blocks whose
lengths are very dissimilar. If the ratio of the length of the long block to the length of
the short block is greater than the programmed (or default) threshold, spline
redefines the long block as a linear block
The short block is interpolated as a smooth curve that joins the long linear block in
such a way that its tangent vector is coincident with that of the linear block. The
length ratio threshold may be programmed to a non-default value by including a I
word in the G5.x block.
Figure 12.2 Re-definition of a Long Block to a Linear Move
G
Spline does not try to fit a smooth curve through two consecutive blocks whose
chord vectors cause a change of direction involving an angle that is greater than the
angle threshold. The threshold is programmable using the J word in the G5.1 (or
A2100Di Programming Manual
Publication 91204451- 001
66
Chapter 3
May 2002
Menu
G5.3) block. When the angle of direction change exceeds the threshold, each block
is interpolated as if it were linear.
The blocks adjacent to the linear blocks are spline blocks that join the linear blocks in
such a way that their tangent vectors are coincident. If corner blends are activated (G5.2
or G5.3), the boundary between the two linear blocks is modified by inserting a corner
blend, see Fig 12.3.
The distance from the programmed corner to the blend is specified by the corner blend
tolerance (K word, or the spline corner blend default tolerance). If corner blend is not
active, the boundary will be a sharp corner.
Figure 12.3 Corner Blend in Sharp Corners
G
Spline joins spline blocks tangentially to explicit linear, circular, or helical blocks.
However, this is not done if the spline blocks chord vector has a direction change
angle with the linear/circular/helical blocks tangent vector that is greater than the
angle threshold. If this is so, the spline block is converted to a linear block.
If the explicitly programmed block is linear, a corner blend is inserted (if the feature
has been activated). If the explicit span is circular (or a variation of circular), then a
full stop will occur at the boundary between the linear and circular spans, see Fig.
12.4.
Figure 12.4 Explicitly Programmed Circular Spans in Spline Interpolation
A2100Di Programming Manual
Publication 91204451- 001
67
Chapter 3
May 2002
Menu
13
Tilt Spindle G Codes
13.1
G52.1 Spindle Normal Co-ordinate System
A tilt spindle machine has one or more rotary axes that define the position of the spindle.
Parts cut on these machines often have drawings with features specified in Cartesian coordinates but normal to a specified orientation of the tilt spindle. To simplify
programming these parts, the spindle normal co-ordinate system feature provides the
capability to define a Cartesian co-ordinate system that is normal to a tilted spindle.
Modal G code G52.1, activates the feature. Axis words (X, Y, Z, U, V, W, A, B, and C)
programmed within the G52.1 block specify the origin of the spindle normal co-ordinate
system that is active when G52.1 is programmed.
Example
Consider part of a workpiece containing a feature that is originated at X=10”, Y=5”, and
Z=20” in machine axis dimensions but tilted at 45º.
The programmer first tilts the spindle to 45º, then specifies the block G52.1 X10 Y5 Z20
to establish a spindle normal co-ordinate system whose X, Y, and Z zero point is at
X=10”, Y=5”, and Z=20” in the previous co-ordinate system. No machine motion occurs
on a G52.1 block.
Once a spindle normal co-ordinate system is active, rotating the tilt spindle axis has no
effect on the spindle normal co-ordinate system. This allows ‘5-axis’ contouring within
an established spindle normal co-ordinate system. Programming another G52.1 block
with a spindle normal co-ordinate system already active, simply specifies a new spindle
normal co-ordinate system in the dimensions of the previous spindle normal co-ordinate
system.
The spindle normal co-ordinate system established by a G52.1 is cancelled by
programming a G13.1. A G13.1 restores the last non-spindle normal co-ordinate
system. G13.1 also turns off cylindrical and polar interpolation. The spindle normal coordinate system is also reset by data reset or end of program.
All interpolation modes (G0, G1, G2, etc.) are allowed when a spindle normal co-ordinate
system is in effect. Programming features such as cutter diameter deviation, radius/fillet
blending, scaling, etc. are also permitted within the spindle normal co-ordinate system.
Spindle Normal Programming Considerations
G Cutter diameter compensation (G41, G42) may be programmed within the spindle
normal co-ordinate system but cannot be active when activating or deactivating
spindle normal co-ordinates.
G
Tool length is applied parallel to the tilted spindle. See G44 and G44.1 for tool
length description.
G
Pallet co-ordinates (G50) may be programmed within the spindle normal co-ordinate
system. However, the commands are in pallet co-ordinates and are not normal to
the spindle.
G
Fixture offsets (H word) may be programmed within the spindle normal co-ordinate
system. The offsets are applied in machine axis co-ordinates.
G
Set High / Set Low Limits (SH1, SLO) are not allowed within the spindle normal coordinate system.
A2100Di Programming Manual
Publication 91204451- 001
68
Chapter 3
May 2002
Menu
13.2
G44/G44.1 Multi-axis Tool Length Compensation
When a tilt spindle is configured and the tilt spindle tool length compensation option is
present, the G44 and G44.1 G codes determine how the multi-axis tool length
compensation feature will be applied.
13.3
G44 Apply Tool Length Deviation and Tool Offset
The G44 code instructs the multi-axis tool length compensation feature to apply a
transformed tool length deviation offset to the command positions. This tool length
deviation offset is the sum of the active tools 'length deviation' and the programmable
tool offset 'length' value (selected by the O word), if any.
Deviation offset is based on the active tools 'holder orientation' and is transformed to a
multi-axis offset based on the tilted axis position. The programmed axis positions are
assumed to reference the spindle nose, not the tool tip, and only slight tool deviations
should be compensated.
13.3.1
G44.1 Apply Total Tool Length
The G44.1 code instructs the multi-axis tool length compensation feature to apply a
transformed total tool length offset to the commanded positions. This total tool length
offset is the sum of the active tools 'length' and 'length deviation', and the programmable
tool offset 'length' value (selected by the O word), if any.
The total tool length offset is based on the active tools 'holder orientation', the pivot
distances are applied, and then transformed to a multi-axis offset based on the tilted
axis’ position. In this mode, the programmed axis positions are assumed to reference
the actual tool tip.
A2100Di Programming Manual
Publication 91204451- 001
69
Chapter 3
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204451- 001
70
Chapter 3
May 2002
Menu
Chapter 4
OFFSETTING CO-ORDINATES
Contents
1
1.1
2
2.1
3
3.1
3.2
3.3
3.4
3.5
3.6
3.7
3.8
3.9
3.10
3.11
3.12
4
5
5.1
5.2
5.3
6
7
7.1
8
8.1
8.2
8.2.1
8.2.2
8.2.3
8.2.4
8.2.5
8.3
8.3.1
Introduction.......................................................................................... 3
Shifting the Coordinate System ...........................................................3
Zero Shift .............................................................................................. 4
G92, G92.1 and G92.2 Position Set ......................................................4
Part Program Alignment...................................................................... 6
Using Position Set ................................................................................6
Position Set Feature .............................................................................6
G92 And G92.1 Programming Considerations....................................7
Position Set Cancel G99.......................................................................8
Local Coordinate System (G52) ...........................................................8
INV (Axis Invert) ....................................................................................9
ROT (Rotate)........................................................................................10
Examples of Coordinate Rotation......................................................11
Machine Coordinates Programming (G98 and G98.1) ......................12
G98 Machine Coordinates Programming (Tool Tip Reference) .......13
G98.1 Machine Coordinate Programming (Spindle Face Ref) .........13
Automatic Cutter Dia Compensation(CDC) (G40, G41, G42)............14
Outside Corner Sample Program...................................................... 15
Programming Guidelines .................................................................. 16
G43 PQR Cutter Diameter Compensation .........................................17
Programming Examples .....................................................................19
Symbols and Definitions ....................................................................23
Multiple Setups .................................................................................. 27
Pallet Offsets...................................................................................... 28
Pallet Coordinates Programming (G50).............................................29
NC Program Controlled Offsets ........................................................ 29
Fixture Offsets (H Word).....................................................................29
Fixture Offset Examples .....................................................................30
Fixture Offset Set-Up X And Y........................................................... 30
Fixture Offset Set-Up X And Y........................................................... 31
Fixture Offset Z Axis Set-up .............................................................. 32
Fixture Offset With Axis Inversion.................................................... 32
Fixture Offset With Rotary Axis - (If Supplied)................................. 33
Programmable Coordinate Offsets (D Word) ....................................34
The D Word......................................................................................... 35
A2100Di Programming Manual
Publication 91204451- 001
1
Chapter 4
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204451- 001
2
Chapter 4
May 2002
Menu
1
Introduction
An NC program expresses locations and dimensions in terms of co-ordinates, measured
from an origin. The NC program co-ordinate system, referred to as program coordinates, must be setup so that the program co-ordinates refer to the actual location of
the part to be machined, before machining can begin.
A machine tool has its own 'natural' co-ordinates, referred to as machine co-ordinates.
The origin of the machine co-ordinate system is set by the machine tool builder, usually
with zero at one end of axis travel. There are several means by which the program coordinates used by an NC program can be made to correspond with the actual location of
the workpiece on the machine. All of these methods produce an offset between the
program co-ordinates and the machine co-ordinates.
This Chapter presents the features and capabilities that allow one or several NC
program co-ordinate systems to be established and adjusted for various conditions.
These features fall into two broad categories: setup and adjustment.
Setup offsets are used to locate the NC program co-ordinates on the machine itself, and
generally offset the program co-ordinate system so that the NC program co-ordinates
coincide with the actual workpiece location. The control allows for a single program (and
co-ordinate system), multiple set-ups (each with a co-ordinate system), and for machines
with automatic work-changers, multiple workpieces set up on each pallet.
Adjustment offsets are generally controlled by the NC program and are provided to allow
the machine operator to enter corrections for variations in stock, workpiece or tool
deflection, actual cutter size, and similar conditions that can occur.
1.1
Shifting the Co-ordinate System
A Co-ordinate System Shift operation is used to shift the Program Co-ordinate System
such that program zero may be located at the zero reference position in the workpiece.
Co-ordinate System Shift can be performed in the following recommended priority:
G
G92.1 Position Set Multiple Setup Offsets
G
Zero Shift (Operator Function)
G
D Word Programmable Offsets
G
H Word Fixture Offsets
G
G92.2 Position Set Pallet Offsets
G
G92 Position Set
Note
If there is currently no co-ordinate system shift active, program zero and machine zero
are located at the same position on the machine.
One important use of this feature is to allow writing the NC program without considering
the physical location of the workpiece on the machine. The zero point for the NC
program is then positioned by the operator during workpiece setup.
One important consideration when selecting the program co-ordinates for a part is how
the operator will perform the setup. Some feature on the workpiece or fixture that can be
located accurately is generally used as the reference point to establish the program coordinate system.
A2100Di Programming Manual
Publication 91204451- 001
3
Chapter 4
May 2002
Menu
2
Zero Shift
Zero Shift is a manual operation performed during setup. Zero Shift enables the operator
to move the machine axes without affecting the program co-ordinate position. If the X
axis was positioned to the program co-ordinate of X=4.5 inches and then moved 2
inches with Zero Shift active, the current program co-ordinate position remains at X=4.5
inches. This produces a 2 inch shift of program zero with respect to machine zero.
Zero Shift can be used to adjust program co-ordinates to agree with the actual workpiece
location. This can be done by moving the machine to the program co-ordinates of a
reference point on the work (or on the work-holding device) using MDI or Manual
controls (power feed and handwheel). When the machine is positioned at the program
co-ordinate, zero shift can be used to bring the actual machine position (usually the tool
tip) to the correct relationship with the reference point.
Zero Shift is cancelled by executing a G99 code, or by operator intervention.
2.1
G92, G92.1 and G92.2 Position Set
The nonmodal Position Set Preparatory Codes G92 and G92.1 provide a means to
redefine the part co-ordinate system. The part co-ordinate system offset from the base
co-ordinate system is redefined for all axes programmed in the G92 or G92.1 block. No
machine motion occurs.
The pallet co-ordinate system offset from machine co-ordinates for the active pallet is
redefined by G92.2.
The difference between G92 and G92.1 is that G92 offsets are separate from the setup
offsets, and are not affected by changing between set-ups. G92.1, however, recomputes the setup offsets for the active setup and stores the new setup offsets in the
Multiple Setup Table.
The co-ordinate offsets established by G92 apply to all set-ups, and remain in effect until
another G92 Position Set is performed, or until a Position Set Cancel (G99) is executed.
If G92 is used to establish the relationship between NC program co-ordinates and the
actual workpiece setup in a multiple setup environment, any change made in any setup
changes the co-ordinates for all set-ups. G92.1, however, only affects the NC program
co-ordinates of the setup which is active when G92.1 is executed.
NC program co-ordinates established by G92.1 remain with the setup, so that if multiple
set-ups are used, G92.1 can be used in each setup to establish the relationship between
the workpiece or fixture, and the NC program co-ordinates. The offsets established
remain with the setup and are re-established every time setup is reactivated.
Note
The value of G92 is not displayed in any table. The Current Position value is the sum of
all offsets. If knowing the value is required, use the G92.1 block to load values into the
multiple setup offsets table.
G92.2 is provided to allow pallet co-ordinates to be set easily. The axis words in a G92.2
block represent the co-ordinates of the current position in pallet co-ordinates. The effect
of G92.2 is to set the pallet offsets of the active pallet to the difference between the
programmed axis values and the current machine position.
For example, if a pallet is accurately located by tramming a hole at the center of the
pallet, and the X and Y location of the pallet center is supposed to be 0,0, the pallet
A2100Di Programming Manual
Publication 91204451- 001
4
Chapter 4
May 2002
Menu
offset can be set by executing a block containing G92.2 X0 Y0 Z0. As pallet offsets have
only X, Y, and Z co-ordinate values, only those axes are permitted in a G92.2 block.
The Spindle Probe cycles have a provision to perform a Position Set by specifying an I,
J, or K word in the cycle invocation. The Position Set done by the probe cycles is a
G92.1; that is, it computes the Setup Offset, not the Position Set offset. The probe cycles
can also be programmed to set the pallet offset by specifying H1. In this case the probe
cycles use G92.2 to perform the offset adjustment.
With either G92 or G92.1, and if the Pallet Offset feature is present, the base co-ordinate
system is the active setup co-ordinate system of the active pallet. If the Pallet Offset
feature is not present, the base co-ordinate system is the active setup co-ordinate
system.
The effect of ”G92 X10.” is to define the present position of the X axis as 10.0 millimetres
(if the system is in metric mode) or 10.0 inches if the system is in inch mode.
A second use of the Position Set (G92 or G92.1) Preparatory Codes is to specify the
maximum spindle speed allowed. The G92 or G92.1 blocks S word specifies the
maximum allowable spindle speed in RPM. If the control is in Constant Surface Speed
mode and computes a spindle speed from the specified surface speed and the current
axis position that would exceed the G92 or G92.1 block specified maximum speed, the
maximum RPM value is used instead of the calculated spindle speed. If the control is not
in CSS mode, programmed spindle speed values are not permitted to exceed the G92 or
G92.1 S word value.
The maximum spindle speed setting cannot be specified in a G92.2 block.
Note that the F word is not permitted in G92, G92.1 or G92.2 blocks
Fig 1.1 assigns the current position of the axes co-ordinate values of X=4, Y=3 and Z=2
inches. These values are displayed on the screen as the current axes position after
block G92 X4 Y3 Z2 is executed.
Figure 2.1 Position Set
A2100Di Programming Manual
Publication 91204451- 001
5
Chapter 4
May 2002
Menu
3
Part Program Alignment
The programmer must have the ability to convey to the machine operator the relation
between the part program co-ordinate system and the physical machine co-ordinate
system.
3.1
Using Position Set
The Position Set feature allows the operator and programmer to assign co-ordinate
values to the current axis positions. A Position Set operation defines the relationship
between the machine co-ordinate system and the part co-ordinate system.
There are two ways to assign a Position Set operation:
G
Assign the required co-ordinate values using Preparatory Function G92 or G92.1
(Position Set) in the NC program.
G
Use the MDI mode (execute a G92 or G92.1 block with the appropriate axis address
and the required co-ordinate values). This will replace the current position of the
relevant axis with the values contained in the G92 or G92.1 block.
Fig. 3.1 Position Set Assign Coord. Values
3.2
Position Set Feature
The example below uses the Position Set feature to establish the correct program
coordinate system. The diagram below illustrates how the coordinates for the part
program would be calculated.
Conditions:
G Axis Align Complete.
G Tool Point Positioned at the Corner of the Part.
G X0 - Y0 Position Set to the Corner of the Part.
A2100Di Programming Manual
Publication 91204451- 001
6
Chapter 4
May 2002
Menu
Figure 3.2 Position Set
The operator positions the workpiece at a convenient position on the table, then
positions the tool tip to the datum (corner of part) using manual controls (power feed or
handwheel). When the tool tip is correctly positioned, the operator performs a position
set of X0 Y0 using MDI.
To calculate the coordinates for each position, the programmer must calculate the
distances from the programmed zero, located at the corner of the part.
To find Hole 1:
X Calculation Hole No. 1
X = +1 Y
Calculation Hole No. 1
Y = +1
3.3
G92 And G92.1 Programming Considerations
The following should be considered when programming a G92 and G92.1 - Position Set:
G
G
G
G
G
Any axis position may be redefined.
The G92 or G92.1 may be executed with either absolute or incremental mode active.
The coordinates of the G92 block are always absolute.
Only the axes programmed in the G92 or G92.1 block are redefined.
A block containing a G92 or G92.1 does not cause axis motion.
The coordinate shift defined by G92 or G92.1 remains in effect until:
Another G92 or G92.1 operation is performed.
Until cancelled by a G99 code (G92 only).
Until reset by touching the Reset Part Coordinates menu button in the Coordinate
Setup Menu (G92-1 only).
A2100Di Programming Manual
Publication 91204451- 001
7
Chapter 4
May 2002
Menu
Position Set is not affected by:
M2 - End of Program.
M30 - End of Program (Put Tool Away).
Data Reset.
For G92.1, the shift changes the Setup Offset. It remains with the setup, until it is
replaced by the new setups offset whenever the active setup changes. It is not
affected by Data Reset, or M2, M30, or by G99.
3.4
G
The G92 or G92.1 is non-modal.
G
The only words permissible in a G92 block are: N, Q, X, Y, Z, U, V, W, A, B, C, F, and
S.
G
G92 locations are not displayed by the control. If knowing the position set location is
required, use G92.1.
Position Set Cancel G99
The nonmodal Preparatory code Position Set Cancel (G99) resets the part coordinate
system to be the same as the base coordinate system. If Pallet Offsets are present, the
active Pallet and Setup are the base system; otherwise the base system is the active
Setup referred to machine coordinates. The effect of a G99 is to remove the effects of
any G92 Position Set and Zero Shift.
Note that the setup offsets changed by a G92.1 Position Set are not reset by G99.
3.5
Local Coordinate System (G52)
It is sometimes convenient to define a local coordinate system for one region of an NC
program, either to take advantage of symmetry, or to program a part feature in the
dimensions found on the drawing. The Local Coordinate System (G52) feature provides
this capability without altering any position set that was used by the operator to establish
the setup.
G52 is a nonmodal function that defines a local coordinate system whose origin (zero
point) is specified by the axis words (X, Y, Z, U, V, W, A, B, and C) programmed in the
G52 block.
Axis words in a G52 block are treated as dimensions in the coordinate system that is
active when G52 is programmed.
Example
If a portion of the workpiece contains a symmetrical feature centered at:
X= 50mm
Y=125mm
Programming G52 X50 Y125 establishes a local coordinate system whose X and Y zero
point is at X=50mm, and Y=125mm in the previous coordinate system.
The effect of a G52 is cancelled by programming another G52 block specifying all axis
words as zero. This resets the local coordinate system to have zero offset from the
original coordinate system. If, as in the example, not all axes are offset, it is only
necessary to set to zero the axes that were originally changed.
A2100Di Programming Manual
Publication 91204451- 001
8
Chapter 4
May 2002
Menu
Example
G52 X0 Y0 would reset the local coordinate system in the previous example.
The local coordinate system is also reset by Data Reset or End of Program.
The local coordinate system is applied to the active setups part coordinate system.
If the machine has a pallet changer, the local coordinate system is referred to the zero of
the active setu’s part coordinate system, which is referred to the active pallets Pallet
Coordinate system.
If the NC program changes from one Part Coordinate System to another, the local
coordinate offset is applied to the new Part Coordinate System.
3.6
INV (Axis Invert)
Axis Inversion permits both left and right handed parts to be machined by the same NC
program. When an axis is inverted, the sign of all programmed motion for that axis is
inverted about the axis zero point. The inversion applies only to programmed motion and
not to offsets such as fixture offsets, or to programmed U and V tip offsets used in G86,
G87 and G88 Bore Fixed Cycles.
When one axis in a plane is inverted, all of the features that are direction sensitive are
automatically inverted also to allow the program to function correctly. Axis inversion
affects circular interpolation (G2 and G3 are inverted to maintain symmetry); automatic
CDC codes G41 and G42 (cutter right and cutter left) are reversed, and so on.
The axis inversion state can be specified by the program using the INV Type II block, the
format of which is:
[<label>] [Nxxxx] (INV,<axis words>)
Where:
<label> is an optional label on the INV block.
Nxxxx is the optional sequence number for the INV block.
<axis words> is any combination of axis letter addresses X, Y, Z, U, V, W, A, B, or
C.
Programming any axis word with a value of zero turns off axis inversion for that axis.
Programming a value of 1 for any axis selects axis inversion for that axis. For example,
N0100 (INV, X1 Y0) causes the X axis to be inverted and the Y axis dimensions to be
normal. All other axis inversion states are unchanged.
Note that axis inversion specified by an INV block is cancelled by Data Reset or End of
Program. Processing a colon (:) block does not reset the status of Axis Inversion.
When used in combination with Local Coordinates (G52), Axis Inversion allows part
symmetry to be exploited. As the INV block inverts an axis about program zero, it is often
convenient to first establish a local coordinate system with zero at the axis or axes of
symmetry, and then use INV to obtain the inversion.
For example, in the part shown below, the part coordinate origin (X0, Y0) is established
at the front left of the part because all part dimensions are referred to the corner on the
drawing. There are four irregular shaped pockets symmetrically arranged.
A2100Di Programming Manual
Publication 91204451- 001
9
Chapter 4
May 2002
Menu
The programming task is simplified by programming the pocket once and copying the
block for the other three. The program might be structured as:
:100
(blocks to machine part outline)
G52 X10 Y5
(blocks to machine pocket #1)
(INV, X1 Y0)
(blocks to machine pocket #2)
(INV, X1 Y1)
(blocks to machine pocket #3)
(INV, X0 Y1)
(blocks to machine pocket #4)
(INV, X0 Y0)
G52 X0 Y0
Note that the blocks to machine the four pockets are identical. The computation of all of
the coordinates need be done only once.
Figure 3.3 Axis Inversion
3.7
ROT (Rotate)
The Coordinate Rotation feature allows workpieces or sections of workpieces that are
dimensioned at an angle to the primary coordinate axes to be programmed without using
trigonometric functions. Programming a ROT block creates a coordinate system in the
selected plane that is rotated from the primary coordinate axes in that plane.
In the XY plane (G17 in effect) the primary axes are X or U and V or Y.
In the YZ plane (G19 in effect) the primary axes are Y or V and Z or W.
In the ZX plane (G18 in effect) the primary axes are Z or W and X or U.
Coordinate Rotation is initiated by a ROT Type II block. The word addresses in the ROT
block are G, X, Y, Z, U, V, W, and A, as follows:
[<label>] [Nxxxx] (ROT, [G<mode>] A<angle> <axis words>)
A2100Di Programming Manual
Publication 91204451- 001
10
Chapter 4
May 2002
Menu
Where:
<label> is an optional label on the ROT block.
Nxxxx is the optional sequence number for the ROT block.
The G word determines the meaning of the axis words in the ROT block as follows:
G0 or G absent defines the axis words as the centre of rotation in the current program
coordinates, including any rotation already active.
G1 defines the axis words as the centre of rotation in current program coordinates but
without any rotation already active.
G2 defines the axis words as the unrotated incremental distance from the current axis
position.
G3 defines the axis words as the machine coordinates (which are always unrotated)
of the centre of rotation.
<angle> specifies the angle of rotation about the specified centre of the rotated
coordinate system. The angle is measured counter clockwise from the primary axis of
the selected plane to the same axis of the rotated coordinate system.
<axis words> specify the plane and the coordinates of the centre about which the
new coordinate system is rotated. At most two axis words may be specified, and they
must lie in the selected plane. For example, in the XY plane (G17 active), either X or
U and Y or V can be selected. If neither X nor U is selected, the current position of
the X axis is selected, and so on.
The rotation applies to programmed coordinates including the U and V Tip Offsets used
in G86, G87 and G88 Bore Fixed Cycles. Coordinate rotation does not apply to offsets
such as Fixture Offsets; nor to spindle orientation commands, typically the J word
orientation command used in G86, G87 and G88 fixed cycles. The rotation introduced by
a ROT block is cleared by Data Reset, End of Program or a ROT block specifying a zero
angle. The rotation may also be cancelled by a colon block depending how the system is
configured. See Appendix B to set default.
3.8
Examples of Coordinate Rotation
The following program illustrates how the coordinate rotation feature can be used to
machine the ten 8 mm diameter holes of the workpiece shown on Figure 2.4. It is
assumed that the tool has already been loaded into the spindle and appropriate feeds,
speeds, etc., have been set.
N1030 X80 Y165
N1040 (ROT, G1 X40 Y45 A36)
N1050 G81 X77.5 Y47 R... Z-...
N1060 X97.5
N1070 Y67
N1080 X77.5
N1090 Y87
N1100 X97.5
N1110 Y107
N1120 X77.5
N1130 Y127
A2100Di Programming Manual
Publication 91204451- 001
11
Chapter 4
May 2002
Menu
N1140 X97.5
N1150 (ROT, A0)
Alternatively using a hole pattern cycle
N1030 X80 Y165
N1040 (ROT, G1 X40 Y45 A36)
N1050 G38 I2 U20 J5 V20
N1060 G81 X77.5 Y47 R.... Z....
Figure 3.4 Coordinate Rotation
3.9
Machine Coordinates Programming (G98 and G98.1)
Nonmodal Preparatory codes G98 and G98.1 instruct the control to interpret the axis
dimensions in the block as relative to machine zero instead of the part coordinate system
zero. Use of G98 or G98.1 allows the NC program to move to fixed locations on the
machine regardless of the coordinate offsets which are active.
This is useful for fixed probe applications (to measure tool length and diameter), for
finding a fixture using a spindle probe, and any other operations that require the tool tip
to be positioned to a known machine location.
The difference between G98 and G98.1 is that the coordinate values in a G98 block refer
to the tool tip location while the coordinates in a G98.1 block refer to the axis positions
A2100Di Programming Manual
Publication 91204451- 001
12
Chapter 4
May 2002
Menu
with no tool present. G98.1 is useful to move an axis to the machine limits, or to program
moves for special applications such as setting the tool tram surface or loading tools into
the spindle. G98 is useful when it is required to move the tool tip to a location relative to
the machine axes independent of the pallet, setup, and other active offsets.
3.10
G98 Machine Coordinates Programming (Tool Tip Reference)
Machine Coordinate programming is accomplished by a block containing a G98 code.
The G98 is nonmodal and defines the dimensions in the block to be the absolute
coordinates of the tool tip measured from machine zero. When using G98, note the
following:
G Machine coordinates are always expressed as absolute coordinates measured from
machine zero, even if Incremental mode (G91) is active.
G All Zero Shift, Position Set Offsets, Pallet, Setup, Fixture, and Programmable
Coordinate Offsets are ignored. Tool Length Offsets (both the Tool length from the
Tool Table and Programmable Tool Offset) and Machine Offsets (actuated by the D
word) are active.
G The interpolation mode must be G0 or G1.
G G98 may not be used with cutter diameter compensation active.
G A radius blend (R word) or a chamfer blend (,C word) is not allowed in a G98 block.
G The offsets in effect before execution of a G98 block are in effect immediately after
the G98 block. The current positions of the slides in program coordinates are updated
to reflect the movement made and remain relative to Program Zero.
3.11
G98.1 Machine Coordinate Programming (Spindle Face
Reference)
Machine Coordinate programming is accomplished by a block containing a G98.1 code.
The G98.1 is nonmodal and defines the dimensions in the block to be the absolute
coordinates of the tool tip measured from machine zero. When using G98.1, note the
following:
G Machine coordinates are always expressed as absolute coordinates measured from
machine zero, even if Incremental mode (G91) is active.
G All Zero Shift, Position Set, Pallet, Setup, Fixture Offsets, Programmable Coordinate
Offsets, Tool Lengths and Tool Offsets are ignored. Machine Offsets are active.
G The interpolation mode must be G0 or G1.
G G98.1 may not be used with cutter diameter compensation active.
G A radius blend (R word) is not allowed in a G98.1 block.
G The offsets in effect before execution of a G98.1 block are in effect immediately after
the G98.1 block. The current positions of the slides in program coordinates are
updated to reflect the movement made and remain relative to Program Zero.
A2100Di Programming Manual
Publication 91204451- 001
13
Chapter 4
May 2002
Menu
CAUTION
Programming a G98.1 block with a Z coordinate will position the spindle nose (not
the tool point) to the specified Z axis machine coordinate. If it is necessary to
position the tool point at a specific Z axis machine coordinate, use G98.
Failure to heed this Caution may result in damage to equipment.
3.12
Automatic Cutter Diameter Compensation (CDC) (G40, G41, G42)
This feature compensates the actual machine cutter path to allow the use of cutters with
a diameter different from the nominal size of the tool assumed when the program was
prepared. Cutter Diameter Compensation (CDC) is activated by programming G41 if the
cutter is to the left of the workpiece when viewed in the direction of motion, or G42 if the
cutter is to the right of the workpiece.
When CDC is active, the control computes new intersection points at every change of
direction, so that the contact point between the actual cutter is the same as it would be
for the nominal sized cutter following the original program path.
CDC automatically computes the offset command point for any intersecting moves,
including circular and helical arcs. In the case of circular arcs, the transition between the
circle and the subsequent line or circle need not be tangential to the arc. CDC is turned
off by programming G40.
In addition to correcting the cutter path, CDC avoids wasted time 'cutting air' by inserting
an arc to round outside acute angles, and automatically detects many geometric
situations where an oversized cutter cannot cut the required contour.
To determine the direction of cutter motion, CDC looks ahead in the NC program until
the next axis motion block is located. This look ahead allows blocks that do not specify
any axis motion in CDC while it is active. The number of non motion blocks permitted is
determined by the total look ahead capability configured, typically 30 to 150 blocks.
Automatic CDC operates in the machine plane selected by the active Plane Select code
(G17 for XY, G18 for ZX, G19 for YZ). Commanded motion in the axis perpendicular to
the selected plane and in rotary axes is allowed.
Diameter offset is the difference between the nominal tool (see Tool Compensation)
used by the NC program and the actual tool. This value is stored in the control Tool Data
table as the Diameter Offset field of the tool. If the nominal tool diameter is zero, the
Diameter Offset would be the actual tool diameter. If the nominal tool diameter is nonzero (tool edge programming), the Diameter Offset would be the actual tool diameter
minus the tool diameter used by the NC program.
Diameter Offset can be entered by the machine operator, set by a host computer
system, or computed by the NC program using a probe to measure the tool directly or
indirectly by measuring a test cut.
In addition to the per-tool diameter offset stored in the A2100 tool table, the NC program
can select an additional tool diameter and length offset value using the O-word (see
Programmable Tool Offsets). The O-word selects a programmable tool length and
diameter offset from a table of offset values. These offsets are added to the offset
obtained from the tool table to form the total length and diameter compensation values.
A2100Di Programming Manual
Publication 91204451- 001
14
Chapter 4
May 2002
Menu
Per-tool length and diameter compensation values are used to correct for the difference
between the size of the actual tool and the tool diameter assumed by the NC program.
The Programmable Tool Offset value is used for finish stock allowance and other part or
process related purposes.
Note
The programmable tool diameter offset O word cannot be changed while CDC is active.
It is valid to program an O word with a new diameter offset in the first G41 or G42 block;
that is the block in which CDC is turned on.
The difference between the cutter diameter assumed by the NC program and the actual
cutter is stored in the Diameter Offset column of the tool data table. It may be entered
into the control via the keyboard or from the NC program.
A positive (+) offset value indicates an oversize cutter, a minus (-) offset value an
undersize cutter.
Figure 3.5 Automatic Cutter Diameter Compensation
4
Outside Corner Sample Program
To avoid large departures from the programmed axis command positions when
machining the outside corner of a part surface, the control generates a circular arc to
'round' the corner. In linear interpolation mode, an outside corner is an angle greater
than 270 degrees on the part surface side of the cutter.
The centre point of the inserted circular arc is the intersection, or corner, and the radius
of the arc is the cutter radius offset. An outside corner may also exist for the nontangential intersection of a line and a circular arc or between two circular arcs. An
additional circular span may be necessary in the case of two circular arcs when the
compensated circular arcs do not intersect.
The following sample program illustrates the path of an outside corner. The cutter
Diameter Offset for this example is .4 inches:
:G0 G61 G70 G90 X0 Y0
A2100Di Programming Manual
Publication 91204451- 001
15
Chapter 4
May 2002
Menu
N10 G1 F50 T2 M6
N20 X0 Y5
N30 G41 X5 Y5
N40 X10 Y0
N50 X0 Y-2
N60 G40 X0 Y-3
N70 M2
Figure 4.1 Outside Round-cornering
5
Programming Guidelines
Automatic CDC is still active when axis inversion is selected. The control processes the
motion blocks and modifies the X and Y axis coordinates according to the cutter
compensation G code and cutter diameter input. The mirror image effect is produced by
the control inverting the resultant coordinates.
Changing the offset mode between G41 and G42 in adjacent blocks cause the resulting
end point to be located perpendicular to the next motion span.
Reversing the direction of offsets in adjacent blocks causes an alarm to be reported if
the programmed cutter motion returns the tool along its original path. In this situation, the
change between G41 and G42 must be made using an intermediate G40 block.
Automatic CDC programming is active in either the G90 absolute or G91 incremental
input mode.
Auto CDC can be programmed using the MDI mode as the control allows multiple MDI
blocks. However, G40 must be programmed within the MDI 'program' or an error is
reported.
A2100Di Programming Manual
Publication 91204451- 001
16
Chapter 4
May 2002
Menu
5.1
G43 PQR Cutter Diameter Compensation
While Automatic Cutter Diameter Compensation is simple to program and is capable of
handling many common machining situations, it is not able to compensate for differences
between the actual cutter and the cutter assumed by the NC program in more complex
multiaxis machining situation.
This is because the geometry of the part and cutter are not available to the control, and
in these cases, the PQR Cutter Diameter Compensation feature can be used to allow
cutters other than the nominal sized cutters assumed by the NC program to be used.
PQR CDC offsets the programmed cutter path along a unit vector whose components
are specified in the P, Q, and R words. The P, Q, and R words specify the components
of the offset vector in the X, Y and Z directions respectively.
PQR CDC is selected by programming a G43 preparatory function while the control is in
G40 mode (CDC off). PQR CDC is turned off by programming a G40 (CDC Off). When
PQR CDC is on, every motion block must have the appropriate values for P, Q, and R
programmed.
As this feature requires the use of the P and R words, radius blend specified using the R
word and circular interpolation specifying the circle radius are not allowed. Radius blends
specified using ,"R" are allowed with PQR CDC.
The amount of the offset is determined by the sum of the per-tool Diameter Offset value
and the active Programmable Tool Offset value exactly as described for Automatic
Cutter Diameter Compensation.
Figure 5.1 shows the way in which the signs for the P and Q words are determined. The
signs are independent of the sign of the X and Y value, instead, they indicate the
direction of the offset from the programmed point.
Fig. 5.1 Determination and Designation of P and Q Signs
A2100Di Programming Manual
Publication 91204451- 001
17
Chapter 4
May 2002
Menu
The cutter compensation vector is formed from the intersection of two spans, to the
intersection of construction lines, offset one unit, (1.0), and parallel to the lines forming
the spans. The cutter compensation vector always points away from the part contour,
independent of cutter path direction.
To construct the cutter compensation vector in Figure 5.1 the following steps are used:
G
At a Unit Vector distance, draw construction lines parallel to the programmed cutter
centreline path.
G
The cutter compensation vector is formed by a line drawn from the programmed point
(P2) to the intersection of the construction lines.
G
Lines drawn parallel to each axis (X and Y), one through the intersection point of the
construction lines and the other through the programmed point, form the right triangle
representing the P and Q components.
G
The P and Q components are positive values because the cutter compensation vector
points into the first quadrant (see Figure 5.2).
Fig. 5.2 Cutter Path, Cutter Offset to Outside
Figure 5.3 shows a part contour with the cutter offset to the inside.
The steps for constructing the Cutter Compensation Vector, used on Fig. 5.1 also apply
to Figure 5.3
The P and Q component vectors are negative for this part because the cutter
compensation vector points into the third quadrant.
A2100Di Programming Manual
Publication 91204451- 001
18
Chapter 4
May 2002
Menu
Fig. 5.3 CDC Cutter Path Offset to Inside
5.2
Programming Examples
The cutter path will always have the cutter compensation vectors pointing away from the
part surface, as shown in Fig. 5.1. The sign of the P and Q values will be determined by
the direction of compensation vector.
N010
N011
N012
N013
G1
P +1
X 4.0000
X 6.0000
X 10.0000
Q +1
Y 5.0000
Y 5.0000
Q-1
Y 10.000
(P1)
(P2)
(P3)
(P4)
It is not necessary to repeat the coordinate information and its respective cutter
compensation component value when they have not changed from the previous block,
this is shown in block N012.
A2100Di Programming Manual
Publication 91204451- 001
19
Chapter 4
May 2002
Menu
Fig. 5.4 Cutter Path with CDC Vectors
Fig. 5.5 illustrates how the cutter compensation vectors would appear for a part being
machined with an oversize cutter. The dashed line in the illustration represents the
centreline of the cutter path for the oversize tool.
The illustration shows that one span (P1 to P2) is required to turn the cutter
compensation on, and one span (P8 to P9) to turn it off.
The values for the P and Q vector components for all the points described in the
illustration would be either 0 or 1, but the sign (+ or -) would depend on the vector
direction.
Example
P2
P4
P5
P7
P8
P0
P1
P -1
P -1
P -1
Q1
Q -1
Q -1
Q -1
Q –1
The control uses vector components (P and Q) to calculate the cutter path offset
required to compensate for the oversize (or undersize) tool.
A2100Di Programming Manual
Publication 91204451- 001
20
Chapter 4
May 2002
Menu
Fig. 5.5 CDC Cutter Path with Oversize Cutter
The formulas used by the control are:
X Cutter Path Offset = P (Cutter Compensation Value)
2
Y Cutter Path Offset = Q (Cutter Compensation Value)
2
An example of a calculation made by the control for point P4 using an +0.0500 (oversize)
tool would be:
If coordinates for P4 are X = 10.0 and Y = 5.0
X- Axis Calculation
X Cutter Path Offset = 1.0 (0.0500) = +0.025
2
X Axis Dimension = 10.0 + 0.025 = +10.0250
Y- Axis Calculation
Y Cutter Path Offset = 1.0 (0.0500) = +0.025
2
Y Axis Dimension = 5.0 + 0.025 = +4.9750
The final coordinates for control compensation point P4 would be:
X = 10.0250 and Y = 4.9750
Fig.5 6 illustrates how the cutter compensation vectors would appear for a part being
machined with an undersized cutter. The dashed line in the figure represents the
centreline of the cutter path for the undersize tool.
A2100Di Programming Manual
Publication 91204451- 001
21
Chapter 4
May 2002
Menu
The illustration shows that the vectors point in the same direction for the undersize cutter
as they did for the oversize cutter in Figure 5.5, and that the values for P and Q are the
same in both cases.
The control would calculate for point P4 the dimensions X = 9.9750 and Y = 5.0250 if the
cutter diameter compensation for the tool was -0.0500.
Fig. 5.6
CDC Cutter Path with Undersized Cutter
P and Q Value Calculations
To compute the values of P and Q the following procedure and equations may be used.
All symbols used in the following equations relate to Figure 5.7. The beginning and
ending points of connected spans must be known (X1 Y1, X2 Y2. X3 Y3).
A2100Di Programming Manual
Publication 91204451- 001
22
Chapter 4
May 2002
Menu
Fig. 5.7 CDC Vector Diagram
5.3
Symbols and Definitions
Α = angle measured CCW from the position X-axis to L1 (span 1)
Β = angle measured CCW from the position X-axis to L2 (span 2)
Γ = angle measured CCW from the positive X-axis to the cutter compensation vector
θ = angle measured CCW from L2 to L1
L1 = span 1 (First span is from X1, Y1, to X2Y2
L2 = span 2 (Second span is from X2Y2 to X3 Y3
Procedure
Determine the values of α and β
Α = ARCTAN Y1 - Y2 = ARCTAN ΛY
X1 - X2
ΛX
Β = ARCTAN Y3 - Y2 = ARCTAN ΛY
X3 - X2
ΛX
Note that, if either end point X1Y1 or X3Y3 does not lie in the first quadrant the angle of α
or β must be adjusted by 180º or 360º
The following statements are used to correct each value (α,. Β) calculated in the
previous formulas:
If -ΛY add 180º to result
-ΛX
If +ΛY subtract result from 180º
-ΛX
If -ΛY subtract result from 360º
+ΛX
A2100Di Programming Manual
Publication 91204451- 001
23
Chapter 4
May 2002
Menu
Determine the value of θ.
Θ=α-β
Determine the value of θ .
θ = θ if θ > 0º
θ = θ +360 if θ < 0º
Determine the value of γ
Γ = β + ( θ /2)
Determine the values of P and Q.
P = COS(γ)
[SIN( θ /2 ]
Q = SIN(γ)
[SIN( θ /2]
Example of P and Q value calculations
Fig. 5.8 Vector Diagram
A2100Di Programming Manual
Publication 91204451- 001
24
Chapter 4
May 2002
Menu
To compute the P and Q values for the example
1. Find the angle α (measured CCW from positive X - Axis to span 1):
Α = ARCTAN Y1 - Y2
X1 - X2
Α = ARCTAN 7.0 - 9.0 = - 2 = 0.333
1.0 - 7.0 - 6
Α = ARCTAN + .333, α = 18º 26’
Α = 1980º 26’ , since in third quadrant (- and - )
2. Find the and (measured CCW from positive X - Axis to span 2):
Β = ARCTAN Y3 - Y2
X3 - X2
Β = ARCTAN 3.0 - 9.0 = 3.00
9.0 - 7.0
Β = ARCTAN + 3.000, β = 71º 34’
Β = 288º 26’, since in third quadrant (+ ∆X and - ∆Y)
3. Find the angle (measured CCW from span 2 to span 1):
Θ=α-β
Θ = 198º 26’ - 288º 26’
Θ = -90º
If θ < 0, then θ = θ +360º
θ = -90 +360º
θ = 270º
4. Find the angle (measured CCW from positive X-Axis to the cutter compensation
vector).
Γ = β + ( θ /2)
Γ = 288º 26’ + 270º
2
Γ = 288º 26’ + 135º
Γ = 63º 26’
5. Compute the values of P and Q.
P = COS(γ)
[SIN( θ /2 ]
P = COS(63º 26')
[SIN 135º)]
P = .44724
.707
P = +0.632 or P + 6320
Q = SIN(γ)
[SIN( θ /2 ]
A2100Di Programming Manual
Publication 91204451- 001
25
Chapter 4
May 2002
Menu
Q = SIN(63º 26')
[SIN 135º)]
Q = +1.265 or Q + 12650
Example Circular Arc with CDC
N020
N021
N022
N023
G1
G2P + 10000
G1
X50000
X60000
X70000
Q + 10000
Y70000
Y60000
Y50000
I60000
J60000
(P10)
(P11)
(P13)
(P14)
Fig. 5.9 Circular Arc with CDC
When cutter diameter compensation is used with circular interpolation, it must always be
turned on before the arc segment is entered, and must not be turned off until completion
of the arc segment.
Programmable Tool Offsets (O Word)
Programmable tool offsets are activated by programming an O word in the NC program.
A2100 supports up to 99 tool offsets.
Note
The programmable tool diameter offset O word cannot be changed while CDC is active.
It is valid to program an O word with a new diameter offset in the first G41 or G42 block;
that is, the block in which CDC is turned on.
Programmable tool offset data comprised two fields: tool length and CDC value. These
values are added to the current tool offsets (length and diameter offset) which are active
at the time the tool offset code is programmed. The supported range for CDC and tool
length values is 99999.9999 mm or 3937 in.
A2100 has both cutter diameter compensation and tool length compensation features.
Normally, the cutter diameter and length compensation values are entered into the tool
table for each tool, and specify the deviation of this particular tool from the nominal
values. The NC program is written assuming that the nominal (specified) tool is present.
A2100Di Programming Manual
Publication 91204451- 001
26
Chapter 4
May 2002
Menu
Another use for tool diameter and length compensation is to allow a single tool to be
used for both roughing and finishing operations, or to leave a specified amount of stock
on the part after machining for subsequent operations. This can be accomplished using
the programmable tool offsets feature. A2100 maintains a table of diameter and length
offset pairs.
A specific programmable tool offset pair is activated by programming its identifier in the
O word. This causes the selected table values to be added to the per-tool diameter and
length compensation values. The programmable tool offset is turned off by programming
O0.
The NC program can read and write values in the programmable tool offset table for the
active pallet. This allows programmable tool offsets to be initialised or set to values
determined by the NC program. The syntax used to read or write to tables is described in
detail in System Variables.
Descriptions and ranges for the table are shown in Chapter 14.
6
Multiple Setups
Frequently machine tools are used to machine multiple parts in one batch set-up. This
may be done by mounting multiple workpieces on the table or pallet, or by mounting a
fixture that holds several workpieces. To allow maximum flexibility in how the machine is
set-up, A2100 provides a multiple set-up feature that provides up to 64 separate set-ups.
Each set-up has its own program coordinate system and a complete set of
programmable offsets and fixture offsets. Each set-up also has an NC program
associated with the set-up.
The simplest use of multiple set-ups is to allow more than one workpiece set-up to be
located on the machine at one time. Each set-up is established using the procedures
described earlier in this Chapter to set the program coordinates. To establish a set-up,
the operator selects the set-up number from the operator station screen or from the
machine panel or pendant. With set-up selected, the program coordinate system is
established.
With multiple set-ups turned off, the operator selects the required set-up, activates the
NC program, and runs the program. At the end of the program a new part can be loaded
inyo the same set-up, or a different set-up can be selected.
When multiple set-ups is selected, the control uses the part state and part status field to
determine what to do at end of program. Essentially the multiple set-up feature operates
by processing all of the set-ups with part states PRESENT, NEW, LAST, and PENDING.
The set-ups are processed starting with number one (or the operator selected set-up)
and continuing until a set-up with part state LAST is completed. As each set-ups NC
program completes, the control automatically activates the next set-up. This means that
the control activates program coordinates for the set-up, activates the NC program
associated with the set-up, and starts the cycle.
When cycle start is activated the multiple set-up table Part Status, and pallet offset table
Pallet Status description fields will update as follows:
G
At cycle start the pallet status and part status description fields will change from
PENDING to STARTED.
G
At end of program, the part status description field will change to ABORTED or
COMPLETED. The pallet status description field will change to either SETUP
ABORTED, ABORTED, or COMPLETE.
A2100Di Programming Manual
Publication 91204451- 001
27
Chapter 4
May 2002
Menu
A brief explanation of the part status and pallet status description fields are as follows:
COMPLETE
ABORTED
SETUP ABORTED
PENDING
STARTED
Finished, nothing was aborted.
Aborted not finished.
Pallet was finished but one or more set-ups were aborted.
Ready but not started (this is the default state)
Being executed (the program is being run).
As there is an NC program associated with each set-up, the mix of parts is not restricted,
all of the set-ups can use the same program, or a mix of parts can be accommodated.
Since each set-up has its own set of programmable offsets and fixture offsets, there are
few special programming requirements for operating with multiple set-ups.
By using the set-up offsets instead of NC program controlled offsets such as fixture
offsets to accommodate the distance between parts, the set-up information is removed
from the NC program. This allows the NC program to be written for the part, not the setup, and allows the operator the freedom to vary the number and mix of parts on the
machine.
The multiple set-up feature provides several part set-ups, each with a part coordinate
system and an independent set of fixture offsets and programmable coordinate offsets. If
the machine is equipped with a pallet changer, the part coordinates are referred to the
pallet coordinates. Otherwise, the part coordinates are defined based on the machines
zero position.
The purpose of the part offsets is to allow multiple set-ups to be used on the machine
table or pallet. Each entry in the multiple set-up table represents a separate set-up. The
multiple set-up table contains the offset of the part coordinate system zero point from the
machines zero point (or the pallet zero point).
The partsStatus field specifies the status of this set-up. The NC program ID field
contains the NC program ID for the program associated with this set-up. A2100 provides
64 part set-ups. If the pallet offset option is present, 64 part set-ups are provided for
each pallet.
Descriptions and ranges in the parts Set-up table are shown in Chapter 14.
7
Pallet Offsets
The pallet offset option is generally used on machines equipped with an automatic
workchanger. The purpose of pallet offsets is to correct for the inaccuracy of registration
when a pallet is loaded onto a machine, and to allow a coordinate system to be defined
that has its origin somewhere other than where machine coordinates are defined. Pallet
offsets allow the operator to establish a relationship between a reference point on the
pallet and the centre of rotation of the rotary axis of the machine.
Whether-or-not pallet offsets rotate as a function of rotary axis motion is determined by
the offsets rotate field. Offset rotation is selected by specifying YES or NO. The axis
about which the offsets rotate is determined by the machine configuration.
If offset rotation is specified, the configured axis that represents the pallet rotation on the
particular machine specifies the angle at which the linear axis offsets in the plane of
rotation were measured. For example, if the pallet is an A axis (it rotates about the X
axis), the Y and Z offsets rotate when the A axis rotates.
If the pallet position is measured at an A axis position of 0, the amount by which the
pallet is off centre in Y and Z is entered as the Y and Z axis offset. As the A axis rotates,
A2100Di Programming Manual
Publication 91204451- 001
28
Chapter 4
May 2002
Menu
the offset amount that was in the Z direction moves with the rotation. At 90, the offset
that was in the +Z direction is now in the -Y direction. All axis offsets other than the linear
axes in the plane or rotation are unaffected by the rotary axis position.
Descriptions and ranges in the Pallet Setup Table are shown in Book 3 – Operation &
Probing, Chapter 11.
7.1
Pallet Coordinates Programming (G50)
With the pallet offset option, A2100 supports several coordinate systems, one for each
pallet on a machine with an automatic work changer. With the multiple set-ups feature,
each pallet may have several different part coordinate systems, one for each part on a
multipart set-up. In this case, all command positions in the NC program are interpreted
with respect to the local zero of the active pallet and part coordinate system.
Occasionally, an NC program may have to command a move to a position relative to the
active pallets coordinate system, rather than to the part coordinate system. This could
arise, for example, when using a touch trigger probe to locate a reference surface on the
pallet or to locate the exact position of a fixture.
The non-modal preparatory code G50 causes the control to interpret all dimensions in
the block containing the G50 as dimensions relative to the active pallet zero rather than
to the active part coordinate zero.
8
NC Program Controlled Offsets
The NC program controlled offsets are used primarily to allow position corrections for
process, set-up, or part related errors such as tool or part deflection or workpiece
variation.
The NC programmer must anticipate sources of dimensional errors and program the
appropriate offset code to allow the errors to be corrected. In general, these offsets are
activated between operations, and apply an offset to one or more axes. The offset may
be determined by the operator, based on measurements of raw stock, finished parts, or
the set-up. Alternatively, the NC program can sometimes determine the value by using
the touch probe to measure the workpiece.
8.1
Fixture Offsets (H Word)
Fixture offsets are X, Y, Z, U, V, and W-axis offsets which adjust for off-centre mounting
of a fixtured workpiece. They can be used with a single part mounted on a machine table
or for one of several parts attached to a pallet.
Fixture offsets may be selected to rotate based on a rotary axis position, or not to rotate.
The selection is based on the rotates field which may have a value of YES or NO.
The rotary position field contains the position of the rotary axis at which the offsets were
measured.
32 fixture offsets are provided per part coordinate system.
A2100Di Programming Manual
Publication 91204451- 001
29
Chapter 4
May 2002
Menu
A fixture offset is activated by programming an H word, and remains in effect until it is
replaced by another fixture offset (programmed H word) or is cancelled by:
G
Program H0.
G
Data reset.
G
End of program M2 or M30.
G
A colon block if the control is configured to reset the H word on colon blocks.
The distance to be offset is contained in the fixture offset table which can be displayed
by the operator on the screen to check or change offset data.
Descriptions and ranges for the fixture offsets table are shown in Book 3 – Operation &
Probing, Chapter 11.
The fixture offset is selected by programming an H word with a value H1 through H32.
The H word value designates the fixture offset to be used. The axis offset values listed in
the table for that index are used. This allows the value of the offset to be changed
without changing the NC program.
The following conditions must be met when programming the H word. Failure to meet
these conditions will cause the cycle to halt and an alarm message to be displayed.
G
The H word may only be programmed in a block capable of containing an axis
movement command.
G
The linear interpolation mode (G0 or G1) must be active. All other interpolation modes
may be used in blocks following the one containing the H word.
G
The H word must have a value of 1 to 32.
When a non-zero H word appears in a block, the offset values from the fixture offset
table are activated. These offsets are added to the endpoint of the programmed move,
so the offsets result in a motion in a straight line from the current position to the offset
programmed position.
The cancellation of a fixture offset via data reset, M02, M30, or colon block (if
configured) does not cause axis motion, but updates the actual program coordinate
position in the current position display.
The NC program can read and write fixture offset values using 'assignment statements'.
The NC program may set the offset values based on probe measurements, or may
check the fixture offset values to limit the amount of offset for some operations.
8.2
Fixture Offset Examples
8.2.1
Fixture Offset Set-Up X And Y
Refer to the four part set-up in Fig. 8.1. Fixture #1 is set up using normal techniques.
A2100Di Programming Manual
Publication 91204451- 001
30
Chapter 4
May 2002
Menu
Figure 8.1 Fixture Offset Set-Up X And Y
The distance between locating holes of the four fixtures along X axis is critical, as the
program is written to machine all four parts. Without the fixture offset feature each fixture
would have to be physically positioned exactly 20” apart in the X axis and in line with the
Y axis.
If a fixture offset is provided, fixtures can be placed in an approximate position on the
table, then the difference can be compensated for by using fixture offsets.
In Fig. 8.1 fixture #1 is trammed and the program coordinates are set using G92 to 0,0 at
the centre of the hole. Next, fixture #2 is set-up by first tramming the locating hole, then
comparing the X and Y coordinates displayed on the screen with the coordinates defined
by the programmer.
The difference between programmer defined dimensions and those displayed on the
screen is then applied to the fixture offset number used by the programmer for that
fixture.
For example, the programmer defined dimensions for the locating hole of fixture #2 is
X20”., And Y0”. If after tramming this locating hole, the screen displays dimensions of
X19.7876 and Y-00.0932, the values input for the assigned fixture offset number would
be:
X Axis =
20.0000
Y Axis =
(-) X19.7876
(-) Y00.0932
- 00.2124
8.2.2
Y00.0000
- 00.0932
Fixture Offset Set-Up X And Y
Because fixture offsets are increments of motion, it is necessary to determine the
direction of the offset. Fig. 8.2 illustrates the way in which a + or - sign is determined for
the fixture value. In this example, the physical position of a locating hole falls into
Quadrant #3, therefore the sign will be negative for both axes.
A2100Di Programming Manual
Publication 91204451- 001
31
Chapter 4
May 2002
Menu
Figure 8.2 Fixture Offset Set-Up X And Y
8.2.3
Fixture Offset Z Axis Set-up
The Z axis is set-up similar to the X and Y axes. Refer to Fig. 8.3, fixture #1 is set-up
using normal techniques.
Fixture #2 is set-up by touching the same tool to a feeler gauge at the tool set-up point of
fixture #2, then comparing the difference between the Z coordinate display of fixture #1
and #2.
In Fig. 8.3, the top surfaces of fixture #1 and fixture #2 were programmer defined to be
Z0. When setting up the Z axis for fixture #1 a .1000 feeler gauge is used, so the Z
coordinate display will be Z + 0.1000.
Checking fixture #2, the Z coordinate display reads Z0.1500, indicating that fixture #2 is
.05” higher than fixture #1. A value of +.0500” must be applied to the fixture offset
number programmed for fixture #2.
Figure 8.3 Fixture Offset Z Axis Set-up
8.2.4
Fixture Offset With Axis Inversion
Do not use fixture offsets when machining left and right hand parts with the axis
inversion feature in a single set-up. Fixture offsets can be used when a set-up is
A2100Di Programming Manual
Publication 91204451- 001
32
Chapter 4
May 2002
Menu
completed, the fixtures removed and inverted fixturing installed for mirror image parts
using the same program. In this case, however, the fixture offset data input must be
checked and modified before operation can be started.
Note that the fixture offset values are not inverted when the axis inversion feature is
used.
8.2.5
Fixture Offset With Rotary Axis - (If Supplied)
If a contouring rotary axis is present in the system, the position of the rotary axis is
recorded by the operator where the fixture offset is to be established. On each block with
the fixture offset active, the offset components of the two axes that rotate with the rotary
axis are recomputed for the new position of the rotary axis. For example, if the rotary
axis is an A axis (which rotates around X) the Y, V and Z, and W axis offsets rotate.
The recomputed offsets are correct when the rotary axis reaches its programmed end
point.
Fixture offsets are not truly interpolated and must not be active during an inverse time
(G93) linear-rotary motion block.
For indexing applications (using a positioning/contouring rotary axis), only one fixture
offset assignment is necessary to ensure the presence of a suitable offset at any rotary
position required by the programmer.
Example 1
Program Field Name “ROTATES” set “YES” (See Fixture Offset Table – Book 3,
Chapter 11).
The example shown in Fig. 8.4 illustrates a workpiece mounted on a positioning/
contouring rotary table.
Figure 8.4 Fixture Offset With Rotary Axis - (If Supplied)
A2100Di Programming Manual
Publication 91204451- 001
33
Chapter 4
May 2002
Menu
At Pos 1 (0), the operator will input offset values Y =+1mm and Z =-0.5mm for the
programmed H code.
As the table rotates from position.1 to position.2, then to position.3 and then to
position.4, the control will automatically offset the axes at these end points as follows:
G
Position.2 (90) Y+0.500 Z+1.000
G
Position.3 (180) Y- 1.000 Z+0.500
G
Position.4 (270) Y- 0.500 Z-1.000
The change in the computed Y, Z offsets are executed simultaneously with the rotary
axis motion to its own programmed end point. The offset increments of Y and Z are
summed with any programmed linear axis motion and executed with the rotary span.
In the example when the rotary axis moves from position.2 to position.3, the YZ motion
due to fixture offset is Y -1.5mm Z -0.5mm. If the rotary axis is programmed to move 360
degrees the computed YZ fixture offset motion is zero because the rotary table will return
to its current position.
Fixture offset values greater than 1mm (0.05”) should be used with extreme caution, as
large offset values will cause large axis motions which adds to the possibility of a
collision between the cutting tool and workpiece. The possibility of a tool/workpiece
collision will be reduced by retracting the tool well clear of the workpiece surface prior to
executing a rotary axis block. Retraction of the tool may be accomplished by
programming a separate X, Y, or Z retract block.
Example 2
Program field name “ROTATES” set “NO” (See Fixture Offset Table – Book 3, Chapter
11).
If a contouring axis is present in the system, the position of the rotary axis is recorded by
the operator where the fixture offset is to be established. If the ROTATES field is set to
”NO”, rotary axis movements will not cause recomputations for new positions of the
rotary axis.
8.3
Programmable Coordinate Offsets (D Word)
Programmable coordinate offsets are generally used within an NC program to adjust for
variations in the set-up or part material. These variations are either measured by the
operator, or obtained automatically by probing the part surface. Programmable offsets
are for the linear axes only and do not change with the rotary axis position.
The programmable offsets are listed in the table with index numbers ranging from 1 to
32, and are selected by programming a D word having a value of 1 to 32.
Descriptions and ranges for the programmable offsets table are shown in Book 3 –
Chapter 11.
Programming a zero value D word designates that no programmable offset is to be
active.
The following conditions must be met when programming the D word. Failure to meet
these conditions causes the cycle to stop and an alarm message to be displayed.
G
The D word may only be programmed in a block capable of containing an axis
movement command.
A2100Di Programming Manual
Publication 91204451- 001
34
Chapter 4
May 2002
Menu
8.3.1
G
The linear interpolation mode (G0 or G1) must be active. All other interpolation modes
may be used in blocks following the one containing the D word.
G
The D word must have a value of 1 to 32.
The D Word
The programmable offset value may range from 0 to * 99999.9999 mm (0 to *
9999.99999 inch).
The value of the programmable offset is added to the movement command of the block.
The slides will make a linear movement from their current position to the point defined by
the sum of the movement command and the offset value. This movement is made at
rapid traverse rate when the G0 mode is active. The movement is made at the
programmed feed rate when the G1 mode is active. This allows the offset movement to
be made at feed rate, while the tool is making a cut.
The programmable offset remains active until it is replaced by another programmable
offset (programmed D word) or is cancelled by:
G
Program D0
G
Data reset
G
End of program - M2 or M30
The cancellation of a programmable coordinate offset via data reset, M2, M30 or colon
block (if configured) does not cause axis motion, but updates the actual program
coordinate position in the current position display.
The NC program can read and write programmable coordinate offset values using
assignment statements (ee Chapter 9). The NC program may set the offset based on
data obtained using a touch probe or may check programmable coordinate offset values
to limit the amount of offset for some operations.
Machine Offsets
The machine offsets feature provides the operator with a means of entering and
modifying the linear axis offsets contained in the machine offsets table. These offsets are
activated by programming a D word in a G98 or G98.1 block. The machine offsets data
elements are.
Machine Offset Data
X, Y, Z, U, V, and W axis offset
Program Field Name
X, Y, Z, U, V, W
Description
Range of ± 99999.9999 mm
Note that machine offsets are active only for the block in which they are programmed,
they are not modal.
The control machine offsets are not part of the pallet/part coordinate system offset
hierarchy. There is one machine offsets table which contains 16 records. Each record
contains offset values for the X, Y, Z, U, V, and W axes in the range +\- 99999.9999 mm.
A2100Di Programming Manual
Publication 91204451- 001
35
Chapter 4
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204451- 001
36
Chapter 4
May 2002
Menu
Chapter 5
MECHANISM CONTROL
Contents
1
1.1
1.2
1.3
1.4
1.5
1.6
1.6.1
1.6.2
1.6.2.1
1.7
1.8
Miscellaneous Function Codes (M codes) .................................. 3
Introduction................................................................................... 3
M0 Program Stop .......................................................................... 4
M1 Optional Stop .......................................................................... 4
M2 End of Program ....................................................................... 5
M30 End of Program ..................................................................... 5
M6 Tool Change ............................................................................ 6
Automatically Loaded Tools ........................................................ 7
Manually Loaded Tools ................................................................ 8
Programming Rules...................................................................... 9
Tool Change Clearance Check (With Tool Changer) ................ 11
Tool Change Clearance Check (Without Tool Changer)
12
1.9
1.10
1.11
1.12
1.13
1.14
1.15
1.16
1.17
1.18
1.19
1.20
1.21
1.22
1.23
1.23.1
1.23.2
1.24
1.24.1
1.24.2
1.25
1.26
1.27
2
2.1
2.2
M26 Spindle Axis Full Retract .................................................... 15
M3, M4, M5 Spindle Control........................................................ 16
M13, M14 Combined Spindle and Coolant Control ................... 16
M19 Oriented Spindle Stop......................................................... 16
M41 Select Spindle Constant Power Mode ............................... 17
M42 Select Spindle Constant Torque Mode .............................. 18
M8, M9, M27 Coolant Control ..................................................... 18
M8.1 - M8.8 Automatic Coolant Jets Control (Option) .............. 18
M10, M10.1 - M10.4 Axis Clamp.................................................. 19
M11, M11.1- M11.4 Axis Unclamp .............................................. 20
M48 Feedrate and Spindle Speed Override Enable .................. 20
M49 Feedrate and Spindle Speed Override Disable ................. 20
M58 Disarm Spindle Probe ......................................................... 20
M59 Arm Spindle Probe.............................................................. 21
M60/61 Swarf Wash ON/OFF ...................................................... 21
M60 Swarf Wash On.................................................................... 21
M61 Swarf Wash OFF.................................................................. 21
M91/M92 Swarf Conveyor On/Off ............................................... 21
M91 Swarf Conveyor On............................................................. 22
M92 Swarf Conveyor Off............................................................. 22
M70-79 User M Codes (Option) .................................................. 22
M83 Part Complete...................................................................... 23
M34/M35 Data Acquisition On/Off M69 Alternate Work Station 23
Tool Management ....................................................................... 23
Tool Selection ............................................................................. 24
Tool Data Library ........................................................................ 24
A2100Di Programming Manual
Publication 91204426- 001
1
Chapter 5
May 2002
Menu
2.3
2.4
2.5
2.6
2.7
2.7.1
2.8
2.9
2.10
2.11
2.12
2.13
2.14
2.15
2.16
2.17
2.18
2.19
2.19.1
2.19.2
2.19.3
2.20
2.21
2.21.1
2.22
2.23
2.24
2.25
2.26
Tool Data Information ................................................................. 24
Tool Search.................................................................................. 24
Tool Identification ....................................................................... 25
Tool File ....................................................................................... 25
Tool Magazine and Active Tool Set............................................ 26
Tool Programming ...................................................................... 26
Tool Type ..................................................................................... 26
Migrating Tools ........................................................................... 26
Tool Load Method ....................................................................... 27
Tool Compensation..................................................................... 27
Tool Length.................................................................................. 27
Flute Length................................................................................. 27
Nominal Tool Diameter ............................................................... 27
Diameter Offset ........................................................................... 28
Number of Teeth.......................................................................... 28
Tool Tip Angle ............................................................................. 28
Threads Lead............................................................................... 29
Spindle Speed Override .............................................................. 29
Per Tool Feedrate Override ........................................................ 29
Per Tool Maximum RPM ............................................................. 29
Per Tool Maximum Feedrate....................................................... 29
Tool Status .................................................................................. 29
Tool Cycle Time (Option) ............................................................ 29
Tool Usage Count (Option)......................................................... 30
Alternate Tools ............................................................................ 30
Tool Reference Number .............................................................. 30
Tool Class.................................................................................... 31
X Probe Offset ............................................................................. 31
Y Probe Offset ............................................................................. 31
A2100Di Programming Manual
Publication 91204426- 001
2
Chapter 5
May 2002
Menu
1
Miscellaneous Function Codes (M codes)
1.1
Introduction
Miscellaneous Function Codes (M codes) are used to command various control and
machine functions, mostly related to overall NC program execution and control of
machine mechanisms. The features under this topic are supplied by A2100 as described
in the following paragraphs, but may be modified or extended for specific machine tool
applications.
Miscellaneous functions are coded in the M word which consists of a whole number of
up to three digits and may in some cases contain a decimal point and one or two digits.
Although leading zeros are valid, for maximum performance M codes should be
programmed as shown in Book 3 – Chapter 11. That is, M2, M02 and M002.0 are all
valid, but M2 is preferred.
The M word value becomes active either at the start of the block, that is, before any
commanded motion in the block is executed, or at the end of the block, after any
programmed motion is completed. As with the Preparatory Codes, the Miscellaneous
Function Codes perform several independent tasks, and multiple M words may appear in
a single block. The control allows multiple M words in a block with the restriction that
conflicting M words are disallowed.
In Book 3 – Chapter 11, each M code is shown as a member of a group, and only one M
code from each group can appear in a block. Two or more M codes from the same group
in the same block cause an alarm. For example, it is valid to code M3, M8, and M5 in
one block M3 and M8 start the spindle and coolant before axis motion begins, and M5
stops the spindle and coolant after axis motion completes. M codes for which no group is
shown are independent, and can appear together in a block.
Many Miscellaneous Function Codes are machine specific in their details and are not
discussed here. This Chapter describes the Miscellaneous Function Codes which affect
other features of the control system. Note that a particular machine application may
perform additional functions as a result of executing one of these basic M codes.
A group of M codes is reserved for end user definition. These user M Codes are
configurable by the end user or OEM, to select characteristics such as:
G
Whether the M code is effective at Start of Block or End of Block.
G
The duration of the output signal (pulse or continuous).
G
Whether NC cycle is held while the M code is be acted upon.
The actual number of User M Codes is determined by how the machine tool builder or
system integrator has configured the actual I/O contact complement.
Some commands are ”modal”, meaning they initiate a function or operating mode that
remains active until the opposite command is given.
An example of a modal command is: M8/M9 (coolant on/off).
Non-modal commands cause their functions to occur once only; the command must be
given each time it is required. For example, M6 (tool change) is a non-modal command.
A summary of all M codes is shown in Book 3 - Chapter 11.
A2100Di Programming Manual
Publication 91204426- 001
3
Chapter 5
May 2002
Menu
1.2
M0 Program Stop
M0 Program Stop code stops NC program execution at the end of the block in which it
appears. After any axis motion programmed in the block completes, the spindle is
stopped (usually with an oriented stop, that is, with the spindle stopped at a known
position) and the coolant is turned off. The control is out of cycle, (stopped at End of
Block) and must be restarted by operator action.
The M0 code stops the machining cycle within the program for checking or set-up
purposes.
G
The spindle stops.
G
The coolant is turned off.
G
NC cycle stops.
G
The cycle message PROGRAM STOP is posted.
The operator resumes cycle by pressing Cycle Start. The blocks of information
immediately following the M0 block must contain all necessary information to resume
operation. The control retains the spindle speed and direction, and the coolant selection
that were active before the M0. When the operator resumes cycle, these saved values
are used to restart the spindle and coolant. The block following the M0 block should
begin with a Reference Rewind Stop code (:).
At least one zero must be programmed (M0 or M00). No other M code from the program
control group is allowed in the same block.
1.3
M1 Optional Stop
An Optional Stop (also called a Planned Stop), has the same effect as a Program Stop
(M0) except that it is conditional on the state of an operator actuated Optional Stop
control. An Optional Stop code may be used to allow an operator to either stop the
program, or continue without stopping at points where inspection steps are required, or
other interaction may be required. If the Optional Stop is enabled, the control is out of
cycle (stopped at End of Block) and must be restarted by operator action.
G
The spindle stops.
G
The coolant is turned off.
G
NC cycle stops.
G
The code message OPTIONAL STOP is posted.
The operator resumes cycle by pressing Cycle Start. The blocks of information
immediately following the M1 block must contain all necessary information to resume
operation. The control retains the spindle speed and direction, and the coolant selection
that were active before the M1. When the operator resumes cycle these saved values
are used to restart the spindle and coolant. The block following the M1 block should
begin with a Reference Rewind Stop code (:).
Do not use the M1 code to stop cycle for part changing or mandatory set-up
adjustments. Use an M0 code when the stop is required.
A2100Di Programming Manual
Publication 91204426- 001
4
Chapter 5
May 2002
Menu
CAUTION
Do not use an M1 when a mandatory stop is required. Failure to heed this Caution
may result in damage to equipment.
1.4
M2 End of Program
The M2 code signals the end of the part program. An End of Program code stops the NC
program execution after all axis motion commanded in the block has completed. The
spindle is stopped (usually with an oriented stop) and coolant is turned off. The machine
axes may be moved to a retracted position depending on the machine application. If an
automatic work changer is present, the work changer changes the workpiece.
If an automatic tool changer is present, and a T word is present in the M2 block, that tool
is loaded into the spindle. If no T word is present, the tool in the spindle remains in the
spindle. To unload the spindle and perform the End of Program function, use M30.
The results of this command are:
G
After the axis motion programmed in the block completes, all program controlled
offsets (CDC, Fixture Offsets, Programmable Co-ordinate Offsets, and
Programmable Tool Offsets) are cancelled by updating the current axis positions
with no slide motion. then:
The spindle stops
The coolant stops
The message END OF PROGRAM is posted
G
The active program position is updated as follows:
With Multiple Set-ups turned on, the program for the next set-up is activated.
With Multiple Set-ups turned off, the active program is repositioned to the first
block.
G
If a T word is present in the M2 block, a tool change is performed. If no T word is
present, the tool remains in the spindle.
No other M codes from the program control group are allowed in the block with M2. M2
may appear anywhere in the program. There is no limit on the number of times M2
appears in one program, thus a program can end at several branches of a multiple-path
program.
Note
To empty the spindle at End of Program, use M30 instead of M2.
1.5
M30 End of Program
An M30 End of Program code performs the same function as the M2 End of Program
code, except that it unloads the tool in the spindle, and returns any tools in any part of
the tool change mechanism to the tool magazine.
A2100Di Programming Manual
Publication 91204426- 001
5
Chapter 5
May 2002
Menu
1.6
M6 Tool Change
The M6 code request a tool change. In general, the control moves the machine to a
specific tool change position, stops the spindle and coolant, performs an automatic tool
change, and continues program execution. The control permits tools to be identified as
'manual loaded' tools or as 'cradle loaded' tools.
If either the current tool (in the spindle) or the next tool (specified by the T word) is
designated as manual load, operator action is required to unload or load the manual tool.
Loading a tool, either automatically or manually, also activates all of the tool related data.
If either the current tool or the next tool is designated as a cradle loaded tool, a special
tool change method is used. Cradle loading is generally useful for large tools.
The next tool to be loaded is specified by the T word. The T word can specify either the
tool record number in the tool table or a Tool Identifier. If a Tool Identifier is specified, the
control searches its table of tools and selects an appropriate tool from those present.
This search takes into account the tool status, and allows for multiple similar tools to
permit unattended operation for longer times than a single tool’s lifetime.
A more detailed description of how the control interprets the T word and locates the
proper tool, is given in Section 2 (Tool Management).
A T word in a block without a Tool Change code (M6) causes the machine to locate the
next tool and possibly to position the tool magazine for the next tool. For many tool
changer mechanisms this early programming of the next tool significantly shortens the
time for the next tool change. Normal practice for these machines is to program the next
tool T word as soon as the previous tool change is complete. Even if the mechanism
design does not require the early programming of the next tool, it is valid to do so.
Specific machine types may have additional cautions or requirements to be observed
when programming tool changes.
If the tool change block contains an Automatic Return to Reference Point (G28) the axis
command words in the G28 block specify an intermediate point along the rapid traverse
path to the tool change position. This can be used to control the tool path to ensure that
the part and fixturing are avoided. An Automatic Reference Point Return (G29) in the
block following the tool change causes the tool path to pass through the same
intermediate point specified by the preceding G28.
The M6 Tool Change code is used to command:
G
Loading the first tool into the spindle.
G
All intermediate tool changes.
G
Unloading of the spindle tool (i.e.: T00 M6). Unloading the last tool from the spindle
may be done using the M30 End of Program code.
Program execution continues on completion of an Automatic Tool Change Cycle
In response to an M6:
G
The control moves the machine to a specified tool change position and stops the
spindle and coolant.
G
An automatic tool change is performed and program execution continues.
A2100Di Programming Manual
Publication 91204426- 001
6
Chapter 5
May 2002
Menu
1.6.1
Automatically Loaded Tools
The following axis and mechanism motions occur when an M6 code is processed
requesting the mechanism to automatically exchange tools between the tool storage
matrix and the spindle.
G
The spindle will stop at the oriented spindle stop point, and the coolant will be turned
off while the Z slide retracts to a clearance level beyond the tool change position.
G
The XY axis (and A, if applicable) advance to their respective tool change positions,
if specified in configuration data.
Arrow Machines – 21 Tool Magazine
G
If there is no tool in the spindle, the tool storage magazine will rotate to the
requested tool location then advance beneath the spindle nose. The spindle
advances onto the exposed tool adapter, using the power draw-bar to retain the tool.
The tool storage matrix then retracts from the spindle to its home position.
G
If there is a tool in the spindle, the mechanism will collect the tool from the spindle
prior to searching for the required tool. The search is initiated when the spindle is
retracted to the clearance level beyond the Tool Change position.
G
If an automatically loaded tool is in the spindle and the next tool is a manually loaded
tool, the system returns the tool from the spindle to its reserved pocket in the tool
storage magazine. It then displays a screen instruction requesting the operator to
load the manual tool.
Arrow Machines - 30 Tool Magazine
G
The active tool pocket in the tool storage magazine swings down to its vertical tool
change position, see figures 1 and 2.
Fig 1
Fig 2
Fig 3
G
The tool changer double arm mechanism rotates 90O from the park position and
grasps both the tool in the active tool pocket and the tool in the spindle.
G
The tool in the spindle is released by the drawbar mechanism and the double arm
advances towards the machine table drawing the tools clear from their respective
locations, refer to figure 3.
G
The double arm swings 180O to exchange the tools, then retracts up and locates the
tool from the tool magazine in the spindle. The tool from the spindle is deposited in
the vacated pocket in the tool magazine.
G
The drawbar mechanism clamps the tool in the spindle and the tool changer double
arm rotates 90O to the park position. See figure 4.
A2100Di Programming Manual
Publication 91204426- 001
7
Chapter 5
May 2002
Menu
Fig 4
Note:
The automatic tool change sequence returns the tool from the spindle
into the pocket location of the pre-selected tool. The pre-selected tool
loaded into the spindle will subsequently return to the pocket of the
next pre-selected tool. This activity is termed migration, see Section 2.9
of this Chapter.
G
If the tool in the spindle is an automatically loaded tool, the system returns the tool
from the spindle to an empty pocket in the tool storage magazine, and then displays
a screen instruction calling for the operator to load the manual tool.
FTV Machines
1.6.2
G
If there is no tool in the spindle, the tool storage magazine will rotate to the requested
tool location. The spindle will advance over the tool in the magazine and then
descend onto the exposed tool adapter, using the power drawbar to retain the tool.
The spindle and tool retract clear, in the y axis, of the magazine to complete the tool
load.
G
If an automatically loaded tool is in the spindle, and the next tool is a manually
loaded tool, the system returns the tool from the spindle to its reserved pocket in the
tool storage magazine. A screen instruction is then displayed calling for the operator
to load the manual tool.
Manually Loaded Tools
If a tool is designated as Manual Load status in the Tool Data Table, an operator
message will be displayed at the appropriate time requesting that the operator loads the
tool into the spindle (or unloads the tool from the spindle).
When an M6 is processed for a tool designated as manual load status, the following axis
motion occurs:
G The spindle will stop at the orientated spindle stop point, and the coolant will be
turned off while the Z slide retracts to its manual tool change position.
G
Any X and/or Y axis, and A axis if applicable, rapid to their respective manual tool
change position, if specified in configuration data.
An operator screen instruction appears requesting a tool load or a tool unload. The tool
unclamp push button is depressed to unload a tool, and is held pressed to load a tool
into the spindle. The push button is released to enable the drawbar to restrain the tool in
A2100Di Programming Manual
Publication 91204426- 001
8
Chapter 5
May 2002
Menu
the spindle. Automatic N.C. cycle is engaged by pressing the CYCLE START push
button.
If the tool in the spindle is a manually loaded tool, and the next tool is an automatically
loaded tool, the operator is first instructed to unload the manual tool, before the system
proceeds to access the specified tool in the storage matrix for automatic loading.
1.6.2.1
Programming Rules
The following rules apply when programming tool changes:
G The block containing the M6 code must be an alignment colon (:) block. This block
must contain a T-word.
G
The T-word used must be the Tool Record Number or the Tool Identification Number
of the next tool to be loaded into the spindle.
G
The block should also contain the G00 rapid positioning code, and optionally, an X
and/or Y axis co-ordinate, and also an A co-ordinate if applicable.
G
Do not programme a Z word in a tool change block; always retract a tool to a
clearance level in the Z axis before programming a tool change block.
CAUTION
Processing a Z word in an M6 block will retract an active tool to a clearance
level prior to invoking the end of span tool change M6 sequence. Processing
the M6 block when no tool is specified causes the spindle nose (rather than an
anticipated tool point) to advance to the programmed Z co-ordinate resulting in
the possibility of a collision with the workpiece or fixture.
Failure to heed this Caution may result in damage to equipment.
1.6.2.2
Tool Load Examples
:10 G00 T12345678 M6
Automatic Tool Load
In sequence :10, the spindle and coolant are turned off and the tool magazine
searches for the pocket assigned to Tool Number 12345678. The axes rapid to
their respective AUTO Tool Change Position co-ordinates.
Arrow Machine – 21 Tool
The tool magazine advances to beneath the spindle nose. The spindle advances
onto the tool holder and grips the tool. The magazine retracts to its home position
to complete the cycle.
Arrow Machine – 30 Tool
The tool is loaded into the spindle by the double arm tool changer mechanism.
FTV Machines
The spindle advances into the tool magazine, descends into the tool holder and
grips the tool. The spindle and tool retract in the Y axis clear of the magazine to
complete the cycle.
A2100Di Programming Manual
Publication 91204426- 001
9
Chapter 5
May 2002
Menu
Manual Tool Load
In sequence :10, the spindle and coolant are turned off and the axes rapid to their
respective MANUAL tool change position co-ordinates. Tool Number 12345678
(with manual load status) is loaded into the spindle by hand. NC cycle is engaged
when the operator presses the CYCLE START push button.
G
A tool unload cycle is performed by programming a “T00 M6” command. Program
execution continues on completion of an automatic tool unload cycle. On completion
of a manual tool unload sequence, program execution is resumed on pressing the
CYCLE START push button.
When a Tool Change colon (:) block is executed, all modal preparatory functions are
automatically reset to their initialised (Data Reset) states unless specifically programmed
otherwise. The following are automatically selected:
G01 Linear Interpolation
G17 XY Plane Selection
G40 Cutter Compensation Off
G45 ACC/DEC On
G61 Contouring
G70 Inch Mode (USA Installations Only)
G71 Metric Mode (Installations Other Than USA)
G90 Absolute Input Mode
G94 Feed Per Minute
G97 Spindle RPM Mode
G150 Scaling Off
Span Control - Normal
No pattern is active
CAUTION
Functions other than those listed above must be re-programmed in the block(s)
following a Tool Change Alignment block. Failure to re-programme the necessary
functions may result in damage to both cutting tool and machine.
Arrow 30 Tool Machines Only
To optimise tool change time, tools should be stored in the matrix in the same sequence
in which they are to be selected.
In addition, the tool number for the next tool should be programmed prior to its being
loaded into the machine spindle. This allows the tool to be pre-selected and placed at
the active pocket position in the tool matrix while machining operations are in progress.
thus eliminating tool search waiting time at tool change.
The last block in the part program must contain a M2 or M30 miscellaneous code. The
End of Program M2 code, will leave the last tool in the spindle. The last tool may be
removed from the spindle by programming an M30 code. An automatically loaded tool
will be automatically unloaded and returned to the first available empty pocket in the tool
A2100Di Programming Manual
Publication 91204426- 001
10
Chapter 5
May 2002
Menu
storage magazine. A manually loaded tool will be unloaded by the operator in
accordance with the unload instructions posted to the screen display.
Arrow 21 Tool Machines
FTV Machines
To optimise tool change time, tools should be stored in the matrix in the same sequence
in which they are to be selected.
In addition, the tool number for the next tool should be programmed prior to its being
loaded into the machine spindle. This allows the tool to be pre-selected and placed at
the active pocket position in the tool matrix while machining operations are in progress.
thus eliminating tool search waiting time at tool change.
The last block in the part program must contain a M2 or M30 miscellaneous code. The
End of Program M2 code, will leave the last tool in the spindle. The last tool may be
removed from the spindle by programming an M30 code. An automatically loaded tool
will be automatically unloaded and returned to the empty pocket reserved for the tool. A
manually loaded tool will be unloaded by the operator in accordance with the unload
instructions posted to the screen display.
1.7
Tool Change Clearance Check
Workpiece size and cutting tool geometry may dictate if or where a Tool Change
sequence can take place. The programmer is required to perform a simple calculation to
test for clearance at each tool change. See Fig.5.
1.7.1
Arrow Machines – 21 Tool
Figure 5: Auto Tool Change Clearance Check
Fig 6: Auto Tool Change Clearance Check.
Tool Magazine shown at Spindle
A2100Di Programming Manual
Publication 91204426- 001
11
Chapter 5
May 2002
Menu
Z clearance = ZTC – TL - WC
Where:
ZTC = The fixed position of the spindle nose for tool changes measured from the
machine table surface i.e.:
Machine
Automatic Tool
Change Position
Manual Tool
Change Position
Arrow 500/750
520mm (20.4 ins)
620mm (24.4 ins)*
600mm (23.6 ins)
Arrow 1000/1250C
567mm (22.3 ins)
727mm (28.6 ins)**
600mm (23.6 ins)
Arrow 1250 - 3000
828mm (32.5 ins)
-800mm (31.5 ins)
* = 100mm raised Z axis (option)
** = 160mm extended Z axis range (option)
Tool change positions are nominal values for all tool types, viz. ISO/ANSI/DIN/BT .
TL = Tool Length of the longer of the two tools involved in the tool change.
WC = Clearance level above workpiece and fixturing, measured from the machine table
surface.
A tool change may be completed with the workpiece beneath the spindle provided the
Tool Change Clearance result is zero or a positive value.
Note:
The system does not process a Tool Change Clearance check. If the Tool Change
Clearance value is negative, the X and/or Y axis must be positioned such that the
workpiece/fixture is placed well clear of the tools in the magazine before processing an
“automatic” tool change (M6) block. In addition, the diameter of the cutting tools may
also influence the final position of the X and Y axes. For “manually” loaded tools, the
table should be positioned such that the tool is at the Y axis low limit (in front of the
workpiece/fixture) for ease of handling.
A2100Di Programming Manual
Publication 91204426- 001
12
Chapter 5
May 2002
Menu
1.7.2
Arrow Machines – 30 Tool
Figure 7: Auto Tool Change Clearance Check
Figure 8: Radius Swing of Tool Changer
Double Arm
Z clearance = ZTC – TL – STC - WC
Where:
ZTC = The fixed position of the spindle nose for tool changes measured from the
machine table surface i.e.:
Machine
Automatic Tool
Change Position
Manual Tool
Change Position
Arrow 500/750
624mm (24.5 ins)
724mm (28.5 ins)*
600mm (23.6 ins)
Arrow 1000/1250C
674mm (26.5 ins)
834mm (32.8 ins)**
600mm (23.6 ins)
Arrow 1250 - 3000
940mm (37.0 ins)
-800mm (31.5 ins)
* = 100mm raised Z axis (option)
** = 160mm extended Z axis range (option)
Tool change positions are nominal values for all tool types, viz. ISO/ANSI/DIN/BT .
TL = Tool Length of the longer of the two tools involved in the tool change.
STC = Stroke of Tool Changer Double Arm mechanism = 110mm (4.3 ins)
WC = Clearance level above workpiece and fixturing, measured from the machine table
surface.
A tool change may be completed with the workpiece beneath the spindle provided the
Tool Change Clearance result is zero or a positive value.
A2100Di Programming Manual
Publication 91204426- 001
13
Chapter 5
May 2002
Menu
Note:
The system does not process a Tool Change Clearance check. If the Tool Change
Clearance value is negative, the X and/or Y axis must be positioned such that the
workpiece/fixture is placed well clear of the tools in the magazine before processing an
“automatic” tool change (M6) block. In addition, the diameter of the cutting tools may
also influence the final position of the X and Y axes. For “manually” loaded tools, the
table should be positioned such that the tool is at the Y axis low limit (in front of the
workpiece/fixture) for ease of handling.
1.7.3
FTV 850/840 and 640 Machines – All
Figure 9: Auto Tool Change Clearance Check
Figure 10: Auto Tool Change Position when
“Z clearance” Check is Negative
Although FTV machines perform the physical tool change some distance beyond the
high limit of the Y axis programmable range, the Tool Change Clearance Check detailed
here still applies. Note that the Tool Change Sequence is always to advance the tool end
point to the Z axis Tool Change Position, before traversing across in the Y axis to the
tool storage magazine.
A tool change may be undertaken with the workpiece beneath the spindle, provided the
Tool Change Clearance (Z clearance) result is zero or a positive value.
Caution:
Failure to follow this Caution may cause collision between the cutting tool and
the workpiece/fixture, possibly resulting in damage to the machine.
Z clearance = ZTC – TL – WC
Where:
A2100Di Programming Manual
Publication 91204426- 001
14
Chapter 5
May 2002
Menu
ZTC = The fixed position of the spindle nose for tool changes measured from the
machine table surface i.e.:
Machine
Automatic Tool
Change Position
Manual Tool
Change Position
FTV 640
56mm (22.0 ins)
{563mm (22.1 ins)}
600mm (23.6 ins)
FTV 840
735mm (28.9 ins)*
{738mm (29.0 ins)}*
600mm (23.6 ins)
FTV 850
735mm (28.9 ins)*
{752mm (29.6 ins)}*
600mm (23.6 ins)
Tool change positions are nominal values for all tool types, except BT.
Tool change positions shown bracketed { } are nominal values for BT tools.
* = Add 150mm (5.9 ins) to Tool Change Positions for FTV machines supplied with the
“Increased Table to Spindle Nose” option. Not applicable to FTV 640 Machines.
TL = Tool Length of the longer of the two tools involved in the tool change.
STC = Stroke of Tool Changer Double Arm mechanism
WC = Clearance level above workpiece and fixturing, measured from the machine table
surface.
Note:
The system does not process a Tool Change Clearance check. If the result of “Z
clearance” is negative, the tool end point will be below the workpiece surface, when
advanced to the Z axis tool change position. In this instance, the X and/or Y axes must
be positioned such that the tool is placed well clear of the workpiece/fixture on the
machine table, before processing a ” tool change” (M6) block.
For automatically loaded tools, it will be necessary for the programmer to place the
spindle to either the left or right hand sides of the workpiece to locate sufficient
clearance for the tool change. It is the longer length or larger diameter of the two tools
involved in the tool change that determines the final tool chance position of the X and Y
axes, see figure 10.
For “manually” loaded tools, the table should be positioned such that the tool is at the Y
axis low limit (in front of the workpiece/fixture) for ease of handling.
1.8
M26 Spindle Axis Full Retract
This feature automatically moves the spindle axis (usually Z) to its high limit after all
other motion programmed in the block has completed. M26 may be used to position the
tool away from the part for clearance, or to allow some other operation to be performed.
If the Spindle Axis Full Retract block contains an Automatic Return to Reference Point
(G28) the axis command words in the G28 block specify an intermediate point along the
rapid traverse path to the full retract position.. This can be used to control the tool path to
ensure that the part and fixturing are avoided.
An Automatic Reference Point Return (G29) in the block following the tool change
causes the tool path to pass through the same intermediate point specified by the
preceding G28. The spindle axis retract position is Reference Point #3 (P3).
A2100Di Programming Manual
Publication 91204426- 001
15
Chapter 5
May 2002
Menu
1.9
M3, M4, M5 Spindle Control
These codes start and stop the spindle. M3 starts the spindle in the clockwise direction;
M4 starts it in the counterclockwise direction, M5 stops the spindle and also turns
coolant off if it is on.
If the spindle start codes are in a block that includes programmed, non-rapid traverse
motion (e.g. G1, G2, or G3) the axis motion starts only after the spindle has reached the
operating speed specified by the S word. A valid S word must be active when an M3 or
M4 is programmed.
1.10
M13, M14 Combined Spindle and Coolant Control
These codes are provided as a convenience. They allow the spindle to be started and
the appropriate coolant selected with just one code. The effect is the same as if the
spindle and coolant controls were programmed in separate M words in the same block.
M13 has the effect of a Spindle Start Clockwise (M3) and Coolant #1 Start (M8); M14
has the effect of a Spindle Start Counterclockwise (M4) and Coolant #1 Start (M8).
1.11
M19 Oriented Spindle Stop
The Oriented Spindle Stop (M19) code stops the spindle and turns the coolant off. The
spindle is positioned to the angle specified in the S word. The S word is the required
orientation angle in degrees measured counterclockwise from the defined orient position.
The resolution of the orientation angle depends on the feedback resolution of the spindle
transducer fitted.
If no angle is specified, M19 positions the spindle to the 'orient position', which is defined
for each machine as a home position for the spindle. The S word is programmed in full
input resolution; the actual achievable positioning resolution is determined by the spindle
mechanism.
Figure 11: M19 Orient Spindle Stop
A2100Di Programming Manual
Publication 91204426- 001
16
Chapter 5
May 2002
Menu
Figure 12: Spindle Dive-key Orient Positions for 0° and 90°
The Oriented Spindle Stop code allows the NC program to control the angular position of
the tool in the spindle for such functions as probing where the position is significant.
Positive angles define counterclockwise spindle rotation when looking toward the
spindle.
Successive M19 codes position the spindle to the angle specified by the S word in each
M19 block. The spindle positions to the angle in the same manner as a 'wind-up' rotary
axis. Fig. 1.2 illustrates successive spindle positions, shown as 1 through 5. Note that
the angle is specified relative to the orient position (S = 0), and that the direction of
rotation is determined by the relative position of the current and the commanded
positions.
1.12
M41 Select Spindle Constant Power Mode
This function sets the spindle drive into its constant power mode. This allows spindle
speeds both below the motors base speed (the constant torque range) and above the
motors base speed (the constant power range). This is the default mode, and is
generally used for drilling and milling operations.
This range is automatically established whenever any one of the following conditions
occurs:
G At control turn on.
G Tool Change Code (M6) is executed.
G End of Program (M2 or M30) is executed.
The M41 code is active at the beginning of the span in which it is programmed.
A2100Di Programming Manual
Publication 91204426- 001
17
Chapter 5
May 2002
Menu
1.13
M42 Select Spindle Constant Torque Mode
This function sets the spindle drive into its constant torque mode. This restricts spindle
speeds to below the motors base speed (the constant torque range). This mode is
generally used for tapping operations. The Constant Torque Mode will be changed to the
Constant Power Mode M41 whenever any one of the following conditions occurs:
G At control turn on.
G Tool Change Code (M6) is executed.
G End of Program (M2) or End of Program (M30) is executed.
G M41 is executed.
The M42 code is active at the beginning of the span in which it is programmed.
1.14
M8, M9, M27 Coolant Control
Codes (M8 and M27) select the available coolants, or turn off all coolant (M9).
These codes have no effect on the spindle. All of the coolant on codes are active before
any axis motion programmed in the block is performed.
Coolant Off (M9) is active after any axis motion programmed in the block completes.
Coolant is also turned off by:
Tool Change (M6)
G Program Stop (M0)
G Optional Stop (M1)
G End of Program (M2)
G End of Program (M30)
Each coolant code turns its corresponding coolant on. It is possible for both external
flood coolant and through spindle coolant to be used together.
G
1.15
M8.1 - M8.8 Automatic Coolant Jets Control (Option)
Miscellaneous codes (M8.1 - M8.8) control positioning of the Automatic Coolant Jets
mechanism.
The Automatic Coolant Jets system (if supplied) replaces the standard external flood
coolant feature. The coolant jets, mounted beneath the spindle carrier, may be
incremented through eight angular positions to ensure coolant is directed to the cutting
tip of any tool, up to the maximum tool length and tool diameter specified for the
machine.
The following table can be used to establish the M-code most suited to the active tool
length and diameter. Generally, M8.1 is selected for the smallest/shortest tool, and M8.8
for the largest/longest tool.
Coolant Jets M-code selection
Tool length mm(in) <100(4.0) <150(6.0) <200(8.0) <250(10.0) >250 (10.0)
Recommended
>100 (4.0)
M8.3
M8.5
M8.6
M8.7
M8.8
coolant jets MTool dia mm <100 (4.0)
M8.2
M8.4
M8.5
M8.6
M8.6
codes for
(in)
<60 (2.4)
M8.2
M8.3
M8.4
M8.5
M8.6
selected tool
geometry
<30 (1.2)
M8.1
M8.2
M8.3
M8.4
M8.5
A2100Di Programming Manual
Publication 91204426- 001
18
Chapter 5
May 2002
Menu
Example
Miscellaneous code M8.4 is selected for an end mill 170mm long, and 50mm diameter.
The M8.x code is active when read. If it is to be used in conjunction with a ’fixed cycle’
(e.g.: G81 Drilling) the Coolant Jets M-code command must be programmed prior to
processing the fixed cycle, i.e.:
:10 G00 G40 G90 T1234 M06 ;[Drill: 10mm dia., 150mm long]
N20 X500 Y250 Z350 F75 S750 M13 M8.3
N30 G81 R300 Z-30
N40 X525 .etc…
In this example A2100 NC part program, the Coolant Jet M-code (M8.3) is processed
during the rapid approach span to a clearance position above the workpiece.
Miscellaneous code M13 commands the supply of external flood coolant. Coolant is
delivered to the tool point of the drill prior to starting the G81 machining cycle.
The programmed M-code is retained until another M8.x code from the group is
programmed, or a tool change (M06) block is encountered. When an M06 command is
processed, the control automatically retracts the Coolant Jets to the M8.1 position to
ensure clearance with the tool magazine guard. The jets will remain at this position on
completion of the tool change and until another M8.x code from the group is
programmed.
Alternatively, the system will automatically calculate a Coolant Jets position by
evaluating the active tool length and tool diameter entries from the Tool Data Table (see
Book 1 - User Guide, Chapter 2 for more information).
The Coolant Jets M-codes do not turn on the External Flood Coolant supply. The
existing miscellaneous codes, M8, M13, and M14 will continue as the external coolant
turn-on codes.
1.16
M10, M10.1 - M10.4 Axis Clamp
The NC program can activate an axis clamp by programming M10.1 for Clamp #1,
M10.2 for Clamp #2 and so on. The first axis clamp can also be commanded by
programming M10. In some machine configurations, activating an axis clamp provides
additional rigidity to allow heavier cuts to be taken.
Axis Unclamp codes (M11 and M11.1 to M11.4) disengage the clamp. In general, an
axis fitted with a clamp is automatically unclamped when it is commanded to move by
the NC program. Once unclamped, either by an explicit M11.x or by a motion command,
the axis remains unclamped until the NC program requests it to be clamped by
programming an M10.x code, or until a data reset or end of program occurs.
The control automatically unclamps the axis when powerfeed or handwheel operations
cause motion of a clamped axis. In this case the system also automatically reclamps the
axis when an NC program is initiated or resumed.
The assignment of clamp numbers to actual machine axes is done when the machine is
configured. The machine application determines which axes, if any, are clamped.
A2100Di Programming Manual
Publication 91204426- 001
19
Chapter 5
May 2002
Menu
1.17
M11, M11.1- M11.4 Axis Unclamp
The NC program can release an axis clamp by programming M11.1 for Clamp #1, M11.2
for Clamp #2, and so on. The first clamp can also be released by programming M11.
Axis Clamp codes (M10 and M10.1 to M10.4) activate the clamp. In general an axis fitted
with a clamp is automatically unclamped when it is commanded to move by the NC
program. Once unclamped, either by an explicit M11.x or by a motion command, the axis
remains unclamped until the NC program requests it to be clamped by programming an
M10.x code, or until a data reset or end of program occurs.
The control automatically unclamps the axis when powerfeed or handwheel operations
cause motion of a clamped axis. In this case the system also automatically reclamps the
axis when an NC program is initiated or resumed
The assignment of clamp numbers to actual machine axes is done when the machine is
configured. The machine application determines which axes, if any, are clamped.
1.18
M48 Feedrate and Spindle Speed Override Enable
This code cancels the effect of Feedrate and Spindle Speed Override Disable (M49)
function and applies the current feedrate and spindle speed overrides active in the
current block.
The spindle speed override command takes effect immediately; the new feedrate
override is immediately activated but the feedrate change may be subject to
acceleration/deceleration control.
The M48 (enabled) state is the default state.
1.19
M49 Feedrate and Spindle Speed Override Disable
This code allows the NC program to disable all feed and speed overrides, causing all
blocks executed in the mode to execute at the programmed feed and speed.
Overrides are removed at the start of the block containing the M49.
The spindle speed override is removed immediately; the new feedrate (without the
override) is immediately activated by the feedrate change but may be subject to
acceleration/deceleration control.
CAUTION
When the probe is disarmed, there is no protection against accidental contact with
the part or other obstructions. Failure to heed this Caution can result in damage to
the workpiece, probe, tooling, or machine.
1.20
M58 Disarm Spindle Probe
M58 causes the control to ignore probe contact signals from the probe in the spindle.
This function may be used when the probe is positioned at high speed to avoid false
trigger alarms caused by high acceleration.
A2100Di Programming Manual
Publication 91204426- 001
20
Chapter 5
May 2002
Menu
1.21
M59 Arm Spindle Probe
This code arms the surface sensing probe in the spindle. The probe is armed following a
tool change, or by executing any of the probe cycles. When the probe is armed, the
control is sensitive to any probe contact.
1.22
M60/61 Swarf Wash ON/OFF
Machines equipped with a Swarf Management System are provided with an
arrangement of coolant spray nozzles situated within the machine guard enclosure, and
designed to automatically wash swarf into the associated swarf conveyor(s). The system
is turned on and off automatically, but also allows the user to control the facility via
programmed M codes M60/61.
1.22.1
M60 Swarf Wash On
This code may be used to turn on swarf wash, if the control is in-cycle and has
previously processed an M61 (Swarf Wash OFF) command. The M60 command will also
turn off the INHIBIT WASH button LED.
Swarf Wash ON is automatically activated by the system when any of the following
occur:
G
G
G
1.22.2
The machine is set in-cycle in PROG operating mode by pressing the CYCLE
START button.
A tool change cycle is completed.
A Renishaw Tool Sensor (Tool Setting) probe cycle is completed.
M61 Swarf Wash OFF
This code may be used to turn off the swarf wash during an automatic cycle controlled
via PROG Operating mode. The M61 command will also turn on the INHIBIT WASH
button LED.
Swarf Wash OFF is automatically activated by the system when any of the following
occur:
G PROG Operating mode is de-selected.
G The FEEDHOLD button is pressed, and the operator door is open.
G The control processes an M02, M30 or M61 code.
G For the duration of an M06 (automatic tool change) cycle.
G For the duration of Renishaw Surface Sensing Probe cycles, and Renishaw Tool
Sensor (Tool Setting) Probe cycles.
G On completion of a block in SINGLE BLOCK mode.
G The control is selected in DRY RUN mode.
G The EMERGENCY STOP button is pressed.
1.23
M91/M92 Swarf Conveyor On/Off
Machines equipped with a Swarf Conveyor are arranged with system configuration data
to automatically turn on and turn off conveyor motion. The processing of M codes may
also be used to turn the conveyor off and on under program control.
A2100Di Programming Manual
Publication 91204426- 001
21
Chapter 5
May 2002
Menu
If a machine is not equipped with a Swarf Conveyor, M91/M92 are ignored. If the Swarf
Conveyor is present, M91 and M92 allow the NC program to control the conveyor
directly, overriding automatic conveyor operation. M91 turns the conveyor on and M92
turns the conveyor off.
1.23.1
M91 Swarf Conveyor On
Programming an M91 restarts automatic on/off conveyor operation starting with Swarf
Conveyor on for the period set in system configuration data.
1.23.2
M92 Swarf Conveyor Off
Programming an M92 restarts automatic on/off conveyor operation starting with Swarf
Conveyor off for the period set in system configuration data.
1.24
M70-79 User M Codes (Option)
Many applications require the addition of relatively simple equipment to a machine tool,
and require the added equipment to be controlled from the NC program. The User M
Code option makes available the M70 series of M codes for this purpose. To
accommodate the common uses for programmable outputs, the User M Codes can be
configured in several ways:
G The output signal can be pulsed, maintained until an external signal is received, or
turned off by a second M code.
G NC program execution can be held until the function is complete (a fixed time or
signalled by an external input signal), or can be allowed to continue.
G The code can be active at Start of Block or End of Block.
G The output signal can be configured to be normally on or normally off.
G An alarm can be reported if the external acknowledgement is not received within a
specified time.
Each M code has an assigned output signal and input signal. Each M code can be
individually configured to be pulsed, maintained, or toggled:
A pulsed M code output signal is active for a fixed time each time that M code is
executed. Each of the M70 User M codes has its own pulse duration.
G A maintained M code output signal is active when the M code is executed, and the
signal remains active until the associated input signal is activated by external
circuitry. This arrangement ensures that the external device has time to respond to
the M code output signal.
G A toggled M code output signal is active when the associated M code is executed.
The signal is turned off by executing the corresponding reset M code, which is the
base M code with a ”.1” suffix. For example, if M72 is configured as a toggled M
code, the signal is turned on by programming an M72 and turned off by
programming M72.1.
For user M codes configured as maintained or toggled, the pulsewidth configuration
value establishes a minimum duration. That is, if a non-zero pulsewidth is specified, the
output signal remains active for the specified time duration, and continues to remain
active until the acknowledgement signal (for maintained) or the reset M code (for
toggled) signals occurs.
G
A2100Di Programming Manual
Publication 91204426- 001
22
Chapter 5
May 2002
Menu
Each M user M code can be specified to hold cycle or not. If hold cycle is specified, NC
program execution is held until:
The pulsewidth elapses for pulsed outputs.
G The pulsewidth elapses and the acknowledgement signal is received for maintained
outputs.
G The pulsewidth elapses and the reset M code is executed for toggled outputs.
Finally, each user M code configured as maintained can report an alarm if the
acknowledgement signal is not receive within a specified maximum time. This is useful to
detect a failure in the external equipment and report the condition, rather than simply
remaining in cycle waiting indefinitely for the acknowledgement.
G
1.25
M83 Part Complete
The control maintains a count of parts that have been produced. Normally this count is
incremented automatically based on end of program (M2 or M30). In some cases,
however, a single execution of an NC program may produce multiple parts. For example,
a machining centre program may machine several related parts on a single fixture in a
single program.
The M83 Part Complete code allows the NC program to notify the control that a part has
been completed. The only action is to increment the part count maintained by the
control. If a program that produces multiple parts is implemented using M83 to count
parts, the program should arrange not to execute an M83 on the last part since the end
of program code will also increment the part count.
1.26
M34/M35 Data Acquisition On/Off
The control provides a programmable facility to collect information about the program
execution. The data to be collected are specified using the Data Acquisition Initialisation
(DAI) and Data Acquisition Save (DAS) Type II blocks. When the data acquisition feature
is active, these M codes turn the actual data collection on and off. This allows the NC
program to control that portion of the program for which data are collected. M34 turns on
the data acquisition; M35 turns data acquisition off. The data acquisition may be further
controlled by a programmable trigger that must be satisfied in addition to the M34.
A2100Di Programming Manual
Publication 91204426- 001
23
Chapter 5
May 2002
Menu
1.27 M69 Alternate Work Station.
The spindle may be moved to the Alternate Work station by processing an M69 code.
M69 is an M.D.I. function only.
On processing an M69 in M.D.I. mode, the machine will retract the Y and Z axes to a
factory set reference position and then traverse the spindle along the X axis to the
Alternate Work Station. The M69 function does not affect the current Part Program nor
Co-ordinate Offset selection.
The action of the machine on processing the M69 code occurs when the following
conditions are satisfied:
-
M.D.I. is the selected operating mode.
both operator doors at the front of the machine are closed.
there is no tool in the spindle.
2.
TOOL MANAGEMENT
The tool management system provides the operator with an process-oriented view of
tooling, see Fig.2.1. The tool management system contains information (about each tool
known to the system) to fully describe the tool. The NC program loads the tool, and the
tool-specific information (tool length, diameter offset, number of teeth, maximum RPM,
etc) is applied by the control. Separating the tool-specific information from the NC
program allows the same program to operate with tools that differ in size, number of
teeth, etc, provided the different tool is capable of performing the operation. This
simplifies tooling management for the operator. Most of the data stored in the tool
management system is optional. That is, if data is not supplied, the default
values simply remove the tool data related feature. For example, the default tool type
UNKNOWN turns off all tool type checking.
A2100Di Programming
5 –23A
Publication 91204426A001
Menu
Tooling Data are created and stored within the Tool Resource File. During Job Set-up,
tooling information is moved to the machines active tool storage (magazine and manual
tool rack) from the Tool Resource File.
Figure 13: Tool Management
2.1
Tool Selection
Tool selection is done by programming a T word in an NC program or subroutine. The T
word may be interpreted either as a Tool Identifier or as a Tool Record number. This is
determined by a control configuration parameter for the number of tool pockets in the
system. See Section 2.4 (Tool Search) for more information about the use of the T word.
A machining centre tool changer may queue more than one tool that has been selected
by the programmed T word. In this case, the tool change M-code determines the block in
which the queued tool is inserted into the spindle. The tool selection becomes active
after it is placed in the spindle.
2.2
Tool Data Library
A comprehensive set of tool data is standard on the control. All tool data table
information is read/write accessible from an NC program. Access to the current machine
tooling information is provided in System Names for the ACTIVE, NEXT, and PREVIOUS
tool. Tool data system names are read-only from an NC program.
2.3
Tool Data Information
There is a default value for each tool data item. The tool data may be reset by the
operator at any time on a per field, per column, per row, or per library basis. Refer to
Book 1 – User Guide, Chapter 2 for tool data information.
2.4
Tool Search
When a T word appears in an NC program, the control attempts to find the requested
tool by searching the active tool table (which includes the tools in the tool magazine,
A2100Di Programming Manual
Publication 91204426- 001
24
Chapter 5
May 2002
Menu
manually loaded tools, and cradle loaded tools). Note that the tool search is limited to the
active tool table; tools in the tool file are not accessible to the part program.
The standard tool search algorithm is based on the control configuration parameter
which specifies the minimum tool ID. If the T word value is less than the minimum tool ID
it specifies a tool record number, otherwise it is a tool identifier. To specify that all T
words are treated as tool identifiers, the number of tool pockets configuration parameter
is set to zero.
The control provides three tool search algorithms:
G The first specifies that the control supplies the first available tool.
G The second specifies that the control supplies the tool with the lowest cycle time
remaining.
G The third specifies that the control supplies the tool with the programmed tool ID in
the lowest numbered tool pocket.
Additional algorithms can be added for extended chain management on some machines.
2.5
Tool Identification
Programming by Tool Identifier provides for user cataloguing of tools and redundant tool
programming where multiple tools have the same ID number. The Tool ID entry range is
a full ten digits. Use of the T word in arithmetic expressions is permitted to allow for
automatic tool sequencing program algorithms.
2.6
Tool File
The master tool record is kept in the Tool File. The master tool record is intended to
contain specific tool data about a particular tool as well as that tools history. For tool
tracking each tool has both an external and internal unique identifier. The external
unique ID is the Tool Serial Number, which can be assigned by an operator, cell
controller, or automatic tool chip reader. The internal unique ID is not visible to the user
and exists only to allow unique identification of tooling records for data modification by
an NC program.
This number is assigned automatically by the control system and remains unique to a
particular tool as long as the tool remains within the system. Tool algorithms that need to
reference a unique tool should use this number indirectly (access is provided via a
system variable) to gain access to the associated tool record. This number is not
displayed. The Tool Record Number can be used as a unique tool reference, however
this only applies to the active tool set.
The following sample program shows how the tool record number can be used to rough
machine a pocket, probe the pocket, and update the diameter offset which can be
applied to the tool to finish machine a 4 inch pocket.
T1234 M6; load end mill
[#TEMP1] = [$RECORD_NO(0)];save record # of the active tool
Blocks to rough machine the pocket
T5678 M6; load probe
Blocks to measure pocket
G79..... ;width is in [$PRB_WIDTH]
[$TOOL_DATA([#TEMP1])DIA_OFFSET] =
[$TOOL_DATA([#TEMP1])DIA_OFFSET] + 4.0 - [$PRB_WIDTH]
A2100Di Programming Manual
Publication 91204426- 001
25
Chapter 5
May 2002
Menu
T1234 M6; reload end mill
Blocks to finish machine pocket
Note that when using the Tool Record Number data are only applied to the Active Tool
Set.
2.7
Tool Magazine and Active Tool Set
The tool magazine represents the physical storage device on the machine. Manually
loaded tools that are loaded for a particular job are also considered as part of the active
tool set. Members of the active tool set can be referenced by Record Number or Tool ID.
In a non-migrating tool system Record Number and Pocket Number are the same.
2.7.1
Tool Programming
From the NC program all data or tooling references are made relative to the active tool
set. In the NC program, the T word specifies the tool as a numeric value with up to 10
digits. The value of the T word refers to either the Tool Record Number or Tool ID. A
configuration parameter specifies the number of records in the active tools set. Anything
above this value is considered a tool ID, not a record number.
An additional configuration parameter specifies the number of physical pockets in the
mechanism, any number between the number of physical pockets and maximum records
is considered a manual or cradle loaded tool when record addressing is used.
References to tool data for a specific tool from a NC program can be done by Tool
Reference Number or by Tool Record Number. The difference is that, if an external tool
transport or tool data system is involved, then tool reference number is the only way to
guarantee that the link will exist even if the tool has been removed from the machine.
2.8
Tool Type
The tool type is used by many of the
possible selections for tool type:
UNKNOWN
FACE MILL
SPOT FACE
FLY CUTTER
ROUGH END MILL
FINISH END MILL
BN END MILL(ball nose end mill)
SHELL MILL
fixed cycles. The control supports the following
THD MILL (thread mill)
KEY CUTTER
DRILL
SPOT DRILL
COUNTER SINK
REAMER
TAP
RIGID TAP
BORE
BACKBORE
PROBE
SPECIAL 1
SPECIAL 2
SPECIAL 3
SPECIAL 4
SPECIAL 5
SPECIAL 6
SPECIAL 7
SPECIAL 8
SPECIAL 9
The SPECIAL 1 through SPECIAL 9 are extra tool types that could be utilised in
applications where additional tool types are required.
2.9
Migrating Tools (Arrow Machines – 30 Tool Storage Magazine)
Some tool changer mechanisms can operate more efficiently if the tool in the spindle is
returned to a pocket other than the tools original location. For example, with some tool
A2100Di Programming Manual
Publication 91204426- 001
26
Chapter 5
May 2002
Menu
changers, it is faster to exchange the tool in the spindle with the tool to be loaded. This
style of tool changing is called migrating tools because the tools migrate, or move, as the
NC program runs.
In some cases, it is desirable to place the tool back into its original pocket. The Migrating
Tool field provides this capability.
The Migrating Tool field is set to YES or NO to indicate whether the tool is permitted to
migrate. The Tool Size field indicates the number of adjacent pockets required for the
tool. If a tool is allowed to migrate, the tool may be placed in any available pocket of the
tool chain taking into consideration both the size of the returned tool and the size of the
adjacent tools. For some tool change mechanisms this style of tool search can reduce
tool change cycle times.
2.10
Tool Load Method
The tool load method field provides the following selections:
G
Auto Load (AUTO) = 0
G
Manual Load (MANUAL) = 1
G
Cradle Load (CRADLE) = 2
G
Heavy Auto = 3
A value of AUTO specifies that the associated tool is loaded into the spindle by the tool
change mechanism. MANUAL means that the tool is loaded by the operator. A value of
CRADLE is used to specify that the tool is loaded from a tool cradle, a fixed location on
the machine used to hold tools.
2.11
Tool Compensation
The controls automatic tool compensation feature allows NC programs to be written
without prior knowledge of available tooling. Tooling information may be updated by file
restore, from an NC program, or as an update at the machine by the operator.
2.12
Tool Length
The tool length feature allows the operator to specify the tool length offset that is applied
to the tool axis command when the specified tool is loaded into the spindle. Tool length
values are permitted in the range of ± 999.9999 mm. The default is zero. If zero tool
lengths are used, the NC program must use O word Programmable Tool Offsets or take
tool length into account in the NC program.
2.13
Flute Length
The tool flute length field is used by the control plotter to determine the correct plot cut
depth. The allowable range for tool flute length is ± 999.9999 mm. The default is zero.
2.14
Nominal Tool Diameter
Nominal tool diameter is used by many of the control fixed cycles. Drill cycles, for
example, make use of the nominal diameter and tool tip angle fields to compute a drill tip
compensation allowance. This allowance is automatically included in the cycle plunge
A2100Di Programming Manual
Publication 91204426- 001
27
Chapter 5
May 2002
Menu
depth to correct for tip length in order to produce a hole that is drilled to the final depth at
full diameter. See, Hole Making Cycles (G80 series).
Nominal tool diameter is also used by Milling Cycles (G22-G28), Tool Sensor (G68/G69)
Cycles, and by the control plotter. The default is zero, no tool tip compensation is
applied. Also plot does not show the tool size.
2.15
Diameter Offset
The diameter offset field is used to compensate for oversized or undersized cutters in
NC programs that utilise Cutter Diameter Compensation (CDC). CDC is programmed
using modal G codes G40, G41, and G42. A positive offset is used to specify an
oversize tool. A negative diameter offset means an undersize tool for the CDC feature.
Allowable diameter offset amounts are in the range of ± 999.9999 mm. The Diameter
offset is also used by Tool Sensor (G68/G69) Cycles, and by the A2100 plotter.
The default is zero.
2.16
Number of Teeth
The number of teeth is a two-digit value in the range 1 through 99 which specifies the
number of teeth or cutting edges on the cutter. The value is used in feed per tooth (FPT)
and feed per rev (FPR) feedrate modes.
Entering this value permits G95 feedrates to be specified directly as feed per tooth. If a
cutter with a different number of teeth is substituted, the feedrates are automatically
adjusted. The default is 1, which makes G95 equivalent to feed per revolution.
2.17
Tool Tip Angle
The tool tip angle feature (Fig. 2.2) allows the control to compensate the depth of a hole
based on the tip angle of the particular tool. This is especially useful for drilling
operations. The tool tip angle is also used to record the angle of a single point boring tool
relative to the toolholder drive slot, to allow retraction of the tool without leaving a drag
line. Tool tip angle is the included tip angle in degrees with a valid range of 0-359.999.
Orientation and angle are calculated as follows:
Figure 14: Tool Tip Angle
A2100Di Programming Manual
Publication 91204426- 001
28
Chapter 5
May 2002
Menu
2.18
Threads Lead
For inch or metric taps, the maximum feedrate field (Feed Per Tooth) is used to specify
the thread lead. The valid range for the TPI field is 0-99.
2.19
Spindle Speed Override
Spindle speed override is a three-digit value in the range 1 through 999 percent. This
value is used in combination with the active operator spindle speed override value, to
achieve an effective spindle speed override when the tool is in use.
2.19.1
Per Tool Feedrate Override
The per-tool Feedrate override is a three digit value in the range 1 through 999 percent.
This value is used in combination with the active feedrate override percent set by the
operator, to give an effective feedrate override to be used for this tool.
2.19.2
Per Tool Maximum RPM
The Maximum RPM field in the tool table provides an upper limit for spindle speed while
this tool is active. Spindle RPM ranges from 0.0 to 99999.9 RPM.
2.19.3
Per Tool Maximum Feedrate
The Maximum Feedrate field in the control tool table provides an upper limit for feedrate
while this tool is active. The allowable range for maximum feedrate is 0 to 99999 mm per
minute.
2.20
Tool Status
The Tool Status field indicates the status of the tool. A value of GOOD indicates the tool
is not worn or broken, and that it has been set-up with the correct length or fixed offset. A
value of NEW specifies that the associated tool is being used for the first time. NEW may
be used to indicate that a fixed tool probe is to be used to measure the tool length.
The control tool wear feature allows the operator to set limits, based on time or on tool
usage, for automatic tool monitoring. When a particular tools life has expired, the tool is
marked as WORN. If a worn tool is specified in a tool change block, the worn tool is not
loaded. If an alternate or redundant tool is available, the alternate or redundant tool is
checked for compatibility and, if usable, loaded into the spindle.
2.21
Tool Cycle Time (Option)
The tool cycle time mode is a field with OFF and ON as the possible selections. OFF
specifies that the tool cycle time is not accumulated for the associated tool and ON
means that it is accumulated.
The tool cycle time is accumulated during axis feed motion when the spindle is running.
When a tools life is exceeded during use, an alarm is posted and the tool is marked
worn, but the program execution continues. If the tool is requested in another tool
change, an alternate or redundant tool is used (if one is present). The tool may be
manually set to worn by the operator to cause the tool (and cycle times) to be ignored.
The range for tool cycle time is 0 to 999.99 min
A2100Di Programming Manual
Publication 91204426- 001
29
Chapter 5
May 2002
Menu
2.21.1
Tool Usage Count (Option)
The Tool Usage Count mode field is similar in operation to the Tool Cycle Time Status
field. When set to OFF the tool usage count is not accumulated for the associated tool.
When set to ON the usage count is accumulated. The Tool Usage Count is incremented
each time the tool is selected for use (i.e., in response to a tool change that selects this
tool) if tool usage monitoring is ON.
Tool usage count is incremented up towards a limit. This limit is Tool Usage Count Limit
which has a range of 0 to 99999. When the accumulated Tool Usage Count exceeds the
specified Tool Usage Count Limit the tool is marked as worn. The tool may be manually
set to worn by the operator to cause the tool (and usage count) to be ignored.
2.22
Alternate Tools
Alternate tools are automatically used when the primary or current tool is worn or
exceeds its cycle time limit or usage count. The alternate tool selection and search
algorithms are identical to those specified by the original T word.
Alternate tools may be chained together; that is, an alternate tool may itself specify an
alternate tool. When any tool in the chain of alternate tools is marked as worn the tool is
ignored and the search continues with the next alternate tool. The tool search will
continue until a usable tool is found or no alternate tool is specified.
2.23
Tool Reference Number
The Tool Reference Number provides a unique reference to a tool in the tooling tables.
This field is read only by the NC program and can be used to access tooling information
in the Tool Reference File if the tool is no longer part of the active tool set. If the tool is
part of the active tool set, the Tool Reference Number may be used to access data in the
active tool set. The Tool Reference Number is used by reading it from the active tool
data system name.
The need arises when a tool is used to machine a surface, then, later, the surface is
measured using a probe, and the NC program updates the tool diameter offset or length.
If the tool became worn and was replaced between the machining operation and the
probing, the measured correction would be applied to the wrong tool if the Tool Record
Number is used to access the tool data. Use of Tool Reference Numbers permits the
data for the tool used for the machining to be updated even if the tool is removed from
the system.
The following sample program shows how the tool reference number can be used to
rough-machine a pocket, probe the pocket, and update the diameter offset which can be
applied to the tool to finish-machine a 4 inch pocket.
T1234 M6; load end mill
[#TEMP1] = [$TOOL_DATA(0)REF_NUMBER];save ref#
.
Blocks to rough machine the pocket
.
T5678 M6; load probe
.
Blocks to measure pocket
G79..... ;width is in [$PRB_WIDTH]
A2100Di Programming Manual
Publication 91204426- 001
30
Chapter 5
May 2002
Menu
[$TOOL_DATA([#TEMP1])DIA_OFFSET] =
[$TOOL_DATA([#TEMP1])DIA_OFFSET] + 4.0 - [$PRB_WIDTH]
T1234 M6; reload end mill
.
Blocks to finish machine pocket
2.24
Tool Class
This field specifies the category of the tool. The tool may belong to the ROTATING tool
category (most machining centres tools and rotating tools on turning centres), the FIXED
tool category (most turning centre tools) or the MISCELLANEOUS tool category.
2.25
X Probe Offset
This field contains the X axis incremental offset of the effective centre of a spindle probe
from the spindle centreline (if the Tool Type is PROBE, see fig. 2.3). This value is set by
the G72 Set Stylus and Tip Dimensions cycle. For tools other than probes, this field is
used to record the X axis offset from the tool tip to be measured by the fixed probe from
the spindle centreline. This value is used by the tool probe cycles G68 and G69.
Figure 15: X Probe Offset
2.26
Y Probe Offset
This field contains the Y axis incremental offset of the effective centre of a spindle probe
from the spindle centreline (if the Tool Type is PROBE). This value is set by the G72 Set
Stylus and Tip Dimensions cycle. For tools other than probes, this field is used to record
the Y axis offset from the tool tip to be measured by the fixed probe from the spindle
centreline. This value is used by tool probe cycles G68 and G69.
A2100Di Programming Manual
Publication 91204426- 001
31
Chapter 5
May 2002
Menu
Chapter 6
HOLE-MAKING FIXED CYCLES
Contents
1
2
3
4
5
6
6.1
6.2
6.3
6.4
6.5
6.6
6.6.1
6.6.2
6.6.3
6.7
6.8
6.9
6.10
6.11
6.12
7
7.1
7.2
7.3
7.3.1
7.4
7.5
7.6
7.7
7.8
7.8.1
7.8.2
7.8.3
7.8.4
7.8.5
7.8.6
7.8.7
Overview............................................................................................... 3
R Work Plane........................................................................................ 5
Hole Depth............................................................................................ 6
Boring Tool Retract ............................................................................. 7
End of Cycle Incremental Retract Dimension (W word) .................... 9
Tool Types............................................................................................ 9
Operation in Single Block and Single Loop mode............................. 9
G80 Reset Fixed Cycle ...................................................................... 10
Permissible Tool Types ..................................................................... 10
G81 Drill Cycle ................................................................................... 12
G82 Counterbore/Spot Drill with Dwell Cycle .................................. 13
G83 Deep Hole Drill (Peck Drill) Cycle.............................................. 15
Chip Breaking .................................................................................... 15
Chip Clearance................................................................................... 15
G84 Tap Cycle (Conventional) .......................................................... 19
G84.1Tap Cycle (Rigid) ...................................................................... 21
G85 Bore/Ream Cycle........................................................................ 24
G86 Bore Cycle, Dead Spindle Retract............................................. 25
G87 Back Bore Cycle......................................................................... 28
G88 Web Drill/Bore Cycle .................................................................. 34
G89 Bore/Ream Cycle with Dwell Cycle ........................................... 37
Milling Cycles..................................................................................... 46
Milling Cycle Depth............................................................................ 47
End of Cycle Incremental Retract Dimension (W word) .................. 48
Tool Types.......................................................................................... 48
Operation in Single Block and Single Loop Mode........................... 48
Rectangular Milling Cycle Dimensions ............................................ 49
Circular Milling Cycle Dimensions ................................................... 49
Milling Cycle Cut Width and Depth................................................... 50
Milling Cycle Machine Type .............................................................. 50
Milling Cycle Feeds and Speeds....................................................... 50
G22 Rectangular Face Milling Centre Specified Example............... 55
G22.1 Rectangular Face Milling Corner Specified Example ........... 56
G23 Rectangular Pocket Centre Specified and
G23.1 Rectangular Pocket Corner Specified.................................... 58
G23.1 Rectangular Pocket Corner Specified Example .................... 66
G24 Rectangular Inside Frame Centre Specified and
G24.1 Rectangular Inside Frame Corner Specified. ........................ 68
G24 Rectangular Inside Frame Centre Specified Example ............. 73
G24.1 Rectangular Inside Frame Corner Specified Example.......... 74
A2100Di Programming Manual
Publication 91204426-001
1
Chapter 6
May 2002
Menu
7.8.8
7.8.9
7.8.10
7.8.11
7.8.12
7.8.13
7.8.14
8
9
10
10.1
10.2
G25 Rectangular Outside Frame Centre Specified and
G25.1 Rectangular Outside Frame Corner Specified....................... 76
G25 Outside Rectangular Frame Centre Specified Example........... 80
G25.1 Outside Rectangular Frame Corner Specified Example ....... 82
G26 Circular Face............................................................................... 83
G26.1 Circular Pocket Cycle.............................................................. 89
G27 Circular Inside Frame ................................................................. 94
G27.1 Circular Outside Frame ........................................................... 98
End of Cycle Incremental Retract Dimension (W word) ................ 104
Invoking User Subroutines by a Pattern......................................... 104
G36 Move to Next Operation Site .................................................... 104
Specific Action of G36 ..................................................................... 105
Specific Action of G36.1 .................................................................. 106
A2100Di Programming Manual
Publication 91204426-001
2
Chapter 6
May 2002
Menu
1
Overview
The G80 series of fixed cycle operations provide a simple means of programming
common hole-making operations including drilling, boring, counterboring, and tapping.
The cycles are programmed in a single block and perform all of the stops needed to
perform the specified operation. These cycles are:
G G81 Hole Depth Programming
G
G82 Counter Bore/Spot Drill with Dwell Cycle
G
G83 Deep Hole Drill (Peck Drill) Cycle
G
G84 Tap Cycle (Conventional)
G
G84.1 Tap Cycle (Rigid)
G
G85 Bore/Ream Cycle
G
G86 Bore Cycle Dead Spindle Retract
G
G87 Back Bore Cycle
G
G88 Webb Drill/Bore Cycle
G
G89 Bore Ream Cycle with Dwell Cycle
The Fixed Cycles use a number of parameters that are specified in a table called the
Cycle Parameter Table. These items are normally fixed values, but may be changed to
suit special needs. The Cycle Parameter Table is accessible by the machine operator to
allow cycle specific items such as dwell times to be adjusted for the current program.
The NC program can reset the Cycle Parameter Table to the configurable default
settings by programming a Cancel Cycle (G80) with a J word value of 1. The parameters
for an individual cycle can be reset by programming a J word value equal to the cycles G
code value; e.g., J82 resets the G82 Cycle Parameters.
Note
Refer to Chapter 6 of this publication for a complete listing of Hole-Making Cycles and
Parameters
CAUTION
The sample programs in this Chapter are intended to give the programmer an
understanding of cycle characteristics. Be aware that many of these sample
programs modify Cycle Parameter and Tool Table information. Also, due to the
variety of machine set-ups it is recommended that all sample programs should be
run under Dry Run conditions.
Failure to heed this Caution may result in damage to equipment.
Fixed cycles use various word addresses to specify or control the action of the cycle.
The words can select how to perform a function, specify dimensions to use, or request
optional motions.
The use of word values by fixed cycles is slightly different from most NC blocks. In fixed
cycles, a word value can be modal, non-modal, or cycle-modal. Modal values follow the
normal NC meaning that the value is retained once programmed. Non-modal values are
effective only in the block in which they are programmed. Cycle-modal values are
retained once programmed until a different G code in the same cycle series is
programmed.
A2100Di Programming Manual
Publication 91204426-001
3
Chapter 6
May 2002
Menu
For example, a G86 (Bore, dead spindle retract) cycle can specify an offset value to use
to retract the boring tool from the work using the U word. Once a G86 with a U value is
programmed, subsequent G86 blocks use the same value. If a G85 is programmed,
however, the U value is reset to a 'not programmed' state.
The G80 series of hole-making fixed cycles all share a reference plane, a clearance
plane, and a spindle axis:
G
The reference plane is defined as the nominal work surface.
G
The clearance plane is parallel to the reference plane and located above the nominal
work surface by the gage height amount; this is the plane in which hole-to-hole
positioning motion occurs.
G
The spindle axis is the axis normal to the reference plane.
For many machines, the spindle axis is always the Z axis, and the reference and
clearance planes are parallel to the XY plane. For other machines, the spindle axis may
change as right angle heads are fitted, or the spindle may rotate so that it is not parallel
to Z.
The G80 series cycles are configurable to match the machine type. For most machines,
the cycles are exactly as described in the remainder of this Section; the spindle axis is Z
and the reference plane is parallel to the XY plane.
Figure 1.1 Hole-Making
The G80 hole-making cycles share some common attributes see Fig. 1.1. The basic
sequence of steps for the G80 series cycles is:
G Rapid all non-spindle axes to the commanded position.
G Rapid the spindle (usually Z) axis to the clearance plane (specified by the R word).
G Feed the spindle axis (usually Z) to depth.
G Perform cycle-specific dwell and spindle operations.
G Feed or rapid the spindle axis back to the clearance plane.
G Perform cycle-specific dwell and spindle operations.
G
Rapid the spindle axis the additional W distance, if the W word is programmed.
A2100Di Programming Manual
Publication 91204426-001
4
Chapter 6
May 2002
Menu
The first step (rapid all non-spindle axes to the commanded position) can be specified by
Cartesian (XY) co-ordinates or by Polar co-ordinates.
Note
Three hole-making cycles (G86, G87, G88) use non-modal U and V words, which are
signed incremental offsets applied to X and Y axis respectively. They are used to shift
the tool tip to prevent interference with the part and to eliminate drag lines.
These words are optional in the G86 and G88 cycles, but are required with G87. If it
becomes necessary to use these words, Spindle Feedback option or an Orienting
Spindle is required to assure proper positioning of the tool tip. If the tool is not in correct
orientation when the offsets are applied, spindle, tool tip, or part damage may occur.
2
R Work Plane
Fixed cycles perform all hole-making operations with respect to a reference plane, or R
plane (a plane perpendicular to the spindle axis located at the nominal work surface).
The reference plane location is specified by the NC program using the R word.
As it is not possible to perform hole-to-hole positioning rapid moves at the part surface,
the cycles add a clearance allowance referred to as the 'gage thickness' or 'gage height'
to the programmed R dimension. Gage height is defined in the Cycle Parameter Table.
There are two Cycle Parameter Table entries for gage height, one for inch operation and
one for metric operation.
The R word is always interpreted as an absolute dimension in the spindle axis
regardless of the setting of Absolute/Incremental (G90/G91). The R word is modal, and
once an R word has been programmed in any fixed cycle block in a program, the value
is retained for all fixed cycle blocks in the program.
The highest surface of the workpiece is most commonly designated as the R0 plane. If a
surface on the fixture is used, the distance from this surface to the workpiece must be
known in order to calculate the R plane dimensions of the workpiece.
Fig. 2.1 shows the use of the R dimension on multi-level parts. Note that the R value is
decreased by the thickness of each level. For ease of programming, and to reduce the
chance for error, the R work plane dimensions are always considered to be on the part.
Figure 2.1 R Word
Fig. 2.2 illustrates the relationship of the R dimension. Normally Gage Height is 0.100”
for inch and 3 mm for metric. When an R plane dimension is programmed, the tool
A2100Di Programming Manual
Publication 91204426-001
5
Chapter 6
May 2002
Menu
rapids to the Gage Height above that R plane, clearing the work by 0.100 inch for this
example.
Figure 2.2 Gage Height
3
Hole Depth
The hole depth for fixed cycles can be specified in one of two ways, either as an
incremental depth from the reference plane, or as the absolute dimension of the bottom
of the hole. The hole depth parameter also specifies whether an extra amount to account
for the angled tip of the tool (drill point length) is added to the hole depth. The selection
is made by the Hole Depth Programming Mode Cycle Parameter as shown in Chapter 6,
G81 Hole depth programming follows:
If Hole Depth mode is selected, the hole depth for all cycles is programmed as the
unsigned incremental distance from the R plane (nominal work surface) using the
spindle axis word (usually Z).
The control automatically adds the gage height to the programmed hole depth, and also
adds an allowance to compensate for the angled tip of a drill for certain cycles (G81,
G82, G83, and G88) if the hole depth mode is zero or one. This drill tip compensation
(breakthrough depth) permits the NC program to specify the depth of hole that is
required to be at full diameter.
Drill tip compensation is added only if all of the following are true:
G
The hole depth mode is zero or one.
G
The active tool has a type of Drill.
G
Both the Nominal Diameter and Tip Angle of the tool entry in the tool table are nonzero.
G
The hole depth is modal; once it has been programmed in any cycle block in a
program, the value is retained for all fixed cycle blocks in the program.
If Hole Bottom mode is selected, the spindle axis word specifies the absolute dimension
of the bottom of the hole. This value is decreased (i.e., the hole is made deeper) by the
drill tip compensation if the hole depth mode is zero and the selected tool is specified
with Tool Type DRILL, and the Nominal Diameter and Tip Angle fields of the tool entry in
the tool table are non-zero.
When a Z value is programmed the control automatically generates a move equivalent to
the Z dimension plus gage height dimension, plus drill point if Hole Bottom mode is
A2100Di Programming Manual
Publication 91204426-001
6
Chapter 6
May 2002
Menu
selected. For example, with Hole Depth mode selected, when a 1” dimension is
programmed the Z axis moves a total of -1.1” plus drill point length.
To program the depth of cut for the three holes, as shown in Fig. 2.3, the program would
contain the following Z and R values.
Hole Depth Mode
Hole Bottom Mode
Pos.1 Z-1.0 R0
Pos. 1 Z -1 R0
Pos.2 Z-1.0 R-1.0
Pos. 2 Z -2 R-1
Pos.3 Z-1.0 R-2.0
Pos. 3 Z -3 R-2
Even though the Z value appears first in the program, the R value is acted upon before
the Z dimension.
Figure 2.3 Gage Height
Note
The fixed cycle operation can be changed to emulate some other controls by setting the
gage height to zero and specifying Hole Bottom mode. If the Tool Type is set to
UNKNOWN, or if the tip angle is set to zero, the tip clearance is also omitted.
4
Boring Tool Retract
The G86, G87, and G88 boring cycles allow the boring tool to be retracted with the
spindle stopped and oriented. The U and V words of these blocks specify an amount by
which the tool centreline is offset in X and Y respectively. This allows the tool tip to clear
the workpiece and avoid a drag line as the boring tool is extracted from the hole.
The sign of the U and V word determines the direction of the tip offset. A positive U word
offsets the tool in the +X direction. In Fig. 2.4 a negative U word offsets the tool in the -X
direction.
A2100Di Programming Manual
Publication 91204426-001
7
Chapter 6
May 2002
Menu
Figure 2.4 Boring Tool Retract
To use the tip shift capability, the position of the boring tool tip relative to the machine
axes must be known. The control Tool Data includes a Tip Angle field that, for boring
bars, specifies the angle of the tool tip relative to the zero orientation angle. The angle is
measured counterclockwise from the zero orientation position to the tool tip looking from
the spindle to the work.
Whenever the tool is oriented by one of the bore fixed cycles (G86, G87, and G88), the
Tip Angle is subtracted from the zero orient position. Thus, a tool with a Tip Angle of 90º
will orient the spindle to 270º (-90º).
Additional control of tool tip angle is provided by the J word in the bore fixed cycles. The
J word specifies the required tool tip orient angle, allowing the tip to be placed at any
orientation to take advantage of a keyway. When the J word is used, the resultant
spindle oriented position is the J word value minus the Tip Angle from the tool table. See
Fig. 2.5.
Figure 2.5 Tool Tip Orientation (J-word)
A2100Di Programming Manual
Publication 91204426-001
8
Chapter 6
May 2002
Menu
Note
U and V tip shifts are subject to the effects of a Rotation of Axes (ROT,) command. The
programmed Tool Tip Orientation Angle (J word) ignores (ROT,) commands. U and V tip
shifts, and J orientation angle are not affected by Axis Inversion (INV,) commands.
5
End of Cycle Incremental Retract Dimension (W word)
The G80 series Fixed Cycles finish with the tool at the clearance plane. These cycles
accept an optional, non-modal W word whose value specifies a rapid move to a point
above the work surface (reference plane). The W word value is the distance above the
reference plane (nominal work surface).
If the cycle completes by a rapid move to the clearance plane, programming a W word
causes the reference plane to be ignored and the cycle rapids directly to the position
specified by the W word increment. If the cycle completes by a feed move to the
clearance plane, the rapid move to the W dimension follows the feed move.
6
Tool Types
The control supports the identification of the type of tool in the Tool Type field of the Tool
Data Table. In general the use of the field is optional. If the Tool Type is UNKNOWN or
one of the SPECIAL types, the cycles proceed assuming that the tool is of the proper
type.
If the Tool Type is specified, the Fixed Cycles ensure that the tool is appropriate for the
operation. Some cycles perform additional tool type specific functions if the tool type is
known. For each of the Fixed Cycle descriptions in the following Sections the permissible
Tool Types are noted.
6.1
Operation in Single Block and Single Loop mode
When single block mode is selected, the control executes one block of the NC program
and then stops and waits for the next operator action. Fixed cycle blocks are performed
to completion in single block mode, including both the move to the operation location and
the complete operation specified by the block.
In some circumstances, it may be desirable to execute an NC program without
performing all of the fixed cycle operations, and the control provides a mode of operation
for this purpose. In Single Loop mode, G80 series fixed cycles perform the move to the
operation location, stopping at the clearance position before executing the actual
machining operation.
At this point, the operator can select Cycle Start or Z Repeat:
G
Cycle Start skips the machining operation and proceeds to the next block
immediately. In this case, the end of block functions, including the optional W word
retract, are performed.
G
Z Repeat executes the machining portion of the cycle and stops again when the
spindle axis is returned to the clearance plane.
In a series of G80 operations executed in Single Loop mode with Single Block off, each
press of Cycle Start causes the machine to move to the operation site for the next cycle
and then stop cycle. The operator can press Cycle Start to skip the operation, or Z
Repeat to execute the operation.
In Single Block with Single Loop off, each press of Cycle Start executes one NC program
block completely including the spindle axis machining motions, and stops at the end of
A2100Di Programming Manual
Publication 91204426-001
9
Chapter 6
May 2002
Menu
the block. With Single Loop off. Z Repeat is not active when the operation completes
normally.
With both Single Block and Single Loop on, the first press of Cycle Start moves the
machine to the operation site and then stops. Pressing Z Repeat executes the machining
steps of the cycle. Pressing Cycle Start executes the end of block functions (including
the optional W word retract) and stops again at End of Block. Thus executing each block
requires two presses of Cycle Start in this mode.
If a pattern cycle (G38 or G39) is active, Single Loop operates exactly as described
above. Single Block, however, does not stop after each operation of the pattern but
stops only when the entire pattern is completed.
The G80 series cycles are sensitive to Feedhold while in the machining portion of the
cycle. If a Feedhold occurs during the machining portion of the cycle while the spindle is
still advancing toward the bottom of the hole, the feed motion is immediately stopped.
The remainder of the motion, or motions, to the bottom of the hole are ignored, and any
bottom of hole operations (such as spindle reversal) occur immediately. The cycle then
completes the retract to the clearance plane, performing all required motions to reach
the clearance plane safely, and performs any mechanism operations required to
complete the operation.
The Feedhold is done at the clearance plane. At this point, the operator has the same
choices as when Single Loop mode is active, that is, Z Repeat can be used to reexecute the machining part of the cycle, or Cycle Start can be used to continue NC
program execution.
6.2
G80 Reset Fixed Cycle
This cycle performs the usual rapid moves from the current position to the programmed
hole location, and rapids to the clearance plane (R word) if the R word is present, but
does no spindle axis feed move and performs no spindle or dwell functions. The spindle
axis word specifying the modal hole depth or hole bottom dimension is not used by the
G80 cycle, but remains active for subsequent G80 series cycles.
Note
Unlike the other G80 series cycles, the rapid move to the clearance plane occurs only if
R is programmed.
6.3
Permissible Tool Types
All tool types
Parameters
G
R word - Modal Reference Plane dimension.
G
Spindle axis word - Modal hole depth or hole bottom dimension.
G
J word - Non-modal:
J = 1 resets all G80 series cycle parameter values to the default values (ie. all
operator changes are removed).
J = 81-89 resets the cycle parameters for the correspondingly numbered cycle.
G
K word - Modal extra retract for BACKBORE Tool Type.
A2100Di Programming Manual
Publication 91204426-001
10
Chapter 6
May 2002
Menu
Programming Considerations
G
The non-spindle axes will always be in position before any spindle axis rapid motion
will occur.
G
If a Z axis feed dimension is programmed in a block containing a G80, it is ignored
for that block, however, the Z spindle axis feed motion amount is retained for use by
subsequent G80 series blocks.
G
When a G80 is programmed with a BACKBORE type tool active, the G80 causes an
additional retraction from the R plane, by an amount specified by the K word value,
see Fig. 6.1, from either the G87 or the G80 block after all axis motion specified in
the G80 block, including the rapid to the R plane.
G
If no K word was specified by the G87 or the G80, the G87 Backbore Clearance
cycle parameter is used. This extra motion represents the distance from the cutting
edge of the backboring tool to the end of the boring bar. This additional move is
required since the tool length for backboring tools is the length to the cutting tip and
not to the end of the boring bar.
Note
A K word specified in a G80 block is Cycle Modal, and is not available for subsequent
G87 blocks
Figure 6.1 K Word
The presence of the J word on a G80 block causes the cycle parameters to be reset to
their default values. The other G80 block actions, including the move to the co-ordinates
specified in the G80 block, are not affected by the presence of a J word. When a J word
value of 1 is programmed, the Cycle Parameter table is reset to the configurable default
values. J word values of 81 - 89 and G84.1 reset just the cycle parameters associated
with the fixed cycle with the same number.
For example, G0 J82 resets only the G82 Finish Depth, G82 Finish Feed Factor, and
G82 Dwell Time Cycle Parameters. The J word causes no axis motion and does not
affect any modal values
Example
N10 G80 X4 Y4 Z-1.125 R0 S720 M3 F5$
A2100Di Programming Manual
Publication 91204426-001
11
Chapter 6
May 2002
Menu
The above block, and Fig. 6.2, show the use of a G80 Cancel Cycle.
Block N10
G M3 turns spindle on in the clockwise direction at a spindle speed of 720 rpm.
G
X and Y axes rapid to X4, Y4 inches.
G
Z axis rapids to clearance plane (gage height above zero). The Z-1.125 dimension is
not acted upon but is retained by the control.
Figure 6.2 K Word
6.4
G81 Drill Cycle
The G81 Drill Cycle is used for drilling and spot drilling.
Permissible Tool Types
UNKNOWN, DRILL, SPOT DRILL, SPOTFACE, COUNTERSINK, REAMER, BORE,
ROUGH END MILL, FINISH END MILL
Parameters
G R word - Modal Reference Plane dimension.
G
Spindle axis word - Modal hole depth or hole bottom dimension.
G
W word - Nonmodal final retract distance (overrides Gage Height).
Specific actions of the Drill Cycle G81 are:
G Non-spindle axes rapid to their commanded positions.
G
Spindle axis rapids to clearance plane (R word value + gage height).
G
Spindle axis feeds to depth.
G
Spindle axis rapid retracts to the clearance plane or to the W word value.
These steps occur in the same order every time a G81 cycle is called.
In hole depth mode, the feed distance begins at the clearance plane and extends along
the spindle axis. The feed distance is the modal spindle axis value plus gage height plus
the drill point length. The drill point length is only used if the Hole Depth Mode cycle
parameter is zero and the Tool Type is DRILL and both the Nominal Diameter and Tool
Angle are non-zero.
In Hole Bottom Mode, the feed move begins at the clearance plane and extends to the
absolute position specified by the spindle axis word plus the drill point length. The drill
point length is only used if the Hole Depth Mode cycle parameter is one and the Tool
Type is DRILL and both the Nominal Diameter and Tool Angle are non-zero.
A2100Di Programming Manual
Publication 91204426-001
12
Chapter 6
May 2002
Menu
Programming Considerations
G The non-spindle axes will always be in position before any spindle axis rapid motion
will occur.
G
The following program and Fig.6.3 show the use of a G81 Drill Cycle.
N15 G81 X4 Y1 Z-1.15 R0 S550 M3 F10
N16 Y8 W2
Block N15
G M3 turns spindle on in the clockwise direction at a spindle speed of 550 rpm.
G
X and Y axes rapid to X4, Y1 inches.
G
When Position 1 is reached, Z axis rapids to the clearance plane.
G
Z axis feeds to a depth of 1.15 inches at the programmed rate of 10 ipm. The hole
depth of 1.15 inches is increased by the drill tip length if the Hole Depth Mode cycle
parameter is one, and the Tool Type is DRILL and both the Nominal Diameter and
Tip Angle are non-zero.
G
Z axis rapid retracts to the clearance plane.
Block N16
G Y axis rapid to Y8 inches.
G
Z axis feeds to depth of 1.15 inches at the feed rate of 10 ipm.
G
Z axis rapid retracts to the W word increment of 2 inches above the R plane.
* The hole depth of 1.15 inches is increased by the drill tip length if the Hole Depth Mode
cycle parameter is one and the Tool Type is DRILL and both the Nominal Diameter and
Tip Angle are non-zero.
The tip length is:
Drill tip length = Nominal Diameter of drill
2 x tan (Tip Angle/2)
Figure 6.3 G 81 Drill Cycle
6.5
G82 Counterbore/Spot Drill with Dwell Cycle
The G82 Counterbore/Spot Drill cycle is used for drilling, counterboring, or spot drilling
operations that require a reduced feedrate at the end of the feed move, and a dwell at
the bottom of the feed move. The dwell improves finish and ensures that the full depth is
reached.
A2100Di Programming Manual
Publication 91204426-001
13
Chapter 6
May 2002
Menu
Permissible Tool Types
UNKNOWN, DRILL, COUNTERSINK SPOT DRILL, REAMER, BORE, ROUGH END
MILL, FINISH END MILL
Parameters
G R word - Modal Reference Plane dimension.
G
Spindle axis word - Modal hole depth or hole bottom dimension.
G
W word - Nonmodal final retract distance (overrides Gage Height).
G
Specific actions of the G82 cycle are:
Simultaneously rapid non-spindle axes to their commanded positions.
Rapid the spindle axis to the clearance plane (R word value + gage height).
Feed the spindle axis to the hole depth less the G82 finish depth at the programmed
feedrate.
Feed to the hole depth at the G82 Finish Feed Factor times the programmed
feedrate.
Dwell for the number of seconds specified by the G82 Dwell Time.
Rapid to the clearance plane or the W word value.
These steps occur in the same order every time a G82 cycle is called. The program
illustrated shows the use of a G82 Counter Bore cycle.
The following program, and Fig. 6.4, illustrates the use of a G82 Counterbore/Spot Drill,
assuming that the G82 Finish Feed Factor is 25% and the G82 Finish Depth is 0.1
inches.
N15 G82 X4 Y10. Z-.5 R0 S550 M3 F10
N16 Y8 W1
Block N15
G
M3 turns spindle on in the clockwise direction at a spindle speed of 550 rpm.
G
X and Y axes simultaneously rapid to X4, Y10 inches from the previous position.
G
When Position 1 is reached, Z axis rapids to the clearance plane.
G
The Z axis feeds to -0.4 inches (the programmed depth of -0.5 inches less the 0.1
inch G82 Finish Depth) at the programmed 10 ipm.
G
The Z axis continues to feed to the programmed depth of -0.5 inches at the reduced
feedrate of 2.5 ipm (25% of 10 ipm).
G
After reaching depth, the spindle dwells for the G82 Dwell Time, then Z axis rapid
retracts to clearance plane.
Block N16
G Y-axis rapid advances to Y8 inches.
G
The Z axis feeds to -0.4 inches (the programmed depth of -0.5 inches less the 0.1
inch G82 Finish Depth) at the programmed 10 ipm.
G
The Z axis continues to feed to the programmed depth of -0.5 inches at the reduced
feedrate of 2.5 ipm (25% of 10 ipm).
A2100Di Programming Manual
Publication 91204426-001
14
Chapter 6
May 2002
Menu
G
The spindle dwells for the G82 Dwell Time then rapid retracts to 1.00 inch above the
R plane as specified by W1.
Figure 6.4 Counterbore/Spot Drill with Dwell Cycle G82
6.6
G83 Deep Hole Drill (Peck Drill) Cycle
This cycle is used for drilling operations where the hole depth and workpiece material
require the drill chip to be broken or cleared from the hole during drilling.
6.6.1
Chip Breaking
Chip breaking (J = 1 or 11) is used to break chips when drilling materials that produce
continuous chips. The chip is broken by interrupting the spindle axis feed move by a
short rapid move away from the work. This action results in smaller chips.
6.6.2
Chip Clearance
Chip clearance is done by periodically rapid retracting the drill to either just below the
work surface (J = 2 or 12) or to the clearance plane (J = 3 or 13). Chip clearance by
retracting to the clearance plane (J = 3 or 13) results in more complete chip removal but
may cause difficulty when long, thin drills are used at high speed. Such a drill may tend
to whip when retracted clear of the part. This action can be avoided by using J2 or J12
for small diameter drills.
Variable peck depth (J = 1, 2, 3) feeds by three times the peck depth for the first
increment, two times the peck increment for the second increment, and by the peck
depth for all other increments. This action speeds the operation by feeding further at the
top of the hole, and reducing the feed as the depth increases and chip removal becomes
more difficult.
A2100Di Programming Manual
Publication 91204426-001
15
Chapter 6
May 2002
Menu
Permissible Tool Types
UNKNOWN, DRILL, ROUGH END MILL, FINISH END MILL. Refer to Figs. 6.5 through
6.8.
Parameters
G R word - Modal Reference Plane dimension.
G
Spindle axis word - Modal hole depth or hole bottom dimension.
G
K word - Cycle modal feed increment (default is Nominal Diameter from Tool Table).
G
W word - Nonmodal final retract distance (overrides gage height).
G
J word - Cycle modal selector for the peck and retract type:
1 = variable peck depth, chip breaking.
2 = variable peck depth, short retract chip clearance.
3 = variable peck depth, retract to clearance plane chip clearance.
11 = fixed peck depth, chip breaking.
12 = fixed peck depth, short retract chip clearance.
13 = fixed peck depth, retract to clearance plane chip clearance.
G
G83 Retract Distance, G83 Short Retract Increment, and G83 Relief Amount, are
specified by the Cycle Parameter Table. Specific actions of the G83 cycle are:
Simultaneously rapid the non-spindle axes to their commanded positions.
Rapid the spindle axis rapids to the clearance plane (R word value + gage
height).
Feed the spindle axis feeds to the programmed depth, interrupting the feed as
determined by use of the J word number as follows:
The spindle axis feeds to the programmed depth, interrupting the feed as
determined by use of the J word number as follows:
J word = 1, 2, or 3 selects variable peck depth.
Feed first feed increment amount (three times K word value) + drill point
length.
Rapid retract to break or clear chips.
Rapid to last feed depth plus relief amount for J2 and J3.
Feed second feed increment amount (two times K word value).
Rapid retract to break or clear chips.
Rapid to last feed depth plus relief amount for J2 and J3.
Feed third feed increment amount (K word value).
Repeat feed by K word increment and retract until at depth.
J word = 11, 12 or 13 selects fixed peck depth.
Feed by K word increment amount + drill point length.
Rapid retract to break or clear chips.
Rapid to last feed depth plus relief amount for J2 and J3.
A2100Di Programming Manual
Publication 91204426-001
16
Chapter 6
May 2002
Menu
Repeat feed by K word increment and retract until at depth.
J word = 1 or 11 selects chip breaking.
Feed by the selected increment.
Rapid retract by the G83 Retract Distance to break chips.
Feed by next increment.
Figure 6.5 Deep Hole Drill G83 with Fixed Tool
J word = 2 or 12 select short retract chip clearance.
Feed by selected increment.
Rapid retract to G83 Short Retract Increment following the Reference plane to clear
chips.
Rapid to a point G83 Relief Amount above the previous drilled depth.
Feed by the next increment.
Figure 6.6 Deep Hole Drill G83 Short Retract and Relief Amount
J word = 3 or 13 selects full retract chip clearance.
Feed by selected increment.
Rapid retract to clearance plane to clear chips.
Rapid to a point G83 Relief Amount above the previous drilled depth.
Feed by the next increment.
A2100Di Programming Manual
Publication 91204426-001
17
Chapter 6
May 2002
Menu
Figure 6.7 Deep Hole Drill G83 Full Retract and Short Relief
The spindle axis rapid retracts to the clearance plane or to the W word value above the
reference plane.
The following program segment illustrates the use of a G83 Deep Hole Drill Cycle with a
J1 (variable depth, chip breaking) selection for the first hole and J3 (variable depth, full
retract) selection for the second hole.
N15 G83 X4 Y10 Z-5 R0 S620 M3 F4 J1 K1 W1
N16 Y8 J3 K.85
Block N15
G M3 turns spindle on in the clockwise direction at a spindle speed of 620 rpm.
G
X and Y axes rapid simultaneously to X4, Y10 inches from the previous position.
G
Z axis rapids to clearance plane.
G
Z axis feeds to its first depth of three times the K-word value, or 3 inches plus drill
point length.
G
When the first depth is reached, Z axis rapid retracts G83 retract distance (the J1
function) then feeds in again by same amount.
G
On second feed, the hole depth is drilled twice the value of K, or two more inches,
which is the Z 5 inch hole depth.
G
When full depth is reached, Z axis rapid retracts to the 1 inch distance specified by
the W word.
Block N16
G The G83 code is reused to rapid Y axis to 8 inches to Position 2.
G
At this point, the same hole depth is drilled using the chip clearing (J3) option.
G
The K word value becomes .85, which alters the depth of each feed.
The first and second feeds are multiples of the K word, as in the previous hole, except Z
axis retracts to the clearance plane between each feed.
This action clears any chips before returning to the G83 Relief Amount above the
previous depth at the G83 Return Rate. The remainder of the hole depth is drilled in
increments equal to the K word, with a full retract between each feed.
A2100Di Programming Manual
Publication 91204426-001
18
Chapter 6
May 2002
Menu
Figure 6.8 Deep Hole Drill G83 Relief Amount and Return Rate
6.6.3
G84 Tap Cycle (Conventional)
The Conventional Tapping Cycle (G84) is used with spring-loaded floating tap holders.
Permissible Tool Types
UNKNOWN, TAP. Refer to Fig.6.9.
Parameters
G R word - Modal Reference Plane dimension.
G
Spindle axis word - Modal hole depth or hole bottom .
G
W word - Nonmodal final retract distance.
G
J word - Cycle modal retract feedrate multiplier.
G
Specific actions of the G84 Tap Cycle (Conventional) G84 are:
Rapid non-spindle axes to their commanded positions.
Rapid the spindle axis to the clearance plane (R word value + gage height).
Inhibit feedrate override.
Feed to the hole depth.
Reverse spindle and change speed to the J word value times the programmed
speed: wait for reversal to complete.
Feed to the clearance plane at the J word value times the feedrate.
Dwell by the G84 Dwell Time, then reverse the spindle and restore the feedrate
override and programmed spindle speed.
The G84 Dwell Time is specified by the Cycle Parameter Table.
Then rapid to W distance (if programmed) above the R plane.
These steps occur in the same order every time a G84 cycle is called.
A2100Di Programming Manual
Publication 91204426-001
19
Chapter 6
May 2002
Menu
Programming Considerations
G
In hole depth mode the feed distance begins at the clearance plane and extends
along the spindle axis. The feed distance is the modal spindle axis value plus gage
height.
G
In hole bottom mode, the feed move begins at the clearance plane and extends to
the absolute position specified by the spindle axis word.
G
The programmed values of feedrate and spindle speed must match the tap pitch. If
feedrate mode is Feed Per Tooth (G95), the feedrate is just the thread pitch. If the
feedrate mode is Feed Per Minute (G94), the feedrate must be the spindle RPM
times the tap pitch.
G
The programmed depth must take into account the number of spindle revolutions
that occur after the reversal is commanded. This value varies with spindle speed and
from machine to machine, and may require experimentation to establish the best
value.
G
As proper tapping requires that the spindle and the spindle axis feedrate be
maintained in the proper relationship, the G84 cycle automatically disables feedrate
override. Spindle speed override is allowed. In feed per tooth (G95) mode the
feedrate is driven by the spindle speed directly and therefore remains proportional to
the spindle speed. In feed per minute (G94) mode, both the spindle speed and
feedrate are overridden by the spindle speed override amount to achieve the desired
thread.
G
The feed out part of the cycle is performed at the programmed spindle speed times
the J word value. A J word value less than one results in the feed out being
performed at the programmed spindle speed. A J word value greater than one
allows for a faster retraction.
G
The G84 Dwell Time is specified by the Cycle Parameter table.
The following program, and Fig. 6.9, illustrates the use of the Conventional G84 tap
cycle. This example assumes a 1/4 - 20 tap with a 3 thread chamfer is used.
N15 G84 J2 X4 Y10 Z-.626 R0 S200 M3 F10
N16 Y8 W1.5
Block N15
G M3 turns spindle on in the clockwise direction at a spindle speed of 200 rpm.
G
X and Y axes rapid simultaneously to X4, Y10 inches from the previous position.
G
Z axis rapids to clearance plane.
G
Z axis feeds to -.626 inches, at 10 ipm.
G
The programmed depth for the Z axis in this example was calculated as follows:
Z Position =
Depth to be tapped + Tap Chamfer x Pitch - Revolutions for Reversal x Pitch
This example is based on 1/4-20 tap with 3 thread chamfer.
Therefore: Pitch
A2100Di Programming Manual
Publication 91204426-001
= 1/Threads per inch
= 1/20
= 0.05 inches
20
Chapter 6
May 2002
Menu
Z Position:
G
= 0.500 + (3 x 0.050) - (0.48 x 0.050)
= 0.500 + 0.150 - 0.024
= 0.626
The feedrate for the example was computed as follows:
Feedrate
= (RPM x Pitch) ipm
= 200 x 0.05”
= 10 ipm
When the programmed depth is reached spindle rotation is reversed and Z axis feed
retracts to clearance plane. Since J2 is programmed, feedrate and spindle speed are
doubled during retraction.
J2 x S200 = S400
J2 x F10 = F20
When clearance plane is reached a dwell will occur, then spindle rotation is reversed to
the previous direction at the programmed rate of 200 RPM.
Block N16
G The G84 code is reused to rapid Y-axis to 8 inches to Position 2.
G
Z axis feeds to programmed depth, as before.
G
When depth is reached spindle rotation is reversed and Z axis feed retracts to the
clearance plane then rapid retracts to W1.5 inches.
Figure 6.9 Conventional Tap Cycle G84
6.7
G84.1Tap Cycle (Rigid)
This fixed cycle allows the use of rigid tap holders, providing precise thread cutting and
hole depth control while eliminating the need for expensive floating tap holders. The
thread is cut by controlling the rotation of the spindle and the motion of the spindle axis
synchronously such that the required thread is cut. This provides very accurate and
repeatable depth control and thread form.
The Rigid Tap Cycle also provides the chip breaking function.
Programming is compatible with the conventional Tap Cycle. Rigid Tapping is selected
by programming a G84.1 in place of the G84 for conventional tapping.
A2100Di Programming Manual
Publication 91204426-001
21
Chapter 6
May 2002
Menu
Permissible Tool Types
UNKNOWN, TAP, RIGID TAP.
Parameters
G R word - Modal Reference Plane dimension.
G
Spindle axis word - Modal hole depth or hole bottom dimension.
G
W word - Nonmodal final retract distance.
G
J word - Cycle modal retract feedrate multiplier.
G
K word - Cycle modal feed increment along spindle axis for chip breaking.
G
P word - Cycle modal number of reverse spindle revolutions to break the chips.
G
Specific actions of the G84.1 Tap Cycle (Rigid) are:
Rapid non-spindle axes to their commanded positions.
Rapid the spindle axis to the clearance plane (R word value + gage height).
Stop the spindle.
Feed to hole depth, co-ordinating spindle rotation and spindle axis advance. If the K
and P words are established, the feed is interrupted each time the K word increment
is reached.
If the K word is absent or zero, no peck feed is performed and the P word is ignored.
If the K word is nonzero and the P word is absent or zero, the G84 Chip Break
Spindle Rev. value from the Cycle Parameters Table is used.
Reverse spindle and feed synchronously at bottom of the hole.
Feed to clearance plane.
Rapid to the W distance (if programmed).
These steps occur in the same order every time a G84.1 cycle is called.
Programming Considerations
G In hole depth mode the feed distance begins at the clearance plane and extends
along the spindle axis. The feed distance is the modal spindle axis value plus gage
height.
G
In hole bottom mode, the feed move begins at the clearance plane and extends to
the absolute position specified by the spindle axis word.
G
The control computes the tap pitch from the programmed (or modal) values of
spindle speed and feedrate. In Feed Per Tooth (G95), the pitch is simply the
feedrate in feed per revolution. In Feed Per Minute mode, the pitch is the feedrate
divided by the spindle RPM. The actual tapping feedrate is determined by the
specified spindle RPM. Since the feedrate and spindle speed are controlled
synchronously, feedrate override is permitted for Rigid Tapping cycles. The spindle
direction is required to allow the Rigid Tap cycle to produce the correct thread
direction. The spindle must either be running in the proper direction before the G84.1
cycle is programmed, or the G84.1 block must contain a Spindle Start M code (M3,
M4 M13 or M14) to specify the thread direction.
G
During the feed to depth portion of the cycle, the spindle and spindle axis are moved
such that the spindle rotates at the specified RPM and the spindle axis advances at
the proper rate based on the tap pitch. The spindle stops at the bottom of the hole,
A2100Di Programming Manual
Publication 91204426-001
22
Chapter 6
May 2002
Menu
and reverses for the feed out motion. The feed out part of the cycle is performed at
the programmed rate times the J word value. A J word value less than one results in
the feed out being performed at the programmed rate. A J word value greater than
one allows for a faster retraction. If the J word multiplier results in a speed greater
than the maximum Rigid Tapping Spindle Speed, the maximum speed is used.
G
The Rigid Tap Cycle may be specified with a peck feed increment in the K word.
This interrupts the tap motion by reversing the spindle to break the chip and reduce
the load on the tap. The Rigid Tap Peck Feed cycle is identical to the normal Rigid
Tap cycle except that the feed to depth is interrupted after the peck feed increment
is completed. The spindle is reversed for the number of full rotations specified in the
P word, then the feed resumed. This continues until the programmed depth is
achieved.
G
If the K word is absent or zero, no peck feed is performed and the P word is ignored.
If the K word is nonzero and the P word is absent or zero, the G84 Chip Break
Spindle Revs value from the Cycle Parameter Table is used.
The following program, and fig. 6.10, illustrates the use of the Rigid G84.1 tap cycle This
example assumes that a 1/4 - 20 tap with a 3 thread chamfer is used.
N15 G84.1 J2 X4 Y10 Z-.650 R0 S200 M3 F10
N16 Y8 W1.5
Block N15
G X and Y axes rapid simultaneously to X4, Y10 inches from the previous position.
G
Z axis rapids to clearance plane.
G
Z axis feeds to -.650 inches, at 10 ipm. The spindle rotation co-ordinate and spindle
axis feedrate in order to produce precisely the correct lead.
The programmed depth for the Z axis in this example was calculated as follows:
Z Position = Depth to be tapped + Tap Chamfer x Pitch
This example is based on 1/4-20 tap with 3 thread chamfer. Pitch is 1/20.
Therefore: Pitch
= 1/Threads per inch.
= 1/20
= 0.050 inches
Z Position:
= 0.500 + (3 x 0.050)
= 0.500 + 0.150
= 0.650
When depth is reached, the spindle and spindle axis feed are stopped and then
reversed. When the clearance plane is reached, the spindle and spindle axis stop. Since
J2 is programmed, feedrate and spindle speed are doubled during retraction.
Block N16
The G84.1 code is reused to rapid Y-axis to 8 inches to Position 2.
Z axis feeds to programmed depth, as before.
When depth is reached spindle rotation is reversed and Z axis feed retracts to the
clearance plane, then rapid retracts to W1.5 inches.
A2100Di Programming Manual
Publication 91204426-001
23
Chapter 6
May 2002
Menu
Figure 6.10 Tap Cycle (Rigid) G84.1
6.8
G85 Bore/Ream Cycle
Bore/Ream Cycle (G85) is similar to the Drill Cycle (G81) except the tool is fed to depth
and then fed back to the clearance plane.
Permissible Tool Types
UNKNOWN, ROUGH END MILL, REAMER, BORE .
Parameters
G R word - Modal reference plane dimension.
G
Spindle axis word - Modal hole depth or bottom dimension.
G
W word - Non-modal final retract distance.
G
Specific actions of the Bore/Ream Cycle G85 are:
Rapid all non-spindle axes to their programmed positions.
Rapid the spindle axis to the clearance plane (R word value + gage height).
Feed to the hole depth.
Feed to the clearance plane then.
Rapid to the W word distance above the R plane.
In hole depth mode the feed distance begins at the clearance plane and extends
along the spindle axis. The feed distance is the modal spindle axis value plus
gage height.
In hole bottom mode, the feed move begins at the clearance plane and extends to
the absolute position specified by the spindle axis word.
These steps occur every time a G85 cycle is called.
The program fragment and Fig.6.11 show the use of a G85 Bore/Ream Cycle.
N15 G85 X4 Y10 Z-1.05 R0 S620 M3 F4
N16 Y8 W2
A2100Di Programming Manual
Publication 91204426-001
24
Chapter 6
May 2002
Menu
Block N15
G
M3 turns spindle on in the clockwise direction at a spindle speed of 620 rpm.
G
X and Y axes rapid simultaneously to X4,Y10 inches from the previous position.
G
Z axis rapids to clearance plane.
G
Z axis feeds to -1.05 inches, at 4. ipm.
G
After reaching depth, Z-axis retracts to clearance plane at the 4 ipm feedrate.
Block N16
G The G85 code is reused to rapid Y-axis to 8 inches.
G
Z axis feeds to programmed depth at the previously programmed rate.
G
After reaching depth, Z axis feed retracts to clearance plane and then rapid positions
to 2 inches.
Figure 6.11 Bore/Ream Cycle G85
6.9
G86 Bore Cycle, Dead Spindle Retract
This cycle is used to machine a hole using a single point boring bar, and rapid retract the
tool without leaving a drag line. To eliminate drag lines, U and V words are used to
specify direction (U for X axis, V for Y axis) and amount the tool tip is shifted before
retraction takes place. The J word specifies the angle at which the tool point stops before
the tool retract move.
Permissible Tool Types
UNKNOWN, BORE, DRILL, REAMER.
Parameters
G R word - Modal reference plane dimension.
G
Spindle axis word - Modal depth of cut from the worksurface.
G
W word - Non-modal final retract distance.
G
U word - Cycle modal X increment to allow tool tip to clear the work (invalid with tool
type DRILL, REAMER, ROUGH END MILL, and FINISH END MILL, see CAUTION).
A2100Di Programming Manual
Publication 91204426-001
25
Chapter 6
May 2002
Menu
CAUTION
The U and V words must be used only with single point tools since they move the
tool from the hole centreline while the tool is inside the workpiece.
Ensure that the tool is mounted at the correct orientation in the spindle and
sufficient clearance exists on the non-cutting side of the boring bar. Otherwise, U
and V offset words could produce an interference condition.
Failure to heed this Caution may result in damage to equipment.
G
V word - Cycle modal Y increment to allow tool tip to clear the work (invalid with tool
type DRILL, REAMER, ROUGH END MILL, and FINISH END MILL).
G
J word - Cycle modal orient angle specifying the tool point stop angle; default is
zero.
G
Specific actions of the Bore Cycle Dead Spindle Retract G86 are:
Rapids the non-spindle axes to their commanded positions.
Rapids the spindle axis to the clearance plane.
Feed the spindle axis to depth.
Feed retract toward the clearance plane from the hole bottom, by the G86 Bottom
Retract Distance value in the Cycle Parameter Table.
Stop the spindle and coolant (this is an oriented stop at the angle specified by the
J word).
Rapid retract X and Y axes by the incremental U and V amounts, if programmed.
Rapid retract the spindle axis to clearance plane.
Rapid advance the X and Y axes by the incremental U and V amounts, (if
programmed) to place the tool at the XY location at the start of the spindle axis
portion of the cycle.
Rapid to the W word value (if programmed).
These steps occur in the same order every time a G86 cycle is called.
In hole depth mode the feed move begins at the clearance plane and extends along
the spindle axis. The feed distance is the spindle axis word value plus gage height.
In hole bottom mode the feed move begins at the clearance plane and extends to the
absolute position specified by the spindle axis word.
Control of the tool tip angle when the spindle stops at the bottom of the hole is
provided by the J word, which allows the tip to be placed at any orientation to take
advantage of a keyway. The Tool Data Tip Angle field for boring bars specifies the
angle of the tool tip, measured counterclockwise from the zero orientation position to
the tool tip, looking from the spindle to the work. When the tool is oriented by the fixed
cycle the Tip Angle is subtracted from the specified angle.
The following program fragment, and Fig.6.12, show the use of a G86 Bore Cycle.
: G0 T1 M6
N15 G86 X4 Y10 Z-1.05 R0 J90 V-.02 S620 M3 F4
N16 Y8 W2
N17 G80 M2
A2100Di Programming Manual
Publication 91204426-001
26
Chapter 6
May 2002
Menu
The Block
G : Provides Synchronisation of the control system.
G
G0 code sets Linear Rapid Interpolation.
G
T1 is tool selection for M6 tool change.
Block N15
G M3 turns spindle on in the clockwise direction at a spindle speed of 620 rpm.
G
X and Y axes rapid simultaneously to X4, Y10 inches from the previous position.
G
Z axis rapids to the clearance plane.
G
Z axis feeds to -1.05 inches, at 4. ipm.
G
After reaching the programmed depth, the spindle axis retracts by the G86 Bottom
Retract Distance. The spindle stops at an angle of 90º, leaving the tool pointing in
the + Y direction. Then the Y axis moves by -0.200 inches as specified by V -.02 to
bring the tool tip away from the part surface.
G
Following the tool tip offset move, Z rapid retracts to the clearance plane, then the Y
axis positions +0.020 inches to return the spindle centreline to X4, Y10 inches.
G
The spindle restarts clockwise at 620 RPM and coolant restarts.
Block N16
G The G86 code is reused to rapid Y-axis to 8 inches and the cycle is repeated.
G
Z axis feeds to programmed depth at the previously programmed rate.
G
After reaching the programmed depth, the spindle axis retract by the G86 Bottom
Retract Distance. The spindle again stops at the 90º position. Then the Y axis moves
by -0.200 inches as specified by V -.02 to bring the tool tip away from the part
surface.
Note
Following the tool tip offset move, Z rapid retracts to the clearance plane, then the Y
axis positions +0.020 inches to return the spindle centreline to X4, Y10 inches.
G
Restart spindle and coolant.
G
Retract Z axis to 2 inches.
Block N17
G G80 cancels G86.
G
M2 fully retracts Z axis and ends program.
A2100Di Programming Manual
Publication 91204426-001
27
Chapter 6
May 2002
Menu
Figure 6.12 Bore/Ream Cycle G86
Figure 6.13
6.10
Bore/Ream Cycle G85
G87 Back Bore Cycle
Back Bore Cycle (G87) see fig. 6.14, is used when it is required for a boring bar to pass
through a clearance hole, move to a cutting position, and machine back towards the
spindle nose.
From programmed information the control establishes the thickness of the workpiece
and two reference planes, one at the surface nearer the spindle and one at the surface
away from the spindle. The cycle passes the tool through a pre-existing hole to a point
clear of the lower surface of the part. Next, the tool is moved back to the centreline of the
hole and the operation is performed.
It is the programmers responsibility to ensure that there is sufficient clearance below the
hole for the boring bar head to pass through. Also, it is essential that correct orientation
of the cutter in the spindle exists so that U and V offset dimensions can position the tool
through the initial clearance hole.
Permissible Tool Types
UNKNOWN, BACKBORE.
A2100Di Programming Manual
Publication 91204426-001
28
Chapter 6
May 2002
Menu
CAUTION
Ensure that the tool is mounted at the correct orientation in the spindle and
sufficient clearance exists on the non-cutting side of the boring bar. Otherwise, U
and V offset words could produce an interference condition.
Failure to heed this Caution may result in damage to equipment.
Parameters
G R word - Modal reference plane dimension.
G
Spindle axis word - Modal depth of cut from the worksurface or hole bottom
dimension.
G
I word - Cycle modal unsigned workpiece thickness.
G
J word - Cycle modal orient angle to specify the angle at which the tool is to stop; the
default angle is zero.
G
K word - Cycle modal distance from the end of the boring bar to the cutting tip of the
tool.
Note
If the K word is not programmed, the G87 Backbore Clearance value in the Cycle
Parameters Table is used.
G
W word - Non-modal final retract distance.
G
U word - Cycle modal incremental X axis dimension measured from bore centreline
to the position where the boring bar can pass through the existing hole.
G
V word - Cycle modal incremental Y axis dimension measured from bore centreline
to the position where the boring bar can pass through existing hole.
Note
At least one of U or V is required to be non-zero to allow the tool to enter the hole.
A2100Di Programming Manual
Publication 91204426-001
29
Chapter 6
May 2002
Menu
Figure 6.14 Back Bore Cycle G87
The specific actions of the G87 cycle are:
Rapid non-spindle axes to their commanded position.
G Rapid the spindle axis to place end of boring bar at upper clearance plane (R word
value + gage height + K word).
G Stop and orient the spindle at the angle specified by the J word minus the Tool Tip
angle from the tool data.
G Offset X and Y axes by U and V dimensions at rapid traverse rate.
G Rapid the spindle axis to the lower clearance plane, using the programmed I + K +
twice gage height dimensions.
G Rapid X and Y back to hole centreline.
G Start spindle and coolant.
G Feed the spindle axis to depth (toward the spindle).
G Dwell for G87 dwell time.
G Feed retract the spindle axis away from the spindle by the G87 Bottom Retract
Distance.
G Stop and orient spindle at the angle specified by the J word minus the Tool Tip angle
from the tool data.
G Offset X and Y axes by U and V dimensions at rapid traverse rate.
G Rapid the spindle axis to upper clearance plane (above workpiece) or to W distance
if programmed.
G Cancel X and Y axis offset by U and V dimensions.
These steps occur in the same order every time a G87 cycle is called.
G
A2100Di Programming Manual
Publication 91204426-001
30
Chapter 6
May 2002
Menu
Programming Considerations
G Non spindle axes will always be in position before any spindle axis rapid motion will
occur.
G
Always ensure enough Backbore nose extension clearance exist below the part.
G
At least one U or V word must be used to offset cutter.
G
Always ensure correct offset clearance exist before attempting to clear a bore.
G
The following sample program, and Figs. 6.15 and 6.16. illustrate how a Backbore
cycle can be used to machine a 2.0 inch diameter groove .25 inch in depth.
Positions in the explanation refer to the Figs. following the example.
This example assumes the following specifications
G Tool data table information is entered.
G
Clearance exists for the Boring Tool Nose Extension.
G
Spindle Orientation will position the tool in the -X direction.
G
Z cut depth will be Z .25 inch from the part surface.
Figure 6.15 Back Bore Cycle G87
Example
G0 T1 M6
N15 G87 X4 Y10 Z.25 R0 I1 K.5 U+.25 S620 M3 F4
N16 Y8 W2
N17 G80 M2
The Block
G Provides Synchronisation of the control system.
G
G0 code sets Linear Rapid Interpolation.
G
T1 is tool selection for M6 tool change.
Block N15
G M3 turns spindle on in the clockwise direction at a spindle speed of 620 rpm.
A2100Di Programming Manual
Publication 91204426-001
31
Chapter 6
May 2002
Menu
G
Position 1, X and Y axes rapid simultaneously to X4, Y10 inches from the previous
position. Then Z axis rapids to clearance plane (above workpiece).
G
Spindle is stopped and oriented.
G
Position 2, X axis rapid offsets .25 inch in the plus direction.
G
Position 3, Z axis rapids in the minus direction to lower clearance plane.
G
I 1.0” + K .5” + .100” Gage height = -1.6
G
Position 4, X axis rapid offsets .25 inch in the minus direction.
G
Spindle and coolant are started.
G
Position 5, Z axis feeds in plus direction gage height plus .25 inches, at 4 ipm.
G
After Z axis depth is reached a dwell occurs for chip clearing.
G
Position 6, Z axis feeds in - direction by the G87 Bottom Retract Distance.
G
Spindle and coolant are stopped.
G
Position 7, X axis rapid offsets .25 inch in the plus direction.
G
Position 8, Z axis rapid retracts (+ direction) to upper clearance plane.
G
Position 9, X axis rapid offsets .25 inch in the minus direction.
Block N16
G The G87 code is reused to rapid Y axis 8 inches and the cycle is repeated.
G
After cycle is completed, Z axis rapid retracts (+ direction) to 2 inches above the
upper reference plane + K word.
Block N17
G80 cancels G87.
G
G
M2 ends program.
A2100Di Programming Manual
Publication 91204426-001
32
Chapter 6
May 2002
Menu
CAUTION
Ensure that the tool is mounted at the correct orientation in the spindle and that
sufficient clearance exists on the non-cutting side of the boring bar. Otherwise, U
and V offset words could produce an interference condition.
Failure to heed this Caution may result in damage to equipment.
Figure 6.16 Backbore Cycle G87
A2100Di Programming Manual
Publication 91204426-001
33
Chapter 6
May 2002
Menu
6.11
G88 Web Drill/Bore Cycle
This cycle, see Figs 6.17 and 6.18, is used when it is required to machine two in-line
holes, making a rapid movement between them. This is useful for drilling through both
sides of a hollow part. Programmed information specifies the upper and lower clearance
planes and reference planes.
If the active tool has a type Boring Bar then the cycle can optionally include a tip shift for
drag line elimination. In this case, the spindle is stopped at the bottom of the hole to
allow for the tip shift before the retract move.
Figure .6.17 Web Drill/Bore Cycle G88
Figure 6.18 Web Drill/Bore Cycle G88
Note
Do not use U and V offsets with boring bars having more than one cutter.
Permissible Tool Types
UNKNOWN, DRILL, REAMER, BORE, END MILL, CENTRE CUTTING END MILL.
A2100Di Programming Manual
Publication 91204426-001
34
Chapter 6
May 2002
Menu
Parameters
G R word - Modal reference plane dimension.
G
Spindle axis word - Modal depth or hole bottom dimension.
G
I word - unsigned cycle modal distance between the bottom of the upper hole and
the lower reference plane.
G
J word - cycle modal orient angle to specify the angle at which the tool is to stop;
default is zero.
G
K word - unsigned cycle modal upper hole depth measured from the upper
clearance plane.
G
W word - non-modal final retract distance (overrides gage height).
G
U word - cycle modal X increment to allow tool tip to clear the work.
G
V word - cycle modal Y incremental to allow tool tip to clear the work.
G
Specific actions of the Web Drill/Bore Cycle G88 are:
Rapid the non-spindle axes simultaneously to their commanded position.
Rapid the spindle axis to the upper clearance plane (R word value + gage height).
Feed the spindle axis to depth specified by K-word, plus gage height, plus drill
point length (drill only), plus G88 Breakthrough Distance.
Rapid the spindle axis to the lower clearance plane (R - K - I + gage height).
Feed the spindle axis to the programmed depth + drill point length(drill only).
Stop spindle and coolant at the angle specified by the J word (if tool type is
BORE, UNKNOWN, or SPECIAL).
Offset X and Y axis by U and V dimensions if programmed and tool type is BORE,
UNKNOWN, or SPECIAL.
Rapid retract the spindle axis to upper clearance plane.
Cancel U and V offsets. Restart spindle and coolant if stopped.
Rapid the spindle axis the additional W-distance if programmed.
These steps occur in the same order every time a G88 cycle is called.
The lower clearance plane is derived from the K word value and the I word value. The I
word specifies the distance from the bottom of the upper hole to the top of the lower
work surface. The lower clearance plane location is the R word value minus the K word
value, minus the I word value, plus the gage height.
The K word specifies the upper hole depth and is drilled to the K word depth, plus the
drill point length, plus the G88 Breakthrough Distance. The drill point length is only used
if the Tool Type is DRILL and both the Nominal Diameter and Tool Angle are non-zero
and the Hole Depth Cycle Parameter is zero or one.
In hole depth mode the second feed distance begins at the lower clearance plane and
extends along the spindle axis. The feed distance is the modal spindle axis value, plus
gage height, plus the drill point length, minus the I word value, minus the K word value.
In hole bottom mode, the second feed move begins at the lower clearance plane and
extends to the absolute position specified by the spindle axis word plus the drill point
length. In either case, the drill point length is only used if the Tool Type is DRILL and
both the Nominal Diameter and Tool Angle are non-zero and the Hole Depth Cycle
Parameter is zero or one
A2100Di Programming Manual
Publication 91204426-001
35
Chapter 6
May 2002
Menu
The G88 Breakthrough Distance is specified in the Cycle Parameter Table. This distance
is added to the programmed upper hole depth to ensure that the drill passes completely
through the upper web of the part.
Figure 6.19 Web Drill/Bore Cycle G88
The program and Figs. 6.19 and 6.20show how a G88 cycle functions with a boring bar
tool.
G0 T1 M6
N10 G88 X4 Y10 Z-2.5 R0 I.5 J135U.1 V.1 K.512 S620 M3 F4
N11 Y8 W2
N12 G80 M2
The Block
G Provides Synchronisation of the control system.
G
G0 code sets Linear Rapid Interpolation.
G
T1 is tool selection for M6 tool change.
Block N10
G M3 turns spindle on in the clockwise direction at a spindle speed of 620 rpm.
G
X and Y axes rapid simultaneously to X4, Y10 inches from the previous position.
G
Z axis rapids to clearance plane.
G
Z axis feeds to depth 0.512 inches plus Gage Height, plus breakthrough distance at
4. ipm.
G
When K depth is reached the Z axis rapids to lower clearance plane.
G
Z axis feeds 1.48 inches plus Gage Height.
G
Spindle and coolant are stopped with the Spindle at 135 degrees.
G
X offsets .1 inch in the plus direction, and Y offsets .1 inch in the plus direction.
G
Z axis retracts to the upper clearance plane.
G
X and Y each offset -.1 inch.
G
The spindle and coolant restart.
A2100Di Programming Manual
Publication 91204426-001
36
Chapter 6
May 2002
Menu
Block N11
G The G88 code is reused to rapid Y axis to 8 inches (plus direction).
G
Cycle execution takes place as previously described.
G
After reaching final depth, Z axis rapid retracts to clearance plane, restarts spindle
and coolant, unshifts tip by U and V, and retracts 2 inches.
Block N12
G G80 cancels G88.
G
M2 ends program.
Figure 6.20 Web Drill/Bore Cycle G88
6.12
G89 Bore/Ream Cycle with Dwell Cycle
Bore/Ream with Dwell Cycle (G89) is identical to Bore/Ream Cycle (G85) with the
addition of a dwell at the bottom of the hole.
Permissible Tool Types
UNKNOWN, REAMER, BORE, END MILL, CENTRE CUTTING END MILL, FINISH END
MILL.
Parameters
G R word - Modal Reference Plane dimension.
G
Spindle axis word - Modal hole depth.
G
W word - Non-modal final retract distance.
G
Specific actions of the Bore Ream Cycle with Dwell Cycle (G89) are:
Rapid non-spindle axes to their commanded positions.
Rapid the spindle axis to the clearance plane.
A2100Di Programming Manual
Publication 91204426-001
37
Chapter 6
May 2002
Menu
Feed the spindle axis to depth.
Dwell for G89 Dwell Time value in the Cycle Parameters Table.
Feed the spindle axis to the clearance plane.
Rapid W distance from the R plane if W is programmed.
The following program, and Fig.6.21, show the use of a G89 dwell cycle.
N15 G89 X4 Y10 Z-.5 R0 S650 M3 F10 W1
N16 Y8
Block N15
G M3 turns spindle on in the clockwise direction at a spindle speed of 650 rpm.
G
X and Y axes rapid to X4, Y10 inches from the previous position.
G
Z axis rapids to the clearance plane.
G
Z axis feeds to -.5 inches.
G
After Z axis feed is complete a dwell occurs.
G
After dwell terminates, Z axis feeds to clearance plane, then rapids W1 inch above
the R plane.
Block N16
G The G89 code is reused to rapid Y axis to 8 inches to Position 2.
G
Z axis rapids to the clearance plane.
G
Z axis feeds to programmed depth and dwell.
G
After dwell terminates, Z axis rapids to clearance plane.
Figure 6.21 Bore Ream Cycle/Dwell Cycle G89
A2100Di Programming Manual
Publication 91204426-001
38
Chapter 6
May 2002
Menu
Drilling Example (Fig 6.22)
Figure 6.22 Drilling Example
G
:G0 G90 G40 G77 G17 G94 ; Establish program settings.
G
T1 M6 ; Tool change line - 8mm Drill.
G
(MSG, Drill 3 Holes Through').
G
G0 G90 G40 G71 G17 G94 ; Safety default line.
G
X20 Y20 Z100 S1000 H01 M3 ; Absolute Rapid to start point.
G
Z5 ; Absolute Rapid to a position above material.
G
G81 X20 Y20 Z-22.5 R0 W25 F200 M8 ; Drill Feed to required depth at R0 then
retract additional.
G
; 25mm for next hole (pre-calculated drill tip length of 2.5mm).
G
X50 Y35 Z-42.5 R20 ; Move to next hole position redefining the new R plane and Z
depth.
G
X80 Y20 Z-20 R0 ; Move to final hole position redefining the new R plane and Z
depth. G80 R0 M9.
G
; Cancel the drilling cycle.
G
G0 Z100 ; Move to a safe height above material.
G
M2 ; End Program.
A2100Di Programming Manual
Publication 91204426-001
39
Chapter 6
May 2002
Menu
Drilling Example Using Programmed Drill Set-up (Fig. 6.23)
Figure 6.23 Drilling Example Using Programmed Drill Setup
G
: G0 G90 G40 G71 G17 G94 ; Safety default line.
G
[$TOOL_DATA(1)NOM_DIA]= 8 ; Setup drill Nominal Diameter.
G
[$TOOL_DATA(1)TIP_ANGLE]=118 ; Setup drill tip angle.
G
[$TOOL_DATA(1)TYPE]= 10 ; Setup TYPE as Drill.
G
[$CYCLE_PARAMS(2)HOLE_DEPTH]= 1 ; Incremental depth including drill point.
G
:T1 M6 ; Tool change line - 8mm Drill.
G
(MSG, Drill 3 Holes Thru’)
G
X20 Y20 Z100 H01 S1000 M3 ; Absolute Rapid to start point.
G
Z5 ; Absolute Rapid to a position above material.
G
G81 X20 Y20 Z-20 R0 W25 F200 M8 ; Drill Feed to required depth at R0 then ;
retract additional 25mm for next hole.
G
X50 Y35 Z-40 R20 ; Move to next hole position redefining the new “R” plane and Z
depth.
G
X80 Y20 Z-20 R0 ; Move to final hole position redefining the new R plane and Z
depth.
G
G80 R0 J1 M9 ; Cancel the drilling cycle and reset Cycle Parameters Table with J.
G
G0 Z100 ; Move to a safe height above material.
G
M2 ; End Program.
A2100Di Programming Manual
Publication 91204426-001
40
Chapter 6
May 2002
Menu
Tapping Example (Fig. 6.24)
Figure. 6.24 Tapping Example
G
:T2 M6 ; Tool change line - M10 x 1.5 Tap.
G
(MSG, Tap 3 Holes Through’).
G
G0 G90 G40 G71 G17 G95 ; Safety default line (G95 setting Tapping feed ).
G
X20 Y20 Z100 H01 S300 M3 ; Absolute Rapid to start point.
G
Z5 ; Absolute Rapid to a position above material.
G
G84.1 X20 Y20 Z-25 R0 W25 F1.5 M8 ; Tap Feed (FEED / Pitch) to required depth
at R0 then retract additional 25mm for next hole (pre-calculated Tap Lead length of
5mm).
G
X50 Y35 Z-40 R20 ; Move to next hole position redefining the new R plane and Z
depth
G
X80 Y20 Z-20 R0 ; Move to final hole position redefining the new R plane and Z
depth.
G
G80 R0 M9 ; Cancel the Tapping cycle.
G
G0 Z100 ; Move to a safe height above material.
G
M30 ; End program returning tool from spindle to magazine.
A2100Di Programming Manual
Publication 91204426-001
41
Chapter 6
May 2002
Menu
Tapping Example Using Programmed Tap Setup (Fig. 6.25)
Figure 6.25 Tapping Example Using Programmed Tap Setup
G
: G0 G90 G40 G71 G17 G95 ; Safety default line (G95 setting Tapping feed ).
G
[$TOOL_DATA(2)TEETH]= 1 ; Setup Number of Teeth.
G
[$TOOL_DATA(2)TIP_ANGLE]=118 ; Setup tap tip angle.
G
[$TOOL_DATA(2)TYPE]= 15 ; Setup TYPE as Rigid Tap.
G
[$CYCLE_PARAMS(2)HOLE_DEPTH]= 1 ; Incremental depth including tap point.
G
T2 M6 ; Tool change line - M10 Tap
G
(MSG, Tap 3 Holes Through’)
G
X20 Y20 Z100 H01 S300 M3 ; Absolute Rapid to start point.
G
Z5 ; Absolute Rapid to a position above material.
G
G84.1 X20 Y20 Z-20 R0 W25 F1.5 M8 ; Tap Feed to required depth at R0 then
retract additional ;
G
25mm for next hole (“F” PROGRAMMED AS PITCH “F” = 1 x 1.5 = 1.5mm per
revolution)
G
X50 Y35 Z-40 R20 ; Move to next hole position redefining the new R plane and Z
depth
G
X80 Y20 Z-20 R0 ; Move to final hole position redefining the new “R” plane and Z
depth.
G
G80 R0 J1 M9 ; Cancel the drilling cycle and reset “Cycle Parameters Table with J.
G
G0 Z100 ; Move to a safe height above material.
G
M30 ; End program returning tool from spindle to magazine.
A2100Di Programming Manual
Publication 91204426-001
42
Chapter 6
May 2002
Menu
Hole Making Cycles Main Example (Fig. 6.26)
Figure 6.26 Hole Making Cycles
G
T1 = 25mm x 90 Degree Spot drill.
G
T2 = 8.5mm drill.
G
T3 = M10 x 1.5 Pitch tap.
G
T4 = 9.2mm drill.
G
T5 = 10mm Reamer.
G
T6 = 3/4” Slot drill.
G
T7 = 20mm Boring Bar - Tip faces Spindle Drive Dog.
G
:T1 M6 ;T1 = 25mm x 90 deg. SPOT DRILL.
;ASSUMING X and Y DATUM TO BE TOP LEFT CORNER AND Z TOP OF JOB
G0 G90 G71 G17 G40 G94
X25 Y-25 Z100 H01 S400 M3
Z-15
G82 Z-6 R-20 F60 M8
G91 X50 W25
X50 R0 W25
X50
Y-50
X-50
X-50 R-20 W25
X-50 W25
G90 X50 Y-50 Z-11 F W25
A2100Di Programming Manual
Publication 91204426-001
43
Chapter 6
May 2002
Menu
X150 R0
G80 R0
G90 G0 Z100
:T2 M6 ;T2 = 8.5mm DRILL
G0 G90 G71 G17 G40 G94
X25 Y-25 Z100 H01 S1000 M3
Z-15
G81 Z-27.4 R-20 F200 M8
G91 X50 W25
X50 R0 W25
X50
Y-50
X-50
X-50 R-20 W25
X-50
G80 R-20
G90 G0 Z100
:T3 M6 ;T3 = M10 x 1.5 Pitch TAP
G0 G90 G71 G17 G40 G95
X25 Y-25 Z100 H01 S300 M3
Z-15
G84.1 Z-20 R-20 F1.5 M8
G91 X50 W25
X50 R0 W25
X50
Y-50
X-50
X-50 R-20 W25
X-50
G80 R-20
G90 G0 Z100
:T4 M6 ;T4 = 9.2mm DRILL
G0 G90 G71 G17 G40 G94
X50 Y-50 Z100 H01 S800 M3
Z-15
G83 Z-50 R-20 W25 J13 K5 F160 M8
A2100Di Programming Manual
Publication 91204426-001
44
Chapter 6
May 2002
Menu
X150 Z-70 R0
G80 R0
G90 G0 Z100
:T5 M6 ;T5 = 10mm REAMER
G0 G90 G71 G17 G40 G94
X50 Y-50 Z100 H01 S450 M3
Z-15
G89 Z-50 R-20 W25 F200 M8
X150 Z-70 R0
G80 R0
G90 G0 Z100
:T6 M6 ;T6 = 3/4” SLOTDRILL
G0 G90 G71 G17 G40 G94
X50 Y-50 Z100 H01 S500 M3
Z-15
G82 Z-15 R-20 W25 F70 M8
X150 R0
G80 R0
G90 G0 Z100
:T7 M6 ;T7 = 20mm DIA. BORING BAR TIP FACES SPINDLE DRIVE DOG
G0 G90 G71 G17 G40 G94
X50 Y-50 Z100 H01 S1800 M3
Z-15
G86 Z-15 R-20 W25 U-0.2 J0 F150 M8
X150 R0
G80 R0
G90 G0 Z100
M30
A2100Di Programming Manual
Publication 91204426-001
45
Chapter 6
May 2002
Menu
7
Milling Cycles
Milling cycles mill rectangular or circular faces, pockets, and frames. The NC program
specifies the location, shape, and size of the face, pocket, or frame and the control
automatically performs all the machining steps. These cycles are:
G
G22 Rectangular Face Centre Specified.
G
G22.1 Rectangular Face Corner Specified.
G
G23 Rectangular Pocket Centre Specified.
G
G23.1 Rectangular Pocket Corner Specified.
G
G24 Rectangular Inside Frame Centre Specified.
G
G24.1 Rectangular Inside Frame Corner Specified.
G
G25 Rectangular Outside Frame Centre Specified.
G
G25.1 Rectangular Outside Frame Corner Specified.
G
G26 Circular Face.
G
G26.1 Circular Pocket.
G
G27 Circular Inside Frame.
G
G27.1 Circular Outside Frame.
Milling cycles use a number of parameters that are specified in a table called the Cycle
Parameter Table. These items are normally fixed values, but may be changed to suit
special needs. The Cycle Parameter Table is accessible by the machine operator to
allow cycle specific items such as finish stock adjustments for the current program.
Refer to Book 1 – User Guide, Chapter 8 for a complete listing of Milling Cycle
Parameters.
A face is machined by removing all of the material above the specified area down to a
specified depth. The area around the bounds of the face is assumed to be clear of the
workpiece.
A pocket is machined by removing all of the material inside a rectangular or circular
boundary down to a specified depth.
An inside frame is machined by removing material inside a rectangular or circular outline
down to a specified depth. An inside frame differs from a pocket in that the frame milling
cycles assume that the centre of the area is free of material whereas the pocket cycles
remove all of the included volume.
An outside frame is machined by removing material from around the outside of a
rectangular or circular outline, down to a specified depth. The area around the bounds of
the frame is assumed to be clear of the workpiece.
The tool specified for these cycles must be a milling cutter. For pocketing, the tool must
be an end mill capable of machining in all three axes unless a pre-drilled hole exists. All
of the milling cycles require knowledge of the diameter of the tool used.
The tool diameter is the sum of three fields: the Nominal Diameter and the Diameter
Offset in the tool table, and the Diameter Offset in the Programmable Tool Offset. Any or
all of these fields may be used; the requirement is that the sum of the Nominal Diameter
and the Diameter Offset are equal to the actual cutter diameter.
A2100Di Programming Manual
Publication 91204426-001
46
Chapter 6
May 2002
Menu
This allows use of the milling cycles with programs processed assuming a nominal cutter
diameter (specified in the Nominal Diameter field) and using Cutter Diameter
Compensation to handle variations based on the actual cutter used (specified in the
Diameter Offset).
It also allows the use of milling cycles in programs written in terms of the part dimensions
where Cutter Diameter Compensation is used to provide the full amount of cutter offset.
In the latter case, Nominal Diameter is zero and the Diameter Offset is the full cutter
diameter.
7.1
Milling Cycle Depth
As with the G80 series hole making cycles, the R word specifies a modal reference
plane. The reference plane, see Fig. 7.1, is the dimension of the surface before the
milling cycle is performed. The machining depth, specified by the spindle axis word, can
be specified in two ways: as an incremental depth from the reference plane or as the
absolute dimension of the bottom surface of the machined face, frame, or pocket.
The selection is controlled by the Milling Cycle Depth cycle parameter. Setting this
parameter to 0 selects absolute bottom surface programming, setting it to one selects
incremental milling cycle depth programming. The default setting for this parameter is
configurable.
Figure 7.1 Milling Cycle Depth
If milling cycle depth mode is selected, the depth for all milling cycles is programmed as
the unsigned incremental distance from the R plane (nominal work surface) using the
spindle axis word (usually Z). In this case, the control automatically adds the Gage
Height to the programmed depth. The depth value is retained for all milling cycle blocks
in the program.
If bottom surface mode is selected, the spindle axis word specifies the absolute
dimension of the bottom surface of the machined face. The modal R word and spindle
axis (depth) value are shared by all G80 series hole making cycles and the milling
cycles; once programmed in any cycle block the values are retained for all hole making
and milling cycle blocks in the program.
A2100Di Programming Manual
Publication 91204426-001
47
Chapter 6
May 2002
Menu
7.2
End of Cycle Incremental Retract Dimension (W word)
The milling cycles finish with the tool at the clearance plane. These cycles accept an
optional, non-modal W word whose unsigned value specifies a rapid move to a point
above the work surface (reference plane). The W word value is the distance above the
reference plane (nominal work surface).
If the cycle completes by a rapid move to the clearance plane, programming a W word
causes the clearance plane to be ignored and the cycle rapids directly to the position
specified by the W word increment. If the cycle completes by a feed move to the
clearance plane, the rapid move to the W dimension follows the feed move.
7.3
Tool Types
The control supports the identification of the type of tool in the Tool Type field of the Tool
Data Table. In general the use of the field is optional. If the Tool Type is UNKNOWN or
one of the SPECIAL types, the cycles proceed assuming that the tool is of the proper
type. If this Tool Type is specified, the Milling Cycles ensure that the tool is appropriate
for the operation.
7.3.1
Operation in Single Block and Single Loop Mode
When single block mode is selected, the control executes one block of the NC program
and then stops waiting for the next operator action. Milling cycle blocks are performed to
completion in single block mode, including both the move to the operation location and
the complete operation specified by the block.
In some circumstances, it may be desirable to execute an NC program without
performing all of the milling cycle operations. The control provides a Single Loop mode
of operation for this purpose. In Single Loop mode,G20 series milling cycles perform the
move to the operation location, stopping at the cycle start point at the clearance plane
before executing the actual machining operation. At this point, the operator can select
Cycle Start or Z Repeat. Cycle Start skips the machining operation and proceeds to the
next block immediately. Z Repeat executes the machining portion of the cycle and stops
again when the spindle axis is returned to the clearance plane.
In a series of milling cycles executed in Single Loop mode with Single Block off, each
press of Cycle Start causes the machine to move to the operation site for the next cycle
and stop cycle. The operator can press Cycle Start to skip the operation, or Z Repeat to
execute the operation.
In Single Block with Single Loop off, each press of Cycle Start executes one NC program
block completely including machining the face, pocket, or frame and stops at the end of
the block. With Single Loop off, Z Repeat is not active when the operation completes
normally.
With both Single Block and Single Loop on, the first press of Cycle Start moves the
machine to the operation site and stops. Pressing Z Repeat executes the machining
steps of the cycle. Pressing Cycle Start executes the end of block functions (including
the optional W word retract) and stops again at End of Block. Thus executing each block
requires two presses of Cycle Start in this mode.
If a pattern cycle (G38 or G39) is active, Single Loop operates exactly as described
above. Single Block, however, does not stop after each operation of the pattern but
stops only when the entire pattern is completed.
A2100Di Programming Manual
Publication 91204426-001
48
Chapter 6
May 2002
Menu
Feedhold operates normally during a milling cycle block. That is, Feedhold causes axis
motion to stop just as it does for a G1 or G0 block. Pressing Cycle Start resumes normal
cycle.
7.4
Rectangular Milling Cycle Dimensions
The rectangular face, pocket, and frame cycles (G22-G25.1) all share common
dimensioning. The X and Y words specify the location of the centre of the rectangle or
one of the corners of the rectangle depending on the cycle. The U and V words specify
the length and width of the rectangle.
Fig.7.2 shows the use of the U, V, and O words to describe the basic feature shape. The
reference corner is determined by the signs of U and V. In all cases, the machining starts
as shown on Fig.7.2.
Outside frame cycles start machining at corner #1. The start arrow indicates the start of
machining for pockets and inside frames. Face milling cycles machine the side from
corner 4 to corner 3 first.
Figure 7.2 Rectangular Mill Cycle Dimensions
7.5
Circular Milling Cycle Dimensions
The circular face, pocket, and frame cycles (G26-G27.1) all share common
dimensioning. The X and Y words specify the centre of the circle defining the face,
A2100Di Programming Manual
Publication 91204426-001
49
Chapter 6
May 2002
Menu
pocket, or frame to be machined. The U word defines the diameter of the face, pocket, or
frame.
7.6
Milling Cycle Cut Width and Depth
The milling cycles use the P word to define the cut width and the K word to define the
depth of cut for each pass of the cycle. The P word specifies the percentage of the cutter
diameter that is to be engaged in the cut. The K word specifies the Z axis depth of cut
directly. Both of these distances are treated as maximum values. The milling cycles
adjust the width and depth to cut to distribute the stock removal evenly over the passes
without exceeding the specified width or depth of cut.
For example, if a frame cycle is to remove 20 mm of stock on the outside of the frame
and the cut width is 50 % (P word value of 50) and the cutter diameter is 12 mm, the
width of cut is 0.50 x 12 = 6 mm. This requires 20/6 = 3.33 passes, which is rounded up
to 4 passes. The frame cycle will use four passes of 5 mm each rather than three passes
of 6 mm and one of 2 mm. The K word is similarly used as the upper bound on the depth
of cut, and the total amount of stock to be removed is evenly distributed over the several
passes.
7.7
Milling Cycle Machine Type
All milling cycles use the Q word to specify the machining type. The specific values vary
depending on the cycle, but generally Q selects roughing to final size, roughing leaving
finish stock, finishing only, or both rough and finish. For pocket and frame cycles, the Q
word value also selects whether the finish pass around the periphery of the feature is cut
in several passes at increasing depth or only one pass at full depth.
Climb
Q0
Q1
Q2
Q3
Q4
Q5
7.8
Conventional
Q10
Q11
Q12
Q13
Q14
Q15
Operations
Rough and finish, single finish pass on sides
Rough and finish, multiple finish passes on sides
Rough, leave finish stock
Rough to size
Finish only, single pass on sides
Finish only, multiple finish passes on sides
Milling Cycle Feeds and Speeds
The milling cycles perform all roughing operations using the feed and speed that are
active when the cycle starts. The feed and speed programmed in the milling cycle block
itself are used for the finishing operation if the cycle type (Q word) specifies a finish
pass. The finish feed and speed are cycle modal and do not affect the modal feed and
speed used for the roughing operations.
When a milling cycle that specifies a finish feed or speed completes, the modal
(roughing) feed and speed are restored. If a milling cycle does not specify a finishing
feed or speed, and no cycle modal value has been established, the roughing feed or
speed is used.
Both roughing and finishing can be performed in the same milling cycle block, using the
same cutter for both operations. If it is necessary to change the tool, coolant, or other
mechanism, the roughing and finishing must be specified in separate blocks.
A2100Di Programming Manual
Publication 91204426-001
50
Chapter 6
May 2002
Menu
As almost all of the parameters of the cycle are cycle modal, it is only necessary to
specify the value of the Q word and possibly the W word in the second (finish)
invocation.
For example, to rough and finish a rectangular pocket using different tools, the following
blocks could be used:
N0100 G23 X10 Y5 U2.5 V5 R2.5 Z1 K.2 E5 P60 I.02 J.015 Q2
N0110 G0 T2 M6
N0120 S1000 M13
N0130 G23 F40 Q4
Block N0100
G Roughs the pocket using the active tool, feed, and speed.
Block N0110
G Changes to tool 2. The G0 cancels the modal G23 to prevent the milling cycle from
being repeated.
Block N0120
G Starts the spindle and coolant.
Block N0130
G Finishes the pocket using the information originally specified in block N0100 and
specifies the finish feedrate. Note that the finish feedrate could have been
established in block N0100, since it is cycle modal. The spindle speed in block
N0120 is necessary since the tool change in block N0110 stops the spindle.
G
G22 Rectangular Face Centre Specified and G22.1 Rectangular Face Corner
Specified
The rectangular face cycles machine the stock above the face of a part, assuming that
there is clearance on all sides of the workpiece to position the cutter. The G22 and
G22.1 cycles produce identical motion; the difference is that for G22 the X and Y
dimensions in the G22 block specify the centre of the face, and for G22.1 they specify
the co-ordinates of the reference corner of the rectangle. Refer to Fig.7.3 for centre and
corner reference programming:
Permissible Tool Types
UNKNOWN, FACE MILL, ROUGH END MILL, FINISH END MILL, SHELL MILL.
Parameters:
G X word - X axis dimension of reference point of geometry.
G
Y word - Y axis dimension of reference point of geometry.
G
U word - Cycle modal length parallel to the X axis or the side of the face rotated from
the +X axis by the angle specified by the O word. The sign of U and V determines
the reference corner.
G
V word - Cycle modal length parallel to the Y axis or the side of the face rotated from
the +Y axis by the angle specified by the O word. The sign of U and V determines
the reference corner.
G
O word - Cycle Modal Angle from the +X axis by which the face is rotated about the
reference point.
G
R word - Cycle Modal Reference Plane dimension.
A2100Di Programming Manual
Publication 91204426-001
51
Chapter 6
May 2002
Menu
G
Z word - Cycle Modal milling cycle depth or bottom surface dimension.
G
Q word - Cycle modal cycle type.
G
K word - Cycle modal cut depth for each pass of the face cycle.
G
P word - Cycle modal width of cut, expressed as a percentage of the tool diameter,
in the range 10 - 80.
G
J word - Cycle modal amount of stock to be left on the face for finishing.
G
F word - Cycle modal finish feedrate.
G
S word - Cycle modal finish spindle speed.
G
W word - Non-modal final retract distance (overrides Gage Height).
Programming Considerations
The Q word defines the action of the cycle as shown in the following table:
G
Q word values of 0-5 specify bi-directional milling, or a back and forth pattern.
G
Q values of 10-15 specify that each cutting pass be made in the same direction
across the face. This makes all passes either climb milling or conventional milling.
Whether the cutting is climb or conventional milling determined by the direction of
milling cutter rotation and by which side the face (U or V) is longer.
G
Note that if both roughing and finishing are specified, the same tool is used for both
operations.
G
The operations listed in pairs (Q0 and Q1) are the same. The duplication exists to
make the operation numbers the same as the numbers for the pocket and frame
cycles
Bi-directional
Q0, Q1
Q2
Q3
Q4, Q5
Unidirectional
Q10, Q11
Q12
Q13
Q14, Q15
Operations
Rough and finish
Rough, leave finish stock
Rough to size
Finish only
G
The O word specifies the angle with respect to the +X axis by which the face
geometry is rotated about the reference point. Negative values specify clockwise
rotation and positive values specify counterclockwise rotation. If the face block is
being executed by a pattern cycle (either rectangular, specified by G38, or circular,
specified by G39 as described in this chapter) the geometry of the face is
additionally rotated by the angle defined by the pattern cycle if the pattern cycle
specifies rotated operations.
G
The P word specifies the width of cut for each pass across the face as a percentage
of the tool diameter from the tool table. If the P word is absent, the Face Cycle Cut
Width from the cycle parameter table is used. If P is less than 10 or greater that 80
(that is, specifies an overlap less than 10% or greater than 80% of the cutter
diameter), an overlap of 10% or 80% is used and no alarm is reported. The actual
overlap is computed so that all of the cuts are the same width and the P word value
of overlap is not exceeded.
G
The J word specifies the amount of finish stock to be left for those operations that
leave finish stock (Q = 0,1,2,4,5,10,11,12,14 and 15). If the J word is absent, the
Face Cycle Finish Stock amount from the cycle parameter table is used.
A2100Di Programming Manual
Publication 91204426-001
52
Chapter 6
May 2002
Menu
G
The F and S words specify the feedrate and spindle speed to be used for the finish
passes (if any). These items are cycle modal and do not affect the rough feed and
speed. When a cycle specifying a finish feedrate or speed completes, the original
modal feedrate and speed (that is, the roughing feedrate and speed) are restored.
Note that units of the feedrate and speed are determined by the feed rate mode
(feed per minute - G94 or feed per tooth - G95) and the spindle speed mode (spindle
speed in RPM - G97 or Spindle speed in Surface Feed per Minute) in effect when
the milling cycle is executed.
G
The start point (point #1 in ) is located in the -X direction one half the cutter diameter
plus the Face Cycle XY Clearance distance from the starting corner dimension, and
in +Y by one half the cutter diameter minus the width of cut from the starting corner
dimension.
In cases where the V dimension is greater than the U dimension, the start point is
located in the -Y direction one half the cutter diameter plus the Face Cycle XY
Clearance distance from the starting corner dimension, and in + X by one half the
cutter diameter minus the width of cut from the starting corner dimension.
G
The Face Cycle XY Clearance, Face Cycle Cut Width, and Face Cycle Finish Stock
values are specified in the Cycle Parameter Table. The diameters of the milling
cutters is used by the face milling cycles and must be present in the tool table. The
cycles use the sum of the Nominal Diameter and Diameter Offset fields from the
Tool Data Table and the Diameter Offset from the active Programmable Tool Offset
as the tool diameter.
There must be clearance space around the face for the off-work moves. This
clearance is twice the tool diameter plus twice the Face Cycle XY Clearance in the
axis of the face parallel to the X axis (or rotated from the +X axis by the O word
angle), and the cutter diameter in the axis of the face parallel to the Y axis (or
rotated from the +Y axis by the O word angle).
Cycle Actions (Bi-directional Milling, Q = 0,1,2,3,4,5)
1. Move the non-spindle axes to the cycle start point in rapid (point #1 see Fig. 7.3).
2. Rapid the spindle axis to the clearance plane.
3. Rapid the spindle axis to the depth of cut (K word) below the reference plane or the
previously machined depth, or to final depth.
4. Feed to point #2 parallel to the long side of the face.
5. Rapid to Point #3 parallel to the short side of the face.
6. Feed to point #4 in the opposite direction to feed move step 4.
7. Rapid parallel to the short side of the face by the overlap distance.
8. Repeat steps 4 to 7 until the face is completely machined.
9. If not at depth, rapid retract by a clearance amount to establish a new clearance
plane.
10. Repeat steps 1 to 9 until final depth is reached, including the finish cut if
programmed.
11. After the last pass over the face, rapid retract the spindle axis to the original
clearance plane or to the W word distance above the R plane(if the W word is
programmed). Then rapid the other axes to the position programmed in the face
block (the centre of the face for G22, the specified corner for G22.1).
A2100Di Programming Manual
Publication 91204426-001
53
Chapter 6
May 2002
Menu
Figure 7.3 Cycle Actions (Bi-directional Milling)
Cycle Actions (Unidirectional Milling, Q = 10, 11, 12, 13, 14, 15)
1. Move the non-spindle axes to the cycle start point in rapid (point #1 see Fig.7.4).
2. Rapid the spindle axis to the clearance plane.
3. Rapid the spindle axis to the depth of cut (K word) below the reference plane or the
previously machined depth, or to final depth.
4. Feed to point #2 parallel to the long side of the face.
5. Rapid retract to the clearance plane.
6. Rapid to Point #3 (the start of the next pass).
7. Repeat steps 3 to 6 until the face is completely machined.
8. If not at depth, rapid retract a clearance amount to establish a new clearance plane.
9. Repeat steps 1 to 8 until final depth is reached, including the finish cut if
programmed.
10. After the last pass over the face, rapid retract the spindle axis to the original
clearance plane or to the W word distance above the R plane (if the W word is
programmed), then rapid the other axes to the position programmed in the face block
(the centre of the face for G22, the specified corner for G22.1).
Figure 7.4 Cycle Actions Unidirectional Milling
A2100Di Programming Manual
Publication 91204426-001
54
Chapter 6
May 2002
Menu
7.8.1
G22 Rectangular Face Milling Centre Specified Example
To illustrate the specific action of the G22 cycle, the following program, and Fig. 7.5, will
execute a Bi-directional Face Milling operation, using Centre Reference, Rough and
Finish with Same Tool.
G
T1 is a .750” Diameter End Mill
Example
: G0 T1 M6
N10 S850 M13 F15
N20 G22 X2 Y1 U4 V2 R0 Z-.5 Q0 K.25 P75 J.045 F10 S1500
N30 G0 M2
X and Y axis start position
Before Y axis start position can be calculated, the amount of material removed for
each rough pass must be calculated as follows:
Face Stock to remove = V Word + 1mm or .003937 inch
Face Stock to remove = 2 + .003937 = 2.003937
Cutter Efficiency
= Cutter Diameter x P word
Cutter Efficiency
= .750 inch x .750 = .5625
Number Passes
= Rough Stock/Cutter Efficiency
Number Passes
= 2.003937 = 3.56 or 4 rough passes,
.5625
Cut Width
= Face Stock to remove/Number of Passes
Cut Width
= 2.003937 = .5009843
4
Notes
Sharpened or undersized cutters may initiate additional passes.
Tool Diameter is the sum of the Nominal Diameter from the Tool Data Table +
Diameter Offset from the Tool Data Table + Diameter Offset from the active
Programmable Tool Offset table. For this example only the Nominal Diameter is
used.
X and Y axis Start Position is calculated as follows:
XSP = X Centre position - U/2 - Tool Diameter/2 - XY Clearance.
YSP = Y Centre position + V/2 - Tool Diameter/2 - Cut Width.
XSP = 2 - 4/2 - .750/2 - .02 = .39500.
YSP = 1 + 2/2 + .750/2 - .5009843 = 1.87402.
G22 Face Milling Example (Fig. 7.5).
A2100Di Programming Manual
Publication 91204426-001
55
Chapter 6
May 2002
Menu
Figure 7.5 G22 Face Milling Example
7.8.2
G22.1 Rectangular Face Milling Corner Specified Example
To illustrate specific action of the G22.1 cycle, the following program, and Fig. 7.6
specification will be used:
G
Use unidirectional milling making rough passes at 0.25 inch depth of cut at 850 rpm
and 15 in/min.
G
Make a finish pass removing 0.045 inches at 1200 rpm and the same feedrate.
G
T1 is 0.5 inch End Mill.
Example
: G0 T1 M6
N10 S850 M13 F15
N20 G22.1 X0 Y0 U4 V2 R0 Z-.5 Q10 K.25 P75 J.045 S1200 W1
N30 G0 M2
A2100Di Programming Manual
Publication 91204426-001
56
Chapter 6
May 2002
Menu
X and Y axis start position
Before Y axis start position can be calculated, the amount of material removed for
each rough pass must be calculated as follows:
Face Stock to remove = V Word + 1mm or .003937 inch
Face Stock to remove = 2 + .003937 = 2.003937
Cutter Efficiency
= Cutter Diameter x P word
Cutter Efficiency
= .50 inch x .750 = .375
Number Passes
= Rough Stock/Cutter Efficiency
Number Passes
= .2.003937 = 5.34 or 6 rough passes
.375
Cut Width
= Face Stock to remove/Number of Passes
Cut Width
= 2.003937 = .33398
6
Notes
Sharpened or undersized cutters may initiate additional passes.
Tool Diameter is the sum of the Nominal Diameter from the Tool Data Table +
Diameter Offset from the Tool Data Table + Diameter Offset from the active
Programmable Tool Offset table. For this example only the Nominal Diameter is
used.
X and Y axis Start Position is calculated as follows:
XSP = X Corner position - Tool Diameter/2 - XY Clearance.
YSP = Y Corner position + V + Tool Diameter/2 - Cut Width.
XSP = 0 - .500/2 - .02 = .2700.
YSP = 0 + 2 + .500/2 - .33398 = 1.91602.
A2100Di Programming Manual
Publication 91204426-001
57
Chapter 6
May 2002
Menu
Figure 7.6 G22.1 Face Milling Example Illustration
7.8.3
G23 Rectangular Pocket Centre Specified and G23.1 Rectangular
Pocket Corner Specified
The rectangular pocket cycles machine rectangular pockets in solid material, plunging
the cutter into the work using a ramp decent or a plunge into a pre-drilled hole. The two
Rectangular Pocket cycle codes produce identical motion; the difference is that for G23
the X and Y dimensions specify the centre of the pocket and for G23.1 they specify the
co-ordinates of the reference corner of the rectangle. Refer to Fig. 7.7 for centre and
corner reference programming.
Permissible Tool Types
UNKNOWN, ROUGH END MILL, FINISH END MILL.
Parameters
G X word - X axis dimension of reference point of geometry.
G
Y word - Y axis dimension of reference point of geometry.
G
U word - Cycle modal finished length parallel to the X axis or the side of the pocket
rotated from the +X axis by the angle specified by the O word.
A2100Di Programming Manual
Publication 91204426-001
58
Chapter 6
May 2002
Menu
G
V word - Cycle modal finished length parallel to the Y axis or the side of the pocket
rotated from the +Y axis by the angle specified by the O word.
G
O word - Cycle modal angle from the +X axis by which the pocket is rotated about
the reference point.
G
R word - Modal Reference Plane dimension.
G
Z word - Modal milling cycle depth or bottom surface dimension.
G
,R word - Cycle modal pocket corner radius (,R = 0 specifies no corner radius).
G
Q word - Cycle modal cycle type.
G
L word - Plunge method (L=0 or not programmed - ramp/plunge; L=-1 use pre-drilled
hole, L > 0 ramp approach at angle L measured from the clearance plane).
G
K word - Cycle modal cut depth for each pass of the pocket cycle.
G
E word - Cycle modal plunge feedrate, in the same units as the pocketing feedrate,
to be used when cutting the initial slot.
G
P word - Cycle modal width of cut, expressed as a percentage of the nominal tool
diameter, in the range 10 - 80.
G
,D word - Non-modal corner slowdown modifier, in the range 0% to 100%. ,D0
specifies no corner slowdown; ,D100 specifies corner slowdown to P percent of the
programmed feedrate.
G
I word - Cycle modal amount of stock to be left for finishing on the pocket sides.
G
J word - Cycle modal amount of stock to be left for finishing on the pocket bottom.
G
F word - Cycle modal finish feedrate.
G
S word - Cycle modal finish spindle speed.
G
W word - Non-modal final retract distance from R plane (overrides Gage Height).
Programming Considerations
G The Q word defines the action of the cycle as shown in the following table. The
rectangular pocket cycle machines a slot along the long axis of the pocket to start
each pass of the pocket, and then enlarges the slot by making rectangular passes
around the pocket using climb milling (Q = 0-5) or conventional milling(Q =10-15).
The finish passes around the pocket sides are either cut in one pass at full depth (Q
= 0, 4, 10, 14) or in multiple passes using the K word depth increment (Q = 1, 5, 11,
15).
Climb
Q0
Q1
Q2
Q3
Q4
Q5
G
Conventional
Q10
Q11
Q12
Q13
Q14
Q15
Operations
Rough and finish, single finish pass on sides
Rough and finish, multiple finish passes on sides
Rough, leave finish stock
Rough to size
Finish only, single pass on sides
Finish only, multiple finish passes on sides
The L word modifies the method of entry into the workpiece for pockets requiring
roughing. L = 0 (or not programmed) signifies entry by plunging into the work along a
ramp whose length is the difference between the long and short dimensions of the
pocket, and whose depth is the depth increment (K word). Note that for a square
pocket, the length of the ramp is zero and the cutter plunges directly into the work.
A2100Di Programming Manual
Publication 91204426-001
59
Chapter 6
May 2002
Menu
If L is positive and non-zero, the L word value specifies the angle of the ramp
measured from the XY plane. For square pockets, this results in a square pattern
with each side being 1.6 times the cutter diameter. The slot is cut using as many
passes as necessary at angle L to reach the depth specified by the K word. The
angle is reduced if necessary to make the ramp end at the end of the slot.
When the full depth is reached, one pass is made in the reverse direction to the
opposite end of the slot to ensure that the entire slot is cut to full depth. For square
or nearly square pockets (pockets for which |U - V| < 0.6 times the cutter diameter)
the entry is made around the sides of a rectangle whose short side is 1.6 times the
cutter diameter and whose long side is longer by |U - V|.
In some cases it may be preferable to produce the entry hole by drilling to depth with
a suitable drill, and then milling the pocket with a milling cutter that is not capable of
machining in Z. This is specified by programming L = -1. The entry hole is located at
the cycle start point (#1) which is centred on the shorter dimension of the pocket and
a distance of |U - V|/2 from the centre of the longer dimension of the pocket toward
corner #1.
Figure 7.7 G23 Rectangular Pocket Centre
G
The O word specifies the angle of the pocket with respect to the +X axis by which
the face geometry is rotated about the reference point. Negative values specify
clockwise rotation and positive values specify counterclockwise rotation. If the
pocket block is being executed by a pattern cycle (either rectangular, specified by
G38, or circular, specified by G39) the geometry of the pocket is additionally rotated
by the angle defined by the pattern cycle if the pattern cycle specifies rotated
operations.
G
The ,R word defines a radius to be machined on the corners of the pocket. The ,R
value must be no more than half of the short dimension of the pocket. If the ,R word
is specified, the radius of the cutter used for roughing and finishing must be no larger
than the specified ,R value.
G
The P word specifies the width of cut for each pass around the pocket as a
percentage of the nominal tool diameter from the tool table. If the P word is absent,
the Pocket Cycle Cut Width from the cycle parameter table is used. If P is less than
A2100Di Programming Manual
Publication 91204426-001
60
Chapter 6
May 2002
Menu
10 or greater that 80 (that is, specifies an overlap less than 10% or greater than 80%
of the cutter diameter), an overlap of 10% or 80% is used and no alarm is reported.
The actual overlap is computed so that all passes remove the same amount of stock
and the P word value of overlap is not exceeded.
G
The I word specifies the amount of finish stock to be left on the sides of the pocket
and the J word specifies the amount of finish stock to be left on the bottom of the
pocket for those operations that leave finish stock or perform finish passes (Q = 0, 1,
2, 5, 10, 11, 12, and 15). If the I word is absent, the Pocket Cycle Side Finish Stock
amount from the cycle parameter table is used; if the J word is absent, the Pocket
Cycle Bottom Finish Stock amount from the cycle parameter table is used.
G
The F and S words specify the feedrate and spindle speed to be used for the finish
passes (if any). These items are cycle modal and do not affect the rough feed and
speed. When a cycle specifying a finish feedrate or speed completes, the original
modal feedrate and speed (that is, the roughing feedrate and speed) are restored.
Note that units of the feedrate and speed are determined by the feedrate mode (feed
per minute - G94 or feed per tooth - G95) and the spindle speed mode (spindle
speed in RPM - G97 or Spindle speed in Surface Feed per Minute) in effect when
the milling cycle is executed.
If finishing is specified, the side finish pass starts and ends in one corner of the pocket.
The corner selected depends upon the direction and the shape of the pocket. The entry
to the finish pass is made at an arc beginning 1mm clear of the finish stock; the exit for
the finish pass is made along an arc to a point clear of the pocket side. If a corner radius
is being cut, the finish pass entry occurs at the start of the corner radius and the exit
occurs after the corner radius.
For both rough and finish machining, the pocket cycles recompute a corner feedrate
based on the cutter overlap (the P word) and other factors. Occasionally the computed
corner feedrate may be too slow. The ,D word can be used to modify the corner
slowdown. The ,D word is a percentage of the computed change in feedrate, in the
range 0 to 100%. That is, ,D0 specifies no slowdown and ,D100 specifies the full
computed slowdown. If ,D word is omitted, the full corner slowdown is used.
Unless a pre-drilled entry hole is present (L - 1), the roughing cutter is used to plunge cut
into the work, and therefore must be capable of cutting in the Z direction. The largest
roughing cutter diameter is the smaller of U and V, minus twice the finish stock if finish
stock is to be left (Q = 0, 1, 2, 10, 11, and 12). Furthermore, if radii are specified by a
non-zero ,R word, the cutter diameter must not exceed twice the specified corner radius.
The smallest roughing cutter diameter is such that the overlap (P word times the cutter
diameter) is greater than the finish stock specified.
The finishing cutter is used to plunge into the stock while machining the bottom of the
pocket, and therefore must be capable of machining in the Z direction. The largest
finishing cutter diameter is 1 mm less than the smaller of U and V minus four times the
finish stock on the pocket sides. Furthermore, if radii are specified by a non-zero ,R word
the cutter diameter must not exceed twice the specified corner radius. The smallest
finishing cutter diameter is such that the overlap (P word times the cutter diameter) is
greater than the finish stock specified.
The Pocket Cycle Cut Width, Pocket Cycle Side Finish Stock, Pocket Cycle Bottom
Finish Stock, Pocket Cycle Plunge Feedrate, and Gage Height values are specified in
the Cycle Parameter Table. The diameters of the milling cutters are required by the
pocket milling cycles and must be present in the tool table. The cycle use the sum of the
Nominal Diameter and Diameter Offset fields from the Tool Data Table and Diameter
Offset from the active Programmable Tool Offset as the tool diameter.
A2100Di Programming Manual
Publication 91204426-001
61
Chapter 6
May 2002
Menu
Cycle Actions
Rapid the non-spindle axes to the cycle start point:
G
If L = 0, #2
G
If L = -1, #2
G
If L > 0, either #1 or #2 depending on the depth, slot length and angle
In all cases, the plunge ends at #2 position.
Figure. 7.8 Square Pockets (U = V)
Rapid the spindle axis to the clearance plane as follows:
1. If L = 0 or is not programmed:
Feed the spindle axis to the cut depth at the feedrate specified by the E word (or the
Pocket Cycle Plunge Feedrate cycle parameter if the E word is absent). This feed
motion occurs along a ramp from the start point to the opposite end of a slot whose
length is such that the remaining stock in the pocket is the same in both the long and
short axes of the slot. The slot is machined in one pass, starting at the clearance
point and ending at the opposite end of the slot at the depth of cut for this pass. A
second pass ending at position #2 at the cut depth finishes the slot. Note that for
square pockets (U = V) the entry is a straight plunge cut in Z.
2. If L > 0:
Feed the spindle axis in a zigzag motion along the slot, as in the L=0 case, but the
angle of the descent is specified by the L word. The zigzag motion continues until
the specified depth is reached, then continues for one full length pass at full depth
ending at position #2 to complete the slot. For square or nearly square pockets
(pockets of which |U - V| < 0.6 times the cutter diameter) the entry is made around
the perimeter of a small rectangle whose short side is 1.6 times the cutter radius.
The angle of descent is less than the L word value and selected to reach the
required depth in an integral number of passes. The ramp decent is followed by one
more pass abound the rectangle, ending at position #2.
A2100Di Programming Manual
Publication 91204426-001
62
Chapter 6
May 2002
Menu
3. If L = -1:
An entry hole large enough to accommodate the roughing cutter is assumed to exist,
and the cutter is fed at the full modal feedrate to the cut depth at the cycle start point
(position #1) and then at the plunge feedrate (E word) to position #2. The entry hole
must be located on the centreline of the short dimension of the pocket and (U - V)/2
from the centre of the long axis of the pocket (position #1) as follows:
(a) Feed toward the short side of the pocket at the active feedrate reduced by P%
for a total distance of Tool Diameter 3P (or to the final boundary of the pocket
less the finish allowance).
(b) Feed around the pocket at the active feedrate in the appropriate direction based
on climb or conventional milling, axis inversion states, and the spindle direction.
During this pass the corners are rounded by the ,R word value if a ,R radius
applies. The feedrate is reduced by P% of the active feedrate during the
cornering. The feedrate reduction can be modified by the ,D word if required.
(c) Repeat steps (a) and (b) until the roughing at this cut depth is completed.
(d) If not yet at full roughing depth, rapid the spindle axis to a clearance amount
above the just-cut surface and to the XY co-ordinates of the cycle start point.
(e) Repeat steps (a) to (b) until the pocket is complete to depth.
(f)
If finishing is specified (Q = 0, 1, 4, 5, 10, 11, 14, or 15), activate the F and S
words programmed in the pocket cycle block and complete steps (a) to (e).
(g) Rapid the tool to the X and Y location of the start point for finishing the pocket
bottom (#1).
(h) Rapid the spindle axis just clear of the pocket bottom finish stock level. Feed
the spindle axis to the final depth at the finish feedrate specified by the E word
(or the Pocket Cycle Plunge Feedrate cycle parameter if the E word is absent).
This feed motion occurs at an angle along the slot whose length is such that the
remaining stock in the pocket is the same in both the long and short axes of the
slot. The angle of descent is set such that the cutter ends at one end of the slot.
This move completes at #2. Complete the slot by feeding at the finish feedrate
to the opposite end of the slot at the finish depth..
(i)
Feed toward the short side of the pocket at the finish feedrate reduced by P%
for a total distance of Tool Diameter 3 P (or to the final boundary of the pocket
minus the pocket side finish allowance).
(j)
Feed around the pocket at the finish feedrate in the appropriate direction based
on climb or conventional milling, axis inversion states, and the spindle direction.
During this pass the corners are rounded by the ,R word value. The feedrate is
reduced by P% of the active feedrate during the cornering. The feedrate
reduction can be modified by the ,D word if required.
(k) Repeat steps (?) and (?) until the pocket bottom finish operation is completed.
After the final pass around the bottom of the pocket, position the tool clear of
the pocket wall by the pocket side finish stock allowance (the I word value)
(position #1).
(l)
If multiple finish passes are required (Q = 1, 5, 11, or 15), rapid the spindle axis
to position the tool at depth K below the reference plane for the first pass
around the sides of the pocket. If a single finish pass is specified (Q = 0, 10, 4,
or 14), the tool remains at the final depth of the pocket.
A2100Di Programming Manual
Publication 91204426-001
63
Chapter 6
May 2002
Menu
(m) Make one pass around the pocket in the appropriate direction based on climb or
conventional milling and the spindle direction. The pass begins and ends in one
corner of the part. Entry and exit to the finish pass are made along an arc
tangent to the sides of the corner. If a corner radius is present, the entry is
made before the corner radius and the exit after the corner radius.
(n) If this is not the last pass, rapid the tool to the finish cycle start position in X and
Y (position #1), then rapid advance the tool to the depth for the next pass (this
move is made at the E word feedrate for the final pass).
(o) Repeat steps (m) and (n) until the bottom of the pocket is reached.
(p) Retract the spindle axis to the clearance plane or the W word distance above
the R plane (if the W word is programmed), then rapid the other axes to the
position programmed in the pocket block (the centre of the pocket for G23, the
specified corner for G23.1).
G23 Rectangular Pocket Centre Specified Example
To illustrate the specific action of the G23 cycle, the following program specifications,
and Figs. 7.9 and 7.10, will be used to mill a pocket 2 inch x 4 inch x 0.25 inch depth.
Program information used is as follows:
G
Centre Point Referencing.
G
Climb Milling Q2 Four Rough passes with T1 .750 inch End Mill and leave finish
stock.
G
Climb Milling Q4 One Finish pass with T2 .250 inch End Mill.
G
Use P70 percent cutter overlap.
G
L word is not programmed, ramping plunge is used.
G
,R word corner radius is not used.
G
E word not used Pocket Cycle Plunge Feedrate is from cycle parameter table.
Example
: G0 T1 M6
N10 S800 M13 F10
N20 G23 X2 Y1 U4 V2 R0 Z-.25 I.040 J.020 P70 Q2 K.2
N30 G0 T2 M6
N40 G23 Q4 F12 S1000 M13 N50 G0 M2
The basic sequence used by each pass to machine this pocket will move from position 1
through position 8 as shown on Fig. 7.10.
Note
Tool Diameter is the sum of the Nominal Diameter from the Tool Data Table + Diameter
Offset from the Tool Data Table + Diameter Offset from the active Programmable Tool
Offset table. For this example only the Nominal Diameter is used.
A2100Di Programming Manual
Publication 91204426-001
64
Chapter 6
May 2002
Menu
Figure 7.9 G23 Rectangular Pocket Centre Specified Example
Number of milling passes to remove side stock is calculated as follows:
Rough Stock to remove
= V - I Word
2
Rough Stock
= 2 - .040 inch = 0.96
2
Cutter Efficiency
= Cutter Diameter x P word
Cutter Efficiency
= .750 inch x .70 = .525
No. of Rough Passes
= Rough Stock/Cutter Efficiency
No. of Rough Passes
= .96 = 1.828 or 2 rough passes for each bottom depth of:
.525
K
= .20 and K .25 - J.020 = .23
Note
Sharpened or undersized cutters may initiate additional passes.
The rough passes will remove .48 inch of side stock at each of the above depths. I .040
inch of stock side stock, and J .02 inch of bottom stock will remain for the finish pass.
X and Y axis start position 1 is calculated as follows:
X part centre = U + X
2
X part centre = 4 + 2 = 4
2
Y part centre = V + Y
2
Y part centre = 2 + 1 = 2
2
Entry point calculation = U - V
2
Entry point calculation = 4 - 2 = 1
2
X position 1 = X part centre - Entry point calculation
X position 1 = 4 - 1 = 3
Y position 1 = 2 - 1 = 1
A2100Di Programming Manual
Publication 91204426-001
65
Chapter 6
May 2002
Menu
Figure 7.10 G23 Rectangular Pocket Milling Example Illustration
7.8.4
G23.1 Rectangular Pocket Corner Specified Example
To illustrate the specific action of the G23.1 cycle, the following program specifications,
Figs 7.11 and 7.12 will be used to mill a 2.25 inch x .5 inch x .25 inch depth slot, plunge
with entry hole. Program information used is as follows:
G
Corner Point Referencing X2, Y1.
G
Climb Milling Q3 Four Rough passes with T2 .250 inch End Mill.
G
Pre drilled entry hole (5/16 inch) is assumed.
G
Use P70 percent cutter overlap.
G
L-1 word is programmed for plunge in Z axis direction.
G
,R word corner radius is not used.
G
E word is Pocket Cycle Plunge Feedrate value is from the cycle parameter table.
G
J word is not used, Pocket Cycle Bottom Finish Stock.
G
I word = 0 no Side Finish Stock.
A2100Di Programming Manual
Publication 91204426-001
66
Chapter 6
May 2002
Menu
Example
: G0 T2 M6
N10 S100 M13 F12
N20 G23.1 X2 Y1 U2.25 V.5 R0 Q3 Z-.25 K.2 I.0 L-1 P70
N50 G0 M2
The basic sequence used by each pass to machine this slot will rapid to position 1,
plunge to depth K .2, feed from position 1 through position 6. Then feed to position 2,
rapid back to position 1, feed to final depth Z .25, and repeat sequence. When matching
is completed, Z axis rapids to clearance plane, then X and Y axis rapid to corner
reference X2, Y1. Refer to G23.1 Rectangular Pocket Milling Example Fig. 7.12.
Figure 7.11 G23.1 Rectangular Pocket Corner Specified Example
Entry hole location and position one start point are calculated as follows:
X and Y axis start position
Start Position 1 location is calculated as follows:
X part centre
=U+X
2
X part centre
= 2.25 + 2 = 3.125
2
X Entry point calculation
=U-V
2
X Entry point calculation
= 2.25-.5 =0.875
2
X position 1
= X part centre - Entry point calculation
X position 1
= 3.125 - 0.875 = 2.25
Y part centre
=V+Y
2
Y part centre
= 0.5 + 1 = 1.25
2
Y position 1
= 1.25
Entry hole and position 1 start location is X2.25, Y1.25.
G23.1 Rectangular Pocket Milling Example Fig. 7.12
A2100Di Programming Manual
Publication 91204426-001
67
Chapter 6
May 2002
Menu
Figure 7.12 G23.1 Rectangular Pocket Milling Example Illustration
7.8.5
G24 Rectangular Inside Frame Centre Specified and G24.1
Rectangular Inside Frame Corner Specified.
The Rectangular Inside Frame cycles machine a rectangular pocket in the same manner
as the Rectangular Pocket cycles, but these cycles assume that the centre of the
rectangle is free of stock. As the inside of the pocket is open, the frame cycles do not
have to make plunge cuts and can be performed with an end mill that is not capable of Z
axis milling.
The two Rectangular Inside Frame cycle codes produce identical motion; the difference
is that for G24 the X and Y dimensions specify the centre of the pocket and for G24.1
they specify the co-ordinates of the reference corner of the rectangle.
Permissible Tool Types
UNKNOWN, ROUGH END MILL, FINISH END MILL
Parameters
G X word - X axis dimension of reference point of geometry.
G
Y word - Y axis dimension of reference point of geometry.
A2100Di Programming Manual
Publication 91204426-001
68
Chapter 6
May 2002
Menu
G
U word - Cycle modal finished length parallel to the X axis or the side of the frame
rotated from the +X axis by the angle specified by the O word.
G
V word - Cycle modal length parallel to the Y axis or the side of the frame rotated
from the +Y axis by the angle specified by the O word.
G
O word - Cycle modal angle from the +X axis by which the frame is rotated about the
reference point.
G
R word - Modal Reference Plane dimension.
G
Z word - Modal milling cycle depth or bottom surface dimension. This is the Z axis
location of the surface into which the frame is being cut.
G
,R word - Cycle modal frame corner radius.
G
Q word - Cycle modal cycle type.
G
J word - Cycle modal total amount of stock to be removed from the frame sides.
G
K word - Cycle modal cut depth for each pass of the frame cycle.
G
P word - Cycle modal width of cut, expressed as a percentage of the nominal tool
diameter, in the range 10 - 80.
G
,D word - Non-modal corner slowdown modifier, in the range 0% to 100%. ,D0
specifies no corner slowdown; ,D100 specifies corner slowdown to P percent of the
programmed feedrate.
G
I word - Cycle modal amount of stock to be left for finishing on the frame sides.
G
F word - Cycle modal finish feedrate.
G
S word - Cycle modal finish spindle speed.
G
W word - Non-modal final retract distance from the R plane (overrides Gage Height).
Programming Considerations
G The Q word defines the action of the cycle as shown in the table following. The
rectangular inside frame cycle enlarges an existing opening by making rectangular
passes around the frame using climb milling (Q = 0-5) or conventional milling (Q =
10-15). The finish passes around the frame sides are either cut in one pass at full
depth (Q = 0, 4, 10, 14) or in multiple passes using the K word depth increment (Q =
1, 5, 11, 15).
Climb
Q0
Q1
Q2
Q3
Q4
Q5
G
Conventional
Q10
Q11
Q12
Q13
Q14
Q15
Operations
Rough and finish, single finish pass on sides
Rough and finish, multiple finish passes on sides
Rough, leave finish stock
Rough to size
Finish only, single pass on sides
Finish only, multiple finish passes on sides
The ,R word defines a radius to be machined on the corners of the frame. The ,R
value must be no more than half of the short dimension of the frame. If the ,R word
is specified, the radius of the cutter used for roughing and finishing must be smaller
than the specified ,R value.
A2100Di Programming Manual
Publication 91204426-001
69
Chapter 6
May 2002
Menu
G
The O word specifies the angle with respect to the +X axis by which the frame geometry
is rotated about the reference point. Negative values specify clockwise rotation and
positive values specify counterclockwise rotation. If the frame block is being executed by
a pattern cycle (either rectangular, specified by G38 as described in this Chapter, or
circular, specified by G39) the geometry of the frame is additionally rotated by the angle
defined by the pattern cycle if the pattern cycle specifies rotated operations.
G
The J word defines the amount of stock to be removed from the inside of the frame, and
therefore indirectly specifies size of the opening inside the frame before machining. The
finished frame is a rectangle U by V in size; the inside opening is assumed to be U - 2*J
by V - 2*J in size. If the amount of stock to be removed is not the same on the long and
short sides of the frame, the J word must specify the largest amount of stock.
Figure 7.13 G24 Rectangular Inside Frame Centre and G24.1 Rectangular Inside
Frame Corner
G
The P word specifies the width of cut for each pass around the frame as a percentage of
the nominal tool diameter from the tool table. If the P word is absent, the Frame Cycle
Cut Width from the cycle parameter table is used. If P is less than 10 or greater that 80
(that is, specifies an overlap less than 10% or greater than 80% of the cutter diameter),
an overlap of 10% or 80% is used and no alarm is reported. The actual overlap is
computed so that all passes remove the same amount of stock and the overlap does not
exceed the P word value.
G
The I word specifies the amount of finish stock to be left on the sides of the frame for
those operations that leave finish stock or perform finish passes (Q = 0, 1, 2, 5, 10, 11,
12, and 15). If the I word is absent, the Frame Cycle Side Finish Stock amount from the
cycle parameter table is used.
G
The F and S words specify the feedrate and spindle speed to be used for the finish
passes (if any). These items are cycle modal and do not affect the rough feed and
speed. When a cycle specifying a finish feedrate or speed completes, the original modal
feedrate and speed (that is, the roughing feedrate and speed) are restored. Note that
units of the feedrate and speed are determined by the feed rate mode (feed per minute G94 or feed per tooth - G95) and the spindle speed mode (spindle speed in RPM - G97
A2100Di Programming Manual
Publication 91204426-001
70
Chapter 6
May 2002
Menu
or Spindle speed in Surface Feed per Minute) in effect when the milling cycle is
executed.
G
For both rough and finish machining, the pocket cycles recompute a corner feedrate
based on the cutter overlap (the P word) and other factors. Occasionally the computed
corner feedrate may be too slow. The ,D word can be used to modify the corner
slowdown. The ,D word is a percentage of the computed change in feedrate, in the
range 0 to 100%. That is, ,D0 specifies no slowdown and ,D100 specifies the full
computed slowdown. If ,D word is omitted, the full corner slowdown is used.
G
The finish pass around the sides of the frame is identical to the finish pass for a
rectangular pocket except that the bottom is not machined. If finishing is specified, the
finish pass starts and ends in one corner of the frame. The corner selected depends
upon the direction and the shape of the pocket. The entry to the finish pass is made at
an arc beginning 1 mm clear of the finish stock; the exit from the finish pass is made
along an arc to a point clear of the frame side. If a corner radius is being cut, the finish
pass entry occurs at the start of the corner radius and the exit occurs after the corner
radius.
G
The largest roughing cutter diameter is 1 mm less than the initial 'open area' inside the
frame to be milled. That is, the cutter must be 1 mm smaller than the short dimension of
the frame (U or V, whichever is smaller), minus twice the stock to be removed (J word).
Furthermore, if radii are specified by a non-zero ,R word the cutter diameter must not
exceed twice the specified corner radius. The smallest roughing cutter diameter is such
that the overlap (P word times the cutter diameter) is greater than the finish stock
specified.
Figure 7.14 G 24 and G24.1 Rectangular Frames and Corners
G
The largest finishing cutter diameter is 1 mm less than the smaller of U and V minus
four times the finish stock on the pocket sides. Furthermore, if radii are specified by
a non-zero ,R word the cutter diameter must not exceed twice the specified corner
A2100Di Programming Manual
Publication 91204426-001
71
Chapter 6
May 2002
Menu
radius. The smallest finishing cutter diameter is such that the overlap (P word times
the cutter diameter) is greater than the finish stock specified.
G
The Frame Cycle Cut Width, Frame Cycle Side Finish Stock, and Gage Height
values are specified in the Cycle Parameter Table. The nominal diameters of the of
the milling cutters is required by the frame milling cycles and must be present in the
tool table. The cycles use the sum of the Nominal Diameter and Diameter Offset
fields from the Tool Data Table and the Diameter Offset from the active
Programmable Tool Offset as the tool diameter.
Cycle Actions
1. Rapid the non-spindle axes to the cycle start point in X and Y, which is on the
centreline of the short side of the frame and Gage Height away from the inside
surface of the frame (or at the centre of the slot if the slot is less than twice Gage
Height long).
2. Rapid the spindle axis to position the tool at depth K below the reference plane (for
the first pass) or at depth K below the current machining level (for subsequent
passes).
3. Feed toward the short side of the frame at the active feedrate reduced by P% for a
total distance of Tool Diameter 3 P (or to the final boundary of the frame less the
finish allowance).
4. Feed around the frame at the active feedrate in the appropriate direction based on
climb or conventional milling, axis inversion states, and the spindle direction. During
this pass the corners are rounded by the ,R word value if a ,R radius applies. The
feedrate is reduced to P% of the active feedrate during the cornering. The feedrate
reduction can be modified by the ,D word if required.
5. Repeat steps 3 and 4 until the roughing at this cut depth is completed.
6. If not yet at full roughing depth, rapid the spindle axis to a clearance amount above
the just-cut surface and to the XY co-ordinates of the cycle start point.
7. Repeat steps 3 to 6 until the frame is complete to depth.
8. If finishing is specified (Q = 0, 1, 4, 5, 10, 11, 14, or 15), activate the F and S words
programmed in the frame cycle block and complete steps 10 and 11.
9. Rapid the tool to the finish cycle start point at depth K below the reference plane (for
Q = 1, 5, 11, or 15), or at final depth (for Q = 0, 4, 10, or 14).
10. Make one pass around the frame in the appropriate direction based on climb or
conventional milling and the spindle direction.
11. Repeat steps 9 and 10 until the bottom of the frame is reached.
12. Retract the spindle axis to the original clearance plane or the W word distance
above the R plane (if W is programmed), then rapid the other axes to the position
programmed in the pocket block (the centre of the frame for G24, the specified
corner for G24.1).
A2100Di Programming Manual
Publication 91204426-001
72
Chapter 6
May 2002
Menu
7.8.6
G24 Rectangular Inside Frame Centre Specified Example
To illustrate the specific action of the G24 cycle, the following program specifications,
and Fig. 7.15, will be used:
G
Conventional Milling, Rough Only to Size Q13
G
Centre Reference G24
G
Rough cycle with T2 .500” End Mill
Example
: G0 T2 M6
N10 G1 S850 M13 F12
N20 G24 X2 Y1 U4 V2 R0 Z-.25 J.25 K.2 Q13 P30
N30 G0 M2
X and Y axis start position
The number of rough milling passes is calculated as follows:
Rough Stock to remove = J Word .25
Cutter Efficiency
= Cutter Diameter x P word
Cutter Efficiency
= .50 inch x .30 = .15
No. of Rough Passes
No. of Rough Passes
K
= Rough Stock/Cutter Efficiency
= .25 = 1.66 or 2 Rough Passes for each cut depth of:
15
= .20 and Z .25 - K.20 = .05
Note
Sharpened or undersized cutters may initiate additional passes.
The rough milling passes in this example will remove .1250 inch of side stock at each of
the above depths.
Start Position 1 location is calculated as follows:
Note
Tool Diameter is the sum of the Nominal Diameter from the Tool Data Table + Diameter
Offset from the Tool Data Table + Diameter Offset from the active Programmable Tool
Offset table. For this example only the Nominal Diameter is used.
XSP = X Centre + U - (Tool Diameter + J word + XY clearance)
2
2
XSP = 2 + 4 - (.5 + .25 +.02) = 3.4800
2 2
YSP = 1.0000
A2100Di Programming Manual
Publication 91204426-001
73
Chapter 6
May 2002
Menu
Figure 7.15 G24 Inside Rectangular Frame Milling Example Illustration
7.8.7
G24.1 Rectangular Inside Frame Corner Specified Example
To illustrate specific action of the G24.1 cycle, the following program specification, and
Fig. 7.16, will be used to rough machine an inside frame:
G Conventional Milling, Rough Only leave Finish Stock Q12.
G Corner Point Reference.
G Rough cycle with T1 .500” End Mill.
Example
: G0 T1 M6
N10 S850 M13 F10
N20 G24.1 X3 Y2.5 U4 V2 R0 Z-.2 K.1 Q12 P60 J.2 I.02
N30 G0 M2
A2100Di Programming Manual
Publication 91204426-001
74
Chapter 6
May 2002
Menu
The number of rough milling passes is calculated as follows:
Rough Stock to remove
= J Word - I Word = .2 - .02 = .18
Cutter Efficiency
= Cutter Diameter x P word
Cutter Efficiency
= .50 inch x .60 = .30
Number of Rough Passes
= Rough Stock/Cutter Efficiency
Number of Rough Passes
= .18 = .6 or 1 Rough Pass to depth K = .10
.30
The rough milling pass in this example will remove .18 inch of side stock at the depth
of .10.
Notes
Sharpened or undersized cutters may initiate additional passes
X and Y axis start position 1 location is calculated as follows:
Tool Diameter is the sum of the Nominal Diameter from the Tool Data Table + Diameter
Offset from the Tool Data Table + Diameter Offset from the active Programmable Tool
Offset table. For this example only the Nominal Diameter is used.
XSP = X Corner + U - (Tool Diameter + J Word + XY Clearance)
2
XSP = 3 + 4 - (.5 + 2 + .02) = 6.5300
2
YSP = Y corner + V
2
YSP = 2.5 + 2 = 3.5000
.2
A2100Di Programming Manual
Publication 91204426-001
75
Chapter 6
May 2002
Menu
Figure 7.16 G24.1 Inside Rectangular Frame Milling Example Illustration
7.8.8
G25 Rectangular Outside Frame Centre Specified and G25.1
Rectangular Outside Frame Corner Specified
The Rectangular Outside Frame cycles machine the outer surface of a rectangular
shape which is assumed to have adequate clearance on all sides to allow access by the
selected cutter. The two Rectangular Outside Frame cycle codes produce identical
motion; the difference is that for G25 the X and Y dimensions specify the centre of the
pocket and for G25.1 they specify the co-ordinates of the reference corner of the
rectangle.
Permissible Tool Types
UNKNOWN, ROUGH END MILL, FINISH END MILL.
A2100Di Programming Manual
Publication 91204426-001
76
Chapter 6
May 2002
Menu
Parameters
G X word - X axis dimension of reference point of geometry.
G
Y word - Y axis dimension of reference point of geometry.
G
U word - Cycle modal finished length parallel to the X axis or the side of the frame
rotated from the +X axis by the angle specified by the O word.
G
V word - Cycle modal finished length parallel to the Y axis or the side of the frame
rotated from the +Y axis by the angle specified by the O word.
G
O word - Cycle modal angle from the +X axis by which the frame is rotated about the
reference point.
G
R word - Modal Reference Plane dimension, represents the top of the work.
G
Z word - Modal milling cycle depth or bottom surface dimension.
G
,R word - Cycle modal frame corner radius (,R = 0 specifies no corner radius).
G
Q word - Cycle modal cycle type.
G
J word - Cycle modal amount of stock to be removed from the frame sides.
G
K word - Cycle modal cut depth for each pass of the frame cycle.
G
P word - Cycle modal width of cut, expressed as a percentage of the nominal tool
diameter, in the range 10 - 80.
G
I word - Cycle modal amount of stock to be left for finishing on the frame sides.
G
F word - Cycle modal finish feedrate.
G
S word - Cycle modal finish spindle speed.
G
W word - Nonmodal final retract distance (overrides Gage Height). The W word is
measured from the R plane.
Programming Considerations
G The Q word defines the action of the cycle as shown in the table following. The
rectangular outside frame cycle machines a rectangular shape by making
rectangular passes around the outside of the frame using climb milling (Q = 0-5) or
conventional milling (Q = 10-15). The finish passes around the frame sides are either
cut in one pass at full depth (Q = 0, 4, 10, 14) or in multiple passes using the K word
depth increment (Q = 1, 5, 11, 15).
Climb
Q0
Q1
Q2
Q3
Q4
Q5
G
Conventional
Q10
Q11
Q12
Q13
Q14
Q15
Operations
Rough and finish, single finish pass on sides
Rough and finish, multiple finish passes on sides
Rough, leave finish stock
Rough to size
Finish only, single pass on sides
Finish only, multiple finish passes on sides
The O word specifies the angle of the frame with respect to the +X axis by which the
frame geometry is rotated about the reference point. Negative values specify
clockwise rotation and positive values specify counterclockwise rotation. If the frame
block is being executed by a pattern cycle (either rectangular, specified by G38, or
circular, specified by G39 as described in this Chapter ) the geometry of the frame is
A2100Di Programming Manual
Publication 91204426-001
77
Chapter 6
May 2002
Menu
additionally rotated by the angle defined by the pattern cycle if the pattern cycle
specifies rotated operations.
G
The ,R word defines a radius to be machined on the corners of the frame. The ,R
value must be no more than half of the short dimension of the frame.
G
The J word defines the amount of stock to be removed from the outside of the frame,
and therefore indirectly specifies size of the rough stock before machining. The
finished frame is a rectangle U by V in size; the rough stock is assumed to be U +
2*J by V + 2*J in size. If the amount of stock to be removed is not the same on the
long and short sides of the frame, the J word must specify the largest amount of
stock.
Figure 7.17 G25 and G25.2 Rectangular Frame and Corner
G
The P word specifies the width of cut for each pass around the frame as a
percentage of the nominal tool diameter from the tool table. If the P word is absent,
the Frame Cycle Cut Width from the cycle parameter table is used. If P is less than
10 or greater that 80 (that is, specifies an overlap less than 10% or greater than 80%
of the cutter diameter), an overlap of 10% or 80% is used and no alarm is reported.
The actual overlap is computed so that all passes remove the same amount of stock
and the overlap does not exceed the P word value.
G
The I word specifies the amount of finish stock to be left on the sides of the frame for
those operations that leave finish stock or perform finish passes (Q = 0, 1, 2, 5, 10,
11, 12, and 15). If the I word is absent, the Frame Cycle Side Finish Stock amount
from the cycle parameter table is used.
G
The F and S words specify the feedrate and spindle speed to be used for the finish
passes (if any). These items are cycle modal and do not affect the rough feed and
speed. When a cycle specifying a finish feedrate or speed completes, the original
modal feedrate and speed (that is, the roughing feedrate and speed) are restored.
Note that units of the feedrate and speed are determined by the feedrate mode (feed
per minute - G94 or feed per tooth - G95) and the spindle speed mode (spindle
speed in RPM - G97 or Spindle speed in Surface Feed per Minute) in effect when
the milling cycle is executed.
G
The Frame Cycle XY Clearance, Frame Cycle Cut Width, Frame Cycle Side Finish
Stock, and Gage Height values are specified in the Cycle Parameter Table. The
A2100Di Programming Manual
Publication 91204426-001
78
Chapter 6
May 2002
Menu
nominal diameters of the milling cutters is required by the frame milling cycles and
must be present in the tool table. The cycle use the sum of the Nominal Diameter
and Diameter Offset fields from the Tool Data Table and the Diameter Offset from
the active Programmable Tool Offset as the tool diameter.
Cycle Actions
1. Rapid the non-spindle axes to the cycle start point in the other axis. This start point is
at the #1 corner of the workpiece Frame Cycle XY Clearance, away from the outside
surface of the frame, in the direction of motion, and overlapping the outer edge of the
workpiece by the specified overlap (the P word times the cutter diameter).
2. Rapid the spindle axis to position the tool at depth K below the reference plane (for
the first pass) or at depth K below the current machining level (for subsequent
passes).
3. Feed around the frame at the active feedrate in the appropriate direction based on
climb or conventional milling, axis inversion states, and the spindle direction. During
this pass the corners are rounded by the ,R word value if a ,R radius applies.
If corner radii are not specified, the cutter feeds straight off of the work until the back
edge of the cutter is clear of the work by Frame Cycle XY Clearance. If corner radii
are present, the cutter forms the radius of the final corner and then feeds directly
away from the work by Frame Cycle XY Clearance.
4. Rapid the cutter from the end position to the start position for the next pass.
5. Repeat steps 3 and 4 until the roughing at this cut depth is completed.
6. If not yet at full roughing depth, rapid the spindle axis to a clearance amount above
the just-cut surface and to the XY co-ordinates of the cycle start point.
7. Repeat steps 2 to 7 until the frame is complete to rough depth.
8. If finishing is specified (Q = 0, 1, 4, 5, 10, 11, 14, or 15), activate the F and S words
programmed in the frame cycle block and complete steps 10, 11 and 12.
Figure 7.18 G 25 and G25.1 Square Corners and Rounded Corners
9. Rapid the tool to the finish cycle start point at depth K below the reference plane (for
Q = 1, 5, 11, or 15), or at final depth (for Q = 0, 4, 10, or 14).
10. Make one pass around the frame in the appropriate direction based on climb or
conventional milling and the spindle direction. The pass starts clear of the work in the
same position as the roughing pass starts (position #1). The finish pass ends by
feeding straight off of the work for square corners and by a semicircular move off of
A2100Di Programming Manual
Publication 91204426-001
79
Chapter 6
May 2002
Menu
the work at the end of the final corner radius move if corner radii are specified
(position #2).
11. Repeat steps 10 and 11 until the bottom of the frame is reached.
12. Retract the spindle axis to the original clearance plane or to the W word distance
above the R plane (if the W is programmed), then rapid the other axes to the position
programmed in the pocket block (the centre of the pocket for G25, the specified
corner for G25.1).
7.8.9
G25 Outside Rectangular Frame Centre Specified Example
To illustrate specific action of the G25 cycle, the following program specifications, and
fig. 7.19, will be used:
G Conventional Milling.
G
Centre Reference X2, Y1.
G
Two Rough passes that will leave I.075 stock for finishing cycle.
G
One finish pass removing I.0750 material.
G
Finish and Rough cycle will use same tool T1 .750” End Mill.
G
Finish spindle speed will be S1000.
G
Corner radius will be ,R.125.
Example
: G0 T1 M6
N10 S850 M3 F10
N20 G25 X2 Y1 U4 V2 R0 Z-.25 ,R.125 J.5 Q10 P50 K.25 I.075 S1000
N30 G0 M2
Before Y axis start position can be calculated, the amount of material removed for
each rough pass must be calculated:
Rough Stock to remove
= J Word - I Word = .5 - .075 = .425
Cutter Efficiency
= Cutter Diameter x P word
Cutter Efficiency
= .750 inch x .50 = .375
Number of Rough Passes
= Rough Stock/Cutter Efficiency
Number of Rough Passes
= .425 = 1.13 or 2 rough passes
.375
Each rough side cut will remove .425/2 rough passes = .2125
Notes
Sharpened or undersized cutters may initiate additional passes.
Tool Diameter is the sum of the Nominal Diameter from the Tool Data Table +
Diameter Offset from the Tool Data Table + Diameter Offset from the active
Programmable Tool Offset table. For this example only the Nominal Diameter is
used.
X and Y axis Start Position 1 is calculated as follows:
XSP = X Centre position - U/2 - J word - Tool Diameter/2 - XY Clearance.
A2100Di Programming Manual
Publication 91204426-001
80
Chapter 6
May 2002
Menu
YSP = Y Centre position - V/2 - J word - Tool Diameter/2 + Rough stock removed
on each pass.
XSP = 2 - 4/2 - .5 - .750/2 - .02 = -.8950.
YSP = 1 - 2/2 - .5 - .750/2 + .2125 = -.6625.
Figure 7.19 G25 Outside Rectangular Frame Milling Example Illustration
A2100Di Programming Manual
Publication 91204426-001
81
Chapter 6
May 2002
Menu
7.8.10
G25.1 Outside Rectangular Frame Corner Specified Example
To illustrate specific action of the G25.1 cycle, the following program specifications, and
Fig. 7.20, will be used:
G
Conventional Milling
G
Corner Reference X2, Y1
G
Two Rough passes that will leave I.075 stock for finishing cycle
G
One finish pass removing I.0750 material
G
Finish and Rough cycle will use same tool T1 .750” End Mill
G
Finish spindle speed will be S1000
G
Corner radius will be ,R.125
Example
: G0 T1 M6
N10 S850 M3 F10
N20 G25.1 X2 Y1 U4 V2 R0 Z-.25 ,R.125 J.5 Q10 P50 K.25 I.075 S1000
N30 G0 M2
Before Y axis start position can be calculated, the amount of material removed for
each rough pass must be calculated as follows:
Rough Stock to remove
= J Word - I Word = .5 - .075 = .425
Cutter Efficiency
= Cutter Diameter x P word
Cutter Efficiency
= .750 inch x .50 = .375
Number of Rough Passes
= Rough Stock/Cutter Efficiency
Number of Rough Passes
= .425 = 1.13 or 2 rough passes,
.375
Each rough side cut will remove .425/2 rough passes = .2125
Notes
Sharpened or undersized cutters may initiate additional passes.
Tool Diameter is the sum of the Nominal Diameter from the Tool Data Table +
Diameter Offset from the Tool Data Table + Diameter Offset from the active
Programmable Tool Offset table. For this example only the Nominal Diameter is used.
X and Y axis Start Position 1 is calculated as follows:
XSP = X Corner position - J word - Tool Diameter/2 - XY Clearance
YSP = Y Corner position - J word - Tool Diameter/2 + Rough stock removed each
pass
XSP = 2 - .5 - .750/2 - .02 = +1.10500
YSP = 1 - .5 - .750/2 + .2125 = +.33750
A2100Di Programming Manual
Publication 91204426-001
82
Chapter 6
May 2002
Menu
Figure 7.20 G25.1 Outside Rectangular Frame Milling Example Illustration
7.8.11
G26 Circular Face
The circular face cycle machines the stock above the face of a part, assuming that there
is clearance on all sides of the workpiece to position the cutter. The cuts are made
parallel to the X axis, starting and ending on a circle circumscribed around the face
larger than the face diameter by the cutter diameter plus Face Cycle XY Distance for
clearance.
Permissible Tool Types
UNKNOWN, FACE MILL, ROUGH END MILL, FINISH END MILL.
A2100Di Programming Manual
Publication 91204426-001
83
Chapter 6
May 2002
Menu
Parameters
G
X word - X axis dimension of the centre of the circular face.
G
Y word - Y axis dimension of the centre of the circular face.
G
U word - Cycle modal diameter of the circular face.
G
R word - Modal Reference Plane dimension, refers to the top of the stock to be
machined.
G
Z word - Modal milling cycle depth or bottom surface dimension.
G
Q word - Cycle modal cycle type.
G
K word - Cycle modal Z axis cut depth for each pass of the face cycle.
G
P word - Cycle modal width of cut, expressed as a percentage of the nominal tool
diameter, in the range 10 - 80.
G
J word - Cycle modal amount of stock to be left on the face for finishing.
G
F word - Cycle modal finish feedrate.
G
S word - Cycle modal finish spindle speed.
G
W word - Non-modal final retract distance from the R - plane (overrides Gage
Height).
Programming Considerations
G
The Q word defines the action of the cycle as shown. Q word values of 0-5 specify
bi-directional milling, or a back and forth pattern. Q values of 10-15 specify that each
cutting pass be made in the same direction across the face. This makes all passes
either climb milling or conventional milling.
Bi-directional
Q0, Q1
Q2
Q3
Q4, Q5
Unidirectional
Q10, Q11
Q12
Q13
Q14, Q15
Operations
Rough and finish
Rough, leave finish stock
Rough to size
Finish only
G
The P word specifies the width of cut for each pass across the face as a percentage
of the nominal tool diameter from the tool table. If the P word is absent, the Face
Cycle Cut Width from the cycle parameter table is used. If P is less than 10 or
greater that 80 (that is, specifies an overlap less than 10% or greater than 80% of
the cutter diameter), an overlap of 10% or 80% is used and no alarm is reported.
The actual overlap is computed so that all passes remove the same amount of stock
and the overlap does not exceed the P word value.
G
The J word specifies the amount of finish stock to be left for those operations that
leave finish stock (Q = 0, 1, 10, 11 and 12). If the J word is absent, the Face Cycle
Finish Stock amount from the Cycle Parameter Table is used.
G
The F and S words specify the feedrate and spindle speed to be used for the finish
passes (if any). These items are cycle modal and do not affect the rough feed and
speed. When a cycle specifying a finish feedrate or speed completes, the original
modal feedrate and speed (that is, the roughing feedrate and speed) are restored.
Note that units of the feedrate and speed are determined by the feedrate mode (feed
per minute - G94 or feed per tooth - G95) and the spindle speed mode (spindle
A2100Di Programming Manual
Publication 91204426-001
84
Chapter 6
May 2002
Menu
speed in RPM - G97 or Spindle speed in Surface Feed per Minute) in effect when
the milling cycle is executed.
G
The start point (point #1) is located on the start-finish circle at a point defined by the
cutter overlap and clear of the face by the Face Cycle XY Clearance distance.
G
The Face Cycle XY Clearance, Face Cycle Cut Width, and Face Cycle Finish Stock
values are specified in the Cycle Parameter Table. The nominal diameter of the
milling cutter is required by the face milling cycles and must be present in the tool
table. The cycles use the sum of the Nominal Diameter and Diameter Offset fields
from the Tool Data Table, and the Diameter Offset from the active Programmable
Tool Offset as the tool diameter.
There must be clearance space around the face for the off-work moves. The
clearance area is a circle whose diameter is the face diameter (U word) plus twice
the cutter diameter plus twice the Face Cycle XY Clearance.
Cycle Actions (Bi-directional Milling, Q = 0, 1, 2, 3, 4, 5):
1. Move the non-spindle axes to the cycle start point in rapid (point #1).
2. Rapid the spindle axis to the clearance plane.
3. Rapid the spindle axis to the depth of cut (K word) below the reference plane or the
previously machined depth, or to final depth.
4. Feed in X to point #2.
5. Rapid in Y axis by the overlap distance to Point #3.
6. Feed in X to point #4 in the opposite direction to feed move step 4.
7. Rapid in Y by the overlap distance.
8. Repeat steps 4 to 7 until the face is completely machined.
9. If not at depth, rapid retract by a clearance amount to establish a new clearance
plane.
10. Repeat steps 1 to 9 until final depth is reached, including the finish cut if
programmed.
11. After the last pass over the face, rapid retract the spindle axis to the original
clearance plane or to the W word distance above the R plane (if the W word is
programmed), then rapid the other axes to the centre of the face.
A2100Di Programming Manual
Publication 91204426-001
85
Chapter 6
May 2002
Menu
Figure 7.21 G25 Unidirectional Milling
Cycle Actions (Unidirectional Milling, Q = 10, 11, 12, 13, 14, 15):
1. Move the non-spindle axes to the cycle start point in rapid (point #1).
2. Rapid the spindle axis to the clearance plane.
3. Rapid the spindle axis to the depth of cut (K word) below the reference plane or the
previously machined depth, or to final depth.
4. Feed in X to point #2.
5. Rapid retract by the depth of cut plus gage height.
6. Rapid to Point #3 (the start of the next pass).
7. Repeat steps 3 to 6 until the face is completely machined.
8. If not at depth, retract by a clearance amount to establish a new clearance plane.
9. Repeat steps 1 to 8 until final depth is reached, including finish cut, if programmed.
10. After the last pass over the face, rapid retract the spindle axis to the original
clearance plane or to the W word distance above the R plane (if the W word is
programmed), then rapid the other axes to the centre of the face.
A2100Di Programming Manual
Publication 91204426-001
86
Chapter 6
May 2002
Menu
Figure 7.22 G26 Circular Face Milling
G26 Circular Face Milling Example
To illustrate the specific action of the G26 cycle, the following program will execute a Bidirectional Circular Face Milling operation:
G Rough and Finish with Same Tool.
G T1 is a .750” Diameter End Mill.
Example
: G0 T1 M6
N10 S850 M13 F15
N20 G26 X2 Y1 U4 R0 Z-.5 Q0 K.25 P50 J.045 F10 S1000
N30 G0 M2
The total number of passes is calculated by the control as follows:
Rough Stock to remove
= J Word - I Word = .5 - .045 = .455
Cutter Efficiency
= Cutter Diameter x P word
Cutter Efficiency
= .750 inch x .50 = .375
U modified
= 4 + 1 mm or .003937 inch = 4.003937
Number of Face Passes
= U modified/Cutter Efficiency
Number of Face Passes
= .4.003937 = 10.677 or 11 face passes for each depth.
.375
True Cut Width
= U modified/Number of Face passes
True Cut Width
= 4.003937 = .36399
11
Notes
A2100Di Programming Manual
Publication 91204426-001
87
Chapter 6
May 2002
Menu
Sharpened or undersized cutters may initiate additional passes.
Tool Diameter is the sum of the Nominal Diameter from the Tool Data Table + Diameter
Offset from the Tool Data Table + Diameter Offset from the active Programmable Tool Offset
table. For this example only the Nominal Diameter is used.
X and Y start position 1 is calculated as follows:
YSP
= Y Centre + U + Tool Diameter - True Cut Width
2
2
YSP
= 1 + 4 + .750 - .36399 = 3.01101
2
2
Clearance Radius
= U + FAC_XY_CLR + Tool Diameter
2
2
Clearance Radius
= 4 + 02 + .750 = 2.395
2
2
XSP
= X Centre -
XSP
=2-
(Clearance_Radius )2 − ( YSP − YCenter)2
(2.395)2 − (3.01101− 1)2 = .69928
For this example the X and Y position 1 is: X 3.01101, Y.69928
Figure 7.23 G26.1 Circular Pocket
A2100Di Programming Manual
Publication 91204426-001
88
Chapter 6
May 2002
Menu
7.8.12
G26.1 Circular Pocket Cycle
The circular pocket cycle machines circular pockets in solid material, plunging the cutter
into the work using a helical ramp entry if the tool and pocket sizes allow sufficient room.
Permissible Tool Types
UNKNOWN, ROUGH END MILL, FINISH END MILL.
Parameters
G X word - X axis dimension of the centre of the pocket.
G
Y word - Y axis dimension of the centre of the pocket.
G
U word - Cycle modal finish pocket diameter.
G
R word - Modal Reference Plane dimension (Z dimension of work surface).
G
Z word - Modal milling cycle depth or bottom surface dimension.
G
Q word - Cycle modal cycle type.
G
L word - Plunge method (L=0 or not programmed - helical ramp/plunge; L=1 use
predrilled hole).
G
K word - Cycle modal Z axis cut depth for each pass of the pocket cycle.
G
E word - Cycle modal plunge feedrate, in the same units as the pocketing feedrate,
to be used when cutting the initial entry helix.
G
P word - Cycle modal width of cut, expressed as a percentage of the nominal tool
diameter, in the range 10 - 80.
G
I word - Cycle modal amount of stock to be left for finishing on the pocket sides.
G
J word - Cycle modal amount of stock to be left for finishing on the pocket bottom.
G
F word - Cycle modal finish feedrate.
G
S word - Cycle modal finish spindle speed.
G
W word - Nonmodal final retract distance from R plane (overrides Gage Height).
Programming Considerations
G The Q word defines the action of the cycle. The circular pocket cycle enters the work
by milling a helical ramp to the depth of each pass, unless a pre-drilled hole is
specified (L word = 1). Once the initial entry is complete, the cycle completes the
pocket by spiralling outward around the pocket using climb milling (Q = 0-5) or
conventional milling (Q = 10-15), ending with a circular pass at the rough size. The
finish passes around the pocket sides are either cut in one pass at full depth (Q = 0,
4, 10, 14) or in multiple passes using the K word depth increment (Q = 1, 5, 11, 15).
Climb
Q0
Q1
Q2
Q3
Conventional
Q10
Q11
Q12
Q13
Q4
Q14
Finish only, single pass on sides
Q5
Q15
Finish only, multiple finish passes on sides
A2100Di Programming Manual
Publication 91204426-001
Operations
Rough and finish, single finish pass on sides
Rough and finish, multiple finish passes on sides
Rough, leave finish stock
Rough to size
89
Chapter 6
May 2002
Menu
G
The L word modifies the method of entry into the workpiece for pockets requiring
roughing. L = 0 or not programmed signifies entry by plunging into the work along a
helical ramp whose outer diameter is 1.6 times the cutter diameter or the rough
pocket diameter, whichever is smaller, and with a lead of the depth of cut (K word).
The helical plunge cut is made at the feedrate specified by the E word.
Figure 7.24 G26.1 Circular
G
In some cases it may be preferable to produce the entry hole by drilling to depth with
a suitable drill, and then milling the pocket with a milling cutter that is not capable of
machining in Z. This is specified by programming L = 1. The entry hole is located at
the centre.
G
The P word specifies the maximum width of cut for each pass around the pocket as
a percentage of the nominal tool diameter from the tool table. If the P word is absent,
the Pocket Cycle Cut Width from the cycle parameter table is used. If P is less than
10 or greater that 80 (that is, specifies an overlap less than 10% or greater than 80%
of the cutter diameter), an overlap of 10% or 80% is used and no alarm is reported.
The actual overlap is computed so that all passes remove the same amount of stock
and the overlap does not exceed the P word value.
A2100Di Programming Manual
Publication 91204426-001
90
Chapter 6
May 2002
Menu
Figure 7.25 G26.1 Circular
G
The I word specifies the amount of finish stock to be left on the side of the pocket,
and the J word specifies the amount of finish stock to be left on the bottom of the
pocket for those operations that leave finish stock or perform finish passes (Q = 0, 1,
2, 5, 10, 11, 12, and 15). If the I word is absent, the Pocket Cycle Side Finish Stock
amount from the Cycle Parameter Table is used; if the J word is absent, the Pocket
Cycle Bottom Finish Stock amount from the cycle parameter table is used.
G
The finish pass (if required) is made in a single circular pass with tangent circle entry
and exit arcs. The exit arc is located 1 mm along the arc past the entry point to
ensure cleaning up the full surface.
G
The F and S words specify the feedrate and spindle speed to be used for the finish
passes (if any). These items are cycle modal and do not affect the rough feed and
speed. When a cycle specifying a finish feedrate or speed completes, the original
modal feedrate and speed (that is, the roughing feedrate and speed) are restored.
Note that units of the feedrate and speed are determined by the feedrate mode (feed
per minute - G94 or feed per tooth - G95) and the spindle speed mode (spindle
speed in RPM - G97 or Spindle speed in Surface Feed per Minute) in effect when
the milling cycle is executed.
G
Unless a pre-drilled entry hole is present (L = 1), the roughing cutter is used to
plunge cut into the work, and therefore must be capable of cutting in the Z direction.
The largest roughing cutter diameter is the requested pocket diameter (the U word)
minus twice the finish stock if finish stock is to be left (Q = 0, 1, 2, 10, 11, and 12). In
this case, the initial plunge is a vertical cut. For pockets up to 1.6 times the cutter
diameter, the entire roughing operation is completed by the initial helical entry ramp.
G
The finishing cutter is used to plunge into the stock while machining the bottom of
the pocket, and therefore must be capable of machining in the Z direction. The
largest finishing cutter diameter is four times the finish stock amount less than the
requested pocket diameter. The smallest finishing cutter diameter is such that the
overlap (P word times the cutter diameter) is greater than the finish stock specified.
G
The Pocket Cycle Cut Width, Pocket Cycle Side Finish Stock, Pocket Cycle Bottom
Finish Stock, Pocket Cycle Plunge Feedrate, and Gage Height values are specified
in the Cycle Parameter Table. The nominal diameters of the milling cutters are
required by the pocket milling cycles and must be present in the tool table. The
A2100Di Programming Manual
Publication 91204426-001
91
Chapter 6
May 2002
Menu
cycles use the sum of the Nominal Diameter and Diameter Offset fields from the
Tool Data Table and the Diameter Offset from the active Programmable Tool Offset
as the tool diameter.
Cycle Actions
1. Rapid the non-spindle axes to the cycle start point, which is offset from the pocket
centre along the -X axis by 30% of the cutter diameter or such that the edge of the
cutter is at the rough pocket size.
2. Rapid the spindle axis to the clearance plane.
If L = 0 or is not programmed:
3. Feed the spindle axis to the cut depth at the feedrate specified by the E word (or the
Pocket Cycle Plunge Feedrate cycle parameter if the E word is absent). The initial
feed is in a helix with a lead equal to the programmed depth of cut (K word). After
reaching the cut depth make one full pass at the cut depth to rough the initial circle to
depth. See the initial entry helix for the appearance after machining.
If L = 1:
4. An entry hole large enough to accommodate the roughing cutter is assumed to exist,
and the cutter is fed at the full modal feedrate to the cut depth at the cycle start point.
The entry hole must be located at the centre of the pocket.
5. Feed around the pocket in a spiral formed from 180 arcs until the endpoint of one arc
is at the rough diameter of the pocket; complete the roughing pass by a full circular
cut around the pocket. The spiral is cut at the active feedrate in the appropriate
direction based on climb or conventional milling, axis inversion states, and spindle
direction.
6. Rapid the spindle axis to a clearance amount above the just-cut surface and to the
XY co-ordinates of the cycle start point.
7. Repeat steps 3, 4, and 5 until the pocket is complete to the rough depth.
8. If finishing is specified (Q = 0, 1, 4, 5, 10, 11, 14, or 15), activate the F and S words
programmed in the pocket cycle block and complete steps 8 to 15.
9. Rapid the tool to the cycle start point in X and Y as described in step 1).
10. Rapid the spindle axis to a clearance height above the pocket bottom finish stock
level.
11. Feed the spindle axis to the final depth at the feedrate specified by the E word (or the
Pocket Cycle Plunge Feedrate cycle parameter if the E word is absent). This feed
motion uses the helical ramp and circular cleanup pass described in step 3.
12. Feed around the pocket in the spiral described in step 4 at the finish feedrate, in the
appropriate direction based on climb or conventional milling, axis inversion states,
and the spindle direction.
13. When the rough diameter of the pocket is reached, complete finishing the pocket
bottom with one complete circular pass around the pocket.
14. Rapid the tool to the finish cycle start point at depth K below the reference plane (for
Q = 1, 5, 11, or 15), or at final depth (for Q = 0, 4, 10, or 14).
15. Make one pass around the pocket in the appropriate direction based on climb or
conventional milling and the spindle direction, using tangent circular entry and exit
A2100Di Programming Manual
Publication 91204426-001
92
Chapter 6
May 2002
Menu
arcs. The exit arc is located 1 mm along the arc past the entry point to ensure
cleaning up the full surface.
16. Repeat steps 13 and 14 until the bottom of the pocket is reached.
17. Retract the spindle axis to the clearance plane or to the W word distance above the
R plane (if the W word is programmed), then rapid the other axes to the centre of the
pocket block.
G26.1 Circular Pocket Example
To illustrate the specific action of the G26.1 cycle, the following program specifications,
and Fig. 7.26, will be used.
G
Two Climb Milling passes.
G
Rough and Finish to Size, 3” Diameter.
G
Rough cycle with T1 .750” End Mill.
G
Finish cycle with T2 .500” End Mill.
G
No L word programmed, plunge into work helical ramp.
Example
: G0 T1 M6
N10 S850 M13 F5
N20 G26.1 X5 Y2 R0 Z-.25 U3 Q2 E5 K.15 I.02 P50
N30 G0 T2 M6
N40 G26.1 Q4 S1200 F20 M13
N30 G0 M2
X and Y start position 1 is calculated as follows:
Note
Tool Diameter is the sum of the Nominal Diameter from the Tool Data Table + Diameter
Offset from the Tool Data Table + Diameter Offset from the active Programmable Tool
Offset table. For this example only the Nominal Diameter is used.
XSP = X Centre Position - (30% x Tool Diameter).
XSP = 5 - (.30 x .750) = 4.77500.
YSP = Y Centre Position = 2.00000.
A2100Di Programming Manual
Publication 91204426-001
93
Chapter 6
May 2002
Menu
Figure 7.26 G26.1 Circular Pocket Milling Example Illustration
7.8.13
G27 Circular Inside Frame
The Circular Inside Frame cycle machines a circular pocket in the same manner as the
Circular Pocket cycle, but this cycle assumes that the centre of the pocket is free of
stock. As the inside of the pocket is open, the frame cycle does not have to make plunge
cuts and can be performed with an end mill that is not capable of Z axis milling. As with
rectangular frame milling, the bottom of the frame is assumed to be open and is not
machined.
Permissible Tool Types
UNKNOWN, ROUGH END MILL, FINISH END MILL .
Parameters
G X word - X axis dimension of the centre of the circular frame.
G Y word - Y axis dimension of the centre of the circular frame.
G U word - Cycle modal finished frame diameter.
G R word - Modal Reference Plane dimension (Z dimension of work surface).
G Z word - Modal milling cycle depth or bottom surface dimension.
G Q word - Cycle modal cycle type (see table).
G J word - Cycle modal amount of stock to be removed from the frame sides.
G K word - Cycle Z axis modal cut depth for each pass of the frame cycle.
G P word - Cycle modal width of cut, expressed as a percentage of the nominal tool
diameter, in the range 10 - 80.
A2100Di Programming Manual
Publication 91204426-001
94
Chapter 6
May 2002
Menu
G
G
G
G
I word - Cycle modal amount of stock to be left for finishing on the frame sides.
F word - Cycle modal finish feedrate.
S word - Cycle modal finish spindle speed.
W word - Nonmodal final retract distance measured from R - plane (overrides Gage
Height).
Programming Considerations
G
The Q word defines the action of the cycle as shown in the following table. The
circular inside frame cycle enlarges an existing opening by making spiral passes
around the frame using climb milling (Q = 0-5) or conventional milling (Q = 10-15) as
described under Circular Pocket Cycle. The finish passes around the circular frame
are either cut in one pass at full depth (Q = 0, 4, 10, 14) or in multiple passes using
the K word depth increment (Q = 1, 5, 11, 15).
Climb
Q0
Q1
Q2
Q3
Q4
Q5
G
Conventional
Q10
Q11
Q12
Q13
Q14
Q15
Operations
Rough and finish, single finish pass on sides
Rough and finish, multiple finish passes on sides
Rough, leave finish stock
Rough to size
Finish only, single pass on sides
Finish only, multiple finish passes on sides
The J word defines the amount of stock to be removed from the inside of the circular
frame, and therefore indirectly specifies diameter of the opening inside the frame
before machining. The finished circular frame is a circle of diameter U; the inside
opening is assumed to be a circular opening U -2*J in diameter.
Figure 7.27 G27 Circular
A2100Di Programming Manual
Publication 91204426-001
95
Chapter 6
May 2002
Menu
G
The P word specifies the maximum width of cut for each pass around the frame as a
percentage of the nominal tool diameter from the tool table. If the P word is absent,
the Frame Cycle Cut Width from the cycle parameter table is used. If P is less than
10 or greater that 80 (that is, specifies an overlap less than 10% or greater than 80%
of the cutter diameter), an overlap of 10% or 80% is used and no alarm is reported.
The actual overlap is computed so that all passes remove the same amount of stock
and the overlap does not exceed the P word value.
G
The I word specifies the amount of finish stock to be left on the sides of the circular
frame for those operations that leave finish stock or perform finish passes (Q = 0, 1,
2, 5, 10, 11, 12, and 15). If the I word is absent, the Frame Cycle Side Finish Stock
amount from the Cycle Parameter Table is used.
G
The finish pass around the sides of the frame is identical to the finish pass for a
circular pocket except that the bottom is not machined.
G
The F and S words specify the feedrate and spindle speed to be used for the finish
passes (if any). These items are cycle modal and do not affect the rough feed and
speed. When a cycle specifying a finish feedrate or speed completes, the original
modal feedrate and speed (that is, the roughing feedrate and speed) are restored.
Note that units of the feedrate and speed are determined by the feedrate mode (feed
per minute - G94 or feed per tooth - G95) and the spindle speed mode (spindle
speed in RPM - G97 or Spindle speed in Surface Feed per Minute) in effect when
the milling cycle is executed.
G
The largest roughing cutter diameter is the U diameter minus twice the stock to be
removed minus twice the Frame Cycle XY Clearance. This assures that the cutter
can be placed in the opening inside of the frame.
G
The largest finishing cutter diameter is the U diameter minus four times the finish
stock on the pocket sides. The smallest finishing cutter diameter is such that the
overlap (P word times the cutter diameter) is greater than the finish stock specified.
G
The Frame Cycle XY Clearance, Frame Cycle Cut Width, Frame Cycle Side Finish
Stock, and Gage Height values are specified in the Cycle Parameter Table. The
nominal diameters of the milling cutters are required by the frame milling cycles and
must be present in the tool table. The cycles use the sum of the Nominal Diameter
and Diameter Offset fields from the Tool Data Table and the Diameter Offset from
the active Programmable Tool Offset as the tool diameter.
Cycle Actions
1. Rapid the non-spindle axes to the cycle start point, which is in the -X direction on the
X axis diameter of the frame and Frame Cycle XY Clearance away from the inside
surface of the frame.
2. Rapid the spindle axis to the clearance plane.
3. Feed the Z axis to the cut depth at the modal feedrate.
4. Feed around the frame in a spiral formed from 180º arcs until the endpoint of one arc
is at the rough diameter of the frame; complete the roughing pass by a full circular
cut around the frame. The spiral is cut at the active feedrate in the appropriate
direction based on climb or conventional milling, axis inversion states, and the
spindle direction.
5. If not yet at full depth, rapid the spindle axis to a clearance amount above the just-cut
surface and to the XY co-ordinates of the cycle start point.
A2100Di Programming Manual
Publication 91204426-001
96
Chapter 6
May 2002
Menu
6. Repeat steps 3, 4, and 5 until the frame is complete to depth.
7. If finishing is specified (Q = 0, 1, 4, 5, 10, 11, 14, or 15), activate the F and S words
programmed in the frame cycle block and complete steps 8, 9, and 10.
8. Rapid the tool to the finish cycle start point at depth K below the reference plane (for
Q = 1, 5, 11, or 15), or at final depth (for Q = 0, 4, 10, or 14).
9. Make one pass around the frame in the appropriate direction based on climb or
conventional milling and the spindle direction using tangent circular entry and exit
arcs. The exit arc is located 1 mm along the arc past the entry point to ensure
cleaning up the full surface.
10. Repeat steps 8 and 9 until the bottom of the frame is reached.
11. Retract the spindle axis to the original clearance plane or the W word distance above
the R - plane (if the W word is programmed), then rapid the other axes to the centre
of the frame.
To illustrate specific action of the G27 cycle, the following program specifications, and
Fig.7.28, will be used:
G
Two passes, climb milling rough only Q3
G
Finish Size, 6” Diameter using T1 .750” End Mill
G
Circular opening U - 2(J) or 6 - 2(.5) = 5
Example
: G0 T1 M6
N10 S900 M13 F5
N20 G27 X1 Y1 R0 Q3 P50 U6 J.5 Z-.5 K.25
N30 G0 M2
X and Y start position 1 is calculated as follows:
Note
Tool Diameter is the sum of the Nominal Diameter from the Tool Data Table + Diameter
Offset from the Tool Data Table + Diameter Offset from the active Programmable Tool
Offset table. For this example only the Nominal Diameter is used.
XSP = X Centre Position - U - (TD + J Word + XY Clearance)
2 2
XSP = 1 - 6 - (.750 + .5 + .02) = -1.10500
2
2
YSP = Y Centre Position = 1.00000
A2100Di Programming Manual
Publication 91204426-001
97
Chapter 6
May 2002
Menu
Figure 7.28 G27 Circular Inside Frame Milling Example Illustration
7.8.14
G27.1 Circular Outside Frame
The Circular Outside Frame cycle machines the outer surface of a circular shape which
is assumed to have adequate clearance on all sides to allow access by the selected
cutter.
Permissible Tool Types
UNKNOWN, ROUGH END MILL, FINISH END MILL.
Parameters
G
X word - X axis dimension of the centre of the frame.
G
Y word - Y axis dimension of the centre of the frame.
G
U word - Cycle modal finished frame diameter (Z dimension of part surface).
A2100Di Programming Manual
Publication 91204426-001
98
Chapter 6
May 2002
Menu
G
R word - Modal Reference Plane dimension.
G
Z Axis - Modal milling cycle depth or bottom surface dimension.
G
Q word - Cycle modal cycle type.
G
J word - Cycle modal amount of stock to be removed from the frame sides.
G
K word - Cycle modal Z axis cut depth for each pass of the frame cycle.
G
P word - Cycle modal width of cut, expressed as a percentage of the nominal tool
diameter, in the range 10 - 80.
G
I word - Cycle modal amount of stock to be left for finishing on the frame sides.
G
F word - Cycle modal finish feedrate.
G
S word - Cycle modal finish spindle speed.
G
W word - Nonmodal final retract distance (overrides Gage Height).
Programming Consideration
G
The Q word defines the action of the cycle as shown in the table following. The
circular outside frame cycle machines the outside of a circular pad or boss by
making spiral passes around the frame using climb milling (Q = 0-5) or conventional
milling (Q = 10-15) as described under the Circular Pocket Cycle, but with
decreasing diameter. The finish passes around the circular frame are either cut in
one pass at full depth (Q = 0, 4, 10, 14) or in multiple passes using the K word depth
increment (Q = 1, 5, 11, 15).
Climb
Q0
Q1
Q2
Q3
Q4
Q5
G
Conventional
Q10
Q11
Q12
Q13
Q14
Q15
Operations
Rough and finish, single finish pass on sides
Rough and finish, multiple finish passes on sides
Rough, leave finish stock
Rough to size
Finish only, single pass on sides
Finish only, multiple finish passes on sides
The J word defines the amount of stock to be removed from the outside of the
circular frame, and therefore indirectly specifies diameter of the rough size of the
pad or boss before machining (see Fig. 7.29). The finished circular frame is a circle
of diameter U; the rough boss is assumed to be circular with a diameter of U + 2*J.
A2100Di Programming Manual
Publication 91204426-001
99
Chapter 6
May 2002
Menu
Figure 7.29 G27.1 Circular Outside Frame
G
The P word specifies the maximum width of cut for each pass around the frame as a
percentage of the nominal tool diameter from the tool table. If the P word is absent,
the Frame Cycle Cut Width from the cycle parameter table is used. If P is less than
10 or greater that 80 (that is, specifies an overlap less than 10% or greater than 80%
of the cutter diameter), an overlap of 10% or 80% is used and no alarm is reported.
The actual overlap is computed so that all passes remove the same amount of stock
and the overlap does not exceed the P word value.
G
The I word specifies the amount of finish stock to be left on the sides of the circular
frame for those operations that leave finish stock or perform finish passes (Q = 0, 1,
2, 5, 10, 11, 12, and 15). If the I word is absent, the Frame Cycle Side Finish Stock
amount from the Cycle Parameter Table is used.
G
The F and S words specify the feedrate and spindle speed to be used for the finish
passes (if any). These items are cycle modal and do not affect the rough feed and
speed. When a cycle specifying a finish feedrate or speed completes, the original
modal feedrate and speed (that is, the roughing feedrate and speed) are restored.
Note that units of the feedrate and speed are determined by the feedrate mode (feed
per minute - G94 or feed per tooth - G95) and the spindle speed mode (spindle
speed in RPM - G97 or Spindle speed in Surface Feed per Minute) in effect when
the milling cycle is executed.
G
The Frame Cycle XY Clearance, Frame Cycle Cut Width, Frame Cycle Side Finish
Stock, and Gage Height values are specified in the Cycle Parameter Table. The
nominal diameter of the milling cutters is required by the frame milling cycles and
must be present in the tool table. The cycles use the sum of the Nominal Diameter
and Diameter Offset fields from the Tool Data Table, and the Diameter Offset from
the active Programmable Tool Offset, as the tool diameter.
A2100Di Programming Manual
Publication 91204426-001
100
Chapter 6
May 2002
Menu
G
The nominal diameters of the roughing and finishing milling cutters are required by
the pocket milling cycles and must be present in the tool table.
Cycle Actions
1. Rapid the non-spindle axes to the cycle start point, which is on the X axis diameter of
the boss away from the outside surface of the frame on the -X side of the part, by the
stock amount (J word) plus Frame Cycle XY Clearance.
2. Rapid the Z axis to the clearance plane.
3. Rapid the spindle in Z to the K word amount below the work surface, or to final
depth.
4. Feed around the frame in a spiral formed from 180º arcs until the endpoint of one arc
is at the rough diameter of the frame; complete the roughing pass by a full circular
cut around the frame. The spiral is cut at the active feedrate in the appropriate
direction based on climb or conventional milling, axis inversion states, and the
spindle direction. Each arcs endpoint is closer to the centre of the frame by one half
of the cutter overlap (P word times cutter diameter).
5. Rapid the cutter from the end position to the start position for the next pass. This
move is performed by retracting by a clearance amount in both X and Z, then rapids
to the next pass start point in X. The start point for the next pass will always be on
the same side of the frame as the end point of the last pass. Therefore, for an odd
number of 180 arcs the start point will alternate between the +X and the -X side of
the frame for each subsequent pass. For an even number of arcs, the start point will
always be on the -X side.
6. Repeat steps 3, 4, and 5 until the frame is complete to depth.
7. If finishing is specified (Q = 0, 1, 4, 5, 10, 11, 14, or 15), activate the F and S words
programmed in the frame cycle block and complete steps 8, 9, and 10.
8. Rapid the tool to the finish cycle start point at depth K below the reference plane (for
Q = 1, 5, 11, or 15), or at final depth (for Q = 0, 4, 10, or 14). This point is on the X
axis diameter of the frame, away from the part by twice the finish stock amount (I
word) on the same side of the frame as the end point of the last roughing pass. If no
roughing pass is required, the finish start point will be on the -X side of the frame.
9. Make one pass around the frame in the appropriate direction based on climb or
conventional milling and the spindle direction. The entry and exit from the cut are
made using tangent circular arcs with a radius of the finish stock amount. The exit
arc tangent point overlaps the entry arc tangent point by 1mm on the frame
circumference.
10. Repeat steps 8 and 9 until the bottom of the frame is reached.
11. Retract the spindle axis to the original clearance plane or the W word distance above
the R - plane (if the W is programmed), then rapid the other axes to the centre of the
pocket.
G27.1 Circular Outside Frame Milling Example
To illustrate specific action of the G27.1 cycle, the following program specifications, and
Fig 7.30, will be used:
G
Conventional Milling rough and finish, single finish pass on sides Q10, passes at
three Z axis depths
A2100Di Programming Manual
Publication 91204426-001
101
Chapter 6
May 2002
Menu
G
One Finish Conventional Milling pass will be at final depth with increased spindle
speed and feedrate.
G
Rough/Finish cycle with T1 .750” End Mill.
Example
: G0 T1 M6
N10 S900 M3 F5
N20 G27.1 X0 Y0 U5 R0 Z-.75 J.5 P50 Q10 K.25 I.03 S1200 F10
N30 G0 M2
X and Y start position 1 is calculated as follows:
Note
Tool Diameter is the sum of the Nominal Diameter from the Tool Data Table + Diameter
Offset from the Tool Data Table + Diameter Offset from the active Programmable Tool
Offset table. For this example only the Nominal Diameter is used.
XSP = X Centre Position - U - (TD + J Word + XY Clearance)
2 2
XSP = 0 - 5 - (.750 + .5 + .02) = -3.39500
2
2
YSP = Y Centre Position = 0.00000
A2100Di Programming Manual
Publication 91204426-001
102
Chapter 6
May 2002
Menu
Figure 7.30 G27.1 Circular Outside Frame Milling Example Illustration
G37, G38, G39 Pattern Cycles (Option)
These Pattern Cycles are used in conjunction with the G80 hole making cycles, the G22
- G27.1 milling cycles, and user written subroutines to specify patterns of holes or
pockets to be machined.
G38 specifies a rectangular grid of operations and G39 specifies a pattern of operations
on an arc of a circle. The active G38 or G39 code is cancelled by a G37.These
Preparatory Codes group remains selected until cancelled by G37.
In both cases, the block containing the G38 or G39 code defines a set of values that
defines a pattern of operations. These values are stored and used by subsequent G80
series hole making blocks, milling cycle blocks, or user written pattern subroutines.
A2100Di Programming Manual
Publication 91204426-001
103
Chapter 6
May 2002
Menu
Blocks with interpolation modes other than the G80 series fixed cycles, milling cycles, or
user pattern subroutines ignore the active pattern.
8
End of Cycle Incremental Retract Dimension (W word)
The G38 and G39 pattern cycles finish with the tool at the position specified by the
selected operation, usually the clearance plane.
These pattern cycles also accept an optional, nonmodal W word that specifies a rapid
move to a point above the work surface (reference plane). The W word value is the
incremental distance above the reference plane (nominal work surface). Programming
the W word on the pattern cycle causes the additional retract move following the last
operation in the pattern. If the hole making or milling cycle specifies a W word, that value
is used after each operation in the pattern.
The W word may be programmed on the operation block, the pattern cycle block, or both
the pattern cycle and the operation block if an extra retract is required for each hole and
for the pattern. The incremental retract distances are separate; that is, the W word on
the operation can be a different value from that on the pattern cycle block. If the W word
specifies a location closer to the work surface than the current position, the W word is
ignored.
9
Invoking User Subroutines by a Pattern
The pattern cycles set-up information that defines the set of locations at which to perform
an operation. The blocks following a pattern block execute normally unless they specify
operations that are pattern sensitive.
The control G80 series hole making operations and the G22 - G26 milling cycles are
automatically pattern sensitive. User written subroutines can also be made pattern
sensitive. This is done by specifying that the subroutine is a pattern subroutine when the
subroutine is written. This has the effect of activating pattern co-ordinates when the
subroutine is entered.
10
G36 Move to Next Operation Site
A G36 must be programmed in a user NC program subroutine designated as a pattern
subroutine before the blocks that define the operation. If a pattern is active, the G36
causes a move from the current location to the next operation site defined by the pattern.
The G36 block can also specify the origin for pattern co-ordinates relative to the
operation site and can specify an offset to be included in the move to the operation site.
The pattern co-ordinate offset allows the pattern co-ordinates to be set-up with the
pattern co-ordinate origin at a point other than the reference point of the operation. The
offset move allows the subroutine to ask the pattern cycle to move to some point other
than the defined reference point to avoid wasted motion.
The G36 block allows a sequence number and a block label, and uses the following
parameters:
G
P - The P word specifies the type of the subroutine. The valid values are:
G
P0 or absent: the subroutine ignores patterns (and G36 ignores the I, J, K, X, Y, and
Z words).
P1: the subroutine responds to pattern cycles and executes in pattern co-ordinates.
A2100Di Programming Manual
Publication 91204426-001
104
Chapter 6
May 2002
Menu
P2: the subroutine responds to pattern cycles and executes in NC program coordinates.
G
I, J, K - These words define an incremental vector from the operation site (at current
spindle depth) to the required PCS origin (at R plane). All three axes are used. These
words do not cause axis motion, but are used to offset the origin of the Pattern Coordinate System from the next pattern operation location.
Note that the G36 does not move the Z axis when moving from one operation location
to the next, but instead uses the Z axis position that resulted from the operation. This
means that the Z axis position following an operation can vary depending on the
operation performed. For the first operation, Z is where the NC program placed it prior
to invoking the pattern. For the second and subsequent operations, Z is where the
operation left it.
When using the G80 series hole making cycles or the G20 series milling cycles, for
example, Z is normally left at the R plane, but may be moved to a different location if
the W word is included.
G
X, Y, Z - These words define an incremental vector from Pattern Co-ordinate System
origin to the machining start position. Only the two axes in the currently selected
plane are used. The effect of programming X, Y, and Z is to cause the G36 to move
to the machining start location for the next operation rather than the operation
location specified by the pattern. The motion is to the X, Y, and Z values in the newly
activated pattern co-ordinates.
G
The purpose of the I, J, and K word offset is to allow the co-ordinate system for the
pattern subroutine to have its origin at a meaningful point in terms of the operation,
and still allow the reference point of the operation to be at some other point. For
example, the A2100 rectangular milling cycles allow the reference point of the
rectangle to be either the centre or one corner.
Internally, these two different specifications call a single operation that places pattern
co-ordinates at the centre of the rectangle. This is done by specifying an offset from
the pattern location (which refers to the reference corner of the geometry for G22.1)
to the centre of the rectangle, thus making the geometry identical to that for the
centre specified case.
G
10.1
The purpose of the X, Y, and Z words is to specify an additional distance to move
from the reference point of the geometry to the actual machining start point. Use of
the X, Y, and Z words allows A2100 to combine the G36 move to the next pattern
location and the move from the pattern location to the machining start point in to a
single rapid span, thus saving time and avoiding the extra move.
Specific Action of G36
G
Turns off pattern co-ordinates in case they are on.
G
If G38 or G39 patterns are active, computes the site of the next operation; if patterns
are inactive (G37), uses the current axis positions as the operation site. In either
case, it adds I, J, and K to the site to get the location of the PCS origin; and also adds
two axes to X, Y, and Z to the result to get the location of the machining start point.
G
Rapids to the machining start point simultaneously in X, Y, Z.
G
Only in case P1, enables pattern co-ordinates with origin at the PCS origin, and with
rotation about that origin selected by pattern rotation and by & O. When pattern coordinates are enabled the co-ordinates of the location just acquired become two axes
of X,Y, and Z, and, in the spindle axis, -I, -J, or -K.
A2100Di Programming Manual
Publication 91204426-001
105
Chapter 6
May 2002
Menu
If a subroutine is pattern sensitive but does not use pattern co-ordinates (DFS, , , P2),
execution of G36 may be skipped if patterns are inactive, as:
(IF [&PATTERN] THEN)
G36 P2
(ENDIF)
G36.1 Pattern End/Retract
Parameters
None.
This G - sub MUST be executed unconditionally at the end of any subroutine that is
pattern sensitive (DFS, , , P1) or (DFS, , , P2). Failure to do so could lead to unterminated re-execution of the subroutine.
10.2
Specific Action of G36.1
If G38/G39 patterns are active, and if G36 has moved to the last operation site, then
G36.1:
G
Performs the optional G38/39 W - retract move.
G
Allows the invoking subroutine to terminate at its (ENS) instead of repeating.
G
Turns off pattern co-ordinates.
If G38/39 patterns are inactive (G37), then:
G
Allows the invoking subroutine to terminate at its (ENS).
G
Turns off pattern co-ordinates.
G38 Rectangular Pattern (Option)
Rectangular Pattern (G38) code establishes a rectangular pattern of operations. The
number of operations in each line and the number of lines, as well as the spacing
between operations and lines, are specified. Depending upon how the distances
between operations are specified, the reference corner of the pattern can be any of the
corners of the rectangle.
The pattern is specified independent of the machine axes. When the pattern is applied,
the lines of operations are aligned with the reference axis, which is the first axis in the
pattern plane. For example, if the pattern is executed in the XY plane, the reference axis
is the X axis. The rectangular pattern can also be specified to be at an angle to the
positive reference axis.
To invoke a rectangular pattern, the NC program first moves (usually in rapid traverse,
G0) to the co-ordinates at which the pattern of operations is to be executed. Then the
NC program invokes the G38 pattern block, defining the grid of operation sites.
Following the pattern, the series of G80 series hole making cycles, milling cycle blocks,
or user-written pattern sensitive subroutines that are to be executed is specified. Finally,
a G37 cancels the pattern.
The rectangular pattern is executed in the plane perpendicular to the spindle axis. For
many machines, the spindle axis is always the Z axis, and the pattern is executed in the
A2100Di Programming Manual
Publication 91204426-001
106
Chapter 6
May 2002
Menu
XY plane. For other machines, the spindle axis may change as right angle heads are
fitted, or the spindle may rotate so that it is not parallel to Z.
The pattern cycles are configurable to match the machine type. The description that
follows is general; the pattern moves between operations take place in the plane
perpendicular to the spindle axis and the final retract (W word) occurs in the spindle axis.
Cycle Actions
The G38 block sets up the parameters for the selected grid of locations. The subsequent
blocks containing G80 series hole making cycles, milling cycles, or calls to user pattern
subroutines activate the pattern; each such block executed with G38 active is repeated
for each pattern location specified by the G38. If the operation specifies an optional W
word retract, the retraction is performed on every operation in the pattern. If the G38
block also specifies a W word retract, it is performed after the last operation of the
pattern.
Parameters
G
I word - Cycle modal of operations per line.
G
U word - Cycle modal spacing between operations.
G
J word -Cycle modal number of lines of operations (default is 1).
G
V word - Cycle modal spacing between lines of operations.
G
O word - Cycle modal angle of pattern from reference axis.
G
R word - Cycle modal operation rotation (0 rotate, 1 do not rotate).
G
W word - Nonmodal final retract distance (after last operation or pattern).
G
S word - Nonmodal word specifying the operation at which to start.
G
The sign of the U and V words determines the reference corner of the pattern. This
is the machine position when the pattern starts execution; and is the location of the
first operation of the pattern. The grid of locations is created by moving the signed U
word increment in the first axis, and the signed V word increment in the second axis.
If the selected plane is XY, the first axis is X and the second is Y.
G
The S word specifies the operation at which to start, and is used primarily to restart a
pattern after the pattern has been interrupted. The value of the S word is the
operation number. One specifies the first operation, two the second and so on.
Reference Corner(Hole Number)
1
5
20
16
Sign
+U +V
-U +V
+U -V
-U -V
Operation Sequence
1-5, 6-10, 11-15, 16-20
5-1, 10-6, 15-11, 20-16
20-16, 15-11, 10-6, 5-1
16-20, 11-15, 6-10, 1-5
In Fig. 7.31, the grid consists of 5 evenly spaced operation locations along the first axis,
and 4 evenly spaced rows of operation locations along the second axis. If J is zero or not
programmed, one line of operations is produced. The sequence of operations is
performed according to the signs of the U and V words, which also determines the
reference corner. The following example illustrates these reference corners. The
numbers in the Operation Sequence column (in the Table above) define the machining
sequence based on the U and V sign.
A2100Di Programming Manual
Publication 91204426-001
107
Chapter 6
May 2002
Menu
Figure 7.31 G38 Rectangular Pattern
The grid of locations is rotated by the angle specified in the O word from the positive
direction of the reference axis. If the O word is omitted, the grid is aligned along the axes
of the selected plane. The operation performed at each location is rotated so that the
pattern co-ordinate system aligns along the angle specified by the O word if operation
rotation is specified by omitting the R word or setting the R word to 0. If the R word is set
to 1, the pattern co-ordinate system is not rotated, even though the pattern is rotated.
Example
A line of 10 locations spaced 25.0mm apart at an angle of 30 degrees from the X axis,
with the first hole located at X20.0mm and Y200.0mm, it is specified as:
G0 X20 Y200
G38 I10 U25 O30
Figure 7.32 G38 Rectangular Pattern Cycle Example
If the operations in the example are milling cycles or user subroutines, the rotation of the
pattern by the O word may rotate the operation (R = 0) or leave the operation in the
A2100Di Programming Manual
Publication 91204426-001
108
Chapter 6
May 2002
Menu
unrotated orientation (R = 1). The effect of the R word is shown by the following
examples.
The pattern:
G0 X500 Y35:
G38 I4 U25 O30 R1
generates four unrotated operations spaced along a line at a 30 degree angle to the +X
axis. If the G38 block specifies R0 or omits the R word, the pattern is rotated to align
along the direction of the pattern.
Figure 7.33 G38 Rectangular Pattern Cycle Rotated
Operations are cancelled by using G37 Data Reset
Programming Considerations
G
When a pattern is programmed it is modal until cancelled by a cancel pattern code
(G37), data reset, or end of program. This enables multiple G80 series milling
cycles, or user written subroutine operations to be carried out on the active pattern
without the need to re-program the geometry.
G
When an operation is programmed the information is stored by the control for future
use with G80 series fixed cycles or subroutines.
G
The incremental dimensions between operations and lines are signed oriented to
establish the reference corner of the pattern. If no position move (G0) is
programmed the machine position at the time the G38 is executed will be the first
pattern location.
G
The signs of U and V words in the G38 block determine the pattern reference corner.
G
If J is zero or not programmed, one line of operations is produced.
A2100Di Programming Manual
Publication 91204426-001
109
Chapter 6
May 2002
Menu
To illustrate the specific action of the G38 cycle the following program will create a
rectangular pattern, using a G81 drill cycle, then taps each hole in the rectangular
pattern using G84. After each drill and tap operation the spindle will retract to 1 inch
above the clearance plane. When all drill operations are complete the spindle axis will
retract to 2 inches above the clearance plane.
G
J4 Indicates 4 lines in the pattern
G
I4 Indicates 5 operations per line
G
U1 Is a distance of 1 inch between holes
G
V1 Is the distance between lines or 1 inch.
Example
: 01 M6 T2
N10 G0 X1 Y1
N20 G38 U1 V1 I5 J4 W2
N30 M3 S850
N40 G81 Z-1.1 R0 F10 W1
N50 G0 M5 T3 M6
N60 G0 X1 Y1
N70 G81 R0 Z-1.5 F15 S970 M3 W1
N80 G0 T4 M6
N90 G0 X1 Y1
N100 G84 J2 R0 Z -1.2 S200 M3 F10 W1
N60110 G37
N70120 M2
Block 01
G
: Provides Synchronisation of the control system.
G
The M6 code is used for a tool change if proper tool is not selected. T2 identifies a
centre drill from the tool table.
Block N10
G
The G0 code simultaneously rapids X and Y axes to the centre point of the first hole
X1,Y1 inch.
Block N20
G
G38 sets Rectangular Pattern mode and identifies the pattern.
G
Since the sign of U and V are both plus, corner 1 is the starting point of this pattern.
G
U1 represents an incremental distance of 1 inch between hole centres in a row. The
1 inch distance will be in the +X direction from the reference corner.
G
V1 represents the incremental distance of 1 inch between lines of hole centres. The
1 inch distance will be in the +Y direction from the reference corner.
G
I5 Indicates 5 holes in each line.
G
J4 Indicates 4 lines in the pattern.
A2100Di Programming Manual
Publication 91204426-001
110
Chapter 6
May 2002
Menu
G
W2 is the final retract distance after all drilling operation are complete.
Block N30
G
Starts spindle clockwise at 850 RPM.
Block N40
G
G81 code indicates a Drill cycle.
G
Z axis rapids to clearance plane then rapids to hole No. 1.
G
Z axis feeds to -.1 inch at the programmed rate F10 ipm.
G
Z axis retracts to one inch above the work surface. X and Y axes rapid to hole No. 2,
the second hole in the first line.
G
This action is repeated until all holes in the first line are completed.
G
When the last hole of the first line is completed, X and Y axes rapid to position No. 6.
G
The fourth and fifth serpentine steps are repeated until all holes in the J and I words
are completed. After each drilling operation the spindle axis retracts to one inch
above the work surface as specified by the W word.
Block N50
G
M5 stops spindle rotation, Performs tool change to select T3 Drill.
Block N60
G
Rapids non spindle axes to X1 and Y1, start of hole No. 1.
Block N70
G
Z axis rapids to clearance plane then feeds to - 1.5 at hole No. 1. The serpentine
drilling (G81) sequence described in Block N40 is repeated.
Block N80
G
M5 stops spindle rotation, Performs tool change to select T4 Tap.
Block N90
G
Rapids non spindle axes to X1 and Y1, start of hole No. 1.
Block N100
G
Z axis rapids to clearance plane then feeds to - 1.2 at hole No. 1. The serpentine
tapping (G84) sequence described in Block N40 is repeated. Since J2 is
programmed, feedrate and spindle speed are doubled during retraction at each hole.
Block N110
G
G37 cancels the G38 Rectangular Hole Pattern command. Z axis retracts to the W2
distance.
Block N120
G
M2 ends the program.
A2100Di Programming Manual
Publication 91204426-001
111
Chapter 6
May 2002
Menu
Figure 7.34 G39 Circular Pattern
G39 Circular Pattern
The G39 Circular Pattern code establishes a pattern of locations on the periphery of a
circle or circle arc. Words in the G39 block establish the centre and diameter of the
circle, the number of locations, the location of the first operation, and the included angle
between the first and last location if less than a full circle is specified.
The pattern is specified independent of the machine axes. When the pattern is applied,
the circle of operations is oriented with respect to the reference axis, which is the first
axis in the pattern plane. If the pattern is executed in the XY plane the reference axis is
the X axis; if executed in the ZX plane the reference axis is Z; if executed in YZ plane the
reference axis is Y.
Parameters
G <axes> Location of the centre of the pattern, where <axes> includes any of X,Y,Z.
G P Angular location of the first operation measured counterclockwise from the positive
direction of the reference axis.
G D Diameter of pattern circle.
G I Reference axis co-ordinate of first operation location.
G J Second axis co-ordinate of the first operation location.
G K Number of locations.
G O Included angle between first and last operation.
G R Cycle modal operation rotation (0 - rotate, 1 - do not rotate).
G F Modal feedrate.
G S Nonmodal word specifying the operation at which to start.
G W Final retract distance (after last operation of pattern).
A2100Di Programming Manual
Publication 91204426-001
112
Chapter 6
May 2002
Menu
Note
The location of the first operation can be given by programming either:
G
The operation circle diameter and the angular displacement of the first operation
from the positive direction of the reference axis (using the P word).
G
Or the Cartesian co-ordinates in the pattern plane of the location of the first
operation (using I and J words).
Note that if I and/or J are present, D and P are not allowed.
Circular Pattern programs can be cancelled by using: G37 Data Reset.
Cycle Action
G
The axis words in the G39 block specify the co-ordinates of the centre of the pattern
circle. If any axis word is absent, the current location is used. The co-ordinates in the
blocks that specify the operations to be performed at the pattern location are
ignored.
G
The location of the first operation is specified by programming either the Cartesian
co-ordinates of the first operation, using the I and J words, or by programming the
diameter of the operation circle in the D word and the angular location of the first
operation with respect to the positive direction of the reference axis in the P word. If I
and/or J are present, D and P are not allowed.
G
The location of the remainder of the operations is specified by the pattern circle, the
total included angle between the first and last location (the O word), and the number
of locations (the K word).
If the O word is omitted, a full circle is assumed and the operations are performed
moving counterclockwise around the pattern. If the O word is present, its sign
determines the direction of motion between the pattern locations: positive specifies
counterclockwise, negative specifies clockwise.
Fig. 7.35 illustrates a circular pattern of eight locations with No O word programmed.
Figure 7.35 Circular Pattern
Figure 7.36 illustrates a circle pattern of four locations with an O word of -135 degrees
programmed.
A2100Di Programming Manual
Publication 91204426-001
113
Chapter 6
May 2002
Menu
G
Figure 7.36 Circular Pattern 4 Holes
G39 moves the non-spindle axes motion in rapid traverse to the first operation
location.
G
The remainder of the operations are performed moving around the circle in the
direction specified by the O word. Positive values move counterclockwise, negative
values move clockwise. Full circles are machined in a counterclockwise direction.
G
If no O word is programmed, the pattern will be equally spaced around the complete
circle.
G
If the R word is zero or absent, the operation performed at each location is rotated
so that the pattern co-ordinate system aligns with the angle from the centre of the
pattern to the site of the operation. If R = 1, the operation performed at each location
is not rotated as the pattern is repeated around the circle.
G
If the operation specifies an optional W word retract, the retraction is performed on
every operation in the pattern. If the G39 block also specifies a W word retract the
G39 W word is used after the last operation of the pattern.
G
When a G37 is programmed all pattern data is deleted. Subsequent G80 series
blocks produce a single operations in accordance with their specification.
G
The optional S word specifies the operation number at which to start the pattern. The
S word value must be between 1 and the number of operations (which is the K word
value). If the S word is present, all operations before the operation specified by the S
word are skipped.
The primary purpose for the S word is to resume a pattern that was interrupted by an
unplanned stop.
To illustrate specific action of the G39 cycle the following program will create 10 holes
equally spaced around a 6 inch diameter circle using a G81 Drill cycle.
Example
:01 G0 T3 M6
N10 G39 X0 Y0 D6 P0 K10 W2
A2100Di Programming Manual
Publication 91204426-001
114
Chapter 6
May 2002
Menu
N20 M3 S850
N30 G81 Z-1 R0 F10 W1
N40 G37
N50 G0 M2
Block :01
G : Provides synchronisation of the control system.
G T3 identifies a drill from the tool table. The code M6 is used for tool change if proper
tool is not selected.
Block N10
G G39 initiates circular pattern mode.
G X0, Y0 establish the centre point of the circular hole pattern.
G D6 specifies the diameter of the ring of holes to be 6 inches.
G P0 specifies angle of first hole, zero degrees from the +X axis.
G K10 specifies the number of holes.
G W2 specifies last hole retract distance of two inches.
G As no O word is specified the hole pattern will be equally spaced in a
counterclockwise direction.
G The non-spindle axes rapid to X3, Y0, the location of the first hole.
Block N20
G M3 turns spindle on clockwise at 850 RPM.
Block N30
G G81 code specifies Drill Cycle.
G Z axis rapids to clearance plane.
G Z axis feeds to the programmed depth of -1 inch at the programmed rate of 10 ipm.
G After reaching depth, Z axis retracts to 1 inch above the work surface and nonspindle axes move to the next hole.
G As no O direction sign/spacing word is programmed, the next hole to be machined
will be counterclockwise from the reference hole.
G The fourth and fifth steps are repeated until all 10 holes specified by the K word are
completed. After the last hole Z axis retracts to two inches above the reference
plane.
Block N40
G G37 cancels the G39 Circular Pattern command. All G80 series codes will produce a
single hole in accordance with their specification.
Block N50
G G0 sets positioning mode, M2 ends program.
A2100Di Programming Manual
Publication 91204426-001
115
Chapter 6
May 2002
Menu
Figure 7.37 Circular Pattern 10 Holes
G37 Cancel Pattern
Cancel Pattern (G37) code cancels all pattern information set by previous Grid Pattern
(G38) and Circle Pattern (G39) blocks. Following G37, G80 series hole making blocks,
milling cycle blocks, and user pattern subroutines perform only a single operation. A G37
causes no motion.
A2100Di Programming Manual
Publication 91204426-001
116
Chapter 6
May 2002
Menu
Chapter 7
ARITHMETIC EXPRESSIONS AND VARIABLES
Contents
1
2
2.1
2.2
2.3
2.4
3
3.1
4
4.1
4.2
4.3
4.4
4.5
4.6
4.7
4.8
4.9
4.10
5
Introduction...........................................................................................3
Arithmetic Operators ............................................................................3
Arithmetic Operator Hierarchy............................................................ 3
Control Computation Values............................................................... 4
Relational Operators............................................................................ 4
Relational Operators Comparison ...................................................... 4
Arithmetic and Trigonometric Functions ............................................5
Examples of Arithmetic Functions ..................................................... 6
Variables................................................................................................6
Parameter Variables ............................................................................ 6
Local Variables .................................................................................... 6
Common Variables .............................................................................. 6
System Variables ................................................................................. 7
Parameter Variables ............................................................................ 7
Word Address Parameter Variables ................................................... 7
Modal G-code Parameter Variables .................................................... 8
Local Variables .................................................................................... 8
Common Variables .............................................................................. 9
System Variables ............................................................................... 10
Date/Time Stamp.................................................................................11
A2100Di Programming Manual
Publication 91204426- 001
1
Chapter 7
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204426- 001
2
Chapter 7
May 2002
Menu
1
Introduction
Whilst numbers are adequate for most NC program word values, sometimes the values
must be computed during program execution. The control allows most word value to be
expressed using an arithmetic expression. Arithmetic expressions consist of operands
(numbers, variable references, and arithmetic functions) connected by operators (+, ,
etc.).
2
Arithmetic Operators
Operators are symbols representing an arithmetic operation:
G
Addition (+)
G
Subtraction (-)
G
Multiplication (*)
G
Division (/)
G
Modulus evaluation (\) which returns the remainder of the divide
G
Exponentiation (**)
Examples
G
Modulus:
810 modulus 360 = 810 \ 360 = 90
24 modulus 12 = 24 \12 = 0
G
Exponentiation:
5**2 = 5 X 5 = 25
3**3 = 3 X 3 X 3 = 27
2.1
Arithmetic Operator Hierarchy
Arithmetic operator hierarchy determines the order in which each operation is performed.
The order of evaluation follows standard algebraic practice, ordered from left to right,
beginning with the innermost set of parentheses. The operator hierarchy is:
G
Exponentiation
G
Multiplication, Division, and Modulus
G
Addition and subtraction
Examples
G
2+3*4=2+12 = 14
The multiplication is done first and then the addition.
G
14-3**2=14-9 = 5
The exponentiation is done first, then the subtraction.
G
(14-3)**2=11**2=121
A2100Di Programming Manual
Publication 91204426- 001
3
Chapter 7
May 2002
Menu
The contents of the parentheses are done first, then the exponentiation.
G
12/2X3=18
As multiplication and division are of the same hierarchical level, the operations are
performed left to right. division is done first then the multiplication.
The control computes the value of the arithmetic expression and substitutes the result
for the value of the programmed word. For example, programming an X word using the
expression of 3.0 + 4.0 has exactly the same effect as programming X7.0. In both cases,
the X axis slide moves to the co-ordinate X = 7.0000 inches (or 7.000mm when metric
mode is active).The following examples show how the control computes the value of a
word when it is programmed as an expression:
Arithmetic Operation
Addition
Subtraction
Multiplication
Division
Modulus
Exponentiation
2.2
Programmed Value of the
Word
X8.4375 + 0.5625
X11.4375 - 2.4375
X3 * 3
X27 / 3
X109 \ 25
X3**2
Control Calculated Value of
the Word
X = 9.0
X = 9.0
X = 9.0
X = 9.0
X = 9.0
X = 9.0
Control Computation Values
Each of the above examples produces an X axis value of 9.0 inches (assuming inch
mode). Programming any of these expressions would cause the X axis to position to
exactly the same point.
2.3
Relational Operators
Relational operators represent a comparison:
Alpha
EQ
NE
LT
GT
LE
GE
2.4
Symbol
=
<>
<
>
<=
>=
Description
Equal
Not Equal
Less Than
Greater Than
Less Than or Equal
Greater Than or Equal
Relational Operators Comparison
The result of a relational operator is a true/false condition. If the relation is true, the value
of the operator is 1; if the relation is false, the value is zero.
Example
G
G
G
3 = 3 has a value of 1 0 > = 5 has a value of 0.
3 EQ 3 has a value of 1.
0 LE 5 has a value of 0.
A2100Di Programming Manual
Publication 91204426- 001
4
Chapter 7
May 2002
Menu
3
Arithmetic and Trigonometric Functions
As well as arithmetic operations, the control can compute arithmetic and trigonometric
functions within an NC program. These functions are listed in the following table. The
letters ARG represent the Argument, which is always enclosed in parentheses, as
shown.
Function
SIN
COS
TAN
ARCSIN
ARCCOS
ARCTAN
ABS
SQR
RND
INT
Argument Range
Value Returned
308
1.7 x 10 [ ARG [ +1.7 x 10 ARG is in Sine of ARG, where:
degrees
-1 [ SIN (ARG) [ +1
308
308
Cosine of ARG, where:
-1.7 x 10 [ ARG [ +1.7 x 10 ARG is
in degrees
-1 [ COS (ARG) [ +1
308
308
Tangent of ARG, where:
-1.7 x 10 [ ARG [ +1.7 x 10 except
for values of ARG close to odd multiples -1.7 x 10308 [ TAN (ARG) [ +1.7 x 10308
of 90
Arcsine of ARG, where:
-1 [ ARG [ +1
-90 [ ARCSIN (ARG) [ +90
Arccosine of ARG, where:
-1 [ ARG [ +1
-90 [ ARCCOS (ARG) [ +90
308
308
-90 [ ARCTAN (ARG) [ +90
-1.7 x 10 [ ARG [ +1.7 x 10
308
308
Absolute value of ARG where:
-1.7 x 10 [ ARG [ +1.7 x 10
308
0 [ ABS (ARG) [ +1.7 x 10
308
Square root of ARG where:
0 [ ARG [ +3.37 x 10
308
0 [ SQR (ARG) [ +1.7 x 10
308
308
Rounded integer value of ARG.
-1.7 x 10 [ ARG [ +1.7 x 10
RND (4.5) = 5
RND (4.49) = 4
308
308
Integer value of ARG. Truncates the
-1.7 x 10 [ ARG [ +1.7 x 10
decimal portion of ARG.
INT (4.9) = 4
308
Arithmetic and Trigonometric Functions are programmed using the notation:
<function name> (<arg>)
Example
Both of the following are acceptable:
G
X(SIN(1))
G
XSIN(1)
when the parentheses around the argument are required parts of the notation.
The function name may be any of the mnemonics listed in the table above and the
argument may be any number, variable, or expression that is within the specified range
of values. Argument values that are out of range activate an alarm.
A2100Di Programming Manual
Publication 91204426- 001
5
Chapter 7
May 2002
Menu
3.1
Examples of Arithmetic Functions
Programmed
SIN (22.5)
COS (15)
TAN (45.125)
ARCSIN (0.5)
ARCCOS (0.707106781)
ARCTAN (1)
ABS (-1.3)
SQR (25)
INT (9.87)
RND (12.453287)
Description
Sine of 22.5º
Cosine of 15º
Tangent of 45.125º
Inverse Sine (Arcsine) of 0.5
Inverse Cosine (Arc cosine) of
0.0707106781
Inverse (Arc tangent) Tangent of 1
Answer
0.3826834
0.9659258
1.0043729
30
45
Absolute Value of -1.3
Square Root of 25
Integer Portion of 9.87
12.453287 rounded to the nearest
integer
1.3
5
9
12
45
Note: Angles must be expressed in degrees and decimal parts of a degree.
Example
Angle
= 18º 36’ 18”
= 18 + (36/60) + (18/3600)
= 18 + 0.6 + 0.005
= 18.605º
4
Variables
The values in an arithmetic expression can be numbers or variables. A variable is a
symbol-name combination that refers to a particular value. Variables available to the NC
program are:
4.1
Parameter Variables
Prefixed by &, and have permanently assigned names, are passed to an NC program by
the control, and to a subroutine by the subroutine call statement.
4.2
Local Variables
Prefixed by #, and are owned by the NC program or subroutine, and cannot be read or
written by other subroutines or programs.
4.3
Common Variables
Prefixed by @, and are shared among the main program, the programs that it may link to
using the chaining (CHN) block, and any called subroutines.
A2100Di Programming Manual
Publication 91204426- 001
6
Chapter 7
May 2002
Menu
4.4
System Variables
Prefixed by $, and are permanently assigned named variables supplied by the control.
All variables are named using alphanumeric identifiers. A variable identifier must:
G
Be enclosed in square brackets “[ ]”
G
Begin with a letter or an underscore (“_”)
G
Contain any combination of letters, numbers, and underscore ( _ ) up to 12
characters (not including the square brackets and prefix)
G
Be prefixed with a special character that indicates the type of variable being
referenced:
# - local variable
@ - common variable
$ - system variable
& - parameter
Examples of Variable References
Example Variable
[#LOOP_COUNTER]
[@CUT_DEPTH]
[$HIGH_LIMIT(X)]
[&X]
[&INTERP]
4.5
Description
User-defined local variable.
User-defined common variable that is shared by the main
program and its subroutines.
System-defined variable that contains machine configuration or
machine state information.
System-defined variable that contains machine configuration or
machine state information.
One of the modal G-code states that were active when the
subroutine was called or, in the main program, the default modal
G-code state.
Parameter Variables
Parameters are values passed to the main program or to a subroutine. A main program
or subroutine accesses its parameters by using the “&” prefix and specifying the identifier
for the parameter in the calling block.
4.6
Word Address Parameter Variables
The Call Subroutine block “(CLS,)” uses the word addresses A-Z to pass parameters to
the subroutine. The subroutine references its parameters by coding “&<n>” where <n> is
the letter address of the parameter in the call block. For example, the subroutine call
statement:
(CLS, “SUB1”, X10 Y4.5 Z25 F100)
passes four parameters (the X parameter is 10, Y is 4.5, Z is 25, and F is 100). All other
parameters are “not programmed”.
A2100Di Programming Manual
Publication 91204426- 001
7
Chapter 7
May 2002
Menu
Inside of “SUB1”, these same parameters are referenced by [&X], [&Y], [&Z], and [&F]
respectively. For example, blocks inside the subroutine might look like:
N0100 G1 X[&X] Y[&Y] Z[&Z] F[&F]
N0100 G1 X[&Y] Y[&X] Z[&Z]
In block N0110, the X word contains the value passed in the Y parameter. Notice that
the use of the parameter values is unrestricted; that is, any parameter can be used in
any word address where an expression is appropriate.
It is often the case that a passed parameter is used in the word with the same address
as the parameter. The shorthand notation “!” is allowed in a word to refer to the
parameter with the same address as the word itself. Using this notation, the example
becomes:
N0100 G1 X! Y! Z! F!
N0110 X[&Y] Y[&X] Z!
Variable references to parameters have a special side-effect, different from any other
variable references. As the presence of a word in a Type I block can have special
meaning, it is important that a “pass through” value, like the X, Y, Z, and F values in
block N0100 in the examples, only appear in the subroutine block if the parameter value
is present.
Both the “[&n]” and “!” notation have the property that the word in which the parameter
reference occurs becomes “not programmed” if the parameter is not programmed in the
call subroutine block.
A subroutine may need to know whether-or-not a variable has been programmed. The
NC program can determine whether a parameter is programmed or not by using the
“[?n]” function. This function returns zero (false) if the parameter n is not programmed
and a non-zero value (true) if the parameter is present. For example:
(IF [?F] THEN)
[@MODAL_FDRT] = F! ; SAVE PASSED F PARAMETER
(ENDIF)
...
N050 G1 F[@MODAL_FDRT] ...
In the example, the IF statement determines whether the F word was programmed on
the subroutine invocation and, if it was, updates the modal feedrate.
4.7
Modal G-code Parameter Variables
In addition to values passed to the main program or subroutine, the NC program or
subroutine can access the modal G-code states that were in effect when it was invoked
or called. For the main NC program, these are the default G-code states. The modal
state information includes all of the modes controlled by G-codes.
4.8
Local Variables
Every NC program and NC program subroutine is allowed a set of 50 uniquely defined
local variables. Local variables, prefixed by #, are created and set to zero each time a
A2100Di Programming Manual
Publication 91204426- 001
8
Chapter 7
May 2002
Menu
program is entered. If a subroutine uses local variables, every time the subroutine is
called the variables are initially zero.
Local variables are intended for use as “scratch pad” or working storage. They are
zeroed at end of program but not by Data Reset. This means that local variables are not
reset if execution is stopped with Feed Hold, then Data Reset pressed and the program
repositioned.
As local variable references are encountered, the identifiers are bound to the local
variables until all of the local variables are used. The same variable identifier can be
used in different subroutines, or in the main program and its subroutines.
Each program and subroutine has its own set of local variables. For example, the main
program and subroutines “SUB1” and “SUB2” each defines variable [#ABC]. The
subroutines can each use their own [#ABC] without interfering with, or changing the
value of the main programs variable [#ABC]. This means the subroutines cannot make
use of the main programs local variables.
Example:
Subroutine call:
N1230 (CLS,“SUB2” X10 Y20 Z5 I12 J10 K0)
Subroutine:
(DFS, “SUB2”)
...
N0100 [#CENTER] = [&I]/2
N0200 G1 F100 X[#CENTER]
...
(ENS)
Block N0100 creates a local variable named CENTER and sets it to half of the value
passed to the subroutine in the I word, which is 12 in the example. The resulting value in
[#CENTER] is therefore 6. Block N0200 commands a move to computed location (6).
The local variables for the main program and its subroutines are separate from one
another. If the main program that called SUB2 also defined a local variable named
[#CENTER] the two values are separate from one another.
4.9
Common Variables
Common variables are similar to local variables but are visible to the main NC program,
any programs that the main program links to using the CHN block, and to all subroutines
called using the CLS block.
Common variables are useful because a subroutine can save a value in a common
variable and the value is retained for the next time the subroutine is called. For example,
if a subroutine needs to have a passed parameter to be treated as a modal value, the
parameter value can be saved in a common variable.
If, in subsequent calls to the subroutine, the parameter is not passed, the value saved in
the common variable may be used. As all subroutines share the common variables,
many different subroutines can share “modal” values.
A2100Di Programming Manual
Publication 91204426- 001
9
Chapter 7
May 2002
Menu
As with local variables, the identifiers for common variables are bound to the variables
as they are encountered. The control provides 100 common variables for use by the NC
program and its called NC program subroutines. Common variables are reset to zero
when a new program is loaded. They are not reset by End of Program or by Data Reset.
Common variables are retained during power-down if a sequenced shutdown was
completed.
Example:
Call:
N120 [@CENTER] = 12
N130 (CLS, “SUB1”, X Y Z)
Subroutine:
(DFS,“SUB1”)
...
G1 F100 X[@CENTER]
...
(ENS)
Block N120 creates a common variable named “CENTER” and sets a value of 12 in this
example. Block N130 calls subroutine 1 which moves the X axis 12 inches as defined by
the main program common variable.
Example:
The subroutine is called twice. An F word is passed on the first call and the subroutine
saves it in a common variable. On the second call, no F word is passed and the
subroutine uses the value that was saved in the common variable on the first call:
Calls:
N110 (CLS, “SUB1”, F45)
N200 (CLS, ”SUB1”)
Subroutine:
(DFS, ”SUB1”)
(IF [?F] THEN)
[@MODAL_FDRT] = F! ; SAVE PASSED F PARAMETER
(ENDIF)
N250 G1 F[@MODAL_FDRT]
(ENS)
4.10
System Variables
System variables are defined and maintained by the control. They are used to make
information about the machine configuration and state available to the NC program.
Some system variables are read only (for example, the actual machine axis positions),
while some can be read or written under NC program control (for example, tool and
setup data).
A2100Di Programming Manual
Publication 91204426- 001
10
Chapter 7
May 2002
Menu
System variables can be simple variables that consist of one number, arrays of values,
or tables. Most system variables that are arrays are associated with axis positions.
These axis position variables are referenced using the following notation:
[$<name>(<axis letter>)]
or
[$<name>(<axis index>)]
where:
<name> is the name of the system variable, e.g., HIGH_LIMIT
<axis letter> is the letter address of the axis, from the set X,Y,Z,U,V,W,A,B,C
<axis index> is a value of 0 through 8 corresponding to X,Y,Z,U,V,W,A,B,C.
Relationship of Axis Letters to Axis Index Values
Axis Letter
X
Y
Z
U
V
W
A
B
C
Axis Index
0
1
2
3
4
5
6
7
8
Example:
A variable reference to the value of the high limit of the X axis is written as:
[$HIGH_LIMIT(X)]
or
[$HIGH_LIMIT(0)]
System Variable Table Names
System variables that are tables consist of a set of values indexed by a record number
and a set of named fields. A reference to a field in a table uses the following notation:
[$<table name>(<record>)<field name>] where:
<table_name> is one of the table names recognised by the control.
<record> is the index into the table of the desired record.
<field name> is the name of the desired field.
Note that references to the tool data table generally refer to the data for tools in the tool
data table. However, references to record 0 refer to the data for the currently loaded tool.
For example: [$TOOL_DATA(0)TYPE].
5
Date/Time Stamp
[$CALENDAR] is a system name that contains date and time information. It consists of
three records (0-2) and 7 field names. Record 0 references the current date/time
information and cannot be written to. Records 1 and 2 are used as 'snapshot' date/time
information. For example:
[$CALENDAR(1)] = [$CALENDAR(0)]
Records the current time in [$CALENDAR(1)]. [$CALENDAR(1)] can then be
referenced to determine the date and time the snapshot was performed.
A2100Di Programming Manual
Publication 91204426- 001
11
Chapter 7
May 2002
Menu
The field names are:
G
year
G
month
G
day of week
G
day
G
hour
G
minutes
G
seconds
For example:
[#YEAR] = [$CALENDAR(1)year]
Process Control Data Table
The control provides a scratch-pad for the collection of data in a part program that may
be referenced by the part program, displayed on the operator station screen, and copied
to a printer. This scratch-pad is the Process Control Data Table. This table may be used
to collect probe hits or any other data from the part program and then an analysis may
be performed on the data collected.
Information placed in the Process Control Data Table remains active until replaced by:
G
Table Reset
G
Manual Input
G
System Variable statement
Process Control Data
Program Field Name
Description
X, Y, Z, A, B, C, I, J, K, data fields
X, Y, Z, A, B, C, I, J, K
Range of ± 99999.9999mm
A2100Di Programming Manual
Publication 91204426- 001
12
Chapter 7
May 2002
Menu
Chapter 8
PROGRAM LOGIC, FLOW CONTROL
Contents
1
2
3
4
5
6
7
Overview............................................................................................... 3
Logical Expressions ............................................................................ 3
Branch (GOTO <label>) ....................................................................... 3
Conditional Execution (IF <logical expression> THEN) .................... 5
Selection (Select Case) (Option)......................................................... 6
Program Iteration (DO...LOOP) (Option)............................................. 8
ATR (Automatic Tool Recovery) (Option) .......................................... 9
A2100Di Programming Manual
Publication 91204426- 001
1
Chapter 8
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204426- 001
2
Chapter 8
May 2002
Menu
1
Overview
Flow control statements enable the programmer to control the execution of the NC
program at execution time, both unconditionally and conditionally, based on the value of
a logical expression. These statements provide for:
G Repetitively executing sections of the program (looping).
G Conditionally executing program blocks based on either computed values or
measured values.
G Selecting one of several statements based on some condition determined when the
program executes.
2
Logical Expressions
Certain NC program blocks use Logical Expressions to allow the sequence of the
program flow to be changed based on a combination of conditions that can be tested as
the program executes. A Logical Expression consists of variables connected by logical
(Boolean) operators.
The logical operations supported are NOT, AND, OR, and XOR. As with Arithmetic
Expressions, the order of evaluation is left to right with the operator precedence being
NOT, then AND, then OR, then XOR. Parentheses can be used to change the order of
evaluation.
In Logical Expressions, values of variables are treated as true or false. A variable is false
if it is zero, and true otherwise.
Logical Expressions may also contain terms that compare the value of two Arithmetic
Expressions. Comparisons can test for equal (EQ or =), not equal (NE or <>), less than
(LT or <), greater than (GT or >), less than or equal (LE or <=), or greater than or equal
(GE or >=).
3
Branch (GOTO <label>)
The GOTO statement transfers control immediately to the statement whose Block Label
matches the <label> in the GOTO statement. The form of the GOTO statement is:
[<label>] [Nxxxx] (GOTO <target label>)
where:
G <label> is an optional label on the GOTO block.
G Nxxxx is the optional sequence number for the GOTO block.
G <target label>is the label on the next NC program block to be executed. The target
must not be inside a DO...LOOP or IF...ENDIF unless the GOTO statement is in
the same DO...LOOP or IF...ENDIF.
For example:
:1000 ...
N010 ...
[ _2000] N020 G1 F100 X10 Y10
N030 ...
...N100 (GOTO [ _2000])
Executing block N100 results in an immediate transfer to block N020.
A2100Di Programming Manual
Publication 91204426- 001
3
Chapter 8
May 2002
Menu
:1000 ...
N010 ...
[OPERATION_3] N020 G1 F100 X10 Y10
N030 ...
...
N100 (GOTO [OPERATION_3])
...
This example is identical to the previous example but an alphanumeric identifier is used.
Conditional Branch (IF <logical expression> GOTO <label>)
The IF...GOTO statement provides a means to alter the sequence of execution of the NC
program based on the evaluation of a logical expression. The form of the IF...GOTO
statement is:
[<label>] [Nxxxx] (IF <logical expression> GOTO <target label>)
where:
G
<label> is an optional label on the IF...GOTO block.
G
Nxxxx is the optional sequence number for the IF...GOTO block.
G
<logical expression> is a logical expression that evaluates to true or false.
G
<target label> is the label on the next NC program block to be executed if <logical
expression> is true (non-zero). The target must not be inside of a DO...LOOP or
IF...ENDIF unless the GOTO statement is in the same DO...LOOP or IF...ENDIF.
If <logical expression> evaluates to true (non-zero), the GOTO <target label> part of the
IF...GOTO statement transfers to the block containing <target label> and continues
execution of the program from that point.
If <logical expression> evaluates to false (zero), the GOTO is ignored and NC program
execution continues with the statement following the IF block.
For example:
...
N100 [#PASS_NUMBER] = 0
[NEXT_PASS] N110 ...
...
N290 [#PASS_NUMBER] = [#PASS_NUMBER]+1
N300 (IF [#PASS_NUMBER]<5 GOTO [NEXT_PASS])
N310 ...
In this example, the local variable [#PASS_NUMBER] is set to zero in block N100. Block
N110 is the beginning of a sequence of operations to be repeated five times. After the
sequence ends, block N290 adds one to the pass number. If five passes have not been
completed, block N300 jumps back to block N110.
After the fifth execution of N110 - N300, the value of [#PASS_NUMBER] is five, and
statement N300 does not jump back to block N110 but continues with block N310.
A2100Di Programming Manual
Publication 91204426- 001
4
Chapter 8
May 2002
Menu
4
Conditional Execution (IF <logical expression> THEN)
The optional IF...THEN, ELSE, ELSEIF...THEN and ENDIF statements provide a more
structured method of controlling program execution than the GOTO and IF...GOTO
statements. The IF...THEN statement is used along with the ELSE and ENDIF
statements as follows:
[<label>] [Nxxxx] (IF <logical expression 1> THEN)
NC program block list #1
[Nxxxx] (ENDIF)
[<label>] [Nxxxx] (IF <logical expression 1> THEN)
NC program block list #1
[Nxxxx] (ELSE)
NC program block list #2
[<label>] [Nxxxx] (ENDIF)
[<label>] [Nxxxx] (IF <logical expression 1> THEN)
NC program block list #1
[Nxxxx] (ELSEIF <logical expression 2> THEN)
NC program block list #2
[Nxxxx] (ELSE)
NC program block list #3 [<label>]
[Nxxxx] (ENDIF)
Where:
G <label> is an optional label on the IF...THEN block or ENDIF block.
G
Nxxxx is the optional sequence number for the IF...THEN, ELSEIF...THEN, ELSE,
and ENDIF blocks.
G
<logical expression 1> and <logical expression 2> are logical expressions that
evaluate to true or false.
G
”NC program block list #1”, ”NC program block list #2”, and ”NC program block list #3”
are simply sequences of NC program blocks.
If <logical expression 1> is true (nonzero), ”NC program block list #1” is executed. If the
ELSE block and ”NC program block list #2” are present, they are skipped.
If <logical expression 1> is false, ”NC program block list #1” is skipped.
If the ELSE block and ”NC program block list #2” are present, ”NC program block list #2”
is executed.
If the ELSEIF...THEN keywords are present, <logical expression 2> is evaluated, and if it
is true ”NC program blocklist #2”is executed, otherwise ”NC program block list #3” is
executed.
Any number of ELSEIF...THEN statements can be included in any IF...ENDIF sequence
but only one ELSE statement may be present.
The IF...THEN...ELSE...ENDIF statement allows a section of a program to be executed
only if some condition is true, or allows either one of two sections of a program to be
executed depending on some condition.
A2100Di Programming Manual
Publication 91204426- 001
5
Chapter 8
May 2002
Menu
For example:
N100 (IF [@DEPTH] > 50 THEN)
N110 G83 X100 Y115 R5 Z[@DEPTH]
N200 (ELSE)
N210 G81 X100 Y115 R5 Z[@DEPTH]
N220 (ENDIF)
In the example, if the depth of a hole to be drilled exceeds 50 mm, deep hole drilling
cycle G83 is used, otherwise the normal drill cycle G81 is used.
5
Selection (Select Case) (Option)
The SELECT CASE, CASE, CASE ELSE and END SELECT statements provide a
powerful means to select one of a series of actions depending on the value of a test
expression. The form of the SELECT CASE statement is:
[<label>] [Nxxxx] (SELECT CASE <expression>)
[Nxxxx] (CASE <expression list 1>)
NC program block list #1
[Nxxxx] (CASE <expression list 2>)
NC program block list #2
...
[Nxxxx] (CASE ELSE)
NC program block list #3
[<label>] [Nxxxx] (END SELECT)
Where:
G
<label> is an optional label on the SELECT CASE block.
G
Nxxxx is the optional sequence number for the SELECT CASE, CASE, CASE ELSE,
and END SELECT blocks.
G
<expression> is an arithmetic expression whose value selects the action.
G
<expression list 1> and <expression list 2> are one of the following:
∗
∗
An arithmetic expression or list of expressions separated by commas
A relational test of the form IS <op> <expression> where <op> is one of
”=,>,<,<>,>=,<=” and <expression> is another arithmetic expression
∗ A range in the form <expression> TO <expression>
”NC program block list #1”, ”NC program block list #2”, and ”NC pro gram block
list #3” are simply sequences of NC program blocks.
The simplest form of SELECT CASE statement is:
(SELECT CASE [&G])
(CASE 81)
G81 X! Y!
A2100Di Programming Manual
Publication 91204426- 001
6
Chapter 8
May 2002
Menu
(CASE 82)
G82 X! Y!
(END SELECT)
In the example, parameter [&G] is the test expression. If it is equal to 81, the first CASE
statement is chosen, if 82, the second CASE is chosen. If [&G] is neither 81 nor 82, no
case is selected.
A single CASE can specify a list of individual values:
(SELECT CASE [&M])
(CASE 3,4)
M!
(CASE 5,19)
...
(END SELECT)
In this example, the first CASE statement is executed if the value of [&M] is either 3 or 4,
and the second CASE statement is executed if [&M] is either 5 or 19.
Another form of CASE specifies a range:
(SELECT CASE [#COMMAND])
(CASE 0 TO 5)
some statements
(CASE 6 TO 10)
some other statements
(END SELECT)
In this example, the first list of statements is selected if [#COMMAND] is between 0 and
5 inclusive, and the second list is selected if [#COMMAND] is between 6 and 10. If the
CASE <exp 1> TO <exp 2> form is used, the first expression must be smaller (that is,
more negative) than the second. That is, (CASE -5 TO -1) is correct but (CASE -1 TO -5)
is not.
The third form of CASE statement is the CASE IS form:
(SELECT CASE [#COMMAND])
(CASE IS < 10)
some statements
(CASE 10 TO 19)
some more statements
(CASE IS >= 20)
still more statements
(END SELECT)
This example also illustrates that multiple forms of CASE statements can be combined
in one SELECT CASE...END SELECT.
Any number of CASE statements can be included in the SELECT CASE...END SELECT
range. The CASE clauses are evaluated in order, so if the test expression matches more
than one case, the first matching case is selected.
A2100Di Programming Manual
Publication 91204426- 001
7
Chapter 8
May 2002
Menu
6
Program Iteration (DO...LOOP) (Option)
The DO, DO WHILE, LOOP and LOOP WHILE statements provide a structured program
looping capability. They are used as follows:
[<label>] [Nxxxx] (DO WHILE <logical expression>)
NC program block list
[<label>] [Nxxxx] (LOOP)
Or
[<label>] [Nxxxx] (DO)
NC program block list
[<label>] [Nxxxx] (LOOP WHILE <logical expression>)
Where:
G
<label> is an optional label on the DO and LOOP blocks.
G
Nxxxx is the optional sequence number for the DO and LOOP blocks.
G
<logical expression> is a logical expression that evaluates to true or false
G
”NC program block list” is a sequence of NC program blocks.
In the DO WHILE...LOOP form, the ”NC program block list” is executed as long as
<logical expression> is true. When <logical expression> is false, the ”NC program block
list” is not executed; program execution continues with the block following the LOOP
block. This pre-test form of a loop, tests the logical condition before the loop is executed,
and does not execute the block list at all if the condition is false when the loop starts.
Note that if the value of <logical expression> changes during execution of the ”NC
program block list”, the NC program block list” completes execution, and the value of
<logical expression> terminates the loop when the WHILE clause is again executed.
In the DO...LOOP WHILE form, the ”NC program block list” is executed once before
<logical expression> is tested. This post-test form of a loop always executes once
regardless of the state of the <logical expression>.
Although the NC program block list can contain GOTO blocks, the target of any branch
inside a DO WHILE loop should be inside the loop or be the LOOP statement. Use of a
GOTO statement to jump into a loop is not allowed.
The example in the IF...GOTO section can be performed using DO WHILE as follows:
...
N100 [#PASS_NUMBER] = 0
N110 (DO WHILE [#PASS_NUMBER] < 5)
...
N290 [#PASS_NUMBER] = [#PASS_NUMBER]+1
N300 (LOOP)
N310 ...
Note
If <logical expression> is false the first time the DO WHILE statement is executed, the
”NC program block list” is never executed.
A2100Di Programming Manual
Publication 91204426- 001
8
Chapter 8
May 2002
Menu
The same example can be performed using DO...LOOP WHILE as follows:
...
N100 [#PASS_NUMBER] = 0
N110 (DO)
...
N290 [#PASS_NUMBER] = [#PASS_NUMBER]+1
N300 (LOOP WHILE [#PASS_NUMBER] < 5)
N310 ...
Note
If <logical expression> is false the first time the DO...LOOP WHILE statement is
executed, the ”NC program block list” is still executed one time.
DO...LOOP loops can be nested; that is, one loop can be contained within a second
loop. For example, to machine a grid of three rows of five holes spaced 20 mm apart:
[#ROWS] = 3
(DO WHILE [#ROWS]>0)
[#HOLES] = 5
(DO WHILE [#HOLES]>0)
G81 G91 X20 R100 Z25
[#HOLES]=[#HOLES]-1
(LOOP)
G0 X-100 Y20
[#ROWS]=[#ROWS]-1
(LOOP)
In this example, the outer loop is executed three times, once for each line of holes. The
inner loop is executed five times for each line. The pre-test form of the loop statement is
preferable here so the loop is not executed at all if the required number of rows or holes
is zero.
7
ATR (Automatic Tool Recovery) (Option)
The Automatic Tool Recovery (ATR) block provides a means to specify a section of the
NC program designated to handle an exception condition detected by a machine
monitoring feature. These features, such as a probe cycle that detects a broken tool or
some other machine monitoring capability, are capable of reporting a condition that may
require NC program action.
The effect of the ATR block is to define the label specified in the ATR block as the active
exception handler. If any subsequent exception is reported (such as a broken tool) the
NC program execution transfers to the ATR-specified label. The exception handler
typically determines whether there is any feasible recovery, and either attempts the
recovery, or aborts the program.
Recovery strategies typically include loading an alternative tool, and re-machining the
portion of the part that was machined with the defective tool.
A2100Di Programming Manual
Publication 91204426- 001
9
Chapter 8
May 2002
Menu
The format of the ATR block is:
[<label>] [Nxxxx] (ATR, L<exception handler label>)
Where:
G
<label> is an optional label on the ATR block.
G
Nxxxx is the optional sequence number for the ATR block.
G
<exception handler label> is the label to which the NC program should transfer
control if an exception condition is detected, or zero.
Programming an ATR block with the L word absent or L0, clears any exception handler
that was present. An exception handler should generally clear the handler to prevent
unwanted repeat exceptions.
An exception handler is active for the main program or subroutine in which the ATR
block appears, and for all subroutines that are subsequently called. If a subroutine
contains an ATR block, the exception handler defined by that ATR block overrides any
ATR block that had been encountered in the main program or in another subroutine.
When a subroutine containing an ATR block returns to its caller, the exception handler
for that subroutine is cleared. When an exception handler receives control, the system
variable [$EXCEPTION] contains a number that specifies the cause of the exception.
The exceptions are shown in the table following.
[$EXCEPTION] value
1
2
3
Meaning
Broken Tool
Worn Tool (undersize)
Oversize Tool
ATR (Automatic Tool Recover) Example
In the following sample program, block N020 is the main program ATR block. During
program execution, if ATR is triggered in either OP1 or OP2 the program will jump to
label TOOL_REC, execute motion blocks, determine where to return (OP1 or OP2) and
start program execution.
Note that the first block under label OP1 N050 and OP2 N130 are tool change blocks.
When the tool change is performed, an alternate tool with the same ID could be selected
if the Tool Manager Alternate ID field contains an alternate tool number.
Block N320 in the program following contains an ATR block in subroutine ”SUB1”. If ATR
is triggered during subroutine execution, the program will jump to subroutine label
SUB_TOOL_REC, perform a tool change, then begin cycle execution at the start of the
subroutine:
:010 G0 X0 Y0
N020 (ATR,L[TOOL_REC]) ; Main program ATR block
N030 [#OPERATION] = 1
[OP1]
N050 T1 M6
N060 S100 M3
N070 G1 F10 X1
A2100Di Programming Manual
Publication 91204426- 001
10
Chapter 8
May 2002
Menu
N080 (CLS, ”SUB1”, X[@X] Y[@Y])
N090 G1 G91 F1 X1
N100 G1 F1 Y1
N110 [#OPERATION] = 2
[OP2]
N130 T3 M6
N140 S100 M3
N150 G1 F1 X3
N160 G1 F1 Y2
N170 M02
N180;
[TOOL_REC] ; Main program exception handler label
N200 (MSG, Recover for outside sub)
N210 G0 X0 Y0
N220 G1 F100 X.5
N230 (IF [#OPERATION] = 1 THEN)
N240 (GOTO [OP1])
N250 (ELSEIF [#OPERATION] = 2 THEN)
N260 (GOTO [OP2])
N270 (ENDIF)
N280;
N290 ;Call SUB1 1 time
N300;
N310 (DFS, ”SUB1”)
N320 (ATR,L[SUB_TOOL_REC]) ; Sub program ATR block
[OP1SUB]
N330 G1 X! Y!
N340 G1 G91 F100 X5
N350 G1 F100 Y3
N360 (GOTO [END])
[SUB_TOOL_REC] ; Sub program exception handler label
N380 T2 M6
N390 (GOTO [OP1SUB])
[END]
N410 (ENS)
A2100Di Programming Manual
Publication 91204426- 001
11
Chapter 8
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204426- 001
12
Chapter 8
May 2002
Menu
Chapter 9
SUBROUTINES AND PROGRAM CHAINING
Contents
1
2
3
4
5
6
7
8
9
9.1
9.2
9.3
9.4
9.5
9.6
Overview............................................................................................... 3
NC Program Chaining (CHN Block) .................................................... 3
Call NC Program Subroutine (CLS) .................................................... 5
Define Subroutine (DFS) and End Subroutine (ENS) ........................ 5
Program Parameters Table ................................................................. 9
Move To Next Operation Location (G36) (Option) ........................... 10
I, J, and K Words................................................................................ 10
X, Y, and Z Words .............................................................................. 10
G36 Sample Programs....................................................................... 11
G36 P0 (Incremental) ......................................................................... 11
G36 P1 4 Rectangular Patterns I, J, K Offsets (Incremental) .......... 12
G36 P1 4 Rectangular Patterns X, Y, Z Offsets (Incremental) ......... 13
G36 P2 4 Rectangular Patterns I, J, K Offsets (Absolute) ............... 13
G36 P2 4 Rectangular Patterns X, Y, Z Offsets (Absolute).............. 14
G36 P1 4 Rectangular Patterns, No G36 Offset, Skip First Rectangle15
A2100Di Programming Manual
Publication 91204426- 001
1
Chapter 9
May 2002
Menu
Intentionally Blank
A2100Di Programming Manual
Publication 91204426- 001
2
Chapter 9
May 2002
Menu
1
Overview
The control provides a means for one program to 'chain' to another program, and allows
programs to call subroutines. The difference between chaining and a subroutine call is
that a program that is chained to is still a main program, and cannot return to the
program that chained to it.
When a program chains to another program, the first program is no longer active; the
program that is chained to becomes the active program. When a program calls a
subroutine, the calling program remains active. When the subroutine completes, it
returns to the main program which then continues to execute at the statement following
the call.
The control provides one form of chaining and one form of subroutines. A subroutine is
an NC program that can be called by another NC program to perform some task. The
subroutines supported by the control are NC program subroutines, called using the CLS
Type II block.
Control subroutines consist of a set of NC program blocks that are executed when called
by another program. They have access to parameters, which are values that are passed
to the subroutine when it is invoked.
An NC program subroutine is called by a CLS block which specifies the subroutine either
by name or by an ID number. An NC program subroutine is either an inline subroutine or
a library subroutine. An inline subroutine is a subroutine whose definition is included in
the NC program; a library subroutine is a separate NC program known to the control
program manager.
The CLS block contains, in addition to the name or ID, a repeat count and a set of
parameters to be passed to the subroutine. In effect, an NC program subroutine is an
extension of the main program. NC program subroutines allow a NC program to be
broken into modules and allows the modules to be shared by other programs.
2
NC Program Chaining (CHN Block)
The CHN Type II block allows an NC program to transfer control to another program.
Executing the CHN block causes the new program to become active and the program
that executes the CHN to become inactive. All parameters passed to the first program
remain intact, and all common variables retain their values. A CHN block may not be
executed from a subroutine.
The format of the CHN block is:
[<label>] [Nxxxx] (CHN,<program>)
Where:
G
<label> is an optional label on the CHN block
G
Nxxxx is the optional sequence number for the CHN block
G
<program> is either a quoted string containing the program name of the program to
run or a numeric program identifier associated with the program. In either case, the
program is registered in the A2100 program storage directory.
The CHN block does not have any affect on the machine. That is, it causes no axis
motion and leaves the spindle, coolant, and other mechanisms in the same state that
they were before the CHN block was executed.
A2100Di Programming Manual
Publication 91204426- 001
3
Chapter 9
May 2002
Menu
Example:
[NEXT] N0500 (CHN, “PGM_12345”)
N01000 (CHN, 562)
Where
G
Block N0500, a CHN statement transfers to a program named “PGM_12345”.
G
Block N01000, transfers to the program with program ID 562.
NC Program Subroutines
An NC program can be divided into a main program and sub-programs or into NC
Program Subroutines, and program execution begins with the main program. When the
main program encounters a subroutine call block, the called program is located either in
the program itself or in the controls NC program directory, and NC program execution
switches from the main program to the first block of the subroutine.
The subroutine can call other subroutines, however, the total depth of subroutine nesting
must not exceed four (see Fig. 2.1). Once a subroutine is called, it continues to execute
until it reaches the end of the subroutine, at which time the program or subroutine that
called it resumes execution following the call.
Figure 2.1 Subroutine Nesting
An NC program subroutine can be called repeatedly by specifying the number of times
the subroutine is to be repeated in the call statement. If the repeat count is negative or
zero, the subroutine is not called at all.
The program calling a subroutine can specify information for the subroutine to use in
performing its task, such as locations, dimensions, feedrate, tool number, spindle control
information, and so on. This information is passed in the form of parameters to the
subroutine, and 26 parameters are available.
Subroutines are useful for collecting sequences of blocks that are repeated or that
perform some function that may be required multiple times in a program. The subroutine
is written once and may be called from several places in the program with different
parameters.
A2100Di Programming Manual
Publication 91204426- 001
4
Chapter 9
May 2002
Menu
3
Call NC Program Subroutine (CLS)
An NC program subroutine is called using the CLS Type II block. The format of the block
is:
[<label>] [Nxxxx] (CLS,<subroutine>,<repeat>,<arguments>)
Where:
G
<label> is an optional label on the CLS block.
G
Nxxxx is the optional sequence number for the CLS block.
G
<subroutine> is either a quoted string containing the program name of the subroutine
or a numeric program identifier associated with the subroutine. In either case, the
subroutine must be defined locally in the NC program or located in the program
storage directory.
G
<repeat> is the number of times the subroutine is to be executed. If this field is zero
or negative, the subroutine is not called at all. If it is omitted altogether, the subroutine
is called once.
G
<arguments> is a set of zero or more words, each consisting of a single letter and a
number or an arithmetic expression. The list of arguments can use all 26 letters, but
no letter can be repeated. The use of the letters is not restricted in any way. The
meaning of the arguments is determined by the subroutine.
Examples:
N0100 (CLS,”SUB1”)
N0200 (CLS,123,3)
Block N0100 calls the subroutine named ”SUB1” once, and passes no parameters.
Note
As there is no repeat count and there are no parameters, the commas are not needed.
Block N0200 calls the subroutine with program ID 123 three times passing no
parameters.
[DO_OPERATION] N0300 (CLS,”MILL_PAD”,4, X10.4 Y5 I1 J1 F25 Q100)
This example illustrates a call that passes parameters. The meaning is ”Call the
subroutine named ”MILL_PAD” four times, using parameters X, with a value of 10.4, Y
with a value of 5, I and J with values of 1, F with a value of 25, and Q with a value of
100”. The meaning of the parameters is not determined by the use of letter addresses X,
Y, and so forth; the interpretation is strictly up to the subroutine.
4
Define Subroutine (DFS) and End Subroutine (ENS)
Section 3 described how subroutines are called. An NC program subroutine is either a
library subroutine, which is a separate program, registered in the control program
directory, or an inline subroutine, which is defined in a portion of the NC program itself.
In either case, the subroutine begins with a Define Subroutine (DFS) block, which
defines the subroutines name and its numeric identifier. When a library subroutine is
registered with the control Program Service, the program name and identifier must
match those in the DFS block.
A2100Di Programming Manual
Publication 91204426- 001
5
Chapter 9
May 2002
Menu
A subroutine begins with a Define Subroutine (DFS) block and ends with an End
Subroutine (ENS) block which can have a label. If it is necessary to exit the subroutine
from some point within the body of the subroutine, it is possible to jump to the ENS block
using a GOTO statement or an IF...GOTO statement.
If the subroutine is an inline subroutine, the (DFS) and (ENS) blocks bracket the
subroutine blocks and may appear anywhere within the main NC program. Inline
subroutine definitions cannot be nested. That is, a (DFS) (ENS) and the enclosed
subroutine blocks cannot appear within another subroutine definition.
A library subroutine is an NC program registered in the NC program directory that begins
with a (DFS) block and ends with an (ENS) block, and is permitted to contain one level of
inline subroutine definitions.
The inline subroutines defined inside a library subroutine can only be called from within
that library subroutine. For example, if ABC is a library subroutine that defines that inline
subroutines DEF and GHI, DEF and GHI cannot be called from a program that calls
ABC, but can be called by (CLS) blocks inside the body of library subroutine ABC.
The blocks that form the body of the subroutine can include any valid A2100 program
blocks.
A subroutine can be defined to be a pattern subroutine. This allows the subroutine to be
invoked by the G38 and G39 Pattern Cycles. Defining a subroutine as a pattern
subroutine optionally causes the pattern co-ordinate system to be activated when the
subroutine is invoked if a pattern cycle is active. It also causes the subroutine to execute
the number of times requested by the pattern before finally returning to the calling
program.
The looping within the subroutine is controlled by special G codes within the subroutine.
Execution resumes at the first block of the subroutine each time the ENS block is
encountered until the pattern count is satisfied.
A user NC program subroutine can be written to be pattern sensitive, so that it can be
repeatedly invoked by the pattern cycles. Pattern sensitive subroutines must include a
block containing a G36 to move to the operation location before performing the
subroutines operation. The effect of the G36 is to execute the move to the next operation
location defined by the currently active pattern, and to set-up the pattern co-ordinates.
Following the blocks that perform the operation, the subroutine must contain a block with
a G36.1, which evaluates the pattern and sets-up the subroutine exit condition for the
ENS block at the end of the pattern subroutine.
The format of the DFS block is:
[Nxxxx] (DFS,”<subroutine name>”, <subroutine id>, <step over> <pattern>)
Where:
G
Nxxxx is the optional sequence number for the DFS block.
G
<subroutine name> is the alphanumeric name of the subroutine as it appears in the
(DFS) block of the inline subroutine definition or as it is registered in the NC program
directory. The name is enclosed in quotes.
G
<subroutine id> is the numeric NC program ID assigned to the subroutine by the
inline (DFS) block or that appears in the NC program directory.
A2100Di Programming Manual
Publication 91204426- 001
6
Chapter 9
May 2002
Menu
G
<step over> is programmed as S0 or S1. It defines whether the subroutine behaves
like a single block or like a collection of blocks in Single Block mode. S0 or S1 not
programmed causes the subroutine to stop at the end of each block if Single Block is
active. S1 causes the entire subroutine to execute when the CLS block is executed in
Single Block mode.
G
<pattern> is programmed as P0, P1, or P2. P0 or P1 not programmed specifies that
this subroutine ignores patterns. P1 specifies that this subroutine should respond to
pattern cycles and execute with pattern co-ordinates enabled. P2 specifies that this
subroutine should respond to pattern cycles but not invoke pattern co-ordinates.
With the system in Single Block, if the main program calls a subroutine defined as ”step
over” (S1), and that subroutine calls another subroutine not defined as ”step over” (S
absent or zero), the inner subroutine is stepped through one block at a time until it
reaches its (ENS) block, at which time the first subroutine completes and returns to the
main program.
At least one of <subroutine name> or <subroutine id> must be specified. Both may be
present.
The format of the ENS block is:
[<label>] [Nxxxx] (ENS)
Where:
G
<label> is an optional label on the ENS block.
G
Nxxxx is the optional sequence number for the ENS block.
G
The label on the ENS block is visible only to GOTO blocks inside the subroutine.
When the subroutine executes the (ENS) block, the subroutine is repeated if the repeat
count specified in the CLS block has not been exhausted. If the subroutine repeats, all
temporary variables are reset to zero and all of the parameters passed to the subroutine
are re-evaluated.
Re-evaluation of the parameters allows the subroutine to change a common or writable
system variable, and have that change visible to the subroutine on subsequent
executions.
The blocks of the body of the subroutine obtain the passed parameter values using the I
or [&<n>] notation, where <n> is the letter corresponding to the word address in the CLS
block.
For example, if the main program calls ”SUB_1” with the block:
N0100 (CLS,”SUB_1”, X10 Y5)
the subroutine can retrieve the values of X and Y as:
(DFS,”SUB_1”)
N010 G0 X! Y!
N020 X[&Y] Y[&X]
...
(ENS)
A2100Di Programming Manual
Publication 91204426- 001
7
Chapter 9
May 2002
Menu
The subroutine inherits all of the modal values of the preparatory code groups
(inch/metric, absolute/incremental, etc.), the miscellaneous code groups (spindle,
coolant, etc.) and the modal values for all other functions such as feedrate and spindle
speed.
If the subroutine changes any of these, the changed values become active when the
main program continues following the CLS block. For example, if the main program
starts the spindle and then calls SUB_2:
N0100 S1000 M3
N0110(CLS,”SUB_2”)
N0120 ...
and SUB_2 stops the spindle:
(DFS,”SUB_2”)
N010 ...
...
N080 M5
(ENS)
When the main program reaches block N0120, the spindle is stopped.
A subroutine can be written to make some, or all of its parameters modal. To do this, the
subroutine must make a copy of the passed parameter in a common variable, and use
the saved value from the common variable if the parameter is not programmed on a
subsequent call.
Note that local variables cannot be used to save the modal value as all local variables
are zeroed each time the subroutine is entered.
A subroutine can determine whether a parameter is programmed or not by using the ”?n”
function. This function returns zero (false) if the parameter ”n” is not programmed and a
non-zero value (true) if the parameter is present. The example following illustrates a
subroutine that treats its F parameter as modal once it has been programmed.
(DFS,”SUB_3”)
(IF [?F] THEN)
[@MODAL_FDRT] = &F ; SAVE PASSED F PARAMETER
(ENDIF)
...N050 G1 F[@MODAL_FDRT] ...
The IF statement asks whether the F parameter is present. If it is, the passed value is
copied to the common variable [@MODAL_FDRT]. Later, block N050 uses the modal
value, which is either the passed value or the previous modal value.
The use of common variables to store modal values for parameters allows several
subroutines to share a common default value.
A2100Di Programming Manual
Publication 91204426- 001
8
Chapter 9
May 2002
Menu
A pattern subroutine is typically coded as follows:
(DFS,”SUB_4”,P1)
(IF NOT [#FIRST_TIME] THEN)
<blocks that check parameters and perform initialisation>
[#FIRST_TIME]=1
(ENDIF)
G36 P1 ; move to first pattern location and invoke pattern co-ordinates
...
<blocks that implement the subroutine’s operation>
...G36.1
(IF [$PATTERN_END] THEN)
<any end of pattern operations>
(ENDIF)
(ENS)
The initial blocks may perform checking of passed parameters or other conditions that
are done just once. The local variable [#FIRST_TIME] is initially zero, so the IF test
succeeds and executes any one-time initialisation or checking needed. The assignment
of one (true) to [#FIRST_TIME] makes the test fail on all but the first operation of the
pattern.
The G36 moves to the location of the next operation and invokes pattern co-ordinates. If
the subroutine is written in a way that needs access to the parameters in program coordinates, P2 should be specified to prevent pattern co-ordinates from being used. The P
word on the G36 block must match the P word in the DFS block for proper operation. It
controls whether the G36 invokes pattern co-ordinates or not.
The following blocks implement the steps required to perform the operation that the
subroutine is to perform. These are followed by a G36.1 block which checks for the end
of the pattern and performs the end of pattern retract move (if programmed on the
pattern block).
The G36.1 also sets the system variable [$PATTERN_END] true only if the last pattern
operation has been executed; otherwise it is set false. The NC subroutine can make use
of the state of this variable to perform end of pattern operations.
Note that any operations within the IF clause are executed after the end of pattern retract
move.
5
Program Parameters Table
The Program Parameters table provides the operator with a means of entering and
modifying the parameters associated with each NC program. This feature allows the
main NC program to be treated as if it were an NC program subroutine. The difference is
that the NC program parameters are specified in a table, while in a subroutine the
parameters are passed in a call block.
The NC program uses these parameters in the same way that subroutine parameters
are used with the notation [&<param>] where <param> is the letter A through Z.
A2100Di Programming Manual
Publication 91204426- 001
9
Chapter 9
May 2002
Menu
6
Move To Next Operation Location (G36) (Option)
A G36 is programmed in a user NC program subroutine designated as a pattern
subroutine before the blocks that define the operation. If a pattern is active, the G36
causes a move from the current location to the next operation site defined by the pattern.
The G36 block can also specify the origin for pattern co-ordinates relative to the
operation site and can specify an offset to be included in the move to the operation site.
The pattern co-ordinate offset allows the pattern co-ordinates to be set-up with the
pattern co-ordinate origin at a point other than the reference point of the operation. The
offset move allows the subroutine to ask the pattern cycle to move to some point other
than the defined reference point to avoid wasted motion.
The G36 block allows a sequence number and a block label, and uses the following
words:
P Word - Specifies the type of subroutine values and are as follows:
P0 or absent: the subroutine ignores patterns (and G36 ignores the I, J, K, X, Y and Z
words).
P1: the subroutine responds to pattern cycles and executes in pattern co-ordinates.
P2: the subroutine responds to pattern cycles and executes in NC program coordinates.
7
I, J, and K Words
These words define an incremental vector from the operation site (at current spindle
depth) to the required Pattern Co-ordinate System origin (at R plane). All three axes are
used. These words do not cause axis motion, but are used to offset the origin of the
Pattern Co-ordinate System from the next pattern operation location.
Note that the G36 does not move the Z axis position that resulted from the operation
location to the next, but instead uses the Z axis position that resulted from the operation.
This means that the Z axis position following an operation can vary depending on the
operation performed.
For the first operation, Z is where the NC program placed it prior to invoking the pattern.
For the second and subsequent operations, Z is where the operation left it. When using
the G80 series hole making cycles or the G20 series milling cycles, for example, Z is
normally left at the R plane, but may be moved to a different location if the W word is
included.
8
X, Y, and Z Words
These words define an incremental vector from Pattern Co-ordinate System origin to the
machining starting position. Only the two axes in the currently selected plane are used.
The effect of programming X, Y and Z is to cause the G36 to move to the machining start
location for the next operation rather than the operation location specified by the pattern.
The motion is to the X, Y and Z values in the newly activated pattern co-ordinates.
The purpose of the I, J, and K word offset is to allow the co-ordinate system for the
pattern subroutine to have its origin at a meaningful point in terms of the operation, and
still allow the reference point of the operation to be at some other point.
A2100Di Programming Manual
Publication 91204426- 001
10
Chapter 9
May 2002
Menu
For example, the rectangular milling cycles allow the reference point of the rectangle to
be either the centre of one corner. Internally, these two different specifications call a
single operation that places pattern co-ordinates at the centre of the rectangle. This is
done by specifying an offset from the pattern location (which refers to the reference
corner of the geometry for G22.1) to the centre of the rectangle, thus making the
geometry identical to that for the centre specified case.
The purpose of the X, Y, and Z words is to specify an additional distance to move from
the reference point of the geometry to the actual machining start point. Using the X, Y,
and Z words allows the control to combine the G36 move to the next pattern location and
the move from the pattern location to the machining start point into a single rapid span,
thus saving time and avoiding the extra move.
Check End of Pattern (G36.1) (Option)
A G36.1 must be programmed in a user NC program subroutine designated as a pattern
subroutine (see Section 4) after the blocks that define the operation. The G36.1
evaluates the pattern and sets the 'end of pattern' condition that allows the subroutine to
exit when the ENS block is encountered.
9
G36 Sample Programs
Note
Feed rates used in the following programs are for sample purposes only.
9.1
G36 P0 (Incremental)
:331094 G0 G94 G90 G70 G17 X2 Y2 Z8 F100
;
N010 G1 X1 Y1
N020 G39 X0 Y0 Z8 S1 D4 P0 K4 W10 R0
;Pattern centred at X=0 Y=0,
;Aligned at 0 deg, 4 inch diameter,
;4 rectangles around circle, CCW
;R0 = rotate pattern
;R1 = don’t rotate
N030 (CLS, ”PATTERN”) ;Call pattern sub
N040 G37 ;Cancel patterns
N050 G04 F0.1 ;Sync block
;
N100 (DFS, ”PATTERN”, P0) ;Pattern subroutine
;P0 = ignore patterns & offsets
;P1 = execute pattern, use pattern co-ordinates
;P2 = execute pattern, ignore pattern co-ordinates
N110 G36 P0 I1 J2 K3 X4 Y5 Z6 ;Begin pattern (should run as non-pattern
;subroutine)
N120 (IF NOT [#FIRST_TIME] THEN)
N130 G91 G1 Z-6
N140 [#FIRST_TIME]=1
N150 (ENDIF)
N160 Z-1
N170 X2
N180 Y1
A2100Di Programming Manual
Publication 91204426- 001
11
Chapter 9
May 2002
Menu
N190 X-2
N200 Y-1
N210 Z1
N220 G36.1 R4 ;End pattern, retract to 10” + 4”
N230 (IF [$PATTERN_END] THEN)
N240 G91 G1 Z6 ;Feed to 20”
N250 (ENDIF)
N260 (ENS)
;
N331094 G90 G0 X0 Y0 M30
9.2
G36 P1 4 Rectangular Patterns I, J, K Offsets (Incremental)
:331098 G0 G94 G90 G70 G17 X2 Y2 Z8 F100
;
N010 G1 X1 Y1
N020 G39 X0 Y0 Z8 S1 D4 P0 K4 W10 R0
;Pattern centred at X=0 Y=0,
;Aligned at 0 deg, 4 inch diameter,
;4 rectangles around circle, CCW
;R0 = rotate pattern
;R1 = don’t rotate
N030 (CLS, ”PATTERN”) ;Call pattern sub
N040 G37
N050 G04 F0.1 ;Sync block
;
N100 (DFS, ”PATTERN”, P1) ;Pattern subroutine
;P0 = ignore patterns
;P1 = execute pattern, use pattern co-ordinates
;P2 = execute pattern, ignore pattern co-ordinates
N110 G36 P1 I1 J1 K0 X0 Y0 Z0 ;Begin pattern
N120 (IF NOT [#FIRST_TIME] THEN)
N130 G91 G1 Z-6
N140 [#FIRST_TIME]=1
N150 (ENDIF)
N160 Z-1
N170 X2
N180 Y1
N190 X-2
N200 Y-1
N210 Z1
N220 G36.1 R4 ;End pattern, retract to 10” + 4”
N230 (IF [$PATTERN_END] THEN)
N240 G91 G1 Z6 ;Feed to 20”
N250 (ENDIF)
N260 (ENS)
;
N331098 G90 G0 X0 Y0 M30
A2100Di Programming Manual
Publication 91204426- 001
12
Chapter 9
May 2002
Menu
9.3
G36 P1 4 Rectangular Patterns X, Y, Z Offsets (Incremental)
:331100 G0 G94 G90 G70 G17 X2 Y2 Z8 F100
;
N010 G1 X1 Y1
N020 G39 X0 Y0 Z8 S1 D4 P0 K4 W10 R0
;Pattern centred at X=0 Y=0,
;Aligned at 0 deg, 4 inch diameter,
;4 rectangles around circle, CCW
;R0 = rotate pattern
;R1 = don’t rotate
N030 (CLS, ”PATTERN”) ;Call pattern sub
N040 G37
N050 G04 F0.1
;
N100 (DFS, ”PATTERN”, P1) ;Pattern subroutine
;P0 = ignore patterns
;P1 = execute pattern, use pattern co-ordinates
;P2 = execute pattern, ignore pattern co-ordinates
N110 G36 P1 I0 J0 K0 X1 Y1 Z0 ;Begin pattern
N120 (IF NOT [#FIRST_TIME] THEN)
N130 G91 G1 Z-6
N140 [#FIRST_TIME]=1
N150 (ENDIF)
N160 Z-1
N170 X2
N180 Y1
N190 X-2
N200 Y-1
N210 Z1
N220 G36.1 R4 ;End pattern, retract to 10” + 4”
N230 (IF [$PATTERN_END] THEN)
N240 G91 G1 Z6 ;Feed to 20”
N250 (ENDIF)
N260 (ENS)
;
N331100 G90 G0 X0 Y0 M30
9.4
G36 P2 4 Rectangular Patterns I, J, K Offsets (Absolute)
:331103 G0 G94 G90 G70 G17 X2 Y2 Z8 F100
;
N010 G1 X1 Y1
N020 G39 X0 Y0 Z8 S1 D4 P0 K4 W10 R1
;Pattern centred at X=0 Y=0,
;Aligned at 0 deg, 4 inch diameter,
;4 rectangles around circle, CCW
;R0 = rotate pattern
;R1 = don’t rotate
A2100Di Programming Manual
Publication 91204426- 001
13
Chapter 9
May 2002
Menu
N030 (CLS, ”PATTERN”) ;Call pattern sub
N040 G37
N050 G04 F0.1
;
N100 (DFS, ”PATTERN”, P2) ;Pattern subroutine
;P0 = ignore patterns
;P1 = execute pattern, use pattern co-ordinates
;P2 = execute pattern, ignore pattern co-ordinates
N110 G36 P2 I1 J1 K0 X0 Y0 Z0 ;Begin pattern
N120 (IF NOT [#FIRST_TIME] THEN)
N130 G90 G1 Z2 ;Use absolute to set program co-ordinates
N140 [#FIRST_TIME]=1 ; to a fixed location
N150 (ENDIF)
N160 X0 Y0 Z1
N170 X2
N180 Y1
N190 X0
N200 Y0
N210 Z2
N220 G36.1 R4 ;End pattern, retract to 10” + 4”
N230 (IF [$PATTERN_END] THEN)
N240 G91 G1 Z6 ;Feed to 20”
N250 (ENDIF)
N260 (ENS)
;
N331103 G90 G0 X0 Y0 M30
9.5
G36 P2 4 Rectangular Patterns X, Y, Z Offsets (Absolute)
:331104 G0 G94 G90 G70 G17 X2 Y2 Z8 F100
;
N010 G1 X1 Y1
N020 G39 X0 Y0 Z8 S1 D4 P0 K4 W10 R0
;Pattern centred at X=0 Y=0,
;Aligned at 0 deg, 4 inch diameter,
;4 rectangles around circle, CCW
;R0 = rotate pattern
;R1 = don’t rotate
N030 (CLS, ”PATTERN”) ;Call pattern sub
N040 G37
N050 G04 F0.1
;
N100 (DFS, ”PATTERN”, P2) ;Pattern subroutine
;P0 = ignore patterns
;P1 = execute pattern, use pattern co-ordinates
;P2 = execute pattern, ignore pattern co-ordinates
N110 G36 P2 I0 J0 K0 X1 Y1 Z0 ;Begin pattern
N120 (IF NOT [#FIRST_TIME] THEN)
N130 G90 G1 Z2 ;Use absolute to set program co-ordinates
N140 [#FIRST_TIME]=1 ; to a fixed location
N150 (ENDIF)
N160 X0 Y0 Z1
N170 X2
A2100Di Programming Manual
Publication 91204426- 001
14
Chapter 9
May 2002
Menu
N180 Y1
N190 X0
N200 Y0
N210 Z2
N220 G36.1 R4 ;End pattern, retract to 10” + 4”
N230 (IF [$PATTERN_END] THEN)
N240 G91 G1 Z6 ;Feed to 20”
N250 (ENDIF)
N260 (ENS)
;
N331104 G90 G0 X0 Y0 M30
9.6
G36 P1 4 Rectangular Patterns, No G36 Offset, Skip First
Rectangle
:331107 G0 G94 G90 G70 G17 X2 Y2 Z8 F100
;
N010 G1 X1 Y1
N020 G39 X0 Y0 Z8 S2 I0 J-3 O-135 K4 W10 R0
;Pattern centred at X=2 Y=2,
;Aligned at -90 deg, 6 inch diameter,
;4 rectangles around 135 deg arc, CW, skip 1st rectangle.
;R0 = rotate pattern
;R1 = don’t rotate
N030 (CLS, ”PATTERN”) ;Call pattern sub
N040 G37
N050 G04 F0.1 ;Sync block
;
N100 (DFS, ”PATTERN”, P1) ;Pattern subroutine
;P0 = ignore patterns
;P1 = execute pattern, use pattern co-ordinates
;P2 = execute pattern, ignore pattern co-ordinates
N110 G36 P1 I0 J0 K0 X0 Y0 Z0 ;Begin pattern
N120 (IF NOT [#FIRST_TIME] THEN)
N130 G91 G1 Z-6
N140 [#FIRST_TIME]=1
N150 (ENDIF)
N160 Z-1
N170 X2
N180 Y1
N190 X-2
N200 Y-1
N210 Z1
N220 G36.1 R4 ;End pattern, retract to 10” + 4”
N230 (IF [$PATTERN_END] THEN)
N240 G91 G1 Z6
N250 (ENDIF)
N260 (ENS)
;
N331107 G90 G0 X0 Y0 M30
A2100Di Programming Manual
Publication 91204426- 001
15
Chapter 9
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204426- 001
16
Chapter 9
May 2002
Menu
Chapter 10
PRINT, MESSAGE, and FILE BLOCKS
Contents
1
2
3
4
5
6
7
8
9
10
11
12
13
14
Overview............................................................................................... 3
Message Output Blocks ...................................................................... 3
Numeric Control Program Message Strings ...................................... 3
MSG (Operator Message Display) Block ............................................ 4
OPR (Operator Query) Block............................................................... 5
INP (Operator Input) Block .................................................................. 6
ALM (Report Alarm) Block .................................................................. 7
PAG (Page Format) Block ................................................................... 8
PRT (Print) Block ................................................................................. 9
JRN (Write to Journal) Block .............................................................. 9
FIL (File Pathname) Block ................................................................. 10
WTF (Write To File) Block.................................................................. 11
COM (Communications) Block.......................................................... 11
DWG (Display Drawing) Block .......................................................... 11
A2100Di Programming Manual
Publication 91204426- 001
1
Chapter 10
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 912044526- 001
2
Chapter 10
May 2002
Menu
1
Overview
The machine control provides NC programs with several means to display or record
messages for the operator, for recording results of machining or probing operations, and
for communication with a host computer system.
All of these are accomplished using Type II blocks specifying a message string and
possibly other parameters. There are also related Type II blocks that control the
destination of the message and the message formatting.
2
Message Output Blocks
Message output blocks cause a message specified by the block contents to be sent to
some destination. Messages can be placed on the operator station display, into the
active NC program output file, into a journal file, or sent to a remote computer system.
Message output blocks can also read operator responses (either a simple YES/NO or a
numeric value). Other message output blocks can request a drawing to be displayed on
the operator station display and can also report an alarm.
3
Numeric Control Program Message Strings
Many of the message blocks include a text string as the primary output. In all cases, the
text of the message is included as a quoted string, usually in the "=" word, using ASCII
characters. Both uppercase and lowercase characters are allowed.
Messages may contain inserts, which are numeric values with format codes. Inserts
allow a message to contain dimensional or other numeric information from temporary,
parameter, common, or system variables. The maximum length of a message, including
its inserts, is 132 characters unless otherwise noted.
A message insert consists of an arithmetic expression followed by a colon (:) and a
format code, all contained within semicolons:
;<arithmetic expr>:<total digits>.<fraction digits>[U]
Where:
G
<arithmetic expr> is any arithmetic expression.
G
<total digits> is the number of characters to be occupied by the formatted
number, including the sign and decimal point (if present).
G
<fraction digits> is the required number of digits to the right of the decimal point in
the formatted number.
G
U specifies that the number is unsigned, that is, that the formatted string should
not contain a plus or minus sign.
If the format specifies zero fraction digits, <total digits> does not include room for a
decimal point. Similarly, if the number is specified as unsigned (that is, the format is
followed by "U") <total digits> does not include space for a sign.
For example: the string ;[@PROBE_X]:9.4;specifies that the contents of the common
variable [@PROBE_X] be converted to a string with nine total characters, including a
sign and decimal point, up to three digits to the left of the decimal point, and four digits to
the right of the decimal point.
A2100Di Programming Manual
Publication 91204426- 001
3
Chapter 10
May 2002
Menu
The same string can be formatted without spaces between the sign and the first digit by
specifying ;[@PROBE_X]:0.4; which causes the formatted string to occupy as many
spaces as necessary to contain the sign, decimal point, four digits to the right of the
decimal point, and all of the whole number digits to the left of the decimal point. A
complete message can contain literal text and any number of embedded format items.
For example, the message string:
”The center is X ;[#X_LOW] + ([#X_HIGH] - [#X_LOW])/2:8.4; inches” with [#X_LOW]
equal to 5.1000 and [#X_HIGH] equal to 5.85 would result in the formatted string: The
centre is X + 5.4750 inches
In addition to message inserts, NC program message strings can contain format codes
that cause the ASCII control characters LF (linefeed), HT (tab), and FF (form feed) to be
placed into the text.
These codes are represented in the message text by a character sequence beginning
with a backslash character ”\”. A new line (two line feed) is specified by ”\n”, a tab by ”\+”
and a form feed (new page) by ”\f”. A single backslash is included in the text by coding
”\\”.
4
MSG (Operator Message Display) Block
The Operator Message Display (MSG) block writes the specified message to the
operator station display. The most recent MSG block message is displayed on the
screen and the previous messages are saved in a journal file that is available for
operator display. The displayed message is cleared by end of program and data reset.
The display of the MSG block message is synchronous with program execution, that is,
the MSG block is displayed after the preceding NC block is executed. NC program
execution continues without pause after the message is sent to the display screen,
therefore, the message may appear on the screen after the subsequent block has
started execution. If operator acknowledgement is required, a program stop (M0) or
optional stop (M1) code can be used.
The format of the MSG block is: [<label>] [Nxxxx] (MSG,”<message string>”) where:
G
<label> is an optional label on the MSG block.
G
Nxxxx is the optional sequence number for the MSG block.
G
<message string> is an NC program message string. The quotes around the
message string are optional. If the message string begins with a quotation mark, the
message string terminates with the next quotation mark or end of block character. If
the message string does not begin with a quotation mark, the message string
terminates with the first close parenthesis or end of block character.
The size of the message string is limited to 132 characters, and the string can contain
message inserts and format codes. There are no word values in the MSG block. The
message string and the comma following the mnemonic can be omitted if an empty
message is required.
Note that message strings that are in quotes may not contain a quote character. This
could arise, for example, if the message used the double quote to indicate inches, as in
N1200 (MSG,”ROUGH THE OUTSIDE USING A 1/2” END MILL”).
A2100Di Programming Manual
Publication 912044526- 001
4
Chapter 10
May 2002
Menu
In this example, the double quote mark in 1/2” actually terminates the message string
and the remaining characters result in a syntax error. This example should be written
without the enclosing quotes e.g.:
N1200(MSG,ROUGH THE OUTSIDE USING A 1/2” END MILL)
Similarly, if the message contains parentheses, the quotes must be used or the close
parenthesis terminates the message string.
5
OPR (Operator Query) Block
The Operator Query (OPR) block allows the NC program to display a prompt message in
a dialog box on the operator station, and request a YES or NO response from the
machine operator. When the OPR block is executed, NC program execution is stopped
until the operator responds by selecting either YES, NO or CANCEL The result of
operators selection is returned in the variable specified in the OPR block. A timeout can
be specified to allow the program to continue after the specified elapsed time if no
operator entry is received.
The format of the OPR block is:
[<label>][Nxxxx](OPR,<response variable> "<prompt>”[T<timeout>])
Where:
G
<label> is an optional label on the OPR block.
G
Nxxxx is the optional sequence number for the OPR block.
G
<response variable> is the name of a local, common, or writable system variable
that is to receive the operator’s response.
G
<prompt> is an NC program message string.
G
<timeout> is the time in seconds that is allowed for the operator response.
The operators response appears in <response variable> when NC program execution
resumes following the operators entry or the timeout. The value of <response variable>
is zero (false) for a NO response, one for a YES response, and two for a timeout. Note
that YES, timeout, and CANCEL are logical true values. If the T word is negative, zero,
or not programmed, there is no timeout and the system waits indefinitely for an answer.
Data Reset cancels such an indefinite wait condition.
In the following example, the NC program asks the operator if a roughing pass is
required:
G
N0100 (OPR,[#ANSWER] = ”Is a roughing pass required?” T30)
G
N0110 (IF [#ANSWER] THEN)
G
N0120 ...
G
... do roughing pass
G
...
G
N200 (ENDIF)
The effect of block N0100 is to post the prompt “Is a roughing pass required?” and wait
30 seconds for an answer. If the operator selects YES or CANCEL, or makes no reply
within 30 seconds, the roughing pass is executed. If NO is selected, program execution
resumes following block N200.
A2100Di Programming Manual
Publication 91204426- 001
5
Chapter 10
May 2002
Menu
6
INP (Operator Input) Block
Operator Input (INP) block allows the NC program to display a prompt message in a
dialog box on the operator station, and request a numeric response from the machine
operator. When the INP block is executed, the NC program pauses until the operator
enters a number, the value of the entered is returned in the variable specified in the INP
block.
A timeout can be specified to allow the program to continue after the specified elapsed
time if no operator entry is received, and a default return value to be returned if the INP
block timeout can also be specified.
The format of the INP block is:
[<label>] [Nxxxx] (INP,<response variable> =”<prompt>” [T<timeout>] [D<default
value>])
Where:
G <label> is an optional label on the INP block.
G
Nxxxx is the optional sequence number for the INP block.
G
<response variable> is the name of a local, common, or writable system variable
that is to receive the operator’s response.
G
<prompt> is an NC program message string.
G
<timeout> is the time in seconds that is allowed for the operator response.
G
<default value> is the value to be returned if the timeout occurs, or if the operator
selects “CANCEL”. If the D word is absent, zero is returned after a timeout.
The operators entered value appears in <response variable> when NC program
execution resumes following the operators entry or the timeout. If a timeout occurs, the
INP block returns the value specified in the D word (the default) or zero if no D word is
present. If the T word is negative, zero, or not programmed, there is no timeout, and the
system waits indefinitely for an answer.
Data Reset cancels such an indefinite wait condition. In addition to the response in the
response variable, the System Variable [$INP_STATUS] contains a value indicating the
result of the operation. $[INP_STATUS] is zero for a normal conclusion (that is, the
operator entered a value), two is a timeout occurred, and three if CANCEL terminated
the INP block operation. The numeric value entered is a signed floating point value.
In the following example, the NC program asks the operator to select which of three
parts to machine.
G
N0100 [#GOOD_INPUT] = 0
G
N0110 (DO WHILE NOT [#GOOD_INPUT])
G
N0120 (INP,[#SELECTION] =”Enter 1 for part #ab2345, 2 for part #ab2369, or 3 for
part #ab2388:” T45)
G
N0130 (SELECT CASE INT([#SELECTION]))
G
N0140 (CASE 0); TIMEOUT
G
N0150 (MSG,”NO PART SELECTED”)
G
N0160 M2
G
N0170 (CASE 1)
A2100Di Programming Manual
Publication 912044526- 001
6
Chapter 10
May 2002
Menu
G
N0180 (CLS,”PART_AB2345”)
G
N0190 [#GOOD_INPUT] = 1
G
N0210 (CASE 2)
G
N0220 (CLS,”PART_AB2369”)
G
N0230 [#GOOD_INPUT] = 1
G
N0240 (CASE 3)
G
N0250 (CLS,”PART_AB2388”)
G
N0260 [#GOOD_INPUT] = 1
G
N0270 (CASE ELSE)
G
N0280 (MSG,”Please select either 1, 2, or 3”)
G
N0290 (END SELECT)
G
N0300(LOOP)
The effect of block N0120 is to post the prompt and wait 45 seconds for an answer. If
the operator selects 1, 2, or 3 the corresponding subroutine is called to machine the
selected part. If zero is selected, or if no response is received before the 45 second
timeout, blocks N0140 to N0160 post a message and quit.
If an entry other than 0, 1, 2, or 3 is received, the CASE ELSE in block N0270 posts a
message and exits the SELECT statement.
The DO WHILE NOT...LOOP in N0110 and N0300 repeats the request until 1, 2, or 3 is
entered, or a timeout occurs. The program could alternatively set the value of
[$INP_STATUS] to detect a timeout or “CANCEL” condition, and take default action such
as timeout or some other action for “CANCEL”.
7
ALM (Report Alarm) Block
The Report Alarm Block allows the NC program to report an alarm and stop cycle in
response to some detected condition. The message in the ALM block is inserted into the
alarm text to specify what condition caused the problem.
The format of the ALM Block is: [<label>] [Nxxxx] (ALM,”<message>”)
Where:
G
< label > is an optional label on the ALM block.
G
Nxxxx is the optional sequence number for the ALM block.
G
< message > is an NC program message string. The message string length is
limited to 75 characters (including any inserts). Characters in excess of 75 are
truncated.
Execution of the ALM block reports an NC Program Alarm alarm. The alarm is reported
when the ALM block is executed, and results in a Feedhold. The <message> string
appears in the alarm text displayed on the operator station as the “cause:” of the alarm.
Program execution can resume when the alarm is cleared and Cycle Start is pressed.
The example could be revised to report alarms if a timeout or invalid response occurs as
follows:
G
N0100 [#GOOD_INPUT] = 0
A2100Di Programming Manual
Publication 91204426- 001
7
Chapter 10
May 2002
Menu
G
N0110 (DO WHILE NOT [#GOOD_INPUT])
G
N0120 (INP,[#SELECTION] =”Enter 1 for part #ab2345, 2 for part #ab2369, or 3 for
part #ab2388:” T45)
G
N0130 (SELECT CASE INT([#SELECTION]))
G
N0140 (CASE 0) ; TIMEOUT
N0150 (ALM, ”No response to part number request”)
G
N0160 M2
G
N0170 (CASE 1)
G
N0180 (CLS,”PART_AB2345”)
G
N0190 [#GOOD_INPUT] = 1
G
N0210 (CASE 2)
G
N0220 (CLS,”PART_AB2369”)
G
N0230 [#GOOD_INPUT] = 1
G
N0240 (CASE 3)
G
N0250 (CLS,”PART_AB2388”)
G
N0260 [#GOOD_INPUT] = 1
G
N0270 (CASE ELSE)
G
N0280 (ALM,”Invalid part selection:;[#SELECTION]:4.0;”)
G
N0290 (END SELECT)
G
N0300 (LOOP)
Note
The message in block N0280 includes the value of the erroneous entry as an insert.
8
PAG (Page Format) Block
Page Format (PAG) block sets the modal values of lines per page, columns per page, tab
setting, and page heading. These values are used by the Print (PRT) block to control the
appearance of printed pages. The format of the PAG block is:
[<label>] [Nxxxx] (PAG, [T<tab setting>] [C<columns>] [R<rows>] [=”<heading>”])
where:
G <label> is an optional label on the PAG block.
G
Nxxxx is the optional sequence number for the PAG block.
G
<tab setting> specifies the number of columns between tab settings. This determines
the amount of space resulting from each ASCII HT (tab) character. If the T word is
absent, a configurable default tab setting is used.
G
<rows> specifies the number of print lines per page. The default is configurable.
G
<columns> specifies the number of columns per line. The default is configurable.
G
<heading> is an optional NC program message string. The string is limited to 132.
characters; any characters in excess of 132 are truncated. The heading is printed at
the top of each page printed by PRT blocks.
A2100Di Programming Manual
Publication 912044526- 001
8
Chapter 10
May 2002
Menu
For example:
A PAG block specifying T5 means that a print line starting with two HT characters starts
printing in the 10th column position. The parameters set by the PAG block are active
until a PRT block specifying F2 (end of print job) is encountered, or until End of Program.
These parameters are not reset by Data Reset.
9
PRT (Print) Block
The Print (PRT) block causes one line to be spooled for printing, or commands a page
eject. The format of the printed text can be controlled by the ASCII control characters LF
(line feed), HT (tab), and FF (form feed). These characters are specified in the message
text by a two-character sequence beginning with a backslash character “\”. A line feed
(new line) is specified by “\n”, a tab by “\t”, and a form feed (new page) by “\f”. A single
backslash is included in a message by “\\”.
The format of the PRT block is:
[<label>] [Nxxxx] (PRT, =”<message>” F<function>)
Where:
G
<label> is an optional label on the PRT block.
G
Nxxxx is the optional sequence number for the PRT block.
G
<message> is an NC program message string.
G
<function> selects the function to perform where:
F1 commands a page eject (top of form) on the printer.
F2 denotes the end of the print job. This sends the print job to the printer for
printing; no printing occurs before the F2 command.
A PRT block contains a message string to print and/or a function to perform. If a function
is specified (F word present) together with a message (= word), the message is printed,
followed by the action requested by the function code. A PRT block specifying no words
(that is, no message and no function code) results in one blank line.
Machine control can be configured to report an alarm on a printer error (which stops NC
program execution) or to ignore the error and to ignore all subsequent PRT blocks. The
printer output is spooled to a printer queue as PRT blocks are encountered. When the
(PRT, F2) block that denotes the end of the print job is encountered the print job is sent
to the printer.
10
JRN (Write to Journal) Block
The Journal (JRN) block allows the NC program to write messages to one or more
journals, these are chronological records of events maintained by A2100. All journal
entries are automatically time-stamped with the time of the journal entry. The specific
journal or journals that receive the NC program journal records is configurable.
The format of the JRN block is:
[<label>] [Nxxxx] (JRN, =”<message>” [I<event identifier>])
Where:
G
<label> is an optional label on the JRN block.
A2100Di Programming Manual
Publication 91204426- 001
9
Chapter 10
May 2002
Menu
G
Nxxxx is the optional sequence number for the JRN block.
G
<message> is an NC program message string. The string is limited to 132
characters; any characters in excess of 132 are truncated. The string can contain
message inserts.
G
<event identifier> is a user-selected numeric value that is placed into the journal
entry and may be used to search for journal entries. The I word is optional; the
default value is zero.
The JRN block is intended to provide a means for an NC program to record significant
events in a time-stamped journal associated with the shift, the job, or the program.
Inserting JRN records in an NC program creates a record of the job execution together
with actual times. Events to be entered might include tool changes, operation beginning
and end, and journal entries before and after program stop or optional stop blocks.
The journal entry consists of an optional numeric event identifier specified by the I word
of the JRN block, and a text message. The I word is intended to allow events to be
grouped into user-defined classes.
11
FIL (File Pathname) Block
File Pathname (FIL) block is used to open and close files to be used by Write to File
(WTF) blocks. The FIL block specifies the file pathname and opens the file.
The format of the FIL block is:
[<label>] [Nxxxx] (FIL, =”<pathname>” [F<function>])
Where:
G
<label> is an optional label on the FIL block.
G
Nxxxx is the optional sequence number for the FIL block.
G
<pathname> is a NC program message string containing the name of the file to
be opened. <pathname> includes the full directory path required to specify the
file, and is limited to a total of 132 characters.
G
<function> specifies the file position where:
F0 or F not programmed, specifies that the file is to be positioned at the beginning
of the file, thus overwriting any previous file content.
F1 specifies that the file is to be positioned at the end of the file, so that new
records are appended to the end of the file.
F2 causes all records that have been written to the file to be “flushed” from the
system buffers and written to the file device.
F3 closes the file currently open.
The ”=” word is required for F0, F1, or F not programmed, and is not permitted with F2 or
F3.
Any error encountered in attempting to open the file (invalid path specification, file
protection, etc.) causes an alarm.
A2100Di Programming Manual
Publication 912044526- 001
10
Chapter 10
May 2002
Menu
12
WTF (Write To File) Block
The Write to File (WTF) block causes one record to be written to the file specified by the
most recent File Pathname (FIL) block. The FIL block with F2 specified is used to close
the file when all of the records have been written.
The format of the WTF block is:
[<label>] [Nxxxx] (WTF, =”<message>”)
Where:
G
<label> is an optional label on the WTF block.
G
Nxxxx is the optional sequence number for the WTF block.
G
<message> is an NC program message string. The string is limited to 132
characters in length; any characters in excess of 132 are truncated.
Machine control can be configured to report an alarm on a file error (which stops NC
program execution) or to ignore the error, and to ignore all subsequent WTF blocks until
another FIL block is encountered. A WTF block with no message string results in an
empty record being written to the file. In this case, both the comma following the block
mnemonic and the = word can be omitted.
13
COM (Communications) Block
The Communications (COM) block sends a message to the specified remote computer
connection. Messages are buffered, and NC program execution continues once the
COM block has been executed, unless the buffer queue fills.
The format of the COM block is:
[<label>] [Nxxxx] (COM,”<destination>”, =”<message>”)
Where:
G
<label> is an optional label on the COM block.
G
Nxxxx is the optional sequence number for the COM block.
G
<destination> is an NC program message string containing the communications
network specific address of the message destination. <destination> is limited to
31 characters in length, any characters in excess of 31 are truncated.
G
<message> is an NC program message string. The string is limited to 132
characters, any characters in excess of 132 are truncated.
For example:
(COM,”COM1:”,”TEST DATA\n\r”)
14
DWG (Display Drawing) Block
The Display Drawing (DWG) block activates a specific drawing stored in a file registered
with the A2100 program management service. The operator is notified that the drawing
is active and can cause the drawing to be displayed on the screen. Execution of the
DWG block simply activates the drawing; NC program execution continues without
waiting for the activation.
A2100Di Programming Manual
Publication 91204426- 001
11
Chapter 10
May 2002
Menu
The format of the DWG block is:
[<label>] [Nxxxx] (DWG,<program>)
Where:
G
<label> is an optional label on the DWG block.
G
Nxxxx is the optional sequence number for the DWG block.
G
<program> is either a quoted NC program message string containing the program
name of the drawing file to be displayed, or a numeric program identifier
associated with the program. In either case, the drawing file is located in the
A2100 program storage directory.
The drawing file specified must contain a drawing in bitmap (BMP) format, Tagged
Image File Format (TIF), Graphics Interchange Format (GIF), PCX, or DXF format.
A DWG block specifying no program; i.e. consisting only of (DWG), deactivates any
drawing that was active, this blanks the screen if the Drawing page is being displayed.
A2100Di Programming Manual
Publication 912044526- 001
12
Chapter 10
May 2002
Menu
Chapter 11
DATA ACQUISITION
Contents
1
1.1
1.2
1.3
1.4
Data Acquisition ........................................................................... 3
Overview........................................................................................ 3
DAI (Data Acquisition Initialisation) ............................................ 3
DAS (Data Acquisition Save) ....................................................... 7
Data Acquisition Sample Program .............................................. 7
A2100Di Programming Manual
Publication 91204426- 001
1
Chapter 11
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204426- 001
2
Chapter 11
May 2002
Menu
1
Data Acquisition
1.1
Overview
The machine control provides a facility for collecting machine and process data in real
time and either storing the data in a file for later processing, or displaying the data on the
workstation screen in real time. Data acquisition is controlled by the NC program using
the Data Acquisition Initialisation (DAI) block to specify:
G
What data to collect.
G
The Data Acquisition Save (DAS) block to write the data to a file.
G
The Data Acquisition On and Data Acquisition Off miscellaneous codes (M34 and
M35 respectively) to start and stop data collection.
The data acquisition facility provides the ability to monitor various program execution
related information, including path velocity and acceleration commands, axis position and
velocity commands, axis position feedback, and other axis motion related information, in
real time. Up to eight simultaneous data items can be monitored.
The data acquisition facility provides NC program control of when data are collected
using the Data Acquisition On and Data Acquisition Off miscellaneous (M) codes. A
programmable trigger facility provides additional control over the start of the data
collection, based on the state of a process variable.
When used with NC program control, the data acquisition facility captures a set of data
points and then writes the captured data to a file.
To perform data acquisition, the NC program does the following steps:
1. Selects the file to receive the data using the File Pathname (FIL) block.
2. Defines the data values to be sampled, the sample interval, and (optionally) the
trigger condition, using the Data Acquisition Initialisation (DAI) block.
3. Starts the machining process.
4. When the section of the process to be measured begins, executes an M34 code to
initiate the data capture process.
5. When the process to be measured is completed, executes an M35 code to stop data
acquisition.
6. Writes the data to the selected file using the Data Acquisition Save (DAS) block.
Steps 4 to 6 can be repeated to capture data on several segments of a process.
Steps 2 to 6 can be repeated if different sets of data are required.
1.2
DAI (Data Acquisition Initialisation)
The Data Acquisition Initialisation (DAI) block is used to define the data items to be
sampled, the rate at which samples are to be taken, the optional trigger condition to start
the data collection, and an ASCII note to be written to the output file identifying the
collected data.
A2100Di Programming Manual
Publication 91204426- 001
3
Chapter 11
May 2002
Menu
The format of the DAI block is:
[<label>] [Nxxxx] (DAI, <data sample specifiers> T<sample period> S<sample time>
V<trigger variable> P<pretrigger time> L<trigger level> R<trigger direction> =”<note>”)
where:
G
<label> is an optional label on the DAI block.
G
Nxxxx is the optional sequence number for the DAI block.
G
<data sample specifiers> are from one to eight words with addresses A to H
specifying the eight possible data sample values. The value of each word is a whole
number in the form XXYY where XX specifies a data source and YY specifies the data
to be sampled.
Values of XX from zero to the number of servo channels on the system select servo
channel related data; the servo channels are always numbered from zero.
Other values of XX select non-axis related data are shown in Table 2.
In either case, YY selects the data value to be measured. The values of YY for per-axis
data are shown in Table 1, and the values YY for the non-axis data are shown in Table
2.
Table 1 Per-Axis Data
YY
0
1
2
3
4
5
6
7
8
9
10
Variable
Axis Command Position
Axis Feedback Position
Axis Velocity Feedback
Reserved
Axis Following Error
Total Error Compensation
Reserved
Reserved
Axis Velocity Command
Reserved
Axis Command Position
The axis servo command position (YY = 0) specifies the position command with all axis
error compensation, reversal error compensation, and other machine compensations
included.
The axis command position (YY = 10) is the axis command generated by the NC path
generator without any machine compensations.
The total error compensation value (YY = 5) is the sum of all machine compensations.
The axis feedback position velocity feedback, and axis following error items all refer to
values measured by the servo subsystem.
The axis velocity command values are inputs to the servo from the NC path generator.
The [$BLOCK_COUNT] item (see Table 2) is a count of NC blocks executed since the
last time Cycle Start was pressed. [$BLOCK_COUNT] is made available to tag captured
data with the NC program block that was executing when the data item was captured.
This value is a system variable named [$BLOCK_COUNT] which is visible to the NC
program.
A2100Di Programming Manual
Publication 91204426- 001
4
Chapter 11
May 2002
Menu
The NC program can write to this item just prior to starting data acquisition to control the
block number captured. The DATA_CAPTURE (xx) information is an array of floating
point variables. The array is a system variable named [$DATA_CAPTURE] which is
visible to the NC program; it can also be used by the machine application as required.
Table 2 NC Block Count
Variable
Axis Direction Cosines
Process Sensor Data
Path Speed
Path Acceleration
XXYY
1800-1808
2000-2039
2100
2101
[$BLOCK_COUNT]
2110
DATA_CAPTURE (xx)
2200-2231
Notes
Digital Servo Only
Instantaneous speed along programmed path
Instantaneous acceleration along programmed path
A numerical value incremented for each NC
program block executed
Computed values from machine application or NC
program
T<sample period> specifies the number of axis servo update intervals between samples.
If the T word is not present, the default is to sample every servo update.
S<sample time> specifies the total sampling time in seconds. The sample time begins
when data acquisition starts, and ends when S seconds have elapsed. If the total data
acquisition buffer size is not large enough to accommodate S seconds of data at the
sample period specified by the T word, the sample period is increased (that is, the
samples are taken less often) to fit the total required sample time. If the S word is not
present, data sampling continues until an M35 code is executed. The data are collected
in a circular buffer; that is, once the collection buffer fills, the oldest data is lost.
V<trigger variable> specifies a variable to be used to trigger data acquisition. Trigger
variables are specified using the same XXYY form as the data acquisition variables. If
the V word is absent, the trigger condition is satisfied and data acquisition is controlled
only by the M34 and M35 codes. Trigger words P, L, and R; are ignored. If a trigger
variable is specified, the trigger condition and the M34 Data Acquisition Enable code
must both be true to start data collection.
P<pretrigger time> specifies the time in seconds before the trigger expression becomes
true that data capture is to be enabled. Pre-triggering is useful if the only value available
for triggering data collection occurs after the occurrence of interest. See Fig 1 for a
graphical representation of how P and S interact to specify the data collection activity.
Note that a positive value of P specifies that data capture starts before the trigger event,
a negative value of P specifies that data capture starts after the trigger.
L<triggerlevel> specifies the value of the trigger variable that represents the trigger point.
For example, if the trigger variable is V2100, which specifies speed along the
programmed path, a trigger level specified as L1000 specifies a trigger event when the
value of path velocity crosses 1000 millimetres per minute (assuming that the system is
in metric mode). Data capture would start the first time the commanded path velocity
exceeded 1000 mm/min after an M34 code.
R<trigger direction> specifies whether the trigger event occurs on the rising or falling
edge of the trigger variable. Fig 2 shows how the R value, in conjunction with the L
(trigger level) value, selects which crossing of the trigger level is the trigger event. The
numeric value of the R word is ignored; only the sign is used. If R is absent or positive,
the trigger event occurs when the trigger variable value crosses the trigger level going
A2100Di Programming Manual
Publication 91204426- 001
5
Chapter 11
May 2002
Menu
from low to high values. If the R word is negative, the trigger event occurs when the
trigger variable value crosses the trigger level going from high to low values.
Fig. 1 Interaction of P and S Triggers to Specify Data Collection
Fig 2 Relationship of R and L Values to Establish the Trigger Level
=”<note>” is an NC program message string which can be written to the data file to
identify the particular set of data. The string is limited to 132 characters, characters in
excess of 132 are truncated. The note is written before the records that contain the
captured data.
If no trigger is specified (V word absent) data acquisition begins as soon as an M34 code
is executed. Data capture ends when either the sample time (S word) is satisfied, or
when an M35 code is executed. If a trigger is specified, data capture starts for the first
time after an M34 code is executed and the trigger condition is satisfied.
To use a trigger, both the V word (which specifies the trigger variable) and the L word
(which specifies the trigger level) must be programmed. The R word is optional, if it is
not present the trigger event occurs when the trigger variable value crosses the trigger
level in the positive-going direction.
A2100Di Programming Manual
Publication 91204426- 001
6
Chapter 11
May 2002
Menu
1.3
DAS (Data Acquisition Save)
The Data Acquisition Save (DAS) block causes the information previously collected by a
Data Acquisition Initialisation (DAI) block and the M34 and M35 Data Acquisition On/Off
codes, to be written to the file specified by the most recent File Pathname (FIL) block.
The format of the DAS block is:
[<label>] [Nxxxx] (DAS) where:
G
<label> is an optional label on the DAS block.
G
Nxxxx is the optional sequence number for the DAS block.
Before a DAS block can be executed, the file must be opened using the FIL block. The
FIL block also specifies whether the data, written as a result of the DAS block, overwrites
the existing file data, or is appended to the end of the file. Execution of the DAS block
does not cause NC program execution to pause, but a subsequent Data Acquisition
Initialisation (DAI) block will pause until the previous DAS block completes its file write.
NOTE:
The DAS block and the WTF blocks both write to the same file. This allows additional
annotations to be placed in the data capture file using WTF blocks.
The format of the data written to the file is a series of ASCII records containing the data
specified by the Data Acquisition Initialisation block. The file contains the collected data
records, which are formatted with a record number, followed by one to eight data sample
values, all separated by a single space.
The data sample values are formatted with a leading minus sign if the value is negative,
followed by the value itself in decimal notation. This format is compatible with most DOS
and Windows plotting programs.
If the ”=” word (which specifies the note to be placed in the output file) is present in the
DAI block, a header block containing the DAI block words specifying the capture
information, the trigger information, the note from the ”=” word, and the time and date is
written as the first record in the file. If the ”=” word is absent, no header is written to the
output file.
If the data acquisition buffer overflows (because the amount of data collected exceeded
the amount of memory available for buffering) an additional header record noting the
overflow is placed at the start of the file.
1.4
Data Acquisition Sample Program
The following part program is an example of using data acquisition to obtain the
command positions, path speed, and block count, during execution of a circular contour.
G71
G17G45G61
G0X-50Y0Z0
(MSG,”CCW CIRCLE”)
(FIL,=”C:\TEST.DAT”)
(DAI,A110 B210 C2100 D2110 T1=”DATA ACQUISITION TEST”)
G71F10000
M34
G4F.045
G3X-50Y0I0J0
A2100Di Programming Manual
Publication 91204426- 001
7
Chapter 11
May 2002
Menu
M35
(DAS)
(FIL,F2)
M2
Execution of this program results in the data file ”test.dat” being created on the users
directory. This file can be accessed using the control file manager utility. The file can be
imported into third party applications to allow manipulation and plotting of the data. A
portion of ”test.dat” is reproduced as follows:
Version 1
1995/07/11 10:19:43
DATA ACQUISITION TEST
VARIABLES: (XXYY): 0110 0210 2100 2110
Axis 1 Command Position
Axis 2 Command Position
Path Speed
Block Count
SAMPLE: Period: 1 (BPI: 0.004500) Time: 0.000000
1 +550.00000 +300.00000 +0.00000 +8.
2 +550.00000 +300.00000 +0.00000 +8.
3 +550.00000 +300.00000 +0.00000 +8.
4 +550.00000 +300.00000 +0.00000 +8.
5 +550.00000 +300.00000 +0.00000 +8.
6 +550.00000 +300.00000 +0.00000 +8.
7 +550.00000 +300.00000 +0.00000 +8.
8 +550.00000 +300.00000 +0.00000 +8.
9 +550.00000 +300.00000 +0.00000 +8.
10 +550.00000 +300.00000 +0.00000 +9.
11 +550.00000 +299.99662 +45.06667 +9.
12 +550.00000 +299.98648 +135.20000 +9.
13 +550.00002 +299.96620 +270.40000 +9.
14 +550.00004 +299.93240 +450.66667 +9.
15 +550.00014 +299.88170 +676.00000 +9.
16 +550.00036 +299.81074 +946.13333 +9.
17 +550.00078 +299.71952 +1216.26667 +9.
18 +550.00154 +299.60804 +1486.40000 +9.
19 +550.00274 +299.47630 +1756.53333 +9.
20 +550.00456 +299.32432 +2026.66667 +9.
21 +550.00720 +299.15208 +2296.80000 +9.
22 +550.01082 +298.95958 +2566.93333 +9.
23 +550.01570 +298.74686 +2837.06667 +9.
24 +550.02208 +298.51392 +3107.20000 +9.
25 +550.03026 +298.26074 +3377.33333 +9.
26 +550.04052 +297.98738 +3647.46667 +9.
27 +550.05322 +297.69384 +3917.60000 +9.
28 +550.06868 +297.38014 +4187.73333 +9.
29 +550.08732 +297.04632 +4457.86667 +9.
30 +550.10952 +296.69242 +4728.00000 +9.
31 +550.13572 +296.31846 +4998.13333 +9.
32 +550.16638 +295.92454 +5268.26667 +9.
33 +550.20194 +295.51066 +5538.66667 +9.
34 +550.24296 +295.07692 +5809.06667 +9.
A2100Di Programming Manual
Publication 91204426- 001
8
Chapter 11
May 2002
Menu
35 +550.28992 +294.62340 +6079.46667 +9.
36 +550.34338 +294.15016 +6349.86667 +9.
37 +550.40392 +293.65734 +6620.26667 +9.
38 +550.47212 +293.14508 +6890.66667 +9.
39 +550.54862 +292.61346 +7161.06667 +9.
40 +550.63402 +292.06270 +7431.46667 +9.
41 +550.72902 +291.49292 +7701.86667 +9.
42 +550.83426 +290.90434 +7972.26667 +9.
43 +550.95048 +290.29716 +8242.66667 +9.
44 +551.07838 +289.67164 +8513.06667 +9.
45 +551.21870 +289.02800 +8783.46667 +9.
46 +551.37220 +288.36654 +9053.86667 +9.
47 +551.53966 +287.68760 +9324.00000 +9.
48 +551.72098 +286.99476 +9549.06667 +9.
49 +551.91592 +286.29160 +9729.06667 +9.
50 +552.12400 +285.58168 +9864.00000 +9.
51 +552.34460 +284.86848 +9953.86667 +9.
52 +552.57690 +284.15546 +9998.93333 +9.
53 +552.81990 +283.44592 +10000.00000 +9.
54 +553.07350 +282.74010 +10000.00000 +9.
55 +553.33768 +282.03818 +10000.00000 +9.
56 +553.61234 +281.34028 +10000.00000 +9.
57 +553.89744 +280.64660 +10000.00000 +9.
58 +554.19292 +279.95726 +10000.00000 +9.
59 +554.49870 +279.27244 +10000.00000 +9.
60 +554.81472 +278.59228 +10000.00000 +9.
:
:
:
:
427 +552.79158 +316.47318 +10000.00000 +9.
428 +552.54982 +315.76324 +10000.00000 +9.
429 +552.31872 +315.04974 +10000.00000 +9.
430 +552.09930 +314.33608 +9954.93333 +9.
431 +551.89334 +313.62900 +9819.73333 +9.
432 +551.70044 +312.92876 +9684.53333 +9.
433 +551.52104 +312.23888 +9504.26667 +9.
434 +551.35540 +311.56298 +9278.93333 +9.
435 +551.20360 +310.90462 +9008.53333 +9.
436 +551.06542 +310.26676 +8702.13333 +9.
437 +550.94000 +309.64970 +8395.73333 +9.
438 +550.82652 +309.05370 +8089.33333 +9.
439 +550.72418 +308.47902 +7782.93333 +9.
440 +550.63220 +307.92588 +7476.53333 +9.
441 +550.54980 +307.39448 +7170.13333 +9.
442 +550.47630 +306.88498 +6863.73333 +9.
443 +550.41098 +306.39754 +6557.33333 +9.
444 +550.35316 +305.93230 +6250.93333 +9.
445 +550.30224 +305.48938 +5944.53333 +9.
446 +550.25726 +305.06552 +5683.20000 +9.
447 +550.21738 +304.65744 +5466.93333 +9.
448 +550.18226 +304.26522 +5250.66667 +9.
449 +550.15146 +303.88888 +5034.40000 +9.
450 +550.12466 +303.52852 +4818.13333 +9.
451 +550.10150 +303.18416 +4601.86667 +9.
A2100Di Programming Manual
Publication 91204426- 001
9
Chapter 11
May 2002
Menu
452 +550.08162 +302.85584 +4385.60000 +9.
453 +550.06474 +302.54360 +4169.33333 +9.
454 +550.05054 +302.24746 +3953.06667 +9.
455 +550.03872 +301.96746 +3736.80000 +9.
456 +550.02904 +301.70360 +3520.53333 +9.
457 +550.02130 +301.45928 +3259.20000 +9.
458 +550.01520 +301.23282 +3020.53333 +9.
459 +550.01050 +301.02424 +2781.60000 +9.
460 +550.00698 +300.83526 +2520.26667 +9.
461 +550.00444 +300.66586 +2258.93333 +9.
462 +550.00266 +300.51606 +1997.60000 +9.
463 +550.00148 +300.38584 +1736.26667 +9.
464 +550.00076 +300.27522 +1474.93333 +9.
465 +550.00034 +300.18420 +1213.60000 +9.
466 +550.00012 +300.11278 +952.26667 +9.
467 +550.00004 +300.06164 +681.86667 +9.
468 +550.00000 +300.02740 +456.53333 +9.
469 +550.00000 +300.00668 +276.26667 +9.
470 +550.00000 +300.00000 +89.06667 +10.
471 +550.00000 +300.00000 +0.00000 +11.
A2100Di Programming Manual
Publication 91204426- 001
10
Chapter 11
May 2002
Menu
Chapter 12
PROGRAM TRANSLATION
Contents
1
1.1
1.2
1.2.1
2
3
4
5
5.1
5.2
6
7
8
9
10
11
11.1
11.2
11.3
12
12.1
13
14
15
16
16.1
16.2
17
18
19
20
21
22
23
24
24.1
Overview............................................................................................... 3
Fanuc Translation ................................................................................ 3
Fanuc Set-up ........................................................................................ 3
Fanuc Translation Parameters Configuration Table.......................... 3
Fanuc G Sub-routine Translation Table ............................................. 4
Fanuc System Registers Table ........................................................... 5
Fanuc® M-Codes Translation Table ................................................... 5
Performing a Fanuc Translation ......................................................... 6
Translation Errors and Recovery........................................................ 7
Fanuc Program and Translation Example.......................................... 7
Degree Of Fanuc® Compatibility ...................................................... 10
Fanuc M-Codes .................................................................................. 17
Fanuc Comments............................................................................... 18
Fanuc Custom Macro A ..................................................................... 18
Fanuc Custom Macros not Supported by Machine Control............ 19
Acramatic 850SX Translation............................................................ 19
Acramatic 850SX Set-up.................................................................... 19
Acramatic 850SX G-CODE Translation Table................................... 20
Acramatic 850SX M-CODE Translation Table .................................. 20
Performing an Acramatic 850SX Translation................................... 20
Translation Errors and Recovery...................................................... 20
Degree of Acramatic 850SX Compatibility ....................................... 20
Acramatic 950 Set-up......................................................................... 29
Acramatic 950 G-CODE Translation Table ....................................... 30
Acramatic 950 M-CODE Translation Table ....................................... 30
Acramatic 950 Machine Register Table ............................................ 31
Acramatic 950 Cycle Parameter Table.............................................. 31
Performing an Acramatic 950 Translation........................................ 31
Degree of Acramatic 950 Compatibility ............................................ 31
A950 Machine State Registers Supported in the Machine
Control................................................................................................ 42
A950 Cycle Parameters Supported in the Machine Control............ 43
A950 Temporary Register Variables Supported in the
Machine Control................................................................................. 43
A950 Sub-routine Parameter Variables Supported in the
Machine Control................................................................................. 44
Fixed Cycle Hole Depth ..................................................................... 44
Sub-routine Translations................................................................... 44
Translation Errors and Recovery...................................................... 45
A2100Di Programming Manual
Publication 91204426-001
1
Chapter 12
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204426-001
2
Chapter 12
May 2002
Menu
1
Overview
The program translation function translates correct part programs, using standard
features written for Fanuc Series 0 MC, and Acramatic 850SX MC controls, into
programs that are compatible with the A2100 control system standard. Fanuc Series 0
MC programs are those written using M and G codes that are considered standard by
Fanuc 0 MC Operator’s Manuals.
Correct Fanuc part programs are those which have successfully run on a Fanuc 0 MC
control. The greater the use of non-standard Fanuc programming practices the lower
the translatability of the Fanuc program to a A2100 compatible program. The degree of
similarity of machine configuration also dictates the degree of translatability of the Fanuc
program.
The A850MC Fanuc translator has been used as a basis for which codes are supported;
however, additional A2100 codes are used wherever possible.
The part program file is opened by the Editor, and translation always begins at the
beginning of the file; each block of the program is then processed until the end of
program is reached, or an error occurs. Errors are posted in a dialog box.
The operator can modify tables to cover special cases, or edit the original part program
to avoid the error condition. Thereafter, the translation must be re-started, and the
processing starts at the beginning of the file. The translated program is stored in the
second edit buffer and may be saved to a new filename by the Editor.
The part program type may be:
G
A Fanuc® Series 0 MC.
G
A A850SX MC.
G
A A950 MC.
The Program Translator is accessed under the Editor MORE FEATURES button and is
activated by the TRANSLATE button.
1.1
Fanuc Translation
The source program TRANSLATION TYPE must be selected as FANUC. (*Fanuc® is a
registered trademark for Fanuc Ltd).
1.2
Fanuc Set-up
Parameters for translation must be properly set-up before any translation can be
performed, and is done by pressing the SETUP button.
The TRANSLATION
PARAMETERS, SYSTEM REGISTERS, M-CODE TRANSLATION and USER G-CODE
TRANSLATION tables are look-up tables used by the translation process.
To reduce translation time, a maximum (limiting) value (i.e. all nines) should be entered
into each table under the "Fanuc” column headings after the last entry, to mark the end
of the table, this will stop the translation process from searching the rest of the table.
1.2.1
Fanuc Translation Parameters Configuration Table
The translation parameters configuration table consists of data that can be taken from a
Fanuc® control system parameter table. These data are used during a translation and
A2100Di Programming Manual
Publication 91204426-001
3
Chapter 12
May 2002
Menu
must be properly set-up to ensure accurate translation. The following is a list of the
TRANSLATION PARAMETERS table items and the corresponding Fanuc SYSTEM
PARAMETER number.
TRANSLATION PARAMETERS
1
2
3
4
5
6
7
8
9
10
11
12
13
2
One-Digit Feedrate value (F0) Rapid Traverse
One-Digit Feedrate value (F1)
One-Digit Feedrate value (F2)
One-Digit Feedrate value (F3)
One-Digit Feedrate value (F4)
One-Digit Feedrate value (F5)
One-Digit Feedrate value (F6)
One-Digit Feedrate value (F7)
One-Digit Feedrate value (F8)
One-Digit Feedrate value (F9)
Boring bar tip shift direction. Used by ”No-Drag” boring
cycles.
Given Plane Selection
Value
G17 G18 G19
=====
=== === ===
0
+X +Z +Y
1
-X
-Z
-Y
2
+Y +X +Z
3
-Y
-X
-Z
Co-ordinate system rotation command is translated to a
”(ROT, G2...” incremental block if this value is set to 1, and
a ”(ROT,G3...” absolute block if set to 0.
If ”1” then insert an M6 code in a block containing a T-word
if no M6 code is found in that block.
Fanuc® SYSTEM
PARAMETERS
One-digit F0
One-digit F1
One-digit F2
One-digit F3
One-digit F4
One-digit F5
One-digit F6
One-digit F7
One-digit F8
One-digit F9
#0002 bits
PMXY2 and PMXY1.
=====
=====
0
0
0
1
1
0
1
1
(G76 and G87 command)
#0041 bit RIN
N/A
Fanuc G Sub-routine Translation Table
The G sub-routine translation table contains information to perform translation of Fanuc
User G-codes (those that reference macro programs, other than Custom Macro A) into
User G-codes. The ”TRANSLATION TEXT” column is a text field of 32 characters to
hold the Machine control translation of the adjacent Fanuc code.
This table may only be used if the programs being translated contain Fanuc User Gcodes that reference macro programs (other than Custom Macro A). When a Fanuc
User G-code is found in this table during translation, the translator will substitute the
corresponding machine control and User G-code, and append the remaining words from
the Fanuc program block to the program block.
A machine control User G-code subroutine must be written to perform the same
operations as the Fanuc User G-code subroutine counterpart (not a function of this
translator). It must also use the same words that are programmed in the block with the
Fanuc User G-code.
A2100Di Programming Manual
Publication 91204426-001
4
Chapter 12
May 2002
Menu
Example:
Fanuc
G-SUB NUMBER
(Numeric Field)
25
999
3
A2100
TRANSLATION TEXT
(Text Field)
G125
Fanuc System Registers Table
The purpose of the machine control configuration table is to match the Fanuc® system
variables with the appropriate machine control system variables.
The Fanuc system variable is a 4-digit number and is preceded by a # when used in a
part program. This 4-digit number is placed in the System Variable Number column with
the associated machine control system variable adjacent.
Example:
SYSTEM VARIABLE
NUMBER
5001
5002
9999
TRANSLATION TEXT
$CURPOS_PGM(X)
$CURPOS_PGM(Y)
Fanuc® program:
G01 X#5001
A2100 Translation
G1 X [$CURPOS_PGM(X)]
4
Fanuc® M-Codes Translation Table
The machines control configuration table allows Fanuc M-code values to be entered into
the ORIGINAL M-CODE column. The A2100 TRANSLATION column is a text field of 15
characters to hold the machine control translation of the adjacent Fanuc M-code.
Example:
Fanuc
M-SUB NUMBER
(Numeric Field) 3-digit
1
2
15
21
999
MACHINE CONTROL
TRANSLATION TEXT
(Text Field) up to 32
characters
M1
M2
$(INV,X1)$
In this example the machine control translation for a Fanuc M21 code (represented in the
text field as ”$(INV,X1)$”) is the machine control type II block to invoke X-axis inversion.
The dollar sign at the beginning and end of the text indicates to the translator to insert a
line feed before and after the text. In other words, the translation of the Fanuc M21 code
A2100Di Programming Manual
Publication 91204426-001
5
Chapter 12
May 2002
Menu
will be a single block containing ”(INV,X1)”. Any items before the M21 code would be in
the block previous to ”(INV,X1)” and any items after the Fanuc M21 code would be in the
block following the ”(INV,X1)”.
Fanuc program
G17 M21 M5
A2100 Translation
G17
(INV, X1)
M5
If Fanuc M-code is entered into the table with no corresponding information in the A2100
TRANSLATION column (as M15 in above example) the M word and value will be
removed during the translation. If a Fanuc M-code is not found in the table, an error will
be reported.
A Fanuc® M-code can be translated to set a variable that is internal to the translation
process.
Example:
M-CODE VALUE
29
TRANSLATION TEXT
{SOLIDTAP=1}
In this example the translation of the M29 code will set the internal variable SOLIDTAP
to 1. This allows the translator to translate any tapping canned cycle to the machine
control G84 code.1 for solid tapping. This flag will be turned off when a non-tapping Gcode is encountered, or when another M-code is translated that is set-up in the table to
set SOLIDTAP to zero.
The braces, { and } in the above example delimit the setting of any internal variable. No
spaces are allowed inside these braces. The internal variable name, “SOLIDTAP” in
this case, is a predefined name. This is the only internal translation variable that can be
set at this time.
If a Fanuc M-code is entered into the table with no corresponding information in the
A2100 TRANSLATION column (as M15 in the M-codes translation table example) the
M-word and value will be removed during the translation. If a Fanuc® M-code is not
found in the table, an error will be reported.
The M98 code is a Fanuc sub-routine call and is programmed with a P-word (e.g.. M98
P100) and will be translated to the “(CLS,)” block with an identifier.
The M99 code defines the end of a Fanuc® subroutine and will be translated into an
machine control “(ENS)” block.
5
Performing a Fanuc Translation
Press the “Translate” button under the “More Features” menu button on the Editor to
display the translation dialog box. Start translation by pressing the “Translate” button in
the dialog box. The window containing the Fanuc® program must be the active window.
A2100Di Programming Manual
Publication 91204426-001
6
Chapter 12
May 2002
Menu
The translation always starts from the beginning of the program, and the translated
program is stored in the second edit buffer. If the translation is successful, the translated
program should be saved with a new filename by the Editor.
5.1
Translation Errors and Recovery
If an error occurs while performing a translation, the translation will stop at the block
containing the error and a dialog box will display the related error message, and the
cursor will be positioned at the word that caused the error. After the dialog box is
cleared, a table may be modified to cover special cases, or the Editor can be used to
correct the original Fanuc® part program. This Fanuc® part program is again translated
until no further errors exist.
5.2
Fanuc Program and Translation Example
The following Fanuc part program is interlaced with the machine control translation. This
program contains linear and circular moves together with CDC and tool length
compensation. Spacing between words was added for readability.
The original Fanuc part program file is opened by:
1. Pressing the Edit mode button.
2. Pressing the More Features menu button.
3. Pressing the Translate menu button to bring up the translation dialog box.
4. Under Translation Type, pressing the Fanuc menu button to select type.
5. Press the Translate button in the dialog box to start translation.
Fanuc (1) O1949 (SAMPLE PART WITH CUTTER DIAMETER COMPENSATION)
A2100 (1) [PRG_1949] :1949
The O word or the colon (:) in the first program block is translated as the
colon block number. Any subsequent O word will be translated as the
beginning of a sub-routine. The [PRG_1949] label may be used for mainline
program branching.
(MSG, SAMPLE PART WITH CUTTER DIAMETER COMPENSATION)
The Fanuc program name is translated to a Type II message block, and is
placed in a separate block as the machine control allows only Type I data in
a colon block.
[@PREV_FIXTURE] = 0
This machine control common variable is initialised for later use.
[$CYCLE_PARAMS(2)GAGE_HT_INCH] = 0
[$CYCLE_PARAMS(2)GAGE_HT_MM] = 0
Since the Fanuc system did not use gauge height, the machine control
values are set to zero.
Fanuc (2) N2 (TOOL-1 .500 ENDMILL)
A2100 (2) N2(MSG,TOOL-1 0.500 ENDMILL)
Another message block.
A2100Di Programming Manual
Publication 91204426-001
7
Chapter 12
May 2002
Menu
Fanuc (3) N3 G00 G80 G90 G40 G49 G17 G20
A2100 (3) N3 G80
A G80 code will always be placed in a separate block. Earlier software
versions included an R plane assignment to the current position of the Z axis
R[$CURPOS_PGM(Z)] to prevent motion.
N3 G0 G90 G40 G17 G70 O0
The Fanuc block contains some initialisation. Notice that the Fanuc G20
code, which is inch programming, is changed to G70 cod, which is inch
programming for the machine control. The Fanuc G49 code is translated to
a machine control O-word of value zero.
Fanuc (4) N4 G91 G28 Z0 M19
A2100 (4) N4 [$CYCLE_PARAMS(2)HOLE_DEPTH] = 1
Since the absolute mode was changed to the incremental mode, the
machine control hole depth is selected as incremental.
N4 G91 G28 Z0
The Fanuc block contains a G28 code that is translated into a machine
control G28 code, without a P-word, to establish tool change position as the
reference point.
Fanuc (5) N5 T01 M06
A2100 (5) N5 T1 M6
This M-code table must be present in the M Code Translation table.
Fanuc (6) N6 G54 G90 G00 X0 Y0
A2100 (6) N6 G90 G0 X0 Y0 H1
N6[@X_POS]=[$CURPOS_PGM(X)]-[$FIXTURE(1)X]
N6[@Y_POS]=[$CURPOS_PGM(Y)]-[$FIXTURE(1)Y]
N6[@Z_POS]=[$CURPOS_PGM(Z)]-[$FIXTURE(1)Z]
N6(IF [@PREV_FIXTURE] = 0 GOTO [FIX_1])
N6[@X_POS]=[@X_POS]+[$FIXTURE([@PREV_FIXTURE])X]
N6[@Y_POS]=[@Y_POS]+[$FIXTURE([@PREV_FIXTURE])Y]
N6[@Z_POS]=[@Z_POS]+[$FIXTURE([@PREV_FIXTURE])Z]
[FIX_1]N6X[@X_POS]Y[@Y_POS]Z[@Z_POS]H1
N6[@PREV_FIXTURE] = 1
The translation of the Fanuc G54 to a machine control fixture offset (H1)
generates this series of blocks to avoid axis motion.
N6[$CYCLE_PARAM(2)HOLE_DEPTH] = 0
Since the incremental mode was changed to the absolute mode, the
machine control hole depth is selected as absolute.
N6 G90 G0 X0 Y0
Fanuc (7) N7 G41 D21 Y1.75
A2100 (7) N7 G41 O21 Y+1.75
The Fanuc Offset Table entry 21 (D word) is translated to a machine control
Programmable Tool Offset Table entry (O word). The G41 code is used to
designate the tool diameter field of the table.
A2100Di Programming Manual
Publication 91204426-001
8
Chapter 12
May 2002
Menu
Fanuc (8) N8 G43 Z.1 H01 S2000 M03
A2100 (8) N8 Z0.1 O1 S2000. M3
The Fanuc Offset Table entry 01 (H word) is translated to a machine control
Programmable Tool Offset Table entry (O word). The G43 code is used to
designate the tool length field of the table.
Fanuc (9) N9 G01 Z-.375 F3. M08
A2100 (9) N9 G1 Z-.3750 F3. M8
Same.
Fanuc (10) N10 X.7753 F12.
A2100 (10) N10 X.7753 F12.
Same.
Fanuc (11) N11 G02 X2.25 Y.2753 R-1.25
A2100 (11) N11 G2 X2.25 Y0.2753 P-1.25
The Fanuc block is a circular move whose radius is described by an R
word. This R-word is translated to a P word for the machine control.
Fanuc (12) N12 G00 Z.1
A2100 (12) N12 G0 Z0.1
Re-establish linear interpolation mode.
Fanuc (13) N13 G40 X0 Y.75
A2100 (13) N13 G40 X0 Y0.75
Same. CDC is cancelled
Fanuc (14) N14 M19 M30
A2100 (14) N14 M02
The last Fanuc block is an M30 code that is an end of program. A Fanuc
M30 code may be set- up in the machine control M-code translate table for
an M30 or an M2 code. The machine control M30 code is an End of
Program code that unloads the tool from the spindle. The machine control
M2 code is an End of Program code that does not unload the tool unless a
T-word is present.
Consider the case where the M19 code, in Fanuc part program block (14), is
NOT set-up in the M-CODES translation table. When the translator
processes the M19 code it cannot find it in the table and displays the alarm
”NO TRANSLATION FOR M-CODE”. Recovery from this alert can be
handled in two ways:
G Add this M-code to the M-CODES translation table with either a blank (M
- code will be removed) or a corresponding machine control M - code,
then re-start the translation.
G
Remove this M - code from the original Fanuc program using the Editor,
then restart the translation.
A2100Di Programming Manual
Publication 91204426-001
9
Chapter 12
May 2002
Menu
6
Degree Of Fanuc® Compatibility
This translation feature is designed to translate part programs written for the standard
Fanuc 0-MC control. If the part program falls outside of the following specification some
manual modifications to the program may be needed.
The following document lists those items that are, and also are not supported by the
translation function on the machine control. The ”Comments” column in this list
describes both the Fanuc and the machine control operations.
G
The items bulleted by an ”f” are the Fanuc description for the particular function.
G
The items bulleted by an ”m” are descriptions of how the machine control translate
function will translate the Fanuc function.
Function
Positioning
Linear
Interpolation
Circular
CW
CCW
Interpolation
Dwell
Fanuc G-codes Supported in the Machine Control
Fanuc® A2100
Comments
Code
Code
G00
G0
f Fanuc movement is not a straight line since the rapid
traverse rate is set-up for each axis independently by
system parameters. Therefore, each axis
independently accelerates/decelerates to and from its
individual rapid rate.
m The machine control always moves in a straight line for
G codes. In some cases a different tool path may
result in a problem.
By keeping this as a machine control G0, which is a
linear move, the tool path is more easily predicted.
G1
m Same.
G01
G02
G03
G2
G3
f
m
G04
G4
f
m
Exact Stop
G04
G9
f
m
Exact Stop
Polar Coordinates
Command
Cancel
G09
G15
G9
E-word
and Lword
m
f
m
A2100Di Programming Manual
Publication 91204426-001
Fanuc uses an R-word to define the radius of the
circle. If the I and J words are programmed, they are
always incremental irrespective of G90 or G91 mode.
The R-word is translated to a P-word for the machine
control. A machine control Configuration table is
interrogated for the centre point specification status
and the centre point specification words (I, J and K)
will be translated in accordance with this status.
Dwell, when programmed with a P or X word on
Fanuc,
with a 53 format (seconds).
The commanded time is directly translated to an Fword.
Exact Stop when P or X is not programmed. This
allows axis motion to decelerate to a stop. Non-modal.
Exact Stop.
Same
Fanuc uses this code to cancel the modal G16 code.
The machine control cancels the translation to E and L
words.
10
Chapter 12
May 2002
Menu
Function
Polar Coordinates
Command
Plane Select
XY
Plane Select
ZX
Plane Select
YZ
Inch Input
Metric Input
Reference
Point Return
Check
Fanuc G-codes Supported in the Machine Control
Fanuc® A2100
Comments
Code
Code
G16
E-word
f Depending on the plane selected by G17, G18, or
and LG19; Fanuc uses the X-word for the Command Radius
word
in the first axis of the plane and the Y-word for the
m Angle.
The machine control translates the Y-word to an Eword and calculates the distance to move for the Lword.
G17
G17
m Same
G18
G18
m Same
G19
G19
m Same
G20
G70
f
G71
m
f
G21
G27
Multiple
blocks
m
f
m
Reference
Point Return
G28
G28
f
m
Reference
Point Return
G28
G28
f
m
A2100Di Programming Manual
Publication 91204426-001
Fanuc uses this code to designate that the part
program is in inches.
Translate to G70 for the machine control.
Fanuc uses this code to designate that the part
program is in metric.
Translate to G71 for the machine control
This Fanuc G-code rapids to an intermediate point (if
X,Y,Z are programmed in this block) and then to a
reference point. This reference point is a fixed location
on the machine and is set-up by limit switches and
system parameters.
After reaching these switches an operator light comes
on (i.e. the ”check”).
As the machine control is neither set-up with these
limit switches nor an operator light, this code will be
translated to a G28 block without a P-word (the
machine control treats G28 without a P-word as a
return to tool change position via the intermediate
point) followed by an ”(MSG,)” block and then an M0
block.
Example:
G28X___Y___Z___$
(MSG,______________)$
M0$
This Fanuc block operates the same as the Fanuc G27
block, but without the check feature. This translates to
the machine control G28 without a P-word which
functions similar to the Fanuc G28 with the reference
point at the tool change position; and the intermediate
point co-ordinates are modal.
This Fanuc G-code rapids to an intermediate point (if
X,Y,Z are programmed in this block) and then to a
reference point. This reference point is a fixed location
on the machine and is set-up by limit switches and
system parameters.
This translates to the machine control G28 without a Pword that specifies the reference point at the tool
change position; and the intermediate point coordinates are modal.
11
Chapter 12
May 2002
Menu
Fanuc G-codes Supported in the Machine Control
Fanuc® A2100
Comments
Code
Code
The machine control reference point is specified by the
P-word:
P1 or no P-word = Automatic Tool Change Position.
P2 = Manual Tool Change Position.
P3 = M26 Spindle Axis Full Retract Position.
P4 = Unload Position..
are not necessarily the same as the Fanuc Points
Return From
G29
G29
f Travel is from the previous G28 or G30 reference point
Reference
to the intermediate point and then to the X,Y,Z point
programmed in this block (if any).
Point
m This translates to the machine control G29. The return
travel is from the previous reference point, via the
modal intermediate point, to the position commanded
in this block.
2nd, 3rd, 4th
f Same as G28, but contains a P-word (i.e. P2, P3, P4)
G30
G28
Reference
to define the 2nd, 3rd and 4th reference point.
Point Return
m This translates to a machine control G28 which
functions similarly to the Fanuc G30 with the reference
point specified by the P-word (i.e. P2, P3, P4) and the
intermediate point co-ordinates are modal.
The machine control reference points specified by the
P-word are:
P2 = Manual Tool Change Position
P3 = M26
P4 = Unload Position
These are not necessarily the same as the Fanuc
points.
Thread Cutting G33
G33
f Uses F word to specify the lead in the longer axis.
Equal Lead
Thread cutting starts when the spindle encoder detects
a 1 - turn signal.
m Available on Release 2. Uses K and I words to specify
the lead in the Z and X axes. If two consecutive
moves are commanded in the threading mode the
second move continues immediately following the first
to provide a continuous thread. An automatic pullout
at the end of the thread is specified by the endpoint
being programmed away from the line specified by the
thread lead. A tapered thread is specified by the K
and I lead.
G68
f Uses optional device to measure the tool in the
Automatic Tool G37
spindle, and enters that value in the active offset (HLength
word). May have an X, Y or Z axis programmed.
Measurement
m Translates the Fanuc G37 to a G68 (Tool Probe, Set
Tool Length) and delete X, Y or Z words if
programmed in the block.
Note: The G68 will update the current tool data entry.
Cutter
G40
G40
m Same.
Compensation
Cancel
Function
A2100Di Programming Manual
Publication 91204426-001
12
Chapter 12
May 2002
Menu
Fanuc G-codes Supported in the Machine Control
Fanuc® A2100
Function
Comments
Code
Code
Cutter
G41
G41
f Fanuc G41 and G42 use H-words (or D-words) whose
Compensation
values are indexes into an offset table where the offset
Left
amount to be applied is stored. This H-word (or Dword) after G41 changes the offset amount without
changing tools. Fanuc allows CDC in XY, XZ and YZ
planes under control of the G17/G18/G19 group.
The Fanuc H-word (or D-word) will be translated into
an O-word, whose value will index into the machine
control Programmable Tool Offset table. This table is
analogous to the ”H” (or ”D”) offset table on the Fanuc
control.
G42
G42
m Same as G41.
Cutter
Compensation
Right
Positive Tool G43
O-word
f An offset in the ”H” offset table, which is indexed by
Length Offset
the H-word in this block, is added to the tool length.
m This H-word, as in G41 and G42, will be translated into
an O-word for machine control. The value of this Oword will index into the same machine control
Programmable Tool Offset table used by G41 and
G42.
Negative Tool G44
O-word
m Same as G43.
Length Offset
Tool Length
f Tool length offset is cancelled with an H-word (without
G49
O0
Offset Cancel
tool removal on a Fanuc)
m An O-word value of zero cancels the tool length offset
without removing the tool.
Scaling Cancel G50
G150
m Same.
Scaling
G51
G151
m Same.
Local CoG52
G52
m Same.
ordinate
System Setting
G53
G98.1
m Same.
Machine Coordinate
System Select
f Fanuc allows up to 6 different co-ordinate systems
Work CoG54
H1
selected by the respective G-code.
ordinate
System 1
m Select Fixture Offset 1.
Select
Work Cof Fanuc allows up to 6 different co-ordinate systems
G55
H2
ordinate
selected by the respective G-code.
System 2
m Select Fixture Offset 2.
Select
Work CoG56
H3
f Fanuc allows up to 6 different co-ordinate systems
ordinate
selected by the respective G-code.
System 3
m Select Fixture Offset 3.
Select
Work CoG57
H4
f Fanuc allows up to 6 different co-ordinate systems
ordinate
selected by the respective G-code.
System 4
m Select Fixture Offset 4.
Select
A2100Di Programming Manual
Publication 91204426-001
13
Chapter 12
May 2002
Menu
Function
Work Coordinate
System 5
Select
Work Coordinate
System 6
Select
Single
Direction
Positioning
Exact Stop
Mode
Automatic
Corner
Override
Fanuc G-codes Supported in the Machine Control
Fanuc® A2100
Comments
Code
Code
G58
H5
f Fanuc allows up to 6 different co-ordinate systems
selected by the respective G-code.
m Select Fixture Offset 5.
G59
H6
Fanuc allows up to 6 different co-ordinate systems
selected by the respective G-code.
m Select Fixture Offset 6.
G60
G9
f This is a non-modal positioning move.
m Use machine control G9 without single direction.
G61
G60
G62
G61
Tapping Mode G63
(Ignore FOV)
M49
Cutting Mode
Macro Call
G61
Remove
f This is a modal positioning mode for Fanuc ®.
m Same.
f When the Fanuc G62 is commanded during cutter
compensation, cutting feed rate is automatically
overridden at corner.
m Use machine control G61 contouring mode. A G61.1
and G61.2 will be available in a future release of the
machine control.
f Tapping mode sets feedrate override to 100% and
disables feedhold,
m Translated to output M49 to inhibit feedrate override.
m Translated to the machine control contouring mode.
f This Fanuc G-code performs arithmetic and logic
functions under Fanuc macro’s type A. An H-word (199) is assigned to each function. P, Q and R-words
are used to pass information to these functions.
m This machine control translation will equate a common
variable (@) to an expression, or will set-up a
conditional branch to a targeted program block.
f After the Fanuc G66 is executed, every subsequent
block thereafter causes the macro designated by the
P-word to be called.
m The machine control translation will call the sub-routine
respective to the P-word for every subsequent block.
Note: This sub-routine must be translated from the
Fanuc® sub-program and registered by the user as a
(temporary) separate program in the machine control
program directory.
f This Fanuc code cancels the modal macro activated
by the G66 code.
m The machine control translation cancels the subroutine activated by the G66 code.
f Fanuc allows rotation in XY, YZ or XZ planes. It uses
an R-word to describe the angle of rotation.
m This will be translated to a machine control Type II
rotate block [i.e. (ROT,) ] with the R-word being
translated to an A-word, the plane is selected by G17,
G18 or G19.
m Translated to a machine control Type II rotation cancel
block with an A-word value of zero.
G64
G65
Custom Macro G66
Modal Call
Repeat
CLS/DFS
Custom Macro G67
Modal Call
Cancel
Cancel
CLS/DFS
Co-ordinate
Rotation
G68
”(ROT,”
Co-ordinate
Rotation
Cancel
G69
”(ROT,”
A2100Di Programming Manual
Publication 91204426-001
f
14
Chapter 12
May 2002
Menu
Fanuc G-codes Supported in the Machine Control
Fanuc® A2100
Function
Comments
Code
Code
Peck Drilling
G73
G83
m This Fanuc G-code translates to a machine control
Cycle
G83 code with the J-word set for chip breaking.
Counter
f The Fanuc control uses a G74 for left-hand tapping
G74
G84
Tapping Cycle
and G84 for right-hand tapping.
(Floating)
m The machine control uses G84 (rigid tapping)
G74
G84.1
f The Fanuc control requires programming an M29 prior
Counter
to this block for rigid tapping.
Tapping Cycle (M29)
(Rigid)
m The machine control uses G84.1 with an M4 in the
preceding block.
f Fanuc specifies the shift at the bottom of the hole with
Fine Boring
G76
G86 with
a Q-word and a parameter is used to specify whether
U-word/Vthe shift is in +X, -X, +Y, or -Y.
word
m This translates into a machine control G86 cycle with
the Q-word value being used for either the U-word or
V-word.
Canned Cycle G80
G80
m Same
Cancel
Drilling Cycle, G81
G81
m Translate Fanuc words to machine control words.
Spot Boring
Drilling Cycle, G82
G82
m Translate Fanuc words to machine control words.
Counter Boring
Peck Drilling
G83
G83
f Same as Fanuc G73 but performs chip clearing.
Cycle
m Translates so that the machine control G83 block
contains a J-word defined for chip clearing.
Tapping Cycle G84
G84
m Translates Fanuc words to machine control words.
(Floating)
Tapping Cycle G84
G84.1
f The Fanuc control requires programming an M29 prior
(Rigid)
(M29)
to this block for rigid tapping.
m The machine control uses G84.1 with an M3-in the
preceding block.
Boring Cycle
G85
G85
m Translate Fanuc words to machine control words.
(Spindle runs
on Retract)
G86
G86
m Translate Fanuc words to machine control words.
Boring Cycle
(Spindle stops
bottom then
Retracts)
Back Boring
G87
G87
m Translate Fanuc words to machine control words.
Cycle
Boring Cycle
G89
G89
m Translate Fanuc words to machine control words.
(Dwell at
bottom)
Absolute Input G90
G90
m Same
Incremental
G91
G91
m Same
Input
G92
m Same
Programming G92
Absolute Zero
Point
A2100Di Programming Manual
Publication 91204426-001
15
Chapter 12
May 2002
Menu
Function
Feed per
Minute
Feed per
Rotation
Fanuc G-codes Supported in the Machine Control
Fanuc® A2100
Comments
Code
Code
G94
G94
f The Fanuc F-word format is xxx.xx inch and xxxxxx
m metric.
Note: Fanuc also allows a one-digit F code feed (i.e.
F1-F9) which selects a feedrate set in advance as a
parameter for each number. These values are in the F
PA-RAM Configuration table. F0 is rapid rate.
f This Fanuc code performs a feed per revolution
G95
G95 Tfunction. The machine control code performs a feed
word (1
tooth)
m per tooth function. The Number of Teeth must be set
to 1 in Tool Data .
G96
G96
m Available in Release 2. Same.
Constant
Surface Speed
Spindle Speed G97
in RPM
Return to Initial G98
Point in
Canned Cycle
G99
Return to R
Point in
Canned Cycle
G97
m Same.
W-word
f
Remove
In Fanuc canned cycles this allows the Z-axis, after
retracting to the ”R” plane, to retract to the point at
which it initially started above the ”R” plane.
m The machine control canned cycles will be set-up with
a W-word for this function.
m This is the normal machine control mode.
G-Codes Not Supported in the Machine Control
Function
Fanuc® Code
Comments
Stored Stroke Check Function
G22
ON
Stored Stroke Check Function
G23
OFF
Skip Function
G31
Function
Fanuc® Code
Comments
Corner Offset - Circular
G39
This is used under Fanuc cutter
compensation ”B” to perform small circular
Interpolation
moves, when under G41 or G42 mode, to
align the centre of the compensated tool to
the start point of the next block.
Tool Offset Increase
G45
Tool Offset Decrease
G46
Tool Offset Double Increase
G47
Tool Offset Double Decrease
G48
Constant Surface Speed Control
G96
Machine Control (Future release) G33
Boring Cycle
G88
Fanuc:
The spindle stops at the bottom of a single
hole and the tool is manually fed to the R
plane.
Machine Control:
The Web/Bore cycle is used to machine
two inline holes with a rapid move between
the machining steps. The spindle axis
rapids to the clearance plane.
A2100Di Programming Manual
Publication 91204426-001
16
Chapter 12
May 2002
Menu
7
Fanuc M-Codes
The following M-codes will always be translated as follows and should not be entered
into the M-CODE TRANSLATION table.
Function
Fanuc®
Code
A2100
Code
Subroutine
M98
”(CLS,”
Comments
f
m
Return from M99
Subroutine
”(ENS)”
f
m
Fanuc uses an M98 with a P-word in the part
programs to call subroutines. An O-word defines
the beginning of a subroutine and an M99 is a
return.
This code is translated into a machine control
(CLS,”SUB-xxx”) Type II block.
After successful completion of a translation the
translator will automatically cut out any subroutines, and will save and register them in the
part program directory. The sub-routine filename
will consist of the original un-translated program
name with “SUB-xxxx” appended at the end.
Where xxxx is the sub-routine number from the Pword of the M98.
Example:
Original filename Plate #19N50.
Sub-routine filename Plate #19N50SUB-1001
Note: This sub-routine must be translated from
the Fanuc sub-program. Release 1 software
requires it to be registered as a (temporary)
separate program in the machine control program
directory, while Release 2 software allows inline
sub-routines.
Fanuc uses an M99 to define the end of a
subroutine. The code will be translated to a
machine control ”(ENS)” Type II block.
All other M-codes must be in the ”M-CODE TRANSLATION” table, as shown in the
following example. The ”ORIGINAL M-CODE” column represents the value of the Mcode found in the Fanuc part program, while the ”A2100 TRANSLATION” column shows
the translated code.
Original M-Code
A2100 Translation
Comments
21
$(INV,X1)$
X axis Mirror Image
22
$(INV,Y1)$
Y axis Mirror Image
23
$(INV,B1)$
B axis Mirror Image
24
$(INV,X0Y0B0)$
Mirror Image Cancel
29 *
{SOLIDTAP=1}
Solid Tapping
* The braces are delimiters that designate an internal variable that is set to the value indicated.
For the value of one, a Fanuc G74 or G84 is translated into an machine control G84.1 for solid
tapping. Any non-tapping G-code (e.g. G0, 1, 2, 3, or other canned cycle G-code) will turn this
internal flag off. Another M-code with a translation text of {SOLIDTAP=0} will also turn off this
internal flag.
A2100Di Programming Manual
Publication 91204426-001
17
Chapter 12
May 2002
Menu
8
Fanuc Comments
Fanuc A2100
Comments
Code Code
Comment/MSG (.......) ”(MSG,” f Fanuc uses parentheses to encompass a
program comment.
Delimiters
m The machine control translator inserts an ”MSG,”
immediately following the ”(” delimiter to create a
Type II block.
Function
9
Fanuc Custom Macro A
The following list of Fanuc type A Custom Macros is supported by the machine control
translation feature. The machine control translation will equate a common variable (@)
to an expression, or will set-up a conditional branch to a targeted program block.
Example translations follow in this table.
Fanuc G65
Fanuc Function
H-Code
01
Definition, substitution
02
Addition
Fanuc Definition
#i = #j
#i = #j + #k
03
Subtraction
#i = #j - #k
04
Product
#i = #j * #k
05
Division
#i = #j / #k
21
22
23
Square Root
Absolute Value
Remainder
#i = SQRT(#J)
#i = ABS (#j)
#i = MOD(#j / #k)
26
27
Combined
#i = (#i * #j) / #k
Multiplication/Division
Combined Square Root 1 #i = SQRT(#j*#j + #k*#k)
28
Combined Square Root 2 #i = SQRT( #j*#j - #k*#k)
31
Sine
#i = #j * SIN(#k)
32
Cosine
#i = #j * COS(#k)
33
Tangent
#i = #j * TAN(#k)
34
80
Arctangent
Unconditional Branch
#i = #j * ARCTAN(#k)
GO TO n
NOTE:
”n” is the block sequence
number targeted by the Pword.
A2100Di Programming Manual
Publication 91204426-001
18
Fanuc Program Example
G65 H01 P#101 Q100
G65 H02 P#101 Q#102
R10.0
G65 H03 P#501 Q15.0
R#105
G65 H04 P#100 Q#504
R10.0
G65 H05 P#500 Q#5021
R3.14
G65 H21 P#506 Q#103
G65 22 P#505 Q#5024
G65 H23 P#101 Q10
R#5002
G65 H26 P#101 Q10
R#5002
G65 H27 P#508 Q#5001
R#5002
G65 H28 P#508 Q#5001
R#5002
G65 H31 P#510 Q#5001
R#5002
G65 H32 P#101 Q#10
R#5021
G65 H33 P#102 Q#5002
R#5004
G65 H34 P#510 Q#5001
G65 H80 P150
Chapter 12
May 2002
Menu
Fanuc G65
Fanuc Function
H-Code
81
Conditional Branch 1
Fanuc Definition
IF #j = #k, GO TO n
82
Conditional Branch 2
IF #j <> #k, GO TO n
83
Conditional Branch 3
IF #j > #k, GO TO n
84
Conditional Branch 4
IF #j < #k, GO TO n
85
Conditional Branch 5
86
Conditional Branch 6
IF #j >= #k,
GO TO n
IF #j <= #k,
GO TO n
Fanuc Program Example
G65 H81 P120 Q#101
R#102
G65 H82 P220 Q#101
R10.0
G65 H83 P310 Q#104
R#101
G65 H84 P110 Q#501
R36.2
G65 H85 P1000 Q#502
R#102
G65 H86 P1200 Q#102
R#106
Fanuc Macro Translation Examples
Fanuc® Custom Macro A
G65 H01 P#101 Q100
G65 H02 P#101 Q#102 R10.0
G65 H21 P#506 Q#103
G65 H31 P#510 Q#5001 R#5002
G65 H83 P310 Q#104 R#101
10
A2100 Translation
[@F_XLT_101] = 100
[@F_XLT_101] = [@F_XLT_102] + 10.0
[@F_XLT_506] = SQR[@F_XLT_103]
[@F_XLT_510] = [$CMDPOS_DSP(0)] *
SIN[$CMDPOS_DSP(1)]
IF [@F_XLT_104] > [@F_XLT_101] GOTO [LBL_N310]
Fanuc Custom Macros not Supported by Machine Control
The following Fanuc® type A macros are not supported by the machine control
translation feature.
Fanuc G65
H-Code
11
11
Fanuc® Function
Fanuc Definition
Example
Logical Sum
#i = #j .OR. #k
12
Logical Product
#i = #j .AND. #k
13
Exclusive OR
#i = #j .XOR. #k
24
Conversion from BCD to Binary
#i = BIN(#j)
G65 H11 P#101 Q#102
R#103
G65 H12 P#101 Q#102
R#103
G65 H13 P#101 Q#102
R#103
G65 H24 P#101 Q#102
25
Conversion from Binary to BCD
#i = BCD(#j)
G65 H25 P#101 Q#102
Acramatic 850SX Translation
The source program TRANSLATION TYPE must be selected as A850SX.
11.1
Acramatic 850SX Set-up.
G-CODE and M-CODE translation tables must be set-up before any translation can be
performed. Entries need only be made when there is no standard translation for the
original code, or when the standard translation is to be replaced. The last entry must
have a ”999” in the numeric field.
A2100Di Programming Manual
Publication 91204426-001
19
Chapter 12
May 2002
Menu
11.2
Acramatic 850SX G-CODE Translation Table
This machine control set-up table allows Acramatic 850SX G-code values to be input
into the ”NUMBER” column. The ”TRANSLATION TEXT” column is a text field of 32
characters to hold the machine control translation of the adjacent G-code value.
Example:
A850
G-Code Number
(Numeric Field)
22
23
999
11.3
A2100
Translation Text
(Text Field)
G1
G1
Acramatic 850SX M-CODE Translation Table
This machine control set-up table allows Acramatic 850SX M-code values to be input
into the ”VALUE” column. The ”TRANSLATION TEXT” column is a text field of 32
characters to hold the machine control translation of the adjacent M-code value.
Example:
A850
M-Code Value
A2100
Translation Text
(Numeric Field)
(Text Field)
2
32
999
12
M30
M30
Performing an Acramatic 850SX Translation
From the machine control Edit Mode press the TRANSLATE button to start the
translation. The translation always starts from the beginning of the program, and the
translated program is stored in the second edit buffer. If the translation is successful, the
translated program may be saved to a new filename by the Editor.
12.1
Translation Errors and Recovery
If an error occurs while performing a translation, the translation will stop at that block,
and a dialog box will display the related error message, and the cursor is positioned to
the word which caused the error. After the dialog box is cleared, a table may be
modified to cover special cases, or the Editor can be used to correct the original
Acramatic 850SX part program. This Acramatic 850SX part program is again translated
until no further errors exist.
13
Degree of Acramatic 850SX Compatibility
This translation feature is designed to translate part programs written for the standard
Acramatic 850SX MC control. If the part program falls outside the following specification
some manual modifications to the program may be needed.
A2100Di Programming Manual
Publication 91204426-001
20
Chapter 12
May 2002
Menu
The following table lists those items which are, and which are not supported by the
translation function on the machine control. The comments column in this list describes
the Acramatic 850SX and machine control operations.
The comment bulleted by an ”a” is the A850SX description for the particular function, the
comment bulleted by an ”m” is the description of the machine control translation for that
function.
A850SX G-Codes Supported in the Machine Control
Function
A850sx A2100 Code
Comments
Code
Linear Interpolation G0
G0
m
Same
Rapid Rate
Linear Interpolation G1
G1
m
Same
Feedrate
a
I, J, and K words are switchable as a
G2.01
G2(abs)
Circular
function of G90/G91 mode.
G2.02
(incr)
CW
G3.01
G3(abs)
m
The G code is selected by the
CCW
G3.02
(incr)
absolute/incremental state of the A850
Interpolation
program.
Programmable
G4
G4
m
Same
Dwell
The block is translated into an equation
Assignment
G10
=
m
using common and system variables.
m
A direct or conditional branch block is
Branching
G11
GOTO
translated into a GOTO or an IF...GOTO
IF.....
statement.
....GOTO
Contouring Rotary G12
G12
m
Same
Axis Unwind
XY Plane Select
G17
G17
m
Same
ZX Plane Select
G18
G18
m
Same
YZ Plane Select
G19
G19
m
Same
Mill - Face - Centre G22
G22
m
Same
Point Position
G23
m
Same
Mill - Rect - Pocket G23
Centre Point
Position
Mill - Rect - Frame G24
G24
m
Same
Inside Centre Point
Position
Mill - Rect - Frame G25
G25
m
Same
Outside Centre
Point Position
Mill - Circular
G26
G26.1
m
Same
Pocket
Mill - Circular
G27
G27
m
Same
Frame - Inside
Mill-Circular Frame G28
G27.1
m
Same
- Outside
Work Co-ordinate
G35 is dropped and P-word is translated
G35 P1
H1
m
System 1
into H-word.
Cancel Pattern
G37
G37
m
Same
A2100Di Programming Manual
Publication 91204426-001
21
Chapter 12
May 2002
Menu
Function
Rectangular Hole
Pattern
Circular Hole
Pattern
Cutter Diameter
Compensation
-Cancel
Cutter Diameter
Compensation
- Cutter LEFT of
part
Cutter Diameter
Compensation
- Cutter RIGHT of
part
Tool Length Offset Positive
Tool Length Offset Negative
Tool Length Offset Cancel
Pallet Co-ordinate
Programming
Positioning Mode
Contouring Mode
Mill - Face - Corner
Position
Mill - Rect Pocket Corner Position
Mill - Rec Frame Inside Corner
Position
Mill - Rect Frame Outside - Corner
Position
Set Tool Length
Check Tool Length
Inch Input
Metric Input
Probe Calibration Set Stylus Offset
and Tip Dimension
Probe Calibration Set Stylus Tip
Dimension
Probe Calibration Set Stylus Length
A850SX G-Codes Supported in the Machine Control
A850sx A2100 Code
Comments
Code
G38
G38
m
Same
G39
G39
m
Same
G40
G40
m
Same
G41
G41
m
Same
G42
G42
m
Same
G43
O-Word
m
G44
O-Word
m
G49
O-Word = 0
a
m
G50
G50
m
The G-Code is discarded, but the O-Word
is used to select the offset.
The G-Code is discarded, but the O-Word
is used to select the offset.
No O-Word is programmed in this block.
The G-Code is discarded, and an O-Word
equal to zero is inserted to cancel Tool
Length Offset.
Same
G60
G61
G62
G60
G61
G22.1
m
m
m
Same
Same
Same
G63
G23.1
m
Same
G64
G24.1
m
Same
G65
G25.1
m
Same
G68
G69
G70
G71
G72
G68
G69
G70
G71
G72
m
m
m
m
m
Same
Same
Same
Same
Same
G73
G73
m
Same
G74
G74
m
Same
A2100Di Programming Manual
Publication 91204426-001
22
Chapter 12
May 2002
Menu
Function
Surface
Measurement Locate Internal
Corner
Surface
Measurement Locate External
Corner
Surface
Measurement Locate Surface
Surface
Measurement Locate and
Measure Bore or
Boss
Surface
Measurement Measure Pocket or
Web
Fixed Cycle Cancel
Drill Cycle
A850SX G-Codes Supported in the Machine Control
A850sx A2100 Code
Comments
Code
G75
G75
m
Same
G76
G76
m
Same
G77
G77
m
Same
G78
G78
m
Same
G79
G79
m
Same
G80
G81
G80
G81
m
a
Same
The Z-Word is the INCREMENTAL Hole
Depth referenced to the R plane.
The programmable
CYCLE_PARAMETER-S.HOLE_DEPTH
is set to a value of 1 to select
INCREMENTAL Hole Depth for all fixed
cycles
See G81 comments.
m
Counterbore/ Spot
Drill with Dwell
Cycle
Deep Hole Drill
Cycle
G82
G82
G83
G83
Tap Cycle
G84
G85
G86
G85
G86
See G81 comments.
J-Word = 0 or no J-Word (chip breaking).
J-Word set to 1.
J-Word = 1.
J-Word set to 3.
See G81 comments.
J-Word = 0 or no J-Word.
Floating tap.
J-Word = 1 through 9
Rigid tap.
See G81 comments.
See G81 comments.
G87
G88
G87
G88
See G81 comments.
See G81 comments.
G89
G89
See G81 comments.
G90
G90
a
m
a
m
G84
a
m
a
m
G84.1
Bore Cycle
Bore Cycle, Dead
Spindle Retract
Back Bore Cycle
Web Drill/Bore
Cycle
Bore/Ream with
Dwell Cycle
Absolute Dimension
Input
A2100Di Programming Manual
Publication 91204426-001
m
23
Same.
Chapter 12
May 2002
Menu
Function
Incremental
Dimension Input
Position Set
Inverse Time
Feedrate Mode
A850SX G-Codes Supported in the Machine Control
A850sx A2100 Code
Comments
Code
G91
G91
m
Same.
G92
G93
G92
G93
m
Feed Per Minute
Mode
Feed Per Spindle
Revolution
Machine Coordinate
Programming
G94
G94
m
Same.
Same for linear spans.
For a circular span, the A850SX F-word
contains the inverse time to traverse the
arc length.
For a circular span, the machine control Fword contains the inverse time to traverse
one radian of the arc.
Same
G95
G95
m
Same for fixed tool.
G98
G98.1
a
m
Position Set and
Zero Shift - Cancel
Program Stop
Optional Stop
End of Program
Spindle CW
Spindle CCW
Spindle and
Coolant OFF
Tool Change
Coolant #2 ON
Coolant #1 ON
Coolant OFF
Clamp
Unclamp
Spindle CW and
Coolant #1 ON
Spindle CCW and
Coolant #1 ON
Spindle CW and
Coolant #2 ON
Spindle CCW and
Coolant #2 ON
Spindle CW and
Coolant #3 ON
Spindle CCW and
Coolant #3 ON
G99
G99
m
The machine slides are directed to the
programmed points.
The machine control G98 moves the tool
point to the programmed points, while
G98.1 moves the machine slides to that
position.
Same
M0
M1
M2
M3
M4
M5
M0
M1
M2
M3
M4
M5
m
m
m
m
m
m
Same
Same
A850 and A2100 Different
Same
Same
Same
M6
M7
M8
M9
M10
M11
M13
M6
M7
M8
M9
M10
M11
M13
m
m
m
m
m
m
m
Same
Same
Same
Same
Same
Same
Same
M14
M14
m
Same
M17
M3M7
m
Translated into two M-codes
M18
M4M7
m
Translated into two M-codes
M24
M3M27
m
Translated into two M-codes
M25
M4M27
m
Translated into two M-codes
a
m
A2100Di Programming Manual
Publication 91204426-001
24
Chapter 12
May 2002
Menu
Function
Spindle Axis Full
Retract
Coolant #3 ON
End of Segment
A850SX G-Codes Supported in the Machine Control
A850sx A2100 Code
Comments
Code
M26
M26
m
Same
M29
M30
M27
(CHN,n)
m
m
End of Last
Segment
M32
M30
a
m
Spindle Milling
Range
Spindle Tapping
Range
Disable Probe
Protection
Enable Probe
Protection
M41
M41
m
Translated into a different M-code
The M code is changed to a CHN chaining
type II block with an ID number (n) one
greater than the current program ID is
obtained from the program directory.
Note: Prior to translation, the A850
program segments located in the A2100
program directory must have sequential ID
numbers. After translation, these ID
numbers need to be removed from the
A850 program segments and assigned to
the appropriate A2100 translated
segments.
The current program segment is ended
and the first program segment is loaded.
The current program segment is ended
and a message is posted for the operator
to restart the first program segment.
Same
M42
M42
m
Same
M74
M59
m
Same
M75
M58
m
Same
A850SX M-Codes Not Supported in the Machine Control
Function
A850SX Code
Comments
Quill Clamp
M50
*
Quill Unclamp
M51
*
* User should define operation in M-CODE translation table.
A850SX Type II Blocks Supported in the Machine Control
Function
A850SX A2100 Code
Comments
Code
Automatic Tool
ATR
ATR
m The target address is translated to an A2100
Recovery
label.
Call Sub-routine
CLS
CLS
m The sub-routine program name is configured
by appending the A850SX L - word value
number to the characters ”SUB-”
Define Sub-routine DFS
DFS
m The sub-routine program name is configured
by appending the A850SX L - word value
number to the characters ”SUB-”. A new
registered program is generated for each
sub-routine.
End Subroutine
ENS
ENS
m Same
Invert Axis
INV
INV
m Same
A2100Di Programming Manual
Publication 91204426-001
25
Chapter 12
May 2002
Menu
A850SX Type II Blocks Supported in the Machine Control
Operator Message MSG
MSG
m Same
Rotate Co-ordinate ROT
ROT
m Same
System
Set Low Limits
SLO
SLO
m Same
Set High Limits
SHI
SHI
m Same
A850SX Type II Blocks Not Supported in the Machine Control
Function
A850sx
Comments
Code
Rotary Axis Error Compensation Table
ACB
*
Adaptive Control Parameter
ACP
Not available in A2100
X Axis Error Compensation Table
ACX
*
Y Axis Error Compensation Table
ACY
*
Z Axis Error Compensation Table
ACZ
*
Fixture Offset Table
FOF
*
Framing Milling Cycle
FRA
Not available in A2100
Interference Zone Table
INF
*
Machine Alert Definition
MAL
*
Machine Alert Description
MAD
*
MTB Commissioning Data
MCD
*
Pallet Offset Table
MCS
*
Material Table (SFP)
MTL
*
Pocket Offset Table
POC
Not available in A2100
Programmable Offset Table
POF
*
System Commissioning Data
SCD
*
Tool Data Table
TDA
*
Tool Location Table
TLD
*
Tool Offset Table (Tool Wear)
TWR
*
* No provision exists for A2100 tables to be loaded from Type II blocks.
A850SX G10 Table Assignments Supported by the Machine Control
A850SX
Function
A850SX Value A2100 Table/Field
Assignment
Table/Field
FOF
Fixture Offset
$FIXTURE
Same
XX Offset
X
YY Offset
Y
ZZ Offset
Z
Rotary
ROTARY_POS
Reference
MCS
Pallet Offset
$PALLET
Same
XX Offset
X
YY Offset
Y
ZZ Offset
Z
Rotary Offset
ROTARY_POS
Program ID
PALLET_ID
POF
Programmable
$PROG_OFFSET Same
Offset
A2100Di Programming Manual
Publication 91204426-001
26
Chapter 12
May 2002
Menu
A850SX G10 Table Assignments Supported by the Machine Control
A850SX
Function
A850SX Value A2100 Table/Field
Assignment
Table/Field
XX Offset
X
YY Offset
Y
ZZ Offset
Z
TDA
$TOOL_DATA
A Tool Tip Angle
TIP_ANGLE
Same
D Tool Diameter
NOM_DIA
Same
E Number of
TEETH
Same
Teeth
A850SX G10 Table Assignments Supported by the Machine Control
A850SX
Function
A850SX Value A2100 Table/Field
Assignment
Table/Field
L Tool Length
LENGTH
Same
S Tool Load
0 = None
LOAD_METHOD
N/A
Status
1=Auto
0=Auto
2=Manual
1=Manual
3=Migrating
MIGRATING
1=Migrating
4=Oversize
SIZE
4=Prev_1_Next_1
5=MigratingMIGRATING
1=Migrating
Oversize
SIZE
4=Prev_1_Next_1
Y Tool Type
0=None
TYPE
0=Unknown
1=Plunge Mill
0=Unknown
2=Edge Mill
0=Unknown
3=Face Mill
4=Face Mill
4=End Mill
2=Finish End Mill
5=Drill
10=Drill
6=Center Drill
11=Spot Drill
7=Counter Sink
12=Counter Sink
8=Reamer
13=Reamer
9=Tap
14=Tap
10=Boring Bar
16=Bore
11=Slot Bore
0=Unknown
12=Cntr Bore
0=Unknown
13=Back Bore
17=Back Bore
14=Probe
18=Probe
TD2
Tool Data 2
$TOOL_DATA
F Feedrate
MAX_FEED
Same
L Flute Length
FLUTE_LENGTH
Same
M Tool Material
N/A
P Pilot Diameter
N/A
S Spindle
0=CW
SPDL_DIR
1=DIR_CW
Direction
1=CCW
2=DIR_CCW
2=Both
3=DIR_EITHER
A2100Di Programming Manual
Publication 91204426-001
27
Chapter 12
May 2002
Menu
A850SX G10 Table Assignments Supported by the Machine Control
A850SX
Function
A850SX Value A2100 Table/Field
Assignment
Table/Field
3=Stop
0=DIR_STOP
T Threads per
TPI
Same
Inch
TLD
Tool Location
$TOOL_DATA
T Tool Identifier
IDENTIFIER
Same
TWR
Tool Offset
$TOOL_DATA
X X Probe X
X_PRB_OFFSET
Same
Offset
Y Probe Y Offset
Y_PRB_OFFSET
Same
P Alternative
Not accessible
Tool
S Cut Speed
SPEED_OVR
Same
Override
T Cycle Time
0=TWR_OFF
CYC_TM_MODE
0=Time Inactive
Monitor
1=TWR_ON
1=Time Active
A Accum Cycle
CYCLE_TIME
Same
Timer
C Chip/Tooth
FDRT_OVR
Same
Override
L Cycle Time
CYC_TIME_LIM
Limit
W Tool Worn
0=TWR_NO
TOOL_STATUS
0=Good
Switch
1=TWR_YES
2=Worn
A850SX M-Registers Supported in the Machine Control
A850SX
A850SX
A2100
Machine State
Register
System Variable
ACTIVE_TOOL_DIAMETER
M42
$TOOL_DATA(0)NOM_DIA
ACTIVE_TOOL_LENGTH
M43
$TOOL_DATA(0)LENGTH
ACTIVE_TOOL_TYPE
M41
$TOOL_DATA(0)TYPE
ROT_COMMAND_POS_CMC
M8
$CURPOS_MCH(A, B or C)
X_COMMAND_POS_CMC
M5
$CURPOS_MCH(X)
Y_COMMAND_POS_CMC
M6
$CURPOS_MCH(Y)
Z_COMMAND_POS_CMC
M7
$CURPOS_MCH(Z)
ROT_PROBE_CONTACT_POS
M20
$PROBE_POS_PC(A, B or C)
X_PROBE_CONTACT_POS
M17
$PROBE_POS_PC(X)
Y_PROBE_CONTACT_POS
M18
$PROBE_POS_PC(Y)
Z_PROBE_CONTACT_POS
M19
$PROBE_POS_PC(Z)
G
A850SX temporary register variables supported in the machine control.
G
A850SX t-register variables are translated into A2100 (@) common variables.
G
A850SX subroutine parameter variables supported in the machine control.
A2100Di Programming Manual
Publication 91204426-001
28
Chapter 12
May 2002
Menu
The following sub-routine parameter variables exist in an internal translation table:
A850sx
Parameter
P1
P2
P3
P4
P5
P6
P7
P8
P9
P10
P11
P12
P13
A2100
Variable
&G *
&X
&Y
&Z
&A, B, or C
&I
&J
&K
&F
&S
&T
&M *
&R
* While the &G and &M parameters may be used to pass data to other sub-routine words, the
A2100 control does not allow variable assignments to G or M words.
A850SX Commissioning Data Items Supported in the Machine Control
A850sx
Commissioning Data
X_AXIS_LOW_LIMIT
X_AXIS_HIGH_LIMIT
Y_AXIS_LOW_LIMIT
Y_AXIS_HIGH_LIMIT
Z_AXIS_LOW_LIMIT
Z_AXIS_HIGH_LIMIT
ROT_AXIS_LOW_LIMIT
ROT_AXIS_HIGH_LIMIT
A850sx
Item
C20
C21
C35
C36
C50
C51
C65
C66
A2100
System Variable
$LOW_LIMIT(X)
$HIGH_LIMIT(X)
$LOW_LIMIT(Y)
$HIGH_LIMIT(Y)
$LOW_LIMIT(Z)
$HIGH_LIMIT(Z)
$LOW_LIMIT(A, B, or C)
$HIGH_LIMIT(A, B, or C)
Acramatic 950 MC Translation
The source program TRANSLATION TYPE must be selected as A950.
14
Acramatic 950 Set-up
G-CODE and M-CODE translation tables must be set-up before any translation can be
performed. Entries need only be made when there is no standard translation for the
original code, or when the standard translation is to be replaced. The last entry must
have a ”999” in the numeric field.
1
A950 MC Parameters Translation Table
A950 Commissioning Data
Translation Parameters
Item Number
Inch/mm Input State
3
0 = mm
1 = Inch
A2100Di Programming Manual
Publication 91204426-001
29
Chapter 12
May 2002
Menu
2
3
4
5
6
15
A950 MC Parameters Translation Table
A950 Commissioning Data
Translation Parameters
Item Number
Interpolation State
4
0 = G00 (rapid traverse)
1 = G01
Feedrate State
5
94 = G94 (FPM)
93 = G93 (1/T)
95 = G95 (FPT)
Contouring/Positioning State
6
60 = G60 (positioning)
61 = G61 (contouring)
Plane Select State
7
17 = G17 (XY)
18 = G18 (ZX)
19 = G19 (YZ)
Pallet Offsets Action (PAL)
33
0 = Do not rotate with B axis
1 = Rotate with B axis motion
Acramatic 950 G-CODE Translation Table
The A950 translator has an internal standard G code table; only non-standard G codes
should be entered in this translation table if a comparable A2100 code exists. The
A2100 set-up table allows A950 G-code values to be input into the “NUMBER” column.
The ”TRANSLATION TEXT” column is a text field of 32 characters to hold the A2100
translation of the adjacent G code value.
Example:
A950
G-Code Number
(Numeric Field)
22
23
999
16
A2100
Translation Text
(Text Field)
G1
G1
Acramatic 950 M-CODE Translation Table
The A950 translator has an internal standard G code table; only non-standard M-codes
should be entered in this translation table if a comparable A2100 code exists. This
A2100 set-up table allows A950 M-code values to be input into the “VALUE” column.
The ”TRANSLATION TEXT” column is a text field of 32 characters to hold the A2100
translation of the adjacent M-code value.
Example:
A950
M-Code Value
(Numeric Field)
2
A2100Di Programming Manual
Publication 91204426-001
A2100
Translation Text
(Text Field)
M30
30
Chapter 12
May 2002
Menu
40
*
999
* The machine application group will supply the information for M-Codes 40 through 47
and M-Codes 50 through 199.
16.1
Acramatic 950 Machine Register Table
The purpose of this A2100 table is to match A950 Machine State registers with the
appropriate A2100 system variables. Table entries should only be made for register
items not included in the internal table listed in a later section of this Manual.
Example:
A950
A2100
Machine Register Number
Translation Text
(Numeric Field)
(Text Field)
212
*
245
*
999
* The machine application group will supply the information for Machine State Registers
200 through 254.
16.2
Acramatic 950 Cycle Parameter Table
The purpose of this A2100 table is to match A950 Cycle Parameters with the appropriate
A2100 system variables. Table entries should only be made for parameter items not
included in the internal table listed in a later section of this Manual.
Example:
A950
A2100
Cycle Parameter Number
Translation Text
(Numeric Field)
(Text Field)
22
TRAM_SURFACE *
28
PRB_APPR_FRT *
999
* Invalid assignment, only used for an example.
17
Performing an Acramatic 950 Translation
From the A2100 Edit Mode press the TRANSLATE button to start the translation. The
translation always starts from the beginning of the program, and the translated program
is stored in the second edit buffer. If the translation is successful, the translated program
may be saved to a new filename by the Editor.
18
Degree of Acramatic 950 Compatibility
This translation feature is designed to translate part programs written for the standard
Acramatic 950 MC control. If the part program falls outside the following specification,
some manual modifications to the program may be needed.
A2100Di Programming Manual
Publication 91204426-001
31
Chapter 12
May 2002
Menu
The following table lists those items that are and are not supported by the translation
function on the Cincinnati Milacron A2100 control. The ”Comments” column in this list
describes the Acramatic 950 and A2100 operations.
G
The comment bulleted by an ”a” is the A950 description for the particular function.
G
The comment bulleted by an ”m” is the description of the machine control translation
for that function.
A950 G-Codes Supported in the Machine Control
A950
A2100
Comments
Code
Code
Linear Interpolation - Rapid G0
G0
m Same
Rate
Linear Interpolation G1
G1
m Same
Feedrate
Circular
CW
G2 (abs) G2.01
I, J, and K words are switchable as a
a
G2.02
(incr)
m function of G90/G91 mode.
The G code is selected by the
CCW
G3 (abs) G3.01
G3.02
absolute/incremental state of the A950
Interpolation
(incr)
program
Function
Programmable Dwell
Assignment
G4
G10
G4
=
m
m
Branching
G11
m
Contouring Rotary Axis
Unwind
XY Plane Select
ZX Plane Select
YZ Plane Select
Cutter Load Compensation
-OFF
Cutter Load Compensation
- LEFT
G12
GOTO
IF.....
GOTO
G12
m
Same
The block is translated into an equation
using common and system variables.
A direct or conditional branch block is
translated into a GOTO or an IF.GOTO
statement.
Same
G17
G18
G19
G20
G17
G18
G19
G61
m
m
m
m
Same
Same
Same
Same
G21
G61.1
m
Cutter Load Compensation G22
- RIGHT
Cutter Load Compensation G23
- PARAMETERS
G61.2
m
Same, except the K - word value is
changed to 180 degrees minus the K word value.
Same
G61.3
m
Same
Cutter Load Compensation G40
- CANCEL
G40
m
Same
Cutter Load Compensation G41
- Cutter LEFT of part
G41
m
Same
Cutter Load Compensation G42
- Cutter RIGHT of part
G42
m
Same
Cutter Load Compensation G43
- POR - ON
G43
m
Same
Acceleration/Deceleration - G45
ENABLED
G45
m
Same
A2100Di Programming Manual
Publication 91204426-001
32
Chapter 12
May 2002
Menu
A950 G-Codes Supported in the Machine Control
A950
A2100
Function
Comments
Code
Code
Acceleration/Deceleration - G46
G46
m Same
DISABLED
Short Look Ahead
G47
m This mode is not required in A2100 and
will be ignored.
Long Look Ahead
G48
m This mode is not required in A2100 and
will be ignored.
Pallet Co-ordinate
G50
G50
m Same
Programming
Positioning Mode
G60
G60
m Same
Contouring Mode
G61
G61
m Same
Inch Input
G70
G70
m Same
Metric Input
G71
G71
m Same
Fixed Cycle - Cancel
G80
G80
m Same
Drill Cycle
G81
G81
a
The Z-Word is the INCREMENTAL Hole
m Depth referenced to the R plane.
The programmable
CYCLE_PARAMETERS.HOLE_DEPTH is set to a value of 1 to
select INCREMENTAL Hole Depth for
all fixed cycles
Counterbore/Spot Drill with G82
G82
See G81 comments.
Dwell Cycle
See G81 comments.
Deep Hole Drill Cycle
G83
G83
J-Word = 0 or no J-Word (chip
a
m breaking).
J-Word set to 1.
a
m J-Word = 1 (chip clearance).
J-Word set to 3.
Tap Cycle
G84
G84
See G81 comments.
a
K-Word = 0 or no K-Word.
G84.1
m Floating tap.
a
K-Word >0
m Rigid tap.
Bore/Ream Cycle
G85
G85
See G81 comments.
Bore Cycle, Dead Spindle G86
G86
See G81 comments.
Retract
Back Bore Cycle
G87
G87
See G81 comments.
Web Drill/Bore Cycle
G88
G88
See G81 comments.
Bore/Ream with Dwell
G89
G89
See G81 comments.
Cycle
Absolute Dimension Input G90
G90
m Same
Incremental Dimension
Input
Position Set
A2100Di Programming Manual
Publication 91204426-001
G91
G91
m
Same
G92
G92
m
Same
33
Chapter 12
May 2002
Menu
A950 G-Codes Supported in the Machine Control
A950
A2100
Comments
Code
Code
Inverse Time Feedrate
G93
G93
a
The F - word is modal in A950.
For a circular span, the A950 F-word
Mode
contains the inverse time to traverse the
m arc length.
Since the F - word is not modal in
A2100, an F - word will be added for
every block that it is absent.
For a circular span, the A2100 F-word
contains the inverse time to traverse
one radian of the arc.
Feed Per Minute Mode
G94
G94
m Same.
Function
Feed Per Tooth Mode
Constant Surface Speed
G95
G96
G95
G96
m
m
Same.
Same.
Spindle Speed in RPM
Machine Co-ordinate
Programming
G97
G98
G97
G98.1
m
a
Same.
The machine slides are directed to the
programmed points. Machine control
G98 moves the tool point to the
programmed points, while G98.1 moves
the machine slides to that position.
Same.
m
Position Set and Zero Shift G99
- Cancel
Stop Look Ahead
G199
G99
m
-
m
This mode is not required in A2100 and
will be ignored.
A950 G-Codes Not Supported in the Machine Control
Function
A950 Code
Comments
Establish 3D Circle Tilt
G16
Available in future release.
G23
Tilted
Circular/Helical
G32
Available
in
future
CW
G2.11
G2.12
CCW
(incr)
G3.11
G33
G3.12
Interpolation
(abs)
(incr)
Velocitech Plus ON
G34
Velocitech Plus OFF
G35
release.
A950 M-Codes Supported in the Machine Control
A950
A2100
Comments
Code
Code
Program Stop
M0
M0
m Same.
Optional Stop
M1
M1
m Same.
End of Program
M2
M2
m A850 and A2100 Different.
Spindle CW
M3
M3
m Same.
Spindle CCW
M4
M4
m Same.
Spindle and Coolant OFF
M5
M5
m Same.
Function
A2100Di Programming Manual
Publication 91204426-001
34
Chapter 12
May 2002
Menu
A950 M-Codes Supported in the Machine Control
A950
A2100
Function
Comments
Code
Code
Tool Change
M6
M6
m Same.
Coolant #2 ON
M7
M7
m Same.
Coolant #1 ON
M8
M8
m Same.
Coolant OFF
M9
M9
m Same.
Clamp
M10
M10.1
m Same.
Unclamp
M11
M11.1
m Same.
Spindle CW and Coolant #1
M13
M13
m Same.
ON
Spindle CCW and Coolant #1 M14
M14
m Same.
ON
Spindle CW and Coolant #2
M17
M3M7
m Translated into two M-codes.
ON
Spindle CCW and Coolant #2 M18
M4M7
m Translated into two M-codes.
ON
Orient Spindle Stop
M19
M19
m Same.
Spindle CW and Coolant #3
M20
M3 M27 m Translated into two M codes.
ON
Spindle CCW and Coolant #3 M21
M4 M27 m Translated into two M codes.
ON
Spindle CW and Coolant #4
M22
M3 M28 m Translated into two M codes.
ON
Spindle CCW and Coolant #4 M23
M4 M28 m Translated into two M codes.
ON
Spindle CW and Coolant #5
M24
M3 M29 m Translated into two M codes.
ON
Spindle CCW and Coolant #5 M25
M4 M29 m Translated into two M codes.
ON
Spindle Axis Full Retract
M26
M26
m Same.
Coolant #3 ON
M27
M27
m Same.
Coolant #4 ON
M28
M28
m Same.
Coolant #5 ON
M29
M29
m Same.
End of Segment
M30
(CHN,n) m The M code is changed to a CHN
chaining type II block with an ID
number (n) one greater than the
current program ID obtained from the
program directory.
Note: Prior to translation, the A950
program segments located in the
A2100 program directory must have
sequential ID numbers. After
translation, these ID numbers must be
removed from the A950 program
segments and assigned to the
appropriate A2100 translated
segments.
A2100Di Programming Manual
Publication 91204426-001
35
Chapter 12
May 2002
Menu
A950 M-Codes Supported in the Machine Control
A950
A2100
Comments
Code
Code
End of Last Segment
M32
M30
a
The current program segment is ended
m and the first program segment is
loaded.
The current program segment is ended
and a message is posted for the
operator to restart the first program
segment.
Enable Data Collection
M34
M34
m Same.
Disable Data Collection
M35
M35
m Same.
Spindle RPM Mode
M36
G97
m Same.
Spindle Surface Speed Mode M37
G97.1
m Same.
Feedrate Override Enable
M48
M48
m Feedrate and spindle speed override
enable.
Feedrate Override Disable
M49
M49
m Feedrate and spindle speed override
disable.
Function
A950 M-Codes Not Supported in the Machine Control
Function
A950 Code
Comments
Rapid Vector Mode ON
M38
*
Rapid Vector Mode OFF
M39
*
Defined by Machine Application Group
M40 - 47
*
Defined by Machine Application Group
M50 - 199
*
* User should define operation in M-CODE translation table.
Function
Automatic Tool
Recovery
Call Sub-routine
A950 Type II Blocks Supported in the Machine Control
A950 Code A2100
Comments
Code
The target address is translated to an A2100
ATR
ATR
m
label.
CLS
CLS
m
The sub-routine program name is copied
directly from the = word, when present;
otherwise the Program ID is used.
DAI
DAI
m
Same.
Data Acquisition
Initialisation
Data Acquisition Save DAS
Define Sub-routine
DFS
DAS
DFS
m
m
Draw Graphic
End Subroutine
Path Name
Invert Axis
Event Log
Operator Message
DWG
ENS
FIL
INV
JRN
MSG
m
m
m
m
m
m
A2100Di Programming Manual
Publication 91204426-001
DWG
ENS
FIL
INV
LOG
MSG
36
Same.
The sub-routine program name is configured
by appending the A950 L-word program ID
or the (=) program name to the characters
”SUB-”
Same.
Same.
Same.
Same.
Same.
Same.
Chapter 12
May 2002
Menu
Page Format
PAG
PAG
m
Program Identification PGM
PGM
m
Print Block
PRT
PRT
m
Rotate Co-ordinate
System
Set Low Limits
Set High Limits
ROT
ROT
m
The A2100 lacks the “Lines per form”
parameter, which the A950 has, this will be
interpreted as “Line per page”.
The “Name”, “ID”, “Count”, and “Status”
fields will be translated, any other ones will
be ignored.
Only the message, the top of form, the
linefeed, the write-to-file and the close
printer parameters will be translated, any
other ones will be ignored.
Same.
SLO
SHI
SLO
SHI
m
m
Same.
Same.
A950 Type II Blocks Not Supported in the Machine Control
Function
A950
Comments
Code
Adaptive Control Parameter
ACP
Not available in A2100.
MAI Alert Definition - Set 2 Table
ADF
*
MAI Alert Definition - Set 2 Table
ADS
*
Axis Gain Parameter Table
AGP
*
Axis Configuration Data Table
AXC
*
Axis Definition Data Table
AXD
*
Axis Select Data Table
AXS
*
Axis Error Compensation Table
Cnn
*
Cycle Parameters Table
CYP
*
Drive Configuration Data DC Table
DCD *
Drive Configuration Data PWM Table
DCP
*
Drive Gain Parameters Table
DGP *
Function Lock Table
FLK
*
Fixture Offset Table
FOF
*
Logical Axis Table
LAX
*
Machine Alert Definition - Set 1 Table
MAL
*
Machine Alert Description - Set 1 Table
MAD *
MTB Commissioning Data
MCD *
Multiple Co-ordinate Systems Table
MCS *
MAI Display Format Table
MDF *
Machine Interface Data
MID
*
Machine Application Interface Option Descriptor Table
MOD *
Machine Offsets Table
MOF *
Pocket Offset Table
PAL
*
Process Control Data Table
PCD
*
Machine Panel Definition Table
PDF
*
Programmable Offset Table
POF
*
Set Program Privileges Table
PRV
*
System Commissioning Data
SCD
*
Serial Device Parameters Table
SDP
*
Stop Look Ahead Table
SLK
*
A2100Di Programming Manual
Publication 91204426-001
37
Chapter 12
May 2002
Menu
A950 Type II Blocks Not Supported in the Machine Control
Function
A950
Comments
Code
Tool Data Table
TDA
*
Tool Location Table
TLD
*
Timer Block
TMR Not available in A2100
Tool Wear Table
TWR *
*No provision exists for A2100 tables to be loaded from Type II blocks.
A950 Table Assignments Supported by the Machine Control
A950
Function
A950 Value
A2100 Table/Field
Assignment
Table/Field
CYP
Cycle Parameters
$CYCLE_PARAMS
I
Record Number
N/A
V
Record Number
15
X_POS_TIP
16
X_NEG_TIP
17
Y_POS_TIP
18
Y_NEG_TIP
31
G82_FIN_DPTH
32
G82_FIN_DPTH
33
G83_RELIEF
34
G83_RELIEF
35
G86_BOT_RET
36
G86_BOT_RET
37
G87_BOT_RET
38
G87_BOT_RET
39
GAGE_HT_INCH
40
GAGE_HT_MM
41
G82_FEED_FAC
42
G82_DWELL
43
G87_DWELL
44
G89_DWELL
=
Description
N/A
FOF
Fixture Offsets
$FIXTURE
I
Offset Number
N/A
L
Pallet Number
N/A
Co-ordinate Sys
R
N/A
Number
B
B Position
ROTARY_POS
X
X Offset
X
Y
Y Offset
Y
Z
Z Offset
Z
Multiple Co-ordinate
MCS
$SETUP
Systems
I
Record Number
N/A
L
Pallet Number
N/A
G
A950MC Compatibility
N/A
P
Program ID
NC_PROG_ID
A2100Di Programming Manual
Publication 91204426-001
38
Chapter 12
May 2002
Menu
A950 Table Assignments Supported by the Machine Control
Function
A950 Value
A2100 Table/Field
Assignment
A950
Table/Field
S
Part Status
A
B
C
U
V
W
X
Y
Z
MOF
I
U
V
W
X
Y
Z
PAL
I
A
B
C
D
O
S
A Offset
B Offset
C Offset
U Offset
V Offset
W Offset
X Offset
Y Offset
Z Offset
Machine Offsets
Offset Number
U Offset
V Offset
W Offset
X Offset
Y Offset
Z Offset
Pallet Offsets
Pallet Number
A Offset
B Position
C Offset
Pallet Identifier
Pallet Order
Pallet Status
X
Y
Z
PCD
I
A
B
C
D
X Offset
Y Offset
Z Offset
Process Control Data
Record Number
Data 1
Data 2
Linear 1 axis
Linear 2 axis
A2100Di Programming Manual
Publication 91204426-001
0=Absent
1=Present
2=Last
3=Complete
4=New
5=Aborted
0=Absent
1=Present
2=Last
3=Complete
4=New
5=Aborted
39
SETUP_STATE
SETUP_STATE
SETUP_STATE
PART_STATUS
SETUP_STATE
PART_STATUS
A
B
C
U
V
W
X
Y
Z
$MACH_OFFSET
N/A
U
V
W
X
Y
Z
$PALLET
N/A
A
ROTARY_POS
C
PALLET_ID
ORDER
STATE
STATE
STATE
STATUS
STATE
STATUS
X
Y
Z
$PROCESS_DATA
N/A
I
N/A
X
Y
0=Absent
1=Present
2=Last
3=Complete
3=New
2=Aborted
0=Absent
1=Active
2=Last
3=Completed
3=New
2=Aborted
Chapter 12
May 2002
Menu
A950
Table/Field
E
F
G
H
J
K
POF
I
L
R
U
V
W
X
Y
Z
TDA
I
A
B
C
D
E
L
S
T
Y
A950 Table Assignments Supported by the Machine Control
Function
A950 Value
A2100 Table/Field
Assignment
Linear 3 axis
Linear 4 axis
Linear 5 axis
Linear 6 axis
Rotary 1 axis
Rotary 2 axis
Programmable Offsets
Offset Number
Pallet
Co-ordinate System
Number
U Offset
V Offset
W Offset
X Offset
Y Offset
Z Offset
Tool Data
Record Number
Tool Angle
Nominal Diameter
Plot Colour
Diameter Deviation
Number of Teeth
Tool Length
Tool Load Status
Torque Limit
Tool Type
A2100Di Programming Manual
Publication 91204426-001
Z
A
B
C
J
K
$PROG_OFFSET
N/A
N/A
N/A
0 = None
1=Auto
2=Manual
3=New Auto
4=New Manual
0=None
1=Plunge Mill
2=Edge Mill
3=Face Mill
4=End Mill
5=Drill
6=Center Drill
7=Counter
Sink
8=Reamer
9=Tap
10=Boring Bar
11=Slot Bore
12=Cntr Bore
40
U
V
W
X
Y
Z
$TOOL_DATA
N/A
TIP_ANGLE
NOM_DIA
N/A
DIA_OFFSET
TEETH
LENGTH
LOAD_METHOD
N/A
TYPE
N/A
0=Auto
1=Manual
N/A
N/A
0=Unknown
0=Unknown
0=Unknown
4=Face Mill
2=Finish End Mill
10=Drill
11=Spot Drill
12=Counter Sink
13=Reamer
14=Tap
16=Bore
0=Unknown
0=Unknown
Chapter 12
May 2002
Menu
A950
Table/Field
A950 Table Assignments Supported by the Machine Control
Function
A950 Value
A2100 Table/Field
Assignment
13=Back Bore
14=Probe
15=Spot Drill
16=Thread Mill
17=Special 1
18=Special 2
19=Special 3
20=Special 4
21=Special 5
22=Special 6
23=Special 7
24=Special 8
25=Special 9
26=Solid Tap
=
TLD
I
D
Serial Number
Tool Location
Tool Number
Spindle Direction
M
Migrating Tool
P
S
Pocket Number
Tool Size
T
TWR
(MC)TWR
I
A
C
L
P
S
T
Tool Identifier
Tool Wear
Tool Number
Cycle Time Accum
Feedrate Override
Cycle Time Limit
Alternative Record
Spindle Override
Cycle Time Monitor
W
Tool Worn
X
Y
X Probe Offset
Y Probe Offset
A2100Di Programming Manual
Publication 91204426-001
0=Stop
1=CW
2=CCW
3=BOTH
0=No
1=Yes
0=Normal
1=Oversize
SERIAL_NO
$TOOL_DATA
N/A
SPDL_DIR
MIGRATING
POCKET
SIZE
17=Back Bore
18=Probe
11=Spot Drill
9=Thread Mill
19=Special_1
20=Special_2
21=Special_3
22=Special_4
23=Special_5
24=Special_6
25=Special_7
26=Special_8
27=Special_9
15=Rigid Tap
Not accessible
0=DIR_STOP
1=DIR_CW
2=DIR_CCW
3=DIR_EITHER
0=INACTIVE
1=ACTIVE
0=Prev_0_Next_0
4=Prev_1_Next_1
IDENTIFIER
$TOOL_DATA
0=Off
1=On
0=No
1=Yes
N/A
CYCLE_TIME
FDRT_OVR
CYC_TIME_LIM
ALT_TOOL
SPEED_OVR
CYC_TM_MODE
TOOL_STATUS
Not accessible
0=Time Inactive
1=Time Active
0=Good
2=Worn
X_PRB_OFFSET
Y_PRB_OFFSET
41
Chapter 12
May 2002
Menu
19
A950 Machine State Registers Supported in the Machine Control
Machine state registers not found in the following internal table may be entered in the
MACHINE REGISTERS translation table when there is an equivalent A2100 system
variable.
A950
Register
M1
M2
M3
M4
M5
M6
M7
M8
M9
M31
M32
M33
M34
M35
M36
M37
M38
M39
M76
M77
M78
M79
M80
M81
M82
M83
M84
M155
M156
M157
M158
M159
M160
A950
Machine State
X Command Position in AMC
Y Command Position in AMC
Z Command Position in AMC
U Command Position in AMC
V Command Position in AMC
W Command Position in AMC
A Command Position in AMC
B Command Position in AMC
C Command Position in AMC
X Current Position AMC in Program Coordinates
Y Current Position AMC in Program Coordinates
Z Current Position AMC in Program Coordinates
U Current Position AMC in Program Coordinates
V Current Position AMC in Program Coordinates
W Current Position AMC in Program Coordinates
A Current Position AMC in Program Coordinates
B Current Position AMC in Program Coordinates
C Current Position AMC in Program Coordinates
X Probe Hit Machine Position in AMC
Y Probe Hit Machine Position in AMC
Z Probe Hit Machine Position in AMC
U Probe Hit Machine Position in AMC
V Probe Hit Machine Position in AMC
W Probe Hit Machine Position in AMC
A Probe Hit Machine Position in AMC
B Probe Hit Machine Position in AMC
C Probe Hit Machine Position in AMC
Active Tool Number
Active Tool X Offset - Probe
Active Tool Y Offset - Probe
Active Tool Length
Active Tool Diameter Deviation
Active Tool Number of Teeth
A2100Di Programming Manual
Publication 91204426-001
42
A2100
System Variable
$CURPOS_MCH(X)
$CURPOS_MCH(Y)
$CURPOS_MCH(Z)
$CURPOS_MCH(U)
$CURPOS_MCH(V)
$CURPOS_MCH(W)
$CURPOS_MCH(A)
$CURPOS_MCH(B)
$CURPOS_MCH(C)
$CURPOS_PGM(X)
$CURPOS_PGM(Y)
$CURPOS_PGM(Z)
$CURPOS_PGM(U)
$CURPOS_PGM(V)
$CURPOS_PGM(W)
$CURPOS_PGM(A)
$CURPOS_PGM(B)
$CURPOS_PGM(C)
$PROBE_POS_MC(X)
$PROBE_POS_MC(Y)
$PROBE_POS_MC(Z)
$PROBE_POS_MC(U)
$PROBE_POS_MC(V)
$PROBE_POS_MC(W)
$PROBE_POS_MC(A)
$PROBE_POS_MC(B)
$PROBE_POS_MC(C)
$TOOL_DATA(0)RECORD_NUM
$TOOL_DATA(0)X_PRB_OFFSET
$TOOL_DATA(0)Y_PRB_OFFSET
$TOOL_DATA(0)LENGTH
$TOOL_DATA(0)DIA_OFFSET
$TOOL_DATA(0)TEETH
Chapter 12
May 2002
Menu
A950
Register
M161
M162
M163
M164
M165
20
A950
Machine State
Active Tool Type
Active Tool Tip Angle
Active Tool Pocket
Active Tool Nominal Diameter
Active Tool ID
A2100
System Variable
$TOOL_DATA(0)TYPE
$TOOL_DATA(0)TIP_ANGLE
$TOOL_DATA(0)POCKET
$TOOL_DATA(0)NOM_DIA
$TOOL_DATA(0)IDENTIFIER
A950 Cycle Parameters Supported in the Machine Control
Cycle Parameters not found in the following internal table may be entered in the CYCLE
PARAMETERS Translation table when there is an equivalent A2100 system variable.
A950 Cycle
Parameter
15
16
17
18
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
21
A950
Description
X+ Probe Tip Size
X- Probe Tip Size
Y+ Probe Tip Size
Y- Probe Tip Size
G82 Finish Depth - Inch
G82 Finish Depth - Metric
G83 Relief - Inch
G83 Relief - Metric
G86 Bottom Retract - Inch
G86 Bottom Retract - Metric
G87 Bottom Retract - Inch
G87 Bottom Retract - Metric
Gage Height - Inch
Gage Height - Metric
G82 Finish Feed % Factor
G82 Dwell **.** Sec
G87 Dwell **.** Sec
G89 Dwell **.** Sec
G84 Retract Feed %
A2100 System Variable $Cycle_PaRams(2)
X_POS_TIP
X_NEG_TIP
Y_POS_TIP
Y_NEG_TIP
G82_FIN_DPTH
G82_FIN_DPTH
G83_RELIEF
G83_RELIEF
G86_BOT_RET
G86_BOT_RET
G87_BOT_RET
G87_BOT_RET
GAGE_HT_INCH
GAGE_HT_METRIC
G82_FEED_FAC
G82_DWELL
G87_DWELL
G89_DWELL
J-word value for subsequent G84 and
G84.1 tap cycle blocks
A950 Temporary Register Variables Supported in the Machine
Control
A950 T-register variables are translated into A2100 Process Control Data variables.
[T32] becomes [$PROCESS_DATA(32)K]
[T[T45]] becomes [$PROCESS_DATA([$PROCESS_DATA(45)K])K]
A950 Commissioning Data Items Supported in the Machine Control.
There are no Commissioning Data items [Cnn] translated to A2100 variables.
Note
Some default settings are available in the System Parameters translation table.
A2100Di Programming Manual
Publication 91204426-001
43
Chapter 12
May 2002
Menu
22
A950 Sub-routine Parameter Variables Supported in the Machine
Control
The following sub-routine parameter variables exist in an internal translation table:
23
A950 Parameter
A2100 Variable
P1
P2
P3
P4
P5
P6
P7
P8
P9
P10
P11
P12
P13
P14
P15
P16
P17
P18
&G
&X
&Y
&Z
&B
&I
&J
&K
&F
&S
&T
&M
&R
&A
&C
&U
&V
&W
Fixed Cycle Hole Depth
The Fanuc control Z-word in a fixed cycle is a function of the G90/G91 mode, a block is
inserted in the translated program prior to the first fixed cycle block:
”[$CYCLE_PARAMS(2)HOLE_DEPTH]=0” for G90 mode.
”[$CYCLE_PARAMS(2)HOLE_DEPTH]=1” for G91 mode.
Since the A850SX control and the A950 control Z-word in a fixed cycle is always
programmed incrementally, a block is inserted in the translated program prior to the first
fixed cycle block:
”[$CYCLE_PARAMS(2)HOLE_DEPTH]=1”
For the A850SX control milling cycles, an additional block is inserted:
”[$CYCLE_PARAMS(2)MIL_DEPTH]=1”
24
Sub-routine Translations
A sub-routine program may be embedded in, or appended to the mainline program, or
may be a separate program. An embedded or appended sub-routine is translated and
remains as an in-line sub-routine in the mainline program. A separate sub-routine
program is assigned a machine control sub-routine name by appending the ID number to
the characters ”SUB-”. The translated machine control mainline program will then call
this library sub-routine by this name.
When the subroutine is a separate program, the translated subroutine is stored in the
temporary Editor buffer and must be saved in the program directory by the operator by
using the ”SUB-n” program name.
A2100Di Programming Manual
Publication 91204426-001
44
Chapter 12
May 2002
Menu
24.1
Translation Errors and Recovery
If an error occurs while performing a translation, the translation will stop at that block, a
dialog box will display the related error message, and the cursor will be positioned at the
word which caused the error.
After the dialog box is cleared, a table may be modified to cover special cases, or the
Editor can be used to correct the original Acramatic 950 MC part program. This
Acramatic 950 MC program is again translated until no further errors exist.
The following is a list of translation errors and actions to take when they occur:
Error:
TRN_ERR_NO_PROG_NUMBER Error
The first character of the first block of a Fanuc program is not an alphabetic
”O” or ”:”, which is the designator for the Fanuc® program number.
Solution:
G
G
Error:
Add a Fanuc program number (ie. O1234) at the beginning of the
program.
Restart the translation.
TRN_ERR_NO_TRN_FOR_M_CODE Error
This M code is not in the M CODE translation table. When this error occurs
the cursor is positioned at the M code in question.
Solutions:
G
G
G
G
Error:
This M code may be added to the M CODE translation table with the
corresponding A2100 translation.
The M code may be added to the M CODE translation table with no
corresponding A2100 translation; this would simply remove the M code
when found during translation.
Remove this M code from the Fanuc or the A850SX part program using
edit.
Restart the translation.
TRN_ERR_NO_TRN_FOR_VARIABLE Error
The variable being translated is not in the translation table.
Solutions:
G
G
G
Error:
Enter the Fanuc variable number and the corresponding A2100 System
variable name into the SYSTEM REGISTERS translation table. Note:
Some Fanuc system registers may not correspond to A2100 System
variable names .
Remove variable from program.
Restart the translation.
TRN_ERR_NO_TRN_FOR_G_CODE Error
The G code is not one of the G codes found in the ”Degree of Compatibility”
section and is not found in the G SUBROUTINE or G-CODE translation table.
Solution:
The mainline program must be modified to perform the same function as the
original G-code, since the A2100 control has no provisions for writing special
G-code subroutines.
A2100Di Programming Manual
Publication 91204426-001
45
Chapter 12
May 2002
Menu
Error:
TRN_ERR_BAD_GRAMMAR_P1 Error
A Translator program error occurred on the first pass of the translation.
Solution:
This is a problem within the Translator Program software. Report this error to
the manufacturer with the specific data block being translated.
Error:
TRN_ERR_BAD_GRAMMAR_P2 Error
A Translator program error occurred on the second pass of the translation.
Solution:
This is a problem within the Translator Program software. Report this error to
the manufacturer with the specific data block being translated.
Error:
TRN_ERR_NULL_INPUT_FILE_HANDLE Error
The input file handle is null.
Solution:
This is a control system problem and must be reported to the control
manufacturer.
Error:
TRN_ERR_NULL_OUTPUT_FILE_HANDLE Error
The output file handle is null.
Solution:
This is a control system problem and must be reported to the control
manufacturer.
Error:
TRN_ERR_A850_LEXICAL_ERROR Error
A Translator program error occurred in the lexical portion of the translation.
Solution:
This is a problem within the Translator Program software and must be
reported to the manufacturer with the specific data block being translated.
Error:
TRN_ERR_NO_PWORD_AFTER_G35 Error
A P-word is needed in an A850 G35 block.
Solution:
G
G
Error
Add a P-word with value of (1) to (6) for the Work Co-ordinate System.
Restart the translation.
TRN_ERR_NO_TRN_FOR_VARIABLE_NAME Error
No translation exists for internal variable name used in table character string.
Solution:
G
G
Error:
Correct the string; possible names: {SOLIDTAP=1} there must be no
blanks
Restart the translation.
TRN_ERR_NO_TRN_FOR_A850_VARIABLE
No translation exists for the indicated variable.
Solution:
G
G
Remove the indicated variable.
Restart the translation.
A2100Di Programming Manual
Publication 91204426-001
46
Chapter 12
May 2002
Menu
Error:
TRN_ERR_A850_ASSIGN_TABLE_VALUE
The assignment value is invalid for the designated field.
Solution:
G
G
Error:
Reference the A850SX or A950 G10 Table Assignments chart for valid
values for that field. Edit the original part program
Restart the translation.
TRN_ERR_A850_ASSIGN_TABLE_FIELD
The field is invalid for the designated table.
Solution:
G
G
Error:
Reference the A850SX or A950 G10 Table Assignments chart for valid
fields for that table. Edit the original part program.
Restart the translation.
TRN_ERR_CLS_NOT_ALLOWED_IN_PATTERN
No translation exists for a sub-routine call within a pattern cycle.
Solution:
G
G
Error:
Edit the original part program to avoid this sub-routine call.
Restart the translation.
TRN_ERR_CANCELED_INCOMPLETE
Translation cancelled Incomplete.
Solution:
G
G
Error:
A cancellation produces an incomplete output program that cannot be run.
Restart the translation.
TRN_ERR_NO_TRN_MULTIPLE_THD
No translation exists for multiple threading blocks within a (THD, ) threading
cycle
Solution:
G
G
Error:
Edit the original part program to avoid these multiple threading blocks.
Restart the translation.
TRN_ERR_NO_TRN_FACE_THD
No translation exists for face threading in a (THD, ) threading cycle.
Solution:
G
G
Error:
Edit the original part program to eliminate this face threading cycle, as this
is unavailable in the A2100.
Restart the translation.
TRN_ERR_NO_TRN_MACH_REG
Indicated machine register is not defined in the machine register translation
table.
Solution:
G
G
Add the indicated machine register to the translation table with the
appropriate A2100 system variable, or edit the original part program to
eliminate it.
Restart the translation.
A2100Di Programming Manual
Publication 91204426-001
47
Chapter 12
May 2002
Menu
Error:
TRN_ERR_NO_TRN_CYC_PARM
Indicated cycle parameter is not defined in the cycle parameter translation
table.
Solution:
G
G
Add the indicated cycle parameter to the translation table with the
appropriate A2100 system variable, or edit the original part program to
eliminate it.
Restart the translation.
A2100Di Programming Manual
Publication 91204426-001
48
Chapter 12
May 2002
Menu
Chapter 13
POSITION/CONTOURING ROTARY AXIS (OPTIONAL)
Contents
1
2
3
4
4.1
4.2
5
5.1
6
7
8
8.1
Rotary A-axis........................................................................................ 3
Rotary Axis Motion Codes .................................................................. 4
Absolute Positioning (G90) ................................................................. 5
Incremental Positioning (G91) ............................................................ 6
Linear and Rotary Axis Interpolation (G93)........................................ 6
Calculation of Rotary Rate (RR).......................................................... 8
Contouring Rotary Axis Unwind (G12) ............................................... 9
Rotary B-Axis ....................................................................................... 9
Dual Rotary Axis Applications .......................................................... 11
Rotation of Offsets............................................................................. 12
Axis Clamps ....................................................................................... 13
Rotary Clamp/Unclamp Examples .................................................... 14
A2100Di Programming Manual
Publication 9204426- 001
1
Chapter 13
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204426- 001
2
Chapter 13
May 2002
Menu
1
Rotary A-axis
The rotary A-axis code is an eight-digit number preceded by the letter A.. Leading and
trailing zeros may be omitted. The decimal point is only necessary if the end point is not
in whole degrees, and if no sign is programmed a plus sign is assumed.
Fig. 1.1 Rotary A-Axis Viewed from the Linear Axis (X+) Position
Fig. 1.2 Rotary A-Axis Configured to be CW (+) Seen from the Operators Position
A2100Di Programming Manual
Publication 9204426- 001
3
Chapter 13
May 2002
Menu
The direction of rotation, illustrated above, is said to be positive when the tool moves
counterclockwise around a stationary workpiece. On machining centre installations,
however, the tool is stationary, and the rotary table rotates clockwise to provide the
rotary motion. A programmed command from A0.000 to A+90.000 is said to be a
positive rotation.
The direction of viewing the rotary A-axis is shown on Fig. 1.1. As the A-axis drive is
normally positioned at the right hand end of the machine table, a CW (+) rotation of the
A-axis is seen from the machine operator position as a CCW rotation.
Fig. I.2 illustrates the A-axis faceplate rotating CW (+) as seen from the operators
position. The direction of axis rotation is a user preference and the machine may be
configured to rotate CW or CCW.
The rotary table input is in degrees and thousandths of a degree, and the smallest
movement possible is 0.001 degree. The range of rotary axis movement is ±99999.999.
In absolute positioning mode (G90) the table will position to an absolute A value and the
sign will determine the end-point position with respect to A0. In incremental positioning
mode (G91) the table will rotate from its current position by the number of degrees
programmed, and in a direction determined by the sign.
The zero position of the rotary axis, established during the Target Point Alignment
procedure, can be shifted by using the Position Set (G92) feature, or via a Pallet Offset,
or a Multiple Set-up (Part) Offset - see Chapter 6.
Fixture Offsets may be used to correct for misalignment of the workpiece from the centre
of rotation of the rotary table - see Chapter 6 for principles of operation and programming
procedures.
A position/contouring rotary axis is normally supplied with a clamp/unclamp facility. The
clamp provides additional rigidity to the set-up once the rotary axis is in position. The
clamp/unclamp feature is programmed via miscellaneous (M) codes - see Chapter 7 for
principles of operation and programming procedures.
Axis rotation will occur at either rapid rate or at a programmed feedrate, in degrees per
minute; or at a feedrate selected using inverse time (G93). Rapid rate will occur when a
slide motion G code (e.g. G00, G81 etc.) is selected which directs the linear slides to
'rapid' position. Axis rotation will occur at feedrate when the slide motion G code G01 is
selected.
2
Rotary Axis Motion Codes
G00 A
Rotates at rapid rate.
G00 X- Y- Z- A
All axes start and end their respective spans simultaneously.
The A axis is not interpolated with X, Y or Z motion. Tool
motion is at vector rapid rate unless the A axis takes longer to
reach its position.
G01 A±4.3 F4.0
Rotates at Fxxxx degrees/min.
G94 G01 X-Y-Z-A-F
All axes start and end their respective spans simultaneously.
The A-axis is not interpolated with the X, Y or Z motion. Linear
feedrate is at Fmm/minute, or Fmm/rev of the spindle if G95 is
active.
A2100Di Programming Manual
Publication 91204426- 001
4
Chapter 13
May 2002
Menu
G93 G01 X-Y-Z-A-F2.3 Rotary axis rotation will start with the linear slide motion and
the move will be fully interpolated so that all motion will stop in
the span time specified in the programmed inverse time (G93)
feedrate word - see Chapter 5.
G81 X-Y-Z-R-A-
The X, Y and A axes start and end their respective spans
simultaneously. The A axis is not interpolated with X or Y
motion. Tool motion is at vector rapid rate unless the A axis
takes longer to reach its position. The rapid span (R) then the
feed span (Z) of the fixed cycle, follow the XYA motion.
Note
Do not program a rotary axis command in a Fixed Cycle data block. The rotary axis will
move to position but remain unclamped throughout the motion of the fixed cycle, and
also until the system processes a clamp (Mxx) code.
3
Absolute Positioning (G90)
Fig. 3 1 Absolute Positioning
Figure 3.1 shows the rotary axis with the tool at the zero degree position. If it is required
to move the tool point to the 90 degree position, the programmer programs an “A+90”
command. The faceplate will index through 90 degrees of rotation to place the “A+90”
position on the rotary axis at its 12 o’clock position.
An “A–90” command results in a CCW (–) rotation of the faceplate to locate the “A–90”
position on the rotary axis at the 12 o’clock position.
The rotary axis should be treated as a linear axis in which there is only one zero degree
point. In rotary axis position/contouring applications, the graduations marked on the
faceplate should be ignored.
A2100Di Programming Manual
Publication 9204426- 001
5
Chapter 13
May 2002
Menu
Fig. 3.2 Linear Interpretation of Rotary Movement
Fig. 3.2 shows how a series of 90º indexes has brought the A axis to the 450º position see inset program N10 - N50. The “A+90” command in block N60 rotates the faceplate
in the opposite direction through 360º to the “A+90” position. An “A–90” command in
block N60 rotates the faceplate 540º in the opposite direction to the -90º position.
4
Incremental Positioning (G91)
Fig. 4.1 Incremental Positioning
Figure 4.1 shows the tool positioned at some point P1 on the rotary axis. It is required to
move the tool to a new position (P2) that is 90 degrees in a counterclockwise direction,
i.e. the faceplate is to move clockwise 90 degrees.
There are two possible ways to move to the new position:
4.1
G
Program an “A+90” which will move the faceplate through 90 degrees to the new
position.
G
Program an “A-270º” which will move the faceplate through 270 degrees to the new
position.
Linear and Rotary Axis Interpolation (G93)
When only the X and A-axes are moving, the Span Length used to calculate the inverse
time feed rate number may be found using the following formula:
A2100Di Programming Manual
Publication 91204426- 001
6
Chapter 13
May 2002
Menu
SL =
X 2 + ( ASL)2
Where:
X
ASL
= X-Axis Span Length in mm (ins).
= A-Axis Span Length in mm (ins).
The X-Axis Span Length is the distance between the point where the move starts in X
and where the move stops.
The A-axis Span Length is the Arc Length for the rotary distance travelled and may be
found using the following formula:
ASL = R(0.01745A1)
Where:
0.01745
R
A1
= Constant - to convert Degrees to Radians.
= Radius of Cut in mm (ins).
= Rotation Angle in Degrees.
This span length is used in the following inverse time feed rate number (Fxx.xxx):
calculation:
FRN =
V
60SL
Where:
V
FRN units
= Linear Feedrate in mm(ins)/min.
= 1/seconds in time.
The reciprocal of FRN is the calculated time in seconds to feed through SL, the
programmed Span Length.
Example:
Calculate the FRN value for the following X–A interpolated movement. Assume
normal linear feed rate to be 125mm/min.
Tool tip co-ordinates when cutting at 175mm radius.
Start Point
X0.000
A0.000
End Point
X125.00
A20.00
Tool Tip Movement
X125.00
A20.00 degrees
A-Axis Span Length Calculation
ASL
= R(0.01754A1)
= 175 (0.01745 X 20)
ASL
= 61mm
Span Length Calculation
∆X 2 + ∆( ASL)2
SL
=
SL
= 1252 + 612
SL
= 19346
SL
= 139mm
A2100Di Programming Manual
Publication 9204426- 001
7
Chapter 13
May 2002
Menu
Feedrate Number Calculation
FRN
=
V
60 x SL
FRN
=
125
60 x 139
FRN
=
F0.015
Execution Time Calculation
FRN
=
1
Seconds
Execution Time (Seconds)
=
1
FRN
=
1
0.015
= 66.7 Seconds
When a rotary axis motion is combined with two or more linear axes movements, the
calculations become time consuming and complex. In most cases, an adequate
approximation of the time path can be determined by using only the linear
displacements:
SL
=
X 2 + Y2 + Z2
This approximated span length is used directly in the Inverse Time Feedrate number
calculation ie.:
FRN
= V
60SL
The rotary axis will move at a rate that results in uniform motion through the linear span
length. In the event that a rotary move cannot be completed in the time (1/FRN) allotted
for the linear movement, it will be necessary to use a reduced linear feedrate to allow the
rotary move to be completed within its designated feedrate constraints.
In linear/rotary combination moves, the rotary feedrate may be tested to be within the
feedrate range as follows:
4.2
Calculation of Rotary Rate (RR)
RR
= ∆A x 60 degrees/minute
ET
Where:
∆A
= Rotation span (degrees).
ET
= Execution Time (seconds).
In our example ∆A = 20 degrees and ET = 66.7 seconds, therefore:
RR
= 20 x 60
66.7
= 18 degrees/minute
A2100Di Programming Manual
Publication 91204426- 001
8
Chapter 13
May 2002
Menu
If the calculated rotary rate of 18 degrees/minute does not exceed the feedrate range of
a rotary axis, then an adjustment to the linear feedrate is unnecessary.
The following table and example show how to convert minutes and seconds to
thousandths of a degree.
Minutes or Seconds
Degree Equivalent
Minutes
0.83333
0.66667
0.50000
0.33333
0.16667
0.08333
0.06667
0.05000
0.03333
0.01667
50
40
30
20
10
5
4
3
2
1
Seconds
0.01389
0.01111
0.00833
0.00556
0.00278
0.00139
0.00111
0.00083
0.00056
0.00028
Smallest input in degrees = 0.001
Example:
Convert an index of 83° 17’ 23” to thousandth of a degree input.
8°
17’
23”
=
= 8.00000
= + 10’
+ 5’
+ 2’
17’
= 0.16667
= 0.08333
= 0.03333
= 0.28333
= 0.28333
= + 20”
+ 3”
23”
= 0.00556
= 0.00083
= 0.00639
= 0.00639
8° 17’ 23”
5
= A8.290
Contouring Rotary Axis Unwind (G12)
During some machining operations, a contouring rotary axis can achieve large positive
or negative absolute positions as a result of continuous rotation. A G12 block may be
used to update the current position to its modulo 360 co-ordinate, and so avoid
unnecessary and non-productive axis rotation to return to the 0-360 degree range - see
Chapter 5 for further information.
5.1
Rotary B-Axis
A rotary axis facing along the Y axis of the machine (see Fig. 5.1) is designated a B-axis.
The normal direction of viewing the B-axis is from the positive end of the Y-axis, ie. from
the rear of the machine.
A2100Di Programming Manual
Publication 9204426- 001
9
Chapter 13
May 2002
Menu
Fig. 5.1 Rotary B-axis. Normal Direction of View
From the operators position, a positive B-axis command (e.g.: B0.000 to B+90.000) is
seen as a CCW rotation of the faceplate. As indicated within the A-axis description, the
direction of axis rotation is a user preference and the machine may be configured to suit.
Fig. 5.2 shows that a CW (+) rotation of the faceplate may be seen from the + or - ends
of the Y-axis by configuring the machine as required.
The principles of programming the B-axis are as described for the A-axis earlier in this
Chapter.
The location of a rotary B-axis on a vertical machining centre can present difficulties in
workpiece loading, and can also cause significant reduction in the working range of the Y
and Z axes.
Fig. 5.2 Rotary B-axis. Direction of Rotation
A2100Di Programming Manual
Publication 91204426- 001
10
Chapter 13
May 2002
Menu
6
Dual Rotary Axis Applications
A dual rotary axis device usually takes the form of a tilting axis, integrated with a rotary
axis. Both axes may interpolate together with the linear axes of the machine. The rotary
axis is normally a 360 deg position/contouring device configured with software range
limits. The tilting axis, by definition, incurs a restricted range of rotation governed by
software limits and protected by mechanical range limits (see the manufacturers
handbook).
The location of the dual rotary axis device depends on its size in relation to the machine.
Normally, the device may be situated at the right-hand end of the table such that the
tilting axis is parallel to the Y-axis with the rotary axis facing along the X-axis. Such an
arrangement is shown in Fig. 6.1.
Fig. 6.1 Normal Table Arrangement for Dual Rotary Axis Drive
From the operators position:
G
The Rotary A-axis faceplate faces towards the operator.
G
The Tilting B-axis faceplate faces towards the column.
G
A positive A-axis command (e.g.: A0 to A+90.000) is seen as a CCW faceplate
rotation.
G
A positive B-axis command (e.g.: B0 to B+90.000) is seen as a CCW faceplate
rotation.
Note
The direction of axis rotation is a user preference and the machine can be configured to
suit.
The table arrangement shown in Fig. 6.1 is not practical when larger versions of the dual
rotary axis device are to be considered. In this situation it is necessary to orientate the
A2100Di Programming Manual
Publication 9204426- 001
11
Chapter 13
May 2002
Menu
device such that the tilting axis is parallel to the X-axis, with the rotary axis facing along
the Y-axis. Such an arrangement is shown in Fig. 6.2.
Fig. 6.2 Table Arrangement for Larger Versions of Dual Rotary Axis Drive
From the operators position:
G
The tilting A-axis faceplate faces towards the operator.
G
The rotary B-axis faceplate may rotate 180 degrees to face both the operator and the
column.
G
A positive A-axis command (e.g.: A0 to A+90.000) is seen as a CCW faceplate
rotation.
G
A positive B-axis command (e.g.: B0 to B+90.000) is seen as a CCW faceplate
rotation, when the faceplate faces the column.
Note
The direction of axis rotation is a user preference and the machine can be configured to
suit.
The axis designation specified in Fig. 6.2 is adopted by industry as the 'N.C. Standard'.
However, some users may prefer the full 360,000 position/contouring rotary axis to
remain as the ’A’-axis, and always designate the tilting axis as the B-axis. If so, the user
is requested to read ’B’ where ’A’ is specified, and read ’A’ where ’B’ is specified, and to
mark-up the text accordingly.
Note
Non-conformance to the ’N.C. Standard’ of axis designation precludes any advantage
offered to users by the ’rotation of offsets’ feature.
7
Rotation of Offsets
Pallet and Fixture Offsets may be manually set or programmed to rotate as a function of
rotary axis motion - see Chapter 6. The system is configured such that A-axis rotation
A2100Di Programming Manual
Publication 91204426- 001
12
Chapter 13
May 2002
Menu
will cause Y and Z offsets to rotate. Similarly, B-axis rotation causes the X and Z offsets
to rotate.
The system will rotate offsets about one rotary axis, either A, B or C. In dual rotary axis
applications, the machine will be already configured depending on the table arrangement
shown in Figs. 6.1 and Fig. 6.2. The full 360,000 position/contouring axis will be
configured for this purpose, i.e.: the Y-Z offsets rotate about the A-axis in Fig. 6.1, or the
X-Z offsets rotate about the B-axis in Fig. 6.2.
The rotated offsets are only valid for faceplates at 90 degrees to the machine table
surface. For further information refer to Chapter 6.
8
Axis Clamps
A rotary A or B axis will clamp and unclamp on processing the designated Mxx
commands:
M10 - Rotary Axis Clamp (at control power off).
M11 - Rotary Axis Unclamp (at machine power on).
The M10 code is modal and functional at the end of the span in which it is programmed,
and the M10 (Clamp) function can be entered in the same block as the programmed
rotary axis command, i.e.:
N123 G0 A270 M10
In block N123, once the rotary axis has reached position (A270º) the M10 code will
clamp the axis until receipt of an M11 Unclamp command.
M10 is changed to M11 when any of the following conditions occur:
G
At machine power on.
G
Rotary A-axis command.
G
Rotary axis unclamp function (M11) is processed.
The rotary axis clamp is automatically turned on at control power off.
The M11code is modal and functional when read at the beginning of the span in which it
is programmed, and the M11 (Unclamp) function is automatically executed by the
system when a rotary axis motion block is programmed, i.e.:
N234 G0 A270
In block N234, the rotary axis automatically unclamps (if it was clamped) prior to rotating
to the 270 degree position. The rotary axis remains unclamped unless an M10 code is
present in the block.
If required, the M11 code may be programmed to unclamp the rotary axis in a block prior
to the actual A-axis motion span, i.e.:
N345 G0 Zzzz M11.
N346 A270.
In block N345, the rotary axis is unclamped during the Z axis motion span. Sequence
N346 rotates the unclamped rotary axis to the 270 degree position, and the axis remains
unclamped at the end of the rotary span.
The rotary axis automatically unclamps at control power on.
A2100Di Programming Manual
Publication 9204426- 001
13
Chapter 13
May 2002
Menu
8.1
Rotary Clamp/Unclamp Examples
Milling Example
N456 G0 A180 M10
N457 G1 Y--N458 G0 Y--- Z---M11
N459 A270 M10
N460 G1 Y--- ETC
Following the Y axis milling span, sequence
N458 rapids the tool clear of the workpiece,
repositions the Z axis for the next pass across
the workpiece, and simultaneously unclamps
the axis.
In block N459 the rotary axis rapids to the 270
degree position and clamps the axis prior to
processing sequence N460 in which the tool
feeds back across the workpiece.
Hole Making Example
N567 G80 A180-M10
N568 G81 XYZRFSM
N569 G80 A210 M10
N570 G81 XYZRW
N571 G80 A240 M10 ETC
The drilling cycle in block N568 takes place
with the rotary axis clamped at 180 degrees.
Following the rotary span to A210, sequence
N570 redefines the G81 drilling cycle.
In sequence N570 the XY co-ordinates may
define the same position (optional), or a
specific position different to the earlier XY
location.
Z and R words must be
programmed in this block because of the
change of G codes. This is true whether-ornot there is any change in Z or R coordinates.
A W word effective after the hole is drilled,
may be programmed to provide a clearance
retraction span from the R plane.
Note
The M10 and M11 (clamp/unclamp) codes described here may be used if the rotary axis
is designated with the B address i.e: N456 G0 B180 M10
In Dual Rotary Axis applications (’A’ and ’B’ axes), a separate set of Mxx codes are
provided for each axis, ie:
Rotary Axis
A-axis
- or
B-axis
Clamp Code
M10
(M10.1)
M10.2
Unclamp Code
M11
(M11.1)
M11.2
The functional operation of M10.1/M10.2 (clamp) and M11.1/M11.2 (unclamp) is as
described earlier for M10 and M11 (clamp/unclamp) functions. The M10 and M11
functions are also described in Chapter 7.
Note:
When machining operations are done which require the Rotary Axis to be held stationary
e.g.. mill flat, drill hole, patterns, etc. it is the programmer’s responsibility to ensure that
the device is clamped by programming the ROTARY AXIS CLAMP (Mxx) code.
CAUTION
Failure to ensure that the rotary axis device is clamped, when being used in the
operational mode indicated, may affect the long-term performance of the device.
A2100Di Programming Manual
Publication 91204426- 001
14
Chapter 13
May 2002
Menu
Chapter 14
PROGRAMMERS QUICK REFERENCE
Contents
1
2
3
3.1
3.2
4
5
6
6.1
6.2
6.3
6.4
6.4.1
7
7.1
7.1.1
7.2
Introduction.......................................................................................... 3
Terms and Definitions ......................................................................... 3
Word Addresses and Functions ......................................................... 3
Type I Blocks........................................................................................ 3
Type II Blocks....................................................................................... 4
G Codes................................................................................................ 5
M Codes................................................................................................ 8
Cycle Parameters................................................................................. 9
Drilling Cycle Parameters.................................................................... 9
Milling Cycle Parameters................................................................... 11
Tool Table Fields ............................................................................... 12
System Variables ............................................................................... 15
System Variable Table Names .......................................................... 17
Program Examples ............................................................................ 17
Program Examples (Parameter Variables) ....................................... 19
Parameter Variable Examples........................................................... 20
Mathematical Functions .................................................................... 21
A2100Di Programming Manual
Publication 91204426-001
1
Chapter 14
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204426-001
2
Chapter 14
May 2002
Menu
1
Introduction
This Chapter provides:
2
G
A summary of the Type I and Type II word formats.
G
A summary of information about the G and M codes.
G
The programmable parameters used by G80 fixed cycles.
G
The programmable parameters used by milling cycles.
G
The programmable field names for tool tables.
G
The programmable parameters used by probing cycles.
G
A summary of system variables.
G
A summary of system table variables
G
A summary of system parameter variables
G
A list of mathematical function designators
Terms and Definitions
Modal
That values follow the normal NC meaning that the value is retained
once it is programmed.
Non-modal
That values are effective only in the block in which they are
programmed.
Cycle Modal
That values are retained once programmed until a different G code in
the same cycle series is programmed.
Gauge Height
The position at which Z axis rapid approach is terminated and feed
cycle begins.
Hole Depth
Hole depth is programmed as the unsigned incremental distance from
the R plane (nominal work surface) using the spindle axis word
3
Word Addresses and Functions
3.1
Type I Blocks
Note
This table does not include pattern or milling cycles.
Address
N
:
G
XYZUVW
ABC
,C
Function
Sequence Number.
Modal State Reset Block.
Preparatory Function (Command).
Linear Axis Command Word.
U and V with G80 - G89 Tip Shift.
W with G80 - G89 Final Retract.
Rotary Axis Command Word.
Chamfer Blend.
A2100Di Programming Manual
Publication 91204426-001
3
Chapter 14
May 2002
Menu
Address
IJK
F
PQR
P
Q
R
,R
E
L
D
H
M
S
T
O
3.2
Function
Axis Interpolation Parameter with G2/G3, Circle Centre and Helix Lead with
G75 - G79, Nominal Axis Position Spline Interpolation Parameters.
Feedrate.
Dwell Time.
Cutter Diameter Compensation Normal Vector.
Circle Arc Radius.
Corner Speed Override Entry Percentage Starting Radius for Spiral and Conical
Interpolation
With Probe Cycles, Single/Double Hit.
Radius Change Per 360º Spiral/Conical Interpolation.
Fixed Cycle Reference Plane.
Corner Speed Override Exit Percentage.
CSS Initial Radius.
Ending Radius For Spiral/Conical Interpolation.
Blend Radius.
Polar Co-ordinate Programming Angle.
Polar Co-ordinate Radial Distance Number of Revs of Circular Motion.
Programmable Offset Selector.
Fixture Offset Selector.
Miscellaneous Function.
Spindle Speed.
Spindle Orientation Angle.
Dwell Duration in Spindle Revolutions.
Tool Record Number or Tool Identifier.
Programmable Tool Offset Selector.
Type II Blocks
Mnemonic
Name
Function
ALM
Report Alarm
Reports an Alarm.
ATR (Option) Automatic Tool
Specifies Program Start Point for Exception Handling.
Recovery
CHN
Chain to Program Loads and Executes Another NC Program.
CLS
Call Subroutine
Call NC Program Subroutine.
COM
Communications
Send Message to Host System.
DAI
Data Acquisition
Set-up for Data Acquisition Feature.
Initialisation
Data Acquisition
DAS
Writes Acquired Data to Active File.
Save
DFS
Define Subroutine Defines Start of NC Program Subroutine.
DWG
Drawing
Selects and Displays a Drawing.
ENS
End Subroutine
Defines the End Of an NC Program Subroutine.
FIL
File Pathname
Specifies Destination File for Subsequent Block.
INP (Option) Operator Input
Request Numeric Input From Operator.
INV
Axis Invert
Specifies Axis Invert Status.
JRN
Write to Journal
Writes a Time Stamped Record To a System Journal.
MSG
Message
Displays a Message for the Operator.
PAG (Option) Page Format
Specifies Paging for Print Out.
A2100Di Programming Manual
Publication 91204426-001
4
Chapter 14
May 2002
Menu
Mnemonic
PGM
PRT (Option)
OPR (Option)
ROT
SHI
SLO
WTF (Option)
4
Name
Program
Print
Operator Query
Rotate
Set High Limit
Set Low Limits
Write to File
Function
Specifies Program Name and Attributes.
Writes a Line to a Printer.
Request YES/NO Answer from Operator.
Rotates NC Program Co-ordinates in Selected Plane.
Sets High Axis Limits.
Sets Low Axis Limits.
Write Message to the Selected File.
G Codes
Any program block can contain only one code from each group. All codes, except those
in the non-modal, and the non-modal modifier group, are modal (i.e. once a value is
programmed it is effective until it is changed by programming another code from the
same group).
Each modal group has a default state, most of which are configurable. The codes
marked (*) in the following table are configurable reset states. Groups whose reset state
is not configurable (such as CDC, which must default to off or G40) have the fixed
default state shown with a double asterisk, (**). The default state is activated at control
power on, by a Data Reset, and at End of Program. Additionally, each modal group is
also reset to its default state when a Modal State Reset block (:) is encountered.
Non-modal codes marked Non-modal modifier are permitted in blocks containing
motion, and they modify the motion (G9) or the interpretation of the axis word values
(G50, G98, and G98.1).
G Code
G0*
G1*
Description
Rapid Transverse, Linear
Linear Interpolation
G2
G2.01
G2.02
G3
G3.01
G3.02
G4
G5
G5.1
G5.2
G5.3
Circular/Helical CW
Circular/Helical CW, Absolute
Circular/Helical CW, Incremental
Circular/Helical CWW
Circular/Helical CWW, Absolute
Circular/Helical CWW, Incremental
Dwell
Spline Off
Spline Curves Only
Spline Corner-Rounding Blends Only
Spline Curves and Corner-Rounding
Blends
Cylindrical Interpolation
Suppress Interpolation
Exact Stop
Contouring Rotary Axis Unwind
Polar Interpolation On
Cylindrical Polar Interpolation Off
Polar Co-ordinate Programming, Bolt Circle
G7.1
G8
G9
G12
G12.1
G13.1**
G15.1*
A2100Di Programming Manual
Publication 91204426-001
5
Group
Rapid Transverse, Linear Interpolation
Linear Interpolation.
Interpolation.
Interpolation.
Interpolation.
Interpolation.
Interpolation
Interpolation.
Interpolation.
Non-modal.
SPlane Select.
Spline.
Spline.
Spline.
Polar Co-ordinate Interpolation.
Non-modal.
Non-modal Modifier.
Non-modal.
Polar Co-ordinate Interpolation.
Polar Co-ordinate Interpolation.
Polar Program.
Chapter 14
May 2002
Menu
G Code
G15.2*
G17*
G18*
G19*
G22, 22.1
G23, 23.1
G24, 24.1
G25, 25.1
G26
G26.1
G27
G27.1
G28
G29
G36
G36.1
G37**
G38
G39
G40**
G41
G42
G43
G44
G44.1
G45*
G45.1
G45.2
G45.01
G45.02
G45.03
G46*
G50
G51
G51.1
G51.2
G51.3
G51.4
Description
Polar Co-ordinate Programming, part
contour
XY Plane Select
ZX Plane Select
ZX Plane Select
Milling Cycle Rectangular Face
Milling Cycle Rectangular Pocket
Milling Cycle Rectangular Inside
Frame
Milling Cycle Rectangular Outside Frame
Milling Cycle Circular Face
Milling Cycle Circular Pocket
Milling Cycle Circular Inside Frame
Milling Cycle Circular Outside Frame
Auto Return to Reference Point
Auto Return from Reference Point
Move to Next Operation Location
Test for End of Pattern
Cancel Pattern
Rectangular Pattern
Circle Pattern
Cutter Diameter Compensation Off
Cutter Diameter Compensation On Left
Cutter Diameter Compensation On Right
PQR Cutter Diameter Compensation On
Multi-axis Tool Length Compensation
Using Tool Length Deviation and Tool
Offset
Multi-axis Tool Length Compensation
Using Total Tool Length
Acceleration/Deceleration On
Acceleration/Deceleration On, Die
Roughing
Acceleration/Deceleration On, Die
Finishing
Acceleration/Deceleration On, User
Defined
Acceleration/Deceleration On, User
Defined
Acceleration/Deceleration On, User
Defined
Acceleration/Deceleration Off
Pallet Co-ordinates
Vector Probe a Surface
Vector Probe a Surface and Set Offsets
Rotary Axis Measurement
Angle Measurement in X or Y plane
Measure Feature-to-Feature in XY Plane
A2100Di Programming Manual
Publication 91204426-001
6
Group
Polar Program.
Plane Select.
Plane Select.
Plane Select.
Interpolation.
Interpolation.
Interpolation.
Interpolation.
Interpolation.
Interpolation.
Interpolation.
Interpolation.
Non-modal.
Non-modal.
Non-modal.
Non-modal.
Pattern Cycles.
Pattern Cycles.
Pattern Cycles.
CDC.
CDC.
CDC.
CDC.
Tool Length Compensation (Option).
Tool Length Compensation (Option).
Acceleration/Deceleration.
Acceleration/Deceleration.
Acceleration/Deceleration.
Acceleration/Deceleration.
Acceleration/Deceleration.
Acceleration/Deceleration.
Acceleration/Deceleration.
Non-modal Modifier.
Non-modal (Probe Option).
Non-modal (Probe Option)1.
Non-modal (Probe Option)1.
Non-modal (Probe Option)1.
Non-modal (Probe Option)1.
Chapter 14
May 2002
Menu
G Code
G51.5
G52
G52.1
G60*
G61*
G61.1
G61.2
G61.3
G68
G69
G70*
G71*
G72
G73
G74
G75
G76
G77
G78
G79
G80
G81
G82
G83
G84
G84.1
G85
G86
G87
G88
G89
G90*
G91*
G92
G92.1
G92.2
G93
G94*
G95*
G96
G97*
G97.1*
G98
G98.1
G99
G150*
Description
Measure Feature-to-Feature in Z Plane
Local Co-ordinate System
Spindle Normal Co-ordinate System
Positioning Mode
Contouring Mode
Cutter Path Left of Work
Cutter Path Right of Work
Automatic Corner Speed Override
Tool Probe Cycle Set Tool Length
Tool Probe Cycle Check Tool Length
Inch Programming
Metric Programming
Set Stylus and Tip Dimension
Set Probe Stylus and Tip Dimension
Set Probe Length
Locate Internal Corner
Locate External Corner
Locate Surface
Locate and Measure Bore or Boss
Measure Pocket or Web
Cancel Fixed Cycle
Drill Cycle
Counterbore/Spot Drill with Dwell Cycle
Deep Hole Drill (Peck Drill) Cycle
Tap Cycle, Conventional
Rigid Tap Cycle
Bore/Ream Cycle
Bore Cycle
Back Bore Cycle
Web Drill/Bore Cycle
Bore/Ream with Dwell Cycle
Absolute Dimension Input
Incremental Dimension Input
Position Set
Position Sets Set-up Offset
Position Sets Pallet Offset
Inverse Time Feedrate (I/T)
Feed Per Minute Feedrate Mode
Feed Per Revolution Feedrate Mode
Constant Surface Speed
Constant Spindle Speed (S = RPM)
Constant Spindle Speed (S = Surface
Speed)
Machine Co-ordinates, Tool Tip
Machine Co-ordinates
Position Set Cancel
Scaling Off
A2100Di Programming Manual
Publication 91204426-001
7
Group
Non-modal (Probe Option)1.
Local Co-ordinates.
Polar Co-ordinate Interpolation.
Cornering.
Cornering.
Cornering.
Cornering.
Non-modal.
Non-modal (Probe Option).
Non-modal (Probe Option)2.
Inch/Metric.
Inch/Metric.
Non-modal (Probe Option)1.
Non-modal (Probe Option)1.
Non-modal (Probe Option)1.
Non-modal (Probe Option)1.
Non-modal (Probe Option)1.
Non-modal (Probe Option)1.
Non-modal (Probe Option)1.
Non-modal (Probe Option)1.
Interpolation.
Interpolation.
Interpolation.
Interpolation.
Interpolation.
Interpolation.
Interpolation.
Interpolation.
Interpolation.
Interpolation.
Interpolation.
Absolute/Incremental.
Absolute/Incremental.
Non-modal.
Non-modal.
Non-modal.
Feedrate.
Feedrate.
Feedrate.
Spindle.
Spindle.
Spindle
Non-modal Modifiers.
Non-modal Modifiers.
Non-modal.
Scaling.
Chapter 14
May 2002
Menu
G Code
G151
Description
Group
Scaling On
Scaling.
Note Codes marked (*)are configurable reset states.
5
M Codes
Each M code is shown as a member of a group. At most one M code from each group
can appear in a block. Two or more M codes from the same group in the same block
cause an alarm. For example, it is valid to code M3, M8, and M5 in one block M3 and
M8 start the spindle and coolant before axis motion begins, and M5 stops the spindle
and coolant after axis motion completes. M codes for which no group is shown are
independent, and can appear together in a block.
Code
0
1
2
3
4
5
6
7
8
9
10/10.x
11/11.x
13
14
19
26
27
28
29
30
34
35
41
42
48
Group
Prog Control
Prog Control
Prog Control
Spindle Start
Spindle Start
Spindle Stop
Tool Control
Spindle Start
Spindle Start
Spindle Stop
Prog Control
Spindle Mode
Spindle Mode
Override
49
Override
70-79
83
User
A2100Di Programming Manual
Publication 91204426-001
Function
Program Stop
Optional Stop
End of Program
Spindle on CW
Spindle on CCW
Spindle and Coolant Off
Tool Change
Coolant #2 On
Coolant #1 On
Coolant Off
Clamp Axis #1 - 4
Unclamp Axis #1 - 4
Spindle On CW, Coolant #1 On
Spindle On CCW, Coolant #1 On
Orient Spindle Stop
Spindle Axis Full Retract
Coolant #3 On
Coolant #4 On
Coolant #5 On
End of Program (put tool away)
Enable Data Acquisition
Disable Data Acquisition
Select Spindle Constant Power Mode
Select Spindle Constant Power Mode
Feedrate and Spindle Speed
Override Enable
Feedrate and Spindle Speed
Override Disable
User Definable M Codes (Option)
Part Complete
8
Block
End
End
End
Start
Start
End
Start
Start
Start
End
End
End
Start
Start
End
End
Start
Start
Start
End
Start
End
Start
Start
Start
Modal
No
No
No
Yes
Yes
Yes
No
Yes
Yes
Yes
Yes
Yes
Yes
Yes
Yes
No
Yes
Yes
Yes
No
Yes
Yes
Yes
Yes
Yes
Start
Yes
Start
-
-
Chapter 14
May 2002
Menu
6
Cycle Parameters
The Cycle Parameters tables provides a means of entering and modifying parameters
associated with fixed cycle operations. To view the Cycle Parameters tables:
G
Select the Cycle Parameters Menu (under the Display mode).
G
Select the appropriate tab, Drilling, Milling, or Probe (optional feature).
The table has two columns of values:
The Base Value column shows the default values for each parameter. These values can
be changed under SETUP password.
The Programmable Value column shows the active values for each parameter, and the
operator can modify these values as required. Most of the parameters can be
overridden by the part program when the cycle is invoked.
Note
GAGE_HT_INCH and GAGE_HT_MM are only listed in the Drilling Cycle Parameters
table. However, they apply to both drilling and milling cycles.
Cycle
Parameter
Gage Height
Drilling Inch
Gage Height
Drilling Metric
6.1
Program
References
GAGE_HT_INCH
Range
0 to 99.9999 inch
GAGE_HT_MM
0 to 999.9999 mm
Comments
Clearance amount added to work
surface reference plane (R word).
Drilling Cycle Parameters
Drilling Cycle
G81
Hole Depth
Programming
Program
References
HOLE_DEPTH
G82_FIN_DPTH
G82
Counter bore/
Spot Drill
Finish Depth
G82_FEED_FAC
G82
Counter bore/
Spot Drill
Finish Depth
Factor
G82_DWELL
G82
Counter
bore/Spot Drill
Dwell Time
A2100Di Programming Manual
Publication 91204426-001
Range
Comments
0 = ABS + tip
1 = INCR + tip
2 = ABS (no tip)
3 = INCR (no tip)
0 to 99.99999 inch
0 to 999.9999 mm
Incremental (INCR) is dimension from
the reference plane.
Absolute (ABS) is dimension of the
hole bottom.
0 to 999%
Percentage times the programmed
feed rate.
0 to 99.99 seconds
Defines dwell time in seconds.
9
Amount of stock left for finishing.
Chapter 14
May 2002
Menu
Drilling Cycle
Range
Comments
0 to 99.99999 inch
0 to 999.9999 mm
Rapid retract distance to break chip.
Used with J word 1 or 11.
G83_SHRT_RET
0 to 999.9999 mm
Incremental Rapid retract distance
below reference plane to clear chips.
Used with J word 2 or 12.
G83_RELIEF
0 to 99.99999 inch
0 to 999.9999 mm
Rapid retract distance above previous
drilled depth. Used with J word 3 or
13.
G84_DWELL
0 to 99.99 seconds
Dwell in time before reversing spindle.
G84_CHIP_BRK
0 to 999 revolution
Number of revolutions used to break
chip in G84.1 rigid tap cycle. If K word
is non-zero, and P word is absent,
this value is used.
G86
Bore Cycle,
Dead Spindle
Bottom Retract
Distance
G87
Back bore
Dwell Time
G87
Back bore
Bottom Retract
Distance
G87
Back bore
Clearance
G88
Breakthrough
Distance
G86_BOT_RET
0 to 99.99999inch
0 to 999.9999 mm
Defines feed retract clearance plane
from hole bottom.
G87_DWELL
0 to 99.99 seconds
Defines dwell time before retraction to
G87 Bottom Retract Distance.
G87_BOT_RET
0 to 99.99999inch
0 to 999.9999 mm
Defines incremental feed distance
away from spindle.
G87_BK_CLR
0 to 99.99999inch
0 to 999.9999 mm
Defines additional distance to move
at lower clearance plane if K word is
not programmed.
G88_BRK_DIST
0 to 99.99999inch
0 to 999.9999 mm
G89
Dwell Time
G89_DWELL
0 to 99.99 seconds
Value added to upper K word depth
plus drill length, if Hole Depth Mode
parameter is 0 or 1 and tool type is
Drill, and both Nominal Diameter and
Tool Angle are non-zero.
Defines Bore Ream bottom hole dwell
before retraction to clearance plane.
G83
Deep Hole
Drill (Peck
Drill) Retract
Distance
G83
Deep Hole
Drill (Peck
Drill) Short
Retract
Distance
G83
Deep Hole
Drill (Peck
Drill) Relief
Amount
G84
Conventional
Tap Dwell
Time
G84.1
Rigid Tap Chip
Break Spindle
Rev.
Program
References
G83_RET_DIST
A2100Di Programming Manual
Publication 91204426-001
10
Chapter 14
May 2002
Menu
6.2
Milling Cycle Parameters
Milling Cycle
Milling Cycle
Depth
Programming
Program
Reference
MIL_DEPTH
Range
Function
Controls spindle axis machining
depth. Setting this field to 0 selects
absolute bottom surface
programming. Setting this field to 1
selects incremental milling cycle depth
programming.
Specifies the width of cut (in
G22, G22.1
FAC_CUT_WDTH 0 to 99%
percentage) for each pass across the
Face Cycle
face. If P word is absent this value is
Cut Width
used.
G22, G22.1
FAC_FIN_STK
0 to ± 9.9999 inch
Specifies the amount of finish stock to
be left during operations that leave
Face Cycle
0 to ± 9.9999 mm
finish stock. If J word is absent this
Finish Stock
value is used.
G22, G22.1
FAC_XY_CLR
0 to ± 9.99999 inch Specifies clearance space around the
face for off work moves. Clearance is
Face Cycle XY
0 to ± 9.9999 mm
calculated by twice the tool diameter
Clearance
plus twice the Face Cycle XY
clearance value.
G23, G23.1
POC_CUT_WDTH 0 to 99%
Specifies the width of cut (in
percentage) for each pass around the
Pocket Cycle
pocket. If P word is absent this value
Cut Width
is used.
G23, G23.1
POC_SFIN_STK
0 to ± 9.99999 inch Specifies the amount of finish stock to
0 to ± 9.9999 mm
be left on the sides of the pocket. If I
Pocket Cycle
word is absent this value is used.
Side Finish
Stock
G23, G23.1
POC_BFIN_STK
0 to ± 9.99999 inch Specifies the amount of finish stock to
be left on the bottom of the pocket. If
0 to ± 9.9999 mm
Pocket Cycle
J word is absent this value is used.
Bottom Finish
Stock
G23, G23.1
POC_PLUNG_FR 0 to ± 9.99999 inch Specifies spindle axis cut depth feed
rate. This value is used if L word = 0
0 to ± 9.9999 mm
Pocket Cycle
or not programmed, and the E word is
Plunge Feed
absent.
Rate
Specifies the width of cut (in
G24, G24.1
FRA_CUT_WDTH 0 to 99%
percentage) for each pass around the
Rectangular
frame. If P word is absent this value is
Inside Frame
used.
Cycle Cut
Width
A2100Di Programming Manual
Publication 91204426-001
0 or 1
11
Chapter 14
May 2002
Menu
6.3
Tool Table Fields
Notes
1. The unique Tool Reference Number is not a visible field in the Tool Manager,
however it is accessible from a part program via a READ ONLY Program Field
Name called REF_NUMBER.
2. To ensure that modifications to the data of the loaded tool are properly saved, all
modifications should be written to both the Active Tool table and to the loaded tool_s
data area, accessed by [$TOOL_DATA(0)].
References to a field in the Tool Data table uses the following form:
[$TOOL_DATA(<record>)<field name>] where:
<record>
is the index into the table of the required record. This can be either the
Tool Record Number or the Tool Reference Number.
<field name>
is the name of the required field. The field names are specified in the
Program Field Name column of the following list.
Note
To ensure that modifications to the data of the loaded tool are properly saved, all
modifications should be written to both the Active Tool table and the loaded tool_s data
area, accessed by [$TOOL_DATA(0)]. The Active Tool table data can be accessed
either by the Tool Record Number or the Tool Reference Number.
Tool Manager
Field Name
Record #
Pocket
Tool ID
Serial Number
Program Field
Name
RECORD_NUM
POCKET
IDENTIFIER
SERIAL_NO
Tool Class
CLASS
Size (Pocket)
SIZE
A2100Di Programming Manual
Publication 91204426-001
Description
This program field is READ ONLY.
Three digit number defining tool pocket. Range is 0 to 999.
Ten digit numeric Tool ID in the range 0 to 9999999999.
32 character alphanumeric field. This field is not accessible
from NC program.
This program field is READ ONLY:
Rotation = 0
Fixed = 1
Miscellaneous = 2
For migrating tool feature, the number of adjacent pockets
required for the tool:
Prev 0 Next 0 = 0
Prev 0 Next 1 = 1
Prev 0 Next 2 = 2
Prev 1 Next 0 = 3
Prev 1 Next 1 = 4
Prev 1 Next 2 = 5
Prev 2 Next 0 = 6
Prev 2 Next 1 = 7
Prev 2 Next 2 = 8
12
Chapter 14
May 2002
Menu
Tool Manager
Field Name
Load Method
Type
Migrating
Length
Flute Length
Tip Angle
Nom Diameter
Program Field
Description
Name
LOAD_METHOD Defines how the tool is loaded into the spindle:
Auto = 0
Manual = 1
Cradle = 2
Heavy Auto = 3
TYPE
Specifies the type of tool. The following are the defined
types:
Unknown = 0
Rough End Mill = 1
Finish End Mill = 2
Ball End Mill = 3
Face Mill = 4
Shell Mill = 5
Spot Face Mill = 6
Key Cutter = 7
Fly Cutter = 8
Thread Mill = 9
Drill = 10
Spot Drill = 11
Counter Sink = 12
Reamer = 13
Tap = 14
Rigid Tap = 15
Bore = 16
Back Bore = 17
Probe = 18
Special Tool 1 = 19
Special Tool 2 = 20
Special Tool 3 = 21
Special Tool 4 = 22
Special Tool 5 = 23
Special Tool 6 = 24
Special Tool 7 = 25
Special Tool 8 = 26
Special Tool 9 = 27
**Required for SFP Option
Specifies whether tool is returned to original pocket or not:
MIGRATING
Disabled = 0 Enabled = 1.
LENGTH
Valid range for tool length is 9999.9999 mm. Must be
non-zero with SFP Option.
FLUTE_LENGTH Flute length in range of 0 to ± 9999.9999 mm. Must be
non-zero with SFP Option.
TIP_ANGLE
Angle from tool centreline in degrees, range is 0 to
359.999º.
Valid range for tool diameter is 0 to 9999.9999 mm. Must
NOM_DIA
be non-zero with SFP Option.
A2100Di Programming Manual
Publication 91204426-001
13
Chapter 14
May 2002
Menu
Tool Manager
Field Name
# Teeth
Program Field
Name
TEETH
Diam Offset
Spindle Dir
DIA_OFFSET
SPDL_DIR
Material
MATERIAL
Holder Orient
HOLDER
Feedrate Ovrd
Spindle Ovrd
Max Spn RPM
FDRT_OVR
SPEED_OVR
MAX_RPM
Used in feed per tooth calculations. Range is 1-99 teeth, 1
tooth specifies FPR mode. Must be non-zero with SFP
Option.
Used for CDC compensation, range is ± 9999.9999 mm.
Spindle direction may be required with SFP Option:
No Rotation = 0
CW Rotation = 1
CCW Rotation = 2
Either Direction = 3
Defines tool material type:
Unknown = 0
High Speed Steel = 1
Tin Coated HS Steel = 2
Carbide Insert = 3
Carbide Coated = 4
Carbide Solid = 5
Diamond = 6
Ceramic = 7
Other = 8
Specifies the tool holder orientation:
Unknown = 0
+ X Plus = 1
- X Minus = 2
+ Z Plus = 3
- Z Minus = 4
+ Y Plus = 5 - Y Minus = 6
Tool feedrate override expressed in percent (0 to 999%).
Spindle speed override; range is 0 to 999%.
Maximum Spindle RPM from 0 - 99999.
Max
Feed/Tooth
Tool Status
MAX_FEED
Maximum Feed/Tooth for this tool, 99.9999 mmpm
Cycle Time
Time Limit
Time Mode
Usage Count
Description
TOOL_STATUS
Available only with Tool Cycle Time and Count Option.
Tool status value are:
Good = 0
New = 1
Worn = 2
Broken = 3
CYCLE_TIME
Accumulated cycle time, range is 0 to 9999.99 min. (Tool
Cycle Time and Count Option).
CYC_TIME_LIM Tool cycle time limit, range is 0 to 9999.99 min. (Tool Cycle
Time and Count Option)
CYC_TM_MODE Indicates whether cycle time should accumulate (Tool
Cycle Time and Count Option)
Disabled = 0
Enabled = 1
USAGE_COUNT Number of uses in the range 0 - 9999 (Tool Cycle Time and
Count Option).
A2100Di Programming Manual
Publication 91204426-001
14
Chapter 14
May 2002
Menu
Tool Manager
Field Name
Usage Limit
Program Field
Name
USAGE_LIMIT
Usage Mode
USAGE_MODE
Alternate ID
ALT_TOOL
Thread Lead
Gear Ratio
Length
Deviation
Plot Colour
THRD_LEAD
GEAR_RATIO
LENGTH_DEV
X Probe Offset
Y Probe Offset
6.4
Description
Maximum number of uses per tool (0 - 9999) (Tool Cycle
Time and Count Option).
Indicates whether usage count should accumulate (Tool
Cycle Time and Count Option):
Disabled = 0
Enabled = 1
Alternate tool used if programmed tool is worn. This field is
not accessible from the NC program.
Range is ± 9999.9999 mm.
PLOT_COLOR
Specifies the plot colour of the tool:
Automatic = 0
Yellow = 1
Orange = 2
Violet = 3
Green = 4
Grey = 5
Blue = 6
Cyan = 7
Magenta = 8
Tan = 9
Lime = 10
X_PRB_OFFSET Probe offset in the range of ± 999.9999mm.
Y_PRB_OFFSET Probe offset in the range of ± 999.9999mm.
System Variables
Variable Name
[$BLOCK_COUNT]
[$CMDPOS_DSP]
[$CUR_FIXTURE]
[$CUR_PALLET]
[$CUR_PGM_ID]
A2100Di Programming Manual
Publication 91204426-001
Definition
Contains the number
of blocks executed.
Axis Command
Position from
production display in
program co-ordinates.
The number of the
currently active fixture,
or -1 if there is no
fixture active.
The number of the
currently active pallet,
or -1 if there is no
pallet active.
The ID of the active
program, or -1 if there
is no ID for the active
program.
15
Array Index
Range
N/A
X,Y,Z,U,V, W,A,B,C
Range 99999.9999mm
Range 99999.9999º
N/A
N/A
N/A
Chapter 14
May 2002
Menu
Variable Name
[$CUR_SETUP]
[$CURPOS_MCH]
[$CURPOS_PGM]
Definition
Array Index
The number of the
N/A
currently active set-up,
or -1 if there is no setup active.
X,Y,Z,U,V, W,A,B,C
Current Position in
Machine Co-ordinates.
Machine Co-ordinate
values are the actual
machine co-ordinates
prior to compensating
for offset from logical,
backlash, or axis error
compensation.
Axis Current Position X,Y,Z,U,V, W,A,B,C
in Program Coordinates.
[$CYCLE_TIME]
The elapsed time, in
seconds, that the
current program has
been "In-Cycle”.
[$DATA_CAPTURE] Data capture values.
1-32
Auto Tool
N/A
Recovery/contains a
value identifying which
condition caused the
exception.
[$HIGH_LIMIT]
The maximum coX,Y,Z,U,V, W,A,B,C
ordinate of the
machine axis travel for
each axis.
Status selection for an N/A
Operator Input Block
(INP).
[$LOW_LIMIT]
The minimum coordinate of the
machine axis travel for
each axis.
[$PAL_ABRT_REQ] Value is TRUE when a
Pallet Abort has been
requested.
[$PATTERN_END] Value is TRUE when a
pattern-sensitive subroutine is entered and
when a G36 is
executed.
[$PGM_ABRT_REQ] Value is TRUE when a
Program Abort has
been requested.
A2100Di Programming Manual
Publication 91204426-001
16
Range 99999.9999mm
Range of 99999.9999º
Range 99999.9999mm
Range 99999.9999º
N/A
[$EXCEPTION]
[$INP_STATUS]
Range
X,Y,Z,U,V, W,A,B,C
Range 99999.9999mm
0 = No Exception
1 = Worn (undersize) tool
2 = Broken Tool
3 = Oversize Tool
4 = Wear limit exceeded
5 = Reserved
Range 99999.9999mm
Range 99999.9999º
0 = Normal conclusion
(operator entered a
value)
2 = Time out
3 = Cancel
Range 99999.9999mm
Range 99999.9999º
N/A
FALSE = 0
TRUE = 1
N/A
FALSE = 0
TRUE = 1
N/A
FALSE = 0
TRUE = 1
Chapter 14
May 2002
Menu
Variable Name
[$PLUNGE_PCT]
[$POSITION_OFS]
[$RECORD_NO]
[$TOOLPOS_MCH]
6.4.1
Definition
Array Index
Used in contour milling N/A
to control plunge feed
rate where feed rate
limitation is require.
Position offsets
X,Y,Z,U,V, W
The record number of N/A
the currently active
tool, or zero (0) if there
is no tool active.
X,Y,Z,U,V, W,A,B,C
Location of tool
change position in
machine co-ordinates.
Range 99999.9999mm
Range 99999.9999mm
Range 99999.9999º
System Variable Table Names
Variable Name
[$PALLET]
[$SETUP]
[$FIXTURE]
[$PROG_OFFSET]
[$TOOL_OFFSET]
[$MACH_OFFSET]
[$CYCLE_PARAMS]
[$TOOL_DATA]
[$PROCESS_DATA]
[$CALENDAR]
7
Range
1 to 100 representing 1%
to 100% of the
programmed feed rate.
Table
Pallet Offsets
Multiple Set-up
Fixture Offsets
Programmable Co-ordinate Offsets
Programmable Tool Offsets
Machine Offsets
Cycle Parameters
Tool Data
Process Control Data
Date/Time Stamp
Program Examples
Example
Program Segment
Pallet Offset Table
[$PALLET(1)X] = .5
Multiple Set-up
Table
[$SETUP(2)X] = 10
Fixture Offsets
[$FIXTURE(1)Y] = 15
Programmable Coordinate Offsets
[$PROG_OFFSET(1)X] = 10
Programmable Tool
Offsets
[$TOOL_OFFSET(1)DIAMETER]
= .5
Programmable Tool
Offsets
[$TOOL_OFFSET(1)LENGTH] =
10.5
A2100Di Programming Manual
Publication 91204426-001
17
Function
In the Pallet Offset Table, the
value 0.5 will be loaded into record
1 in column X.
In the Multi-Set-up Offsets Table,
the value 10 will be loaded into
record 2 in column X.
In the Fixture Offsets Table, the
value 15 will be loaded into record
1 in column Y.
In the Programmable Co-ordinate
Offsets Table, the value 10 will be
loaded into record 1 in column X.
In the Programmable Tool Offsets
Table, the value 0.5 will be loaded
into record 1 in the DIAMETER
column.
In the Programmable Tool Offsets
Table, the value 10.5 will be
loaded into record 1 in the
LENGTH column.
Chapter 14
May 2002
Menu
Example
Program Segment
Machine Offsets
[$MACH_OFFSET(1)X] = .5
Cycle Parameters
[$CYCLE_PARAMS(2)G82_FIN_
DPTH] = .25
Tool Data
[$TOOL_DATA(6)NOM_DIA] = .5
Tool Data
[$TOOL_DATA(0)LENGTH] =
10.2
Process Control
Data
[$PROCESS_DATA(3)X] = .5
Date/Time Stamp
[$CALENDAR(1)] =
[$CALENDAR(0)]
(MSG,_TODAY IS
[$CALENDAR(1)dayofweek]_)
A2100Di Programming Manual
Publication 91204426-001
18
Function
In the Machine Offset Table, the
value 0.5 will be loaded into record
1 in column X.
In the Cycle Parameter Table, the
value 0.25 will be loaded into
record 2 (which is the
Programmable Value column). The
G82_FIN_DPTH identifies the
Program Reference column for
fixed cycle parameter G82 Finish
Depth.
Note
Always use record number (2)
when programming to the Cycle
Parameter table. An alarm is
posted if any other number is
used.
This program segment will load the
value 0.5 into record 6 in the Nom
Diameter column of the Tool Data
Table.
This program segment will load the
value 10.2 into the Length data
field of the currently loaded tool.
When the tool is unloaded, the
value 10.2 will be stored in the
Tool Data table in the record
corresponding to the tool.
This program segment will load the
value 0.5 into record 3 in the X
column of the Process Control
Data Table.
The program reads the current
date, day, and time into [$CALENDAR(1)] and then the message
”TODAY IS <?>” is displayed on
the operator screen.
Chapter 14
May 2002
Menu
7.1
Program Examples (Parameter Variables)
Note
The following Parameter Variables contain values of the parent (calling) program or subroutine, not the current sub-routine. For the main program, the values are the Modal
Reset values.
Modal State
Variable Name
[&INTERP]
Modal Group
Interpolation
[&PLANE]
Plane Select
[&CORNERING]
Cornering
[&CDC]
Cutter Diameter
Compensation
[&FEEDRATE]
Feedrate
[&SPINDLE]
Spindle speed
[&INCH]
Inch/mm
[&ABSOLUTE]
Abs/Inc
[&ACC_DEC]
Acc/Dec
[&POLAR]
Polar interpolation
[&SCALING]
Scaling
A2100Di Programming Manual
Publication 91204426-001
States
0 - Rapid (G0)
1 - Linear (G1)
2 - Circular CW (G2)
3 - Circular CW (G3)
4 - Tilted Circular CW (G2.1)
5 - Tilted Circular CCW (G3.1)
0 - XY Plane (G17)
1 - ZX Plane (G18)
2 - YZ Plane (G19)
0 - Positioning mode (G60)
1 - Contouring mode (G61)
2 - Corner Speed Override Left (G61.1)
3 - Corner Speed Override Right (G61.2)
0 - CDC Off (G40)
1 - Auto CDC Left (G41)
2 - Auto CDC Right (G42)
3 - PQR CDC (G43)
0 - Inverse time (G93)
1 - Feed per Minute (G94)
2 - Feed per Tooth/Rev (G95)
0 - Constant Surface Speed (G96)
1 - RPM Mode (G97)
2 - Surface Speed per Minute (G97.1)
1 (true) - Inch input (G70)
0 (false) - Metric input (G71)
1 (true) - Absolute input (G90)
0 (false) - Incremental input (G91)
0 - Acc/Dec Off (G46)
1 - Acc/Dec On (General machining, G45)
2 - Acc/Dec On (Contour roughing, G45.1)
3 - Acc/Dec On (Contour finishing,G45.2)
4 - Acc/Dec On (User mode 1, G45.01)
5 - Acc/Dec On (User mode 2, G45.02)
6 - Acc/Dec On (User mode 3, G45.03)
0 - Polar Co-ordinate Interpolation Off (G13.1)
1 - (not used)
2 - Cylindrical Interpolation On (G7.1)
1 (true) - Scaling On (G151)
0 (false) - Scaling Off (G150)
19
Chapter 14
May 2002
Menu
Modal State
Variable Name
[&PATTERN]
[&POLAR_PGM]
7.1.1
Modal Group
States
Pattern
0 - No pattern active (G37)
1 - Rectangular pattern active (G38)
2 - Circular pattern active (G39)
Polar programming mode 0 - Bolt circle (G15.1)
1 - Part contour (G15.2)
Parameter Variable Examples
Example:
(PGM, NAME=”EXAMPLE#1”, ID=”1234”)
:G0
(CLS, SUB1)
M2
(DFS, SUB1)
G1
[#TEMP1] = [&INTERP]
(CLS, SUB2)
[ENS]
(DFS, SUB2)
G2
[#TEMP2] = [&INTERP]
[ENS]
The value of [#TEMP1] is 0, since the calling program was in G0 interpolation mode
at the time SUB1 was called.
The value of [#TEMP2] is 1, since the calling program (SUB1) was in G1 interpolation
mode at the time SUB2 was called.
Example:
(PGM, NAME=”EXAMPLE#2”, ID=”5678”)
:1 G0 G71 X0 Y0 Z304.8 M6 T123 M3 S420
N10 G1 X254.0 F610
N20 G[&INCH] X5 F24
M2
In a main NC program, references to the Parameter Variables yield the Default Modal G
Code values, most of which are configured in NC Programming under System
Configuration
Assuming that the Default Inch/Metric Modal G Code was configured for Inch mode
(G70), in block N20 the Inch/Metric mode will change to Inch mode.
A2100Di Programming Manual
Publication 91204426-001
20
Chapter 14
May 2002
Menu
7.2
Mathematical Functions
Function
SIN
COS
TAN
ARCSIN
ARCCOS
ARCTAN
ABS
SQR
RND
INT
Argument Range
308
308
-1.7 x 10 [ ARG [ +1.7 x 10 ARG is
in DEGREES
Value Returned
Sine of ARG, where:
-1 [ SIN (ARG) [ +1
-1.7 x 10308 [ ARG [ +1.7 x 10308 ARG Cosine of ARG, where:
is in DEGREES
-1 [ COS (ARG) [ +1
Tangent of ARG, where:
-1.7 x 10308 [ ARG [ +1.7 x 10308
except for values of ARG close to odd
-1.7 x 10308 [ TAN (ARG) [ +1.7 x 10308
multiples of 90º
Arcsine of ARG, where:
-1 [ ARG [ +1
-90 [ ARCSIN (ARG) [ +90
Arccosine of ARG, where:
-1 [ ARG [ +1
-90 [ ARCCOS (ARG) [ +90
Arctangent of ARG, where:
-1.7 x 10308 [ ARG [ +1.7 x 10308
-90 [ ARCTAN (ARG) [ +90
Absolute value of ARG where:
-1.7 x 10308 [ ARG [ +1.7 x 10308
0 [ ABS (ARG) [ +1.7 x 10308
Square root of ARG where:
0 [ ARG [ +3.37 x 10308
0 [ SQR (ARG) [ +1.7 x 10308
Rounded integer value of ARG.RND (4.5)
-1.7 x 10308 [ ARG [ +1.7 x 10308
= 5 RND
(4.49) = 4
Integer value of ARG. Truncates the
-1.7 x 10308 [ ARG [ +1.7 x 10308
decimal portion of ARG. INT (4.9) = 4
A2100Di Programming Manual
Publication 91204426-001
21
Chapter 14
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204426-001
22
Chapter 14
May 2002
Menu
Chapter 15
SYSTEM CONFIGURATION
Contents
1
1.1
1.2
1.2.1
1.2.2
1.2.3
1.2.4
1.2.4.1
1.2.4.2
1.2.4.3
1.2.5
1.2.6
1.2.7
1.2.7.1
1.2.7.2
1.2.7.3
1.2.8
Configuration Overview .......................................................................3
Security .................................................................................................3
NC Programming Execution ................................................................3
Reset Fixture Offsets ...........................................................................3
Cutter Diameter Compensation (CDC) ................................................4
Glide On/Off ..........................................................................................4
Report Alarms.......................................................................................5
Report PRT Alarms...............................................................................5
Report WTF Alarms ..............................................................................5
Report COM Alarms .............................................................................5
Fixture Offset Axis of Rotation ............................................................5
Modes....................................................................................................6
Circular..................................................................................................6
Endpoint Tolerance ..............................................................................6
Centre Specification.............................................................................6
Collinear Angle .....................................................................................6
M70 - 79 User M Codes Execution (Option) ........................................6
A2100Di Programming Manual
Publication 91204426-001
1
Chapter 15
May 2002
Menu
Intentionally blank
A2100Di Programming Manual
Publication 91204426-001
2
Chapter 15
May 2002
Menu
1
Configuration Overview
The Acramatic 2100 NC control system is configured by setting various system
configuration parameters, by means of icon menu buttons displayed when the
configuration window is opened. The following items affect operation of the NC program.
1.1
Security
Used to select and change password levels. The system control provides multiple
password levels to restrict access to some areas of the system. All passwords are
encrypted within the system and require verification. The following password levels
exist in order of decreasing restrictions:
Operator
Operator level is the default and does not have a password. This level is used for
standard machining operations and control.
Name = Setup
The setup level allows modification of tooling tables, NC programming defaults, and
part-related offset tables.
There is also a service level password that is under control of the Machine Tool Builder.
1.2
NC Programming Execution
Used to set part program default conditions. Defaults listed in this window can only be
changed at the machine site. The following is a brief description of the NC Program
Execution features:
Colon Block - Colon Required
When checked, indicates part program execution must begin on a colon (:) block. No
check means program execution can be anywhere in the part program.
At Colon Block
Any checks in these menu buttons will cause the selected item to be reset when a colon
block in the part program is encountered.
1.2.1
Reset Fixture Offsets
When checked, the H word is cancelled when a colon block is encountered. When
unchecked, the H word value is not cancelled when a colon block is encountered.
Reset Programmable Offsets
When checked, the D word is cancelled when a colon block is encountered. When
unchecked, the D word value is not cancelled when a colon block is encountered.
Reset Programmed Rotation
When checked, the ROT type II block is cancelled when a colon block is encountered.
When unchecked, the ROT type II block is not cancelled when a colon block is
encountered.
A2100Di Programming Manual
Publication 91204426-001
3
Chapter 15
May 2002
Menu
1.2.2
Cutter Diameter Compensation (CDC)
Report CDC Error
When checked, CDC errors will be displayed and reported in the Alarms Journal. When
unchecked, CDC errors will not be displayed or reported in the Alarms Journal.
Constant Feedrate
When checked, CDC maintains a constant feedrate for circular interpolation blocks,
depending on the cutter size. An oversized cutter will move slower when machining the
outside of a circular arc, and an undersized cutter will move slower when machining the
inside of a circular arc. Programmed feedrates are increased or decreased within the
feedrate limits to maintain a constant feedrate.
When unchecked, constant feedrate is not maintained, and circular interpolation blocks
execute at the programmed feedrate.
1.2.3
Glide On/Off
When checked, the CDC Glide On/Glide Off algorithm is executed.
CDC offset X = d * next span direction cosine Y
CDC offset Y = d * next span direction cosine X
where d = cutter radius deviation
Glide On axis CDC offsets are calculated when cutter diameter compensation is
activated. Glide Off offsets are calculated when CDC is deactivated. Glide Off offsets
are also generated in the case where, because of reversal of the programmed path
direction, the CDC modal state is changed from cutter left to cutter right or vice versa.
For Glide On offsets when the next span is a linear span, the axis compensated
commands define an intersection point of the line parallel to the next span and of a line
perpendicular to the end point of the current span.
If the next span is circular, the axis compensated commands define the intersection
between an arc concentric with the programmed arc and a line from the programmed
centre point and the end point of the programmed arc.
A2100Di Programming Manual
Publication 91204426-001
4
Chapter 15
May 2002
Menu
Figure 1.1 CDC Glide On/Glide Off
When unchecked, CDC Glide On/Glide Off is not performed, and the cutter radius
deviation bisects the angle between two spans.
Figure 1.2 CDC Glide On/Glide Off
1.2.4
Report Alarms
1.2.4.1 Report PRT Alarms
When checked, printer errors encountered when executing PRT blocks stop the cycle
and alarms will be displayed and reported in the Alarms Journal. When unchecked,
printer errors encountered when executing PRT blocks are ignored and alarms will not
be displayed or reported in the Alarms Journal.
1.2.4.2 Report WTF Alarms
When checked, any errors encountered when executing FIL, WTF, and DAT blocks stop
the cycle and alarms will be displayed and reported in the Alarms Journal.
When unchecked, file errors encountered when executing FIL, WTF, and DAT blocks
are ignored and alarms will not be displayed or reported in the Alarms Journal. However,
the file data may be lost.
1.2.4.3 Report COM Alarms
When checked, communication errors encountered when executing a COM block will
stop the cycle, and alarms will be displayed and reported in the Alarms Journal.
When unchecked, communication errors encountered when executing a COM block are
ignored and alarms will not be displayed or reported in the Alarms Journal.
1.2.5
Fixture Offset Axis of Rotation
Fixture Offsets will be applied to the rotary axis selection. When this field is blank, rotary
axis Fixture Offsets are not applied.
A2100Di Programming Manual
Publication 91204426-001
5
Chapter 15
May 2002
Menu
1.2.6
Modes
Used to set the Modal G Code Default state used when Data Reset is activated, a colon
block is executed, or end of program is encountered.
Default Modal G Codes selections are as follows:
G0
G1
G18
G17
G19
G60
G61
G71
G70
1.2.7
Rapid
Linear
ZX Plane
XY Plane
YZ Plane
Positioning
Contouring
Metric (mm)
English (Inch)
G91
G90
G15.2
G15.1
G94
G95
G97
G97.1
G96
Incremental
Absolute
Part Contour
Bolt Circle
Feed per Minute
Feed per Tooth
Spindle RPM
Spindle Surface Speed
Spindle CSS
Circular
1.2.7.1 Endpoint Tolerance
Data in this field define the allowable end point tolerance; that is, the amount by which
the starting and ending radius values are allowed to differ. If this value is exceeded, the
alarm will be posted.
To change Circular Endpoint Tolerance, touch to highlight the field, then key-in the
required tolerance using the OSA keypad.
1.2.7.2 Centre Specification
Always Absolute - sets circular centre dimension (I,J,K) are always absolute.
Always Incremental - sets circular incremental.
G90/G91 Switchable - circular centre dimensions follow G90/G91.
Linear.
1.2.7.3 Collinear Angle
Not used in this release.
1.2.8
M70 - 79 User M Codes Execution (Option)
Many applications require the addition of relatively simple equipment to a machine tool,
and require the added equipment to be controlled from the NC program. The user M
Code option makes available the M70 series of M codes for this purpose. To
accommodate the common uses for programmable outputs, the user M Codes can be
configured in several ways:
G
The M code can be active at the Start of Block or End of Block.
G
The output signal can be pulsed and maintained until an external signal is received,
or can be turned off by a second M code.
A2100Di Programming Manual
Publication 91204426-001
6
Chapter 15
May 2002
Menu
G
NC program execution can be held until the function is complete (a fixed time, or
signalled by an external input signal) or NC program execution can be allowed to
continue.
G
The output signal can be configured to be normally on or normally off.
G
An alarm can be reported if the external acknowledgement is not received within a
specified time.
For user M codes, configured as either maintained or toggled, the pulse-width
configuration value establishes a minimum duration. that is:
G
For maintained outputs: if a non-zero pulse-width is specified, the output signal
remains active for the specified time duration, and continues to remain active until
the acknowledgement signal is received.
G
For toggled outputs: if a non-zero pulse-width is specified, the output signal remains
active until the reset M code is received.
Each user M code can be specified to hold cycle or not. If hold cycle is specified, NC
program execution is held until:
G
The pulse-width elapses for pulsed outputs.
G
The pulse-width elapses, and the acknowledgement signal is received for maintained
outputs.
G
The pulse-width elapses and the reset M code is executed for toggled outputs
Finally, each user M code configured as maintained can report an alarm if the
acknowledgement signal is not received within a specified maximum time. This is useful
to detect a failure in the external equipment and report the condition, rather than simply
remaining in cycle waiting indefinitely for the acknowledgement.
The user M codes are independently configurable, and each has an assigned output
signal. The acknowledgement signal, pulse-width, start of block, or end of block
activation, whether-or-not the NC program is held, and also the allowable time to
acknowledge are configurable.
Turn Off Method
Each M code can be individually configured to be toggled, pulsed, or maintained.
M Code
A toggled M code activates its output signal when the associated M code is executed.
The signal is turned off by executing the corresponding reset M code, which is the base
M code with a ”.1” suffix. For example, if M72 is configured as a toggled M code, the
signal is turned on by programming an M72, and turned of by programming M72.1.
Pulsed
A pulsed M code activates its output signal for a fixed time each time that M code is
executed. Each of the M70 user M codes has its own pulse duration.
Feedback 0 through 9
A maintained M code activates its output signal when the M code is executed, and the
signal remains active until the assigned input signal is activated by external circuitry.
This arrangement ensures that the external device has time to respond to the M code
output signal.
Note
Only select one feedback per M code. However, one input can be used for each M code
if required.
A2100Di Programming Manual
Publication 91204426-001
7
Chapter 15
May 2002
Menu
Hold Program
When checked (On), Program Execution will wait for feedback, or if pulsed selected, will
wait for pulse to time-out.
When unchecked (Off), Program Execution will continue and will not wait for feedback or
pulse time-out.
Executed
Only one selection is active, either Start Of Span, or End Of Span.
Start Of Span
When active the M Code is Executed before axis motion.
End Of Span
When active the M Code is Executed after axis motion.
Signal
Only one selection is active, either Normally On, or Normally Off.
Normally On
When active the M Code output contact is opened.
Normally Off
When active the M Code output contact is closed.
Pulse Width
If M Code is pulsed selected, this value is the width of the output.
Time Before Alarm
This value (in seconds) is the time waiting for feedback, after which an alarm is reported.
A2100Di Programming Manual
Publication 91204426-001
8
Chapter 15
May 2002