7.1 CNC

Download as pdf or txt
Download as pdf or txt
You are on page 1of 35

Computer Numerical Control

Dr Atul Thakur
Assistant Professor
Department of Mechanical Engineering
CNC Machines
 CNC : Computer Numerical Control

 In a CNC Machine functions and slide


movements are controlled by motors
using computer programs.
 Conventionally, a human operator decides
and adjusts various machines parameters
like feed, depth of cut etc depending on
type of job, and controls the slide
movements by hand.
Types of Milling Machine
 Mills and Machining Centres
 Lathes and Turning Centres
 Drilling Machines
 EDM Sinker and wire cut Machines
 Flame and Laser-Cutting Machines
 Water Jet Profilers
Commercial Control Units
 FANUC CONTROL
 SIEMENS
 GSK
 MECH3
CNC Vs Manual Operation

CNC Operation Manual Operation


CNC Block Diagram
CNC Overview
 A numerical control, or “NC”, system automatically controls many
machine functions and movements
 traditionally performed by skilled machinists.
 Numerical control developed to meet the requirements of
 high production rates,
 uniformity, and
 consistent part quality.
 Programmed instructions converted into output signals which in
turn control machine operations such as spindle speeds, tool
selection, tool movement, and cutting fluid flow.

Machine
Program
Control Unit

Machine
CNC Overview
 By integrating a computer processor, computer numerical control
(CNC) is obtained or “CNC”
 allows part machining programs to be edited and stored in the
computer memory
 permit diagnostics and quality control functions during actual
machining.
 All CNC machining begins with a part program,
 a sequential instructions or coded commands that direct the specific
machine functions.
 Part program may be
 manually generated or,
 using computer aided part programming systems.
Basic Principle of CNC
 All computer controlled machines are able to accurately and
repeatedly control motion in various directions
 Each of these directions of motion known as axis
 Depending on the machine type there are commonly two to five
axes
 Two types of CNC axes
 linear axis in which movement is in a straight line,
 rotary axis with motion following a circular path

For Prismatic Components For Rotary Components


Open Loop and Closed Loop Control

Open Loop Control

Closed Loop Control


Absolute Vs Incremental Coordinate

Absolute Incremental
CNC Code - Information Required
 Preparatory Information: units, incremental or absolute
positioning
 Coordinates: X,Y,Z, RX,RY,RZ
 Machining Parameters: Feed rate and spindle speed
 Coolant Control: On/Off, Flood, Mist
 Tool Control: Tool and tool parameters
 Cycle Functions: Type of action required
 Miscellaneous Control: Spindle on/off, direction of rotation,
stops for part movement

Information conveyed to CNC machine through a set of instructions arranged in a particular


sequence – Program
Lathe Coordinate System
Milling Machine Coordinate System
Mill Tool Coordinate System
Planes
Absolute Coordinate
Incremental Coordinate System
Exercise
 A(-1,2)
 B(-3,0)
 C(0,-1.5)
 D(-0.5, -3)
 E(2,-2)
 F(5,1)
 G(1,2)
 H(0,2)
Example CNC Program
 Each instruction to the machine
consists of a letter followed by a
number
 Each letter is associated with a
specific type of action or piece of
information needed by the machine

 N,G,X,Y,Z,A,B,C,I,J,K,F,S,T,R,M
Codes (G and M)
 G-codes: Preparatory Functions
– involve actual tool moves
 M-codes: Miscellaneous
Functions – involve actions necessary
for machining (i.e.,spindle on/off,
coolant on/off)
Letter G - Codes
M – Codes
Codes (N)
 N-codes: Gives an
identifying number for
each block of information
 It is generally good
practice to increment each
block number by 5 or 10
to allow additional blocks
to be inserted if future
changes are required.
Codes (X, Y, Z)
 X, Y, and Z codes are
used to specify the
coordinate axis.
 Number following the
code defines the
coordinate at the end of
the move relative to an
incremental or absolute
reference point
Codes (I, J, K)
 I, J, and K codes
are used to specify
the coordinate axis
when defining the
center of a circle.
 Number following the
code defines the
respective coordinate
for the center of the
circle
Codes (F, S, T)
 F-code: used to specify
the feed rate
 Relative translation of tool
w.r.t. work piece
 S-code: used to specify
the spindle speed
 T-code: used to specify
the tool identification
number associated with the
tool to be used in subsequent
operations.
Example
Setup
 % Program start flag. Placed at the beginning of each
program
 :1025 Program identification number. Follows the program
start flag at the beginning of each program
 G90 G20 (Absolute units, inches)
 M06 T3 (Stop for tool change, use tool # 3)
 M03 S1250 (Turn the spindle on CW to 1250 rpm)

Cutting
 G00 X1 Y1 (Rapid to X1,Y1 from origin point)
 Z0.1 (Rapid down to Z0.1)
 G01 Z-0.125 F5 (Feed Z-0.125 with feed 5 inch/min)
 G00 Z1 (Retract fast to Z1)
 X0Y0 (Retract fast to origin)

Shutdown
M05 (Stop spindle)
M30 (End of program)
Additional Information
 Restrictions on CNC blocks
 Each may contain only one tool move
 Each may contain any number of non-tool move G-codes
 Each may contain only one feedrate
 Each may contain only one specified tool or spindle speed
 The block numbers should be sequential
 Both the program start flag and the program number must be
independent of all other commands (on separate lines)
 The data within a block should follow the sequence shown in
the above sample block
Modal G Code
 Most G-codes set the machine in a “mode” which stays in
effect until it is changed or cancelled by another G code.
 These commands are called “modal”.

In the example, G00 and G01 are modal.


Arc
Example

You might also like