Module 2 Part 1
Module 2 Part 1
PART PROGRAMMING
NC/CNC MACHINES
NC and CNC MACHINE PROGRAMMING
• Automated control of machining tools
• Machine run on program –Program written in manuscript- using numbers,
letters and symbols
• NC the input given is by punched cards or magnetic tapes.
• Manuscript (standard format-word format) to tape using flexo writer which
is read by tape reader
CNC-computer + NC
• computer interface- easily changeable
program
• High accuracy products in less time
A part program contains all the information for machining a component
which is given as a input to the control unit.
The control unit provides the control signals at the correct time and in the
correct sequence to the various drive units of the machine.
Part Program
1. Part program is a set of instructions which instruct the machine tool
about the processing steps to be performed for the manufacture of a
part.
2. A program defining motion of tool / work piece in this coordinate
system is known as a part program.
3. NC part programming comprises the collection of all data required to
produce the part,
• the calculation of a tool path along which the machine operations
will be performed and the arrangement of those given and
calculated data in a standard format which could be converted to
an acceptable form for a particular MCU.
4. The shape and size of the finished component is totally dependent on
how well the program has been prepared.
Types of part programming
1. Manual part programming,
2. Computer aided part programming.
NC COORDINATE SYSTEM
Machining of a work piece by an NC program in the NC lathe centers require a
‘coordinate system’ to be applied to the machine tool. The Z axis is always parallel
to the main spindle of the machine. The x axis is at right angle to the Z axis and
parallel to the work holding surface.
Reference Points
A reference point is a fixed or selected arbitrary location on the machine, on the tool and
on the part. A fixed reference point is a precise location along two or more axes, designed
during manufacturing or setup. Three reference points are either set by manufacturer or
user.
Machine Origin-Machine Zero Point
The machine origin is a fixed point set by the machine tool builder. Usually it cannot
be changed. Any tool movement is measured from this point. The controller always
remembers tool distance from the machine origin.
Program Origin
It is also called home position of the tool. Program origin is point from where the tool
starts for its motion while executing a program and returns back at the end of the
cycle. This can be any point within the workspace of the tool which is sufficiently
away from the part. In case of CNC lathe it is a point where tool change is carried out.
Part Origin- Work piece zero point
This point determines the work piece co- ordinate system in relation to the CNC
system when setting up the machine. Usually part origin needs to be defined for each
new setup.
Programming format/tape format
Word Address Format
This type of tape format uses alphabets called address, identifying the function of
numerical data followed.
N20 G00 X1.200 Y.100 F325 S1000 T03 M09 <EOB>
Tab Sequential Format
Here the alphabets are replaced by a Tab code, which is inserted between two words.
The MCU reads the first Tab and stores the data in the first location then the second
word is recognized by reading the record
>20 >00 >1.200 >.100 >325 >1000 >03 >09
Fixed Block Format
In fixed block format no letter address of Tab code are used and none of words can be
omitted. The main advantage of this format is that the whole instruction block can be read
at the same instant, instead of reading character by character. This format can only be
used for positioning work only.
20 00 1.200 .100 325 1000 03 09 <EOB>
G- Code description
G00 – Rapid traverse
The G00 code executes a non-cutting movement, at a rapid feed rate, to a specific co-
ordinate position in the working area. G00 command is written in the following format
G00 X_ _ _ _Y_ _ _ _ Z_ _ _ _
Here X, Y and Z denote the location of the ending position of the tool. The tool moves
from starting point to the ending point in maximum possible speed. The path taken by
the tool may not be linear, but it will be the quickest.
G01 Linear interpolation
The G01 code executes a cutting movement following a straight line, at a set
feed rate. G01 command is written in the following format.
G01 X_ _ _ _Y_ _ _ _ Z_ _ _ _
If we give the command,G01 X100 Y50 F50
Then, the tool will move from starting point to end point performing cutting
motion in a straight line between them as shown in the figure at the specified
feed rate (50 mm/min)
What is IJK
“I” = Incremental distance from Start Point to arc
center in the “X axis.”
“J” = Incremental distance from Start Point to arc
center in the “Y axis.”
“K” = Incremental distance from Start Point to arc
center in the “Z axis.”
G94 Feed Per Minute
G95 Feed Per Revolution
G98 Return to initial level in canned cycle
R Method
The R Method can only be used for arcs less than 360 degrees
(In absolute mode, G90):
G01 X100 Y40 F125;
G03 X80 Y60 I-20;
G01 X60;
G02 X40 Y40 I-20;
G40 G41 G42 Cutter compensation
In NC machining, if the cutter axis is moving along the programmed path,
the dimension of the work piece obtained will be incorrect since the
diameter of the cutter has not be taken in to account.
The use of cutter compensation allows the programmer to use the part
geometry exactly as from the print for programmed coordinates.
G40 = Cutter Compensation Cancel
G41 = Cutter Compensation Left
G42 = Cutter Compensation Right
G80 G81 CANNED CYCLE – DRILLING
A canned cycle is a way of conveniently
performing repetitive CNC machine operations.
Canned cycles automate certain machining
functions such as drilling, boring, threading,
pocketing, etc. A canned cycle is used to simplify
programming of a part. Once selected, a canned
cycle is active until cancelled with the G80 code.
G80 Canned cycle stop and G81 for canned
Drilling Cycle Start.
G98/G99 G81 X _ _ _ Y _ _ _ Z _ _ _ R _ _ _ F _
__
THE TOOL IS POSITIONED ON THE RIGHT HAND
SIDE OF THE PART, AS SEEN FOLLOWING THE
DIRECTION OF MOVEMENT, FROM BEHIND THE
TOOL.
2.000
(6,6)
CNC Part Program:
O1011
G21 G98
G28 X0 Z0
M06 T0101
M03 S100
G00 X10 Z1 M08
G00 X7.5
G01 Z-40 F0.2
G00 X10 Z1
G00 X5
G01 Z-20 F0.2
G00 X10 Z1
G28 X0 Z0
M05 M09
M30
CNC Part Program:
O1012
G21 G98
G28 X0 Z0
M06 T0101
M03 S100
G00 X15 Z1 M08
G00 X10
G01 Z-40 F0.2
G00 X15 Z1
G00 X5
G01 Z-20 F0.2
G00 X15 Z1
G00 X10 Z-40
G01 X15 Z-60 F0.2
G00 X15 Z1
G00 X5 Z-20
G01 X10 Z-25 F0.2
G00 X15 Z1G28 X0 Z0
M05 M09
M30
CNC Part Program:
O1013
G21 G98 G00 X50 Z1
G28 X0 Z0 G00 X25 Z-55
M06 T0101 G01 X20 Z-50 F0.2
M03 S100 G00 X50 Z1
G00 X50 Z1 M08 G00 X15 Z-5
G00 X40 G01 X10 Z0 F0.2
G01 Z-230 F0.2 G00 X50 Z1
G00 X50 Z1 G28 X0 Z0
G00 X25 M05 M09
G01 Z-130 F0.2 M30
G00 X50 Z1
G00 X15
G01 Z-50 F0.2
G00 X50 Z1
G00 X40 Z-135
G01 X35 Z-130 F0.2
CNC Part G00 X60 Z1
Program: O1014 G00 X50 Z-185
G21 G98 G02 X45 Z-180 R5
G28 X0 Z0 G00 X60 Z1
M06 T0101 G00 X30 Z-83
M03 S100 G02 X27 Z-80 R3
G00 X60 Z1 M08 G00 X60 Z1
G00 X50 G00 X20 Z-2
G01 Z-330 F0.2 G02 X18 Z0 R2
G00 X60 Z1 G00 X60 Z1
G00 X30 G28 X0 Z0 M05
G01 Z-180 F0.2 M09
G00 X60 Z1 M30
G00 X20
G01 Z-80 F0.2
A binary digit is called a bit. It has a value of 0 or 1 depending on the
absence or presence of a hole in a certain row and column position on
the tape. Out of a row of bits, a character is made. A character is a
combination of bits, which represents a letter, number, or other
symbol.
A word is a collection of characters used to form part of an instruction.
Typical NC words are x-position, y-position, cutting speed, and so on.
Out of a collection of words, a block is formed. A block of words is a
complete NC instruction.
MAY 2019
MODULE 1
1. Explain the different stages of sintering process in Powder metallurgy with a
neat sketch
2. Differentiate the impregnation and infiltration process in Powder metallurgy
3. What are the different methods of atomization for making metal powders in
Powder metallurgy?
4. What are the advantages of Powder metallurgy?
DEC 2019
MODULE 1
1. How carbonyls are useful in powder metallurgy?
2. Differentiate between open loop and closed loop CNC with sketches
3. Draw a PLC ladder logic diagram to get the reciprocating motion of a punching machine
using following sequential operations. One of the two motors operates when power is
supplied. Motor drives the punch to one side. When it completes the required
movement in one direction, a limit switch detects the position of the punch. First
motor is get deactivated. Second motor starts and moves the punch to the opposite
direction. When it completes required movement in opposite direction, a second limit
switch detects the position of the punch. Second motor is get deactivated and first
motor is started again and the process continues so as to get a continuous
reciprocating motion. Also draw the input and output diagrams.
APRIL 2018
MODULE 2
1. What are the different word address formats used in part programming? (5)
2. Mention the purpose of miscellaneous functions in part programming.
3. Write any 2 M – codes with their applications. (5)
What is meant by interpolation in NC systems? Explain different types of interpolations
MAY 2019
MODULE 2
1. Write any Five preparatory function code in manual part programming and its
explanation
2. Write any two methods of specifying a line in an APT language
3. Write a Manual Part Program for the given figure
DEC 2019
MODULE 2
1. Explain the working of DDA integrator with schematic diagram and flow chart.
2. A DDA contains 8 bit registers. The value of its p register is constant and P=150 and
the clock frequency is 10240pps. Calculate the output frequency of DDA
3. Write a manual part program for the given work shown in figure , material
thickness is 20mm.Show the tool movement path and write the description of
blocks (all dimensions are in mm)
%
1234
N171 G00 X-15 Y-15 Z50;
N172 G01 Z-1;
N172 G41 X0 Y0 F100; (Start-Up Move)
N173 G01 Y40;
N174 G01 X30 Y80;
N175 G01 X60;
N176 G02 X100 Y40 R40;
N177 G01 Y30;
N178 G03 X70 Y0 R30;
N179 G01X0;
N180 G40 X-15 Y-15; (Cancellation
Move)
N190 G00 Z50
%
358
N1 (BRIDE)
N10 G90 G71 G80 G40
N20 G0 G52 Z0
(Contour)
N30 T4 D4 M6
N40 G97 S345
N50 G94 F110
N60 G0 X62 Y-18
N70 Z-5 M3 M41
N80 G1 G42 X50 M8
N85 G1 Y33
N90 G3 X38 Y45 R12
N100 G1 X-35 Y45
N110 G2 X-50 Y 30 R15
N120 G1 X-50 Y25
N130 G1 X-35 Y0
N140 G1 X-25 Y0
N150 G2 X25 Y0 R25
N155 G1 X50 (Counterbore)
N160 G1 G40 X68 Y-12 M9 N260 T7 D7 M6
N170 G0 G52 Z0 M5 N270 G97 S530
(Drilling) N280 G94 F106
N180 T6 D6 M6 N290 G0 X38 Y33
N190 G97 S1061 N300 Z3 M3 M40
N200 G94 F74 N310 G1 Z-5 M8
N210 G0 X38 Y33 N320 G0 Z3 M9
N220 Z3 M3 M42 N330 G0 G52 Z0 M5
N230 G1 Z-18 M8 (5+10+3) N340 M2
N240 G0 Z3 M9
N250 G0 G52 Z0 M5
N70 Y80
N80 G02 X20 Y90 R10
N90 G01 X50
N100 X90 Y50
N110 Y20
N120 G02 X80 Y10 R10
N130 G01 X50
N10 T1 N140 X10 Y50
N20 S1000 M3 N150 Y65
N30 G00 G40 G90 G17 X-30 N160 G40 X-30 Y60
Y60
N170 G00 Z200 M02
N40 G43 Z50 H1
N50 Z-5
N60 G01 G41 X10 Y60 D1
F200
HARSH .MPF /O1234
N01 G90 G71 G94 F100 ;
N02 G75 X0 Y0 Z0 ;
N03 M06 T01 D01 ;
N04 M03 S1000 ;
N05 G00 X20 Y20 Z2 ;
N06 G01 X20 Y20 Z-5 ; (Position A)
N07 G01 X50 Y20 Z-5 ;(Position B)
N08 G02 X74 Y20 Z-5 CR=12 ;(Position
C)
N09 G01 X99 Y20 Z-5 ;(Position D)
N10 G01 X75 Y70 Z-5 ;(Position E) ;
N11 G01 X70 Y70 Z-5 ; (Position F)
N12 G03 X50 Y70 Z-5 CR=10 ;(Position
G)
N13 G01 X20 Y70 Z-5 ; (Position H)
N14 G01 X20 Y20 Z-5 ;(Position A)
N15 G75 X0 Y0 Z0 ;
N16 M05 ;
N17 M09 ;
N18 M30