0% found this document useful (0 votes)
7 views91 pages

CNC Programming FANUC Control

This document describes the main ISO programming codes used in CNC machining centers with FANUC control. It explains the G codes for tool movements, the M codes for auxiliary functions such as turning on the spindle or coolant, and the T, S, F codes for tool change, spindle speed, and feed rate. It also covers the coordinate system and how to program absolute and incremental positions. The aim is to provide an introduction.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
7 views91 pages

CNC Programming FANUC Control

This document describes the main ISO programming codes used in CNC machining centers with FANUC control. It explains the G codes for tool movements, the M codes for auxiliary functions such as turning on the spindle or coolant, and the T, S, F codes for tool change, spindle speed, and feed rate. It also covers the coordinate system and how to program absolute and incremental positions. The aim is to provide an introduction.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 91

IMOCOM

TRAINING CENTER
TECHNOLOGICAL
PROGRAMMING FOR CENTER OF
CNC MACHINING

WITH CONTROLFANUC
PROGRAMMING LANGUAGE
ISO
The ISO standardized the programming language for
CNC machines.

Many control manufacturers have developed a


own language for its controls known as
conversational, but a programmer who masters the
ISO programming can be well defended in most
of the controls, that's why we will focus on this
programming language focused on controls
FANUC, which are the most used in our industry.

This programming language is composed of codes.


composed of letters followed by numbers, by means of
of which the movement orders are given and
activation of machine functions.
PROGRAMMING CODES
ISO
CODESG: were originally created to
specifying the geometry of the trajectory of the
tool, if it advances quickly, or mechanizing in
line or arc. These codes are made up of the
letter G followed by numbers, range from G0 to G
G99.

MISCODES: Miscellaneous or auxiliary functions, are


they were initially created to automate the functions that
the operator would perform, like turning on the spindle, igniting
the refrigerant, etc. These codes range from M0
up to M99.
PROGRAMMING CODES
ISO

CODES: Speed = with this S = Speed


code programs the
spindle speed in rpm
(SPINDLE SPEED), the code
S is accompanied by the value
numeric of the r.p.m to the
what will turn the spindle.
Example, if it is scheduled
The spindle will rotate at 2300
r.p.m. The value of the speed
of the spindle will be programmed from
according to the material to be worked on and
to the type of tool
to use.
PROGRAMMING CODES
ISO
CODIGOF: FEED =
feeding or progress of
F = Feed
machining is the speed
what moves the machine
in the operations of
machining, in the center of
machining this speed is
program in millimeters per
minute, the F code goes
accompanied by value
numerical progress of
machining. Example, if it
F500 program, the machine is
It will move at 500 mm/minute.
PROGRAMMING CODES
ISO
CODE: TOOL
the tool of work
programming of the
T = Tool
tools are made of
agreement to the order
operational of the process.
The T code goes
accompanied by the number
of the tool that has been
to call to work, T1,
T2, T3, etc.
ISO PROGRAMMING CODES

CODES X, Y, Z: in a center of
vertical machining, the X axis moves the X, Y, Z
work table from left to
right and vice versa. The Y axis moves
the table back and forth.
The Z axis moves the head along with the
work tool from top to bottom
down and vice versa.
These codes are accompanied by
numerical values example: X120.
Y250 or Z169. in this way it
they program the coordinates to where
the machine must move according to the
given order.
The X, Y axes define the geometry of
a contour or the positioning of
holes.
The Z axis defines the height or depth
of machining .
ISO PROGRAMMING CODES
CODES A, B, C: these codes
they design the fourth axis, which is a
axis that rotates in degrees and is
also controlled by the CNC.

The designation A, B, or C,
it depends on whether the device is
parallel to the X, Y, Z axes.

In the machining centers


the horizontal 4 axis is standard and
it is referred to with the letter B,
example: if B90 is programmed. the
the axis will rotate 90 degrees.

The codes seen earlier


they are the most important,
later in the
programming will be explained by others
within the format of each
code.
Axis B
4 AXIS (AXIS A)

The fourth axis installed parallel to the X axis, as seen in


the photograph is programmed with coordinate A, being a
The rotating axis is worked in degrees.
CODES M
In a programming block, a is programmed
just code M.

M00:intermediate stop in the program, it


use for the operator to perform some
necessary intervention before continuing with
the normal sequence of the program
generally to top off a piece.

