📷 IMAGE AREA — Vertical machining centre overview: body/column, table, spindle, tool magazine and the X-Y-Z axes
Suggested alt text: CNC vertical machining centre main parts and axes
Before starting CNC milling training, we must first understand what the machine does, which basic parts it consists of, and in which directions the tool moves. Memorising a CNC program alone is not enough: the student must know which part of the machine a command moves, from which direction the tool approaches the workpiece, and what a wrong command can cause. In this lesson we do not yet start detailed G-code programming; we first learn the working logic of CNC milling and the basic structure of the vertical machining centre.
1. Aim of the lesson
By the end of this lesson the student will be able to: explain the concept of CNC; understand the relationship between a CNC mill and a vertical machining centre; explain the basic working logic of CNC milling; recognise the main sections of a vertical machining centre; distinguish the X, Y and Z axes; determine positive and negative axis directions; understand that the machine zero and the workpiece zero are not the same; and explain the basic safety rules in CNC milling.
2. What is CNC?
CNC stands for Computer Numerical Control. On a CNC machine the axis moves, spindle speed, feed rate, tool selection and auxiliary machine functions are controlled by numerical commands. On a conventional milling machine the operator turns the table handles by hand, follows the axes on the dials, sets the depth of cut manually and continuously monitors most of the operation.
On a CNC mill these moves are carried out through a program: the control unit reads the commands and sends the necessary motion orders to the servo motors. The most basic task of CNC machines is to move the axes automatically, in a controlled and precise way. The linear and rotary motion directions on the machine are called “axes.”
3. What is a CNC mill?
A CNC mill is a machine tool that removes material from a clamped workpiece with a rotating cutting tool, whose movements are managed by the CNC control system. In CNC milling the cutting tool usually rotates, the workpiece is fixed to the table or a fixture, and a controlled relative motion is created between the tool and the workpiece in the X, Y and Z directions.
Basic operations possible in CNC milling include:
- Face milling, slotting, pocket clearing, contour machining, chamfering
- Drilling, counterboring, reaming, tapping
- Precise bore machining with a boring bar, circular pocket and slot machining
- Thread milling with a helical move if suitable hardware is available
CNC programming is essentially telling the machine in what order, to which positions and at what speeds the cutting tool will move.
4. Are a CNC mill and a vertical machining centre the same thing?
These two concepts are very close but not always used identically. A CNC mill refers to general milling machines controlled by CNC; the machine can be vertical, horizontal, bridge, gantry or universal. A vertical machining centre is a type of CNC mill in which the spindle is basically vertical, usually with an automatic tool-change system and a tool magazine. Vertical machining centres usually have the X, Y and Z linear axes, a tool magazine, an automatic tool changer, an enclosed cabin, a coolant system, a chip collection system and a CNC control panel. This training focuses mainly on FANUC-controlled three-axis vertical machining centres.
4.1. Vertical and horizontal machining centres
Machining centres are divided into two groups according to the spindle orientation.
In a vertical machining centre the spindle axis is perpendicular to the table; the cutting tool usually approaches the part from above. It is widely used for dies and molds, plates, fasteners, machine parts, and pocket and slot operations.
In a horizontal machining centre the spindle axis is parallel to the floor. Rotary tables or pallet systems are often used so that several faces of the part can be machined with fewer setups. Horizontal machining centres are generally preferred in series production, for multi-face parts, for deep pocket machining and in operations where chip evacuation matters; since the chips fall away naturally, they do not accumulate in the cutting zone.
Most of the concepts in this training series apply to both types; the examples are given on a vertical machining centre.
5. Advantages of CNC milling
The main reason CNC machines became widespread is not only their speed; their real advantages are automation, precision and repeatability.
5.1. Automatic operation
When the program is prepared correctly and the machine is set up safely, the machine can perform many operations without the operator’s constant intervention. The operator must still monitor the workpiece clamping, tool condition, coolant, chip evacuation and dimensional checks. CNC does not make the operator unnecessary; it changes the role from moving axes by hand to control, setup and production management.
5.2. Repeatability
With the right program, tool and clamping, many identical parts can be produced. The first part and the hundredth part are meant to come out to the same dimensions; but for this, tool wear, temperature change, clamping errors, tool breakage and the mechanical condition of the machine must be monitored.
5.3. Machining complex geometries
Thanks to the simultaneous motion of several axes, curved contours, circular pockets, complex slots and three-dimensional surfaces can be machined. Simple parts can be programmed by hand, while CAD/CAM systems are used for complex surfaces.
5.4. Ease of setup and program change
A saved program can be recalled later; if a similar part is to be produced, controlled changes can be made. However, an old program must not be run directly. The tool numbers, offsets, zeros and clamping layout must be re-checked.
6. Main sections of a vertical machining centre
- Body and column: the main structure; carries the axis systems, resists cutting forces, reduces vibration and preserves geometric accuracy. Rigidity is essential; insufficient rigidity causes vibration, poor surface, tool wear and dimensional error.
- Table: the workpiece is fixed to the T-slotted table directly or via a fixture. The part must not move, rotate, lift or vibrate.
- Spindle: rotates the cutting tool at the set speed. Speed is given in the program with the S address (e.g. S1200 = 1200 rpm); the direction is given with M codes.
- Tool magazine: where the cutting tools are kept ready (12, 16, 20, 24, 30, 40 or more pockets). When the program calls a tool, the ATC engages.
- Automatic tool changer (ATC): removes the used tool from the spindle to the magazine and loads the new tool into the spindle. On FANUC, tool selection is T and the change is usually M06 (e.g. T1 M06). The sequence and special M codes can vary by builder.
- Control unit and screen: program writing/searching/editing, coordinate monitoring, offset entry, workpiece-zero saving and alarm monitoring are done here. The CNC control panel and the machine operator panel (mode select, Cycle Start, Feed Hold, emergency stop, override) may be separate.
- Servo motors, ball screws and slides: CNC command → servo drive → servo motor → ball screw → axis motion. The feedback system verifies whether the axis reached the required position.
- Coolant system: cools the tool/part, removes chips and aids surface quality. Some operations are dry, some use air blast, some use coolant.
- Guard cabin and door system: prevents chip/coolant splashing and broken tool fragments; the door safety system must not be disabled.
6.1. Servo motors and closed-loop control
CNC axes are driven by servo motors. The control unit defines the target position; the measuring system continuously reports the actual position of the axis back to the control. If there is a difference between the target and the actual position, the servo system works to reduce it. This structure, in which the actual position is constantly measured and compared with the commanded position, is called closed-loop control. The accuracy of CNC machines is built on this continuous compare-and-correct logic.
6.2. Encoder and measuring system
An encoder is the element that measures the position and motion of the motor or the axis. Thanks to the encoder, the control unit can track where the axis is, how far and in which direction it has moved, and the spindle speed.
If the measuring system works through the motor or the ball screw, it is called an indirect measuring system; if it measures the slide position directly with a linear scale, it is called a direct measuring system. In indirect measurement, play and flexing in the mechanical transmission can affect the reading; direct measurement is less affected by these factors.
6.3. Ball screw
The ball screw converts the rotary motion of the servo motor into the linear motion of the axis. Compared with conventional lead screws it has lower friction, higher accuracy and better efficiency.
Play between the ball nut and the screw can cause dimensional errors when the axis reverses direction. Double-nut and preloaded designs are used to reduce this play. Play that grows over time is also the basic reason behind backlash compensation, one of the more advanced topics.
6.4. Chip conveyor
The chip conveyor removes the chips produced during cutting from the machine. If chips accumulate, coolant flow can be blocked, the tool can re-cut chips, surface quality can degrade and moving parts can jam. The conveyor can be started from the panel or with auxiliary commands in the program.
7. Basic axes in CNC milling
On a three-axis CNC mill the basic linear axes are X, Y and Z. X and Y are in the horizontal plane, Z is perpendicular to it. The X axis is the left-right motion (X+ right, X- left), the Y axis the front-back motion. The Z axis is along the spindle: Z+ means the tool moving away from the part, Z- means approaching it; hence Z is critical for safety (a wrong Z- causes collisions, vise/fixture cutting, tool/spindle damage). In programming, the workpiece is always assumed fixed and the tool moving; so the programming logic is preserved even if the machine design differs.
8. Auxiliary linear and rotary axes
Some machines have additional axes: rotation about X is A, about Y is B, about Z is C. Auxiliary linear axes are usually shown with the letters U, V, W. The basic part of this series focuses first on the three-axis CNC mill.
9. Why is a coordinate system needed?
The CNC control cannot understand vague expressions like “go a little to the right”; a numerical position must be given (e.g. X50 Y30 Z5). Without a coordinate system, the start and end of a move, the position of the workpiece and the depth of cut cannot be defined. However, CNC milling has more than one “zero” concept, and they must not be confused.
10. Machine zero, reference point and workpiece zero
- Machine zero: the fixed point set by the builder; the basis of the machine coordinate system, not changed by the operator.
- Reference point: after the machine is switched on, the point where the axes are sent to a known position so the control recognises the axis positions. Without returning to reference, some safety functions (stroke-limit check) may not work correctly.
- Workpiece zero: the program start point chosen on the workpiece by the programmer/operator (e.g. a corner, the part centre, a hole centre). It determines where the dimensions in the program start from.
Critical difference: machine zero = the machine’s fixed reference; workpiece zero = the program’s reference on the part. These are not the same. Entering the workpiece zero wrongly runs even a correctly written program in the wrong place; FANUC clearly states that a wrongly set coordinate system can take the machine to an unexpected position.
11. Basic workflow in CNC milling
Producing a part is not just writing the program and pressing Cycle Start. The general order: review the drawing → determine the raw material → machining sequence → clamping method → tool selection → cutting values → workpiece zero → prepare the program → clamp the part safely → prepare the tools → enter tool length/radius → define the coordinate system → safe test → first part → measure → wear compensation if needed → series production. Skipping any step can make later operations faulty.
12. Safety in CNC milling
A CNC machine applies both the correct and the wrong exactly as programmed, with the same speed and precision. FANUC recommends checking a part before machining with single block, feed override, machine lock or dry run, and verifying the entered data, feed rate and tool compensations.
12.1. Before running the machine
- Wear safety glasses; do not work with loose clothing, jewellery or loose hair.
- Check that the workpiece is clamped firmly and the cutter is tightened correctly in the holder.
- Verify the magazine tool numbers, the workpiece zero and the tool length values; examine the Z values in the program especially.
- Close the door; know the location of the emergency stop button.
12.2. Do not approach the rotating tool
While the spindle turns, do not remove chips by hand, measure the part, clean the tool or touch the clamping element. Chips are removed with a suitable chip hook, brush, controlled air or the coolant system; with compressed air, take care not to throw chips at the surroundings or another person.
12.3. Do not run the program at full speed directly
A new/modified program must be checked with single block, a low rapid and feed override, a safe Z height and dry run. Be careful with Dry Run; FANUC notes that the dry-run speed can differ from the programmed feed and in some cases be higher.
12.4. RESET and emergency stop are not the same
The RESET key can stop the program but does not always replace the emergency stop. In a dangerous situation the Emergency Stop must be used. The FANUC 0i-D manual notes that RESET may not work due to a panel fault; emergency stop must be used when the motors need to be stopped safely.
13. Common beginner mistakes
- Thinking of the axis only by the actual table motion (in programming the workpiece is fixed, the tool moves).
- Confusing the Z- direction (Z- usually brings the tool toward the part).
- Assuming the machine zero and the part zero are the same.
- Just resting the workpiece in the vise; not clamping to the correct locating faces with adequate force.
- Thinking the machine is safe if the program is correct (a wrong tool/offset/zero/clamping can cause a crash).
- Mistaking rapid motion (G00) for cutting motion (G01).
14. A mental model for the student
When learning CNC milling, think in this order: Where is the part? → Where is the zero point? → Which tool? → What is the tool length and diameter? → From which position will the tool start? → On which axes will it move? → Is the move rapid or cutting? → Where will the tool retract after the operation? Safe programming is impossible without answering these.
15. Lesson summary
- CNC is a computer numerical control system; in CNC milling the tool usually rotates and the workpiece is fixed.
- A vertical machining centre is a CNC mill with a vertical spindle and usually an ATC.
- The basic linear axes are X, Y, Z; Z+ means moving away from the part, Z- approaching it.
- Machine zero and workpiece zero are not the same; do not run the program without checking offsets and zeros.
- New programs are tested with single block and low rates; RESET is not used instead of emergency stop.