Presentation is loading. Please wait.

Presentation is loading. Please wait.

M.nazmi ‹#› General 1- Composition of a part programs. 2- Block Configuration. 3- Part programming Block format: N G X(u) Y(w) Z F M S T N (block number):

Similar presentations


Presentation on theme: "M.nazmi ‹#› General 1- Composition of a part programs. 2- Block Configuration. 3- Part programming Block format: N G X(u) Y(w) Z F M S T N (block number):"— Presentation transcript:

1 M.nazmi ‹#› General 1- Composition of a part programs. 2- Block Configuration. 3- Part programming Block format: N G X(u) Y(w) Z F M S T N (block number): Each block of information must be allocated a number. Ex: N0010, N0020, It is recommended that the blocks are programmed in increments of 10 to allow for further block insertion. G (code for preparatory function): A G code is a command to the control unit to perform some specific task or function. G code is made from the G address letter and a two digit number: G00, G01 Some G codes remain active till replaced or cancelled. These are called modal (retained) G codes. G code from group 0 are non-modal. XYZ (position co-ordinate data): These letters refer to movement along the designated axes. Use XYZ when absolute mode is intended. Use U,W when incremental mode is intended. F (feed function): The movement of the tool at a specified speed for cutting is called the feedrate. The feedrate is defined using the F address letter followed by a numerical value:F256 Feedrates can be specified as either millimetre or inches movement per minute or revolution. Incorrect feedrates may result in damage to the cutting tool or the work piece.

2 M.nazmi ‹#› M code (miscellaneous functions): are (non-standard) commands to the control unit to perform special tasks. M codes are defined using the M address letter and a two digit number EX:M03 spindle forward S (spindle speed function): The rotational speed of the tool with respect to the work piece being cut is called the spindle speed. Four digit number following the S code specifies the speed in RPM. When a move command and a S code is specified in the same block a simultaneous execution of the command is performed. T (tool function): A tool from the ATC is selected using the address letter T followed by a number in ATC magazine position. To command a tool change the M06 code would precede the number of the “new” tool required. Ex: M06 T01 4- Tool Movement Point-to-Point This is a rapid traverse movement that moves the slide to the next position required. Axes movements are not co-ordinated with each other so care must be taken to avoid collision with clamps. This is used for tool positioning and no cutting should be undertaken. Line Motion (Linear interpolation) Tool moves along the specified straight line with a given feed rate. Line motion is used when the tool is to cut in a straight line under co- ordinated axis movement. Contouring This involves programming that is similar to line motion in that the next position is specified and a feed rate is given but an arc movement is achieved.

3 M.nazmi ‹#› De to the great cutting forces that these machines are capable of producing and the increased feed rates over conventional machines, great care must be taken at all times as any fault in the program may have disastrous effects on the machine and the operator. Safety Rules: Make sure you know how to stop the machine in case of an emergency. Make sure that the machine guards are in position when machining. If you suspect something is going wrong, STOP the machine immediately. Isolate the machine before any adjustments. Do not attempt to use the machine until you are sure you can use it correctly. Part programs should be proved prior to machining using a dry run or computer simulation. 6- Program Proving 5- SAFETY

4 M.nazmi ‹#› Methods of checking/verification Graphical simulation: computer graphics are used to simulate the workipece and the cutting tool movements. Any errors in the program will be highlighted prior to the program being entered into the machine and therefore the programmer is able to edit/correct his program.

5 M.nazmi ‹#› DATUM: Machine datum: defines the zero point of all axes which is fixed by the manufacturer. We can use zero offset facility to move this datum. Program/work datum is specified by the programmer when the program is written. All subsequent measurements are then made relative to this new “program” datum. Dry Run: this method of program proving is done on the machine tool but the component or billet to be cut is not installed. As the tool or cutter moves in air the operator looks to see that the cutting tool will not collide with proposed clamping and fixture arrangements or the part. A dry run can be done in single step mode which means that the part program can be run block by block under the control of the operator. All CNC machine controllers have this facility. Y Z X