O0002;
N5 M6T1;
N10 G0X0Z0;
N15M00 (SET THE PIECE TO THE TOP);
---- N20 G0 X50. Z100;
N25 M6T2;
M01: scheduled optional stop (optional stop):
It has the same utility as code M00, but the machine
it stops when it reads the code if the operator has
the optional stop button is activated, if you have not activated it the
machine does not execute the intermediate stop.

¨¨ ¨¨¨ ¨¨
N90 G1Z-45.F140;
N95 G0Z100.
N100M01(VERIFY INNER DIAMETER);
N105 G0X36.Y30.
N110 G1Z-45.
M02:end of program, it
use to close the structure
of the program, currently it
use code M30 more.

N225 G0 Z100.;
N230M02

M03: spindle rotation in direction


schedule, spindle CW (clock
wise).
This code is accompanied by
spindle speed code
And the numerical value of the
rpm. The direction of rotation is
determine by looking at the screw
from above

N125 M6T4;
N130M03S1200
N135 G0 X20. Y67.
M04: turn spindle in direction
counterclockwise, spindle CCW
(counterclockwise).
This code works too
accompanied by the codeSy
the RPM.

N125 M6T9
N130M04S2000
N135 G0 X20. Y45.

M05: detener husillo, spindle


stop.
This code is used on
everything before changing the
direction of rotation of the spindle.
N70 G0Z100.M05;
N75 M6T7
N80 G0X0Y54.M3;
M6: automatic tool change, the ATC (automatic tool
Change) already the previous tool in the magazine and install the new one.
tool commanded on the spindle, accompanied by code T
and the tool number to be placed in the spindle.

M6T3;
G0 X2. Y40. M3 S1300;
M08:turn on the refrigerant,
(coolant on), for what
it works with this code
you must activate the coolant button
car in the control panel. It
must program after
each tool change.

N50 M6T4;
N55 G0X32.Z2.M8;

M09: turn off the coolant.


(coolant off).

N65 G0 X100 Z100 M9;


M13:light the spindle
schedule and the refrigerant

N50 M6 T3;
N55 G0 X32. Y2.M13S1200

M14: turn on the anti-spindle


schedule and the cooler.
M19: align spindle.
(spindle orient)

M29: activate rigid threading.


Rigid tapping.
This code is used for
synchronize the rpm with the
advance for revolution in the
rigid threading cycle with the
code G84.
M30: end of program

Close the program structure, turn off all the functions and
in addition, it features a completed piece.

O0024;
N5 M6 T4;
¨¨¨¨¨¨¨¨¨¨¨¨¨
¨¨¨¨¨¨¨¨¨¨¨¨¨
N450M30

M95:contador de piezas, (part count)


It is scheduled when within a work cycle products are manufactured.
various pieces. The last piece will be counted with the code M30.
M98: call subprogram a
to work. It is used to call
a subprogram from a
main program, with the lyrics
P designates the number of
subprogram to call.

M99: end of subprogram, this


code closes the structure of
subprogram.
Coordinate system
MECHANICAL COORDINATES

To the coordinate system of


the machine or mechanics is referred to
llama: machine reference,
machine zero or Home.

The machine zero or Home


is determined
generally by microswitch
at the ends of the route
of the axes X, Y, Z, is a
fixed coordinate system
in the machine.
Mechanical coordinates - zero piece
Mechanical coordinates - zero piece
ABSOLUTE COORDINATES
The zero point of the part can be fixed at
any part of the piece to
convenience of the programmer,
generally it focuses on a
corner on the X, Y axes on the axis
Preferably on the surface
from the piece. It can also be fixed
in the center of the piece, if the
machining is symmetrical with
regarding the origin.
Restricted:
G90 = Absolute measurements
There are two possibilities to define the nominal positions where it has to go.
the tool to be machined:

Absolute measures:
The values X, Y, Z of the nominal position are always programmed in relation to the
zero of the part, all values are measured from the zero of the part to where
the tool has to arrive (They are programmed with the code G90 absolute
command).
G91 = Incremental or relative measurements
The values X, Y, Z of the position measured from the are programmed.
the last point where the working tool is located, that is to say
the increase that the tool needs to move for
reach the next destination point. The sign indicates in which direction
the tool must be moved regardless of whether it is
find in a positive or negative quadrant of the system of
Cartesian coordinates (They are programmed with the code G91
increment command)
EXERCISE 1
EXERCISE 1

