of 43 /43
Computer Numerical Control Programming Workbook Generic Mill Preview Sample

CNC Programming Workbook Mill Generic Sample

Embed Size (px)

Text of CNC Programming Workbook Mill Generic Sample

PrGeneric Mill

ev i

ew

Sa

m pl e

Computer Numerical Control Programming Workbook

Computer Numerical Control Workbook Generic Mill Published by CamInstructor Incorporated 330 Chandos Crt. Kitchener, Ontario N2A 3C2 www.caminstructor.com Date: September 1, 2010 Author: Matthew Manton and Duane Weidinger ISBN: 978-1-897466-84-1

National Library of Canada Cataloguing in Publication To order additional copies of the book contact: CamInstructor Inc. 330 Chandos Crt, Kitchener, ON, N2A 3C2 Phone 1-877-873-6867 Fax 1-866-741-8421 email [email protected]

Notice CamInstructor Inc. reserves the right to make improvements to this book at any time and without notice.

Page

2

PrPrinted in Canada

Trademarks Haas is a registered trademark of Haas Automation, Inc. All brands are the trademark of their respective owners.

Requirements Use of the Multi-media CD/DVD requires a computer with speakers, and CD/DVD ROM. August 3, 2010

ev i

Limit of Liability/Disclaimer of Warranty: While the Publisher and Author have used their best efforts in preparing this book, they make no representations or warranties with respect to the accuracy or completeness of the contents of this book and specifically disclaim any implied warranties of merchantability or fitness for a particular purpose. No warranty may be created or extended by representatives. The advice and strategies contained in this book may not be suitable for the readers or users situation. Neither the publisher nor author shall be liable for any damage, loss or any other damages, including but not limited to special, incidental, consequential, or other damages including personal.

ew

SaCamInstructor CNC Programming Work Book-Generic Mill

m pl e

Copyright 2010 CamInstructor Inc. - All rights reserved. This book is protected under the copyright laws of Canada and the United States. All rights are reserved. This document may not, in whole or part, be copied, photocopied, reproduced, translated or reduced to any electronic medium or machine-readable form without prior consent, in writing, from CamInstructor Inc.

TABLE OF CONTENTS

1. AUTOMATIC TOOL CHANGER STANDARD TOOL CAROUSEL 2. COMMONLY USED PREPARATORY G CODES 3. COMMONLY USED MISCELLANEOUS M CODES 4. EXAMPLE OF PROGRAM START-UP LINES 5. EXAMPLE OF PROGRAM ENDING LINES 6. EXAMPLE OF PROGRAM TOOL CHANGE LINES 7. ABSOLUTE & INCREMENTAL POSITIONING a. EXERCISE # 7-1 ~ # 7-5

4 5 6

m pl e

7 8 8 9

8. RAPID (G00) AND LINEAR(G01) INTERPOLATION

Sa

14 15 19 20 22 24 26 28 29 35 37

a. LINEAR INTERPOLATION: EXERCISE # 8-1 ~ # 8-4 9. DRILL CANNED CYCLE (G81)

a. DRILL CANNED CYCLE: EXERCISE # 9-1 10. DEEP HOLE PECK DRILL CANNED CYCLE (G83) 11. CIRCULAR INTERPOLATION (G02 & G03) : EXERCISE # 11-1

Pr

12. CUTTER COMPENSATION (G40, G41, & G42) 13. CNC PROGRAMMING: EXERCISE # 13 14. CNC PROGRAMMING: EXERCISE # 14

ev i

a. G02 CIRCULAR INTERPOLATION : EXERCISE # 11-2 b. G03 CIRCULAR INTERPOLATION : EXERCISE # 11-3 c. CIRCULAR INTERPOLATION: EXERCISE # 11-4 ~ # 11-7

ew

CamInstructor CNC Programming Work Book-Generic Mill

Page

3

40

1

AUTOMATIC TOOL CHANGER STANDARD TOOL CAROUSEL

The CNC Machining Center used in this text is set-up with following tools. All program examples and exercises in this workbook are using the same tools.

Carousel # 1 2 3 4 5 6 7 8 9

0.125 Diameter Flat End Mill

0.1875 Diameter Flat End Mill

ev i Pr10Page

ew

4

Sa

0.250 Diameter Flat End Mill

0.3125 Diameter Flat End Mill 0.375 Diameter Flat End Mill 0.500 Diameter Flat End Mill 0.625 Diameter Flat End Mill # 4 Centre Drill 0.187 Diameter Drill 0.250 Diameter Drill

CamInstructor CNC Programming Work Book-Generic Mill

m pl eTool Description

2CODE

