Fanuc Lathe Cycles G70–G76: Roughing, Finishing and Threading

Updated

In short

Fanuc lathe cycles G70–G76 calculate passes automatically from a contour described once or from a few parameters: G71 and G72 for longitudinal and facing roughing, G73 for pattern repeating, G70 for finishing, G74 and G75 for peck drilling and grooving, and G76 for threading. On Fanuc 0i/30i controls they use a two-block format, and P and Q values in G74–G76 are often given in microns without a decimal point.

Fanuc lathe cycles G70–G76 (multiple repetitive cycles) are control cycles that calculate every pass from a contour described once or from a few parameters: roughing, finishing, grooving and threading. Two lines replace dozens of blocks, and changing the allowance or depth of cut does not require rewriting the program. This article covers the two-block format of the Fanuc 0i/30i series and G-code system A, in which X is programmed as a diameter, U and W are incremental coordinates and G99 means feed per revolution. General concepts are in G-code basics.

Cycle overview

CyclePurpose
G70Finishing along a contour defined for G71, G72 or G73
G71Longitudinal (OD/ID) roughing, cuts parallel to Z
G72Facing roughing, cuts parallel to X
G73Pattern repeating for castings, forgings and pre-formed blanks
G74Peck drilling along Z, face grooving
G75OD and ID grooving with pecking in X
G76Multi-pass threading with automatic infeed distribution

G71 and G72 – roughing

G71 U(Δd) R(e)
G71 P(ns) Q(nf) U(Δu) W(Δw) F S T

AddressMeaning
U(Δd), first blockDepth of cut per pass, radius value, unsigned
R(e)Retract amount after each pass
P(ns), Q(nf)Sequence numbers of the first and last contour blocks
U(Δu), second blockFinishing allowance in X, diameter value
W(Δw)Finishing allowance in Z
F, S, TRoughing feed, speed and tool

The same U address means depth of cut in the first block and allowance in the second, a common source of mistakes. U and W are sign-sensitive: Δu is positive when stock is left on an outside diameter and negative when boring; Δw is positive when the contour runs towards the chuck. F and S written inside blocks ns–nf are ignored during roughing and used only by G70.

Type I requires a contour that changes monotonically in X and Z (no pockets), with only an X move in the first contour block. Type II allows pockets (undercuts); it is selected by programming both X and Z (even W0) in the first block, and may be an optional control function. G72 works the same way but cuts across the face: G72 W(Δd) R(e), G72 P Q U W F, with the depth of cut given by W.

G73 and G70

G73 U(Δi) W(Δk) R(d)
G73 P Q U W F

G73 repeats the contour, each time closer to the final shape: Δi and Δk are the total stock to remove in X (radius) and Z, and d is the number of passes. It suits blanks already close to the part shape; on bar stock many passes would cut air. G70 P(ns) Q(nf) finishes the contour using F, S and T from blocks ns–nf; usually a finishing insert is called before it (see ISO turning insert designation).

Example: stepped shaft with G71 and G70

O3001
N10 G21 G40 G99
N20 T0101 (ROUGH AND FINISH)
N30 G50 S2500
N40 G96 S200 M03
N50 G00 X52.0 Z2.0 M08
N60 G71 U2.0 R0.5
N70 G71 P100 Q200 U0.4 W0.1 F0.25
N100 G00 X16.0
N110 G01 Z0 F0.1
N120 X20.0 Z-2.0
N130 Z-20.0
N140 X28.0
N150 X30.0 Z-21.0
N160 Z-40.0
N170 X43.0
N180 X45.0 Z-41.0
N190 Z-60.0
N200 X52.0
N210 G96 S250
N220 G70 P100 Q200
N230 G00 X150.0 Z150.0 M09
N240 M30

A shaft with Ø20, Ø30 and Ø45 mm steps and chamfers is turned from Ø50 mm bar. Roughing uses a 2 mm depth of cut (radius), leaving 0.4 mm on diameter and 0.1 mm on faces at 0.25 mm/rev; G70 then finishes with the same tool at 0.1 mm/rev. The contour is monotonic, so Type I applies. G50 S2500 limits spindle speed, because in G96 the rpm rises as the diameter gets smaller. Values are illustrative – real cutting data depend on the insert and material (cutting speed and rpm).

G74 and G75 – drilling and grooving

G74 R(e)
G74 X(U) Z(W) P(Δi) Q(Δk) R(Δd) F

Here e is the retract after each peck, Δk the peck depth in Z, Δi the step in X between plunges and Δd the relief at the bottom. P and Q are given in microns without a decimal point: Q5000 = 5 mm. With X and P omitted, G74 acts as centre-line peck drilling:

G00 X0 Z2.0
G74 R1.0
G74 Z-30.0 Q5000 F0.1

G75 has the same format but pecks in X (P is the peck depth, Q the step in Z), which makes it suitable for wide OD and ID grooves (see grooving and parting tools).

G76 – threading

G76 P(m)(r)(a) Q(Δdmin) R(d)
G76 X(U) Z(W) R(i) P(k) Q(Δd) F(L)

AddressMeaning
mNumber of finishing passes (2 digits, 01–99)
rChamfer (pull-out) length in units of 0.1×L (2 digits, 00–99)
aTool angle (2 digits: 80, 60, 55, 30, 29, 00)
Q(Δdmin)Minimum depth of cut, microns, radius
R(d)Finishing allowance, mm
X, ZMinor diameter (external thread) and end point
R(i)Radius difference for taper threads; 0 or omitted for straight
P(k)Thread height, microns, radius
Q(Δd)First depth of cut, microns, radius
F(L)Lead (equal to pitch for single-start threads)

The cycle distributes infeed so the chip area stays roughly constant: after pass n the total depth is Δd×√n, so each successive cut is smaller, but never smaller than Δdmin.

Example: external thread M20×2.5

The thread height of an external metric thread is ≈ 0.6134 × P = 0.6134 × 2.5 ≈ 1.53 mm, giving P1534 and a minor diameter of X = 20 − 2 × 1.534 ≈ 16.93 mm (see metric threads).

N300 T0303
N310 G97 S600 M03
N320 G00 X24.0 Z8.0 M08
N330 G76 P021060 Q100 R0.05
N340 G76 X16.93 Z-30.0 P1534 Q400 F2.5
N350 G00 X150.0 Z150.0 M09

P021060 means 2 finishing passes, a 1.0×L pull-out chamfer and a 60° insert; Q100 is a 0.1 mm minimum cut and Q400 a 0.4 mm first cut. These are typical starting values: the first cut is often 0.2–0.5 mm depending on pitch and material, and the insert manufacturer's recommendations take priority. Start at least 2–3 pitches clear of the part so the Z axis can accelerate. Threading uses G97 (constant rpm), because a changing spindle speed breaks thread synchronisation.

G92 and G32

G92 is the simple threading cycle: each block performs one pass (approach, thread, retract, return), and the diameter of every pass is programmed separately:

G00 X24.0 Z8.0
G92 X19.3 Z-30.0 F2.5
X18.8
X18.35
X17.95
…
X16.93
G00 X150.0 Z150.0

G32 is a single synchronised threading move with no automatic approach or retract; it is used for special threads and profiles where the programmer writes the whole sequence.

Practical tips

  • With G96 always clamp maximum spindle speed with G50 S.. – especially when facing or turning small diameters.
  • Place the cycle start point clear of the blank: X slightly above the stock diameter, Z 1–3 mm off the face; the tool returns here after the cycle.
  • Check the signs of U and W for internal work – a wrong sign puts the allowance on the wrong side of the contour.
  • Avoid subprogram calls and other non-contour commands inside blocks ns–nf – many controls do not allow them there.
  • For internal turning, choose overhang following boring bar guidelines.

Other controls

In Fanuc G-code systems B and C some codes are numbered differently (for example the simple threading cycle G92 becomes G78), and other makers' controls differ fundamentally: Siemens uses CYCLE95 (contour roughing) and CYCLE97 (threading), Mazak offers Mazatrol conversational programming, and older Fanuc models use a single-block cycle format. The programming manual of the specific machine is always the authoritative source. Milling cycles are covered in drilling canned cycles G73–G89 and the process itself in CNC turning. CNC programming services can be found or requested on the CNC Pasaulis marketplace.

Frequently asked questions

What is the difference between G71 and G72?

G71 roughs longitudinally with cuts parallel to the Z axis and suits long shafts. G72 cuts across the face, parallel to X, and suits short large-diameter parts and faces.

What does U mean in the first and second G71 blocks?

In the first block U is the depth of cut per pass as a radius; in the second it is the finishing allowance on diameter. The sign of the second U sets which side of the contour the stock is left on.

How do I calculate P in G76 for a metric thread?

The thread height of an external metric thread is about 0.6134 × pitch. For M20×2.5 this is ≈ 1.534 mm, so P1534 (in microns) is programmed.

Why is G97 used for threading?

Threading is synchronised with spindle revolutions, so the speed must stay constant over all passes. In G96 it would change with the diameter.

How does G92 differ from G76?

G92 performs one threading pass per block, with the diameter of each pass programmed separately. G76 calculates all passes and infeed depths itself from two blocks.

Looking for someone to do this job? Find a manufacturer on the marketplace or post a request.

Services offered I need a service