ABSOLUTES G90
X YZ
P1 15 30 0
P2 15 30 40
P3 50 30 40
P4 70 30 0
P5 70 0 0
EXERCISE 1

INCREMENTAL
G91
X Y Z
P1 15 30 0
P2 0 0 40
P3 35 0 0
P4 20 0 - 40
P5 0 - 030
EXERCISE 2
Code G
The G codes will be explained below.
necessary for milling programming
C.N.C. Within the G codes are found
the modal codes that remain activated in
the program until they are canceled or
changed for others.
The basic G codes are G0, G1, G2, G3, and
G4. These codes are common to most
controls, from then on the codes
can vary according to the manufacturer of
control or to the standardization that I used (standard
DIN, ISO, etc.
POSITIONING OF THE TOOL BEFORE AND
AFTER MECHANIZING
G0 Fast positioning: This is a
modal code, it is used to bring the tool closer to the part of
work in rapid progress before starting the machining for
move away from this after having machined or to carry out
movements from one point to another in empty space. The machine moves
at maximum speed to the programmed coordinates.
The programming format is as follows:

G0X32.Y5.
G0Z2.

In this case, the machine approaches the workpiece from


where it is, up to the coordinate X32. Y5. and then it will approach 2
mm from the surface of the piece. The three can be programmed.
coordinates in a single block but there is a risk of
to crash with the clamps or fastening devices of the piece.

At the end of a machining process, a retraction is programmed on the Z axis to


a safe height where one can move to the location
for another machining, or to finish the program:

G0Z100.
M30;
MACHINING ON LINEAR TRAJECTORY
G1 Linear Machining
interpolation
Also called linear interpolation. This
code is used to mechanize everything
straight line trajectory. The machine is
move with machining advance
programmed with codeF. When programming
the X and Y axes at the same time, are generated
easily diagonal trajectories
(linear interpolation of the two axes). The
code G1 is modal acts until when it
put another G code. The format of
programming is the following:

G1X50.Y95. F130;

In this case, the machine will move from


where this is diagonally up to the
final coordinate X50. Y95. with a
machining feed rate of 130
mm/min .
Approach to programming
1- Choose the zero point of the piece (one or several).
2- It will be scheduled in absolute coordinates or
incremental?
3- Develop the work plan in individual steps:
determine tool, spindle rotation speed,
soft drink, routes, progress, etc.
4- Write the program, translating the work steps
to the programming language.
5- Program entry to control.
6- Test the program (in the graph and empty).
7- Process the program (mechanize).
8- Check the piece's measurements and compensate
differences.
9- Optimize the program (traversals and progress of
machining
EXERCISE G0-G1: Program diagonal notches

Define the zero point of the part.


Absolute coordinates.
Define tool or
Tools. Reamer
8mm.
Spindle speed.
Soda?
Define Routes of
quick approximation.
Define routes of
machining with its feed.
Tool withdrawal.
End of program.
PROGRAM STRUCTURE
The programs are identified with the letter O and four digits are available.
to number the program, in some controls you can type between
parenthesis the name of the program for better identification in the
program library, finally the block or line of closes
programming with a semicolon when pressing the EOB (end of block) key.

O1235 (SWIVEL SUPPORT MOULD);

Typically, the blocks or lines of code are numbered with the


lettering in groups of 5 or 10 to have an order in the editing of the
programs, although this is not strictly necessary. After the number
Block instructions are programmed with the codes G, M, F, S, T.
that are needed by closing the programming block with a semicolon.

N5 G17G15 G40 G80 G94;


/ N10 G91G28Z0;
/ N15 G28 X0. Y0.;
N20 M6 T1;

The program structure concludes with the M30 code (end of program)
GRAPHIC SIMULATION OF RACE IN CONTROL
FANUC
GRAPHICAL RELIEF SIMULATION IN CONTROL
FANUC
EXERCISE: CASHIER
MACHINING OF ARCHES AND CIRCLES

G2 Circular interpolation in
clockwise (circular)
interpolation CW): this code
modal is used to machine arches
and circles where the tool
describe a circular trajectory in
clockwise
This code is also accompanied by the
machining advance F.

The programming format is the


next:
G2 X22.5 Y40. R-27.5 F160;

Where: X22.5 and Y40. are the


coordinates of the point where it ends
the arc, R-27.5 is the radius of the arc
(negative for sweeping an arch more)
de180 degrees) and F160 mm/min ,the
machining advance for said
arch.
Arch exercise
G2
G3 Circular interpolation counterclockwise
(circular interpolation CCW): this modal code is
used for machining arcs and circles where the
tool describes a circular trajectory in the sense
contrario a las manecillas del reloj. Este código también
is accompanied by the progress of machining F.

