GreatLight CNC Machining Factory logo
CNC Machining
Rapid Prototyping
Materials
Industries
News
About GL

Get Instant Quote

CNC Knowledge

Analysis of Typical Examples of CNC Lathe Machining and Programming

This page walks through the turning jobs that come up most often in a lathe shop: simple shafts, stepped diameters, threads, grooves and mill-turn parts. It is written for engineers and programmers who have to turn a drawing into a program that holds ±0.005 mm. After reading it you can tell which features suit a two-axis lathe, which need live tooling, and where a program is likely to drift.

TurningThreadingMill-turn±0.005 mm
CNC Knowledge: CNC lathe programming examples, a must-have for novices
Doc

What the Examples Have in Common

Every turning example below is a geometry problem first and a code problem second. Get the setup and the tool sequence right, and the G-code is short.

Basics

Reading a Turned Part Before Writing Code

Start with the drawing, not the controller. A turned part is defined by its rotational axis, so the first question is whether every feature shares that axis. Simple outside diameters, shoulders, chamfers, grooves and threads do. Cross holes, flats, slots and off-axis pockets do not, and they change the machine choice before you write a single line.

Next, look at the tolerance stack. A shaft with three stepped diameters held at ±0.005 mm is a different job from one held at ±0.05 mm. Tight diameters usually mean a finishing pass with a small depth of cut and a sharp insert, plus a spring pass if the material pushes back. Loose diameters can often be cut in one pass after roughing.

Also check the material. Aluminium 6061 and 7075 cut clean and allow high surface speed. Stainless 316 and 17-4PH work-harden, so the tool must stay engaged and the feed must not dwell. Titanium TC4 (Ti-6Al-4V) and Inconel move heat into the tool, which means lower speed, heavier feed and more coolant.

Finally, count the setups. A part that can be finished in one chucking is cheaper and more accurate than one that needs a flip. When a flip is unavoidable, plan a machined reference face or a soft jaw so the second op repeats within a few microns.

  • 1
    All features on axis?Two-axis lathe is enough. Any cross feature needs live tooling or a mill.
  • 2
    Tolerance tighter than ±0.01 mm?Plan a separate finishing pass and a spring pass.
  • 3
    Work-hardening alloy?Keep the insert cutting; never let it rub.
  • 4
    More than one setup?Define the datum from a machined face, not a raw face.
Example 1

Simple Stepped Shaft: Manual Programming Still Wins

A straight shaft with two or three diameters and a chamfer is the classic manual programming case. The geometry is short, the tool list is one roughing insert and one finishing insert, and the program fits on one screen. Writing it by hand is faster than building a CAD model and posting it.

The structure is always the same. Set the work offset so Z0 sits on the finished face. Rapid to a safe start point clear of the stock. Face the end. Rough the profile with G71, leaving 0.2–0.3 mm on the diameter for finishing. Then run G70 with the finishing tool, feeding from the tailstock end toward the chuck so the tool pushes the part into the jaws.

Two details decide whether the part comes out round. First, the roughing pass should not leave a thin wall unsupported; if the shaft is long, use a tailstock or a steady rest. Second, the finishing feed on a 6061 shaft at Ra 0.8–1.6 μm is usually fine at 0.08–0.12 mm/rev, but stainless wants a slightly heavier feed to avoid rubbing.

For a part like this, automatic programming adds nothing. The CAM post has to be checked anyway, and a hand-written G71 block is easier to prove out at the machine.

Example 2

Threaded Stud: Where Most Programs Fail

Threading looks simple until the pitch and the relief groove are wrong. The program has to match the thread callout, the insert profile and the relief at the end of the thread. A missing relief groove is the most common cause of a torn thread on the first part.

Set the spindle speed so the thread does not overshoot. For a metric thread on 1045 steel, a conservative surface speed keeps the synchronization stable. The controller needs a few millimeters of run-in and run-out beyond the thread length; if the shoulder is close, cut a relief groove wide enough for the insert to decelerate.

Check the thread with a go/no-go gauge, not with a caliper. A caliper measures the outside diameter, which tells you almost nothing about pitch diameter. On a 316 stainless stud, spring passes on the thread are usually a mistake because they rub the flank and work-harden it.

If the part has a thread on both ends and a tight overall length, consider a mill-turn center. It can thread one end, index, and thread the other without a second chucking, which holds the length tolerance better.

Example 3

Grooved and Undercut Features: Tool Reach Matters

Grooves and undercuts are limited by the tool, not by the controller. A groove 4 mm wide and 6 mm deep needs a bar that can reach the bottom without chattering. As a rule, the bar diameter should be at least 0.7 times the depth of the groove, or the insert will flex and the width will taper.

Program the groove in two moves: plunge to depth, then a short dwell to clean the floor. If the groove is wider than the insert, step over by 60–70 percent of the insert width. Full-width plunges on stainless or titanium generate heat at the corner and shorten tool life.

