1
CNC PROGRAMMING
2
3
4
5
7
8
9
10
11
• Part Program Storage Memory
• Part Program editing
• Part Program Downloading and Uploading
• Part Program Simulation using Tool path
• Tool offset data and Tool life Management
• Additional Part Program Facilities
• Macros and Subroutine
• Additional support Software for Diagnostics and Maintenance
• Using std operating systems like Win 95
• Drip feeding of part programs for large size part programs.
12
CNC LATHE
Turning Fundamentals
Two axis coordinate system
+ Z
- Z
+ X
- X
XZ – Cartesian Coordinate
system
13
14
Diameter Programming
Radius Programming
Relates to the X axis to the diameter of work piece
Ex. X 5
Relates to the X axis to the radius of work piece
Ex. X 2.5
Ø 5
15
Absolute Coordinate System
Each point referred form the origin point when measured.
X 0 Z 0
Point A: X 6 Z 1
Point B: X 4 Z - 2
Point C: X 2 Z - 5
A
B
C
+ Z
- Z
+ X
- X
16
Incremental Coordinate System
+ Z
Use successive point to measure the next coordinate
(Refers the previous point).
X 0 Z 0
Point A: X 6 Z 1
Point B: X - 2 Z - 3
Point C: X - 2 Z - 3
A
B
C
- Z
+ X
- X
17
Example:
+ Z
A
B
C
- Z
+ X
- X
D
E
F
18
19
NC Part Programming:
•The procedure by which the sequence of processing steps to be
performed on the NC Machine is planned and documented.
•It involves the preparation of punched tape used to transmit the
processing instructions to the machine tool.
Part Programming Manuscript:
•The programmer writes the machining instructions on a special form.
•Manuscript is a listing of the relative tool and work piece locations.
20
Methods of Manual Part Programming Formats
Fixed block format
Tab sequential format
Word address format
22
Word Address Format
N… G.. X… Y… Z… I… J…K… F…. H.. S…. T.. M..
N… Block Sequence No. G… Initiates a preparatory function
X… Designates an X axis coordinate I… Identifies the X axis arc vector
Y… Designates an Y axis coordinate J… Identifies the Y axis arc vector
Z… Designates an Z axis coordinate K… Identifies the Z axis arc vector
F… Assigns a feed rate S… Sets the spindle rpm
H… Specifies the tool length compensation register
T… Specifies the standby tool (next tool change) to be used
M… Initiates Miscellaneous function
23
Block Format (Examples)
N100 G90 X25 Z-40 F0.1
N200 G96 S150 M03
24
Limitations of CNC Blocks
Each Block may contain only one Tool Movement
Each Block may contain only one Tool
Each block may contain only one Feedrate
Each Block may contain only one Spindle Speed
Block numbers should be Sequential
The data specified will follow sequence of block number
25
Common Preparatory (G) Codes
G Codes - Describes machine tool movement
G00 Fast Traverse
G01 Linear Interpolation
G02 Clw - Circular Interpolation
G03 Cclw - Circular Interpolation
G04 Dwell
G20 Imperial Mode
G21 Metric Mode
G28 Goto Reference
G40 Cancel Compensation
G41 Compensate Right
G42 Compensate Left
G50 Clamp Spindle
G70 Finishing cycle
G71 Multiple Turning
G72 Multiple Facing
G76 Multiple Thread
G90 Turning cycle
G92 Threading cycle
G94 Facing cycle
G96 Constant surface speed
G97 Variable surface speed
G98 Feed per Minute
G99 Feed per Revolution
26
Common Miscellaneous Codes
M codes - Describes machine miscellaneous functions
M00 Program Stop
M01 Optional Stop
M02 Program End
M03 Spindle Forward
M04 Spindle Reverse
M05 Spindle Stop
M06 Tool Change
M08 Coolant On
M09 Coolant Off
M30 Program End
M98 Subprogram Call
M99 Subprogram Exit
The Three Part of a
CNC Program
• Program Setup
• Material Removal
• System Shutdown
27
28
%
O1212
[BILLET X Z ]
N10 G21 G99
N20 G28 U0 W0
N30 M06 T0101
N40 S1500
N50 M08
N60 M03
Program Setup
29
N120 G28 U0 W0;
N125 M05
N130 M09
N130 M30;
System Shutdown
30
G Code Syntax
G00 N X Z
G01 N X Z F
G04 X or U or P
31
What is Rapid traverse movement?
32
1.Write manual part program for the component shown below. Take billet size is
55 mm long and 20 mm in diameter. The spindle speed is 1000 rpm and feed
rate is 40 mm/min
33
34
CANNED CYCLES
The length of the part program increases when a number of
cuts are involved.
A majority of the motions are repetitive in nature and
therefore, the motion can be embedded in a canned cycle.
Turning Canned Cycle
This cycle is used to produce either a parallel or tapered tool
path
computer aided manufacturing
laboratory
35
36
2. Write manual part program for the component shown below. Take billet size
is 55 mm long and 20 mm in diameter. The spindle speed is 1000 rpm and
feed rate is 40 mm/min. Use Canned Cycle.
37
38
3.
Taper turning Cycle
39
Modal and Non modal G-Codes
Non Modal –The G code is effective only at the block in
which it is specified eg:G00
Modal-The G code is effective until another G code in
the same group is commanded
Note:
A number of G codes can be specified in a block even
if they belong to same group. When a number of G codes of
the same group are specified, the G code specified last is
effective.
40
Home Work ?
G71 – MULTIPLE TURNING
G71 – MULTIPLE TURNING FORMAT:
G71 U1 R0.5
G71 P10 Q20 U0.25 W0.25 F0.1
First line - Specifies a depth of cut of 1mm and the escape of 0.5mm.
Second line - P, Q specifies block numbers at the start and end of the profile.
U & W specify the distance and direction of the finishing allowance on X
and Y-axes.
F specifies the feed rate.
[BILLET X25 Z60]
N10 G21 G40 G99;
N20 G28 U0 W0;
N30 M06 T0101;
N40 G50 S1500;
N50 G96 S150 M03;
N60 G00 X26 Z2;
N70 G71 U0.5 R0.5;
N80 G71 P90 Q150 U0.25 W0.15 F0.1;
N90 G01 X0;
N100 Z0;
N110 G03 X10 Z-5 R5 F0.25;
N120 G01 Z-15 F0.75;
N130 X20 Z-20;
N140 Z-30
N150 GO2 X25 Z-35 R5 F0.25;
N160 G70 P90 Q150 F0.01;
N170 G28 U0 W0;
N180 M30;
G71 – MULTIPLE TURNING
G72 – MULTIPLE FACING
G72 – MULTIPLE FACING FORMAT:
G72 W1 R0.5
G72 P10 Q20 U0.25 W0.25 F0.1
First line - Specifies a depth of cut of 1mm and the escape of 0.5mm.
Second line - P, Q specifies block numbers at the start and end of the profile.
G72 – MULTIPLE FACING
[BILLET X25 Z60]
N10 G21 G40 G99;
N20 G28 U0 W0;
N30 M06 T0101;
N40 G50 S1500;
N50 G96 S150 M03;
N60 G00 X26 Z2;
N70 G72 W0.5 R0.5;
N80 G72 P90 Q170 U0.25 W0.15 F0.1;
N90 G01 Z-20 F0.75;
N100 X25;
N110 X20;
N120 Z-18;
N130 X15 Z-15;
N140 Z-10
N150 GO2 X10 Z-5 R5 F0.25;
N160 G01 Z-3 F0.75;
N170 G01 X5 Z0;
N180 G70 P90 Q170 F0.01;
N190 G28 U0 W0;
N200 M30;