COMMONLY USED PREPARATORY G CODESFUNCTIONRapid traverse motion; Used for non-cutting rapid moves of the machine axis to a location to be machined, or rapid retract moves after cuts have been completed. Maximum rapid motion (I.P.M.) of a CNC Machine will vary on machine model. Linear interpolation motion; Used for actual machining and metal removal. Governed by a programmed feedrate in inches (or mm) per minute. Maximum feed rate (I.P.M.) of a CNC Machine will vary depending on the model of the machine. Circular Interpolation, Clockwise

G00 *

G01 * G02 * G03 * G04 G17 G20 G21 G28 G40 G41 G42 G43 G49 G54 G80 * G81 * G82 G84 G83 * G90 * G91 * G98 G99

Circular Interpolation, Counterclockwise Dwell Circular Motion XY Plane Selection Verify Inch Coordinate Positions Verify Metric Coordinate Positions Machine Home (Rapid traverse) Cutter Compensation CANCEL

Cutter Compensation LEFT of the programmed path

Cutter Compensation RIGHT of the programmed path Tool Length Compensation

Tool Length Compensation CANCEL Work Coordinate #1 (Part zero offset location) Canned Cycle CANCEL Drill Canned Cycle

Pr

CamInstructor CNC Programming Work Book-Generic Mill

Page

5

* Programming exercises included

ev iTapping Canned Cycle

Spot Drill Canned Cycle Peck Drill Canned Cycle

Absolute Programming Positioning Incremental Programming Positioning Canned Cycle Initial Point Return Canned Cycle Rapid (R) Plane Return

ew

Sa

m pl e

3CODE

COMMONLY USED MISCELLANEOUS M CODESFUNCTIONThe M00 code is used for a Program Stop command on the machine. It stops the spindle, turns off coolant and stops look-a-head processing. Pressing CYCLE START again will continue the program on the next block of the program. The M01 code is used for an Optional Program Stop command. Pressing the OPT STOP key on the control panel signals the machine to perform a stop command when the control reads an M01 command. It will then perform like an M00. Optional stops are useful when machining the first part to allow for inspection of the part as it is machined. Starts the spindle CLOCKWISE for most machining. Must have a spindle speed defined. The M03 is used to turn the spindle on at the beginning of program or after a tool change. Starts the spindle COUNTERCLOCKWISE. Must have a spindle speed defined. STOPS the spindle. The M05 is used to turn the spindle off at the end of program or before a tool change. If the coolant is on, the M05 will turn it off. Tool change command along with a tool number will execute a tool change for that tool. This command will automatically stop the spindle, Z-axis will move up to the machine zero position and the selected tool will be put in the spindle. The coolant pump will turn off right before executing the tool change.

M00

M01

M03

M04

Page

6

PrM09 M30

Note: Only one M code can be used per line. And the M-codes will be the last command to be executed in a line, regardless of where it is located in that line.

ev iM08

M06

Coolant ON command.

Coolant OFF command.

Program End and Reset to the beginning of program.

ew

M05

Sa

CamInstructor CNC Programming Work Book-Generic Mill

m pl e

4%

EXAMPLE OF PROGRAM START-UP LINESPrograms must begin and end with % depending on the type of control. Letter O and up to a five digit program number. Blocks are always terminated by the ; symbol: End of Block (EOB)

O00023 ;

N20 G00 G17 G40 G49 G80 G90 ;

N30 T8 M06 ;

Pr

ev i

N40 G00 G90 G54 X1. Y1. S4000 M03 ;

N50 G43 H8 Z2. ;

ew

Sa

G00 - Rapid Traverse G17 - X, Y Circular Plane Selection G40 - Cutter Compensation Cancel G49 - Tool Length Compensation Cancel G80 - Canned Cycle Cancel G90 - Absolute Programming

T8 - Tool number #8 to be loaded into the spindle. M06 - Tool Change G00 - Rapid Traverse G90 - Activates control to be in ABSOLUTE. G54 - Selects work coordinate offset system No. 1 X__ - Axis move to initial X position. Y__ - Axis move to initial Y position. S4000 - Spindle speed 4000 RPM for this tool. M03 - Turns the spindle on in a clockwise direction G43 - Tool Length Compensation: Recognizes the tool length offset value stored in the Hnn code offset display register in the offset length display. H8 - Defines to the control the offset register the tool offset value is stored in. * Tool Length offset # = Tool # Z2. - Informs the control to move from full spindle retract to this Z value and apply the tool length offset.

m pl e

N10 G20 ;

Nnn - Sequence Number G20 - Verify Inch

Startup Block (Machine Default Setting)