6 M.nazmi ‹#› Co-Ordinate Dimensioning: There are two types of co-ordinate dimensioning systems used in CNC programming: Incremental: where next position measurements are taken relative to the current position. - an error made in one dimension will effect subsequent measurements - if a dimension changes then the rest of dimension will have to be changed Absolute: Dimensions are always measured from the same datum position therefore there are no build-up or accumulation of errors between dimensions. X Y Absolute Incremental

7 M.nazmi ‹#›

8 G&N programming for CNC lathe 6- Absolute and Incremental Co-ordinates The addresses X and Z within a program relate to a co-ordinate position from the workpiece datum. The address U and W within a program relate to the individual axis movements required to reach the new position, from the last position reached by the tool. The address U refers to the X axis and the address W refers to the Z axis. Dia 20 Dia Z axis X axis Four different ways can be used to write a block within a program: Absolutes/ absolutesG01 X30 Z-50; Incremental/incrementalG01 U10 W-50; Absolutes/incrementalG01 X30 W-50; Incremental/absolutesG01 U10 Z-50;

9 M.nazmi ‹#› List of G Codes (Turning machine) G00positioning (rapid traverse) G01liner interpolation (feed) G02circular interpolation CW G03circular interpolation CCW G04dwell G20inch data input G21metric data input G28reference point return G40tool nose radius compensation cancel G41tool nose radius compensation left G42tool nose radius compensation right G50work coordinate change/Max spindle speed setting G70finish cycle G71stock removal in turning –X G72stock removal in facing-Z G73pattern repeating G74Peck drilling in Z axis G75Grooving in X axis G76multiple thread cutting cycle G81deep hole drilling G90diameter cutting cycle A (outer/inner) G92thread cutting cycle G94cutting cycle B (end face cycle) G96assessed surface speed control G97Assessed surface speed control cancel G98feed per minute G99feed per revolution

10 M.nazmi ‹#› G Codes G00 /Rapid positioning & traverse (modal) Executes a non cutting movement at a rapid feedrate to a specific coordinate position in the working area (absolutes mode) or a certain distance from previous position (increment mode). The two axes move completely independent off each other at the maximum feedrate along a non vector path. P1 2.0 Dia. X 30 Z 0.0 G00 X30 Z2 Non vector movement 2.0 G00 Z2 X30 G00 is modal G01 /Linear interpolation (modal) The G01 executes a cutting movement following a straight line at a set feedrate.G01 X(or U) Z(or W) F The feedrate value programmed into the G01 command is the actual feedrate along the proposed tool path, not the feed rates of the slide. On two axis movements, the machine controller will calculate the separate feedrates for both the X and Z slides, enabling the actual vector feedrate to equal that stated in the G01 command. The coordinates can be programmed in absolutes values as X and Y, or incremental values as U and W. The coordinates may be programmed in mixed modes.to

11 M.nazmi ‹#› Dia P1 P2 P3 25 Dia Absolute: G01Z-25 F0.1; X40 -Z50; Incremental: G01W-25 F0.1; U15 W-25; Mixed: G01W-25 F0.1; X40 W-25; Feedrate values are modal. G02/G03 circular interpolation (modal) G02 executes a cutting movement following a clockwise circular path at a set feedrate. G03 executes the cutting movement following an anticlockwise circular path at a set feedrate. When using absolute position, X & Z values are the dimensions of the end point of the arc in relation to the datum position of the component. In incremental mode, U & W are the distance the tool moves from the start position of the arc. This can either be a plus value or a minus value depending on the direction of the movement relative to the start position. G02X Z RAbsoluteG03X Z R G02+/-U +/-W RIncrementalG03U W R +Z +X R Start End 30 Dia 20 G02 X30 Z-30 R F G02 X30 W-20 R F 10

