FANUC Series 30*/300*/300*
FANUC Series 31*/310*/310*s-MODEL A5
FANUC Series 31*/310*/310*s-MODEL A
FANUC Series 32*/320*/320*s-MODEL A
MODEL A
Common to Lathe System/Machining Center System
USER’S MANUAL
(Volume 1 of 2)
B-63944EN/02
Page 2
• No part of this manual may be reproduced in any form.
• All specifications and designs are subject to change without notice.
The export of this product is subject to the authorization of the government of the country
from where the product is exported.
In this manual we have tried as much as possible to describe all the various matters.
However, we cannot describe all the matters which must not be done, or which cannot be
done, because there are so many possibilities.
Therefore, matters which are not especially described as possible in this manual should be
regarded as ”impossible”.
This manual contains the program names or device names of other companies, some of
which are registered trademarks of respective owners. However, these names are not
followed by or in the main body.
Page 3
B-63944EN/02 SAFETY PRECAUTIONS
SAFETY PRECAUTIONS
This section describes the safety precautions related to the use of CNC
units.
It is essential that these precautions be observed by users to ensure the
safe operation of machines equipped with a CNC unit (all descriptions
in this section assume this configuration). Note that some precautions
are related only to specific functions, and thus may not be applicable
to certain CNC units.
Users must also observe the safety precautions related to the machine,
as described in the relevant manual supplied by the machine tool
builder. Before attempting to operate the machine or create a program
to control the operation of the machine, the operator must become
fully familiar with the contents of this manual and relevant manual
supplied by the machine tool builder.
CONTENTS
1.1 DEFINITION OF WARNING, CAUTION, AND NOTE ........s-2
1.2 GENERAL WARNINGS AND CAUTIONS ...........................s-3
1.5 WARNINGS RELATED TO DAILY MAINTENANCE....... s-12
s-1
Page 4
SAFETY PRECAUTIONSB-63944EN/02
1.1 DEFINITION OF WARNING, CAUTION, AND NOTE
This manual includes safety precautions for protecting the user and
preventing damage to the machine. Precautions are classified into
Warning and Caution according to their bearing on safety. Also,
supplementary information is described as a Note. Read the
Warning, Caution, and Note thoroughly before attempting to use
the machine.
WARNING
Applied when there is a danger of the user being
injured or when there is a danger of both the user
being injured and the equipment being damaged if
the approved procedure is not observed.
CAUTION
Applied when there is a danger of the equipment
being damaged, if the approved procedure is not
observed.
NOTE
The Note is used to indicate supplementary
information other than Warning and Caution.
•Read this manual carefully, and store it in a safe place.
s-2
Page 5
B-63944EN/02 SAFETY PRECAUTIONS
1.2 GENERAL WARNINGS AND CAUTIONS
WARNING
1 Never attempt to machine a workpiece without first
checking the operation of the machine. Before
starting a production run, ensure that the machine
is operating correctly by performing a trial run
using, for example, the single block, feedrate
override, or machine lock function or by operating
the machine with neither a tool nor workpiece
mounted. Failure to confirm the correct operation
of the machine may result in the machine behaving
unexpectedly, possibly causing damage to the
workpiece and/or machine itself, or injury to the
user.
2 Before operating the machine, thoroughly check
the entered data.
Operating the machine with incorrectly specified
data may result in the machine behaving
unexpectedly, possibly causing damage to the
workpiece and/or machine itself, or injury to the
user.
3 Ensure that the specified feedrate is appropriate
for the intended operation. Generally, for each
machine, there is a maximum allowable feedrate.
The appropriate feedrate varies with the intended
operation. Refer to the manual provided with the
machine to determine the maximum allowable
feedrate.
If a machine is run at other than the correct speed,
it may behave unexpectedly, possibly causing
damage to the workpiece and/or machine itself, or
injury to the user.
4 When using a tool compensation function,
thoroughly check the direction and amount of
compensation.
Operating the machine with incorrectly specified
data may result in the machine behaving
unexpectedly, possibly causing damage to the
workpiece and/or machine itself, or injury to the
user.
s-3
Page 6
SAFETY PRECAUTIONSB-63944EN/02
WARNING
5 The parameters for the CNC and PMC are
factory-set. Usually, there is not need to change
them. When, however, there is not alternative other
than to change a parameter, ensure that you fully
understand the function of the parameter before
making any change.
Failure to set a parameter correctly may result in
the machine behaving unexpectedly, possibly
causing damage to the workpiece and/or machine
itself, or injury to the user.
6 Immediately after switching on the power, do not
touch any of the keys on the MDI panel until the
position display or alarm screen appears on the
CNC unit.
Some of the keys on the MDI panel are dedicated
to maintenance or other special operations.
Pressing any of these keys may place the CNC
unit in other than its normal state. Starting the
machine in this state may cause it to behave
unexpectedly.
7 The User’s Manual and programming manual
supplied with a CNC unit provide an overall
description of the machine's functions, including
any optional functions. Note that the optional
functions will vary from one machine model to
another. Therefore, some functions described in
the manuals may not actually be available for a
particular model. Check the specification of the
machine if in doubt.
8 Some functions may have been implemented at
the request of the machine-tool builder. When
using such functions, refer to the manual supplied
by the machine-tool builder for details of their use
and any related cautions.
CAUTION
The liquid-crystal display is manufactured with very
precise fabrication technology. Some pixels may
not be turned on or may remain on. This
phenomenon is a common attribute of LCDs and is
not a defect.
s-4
Page 7
B-63944EN/02 SAFETY PRECAUTIONS
NOTE
Programs, parameters, and macro variables are
stored in nonvolatile memory in the CNC unit.
Usually, they are retained even if the power is
turned off.
Such data may be deleted inadvertently, however,
or it may prove necessary to delete all data from
nonvolatile memory as part of error recovery.
To guard against the occurrence of the above, and
assure quick restoration of deleted data, backup all
vital data, and keep the backup copy in a safe
place.
s-5
Page 8
SAFETY PRECAUTIONSB-63944EN/02
1.3 WARNINGS AND CAUTIONS RELATED TO
PROGRAMMING
This section covers the major safety precautions related to
programming. Before attempting to perform programming, read the
supplied User’s Manual carefully such that you are fully familiar with
their contents.
WARNING
1 Coordinate system settingIf a coordinate system is established incorrectly,
the machine may behave unexpectedly as a result
of the program issuing an otherwise valid move
command. Such an unexpected operation may
damage the tool, the machine itself, the workpiece,
or cause injury to the user.
2 Positioning by nonlinear interpolationWhen performing positioning by nonlinear
interpolation (positioning by nonlinear movement
between the start and end points), the tool path
must be carefully confirmed before performing
programming. Positioning involves rapid traverse. If
the tool collides with the workpiece, it may damage
the tool, the machine itself, the workpiece, or
cause injury to the user.
3 Function involving a rotation axisWhen programming polar coordinate interpolation
or normal-direction (perpendicular) control, pay
careful attention to the speed of the rotation axis.
Incorrect programming may result in the rotation
axis speed becoming excessively high, such that
centrifugal force causes the chuck to lose its grip
on the workpiece if the latter is not mounted
securely. Such mishap is likely to damage the tool,
the machine itself, the workpiece, or cause injury to
the user.
4 Inch/metric conversionSwitching between inch and metric inputs does not
convert the measurement units of data such as the
workpiece origin offset, parameter, and current
position. Before starting the machine, therefore,
determine which measurement units are being
used. Attempting to perform an operation with
invalid data specified may damage the tool, the
machine itself, the workpiece, or cause injury to the
user.
s-6
Page 9
B-63944EN/02 SAFETY PRECAUTIONS
WARNING
5 Constant surface speed controlWhen an axis subject to constant surface speed
control approaches the origin of the workpiece
coordinate system, the spindle speed may become
excessively high. Therefore, it is necessary to
specify a maximum allowable speed. Specifying
the maximum allowable speed incorrectly may
damage the tool, the machine itself, the workpiece,
or cause injury to the user.
6 Stroke checkAfter switching on the power, perform a manual
reference position return as required. Stroke check
is not possible before manual reference position
return is performed. Note that when stroke check is
disabled, an alarm is not issued even if a stroke
limit is exceeded, possibly damaging the tool, the
machine itself, the workpiece, or causing injury to
the user.
7 Tool post interference checkA tool post interference check is performed based
on the tool data specified during automatic
operation. If the tool specification does not match
the tool actually being used, the interference check
cannot be made correctly, possibly damaging the
tool or the machine itself, or causing injury to the
user. After switching on the power, or after
selecting a tool post manually, always start
automatic operation and specify the tool number of
the tool to be used.
8 Absolute/incremental modeIf a program created with absolute values is run in
incremental mode, or vice versa, the machine may
behave unexpectedly.
9 Plane selectionIf an incorrect plane is specified for circular
interpolation, helical interpolation, or a canned
cycle, the machine may behave unexpectedly.
Refer to the descriptions of the respective
functions for details.
10 Torque limit skipBefore attempting a torque limit skip, apply the
torque limit. If a torque limit skip is specified
without the torque limit actually being applied, a
move command will be executed without
performing a skip.
s-7
Page 10
SAFETY PRECAUTIONSB-63944EN/02
WARNING
11 Programmable mirror imageNote that programmed operations vary
considerably when a programmable mirror image is
enabled.
12 Compensation functionIf a command based on the machine coordinate
system or a reference position return command is
issued in compensation function mode,
compensation is temporarily canceled, resulting in
the unexpected behavior of the machine.
Before issuing any of the above commands,
therefore, always cancel compensation function
mode.
s-8
Page 11
B-63944EN/02 SAFETY PRECAUTIONS
1.4 WARNINGS AND CAUTIONS RELATED TO
HANDLING
This section presents safety precautions related to the handling of
machine tools. Before attempting to operate your machine, read the
supplied User’s Manual carefully, such that you are fully familiar with
their contents.
WARNING
1 Manual operationWhen operating the machine manually, determine
the current position of the tool and workpiece, and
ensure that the movement axis, direction, and
feedrate have been specified correctly. Incorrect
operation of the machine may damage the tool, the
machine itself, the workpiece, or cause injury to the
operator.
2 Manual reference position returnAfter switching on the power, perform manual
reference position return as required.
If the machine is operated without first performing
manual reference position return, it may behave
unexpectedly. Stroke check is not possible before
manual reference position return is performed.
An unexpected operation of the machine may
damage the tool, the machine itself, the workpiece,
or cause injury to the user.
3 Manual numeric commandWhen issuing a manual numeric command,
determine the current position of the tool and
workpiece, and ensure that the movement axis,
direction, and command have been specified
correctly, and that the entered values are valid.
Attempting to operate the machine with an invalid
command specified may damage the tool, the
machine itself, the workpiece, or cause injury to the
operator.
4 Manual handle feedIn manual handle feed, rotating the handle with a
large scale factor, such as 100, applied causes the
tool and table to move rapidly. Careless handling
may damage the tool and/or machine, or cause
injury to the user.
s-9
Page 12
SAFETY PRECAUTIONSB-63944EN/02
WARNING
5 Disabled overrideIf override is disabled (according to the
specification in a macro variable) during threading,
rigid tapping, or other tapping, the speed cannot be
predicted, possibly damaging the tool, the machine
itself, the workpiece, or causing injury to the
operator.
6 Origin/preset operationBasically, never attempt an origin/preset operation
when the machine is operating under the control of
a program. Otherwise, the machine may behave
unexpectedly, possibly damaging the tool, the
machine itself, the tool, or causing injury to the
user.
7 Workpiece coordinate system shiftManual intervention, machine lock, or mirror
imaging may shift the workpiece coordinate
system. Before attempting to operate the machine
under the control of a program, confirm the
coordinate system carefully.
If the machine is operated under the control of a
program without making allowances for any shift in
the workpiece coordinate system, the machine
may behave unexpectedly, possibly damaging the
tool, the machine itself, the workpiece, or causing
injury to the operator.
8 Software operator's panel and menu switchesUsing the software operator's panel and menu
switches, in combination with the MDI panel, it is
possible to specify operations not supported by the
machine operator's panel, such as mode change,
override value change, and jog feed commands.
Note, however, that if the MDI panel keys are
operated inadvertently, the machine may behave
unexpectedly, possibly damaging the tool, the
machine itself, the workpiece, or causing injury to
the user.
9 RESET key Pressing the RESET key stops the currently
running program. As a result, the servo axes are
stopped. However, the RESET key may fail to
function for reasons such as an MDI panel
problem. So, when the motors must be stopped,
use the emergency stop button instead of the
RESET key to ensure security.
s-10
Page 13
B-63944EN/02 SAFETY PRECAUTIONS
WARNING
10 Manual interventionIf manual intervention is performed during
programmed operation of the machine, the tool
path may vary when the machine is restarted.
Before restarting the machine after manual
intervention, therefore, confirm the settings of the
manual absolute switches, parameters, and
absolute/incremental command mode.
11 Feed hold, override, and single blockThe feed hold, feedrate override, and single block
functions can be disabled using custom macro
system variable #3004. Be careful when operating
the machine in this case.
12 Dry runUsually, a dry run is used to confirm the operation
of the machine. During a dry run, the machine
operates at dry run speed, which differs from the
corresponding programmed feedrate. Note that the
dry run speed may sometimes be higher than the
programmed feed rate.
13 Cutter and tool nose radius compensation in
MDI modePay careful attention to a tool path specified by a
command in MDI mode, because cutter or tool
nose radius compensation is not applied. When a
command is entered from the MDI to interrupt in
automatic operation in cutter or tool nose radius
compensation mode, pay particular attention to the
tool path when automatic operation is subsequently
resumed. Refer to the descriptions of the
corresponding functions for details.
14 Program editingIf the machine is stopped, after which the
machining program is edited (modification,
insertion, or deletion), the machine may behave
unexpectedly if machining is resumed under the
control of that program. Basically, do not modify,
insert, or delete commands from a machining
program while it is in use.
s-11
Page 14
SAFETY PRECAUTIONSB-63944EN/02
1.5 WARNINGS RELATED TO DAILY MAINTENANCE
WARNING
1 Memory backup battery replacementWhen replacing the memory backup batteries,
keep the power to the machine (CNC) turned on,
and apply an emergency stop to the machine.
Because this work is performed with the power on
and the cabinet open, only those personnel who
have received approved safety and maintenance
training may perform this work.
When replacing the batteries, be careful not to
touch the high-voltage circuits (marked
fitted with an insulating cover).
Touching the uncovered high-voltage circuits
presents an extremely dangerous electric shock
hazard.
NOTE
The CNC uses batteries to preserve the contents
of its memory, because it must retain data such as
programs, offsets, and parameters even while
external power is not applied.
If the battery voltage drops, a low battery voltage
alarm is displayed on the machine operator's panel
or screen.
When a low battery voltage alarm is displayed,
replace the batteries within a week. Otherwise, the
contents of the CNC's memory will be lost.
Refer to the Section “Method of replacing battery”
I. GENERAL
Describes chapter organization, applicable models, related
manuals, and notes for reading this manual.
II. PROGRAMMING
Describes each function: Format used to program functions in the
NC language, explanations, and limitations.
III. OPERATION
Describes the manual operation and automatic operation of a
machine, procedures for inputting and outputting data, and
procedures for editing a program.
IV. MAINTENANCE
Describes procedures for daily maintenance and replacing
batteries.
APPENDIX
Lists parameters, valid data ranges, and alarms.
NOTE
1 This manual describes the functions common to
the lathe system and machining center system.
For the functions specific to the lathe system or
machining center system, refer to the User's
Manual (T series) (B-63944EN-1) or the User's
Manual (M series) (B-63944EN-2).
2 Some functions described in this manual may not
be applied to some products. For detail, refer to the
Descriptions manual (B-63942EN).
3 This manual does not detail the parameters not
mentioned in the text. For details of those
parameters, refer to the Parameter Manual (B63950EN).
Parameters are used to set functions and operating
conditions of a CNC machine tool, and frequentlyused values in advance. Usually, the machine tool
builder factory-sets parameters so that the user
can use the machine tool easily.
4 This manual describes not only basic functions but
also optional functions. Look up the options
incorporated into your system in the manual written
by the machine tool builder.
- 3 -
Page 38
1.GENERAL GENERAL B-63944EN/02
Applicable models
This manual describes the models indicated in the table below.
In the text, the abbreviations indicated below may be used.
Model name Abbreviation
FANUC Series 30i-MODEL A 30i –A Series 30i
FANUC Series 300i-MODEL A 300i–A Series 300i
FANUC Series 300is-MODEL A 300is–A Series 300is
FANUC Series 31i-MODEL A 31i –A
FANUC Series 31i-MODEL A5 31i –A5
FANUC Series 310i-MODEL A 310i–A
FANUC Series 310i-MODEL A5 310i–A5
FANUC Series 310is-MODEL A 310is–A
FANUC Series 310is-MODEL A5 310is–A5
FANUC Series 32i-MODEL A 32i –A Series 32i
FANUC Series 320i-MODEL A 320i–A Series 320i
FANUC Series 320is-MODEL A 320is–A Series 320is
NOTE
1 For an explanatory purpose, the following
descriptions may be used according to the types of
path control used:
- T series: For the lathe system
- M series: For the machining center system
2 Unless otherwise noted, the model names
31i/310i/310is-A, 31i/310i/310is-A5, and
32i/320i/320is-A are collectively referred to as
30i/300i/300is. However, this convention is not
necessarily observed when item 3 below is
applicable.
3 Some functions described in this manual may not
be applied to some products.
For details, refer to the DESCRIPTIONS (B-
63942EN).
Series 31i
Series 310i
Series 310is
- 4 -
Page 39
B-63944EN/02 GENERAL 1.GENERAL
Special symbols
This manual uses the following symbols:
M
-
T
-
-
- IP
- ;
Indicates a description that is valid only for the machine center system
set as system control type (in parameter No. 0983).
In a general description of the method of machining, a machining
center system operation is identified by a phase such as "for milling
machining".
Indicates a description that is valid only for the lathe system set as
system control type (in parameter No. 0983).
In a general description of the method of machining, a lathe system
operation is identified by a phrase such as "for lathe cutting".
Indicates the end of a description of a system control type.
When a system control type mark mentioned above is not followed by
this mark, the description of the system control type is assumed to
continue until the next item or paragraph begins. In this case, the next
item or paragraph provides a description common to the control types.
Indicates a combination of axes such as X_ Y_ Z_
In the underlined position following each address, a numeric value
such as a coordinate value is placed (used in PROGRAMMING.).
Indicates the end of a block. It actually corresponds to the ISO code
LF or EIA code CR.
- 5 -
Page 40
1.GENERAL GENERAL B-63944EN/02
Related manuals of
Series 30i/300i/300is- MODEL A
Series 31i/310i/310is- MODEL A
Series 31i/310i/310is- MODEL A5
Series 32i/320i/320is- MODEL A
The following table lists the manuals related to Series 30i/300i /300is-
A, Series 31i/310i /310is-A, Series 31i/310i /310is-A5, Series
32i/320i /320is-A. This manual is indicated by an asterisk(*).
Table 1 Related manuals
Manual name Specification
number
DESCRIPTIONS B-63942EN
CONNECTION MANUAL (HARDWARE) B-63943EN
CONNECTION MANUAL (FUNCTION) B-63943EN-1
USER’S MANUAL
(Common to Lathe System/Machining Center System)
USER’S MANUAL (For Lathe System) B-63944EN-1
USER’S MANUAL (For Lathe Machining Center System) B-63944EN-2
MAINTENANCE MANUAL B-63945EN
PARAMETER MANUAL B-65950EN
Programming
Macro Compiler / Macro Executor PROGRAMMING
MANUAL
Macro Compiler OPERATOR’S MANUAL B-66264EN
C Language Executor OPERATOR’S MANUAL B-63944EN-3
PMC
PMC PROGRAMMING MANUAL B-63983EN
Network
PROFIBUS-DP Board OPERATOR’S MANUAL B-63994EN
Fast Ethernet / Fast Data Server OPERATOR’S MANUAL B-64014EN
DeviceNet Board OPERATOR’S MANUAL B-64044EN
Operation guidance function
MANUAL GUIDE i OPERATOR’S MANUAL
MANUAL GUIDE i Set-up Guidance
OPERATOR’S MANUAL
B-63944EN *
B-63943EN-2
B-63874EN
B-63874EN-1
- 6 -
Page 41
B-63944EN/02 GENERAL 1.GENERAL
Related manuals of SERVO MOTOR αis/αi/βis/βi series
The following table lists the manuals related to SERVO MOTOR
αis/αi/βis/βi series
Table 2 Related manuals
Manual name
FANUC AC SERVO MOTOR αis series
FANUC AC SERVO MOTOR αi series
DESCRIPTIONS
FANUC AC SPINDLE MOTOR αi series
DESCRIPTIONS
FANUC AC SERVO MOTOR βis series
DESCRIPTIONS
FANUC AC SPINDLE MOTOR βi series
DESCRIPTIONS
FANUC SERVO AMPLIFIER αi series
DESCRIPTIONS
FANUC SERVO AMPLIFIER βi series
DESCRIPTIONS
FANUC SERVO MOTOR αis series
FANUC SERVO MOTOR αi series
FANUC AC SPINDLE MOTOR αi series
FANUC SERVO AMPLIFIER αi series
MAINTENANCE MANUAL
FANUC SERVO MOTOR βis series
FANUC AC SPINDLE MOTOR βi series
FANUC SERVO AMPLIFIER βi series
MAINTENANCE MANUAL
FANUC AC SERVO MOTOR αis series
FANUC AC SERVO MOTOR αi series
FANUC AC SERVO MOTOR βis series
PARAMETER MANUAL
FANUC AC SPINDLE MOTOR αi series
FANUC AC SPINDLE MOTOR βi series
PARAMETER MANUAL
Any of the servo motors and spindles listed above can be connected to
the CNC described in this manual. However, αi series servo amplifiers
can only be connected to αi series SVMs (for 30i/31i/32i).
This manual mainly assumes that the FANUC SERVO MOTOR αi
series of servo motor is used. For servo motor and spindle information,
refer to the manuals for the servo motor and spindle that are actually
connected.
Specification
number
B-65262EN
B-65272EN
B-65302EN
B-65312EN
B-65282EN
B-65322EN
B-65285EN
B-65325EN
B-65270EN
B-65280EN
- 7 -
Page 42
1.GENERAL GENERAL B-63944EN/02
1.1 NOTES ON READING THIS MANUAL
CAUTION
1 The function of an CNC machine tool system
depends not only on the CNC, but on the
combination of the machine tool, its magnetic
cabinet, the servo system, the CNC, the operator's
panels, etc. It is too difficult to describe the function,
programming, and operation relating to all
combinations. This manual generally describes these
from the stand-point of the CNC. So, for details on a
particular CNC machine tool, refer to the manual
issued by the machine tool builder, which should take
precedence over this manual.
2 In the header field of each page of this manual, a
chapter title is indicated so that the reader can
reference necessary information easily.
By finding a desired title first, the reader can
reference necessary parts only.
3 This manual describes as many reasonable variations
in equipment usage as possible. It cannot address
every combination of features, options and commands
that should not be attempted.
If a particular combination of operations is not
described, it should not be attempted.
1.2 NOTES ON VARIOUS KINDS OF DATA
CAUTION
Machining programs, parameters, offset data, etc.
are stored in the CNC unit internal non-volatile
memory. In general, these contents are not lost by
the switching ON/OFF of the power. However, it is
possible that a state can occur where precious data
stored in the non-volatile memory has to be deleted,
because of deletions from a maloperation, or by a
failure restoration. In order to restore rapidly when
this kind of mishap occurs, it is recommended that
you create a copy of the various kinds of data
beforehand.
- 8 -
Page 43
II. PROGRAMMING
Page 44
Page 45
B-63944EN/02 PROGRAMMING 1.GENERAL
1 GENERAL
- 11 -
Page 46
1.GENERALPROGRAMMINGB-63944EN/02
X
1.1 TOOL MOVEMENT ALONG WORKPIECE PARTS FIGURE-
INTERPOLATION
The tool moves along straight lines and arcs constituting the
workpiece parts figure (See II-4).
Explanation
The function of moving the tool along straight lines and arcs is called
the interpolation.
- Tool movement along a straight line
• For milling machining
• For lathe cutting
Workpiece
Fig. 1.1 (a) Tool movement along a straight line
Workpiece
Tool
To ol
Program
G01X_Y_ ;
X_ ;
Program
G01Z_ ;
G01X_Z_ ;
Z
- 12 -
Page 47
B-63944EN/02 PROGRAMMING 1.GENERAL
X
- Tool movement along an arc
• For milling machining
Program
G03 X_ Y_ R_ ;
Workpiece
Tool
• For lathe cutting
Program
G02 X_ Z_ R_ ;
or
G03 X_ Z_ R_ ;
Workpiece
Fig. 1.1 (b) Tool movement along an arc
Z
The term interpolation refers to an operation in which the tool moves
along a straight line or arc in the way described above.
Symbols of the programmed commands G01, G02, ... are called the
preparatory function and specify the type of interpolation conducted in
the control unit.
(a) Movement along straight line
G01 Y_ ;
X_ Y_ ;
CNC
(b) Movement along arc
G03X_ Y_ R_ ;
X axis
Interpolation
Y axis
a)Movement
along straight
line
b)Movement
along arc
Fig. 1.1 (c) Interpolation function
Tool
movement
NOTE
Some machines move tables instead of tools but
this manual assumes that tools are moved against
workpieces.
- 13 -
Page 48
1.GENERALPROGRAMMINGB-63944EN/02
1.2 FEED-FEED FUNCTION
Movement of the tool at a specified speed for cutting a workpiece is
called the feed.
• For milling machining
mm/min
F
Workpiece
Table
Tool
• For lathe cutting
mm/min
F
Workpiece
Chuck
Fig. 1.2 (a) Feed function
Tool
Feedrates can be specified by using actual numerics. For example, to
feed the tool at a rate of 150 mm/min, specify the following in the
program:
F150.0
The function of deciding the feed rate is called the feed function (See
II-5).
- 14 -
Page 49
B-63944EN/02 PROGRAMMING 1.GENERAL
1.3 PART DRAWING AND TOOL MOVEMENT
1.3.1 Reference Position (Machine-specific Position)
A CNC machine tool is provided with a fixed position. Normally, tool
change and programming of absolute zero point as described later are
performed at this position. This position is called the reference
position.
• For milling machining
Reference position
Tool
Workpiece
Explanation
Table
• For lathe cutting
Tool post
Chuck
Fig. 1.3.1 (a) Reference position
Reference
position
The tool can be moved to the reference position in two ways:
1. Manual reference position return (See III-3.1)
Reference position return is performed by manual button
operation.
2. Automatic reference position return (See II-6)
In general, manual reference position return is performed first
after the power is turned on. In order to move the tool to the
reference position for tool change thereafter, the function of
automatic reference position return is used.
- 15 -
Page 50
1.GENERALPROGRAMMINGB-63944EN/02
X
y
1.3.2 Coordinate System on Part Drawing and Coordinate System
Specified by CNC - Coordinate System
• For milling machining
Z
Y
Part drawing
• For lathe cutting
Program
X
Tool
Z
Workpiece
Machine tool
Z
Y
Coordinate system
CNC
Command
Tool
Y
X
X
Part drawing
X
Program
Z
Coordinate s
Command
X
Workpiece
Z
Machine tool
Fig. 1.3.2 (a) Coordinate system
Z
stem
CNC
- 16 -
Page 51
B-63944EN/02 PROGRAMMING 1.GENERAL
Explanation
- Coordinate system
The following two coordinate systems are specified at different
locations: (See II-7)
1 Coordinate system on part drawing
The coordinate system is written on the part drawing. As the
program data, the coordinate values on this coordinate system are
used.
2. Coordinate system specified by the CNC
The coordinate system is prepared on the actual machine tool
table. This can be achieved by programming the distance from
the current position of the tool to the zero point of the coordinate
system to be set.
Y
230
300
Program
origin
Fig. 1.3.2 (b) Coordinate system specified by the CNC
Present tool position
Distance to the zero point of a coordinate system to be set
X
Concrete programming methods for setting coordinate systems
specified by the CNC are explained in II-7, "COORDINATE
SYSTEM".
- 17 -
Page 52
1.GENERALPROGRAMMINGB-63944EN/02
The positional relation between these two coordinate systems is
determined when a workpiece is set on the table.
• For milling machining
Coordinate system on
part drawing estab
Coordinate system
specified by the CNC
established on the table
• For lathe cutting
Table
Y
Y
Workpiece
lished on the workpiece
X
X
Coordinate system specified by the
CNC established on the chuck
X
Workpiece
Z
Chuck
Fig. 1.3.2 (c) Coordinate system specified by CNC and coordinate
system on part drawing
Coordinate system on part drawing
established on the workpiece
X
Z
The tool moves on the coordinate system specified by the CNC in
accordance with the command program generated with respect to the
coordinate system on the part drawing, and cuts a workpiece into a
shape on the drawing.
Therefore, in order to correctly cut the workpiece as specified on the
drawing, the two coordinate systems must be set at the same position.
- 18 -
Page 53
B-63944EN/02 PROGRAMMING 1.GENERAL
A
- Methods of setting the two coordinate systems in the same position
M
To set the two coordinate systems at the same position, simple
methods shall be used according to workpiece shape, the number of
machinings.
1. Using a standard plane and point of the workpiece.
Y
Fixed distance
Program
origin
Bring the tool center to the workpiece standard point.
nd set the coordinate system specified by CNC at this position.
Workpiece's
standard point
Fixed distance
X
2. Mounting a workpiece directly against the jig
Program origin
Jig
Meet the tool center to the reference position. And set the coordinate
specified by CNC at this position. (Jig shall be mounted on the
point from the reference
3. Mounting a workpiece on a pallet, then mounting the workpiece
and pallet on the jig
Pallet
Jig
Workpiece
(Jig and coordinate system shall be specified by the same as (2)).
- 19 -
Page 54
1.GENERALPROGRAMMINGB-63944EN/02
X
p
T
The following method is usually used to define two coordinate
systems at the same location.
1 When coordinate zero point is set at chuck face
- Coordinates and
dimensions on part drawing
- Coordinate system on
lathe as s
ecified by CNC
Workpiece
6040
40
150
X
Chuck
Workpiece
Program origin
Z
Z
When the coordinate system on the part drawing and the coordinate
system specified by the CNC are set at the same position, the program
origin can be set on the chuck face.
- 20 -
Page 55
B-63944EN/02 PROGRAMMING 1.GENERAL
p
2. When coordinate zero point is set at workpiece end face.
- Coordinates and
dimensions on part drawing
60
Workpiece
80
100
X
30
Z
30
- Coordinate system on
lathe as s
ecified by CNC
Chuck
Workpiece
X
Z
Program origin
When the coordinate system on the part drawing and the coordinate
system specified by the CNC are set at the same position, the program
origin can be set on the end face of the workpiece.
- 21 -
Page 56
1.GENERALPROGRAMMINGB-63944EN/02
A
X
φ30A
1.3.3 How to Indicate Command Dimensions for Moving the Tool
(Absolute, Incremental Commands)
Explanation
Command for moving the tool can be indicated by absolute command
or incremental command (See II-8.1).
- Absolute command
The tool moves to a point at "the distance from zero point of the
coordinate system" that is to the position of the coordinate values.
• For milling machining
Z
X
Command specifying movement from
point A to point B
• For lathe cutting
X
Tool
Y
B(10.0,30.0,5.0)
G90 X10.0 Y30.0 Z5.0 ;
Coordinates of point B
Tool
Workpiece
70
Command specifying movement from point A to
point B
B
Z
110
30.0Z70.0;
Coordinates of point B
- 22 -
Page 57
B-63944EN/02 PROGRAMMING 1.GENERAL
A
φ30A
A
- Incremental command
Specify the distance from the previous tool position to the next tool
position.
• For milling machining
Z
Tool
X
B
Command specifying movement from
point A to point B
• For lathe cutting
X
Workpiece
Y-30.0
B
X=40.0
Y
Z=-10.0
G91 X40.0 Y-30.0 Z-10.0 ;
Distance and direction for
movement along each axis
Tool
-30.0 (diameter value)
φ60
Z
-40.0
Command specifying movement from point
to point B
U-30.0 W-40.0
Distance and direction for movement
along each axis
- 23 -
Page 58
1.GENERALPROGRAMMINGB-63944EN/02
φ30ABφ
A
- Diameter programming / radius programming
Dimensions of the X axis can be set in diameter or in radius. Diameter
programming or radius programming is employed independently in
each machine.
1. Diameter programming
In diameter programming, specify the diameter value indicated
on the drawing as the value of the X axis.
X
Workpiece
40
60
80
Z
Coordinate values of points A and B A(30.0, 80.0), B(40.0, 60.0)
2. Radius programming
In radius programming, specify the distance from the center of
the workpiece, i.e. the radius value as the value of the X axis.
X
B
60
20
15
Z
80
Workpiece
Coordinate values of points A and B A(15.0, 80.0), B(20.0, 60.0)
- 24 -
Page 59
B-63944EN/02 PROGRAMMING 1.GENERAL
φ
1.4 CUTTING SPEED - SPINDLE FUNCTION
The speed of the tool with respect to the workpiece when the
workpiece is cut is called the cutting speed.
As for the CNC, the cutting speed can be specified by the spindle
speed in min
• For milling machining
<When a workpiece should be machined with a tool 100 mm in
diameter at a cutting speed of 80 m/min.>
The spindle speed is approximately 250 min
N=1000v/πD. Hence the following command is required:
S250;
Commands related to the spindle speed are called the spindle speed
function ( See II-9) .
•For lathe cutting
-1
unit.
Spindle speed N
min
-1
Tool
Workpiece
Tool diameter
D mm
V: Cutting speed
m/min
-1
, which is obtained from
To ol
Cutting speed
v m/min
Workpiece
Spindle speed
φD
N min
-1
<When a workpiece 200 mm in diameter should be machined at a
cutting speed of 300 m/min.>
The spindle speed is approximately 478 min
-1
, which is obtained from
N=1000v/πD. Hence the following command is required:
S478 ;
Commands related to the spindle speed are called the spindle speed
function (See II-9).
The cutting speed v (m/min) can also be specified directly by the
speed value. Even when the workpiece diameter is changed, the CNC
changes the spindle speed so that the cutting speed remains constant.
This function is called the constant surface speed control function (See
II-9.3).
- 25 -
Page 60
1.GENERALPROGRAMMINGB-63944EN/02
A
1.5 SELECTION OF TOOL USED FOR VARIOUS MACHINING -
TOOL FUNCTION
Overview
For each of various types of machining (such as drilling, tapping,
boring, and milling for milling machining, or rough machining,
semifinish machining, finish machining, threading, and grooving for
lathe cutting), a necessary tool is to be selected. When a number is
assigned to each tool and the number is specified in the program, the
corresponding tool is selected.
Examples
M
Tool number
01
02
TC magazine
Fig. 1.5 (a) Tool used for various machining
<When No.01 is assigned to a drilling tool>
When the tool is stored at location 01 in the ATC magazine, the tool
can be selected by specifying T01. This is called the tool function (See
II-10).
T
Tool number
01
06
02
03
Fig. 1.5 (b) Tool used for various machining
05
04
Tool post
<When No.01 is assigned to a roughing tool>
When the tool is stored at location 01 of the tool post, the tool can be
selected by specifying T0101. This is called the tool function (See II-
10).
- 26 -
Page 61
B-63944EN/02 PROGRAMMING 1.GENERAL
1.6 COMMAND FOR MACHINE OPERATIONS - AUXILIARY
FUNCTION
When a workpiece is actually machined with a tool, the spindle is
rotated, coolant is supplied, and the chuck is opened/closed. So,
control needs to be exercised on the spindle motor of the machine,
coolant valve on/off operation, and chuck open/close operation.
• For milling machining
Tool
Spindle
rotation
Coolant on/off
Workpiece
• For lathe cutting
Coolant on/off
Chuck open/close
Workpiece
Fig. 1.6 (a) Auxiliary function
Spindle rotation
The function of specifying the on-off operations of the components of
the machine is called the auxiliary function. In general, the function is
specified by an M code (See II-11).
For example, when M03 is specified, the spindle is rotated clockwise
at the specified spindle speed.
- 27 -
Page 62
1.GENERALPROGRAMMINGB-63944EN/02
1.7 PROGRAM CONFIGURATION
A group of commands given to the CNC for operating the machine is
called the program. By specifying the commands, the tool is moved
along a straight line or an arc, or the spindle motor is turned on and off.
In the program, specify the commands in the sequence of actual tool
movements.
Block
Block
Tool movement
Block
sequence
Program
Fig. 1.7 (a) Program configuration
Block
:
:
:
:
Block
A group of commands at each step of the sequence is called the block.
The program consists of a group of blocks for a series of machining.
The number for discriminating each block is called the sequence
number, and the number for discriminating each program is called the
program number (See II-13).
- 28 -
Page 63
B-63944EN/02 PROGRAMMING 1.GENERAL
A
Explanation
The block and the program have the following configurations.
- Block
1 block
Nxxxxx Gxx Xxxx.x Yxxx.x Mxx Sxx Txx ;
- Program
Sequence
number
Preparatory
function
Dimension word
uxiliary
function
Spindle
function
Tool
function
End of block
Fig. 1.7 (b) Block configuration
A block starts with a sequence number to identify the block and ends
with an end-of-block code.
This manual indicates the end-of-block code by ; (LF in the ISO code
and CR in the EIA code).
The contents of the dimension word depend on the preparatory
function. In this manual, the portion of the dimension word may be
represent as IP_.
;
xxxxx ;
Program number
Block
Block
Block
:
:
:
M30 ;
Fig. 1.7 (c) Program configuration
:
:
:
End of program
Normally, a program number is specified after the end-of-block (;)
code at the beginning of the program, and a program end code (M02
or M30) is specified at the end of the program.
- 29 -
Page 64
1.GENERALPROGRAMMINGB-63944EN/02
- Main program and subprogram
When machining of the same pattern appears at many portions of a
program, a program for the pattern is created. This is called the
subprogram. On the other hand, the original program is called the
main program. When a subprogram execution command appears
during execution of the main program, commands of the subprogram
are executed. When execution of the subprogram is finished, the
sequence returns to the main program.
Main program
:
:
M98P1001
:
:
:
Subprogram #1
O1001
M98P1002
:
:
M98P1001
:
:
:
M99
Subprogram #2
O1002
M99
Fig. 1.7 (d) Subprogram execution
- 30 -
Page 65
B-63944EN/02 PROGRAMMING 1.GENERAL
1.8 TOOL MOVEMENT RANGE - STROKE
Limit switches are installed at the ends of each axis on the machine to
prevent tools from moving beyond the ends. The range in which tools
can move is called the stroke.
Machine zero point
Motor
Limit
switch
Stroke a rea
Besides strokes defined with limit switches, the operator can define an
area which the tool cannot enter using a program or data in memory.
This function is called stroke check (see III-6.3).
- 31 -
Page 66
1.GENERALPROGRAMMINGB-63944EN/02
y
Motor
Limit
switch
Machine zero point
Specif
these distances.
Tools cannot enter this area. The
area is specified by data in memory
or a program.
- 32 -
Page 67
B-63944EN/02 PROGRAMMING 2.CONTROLLED AXES
2 CONTROLLED AXES
- 33 -
Page 68
2.CONTROLLED AXESPROGRAMMINGB-63944EN/02
2.1 NUMBER OF CONTROLLED AXES
Explanation
The number of controlled axes used with this NC system depends on
the model and system control type as indicated below.
Lathe system 2 axes 2 axes 2 axes 2 axes Number of basic
be used is limited depending on the option
configuration. Refer to the manual provided by the
machine tool builder for details.
2 The number of simultaneously controllable axes for
manual operation (jog feed, manual reference
position return, or manual rapid traverse) is 1 or 3
(1 when parameter JAX (No. 1002#0) is set to 0
and 3 when it is set to 1).
- 34 -
Page 69
B-63944EN/02 PROGRAMMING 2.CONTROLLED AXES
2.2 NAMES OF AXES
Explanation
The move axes of machine tools are assigned names. These names are
referred to as addresses or axis names. Axis names are determined
according to the machine tool. The naming rules comply with
standards such as the ISO standards.
With complex machines, one character would become insufficient for
representing axis names. So, up to three characters can be used for
axis names. A move axis may be named "X", "X1", or "XA1". The
first character of the three characters is called the first axis name
character, the second character is called the second axis name
character, and third character is called the third axis name character.
Example)
X A 1
3rd axis name character
2nd axis name character
1st axis name character
NOTE
1 Axis names are predetermined according to the
machine used. Refer to the manual supplied by the
machine tool builder.
2 Since many ordinary machines use one character
to represent each address, one-character
addresses are used in the description in this
manual.
- 35 -
Page 70
2.CONTROLLED AXESPROGRAMMINGB-63944EN/02
2.3 INCREMENT SYSTEM
Explanation
The increment system consists of the least input increment (for input)
and least command increment (for output). The least input increment
is the least increment for programming the travel distance. The least
command increment is the least increment for moving the tool on the
machine. Both increments are represented in mm, inches, or deg.
Five types of increment systems are available as indicated in Table 2.3
(a). For each axis, an increment system can be set using a bit from bit
0 to bit 3 (ISA, ISC, ISD, or ISE) of parameter No. 1013.
When IS-D or IS-E is to be selected, the corresponding option is
required.
Table 2.3 (a) Increment system
Name of increment
system
IS-A
IS-B
IS-C
IS-D
IS-E
Least input increment
0.01 mm 0.01 mm
0.001 inch 0.001 inch
0.01 deg 0.01 deg
0.001 mm 0.001 mm
0.0001 inch 0.0001 inch
0.001 deg 0.001 deg
0.0001 mm 0.0001 mm
0.00001 inch 0.00001 inch
0.0001 deg 0.0001 deg
0.00001 mm 0.00001 mm
0.000001 inch 0.000001 inch
0.00001 deg 0.00001 deg
0.000001 mm 0.000001 mm
0.0000001 inch 0.0000001 inch
0.000001 deg 0.000001 deg
The least command increment is either metric or inch depending on
the machine tool. Set metric or inch to the parameter INM
(No.0100#0).
For selection between metric and inch for the least input increment, G
code (G20 or G21) or a setting parameter selects it.
Combined use of the inch system and the metric system is not allowed.
There are functions that cannot be used between axes with different
unit systems (circular interpolation, cutter compensation, etc.). For the
increment system, see the machine tool builder's manual.
NOTE
1 The unit (mm or inch) in the table is used for
indicating a diameter value for diameter programming
(when bit 3 (DIA) of parameter No. 1006 is set to 1)
or a radius value for radius programming.
2 Some increment systems are unavailable depending
on the model. For details, refer to “Descriptions” (B63942EN).
Least command
increment
- 36 -
Page 71
B-63944EN/02 PROGRAMMING 2.CONTROLLED AXES
2.4 MAXIMUM STROKE
Explanation
The maximum stroke controlled by this CNC is shown in the table
below:
Maximum stroke = Least command increment × 99999999
(999999999 for IS-D and IS-E)
Commands that exceed the maximum stroke are not permitted.
Table 2.4 (a) Maximum strokes
Name of increment
system
IS-A
IS-B
IS-C
IS-D
IS-E
NOTE
1 The actual stroke depends on the machine tool.
2 The unit (mm or inch) in the table is used for
indicating a diameter value for diameter
programming (when bit 3 (DIA) of parameter No.
1006 is set to 1) or a radius value for radius
programming.
3 Some increment systems are unavailable
depending on the model. For details, refer to
“Descriptions” (B-63942EN).
Least input increment Maximum stroke
0.01 mm ±999999.99 mm
0.001 inch ±99999.999 inch
0.01 deg ±999999.99 deg
0.001 mm ±99999.999 mm
0.0001 inch ±9999.9999 inch
0.001 deg ±99999.999 deg
0.0001 mm ±9999.9999 mm
0.00001 inch ±999.99999 inch
0.0001 deg ±9999.9999 deg
0.00001 mm ±9999.99999 mm
0.000001 inch ±999.999999 inch
0.00001 deg ±9999.99999 deg
0.000001 mm ±999.999999 mm
0.0000001 inch ±99.9999999 inch
0.000001 deg ±999.999999 deg
- 37 -
Page 72
3.PREPARATORY FUNCTION (G FUNCTION)PROGRAMMINGB-63944EN/02
3 PREPARATORY FUNCTION (G
FUNCTION)
A number following address G determines the meaning of the
command for the concerned block.
G codes are divided into the following two types.
Type Meaning
One-shot G code
Modal G code
(Example)
G01 and G00 are modal G codes in group 01.
G01 X_ ;
Z_ ; G01 is effective in this range.
X_ ;
G00 Z_ ; G00 is effective in this range.
X_ ;
G01 X_ ;
:
T
There are three G code systems in the lathe system : A, B, and C
(Table 3.1(a)). Select a G code system using the parameters GSB and
GSC (No. 3401#6 and #7). To use G code system B or C, the
corresponding option is needed. Generally, User’s Manual describes
the use of G code system A, except when the described item can use
only G code system B or C. In such cases, the use of G code system B
or C is described.
The G code is effective only in the block in which it
is specified.
The G code is effective until another G code of the
same group is specified.
- 38 -
Page 73
B-63944EN/02 PROGRAMMING3.PREPARATORY FUNCTION (G FUNCTION)
Explanation
1. When the clear state (parameter CLR (No. 3402#6)) is set at
power-up or reset, the modal G codes are placed in the states
described below.
(1) The modal G codes are placed in the states marked with
as indicated in Table.
(2) G20 and G21 remain unchanged when the clear state is set
at power-up or reset.
(3) Which status G22 or G23 at power on is set by parameter
G23 (No. 3402#7). However, G22 and G23 remain
unchanged when the clear state is set at reset.
(4) The user can select G00 or G01 by setting parameter G01
(No. 3402#0).
(5) The user can select G90 or G91 by setting parameter G91
(No. 3402#3).
When G code system B or C is used in the lathe system,
setting parameter G91 (No. 3402#3) determines which code,
either G90 or G91, is effective.
(6) In the machining center system, the user can select G17,
G18, or G19 by setting parameters G18 and G19 (No.
3402#1 and #2).
2. G codes other than G10 and G11 are one-shot G codes.
3. When a G code not listed in the G code list is specified, or a G
code that has no corresponding option is specified, alarm PS0010
occurs.
4. Multiple G codes can be specified in the same block if each G
code belongs to a different group. If multiple G codes that belong
to the same group are specified in the same block, only the last G
code specified is valid.
5. If a G code belonging to group 01 is specified in a canned cycle
for drilling, the canned cycle for drilling is cancelled. This means
that the same state set by specifying G80 is set. Note that the G
codes in group 01 are not affected by a G code specifying a
canned cycle for drilling.
6. G codes are indicated by group.
7. The group of G60 is switched according to the setting of the
parameter MDL (No. 5431#0). (When the MDL bit is set to 0,
the 00 group is selected. When the MDL bit is set to 1, the 01
group is selected.)
T
8. When G code system A is used, absolute or incremental
programming is specified not by a G code (G90/G91) but by an
address word (X/U, Z/W, C/H, Y/V). Only the initial level is
provided at the return point of the canned cycle for drilling..
- 39 -
Page 74
3.PREPARATORY FUNCTION (G FUNCTION)PROGRAMMINGB-63944EN/02
3.1 G CODE LIST IN THE MACHINING CENTER SYSTEM
M
G code Group Function
G00 Positioning (rapid traverse)
G01 Linear interpolation (cutting feed)
G02 Circular interpolation CW or helical interpolation CW
G03 Circular interpolation CCW or helical interpolation CCW
G02.2, G03.2 Involute interpolation CW/CCW
G02.3, G03.3 Exponential interpolation CW/CCW
G02.4, G03.4
G04 Dwell
G05 AI contour control (high-precision contour control compatible command)
G05.1 AI contour control / Nano smoothing / Smooth interpolation
G05.4
G06.2 01 NURBS interpolation
G07 Hypothetical axis interpolation
G07.1 (G107) Cylindrical interpolation
G08 AI contour control (advanced preview control compatible command)
G09 Exact stop
G10 Programmable data input
G10.6 Tool retract and recover
G10.9 Programmable switching of diameter/radius specification
G11
G12.1 Polar coordinate interpolation mode
G13.1
G15 Polar coordinates command cancel
G16
G17 XpYp plane selection
G18 ZpXp plane selection
G19
G20 (G70) Input in inch
G21 (G71)
G22 Stored stroke check function on
G23
G25 Spindle speed fluctuation detection off
G26
G27 Reference position return check
G28 Automatic return to reference position
G29 Movement from reference position
G30 2nd, 3rd and 4th reference position return
G30.1 Floating reference position return
G31 Skip function
G31.8
G33 Threading
G34 Variable lead threading
G35 Circular threading CW
G36
01
00
00
21
17
02
06
04
19
00
01
Three-dimensional coordinate conversion CW/CCW
HRV3,4 on/off
Programmable data input mode cancel
Polar coordinate interpolation cancel mode
Polar coordinates command
YpZp plane selection
Input in mm
Stored stroke check function off
Spindle speed fluctuation detection on
EGB-axis skip
Circular threading CCW
Table 3.1 (a) G code list
Xp: X axis or its parallel axis
Yp: Y axis or its parallel axis
Zp: Z axis or its parallel axis
- 40 -
Page 75
B-63944EN/02 PROGRAMMING3.PREPARATORY FUNCTION (G FUNCTION)
Table 3.1 (a) G code list
G code Group Function
G37 Automatic tool length measurement
G38 Cutter or tool nose radius compensation : preserve vector
G39
G40
G41
G41.2 Cutter compensation for 5-axis machining : left (type 1)
G41.3 Cutter compensation for 5-axis machining : (leading edge offset)
G41.4 Cutter compensation for 5-axis machining : left (type 1) (FS16i-compatible command)
G41.5 Cutter compensation for 5-axis machining : left (type 1) (FS16i-compatible command)
G41.6 Cutter compensation for 5-axis machining : left (type 2)
G42
G42.2 Cutter compensation for 5-axis machining : right (type 1)
G42.4 Cutter compensation for 5-axis machining : right (type 1) (FS16i-compatible command)
G42.5 Cutter compensation for 5-axis machining : right (type 1) (FS16i-compatible command)
G42.6
G40.1 Normal direction control cancel mode
G41.1 Normal direction control on : left
G42.1
G43 Tool length compensation +
G44
G43.1 Tool length compensation in tool axis direction
G43.4 Tool center point control (type 1)
G43.5
G45 Tool offset increase
G46 Tool offset decrease
G47 Tool offset double increase
G48
G49 (G49.1) 08 Tool length compensation cancel
G50 Scaling cancel
G51
G50.1 Programmable mirror image cancel
G51.1
G50.2 Polygon turning cancel
G51.2
G52 Local coordinate system setting
G53 Machine coordinate system setting
G53.1
G54 (G54.1) Workpiece coordinate system 1 selection
G55 Workpiece coordinate system 2 selection
G56 Workpiece coordinate system 3 selection
G57 Workpiece coordinate system 4 selection
G58 Workpiece coordinate system 5 selection
G59
G60 00 Single direction positioning
00
07
19
08
08
00
11
22
31
00
14
Cutter or tool nose radius compensation : corner circular interpolation
Cutter or tool nose radius compensation : cancel
Three-dimensional cutter compensation : cancel
Cutter or tool nose radius compensation : left
Three-dimensional cutter compensation : left
Cutter or tool nose radius compensation : right
Three-dimensional cutter compensation : right
Cutter compensation for 5-axis machining : right (type 2)
Normal direction control on : right
Tool length compensation -
Tool center point control (type 2)
Tool offset double decrease
Scaling
Programmable mirror image
Polygon turning
Tool axis direction control
Workpiece coordinate system 6 selection
- 41 -
Page 76
3.PREPARATORY FUNCTION (G FUNCTION)PROGRAMMINGB-63944EN/02
Table 3.1 (a) G code list
G code Group Function
G61 Exact stop mode
G62 Automatic corner override
G63 Tapping mode
G64
G65 00 Macro call
G66 Macro modal call A
G66.1 Macro modal call B
G67
G68 Coordinate system rotation start or 3-dimensional coordinate conversion mode on
G69 Coordinate system rotation cancel or 3-dimensional coordinate conversion mode off
G68.2
G72.1 Figure copy (rotation copy)
G72.2
G73 Peck drilling cycle
G74 Left-handed tapping cycle
G76 Fine boring cycle
G80
G80.5 24 Electronic gear box 2 pair: synchronization cancellation
G80.8 34 Electronic gear box: synchronization cancellation
G81 09 Drilling cycle or spot boring cycle
G81.1 00 Chopping
G81.5 24 Electronic gear box 2 pair: synchronization start
G81.8 34 Electronic gear box: synchronization start
G82 Drilling cycle or counter boring cycle
G83 Peck drilling cycle
G84 Tapping cycle
G84.2 Rigid tapping cycle (FS15 format)
G84.3 Left-handed rigid tapping cycle (FS15 format)
G85 Boring cycle
G86 Boring cycle
G87 Back boring cycle
G88 Boring cycle
G89
G90 Absolute programming
G91
G91.1 Checking the maximum incremental amount specified
G92 Setting for workpiece coordinate system or clamp at maximum spindle speed
G92.1
G93 Inverse time feed
G94 Feed per minute
G95
G96 Constant surface speed control
G97
G98 Canned cycle : return to initial level
G99
G107 00 Cylindrical interpolation
G112 Polar coordinate interpolation mode
G113
15
12
16
00
09
09
03
00
05
13
10
21
Cutting mode
Macro modal call A/B cancel
Feature coordinate system selection
Figure copy (linear copy)
Canned cycle cancel
Boring cycle
Incremental programming
Workpiece coordinate system preset
Feed per revolution
Constant surface speed control cancel
Canned cycle : return to R point level
Polar coordinate interpolation mode cancel
- 42 -
Page 77
B-63944EN/02 PROGRAMMING3.PREPARATORY FUNCTION (G FUNCTION)
AI contour control (command compatible with high precision
00
00
21
24
16
06
09
08
contour control)
HRV3,4 on/off
Cylindrical interpolation
Tool retract and recover
Programmable switching of diameter/radius specification
Programmable data input mode cancel
Polar coordinate interpolation mode
Polar coordinate interpolation cancel mode
Polar coordinate command
YpZp plane selection
Input in mm
Stored stroke check function off
Spindle speed fluctuation detection off
Spindle speed fluctuation detection on
- 43 -
Page 78
3.PREPARATORY FUNCTION (G FUNCTION)PROGRAMMINGB-63944EN/02
Table 3.2 (a) G code list
G code system
A B C
G27 G27 G27 Reference position return check
G28 G28 G28 Return to reference position
G29 G29 G29 Movement from reference position
G30 G30 G30 2nd, 3rd and 4th reference position return
G30.1 G30.1 G30.1 Floating reference point return
G31 G31 G31 Skip function
G31.8 G31.8 G31.8
G32 G33 G33 Threading
G34 G34 G34 Variable lead threading
G35 G35 G35 Circular threading CW
G36 G36 G36
G37 G37 G37
G37.1 G37.1 G37.1
G37.2 G37.2 G37.2
G38 G38 G38
G39 G39 G39
G40 G40 G40 Cutter compensation of tool nose radius compensation : cancel
G41 G41 G41 Cutter compensation of tool nose radius compensation : left
G42 G42 G42 Cutter compensation of tool nose radius compensation : right
G41.2 G41.2 G41.2 Cutter compensation for 5-axis machining : left (type 1)
G41.3 G41.3 G41.3
G41.4 G41.4 G41.4
G41.5 G41.5 G41.5
G41.6 G41.6 G41.6 Cutter compensation for 5-axis machining : left (type 2)
G42.2 G42.2 G42.2 Cutter compensation for 5-axis machining : right (type 1)
G42.4 G42.4 G42.4
G42.5 G42.5 G42.5
G42.6 G42.6 G42.6
G43 G43 G43 Tool length compensation +
G44 G44 G44 Tool length compensation G43.1 G43.1 G43.1 Tool length compensation in tool axis direction
G43.4 G43.4 G43.4 Tool center point control (type 1)
G43.5 G43.5 G43.5 Tool center point control (type 2)
G43.7
(G44.7)
G49
(G49.1)
G43.7
(G44.7)
G49
(G49.1)
G43.7
(G44.7)
G49
(G49.1)
Group Function
00
EGB-axis skip
Circular threading CCW (When the parameter G36 (No.
3405#3) is set to 1) or Automatic tool offset (X axis) (When the
parameter G36 (No. 3405#3) is set to 0)
Automatic tool offset (Z axis) (When the parameter G36 (No.
01
07
23
3405#3) is set to 0)
Automatic tool offset (X axis) (When the parameter G36 (No.
3405#3) is set to 1)
Automatic tool offset (Z axis) (When the parameter G36 (No.
3405#3) is set to 1)
Cutter compensation of tool nose radius compensation: with
vector held
Cutter compensation of tool nose radius compensation: corner
rounding interpolation
Cutter compensation for 5-axis machining :
(leading edge offset)
Cutter compensation for 5-axis machining : left (type 1) (FS16icompatible command)
Cutter compensation for 5-axis machining : left (type 1) (FS16icompatible command)
Cutter compensation for 5-axis machining : right (type 1) (FS16icompatible command)
Cutter compensation for 5-axis machining : right (type 1) (FS16icompatible command)
Cutter compensation for 5-axis machining : right (type 2)
Tool offset (lathe system ATC type)
Tool length compensation cancel
- 44 -
Page 79
B-63944EN/02 PROGRAMMING3.PREPARATORY FUNCTION (G FUNCTION)
Table 3.2 (a) G code list
G code system
A B C
G50 G92 G92 Coordinate system setting or max. spindle speed clamp
G50.3 G92.1 G92.1
The G00 command moves a tool to the position in the workpiece
system specified with an absolute or an incremental command at a
rapid traverse rate.
In the absolute command, coordinate value of the end point is
programmed.
In the incremental command the distance the tool moves is
programmed.
Format
G00 IP_ ;
IP_ : For an absolute command, the coordinates of an end
point, and for an incremental command, the distance
the tool moves.
Explanation
Either of the following tool paths can be selected according to bit 1
(LRP) of parameter No. 1401.
•Nonlinear interpolation type positioning
The tool is positioned with the rapid traverse rate for each axis
separately. The tool path is normally straight.
•Linear interpolation type positioning. The tool is positioned
within the shortest possible time at a speed that is not more than
the rapid traverse rate for each axis.
Linear interpolation type positioning
End position
The rapid traverse rate in G00 command is set to the parameter No.
1420 for each axis independently by the machine tool builder. In the
positioning mode actuated by G00, the tool is accelerated to a
predetermined speed at the start of a block and is decelerated at the
end of a block. Execution proceeds to the next block after confirming
the in-position.
"In-position " means that the feed motor is within the specified range.
This range is determined by the machine tool builder by setting to
parameter (No. 1826).
The rapid traverse rate cannot be specified in the address F.
Even if linear interpolation type positioning is specified, nonlinear
type interpolation positioning is used in the following cases. Therefore,
be careful to ensure that the tool does not foul the workpiece.
• G28 specifying positioning between the reference and
For accurate positioning without play of the machine (backlash), final
positioning from one direction is available.
Overrun
Start point
Start point
Format
Explanation
End point
Temporary stop
G60 IP_ ;
IP_ : For an absolute command, the coordinates of an end
point, and for an incremental command, the distance
the tool moves.
An overrun and a positioning direction are set by the parameter (No.
5440). Even when a commanded positioning direction coincides with
that set by the parameter, the tool stops once before the end point.
G60, which is an one-shot G-code, can be used as a modal G-code in
group 01 by setting 1 to the parameter MDL (No. 5431#0).
This setting can eliminate specifying a G60 command for every block.
Other specifications are the same as those for an one-shot G60
command. When an one-shot G code is specified in the single
direction positioning mode, the one-shot G command is effective like
G codes in group 01.
•In the case of positioning of non-linear interpolation type (bit
1 (LRP) of parameter No. 1401 = 0)
As shown below, single direction positioning is performed
independently along each axis.
X
Overrun distance in the Z-axis direction
Overrun distance in the
X-axis direction
Programmed end point
Z
Programmed start point
•In the case of positioning of linear interpolation type (bit 1
(LRP) of parameter No. 1401 = 1)
Positioning of interpolation type is performed until the tool once
stops before or after a specified end point. Then, the tool is
positioned independently along each axis until the end point is
reached.
X
Limitation
Overrun distance in the Z-axis direction
Overrun distance in the
X-axis direction
Programmed end point
Z
Programmed start point
•Single direction positioning is not performed along an axis for
which no overrun distance is set in parameter No. 5440.
•Single direction positioning is not performed along an axis for
which travel distance 0 is specified.
• The mirror image function is not applied in a parameter-set
direction. Even in the mirror image mode, the direction of single
direction positioning remains unchanged. If positioning of linear
interpolation type is used, and the state of mirror image when a
single direction positioning block is looked ahead differs from
the state of mirror image when the execution of the block is
started, an alarm is issued. When switching mirror image in the
middle of a program, disable looking ahead by specifying a
non-buffering M code. Then, switch mirror image when there is
no look-ahead block.
•In the cylindrical interpolation mode (G07.1), single direction
positioning cannot be used.
• In the polar coordinate interpolation mode (G12.1), single
direction positioning cannot be used.
• When specifying single direction positioning on a machine that
uses angular axis control, first position the angular axis then
specify the positioning of the Cartesian axis. If the reverse
specification order is used, or the angular axis and Cartesian axis
are specified in the same block, an incorrect positioning direction
can result.
• In positioning at a restart position by program restart function,
single direction positioning is not performed.
M
T
•During canned cycle for drilling, no single direction positioning
is effected in drilling axis.
•The single direction positioning does not apply to the shift
motion in the canned cycles of G76 and G87.
•The G-code for single direction positioning is always G60, if
G-code system is A or B or C in all case.
•The single direction positioning can not be commanded during
the multiple repetitive cycle (G70-G76).
•No single direction positioning is effected in the drilling or
patting axis, during canned cycle for drilling (G83-G89) and the
rigid tapping (G84, G88). However, it can be commanded for
positioning.
•The single direction positioning can not be commanded during
the canned cycle (G90, G92, G94).
• During the single direction positioning mode (G60), the
IP_ : For an absolute command, the coordinates of an end
point, and for an incremental command, the distance
the tool moves.
F_ : Speed of tool feed (Feedrate)
Explanation
A tools move along a line to the specified position at the feedrate
specified in F.
The feedrate specified in F is effective until a new value is specified.
It need not be specified for each block.
The feedrate commanded by the F code is measured along the tool
path. If the F code is not commanded, the feedrate is regarded as zero.
The feedrate of each axis direction is as follows.
G01 αα ββ γγ ζζ Ff ;
α
Feed rate of α axis direction : f
Feed rate of β axis direction :
Feed rate of γ axis direction :
Feed rate of ζ axis direction :
2222
ζγβα
+++=L
α
F×=
L
β
β
F×=
L
γ
γ
f
F×=
L
ζ
ζ
f
F×=
L
f
The feedrate of the rotary axis is commanded in the unit of deg/min
(the unit is decimal point position).
When the straight line axis α (such as X, Y, or Z) and the rotating axis
b (such as A, B, or C) are linearly interpolated, the feedrate is that in
which the tangential feedrate in the α and β cartesian coordinate
system is commanded by F(mm/min).
β-axis feedrate is obtained ; at first, the time required for distribution
is calculated by using the above formula, then the β-axis feedrate unit
is changed to deg/min.
A calculation example is as follows.
G91 G01 X20.0B40.0 F300.0 ;
This changes the unit of the C axis from 40.0 deg to 40mm
with metric input. The time required for distribution is
calculated as follows:
22
4020
300
+
)(14907.0mm
The feedrate for the C axis is
40
14907.0
mindeg/3.268
In simultaneous 3 axes control, the feedrate is calculated the same way
as in 2 axes control.
Example
- Linear interpolation
• For milling machining
(G91) G01X200.0Y100.0F200.0;
Y axis
100.0
0 (Start point)
200.0
• For lathe cutting
(Diameter programming)
G01X40.0Z20.1F20; (Absolute command)
or
G01U20.0W-25.9F20; (Incremental command)
The command below will move a tool along a circular arc.
Format
Arc in the XpYp plane
G
02
G
17
G
03
YpXp
Arc in the ZpXp plane
G
02
G
18
G
03
XpZp
Arc in the YpZp plane
G
02
G
19
G
03
ZpYp
Command Description
G17 Specification of arc on XpYp plane
G18 Specification of arc on ZpXp plane
G19 Specification of arc on YpZp plane
G02 Circular Interpolation Clockwise direction (CW)
G03 Circular Interpolation Counterclockwise direction (CCW)
Xp_
Yp
_
Zp
_
I_
J_
K_
R_ Arc radius (with sign, radius value for lathe cutting)
F_ Feedrate along the arc
Command values of X axis or its parallel axis
(set by parameter No. 1022)
Command values of Y axis or its parallel axis
(set by parameter No. 1022)
Command values of Z axis or its parallel axis
(set by parameter No. 1022)
Xp axis distance from the start point to the center of an arc
with sign
Yp axis distance from the start point to the center of an arc
with sign
Zp axis distance from the start point to the center of an arc
with sign
"Clockwise"(G02) and "counterclockwise"(G03) on the XpYp plane
(ZpXp plane or YpZp plane) are defined when the XpYp plane is
viewed in the positive-to-negative direction of the Zp axis (Yp axis or
Xp axis, respectively) in the Cartesian coordinate system. See the
figure below.
Y
G03
G02
G17
- Distance moved on an arc
The end point of an arc is specified by address Xp, Yp or Zp, and is
expressed as an absolute or incremental value according to G90 or
G91. For the incremental value, the distance of the end point which is
viewed from the start point of the arc is specified with sign.
- Distance from the start point to the center of arc
The arc center is specified by addresses I, J, and K for the Xp, Yp, and
Zp axes, respectively. The numerical value following I, J, or K,
however, is a vector component in which the arc center is seen from
the start point, and is always specified as an incremental value
irrespective of G90 and G91, as shown below.
I, J, and K must be signed according to the direction.
X
G02
G18
G03
Z
G02
G19
G03
YZ
- Command for a circle
End point (x,y)
y
x
Center
End point (z,x)
x
Start
i
point
z
Center
k
Start
point
i
End point (y,z)
z
y
Center
Start
point
k
I0,J0, and K0 can be omitted.
If the difference between the radius at the start point and that at the
end point exceeds the permitted value in a parameter (No.3410), an
alarm PS0020 occurs.
When Xp, Yp , and Zp are omitted (the end point is the same as the
start point) and the center is specified with I, J, and K, a 360° arc
(circle) is specified.
G02 I_ ; Command for a circle
The distance between an arc and the center of a circle that contains the
arc can be specified using the radius, R, of the circle instead of I, J,
and K.
In this case, one arc is less than 180°, and the other is more than 180°
are considered. When an arc exceeding 180° is commanded, the radius
must be specified with a negative value. If Xp, Yp, and Zp are all
omitted, if the end point is located at the same position as the start
point and when R is used, an arc of 0° is programmed
G02R_ ; (The cutter does not move.)
For arc <1> (less than 180°)
G91 G02 XP60.0 YP55.0 R50.0 F300.0 ;
For arc <2> (greater than 180°)
G91 G02 XP60.0 YP55.0 R-50.0 F300.0 ;
- Feedrate
<2>
Start point
r=50mm
<1>
Y
End point
r=50mm
X
The feedrate in circular interpolation is equal to the feedrate specified
by the F code, and the feedrate along the arc (the tangential feedrate of
the arc) is controlled to be the specified feedrate.
The error between the specified feedrate and the actual tool feedrate is
±2% or less. However, this feedrate is measured along the arc after the
cutter compensation is applied
If I, J, K, and R addresses are specified simultaneously, the arc
specified by address R takes precedence and the other are ignored.
- Specifying an axis that is not contained in the specified plane
If an axis not comprising the specified plane is commanded, an alarm
PS0028 occurs.
For example,
For milling machining:
If the X-axis and a U-axis parallel to the X-axis are specified when the
XY plane is specified
For lathe cutting:
If the X-axis and a U-axis parallel to the X-axis are specified when the
ZX plane is specified with G code system B or C
- Specifying a semicircle with R
When an arc having a center angle approaching 180° is specified, the
calculated center coordinates may contain an error. In such a case,
specify the center of the arc with I, J, and K.
- Difference in the radius between the start and end points
If the difference in the radius between the start and end points of the
arc exceeds the value specified in parameter No. 3410, alarm PS0020
is generated.
If the end point is not on the arc, the tool moves in a straight line
along one of the axes after reaching the end point.
Helical interpolation which moved helically is enabled by specifying
up to two other axes which move synchronously with the circular
interpolation by circular commands.
Format
Arc of XpYp plane
G17
Arc of ZpXp plane
G18
Arc of YpZp plane
G19
G02
G03
G02
G03
G02
G03
Xp_Yp_
Zp_Xp_
Yp_Zp_
I_J_
R_
K_I_
R_
J_K_
R_
α_(β
α_(β
α_(β
_)F_;
_)F_;
_)F_;
Explanation
α, β
: Any one axis where circular interpolation is not applied.
Up to two other axes can be specified.
A tangential velocity of an arc in a specified plane or a tangential
velocity about the linear axis can be specified as the feedrate,
depending on the setting of bit 5 (HTG) of parameter No.1403.
An F command specifies a feedrate along a circular arc, when HTG is
specified to 0. Therefore, the feedrate of the linear axis is as follows:
Length of linear axis
F ×
Length of circular arc
Determine the feedrate so the linear axis feedrate does not exceed any
of the various limit values.
The feedrate along the circumference of two circula
interpolated axes is the specified feedrate.
Y
If HTG is set to 1, specify a feedrate along the tool path about the
linear axis. Therefore, the tangential velocity of the arc is expressed
as follows:
Length of arc
F ×
(Length of arc)2 + (Length of linear axis)2
The velocity along the linear axis is expressed as follows:
Length of linear axis
F ×
(Length of arc)2 + (Length of linear axis)2
Z
Limitation
Tool path
X
The feedrate along the tool path is specified.
Y
• Cutter compensation or tool nose radius compensation is applied
only for a circular arc.
• Tool offset and tool length compensation cannot be used in a block
The helical interpolation B function differs from the helical
interpolation function just in that circular interpolation and a
movement on four axes outside the specified plane can be
simultaneously performed.
For the restrictions and parameters, see the description of the helical
interpolation function.
Format
Arc in the XpYp plane
G02
G17
G03
Arc in the ZpXp plane
G02
G18
G03
Arc in the YpZp plane
G02
G19
G03
α, β, γ, δ
: Any axis to which circular interpolation is not applied.
Spiral interpolation is enabled by specifying the circular interpolation
command together with a desired number of revolutions or a desired
increment (decrement) for the radius per revolution.
Conical interpolation is enabled by specifying the spiral
interpolation command together with an additional axis of movement,
as well as a desired increment (decrement) for the position along the
additional axes per spiral revolution.
Format
- Spiral interpolation
XpYp plane
G17
ZpXp plane
G18
YpZp plane
G19
X, Y, Z : Coordinates of the end point
L: Number of revolutions (positive value without a decimal point)
Q:Radius increment or decrement per spiral revolution (*1, *2)
I, J, K :Signed distance from the start point to the center (same as
F:Feedrate
(*1)Either the number of revolutions (L) or the radius increment or
(*2)The increment system for Q depends on the reference axis.
G02
G03
G02
G03
G02
G03
(*1)
the distance specified for circular interpolation)
decrement (Q) can be omitted. When L is omitted, the number of
revolutions is automatically calculated from the distance between
the current position and the center, the position of the end point,
and the radius increment or decrement. When Q is omitted, the
radius increment or decrement is automatically calculated from
the distance between the current position and the center, the
position of the end point, and the number of revolutions. If both L
and Q are specified but their values contradict, Q takes
precedence. Generally, either L or Q should be specified. The L
value must be a positive value without a decimal point. To
specify four revolutions plus 90°, for example, round the number
of revolutions up to five and specify L5.
X, Y, Z :Coordinates of the end point
L:Number of revolutions (positive value without a decimal point)
Q:Radius increment or decrement per spiral revolution (*1, *2)
I, J, K :Two of the three values represent a signed vector from the start
F:Feedrate (The tangential velocity about the linear axis is
(*1) One of the height increment/decrement (I, J, K), radius
increment/decrement (Q), and the number of revolutions (L) must be
specified. The other two items can be omitted.
• Sample command for the XpYp plane
G02
G03
G02
G03
G02
G03
(*1)
point to the center. The remaining value is a height increment or
decrement per spiral revolution in conical interpolation. (*1)
When the XpYp plane is selected:
The I and J values represent a signed vector from the start
point to the center.
The K value represents a height increment or decrement per
spiral revolution.
When the ZpXp plane is selected:
The K and I values represent a signed vector from the start
point to the center.
The J value represents a height increment or decrement per
spiral revolution.
When the YpZp plane is selected:
The J and K values represent a signed vector from the start
point to the center.
The I value represents a height increment or decrement per
spiral revolution.
specified.)
X_Y_I_J_Z_Q_L_F_;
Z_X_K_I_Y_Q_L_F_;
Y_Z_J_K_X_Q_L_F_;
G17
If both L and Q are specified, but their values contradict, Q takes
precedence. If both L and a height increment or decrement are
specified, but their values contradict, the height increment or
decrement takes precedence. If both Q and a height increment or
decrement are specified, but their values contradict, Q takes
precedence. The L value must be a positive value without a decimal
point. To specify four revolutions plus 90°, for example, round the
number of revolutions up to five and specify L5.
(*2) The increment system for Q depends on the reference axis.
G02
G03
X_Y_I_J_Z_Q_ F_;
K_
L_
- 66 -
Loading...
+ hidden pages
You need points to download manuals.
1 point = 1 manual.
You can buy points or you can get point for every manual you upload.