CamInstructor CNC Programming Work Book-Generic Mill

Page

7

5N200 G00 Z2. ; N210 M05 ;

EXAMPLE OF PROGRAM ENDING LINESG00 - Rapid Traverse Z2. Retracts tool to 2.0 above part zero M05 Turn off spindle G91 - Incremental Programming G28 - Machine Zero Return Z0. - Z axis in the up direction to machine zero G28 - Machine Zero Return X0. - X axis to machine zero Y0. - Y axis to machine zero

N220 G28 G91 Z0. ;* N220 G53 Z0. ;

N230 G28 X0. Y0. ;* N230 G53 X-15. Y0.;

N240 M30 ;

M30 End of Program and Reset

N100 G00 Z2. ; N110 M05 ;

ev i

N120 G28 G91 Z0. ; / *N120 G53 Z0. ;

Pr

N130 G28 X0. Y0. ; / *N130 G53 X-15. Y0.; N140 M01;

N150 T9 M06

N160 G00 G90 G54 X1. Y1. S4000 M03 ; Turn on the spindle and Rapid traverse to X1. Y1. N170 G43 H9 Z2. ;Page

8

ew

6

EXAMPLE OF PROGRAM TOOL CHANGE LINESRapid Traverse and Retracts tool to 2.0 above part zero M05 Turn off spindle Send to machine zero Z-axis first to Machine Zero Return - X, Y axis avoid any crash. Optional Program Stop Tool Change - Tool # 9 Machine Zero Return - Z axis

Sa

Tool Length compensation for Tool #9 (H9)

CamInstructor CNC Programming Work Book-Generic Mill

m pl e

Send to machine zero Z-axis first to avoid any crash.

*Another way to return to machine zero

7

ABSOLUTE & INCREMENTAL POSITIONING

EXERCISE # 7-1

G90 ABSOLUTE PROGRAMMING

All axis motions are based on a fixed zero reference point, known as ABSOLUTE ZERO (part zero). Each coordinate is in relation to this absolute zero using Cartesian Co-ordinates.

G91 INCREMENTAL PROGRAMMING

All axis motions are based on the distance to the next location. Each coordinate is based on how far the cutter is to move from start to finish.

ev iG901 2 3 4 5 6 7 8 9

STARTING AT THE POINT O (ORIGIN), DESCRIBE THE PATH FROM O THROUGH ALL 9 POINTS AND BACK TO THE POINT O USING G90 & G91

ewX Y

SaG91O1 12 23 34 45 56 67 78 89 9O

O (Origin)

Pr

m pl eX Y CamInstructor CNC Programming Work Book-Generic MillPage

9

ABSOLUTE & INCREMENTAL POSITIONING

EXERCISE # 7-2

G90 ABSOLUTE PROGRAMMING

All axis motions are based on a fixed zero reference point, known as ABSOLUTE ZERO (part zero). Each coordinate is in relation to this absolute zero using Cartesian Co-ordinates.

G91 INCREMENTAL PROGRAMMING

All axis motions are based on the distance to the next location. Each coordinate is based on how far the cutter is to move from start to finish.

ev iG901 2 3 4 5 6 7 8

STARTING AT THE POINT O (ORIGIN), DESCRIBE THE PATH FROM O THROUGH ALL 9 POINTS AND BACK TO THE POINT O USING G90 & G91

ewX Y

SaG91O1 12 23 34 45 56 67 78 89 9O

O (Origin)

10

Page

Pr

9

CamInstructor CNC Programming Work Book-Generic Mill

m pl eX Y

ABSOLUTE & INCREMENTAL POSITIONING

EXERCISE # 7-3

G90 ABSOLUTE PROGRAMMING

All axis motions are based on a fixed zero reference point, known as ABSOLUTE ZERO (part zero). Each coordinate is in relation to this absolute zero using Cartesian Co-ordinates.

All axis motions are based on the distance to the next location. Each coordinate is based on how far the cutter is to move from start to finish.

ev iG901 2 3 4 5 6 7 8 9

STARTING AT THE POINT O (ORIGIN), DESCRIBE THE PATH FROM O THROUGH ALL 9 POINTS AND BACK TO THE POINT O USING G90 & G91

ewX Y

G91 INCREMENTAL PROGRAMMING

SaG91O1 12 23 34 45 56 67 78 89 9O

O (Origin)

Pr

m pl eX Y CamInstructor CNC Programming Work Book-Generic MillPage

11

ABSOLUTE & INCREMENTAL POSITIONING

EXERCISE # 7-4