The programming format is as follows: G3 X50. Y-70.


R35. F90
Where: X50. and Y-70. are the coordinates of the point
where the arc ends, R35. it is the radius of the arc and F90 the
machining progress for that arch. If the arch sweeps
more than 180 degrees the radius has to be specified
negative: G3 X40. Y60. R-25. F120with this format not
A circle can be machined in a single block, it would be done.
in two blocks.
Arc exercise
G3
ARCHES AND CIRCLES IN FORMAT I, J.

I, J are the coordinates of the center of the arch.


REGARDING THE INITIAL POINT OF THE ARCH.
Exercise
G3
G4 :TEMPORIZACIÓN (DWELL)

THE TIMER IS USED


IN THE CASE OF MAKING A
TEMPORARY STOP FOR
BREAK THE SHAVINGS WELL AND
TO IMPROVE THE FINISH OF
HOLES.

G1 Z-45 F120
G4 X1 (TIMES 1 SECOND)
G0 Z2.
Zero piece (work piece coordinate system)

The zero of the piece is the


distance from
the machine's zero up to
the origin of coordinates
chosen for the piece of
work, this is recorded in
mechanical coordinates
(regarding zero
machine).
Zero fixation of the part
The program specifies the
code for each table of zero of
piece that is used in a cycle of
work, it can be one or several
tables.

G54 = zero of the part engraved in the