12 M.nazmi ‹#› When you do not know the radius: A case for I and K To program an arc when only the arc center is given use the address letter I and K. I relates to the address X and is the incremental value and direction from the start point of the arc in the X axis to the arc center. K relates to the address Z and is the incremental value and direction from the start point of the arc in the Z axis to the arc center. End Start Center of ARC I K +Z +X Absolute G02 X Z I K F; IncrementalG02 U W I K F; Start Finish I Z G04 /Dwell G04 X-- (Integer time in seconds) G04 X10 G04 U- (Real time in seconds) G04 X10.5 G04 P-- (time in milliseconds)G04 P2500 Used to enter a set time delay into the program. No decimal points can be used with address P Dwell is performed at the start of the block in which it is programmed. G04 is non-modal

13 M.nazmi ‹#› G20-G21 / Inch-Metric Data input unit The machine controller can be programmed in either inch unit input or metric unit input. G20Imperial/Inchlowest value G21Metric/Millimeterlowest value Do not switch between G20/G21 during a program The offsets must be set according to the units of measurement being used. Offsets !!!!!!!!!!!????!! There are two parameters that are different from tool to tool. These are radius and length. The offset compensation table is a useful means of overcoming this problem G28 /Reference point return G28 X(U) Y(W) The reference point is a fixed position on the machine to which the tool can be moved. (home position) G28 instructs the tool to automatically move to this reference point. X/Y/ can be used to indicate an intermediate point through which the tool will pass before continuing to the reference point.

14 M.nazmi ‹#› G28 moves are performed at rapid traverse rates (non-vector tool path) Reference Point Collision Point P1 P2 G28 U0 W0 when no intermediate points are required U&W are set to zero. P1 P2 P3 Reference Point G28 X100 Z-40 To avoid this collision the tool is sent on a path through the intermediate point P2. Dia G50 /1- Clamping maximum spindle speed. 2- Coordinate system setting. 3- Coordinate system shift. 1- Clamping maximum spindle speed.G50 S____ The value in word address S specifies the maximum spindle speed measured in RPM. this command can be used in conjunction with G96 (Constant surfaces speed control) to clamp the spindle speed to the given value. 2- Coordinate system setting. This command can be used to specify a user coordinate value to register as the current position of the tool. The tool will think it is at the specified coordinates although it has not actually moved.

15 M.nazmi ‹#› Z G50 X10 Z Coordinate system shift. If incremental word addresses are used to specify the values then this command shifts the coordinate axes by the specified values Z G50 U10 W G71 / Stock removal in X axis. G71 is a canned cycle that generates the roughing cuts needed to make a component profile. U1 F r F R U2 W Programmed Path R = retract escaping amount. F= feedrate for roughing. U1= depth of cut in X axis (Radius value) U2=finishing allowance in X axis (sign & Mag) W=finishing allowance in Z axis (sign & Mag) A B

16 M.nazmi ‹#› Prior to writing this command the tool is positioned at the start point. The sequence of tool moves are as follows: A- roughing cycle. 1- From the start position, the tool moves a distance U2 along the X axis and W along the Z axis at a rapid feed rate. 2- the tool moves the distance U1 along the X axis towards the billet centerline at a feed rates corresponding to the G code in the ns block. 3- the tool moves along the Z axis towards the spindle. The feedrate used is a stated in the second block of G at this point the tool retracts in the X and Z axis away from the work at an angle of 45 degrees at a rapid traverse. feedrates. The amount R is stated in the first block of the G the tool then retracts along the Z axis at a rapid feedrate until it reaches the start point of that same diameter. 6- from this point the above cycle is repeated until the programmed shape between ns and nf has been roughed out. 7- after all the roughing passes are completed a singled roughing profile pass is performed at G71stated feedrate. when this single pass is complete the tool will retract to the original starting position of the G71. B-finishing cycle. 8- if the next block contains G70 the same tool will be used to perform the finishing pass at feedrate and spindle speed contained between ns and nf. should a different tool be required to perform the finishing pass: a) The block after nf would instruct the machine to move to a tool change position. b)The next block would instruct the machine to change to the tool required for the finishing pass. c)The next block would move the tool back to the original G71 starting position. d)At this point the finishing pass block would be read into the machine and executed. 9- When the finishing pass ends the tool will retract to original G71 start position. G71 command is written in the following format: N ns …………F…..; G71 U(1) R__; ……….; G71 P ns Q nf U(2) W_ F_; F …….; S …….; Any F or S commands between ns to nf blockN nf ……………….; numbers will only be effective on the finishing pass. Move commands are specified between program block numbers ns to nf.