STARTING AT THE POINT O (ORIGIN), DESCRIBE THE PATH FROM O THROUGH ALL 9 POINTS AND BACK TO THE POINT O USING G90 & G91

O (Origin) 1 2 3 4 5 6 7 8 9

ev i

G90

ewX Y

SaG91O1 12 23 34 45 56 67 78 89 9O

Page

12

Pr

CamInstructor CNC Programming Work Book-Generic Mill

m pl eX Y

ABSOLUTE & INCREMENTAL POSITIONING

EXERCISE # 7-5

Sa ev iG90O 1 2 3 4 5 6 1 O

STARTING AT THE POINT O (ORIGIN), DESCRIBE THE ENDMILL PATH FROM O THROUGH ALL THE POINTS AND BACK TO THE POINT O USING G90 & G91

ewX Y

Pr

m pl eDIRECTION OF CUT CW

G91O1 12 23 34 45 56 61 1O

X

Y

CamInstructor CNC Programming Work Book-Generic Mill

Page

13

8

RAPID G00 AND LINEAR G01 INTERPOLATIONG00 RAPID TRAVERSE

This code is used for rapid motion of the cutter in air to traverse from one position to another as fast as possible. This code will work for all axis motion up to three axes at once. This G00 code is modal and causes all the following blocks to be in rapid (710 in. /min.) motion until another Group 01 code is specified. Generally, rapid motions "will not" be in a straight line. All the axes specified are moved at the maximum speed and will not necessarily complete each axis move at the same time. It activates each axis drive motor independently of each other and, as a result, the axis with the shortest move will reach its destination first. So you need to be careful of any obstructions to avoid with this type of rapid move.

G00 is used when you are positioning the cutter in fresh air. Retracting from a hole you have drilled.

Rapid traverse is not used when cutting the part.

This G code provides for straight line (linear) motion with programmed feedrate for all axis motions from point to point. Motion can occur up to three axes at once. All axes specified will start at the same time and proceed to their destination and arrive simultaneously at the specified feedrate.

Page

14

Prprevious block.G01 is used for

To program a feedrate, the F command is used. The F command is modal and may be specified in a

ev iDrilling a hole Machining a slot Machining a profile

ew

Used incorrectly, rapid traverse will break a cutter very easily.

G01 LINEAR INTERPOLATION

Sa

CamInstructor CNC Programming Work Book-Generic Mill

m pl e

LINEAR INTERPOLATION EXERCISEDIRECTION OF CUT CW EXERCISE #8-1 CENTER DRILLING EXERCISE #8-2 CONTOUR THE PROFILE

EXERCISE # 8-1

LINEAR INTERPOLATION EXERCISE #8-1 (CENTRE DRILL 4 HOLES .100 DEEP)% O00081 (CENTRE DRILL EXERCISE) ; N1 G20 (VERIFY INCH) ; N3 G00 G17 G40 G49 G80 G90 (MACHINE DEFAULT SETTING) ; N5 T8 M06 (#4 CENTRE DRILL) ; N7 G90 G54 G00 X Y S4000 M03 (HOLE #1 POSITION) ; N9 G43 H08 Z2. ; N11 Z.1 (FAST FEED DOWN TO .1 ABOVE THE PART, NON-CUTTING MOVE) ; F15. (CUT TO THE DEPTH) ; N13 G01 Z N15 G Z.1 (RAPID RETRACT) ; N17 X (MOVE TO THE NEXT HOLE POSITION #2) ; N19 G Z (CUT TO THE DEPTH) ; Z.1 (RAPID RETRACT) ; N21 G N23 X (MOVE TO THE NEXT HOLE POSITION #3) ; N25 G Z (CUT TO THE DEPTH) ; N27 G Z.1 (RAPID RETRACT) ; N29 X Y (HOLE POSITION #4) ; Z (CUT TO THE DEPTH) ; N31 G N33 G00 Z2. M05; N35 G28 G91 Z0. ; N37 G28 X0. Y0. ; N39 M30 (PROGRAM END) ; %

Pr

ev i

ew

Absolute Zero (Part Zero) is the bottom left corner of the part & Z=0 is the top of the part. Center drill 4 holes .100 deep

Sa

m pl eCamInstructor CNC Programming Work Book-Generic MillPage

15

LINEAR INTERPOLATION EXERCISE(CONTD) %

EXERCISE # 8-2

LINEAR INTERPOLATION EXERCISE #8-2 (CONTOUR THE PROFILE .250 DEEP)Cutter will be a .750 endmill (Tool # 12) Start contour from the bottom left corner of the part .250 deep. Cutter Compensation is not being used in this exercise, so when programming, define the center of cutter to position around the part. Z=0 is the top of the part.

