Valid for
Software Version
SINUMERIK 840D/DE powerline 7.4 SINUMERIK 840Di/DiE powerline 3.3 SINUMERIK 810D/DE powerline 7.4
SINUMERIK 840D sl/DE sl 1.4
SINUMERIK 840Di sl/DiE sl 1.4
SINUMERIK 802D sl 1.4
Programming Manual ISO Milling
SINUMERIK 802D sl/840D/840D sl/
840Di//840Di sl/810D
Programming Guide
Programming Guide
Programming Guide
Programming Guide
Programming Guide
Programming Guide
Programming Guide
Programming Guide
Programming Guide
Programming Guide
Programming Guide
Programming Guide
Programming Guide
Programming Guide
Commands Calling
Axis Movements
2
Movement Control
Commands
3
Enhanced Level
Commands
4
Appendix
Abbreviations A Terms B G Code Table C MDs and SDs DData Fields, Lists E
Alarms F
Brief details of this edition and previous editions are listed below.
The status of each edition is shown by the code in the “Remarks” column.
Status code in the “Remarks” column:
A. . . . .New documentation.
B. . . . .Unrevised reprint with new Order No.
C. . . . .Revised edition with new status.
Edition Order No. Remarks
02.01 6FC5 298--6AC20--0BP0 A 12.01 6FC5 298--6AC20--0BP1 C 11.02 6FC5 298--6AC20--0BP2 C 04.05 6FC5 298--7AC20--0BP0 C 04.07 6FC5398--7BP10--0BA0 C Trademarks
All product designations could be trademarks or product names of Siemens AG or other companies which, if used by third parties, could infringe the rights of their owners.
Exclusion of liability
We have checked the contents of the documentation for consistency with the hardware and software described. Since deviations cannot be precluded entirely, we cannot guarantee complete conformance. The information in this document is regularly checked and necessary corrections are included in reprints. Suggestions for improvement are also welcome.
Structure of the documentation
The SINUMERIK documentation is structured in three levels:
S General documentation S User documentation
S Manufacturer/service documentation.
An overview of publications that is updated monthly is provided in a number of lan-guages in the Internet at:
http://www.siemens.com/motioncontrol
Follow menu items > ”Support” > ”Technical Documentation” > ”Overview of Docu-ments”.
DOConWEB, the Internet edition of DOConCD, is available at: http://www.automation.siemens.com/doconweb
Information on the training courses offered as well as FAQs (frequently asked questions) are provided on the Internet at:
http://www.siemens.com/motioncontrol, ”Support” menu item.
Target audience
This documentation is intended for:
S Project engineers
S Technologists (from machine manufacturers) S System startup (Systems/Machines
S Programmers
Standard scope
This documenation only describes the functionality if the standard version. Exten-sions or changes made by the machine tool manufacturer are documented by the machine tool manufacturer.
It may be possible to runfunctions that are not described in this document in your controller. This does not, however, represent an obligation to supply such functions with a new control or when servicing.
Further, for the sake of simplicity, this documentation does not contain all detailed information about all types of the product and cannot cover every conceivable case of installation, operation or maintenance.
Technical Support
If you have any questions, please get in touch with our Hotline:
Europe / Africa Asia / Australia America
Phone +49 180 5050 222 +86 1064 719 990 +1 423 262 2522 Fax +49 180 5050 223 +86 1064 747 474 +1 423 262 2289 Internet http:// www.siemens.com/automation/support--request E--Mail mailto:[email protected]
Note
Should you require technical support, please call one of the country--specific phone numbers provided on the Internet:
http://www.siemens.com/automation/services&support
Questions regarding the manual
If you have any queries (suggestions, corrections) in relation to this documentation, please send a fax or e--mail to the following address:
Fax +49 9131 98 63315
E--Mail mailto:[email protected] Fax form: see reply form at the end of the manual.
SINUMERIK Internet address
http://www.siemens.com/sinumerik
Origin
In contrast to the Siemens mode programming of YASKAWA SIEMENS 840DI, ISO dialect programming is mainly based on SINUMERIK 6T--B and SINUMERIK 6M--B, a CNC control which had already been phased out. However, OEM and en-duser requirements on SINUMERIK 6T--B programming compatibility lead to the development of the ISO dialect function.
Safety Instructions
This manual contains information which you should carefully observe to ensure your own personal safety and the prevention of material damage. These notices referring to your personal safety are highlighted by a safety alert symbol. The noti-ces referringto property damage alone have no safety alert symbol. The warnings appear in decreasing order of risk as given below.
!
Dangerindicates that death or severe personal injurywillresult if proper precautions are not taken.!
Warningindicates that death or severe personal injurycanresult if proper precautions are not taken.!
Cautionwith a warning triangle indicates that minor personal injury can result if proper pre-cautions are not taken.Caution
without warning triangle indicates that material damage can result if proper precau-tions are not taken.
Notice
indicates that an undesirable event or state may arise if the relevant notes are not observed.
If several hazards of different degree occur, the hazard with the highest degree must always be given priority. If a warning note with a warning triangle warns of personal injury, the same warning note can also contain a warning of material da-mage.
Qualified personnel
The associated device/system may only be set up and operated using this docu-mentation. Commissioning and operation of a device/system may only be perfor-med byqualified personnel. Qualified persons are defined as persons who are authorized to commission, to ground, and to tag circuits, equipment, and systems in accordance with established safety practices and standards.
Prescribed Usage
Please note the following:
!
WarningThe equipment may only be used for single purpose applications explicitly descri-bed in the catalog and in the technical description and it may only be used along with third--party devices and components recommended by Siemens. To ensure trouble--free and safe operation of the product, it must be transported, stored and installed as intended and maintained and operated with care.Further notes Note
This icon is displayed in the present documentation whenever additional facts are being specified.
Table of Contents
1 Programming Basics . . . . 1-11
1.1 Introductory explanations. . . 1-11 1.1.1 Siemens mode. . . 1-11 1.1.2 ISO Dialect mode . . . 1-11 1.1.3 Switchover . . . 1-12 1.1.4 G code display . . . 1-12 1.1.5 Maximum number of axes/axis designation . . . 1-12 1.1.6 Decimal point programming. . . 1-13 1.1.7 Comments . . . 1-15 1.1.8 Block skip . . . 1-15 1.2 Basics of feed function . . . 1-17 1.2.1 Rapid traverse . . . 1-17 1.2.2 Cutting feed (F command) . . . 1-17 1.2.3 F1-digit feed . . . 1-20 1.2.4 Feed per minute function (G94) . . . 1-21 1.2.5 Inverse time feed (G93) . . . 1-21
2 Commands Calling Axis Movements . . . . 2-23
2.1 Interpolation commands . . . 2-23 2.1.1 Positioning (G00). . . 2-23 2.1.2 Linear interpolation (G01) . . . 2-25 2.1.3 Circular interpolation (G02, G03) . . . 2-26 2.1.4 Helical interpolation (G02, G03) . . . 2-32 2.2 Reference point return . . . 2-34 2.2.1 Automatic return to reference point (G28). . . 2-34 2.2.2 Reference point return check (G27). . . 2-37 2.2.3 Second to fourth reference point return (G30) . . . 2-38 2.2.4 Rapid lift with G10.6 . . . 2-38
3 Movement Control Commands . . . . 3-41
3.1 The coordinate system . . . 3-41 3.1.1 Machine coordinate system (G53) . . . 3-42 3.1.2 Workpiece coordinate system (G92) . . . 3-43 3.1.3 Resetting the work (G92.1) . . . 3-45 3.1.4 How to select a workpiece coordinate system . . . 3-45 3.1.5 Instantaneous mapping of the ISO functions onto Siemens frames
(until powerline 7.04.2, solution line 1.4) . . . 3-46 3.1.6 Uncoupling the frames between the Siemens and the ISO modes
(with powerline 7.04.02 or solution line 1.4 and higher) . . . 3-49 3.1.7 Local coordinate system (G52) . . . 3-52 3.1.8 Plane selection (G17, G18, G19) . . . 3-54 3.1.9 Parallel axes (G17, G18, G19) . . . 3-54 3.1.10 Rotation of coordinate system (G68, G69) . . . 3-56 3.1.11 3D rotation G68 / G69 . . . 3-58 3.2 Determining the coordinate value input modes . . . 3-59 3.2.1 Absolute/incremental designation (G90, G91) . . . 3-59
3.2.3 Scaling (G50, G51) . . . 3-61 3.2.4 Programmable mirror image (G50.1, G51.1) . . . 3-64 3.2.5 G60: Oriented positioning . . . 3-66 3.3 Time-controlling commands. . . 3-67 3.3.1 Dwell (G04) . . . 3-67 3.4 Cutting feedrate control . . . 3-68 3.4.1 Automatic corner override G62 . . . 3-68 3.4.2 Compressor in ISO dialect mode . . . 3-71 3.4.3 Exact stop (G09, G61), cutting mode (G64), tapping mode (G63) . . . 3-72 3.5 Tool offset functions . . . 3-73 3.5.1 Tool offset data memory. . . 3-73 3.5.2 Tool length offset (G43, G44, G49) . . . 3-73 3.5.3 Cutter radius compensation (G40, G41, G42) . . . 3-76 3.5.4 Collision monitoring. . . 3-81 3.6 S, T, M, and B functions . . . 3-86 3.6.1 Spindle function (S function) . . . 3-86 3.6.2 Tool function (T function) . . . 3-87 3.6.3 Miscellaneous function (M function) . . . 3-87 3.6.4 Internally processed M codes . . . 3-88 3.6.5 Macro call via M function . . . 3-88 3.6.6 General purpose M codes . . . 3-89
4 Enhanced Level Commands. . . . 4-91
4.1 Program support functions (1). . . 4-91 4.1.1 Canned cycles (G73 to G89). . . 4-91 4.1.2 High--speed peck drilling cycle (G73). . . 4-98 4.1.3 Fine boring cycle (G76) . . . 4-99 4.1.4 Drilling cycle, spot drilling (G81) . . . 4-103 4.1.5 Drilling cycle, counter boring cycle (G82) . . . 4-105 4.1.6 Peck drilling cycle (G83). . . 4-107 4.1.7 Boring cycle (G85) . . . 4-109 4.1.8 Boring cycle (G86) . . . 4-111 4.1.9 Boring cycle, back boring cycle (G87) . . . 4-113 4.1.10 Drilling cycle (G89), retract using G01. . . 4-116 4.1.11 Rigid tapping cycle (G84). . . 4-118 4.1.12 Left--handed rigid tapping cycle (G74) . . . 4-121 4.1.13 Peck tapping cycle (G84 or G74) . . . 4-124 4.1.14 Canned cycle cancel (G80) . . . 4-127 4.1.15 Program example using tool length offset and canned cycles . . . 4-128 4.1.16 Multiple threads with G33. . . 4-130 4.1.17 Threads with variable lead (G34) . . . 4-131 4.2 Programmable data input (G10) . . . 4-132 4.2.1 Changing of tool offset value . . . 4-132 4.2.2 Setting the workpiece coordinate system shift data. . . 4-132 4.3 Subprogram call up function (M98, M99) . . . 4-133 4.4 Eight--digit program number . . . 4-134 4.5 Polar coordinate command (G15, G16). . . 4-136 4.6 Polar coordinate interpolation (G12.1, G13.1) . . . 4-137
4.7 Cylindrical interpolation (G07.1) . . . 4-139 4.8 Program support functions (2). . . 4-143 4.8.1 Working area limitation (G22, G23) . . . 4-143 4.8.2 Chamfering and corner rounding commands . . . 4-144 4.9 Automating support functions . . . 4-148 4.9.1 Skip function (G31) . . . 4-148 4.9.2 Multistage skip (G31, P1 -- P4) . . . 4-150 4.9.3 Program interrupt function (M96, M97) . . . 4-151 4.9.4 Tool life control function . . . 4-153 4.10 Macroprograms . . . 4-154 4.10.1 Differences from subprograms . . . 4-154 4.10.2 Macroprogram call (G65, G66, G67) . . . 4-154 4.10.3 Macro Call via G Function . . . 4-161 4.11 Additional functions. . . 4-164 4.11.1 Figure copy (G72.1, G72.2). . . 4-164 4.11.2 Switchover modes for DryRun and skip levels . . . 4-166 4.12 Interrupt programm with M96 / M97 (ASUB) . . . 4-168
A Abbreviations . . . . A-171 B Terms. . . . B-181 C G Code Table. . . . C-211
C.1 G code table. . . C-211
D Machine and Setting Data . . . . D-215
D.1 Machine/Setting data . . . D-215 D.2 Channel-specific machine data . . . D-226 D.3 Axis-specific setting data . . . D-236 D.4 Channel-specific setting data . . . D-237
E Data Fields, Lists . . . . E-239
E.1 Machine data . . . E-239 E.2 Setting data . . . E-241 E.3 Variables . . . E-242
F Alarms. . . . F-245 G Commands. . . . I-247 Index . . . . I-249
Programming Basics
1.1
Introductory explanations
1.1.1
Siemens mode
The following conditions apply when Siemens mode is active:
S Siemens G commands are interpreted on the control by default. This applies to
all channels.
S It is not possible to extend the Siemens programming system with ISO Dialect
functions because some of the G functions have different meanings.
S Downloadable MD files can be used to switch the control to ISO Dialect mode.
In this case, the system boots the ISO Dialect mode by default.
1.1.2
ISO Dialect mode
The following conditions apply when ISO Dialect mode is active:
S Only ISO Dialect G codes can be programmed, not Siemens G codes.
S It is not possible to use a mixture of ISO Dialect code and Siemens code in the
same NC block.
S It is not possible to switch between ISO Dialect--M and ISO Dialect--T via
G command.
S Siemens subprogram calls can be programmed.
S If further Siemens functions are to be used, it is necessary to switch to Siemens
mode first.
1.1.3
Switchover
The following two G commands are used to switch between Siemens mode and ISO Dialect mode:
-- G290 -- Siemens NC programming language active -- G291 -- ISO Dialect NC programming language active
The active tool, the tool offsets and the zero offsets are not changed by this action. G290 and G291 must be programmed in a separate program block.
1.1.4
G code display
The G code display must always be implemented in the same language type (Siemens/ISO Dialect) as the current block display. If the block display is suppres-sed with DISPLOF, the current G codes continue to be displayed in the language type of the active block.
Example
The Siemens standard cycles are called up using the G functions of the ISO Dia-lect mode. DISPLOF is programmed at the start of the cycle, with the result that the ISO Dialect G commands remain active for the display.
PROC CYCLE328 SAVE DISPLOF N10 ...
... N99 RET
Procedure
External main program calls Siemens shell cycle. Siemens mode is selected impli-citly on the shell cycle call.
DISPLOF freezes the block display at the call block; the G code display remains in external mode. This display is refreshed while the Siemens cycle is running. The SAVE attribute resets the G codes modified in the shell cycle to their original state when the shell cycle was called on the return jump to the main program.
1.1.5
Maximum number of axes/axis designation
In ISO Dialect--M the maximum number of axis is 9. Axis designation for the first three axes is fixed to X, Y and Z. Further axes can be designated A, B, C, U, V, W.
1.1.6
Decimal point programming
There are two notations for the interpretation of programming values without a decimal point in ISO Dialect mode:
S pocket calculator type notation
Values without decimal points are interpreted as mm, inch or degrees.
S standard notation
Values without decimal points are multiplied by a conversion factor. The setting is defined by MD 10884.
There are two different conversion factors,IS-BandIS-C.This evaluation refers to addresses X Y Z U V W A B C I J K Q R and F.
Example of linear axis in mm:
X 100.5 corresponds to value with decimal point: 100.5mm X 1000 pocket calculator type notation: 1000mm
standard notation: IS-B: 1000* 0.001= 1mm IS-C: 1000* 0.0001 = 0.1mm
ISO-Dialekt Milling
Table 1-1 Different conversion factors for IS-B and IS-C
Address Unit IS-B IS-C
Linear axis mm inch 0.001 0.0001 0.0001 0.00001
Rotary axis deg 0.001 0.0001
F feed G94 (mm/inch per min.) mm
inch 10.01 10.01 F feed G95 (mm/inch per min.) mm
inch 0.010.0001 0.010.0001 F thread pitch mm inch 0.010.0001 0.010.0001 C chamfer mm inch 0.0010.0001 0.00010.00001 R radius, G10 toolcorr mm inch 0.0010.0001 0.00010.00001 Q mm inch 0.0010.0001 0.00010.00001 I, J, K interpolation parameters mm inch 0.0010.0001 0.00010.00001 G04 X or U s 0.001 0.001
Table 1-1 Different conversion factors for IS-B and IS-C
Address Unit IS-B IS-C
A contour angle deg 0.001 0.0001 G74, G84 thread drilling cycles
$MC_EXTERN_FUNCTION_MASK Bit8 = 0 F feedrate like G94, G95 Bit8 = 1 F thread pitch
ISO dialekt Turning
Table 1-2 Different conversion factors for IS-B and IS-C
Address Unit IS-B IS-C
Linear axis mm
inch 0.0010.0001 0.00010.00001
Rotary axis deg 0.001 0.0001
F feed G94 (mm/inch pro min.) mm
inch 10.01 10.01 F feed G95 (mm/inch pro Umdr.)
$MC_EXTERN_FUNCTION_MASK Bit8 = 0 mm inch 0.010.0001 0.010.0001 Bit8 = 1 mm inch 0.00010.00000 1 0.0001 0.00000 1 F thread pitch mm inch 0.00010.00000 1 0.0001 0.00000 1 C chamfer mm inch 0.0010.0001 0.00010.00001 R radius, G10 toolcorr mm inch 0.0010.0001 0.00010.00001 I, J, K interpolation parameters mm inch 0.0010.0001 0.00010.00001 G04 X or U 0.001 0.001 A contour angle 0.001 0.0001
G76, G78 thread drilling cycles $MC_EXTERN_FUNCTION_MASK Bit8 = 0 F feedrate like G94, G95 Bit8 = 1 F thread pitch
G84, G88 thread drilling cycles $MC_EXTERN_FUNCTION_MASK
Bit9 = 0 G95 F mm
Table 1-2 Different conversion factors for IS-B and IS-C
Address Unit IS-B IS-C
Bit8 = 1 G95 F mm inch 0.00010.00000 1 0.0001 0.00000 1
1.1.7
Comments
In ISO dialect mode, round brackets are interpreted as comment characters. In Siemens mode, “;” is interpreted as a comment. To simplify matters, “;” is also interpreted as a comment in ISO dialect model.
If the comment start character “(” is used again within a comment, the comment will not be terminated until all open brackets have been closed again.
Example:
N5 (comment) X100 Y100
N10 (comment(comment)) X100 Y100 N15 (comment(comment) X100) Y100
In blocks N5 and N10 X100 Y100 is executed, in block N15 only Y100, as the first bracket is closed only after X100. Everything up to this position is interpreted as a comment.
1.1.8
Block skip
The skip character “/” can be anywhere within the block, even in the middle. If the programmed skip level is active at the moment of compiling, the block will not be compiled from this position to the end of the block. An active skip level therefore has the same effect as an end of block.
Example:
N5 G00 X100. /3 YY100 --> Alarm 12080,
N5 G00 X100. /3 YY100 --> No alarm when skip level 3 is active
Skip characters within a comment are not interpreted as skip characters. Example:
N5 G00 X100. ( /3 part1 ) Y100 ;even when skip level 3 is active, the
;Y axis will be traversed
The skip level can be /1 to /9. Skip values <1 >9 give rise to alarm 14060 The function is mapped onto the existing Siemens skip levels. In contrast to ISO Dialect Original, / and /1 are separate skip levels and therefore have to be activated separately.
Note
S “0” can be omitted for “/0”.
S The optional block skip function is processed when a part program is read to
the buffer register from either the tape or memory. If the switch is set ON after the block containing the optional block skip code is read, the block is not skip-ped.
S The optional block skip function is disregarded for program reading (input) and punch out (output) operation.
1.2
Basics of feed function
This section describes the feed function that specifies feedrate (distance per minute, distance per revolution) of a cutting tool.
1.2.1
Rapid traverse
Rapid traverse is used for positioning (G00) and manual rapid traverse (RAPID) operation. In the rapid traverse mode, each axis moves at the rapid traverse rate set for the individual axes; the rapid traverse rate is determined by the machine tool builder and set for the individual axes by using parameters. Since the axes move independently of each other, the axes reach the target point at different time. Therefore, the resultant tool paths are not a straight line generally.
Note
Setting units of rapid traverse rate 1 mm/min 0.1 inch/min 1 deg./min
Since the most appropriate value is set conforming to the machine capability, refer to the manuals published by the machine tool builder for the rapid traverse rate of your machine.
1.2.2
Cutting feed (F command)
NoteThe unit ”mm/min” is normally used for feedrate for cutting tool in this manual, as long as there is especially no explanation.
The feedrate at which a cutting tool should be moved in the linear interpolation (G01) mode or circular interpolation (G02, G03) mode is designated using address character F.
With a 6-digit numeral specified following address character F, feedrate of a cutting tool can be designated in units of “mm/min”.
Refer to the manuals published by the machine tool builder for programmable range of the F code.
The upper limit of feedrates could be restricted by the servo system and the me-chanical system. In this case, the allowable upper limit is set by MD and if a fee-drate command exceeding this limit value is specified, the feefee-drate is clamped at the set allowable upper limit.
An F command specified in the simultaneous 2-axis linear interpolation mode or in the circular interpolation mode represents the feedrate in the tangential direction.
Example of programming With the following program: G91 (incremental programming) G01 X40. Y30. F500; 300 mm/min 400 mm/min +Y +X Tangential velocity 500 mm/min
Fig. 1-1 F command in simultaneous 2-axis control linear interpolation
Example of programming With the following program: G91 (incremental programming) G03 X⋅⋅⋅ Y⋅⋅⋅ I⋅⋅⋅ F200; Center 200 mm/min Fy Fx +X +Y
In the simultaneous 3-axis control linear interpolation, an F command indicates the tangential feedrate. +Y End point 400 mm/min Start point +X +Z Example of programming
With the following program: G01 X⋅⋅⋅ Y⋅⋅⋅ Z⋅⋅⋅ F400;
Fig. 1-3 F command in simulaneous 3-axis control linear interpolation
In the simultaneous 4-axis control linear interpolation, an F command indicates the tangential feedrate.
F (mm∕min)=
Fx2+Fy2+Fz2+Fα2In the simultaneous 5-axis control linear interpolation, an F command indicates the tangential feedrate.
F (mm∕min)=
Fx2+Fy2+Fz2+Fα2+Fβ2Note
1. If “F0” is specified and F 1--digit feed is not used, an alarm occurs.
2. For an F command, a minus value must not be specified. If a minus value is specified for an F command, correct operation cannot be guaranteed.
1.2.3
F1-digit feed
It is possible to select a feedrate by specifying a 1-digit numeral (1 to 9) following address F. With this manner of designation of an F command, the feedrate preset for the specified numeral is selected.
The F1--Digit Feed function needs to be enabled by MD setting as follows: $MC_FIXED_FEEDRATE_F1_F9_ACTIV = TRUE: F1--Digit Feed enable $MC_FIXED_FEEDRATE_F1_F9_ACTIV = FALSE: F1--Digit Feed disable With the above mentioned MD set to FALSE, F1 to F9 in a machining program is interpreted as standard feed (F) programming, i.e. F2 = 2 mm/min. With the above mentioned MD set to TRUE, the feedrate to be selected in response to the desi-gnation of F1 to F9 should be set for the setting data indicated in Table 1-3. Feedrate 0 is activated if the corresponding value of the setting data is 0.
Table 1-3 Setting data used for preseting F1--digit feedrates
F command Setting data
F1 $SC_EXTERN_FIXED_FEEDRATE_F1_F9[0] F2 $SC_EXTERN_FIXED_FEEDRATE_F1_F9[1] F3 $SC_EXTERN_FIXED_FEEDRATE_F1_F9[2] F4 $SC_EXTERN_FIXED_FEEDRATE_F1_F9[3] F5 $SC_EXTERN_FIXED_FEEDRATE_F1_F9[4] F6 $SC_EXTERN_FIXED_FEEDRATE_F1_F9[5] F7 $SC_EXTERN_FIXED_FEEDRATE_F1_F9[6] F8 $SC_EXTERN_FIXED_FEEDRATE_F1_F9[7] F9 $SC_EXTERN_FIXED_FEEDRATE_F1_F9[8] Note: Input format=REAL
Note
1. If F1--digit command is activated by setting MD
$MC_FIXED_FEE-DRATE_F1_F9_ON = TRUE and F1 to F9 should not be used, be sure to pro-gram the feedrate F as a REAL value. For example, not F1 but F 1.0 for 1 mm/ min.
2. If “F0” is specified, it is switched to rapid traverse mode (G00) automatically. Subsequently, G01 needs to be specified in order to use F1--digit command. 3. When the DRY RUN switch is ON, feed commands are all executed at the
fee-drate set for the dry run operation.
4. The feed override function is invalid for the feedrate selected by the F1-digit command.
5. The feedrate set for setting data is retained in memory if the power is turned OFF.
6. In a macro call using G65/G66, the value commanded with address F is always stored in system varible $C_F, meaning that numeral values 1 to 9 will stored. 7. If F1--digit command is used in a machining program containing a cycle call
(G81 to G87), the feedrates are read from the corresponding setting data and stored into variable $C_F.
Example
$SC_EXTERN_FIXED_FEEDRATE_F1_9[0] = 1500.0 $SC_EXTERN_FIXED_FEEDRATE_F1_9[1] = 550.0
N10 X10 Y10 Z10 F0 G94 ; Positioning, rapid traverse N20 G01 X150 Y30 F1 ; feedrate 1500 mm/min active N30 Z0 F2 ; feedrate 550 mm/min active
N40 Z10 F0 ; Positioning, rapid traverse
1.2.4
Feed per minute function (G94)
When G94 is designated, a feedrate specified following address F is executed in units of “mm (inch)/min”.
1.2.5
Inverse time feed (G93)
When G93 is designated, a feedrate specified following address F is executed in units of “1/min”. G93 is a modal G code.
Example
2.1
Interpolation commands
This section describes the positioning commands and the interpolation commands that control the tool path along the specified functions such as straight line and arc.
2.1.1
Positioning (G00)
In the absolute programming mode (G90), the axes are moved to the specified point in a workpiece coordinate system, and in the incremental programming mode (G91), the axes move by the specified distance from the present position at a rapid traverse rate.
For calling the positioning, the following G codes can be used. Table 2-1 G codes for positioning
G code Function Group
G00 Positioning 01
Positioning (G00) Format
G00 X... Y... Z... ;
Explanation
When G00 is designated, positioning is executed. The program advances to the next block only when the number of lag pulses due to servo lag are checked after the completion of pulse distribution has reduced to the permissible value.
In the G00 mode, positioning is made at a rapid traverse rate in the simultaneous 3-axis (*5-axis) control mode. The axes not designated in the G00 block do not mo-ve. In positioning operation, the individual axes move independently of each other at a rapid traverse rate that is set for each axis. The rapid traverse rates set for the individual axes differ depending on the machine. For the rapid traverse rates of
Example of programming Y-axis 40. 40. X-axis Z-axis 40. G00 X40. Y40. Z40.;
Rapid traverse rate X--axis: 8 mm/min Y--axis: 8 mm/min Z--axis: 4 mm/min
Fig. 2-1 Positioning in simultaneous 3-axis control mode
Note
In the G00 positioning mode, since the axes move at a rapid traverse rate set for the individual axes independently, the tool paths are not always a straight line. Therefore, positioning must be programmed carefully so that a cutting tool will not interfere with a workpiece or fixture during positioning.
G0 Linear Mode
The G0 linear mode is valid if MD $MC_EXTERN_G0_LINEAR_MODE is set. In this case, all programmed axes move in linear interpolation and reach their target position at the same point of time.
2.1.2
Linear interpolation (G01)
FormatG01 X... Y... Z... F... ;
With the commands of G01, linear interpolation is executed in the simultaneous 3-axis (*5-axis) control mode. The axes not designated in the G01 block do not mo-ve. For the execution of the linear interpolation, the above command must be spe-cified.
Feedrate
Feedrate is designated by an F code. The axes are controlled so that vector sum (tangential velocity in reference to the tool moving direction) of feedrate of the desi-gnated axes will be the specified feedrate.
F (mm∕min)=
Fx2+Fy2+Fz2+( Fα2+Fβ2)(Fx: feedrate in the X-axis direction)
Note
If no F code is designated in the block containing G01 or in the preceding blocks, execution of a G01 block causes an alarm.
If the optional 4th and 5th axis are rotary axes (A-, B-, or C-axis), feedrates of basic three axes (X-, Y-, and Z-axis) and the optional 4th and 5th axis are determined in the machine data (MD).
End point
The end point can be specified in either incremental or absolute values. In G code system B and C it is determind corresponding to the designation of G90 or G91 (for details, see 3.2.1, “Absolute/Incremental Programming”).
Example of programming Y-axis 40. 40. Tangential velocity 0 Z-axis X-axis 40. G01 X40. Y40. Z40. F100; 100mm/min
Fig. 2-2 Linear interpolation
2.1.3
Circular interpolation (G02, G03)
Command formatTo execute the circular interpolation, the commands indicated in Table 2-2 must be specified.
Table 2-2 Commands necessary for circular interpolation Item Command Description
G17 Circular arc in the XY plane Plane designationg G18 Circular arc in the ZX plane G19 Circular arc in the YZ plane Direction of rotation G02 Clockwise (CW)
Direction of rotation
G03 Counterclockwise (CCW) Position of end point
Two axes among
X, Y, and Z End point position in a workpiece coordi-nate system Position of end point
Two axes among
X, Y, and Z Signed distance from the start point tothe end point Distance from the start
point to the center
Two axes among I, J, and K
Signed distance from the start point to the center
Radius of circular arc R Radius of circular arc Feedrate F Velocity along the circular arc
Plane designation
With the commands indicated below, a cutting tool moves along the specified circu-lar arc in the XY plane, ZX plane, or YZ plane so that the feedrate specified by the F command will be the tangential velocity of the arc.
S In the XY Plane G17 G02 (or G03) X⋅⋅⋅Y⋅⋅⋅R⋅⋅⋅(or I⋅⋅⋅J⋅⋅⋅) F⋅⋅⋅; S In the ZX Plane G18 G02 (or G03) Z⋅⋅⋅X⋅⋅⋅R⋅⋅⋅(or K⋅⋅⋅I⋅⋅⋅) F⋅⋅⋅; S In the YZ Plane G19 G02 (or G03) Y⋅⋅⋅Z⋅⋅⋅R⋅⋅⋅(or J⋅⋅⋅K⋅⋅⋅) F⋅⋅⋅;
To designate the circular interpolation mode (G02, G03), the plane of interpolation should be selected first by specifying the G17, G18, or G19. For the 4th and 5th axis, circular interpolation is allowed only when they are linear axes.
The G code designated to select the plane in which circular interpolation is execu-ted also selects the plane where tool radius offset (G41/G42) is execuexecu-ted. When the power is turned ON, the XY plane (G17) is automatically selected.
G17 XY plane, or Xαor Xβplane G18 ZX plane, or Zαor Zβplane G19 YZ plane, or Yαor Yβplane
If an optional linear 4th-axis is selected, circular interpolation is possible in the Xα, Zα, or Yαplane which includes the 4th-axis in addition to the XY, YZ, and ZX pla-nes. (α=U, V, or W)
S Circular interpolation in Xαplane
G17 G02 (or G03) X⋅⋅⋅α⋅⋅⋅R⋅⋅⋅(or I⋅⋅⋅J⋅⋅⋅) F⋅⋅⋅;
S Circular interpolation in Zαplane
G18 G02 (or G03) Z⋅⋅⋅α⋅⋅⋅R⋅⋅⋅(or K⋅⋅⋅I⋅⋅⋅) F⋅⋅⋅;
S Circular interpolation in Yαplane
If an optional linear 5th-axis is selected, circular interpolation is possible in the Xβ, Zβ, or Yβplane which includes the 5th-axis in addition to the XY, YZ, and ZX pla-nes. (β=U, V, or W)
S Circular interpolation in Xβplane
G17 G02 (or G03) X⋅⋅⋅β⋅⋅⋅R⋅⋅⋅(or I⋅⋅⋅J⋅⋅⋅) F⋅⋅⋅;
S Circular interpolation in Zβplane
G18 G02 (or G03) Z⋅⋅⋅β⋅⋅⋅R⋅⋅⋅(or K⋅⋅⋅I⋅⋅⋅) F⋅⋅⋅;
S Circular interpolation in Yαβplane
G19 G02 (or G03) Y⋅⋅⋅β⋅⋅⋅R⋅⋅⋅(or J⋅⋅⋅K⋅⋅⋅) F⋅⋅⋅;
S If address characters which represent the 4th- and 5th-axis are omitted as with
the commands of “G17 G02 X⋅⋅⋅R⋅⋅⋅(or I⋅⋅⋅J⋅⋅⋅) F⋅⋅⋅;” the XY plane is automatically selected for the interpolation plane. Circular interpolation with the 4th or 5th axis is not possible if these additional axes are rotary axes.
Rotation direction
The direction of arc rotation should be specified in the manner indicated in Fig. 2-3. G02 Clockwise direction (CW) G03 Counterclockwise direction (CCW) Y-axis G02 G03 X-axis XY plane (G17) X-axis G02 G03 G02 G03 Z-axis ZX plane (G18) Z-axis Y-axis YZ plane (G19)
Fig. 2-3 Rotation direction of circular arc
End point
The end point can be specified in either absolute or incremental values correspon-ding to the designation of G90 or G91 (not in G code system A).
(a) Absolute programming (G90) Y-axis 40. 20. End point G03 Start point Center --10. --30. 15. 55. X-axis (b) Incremental programming (G91) --40. Example of programming G17 G91 G03 X-40. Y20. I-30. J-10. F150; Y-axis 40. 20. End point G03 Center --10. --30. 15. 55. X-axis 20. G17 G90 G03 X15. Y40. I-30. J-10. F150; Example of programming
Fig. 2-4 End point of circular arc
If the specified end point is not on the specified arc, the arc radius is gradually changed from the start point to the end point to generate a spiral so that the end point lies on the specified arc.
(b) End point positioned inside the circumference rt= rs+ ( rs-- re) /θ¢θt rt re θt θ rs G01 X100 Y0 F200; G01 X50. Y0; --100 --50 0 100 50
(a) Correcting an arc
(c) End point lying outside the circumference --50
50
--100 --50 0
--100 100
Radius correction amount per unit angle
nr = ( rs-- re) /θ
G03 X--50 I--100; G03 X--100 I--50;
Center of arc
The center of arc can be specified in two methods -- designation of the distance from the start point to the center of the arc and designation of the radius of the arc.
S Specifying the distance from the start point to the center
Independent of the designated dimensioning mode (G90 or G91), the center of an arc must be specified in incremental values referenced from the start point.
S Specifying the radius
When defining an arc, it is possible to specify the radius by using address R in-stead of specifying the center of the arc by addresses I, J, or K. This is called “circular interpolation with R designation” mode.
S For the circular arc with the central angle of 180 deg. or smaller, use an R value
of “R > 0”.
S For the circular arc with the central angle of 180 deg. or larger, use an R value
of “R < 0”. Example of programming 180_or larger R < 0 Start point End point 180_or smaller R > 0 G17 G02 X⋅⋅⋅Y⋅⋅⋅R ⋅⋅⋅F⋅⋅⋅;
Fig. 2-6 Circular interpolation with radius R designation
Feedrate
In the circular interpolation mode, the feedrate can be specified in the same man-ner as in the linear interpolation mode. Refer to 2.1.2 “Linear interpolation (G01)”.
Supplements to circular interpolation
A circular arc extending to multiple quadrants can be defined by the commands in a single block. It is also possible to specify a full circle.
Example of programming Y-axis G02 10 20 X-axis G00 X0 Y0; G02 X0 Y0 I10 J0 F100;
Fig. 2-7 Full circle
With the commands of “G17 G02 (or G03) I⋅⋅⋅J⋅⋅⋅F⋅⋅⋅Ln;”, full-circle inter-polation is repeated by n times. If address L is omitted, interinter-polation is executed once. Execution of the commands with the single-block function ON causes full-circle interpolation to be interrupted after the execution of one full-full-circle interpola-tion.
2.1.4
Helical interpolation (G02, G03)
It is possible to execute linear interpolation in synchronization with circular interpo-lation with the axis which is not included in the circular interpointerpo-lation plane. This is called helical interpolation. The command format is indicated below.
S In the XY plane G17 G02 (or G03) X⋅⋅Y⋅⋅R⋅⋅(or I⋅⋅J⋅⋅) Z (α,β)⋅⋅F⋅⋅; S In the ZX plane G18 G02 (or G03) Z⋅⋅X⋅⋅R⋅⋅(or K⋅⋅I⋅⋅) Y (α,β)⋅⋅F⋅⋅; S In the YZ plane G19 G02 (or G03) Y⋅⋅Z⋅⋅R⋅⋅(or J⋅⋅K⋅⋅) X (α,β)⋅⋅F⋅⋅; S In the Xαplane G17 G02 (or G03) X⋅⋅α⋅⋅R⋅⋅(or I⋅⋅J⋅⋅) Z (β)⋅⋅F⋅⋅; S In the Zαplane G18 G02 (or G03) Z⋅⋅α⋅⋅R⋅⋅(or K⋅⋅I⋅⋅) Y (β)⋅⋅F⋅⋅; S In the Yαplane G19 G02 (or G03) Y⋅⋅α⋅⋅R⋅⋅(or J⋅⋅K⋅⋅) X (β)⋅⋅F⋅⋅;
S In the Xβplane G17 G02 (or G03) X⋅⋅β⋅⋅R⋅⋅(or I⋅⋅J⋅⋅) Z (α)⋅⋅F⋅⋅; S In the Zβplane G18 G02 (or G03) Z⋅⋅β⋅⋅R⋅⋅(or K⋅⋅I⋅⋅) Y (α)⋅⋅F⋅⋅; S In the Yβplane G19 G02 (or G03) Y⋅⋅β⋅⋅R⋅⋅(or J⋅⋅K⋅⋅) X (α)⋅⋅F⋅⋅;
Where,αandβare the linear 4th and 5th axes respectively, each representing any of U-, V-, and W-axis. If no 4th or 5th axis is specified as the end point command of the arc, any of the command format is selected among the commands in the XY plane, ZX plane, and YZ plane.
Example of programming Z 90 End point 100 Y F=10 R 100 X Start point G17 G03 X0 Y100. R100 Z90. F10;
Fig. 2-8 Helical interpolation
Note
An arc must be programmed within 360_range.
The feedrate specified with an F command indicates the tangential velocity in the three dimensional space constituted by the circular interpolation plane and the linear axis perpendicular to the interpolation plane.
2.2
Reference point return
2.2.1
Automatic return to reference point (G28)
FormatG28 X... Y... Z... ;
With the commands of “G28 X⋅⋅⋅Y⋅⋅⋅Z⋅⋅⋅;”, the numerically controlled axes are returned to the reference point. The axes are first moved to the specified posi-tion at a rapid traverse rate and then to the reference point automatically. This reference point return operation is possible in up to simultaneous 3-axis control. The axes not designated in the G28 block are not returned to the reference point.
Reference position
The reference position refers to a fixed position The position of the tool can easily be referenced by means of the reference position return function. This could, for instance, be used as the tool change position. A total of four reference positions can be determined by setting the coordinates using MD $_MA_REFP_SET_POS[0] to [3]). Example of programming: Z-axis Positioning A Z Start point Y B Reference point
(A fixed point in the machine) Z-axis deceleration LS
Reference point return operation Intermediate positioning point Y-axis deceleration LS
Y-axis (G90/G91) G28 X⋅⋅⋅Y⋅⋅⋅Z⋅⋅⋅;
Reference point return operation
Reference point return operation is the series of operations in which the axes re-turn to the reference point after the reference point rere-turn operation has been star-ted manually.
Reference point return is executed in the following manner:
S After the positioning at the intermediate positioning point B, the axes return
di-rectly to the reference point at a rapid traverse rate. The axes can be returned to the reference point in a shorter time compared to the normal reference point return operation that uses a deceleration limit switch for the individual axes.
S Even if point B is located outside the area in which reference point return is
allo-wed, the high-speed reference point return specification allows the axes to re-turn to the reference point.
S High-speed automatic reference point return is valid only when reference point
return is called by G28, and it does not influence manual reference point return operation.
Automatic reference point return for rotary axes
With a rotary axis, it is possible to execute the automatic reference point return the same as with a linear axis. With a rotary axis, if it has been moved by more than
360.000_from the reference point established first, reference point return is
ex-ecuted to the closest reference point in the preset direction of reference point re-turn. The illustration below shows how the reference point return is executed from points A and B. (The reference point return direction is determined by the setting of MD_$MA_REFP_CAM_IS_MINUS.
B B’ A
--720_ ---360_ 0 360_ 720_
+
A’
(Reference point return: Plus direction is selected for the reference point return direction)
Supplements to the automatic reference point return commands Tool radius offset and canned cycle
G28 must not be specified in the tool radius offset mode (G41, G42) or in a canned cycle.
!
WarningIssuing G28 will cancel tool radius offset (G40) followed by axes movement to-wards the reference point. For that reason, make sure to disable tool radius offset before issuing G28.Tool position offset
If G28 is specified in the tool position offset mode, positioning at the intermediate positioning point is made with the offset data valid. However, for the positioning at the reference point, the offset data are invalid and positioning is made at the abso-lute reference point.
Tool length offset
It is possible to cancel the tool length offset mode by G28 by changing the setting for a parameter. Although cancellation of the tool length offset mode is possible by G28, the tool length offset mode should be canceled before the designation of G28.
Machine lock intervention
The lamp for indicating the completion of return does not go on when the machine lock is turned on, even when the tool has automatically returned to the reference position. In this case, it is not checked whether the tool has returned to the refer-ence position even when a G27 command is specified.
2.2.2
Reference point return check (G27)
FormatG27 X... Y... Z... ;
This function checks whether the axes are correctly returned to the reference point at the completion of the part program which is created so that the program starts and ends at the reference point in the machine by specifying the commands of “G27 X⋅⋅⋅Y⋅⋅⋅Z⋅⋅⋅;”.
In the G27 mode, the function checks whether or not the axes positioned by the execution of these commands in the simultaneous 3-axis (* 5-axis) control mode are located at the reference point. For the axes not specified in this block, and not moved although the axis command specified, positioning and check are not execu-ted.
Operation after the check
When the position reached after the execution of the commands in the G27 block agrees with the reference point, the reference point return complete lamp lights. The automatic operation is continuously executed when all of the specified axes are positioned at the reference point. If there is an axis that has not been returned to the reference point, reference point return check error occurs and the automatic operation is interrupted.
Supplements to the reference point return check command and other operations
S If G27 is specified in the tool offset mode, positioning is made at the position
displaced by the offset amount and the positioning point does not agree with the reference point. It is necessary to cancel the tool offset mode before specifying G27. Note that the tool position offset and tool length offset functions are not canceled by the G27 command.
S Check is not made if G27 is executed while the machine lock state is valid even
for one axis. For example, if an X-axis movement command is specified in the G27 block while in the Z-axis neglect state, X-axis position is not checked.
S The mirror image function is valid to the direction of axis movement in the
refer-ence point return operation called by G27. To avoid a position unmatch error, the mirror image function should be canceled before executing G27.
2.2.3
Second to fourth reference point return (G30)
FormatG30 Pn X... Y... Z... ;
With the commands of “G30 Pn X⋅⋅⋅Y⋅⋅⋅Z;”, the axes are moved to P2 (se-cond reference point), P3 (third reference point*), or P4 (fourth reference point*) in the simultaneous 3-axis (* 5-axis) control mode after the positioning at the specified intermediate positioning point. If “G30 P3 X30. Y50.;” is specified, the X- and Y-axis return to the third reference point. If “Pn” is omitted, the second reference point is selected. The axes not specified in the G30 block do not move.
Reference point positions
The position of each reference point is determined in reference to the first refer-ence point. The distance from the first referrefer-ence point to each of the referrefer-ence points is set for the following machine data:
Table 2-3 Reference points
Item MD
3rd reference point $_MA_REFP_SET_POS[2] 4th reference point $_MA_REFP_SET_POS[3]
Supplements to the 2nd to 4th reference point return commands
S For the points to be considered to for the execution of G30, refer to the
supple-ments in 2.2.1, “Automatic Return to Reference Point (G28)”.
S For the execution of G30, reference point return must have been completed
after power-ON either manually or by the execution of G28. If an axis for which reference point return has not been completed is included in the axes specified in the G30 block, an alarm occurs.
2.2.4
Rapid lift with G10.6
G10.6 <AxisPosition> is used to activate a retraction position for the rapid lifting of a tool (e.g., in the event of a tool break). The retraction motion itself is started with a digital signal. The second NC fast input is used as the start signal.
Machine data $MN_EXTERN_INTERRUPT_NUM_RETRAC is used to select a different fast input (1 -- 8).
In Siemens mode, the activation of the retraction motion comprises a number of part program commands.
generates internally in the NCK
N10 SETINT (2) PRIO=1 CYCLE3106 LIFTFAST ; Activate interrupt input
N30 LFPOS ; Select lift mode
N40 POLF[X]=19.5 POLF[Y]=33.3 ; Program lift positions
; for x19.5 and y33.3
N70 POLFMASK(X, Y) ; Activate retraction
; of x and y axis
G10.6 is used to group these part program commands internally in a command set. In order to activate an interrupt input (SETINT(2)), an interrupt program (ASUP) must also be defined. If one has not been programmed, the part program will not be able to continue as it will be interrupted with a reset alarm once the retraction motion is complete. The interrupt program (ASUP) CYCLE3106.spf is always used for fast retraction with G10.6. If the part program memory does not contain program CYCLE3106.spf, alarm 14011 “Program CYCLE3106 not available or not enabled for processing” is output in a part program set with G10.6.
The behavior of the control following fast retraction is specified in ASUP
CYCLE3106.spf. If the axes and spindle are to be stopped following fast retraction, M0 and M5 must be programmed accordingly in CYCLE3106.spf.
If CYCLE3106.spf is a dummy program, which only contains M17, the part program will continue uninterrupted following fast retraction.
If G10.6 <AxisPosition> is programmed to activate fast retraction, when the input signal of the second NC fast input changes from 0 to 1, the motion currently in progress is interrupted and the position programmed in set G10.6 is approached at rapid traverse. The positions are approached absolutely or incrementally according to the program settings in set G10.6.
The function is deactivated with G10.6 (without positional data). Fast retraction by means of the input signal of the second NC fast input is disabled.
Siemens
To some extent, the fast retraction function with G10.6 can be achieved using function POLF[<AxisName>] = <RetractionPosition>. This function will also retract the tool to the programmed position. However, it does not support the remainder of the ISO dialect original functionality. If the interrupt point cannot be approached directly, obstructions must be bypassed manually.
References: /PGA/, Programming Guide Advanced, Chapter “Extended Stop and Retract”
Restrictions
3.1
The coordinate system
A tool position is clearly determined by coordinates within a coordinate system. These coordinates are defined by program axes. For example, if there are 3 pro-gram axes involved designated as X, Y, and Z, the coordinates are specified as: X... Y... Z...
The above command is called a dimension word.
Z Y 55.0 30.0 44.0 X
Fig. 3-1 Tool position specified by X... Y... Z...
The following three coordinate systems are used to determine the coordinates: 1. Machine coordinate system (G53)
2. Workpiece coordinate system (G92) 3. Local coordinate system (G52)
3.1.1
Machine coordinate system (G53)
The machine zero point represents the point that is specific to a machine and ser-ves as the reference of the machine. A machine zero point is set by the MTB for each machine tool. A machine coordinate system consists of a coordinate system with a machine zero point at its origin.
A coordinate system with a machine zero point set at its origin is referred to as a machine coordinate system. By using manual reference position return after power-on the machine coordinate system is set. Once set, the machine coordinate system remains unchanged until power--off.
Format
(G90) G53 X... Y... Z... ;
X, Y, Z, Absolute dimension word
How to select a machine coordinate system (G53)
Once a position has been determined in terms of machine coordinates, the tool moves to that position in rapid traverse. G53 is a one--shot G code. Thus, any command based on the selected machine coordinate system is effective only in the block where G53 is issued. The G53 command has to be determined by using ab-solute values. Program the movement in a machine coordinate system based on G53 whenever the tool should be moved to a machine--specific position.
Cancel of the compensation function
If $MN_G53_TOOLCORR = 0, G53/G153/SUPA is non--modal suppression of zero offsets, tool length compensation and tool radius compensation, however, remain active.
If $MN_G53_TOOLCORR = 1, G53/G153/SUPA is non--modal suppression of zero offsets, and active tool length and tool radius compensation.
G53 specification right after power--on
At least one manual reference position return must be applied after power--on, since the machine coordinate system must be set before the G53 command is de-termined.
Reference
A machine coordinate system is set so that the reference position is at the coordi-nate values set using MD $MC_CHBFRAME_POWON_MASK Bit 0 whenever ma-nual reference position return is applied after power--on.
Machine coordinate system Machine zero
Reference position
α β
Fig. 3-2 Reference
3.1.2
Workpiece coordinate system (G92)
Prior to machining, a coordinate system for the workpiece, the so--called workpiece coordinate system, needs to be established. This section describes the various methods of how to set, select, and change a workpiece coordinate system.
How to set a workpiece coordinate system
The following two methods can be used to set a workpiece coordinate system: 1. Using G92
A workpiece coordinate system is set by determining a value subsequent to G92 within the program.
Format
(G90) G92 X... Y... Z... ;
Examples
Example 1: G92X30.5Z27.0;
(The tip of tool is the start point.)
Z X 30.5 27.0 0 Fig. 3-3 Example 1 Example 2: G92X500.0Z1100.0;
(The base point on the tool holder is the start point.)
Z X 500.0 1100.0 Base point 0 Fig. 3-4 Example 2
Whenever an absolute command is issued, the base point moves to the targeted position. The difference in position between the tool tip and the base point is com-pensated by the tool length offset in order to move the tool tip to the targeted posi-tion.
3.1.3
Resetting the work (G92.1)
With G92.1 X.., you can reset an offset coordinate system before shifting it. This resets the work to the coordinate system which is defined by the actively settable work offsets (G54--G59). If not settable work offset is active, the work is set to the reference position. G92.1 resets offsets which have been performed by G92 or G52. Only axes which are programmed are reset.
Example 1:
N10 G0 X100 Y100 ;Display: WCS: X100 Y100 MCS: X100 Y100 N20 G92 X10 Y10 ;Display: WCS: X10 Y10 MCS: X100 Y100 N30 G0 X50 Y50 ;Display: WCS: X50 Y50 MCS: X140 Y140 N40 G92.1 X0 Y0 ;Display: WCS: X140 Y140 MCS: X140 Y140
Example 2:
N10 G10 L2 P1 X10 Y10
N20 G0 X100 Y100 ;Display: WCS: X100 Y100 MCS: X100 Y100 N30 G54 X100 Y100 ;Display: WCS: X100 Y100 MCS: X110 Y110 N40 G92 X50 Y50 ;Display: WCS: X50 Y50 MCS: X110 Y110 N50 G0 X100 Y100 ;Display: WCS: X100 Y100 MCS: X160 Y160 N60 G92.1 X0 Y0 ;Display: WCS: X150 Y150 MCS: X160 Y160
3.1.4
How to select a workpiece coordinate system
As described below, the user may choose from set workpiece coordinate systems. 1. G92
Absolute commands work with the workpiece coordinate system once a work-piece coordinate system has been selected.
2. Selecting from workpiece coordinate systems previously set up by using the HMI.
A workpiece coordinate systems can be selected by determining a G code from G54 to G59, and G54 P{1...100}.
Workpiece coordinate systems are set up subsequent to reference position re-turn after power--on. The default coordinate system after power--on is G54.
Examples
X 35.0
Y
60.0
Workpiece coordinate system 2 (G55)
Positioning to (X=35.0, Y=60.0) in workpiece coordinate system G55. G90 G55 G00 X35.0 Y60.0 ;
Fig. 3-5 Workpiece coordinate system G55
3.1.5
Instantaneous mapping of the ISO functions onto Siemens
fra-mes
(until powerline 7.04.2, solution line 1.4)
By changing an external workpiece zero point offset value or workpiece zero point offset value, the workpiece coordinate systems determined through G54 to G59 as well as G54 P{1 ... 93} are changed.
In order to change an external workpiece zero point offset value or workpiece zero point offset value, two methods are available.
1. Entering data using the HMI panel 2. By program command G10 or G92
adjustable FrameG54 - G59 NV $P_UIFR G54 P1..93 NV
$P_CHBFRAME[0] G92 set value $P_CHBFRAME[0] EXOFS
progr. Frame G52 NV $P_BFRAME G51 scale
$P_CHBFRAME[1] G51.1 Mirror image at progr. axis $P_CHBFRAME[2] G68 2DRot / 3DRot
$P_CHBFRAME[3] G68 3DRot
Channelspecific Basic Frames
Fig. 3-6 ISO-dialect coordinate systems
G54P1...P93 (changes at Siemens Mode G505--G597 ) G58 (changes at Siemens Mode G505 )
G59 (changes at Siemens Mode G506 )
Format
Changing by G10: G10 L2 Pp X... Y... Z... ;
p=0: External workpiece zero point offset value (EXOFS)
p=1 to 6: Workpiece zero point offset value correspond to workpiece coordi-nate system G54 to G59
X, Y, Z: Workpiece zero point offset for each axis in case of absolute com-mand (G90).
Value to be added to the set workpiece zero point offset for each axis in case of an incremental command (G91).
p=1 to 93: Workpiece zero point offset value correspond to workpiece coordi-nate system G54 P1 ... P93
X, Y, Z: For an absolute command (G90), workpiece zero point offset for each axis.
Value to be added to the set workpiece zero point offset for each axis in case of an incremental command (G91).
Changing by G92: G92 X... Y... Z... ;
Explanations
Changing by using G10
Each workpiece coordinate system can be changed separately by using the G10 command.
If G10 is executed in the main run, G10 must execute an internal STOPRE com-mand before writing the value.
In MD $MC_EXTERN_FUNCTION_MASK Bit 13, you can configure whether the G10 command shall execute an internal STOPRE. The machine data bit affects all G10 commands in ISO--Dialect--T and ISO--Dialect--M.
Changing by using G92
A workpiece coordinate system (selected with a code from G54 to G59 and G54 P{1 ...93}) is shifted to set a new workpiece coordinate system by specifying G92 X... Y... Z.... This way, the current tool position is made to match the specified coordinates. If X, Y, Z, is an incremental command value, the work coordinate system is defined so that the current tool position coincides with the result of adding the specified incremental value to the coordinates of the previous tool position (coordinate system shift). Subsequently, the value of the coordinate sy-stem shift is added to each individual workpiece zero point offset value. In other words, all of the workpiece coordinate systems are systematically shifted by the same value amount.
Example
When the tool is positioned at (190, 150) in G54 mode, workpiece coordinate sy-stem 1 (X’ -- Y’) shifted by vector A is created whenever G92X90Y90; is comman-ded. X’ X Y Y’ 150 60 90 90 100 190 A
G54 workpiece coordinate system
Tool position
Fig. 3-7 Example of the setting of coordinates
3.1.6
Uncoupling the frames between the Siemens and the ISO
mo-des
(with powerline 7.04.02 or solution line 1.4 and higher)
In the ISO mode, various G codes occupied the programmable frame $P_FRAME, the settable frame $P_UIFR and three base frame $P_CHBFRAME[ ]. If you switch from the ISO mode to the Siemens mode, these frames will not be available to the user of the Siemens language. This pertains to:
G52 Programmable zero offset --> progr. frame $P_PFRAME G51 Scaling --> progr. frame $P_BFRAME SCALE
G54--G59 Zero offset --> settable frame $P_UIFR G54 P1..100 Zero offset --> settable frame $P_UIFR G68 3D rotation --> base frame $P_CHBFRAME[3] G68 2D rotation --> base frame $P_CHBFRAME[2] G51.1 Mirroring --> base frame $P_CHBFRAME[1] G92 Set actual value--> base frame $P_CHBFRAME[0]S G10 L2 P0 Ext. zero offset --> base frame $P_CHBFRAME[0]S
To uncouple the concerned frames between the Siemens and the ISO modes, four new system frames are provided: $P_ISO1FRAME to $P_ISO4FRAME. The
fra-STEM_FRAME_MASK, bits 7 to 10. The reset behavior is set using the machine data 24006: $MC_CHSFRAME_RESET_MASK, bits 7 to 10.
Fig. 3-8 shows the G codes in the ISO mode and the assignment of the frames if the system frames $P_ISO1FRAME to $P_ISO4FRAME, $P_SETFRAME and $P_EXTFRAME are created.
Settable frames G54 - G59 ZO $P_UIFR G54 P1..100 ZO
$P_SETFRAME G92 Set actual va-lue
$P_ISO4FRAME G51 Scale
$P_EXTFRAME G10 L2 P0 ExtOffset ZO
$P_ISO2FRAME G68 2DRot / 3DRot $P_ISO3FRAME G68 3DRot
$P_ISO1FRAME G51.1 Mirroring on progr. axis $P_PFRAME G52 ZO
Fig. 3-8 Mapping of the ISO functions to the ISO frames and Siemens frames
Note
If the new frames are created, the ISO G codes will write to these frames; if they are not created, the frames are written as described in Section 3.1.5.
The tables on the following pages illustrate which G codes write to which frames, how they are created and how the reset behavior of the frames must be set to achieve a compatible behavior to the ISO mode original. The reset behavior can be set deviating from the ISO mode original using the MDs mentioned above. This can be necessary when switching from the ISO mode to the Siemens mode.
G51: Scaling
G51 X10 writes to $P_ISO4FRAME Component TRANS, SCALE
Creates $MC_MM_SYSTEM_FRAME_MASK Bit10 = 1 Reset behavior Delete frame
$MC_CHSFRAME_RESET_MASKBit 10 = 0
G52:Programmable zero offset
G52 X10 writes to $P_PFRAME Component TRANS Creates Always present
Reset behavior Is deleted in case of RESET
G54 -- G59 P1...100: Settable zero offset
G52 -- G59 $P_UIFER Component TRANS Creates Always present
Reset behavior G54 is active after RESET
$MC_EXTERN_GCODE_RESET_VALUES[13] = 1
G68 3DRot
G68 X Y I J K R $P_ISO3FRAME Component TRANS, SCALE
Creates $MC_MM_SYSTEM_FRAME_MASK Bit 9 = 1 Reset behavior Delete frame
$MC_CHSFRAME_RESET_MASKBit 9 = 0
G68 2DRot
G68 X Y R $P_ISO2FRAME Component TRANS, SCALE
Creates $MC_MM_SYSTEM_FRAME_MASK Bit 8 = 1 Reset behavior Delete frame
$MC_CHSFRAME_RESET_MASKBit 8 = 0
G51.1: Mirroring
G51.1 X Y $P_ISO1FRAME Component TRANS, MIRROR
Creates $MC_MM_SYSTEM_FRAME_MASK Bit 7 = 1 Reset behavior Delete frame
$MC_CHSFRAME_RESET_MASKBit 7 = 0
G92: Set actual value
G92 X Y R $P_SETFRAME Component TRANS
Creates $MC_MM_SYSTEM_FRAME_MASK Bit 0 = 1 Reset behavior Frame is maintained after RESET
$MC_CHSFRAME_RESET_MASKBit 0 = 1
G10 L2 P0
G10 L2 P0 $P_EXTFRAME Component TRANS
Creates $MC_MM_SYSTEM_FRAME_MASK Bit 1 = 1 Reset behavior Delete frame
$MC_CHSFRAME_RESET_MASKBit 1 = 0
If all frames are created, it is no longer necessary for the ISO mode that the fra-mes are configured using the FINE component. The machine data 18600: $MN_MM_FRAME_FINE_TRANS need not be set to ”1”. If you switch from the ISO mode to the Siemens mode and if the Siemens mode uses a function which requires a fine offset (e.g. G58, G59), $MN_MM_FRAME_FINE_TRANS must re-main ”1”.
For easier programming, a kind of sub--workpiece coordinate system can be set whenever a program is created in a workpiece coordinate system. Such a sub--coordinate system is called a local sub--coordinate system.
Format
G52 X... Y... Z... ; Local coordinate system set G52 X0 Y0 Z0 ; Local coordinate system cancel X, Y, Z: Local coordinate system origin
Explanations
A local coordinate system can be set in all the workpiece coordinate systems (G54 to G59) by specifying G52 X... Y... Z...;. Within the workpiece coordinate system, the origin of each local coordinate system is set to the position determined by X, Y, and Z.
Whenever a local coordinate system is set, the motion commands subsequently commanded in the absolute mode (G90) correspond to the coordinate values wit-hin the local coordinate system. By determining the G52 command through the zero point of a new local coordinate system in the workpiece coordinate system, the local coordinate system can be changed.
Match the zero point of the local coordinate system with that of the workpiece coor-dinate system in order to cancel the local coorcoor-dinate system and to determine the coordinate value within the workpiece coordinate system.
The position value displayed as the coordinate value of workpiece coordinate sy-tem refers to the zero point of workpiece coordinate syssy-tem even if the local coor-dinate system is set by specifying G52.
Machine coordinate system origin Reference point
(Local coordinate system) (G55 : Workpiece coordinate system 2)
(Local coordinate system)
(G59 : Workpiece coordinate system 6) G54
G56 G57 G58
(Machine coordinate system)
3.1.8
Plane selection (G17, G18, G19)
The plane where circular interpolation, tool radius offset, and coordinate system rotation are executed is selected by specifying the following G code.
Table 3-1 Plane selection G codes
G code Function Group
G17 XY plane 02
G18 ZX plane 02
G19 YZ plane 02
A plane is defined in the following manner (in the case of XY plane):
The horizontal axis in the first quadrant is “+X-axis” and the vertical axis in the same quadrant “+Y-axis”.
+Y-axis
0 +X-axis
Fig. 3-10 Plane selection
S When the power is turned ON, the XY plane (G17) is selected.
S Axis move command of a single axis can be specified independent of the
selec-tion of plane by G17, G18, and G19. For example, the Z-axis can be moved by specifying “G17 Z ....;”.
S Execution of a canned cycle is possible only in the G17 plane (hole machining
axis: Z-axis).
S The plane on which the tool radius offset is executed by the G41 or G42
com-mand is determined by the designation of G17, G18 or G19; the plane that inc-ludes the rotary 4th-or 5th-axis cannot be selected as the offset plane.
3.1.9
Parallel axes (G17, G18, G19)
Using the function G17 (G18, G19) <axis name>, an axis parallel to one of the three basic axes of the coordinate system can be activated.
Example
G17 U0 Y0
Parallel axis U is activated, replacing the X axis within the G17 plane.
Explanations
S The parallel axes command is emulated using the Siemens function
GEOAX(..,..). With the help of this function, a geometrical axis can be exchanged by any available channel axis.
S For each of the geometrical axes, a related parallel axis can be determined
using machine data
$MC_EX--TERN_PARALLEL_GEOAX[].
S Only axes related to the programmed plane (G17, G18, G19) can be
exchanged.
S Usually, when exchanging axes, all offsets (frames) except for handwheel and
external offsets, work area limitation and protection zones are cleared. Be sure to set the following machine data to prevent from clearing such values:
Offsets (frames)
$MN_FRAME_GEOAX_CHANGE_MODE Protection zones
$MC_PROTA--REA_GEOAX_CHANGE_MODE Work area limitation
$MN_WALIM_GEOAX_CHANGE_MODE
S Refer to machine data description for detail.
S Alarm 12726 is issued, if a basic axis is programmed together with its parallel
3.1.10
Rotation of coordinate system (G68, G69)
Does not work with SINUMERIK 802D sl.
Using the G68 and G69 commands Features of G68 and G69
For the rotation of a coordinate system, the following G codes are used. Table 3-2 Coordinate system rotation G codes
G code Function Group
G68 Coordinate system rotation 16 G69 Cancel of coordinate system
rotation 16
G68 and G69 are modal G codes belonging to 16-group. When the power is turned ON and when the NC is reset, G69 is automatically selected.
The G68 and G69 blocks must not include other G codes.
The coordinate system rotation which is called by G68 must be canceled by G69.
Command format
G68 X_ Y_ R_ ; X_, Y_ :
Absolute coordinate values of the center of rotation. If omitted, the actual position is regarded as center of rotation.
R_ :
Rotation angle, absolute or incremental depending on G90/G91. If omitted, the va-lue of the channel specific setting $SC_DEFAULT_ROT_FACTOR_R is used as rotation angle.
S By specifying “G17 (or G18, G19) G68 X⋅⋅⋅Y⋅⋅R⋅⋅; ”, the commands
spe-cified in the following blocks are rotated by the angle spespe-cified with R around the point (X, Y). Rotation angle can be specified in units of 0.001 degree.
R
(X, Y)
X, Y: Center of rotation R : Angle of rotation
(CCW rotation is “+”; to be specified in an absolute value)
Fig. 3-11 Rotation of coordinate system
S By specifying “G69;”, the coordinate system rotation mode is canceled. S The G68 command is executed in the plane that has been selected when the
G68 command is specified. The 4th and 5th axis must be linear axes. G17 : XY plane or Xα, Xβplane
G18 : ZX plane or Zα, Zβplane G19 YZ plane or Yα, Yβplane
Supplements to the coordinate system rotation commands
S MD $MC_MM_NUM_BASE_FRAMES must be set to a value >= 3 if coordinate
system rotation is used.
S If “X” and “Y” are omitted, the present position when the G68 block is executed
is taken as the center of rotation.
S When the coordinate system is rotated, position data are given in the rotate