17 M.nazmi ‹#› In canned cycle G71 only an X axis move is permitted in the first block of the finished profile. Only G00, G01, G02, G03 and G04 can be programmed between ns and nf blocks. 38 Dia30 Dia 25 Dia 20 Dia Rad 1 Rad 1.5 Chamfer N0050G00 X38 Z2; start & finished position N0060G71 U1.5 R0.5; N0070P80 Q170 U2 W0.1 F0.15; N0080G01 X16 F0.3;(ns) N0090Z0.5; N0100X20 Z-1.5 F0.05; N0110Z-30 F0.075; N0120X23; N0130G03 X25 Z-31 R1; N0140G01 X30 Z-65; N0150Z-74; N0160G02 X36 Z-77 R3; N0170G01 X38.5;(NF) N0180G70 P80 Q170;Finish pass G70 /Finishing CycleG70 Pns Qnf After part profile rough cutting has been competed using G71-G72-G73 codes the G70 can be used to perform a finishing pass/cut. ns = the sequence number of the start block for the finishing pass. nf = the sequence number of the last block for the finishing pass. When the finished pass is ended the tool returns to the position it was originally at before G70 was commanded. F and S between the sequence numbers ns and nf will be effectively in the G70 operation.

18 M.nazmi ‹#› Rad 20 Dia 32 Dia 1.5 Chamfer N0070G00 X16 Z2; N0080G71 U1.25 R0.5; N0090G71 P100 Q170 U-1.5 W0.07 F0.075; N0100G01 X36 F0.3; N0110Z0.5; N0120X32 Z-15 F0.05; N0130Z-15 F0.07; N0140X20 Z-30; N0150Z-43.5; N0160G03 X17 Z-45 R1.5 F0.05; N0170G01 X15.8; N0180G70 P100 Q170; G72 /Stock removal in Z axis similar to G71except that the cut is applied in the Z axes. G72 W(1) R__; G72 Pns Qnf U__ W(2) F__; W1 W(2) U Programmed Path F R A B r F= feedrate. r= rapid traverse. W1= depth of cut. U= finishing cut allowance in X axis. R=escaping amount. ns= sequence number of the first block of the programmed finished shape. nf= sequence number of the last block of the programmed finished shape. U= distance and direction of the finished allowance in the X axis. W(2)= finishing cut allowance in Z axis. F=feedrate for roughing.

19 M.nazmi ‹#› Only a Z axis move is allowed in the ns block. If the finishing pass is required to block G70 Pns Qnf is placed after the G72 command has been completed. 80 Dia 60 Dia 60 Dia 40 Dia Dia U N0050G00 X81 Z2; N0060G72 W2 R0.5; N0070G72 P80 Q150 U0.5 W1 F0.1; N0080G00 Z-60; N0090G01 X80 F0.2; N0100X60 W10 F0.075; N0110W10; N0120X40 W10; N0130W20; N0140X180 W11; N0150W1; N0160G70 P80 Q150;

