0% found this document useful (0 votes)
231 views5 pages

CNC Examples

The document contains a CNC program with G-code instructions to machine several parts. It includes: 1) Instructions to machine a pocket profile including linear and circular interpolation movements, tool changes, and spindle/feed parameter changes. 2) A subprogram referenced by the main program to machine a pocket with circular and linear movements. 3) Programs for both absolute and incremental coordinate systems to machine a profile including linear, circular and arc movements. 4) A program to machine a profile including linear and circular movements, tool changes, and spindle start/stop instructions.

Uploaded by

Huy Trần
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
231 views5 pages

CNC Examples

The document contains a CNC program with G-code instructions to machine several parts. It includes: 1) Instructions to machine a pocket profile including linear and circular interpolation movements, tool changes, and spindle/feed parameter changes. 2) A subprogram referenced by the main program to machine a pocket with circular and linear movements. 3) Programs for both absolute and incremental coordinate systems to machine a profile including linear, circular and arc movements. 4) A program to machine a profile including linear and circular movements, tool changes, and spindle start/stop instructions.

Uploaded by

Huy Trần
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
You are on page 1/ 5

05007

N001 G71 G90 (Set dimension type mm, set


absolute co-ordinate system)
N002 G92 X-15.0 Y-15.0 Z0.0 T01 F100 S1200 (Set reference
point -15, -15, 0. Tool T01 side milling tool. Feed 100mm/rev,
spindle speed 1200 rpm)
N003 G41 G00 X0.0 Y0.0 Z2.0 (Cutter radius compensation left
ON, move the tool at A & give clearance of 2mm before starting
spindle rotation)
N004 G01 Z-15.0 M03 (Start the spindle. Move tool
down i.e. at Z direction for cut with feed here M03 will execute first)
N005 G01 X0.0 Y110.0 (Go to B linearly)
N006 G02 X10.0 Y120.0 R10.0 (Go to C with clockwise circular
interpolation with radius = 10)
N007 G01 X75.0 (Go to D linearly)
N008 G01 X100.0 Y92.0 (Go to E linearly)
N009 G01 Y10.0 (Go to F linearly)
N010 G02 X90.0 Y0.0 R10.0 (Go to G with clockwise circular
interpolation with radius = 10)
N011 G01 X0.0 (Go to A linearly)
N012 Z2.0 M05 (Go up 2mm in Z direction for
clearance. Stop spindle rotation here M05 will execute last.)
N013 G40 G00 X-15.0 Y-15.0 (Cutter radius compensation OFF.
Move tool to reference set point.)
N014 M06 T02 F120 (Change the tool & use tool T02 - here for slot mill tool with dia 6mm. Set feed as 120mm/rev.)
N015 G00 X15.0 Y55.0 (Move tool to 'P' rapidly.)
N016 G01 Z-5.0 M03 (Start the spindle. Move tool 5mm down i.e. at Z direction for cut with feed - here M03 will execute
first)
N017 Y80.0 (Go to Q linearly.)
N018 X85.0 (Go to R linearly.)
N019 Y80.0 (Go to S linearly.)
N020 Z2.0 M05 (Go up 2mm in Z direction for clearance. Stop spindle rotation - here M05 will execute last.)
N021 G00 X-15.0 Y-15.0 (Move tool to reference set point.)
N022 M06 T03 F80 (Change the tool & use tool T03 - here for drill bit with dia 15mm. Set feed as 80mm/rev.)
N023 G00 X50.0 Y25.0 (Move tool to 'T')
N024 G01 Z-20.0 M03 (Go down 20mm for assuring full depth of hole.)
N024 Z2.0 M05 (Go up 2mm in Z direction for clearance. Stop spindle rotation - here M05 will execute last.)
N025 G00 X-15.0 Y-15.0 (Move tool to reference set point.)
N026 M30 (Stop the program)

Bà i 2:

N40 G90 G00 X0 Y0


