🚧 Under construction — VoTechWorks is being built. A free tech program — complimentary, as our commitment to get America working.
voTechWorksGrade 13 · a vocational technology learning center, by urbanicity
newSchoolWorks.com › VoTechWorks › Manufacturing & Marine › CNC Machining › CNC Setup: Machine Preparation, Tooling, and First-Part Verification › Lesson 6
MFG-CNC14-06 · Lesson 6 · 14 clock hours · lab

Work Coordinate System Setup (G54–G59) on Mill and Lathe

Objective. Students locate and set the work coordinate origin (G54) for a milled part using an edge finder and a lathe work offset (G54 Z) using a tool touch-off, entering all values at the control and verifying with a position readout check.

⚠ Pending professional review

This lesson, its worked examples and its practice questions has not yet been verified by a licensed engineer or certified journey-level tradesperson or by a certification or approval body. It is a study draft and may contain errors. Do not use it as instructions for work on a job site or on live equipment. Always follow your instructor, your supervising professional, and current official references and regulations.

VoTechWorks program approval and accreditation are still in progress. Credentials are issued only by the certifying bodies named in each program, after their own exams.

What Is a Work Coordinate System?

A CNC control can store many different coordinate origins, each called a Work Coordinate System (WCS). The machine has its own fixed home position called machine zero (or machine home). Your part almost never sits exactly at machine zero, so you tell the control exactly how far your part origin is from machine home. That measured offset is stored in a register — G54, G55, G56, G57, G58, or G59 — and every move in the program that calls that register is measured from your chosen part origin.

G54 is the default and most commonly used offset. Think of G54 as a sticky note attached to a corner (or center) of your part: wherever the part is clamped, the program still knows where "X0 Y0 Z0" is relative to that part.

Setting G54 on a Haas Mill Using an Edge Finder

An edge finder is a precision tool used to locate the exact position of a workpiece edge relative to the spindle centerline. The most common style is the mechanical (wiggle) edge finder. It spins in the spindle at roughly 500–1,000 RPM. As you jog the spindle toward the part edge, the two-piece body wobbles. At the instant the tip contacts the edge cleanly, it snaps concentric and then kicks sideways as you go a few thousandths further. That snap-true moment is your contact point.

For a 0.200 in diameter edge finder, the spindle centerline is 0.100 in away from the edge at the moment of contact. You use that offset in your calculation.

Procedure — X axis:

1. Mount the edge finder in the spindle collet. Start the spindle at the manufacturer's recommended speed (typically 500–1,000 RPM). Wear safety glasses; keep fingers clear of the rotating tool.

2. Jog the spindle down to part height, then jog in X until the edge finder contacts the left edge of the block and kicks. Note the machine X position displayed on the position screen — call it X_left.

3. Move to the right edge and repeat. Note X_right.

4. The center of the block in machine coordinates: X_center = (X_left + X_right) / 2. If you want the origin at the left edge instead of center, use X_left + 0.100 (add the edge finder radius).

5. Navigate to Offset → Work on the Haas control, cursor to G54 X, and type in the machine X value followed by Measure (or enter it manually). The control calculates and stores the offset automatically if you use the Measure function while at the contact position.

Repeat for the Y axis using the front and back edges, or just the front edge if the origin is at one corner.

Setting G54 Z on the Mill

For the Z axis on a mill, use the same spindle-probing logic with a Z-setter or by touching off a known-length tool directly to the part surface. Record the machine Z at contact, subtract the tool length offset active at the time, and store the resulting value in G54 Z. Always verify: command G0 G54 Z1.0 in MDI and measure that the tool tip is exactly 1.000 in above the part face.

Setting G54 Z on a Haas Lathe (Tool Touch-Off)

On a lathe the Z origin is usually the face of the finished part (Z=0). The standard method is face-and-touch-off:

1. Mount the facing tool in the turret. Load the correct tool and geometry offset numbers.

2. Face the part to a clean finish — this establishes the physical Z=0 surface.