CNC-LATHE MPP1.ppt

  • 1.
  • 2.
  • 3.
  • 4.
  • 5.
  • 6.
  • 7.
  • 8.
  • 9.
  • 10.
    11 • Part ProgramStorage Memory • Part Program editing • Part Program Downloading and Uploading • Part Program Simulation using Tool path • Tool offset data and Tool life Management • Additional Part Program Facilities • Macros and Subroutine • Additional support Software for Diagnostics and Maintenance • Using std operating systems like Win 95 • Drip feeding of part programs for large size part programs.
  • 11.
  • 12.
    Turning Fundamentals Two axiscoordinate system + Z - Z + X - X XZ – Cartesian Coordinate system 13
  • 13.
  • 14.
    Diameter Programming Radius Programming Relatesto the X axis to the diameter of work piece Ex. X 5 Relates to the X axis to the radius of work piece Ex. X 2.5 Ø 5 15
  • 15.
    Absolute Coordinate System Eachpoint referred form the origin point when measured. X 0 Z 0 Point A: X 6 Z 1 Point B: X 4 Z - 2 Point C: X 2 Z - 5 A B C + Z - Z + X - X 16
  • 16.
    Incremental Coordinate System +Z Use successive point to measure the next coordinate (Refers the previous point). X 0 Z 0 Point A: X 6 Z 1 Point B: X - 2 Z - 3 Point C: X - 2 Z - 3 A B C - Z + X - X 17
  • 17.
  • 18.
    19 NC Part Programming: •Theprocedure by which the sequence of processing steps to be performed on the NC Machine is planned and documented. •It involves the preparation of punched tape used to transmit the processing instructions to the machine tool. Part Programming Manuscript: •The programmer writes the machining instructions on a special form. •Manuscript is a listing of the relative tool and work piece locations.
  • 19.
    20 Methods of ManualPart Programming Formats Fixed block format Tab sequential format Word address format
  • 20.
    22 Word Address Format N…G.. X… Y… Z… I… J…K… F…. H.. S…. T.. M.. N… Block Sequence No. G… Initiates a preparatory function X… Designates an X axis coordinate I… Identifies the X axis arc vector Y… Designates an Y axis coordinate J… Identifies the Y axis arc vector Z… Designates an Z axis coordinate K… Identifies the Z axis arc vector F… Assigns a feed rate S… Sets the spindle rpm H… Specifies the tool length compensation register T… Specifies the standby tool (next tool change) to be used M… Initiates Miscellaneous function
  • 21.
    23 Block Format (Examples) N100G90 X25 Z-40 F0.1 N200 G96 S150 M03
  • 22.
    24 Limitations of CNCBlocks Each Block may contain only one Tool Movement Each Block may contain only one Tool Each block may contain only one Feedrate Each Block may contain only one Spindle Speed Block numbers should be Sequential The data specified will follow sequence of block number
  • 23.
    25 Common Preparatory (G)Codes G Codes - Describes machine tool movement G00 Fast Traverse G01 Linear Interpolation G02 Clw - Circular Interpolation G03 Cclw - Circular Interpolation G04 Dwell G20 Imperial Mode G21 Metric Mode G28 Goto Reference G40 Cancel Compensation G41 Compensate Right G42 Compensate Left G50 Clamp Spindle G70 Finishing cycle G71 Multiple Turning G72 Multiple Facing G76 Multiple Thread G90 Turning cycle G92 Threading cycle G94 Facing cycle G96 Constant surface speed G97 Variable surface speed G98 Feed per Minute G99 Feed per Revolution
  • 24.
    26 Common Miscellaneous Codes Mcodes - Describes machine miscellaneous functions M00 Program Stop M01 Optional Stop M02 Program End M03 Spindle Forward M04 Spindle Reverse M05 Spindle Stop M06 Tool Change M08 Coolant On M09 Coolant Off M30 Program End M98 Subprogram Call M99 Subprogram Exit
  • 25.
    The Three Partof a CNC Program • Program Setup • Material Removal • System Shutdown 27
  • 26.
    28 % O1212 [BILLET X Z] N10 G21 G99 N20 G28 U0 W0 N30 M06 T0101 N40 S1500 N50 M08 N60 M03 Program Setup
  • 27.
    29 N120 G28 U0W0; N125 M05 N130 M09 N130 M30; System Shutdown
  • 28.
    30 G Code Syntax G00N X Z G01 N X Z F G04 X or U or P
  • 29.
    31 What is Rapidtraverse movement?
  • 30.
    32 1.Write manual partprogram for the component shown below. Take billet size is 55 mm long and 20 mm in diameter. The spindle speed is 1000 rpm and feed rate is 40 mm/min
  • 31.
  • 32.
    34 CANNED CYCLES The lengthof the part program increases when a number of cuts are involved. A majority of the motions are repetitive in nature and therefore, the motion can be embedded in a canned cycle. Turning Canned Cycle This cycle is used to produce either a parallel or tapered tool path
  • 33.
  • 34.
    36 2. Write manualpart program for the component shown below. Take billet size is 55 mm long and 20 mm in diameter. The spindle speed is 1000 rpm and feed rate is 40 mm/min. Use Canned Cycle.
  • 35.
  • 36.
  • 37.
    39 Modal and Nonmodal G-Codes Non Modal –The G code is effective only at the block in which it is specified eg:G00 Modal-The G code is effective until another G code in the same group is commanded Note: A number of G codes can be specified in a block even if they belong to same group. When a number of G codes of the same group are specified, the G code specified last is effective.
  • 38.
  • 39.
    G71 – MULTIPLETURNING G71 – MULTIPLE TURNING FORMAT: G71 U1 R0.5 G71 P10 Q20 U0.25 W0.25 F0.1 First line - Specifies a depth of cut of 1mm and the escape of 0.5mm. Second line - P, Q specifies block numbers at the start and end of the profile. U & W specify the distance and direction of the finishing allowance on X and Y-axes. F specifies the feed rate.
  • 40.
    [BILLET X25 Z60] N10G21 G40 G99; N20 G28 U0 W0; N30 M06 T0101; N40 G50 S1500; N50 G96 S150 M03; N60 G00 X26 Z2; N70 G71 U0.5 R0.5; N80 G71 P90 Q150 U0.25 W0.15 F0.1; N90 G01 X0; N100 Z0; N110 G03 X10 Z-5 R5 F0.25; N120 G01 Z-15 F0.75; N130 X20 Z-20; N140 Z-30 N150 GO2 X25 Z-35 R5 F0.25; N160 G70 P90 Q150 F0.01; N170 G28 U0 W0; N180 M30; G71 – MULTIPLE TURNING
  • 41.
    G72 – MULTIPLEFACING G72 – MULTIPLE FACING FORMAT: G72 W1 R0.5 G72 P10 Q20 U0.25 W0.25 F0.1 First line - Specifies a depth of cut of 1mm and the escape of 0.5mm. Second line - P, Q specifies block numbers at the start and end of the profile.
  • 42.
    G72 – MULTIPLEFACING [BILLET X25 Z60] N10 G21 G40 G99; N20 G28 U0 W0; N30 M06 T0101; N40 G50 S1500; N50 G96 S150 M03; N60 G00 X26 Z2; N70 G72 W0.5 R0.5; N80 G72 P90 Q170 U0.25 W0.15 F0.1; N90 G01 Z-20 F0.75; N100 X25; N110 X20; N120 Z-18; N130 X15 Z-15; N140 Z-10 N150 GO2 X10 Z-5 R5 F0.25; N160 G01 Z-3 F0.75; N170 G01 X5 Z0; N180 G70 P90 Q170 F0.01; N190 G28 U0 W0; N200 M30;