20 M.nazmi ‹#› G75 / grooving cycle. G75 permits grooving in the X axis. G75R(1); G75X(U) Z(W) P__ Q__ R(2) F__; R1peck return amount. X(U) the diameter of the depth of the groove. Z(W)the width of the groove. Pstepover in the X axis measured in microns. Qpecking debt in the Z axis measured in microns. The retract amount R(2) at the base of the groove may be impossible unless a clearance amount has been provided. If no clearance amount has been left the R(2) value must be set to zero or omitted from the block. Q z(w) R(2) P R(1) X(U) Star position X52 Z mm wide grooving tool 20 Dia 50 Dia 40 5 N0060G00 X52 Z-8; N0070G01 X20 F0.075; N0080G00 X52; N0090W-2.5; N0100G75 R0.5; N0110G75 X20 Z-40 P5000 Q2500 R0.5 F0.075;

21 M.nazmi ‹#› G90 /outer diameter cutting cycle The command G90 performs the one pass cutting cycle where the cut is applied in the x axis. G90 is modal. G90 can also be used to cut tapers. To sign of R depends on the direction of path P1. In this example İt is entered as a minus value. Z X/2 U/2 W P1(R) P2(F) P3(F) P4(R) G90 X(U)_ Z(W)_ F_; In this example both U and W are minus. Z X/2 U/2 W P1(R) P2(F) P3(F) P4(R) G90 X(U) Z(W) R_ F_; R 40 Dia 25 Dia Dia 8 N0060G00 X41 Z2; N0070G90 X35 Z-45 F0.1; N0080X30; N0090X25 Z-25; N0100X20; N0110X20 R-3.512;

22 M.nazmi ‹#› G94 /end face turning cycle This command performs a one pass face cutting cycle. The cut is applied in the Z axis. G94 can also be used for cutting taper profiles. If repetition of the move is required only the values that changed needs to be entered into the next block. W P1(R) P3(F) P2(F) P4(r) X U/2 Z G94 X(U) Z(W) F_ W R Z X U/2 G94 X(U) Z(W) R_ F_ To sign of R depends on the direction of path P1. In this example It is entered as a minus value. P1(R) P2(F) P3(F) R Dia 20 Dia 60 Dia N0060G00 X61 Z2; N0070G94 X20 Z-2.5 F0.1; N0080Z-5; N0090Z-7.5; N0100Z-10; N0110Z-12.5; N0120Z-15; N0130G00 X21 Z5; N0140Z-2.5; N0150Z-5; N0160G94 X10 Z-7.5 R-2.5; N0150Z-11 R-6;

23 M.nazmi ‹#› Spindle speed this spindle speed specified by the word address S in any block of a program may be interpreted in two ways depending on the mode selected. these are: G96 / constant surface speedG96 S___; The spindle speed is calculated so that the surface speed is always the specified value (in S) in relation to the tool position. The units used will depanned on whether the machine is operating using metric or Imperial measurements. G96 units can therefore be meters pair minutes, or feet per min. When using G96, the work datum point must be set so that the center of rotation meets the Z axis. G50 code defining clamping off maximum spindle speed must be used in conjunction with G96, so as not to overrun the safe maximum spindle speed off the chuck. G96 is modal. G97 / spindle speed in Rev Per MinuteG97 S__; Once G97 is entered all subsequent spindle speeds are defined in revolution per minutes. G97 is the default mode at power up. G98 / Fee per MinuteG98 F__; This command allows a feedrate written in the units, millimeters per minute or inches per minute to be entered into the machine controller. G98 is modal therefore if a change to the feedrate is required within a program, only the F value needs to be entered. G98 is the default condition at power up. G99 / Per Revolution FeedG99 F__; G99 results in feed rate of millimeters or inches per revolution depending on the previously selected units. G99 is modal