N10 G20 ;

N20 G00 G17 G40 G49 G80 G90 (MACHINE DEFAULT SETTING) ; N30

Page

16

PrCamInstructor CNC Programming Work Book-Generic Mill

ev i

ew

Sa

m pl e

O00082 ;

LINEAR INTERPOLATION EXERCISEMaterial: SAE 1018 CS= ft/min

EXERCISE # 8-3

XY PLANE

Tool #6 (.500 Flat End Mill) Mill the .5 Wide Slot Through the PartSpindle Speed RPM = 4xCS/D= Depth of Cut = Feed =

% O00083;

Pr

ev i

ew

Sa

m pl eStart from the top of the slot

in/min

CamInstructor CNC Programming Work Book-Generic Mill

Page

17

LINEAR INTERPOLATION EXERCISEMaterial: Al. 6061 CS= ft/min

EXERCISE # 8-4

XY PLANE

Spindle Speed RPM = 4xCS/D= Depth of Cut =

SaFeed =

Tool #6 (.500 Flat End Mill) Mill the profile .125 deep; Z=0 is Top of the Part

O00084;

Page

18

Pr

ev i

ew

%

CamInstructor CNC Programming Work Book-Generic Mill

m pl ein/min Start from Position #1

9

DRILL CANNED CYCLE G81G80 CANCEL CANNED CYCLE

A canned cycle, which permits multiple function programming on one block, is canceled with this code.

G81 CANNED CYCLE DRILLFormat: G81 G99 Z-0.625 R0.1 F10. X Y Z R F

Rapid X location (Optional) Rapid Y location (Optional) Z-depth (Feed to Z-depth starting from R Plane) R-Plane (Rapid point to start feeding) Feed rate in inches/min

reduce the length of program. The figure below shows the axis motions that are included with a Canned Cycle Drill.

All Z axis motions are in ABSOLUTE with any other axis motions unaffected.

rapid rate to the R Plane, which is a point above the work surface. From the R Plane the cutter feeds to the Z-depth at the specified feedrate. When the cutter reaches the Z depth, it retracts at rapid rate to the R Plane.

Pr

ev i

ew

In a canned cycle drill, the cutter moves at rapid to the X and Y, then to a height above the part at

Sa

This G code permits the inclusion of multiple axis motions on one block of program. It is used to

m pl e

CamInstructor CNC Programming Work Book-Generic Mill

Page

19

DRILL CANNED CYCLE EXERCISEMaterial: CRS 1018 CS= ft/min

EXERCISE # 9-1

Sa1. Feed = 2. Feed = Drill in order

1. Center Drill -.100 deep in Absolute Mode 2. Drill .25 Holes Through in Incremental Mode1. Spindle Speed RPM = 4xCS/D= 2. Spindle Speed RPM = 4xCS/D= 1. Depth of Cut = 2. Depth of Cut =

ew

%

O00091;

Page

20

Pr

ev i

CamInstructor CNC Programming Work Book-Generic Mill

m pl eXY PLANE in/min in/min

DRILL CANNED CYCLE EXERCISE (CONTD)

EXERCISE # 9-1

Pr

ev i

ew

SaCamInstructor CNC Programming Work Book-Generic MillPage

m pl e21

10

DEEP HOLE PECK DRILL CANNED CYCLE G83G83 DEEP HOLE PECK DRILL CANNED CYCLE

Format : G83 G99 Z-2.5 Q0.5 R0.1 F10.

/

G83 G99 Z-2.18 I0.5 J0.1 K0.2 R0.1 F9.

Page

22

PrCamInstructor CNC Programming Work Book-Generic Mill

ev i

ew

This G code is similar to G81 but is used for drilling when the tool must be withdrawn periodically to allow chips to be removed from the hole. This cycle allows the tool to rapid to the R Plane, feeds towards the Z depth in increments (traversing to the R Plane and back to the point where drilling was interrupted after each increment) until the tool reaches the final Z depth.

Sa

X* Rapid X-axis location Y* Rapid Y-axis location Z Z-depth (feed to Z-depth starting from R plane) Q* Pecking equal incremental depth amount (if I, J and K are not used) I* Size of first peck depth (if Q is not used) J* Amount reducing each peck after first peck depth (if Q is not used) K* Minimum peck depth (if Q is not used) P Dwell time at Z-depth R R-plane (rapid point to start feeding) F Feed rate in inches (mm) per minute * Indicates optional

m pl e

11

CIRCULAR INTERPOLATION G02 & G03

Sa ewG02Clockwise Direction

G02 & G03 Circular Interpolation Format