table #1.
G55= in table #2.
G56= in table #3.
G57= in table #4.
G58= in table #5
G59= in table #6
If the machine has piece zeros
extended:
G54P1= zero recorded in the table
extended P1
G54P48= zero recorded in the table
extended P48.
By pressing the OFFSET SETTING key and then
(WORK) the zero tables of the piece appear.
When pressing the OFFSET SETTING key and then (WORK) appear
the zero tables of extended piece G54P1 - G54P48
Taking into account the height of each tool
height compensation
The height of the tools varies from
one another, so that the control has
at this height, the ... is used
code G43 H__when applying this code
to each tool the control does the
calculation for these to reach the value
nominal programmed on the Z axis
adding or subtracting the length.
There are several ways to set the height
for the tools:
If you take a tool like
boss, the difference is calculated between the
other tools regarding
this.
Another way is to find the distance from
the machine zero in Z to the piece
for each tool.
If it is taken as a reference in Z
the length will be found on the spindle's nose
from each tool from the nose
from the spindle to the tip of each
tool.
G43 H__ COMPENSATE HEIGHT (tool length
compensation
This code needs to be programmed.
after each change of
tool in a movement of
approach to the part on the Z axis.

M6 T5
G0 X20 Z10 M3 S1000
G43 H5 Z2

Where: H5 is the box 5 where it is


record the height of the tool =
15mm. Z2 is the coordinate to reach
(2mm above the piece).

This box is pressed down.


the OFFSET SETTING key and then
the key (COM).
By pressing the OFFSET SETTING key and then (COMP)
the height compensation table appears.
WORK PLANS (plane selection)
WORK PLANS

G17 Work on the plane (X,Y): When the machine is turned on, it
find active the work plane X,Y where the milling is done
most contours, it is necessary to place it when it has been
changed the work plan previously and wishes to continue
working in the X,Y plane again and at the start of the program,
because if the machine was working in another plane and we stop it
the program, the code of the last plan that was being worked on
it remains active and the machine would move upon restarting the program
wrong trajectories.

G18 Work in the (X,Z) plane: When working with an interpolation with
coordinates X,Z example: G2 X20.Z30.R35.F120 previously
we must define the plane where the interpolation is generated, in this
if it is the work plan X,Z G18, it would be programmed:

G18; (SWITCH TO WORK PLANE X, Z)


G2X20.Z30. R35.F120;(MACHINING OF A ARCH WITH
COORDINATES X,Z
G17; (IF WORK WILL CONTINUE ON THE NORMAL PLANE
X,Y)
PLANE G18 (X, Z)
G19 Work in the (Y,Z) plane: When working a
interpolation with Y,Z coordinates example: G2
Y10.Z20.R25.F100 previously it is necessary to define the
plane where the interpolation is generated, in this case it is
the work plan Y,Z G19 would be scheduled:

G19; (CHANGE TO WORKPLANE AND Z)


G2Y10.Z20. R25.F100;(MECHANIZE ARCH WITH
COORDINATES X,Z)
G17; (IF WORK WILL CONTINUE ON THE PLANE
NORMAL X,Y)
PLANE G19 (Y, Z)
G20: WORK IN INCHES (input inch)

When working in inches, the G20 code is placed at the beginning of the
the coordinates are presented with 4 decimals after the
point.
G21: WORK IN MILLIMETERS (input metric)

When working in millimeters, the G21 code is placed at the beginning of the
the coordinates are presented with 3 decimals after the
dot.
MACHINE OR HOME REFERENCE

G28 Machine reference (return to reference position): this code


it is used to send the machine to Home or machine reference in form
automatically, the machine moves at high speed until it reaches zero
For safety, the Z axis is sent to reference first and then the X axis.
It is generally used in some machines where it is necessary to send
the machine references before changing the tool, or also at
end the program is sent for reference to facilitate the part change
to the worker. This is not a modal code and is programmed along with the code
G91. The machine is referenced by generally reaching the end of the
route of each axis.

O0005
/ G91G28Z0 (GO HOME THE Z AXIS);
G28X0 Y0 (GO HOME ON X, Y AXES);
G90;
M6T1;
““““
G91G28Z0;
G28X0Y0; (THE PART IS LOCATED NEAR THE OPERATOR)
M30;
G94 work feed F in millimeters per minute
minute):

Normally in milling, the machining feed rate is used in


millimeters per minute. This code is placed at the beginning of the program
so that the advance always starts with millimeters per minute, just in case
the G95 code has been activated which is to work on the feed in
millimeters per revolution of the screw, which would be very dangerous if
It will remain active, for example, for drilling. When it is programmed.
In G-code G94, the feed F is set to F100 (mm/minute).

G95 Work the feed F in millimeters per revolution of


screw (feed per revolution):

It is programmed only in the rigid threading cycle with feed F.


in millimeters per spindle revolution, the feed is programmed
F1.25 (mm/rev), at the end of the cycle it should be placed back in
advance in millimeters per minute with the G94 code, and at the beginning of
program for if the cycle is interrupted without reading the G94 code.
Compensation of the radius
tool
CONTOUR MACHINING
Compensation of the radius of the
tool (cutter compensation):

The programming point in X, Y is


center of the tool and it works like this
for machining such as drilling,
grooved, milling of linear notches
or in arc, but in the case of milling of
the edge of the tool is the
what the contour of the profile must be machined and
not the center of the tool, for this
situation codes were created for
calculate the programming trajectory
moving the tool radius to
one side of the scheduled outline, this
automatically performs the control, the
contour is programmed with its measurements
normal.

G40 = Cancel radio compensation.


G41 D_ = Compensate radius to the
left of the scheduled outline.
G42 D _ = Compensate radio to the right
of the scheduled contour.
G41 D__= Compensate radius
to the left of the outline
scheduled (cutter
compensation left):
It is used to compensate for the
trajectory of the tool
when the tool advances
to the left of the outline
programmed, in this case the
control calculates the trajectories
of intersection of the
geometries displacing the
value of the radius of the
tool to the left
of the contour geometry.
The programming format is:
M6T1;
G0X-10. Y-10.M13S1200
G1 G41 D55 X10. Y20. F100;

Where D55 is the box of


offset or compensation where
the value of the radius was saved
this tool =15mm.
By pressing the offset key
Setting and then (COMP)
the table appears of
compensations for the
tools:
G42 D__= Compensate radio
to the right of the outline
programmed (cutter
compensation right):
It is used to compensate for the
trajectory of the tool
when the tool advances
to the right of the outline
programmed, in this case the
control calculates the trajectories
of intersection of the
geometries displacing the
value of the radius of the
tool to the right
of the contour geometry.
By pressing the OFFSET SETTING key and then (COMP)
the radio compensation table appears.
G40 = Cancel cutter compensation:

It is programmed at the end of the profile outline after having


correcting the trajectory with G41 or G42. It is also placed at the beginning of
program to cancel the compensations that have remained active
previously.

M6T2;
G0 X-10. Y-10. M13 S1200,
G1 G42 D22 X10. Y20 F120;
X40
Y80;
X10;
Y10;
G1G40X-10.Y-10.;(RADIO COMPENSATION)
G0Z100;
M30;
Compensation trajectory
Before starting the
machining should be
to make a trajectory of
approach to the contour,
in which it is programmed
G41D__ or G42D__
depending on the case,
so that when starting the
contour geometry
tool already this
displaced the value of the
tool radio.
Exercise
G41
Exercise
G42
DRILLING EXERCISE
GENERAL STRUCTURE OF CYCLES
Location at coordinate X,Y where the will be made.
first drilling.
Lower in Z to an Initial level of
approach on the Z axis, where the tool
After machining a hole, it will come out and can
move in X, Y to the following holes without
crash into obstacles.

M6T1;
G0X20.Y30.M13 S1000;
G0 G43H1Z12.; (INITIAL LEVEL Z)

The output of the tool is specified afterwards.


for machining the hole, if it comes out at the initial level it
programG98, if it goes out to the security levelRse
programG99.
The code of the cycle to be used is programmed.
In the same block, the machining depth
Z,.
A level of security approach before
start the machining and where the tool will come out
if there are no obstacles to position oneself in others
holes.
The machining progress is scheduled with F.

M6T1;
G0 X20. Y30. M13 S1000;
G0 G43H1Z12.
G98G81Z-27.R2.F100;
Then only the X, Y position of each is programmed in each block.
hole to be machined, G98 or G99 is set to indicate that when
Get out of machining that hole, it will come out at level R or at the initial level.
You can also change the depth for each hole and the level.
security R if necessary.

M6T1;
G0 X20 Y30 M13 S1000;
G0 G43H1Z12.
G98G81X40.Y50.Z-27.R2.F100;
G99 X40 Y50;
X60 Y67 Z-20;
G80

At the end of machining the holes, the G80 code is programmed.


cancel the cycle mode and the machine can move to another position
to perform a different operation or to end the program.
G73 PECK DRILLING CYCLE WITH CHIP BREAKER

It is used to break the chip that


sale continues in materials called
soft metals like aluminum and steels of
low carbon when making the retraction
break the shavings. The format of the cycle is:

M6T1
G0 X20 Y30 M13 S1000;
G0 G43H1 Z30.
G99G73 X40. Y50. Z-30. R2. Q5.
F100;
X50. Y60.
X60. Y80.
G80

Where: Q5. is the quantity of


drilling carried out prior to
retract 5 mm, the dimension of the
retraction is given by a
parameter
G76 PRECISION BORING OR THREADING CYCLE
boring)
It is used to ream or machine previously drilled holes.
drilled to provide a more precise diameter and with better
finished. A boring tool is used that has a burin or a
sliding insert for calibrating the diameter to be machined.
G76 PRECISION BORE OR THREADING CYCLE
The format of the cycle is:

G99G76 X40. Y50. Z-30. R2. Q0.03 F90;


X50. Y60.
X60. Y80.
G80

Where: Q0.03. is the amount of


retraction made at the bottom of the hole
in the X,Y plane so that the burin does not scratch the
machined diameter when exiting the hole. The
the blender approaches quickly until
the programmed R2 security level R
from this point begins to mechanize
to the bottom of the hole, where the spindle
it stops, then it oriented (in the same
position that is oriented for change of
tool), then the value Q is retracted
programmed in this case 0.03 mm ( the
direction towards which it retracts is fixed
by parameters), the reamer comes out in brand
fast up to level R2. In this position
returns the scheduled retraction for
continue working with the center of
shout, ignite the spindle again and it
locate in the position of the following hole.
G81 NORMAL DRILLING CYCLE

It is used to drill small holes.


deep or where it is not needed
shredder.

The format of the cycle is:

G99G81 X40. Y50. Z-30. R2. F180;


X50. Y60.
X60. Y80.
G80

Where: X, Y is the location of the first


hole, Z is the drilling depth, R
it is the level of security and F the progress of
machining. The drill approaches while running
fast to the R level of security
programmed R2, from this point begins
drill down to a depth of Z-30
millimeters and will proceed at high speed until
the R2 level programmed with G99 code.
If G98 is programmed instead of G99, it will result in.
at the initial level of approach Z30. Then
is located in the position of the following
hole.
CYCLE EXERCISE
G82 DRILLING CYCLE WITH TIMING IN THE
FUND (counterboring cycle)

It is used to drill holes where