24 M.nazmi ‹#› M Codes:M?? Miscellaneous functions, called M codes, are used by the CNC control to command on/off signals to the machine functions. The functions allocated are constant in most CNC machines however some can vary from one make of the machine to the next. Only one M code can be programmed within each block. M00program stop M01optional stop M02end of program M03spindle forward (clockwise) M04spindle reverse (counter clockwise) M05spindle stop M06automatic tool change M08coolant on M09coolant off M10chuck open M11chuck close M13spindle forward and coolant on M14spindle reverse and coolant on M25tailstock quill extend M26tailstock quill retract M30program stop and reset M38door open M39door close M40parts catcher extend M41parts catcher retract M98sub program call M99sub program end and return Main prog. O0001 N0020……; N0030……; N0040M98 P1000; N0090……; N0100……; N0110M30; Sub prog. 1 O1000 N0020……; N0030……; N0040M98 P2000; N0090……; N0100……; N0110M99; Sub prog. 2 O2000 N0020……; N0030……; N0040……; N0090……; N0100……; N0110M99;

25 M.nazmi ‹#› DATUM: Machine datum: Sometimes referred to as the zero datum defines the zero point of all axes which is fixed by the manufacturer. We can use zero offset facility to move this datum. Program datum is specified by the programmer when the program is written. All subsequent measurements are then made relative to this new “program” datum. 7- G&N programming for CNC Milling Machine X Y Z

26 M.nazmi ‹#› Co-Ordinate Dimensioning: There are two types of co-ordinate dimensioning systems used in CNC programming: Incremental: where next position measurements are taken relative to the current position. - an error made in one dimension will effect subsequent measurements - if a dimension changes then the rest of dimension will have to be changed Absolute: Dimensions are always measured from the same datum position therefore there are no build-up or accumulation of errors between dimensions. X Y Absolute Incremental

27 M.nazmi ‹#› 2 holes on CL, 8 Dia x 10 deep X8X5 deep

28 M.nazmi ‹#› O0001 N0010 G21;metric measure [BILLET X98 Y147 Z36;size of work piece [TOOLDEF T3 D8 Z20;define tool [EDGEMOVE X0 Y0 Z0;force billet datum to be at workpiece datum /for simulation set X datum to 20 /this means we have room to move to the left the billet N0015 M6 T3;pick tool N0020 G90;Go home - absolute N0040 G00 X-4 Y4 Z-25;1st move N0050 M03 S1500;Spindle on N0060 G01 X94 F120;2nd cut N0070 Y143;3nd cut N0080 X-4;make sure no corner remains N0090 Y139; N0100 X93;4rd cut complete N0110 G00 Y140; N0120 X4;ready for last cut N0130 G01 Y4;last cut round / N0140 G00 Z10;lift clear N0150 X49 Y20;position over 1st hole N0150 G01 Z-10; N0160 G00 Z10; N0170 Y127;Over 2nd hole N0180 G01 Z-10; N0190 G00 Z10;Retract / N0200 Y73.5;Over the slot center N0210 G01 Z-5; N0220 G91;incremntal N0230 X30; N0240 X-60; N0250 G00 z10; N0260 G90; N0270 M02; N0280 M30

29 M.nazmi ‹#› G00 /Rapid positioning & traverse G00 X10 Y20 Z30 Executes non cutting movement (point-to-point) at a rapid feed rate. Axis co-ordinate moves can be absolute or incremental G00 freezes tool radius compensation and axis movement are independent of each other. G00 is modal G01 /Linear interpolationG90 G01 X100 Y50 F170 Executes cutting movement along a straight line at a given feed rate Axis co-ordinate moves can be absolute or incremental G01 is modal F is modal and is specified as inches per minute (G20) or millimeters per minute (G21) G02-G03 /Circular interpolation G02 (CW) and G03(CCW) executes a cutting movements in circular path. There are four ways to program a CW/CCW circular path: G90 G02/03 X-- Y-- R-- F-- [can use G91] arc end point in X&Y (absolute/incremental). R length of arc radius. F feed rate. G90 G02/G03 X-- Y-- I-- J-- F-- [can use G91] I-- J-- defines the signed distance of the arc start point from the centre point of the arc. For arcs exceeding 180 degree the radius value R-- must be specified as negative. When X or Y are omitted the arc end point is located at the same position as the arc start point and the arc center is commanded by I or J, an arc of 360 degree is assumed.