X4.25 Y3.0Arc End Point

I 0. I 0.

Incremental Distance from the tool start point to the center of arc

Counter Clockwise

ev i

G03

X2.25 Y1.0Arc End Point

Incremental Distance from the tool start point to the center of arc

Pr

When the machine is required to move in a straight line under a controlled federate, linear interpolation is used (G01). When it is necessary to travel in the circular motion in any plane (XY, YZ, XZ) circular interpolation is used (G02, G03). The velocity at which the tool is moving is controlled by the feed rate (F) command. All circular interpolation moves are defined and machined by programming in three pieces of information into the control.

1. DIRECTION OF TRAVEL: CLOCKWISE G02, COUNTER CLOCKWISE G03

CamInstructor CNC Programming Work Book-Generic Mill

Page

3. ARC CENTER: INCREMENTAL DISTANCE FROM START POINT TO ARC CENTER (I, J, K)

23

2. ARC END POINT

m pl eG02 X4.25 Y3. I 0. J-1.25 G03 X2.25 Y1. I 0. J-.75 XY PLANE

J-1.25 J-.75

F15.Feed rate 15 in/min

F15.Feed rate 15 in/min

CIRCULAR INTERPOLATION EXERCISEContour the profile .200 deep as shown on page 22. Material: Aluminum 6061 & Use appropriate Spindle Speed and Feedrate.% O00111;

EXERCISE # 11-1

Page

24

PrCamInstructor CNC Programming Work Book-Generic Mill

ev i

ew

Sa

m pl e

G02 CIRCULAR INTERPOLATION

Entry

** The figure above is taken from HAAS Automation Workbook for educational purpose only.

Note: The exercise of G02 circular interpolation above is not using cutter compensation, so the circular moves that are shown here are defined from the center of the cutter around arc.

I = INCREMENTAL DISTANCE ALONG THE X-AXIS FROM THE TOOL START POINT TO THE CENTER OF ARC (ARC PIVOT POINT)

Pr

J = INCREMENTAL DISTANCE ALONG THE Y-AXIS FROM THE TOOL START POINT TO THE CENTER OF ARC (ARC PIVOT POINT) K = INCREMENTAL DISTANCE ALONG THE Z-AXIS FROM THE TOOL START POINT TO THE CENTER OF ARC (ARC PIVOT POINT)

To cut a complete circle of 360, you do not need to specify an end point X, Y, or Z. Just program I, J, or K to define the centre of the circle.Page

ev i

ew

SaCamInstructor CNC Programming Work Book-Generic Mill

m pl e25

G02 CIRCULAR INTERPOLATION EXERCISEContour the outside profile .200 deep as shown on page 24. Entry at mid point in a closed contour and .25 away from the part. Material: Aluminum 6061 & Use appropriate Spindle Speed and Feedrate.% O00112;

EXERCISE # 11-2

Page

26

PrCamInstructor CNC Programming Work Book-Generic Mill

ev i

ew

Sa

m pl e

G03 CIRCULAR INTERPOLATION

Entry

** The figure above is taken from HAAS Automation Workbook for educational purpose only.

Note: The exercise of G02 circular interpolation above is not using cutter compensation, so the circular moves that are shown here are defined from the center of the cutter around arc.

I = INCREMENTAL DISTANCE ALONG THE X-AXIS FROM THE TOOL START POINT TO THE CENTER OF ARC (ARC PIVOT POINT) J = INCREMENTAL DISTANCE ALONG THE Y-AXIS FROM THE TOOL START POINT TO THE CENTER OF ARC (ARC PIVOT POINT) K = INCREMENTAL DISTANCE ALONG THE Z-AXIS FROM THE TOOL START POINT TO THE CENTER OF ARC (ARC PIVOT POINT)

Pr

To cut a complete circle of 360, you do not need to specify an end point X, Y, or Z. Just program I, J, or K to define the centre of the circle.

ev i

ew

SaCamInstructor CNC Programming Work Book-Generic MillPage

m pl e27

G03 CIRCULAR INTERPOLATION EXERCISEContour the inside profile .200 deep as shown on page 26. Entry at mid point in a closed contour and .25 away from the part. Material: Aluminum 6061 & Use appropriate Spindle Speed and Feedrate.% O00113;

EXERCISE # 11-3

Page

28

PrCamInstructor CNC Programming Work Book-Generic Mill

ev i

ew

Sa

m pl e

CIRCULAR INTERPOLATION EXERCISE1. Clockwise/ Counter Clockwise? 2. End Point? 3. Incremental Distance from the tool center to the arc center

EXERCISE # 11-4