3. With the spindle running, carefully jog the tool until the tip just grazes the freshly faced surface. You can feel and hear the light contact; a thin witness mark confirms it.

4. At that exact Z position, go to Offset → Geometry, cursor to Tool 1 Z (or whichever tool number you are using), and press Measure. The control stores the current machine Z position as the geometry offset.

5. Then set G54 Z to 0.000 (the part face is your program origin), or use the Work Offset page to confirm the relationship. Command G0 G54 Z1.0 in MDI and measure with a rule or calipers that the tool tip is 1.000 in from the part face. Tolerance: within 0.002 in.

Using G55 for a Second Operation

When a second setup (second op) is needed on the same machine without moving the first part, store the second origin in G55. Jog to the new reference position, enter the machine coordinates in the G55 row of the Work Offset table, and document the incremental shift (distance from G54 origin to G55 origin) on your setup sheet. The setup sheet travels with the job so any operator can recreate the offsets.

Safety Rules for This Lab

Key terms10

Work Coordinate System (WCS)A programmable coordinate origin stored in the CNC control (G54–G59) that tells the machine where the part's X0 Y0 Z0 is located relative to machine home.
G54The first and most commonly used work offset register; the default work coordinate system activated in most CNC programs.
Machine Zero (Machine Home)The fixed reference position built into the machine; all work offsets are measured from this point.
Edge FinderA precision spindle-mounted tool used to locate a workpiece edge; the mechanical (wiggle) type snaps concentric at contact, indicating the edge position to within about 0.0005 in.
Tool Touch-OffThe process of bringing a cutting tool into light contact with a reference surface and recording the machine position to establish a tool geometry or work offset.
MDI (Manual Data Input)A control mode that lets the operator type and execute a single block of G-code directly, used here to verify that a work offset is set correctly before running the full program.
Work Offset RegisterA memory location in the control (G54–G59) that stores the X, Y, and Z distance from machine zero to the chosen part origin.
Setup SheetA written document that records all offsets, tool numbers, speeds, feeds, and clamping details so any qualified operator can reproduce the setup exactly.
G55The second work offset register; used when a second part origin is needed — for example, a second operation on the same setup or a second vise position.
Geometry OffsetA value stored in the tool offset table that accounts for a specific tool's length (lathe Z) or radius, allowing the control to position the cutting edge accurately.

Worked examples4

1. You use a 0.200 in edge finder to locate both X edges of a vise-held block. The machine X position at left-edge contact is X = –7.432 in, and at right-edge contact is X = –4.568 in. You want G54 X at the center of the block. What value do you enter for G54 X?
  1. Identify the two machine X contact positions: X_left = –7.432 in, X_right = –4.568 in.
  2. At each contact point the spindle centerline is 0.100 in (half of 0.200 in) away from the actual edge. The contact positions already represent spindle-center locations, so the block edges are at –7.432 + 0.100 = –7.332 in (left edge) and –4.568 – 0.100 = –4.668 in (right edge).
  3. Find the center: X_center = (–7.332 + (–4.668)) / 2 = (–12.000) / 2 = –6.000 in.
  4. Enter –6.000 in the G54 X register on the Haas control.
Answer: G54 X = –6.000 in
2. Using the same setup, you locate the Y axis. The front-edge contact is at Y = –5.100 in (machine position). You want the G54 Y origin at the front edge of the block, not the center. What value do you enter for G54 Y?
  1. At front-edge contact the spindle centerline is 0.100 in in front of (lower Y than) the actual edge.
  2. Actual front-edge machine position = –5.100 + 0.100 = –5.000 in.
  3. Because the part origin is defined at the front edge, enter –5.000 in for G54 Y.
  4. No averaging is needed; only one edge is used for this axis.