needs the bottom of the hole to be left with
a good finish. It is used for countersinking
holes, flared holes, the
timing in the bottom of the hole allows
break the shavings well.
The cycle format is:

G99G82 X40 Y50 Z-15 R2 P1000 F150;


X50. Y60.
X60. Y80.
G80

Where: P 1000 is the timing value in


thousandths of a second at the bottom of
hole, the tool will remain in this
case 1 second and it will come out in quick mode
up to the R2 level programmed with the code
G99.
G83 DRILLING CYCLE WITH CHIP REMOVAL (peck
drilling cycle
It is used to drill deep holes and to drill with
small diameter drills.
The cycle removes the drill bit from the hole to dislodge the chips and
refrigerate the hole, preventing the drill from getting stuck and
break due to chip accumulation.
G83 DRILLING CYCLE WITH CHIP REMOVAL

The cycle format is:

G99G83 X40. Y50. Z-50. R2. Q5. P1000 F100;


X50. Y60.
X60. Y80.
G80

Where: Q5. is the amount of drilling done


5mm before retracting, the maximum Q value will be
three times the diameter of the drill. If desired
timing at the bottom of the hole at the bottom
the tool will remain the value of the hole
programmed in P1000 value given in thousandths of
second, in this case 1 second, and F the advance
of machining. The drill approaches while running
quick to the programmed R security level
R2, from this point begins to drill 5
millimeters and retracts to level R2. then
drill another 5 millimeters more and retract until the
level R2. and so on to the bottom of the
hole where the programmed value will remain
in P1000 value given in milliseconds, in
this case 1 second, and it will come out in fast motion
up to the R2 level programmed with the G99 code.
G84 Tapping cycle with right-hand tap
cycle

It is used for threading


holes with a tap,
preferably used
helical male for
facilitate the extraction of the
shavings, can be threaded
with straight male for
shallow holes
and interns, if it gets threaded
with a threaded male
left is programmed from
the same way but
changing G84 to G74.
Rigid threading cycle with retraction
(rigid tapping): It is used in controls
FANUC 21MB and series 0i where it exists
option to work the threading with retraction
with movements similar to the code of
drilling G83. It is used for threading
deep holes. The format of this cycle
es:

G95; (ADVANCE F IN MM/ REVOLUTION)


M29S100; (ACTIVATION WITHOUT SYNCHRONIZATION)

G99G84 X40. Y50. Z-30. R2.Q5. F1.25;


X50. Y60.
X60. Y80.
G80G94;(FEED RATE IN MM/MINUTE)
G89 RIMING CYCLE (boring cycle)

It is used to rectify holes


previously drilled, using a
straight or conical rhyme. The rhyme comes with
machining advance and it is returned with
machining advance to avoid scratching the
hole or damage the rhyme, leaving a
more precise hole and very well finished.
The format of this cycle is:

G99G89 X40. Y50. Z-15. R2. P1000 F60;


X50. Y60.
X60. Y80.
G80;

Where: The rhyme approaches in march


fast to the R security level
programmed R2, from this point
starts to rhyme down to depth Z-15
millimeters with machining feed F60
mm/min, if the timing is programmed
With P1000 it will take 1 at the bottom.
second and will also be released in advance of
machining F60 up to level R2
programmed with G-code G99.
SUBPROGRAM CALL
M98:call subprogram to work(subprogram call)
It is used to call a subprogram from a
main program, the letter P designates the number
of the subprogram to be called. If M98 P32 is programmed
it will look for the subprogram32 to execute it.

The letter is used to repeat the same several times.


subprogram, if programmed M98 P48 L5, the
subprogram 48 will repeat 5 times before returning to the
program that called it.

M99: end of subprogram, this code closes the


structure of the subprogram and returns to the program that it
called. If the subprogram M99 P50 is scheduled
will return to block number N50.
PROGRAM AND SUBPROGRAM
O0024
N5 M6T1
N6 G90 G54 G0 X63 Y30 M3 S1200
N12 G43 H1 Z5
N15M98 P25 O0025
N20 G55 G0 X63 Y30 G1 Z-5 F200
G1 X66 F250
N25M98 P25 Y35
N30 G56 G0 X63 Y30 X78
N35M98 P25 Y43
X80 Y45
N35 M30 X83
% Y46
X97
Y43
X65
X43 Y47
Y55
X70 Y60
X96
Y76
G0 Z5
M99
%

You might also like