Note: The exercise of this circular interpolation above is not using cutter compensation, so the circular moves that are shown here are defined from the center of the cutter around arc.

A: C:

ev i

1. What are the coordinates at the center of the cutter for A, B, C, and D B: D:

2. A to B Circular Interpolation (CW)

Pr

3. A to C Circular Interpolation (CW) 4. D to C Circular Interpolation (CCW) 5. D to B Circular Interpolation (CCW) 3. A to A Circular Interpolation (CW)

ew

SaCamInstructor CNC Programming Work Book-Generic MillPage

m pl e29

CIRCULAR INTERPOLATION EXERCISE

EXERCISE # 11-5

PROGRAM CIRCULAR INTERPOLATION USING ABSOLUTE AND INCREMENTAL IN DIRECTION SHOWNY+ XX+ (0, 0)

ABSOLUTE START POINT END POINT G X X X Y Y Y I J / . .

R=2

INCREMENTALSTART FINISH Y-

START POINT END POINT G X

m pl eX X Y Y I Y J X X Y Y Y I J G X X X Y Y Y I J G X X X Y Y Y I J G X X X Y Y Y I J G X

/ . .

XABSOLUTE

START/ FINISH

(-10, -5)

SaX+

Y+

ABSOLUTE (COUNTER CLOCKWISE DIRECTION) START POINT END POINT / . .

INCREMENTAL D=10

ew

INCREMENTAL (CLOCKWISE DIRECTION) START POINT END POINT / . .

ev iY+ FINISH

Y-

ABSOLUTEX+

X-

(5, 2)

Pr

START POINT END POINT

/ . .

R=1.414

INCREMENTALSTART Y-

START POINT END POINT

/ . .

Page

30

CamInstructor CNC Programming Work Book-Generic Mill

CIRCULAR INTERPOLATION EXERCISEMaterial: Aluminum 6061 CS= ft/min

EXERCISE # 11-6

Tool #6 (.500 Flat End Mill) Mill the profileSpindle Speed RPM = 4xCS/D= Depth of Cut =

SaFeed =

% O00116 ;

Pr

ev i

ew

m pl ein/min Start from the top left corner

CamInstructor CNC Programming Work Book-Generic Mill

Page

31

CIRCULAR INTERPOLATION EXERCISE

EXERCISE # 11-6

Page

32

PrCamInstructor CNC Programming Work Book-Generic Mill

ev i

ew

Sa

m pl e

CIRCULAR INTERPOLATION EXERCISE

EXERCISE # 11-7

SaFeed =

Tool #6 (.500 Flat End Mill) Mill the profileSpindle Speed RPM = 4xCS/D= Depth of Cut =

ew

% O00117 ;

Pr

ev i

m pl eMaterial: Aluminum 6061 CS= ft/min in/min Start from the top right hand corner

CamInstructor CNC Programming Work Book-Generic Mill

Page

33

CIRCULAR INTERPOLATION EXERCISE

EXERCISE # 11-7

Page

34

PrCamInstructor CNC Programming Work Book-Generic Mill

ev i

ew

Sa

m pl e

12

G40, G41, & G42 CUTTER COMPENSATION

Cutter Compensation is used to offset the center of the cutter and shift it the distance of thecutters radius. When cutting angled geometry, substantial computations are required to determine the center of the cutter. Using Cutter Compensation, you can program the part as if the center of the cutter will be travelling along the geometry.

G40 CUTTER COMPENSATION CANCELG40 will cancel the G42 or G42 cutter compensation commands.

G41 CUTTER COMPENSATION LEFT

G42 CUTTER COMPENSATION RIGHTG42 will select cutter compensation right. The tool is moved to the right of the programmed path to compensate for the size of the tool.

ev i

ewG41

SaG42 Right of the Line

G41 will select cutter compensation left. The tool is moved to the left of the programmed path to compensate for the radius of the tool. A Dnn must also be programmed to select the correct tool size from the DIAMETER/RADIUS offset display register.

Pr

G41 Left of the Line

G41 : Tool is moved to the left of the profile (e.g. Outside Profile shown as above) G42 : Tool is moved to the right of the profile (e.g. Inside Profile shown as above)Page

m pl eG41

CamInstructor CNC Programming Work Book-Generic Mill

35

G40, G41, & G42 CUTTER COMPENSATION