The floor diameter of a groove usually carries the tight tolerance, not the width. Measure the floor with a groove micrometer or an optical comparator. A pin gauge only confirms the width, which is often the looser dimension.

When a groove sits next to a shoulder, leave a small fillet radius on the drawing. Sharp internal corners concentrate stress and are hard to cut without a special tool.

Example 4

Mill-Turn Parts: When a Lathe Becomes a Milling Machine

A part with a turned body and a few cross holes or flats no longer fits a two-axis lathe. The choice is between a live-tool lathe and a mill-turn center. Live tooling handles radial holes, axial holes and light flats; mill-turn centers handle heavier milling and can often finish the part in one setup.

The programming shift is the datum. On a lathe, Z0 is the face. On a mill-turn, the same face becomes the reference for both turning and milling, so the work offset must be set once and trusted. Any mismatch between turning and milling zero shows up as an off-center hole.

Tool length and tool wear also matter more. A drill that has worn 0.05 mm will still cut a turned shaft, but it will push a cross hole off center on a tight pattern. Track the drill and replace it on a count, not on a hunch.

For parts with a cross hole pattern, a Ø400 mm rotary table on a mill-turn center holds angular position well. For simple radial holes, a live-tool lathe with a C-axis is usually enough and costs less per part.

Selection

Which Lathe Setup Fits Which Feature

Use this as a first filter when a drawing lands on your desk.

FeatureBest setupWatch out for
Straight shaft, 2–3 diametersTwo-axis lathe, manual G71/G70Long parts need tailstock support
External or internal threadTwo-axis lathe with threading cycleRelief groove and run-out length
Groove or undercutTwo-axis lathe, narrow grooving barBar flex on deep grooves
Radial hole or flatLive-tool lathe with C-axisTurning and milling zero must match
Cross pattern plus turningMill-turn center, Ø400 mm tableTool wear shifts hole position
Both ends threaded, tight lengthMill-turn center, one setupSecond-op length stack
Verification

Checking the First Part Before the Run

The first part off a new program tells you more than any simulation. Measure the diameters, the length and the thread before the operator runs the second part. If the length is off, adjust the work offset, not the program. If a diameter is off, adjust the tool offset.

Keep the offsets in a log. A lathe with a dozen tools drifts over a run, and a log shows which tool moved and when. On a 10,000 part run, a tool that moves 0.02 mm every 500 parts will scrap the tail of the run unless it is changed on a count.

Surface finish should be checked with a profilometer when the drawing calls for Ra 0.8–1.6 μm. Visual checks miss the difference between a good finish and one that will fail a customer audit.

We run 100 percent inspection before shipment, with raw material checks, in-process monitoring and a final inspection. Reports are available on request.

FAQs

Common Questions

When should a turned part be programmed by hand instead of with CAM?

Hand programming suits parts with a small number of features on the rotational axis: shafts, steps, chamfers, simple threads. The geometry is short and the tool list is small, so a hand-written cycle is faster to prove out than a posted program.

Use CAM when the part has complex profiles, many arcs, or a mill-turn operation with cross features. The risk of a hand-writing error grows faster than the time saved.

How do you hold ±0.005 mm on a turned diameter?

Rough with 0.2–0.3 mm left on the diameter, then finish with a sharp insert and a small depth of cut. A spring pass helps on materials that push back, such as stainless.

Control the temperature. A part that heats up during roughing will shrink after finishing, so measure after the part has settled, not immediately off the machine.

What causes a thread to tear on the first part?

Most often the relief groove is missing or too narrow, so the insert cannot decelerate before the shoulder. The other common cause is a spindle speed too high for the controller to stay synchronized.

Check the insert profile against the thread callout. A partial-profile insert used for a full-profile thread will cut the wrong flank angle.

Can a live-tool lathe replace a mill for cross holes?

For radial holes, axial holes and light flats, yes. A live-tool lathe with a C-axis holds position well and avoids a second setup.

For heavier milling, deep pockets or tight hole patterns, a mill-turn center or a separate mill is more stable. The live-tool head has less rigidity than a spindle.

What materials are hardest to turn on a CNC lathe?

Titanium TC4 and Inconel move heat into the tool, so they need lower surface speed, heavier feed and plenty of coolant. Stainless 316 and 17-4PH work-harden if the tool rubs.

Aluminium 6061, 7075 and brass C36000 are the easiest. They cut clean, allow high speed and hold finish without special tooling.

How many setups should a turned part need?

One, if the drawing allows it. Every extra chucking adds error and cost. Design a machined reference face so the second op repeats within a few microns.

When a flip is unavoidable, use soft jaws cut to the first-op diameter. That keeps runout low and avoids marking the finished surface.

Send Us the Drawing, Get the Program and the Part

We quote and return a free DFM analysis within 12 hours, and production can start within 24 hours. Uploads are secure and confidential.

12-hour quote100% inspection±0.005 mmNo minimum order

Trusted by engineers and manufacturers worldwide

Tesla Ford Motor Company BYD Auto Denso Magna International Boeing Airbus Medtronic KUKA FANUC