30 M.nazmi ‹#› G04 /Dwell G04 X-- (time in seconds) G04 X1.5 G04 P-- (time in 1 milliseconds)G04 P2500 Used to enter a set time delay into the program. No decimal points can be used with address P Dwell is performed at the start of the block in which it is programmed. G04 is non-modal G20-G21 /Data input unit G20Imperial/Inchlowest value G21Metric/Millimeterlowest value Do not switch between G20/G21 during a program G28 /Reference point return G28 X-- Y-- Z-- the reference point is a fixed position on the machine to which the tool can be moved. (home position) X/Y/Z can be used to indicate an intermediate point through which the tool will pass before continuing to the reference point. G28 is non-modal G40-G41-G42 /Cutter compensation G41/42 the tool is positioned on the left/right hand side of the part (programmed path) as seen following the direction of movement from behind the tool. G40 cancels cutter compensation The radius of the tool (amount compensated by) should have been set in the machine controller.

31 M.nazmi ‹#› G40-G41-G42 /Cutter compensation G41/42 the tool is positioned on the left/right hand side of the part (programmed path) as seen following the direction of movement from behind the tool. G40 cancels cutter compensation The radius of the tool (amount compensated by) should have been set in the machine controller. A start-up or ramping on block must be used to allow the tool time to change from moving along he programmed path line to following either side of the path line. Therefore: G41/42 must be contained in the block or specified in the previous block and A G01 is specified in the block and the distance of the linear move must be greater than the tool compensation The tool offset store in the table must not be 00 G02 or G03 can not be specified in the start-up block G40/41/42 are modal G40 can only be performed in a block in which a linear move (G00-G01-G28) is performed 2 holes on CL, 8 Dia x 10 deep X8X5 deep

32 M.nazmi ‹#› Caned cycles (G73-G89) simplifies the program by replacing a number of complex machine sequence blocks with just one block. G98 - initial point return G99 - R point level return G81 /Drilling- spot boring G90/G91 G98/G99 G81 X-- Y-- Z-- R-- K-- F--; G90 G81 X10 Y30 Z-17 R2 F75; G91 G99 G81 X10 Y6 Z-10 R-8 K4 F100; Rapid position to XY (initial level) Rapid traverse to R point level Feed to depth Z Rapid traverse to initial Z level (G98) or R point (G99). K defines the number or repeats G90-G91-G42 /Absolute/incremental data format Z defines the distance from the R point to the bottom of the hole in incremental mode or the position of the hole bottom in absolute mode. R defines the distance from the initial level to the R point level in incremental mode or the position of the R point level in absolute mode. XY Z=0 Z R G99 G98 XY Z=0 Z R G99 G98

33 M.nazmi ‹#› G82 /Drilling- counter boring G90/G91 G98/G99 G82 X-- Y-- Z-- P-- R-- K-- F--; Rapid position to XY (initial level) Rapid traverse to R point level Feed to depth Z Dwell for value P Rapid traverse to initial Z level (G98) or R point (G99). K defines the number or repeats G80 /Canned cycle cancel The data specified (ZPQR) is retained until it is either changed or the canned cycle cancelled. G73 /high speed peck drilling G90/G91 G98/G99 G73 X-- Y-- Z- Q-- R-- F--; Move rapid to XY Move rapid to R Feed to a depth of Q Retract a small distance Re-feed to a further depth of Q Retract and repeat till Z is reached Retract to R or initial level as specified G 83/deep hole peck drilling Rapid position to XY Move rapid to R Feed to a depth of Q Retract rapid to R Rapid traverse back to within 1mm depth of Q cut Feed to a further depth of Q Retract to R and repeat till a depth of Z is reached G 84 /Tapping G74 /Counter Tapping G76 /Fine Boring G 85-G86-G89 /Boring G 87 /Back boring