N50 G01 X-10 Y-20 R8 (P1)
N60 G01 X-50 R10 (P2)
N70 Y10 (P3)
N80 X-19.97 Y25.01 (P4)
N90 G03 X7.97 Y38.99 R18 (P5)
N100 G01 X30 Y50 (P6)
N110 G91 X10.1 Y-10.1 (P7)
N120 G90 G02 X59.9 Y20.1 R14 (P8)
N130 G01 X70 Y10 (P9)
N140 Y-20 R10 (P10)
N150 X50 (P11)
N160 G03 X30 R10 (P12)
N170 G01 X10 R8 (P13)
N180 X0 Y0
N10 M6 T1 G43 H1 M3
N15 S500 F120
N20 G0 X0 Y0 (P1)
N25 G1 Y20 (P2)
N30 G3 X-15 Y35 I-15 J0 (P3)
N35 G2 X-45 Y35 I-15 J0 (P4)
N40 G3 X-60 Y20 I0 J-15 (P5)
N45 G1 Y0 (P6)
N50 G1 X0 (P1)
N55 M30

G0 X30 Y-30 (P1)


G1 Y22.67 (P2)
G3 X24.07 Y26.18 R4 (P3)
G2 X-18.27 Y23.46 R50 (P4)
G3 X-23.46 Y18.27 R4 (P5)
G2 X-23.46 Y-18.27 R50 (P6)
G3 X-18.27 Y-23.46 R4 (P7)
G2 X24.07 Y-26.18 R50 (P8)
G3 X30 Y-24.67 R4 (P9)
G1 X33

CNC Part Program


N10 T1 H1 M6 G43 M3
N20 F150 S250
N30 G0 X-21 Y50 Z0.5
N40 G0 Z0
N50 M98 P040050
N60 G49
N70 G0 Z50
N80 M30
Subprogram
O0050
N10 F160 S400
N20 G0 Z-2.5 G91
N30 G1 G90 X5 Y50 G41 (P1)
N40 G2 X22 Y85.23 I45 J0 (P2)
N50 G3 X78 Y85.23 R45 (P3)
N60 G2 X78 Y14.77 R45 (P4)
N70 G3 X22 Y14.77 R45 (P5)
N80 G2 X5 Y50 R45 (P1)
N90 G0 G40 X-21
N100 M99
N05 G54
N10 M6 T1 G43 H1 M3
N15 S500 F120
N20 G0 X-22 Y-22
N25 Z-3
N30 G1 X3 Y6 G41 H2 (P1)
N35 G91 X0 Y24 (P2)
N40 X12 Y9 (P3)
N45 X36 (P4)
N50 Y-24 (P5)
N55 X-21 (P6)
N60 G90 X3 Y6 (P1)

N65 G0 X-21 G40

G90 Absolute Program G91 Incremental Program

N10 T1 M6 M3 G43 N10 T1 M6 M3 G43


N15 S2000 F80 N15 S2000 F80
N20 G0 X10 Y10 Z1 (P1) N20 G0 X10 Y10 Z1
N25 F30 N25 F30
N30 G1 Z-2 N30 G1 Z-2
N35 X25 F80 (P2) N35 G91 X15 F80
N40 G3 X25 Y20 I0 J5 (P3) N40 G3 X0 Y10 I0 J5
N45 G1 X10 (P4) N45 G1 X-15
N50 Y30 (P5) N50 Y10
N55 G0 Z100 G49 N55 G90 G0 Z100 G49
N60 M30 N60 M30
N5 G00 G54 G64 G90 G17 X-20 Y-20 Z50
N10 S450 M03 F250 D01 (12.5 MM DIA)
N15 C0
N20 Z5
N25 G01 Z0
N30 Z-5
N35 G42 X0 Y0 M08 (Liner motion)
N40 X60 Y0 (Liner motion)
N45 X85 Y30 (Liner motion)
N50 X85 Y50 (Liner motion)
N55 G03 X70 Y65 U15 (Circular motion G03 for Counter Clockwise motion and U for arc radius)
N60 G01 X45 Y65 (Liner motion)
N65 G02 X30 Y50 U15 (Circular motion G02 for Clockwise motion and U for arc radius)
N70 G01 X10 Y50 (Liner motion)
N75 X0 Y0 (Liner motion)
N80 G40 X-20 Y-20
N85 G00 Z50 M09
N90 Y100
N95 M30

N5 G00 G54 G64 G90 G17 X-20 Y-20 Z50


N10 S450 M03 F250 D01 (12.5 MM DIA)
N15 C0
N20 Z5
N25 G01 Z0
N30 Z-5
N35 G42 X0 Y0 M08
N40 X80 Y0
N45 X60 Y30 U10
N50 X80 Y50
N55 X50 Y50
N60 G02 X30 Y30 U20
N65 G01 X10 Y30 U8
N70 X0 Y0
N75 G40 X-20 Y-20
N80 G00 Z50 M09
N85 Y100
N90 M30

You might also like