Answer: G54 Y = –5.000 in
3. After setting G54 Z on the lathe by touching off the faced surface, you command G0 G54 Z1.0 in MDI. You measure the actual distance from the part face to the tool tip and get 0.997 in. Is the verification within the ±0.002 in tolerance, and what is the error?
  1. Commanded position: Z = 1.000 in from the part face.
  2. Measured actual position: 0.997 in from the part face.
  3. Error = |1.000 – 0.997| = 0.003 in.
  4. Compare to tolerance: 0.003 in > 0.002 in, so the verification FAILS.
  5. The G54 Z offset must be re-entered and the touch-off repeated before running a program.
Answer: Error = 0.003 in; this exceeds the ±0.002 in tolerance — verification fails and the offset must be corrected.
4. Your G54 origin is at the left-front corner of a block. You need to place G55 at a point 4.500 in to the right (+X) and 2.250 in toward the back (+Y) of G54. Your G54 machine coordinates are X = –6.000 in, Y = –5.000 in. What machine coordinates do you enter for G55 X and G55 Y?
  1. G55 X = G54 X + incremental X shift = –6.000 + 4.500 = –1.500 in.
  2. G55 Y = G54 Y + incremental Y shift = –5.000 + 2.250 = –2.750 in.
  3. Enter G55 X = –1.500 in and G55 Y = –2.750 in in the Work Offset table.
  4. Document both offsets (G54 and G55) and the incremental shift on the setup sheet.
Answer: G55 X = –1.500 in; G55 Y = –2.750 in
In class: Students use a 0.200 in edge finder to locate the X and Y edges of a vise-held block on the mill, calculate the center offset, and enter the G54 X and Y values; instructor verifies by jogging to the nominal origin and reading the position display. · On the lathe, students face a workpiece, touch off the facing tool at Z=0, enter the G54 Z offset, then verify by commanding G0 G54 Z1.0 in MDI and measuring the actual distance from the face to the tool tip with a rule. · Students practice offsetting G55 for a second op on the same mill setup, enter the incremental shift, and document both work offsets on a setup sheet for handoff.
Materials: Haas CNC mill and lathe, 0.200 in edge finder, vise-held steel block, lathe chuck, facing tool, digital calipers, setup sheet form, Haas Operator's Manual (WCS section)
Check: G54 X, Y (mill) and G54 Z (lathe) each within ±0.001 in of instructor-measured actual origin; MDI verification move matches commanded position within 0.002 in — both machines must pass.

Practice check8

Answer each question, then check it. Nothing is recorded; this is your own practice.

NIMS Machining L1-2 — Machine Setup and Operation
1. A 0.200 in diameter edge finder contacts the left edge of a block. The machine X position at that moment reads –8.350 in. What is the machine X coordinate of the actual left edge of the block?
NIMS Machining L1-2 — Machine Setup and Operation
2. On a Haas lathe you use the Measure function to set a facing tool's geometry offset while the tool tip is touching the faced surface. What value should you confirm is stored in the G54 Z work offset register for this setup?
NIMS Machining L1-2 — Safety and Health
3. Before commanding any MDI motion to verify a work offset, what is the most important safety action the operator must take?
NIMS Machining L1-2 — CNC Programming
4. Which G-code registers are used to store up to six separate work coordinate origins on a standard CNC machining center?
NIMS Machining L1-2 — Quality Assurance and Measurement
5. After entering G54 offsets on the mill, you jog the spindle to the stored origin and the position display shows X = 0.003 in instead of X = 0.000 in. Within the ±0.001 in verification tolerance for this lab, what is the correct conclusion?
NIMS Machining L1-2 — Machine Setup and Operation
6. Why is it important to document G54 and G55 offsets — including the incremental shift between them — on a setup sheet?
NIMS Machining L1-2 — CNC Programming
7. In the context of work coordinate systems, what does 'machine zero' refer to?
NIMS Machining L1-2 — Safety and Health
8. A student setting up a Haas lathe must reach inside the open machine enclosure to adjust the chuck jaws before touching off the tool. The correct action is to:
Record this lesson on my transcript. Sign in with your key and enrollment email to record lessons (enroll free if you have no key). This page stays open to read and practise.