34 M.nazmi ‹#› G170 - G171 /circular pocket canned cycle The canned cycle required two blocks G170&G171 There are three ways to program these canned cycles G170 R0 P0 Q3 X0 Y0 Z- nI0 J0 K-24; rough cut no allowance G171 P75 S3000 R75 F250 B J; For 1st block R defines the position of the tool to start cycle P =0 means a roughing cycle Q defines the peck (vertical cut) increment XY defines the hole centre I defines the side finish allowance J defines the base finish allowance K defines the radius of the pocket (- means CCW) For 2nd block P defines the cut width percentage S roughing spindle speed R roughing feed in Z F roughing feed in XY B finished spindle speed (ignored when P=0) J finish feed (ignored when P=0) When the tool has finished cutting the tool retracts 1mm in the Z axis, moves to the centre of the circular pocket at rapid traverse, retracts again in the Z axis. G170 R0 P0 Q3 X0 Y0 Z-- I0.5 J0.1 K-24; rough cut WITH G171 P75 S3000 R75 F250 B3500 J200; finishing allowance G170 R0 P1 Q3 X0 Y0 Z-6 I0.5 J0.1 K-24;One step finishing cycle G171 P75 S3000 R75 F250 B3500 J200 I&J are ignored when P=1 S&R&F must be entered but ignored for finishing cycle

35 M.nazmi ‹#› G172 - G173 /Rectangular pocket canned cycle The canned cycle required two blocks G170&G171 G172 I-50 J-50 K0 P0 Q3 R0 X-25 Y-25 Z-6;Roughing cut G173 I0 K0 P75 T1 S3000 R75 F250 B3500 J200 Z5; For 1st block I defines the pocket X length (+ CW/ - CCW) J defines the pocket Y length P=0 roughing cycle Q defines Z peck increment R defines the absolute Z R point XYZ absolute position of the pocket corner points For 2nd block I pocket side finish allowance (=0 when P=0) K Pocket base finish allowance (=0 when roughing) P is the cut width percentage T is the pocket tool S roughing spindle speed R roughing feed for Z F Rouging feed for X and Y B finish spindle speed J finish feed Z safety Z above R. G172 I-50 J-50 K0 P0 Q3 R0 X-25 Y-25 Z-6; rough cut WITH finish G173 I0.5 K0.1 P75 T1 S3000 R75 F250 B3500 J200 Z5; G172 I-50 J-50 K0 P1 Q3 R0 X-25 Y-25 Z-6; One step finishing cycle G173 I0.5 K0.1 P75 T1 S3000 R75 F250 B3500 J200 Z5;

36 M.nazmi ‹#› G90 /Absolute command Active when machine is first switched on G91 /Incremental command G94 /Feed per minute (G29) F6= 6 inches/min (G21) F150= 150 mm/minute G95 /Feed per revolution of spindle List of G Codes (Milling machine) G00positioning (rapid traverse) G01liner interpolation (feed) G02circular interpolation CW G03circular interpolation CCW G04dwell G20inch data input G21metric data input G28reference point return G40/G41/ G73-G89Canned cycles G73High speed peck drilling G74Counter tapping G76Fine boring G80Canned cycle cancel G81Drilling – counter boaring G83Deep hole peck drilling G84Tapping G85Boring G86Boring G87 Peck boring G89Boring G90Absolute zero command G91Incremental command G94feed per minute G95feed per revolution G98Return to initial level G99Return to R point G170-G173 Cirular/Rect pockets


Download ppt "M.nazmi ‹#› General 1- Composition of a part programs. 2- Block Configuration. 3- Part programming Block format: N G X(u) Y(w) Z F M S T N (block number):"

Similar presentations


Ads by Google