% O10011 ; N1 T12 M06 (3/4 Flat Endmill) ; N2 G90 G54 G00 X-.575 Y-.200 S1500 M03; N3 G43 H12 Z2. ; N4 Z.1 ; N5 G01 Z-.25 F10. ; N6 X-.375 (Point B); N7 Y?.???? (Point C) ; N8 X?.???? Y2.375 (Point D) ; N8 X2.875 (Point E) ; N10 M05 ; N11 G00 Z2. ; N12 G91 G28 Z0. (Machine Home Z-Axis) ; N13 G28 X0. Y0. (Machine Home X,Y-Axis); N14 M30 ; %

ew

Without Cutter Compensation

Page

36

Pr

The Cutter Compensation (G41) will reflect the actual part geometry (O, P1, P2..) instead of Cutter Centers (Point B,C,D & E)

ev i

SaUsing Cutter Compensation % O10012 ; N1 T12 M06 (3/4 Flat Endmill) ; N2 G90 G54 G00 X-.575 Y-.200 S1500 M03; N3 G43 H12 Z2. ; N4 Z.1 ; N5 G01 Z-.25 F10. ; N6 G41 X0. D12 (Origin); N7 Y1.0 (P1) ; N8 X1.732 Y2.0 (P2) ; N8 X2.875 ; N10 G40 M05 ; N11 G00 Z2. ; N12 G91 G28 Z0. (Machine Home Z-Axis) ; N13 G28 X0. Y0. (Machine Home X,Y-Axis); N14 M30 ; % CamInstructor CNC Programming Work Book-Generic Mill

m pl e

13

PROGRAMMING EXERCISE

EXERCISE #13

Material: Aluminum 6061 CS= ft/min

P1

XY PLANE

1. Tool #8 (Center Drill) Center Drill 4 Holes to a depth of .100 in Absolute Mode (G90)

ew

SaP2Depth of Cut =

ev i

Spindle Speed RPM = 4xCS/D=

2. Tool #10 (.250 Drill) Drill 4 Holes through the part in Incremental Mode (G91)Spindle Speed RPM = 4xCS/D=

Pr

Depth of Cut = Through

3. Tool #6 (.500 Flat End Mill) Mill the Profile to a depth of .260 in Absolute Mode (G90)Spindle Speed RPM = 4xCS/D= Depth of Cut = Cutter Compensation is not being used Feed = in/min Start from the top left corner

With given information as above, write a CNC program.

CamInstructor CNC Programming Work Book-Generic Mill

Page

37

Center Drill all holes in order P1, P2, P3, & P4 in Absolute Mode and drill them in Incremental Mode. The next step will be to contour the profile using an endmill.

m pl eP3Feed = in/min Use a G81 Canned Cycle Feed = in/min Use a G81 Canned Cycle

P4

PROGRAMMING EXERCISE (CONTINUED)% O00013;

EXERCISE #13

Page

38

PrCamInstructor CNC Programming Work Book-Generic Mill

ev i

ew

Sa

m pl e

PROGRAMMING EXERCISE (CONTINUED)

EXERCISE #13

Pr

ev i

ew

SaCamInstructor CNC Programming Work Book-Generic MillPage

m pl e39

14Material: Aluminum 6061 CS= ft/min

CNC PROGRAMMING EXERCISE

EXERCISE #14

XY PLANE

1. Tool #8 (Center Drill) Center Drill 4 Holes in this orderSpindle Speed RPM = 4xCS/D= Depth of Cut = Feed = in/min Use a G81 Canned Cycle Feed = in/min Use a G81 Canned Cycle

2. Tool #10 (.250 Drill) Drill 4 Holes through the part; Decide on the appropriate depthSpindle Speed RPM = 4xCS/D=

Pr

Depth of Cut = Through

3. Tool #6 (.500 Flat End Mill) Machine the inside contour to a depth of .125 (G90) Entry and Exit .500 away from the partSpindle Speed RPM = 4xCS/D= Depth of Cut = Feed = in/min Start from the top left corner

USING CUTTER COMPENSATION (G41) With given information as above, write a CNC program.

40

Page

ev i

Center Drill all holes 1, 2, 3, and 4 in this order and drill all holes through the part. Then using an endmill, contour the inside profile to a depth of .125.

ew

SaCamInstructor CNC Programming Work Book-Generic Mill

m pl e

CNC PROGRAMMING EXERCISE (CONTINUED)% O00014;

EXERCISE #14

Pr

ev i

ew

SaCamInstructor CNC Programming Work Book-Generic MillPage

m pl e41

CNC PROGRAMMING EXERCISE (CONTINUED)

EXERCISE #14

Page

42

PrCamInstructor CNC Programming Work Book-Generic Mill

ev i

ew

Sa

m pl e

Standard MILL G & M CODES

Page

44

PrCamInstructor CNC Programming Work Book-Generic Mill

ev i

ew

Sa

m pl e