part programming manual machinematejinhoe/notes/skmp4722 modern... · 1 basics of nc programming...

376
Part Programming Manual MACHINEMATE ®

Upload: phamxuyen

Post on 06-May-2018

220 views

Category:

Documents


2 download

TRANSCRIPT

Page 1: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

Part Programming Manual

MACHINEMATE®

Page 2: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 2/376

NOTE Progress is an ongoing commitment at MACHINEMATE INC. We continually strive to offer the most advanced products in the industry. Therefore, information in this document is subject to change without notice. The illustrations and specifications in this document are not binding in detail. MACHINEMATE INC shall not be liable for any technical or editorial omissions occurring in this document nor for any consequential or incidental damages resulting from the use of this document.

DO NOT ATTEMPT to use any MACHINEMATE INC product until the use of such product is completely understood. It is the responsibility of the user to make certain proper operation practices are understood. MACHINEMATE INC products should be used only by qualified personnel and for the express purpose for which said products were designed. Should information not covered in this document be required, please contact: MACHINEMATE INC. Fond du Lac, WI 54937 Phone: 920-907-0001 Fax: 920-907-0181 Email: [email protected] Document revision: 0527

Page 3: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 3/376

Table of Contents TABLE OF FIGURES AND TABLES ........................................................................... 10 1 BASICS OF NC PROGRAMMING ........................................................................... 15

1.1 Program Layout................................................................................................ 15 1.2 Program block .................................................................................................. 15 1.3 Program Word.................................................................................................. 16 1.4 Auxiliary functions (BCDs)................................................................................ 22 1.5 Programming functional overview .................................................................... 23 1.6 Block suppression ............................................................................................ 24 1.7 Program Repetition .......................................................................................... 24 1.8 Subroutines ...................................................................................................... 25 1.9 Comments in NC programs.............................................................................. 26 1.10 Program number .............................................................................................. 26 1.11 Cycle block layout ............................................................................................ 27 1.12 Reading from External Data Carriers, Format Defaults .................................... 27 1.13 Checksum ........................................................................................................ 29 1.14 Program Safety ................................................................................................ 32 1.15 Axis designations for machine tool machines................................................... 33 1.16 Gantry Axes...................................................................................................... 36 1.17 Resettable Rotational Axis ............................................................................... 37

2 POSITIONING INSTRUCTIONS............................................................................... 38 2.1 General positioning instructions ....................................................................... 38

2.1.1 Monitoring the axis travel limits.............................................................. 38 2.1.2 G00 linear interpolation in rapid traverse............................................... 39 2.1.3 G01 linear interpolation in the feed rate................................................. 43 2.1.4 G02, G03 circular interpolation with specified center point .................... 46 2.1.5 G12, G13 circular interpolation with specified radius............................. 50 2.1.6 Helical Interpolation ............................................................................... 52 2.1.7 G74 Programmable homing................................................................... 53 2.1.8 M80 delete remaining path using probe function ................................... 53

2.2 Positioning instructions..................................................................................... 59 2.2.1 G07 Tangential circular interpolation ..................................................... 59 2.2.2 G05, G06 Spline Definition and Spline Interpolation 2D ........................ 61 2.2.3 G78, G79 Tangential Setting to the 2D Path ......................................... 66

3 INFLUENCING THE PROGRAM.............................................................................. 75 3.1 M00 program interruption (unconditional stop)................................................. 75 3.2 M01 program interruption (conditional stop)..................................................... 75 3.3 M02, M30 end of program ................................................................................ 75 3.4 G10, G11 empty/fill dynamic block buffer......................................................... 76

3.4.1 G10 Empty dynamic block buffer........................................................... 76 3.4.2 G11 Fill dynamic block buffer ................................................................ 77

3.5 G72, G73 interpolation with precision stop OFF or ON .................................... 77 3.6 G08, G09 look ahead OFF or ON..................................................................... 79 3.7 G186 corner acceleration, contour accuracy.................................................... 81

3.7.1 Corner Acceleration............................................................................... 82 3.7.2 Contour Accuracy: ................................................................................. 85

Page 4: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 4/376

3.8 G75, G76 Curvature .........................................................................................86 3.8.1 Curvature Activation...............................................................................86 3.8.2 Curvature Acceleration Limit ..................................................................87

3.9 G04 dwell time..................................................................................................87 3.10 Corner Smoothing.............................................................................................88

3.10.1 G-codes .................................................................................................88 3.10.2 Curvature radius R.................................................................................88 3.10.3 Corner deviation E .................................................................................88 3.10.4 Minimum block length ............................................................................89 3.10.5 Acceleration monitoring .........................................................................90 3.10.6 Minimum and maximum bend angle ......................................................90 3.10.7 The necessity of corner smoothing ........................................................91 3.10.8 Programming .........................................................................................92 3.10.9 Problem case: angle too acute...............................................................95 3.10.10 Problem case: collision monitor with real-time mill radius correction 96

4 TECHNOLOGICAL INSTRUCTIONS .......................................................................97 4.1 Influencing the feedrate ....................................................................................97

4.1.1 G94 Inches (Millimeters) per minute � IPM/MMPM................................97 4.1.2 G95 Inches (Millimeters) per revolution � IPR/MMPR............................97 4.1.3 F word for feed rate................................................................................97 4.1.4 G63, G66 Feed override ........................................................................98 4.1.5 Programmable acceleration .................................................................100

4.2 Spindle Control ...............................................................................................101 4.2.1 S Word.................................................................................................101 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ....................101 4.2.3 M05 Spindle OFF.................................................................................101 4.2.4 M19 Spindle Orientation ......................................................................101 4.2.5 G63, G66 Spindle Override..................................................................101 4.2.6 G92 Spindle speed limitation ...............................................................103 4.2.7 G96 Constant Surface Speed (Feet/Meter)..........................................103 4.2.8 G97 Revolutions per minute.................................................................104 4.2.9 Reversal of rotation at M19, spindle orientation ...................................104

4.3 Tool compensation functions ..........................................................................105 4.3.1 Tool tip radius compensation ...............................................................105 4.3.2 Tool length compensation values.........................................................107 4.3.3 Tool or turret selection .........................................................................109

4.4 G110-G117 power control 2D instructions......................................................113 4.4.1 Application ...........................................................................................113 4.4.2 Programming .......................................................................................113 4.4.3 Fast output signals for laser power control ..........................................128

4.5 Advanced Regulation Technology (ART)........................................................134 4.5.1 Application ...........................................................................................134

5 GEOMETRIC INSTRUCTIONS...............................................................................135 5.1 General geometric instructions .......................................................................135

5.1.1 G40-G44 Path compensations.............................................................135 5.1.2 G53-G59 Part position offsets..............................................................166

Page 5: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 5/376

5.1.3 G70, G71 Programming in metric or inch format ................................. 170 5.1.4 G90, G91 Absolute/incremental dimension programming ................... 171 5.1.5 G92 Set axis value .............................................................................. 173 5.1.6 G14-G16 Polar coordinate programming............................................. 175

5.2 Specific geometric instructions....................................................................... 180 5.2.1 G17-G20 Plane selection..................................................................... 180 5.2.2 G24-G27 Programmable work field limitation (Safe Zone Programming)................................................................................................. 182 5.2.3 G38, G39 Programmable axis motion mirror ....................................... 185 5.2.4 G51, G52 Part rotation......................................................................... 190 5.2.5 G50 Scaling ......................................................................................... 193

5.3 Dresser, wheel or tool tip radius compensation (DWRC) ............................... 195 5.3.1 Entering compensation values in tables .............................................. 195 5.3.2 Dresser Wheel Radius Compensation................................................. 198 5.3.3 DWRC application schemes................................................................ 200 5.3.4 NC block formats ................................................................................. 203 5.3.5 Compensation Entry/Exit Move Types................................................. 204 5.3.6 Special Cases...................................................................................... 211

6 GENERAL CYCLE PROGRAMMING .................................................................... 213 6.1 Introduction .................................................................................................... 213 6.2 Application of Cycle Blocks ............................................................................ 213

6.2.1 Cycle programming ............................................................................. 213 6.2.2 Integrating Cycle Blocks in an NC Program......................................... 214 6.2.3 Comments ........................................................................................... 214 6.2.4 Cycle block syntax............................................................................... 215 6.2.5 Basic rules for processing of instructions............................................. 216 6.2.6 Numbers and variables........................................................................ 217 6.2.7 Calculation operations and functions................................................... 218 6.2.8 Use of P-parameters ........................................................................... 222 6.2.9 Use of CNC parameters ...................................................................... 225 6.2.10 Conditional instructions and jump instructions..................................... 229 6.2.11 Possible errors..................................................................................... 231 6.2.12 Instructions .......................................................................................... 233

6.3 Work Cycles ................................................................................................... 236 6.3.1 General notes ...................................................................................... 236 6.3.2 Example............................................................................................... 236

7 DRILLING CYCLES ............................................................................................... 237 7.1 Introduction .................................................................................................... 237 7.2 Use of the drilling cycles................................................................................. 238

7.2.1 Allocation of the parameters/definition of terms................................... 238 7.2.2 Selection of the desired drilling cycle................................................... 240 7.2.3 Move to the drilling position in X and Y (once or repeatedly)............... 240 7.2.4 Deselecting of the drilling cycle ........................................................... 242

7.3 G80 Cancel the drilling cycle .......................................................................... 243 7.4 G81 Drilling to final depth ............................................................................... 243 7.5 G82 Spot facing with dwell time ..................................................................... 245 7.6 G83 Deep hole drilling.................................................................................... 247

Page 6: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 6/376

7.7 G84 Thread cutting with balanced chuck........................................................249 7.8 G85 Reaming .................................................................................................251 7.9 G86 Bore out ..................................................................................................253 7.10 G87 Reaming with measuring stop.................................................................255 7.11 G88 Bore out with spindle halt ........................................................................257 7.12 G89 Bore out with intermediate halt................................................................259 7.13 Example: base plate .......................................................................................261

8 PROGRAM OPTIMIZATION...................................................................................264 8.1 Hints for rational program creation..................................................................264

8.1.1 Subroutines..........................................................................................264 8.1.2 Modally effective instructions ...............................................................264 8.1.3 Value allocation to NC addresses using parameters ...........................264

8.2 Hints for Processing Programs .......................................................................265 8.2.1 Look Ahead..........................................................................................265 8.2.2 Programmable acceleration at Look Ahead .........................................265 8.2.3 Activation of special functions using a subroutine................................265

8.3 Hints for Avoiding Errors.................................................................................266 8.3.1 Protection of subroutines against call up as main program..................266 8.3.2 Functions not automatically reset at the program end .........................266 8.3.3 Circular interpolation ............................................................................266 8.3.4 Avoid dummy blocks at subroutine call up ...........................................266 8.3.5 Avoid dummy blocks at subroutine end ...............................................267 8.3.6 Avoid dummy blocks at path compensation.........................................267 8.3.7 Collision free movement.......................................................................268 8.3.8 Contour accuracy (G186).....................................................................268

9 PROGRAMMING VARIOUS CNC FEATURES/CAPABILITIES ............................269 9.1 Angled Wheel Transformation ........................................................................269

9.1.1 Angled wheel transformation syntax ....................................................269 9.1.2 Axes sequence by two step mode .......................................................273 9.1.3 Mirroring...............................................................................................274 9.1.4 H and G compensation ........................................................................274

9.2 Automatic Spindle Gear Step (Range) Selection............................................274 9.2.1 General ................................................................................................274 9.2.2 M40 is Active........................................................................................275 9.2.3 M41 to M46 is Active............................................................................275 9.2.4 Switchover procedure between gear ranges........................................275 9.2.5 G96 is Active........................................................................................276 9.2.6 G92 is Active........................................................................................276 9.2.7 G33/G34 is Active ................................................................................276

9.3 Barrel Cam Transformation ............................................................................277 9.3.1 General ................................................................................................277 9.3.2 Barrel cam transformation using Cartesian coordinates G102.............277 9.3.3 Barrel cam transformation with cylinder coordinates G106..................279 9.3.4 Illegal G-codes during Barrel Cam.......................................................280 9.3.5 Real time radius compensation G103, G107 .......................................280 9.3.6 Barrel cam transformation with centerline deviation of an additional axis and real time radius compensation, G104, G108....................282

Page 7: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 7/376

9.3.7 Switching between machine coordinates with barrel cam transformation. ............................................................................................... 284 9.3.8 End of program and change of the operating mode. ........................... 284

9.4 Diameter Programming .................................................................................. 285 9.4.1 Programming ....................................................................................... 285 9.4.2 Control reset, end of program.............................................................. 288 9.4.3 Display functions ................................................................................. 288 9.4.4 Programming conditions...................................................................... 289 9.4.5 Programming Examples ...................................................................... 290

9.5 Distance Regulation ....................................................................................... 291 9.5.1 G265 Axis selection............................................................................. 291 9.5.2 M140 / M141 activation/deactivation of distance regulation................. 291 9.5.3 Monitoring the axis limits ..................................................................... 292 9.5.4 G74 is invalid ....................................................................................... 292

9.6 Feed Influencing via Probe Signals ................................................................ 293 9.6.1 General................................................................................................ 293 9.6.2 Programming ....................................................................................... 294 9.6.3 Programming measurement probe logic.............................................. 295 9.6.4 Masking out input bits via the PLC ...................................................... 295 9.6.5 G92 and setting the remaining distance to zero .................................. 295 9.6.6 Measurement probe logic via the interface signal................................ 295 9.6.7 Dwell time............................................................................................ 296 9.6.8 Programming with Stop on block pre-processing ................................ 296

9.7 Feed Interpolation .......................................................................................... 296 9.7.1 Function and handling ......................................................................... 296

9.8 Handwheels in Automatic mode..................................................................... 298 9.8.1 General................................................................................................ 298 9.8.2 Programming ....................................................................................... 298 9.8.3 End of program and control reset ........................................................ 299 9.8.4 Cycle-Stop, Cycle-Off .......................................................................... 299

9.9 Infinitely Rotating Round (or Rotary) Axis ...................................................... 300 9.9.1 General................................................................................................ 300 9.9.2 Programming ....................................................................................... 300 9.9.3 Normal round axis ............................................................................... 301 9.9.4 Tool magazine round axis.................................................................... 303 9.9.5 Modulo round axis ............................................................................... 304

9.10 Multiple Spindles ............................................................................................ 307 9.10.1 General................................................................................................ 307 9.10.2 Spindle programming .......................................................................... 307 9.10.3 Thread cutting, G33 and G34 .............................................................. 308 9.10.4 Spindle speed override rotary switch, G63 .......................................... 308 9.10.5 Spindle speed restriction, G92............................................................. 308 9.10.6 Feed rate in mm / rev, or in / rev, G95................................................. 309 9.10.7 G93, G96 and G97 .............................................................................. 310 9.10.8 Spindle orientation, M19...................................................................... 312 9.10.9 Spindle / rotational axis switchover...................................................... 312 9.10.10 Gear stages .................................................................................... 312

Page 8: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 8/376

9.11 Parallel Axes...................................................................................................313 9.11.1 Syntax..................................................................................................313 9.11.2 Program examples...............................................................................313

9.12 Polar Transformation ......................................................................................315 9.12.1 General ................................................................................................315 9.12.2 Examples .............................................................................................316 9.12.3 Monitoring the axis limits......................................................................321 9.12.4 Illegal G-codes.....................................................................................321 9.12.5 Switching operations in machine coordinates with polar transformation.................................................................................................321 9.12.6 Switching of the limits of the axes ........................................................322 9.12.7 End of program and change of the operating mode.............................322 9.12.8 Machine error compensation for polar transformation..........................322 9.12.9 Speed monitoring at polar transformation ............................................324

9.13 Positioning Axis ..............................................................................................325 9.13.1 Introduction ..........................................................................................325 9.13.2 Programming .......................................................................................326

9.14 Programmable Oscillation...............................................................................329 9.14.1 Preparation set.....................................................................................329 9.14.2 Erasing oscillation data ........................................................................329 9.14.3 Deviation lengths .................................................................................329 9.14.4 Number of deviations ...........................................................................329 9.14.5 Frequency............................................................................................330 9.14.6 Dwell times...........................................................................................330 9.14.7 Behavior in case of programming errors ..............................................330 9.14.8 Behavior in case of Emergency Stop ...................................................330 9.14.9 M20 Start M-code ................................................................................331 9.14.10 M21 End M-code.............................................................................331 9.14.11 M00 Programming ..........................................................................332 9.14.12 Program end / home position..........................................................332 9.14.13 Error messages...............................................................................332

9.15 Switchover Spindle-Rotary Axis......................................................................333 9.15.1 General ................................................................................................333 9.15.2 Programming .......................................................................................333 9.15.3 Spindle running ....................................................................................334

9.16 Thread Cutting................................................................................................336 9.16.1 General ................................................................................................336 9.16.2 Spindle Control ....................................................................................336 9.16.3 Programming thread with uniform pitch, G33.......................................336 9.16.4 Programming thread with dynamic pitch, G34 .....................................337 9.16.5 Definition of the thread block................................................................337 9.16.6 Programming cylindrical thread, G33, G34 ..........................................338 9.16.7 Programming conical thread G33, G34................................................341 9.16.8 Programming lag free thread, G133, G134..........................................342

9.17 Turning Cycles or Stock Removal Cycles.......................................................344 9.17.1 General ................................................................................................344 9.17.2 G271 Stock removal in turning.............................................................344

Page 9: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 9/376

9.17.3 G272 Stock removal in facing.............................................................. 347 9.17.4 Direction of allowance.......................................................................... 348 9.17.5 G270 Finishing Cycle .......................................................................... 350 9.17.6 G274 Peck finishing cycle.................................................................... 351 9.17.7 G275 Outer diameter/internal diameter turning cycle .......................... 352 9.17.8 G276 Multiple pass threading cycle..................................................... 353 9.17.9 Error messages ................................................................................... 355 9.17.10 Part program display ...................................................................... 356

10 PROGRAMMING MACHINEMATE SPECIAL FEATURES ................................... 357 10.1 Lathe T-code Programming............................................................................ 357 10.2 Programming a Rotary-only Motion in G70 .................................................... 358 10.3 G93 for Programming a Mix of Linear and Rotary Motion .............................. 358 10.4 Canned Drilling Cycle Letter Programming .................................................... 360

10.4.1 Canned Cycle Programming with Letters not Parameters................... 360 10.4.2 Canned Cycle Programming: Cross Reference to Section 7 ............... 362 10.4.3 Canned Cycle Programming Examples............................................... 362

10.5 Two-axes Collinear Tracking Programming ................................................... 363 10.6 Extended Part Offsets Programming.............................................................. 365

10.6.1 Programming the additional Part Offsets............................................. 365 10.6.2 Managing the additional part offsets.................................................... 366

INDEX ......................................................................................................................... 368

Page 10: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 10/376

Table of Figures and Tables Figure 1-1: Elements of an NC program ......................................................................... 15 Table 1-1: G-Codes ........................................................................................................ 20 Table 1-2: M-Codes........................................................................................................ 22 Figure 1-2: Nesting depth ................................................................................................ 25 Table 1-3: ASCII Character Set ..................................................................................... 31 Figure 1-3: Orientation of the three basic feed axes using the right-hand rule ............... 33 Figure 1-4: Work piece rigid, tool rotates ....................................................................... 34 Figure 1-5: Work piece rotates, tool rigid ....................................................................... 35 Figure 1-6: Position and direction of feed rate and rotary axes....................................... 36 Figure 2-1: G00 when turning ......................................................................................... 39 Figure 2-2: G00 when milling ......................................................................................... 39 Figure 2-3: Two successive rapid traverse positioning instructions................................ 40 Figure 2-4: Absolute dimension coordinates (G90) ........................................................ 41 Figure 2-5: Incremental dimension coordinates (G91).................................................... 42 Figure 2-6: G01 when turning ......................................................................................... 43 Figure 2-7: G01 when milling ......................................................................................... 44 Figure 2-8: G01 Linear interpolation in the feed rate...................................................... 45 Figure 2-9: Direction of rotation with G02 and G03 (turning)........................................ 46 Figure 2-10: Direction of rotation with G02 and G03 (milling)........................................ 47 Table 2-1: Interpolation parameters at G02 and G03 (at G17, G18 and G19)............... 48 Figure 2-11: Example for G02........................................................................................... 49 Figure 2-12: G12, G13 Circular interpolation in the counter-clockwise direction with

specified radius with K > 0 and K < 0 ............................................................................ 50 Figure 2-13: G12, G13 circular interpolation with specified radius.................................. 51 Figure 2-14: Delete remaining path using probe function (ignoring the probe's radius)... 54 Figure 2-15: Delete remaining path using probe function and measuring probe radius ... 56 Figure 2-16: CNC reaction to the probe contact................................................................ 57 Figure 2-17: Straight line/circular arc................................................................................ 59 Figure 2-18: Straight line/circular arc................................................................................ 60 Figure 2-19: Circular arc/circular arc ................................................................................ 61 Figure 2-20: M70: Start of spline and end of spline with the curve 0 (natural spline)...... 63 Figure 2-21: M71: Start of spline with tangential transition and end with curve 0........... 63 Figure 2-22: M72: Start of spline with curve 0 and end of spline with tangential transition

63 Figure 2-23: M73: Start of spline and end of spline with tangential transitions ............... 64 Figure 2-24: Path velocity with linear interpolation and spline interpolation ................... 66 Figure 2-25: Tangential setting to the 2D path.................................................................. 67 Figure 2-26: Tangential setting to the 2D path when turning............................................ 67 Figure 2-27: Tangential setting to the 2D path when punching/nibbling.......................... 68 Figure 2-28: Programming the leading-in at a specific angle............................................ 69 Figure 2-29: Programming a changing angle offset using G78......................................... 70 Figure 2-30: Behavior of the lead-in during a reversal of the motion direction................ 71 Figure 2-31: Influence of the lead-in at reversal of motion reversal ................................. 72

Page 11: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 11/376

Figure 3-1: Contour with contouring error ...................................................................... 77 Figure 3-2: Contour processed with precision stop ......................................................... 78 Figure 3-3: Processing of NC blocks with and without "Look Ahead" .......................... 80 Table 3-1: Effect of different E word values.................................................................. 82 Figure 3-4: Sharp decrease in speed between motion blocks dependent on the corner

acceleration...................................................................................................................... 83 Figure 3-5: Sharp decrease in speed dependent on the angle between successive motion

blocks. 84 Figure 3-6: Circle reduction error when pulling out of a circle from standstill .............. 85 Figure 3-7: Corner deviation E ........................................................................................ 89 Figure 3-8: Curvature radius R ........................................................................................ 89 Figure 3-9: Curvature radius R with a minimum path shortened .................................... 90 Figure 3-10: Curvature bend angle in a corner .................................................................. 91 Figure 3-11: Corner smoothing and corner jumps............................................................. 92 Figure 3-12: Corner smoothing in G203 ........................................................................... 93 Figure 3-13: Real-time radius correction with corner smoothing ..................................... 95 Figure 3-14: Corner smoothing with corners rounded outside not inside ........................ 96 Figure 4-1: Tool tip radius compensation for rotating tools.......................................... 105 Figure 4-2: Tool length compensation for rotating tools............................................... 107 Figure 4-3: Tool length compensation for fixed tools ................................................... 107 Figure 4-4: Output of firm voltage values ..................................................................... 117 Figure 4-5: Voltage output as a function of the path velocity ....................................... 119 Figure 4-6: Call of U20 when firm output voltage is active.......................................... 120 Figure 4-7: Voltage output as a function of time........................................................... 122 Figure 4-8: Output voltage as a function of time (T1 not programmed) ...................... 123 Figure 4-9: Voltage output as a function of time (example U31).................................. 124 Figure 4-10: Voltage output as function of the motion path (example U41) .................. 126 Figure 4-11: Power control .............................................................................................. 127 Figure 4-12: Position-defined fast M-functions .............................................................. 130 Figure 5-1: Effect of different tool radii on the work piece contour. ............................ 135 Figure 5-2: Equidistant left and right of the work piece contour .................................. 136 Figure 5-3: Path compensation at the block transition Straight line/Straight line......... 137 Figure 5-4: Path compensation at the block transition Straight line/Circular arc.......... 138 Figure 5-5: Path compensation at the block transition circular arc/circular arc ............ 139 Figure 5-6: Move to intersection on a linear path.......................................................... 141 Figure 5-7: Move to intersection on a spiral path.......................................................... 142 Figure 5-8: Comparison of path compensations G41 and G43. .................................... 143 Figure 5-9: Retreat on a linear path ............................................................................... 144 Figure 5-10: Retreat on a spiral path ............................................................................... 145 Figure 5-11: Generation of intermediate blocks, example 1 ........................................... 146 Figure 5-12: Generation of intermediate blocks, example 2 ........................................... 147 Figure 5-13: Generation of intermediate blocks, example 3 ........................................... 148 Figure 5-14: Angle cut off ............................................................................................... 149 Figure 5-15: End point radius compensation................................................................... 150 Figure 5-16: Real-time radius compensation................................................................... 151 Figure 5-17: Insufficient cutting of internal contours with real-time radius compensation

151

Page 12: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 12/376

Figure 5-18: Motion with blocks without positioning information in the active plane... 154 Figure 5-19: Motion with a change between G41 and G42............................................. 155 Figure 5-20: Motion with a sign change of the compensation value............................... 156 Figure 5-21: Motion with change of compensation value but no sign change, example 1

157 Figure 5-22: Motion with change of compensation value but no sign change, example 2

158 Figure 5-23: Motion with a tool radius that is too large for an inside corner.................. 159 Figure 5-24: Radius smaller than compensation value (R < D) ...................................... 160 Figure 5-25: Motion with a full circle as external contour (with G42) ........................... 161 Figure 5-26: Motion with a full circle as external contour (with G44) ........................... 162 Figure 5-27: Motion with a full circle as internal contour (with radius compensation).. 163 Figure 5-28: Full circle as external contour (with radius compensation) ........................ 164 Figure 5-29: Processing with external path compensation at corners, internal contour

processing 165 Figure 5-30: Setting work piece zero points.................................................................... 167 Figure 5-31: Programming in metric or imperial format................................................. 170 Figure 5-32: Dimension input in absolute dimension programming............................... 171 Figure 5-33: Dimension input in incremental dimension programming ......................... 172 Figure 5-34: Set axis value with G92 .............................................................................. 173 Figure 5-35: Definition of a reference point for work piece zero points......................... 174 Figure 5-36: Polar coordinates......................................................................................... 176 Table 5-1: Major axis and minor axis .......................................................................... 176 Table 5-2: Angle and radius values in the three predefined planes.............................. 177 Figure 5-37: Polar coordinate programming without pole point information ................. 177 Figure 5-38: Polar coordinate programming with pole point information ...................... 179 Figure 5-39: Circular interpolation plane selection ......................................................... 181 Table 5-3: Circular interpolation planes (G20) ............................................................ 182 Figure 5-40: Work area of a machine tool with the axes X and Y .................................. 183 Figure 5-41: Programmable mirror, effect of the programs P1 to P4.............................. 186 Figure 5-42: Mirror with prior setting of an axis value using G92 ................................. 187 Figure 5-43: Part rotation in the case of active G90........................................................ 191 Figure 5-44: Part rotation in combination with incremental programming (G91) .......... 192 Figure 5-45: Scaling with absolute and relative dimension input ................................... 194 Figure 5-46: Grinding wheel offset definitions ............................................................... 195 Figure 5-47: Grinding wheel radius orientation definitions ............................................ 196 Figure 5-48: Dresser or tool tip radius orientation definitions ........................................ 197 Figure 5-49: Grinding wheel control point and gauge point definitions ......................... 198 Figure 5-50: Inside corner definition............................................................................... 199 Table 5-4: Differences between DWRC entry/exit move types A, B, C...................... 199 Table 5-5: G-codes for DWRC path compensation ..................................................... 200 Table 5-6: Application schemes for DWRC path compensation ................................. 201 Figure 5-51: Dress/wheel radius compensation example ................................................ 201 Figure 5-52: Wheel corner radius compensation example .............................................. 202 Table 5-7: Activations of DWRC path compensation.................................................. 203 Figure 5-53: Linear and circular intermediate blocks...................................................... 204 Figure 5-54: The three compensation entry move types (overview)............................... 205

Page 13: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 13/376

Figure 5-55: Compensation entry moves type A, linear to linear.................................... 206 Figure 5-56: Compensation entry moves type A, linear to circular ................................ 207 Figure 5-57: Compensation entry moves type A, circular to linear ................................ 207 Figure 5-58: Compensation entry moves type A, circular to circular ............................. 208 Figure 5-59: Compensation entry moves type B, linear to linear.................................... 209 Figure 5-60: Compensation entry moves type B, circular intermediate blocks .............. 210 Figure 5-61: Compensation entry moves type C, linear to linear.................................... 211 Table 6-1: Cycle programming: parameters and instructions ...................................... 216 Figure 6-1: Transfer of the NC blocks to the interpolator process ................................ 216 Table 6-2: Calculation operations and functions.......................................................... 219 Table 6-3: Reserved cycle parameters.......................................................................... 224 Table 6-4: Summary of CNC data as cycle parameters ............................................... 225 Table 6-5: IF comparison operators ............................................................................. 233 Table 6-6: Summary of cycle block SEL functions ..................................................... 235 Figure 7-1: Reference plane, retract plane and final hole depth.................................... 239 Figure 7-2: Drilling cycle G81 ...................................................................................... 244 Figure 7-3: Drilling cycle G82 ...................................................................................... 246 Figure 7-4: Drilling cycle G83 ...................................................................................... 248 Figure 7-5: Drilling cycle G84 ...................................................................................... 250 Figure 7-6: Drilling cycle G85 ...................................................................................... 252 Figure 7-7: Drilling cycle G86 ...................................................................................... 254 Figure 7-8: Drilling cycle G87 ...................................................................................... 256 Figure 7-9: Drilling cycle G88 ...................................................................................... 258 Figure 7-10: Drilling cycle G89 ...................................................................................... 260 Figure 7-11: Example: Base plate.................................................................................... 261 Figure 9-1: Relationship between two linear axes with Angled Wheel Transformation

270 Figure 9-2: Example for G222, two step move for Angled Wheel Transformation...... 272 Table 9-1: Angled Wheel Transformation two-step motion description ..................... 273 Figure 9-3: Interpretation of the X and Y values when G102 is active. ........................ 278 Figure 9-4: Barrel cam transformation .......................................................................... 278 Figure 9-5: Meaning of the C and V values when G106 is active................................. 280 Figure 9-6: Osculation plane – axis allocations for the cylinder ................................... 281 Figure 9-7: Real-time radius compensation................................................................... 282 Figure 9-8: Barrel cam transformation with centerline deviation ................................. 283 Figure 9-9: Diameter Programming............................................................................... 285 Table 9-2: Diameter programming G-codes ................................................................ 286 Figure 9-10: Diameter Programming with negative orientation...................................... 287 Figure 9-11: Diameter Programming Point of Contact ................................................... 289 Table 9-3: Diameter programming conditions ............................................................. 289 Figure 9-12: Rotations of a normal round axis................................................................ 301 Table 9-4: Programmable values for a round axis ....................................................... 301 Figure 9-13: Rotations of A axis (normal round) ............................................................ 303 Table 9-5: Programmable values for a tool magazine axis .......................................... 303 Figure 9-14: Tool magazine round axis........................................................................... 304 Figure 9-15: Modulo round axis ...................................................................................... 305 Table 9-6: Programmable values for a modulo axis..................................................... 305

Page 14: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 14/376

Figure 9-16: Motion path for G101 example: processing a square contour .................... 316 Figure 9-17: Square contour of a work piece before real-time polar transformation ...... 317 Figure 9-18: Square contour of a work piece during real-time polar transformation...... 319 Figure 9-19: Displacement of Cartesian coordinates....................................................... 323 Figure 9-20: Machine error compensation ...................................................................... 324 Table 9-7: Definition of a G33/G34 thread block ........................................................ 337 Figure 9-21: Work piece before G33 processing............................................................. 338 Figure 9-22: Work piece after processing with G33 ....................................................... 339 Figure 9-23: Work piece with controller running out (G33) ........................................... 339 Figure 9-24: Work piece with increasing pitch (G34)..................................................... 340 Figure 9-25: Work piece with decreasing pitch (G34) .................................................... 340 Figure 9-26: Work piece before processing with G33..................................................... 341 Figure 9-27: Work piece after processing with G33 ....................................................... 341 Figure 9-28: Work piece with controlled running out (G33) .......................................... 342 Figure 9-29: Stock removal ............................................................................................. 345 Figure 9-30: Stock removal: direction of allowance ....................................................... 346 Figure 9-31: Stock removal in facing .............................................................................. 348 Figure 9-32: Stock removal in facing: direction of removal ........................................... 349 Figure 9-33: G274 peck finishing cycle .......................................................................... 352 Figure 9-34: G275 inner/outer diameter turning cycle .................................................... 353 Figure 9-35: G276 multiple pass thread turning cycle .................................................... 355 Figure 9-36: G276 threading cycle and tool tip parameters ............................................ 355

Page 15: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 15/376

1 Basics of NC Programming 1.1 Program Layout

An NC program (part program) is a sequence of processing steps and is divided into program blocks. Each program block contains the information that the machine requires to perform the desired process.

N10 G90

Additional conditions

N20 G1 X50 Y20 F120 M3 S100

Instruction N30 X15

Sequence of digits Program blocks

N40 Y-20 X25

Address letter N50 G4 F1000

Program words

Block number

Figure 1-1: Elements of an NC program

1.2 Program block

Individual lines of an NC program are called program blocks or NC blocks. A program block is the smallest work step that can be taken when processing a work piece. A program block begins with a block number and ends with a block end character. A block number is made up of the address character N with a maximum of four digits. Leading zeros can be omitted. Blocks without block numbers can neither be read nor entered during programming. The block end character used by the CNC is the linefeed character (0AH). Placing a slash / (block slash code) before a block allows the block to be ignored or masked out. (See 1.5 Block Suppression.)

The maximum length of a program block is 128 characters (including block end character and optional checksum). To allow editing of an NC program the program blocks are numbered sequentially in blocks of ten with rising block numbers. This provides easy location of program blocks and insertion of additional blocks.

Example: N10 G90 N20 G1 X50 Y20 F3000 M3 S1000 N30 X15

Page 16: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 16/376

N40 Y-20 X25 N50 G4 F1000 N60 M30 The NC blocks being manually input into the CNC are automatically sorted according to block numbers. The NC block with the lowest block number appears at the beginning of the program and the one with the highest number at the end.

The program blocks are processed in the sequence in which they were stored. NC programs entered directly into the CNC are also processed by increasing block numbers. NC programs that have been externally created and then read into the CNC may not be processed by increasing block numbers because the program is not checked for increasing block numbers when loaded. The externally created program will be processed sequentially as ordered in the file, not by increasing block number.

1.3 Program Word The individual information in a program block is called a program word. A program word contains technical, geometrical or technological information related to the program. The sequence of the program words in a block is arbitrary. A program word is made up of an address letter and a sequence of digits with or without a sign.

The address letter designates the type of program word. Each address letter must only be programmed once per NC block. If the same address letter is programmed several times in a block during program input, the program block is rejected (error message 5 appears). If the same address letter appears repeatedly in a block from an externally created program that is read into the CNC, the last address letter read becomes effective.

The sequence of digits of a word is an integer or a number, consisting of an integer value and a decimal fraction that can be zero. The decimal is separated from the integer by a period. A comma is not admissible. Signs are programmed between address letter and sequence of digits. Positive signs, leading zeros and non-significant zeros after the decimal point do not need to be programmed. If the decimal point is not followed by any significant digits, it is automatically set in the display.

Example: G1 instead of: G01

M1 instead of: M01

X1234.5 instead of: X+1234.500

Y12 instead of: Y+12.00

Z-25.4 instead of: Z-0025.4

Program words are considered instructions or additional conditions. An instruction (e.g., G- or M-codes) prepares or triggers a process in the machine tool

Page 17: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 17/376

or the control. An additional condition describes the instructions more exactly (e.g., specifying the destination coordinates for a positioning instruction).

Program words can be distinguished as either modal (retentive) or non-modal. Modal program words are active in all following program blocks until they are overridden or overwritten by an instruction or additional condition that cancels them. Non-modal program words are only active in the block in which they are programmed. Modal instructions must therefore only be programmed when they are changing or when additions are necessary. Non-modal instructions have to be programmed in each block in which they are included.

Instructions are organized into instruction groups. In any one instruction group all the instructions are summed up but only one instruction can be in effect at a time.

Table 1-1 on the following pages contains G-Codes available in the CNC. The tables include notes on group division, effectiveness, whether the respective instruction is active at CONTROL RESET and whether positioning instructions are programmable in the same block. G-Codes used to program travel movements within the same block are marked in Table 1-1 by an asterisk (*). Table 1-2 on the following pages contains M-codes, some of which are available only in application specific versions of the CNC.

Page 18: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 18/376

G-Function Meaning Group Effectivity Active after

reset? G00 * Linear interpolation with maximum speed 1 Modal G01 * Linear interpolation with programmed speed 1 Modal Yes G02 * G03 *

Circle or helical interpolation with defined circle center (clockwise) Circle of helical interpolation (counter clockwise)

1 1

Modal Modal

G04 * Dwell time Blockwise G05 * G06 *

Definition of spline Activation of spline

1

Blockwise Modal

G07 * Tangential arc interpolation 1 Modal G08 * G09 *

Look Ahead OFF Look Ahead ON

7 7

Modal Modal

Yes

G10 * G11 *

Clean dynamic buffer Fill up dynamic buffer

Blockwise Blockwise

G12 * G13 *

Arc interpolation with defined radius (clockwise) Arc interpolation with radius (counter clockwise)

1 1

Modal Modal

G14 * G15 * G16 *

Polar coordinate programming absolute Polar coordinate programming incremental Definition of coordinate system

3 3

Modal Modal Blockwise

G17 * G18 * G19 * G20 *

Plane select X/Y Plane select Z/X Plane select Y/Z Plane select programmable

12 12 12 12

Modal Modal Modal Modal

Yes

G21 * G22 *

Parallel axis ON Parallel axis OFF

14 14

Modal Modal

Yes

G24 * G25 * G26 * G27

Work area limit lower boundary Work area limit upper boundary Work area limit OFF Work area limit ON

9 9

Blockwise Blockwise Modal Modal

G33 * G34 *

Thread cutting, constant pitch Thread cutting, variable pitch

1 1

Modal Modal

G35 * Oscillation Blockwise G38 G39 *

Programmable mirroring ON Programmable mirroring OFF

10 10

Modal Modal

Yes

G40 * G41 * G42 * G43 * G44 *

Tool radius correction OFF Tool radius correction to the left Tool radius correction to the right Tool radius correction to the left with modified activation Tool radius correction to the right with modified activation

4 4 4 4 4

Modal Modal Modal Modal Modal

Yes

G50 * Scaling Modal G51 * G52 *

Part rotation degrees Part rotation radians

Modal Modal

G53 * G54 * G55 * G56 * G57 * G58 * G59 *

Zero point shifting OFF Zero point shifting 1 ON Zero point shifting 2 ON Zero point shifting 3 ON Zero point shifting 4 ON Zero point shifting 5 ON Zero point shifting 6 ON

11 11 11 11 11 11 11

Modal Modal Modal Modal Modal Modal Modal

Yes

G63 * G66 *

Feed/spindle override ON Feed/spindle override OFF

8 8

Modal Modal

Yes

G70 * G71 *

Programming in inches Programming in metric (mm)

2 2

Modal Modal

Yes

G72 * G73 *

Interpolation with exact position OFF Interpolation with exact position ON

6 6

Modal Modal

Yes

G74 Programmable homing Blockwise

Page 19: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 19/376

G75 G76

Curvature activation Curvature acceleration

7 7

Modal Modal

G78 * G79 *

Tangential direction 2D control ON Tangential direction 2D control OFF

Modal Modal

G80 * G81 ^ G82 ^ G83 ^ G84 ^ G85 ^ G86 ^ G87 ^ G88 ^ G89 ^

Canned Drilling Cycles (work cycles) Canned cycle off Drilling to final depth Spot facing with dwell time Deep hole drilling Tapping or thread cutting with balanced chuck Reaming Boring Reaming with measuring stop Boring with spindle stop Boring with intermediate stop

Modal Modal Modal Modal Modal Modal Modal Modal Modal Modal

G90 * G91 *

Absolute programming incremental programming

3 3

Modal Modal

Yes

G92 Zero point setting, maximum spindle speed Modal G94 * G95 *

Feed in millimeters/minute Feed in millimeters/revolution

5 5

Modal Modal

Yes

G96 * G97 *

Constant cutting speed ON Constant cutting speed OFF

15 15

Modal Modal

Yes

G98 ^ Positioning axis dwell time Blockwise G99 * Axis offset Modal G100 G101 ^ G102 ^ G103 ^ G104 ^ G105 ^ G106 ^ G107 ^ G108 ^

Polar/cylindrical transformation OFF Polar/cylindrical transformation ON Cylindrical transformation ON Barrel CAM transformation, real time radius comp Barrel CAM transformation with centerline deviation G101 with alternative axis addresses G102 with alternative axes addresses G103 with alternative axes addresses G104 with alternative axes addresses

Modal Modal Modal Modal Modal Modal Modal Modal Modal

G109 * Axis transformation programming of tool depth Modal G110 ^ G111 * G112 * G113 * G114 * G115 * G116 * G117 *

Axes selection laser power control Definition of voltage 1 (V1), speed (F1), time (T1) Definition of voltage 2 (V2), speed (F2), time (T2) Definition of voltage 3 (V3), speed (F3), time (T3) Definition of time 4 (T4) Definition of time 5 (T5) Definition of time 6 (T6) Definition of time 7 (T7)

Blockwise Blockwise Blockwise Blockwise Blockwise Blockwise Blockwise Blockwise

G120 G121

Axis transformation; orientation change of rotary axis Axis transformation; orientation change in a plane

Modal Modal

G125 G126 G127 G128

Electronic gear box; plain teeth Electronic gear box; helical gearing, axial Electronic gear box; helical gearing, tangential Electronic gear box; helical gearing, diagonal

Modal Modal Modal Modal

G130 G131 G132

Axis transformation; program orientation change Axis transformation; orientation change Axis transformation; orientation change

Modal Modal Modal

G133 G134

Lag free threading learning ON Lag free threading learning OFF

Modal Modal

G140 G141

Axis transformation; orientation designation of work piece fixed coordinates Axis transformation; orientation designation of active coordinates

Modal Modal

G150 G151 G152

Real-time cutter radius compensation OFF Real-time cutter radius comp ON to the left of path Real-time cutter radius comp ON to right of path

Modal Modal Modal

G160 ART (Adaptive Regulation Technology) activation Modal

Page 20: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 20/376

G161 ^ G162 ^ G163 ^ G164 ^

ART learning function for velocity factors ART learning function deactivation ART learning function for acceleration factors ART learning function for acceleration changing

Modal Modal Modal Modal

G165 G166

Command filter OFF Command filter ON

Modal Modal

G170 G171 G172

Digital measuring signals; block transfer, hard stop Digital measuring signals; block transfer, without hard stop Digital measuring signals; block transfer, soft stop

Modal Modal Modal

G180 ^ G181 ^ G182 ^ G183 * G184 *

5-axes transformation OFF 5-axes transformation ON, no rotated coord. sys. 5-axes transformation ON with rotated coord. sys. 5-axes transformation; define coordinate system 5-axes transformation; program tool dimensions

Modal Modal Modal Modal Modal

G186 Acceleration on corners, accuracy of arc interpolation Blockwise G188 * Enable positioning axis motion Blockwise G190 G191 G192 G193

Diameter programming OFF Diameter programming and display ON Diameter display ON Diameter display in actual dimension

Modal Modal Modal Modal

G200 G201 G202 G203

Corner smoothing OFF Corner smoothing ON with defined radius Corner smoothing ON with defined corner radius Corner smoothing ON with defined radius up to tolerance

Modal Modal Modal Modal

G210 to G217

Laser power control for 2nd output channel (like G110-G117)

Modal

G220 ^ G221 ^ G222 ^ G223 ^ G224 ^ G225 ^

Angled wheel transformation OFF Angled wheel transformation ON - normal Angled wheel transformation ON � two-step with angled wheel axis moving first then other axes Angled wheel transformation ON � two-step with angled wheel axis moving last after other axes Same as G222 but axes move in machine coord. Same as G223 but axes move in machine coord.

Modal Modal Modal Modal Modal Modal

G265 Distance regulation � axis selection Modal G270 G271 G272 G274 G275 G276

Turning Cycles Turning finishing cycle Stock removal in turning Stock removal in facing Peck finishing cycle Outer diameter / inner diameter turning cycle Multiple pass threading cycle

Modal Modal Modal Modal Modal Modal

G310 to G317

Laser power control for 3rd output channel (like G110-G117)

Modal

* Axis information is programmable in the same block ^ No axis information is allowed in the same block

Table 1-1: G-Codes

• The currently active G-codes are displayed in the G-codes window of the Information page by entering ALT I: INFO.

• The above list contains optional G-codes that are only available in application specific versions of the CNC.

• With typical default settings, then at CONTROL RESET the correspondingly marked G-codes in Table 1-1 are active. For another possible default setting see the G-codes window by entering ALT I: INFO after selection of CONTROL RESET or reference the documentation with control (with any changes to the control defaults).

Page 21: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 21/376

M-Command Meaning M00 * M01 (*) M02 (*)

Unconditional Stop Conditional Stop End of Program

M03 * M04 * M05 * M19 *

Spindle clockwise Spindle counterclockwise Spindle Stop Spindle orientation

M20 * M21 * M22 * M25 *

Oscillation ON, Punching/Nibbling ON Oscillation OFF Nibbling ON Punching with/without dwell time ON

M30 (*) End of program M40 * M41 * M42 * M43 * M44 * M45 * M46 *

Automatic gear selection Spindle gear transmission step 1 Spindle gear transmission step 2 Spindle gear transmission step 3 Spindle gear transmission step 4 Spindle gear transmission step 5 Spindle gear transmission step 6

M70 * M71 * M72 * M73 *

Spline, beginning and end curve 0 Spline, beginning tangential, end curve 0 Spline, beginning curve 0, end tangential Spline, beginning and end tangential

M80 * Delete rest of distance using probe function M81 * Drive on application block (resynchronize axis

positions via PLC signal during the block) M101 . . . M108 M109 M111 . . . M118 M121 . . . M128

Reset Bit 1 . . . Reset Bit 8 Reset all (8) bits Set Bit 1 . . . Set Bit 8 Pulsate Bit 1 . . . Pulsate Bit 8

M140 * M141 *

Distance regulation ON (configured by G265) Distance regulation OFF

M150 * M151 * to M158 * M159 * M160 * M161 * to M168 *

Delete rest of distance using probe function, for a probe input (one of 16, M151-M168) Digital input byte 1 bit 1 (to bit 8) is active probe input (for M150) PLC cannot define the bit mask for probe PLC can define the bit mask for probe Digital input byte 2 bit 1 (to bit 8) is active probe input (for M150)

M170 * M171 *

Continue look ahead (cancel M171) Stop look ahead in probe program

M200 * M201 * to M208 * M209 * M210 * M211 *

Handwheel in automatic mode ON (activated) Axis select for handwheel in auto (axis 1 to 8) Handwheel parameters Suspend handwheel input (offsets still active) Handwheel in automatic mode OFF

M213 * M214 * M215 *

Spindle 2 on, clockwise Spindle 2 on, counter clockwise Spindle 2 off or stop

M280 *

Switchable spindle/rotary axis � rotary axis on (not spindle), first combination

Page 22: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 22/376

M281 * M290 * M291 *

Switchable spindle/rotary axis � rotary axis on (not spindle), second combination Switchable spindle/rotary axis � spindle on (not rotary axis), first combination Switchable spindle/rotary axis � spindle on (not rotary axis), second combination

* M-Code will be transmitted as BCD to PLC (*) M-Code will only be transmitted to PLC if the function is actually executed M-Code will not be transmitted as BCD to PLC; these are the fast output signals for the laser

power control option, handled internally by the CNC. Note: The above list contains some optional M-Codes that are available only in application

specific versions of MACHINEMATE. Many of the M-codes in the table above can be assigned a different value with a machine parameter associated with that feature.

Table 1-2: M-Codes

1.4 Auxiliary functions (BCDs) Auxiliary functions are program words that are used to transfer information from the NC program to the PLC program.

Up to four of these auxiliary functions can be preset in the CNC. The address letters M, S, U and T are used for auxiliary functions. The corresponding program words are ignored in the NC program and transferred as BCDs to the PLC Program.

The meaning of the BCDs is determined by the machine manufacturer and should be explained in the machine documentation. The M-codes that are listed in Table 1-2 however are predefined but can only be used if the relevant function is also available.

Only those M-codes listed in Table 1-2 that are marked by an asterisk (*) are transferred to the PLC. Some M-Codes (e.g., M02, M30) are only transferred to the PLC when the corresponding function is actually executed. For example M02 is only transferred to the PLC when it is at the end of a main program and CONTROL RESET is initiated. M02 is not transferred to the PLC when it is positioned at the end of a subroutine because this would cause a jump back to the main program.

Page 23: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 23/376

1.5 Programming functional overview This is a summary of the programming functions.

Positioning instructions

G00 Linear interpolation in rapid traverse

G01 Linear interpolation in the feed rate

G02/G03 Circular interpolation with specified center point

G12/G13 Circular interpolation with specified radius

G74 Programmable homing

M80 Delete remaining paths using probe function

G07 Tangential circular interpolation

G05/G06 Spline interpolation 2D

G78/G79 Tangential setting to the 2D path

G08/G09 Look Ahead over more than two blocks

G101/G105 Polar transformation

G102/G106 Cylinder pattern development transformation

Program execution instructions

M00 Program stop (unconditional)

M01 Program stop (conditional)

M02/M30 End of program

G10/G11 Empty/Fill block buffer

G72/G73 Interpolation with precision stop OFF/ON

G08/G09 Look Ahead over more than two blocks

G186 Corner acceleration, contour accuracy

G75/G76 Curvature

G04 Programmable dwell

Technical instructions:

G94/G95 Inches/minute or Inches/revolution

F word, S word Feed rate, spindle speed

G63/G66 Feed rate or spindle override ON/OFF

B word Programmable acceleration

M03/M04/M05 Spindle ON/OFF (clockwise or counter-clockwise)

M19 Spindle Orientation

G92 Spindle speed limitation

G96/G97 S as constant surface speed or rpm

Geometric instructions:

G40-G44 Path compensations

G53-G59 Part position offsets

G70/G71 Programming in imperial/ metric format (inch/mm)

G90/G91 Absolute or incremental programming

G92 Axis value settings

G14-G16 Polar coordinate programming

Page 24: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 24/376

G17-G20 Plane selection

G24-G27 Programmable work field limits

G38/G39 Programmable axis motion mirror

G51/G52 Part rotation in degrees/radians

G50 Scaling

1.6 Block suppression

Placing a slash (block slash code) before a block marks the block as suppressed. The block is ignored if Alt A: AUTOmatic → F3: Execute program 2 → F1: (/) Block Read over is selected. When F1:(/) Block Read over is not selected, the blocks are processed like ordinary NC blocks. Cycle blocks cannot be suppressed in this manner.

Example: N10 G0 X0 Y0 /N20 G1 X2000 Y300 Is not executed when ignore block read over is selected. N30 G1 X4000

Application:

The processing of a family of parts is described in an NC program. All machining operations that are required for part version A, but are not to be executed for part version B, can be preceded by a slash (/). After selection of: Alt A: AUTOmatic → F3: Program process 2 → F1: (/) Block Read over the blocks marked by a slash are not considered.

Note: If Alt A: AUTOmatic → F3: Program process 2 → F1: (/) Block read over is selected after a suppressed block has already been preprocessed and is waiting in the dynamic block buffer, the suppressed block is not ignored, even if this block has not yet been reached in the actual program execution.

1.7 Program Repetition Program repetitions are programmed with an L-code in the last block along with the instructions M30 or M02:

Example: N... L5 M30 The program is repeated 5 times. It is executed 6 times in total.

The special case of L0 causes the program to be executed infinitely.

Repetition calls in the last block of a subroutine are ignored (see 1.8 Subroutines). At the end of a subroutine, the instructions M02 and M30 cause a jump back to the main program from which the subroutine was called. At the end of a main program, the instructions M02 and M30 initiate CONTROL RESET.

Page 25: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 25/376

1.8 Subroutines Subroutine calls are programmed by entering Q followed by the program number of an NC program already available in the CNC. The subroutine call causes the first block of the selected subroutine to be processed as next NC block. A subroutine is also called a subprogram because the syntax in a subroutine is identical to that of a main program (except its very first block cannot be a cycle block). When the main program calls a subroutine, it is really just calling another program to run.

Program repetition calls in the last block of a subroutine are ignored and have to be programmed, together with L, in the calling program. They are programmed in the same line in which Q was entered, followed by the number of subroutine runs.

Example: N... Q100 L5 The program with the number 100 is called as a subroutine and

executed 6 times in total. Further subroutines can be called within subroutines. The nesting depth is limited to 4 times. One main program level and four subroutine levels can be programmed altogether.

Figure 1-2: Nesting depth

Note: A M30 or M02 code cannot be positioned in a block with a subroutine call, since in such blocks subroutine calls are ignored. Also, subroutines must not start with a cycle block!

The example above uses a main program and its subroutines that are in CNC memory. The subroutines must be in the same location as the main program. If the main is in CNC memory then subroutines must be there also.

When the main program is in a disk folder then the file naming for the subprograms is important. The default format for the letter Q is six digits. Therefore the CNC will look for a file having exactly the correct name to match the subprogram call. For example, a program running from the disk having a block N40Q100 will result in the running of a file named P000100. from the same disk folder as the main program.

P300 P400 P100 P200

Page 26: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 26/376

1.9 Comments in NC programs NC blocks for the CNC can contain comments. These can be included at any position in the NC block. They have no effect on the processing of the NC block. The comment is enclosed in parentheses.

Example: ... N20 G1 X0 Y0 Z0 (move to zero point) ... This comment is included in the NC block and the block display during processing but is otherwise completely ignored by the CNC. There are two forms of comment that can be used to output notes in the state line:

... (MSG, text)...

... (*MSG, text)... In the first case, the text between the comma and the closing parenthesis together with the icon (symbol) for notes is displayed in the status line of the CNC during the processing of the NC block. The text is then cleared again when the next block is processed. In the second case the text remains displayed in the status line until it is either explicitly confirmed or the end of the main program is reached.

In cycle blocks, comments of the form

... /Text... can also be used. Here all characters between the slash (/) and the block end are treated as a comment. There are no parentheses in cycle blocks (before a comment).

1.10 Program number The first line in a part program is an empty line with just the �line feed� character (the ASCII character value of 10-decimal), that may or may not be followed by the �carriage return� character (the ASCII character value of 13-decimal).

The second line in a part program is a % character (followed by the �line feed� character, then the optional �carriage return� character).

The third line in a part program (after the line with the %) is the program number. The syntax for this line is the letter P followed by the number, as in �P0010� for program number 10.

The program number standard is usually limited to a maximum of 6 digits. However, the software configuration can be changed to increase the limit to 16 digits.

Note: Any text that is in the part program file before the line with the % will be ignored by the control. This �header� can be used for any information that should be in the file but that will be ignored by the CNC. An error 816 (missing header in file) will occur if a line with just the % is not found in the file.

Page 27: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 27/376

1.11 Cycle block layout

Cycle blocks always begin with an asterisk (*) followed by the block number (with no space between them).

A cycle block is used for calculations with the cycle parameters, for conditional processing (e.g., IF or GO) or for other cycle programming. Further information about cycle programming can be found in section 6 for general cycle programming.

1.12 Reading from External Data Carriers, Format

Defaults NC programs that are read from external data carriers must meet the following format requirements:

The first program line must contain the ASCII-code for a line feed (linefeed <lf>). Special characters and spaces (blanks) are not admissible in the first line of the program.

The second program line must begin with the percent character followed by the ASCII-code for a line feed. Special characters or spaces are not admissible.

The third program line must begin with the program number, consisting of the address letter P and a number of digits (maximum of 6), and end with the ASCII-code for a line feed. In this line, a station identifier enclosed in brackets can also be contained (e.g., PST 01 as shown in the Note following these requirements).

Program lines after the third program line must begin with a block number consisting of the address letter N and a number of digits (maximum 4 digits) and end with the respective ASCII-code for a line feed. Spaces (blanks) are admissible in NC blocks; however, they are deleted upon loading when they are not contained in comments or cycle blocks.

The last program block must start with a block number, must contain the instruction M02 or M30 and must end with the ASCII-code for a line feed.

In all program lines, the combination of line feed and carriage return (<lf><cr>) can also be used instead of line feed (<lf>). Furthermore, the combination (<lf> <cr>) can also be preset as an admissible block end character.

Any carriage return characters (<cr>) are ignored during loading from external data carriers. Only the line feed character (<lf>) is used internally in the CNC as the block end character. However, during output to external data carriers (depending on default setting), either <lf>, <cr> <lf> or <lf> <cr> are generated as block end characters.

Page 28: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 28/376

The maximum block length is 128 characters including the checksum (3 characters) and the internally exclusively used block end character <lf>. Thus generally only 124 characters in each block are available.

NC blocks may begin as follows:

N... normal NC block /N... ignored block (see block suppression) *N... Cycle block (see Chapter 6 General Cycle Programming)

An NC block must not begin with /*N� The loading format to be followed can be shown schematically as follows:

<lf> (<cr>) % <lf> (<cr>) <lf> (<cr>) N....<lf> (<cr>) N....<lf> (<cr>) ... N....M02/M30 <lf> (<cr>)

Symbols used:

<lf> ASCII-code for line feed (Linefeed)

<cr> ASCII-code for carriage return

P...... Program number, 6 digits maximum

N.... Block number, usually 4 digits maximum

PST01 Station identifier

The CNC accomplishes recognition of data loss during program transfer and storage by providing the NC program with a checksum. In this case, the loading format additionally includes:

• the character combination @ 00 at the beginning of the first block

• the character @ together with a two-digit ASCII-coded block checksum before the <lf> character of each block

• the character @ together with a two-digit ASCII-coded program checksum at the end of the program

Thus the following loading format is valid for programs with checksum:

<lf> (<cr>) % <lf> (<cr>) P...... (PST01) <lf> (<cr>) @00N....... @ss <lf> (<cr>)

Page 29: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 29/376

N....... @ss <lf> (<cr>) ... N.... M02/M30 @ss <lf> (<cr>) @pp

Symbols used: see above

ss Block checksum

pp Program checksum

Further information concerning calculation and checking of the checksums can be found in the section 1.13 Checksum.

Note Lower case letters may only occur within a comment. Special characters (like tabs) are not allowed. All program words must contain capital letters only.

1.13 Checksum The optional checksums provide a method of checking NC programs for data losses during program transfer and saving. There are two types of checksums used with the NC program, the block checksums and the program checksum.

The block checksum are determined as follows:

Hexadecimal ASCII-codes are created from all the characters of an NC block apart from the two characters which form the checksum itself, but including the @ character and the <lf>. These codes are added up. The last two digits of the sum are put directly before the <lf> of each block as a block checksum. When calculating the sum, spaces (blanks) in NC-blocks are only included if they occur within a comment or in a cycle block.

Example:

Block Checksum:

N10X10 @B2<lf> (Note: 4E+31+30+58+31+30+40+A=1B2)

The program checksum is determined as follows:

The hexadecimal ASCII-codes of all characters of the program including the <lf>, the @ and the characters of the block checksums are added together. The dummy program checksum (@00) at the beginning of the program is not considered. The last two digits of the sum are put at the end of the program as the program checksum.

Page 30: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 30/376

Example:

Program Checksum: N10...N20......@ 00 N120 M30 @DB<lf> (Note: 4E+31+32+30+40+33+30+40+A=1DB)@61

NC programs can be read in with and without checksums. When loading NC programs without checksum, a checksum is created for storage in the control.

After a program is edited in the operating mode "DATA", the program checksum is checked. The block checksums are also checked if an error is found. If an error occurs, it is only possible to exit the block display after the block containing the error has been deleted or changed. If a block is changed to correct an error, the checksum for the changed block is recalculated. If the checksums of the remaining blocks are correct, the program checksum is recalculated and it is possible to exit the block display again.

During the execution of a program the checksum of each individual NC block is checked.

Example: @00 N10 X1.25 Y2 F5000 @AD <lf> N20 X0 Y0 @0B <lf> N30 M30 @AB <lf> @DD

(The blanks were inserted in this example for clarity; they are not stored in the program and remain unconsidered during calculation of the checksums).

When creating an NC program, the program checksum is entered at the beginning of the program as a dummy (@00). After completion of the program, the program checksum is calculated and moved to the end of the program. The ASCII-characters of the program checksum itself are not considered during the calculation of block and program checksums.

Page 31: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 31/376

Dec Hex Code Dec Hex Char Dec Hex Char Dec Hex Char 00 0x00 NUL 32 0x20 SP 64 0x40 @ 96 0x60 ` 01 0x01 SOH 33 0x21 ! 65 0x41 A 97 0x61 a 02 0x02 STX 34 0x22 " 66 0x42 B 98 0x62 b 03 0x03 ETX 35 0x23 # 67 0x43 C 99 0x63 c 04 0x04 EOT 36 0x24 $ 68 0x44 D 100 0x64 d 05 0x05 ENQ 37 0x25 % 69 0x45 E 101 0x65 e 06 0x06 ACK 38 0x26 & 70 0x46 F 102 0x66 f 07 0x07 BEL 39 0x27 ' 71 0x47 G 103 0x67 g 08 0x08 BS 40 0x28 ( 72 0x48 H 104 0x68 h 09 0x09 HT 41 0x29 ) 73 0x49 I 105 0x69 i 10 0x0A LF 42 0x2A * 74 0x4A J 106 0x6A j 11 0x0B VT 43 0x2B + 75 0x4B K 107 0x6B k 12 0x0C FF 44 0x2C , 76 0x4C L 108 0x6C l 13 0x0D CR 45 0x2D - 77 0x4D M 109 0x6D m 14 0x0E SO 46 0x2E . 78 0x4E N 110 0x6E n 15 0x0F SI 47 0x2F / 79 0x4F O 111 0x6F o 16 0x10 DLE 48 0x30 0 80 0x50 P 112 0x70 p 17 0x11 DC1 49 0x31 1 81 0x51 Q 113 0x71 q 18 0x12 DC2 50 0x32 2 82 0x52 R 114 0x72 r 19 0x13 DC3 51 0x33 3 83 0x53 S 115 0x73 s 20 0x14 DC4 52 0x34 4 84 0x54 T 116 0x74 t 21 0x15 NAK 53 0x35 5 85 0x55 U 117 0x75 u 22 0x16 SYN 54 0x36 6 86 0x56 V 118 0x76 v 23 0x17 ETB 55 0x37 7 87 0x57 W 119 0x77 w 24 0x18 CAN 56 0x38 8 88 0x58 X 120 0x78 x 25 0x19 EM 57 0x39 9 89 0x59 Y 121 0x79 y 26 0x1A SUB 58 0x3A : 90 0x5A Z 122 0x7A z 27 0x1B ESC 59 0x3B ; 91 0x5B [ 123 0x7B { 28 0x1C FS 60 0x3C < 92 0x5C \ 124 0x7C | 29 0x1D GS 61 0x3D = 93 0x5D ] 125 0x7D } 30 0x1E RS 62 0x3E > 94 0x5E ^ 126 0x7E ~ 31 0x1F US 63 0x3F ? 95 0x5F _ 127 0x7F DEL

Table 1-3: ASCII Character Set

Page 32: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 32/376

1.14 Program Safety NC programs are protected during transfer, storage and execution from unintentional change or loss of data.

Safety during transfer During transfer of NC programs via the serial interface or from and to floppy/hard disk, a syntax check and a checksum test are made. The syntax check covers the following points:

• valid program start (<lf>% <lf>)

• valid program end (M02/M30)

• valid start of each block (N, *N, /N)

• valid block length (<128 characters including checksum)

A checksum test can be preset. If it is preset, both the block checksums as well as the program checksums are checked. A transfer end character (as default ETX, 03H) must also be present.

Safety during storage After selecting and editing an NC program in the operating mode "DATA" and after copying of an NC program, block and program checksums are verified. Furthermore, during the editing of an NC program, a syntax check on the edited NC blocks is performed. This includes a check on allowable NC addresses, number of digits, signs, block length, block number, and whether NC addresses appear twice. If necessary, the corresponding error messages are immediately output during editing.

Safety during execution During execution of NC programs a syntax check is performed, which corresponds to the test performed during the editing of NC programs. The block checksum of each block is also checked before processing and error message 30 is output if an error occurs.

Page 33: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 33/376

1.15 Axis designations for machine tool machines There are two types of axes, feed axes (linear axes) and rotary axes for a machine tool machine.

The feed axes are designated as X,Y, and Z. The X-axis runs parallel to the work piece table, preferably horizontal. The Z-axis runs parallel to the axis of the work spindle.

The position of the three feed axes relative to each other can be determined with the help of the right-hand rule:

Figure 1-3: Orientation of the three basic feed axes using the right-hand rule

Page 34: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 34/376

For machines with rotating tool: With a horizontal Z-axis (see Figure 1-4), the positive X-axis runs towards the right (viewed from the main spindle towards the work piece).

With a vertical Z-axis (see Figure 1-5), on single column machines, the positive X-axis runs towards the right (viewed from the main spindle towards the column).

With a vertical Z-axis, on twin column machines, the positive X-axis runs towards the right (viewed from the main spindle towards the left column).

Figure 1-4: Work piece rigid, tool rotates

Page 35: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 35/376

Figure 1-5: Work piece rotates, tool rigid

For machines with rotating work piece:

The X-axis lies radially towards the work piece and runs from the work piece axis towards the main tool carrier (see Figure 1-4).

For machines without a work spindle: The X-axis runs parallel to the main processing direction.

The position of the Y-axis results from the position of the Z and X-axis in the three-axes coordinate system.

Feed axes, which are available in addition to the basic feed axes X, Y and Z, are usually designated with the letters U, V and W. Their position and direction is to be taken from Figure 1-6.

The rotary axes are designated by the letters A, B and C. The A-axis is the rotary axis around the feed axis X, the B-axis is the rotary axis around the feed axis Y and the C-axis is the rotary axis around feed axis Z.

Page 36: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 36/376

Figure 1-6: Position and direction of feed rate and rotary axes.

Memory Aid:

All planes are to be considered in the negative direction of the axis positioned perpendicular on the plane (e.g., when determining the rotation direction in connection with the instructions G02 and G03). The rotation direction of the rotary axes is counter clockwise (mathematically positive) when viewed in the negative direction of the axis.

1.16 Gantry Axes A gantry axis is always moved synchronous to another axis (leading axis). An example is a machine where the gantry must be positioned by means of two linear axes without tilt. A gantry axis cannot be programmed independently; both servos move together. Although a gantry axis could be displayed on the user interface of the CNC, its travel movements result from the travel movements of the leading axis.

Page 37: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 37/376

1.17 Resettable Rotational Axis The feature �resettable rotational axis� is optional and is not available in all systems. It must be activated from the machine manufacturer.

In principle, a rotational axis can be positioned "into infinity", since its position is repeated after every revolution of 360°. However, since the numerical range for the representation of the position is limited, the axis also has a finite travel range of axis limits. A resettable rotational axis also avoids rounding errors that occur with long travel paths. It also avoids lower resolution of the position representation at the edges of the travel range.

For many applications, only the relative position of the axis between 0 and 360° is required. Positions, which vary by complete revolutions, can be considered as having the same value. A resetting of the position into the range from 0 to 360° can be undertaken for a rotational axis that is configured as a "resettable rotational axis". This is done by programming G92 (zero position offset).

Programming: 360 increments are preset for each revolution of the rotational axis. According to the programming of A730, the rotational axis is moved to the position 730°, or 2 complete revolutions plus 10°. After programming G92 A0, the position is set to 0 and the actual angular position is internally saved.

If G92 does not include any axis information, the position is set to the actual angular position (10). The information for the two complete revolutions is then lost and the position of the rotational axis is reduced to the actual angular position (between 0 and 360°). At Delete remaining path, no automatic reduction of a position to the range 0 - 360° is made. A violation of axis limit can be avoided if the position is reduced in time.

Page 38: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 38/376

2 Positioning Instructions 2.1 General positioning instructions

2.1.1 Monitoring the axis travel limits

The limit values for the axis travel movements can be preset. During processing of the NC blocks, the system is monitored to assure that preset axis travel limits are not exceeded. This monitoring applies only to the programmed end positions and is true for all interpolation types with real-time processes and active transformations.

If the look ahead monitoring function recognizes that the axis travel limits are exceeded then:

• error message 211 is output

• the NC block which caused the violation is displayed

• program execution is stopped before the system processes the block that caused the violation

The error can be corrected by editing the NC block that caused the violation.

An error message is displayed in all cases where a violation of the axis travel limits is recognized in real-time. However, the further reaction of the system is different and is described in the following text in relation to operating functions.

Note: The axis travel limits can be reduced using the function Programmable work field limitation, thus further restricting the work field.

Page 39: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 39/376

2.1.2 G00 linear interpolation in rapid traverse

Syntax: G0 X... Y... ... The rapid traverse instruction is selected using the modal program word G00. The rapid traverse instruction causes the tool to be moved at maximum velocity to its destination. The destination point is input as an additional condition.

Application: The rapid traverse instruction is mainly used for positioning tools. During positioning, the tool should not be in operation.

Figure 2-1: G00 when turning

Figure 2-2: G00 when milling

The motion path taken by the tool under the rapid traverse instruction G00 is a direct connecting line between the starting position at which the rapid traverse instruction is selected and the destination whose coordinates are input as additional conditions. Therefore, not all of the axes are necessarily positioned with maximum velocity.

Example: Starting position: X = 250, Y = 200, Z = 250 (see Figure 2-3)

Page 40: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 40/376

N10 G90 N20 G0 X50 Y80 Z100 "Move to the point X50 Y80 Z100 N30 Z20 in rapid traverse and then move to Z20 in rapid traverse."

Starting point

Figure 2-3: Two successive rapid traverse positioning instructions

Either absolute or incremental dimension inputs are possible:

Page 41: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 41/376

Destination

Starting point

Absolute dimension

Absolute dimenstion

Figure 2-4: Absolute dimension coordinates (G90)

Page 42: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 42/376

Destination

Absolutedimension

Start

Abolute dimension

point

Figure 2-5: Incremental dimension coordinates (G91)

Absolute Dimension

Page 43: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 43/376

2.1.3 G01 linear interpolation in the feed rate

Syntax: G1 X... Y... F... ... The instruction linear interpolation (straight line interpolation) in the feed rate is selected using the program word G01. The following are additional conditions:

• the destination coordinates

• the feed rate

• the speed of rotation or cutting speed

The instruction G01 causes the tool to be positioned in a straight line to the indicated destination point with the feed rate that was specified as an additional condition or was already programmed. Feed rate, speed of rotation and cutting speed are all modally effective. All axes programmed in the block are positioned simultaneously. The tool motion path can be either an axis parallel or a non-axis parallel straight line. The coordinates of the destination points can be entered as either absolute or incremental dimensions. Straight line interpolation for the feed rate is illustrated in Figure 2-6, 2-7 and 2-8.

Figure 2-6: G01 when turning

Page 44: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 44/376

Figure 2-7: G01 when milling

Example:

(Starting position: X = 50, Y = 60, Z = 40)

N10 G90 N20 G1 X80 Y80 Z20 F40 S100 � � �

Destination point Feed rate Speed of rotation 40mm/min 100 Revs/min

Page 45: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 45/376

Start point

N20

Figure 2-8: G01 Linear interpolation in the feed rate

Page 46: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 46/376

2.1.4 G02, G03 circular interpolation with specified center point

Syntax: G2/G3 X... Y... I... J... (G17 active) G2/G3 Z... X... K... I... (G18 active) G2/G3 Y... Z... J... K... (G19 active)

The positioning instruction circular interpolation with specified center point in clockwise direction is selected with the program word G02. The positioning instruction circular interpolation with specified center point in the counter-clockwise direction is selected with the program word G03.

These instructions are used for the programming of curved work piece contours. The curve must lie in the plane defined by the instructions G17 to G20.

MACHINEMATE operates with a clockwise coordinate system. The statement in the clockwise or the counter-clockwise direction relates to the relative movement of the tool with respect to the work piece when looking towards the path plane in the negative direction from the coordinate system�s axis that is vertically positioned on the path plane.

Figure 2-9: Direction of rotation with G02 and G03 (turning)

Page 47: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 47/376

Figure 2-10: Direction of rotation with G02 and G03 (milling)

The additional conditions for the instructions G02 and G03 are as follows:

• The destination point coordinates (except during full circle programming)

• The coordinates of the center of the circular arc

• The feed rate

• The speed of rotation or the cutting speed

If it is not geometrically possible to produce a circle from the additional conditions programmed in a G02/G03-block, the error message 243 or 203 is output.

If a feed rate, a speed of rotation or a cutting speed was already programmed in an NC block before the call of G02 or G03, and the values programmed there are to remain effective, then the values do not need to be input again as modal additional conditions for the instructions G02 or G03.

An arc of a circle of up to 360° can be programmed in each block. An arc must lie in the plane defined by the instructions G17 to G20.

The coordinates of the circle center are indicated in incremental dimensions relative to the starting position. The axis addresses I, J and K are to be used with G17, G18 and G19 for the specification of the circle center coordinates.

Page 48: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 48/376

Axis address: Distance of the starting position to the circle center:

I in direction of the X-axis

J in direction of the Y-axis

K in direction of the Z-axis

Table 2-1: Interpolation parameters at G02 and G03 (at G17, G18 and G19)

For a plane selected with G20, the axis addresses with which the plane itself was selected are to be used for the input of the circle center:

I Major axis

J Minor axis

The coordinates of the circle center are to be indicated as positive or negative. A positive sign does not need to be programmed.

Example: (Starting position: X = 0, Y = 50)

... N30 G2 X60 Y30 I30 J-10 F200 � � �

Destination Circle center, Feed rate Incremental dimension relative 200mm/min to starting position

Page 49: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 49/376

Startpoint

Center point

Destination

of circle

Figure 2-11: Example for G02

The contour accuracy of the circle and the circle processing velocity are dependent on the circular interpolation of the K word value programmed in a G186-block (see 3.7 G186 Corner acceleration, contour accuracy). If no K word was programmed, the value preset by the machine manufacturer is effective.

Page 50: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 50/376

2.1.5 G12, G13 circular interpolation with specified radius

Syntax: G12/G13 X... Y... K... Like G02 and G03 the instructions G12 and G13 enable the programming of the circular arc. However, the following differences exist between the instructions G12 and G13 and the instructions G02 and G03:

• For G02 and G03, the center coordinates are given using the interpolation parameters I, J and K. Apart from the end position, only the radius as interpolation parameter K has to be given for G12 and G13.

• In contrast to G02 and G03, no full circle can be programmed with the instructions G12 and G13.

A clockwise circular arc is programmed with G12; a counter-clockwise circular arc is programmed with G13. The statement in the clockwise or the counter-clockwise direction relates to the relative movement of the tool facing the work piece when looking from the vertically positioned coordinates axis on the path plane in the negative direction at the path plane (see 5.2.1 Plane selection).

A circle section that is smaller than 180° is programmed with positive interpolation parameter K, a circle section that is larger than 180° is programmed with negative interpolation parameter K.

Figure 2-12: G12, G13 Circular interpolation in the counter-clockwise

direction with specified radius with K > 0 and K < 0

Page 51: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 51/376

Example: ... N40 G1 X15 Y5 N50 X10 Y15 N60 Y45 N70 G2 X30 Y65 I20 N80 G1 X85 N90 G12 X90 Y60 K5 circular arc < 180°(K positive) N100 G1 X95 N110 Y15 N120 G13 X75 Y5 K-14 circular arc > 180°(K negative) N130 G1 X15 ...

Figure 2-13: G12, G13 circular interpolation with specified radius

The following inputs are rejected with the error message 114:

• Starting point = end position

• No input of K

• Radius too small, i.e., the distance between the starting point and the end position is larger than twice the radius

• A spiral cannot and should not be produced with G12/G13.

Page 52: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 52/376

• The contour accuracy and the circle processing velocity are dependent on the circular interpolation of the K word value programmed in a G186-block (see 3.7 G186 Corner Acceleration, contour accuracy). If no K word was programmed, the contour accuracy and circle processing velocity are dependent on the existing value programmed by the machine manufacturer.

2.1.6 Helical Interpolation

Helical Interpolation is activated and performed in combination with G02, G03, G12, and G13. All the axes out of the active plane are treated as helical axes. The maximum number of helical axes is 6. An example for the x-/y-plane (G17) is:

N10 G02 I10.73 Z20.1

In the x-/y-plane, a complete circle is interpolated. The Z-axis is treated as the helical axis.

Note: The maximum number of helical axes is 6. The combination with tangential circle interpolation (G7) and cutter compensation is possible (G41, G42).

Page 53: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 53/376

2.1.7 G74 Programmable homing

Syntax: G74 X... Y... ... The instruction G74 causes one or several axes to move to their home position. A value is entered for each programmed axis address character. This value must be >= 1 but has no effect on the homing.

The axes programmed in connection with G74 all move simultaneously in the direction of their home position. When the axes have reached their home position, the machine zero point is set based on the home position.

Example: ... N50 G74 X1 Y1 ... • Never program two consecutive G74-blocks.

• When G74 is called up, no path compensations may be active.

• When G74 is called up, set axis values are set to 0 with G92.

• Part position offsets programmed with G54-G59 are not influenced by G74.

2.1.8 M80 delete remaining path using probe function

Syntax: M80 X... Y... The function delete remaining path using probe function is activated as default by the block effective instruction M80.

Note If the instruction M80 has already been allocated to another function in the control, then the function "delete remaining paths using probe function" may be assigned to another M-code.

Application: After the homing process, the machine's coordinate system is clearly laid out. The exact location of a work piece to be processed in the machine's coordinate system can be determined by using measuring probes and the function delete remaining path using probe.

Example 1: Delete remaining path using Probe function work as follows (without consideration of the measuring probe's radius):

... N10 X0 Y0 F1000 M80 N20 X-1 N30 Y-5 N40 X5 N50 Y0 M80 ...

Page 54: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 54/376

X, Y is original coordinate system. X'', Y'' is coordinate system after part position offset.

Figure 2-14: Delete remaining path using probe function (ignoring the probe's radius)

The exact location of the work piece in the coordinate system is unknown. The following program blocks enable a clear location of the work piece in the coordinate system:

Description:

N10 X0 Y0 F1000 M80 The point at which the measuring probe or tool reaches the work piece is assigned the coordinates X=0, Y=0.

N20 X-1 Move the measuring probe or tool away from the work piece edge. N30 Y-5 Position the measuring probe or tool under the work piece N40 X5 N50 Y0 M80 The point at which the measuring probe or tool reaches the work piece

is assigned the coordinates X05, Y00. The new coordinate origin is now positioned at the left lower corner of the work piece.

N60... Beginning of the actual NC program for the processing of the work piece.

...

Explanation of Example 1: The first program block N10 causes the measuring probe to be moved in a straight line in the axes X and Y to the machine's zero point. However, as soon as the

Page 55: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 55/376

measuring probe reaches a tool edge (point P1 in the example), the axis movement is stopped and the point P1 is assigned the destination point coordinates X`= 0, Y`= 0, which have not actually been reached yet. Thus the offsetting of the X-axis for the work piece in relation to the machine's coordinates system is performed.

The offset is determined for the Y-axis as follows:

The measuring probe is moved away from the work piece edge by the program block N20 and then brought to a position underneath the work piece by the program blocks N30 and N40.

The offsetting of the Y-axis of the work piece is determined in relation to the Y-axis of the machine's coordinate system by a travel movement in the Y-axis. This happens in the program block N50.

The measuring probe is driven linearly in the Y-axis in the direction Y'= 0. When the work piece edge is reached the travel movement is stopped.

The destination point coordinate Y``= 0 is assigned to the point reached P2. The point P3 X``= 0, Y''= 0 is therefore the origin of the coordinate system in which the work piece can be clearly positioned. It lies at the lower left-hand corner the work piece.

Example 2: The exact location of the work piece in the coordinate system is unknown and is determined using a measuring probe with the radius 10 mm (see Figure 2-15).

... N10 X-10 Y0 M80 N20 X-15 N30 Y-50 N40 X50 N50 Y-10 M80 ...

Page 56: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 56/376

T = tool with radius 10 mm

X, Y is original coordinate system. X ", Y" is coordinate system after the part position offset.

Figure 2-15: Delete remaining path using probe function and measuring probe radius

Description:

N10 X-10 Y0 M80 The measuring probe T is positioned in the direction of the point X-10, Y0. Coordinates X-10, Y0 are assigned to the point, which the measuring probe center reaches when the measuring probe touches the work piece.

N20 X-11 The measuring probe is moved away from the work piece edge. N30 Y-50 The measuring probe is positioned under the work piece. N50 Y-10 M80 The tool is positioned in the direction of the point X50, Y-10.

Coordinates X = 50, Y = -10 are assigned to the point which the measuring probe center reaches when the measuring probe touches the work piece. The new coordinate origin lies at the lower left-hand corner of the work piece.

Page 57: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 57/376

The instruction delete remaining paths using probe function may only be programmed with the codes G01, G02, G03, G07, G12 or G13.

The function delete remaining paths using probe function works similarly to the instruction G92 axis value settings. In the case of G92, the coordinates values programmed in connection together with G92 are assigned to the position where the tool is located when G92 is called up. In the case of M80, the destination point coordinates programmed in the M80-block are assigned to the point where the measuring probe or the tool reaches a work piece edge. Thus in both cases a part position offset occurs. In the further course of the program, the processes are based on the offset zero point.

With the delete remaining paths using probe function, part position offsets reached correspond to axis values set with G92. These can be cancelled with N.. G92. These values are retained during CONTROL RESET (see 5.1.5 G92 Set axis value).

2.1.8.1 Probe contact processing

This feature has built-in processing. Upon the detection of the probe contact, the CNC will react as illustrated below.

Figure 2-16: CNC reaction to the probe contact

Page 58: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 58/376

The drawing above, especially the time axis (in milliseconds), is not shown to scale.

n0 mechanical contact of the probe to a surface occurs

n1 probe input detected at the drive (Sercos) or at NC hardware (analog). At that time, the current axis position P1 will be latched (or saved) internally (with analog axes, all 4 axes of one input group will be latched). The distance traveled between the probe contact and the contact�s detection will be proportional to the axis velocity (so probing is usually performed at a slow feed rate).

n2 probe input detected by NC software. NC sets the current position to the latched position (with analog axes all 4 axes of one input group will be updated to the latched position) and the axis remaining path is moved into the G92 offset. In other words, the difference between the end position and the actual position (also called the axis remaining path) is added to the G92 part coordinate system offset for this axis; this difference is the probe offset obtained by this probe contact.

n3 the NC sets the latched position as new end position to the drive.

n4 drive receives the new end position and stops its previously programmed motion, so the axis has reached its farthest position P2

n5 drive moves immediately to the new position (which is the position at the moment of probe contact) and stops.

Page 59: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 59/376

2.2 Positioning instructions

2.2.1 G07 Tangential circular interpolation

Syntax: G7 X... Y... The tangential circular interpolation is activated with the program word G07. The following may be possible or necessary as additional conditions:

• The destination point coordinates

• The feed rate

• The speed of rotation or the cutting speed

The tangential circular interpolation causes a circular arc to be blended in between the destination of the preceding motion block and the destination programmed in connection with G07. The arc is joined tangentially to the preceding motion block. The following three examples illustrate the function of the tangential circular interpolation.

Example 1: N10 G0 X10 Y10 F1000 N20 G1 X20 Y40 N30 G7 X50 N40 G1 X60 Y10 N50 M30

Figure 2-17: Straight line/circular arc

Page 60: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 60/376

Example 2:

N10 G0 X10 Y10 F1000 N20 G1 X20 Y40 N30 G7 X50 N40 G1 X90 Y20 N50 M30

Figure 2-18: Straight line/circular arc

Note: In this example the circular arc only joins tangentially to the straight line of the

preceding motion block but not to that of the following block. The two tangential joints in the example from the figure above only emerge by chance due to the location of the straight line of the block N40.

Page 61: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 61/376

Example 3: N10 G2 X30 Y30 I30 N20 G7 X50 Y50 N30 G1 X70 Y60 N40 M30

Figure 2-19: Circular arc/circular arc

If a circular arc was programmed in the block before the call of the tangential circular interpolation, a circular arc is fitted through the destination of the previously programmed circular arc and the destination point coordinates of G07. The circular arc is fitted so that the circular arc programmed in the preceding block and the circular arc produced by the tangential circular interpolation have the same tangent at the point of contact (see the figure above).

If a tangent is geometrically not possible at the starting point of the circular arc to be produced by the tangential circular interpolation, or, if the radius is larger than 10,000,000 increments, then a straight line is produced by the instruction G07 instead of a circular arc.

Note: In tangential circular interpolation the contour accuracy and the circle processing speed are dependent on the K word value programmed in a G186-block (see 3.7 Corner acceleration, contour accuracy). If no K word was programmed, the circular interpolation and the contour accuracy depend on the default value set in the control.

2.2.2 G05, G06 Spline Definition and Spline Interpolation 2D

Page 62: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 62/376

Syntax: G5 X... Y... M70/71/72/73 (Spline definition) G6 X... Y... F... (Spline interpolation)

Spline interpolation is used for the connection of specified points with smooth curves whose curve radii continually change. It is especially useful when combined with the function Teach In for the processing of contours, which are not defined as measured values but exist as models. The programming of a spline interpolation is made in two steps:

2.2.2.1 Step 1: Spline Definition

The axes addresses involved in the spline interpolation of the axes are programmed together with the program word G05. For each programmed axis, a dummy value must be specified which consists of at least one digit but which has no meaning (see following example).

The spline type is determined using an M-code. The M-codes M70 to M73 are available with the following meanings as default:

M70 Start and end of spline with curve 0 (natural spline), M70 is the default instruction.

M71 Start of spline with tangential transition and end of spline with curve 0.

M72 Start of spline with curve 0 and end of spline with tangential transition.

M73 Start of spline and end of spline with tangential transitions.

Splines with tangential transitions Splines with tangential transitions are joined without any kink to the last block before the spline interpolation and to the first block after the spline interpolation. These blocks may be linear or circular. If they do not contain any positioning information and therefore no direction is defined, then the spline starts and ends with the direction of the first and the last spline blocks respectively.

Examples: N10 G5 X1 Y1 M70/M71/M72/M73 (Spline definition) N20 G1 X10 Y0 N30 X0 Y15 N40 G6 X5 Y30 N50 X20 Y15 N60 X45 Y30 N70 X60 Y15 N80 G1 X65 Y30 N90 M30

Page 63: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 63/376

Figure 2-20: M70: Start of spline and end of spline with the curve 0 (natural spline)

Figure 2-21: M71: Start of spline with tangential transition and end with curve 0

Figure 2-22: M72: Start of spline with curve 0 and end of spline with tangential transition

Page 64: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 64/376

Figure 2-23: M73: Start of spline and end of spline with tangential transitions

2.2.2.2 Step 2: Spline Interpolation

Spline interpolation is activated using G06. Using any other G-code of the same group (e.g., G00, G02, and G13) can deactivate the spline interpolation. The block preceding a G06 block must always contain positioning information if a tangential transition is to be achieved.

Example: ... N30 G5 X1 Z1 M71 N40 G1 X2 Z5 N50 G6 X3 Z10 ... These program blocks have the following effect on a control with the three axes X, Y and Z.

Spline interpolation is effective for the axes X and Z. The axis Y is interpolated linearly. The values programmed in the G05 block with the axis addresses X and Z do not result in axis movements and do not influence future motion of the axes. The spline starts tangentially from the destination of the last motion block before the call of the G06-code. M71 makes the curve at the end of the spline is 0.

The spline definition G05 can be programmed in a single block together with the dummy coordinates of the axes involved in the spline and an M-code for the spline type (M70-M73) as shown in the example above. If no coordinates are programmed together with G05, then no axis is involved in the spline. Activation of the spline interpolation with G06 at a later point in time has the same effect as G01.

If a spline interpolation is deactivated and called up again later by programming another G-code of the same code group in a program, both the original spline

Page 65: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 65/376

definition with G05 as well as the original definition of the spline type (M70-M73) will remain valid.

If, for a new call-up of the spline interpolation, other axes are to be involved in the processing of the spline, their axis addresses (each together with a dummy value) must be programmed in a new G05 block prior to the activation of the spline interpolation. If a change of the spline type is desired, the M-code for the desired spline type must be programmed in a block prior to the reactivation of the spline interpolation or in the block from which the spline type change is to apply.

Additional Notes: • If only axis addresses and no new spline type have been programmed along with

G05, spline type remains the same.

• If G05 is programmed while G06 is active, then the error message 108 appears.

• If the spline interpolation is active, only blocks with positioning instructions in the plane in which the spline is processed may be programmed. Blocks without positioning instructions (e.g., G04, G92) result in error message 257.

• A spline that extends over only one block is executed without an error message as a normal linear interpolation (e.g., G01).

• For test purposes, programs that use spline interpolation can be converted to linear interpolation by replacing G06 with G01 in the corresponding program. The instructions for the spline definition or the selection of the spline type do not influence the linear interpolation.

• A contour accuracy programmed with a K word together with active Look Ahead and G186 has no effect on spline interpolation.

Path velocity

Extreme deviations of a spline from the programmed linear motion distance may result in a higher actual path velocity than that programmed. This is due to the fact that the programmed path velocity is always related to the linear motion distance. During processing of a spline, the tool is positioned with the necessary path velocity so that it reaches the destination at the same point in time as it would have done had it traveled along the linear path with the programmed path velocity.

Example:

... N10 G5 X1 Y1 M70 N20 G1 X10 Y10 N30 G6 X30 Y15 or N30 X30 Y15 respectively. N40 X30 Y25 N50 X10 Y20 ...

Page 66: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 66/376

Figure 2-24: Path velocity with linear interpolation and spline interpolation

Additional Notes: • Note the method of operation of the path compensations for spline interpolation

(see 5.1.1 Path Compensations).

• To achieve optimum results with spline interpolation, a programming of G11 fill dynamic block buffers before the activation of the spline interpolation can be useful (see 3.4 Empty/fill dynamic block buffer).

• The function G05, G06 spline is optional and not available in all MACHINEMATE CNCs.

2.2.3 G78, G79 Tangential Setting to the 2D Path

Syntax: G78 (C...) ... Tangential setting to the 2D path ON G79 Tangential setting to the 2D path OFF

The function Tangential setting at path 2D enables a rotational axis to be orientated during a travel movement in a plane so that a set angle with the tangent is always obtained at the point reached each time.

Application examples: 1. Sawing

Page 67: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 67/376

Figure 2-25: Tangential setting to the 2D path

To achieve the contour displayed in the figure above when sawing, the saw must be turned during the travel movement so that the saw blade is positioned tangential to the contour each time.

2. Laser welding During laser welding, the material feed must be made at a certain angle to the laser beam. The material must always be conveyed in the direction of processing in front of the laser ray.

3. Turning

Figure 2-26: Tangential setting to the 2D path when turning

If during turning, the material is always to be removed with the tip (A) of the cutting tool, then the tip must always be guided tangentially along the work piece contour. If the removal of material from the work piece is to be made by position B on the cutting tool, then the cutting tool must always be led at a certain inclined angle along the work piece contour.

4. Punching/nibbling

Page 68: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 68/376

Figure 2-27: Tangential setting to the 2D path when punching/nibbling

If the contour described in the figure above is to be achieved by punching or nibbling then the tool or the die must always be orientated according to the desired work piece contour.

Key Terms: Tangent Vector:

The tangent vector is a unit vector that points in the instantaneous direction of motion in the active plane at each point on the motion path.

Tangent Vector Angle: The tangent vector angle is the angle that is formed between the tangent vector and the main axis of the coordinate system. The angle of alignment is calculated from the sum of the tangent vector angle and any angle offset that may have been programmed.

Programming the lead-in The function tangential setting to the 2D path is activated by the modally effective command G78. This function is effective starting from the block that contains G78. If the axis address of the rotational axis is not programmed while in the G78 then a tangential lead-in is made and the angle offset totals 0. To program a lead-in with an angle relative to the tangent to the motion path (angle offset), the axis address of the rotational axis must be specified with the desired angle offset value and command G78 (see the figure below).

The function tangential setting to the 2D path is deactivated using the command G79 or by CONTROL RESET. Intermediate blocks (for synchronization) are generated when this function is switched off.

In servo processor systems, switching off the tangential setting to the 2D path function also stops the processing or preprocessing in the base processor until the switch off instruction has been processed.

Page 69: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 69/376

When the function tangential setting to the 2D path is activated, the rotational axis takes the shortest route (turn < 180°) to the alignment angle at the beginning of the processing. The function tangential setting to the 2D path is already active when the G78 block is processed.

The values of the angle offset programmed together with the axis address of the rotational axis are limited from -360° to +360°. If the programmed value lies outside this range, the error message 54 is displayed.

Figure 2-28: Programming the leading-in at a specific angle

2.2.3.1 Changing the angle offset with modally effective G78

If the function tangential setting to the 2D path is already active, programming another G78 block can change the angle offset. If G78 is programmed without specification of an angle offset, the angle offset is set to the value 0° starting at this block. In all other cases offset the angle offset is set to the programmed value.

In G78 blocks no programming of the rotational axis itself is possible. Only the angle offset for the rotational axis can be specified. With modally effective G78, however, the rotational axis (together with other axes) can be programmed as usual. The Leading-in is then deactivated in the block where the rotational axis is programmed with modally effective G78. If the rotational axis is positioned incrementally with modally effective G78 (with G91 active), the programmed values correspond to the adjusted position of the rotational axis.

Page 70: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 70/376

Example: See the following table and Figure 2-29.

N10 G1 X0 Y0 C0 F3000 N20 G78 X30 Y30 Angle of alignment 45° N30 G1 X60 Y40 Angle of alignment approx. 16.5° N40 G3 Y80 J-20 Tangential lead-in to circular arc N50 G1 X0 Angle of alignment 180° N60 G78 X-40 C45 Angle of alignment 225° N70 G3 Y40 J-20 Angle of alignment: 45° + tangent

vector angle N80 G1 X-20 Angle of alignment 45° N90 G78 Y0 Angle of alignment 270° N100 G1 X-30 Y-30 M30 Angle of alignment: approx. 217°

Figure 2-29: Programming a changing angle offset using G78

At block transition N90/N100, the rotational axis turns from 270° to approx. 217° using the shortest route to rotate approximately 53° in the clockwise direction. At contour corners the rotational axis always moves with maximum velocity to the alignment angle necessary for the following path. The interpolation of the remaining axes is not interrupted during this jump. Their positioning is continued during the "jump" of the rotational axis.

2.2.3.2 Behavior of the lead-in during reversal of motion direction

Page 71: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 71/376

Example: (See the following table and Figure 2-30.)

N10 G78 C45 N20 G1 X0 Y0 N30 X10 Y10 N40 X30 N50 G0 X10 M30

Figure 2-30: Behavior of the lead-in during a reversal of the motion direction

If two contradictory motion blocks are programmed, the tool jumps through 180° on the same path moving backwards. Specifying a limit angle can prevent this. This limit angle determines the maximum angle through which the rotational axis may jump at block transitions.

A second method used to prevent rotational axis jumping is to change the angle offset corresponding to the desired jump in the program.

Example: ... N10 G78 C45 N20 G1 X0 Y0 N30 X10 Y10 N40 X30 N50 G78 C-45 N60 G1 X10 ...

Page 72: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 72/376

Figure 2-31: Influence of the lead-in at reversal of motion reversal

2.2.3.3 Programming G92 and G54-G59 with G78 active

Programming of G92 set axis value together with a value for the rotational axis is not permitted when G78 is active. Values for the remaining axes can be programmed together with G92 as usual even when G78 is active.

In addition no axis value for the rotational axis may be set when G78 is called up together with G92. If necessary, an axis value set for the rotational axis must be reset to the original position.

When G78 is active, the part position offsets for the rotational axis selected with G54 to G59 is ineffective.

Axis limits of the rotational axis for full rotations: The current position of the rotational axis is displayed each time the function the tangential setting to the 2D path is switched on. At the same time the displayed angle values are reduced to the range of 0° to 360°. For a rotational axis position of 365°, only 5° is displayed.

The reaction of the control upon switching the function off can be preset and one of the two following possibilities can be selected (see the machine tool manufacturer's documentation to determine operation for your machine):

Page 73: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 73/376

1) The control internally counts the full rotations that the rotational axis makes when repeatedly moving along a closed contour in the same direction. The reduction to within the range of 0° to 360° is disabled after the function tangential setting to the 2D path is switched off. The absolute position of the rotational axis is restored. However, continued turns in one direction may result in a violation of the axis limits of the rotational axis, which is recognized in real-time. The error message 211 is displayed and EMERGENCY STOP is set. In this case the axis limits of the rotational axis therefore limit the number of full rotations that the rotational axis is able to make in the same direction. The axis limits can be preset. See the machine tool manufacturer's documentation for details.

2) The control does not internally count the full rotations of the rotational axis. Consequently, the absolute position of the rotational axis cannot be restored after the function tangential setting to the 2D path is switched off. However, this also prevents the rotational axis limits from being violated.

Note: Continued rotation of the rotational axis in the same direction can cause problems such as distortion of cables.

Programmable limit angle Using this function, it is possible to switch off the tangential leading-in until the directional change in the leading axis has exceeded the programmed limit angle. This function is only effective with linear interpolation since with all other types of interpolation the direction is constantly changed within a block.

To avoid the following axis jumping, the leading�in can be suppressed at small, non-programmed changes in direction of the leading axis.

The limit angle is programmed using a NC address that can be set (in the following examples the letter Z is used). The limit angle can be programmed either when the leading-in is activated or deactivated. In the following text it has been assumed that the leading axes are designated X and Y and the following axis C.

Example program:

Position of the C axis (in degrees)

N 5 G0 F1000 N 10 G78 X0 Y0 F3000 N 15 X10 Y0 0 N 20 X20 Y-1 354.289 N 30 X40 Y+1 5.711 N 40 X59 Y0.5 358.493 N 50 X71 Y-1.5 350.538 N 60 X80 Y0 9.462 N 70 X102 Y-1.8 355.323 N 80 X120 Y0.5 7.282 N 90 X140 Y0 358.568 N100 G02 X160 Y-20 J20 I0 358.568 -270

Page 74: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 74/376

N110 G1 Y-100 270 N120 X0 180 N130 Y0 90 N140 M30

The example program basically describes a rectangle with a rounded corner on the upper right. In the blocks N10 to N90 a move is made parallel to the X-axis towards the right, whereby the Y value varies about 0. This means that the tangential following axis jumps by a value between 2° and 10° at each block transition.

If in the example program the block N15 is changed to:

N15 X10 Y0 Z10

then from block N15 onwards all jumps which are less than 10° are suppressed. This means that the tangential following axis remains at its start position up to and including the block N90. Its position only changes at the start of the circle block.

The programmed Z value is always relative to the last rotational axis position reached. If the value Z - 10 is not programmed until block N30, then a jump is made through 15.173 degrees upon the transition to the N50 block.

A Z value can be programmed at any position in a program and remains active until a new value is programmed. At CONTROL RESET and end of the program the Z value is deleted.

Page 75: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 75/376

3 Influencing the Program 3.1 M00 program interruption (unconditional stop)

Syntax: M00 Unless other arrangements have been made in the PLC program, the instruction M00 enables an NC program to be interrupted in order to carry out a measurement. After processing an NC block in which the instruction M00 was programmed, the CNC interrupts the program execution. All modal values are preserved. Press the start-button afterwards to allow the processing to continue.

3.2 M01 program interruption (conditional stop) Syntax: M01

The instruction M01 has the same function as M00 if Alt A: AUTOmatic → F3: Program process 2 → F2: Optional halt (M01) was previously selected.

If Alt A: AUTOMATIC → F3: Program process 2 → F2: Optional halt (M01) is selected after an NC block with the instruction M01 has been processed and is already located in the dynamic block buffer, then the program is not interrupted even if the actual execution of the M01block has not yet begun.

3.3 M02, M30 end of program Syntax: M02/M30

The end of the program is programmed with the instructions M02 or M30. These two instructions have exactly the same effect. Therefore, it is not important which one is used.

In contrast to M00 the instructions M02 and M30 have the effect that all modal values are cancelled and the control is again reset in the home position.

M02 or M30 is entered in the last block of an NC program. The axes remain at the position reached at the end of the program.

The start key re-starts the program flow.

If a program repetition was programmed with L in an M02 or M30 block, then M02 or M30 respectively first becomes active after the last repetition.

In subroutines M02 or M30 only marks the end of the subroutine; not the end of the main program. M02 or M30 in this case cause only a return to the main program; the control is not reset to the home position.

Page 76: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 76/376

Each program must contain M02 or M30 as an end label. If this is not the case, the error message 32 appears.

Additional Notes: • An offset of the coordinate zero point programmed with G92 is not reset by

M02/M30.

• Subroutine calls in a block with M02/M30 are not allowed. No error message appears; however, the subroutine call is not executed.

• M02/M30 can be positioned anywhere in the last block; the instructions which follow after it in the same block are still processed before M02/M30 becomes active.

3.4 G10, G11 empty/fill dynamic block buffer

3.4.1 G10 Empty dynamic block buffer

Syntax: G10

The CNC is equipped with a block buffer for a certain number of NC blocks. The interpreter process fills this block buffer. From this block buffer, the interpolator process takes the NC blocks. For certain applications, it is necessary to prevent the interpolator process from taking blocks from the block buffer. The withdrawal of blocks from the block buffer can be enabled or disabled using the instruction G10 Empty dynamic block buffer or G11 Fill dynamic block buffer.

Application: The instruction G10 is necessary, for example, when a program must be stopped at a certain position using M00. This allows output of messages to the operator with the help of the interactive cycles.

After processing a G10-block, the interpolator�s block buffer is only refilled by the interpreter process after all preceding blocks have left the block buffer.

Example: Tool change at unload position X=0, Y=0.

... N100 Y0 N110 X0 N120 M0 N130 G10 N140 X200 Y200 ...

Page 77: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 77/376

The instruction G10 in N130 has the effect that the block N140 is processed only after the cycle start button is pressed (to resume the program after the M00).

3.4.2 G11 Fill dynamic block buffer

Syntax: G11

Application: The instruction G11 is useful when a fairly large number of very short blocks has to be processed without pauses at the block transitions. Programming of G11 is recommended before the activation of a spline interpolation or the function Look Ahead, where an optimum result can only be achieved when a sufficient number of NC blocks are present in the dynamic block buffer at the time of activation.

If G11 is programmed in a block, then this instruction as well as the following blocks are only processed in the interpolator process when the block buffer is completely full or the complete program is contained in the block buffer.

3.5 G72, G73 interpolation with precision stop OFF or ON Syntax: G72/G73 ...

With the program word G73, the instruction interpolation with precision stop is activated. It is deactivated with the program word G72. Contouring errors are removed right up to the block end using the interpolation with precision stop.

Contouring errors result from inevitable control deviations. The size of the contouring error depends on the feed rate and the control loop amplification (KV Factor). Contouring errors can lead to slight rounding of the corners of the work piece, as shown in Figure 3-1. Depending on the type of processing, contouring errors can also lead to twisting and deformed corners.

Figure 3-1: Contour with contouring error

Page 78: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 78/376

A rounded contour corner due to contouring errors is not usually a negative thing, since sharp edges are mainly undesirable. However, if contouring errors must be avoided (e.g., when turning special edges for seals), instruction G73 is used. For all types of interpolation, the following NC-block is only activated once the axes have traveled to the destination of the block that is currently processing. A preset number of contouring errors can remain to the block end.

If G73 is programmed, the tool may lose contact with the work piece when stopping. Marks will occur in the workplace contour because the cutting pressure is suddenly reduced when the feed is halted.

Figure 3-2: Contour processed with precision stop

Page 79: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 79/376

3.6 G08, G09 look ahead OFF or ON Syntax: G08/G09 ...

The function Look Ahead is switched on using the instruction G09 and switched off using the instruction G08.

The function Look Ahead is deactivated during processing of an NC program by blocks and by the following G-Codes:

• G73 interpolation with precision stop ON

• G74 programmable homing

• G95 feed rate as distance/rev

Method of operation of the function "Look Ahead" With G08 active, the NC motion block acceleration takes place from 0 up to the feed rate. The NC block braking takes place at the end, so the feed rate is zero when the destination point of the motion block is reached. Travel stops at exactly that point.

When Look Ahead is active the CNC recognizes several NC blocks in advance, at which positions the axes have to be accelerated or braked. The feed rate is automatically adjusted by acceleration or braking. The adjustment is made in consideration of the following factors:

• The feed rate programmed in the individual NC blocks (see Figure 3-3)

• The path curve and the corners, taking the maximum admissible axis acceleration values into consideration (see Figure 3-5)

• The maximum admissible axis speeds

G08 must be active when G95 (in/min or mm/min) is active. With the G95 function the CNC is performing a different type of look ahead than being described here with G09. G09 is not allowed with G95 active.

Page 80: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 80/376

Figure 3-3: Processing of NC blocks with and without "Look Ahead"

A uniform feed is guaranteed for two or more NC blocks in advance (see Figure 3-3). This leads to a more uniform, and in some cases, faster processing which results in higher surface quality and increased productivity. To guarantee uniform feed, control must not only consider the current NC blocks, but also must �look ahead" and take the course of the following NC blocks into consideration.

To enable a constant feed rate over several blocks in advance, when Look Ahead is active, the motion does not stop at the programmed block destinations, but continues with the feed rate reached at the block end (see Figure 3-3).

If the feed rate must be reduced to 0 at the block end, (e.g., because G09 was deactivated) motion stops exactly at the last block destination before deactivation of the function Look Ahead.

The CNC allows a large number of NC blocks to be "looked" at in advance with active G09 function. The number of NC blocks that can be looked at in advance depends on the available memory space in the dynamic block buffer (at least 4 blocks).

Page 81: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 81/376

When processing several NC blocks with the Look Ahead function active, the feed rate is limited so that a reduction of the feed rate to 0 is possible up to the last block to be processed. Each block has at least one point of interpolation.

If a block without positioning instructions appears within a sequence of NC blocks that are to be processed with active G09, the feed rate is reduced to 0 at the end of the preceding motion block.

If G09 is active and the minimum block execution times are not too short or the maximum block preparation times not too long, a new block in the geometry preparation is finished in time and the interpolator process is available for the processing in time. Programming G11 Fill dynamic block buffer or G04 Dwell time (e.g., before a critical program section) can ensure this. It is also possible to accelerate or brake from over several blocks away.

Additional Notes: • Switching from next block mode to the single mode causes all unprocessed G09

blocks to be processed as G08 blocks. If G09 blocks were already interpreted as G08 blocks, switching from single block mode to next block mode will cause the blocks to still be processed as G08-blocks. When processing NC blocks in the single mode the instruction G09 always works like G08.

• When Look Ahead is active, the spline interpolation with tangential transitions should always be used. The other spline interpolation types are also applicable (in which case one G08 block at the spline start and one at the spline end must be tolerated).

• To achieve optimal method of operation with servo processor systems after the Look Ahead function is activated, the dynamic block buffer should be filled before the first motion block is executed. The filling of the dynamic block buffer can be achieved by using the instruction G11 fill dynamic block buffer or with a dwell time programmed with G04.

Example: ...N30 G9 (G09 must already be active before

G04/G11 is programmed)N40 G4 F500 or N40 G11N50 G1 X20 Y30...N200 M30

Note: The function Look Ahead is optional and not available in all controls. When Look Ahead is available and active, it may be beneficial to limit the acceleration using the instruction programmable acceleration. This causes a level setting of the acceleration.

3.7 G186 corner acceleration, contour accuracy

Page 82: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 82/376

3.7.1 Corner Acceleration

Syntax: G186E ...

Example: ... N20 G186 E0.9 K0.05 ... The axes of a machine tool have a maximum admissible acceleration. A corner acceleration can be programmed by the instruction G186 together with an E word. Depending on the value of the E word, the corner acceleration either causes a short-term infringement of, or a reduction of, the maximum acceleration of the axes when G09 Look Ahead is active. The effect of different E word values is to be taken from the following table:

Value of the E Word Effect 1 Doubles the max. acceleration 0.5 (Preset Value) Retains the max. acceleration 0.25 Halves the max. acceleration 0.05 Reduces the max. acceleration by 10%

Table 3-1: Effect of different E word values

The E word programmed with G186 controls the sharp decrease in axis speed between motion blocks as shown in Figure 3-4.

Page 83: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 83/376

Figure 3-4: Sharp decrease in speed between motion blocks dependent on the corner acceleration

Page 84: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 84/376

Figure 3-5: Sharp decrease in speed dependent on the angle between

successive motion blocks.

Page 85: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 85/376

The size of this sharp decrease in speed depends on the size of the E word value and the angle between the paths described in successive blocks (see Figure 3-5). The higher the E word value and the less the deviation of the angle from 180°, the less the decrease in speed. On the basis of the contouring error, the required contour accuracy at the corner is therefore finally programmed via the E word.

Additional Notes: • If no E word was programmed, the value preset by the machine tool

manufacturer applies. (The default value comes from the Machine Parameter CornerAccelerationG09.)

• The function Look Ahead can be switched off with a very low E-value (e.g., 0.001), so that the processing is made in the same way as when G08 is active.

3.7.2 Contour Accuracy:

Syntax: G186K ... The desired contour accuracy during circular interpolation can be programmed with the instruction G186 together with a K word.

During circular interpolations a circle radius reduction, therefore a contour inaccuracy, appears depending on circle amplification (KV) and path velocity.

Figure 3-6: Circle reduction error when pulling out of a circle from standstill

Page 86: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 86/376

During circular interpolation with programmed contour accuracy, the path velocity is lowered so greatly that the programmed maximum circle radius reduction is not exceeded. If no value is input for the circle accuracy, a high K value can be programmed. The K value is programmed in the same units as the axis positions.

Additional Notes: • A programmed contour accuracy only influences the circular interpolation (with

G02/G03, G12/G13 and G07), and not the linear and spline interpolation.

• If no K-value was programmed, the value preset by the machine tool manufacturer is valid.

• Regardless of the programmed contour accuracy the feed rate of circular interpolation is always limited by the machine protection element set by the machine tool manufacturer, so that the permissible axis accelerations are not exceeded during circle processing. Therefore, the machine protection element may not allow high axis acceleration during the program execution despite an increase of the K word value.

• The programming of circular accuracy may be deactivated by a very high K value (e.g., 100). In this case the machine protection element comes into effect.

3.8 G75, G76 Curvature

3.8.1 Curvature Activation

Syntax: G75

Example: ... N20 G75 ... After a block with G75 the curvature function is active. The function is deactivated with G8 and/or G9. The curvature function includes Look Ahead so when G75 is active the Look Ahead function is also active.

The purpose of the function is to adjust continuously the velocity to the path curvature when running so that the axes do not exceed a given limit of their acceleration. The function approximates the G1 blocks with polynomials with a given accuracy.

The polynomials are defined so that the transitions between two blocks will be tangential. Depending on the curvature, a profile for the velocity is calculated to ensure the given maximum radial acceleration is not exceeded. The maximum allowed acceleration limit can be programmed with G76.

Page 87: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 87/376

Additional Notes: • When the curvature function is active programming the contour accuracy with

G186 has no effect. Curvature cannot be activated during G95.

3.8.2 Curvature Acceleration Limit

Syntax: G76 Kxx

Example: ... N20 G76 K70 ... The G76 K value specifies the percentage of the maximum acceleration that is allowed for the radial acceleration. In the example, the K70 indicates that the allowed radial acceleration is 70 percent of the maximum axis acceleration.

When G76 is not programmed the default value for the curvature acceleration is used. (The default value comes from the Machine Parameter CurvatureAcceleration.)

When the given accuracy limit for the polynomial interpolation is met then the polynomial is modified so that it is just inside the accuracy limit. This leads to a corner at the block transition and probably to a velocity at the block transition that is below the velocity profile from the curvature. (The accuracy limit value comes from the Machine Parameter CurvatureAccuracy.)

3.9 G04 dwell time Syntax: G4 F...

The instruction Dwell time is programmed with the program word G04 together with an F word. The dwell time in seconds is to be entered as sequence of digits in the F word.

However, another unit of time can also be used, such as milliseconds. If the letter F is expected to have a number of decimal places, usually 3, then the programmed dwell time is usually configured to be in seconds (but with the time resolution to milliseconds with those digits to the right of the decimal point). If the letter F syntax is expected to have no decimal places then the programmed time is often configured to be in milliseconds.

The maximum value is 99999. If dwell times longer than this are necessary, G04 blocks must be programmed the required number of times in sequence.

A dwell time has the effect that the next NC block is not executed before expiration of the dwell time. Note that a feed hold (cycle stop) condition does not suspend a dwell, only axis motion.

Page 88: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 88/376

Example: ... N50 X10 N60 G4 F500 N70 Y20 ... The programmed dwell time in block N60 has the effect that after processing of block N50 a waiting time is inserted (in this case either 500 seconds or 0.5 seconds, depending on the definition for the letter F syntax) before the next block (N70) is processed.

3.10 Corner Smoothing

3.10.1 G-codes Corner smoothing is achieved by using G-codes G200 corner smoothing off G201 R corner smoothing with a defined radius curve G202 E corner smoothing with a defined corner deviation G203 E...R� corner smoothing with a defined radius up to a maximum deviation. The first G-code is configurable with a machine parameter. Its default value is 200. The three following G-codes (here G201 to G203) are assigned the numbers following the first G-code.

3.10.2 Curvature radius R

The curvature radius is programmed using the letter R. If another letter must be used because R is being used for another function its ASCII code can be changed in a machine parameter. The value specified in a machine parameter is active after a control reset until a curvature radius has been programmed.

3.10.3 Corner deviation E

The corner deviation E states the distance between the programmed corner and the interpolated circular edge.

Page 89: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 89/376

Figure 3-7: Corner deviation E

If the corner deviation should be programmed using a different letter, then its ASCII code has to be entered in a machine parameter. The value specified in a machine parameter is active after a control reset until a corner deviation has been programmed.

3.10.4 Minimum block length

If blocks are programmed with a short path in relation to the programmed curvature radius or the permitted corner deviation, cases can occur when the insertion of a circular curve causes the neighboring NC blocks to become too short or that even the insertion of the arcs becomes impossible as is shown in the following example:

Figure 3-8: Curvature radius R

R programmed curvature radius • Block end points

A machine parameter defines the minimum path length that can be shortened.

An example case yields the following path:

Page 90: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 90/376

Figure 3-9: Curvature radius R with a minimum path shortened L minimal set length R programmed curvature radius • end points for the block __ programmed path __ rounded path

The blocks that are shorter than the machine parameter value were halved.

3.10.5 Acceleration monitoring

A special acceleration monitoring is active during the active real-time radius correction and corner smoothing.

This monitors the accelerations that occur on the corrected path as a result of feed direction changes. The maximum permitted acceleration is the circular acceleration defined by two machine parameters.

The path feed-rate is limited for blocks in which the permitted acceleration is exceeded in such a way that it will just be maintained.

A simple example:

The D correction value is 100 mm.

The traverse block causes a movement of 1 mm in the X-direction on the X-axis. The tool is located at the beginning of the block in the direction of the X-axis. At the end of the block, the tool is positioned exactly 180 degrees rotated in the reverse direction to the Y-axis. Within the block, the D correction value turns therefore from the positive Z-direction into the opposite negative Z-direction. This means that the working point moves approximate around a semicircle of Z = -100 mm, Y = 0 to Z = +100 mm, Y = 0. The acceleration monitoring limits the path feed in such a way that the permitted circular acceleration on this circuit is not exceeded.

3.10.6 Minimum and maximum bend angle

The following drawing below shows the definition of the bend angle.

Page 91: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 91/376

Figure 3-10: Curvature bend angle in a corner

Phi can take on values between 0 and 180 degree. The cosine of the maximum half bend angle is specified by a machine parameter. In case of this parameter being 0 then phi/2 is just 90 degrees or phi = 180 degrees. Corners whose internal angle is greater than that being applied will not be rounded.

The sine of the minimum internal angle phi/2 is specified by a machine parameter to define which corners will still be rounded. If the appropriate bit is also set in this parameter then the corner will be moved around from the outside using this angle.

3.10.7 The necessity of corner smoothing

With the corner smoothing function it should be possible to avoid corners that occur in a sequence of linear blocks. In this way, a more convenient handling of the 5-axis mill radius correction should also be made possible.

When processing a programmed path, a 3D mill radius correction takes place in real-time for 5-axis machines. The correction occurs perpendicular to the current tool orientation. During the definition of the correction required, only the parts of the path of the linear axes are considered. This does not limit tool center point (TCP) programming (G181 and G182) since, in this instance, the round axis does not contribute to the path. Without an active transformation, the part of the path of the round axis is not included.

At block transitions that are not tangential, the real-time mill radius correction causes nominal value jumps. This is shown in the following diagram.

Page 92: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 92/376

Figure 3-11: Corner smoothing and corner jumps ___ Uncorrected path __ Corrected path

The corner smoothing function is necessary for avoiding these jumps.

3.10.8 Programming

The function has three different activation mechanisms.

These are specified by G200-G203 where G201, G202, G203 are for the activation and G200 is for the deactivation. If only the activation code is programmed then the corners being programmed in the currently work plane level are rounded. In this case, corners created by movements out of the current plane will not be rounded. If one wants to round corners oriented freely in the used area, the three axes forming the spatial co-ordinate system must be programmed with an arbitrary value in the activation block. The individual G-codes are explained in the following text.

3.10.8.1 G201: Corner smoothing with a defined radius curve

The "corner smoothing with a defined radius curve" function is activated with G201. A radius curve can be programmed using R.

This can be changed in the NC program as desired with the first programming of G201. If no radius is programmed, the value that is specified in a machine parameter will be used.

A block with activated corner smoothing could appear as follows:

N4711 G201 R10 activates corner smoothing with a defined curvature radius of 10 mm

3.10.8.2 G202: Corner smoothing with a defined corner deviation

A programmable corner deviation is used instead of the radius curve. This can also be re-programmed in every block. The value specified in a machine parameter is used as default value. An activation block would appear as follows:

N4711 G202 E47.11 X1 Y1 Z1 activates corner smoothing with a defined corner error in the coordinate system formed by the X, Y and Z axes.

Page 93: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 93/376

3.10.8.3 G203: Corner smoothing with defined curvature radius and a maximum deviation

This is very similar to G201. G203 can program a corner error in addition to the radius. This corner error is then interpreted as a maximum permissible corner deviation. If smoothing is possible as defined by the programmed (or default) radius curve without exceeding the programmed (or default) corner tolerance then smoothing will take place using this radius curve. In the other case smoothing will take place in such a way that the maximum tolerance is observed. Programming should take place as follows:

N4711 G203 R10 E47.11 activates corner smoothing with a defined radius and a maximum corner error

The following diagram details the contexts just described:

Figure 3-12: Corner smoothing in G203

• Block end points ___ Original path __ Rounded path

3.10.8.4 Corner smoothing with 5-axis mill radius correction

Correction in all three linear axes is generally needed for mill radius correction of an arbitrary path when moving in three dimensions. It is possible to make the correction to the right and to the left of the path in the direction of milling.

Page 94: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 94/376

The tool vector and the path tangents do not have be vertically oriented to each other in order to obtain an unambiguous correction. The correction always occurs vertically to the plane which is created by the path tangent and the tool vector. This unambiguity is then missing if the tool vector and the path tangent are parallel to each other or if the path tangent is zero.

The first case occurs only if one proceeds in the direction of the tool. In this case, the old correction value is retained. The second case can arise through sole movement of the round axes. In this instance, the old path tangent is used but the new tool orientation is used to calculate the correction.

Programming of the real-time mill radius correction occurs with these (configurable) G-codes.

G150 turns off the real-time mill radius correction G151 correction takes place to the left of the path G152 correction takes place to the right of the path

The mill radius is determined by a value stored in a D correction.

A simple programming example without the additional corner smoothing functionality: N10 D7 invoke the 7th correction for D N20 G151 X10 activate the real-time mill radius correction, approach the

corrected path N30 X40 N40 G150 X60 deactivate the correction function N50 M30

The activation of the correction function is also permitted without path information: N10 D7

N20 G152 N30 G90 N40 G181 N50 X22

Entry into the corrected path occurs with a linear accumulation of the correction value. Leaving the corrected path occurs with a linear removal of the correction value.

A real-time mill radius correction without the function Corner Smoothing is generally not usable since corners cannot be machined and speed jumps occur at all changeover points between blocks causing the path curvature (spline - straight, circle - straight, circle - circle) to change suddenly.

The primary purpose of the corner smoothing function is to generate bend-free paths for the real-time radius correction and to ensure that the programmed feed-rate is maintained on the corrected path. Therefore, the corner smoothing function with active 5-axis mill radius correction deviates from the standard range of functions in two ways:

Page 95: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 95/376

• A circle is inserted in internal corners in the plane formed by the corner that

ensures that the corner can be rounded without contour violation. A circle having

exactly a radius of the correction value is inserted resulting in a corner as for the

standard 2D radius correction if the tool is positioned vertically on the corner.

• A circle with a negligible radius is inserted at the outer corners. Thus a circle with

the correction value is traversed using the real-time radius correction.

The programming of the real-time radius correction with Corner Smoothing appears, for example, as follows:

N10 D7 invoke the 7th correction for D N20 G203 X1 Y1 Z1 activate Corner smoothing N30 G151 X10 Y0 activate the real-time mill radius correction,

approach the corrected path N40 X40 Y0 N50 X40 Y40 N60 G150 X60 deactivate the correction function N70 G200 deactivate corner smoothing N50 M30

Figure 3-13: Real-time radius correction with corner smoothing

3.10.9 Problem case: angle too acute

Several problems arise if the angle is too acute or if the internal angle of the corner is nearly 0 degrees:

• the permitted corner deviation allows only a minimal radius curve.

• the neighboring blocks are shortened due to the smoothing function causing large errors in the corner.

• smoothing takes place with a radius that is too small and together with real-time radius correction an error results at the workpiece.

Page 96: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 96/376

To solve this problem, the corner smoothing function can be preset so that starting at a certain marginal angle the corners are rounded outside rather than inside. This is demonstrated in the following diagram.

Figure 3-14: Corner smoothing with corners rounded outside not inside

3.10.10 Problem case: collision monitor with real-time mill radius correction

In contrast to the mill radius correction using G40 to G44, there is no collision monitoring with the real-time mill radius correction. In this way various errors can occur on the workpiece such as semi-enclosed inner chambers. Therefore, it must be ensured that the programmed correction value can always be used without problems.

Furthermore, the path speed differs strongly from the programmed speed in places where collisions occur.

Together with corner smoothing, this problem cannot occur as long as no splines or circles are programmed since corner smoothing always inserts circles that do not cause collisions.

Page 97: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 97/376

4 Technological instructions 4.1 Influencing the feedrate

4.1.1 G94 Inches (Millimeters) per minute � IPM/MMPM

Syntax: G94 When G94 is active, the F code is interpreted as inches (millimeters) per minute feedrate. G94 is cancelled by G95.

It is recommended that a G94 be programmed on the same line as the F code to avoid confusion as to the active feedrate mode.

When changing feedrate modes, a new feedrate is required with either the G94 or G95. The old F value cannot be used in the new feedrate mode.

4.1.2 G95 Inches (Millimeters) per revolution � IPR/MMPR

Syntax: G95

When G95 is active, the F code is interpreted as inches (millimeters) per revolution feedrate. It is recommended that a G95 be programmed on the same line as the F code to avoid confusion as to the active feedrate mode.

When changing feedrate modes, a new feedrate is required with either the G94 or G95. The old F value cannot be used in the new feedrate mode. Before an axis will move at the feedrate specified with the G95 the spindle must be turning (i.e., M3/M4) because with the spindle stopped (i.e., M05) the effective feed rate in G95 is 0.0.

G08 must be active before G95 becomes active because G95 requires its own type of look ahead processing as the feed rate follows the spindle rotation.

4.1.3 F word for feed rate

The feed rate (the path velocity) is programmed with an F word as distance/min (when G94 is active) or as distance/rev (when G95 is active). The unit of distance is millimeters (when G71 is active) or inches (when G70 is active).

Example: F2000 means: Feed rate 2000 mm/min (when G94 and G71 are active)

• A feed rate not equal to 0 must be programmed for all types of interpolation unless positioning in rapid traverse (G00), programmable homing (G74) or thread

Page 98: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 98/376

cutting (G33, G34). At G00, the pre-defined rapid traverse velocity becomes active.

• A programmed feed rate is modal. It is valid until a new feed rate is programmed or until the feedrate mode is changed (G94/G95).

• A programmed feed rate and the rapid traverse velocity can be changed by the feed override (see 4.1.1.2 Feed override).

Additional Notes: During control reset, F is set to 0. An F word must be programmed in the first motion block of a program (or in a preceding block). This is not valid however for programs which are to be processed as subroutines only. In subroutines, the fact that the F word is missing offers a certain protection against the subroutine being started as a main program. If the F word is missing, the error message 199 appears and the program is not executed.

A dwell time is programmed through F in connection with the instruction G04 (see 3.8 G04 Dwell time).

4.1.4 G63, G66 Feed override

Syntax G63 F... Feed override ON G66 Feed override OFF

A feed override is a percentage change of the programmed feed rate. The MACHINEMATE can distinguish between two different feed overrides:

• A manually adjusted feed override (on the machine tool, usually a rotary switch)

• A programmed feed override

In the operating modes MANUAL and AUTOMATIC, the programmed feed rate (SET value), the override in %, the momentarily actual effective feed rate and the interpolation velocity of the CNC (ACTUAL value) are displayed in the FEED window. A feed rate influenced by an override can therefore be read directly from the monitor for program optimization.

Important: Feed override and spindle override cannot be adjusted with the user interface, but only with this part program technique or an external override switch.

Programming a feed override A feed override is programmed with an F word in a G63-block. The value of the F word (in %) must be an integer between 1 and 120. A feed override programmed with G63 has precedence over the feed override adjusted at the machine tool. However, if the feed override rotary switch on the machine tool is turned to 0%, then this setting always has precedence over a programmed feed override. Thus it is always possible to stop the movement of the axes by reducing the feed override to 0%.

Page 99: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 99/376

A feed override programmed with G63 can be deactivated by the instruction G66. G66 simultaneously activates the feed override, which is set at the feed rate override switch on the machine tool.

If no feed override was programmed with G63, the feed override adjusted on the machine tool is active.

If no F word is programmed in a G63 block, the axes are positioned with the feed rate programmed in the NC program. If a feed override has already been programmed in a preceding G63 block using an F word and this has since been deactivated, this previously programmed feed override becomes effective again.

Example:

N10 G66 The feed override adjusted at the machine tool is activated. ... N50 G63 The feed override adjusted at the machine tool is deactivated. The axes

are positioned with the feed rate programmed in the NC Program. ... N100 G63 F55 The feed override is set to 55%; i.e., the axes are positioned at 55% of

the programmed feed rate. ... N200 G66 The programmed feed override is rendered ineffective; the feed override

adjusted at the machine tool is activated.

... N300 G63 Same effect as N100.

Additional Notes:

• Feed overrides are effective both on the programmed feed rate as well as on the rapid traverse velocity. During execution of G00 rapid traverse, the feed override is limited to 100% max.

• Feed rate override values not equal to 0 have no effect on G74-blocks programmable homing or G33 or G34 blocks thread cutting.

Page 100: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 100/376

4.1.5 Programmable acceleration

Syntax: B... ... The function programmable acceleration enables the reduction of the axis acceleration with respect to the preset maximum value. The term acceleration means any increase or decrease in velocity.

Application: A reduction of the preset maximum acceleration is sometimes necessary (e.g., if the load on certain components such as laser optics has to be limited).

Programming: • The acceleration is programmed with the axis address B and a value (as a %)

between 1 and 100 without decimal places.

• The programmed percentage value relates to the maximum admissible acceleration.

• A programmed acceleration is modal. It can be changed through the programming of a new B word with another value. A programmed acceleration is overridden by control reset.

Example: The preset maximum admissible acceleration is reduced to 25% of its value and the acceleration time or braking time is quadrupled.

... N20 B25 N30 G1 X10 Y15 ... The programmed value affects all axes.

Additional Notes: • When inputting values larger than 100 or values that would result in an

acceleration time of more than 32 seconds, the error messages 212 or 110, respectively, appear.

• If Look ahead is active, the acceleration can be limited using the instruction programmable acceleration. This instruction causes a leveling of the accelerations when Look Ahead is active.

• The function Programmable Acceleration is optional and not available in all controls.

Page 101: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 101/376

4.2 Spindle Control

4.2.1 S Word

The spindle speed in revs/min is programmed with an S word. A spindle override can be programmed with an S word together with the instruction G63 (see 4.2.4 G63, G66 Spindle override). A limitation of the spindle speed can be programmed with G92 (see 4.2.5 G92 Spindle speed limitation). The direction of rotation of the spindle is determined by M-codes (see 4.2.2 M03, M04 Spindle ON, clockwise or counter-clockwise).

4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise

Syntax: M03... Spindle ON (clockwise) M04... Spindle ON (counter-clockwise)

The direction of spindle rotation is programmed and the spindle switched on with the instructions M03 and M04. The instruction M03 causes a clockwise spindle rotation; the instruction M04 causes a counter-clockwise spindle rotation. The directions clockwise and counter-clockwise are as viewed looking away from the spindle towards the working area.

4.2.3 M05 Spindle OFF

Syntax: M5... A spindle halt is programmed with the instruction M05. Spindle speed is set to 0.

4.2.4 M19 Spindle Orientation

Syntax: M19 S... A spindle orientation is programmed with the instruction M19. The orientation for the spindle is set with the S-code, which ranges from 0 to 360 (i.e., in degrees).

The S is required as it defines the target orientation.

4.2.5 G63, G66 Spindle Override

Syntax: G63 S... Spindle override ON G66 Spindle override OFF

The term spindle override is a proportional change of the programmed spindle speed. The MACHINEMATE can distinguish between two different spindle overrides:

• the manually adjusted spindle override (on the machine tool, usually a rotary switch)

Page 102: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 102/376

• A programmed spindle override

In the operating modes MANUAL and AUTOMATIC, the programmed spindle speed (SET value), the override in % and the momentarily actual effective speed rate (ACTUAL value) are displayed in the window SPINDLE. A spindle speed influenced by an override can therefore be read directly from the monitor for program optimization.

Important: Feed rate override and spindle override cannot be adjusted with the user interface, but only with this part program technique or an external override switch.

Programming a Spindle Override • A spindle override is programmed in a G63 block with an S word. The value of

the S word (in %) must be an integer in the range of 50 to 120. A spindle override programmed with G63 has precedence over the spindle override adjusted on the machine tool.

• A spindle override programmed with G63 can be deactivated by the instruction G66. G66 simultaneously activates the spindle override switch on the machine tool.

• If no spindle override was programmed with G63, the spindle override adjusted on the machine tool is active.

• If no S word is programmed in a G63 block, the spindle is rotated with the speed programmed in the NC program. However, if a spindle override has already been programmed in a preceding G63 block using an S word and this has since been deactivated, then the previously programmed spindle override becomes effective again.

Example: N10 G66 The spindle override adjusted at the machine tool is activated. ... N50 G63 The spindle override adjusted at the machine tool is deactivated. The

spindle rotates with the speed programmed in the NC program. ... N100 G63 S60 The spindle override is set to 60%. The spindle rotates at 60% of the

programmed spindle speed. ... N200 G66 The programmed spindle override becomes ineffective, the spindle

override which was set at the machine tool is activated ... N300 G63 Same effect as N100.

Note: Spindle overrides have no effect on G74 blocks (programmable homing) and

G33 or G34 blocks (thread cutting).

Page 103: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 103/376

4.2.6 G92 Spindle speed limitation

Syntax: G92 S... A spindle speed limitation can be programmed with the instruction G92 together with an S word. The value of the S word indicates the maximum speed in rev/min. If a speed change occurs during program execution while speed limitation is active, the change is only executed as long as the programmed maximum speed is not exceeded.

Application: A speed limitation can sometimes be necessary:

• When using tools with a prescribed maximum speed.

• With certain work pieces, to avoid overloading the drives.

• When using a chuck without compensation for the centrifugal force. The speed should then be limited for safety reasons to a value at which a sufficient tension is still guaranteed.

4.2.7 G96 Constant Surface Speed (Feet/Meter)

Syntax: G96 S... G96 provides constant SFM/SMM operation allowing direct programming of the desired SFM/SMM with the S letter address. The constant surface speed feature is sometimes called CSS.

When G96 is used, a maximum RPM constant should be entered in the program prior to the first G96; (G92 Sxxxx) if not, the maximum RPM for the machine is used.

When moving X in toward the center of the spindle, the RPM will only be updated until either the machine�s maximum RPM is reached, or the maximum RPM constraint (G92 Sxxxx) is reached. For correct CSS operation, X0.0 must be the center of the spindle.

When either limit is reached, the spindle operation will be straight RPM.

SFM/SMM operation will again function once the tool position causes the control to calculate an RPM less than either of the limits.

Do not position the X-axis at high feedrates in the G01 mode during G96 operation. The spindle drive may not be able to react fast enough and may cause a fault.

Note that a spindle gear change cannot be performed during the G96 mode. The correct spindle gear range must be defined before the G96 block. If the axis motion

Page 104: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 104/376

requires the spindle speed to exceed a limit of the current range then the speed (and so the feedrate) is clamped there, at that limit in the range (minimum or maximum). If the machine has more than one spindle gear range and if the G96 is programmed without an explicit gear range declaration (i.e., M41 to M46) then error 871 results. The gear range must be explicitly declared prior to the G96, if a gear selection is possible, because the G96 will not change spindle gear ranges based on the varying spindle speed as it maintains the CSS. If there are no spindle gear ranges then this M-code requirement does not apply.

4.2.8 G97 Revolutions per minute

Syntax: G97 S... G97 provides direct RPM operation allowing the desired RPM to be programmed as an S value. This cancels the G96 mode.

4.2.9 Reversal of rotation at M19, spindle orientation

An internal setting can be made for spindles with feedback if the rotation direction for reaching the programmed position can be reversed. The spindle position control loop will be closed after the deceleration of the spindle and the reaching of the "spindle stop rpm". The programmed position will be reached using shortest distance.

Depending on the position when reaching "spindle stop rpm", a reversal of the rotation can result. It is possible for spindles with only one direction to be set-up so that a reversal of the rotation is not allowed. In this case, the spindle rotates after reaching the "stop rpm" in the present direction to the position so the programmed position might not be reached using the shortest distance.

Page 105: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 105/376

4.3 Tool compensation functions Even with flawless preparation of the part programs, devices, tools etc., it is necessary to make corrections in the processing to compensate for a worn tool. Two types of tool compensations are stored and processed:

• Tool tip radius compensation (associated axis address D),

• Tool length compensation (associated axis address H).

The two types of compensation values are assigned their own compensation value memories in the control. The size of this memory and therefore the number of compensation values that can be stored are preset. The corresponding values can be taken from the documentation of the machine tool manufacturer.

4.3.1 Tool tip radius compensation

With tool tip radius compensation, the radius of the tool employed can be taken into account during processing using the function path compensation (see 5.1.1 G40-G44 Path compensation). The radius compensation memory contains the tool tip radius.

Figure 4-1: Tool tip radius compensation for rotating tools

4.3.1.1 Input of tool tip radius compensation values

There are three ways in which values of the tool tip radius compensation memory can be set Manually, By Allocation in a Cycle Block, and By Loading a File Which Contains the Required Values, as follows:

Manually: • Select Alt D: Data → F1: Data Selection → F4: Path Comp. D

• Select Alt D: Data →F5: Modify

Page 106: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 106/376

• Select the memory location, whose value is to be changed. (The memory location now appears in the input window. Here the old value can be deleted with the BACKSPACE key and a new value entered.)

• Click onto the OK field or press the RETURN key.

These inputs are now stored in the compensation value memory of the MACHINEMATE and are displayed on the monitor in the upper window by 1) allocation in a cycle block (see Chapter 6, General Cycle Programming), or 2) loading a file which contains the required values. Here a certain file format must be observed, which is similar to the file format for part programs:

<lf> % <lf> DTABXX <lf> Correction value table number D001=+00000.000 <lf> . . . <ETX> File end character

Notes: • <cr> <lf> can also be used instead of <lf>.

• The file end character (in the above display <ETX> =03H) can be preset.

• xx is a two-digit table number.

4.3.1.2 Calling up tool tip radius compensation values

Tool tip radius compensation values are selected with the axis address D and the number of the desired compensation value memory.

Example: ... N30 G1 X5 Y0 D4 ... Here, in the block N30, the content of the fourth radius compensation value memory is selected. This value is used for the function path compensation.

A previously selected radius compensation value is deactivated by:

• The selection of another compensation value memory

• Programming D0

Notes:

Page 107: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 107/376

• Active tool tip radius compensations are displayed in the window compensations in the operating mode INFORMATION.

• With spline interpolation a connection exists between the radius compensation value memory number and the method used for the path compensation (see 5.1.1 Path compensations).

4.3.2 Tool length compensation values

Tool length compensation enables for compensation between the difference of the pre-defined and the actual tool length. The tool length compensation memory contains the length of the tool in the direction of approach with respect to a tool reference point (see Figure 4-2).

Figure 4-2: Tool length compensation for rotating tools

In addition, the length compensation value memory can be preset to contain a second value for each compensation value. This second value enables a compensation parallel to, and in the direction of, another axis. Thus the outreach of a tool can be taken into account.

R

Figure 4-3: Tool length compensation for fixed tools

Page 108: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 108/376

4.3.2.1 Input of tool length compensation values

Manually: • Select Alt D: Data → F1: Data Selection → F2: Length Comp. H

• Select Alt D: Data → F5: Modify

• Select the memory location whose value is to be changed. (The memory location now appears in the input window. Here the old value can be deleted with the BACKSPACE key and a new value entered.)

• Click onto the OK field or press the RETURN key.

These inputs are now stored in the compensation value memory of the MACHINEMATE and are displayed on the monitor in the upper window by 1) allocation in a cycle block (see Chapter 6, General Cycle Programming), or 2) loading a file which contains the required values. Here a certain file format must be observed, which is similar to the file format for part programs:

<lf> % <lf> HTABXX <lf> Compensation value table number H001X=+00000.000 Y=+00000.000 <lf> . . . <ETX> File end character

Notes:

• <cr> <lf> can also be used instead of <lf>.

• xx is a two-digit table number.

• The axis addresses of the axes that are preset for length corrections must also be entered. If only one axis is preset for length corrections, then only one value per line can be entered and this must also be accompanied by the axis address.

4.3.2.2 Calling up tool length compensation values

Tool length compensation values are selected with the axis address H and the number of the desired compensation value memory.

Example: ...

Page 109: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 109/376

N30 X2 Y1 H2 ... Here, in the block N30, the content of the second length compensation value memory is called up and is consequently taken into account when positioning the axes (maximum of 2) which have preset length compensation.

A previously selected length compensation value is deactivated by:

• The selection of another compensation value memory

• Programming H0

Notes: • Tool length compensations should be deactivated at the end of the program with

H0.

• Active tool length compensations are shown on the axis display during the execution of the program (operating mode "AUTOMATIC" and "MANUAL" and in the window compensations in the operating mode "INFORMATION").

4.3.3 Tool or turret selection The part program will typically specify the tool number or the turret position to be used in the machining process. The syntax for either (tool number or turret position) is simply a T followed by the number.

4.3.3.1 Lathe Turret Position Number

For a lathe, the T-code defines the next turret position. The block with the T-code expects the turret to be rotated to that turret position. The block identifying the new turret position will often include its accompanying tool compensation codes, as required, as in: N150 T5 D5 H5 Alternately, the D and H codes will be in the part program as needed. The D-code is not required until a G41 to G44. The H-code is required before or with the next axis motion that requires the tool length compensation (usually both X and Z axes).

Page 110: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 110/376

4.3.3.2 Milling Tool Number

For a milling machine, the T-code defines the next tool number. There are many different approaches to tool management in milling applications. The most common: 1) Fixed location tooling 2) Variable location tooling 3) Manual tooling

A block after the new tool is in the spindle will include its accompanying tool compensation codes, as required, as in: N150 T5 M6 N160 G0 X10 Y10 Z20 D5 H5 Alternately, the D and H codes will be in the part program as needed. The D-code is not required until a G41 to G44. The H-code is required before or with the next axis motion that requires the tool length compensation (usually the Z-axis).

4.3.3.2.1 Fixed location tooling

With fixed location tooling, each tool is assigned a particular location (or pocket) in the tool storage, often called the tool magazine. Each time a new tool is selected, the previous tool is returned to its original pocket and then the new tool is moved from its pocket to the spindle. The M-code M06 will accompany the T-code in the same block to indicate to the PLC that a tool change is required. Example:

N10 T1 M6 get tool T1 from pocket 1 . . . N120 T5 M6 return T1 to its pocket 1, get tool T5 from pocket 5 . . . N540 T3 M6 return T5 to its pocket 5, get tool T3 from pocket 3

The tool change sequence will take several steps: 1) move the magazine to the correct pocket for the spindle tool (or just check

that it is still there) 2) move the tool from the spindle to its original pocket 3) move the magazine to the pocket with the next tool, just selected by the part

program 4) move the tool from its pocket to the spindle The special T-code of T0, with the M6, is sometimes used to indicate to the PLC that the tool in the spindle should be returned to its location in the tool magazine but another tool is not selected to replace it in the spindle.

Page 111: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 111/376

4.3.3.2.2 Variable location tooling With variable location tooling, each tool is assigned a particular number and it is loaded into an appropriate location or pocket in the tool magazine. The operator will update the CNC tool table with the correct tool numbers and pocket numbers. Each time a new tool is selected, the previous tool is returned to the pocket for this new tool while this new tool is moving from that pocket to the spindle. Essentially, at each tool change, the new tool is swapped with the previous tool. Over time (and after tool changes) the various tools will migrate among positions within the tool magazine. With this tool management scheme, the M-code M06 indicate to the PLC that a tool change is required. A previous block would have identified the T-code for which tool should go into the spindle. This coding is sometimes called the tool preselect, because the tool is identified for its eventual movement into the spindle but it is not moved to the spindle at that time. The tool preselect is done in the program so that the tool is picked up by the PLC prior to the actual tool exchange. This approach decreases the time when the part program is not cutting because the interruption to the part program is just the time for the tool exchange. With the first variation above (fixed location tooling) each tool change (M06) requires several mechanical motions, including one or two moves of the tool magazine. For this approach, the tool change sequence is different: 1) Swap the tools � move the tool that is waiting into the spindle at the same

time that the tool in the spindle is coming out. 2) Move the tool just taken from the spindle into the current pocket of the tool

magazine.

Since the tool is in the spindle after the completion of step 1, the part program can resume execution with the next block at its conclusion. The program does not have to wait for the completion of step 2. This approach minimizes the �chip to chip� time of the spindle but it also requires a mechanical tool change configuration that allows this swap of two tools. The mechanical tool change configuration is typically simpler for fixed location tooling than it is for variable location tooling.

Example:

N10 T1 move the magazine to the pocket with T1, move it from the pocket into the tool change mechanism

. . . N120 M6 put T1 into the spindle, get the tool that was in the spindle put that tool into the pocket that had T1 . . . N140 T3 move the magazine to the pocket with T3,

move it from the pocket into the tool change mechanism

. . . N640 M6 put T3 into the spindle, get the tool that was in the spindle put that tool into the pocket that had T3

Page 112: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 112/376

The special T-code of T0, with the M6, is sometimes used to indicate to the PLC that the tool in the spindle should be returned to a location in the tool magazine but another tool is not selected to replace it in the spindle. With this approach, the pocket to receive this tool is not predictable. The only requirement is that the CNC find an empty pocket for the tool. If the operator is running with the maximum number of tools (i.e., one more than the tool magazine capacity, so that every tool change is a swap and there are no spare locations) then the T0 will not be possible.

4.3.3.2.3 Manual tooling With manual tooling (usually in a milling application; unusual for turning), the T-code, if any, identifies the tool number for any tool change. Example:

N10 M0 (MSG,T1) operator manually puts T1 into spindle . . . N120 M0 (MSG,T5) operator manually puts T5 into spindle . . . N540 M0 (MSG,T3) operator manually puts T3 into spindle

The M0, the operator stop M-code, stops the part program. An operator message can be provided with the M0 in the block, using (MSG, . . . ) to identify the message to be displayed when this M0 becomes active. With manual tool management, there is usually no need to even use the T-code in the part program because the operator is managing the tooling, rather than the CNC picking the desired tool from a tool magazine.

Page 113: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 113/376

4.4 G110-G117 power control 2D instructions Note: The function "Power control 2D" is optional and is not available in all controls.

4.4.1 Application

Technologies that involve laser cutting and laser welding require processing power to be dependent on the elements of time, path velocity or current motion path. During laser cutting, the laser power must be adjusted to the changing path velocities. During laser welding, it must be possible to influence the processing power depending on the time or the current motion path. The MACHINEMATE outputs a voltage that controls the power of the laser, plasma beam or similar instrument.

4.4.2 Programming

The following variations are possible:

• Constant output voltage value U = constant

• Voltage output dependent on path velocity (v) U = f (v)

• Voltage output dependent on time (t) U = f (t)

• Voltage output dependent on motion path (s) U = f (s)

Programming this feature requires preparation instructions and activation instructions.

4.4.2.1 Preparation Instructions

Syntax: G110 X... Y... Axis selection G111 Preselection of V1, F1, T1 G112 Preselection of V2, F2, T2 G113 Preselection of V3, F3, T3 G114 Preselection of T4 G115 Preselection of T5

The 13 parameters, which are used together with the power control and the pulsed fast output signals, are specified with instructions from G111 to G117:

• 3 voltage values (V1, V2, V3)

• 3 feed values (F1, F2, F3)

• 7 time spans (T1 to T7)

Page 114: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 114/376

• T6 and T7 are used for the pulsing of fast output signals. The remaining eleven parameters are used for the function power control. Each value is assigned by first activating the function using the relevant U-code as follows:

• The voltage is programmed with a V word, value given in mV.

• the feed rate is programmed with a F word, value given in mm/min when G71 is active or Inch/min when G70 is active.

• the time is programmed with a T word, value given in ms.

Additional Notes • The preparation instructions should be programmed at the start of the program

for reasons of clarity. If power changes are necessary during the processing, the corresponding preparation instructions can be reprogrammed within the program with the necessary values.

• In blocks that contain the instructions G111 and G112 through G117, positioning instructions and additional instructions can be programmed simultaneously (M, S, and T).

• The parameters for the power control programmed together with the preparation instructions are modally effective. They are set to 0 either by CONTROL RESET or when the instruction M02 or M30 is reached during the program execution.

Example: ... N10 G111 V1800 F2000 T500 N20 G112 V6000 F10000 T1500 N30 G113 V500 T1000 ...

Explanation of Example: N10: Voltage 1 = 1.8V Feed rate 1 = 2m/min Time 1 = 0.5s N20: Voltage 2 = 6V Feed Rate 2 = 10m/min Time 2 = 1.5s N30: Voltage 3 = 0.5V Time = 1.0s

As the example illustrates, all three parameters do not necessarily have to be programmed in a block with G111, G112 or G113 each time. During the processing of the power functions, only those programmed parameters that are necessary for that particular case are considered. Non-programmed parameters either contain the value 0 or the value that was last programmed.

Page 115: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 115/376

4.4.2.2 Activation instructions

Activation instructions are programmed at the program position where processing power is desired. The desired type of voltage output can be chosen by selecting the corresponding activation instruction. An activation instruction that is effective at the beginning of the block remains active until another activation instruction is programmed. The activation instructions include the following:

U = Constant Instruction Effect

U0 The voltage is set to 0V.

U1 The voltage that is definable in the G111 block V1 is activated.

U2 The voltage that is definable in the G112-block V2 is activated.

U3 The voltage that is definable in the G113-block V3 is activated.

U9 The voltage that becomes effective due to another activation instruction is held.

U10 The voltage is set to 10V.

U = f (v)

Instruction Effect

U20 The voltage rises proportionally to the path velocity within the boundaries determined with G111 and G112.

U = f (t)

Instruction Effect

U30 The voltage is dependent on the time. The voltage linearly acquires the value V1 within the time T1; this is held for the time T4. The voltage linearly acquires the value V2 within the time T2, this is held for the time T5. The voltage linearly acquires the value V3 within the time T3.

U31 The voltage is dependent on the time. The voltage linearly acquires the value V1 within the time T1.

U32 The voltage is dependent on the time. The voltage linearly acquires the value V2 within the time T2.

U33 The voltage is dependent on the time. The voltage linearly acquires the value V3 within the time T3.

Page 116: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 116/376

U = f (s)

Instruction Effect

U41 The voltage is dependent on the programmed motion path. The voltage linearly acquires the value V1 during the move along the programmed motion path.

U42 The voltage is dependent on the programmed motion path. The voltage linearly acquires the value V2 during the move along the programmed motion path.

U43 The voltage is dependent on the programmed motion path. The voltage linearly acquires the value V3 during the move along the programmed motion path.

4.4.2.3 Programming constant output voltage (U=constant)

Preparation instructions: G111 V... Setting of V1 G112 V... Setting of V2 G113 V... Setting of V3

The parameters V1, V2 and V3 are used for the output of firm voltage values. These parameters can be set with the instructions G111 to G113.

Activation instructions: U0/U1/U2/U3/U9/U10

U0 The output voltage jumps to 0V.

U1 The output voltage jumps to the value V1.

U2 The output voltage jumps to the value V2.

U3 The output voltage jumps to the value V3.

U9 The output voltage is held at its current value.

U10 The output voltage jumps to 10V.

Example: ... N10 G111 V... N20 G112 V... N30 G113 V... ... N50 U1 ... N70 U2 ...

Page 117: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 117/376

N90 U3 ... N100 U10 ... N120 U0 ...

Figure 4-4: Output of firm voltage values

Page 118: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 118/376

4.4.2.4 Programming voltage output dependent on the path velocity (U=f(v))

Preparation instructions G110... Axis selection G111 V... F... Setting of V1 and F1 G112 V... F... Setting of V2 and F2

The parameters V1, F1, V2 and F2 are used for the function "Voltage output as a function of the path velocity". These can be allocated with values using the instructions G111 and G112. Furthermore, a maximum of two axes can be selected whose motion path is used for the calculation of the voltage output. The parameters V1 and F1 determine the lower limit values while the parameters V2 and F2 are the upper limits.

• If the feed rate F is given a value < F1, the output voltage U=V1. If the feed rate F is given a value > F2, the output voltage U=V2.

The calculation of the path velocity is based on the axes (maximum 2) that were programmed together with G110. The speed can be preset as the actual or set value. For further information about this please refer to the machine tool manufacturer's documentation.

Note: The equation F1 < F2 must be held true for the path velocity. If this is not the case F1 is internally set to the value of F2.

Page 119: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 119/376

Activation instructions (U20)

Figure 4-5: Voltage output as a function of the path velocity

The voltage output between the lower voltage limit value V1 and the upper voltage limit value V2 is made proportionally to the path velocity.

If the machine is already in motion when instruction U20 is called up or if a firm output voltage is programmed, the output voltage jumps back to the value corresponding to the current path velocity. The voltage output is made proportional to the respective path velocity.

Page 120: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 120/376

Figure 4-6: Call of U20 when firm output voltage is active

Page 121: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 121/376

4.4.2.5 Programming voltage output dependent on time (U=f (t))

Preparation instructions G111V� T� Setting of V1, T1 G112V� T� Setting of V2, T2 G113V� T� Setting of V3, T3 G114V� T� Setting of T4 G115V� T� Setting of T5

The parameters V1, T1, V2, T2, V3, T3, T4 and T5 are used for the function "Voltage output as function of time". With this, a linear rise or fall of the output voltage to the voltage values V1, V2 or V3 is made within the times T1, T2 and T3 respectively. The times T4 and T5 are stopping times for the voltages V1 or V2.

These parameters are set with the instructions G111 to G115.

Activation instructions (U30/U31/U32/U33) U30 Linear rise/fall of the currently available output voltage to the value

V1 within the time T1, keeping the value V1 for the time T4. After that, linear rise/fall of the currently available output voltage to the value V2 within the time T2, keeping the value V2 for the time T5. After that linear rise/fall of the currently available output voltage to the value V3 within the time T3.

U31 Linear rise/drop of the currently available output voltage to the value V1 within the time T1.

U32 Linear rise/fall of the currently available output voltage to the value V2 within the time T2.

U33 Linear rise/fall of the currently available output voltage to the value V3 within the time T3.

Example of U30:

... N20 G111 V... T... Setting of V1, T1 N30 G112 V... T... Setting of V2, T2 N40 G113 V... T... Setting of V3, T3 N50 G114 T... Setting of T4 N60 G115 T... Setting of T5 ... N100 U30

Page 122: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 122/376

Figure 4-7: Voltage output as a function of time

The stopping times T4 and T5 are inserted after T1 and T2, respectively, if they were programmed before with G114 and G115 respectively. The voltage values V1 and V2 remain constant during the times T4 and T5 respectively.

If one or more of the times T1, T2 and T3 are programmed, then the output voltage either jumps immediately to the corresponding output voltage value V1, V2 or V3, respectively, or after the stopping times T4 and T5 have elapsed (if programmed).

Example of U30 with T1 not programmed: ... N50 U0 Firm voltage value 0V. N60 G111 V1000 Voltage V1=1V N70 G112 V2000 T500 Voltage V2=2V, time T2=0, 5s N80 G113 V3000 T600 Voltage V3=3V, time T3=0,6S N90 G114 T400 Stopping time T4 of the voltage V1=0,4S N100 G115 T700 Stopping time T5 of the voltage V2=0,7S N110 U30 T1 is not programmed, thus the output voltage jumps

directly to the value V1, and this is kept for the stopping time T4. A linear rise of the output voltage to the value V2 within the time T2 then follows and V2 is held during the stopping time T5. Finally, a new rise to the value U3 within time T3 is made.

Page 123: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 123/376

Figure 4-8: Output voltage as a function of time (T1 not programmed)

Example of U31:

... N60 G111 V... T... Setting of V1, T1 ... N100 U31 The output voltage rises linearly to the value V1 within the time

T1. ...

Page 124: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 124/376

Figure 4-9: Voltage output as a function of time (example U31)

If no time T1 is programmed, U31 behaves like U1. The output voltage jumps to the value V1.

The instructions U32 and U33 result in an analog conduct, the times T2 and T3 and the voltages V2 and V3, respectively, are however standard for these instructions.

Additional Notes: • The instructions for the voltage output as function of time (U31-U33) work

completely asynchronous for the processing of the NC program. The block sequence has no influence on the voltage output, as long as no new voltage output functions are active.

• If one of the instructions U31 to U33 is processed, before a previously programmed time span has elapsed, then this instruction is immediately activated.

Page 125: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 125/376

4.4.2.6 Programming voltage output dependent on motion path (U=f(s))

Preparation instructions G111 V... Setting of V1 G112 V... Setting of V2 G113 V... Setting of V3

The parameters V1, V2 and V3 are used from the functions U41 to U43. These parameters can be set with the instructions G111 to G113. The parameters specify the values to which the output voltage linearly rises during the processing of the motion block in which U41, U42 or U43, respectively, was programmed.

Activation instructions U41/U42/U43 X... Y... ... U41 The output voltage linearly acquires the voltage value V1 during the

processing of the motion block in which U41 was programmed.

U42 The output voltage linearly acquires the voltage value V1 during the processing of the motion block in which U42 was programmed.

U43 The output voltage linearly acquires the voltage value V1 during the processing of the motion block in which U43 was programmed.

U41 to U43 therefore always relate to the motion path that is programmed in the same block.

Example of U41 : ... N10 G111 V... Setting of V1 N20 G112 V... Setting of V2 N30 G113 V... Setting of V3 ... N60 G1 X5 Y5... N100 U41 X0 Y0 The output voltage linearly acquires the value V1 during the

processing of the block N100. �

Page 126: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 126/376

Figure 4-10: Voltage output as function of the motion path (example U41)

Page 127: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 127/376

Example Program for Power Control:

Figure 4-11: Power control

N10 G110 X0 Y0 Selection of the axis X and Y for the calculation of the path

velocity. N20 G111 V1000 F1000 Voltage 1=1V, feed rate 1=1m/min N30 G112 V8000 F8000 T200 Voltage 2=8V, Feed rate 2=8m/min, Time 2=0.2s ... N70 X100 Y100 F2000 U1 U1 causes the voltage at the beginning of the block to jump to

the voltage V1 (= 1V) programmed with G111 in block N20. N80 Y250 N90 X150 Y300 F6000 U20 U20 Causes the voltage output to be realized as a function of

the velocity. The voltage value of the respective path velocity is adjusted from block N90 onwards. The output voltage thereby jumps at the beginning of the block N90 to the value corresponding to current path velocity. The boundaries, between which the respective voltage values alter, are specified in the blocks N20 and N30. They are programmed with G111 and G112.The values programmed in N20 after G111 determine the lower voltage boundary: in this case 1V, and is valid at feed values < 1m/min. The values programmed in N30 after G112 determine the upper voltage boundary: in this case 8V, at feed values > 8m/min.

...

Page 128: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 128/376

N140 Y2000 U1 Causes the voltage value to jump to the value V1 (= 1V) programmed in block N20 after G111

N150 X300 Y-250 U32 Causes the output voltage to be realized as a function of time, whereby the values programmed after G112 are valid: The output voltage linearly acquires the voltage value V2 (= 8V) programmed in block N30 within the time T2 (=0.2s) that was programmed in the same block.

N160 Y0 U0 Causes the voltage to jump to the value 0V. In the example, the versatile possibilities of usage of the power control are clear. The output voltage can be easily manipulated by the clear separation between the programming of the preparation parameters and the activation instructions.

Additional Notes: • The currently enabled instruction becomes ineffective when EMERGENCY

STOP is set and at CONTROL RESET.

• In both cases the voltage is set to 0.

• It is possible to preset whether an axis selection decided with G110 is preserved at CONTROL RESET.

4.4.3 Fast output signals for laser power control

4.4.3.1 Laser shutter control

The signal to open and close the laser shutter is critical in time. The CNC has to output the signal directly and fast. To control the opening or closing of the laser shutter for safety purposes with external signals (PLC, relays, etc.) an allow signal (shutter allow) is necessary (see machine parameter BCDByteMaskIndex). This signal gives the possibility to interlock the opening or closing of the laser shutter with different conditions. This makes it possible to close the shutter in emergency situations or open it, when all interlock conditions are fulfilled.

Some applications need additional fast signals (M-functions); therefore additional bits are necessary. Due to this reason a complete byte for time critical signals is provided. This byte has specified M-functions that can be selected in the part program.

M111 output bit 1 M101 reset bit 1 M112 output bit 2 M102 reset bit 2 M113 output bit 3 M103 reset bit 3 M114 output bit 4 M104 reset bit 4 M115 output bit 5 M105 reset bit 5 M116 output bit 6 M106 reset bit 6 M117 output bit 7 M107 reset bit 7 M118 output bit 8 M108 reset bit 8 M109 reset all bits

Page 129: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 129/376

Open laser shutter by M-function

The M-code to set an output bit (e.g., M111) is active at the beginning of an executed block. The opening of the laser shutter takes a certain amount of time. A delay of the feedrate release can be achieved by programming a dwell time.

N10 G04 F100 M111 N20 G01 X1000 F6000

Shutter opens at the beginning of the block � dwell time cycle � feedrate

Close laser shutter by M-function

The M-code that resets a fast output is modal and is active at the beginning of the block. For example, the M111 resets the output bit that is set by M101.

The following conditions also reset the output bit signal (e.g., M111) and close the laser shutter:

• EMERGENCY STOP • CONTROL RESET • M02 or M30

4.4.3.2 Position-defined fast M-functions

Syntax

M111 to M118 (set output) M101 to M109 (reset output)

With the function, the output of the fast M-codes (M101-M118) will be controlled so that the output is affected by a defined position.

Example:

In the following example, a position is defined for the fast outputs at the points X10 and X20 is desired. After the position X10 is reached, the fast output bit 1 (M111) is set; at the position X20 the fast output bit 1 (M101) will be reset. The function is active at the beginning of the block so the axis reaching its start point (or the end point of the last block) results in the fast output (set or reset).

With machine parameters, a delay (defined in microseconds) can be specified for a fast output. The second figure indicates that a specified delay has retarded the fast output actions (both the set and reset).

N10 X10 F1000 N20 X20 M111 N30 X30 M101

Page 130: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 130/376

X

N10t

N20

N30

t

Bit = 1retarded output

Figure 4-12: Position-defined fast M-functions

4.4.3.3 Pulsing of fast output signals

Syntax

To pulse the laser shutter with an M-code (e.g. M121), the laser G-codes are also used: G116 or G117 in conjunction with the times T6 and T7.

Preparatory functions

G116 T6

G117 T7

Executing functions

M121 to M128

Page 131: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 131/376

The M-code is executed at the beginning of a block at the same time as the axis interpolation. The fast output signals selected by M111 - M118 can be pulsed in this manner.

Example:

M121 Pulses the laser shutter M111 Opens the laser shutter, and the shutter stays open M127 Pulses the output signal M101 Closes the laser shutter, and the shutter stays closed

� Programming either M101 or M111 resets the pulsing of bit 1

� M101 resets pulsing and closes the shutter.

� M111 resets pulsing and the shutter stays open.

If a motion is programmed while pulsing is active then the laser shutter is pulsing during the movement. If pulsing is required without motion then a dwell time has to be programmed for the time the pulsing is needed.

4.4.3.4 Laser power control - fine interpolation

The laser power is output during the axis position control loop.

The fine interpolation is executed at all commands for a change in the constant value for the power.

At a step change in power (e.g., output of two different fixed voltage values) there is no fine interpolation.

4.4.3.5 Multiple channel power control

Syntax:

G110 - G117 U0 - U43 G210 - G217 U100 - U4300 G310 - G317 U10000 - U430000

This feature (Multiple channel power control) is an extension of the function laser power control (4.4.1 through 4.4.2). The difference is the number of laser output channels. With this extension, up to 3 laser output channels are possible.

Preparatory functions

channel 1 channel 2 channel 3 function

Page 132: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 132/376

G110 G210 G310 axes selection

G111 G211 G311 preselection of V1, F1, T1

G112 G212 G312 preselection of V2, F2, T2

G113 G213 G313 preselection of V3, F3, T3

G114 G214 G314 preselection of T4

G115 G215 G315 preselection of T5

V = voltage in mV F = mm/min T = time in ms

These remain independent of the respective laser output channels:

G116 T6

G117 T7

Executing functions

The executing functions are always programmed using the address U. The U-word always has 6 digits when controlling three laser output channels. For compatibility reasons with a single laser output channel, the units digit and the tens digit have to be programmed for the first channel, the hundreds digit and the thousands digit for the second channel and the higher positions for the third channel.

The function definitions by laser output channel:

channel 1 channel 2 channel 3 function

Uxxxx00 Uxx00xx U00xxxx 0 - Volt

Uxxxx01 Uxx01xx U01xxxx voltage V1

Uxxxx02 Uxx02xx U02xxxx voltage V2

Uxxxx03 Uxx03xx U03xxxx voltage V3

Uxxxx09 Uxx09xx U09xxxx voltage Vact

Uxxxx10 Uxx10xx U10xxxx 10 - Volt

Uxxxx20 Uxx20xx U20xxxx f (v)

Uxxxx30 Uxx30xx U30xxxx f (t) V1 > V2 > V3

Uxxxx31 Uxx31xx U31xxxx f (t) V1

Page 133: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 133/376

Uxxxx32 Uxx32xx U32xxxx f (t) V2

Uxxxx33 Uxx33xx U33xxxx f (t) V3

Uxxxx41 Uxx41xx U41xxxx f (s) V1

Uxxxx42 Uxx42xx U42xxxx f (s) V2

Uxxxx43 Uxx43xx U43xxxx f (s) V3 Example:

N70 U14130 N80 U1 N90 U100

Explanation:

N70: channel 1 time dependent voltage output (U30) channel 2 distance dependent voltage output (U41) channel 3 constant voltage output (U1) N80: channel 1 constant voltage output (U1) channel 2 voltage output is set to 0V (U0) channel 3 voltage output is set to 0V (U0) N90: channel 1 voltage output is set to 0V (U0) channel 2 constant voltage output (U1) channel 3 voltage output is set to 0V (U0)

Page 134: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 134/376

4.5 Advanced Regulation Technology (ART)

4.5.1 Application

The goal of ART is to eliminate the path inaccuracies that result from the lag (or the position following error) of the axes. As a result of the programming of ART (which is a process that allows the control to monitor the performance of the axes) the axes will follow exactly the programmed path and the actual acceleration of the axes will be set to the commanded acceleration.

The procedure for the programming of ART is described in the MachineMate Start Up Manual section 15. The ART programming is in that manual, not in this NC Programming manual, because ART is part of the control start up activities. There are three optimizations that are run during the process of ART: optimizing the axis velocities, optimizing the axis accelerations and optimizing the changing in accelerations. Each optimization consists of running a part program that exercises the machine, enabling the CNC to monitor the axis performance under defined circumstances. The respective part programs are also described in the Start Up Manual. None of these ART programming sequences will be applied within a normal part program.

The G-codes used for ART programming are G160 to G164.

Page 135: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 135/376

5 Geometric instructions 5.1 General geometric instructions

5.1.1 G40-G44 Path compensations

Syntax: D... ... Selection of the path compensation value G40... Path compensation OFF G41... Path compensation left of the work piece contour G42... Path compensation right of the work piece contour G43... Path compensation left of the work piece contour with altered

approach G44... Path compensation right of the work piece contour with

altered approach 5.1.1.1 Necessity of path compensations

Most NC programs are written for tool travel movements. The travel movements can be programmed relative to:

• The work piece contour

• The milling cutter center path for a "standard tool� (a tool with specified dimensions).

If the dimensions of the tools are not considered during program execution, the tool travel movements can have different effects on the work piece contour depending on the tool actually used. This is illustrated in the following figure:

Figure 5-1: Effect of different tool radii on the work piece contour.

From this illustration it is clear that:

• When using a milling cutter with relatively small radius (A) less material is removed from the work piece than when using a milling cutter with relatively large

Page 136: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 136/376

radius (B) when executing the same NC program with identical milling cutter center path.

• Such a dependence of the finished contour of the work piece on the tool dimensions is undesirable. To avoid this dependence, G-codes are available for so-called path compensations. If these G-codes are activated during execution, the tool will move on a path that has a constant distance to the programmed contour, according to size and dimensions.

• Depending on the tool used, the distance is calculated by the MACHINEMATE so that the work piece is produced exactly to the desired dimensions.

• The path on which the tool moves and which always has a constant distance to the work piece contour is called an equidistant.

• To be able to determine the equidistant on which the tool must be positioned, the control requires, among other things, the data of the used tool and input as to whether the equidistant must lie in motion direction left or right of the work piece contour (see Figure 5-2).

Figure 5-2: Equidistant left and right of the work piece contour

The active plane (selected with G17-G20) is always the decisive factor. The path compensation always takes place in the active plane. To determine whether the path compensation should be made in motion direction left or right of the work piece contour, look in the negative direction of the axis that is perpendicular to the active plane. The control takes the tool data from the tool tip radius compensation memory. It is either entered into the CNC control during set-up using the set-up sheet or read in. If the program is written based on the work piece contour, the path compensation value is the radius of the tool.

Page 137: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 137/376

If the program is written based on a standard tool, the path compensation value is the deviation of the radius of the tool actually used from the standard tool radius.

5.1.1.2 Path compensation, intersection point positioning

Assume the work piece contour is programmed and path compensation is active during block processing. The positioning is then made on an equidistant to the programmed contour. At block transitions, the intersection point of the extended equidistant paths of the block currently being processed and the next block is moved to and stopped at. If no intersection is obtained, linear intermediate blocks are produced. See Figure 5-3, 5.1-4 and 5.1-5 for examples of the intersection position.

Figure 5-3: Path compensation at the block transition Straight line/Straight line

Page 138: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 138/376

Figure 5-4: Path compensation at the block transition Straight line/Circular arc

Page 139: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 139/376

Figure 5-5: Path compensation at the block transition circular arc/circular arc

5.1.1.3 Programming path compensations

Path compensations are activated with the instructions G41 to G44 as follows:

• If equidistant is in tool motion direction left of the work piece contour, the path compensation is programmed with the instructions G41 or G43 (see Figure 5-2).

• If the equidistant is in tool motion direction right of the work piece contour the path compensation is programmed with the instructions G42 or G44 (see Figure 5-2).

• The path compensation is deactivated with the instruction G40, by D0 and by selection of a tool compensation value that contains the value 0.

• The control requires the exact dimensions of the current tool for the determination of the equidistant path. These dimensions are stored in the tool tip radius compensation memory. These compensation values are activated with the

Page 140: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 140/376

address character D together with the number of the desired compensation value memory.

• Negative compensation values are also possible. G41 with a negative compensation value is equivalent to G42 with a positive compensation value of the same amount. G42 with a negative compensation value is equivalent to G41 with a positive compensation value of the same amount.

• The call up of the compensation values and the activation of the path compensation can be programmed in different NC blocks (example A) or in the same NC block (example B).

The instructions G41 and G43 and the instructions G42 and G44 each differ when applied to approach behavior of the axes (see following topic titled �Approach and retreat behavior of the axes�).

Example A: N10 D7 Call up the 7th tool tip radius compensation

value from the compensation value memoryN20 G41 Activation of the path compensation (equidistant

left of the work piece contour)

Example B: N10 G41 D2 Call up the 2nd tool tip radius compensation

value from the compensation value memory andactivation of the path compensation (equidistantleft of the work piece contour)

5.1.1.4 Approach behavior of the axes

The positioning block after the activation of a path compensation is called the approach block. If a path compensation is programmed along with a positioning instruction in the same block, this block is designated as an approach block.

If a path compensation is activated with G41 or G42, a move is first made to the intersection of the equidistant of the approach block and the next block. If the approach block is one with linear positioning instructions, the intersection is moved to in a linear path. If the approach block is one with circular positioning instructions, the intersection is moved to on a spiral path.

Example of approach using G41 to move to intersection on a linear path (see Figure 5-6)

N10 G1 X10 Y2 F1000N20 G41 D2N30 X14 Y10N40 X20

Page 141: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 141/376

Figure 5-6: Move to intersection on a linear path

Example of approach using G41 to move to intersection on a spiral path

(Figure 5-7)

N10 G1 X1 Y1 F1000...N40 Y2N50 G41 D1N60 G2 X2.5 Y3.5 I1.5N70 G1 X5...

Page 142: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 142/376

Figure 5-7: Move to intersection on a spiral path

An altered approach of the equidistant path is enabled with the instructions G43 or G44. After programming G43 or G44 the starting position of the equidistant path of the next block is moved to. This starting position is offset perpendicular to the programmed tool path.

It is important that the instructions G43 and G44 are programmed in a single positioning block. If this is not done these instructions have the same effect as G41 or G42.

Example of path compensations G41 and G43: ...N10 G1 X1.5 Y0N20 G41 D1 X4 Y2 and/or N20 G43 D1 X4 Y2N30 X3 Y5N40 X7...

Page 143: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 143/376

Figure 5-8: Comparison of path compensations G41 and G43.

From the illustration it is clear that when programming with G41 the desired work piece contour would not be achieved exactly.

Additional Notes: • The instructions G43 and G44 differ only in the approach behavior from G41 and

G42. There is no difference when moving away.

• The first NC block with a positioning instruction after the deactivation of a path compensation with the instruction G40 is called a retreat block. If G40 is programmed along with a positioning instruction in the same block, this block is designated as a retreat block.

• The equidistant path is quit either linearly or on a spiral path at the intersection of the equidistant of the last block with path compensation and the equidistant of the retreat block.

Page 144: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 144/376

5.1.1.5 Retreat behavior of the axes

Example of retreat on a linear path ...N20 G41 D1N30...N40 G1 X20 Y30N50 X30 Y10N60 G40 X40...

Figure 5-9: Retreat on a linear path

Page 145: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 145/376

Example of Retreat on a spiral path ...N40 G41 D1...N70 X5 Y2N80 G3 X9 Y2 I2 J2 DO...

Figure 5-10: Retreat on a spiral path

After deactivation of the path compensation with the instruction G40 the tool can be led back again to the previous equidistant path by reprogramming G41 and G43 or G42 and G44 without changing the compensation value.

A deactivation of the compensation value is possible by programming D0 or by the selection of a compensation value memory with the contents 0.

Page 146: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 146/376

5.1.1.6 Intermediate blocks

If the equidistants of two successive positioning blocks do not intersect, the MACHINEMATE automatically generates up to three linear intermediate blocks. Positioning is then made to these intermediate blocks at the transition of the two positioning blocks.

Example 1 of generation of intermediate blocks: ...N30 G41 D1N40...N50 G1 Y4N60 G3 X6 Y0.5 I3.5...

Figure 5-11: Generation of intermediate blocks, example 1

Page 147: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 147/376

Example 2 of generation of intermediate blocks: ...N30 G41 D1N40...N50 G1 X4 Y4N60 G3 X7 Y1 I3...

Figure 5-12: Generation of intermediate blocks, example 2

Page 148: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 148/376

Example 3 of generation of intermediate blocks: ...N30 G41 D1...N50 G3 X5 Y3.5 J3N60 X8 Y0.5 I3...

Figure 5-13: Generation of intermediate blocks, example 3

Page 149: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 149/376

5.1.1.7 Angle cut off

If the intersection of two equidistants lies very far away from the programmed point, a disproportionately long motion path would have to be traveled to reach this intersection.

In such cases where the angle included by the two equidistants is less than a preset value, the tool motion path is shortened. Instead of moving to the intersection of the equidistants, the positioning is carried out according to a linear intermediate block.

Example of angle cut off: ...N30 G41 D1...N50 X3 Y5N60 X4 Y1...

Figure 5-14: Angle cut off

Page 150: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 150/376

5.1.1.8 Path Compensations at spline interpolation

Two different types of path compensations are possible with spline interpolation, end point radius compensation and real-time radius compensation. The number of the D-compensation dictates which of the two possibilities is used.

End point radius compensation is used below a determined D-number. Real-time radius compensation is used above a determined D-number. This partition of D-compensations can be preset. For details see the Start Up Manual or the control manufacturer's documentation.

End Point Radius Compensation The bisector of the angle between the straight connecting lines drawn between the programmed end points is calculated. The compensated end point is then the point on the bisector that is exactly the distance D from the programmed end point. The only exception to this is the formation of the first and the last spline point.

The compensated points in this case are formed by the intersection point between the straight connecting lines and the preceding, or following, contour element (straight line or circle). This means that in these two cases the distance of the compensated point from the programmed end point is larger than the compensation value.

The compensated end points form the spline construction points for the calculation of the compensated path. Therefore, the compensated path between the block end points does not run exactly equidistant to the original path.

Figure 5-15: End point radius compensation

Real-Time Radius Compensation

Here the path compensation is made in real-time perpendicular to the spline contour running through the uncompensated block end points (the actual layout of the determined points is much denser than is implied in Figure 5-16.)

Page 151: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 151/376

With real-time radius compensation the average distance between the compensated and the uncompensated path is equal to D. There is no increase at the block ends as can be the case with end point radius compensation. However, processing of narrow internal contours with real-time radius compensation can lead to insufficient material being removed (see Figure 5-17).

Figure 5-16: Real-time radius compensation

Figure 5-17: Insufficient cutting of internal contours with real-time radius

compensation

Page 152: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 152/376

5.1.1.9 Path velocity deviations

When path compensation is active, deviations of the path velocities resulting from the program can occur during program execution. Deviations can occur because the programmed path velocities relate to the programmed path (without path compensation) or the tool cutting point (with active path compensation). However, path compensations have the effect of not allowing the center of the milling cutter to move along this path, but rather along an equidistant. Therefore, the center of the milling cutter must be positioned depending on the contour on either a longer path (e.g., during outside circle processing), or on a shorter path (e.g., during inside circle processing).

The MACHINEMATE offers the possibility to control path velocity deviations depending on the interpolation type.

The programmed feed rates always relate to the tool center path and there are no deviations from the programmed velocity for linear interpolation and spline interpolation with end position radius compensation. The programmed feed rates relate to the corrected path for circular interpolation as well as for spline interpolation with real-time radius compensation. The conduct of the control in reference to the axis velocity deviations resulting out of this can be preset as follows:

• Speed increase with external contours, no change with internal contours

• Speed reduction with internal contours, no change with external contours

• Speed increase with external contours, speed reduction with internal contours. This is the default preset.

Additional Notes: Path compensation is not possible for:

• Axis value settings with G92 during path compensation. The error message 121 �Path correction, No G92 possible� appears.

• Programmable homing with G74 during path compensation. The error message 209 �Path correction, G code is not permitted� appears.

• Thread cutting (G33, G34). There is no error message; however, no path compensation is executed.

Page 153: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 153/376

5.1.1.10 Special cases for path compensation

4 special cases for path compensations exist as follows:

Special case 1: NC blocks without positioning information or with positioning information which does not result in axis movements in the active plane

Reaction of the control block: The block that follows a NC block (without positioning information or with positioning information) that does not result in axis movements in the active plane is treated like an approach block. During the processing of the block before this "approach block", a move to the offset point of the programmed destination point is made.

Example of reaction of the control to blocks without positioning information in the active plane: ...N20 G41 or G42 D1N30 G1 X6 Y10N40 X12N50 ... (Block without positioning

information in the active plane)N60 X14 Y5N70 X18N80 ...

Page 154: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 154/376

Figure 5-18: Motion with blocks without positioning information in the active plane

Important: A plane change may only be programmed when path compensation (G40) is

switched off).

Special case 2: Change of the compensation direction (change between G41 and G42)

Reaction of the control block The block in which the change between G41 and G42 was programmed is treated like an approach block. During the processing of the block before this "approach block", a move to the offset point of the programmed destination point is made.

Example of reaction of the control to a change between G41 and G42:

... G1 ...N40 G41 X3 Y7 D1

Page 155: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 155/376

N50 X10N60 G42 X12 Y3 (Change of the compensation direction)N70 X16...

Figure 5-19: Motion with a change between G41 and G42

Page 156: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 156/376

Special case 3: Sign change of the compensation value Reaction of the control The block, in which the compensation value is selected with an opposite sign, is treated like an approach block. During the processing of the block before this "approach block", a move to the offset point of the programmed destination point is made.

Example of sign change of the compensation value: ... G1 ...N40 G41 X3 Y7 D1 D1 = 2N50 X10 D2 = -2N60 X12 Y3 D2 (Sign change of the compensation value)N70 X16...

Figure 5-20: Motion with a sign change of the compensation value

Page 157: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 157/376

Special case 4: Change of the size of the compensation value but with no sign change

Reaction of the control A move is made to the intersection of the last equidistant with the previous compensation value and the first equidistant with the new compensation value.

Example 1 for change of size of compensation value but no sign change: … G1 …N30 G41 X7 Y7 D1 D1 = 2.2N40 X14 D2 = 1.1 D1 > D2N50 X20 Y2 D2 Change of the size of the

compensation value but with no signchange

...

Figure 5-21: Motion with change of compensation value but no sign change, example 1

Example 2 for change of size of compensation value but no sign change: ... G1 ...N30 G41 X7 Y7 D1 D1 = 1,1N40 X14 D2 = 2,2 D1 < D2N50 X20 Y2 D2...

Page 158: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 158/376

Figure 5-22: Motion with change of compensation value but no sign change, example 2

5.1.1.11 Problem cases

5 possible problem cases are as follows:

Problem case 1: Tool radius too large for an inside corner ...N40 G42 D1N50 G1 X2.5 Y4N60 X4N70 X5 Y8.5N80 X6 Y4N90 X9...

Page 159: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 159/376

Figure 5-23: Motion with a tool radius that is too large for an inside corner

The tool radius is too large for the programmed internal contour. This results in a reversal of the motion direction. In such cases the error message 207 appears.

Problem case 2: Radius of the circle < compensation value (R < D). Example of Radius of circle < compensation value (R<D): ... G1 ...N20 G42 X2 Y5 D1N30 X6 Y9N40 G2 X12 I3N50 G1 X16 Y2...

Page 160: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 160/376

Figure 5-24: Radius smaller than compensation value (R < D)

If the radius of the circle is smaller than the compensation value, the error message 98 appears.

Problem case 3: Full circle with radius compensation, external contour processing:

Reaction of the control Material is left unprocessed in the area of the programmed circle starting position.

Example 1: Material left unprocessed in area of programmed circle starting position (G42): ...N10 G1 X7 Y0 F1000N20 G42 D1N30 Y10N40 G3 J3N50 G1 Y0 D0...

Page 161: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 161/376

Figure 5-25: Motion with a full circle as external contour (with G42)

The same contour error also occurs when G41 is programmed in the block N20 and G02 in block N40. This type of contour error can also occur when using G42 or G44, however, fewer material is left unprocessed, since a move is made to the vertically displaced circle starting position (Q) and not to the intersection of the equidistant (P) (see Figure 5-26).

Example 2: Material left unprocessed in area of programmed circle starting position (G44): N10 G1 X7 Y0 F1000N20 G44 D1N30 Y10N40 G3 J3N50 G1 Y0 D0...

Page 162: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 162/376

Figure 5-26: Motion with a full circle as external contour (with G44)

Problem case 4: Full circle with radius compensation G42, internal contour processing

Reaction of the control: It is difficult to produce a full circle with radius compensation as an internal contour. This is because the tool will have already left the internal contour of the circle at the intersection of the equidistant of circle path and next block. This is illustrated in the following example.

Example of full circle with radius compensation as internal contour: ... G1 ...N20 G42 X9 Y4 D1N30 Y6N40 G2 J6N50 G1 Y4N60 X0 Y0 D0...

Page 163: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 163/376

Figure 5-27: Motion with a full circle as internal contour (with radius

compensation)

The control reacts similarly, when G03 is programmed in the above-mentioned program after G41.

The full circle as internal contour displayed in Figure 5-27 can be achieved by programming two semicircles instead of a full circle. The above-mentioned program example would have to be altered as follows:

... G1 ...N20 G42 X9 Y4 D1N30 Y6N40 G2 Y18 J6N50 Y6 J-6N60 G1 Y4...

Contour errors can be avoided through skillful programming and, if necessary, by inserting NC blocks without positioning information. The following program example shows a possible method of programming an external contour of a full circle with path compensation, which results in a full circle without contour errors:

Example for method of programming an external contour of a full circle with path compensation, which results in a full circle without contour errors:

Page 164: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 164/376

...N20 G1 X7 Y0N30 G44 Y10 D1N40 G3 J3N50 G4 (Dummy block)N60 G1 Y0 D0...

Figure 5-28: Full circle as external contour (with radius compensation)

The dummy block N50 has the effect that a move is made to the offset point of the destination point of the preceding block (N40). In block N60 the path compensation is disabled (retreat block).

Problem case 5: Insufficient cutting

Insufficient material may be removed when processing inside corners (work piece angle α > 180°). Therefore, it is practically impossible to produce an inside corner of radius < R with a tool of radius R.

Examples of External contour processing and Internal contour processing

Page 165: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 165/376

Figure 5-29: Processing with external path compensation at corners, internal

contour processing

Page 166: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 166/376

5.1.2 G53-G59 Part position offsets

Syntax: G53 � Cancel part position offsets G54/55/�/ 59 � Activate part position offsets

The instructions G54 to G59 are used for setting part position offsets. Part position offsets are cancelled with the instruction G53.

5.1.2.1 Application example for part position offset

Clamped in the chuck in Figure 5-30 are two identical work pieces that are to obtain the same finished contour. To avoid the necessity of programming two program parts with different coordinates for the two work pieces, part position offsets are carried out in the NC program.

The zero point G54 is positioned at the lower left corner of work piece 1. Zero point G55 is positioned at the lower left corner of work piece 2.

The relationship of the coordinates of work piece 1 to the zero point G54 is now exactly the same as the relationship of the coordinates of work piece 2 to zero point G55. This way the positioning instructions for the first work piece can then also be used for the second work piece.

5.1.2.2 Location and selection of the zero points

The programmer enters the location of the work piece zero points, which he used when writing the NC program, into the set up sheet.

The control is informed of the location of the pallet zero point in relation to the zero point G53 when arranging the machine. This is done by programming G92. The location of the zero points specified by the programmer (G54 to G59 maximum) in relation to the pallet zero point is read in into the control or entered manually.

If the work pieces are processed on a pallet with the same set-up on several machine tools, the location of the work piece zero points in relation to the pallet zero point remains the same respectively. Only the location of the pallet zero point in relation to the respective machine zero point needs to be determined and input to the control.

Page 167: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 167/376

Figure 5-30: Setting work piece zero points

5.1.2.3 Programming

At CONTROL RESET the zero point G53 is active. Programming of G53 disables part position offsets (G54-G59).

Six different part position offsets can be programmed in a NC program with the instructions G54 to G59. If one of the instructions G54 to G59 is programmed, the corresponding part position offset is only prepared and no axes are positioned. The offset values entered in the operating mode DATA when arranging the machine tool, only become active when coordinates are programmed after the programming of a part position offset with G54 to G59.

When programming circles, and if a part position offset is to control both axes, the destination point must be programmed by giving both coordinates values.

If a further part position offset (e.g., G55) is programmed in the NC program after a part position offset (e.g., G54), the offset values entered for this second part position

Page 168: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 168/376

offset G55 again relate to the zero point specified with G92 or to zero point G53, and not to the first part position offset G54.

Example:

N10 G1 X0 Y0 Z0 F1000 Move to the starting point, G53 activeN20 G54 Setting the work piece zero point G54

(In the following text, it is assumedthat for G54 the offset values X10,Y20, Z15 with reference to G53 wereentered in the operating mode "DATA".)

N30 X10 Y10 The offset values for the X and the Y-axis become active; i.e., a move ismade to the position X20, Y30 inreference to G53 or G92.

N40 Z10 The offset value for the Z-axisbecomes active; i.e., it will be movedto the position Z25.

N50 G53 G54 is disabled, G53 is reselected, noaxis travel movement

N60 M30 Program end

5.1.2.4 Input of part position offsets

The part position offsets can be called up with G54 to G59. The offset values can be assigned manually, by allocation in a cycle block, or by loading a file containing the required values, as follows:

Manually 1. In the operating mode "DATA", select F1:Data selection → F5:Zero offset G.

2. Select Alt D: Data → F5: Modify.

3. Click onto the line of the part position offset to which you would like to assign values. (The line now appears in the input window where you can delete previous values with the BACKSPACE key and enter new values.)

4. Click onto the OK field. Press the OK key or the RETURN key.

Using this method your values for the part position offset are transferred into the zero point compensation value memory of the MACHINEMATE and displayed in the upper window on the monitor.

By allocation in a cycle block See Chapter 6 General cycle programming.

By loading a file containing the required values The following file format must be observed:

Page 169: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 169/376

<lf> % <lf> GTABXX <lf> Number of the part position offset table G54X=+00000.000 Y=+00000.000 ... ... G59X=+00000.000 Y=+00000.000 ... <ETX>

< cr > < lf > can also be used instead of < lf >.

The file end character (< ETX > =03H in the above mentioned example) can be preset.

xx is a two digit table number.

Page 170: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 170/376

5.1.3 G70, G71 Programming in metric or inch format

Syntax: G70 ... Programming in the inch format G71 ... Programming in the metric format

With the instructions G70 (inch) and G71 (metric) a changeover is made between the input format. If the system integrator made no changes then at CONTROL RESET the instruction G70 is usually active for the MachineMate control.

A format change within a NC program is possible with these G-codes. After the format change, programmed length statements, positions and speeds are interpreted as values in the format that was selected. The values that are active when the format change is called up are converted into the new format.

Example of programming in the metric or inch format: ...N50 G71N60 G1 X2 Y2N70 G2 I2N80 G70N90 G2 I2...

Figure 5-31: Programming in metric or imperial format

Page 171: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 171/376

5.1.4 G90, G91 Absolute/incremental dimension programming

Syntax: G90 ... Absolute dimension programming G91 ... Incremental dimension programming

The instructions G90 and G91 distinguish between absolute dimension programming (absolute dimension input, G90) and incremental programming (incremental dimension input, G91). If G90 is active then all entered coordinate values of the axes relate to the part coordinate zero point. The values can be entered with negative sign.

Example of absolute dimension input (G90): N10 G0 X0 Y0 G90N20 G1 X20 F500N30 Y20N40 X70N50 Y0N60 X100N70 Y40N80 X70 Y70N90 X0N100 Y0 M30

Figure 5-32: Dimension input in absolute dimension programming

Page 172: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 172/376

The input of the coordinate values as incremental dimensions is programmed with the instruction G91. With incremental programming each axis statement relates to the position arrived at before the block. Incremental dimensions are therefore distances between adjacent points; they indicate the motion paths of the axes. The sign determines the motion direction.

Example for incremental dimension input (G91) N10 G0 X0 Y0 G91N20 G1 X20 F500N30 Y20N40 X50N50 Y-20N60 X30N70 Y40N80 X-30 Y30N90 X-70N100 Y-70 M30

Figure 5-33: Dimension input in incremental dimension programming

Page 173: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 173/376

5.1.5 G92 Set axis value

Syntax: G92 X ... Y...

The current part coordinate zero point can be shifted to an arbitrary point with the instruction G92.

This type of coordinate shift is achieved by assigning new coordinates to the destination point of the motion block preceding the G92-block. These coordinates that are to be newly assigned are programmed together with G92. Coordinate values (e.g., the X-coordinate value or the Y-coordinate value) that do not change with respect to the original values do not have to be programmed.

To cancel this shifting of coordinates, program the instruction G92 without coordinate values.

Example: N10 G1 X50 Y50N20 G92 X0 Y10

Figure 5-34: Set axis value with G92

The destination point of the NC block N10 is the point with the coordinates X50, Y50. In the NC block N20, this point will be assigned the coordinates X0, Y10. The coordinate zero point is shifted as shown in the example.

Application of Set Axis Value:

Page 174: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 174/376

A starting point can be defined for the processing of the work piece using the instruction G92 (e.g., the pallet zero point for the work piece zero points G54 and G55 in the example from Figure 5-35).

Figure 5-35: Definition of a reference point for work piece zero points

Like the instructions G54 to G59, the instruction G92 causes no axis travel movements; it only causes a part coordinate shift. The values programmed with G92 only become active when coordinates are programmed after programming of G92.

Additional Notes: • The instructions M02 and M30 do not reset axis values specified with G92.

• The instruction G92 has another meaning when programmed together with an S word. In this case it is used for programming the maximum rotational speed of the spindle. Spindle speeds programmed afterwards are limited to this value. (See 4.1.2.5 Spindle speed limitation.)

Page 175: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 175/376

5.1.6 G14-G16 Polar coordinate programming

Syntax: G14� Polar coordinate programming absolute G15� Polar coordinate programming relative G16 X� Y� � Definition of the pole point

With the instructions G14 and G15, a changeover can be made to programming the destination point coordinate values in the form of polar coordinates. After programming G14, the polar coordinates are interpreted as absolute values (analogous to G90); after programming of G15 they are interpreted as relative values (analogous to G91).

Before a changeover to polar coordinate programming, the plane must be programmed in which the polar coordinate system is to lie. If the system integrator made no changes, then the X/Y plane (G17) is active at CONTROL RESET; therefore, G17 does not need to be programmed when desired.

The coordinate values indicated after activation of polar coordinate programming are interpreted as follows:

• The angle is programmed in degrees with the address character of the main axis of the active plane.

• The radius is specified with the address character of the minor axis of the active plane.

Page 176: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 176/376

Figure 5-36: Polar coordinates

The polar coordinate programming is deactivated with the instructions G90 or G91 (see 5.1 Absolute/incremental dimension programming).

Major axis Minor axis

G17 X/Y-Plane X Y

G18 Z/X-Plane Z X

G19 Y/Z-Plane Y Z

Table 5-1: Major axis and minor axis

When G20 is active, the axis programmed with the address character I is the major axis, the axis programmed with the address character J is the minor axis.

The following table outlines which coordinate value on the three planes is interpreted as angle and which one as radius:

Page 177: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 177/376

X/Y-Plane (G17) Z/X-Plane (G18) Y/Z-Plane (G19) X: Angle in degrees Z: Angle in degrees Y: Angle in degrees Y: Radius in X/Y-Plane X: Radius in Z/X-Plane Z: Radius in Y/Z-Plane

Table 5-2: Angle and radius values in the three predefined planes

Example of polar coordinate programming without pole point

information (G17 "X/Y plane" is active as standard):

N10 G1 X0 Y0 F100N20 G14 X45 Y40 (P1) Activation of the polar

coordinate programming(absolute)

N30 X135 Y30 (P2) Angle with respect to X axis135°, radius 30

...

Figure 5-37: Polar coordinate programming without pole point information

Page 178: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 178/376

5.1.6.1 Programming the pole point

The pole point of the polar coordinate system can be determined at any position where required by using the instruction G16, if it is not to be identical with the zero point of the Cartesian coordinate system.

The coordinates of the desired pole point are programmed together with the instruction G16. If polar coordinate programming with G14 or G15 was activated before programming G16, then the pole point coordinates programmed together with G16 are interpreted as polar coordinates in absolute dimensions (according to G14) or in incremental dimensions (according to G15). If no change was made to polar coordinate programming before the call of G16, the pole point coordinates programmed together with G16 are interpreted as Cartesian coordinates.

Important Notes • Simultaneous use of G16 and G92 is not allowed.

• With the instruction G16, only a new pole point for polar coordinate programming is specified but no new coordinate zero point.

• In the case of a plane change with G17 to G20 a pole point programmed with G16 is reset to the zero point.

• In the following examples, �w.r.t.� represents �with respect to�.

Example of Programming the pole point with G17 active:

N10 G14 Activation of polar coordinateprogramming (absolute)

N20 G16 X30 Y20 Definition of the pole point: Anglewith respect to X axis 30°, radius 20

N30 X45 Y30 (P1) Point in the "shifted" coordinatesystem: Angle with respect to shifted Xaxis 45°, radius 30

Page 179: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 179/376

Figure 5-38: Polar coordinate programming with pole point information

Page 180: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 180/376

5.2 Specific geometric instructions

5.2.1 G17-G20 Plane selection

Syntax: G17 � Selection of X/Y plane G18 � Selection of Z/X plane G19 � Selection of Y/Z plane G20 I� J � Selection of freely definable plane

See Figure 5-39. The planes displayed are selected with the instructions G17, G18 and G19. In addition, the instruction G20 is available for the selection of a freely definable plane.

The active plane each time is relevant for the following functions:

• G02, G03 Circular interpolation with specified center point in the clockwise or counter-clockwise direction.

• G12, G13 Circular interpolation with specified radius in clockwise or counter-clockwise direction.

• G50 Scaling.

• G51, G52 Part rotation.

• G40-G44 Path compensations.

• G14-G16 Polar coordinate programming.

Note that in a lathe, with just axes X and Z, it is not uncommon to have all three planes and G-codes configured for the Z/X plane (since the machine has only one plane for two axes).

Page 181: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 181/376

Figure 5-39: Circular interpolation plane selection

5.2.1.1 Programming a freely definable plane

G20 together with the address characters I and J are programmed to freely define and select a plane. The number of the major axis must be given as the value of the I word, the number of the minor axis must be given as the value of the J word. These are the axes from which the freely defined plane is to be formed.

Major and Minor axis can be determined with the help of the right-hand-rule. If the thumb points in the positive direction of the major axis and the index finger points in the positive direction of the minor axis, then the middle finger must point in the positive direction of the third axis.

Page 182: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 182/376

Note: The error message 204 will appear if unavailable axes, the value 0, or two equal numbers are programmed in G20-blocks together with I and J numbers.

Example:

N10 G20 I4 J2 The plane G20 is formed by the axes with the

numbers 4 (major axis) and 2 (minor axis).N20 G2 I1 J0.5 Full circle in the plane G20, I controls the

4th axis, J controls the 2nd axisN30 G18 Call of the plane G18 (Z/X plane)N40 G3 I0.5 K1 Full circle in the plane G18 (Z/X plane)N50 ...

If the X-axis was assigned the number 1, the Y-axis the number 2 and the Z-axis the number 3, then the following analogies are produced:

Major axis Minor axis

G17 X/Y plane analogous with G20 I1 J2

G17 Z/X plane analogous with G20 I3 J1

G17 Y/Z plane analogous with G20 I2 J3

Table 5-3: Circular interpolation planes (G20)

Additional Notes: Circular arcs are programmed in the active plane with the instructions G02 or G03 (see 2.1.4 G02, G03 circular interpolation with specified center point). If G20 is the active plane, then the parameters I and J relate to the major and minor axes respectively, which were programmed together with G20. The parameter K has no meaning.

The destination point coordinates are programmed in G20-blocks using the address characters of the axes that form the plane G20.

A plane change is always made when the major and/or the minor axis/axes change.

A plane change deactivates G16 Pole of the coordinate system and resets the pole point to the coordinate zero point.

5.2.2 G24-G27 Programmable work field limitation (Safe Zone Programming)

Syntax: G24X � Y � Definition of the lower limit values G25X � Y � Definition of the upper limit values

Page 183: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 183/376

G27 � Turn on G26 � Turn off

The work area of a machine tool is determined by the motion limits of the individual axes. The motion limits prevent the axes from being positioned outside of their maximum and minimum position (see 2.1 General positioning instructions).

It is possible to reduce the work area of a machine tool using instructions G24 to G27 in three steps as follows:

Define the lower limit values for the axis travel movements with the instruction G24.

Define the upper limit values for the axis travel movements with the instruction G25.

Turn on the work field limitation using the modally effective instruction G27. A programmed work field limitation is turned off using the instruction G26 that is also modally effective.

Figure 5-40: Work area of a machine tool with the axes X and Y

8000

8000

-800

0

-8000

6000

-600

0

-6000

4000

-400

0

-4000

2000

2000

-200

0

-2000

Y

X

Upper motion limit Y axis

Lower motion limit X axis

Lower motion limit Y axis

Work area

Upper motion limit X axis

Programmed work area limit

6000

4000

Page 184: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 184/376

Example of reducing the work area of a machine tool using instructions G24 to G27 (See Figure 5-40):

� N10 G24 X-4000 Y3000 N20 G25 X7000 Y5000 N30 G27 ... ... In block N10, the X-axis may not be positioned outside the position X-4000 in the negative direction and the Y-axis may not be positioned outside the position Y3000 in the negative direction, as long as the work field limitation is turned on.

In block N20 the X-axis may not be positioned outside the position X7000 in the positive direction and the Y-axis may not be positioned outside the position Y5000 in the negative direction as long as the work field limitation is turned on. In this way, the X-axis may only be moved to positions within the area of X4000 to X7000 and the Y-axis only to positions within the area of Y3000 to Y5000.

Depending on whether G70 or G71 is active, the limit values are interpreted as inch or metric measurements (see 5.1G70, G71 Programming in the metric format/inch format).

If the programmed limit values are exceeded when processing a motion block when the programmable work field limitation is active, this causes the same reaction as if the preset axis motion limits were exceeded.

Additional Notes: • When the work field limitation is turned off, the axis motion limits (software limit

switch) determined by the machine manufacturer are valid.

• If no limit values were programmed together with G24 or G25, or if the programmed limit values are outside the axis motion limits determined by the machine tool manufacturer and if the programmable work field limitation is then turned on with G27, the axis motion limits (software limit switch) determined by the machine manufacturer are valid.

• Axis limit values programmed in G24 or G25-blocks are always interpreted as absolute values regardless of whether G90 or G91 is active.

• Programmed axis limit values are not subject to scaling.

• A programmed work field limitation is rendered ineffective by CONTROL RESET. In this case, the axis motion limits determined by the control configuration are valid again.

Error messages appearing when work field limitation turned on: The entire corresponding motion block is not processed when the work field limitation is turned on and a destination point coordinate lies outside of the programmed limits. The error message 211 appears.

Page 185: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 185/376

Example:

N10 G24 X-4000 Y+3000 Program the lower limit valuesN20 G25 X+7000 Y+5000 Program the upper limit valuesN30 G27 Turn on the work field limitationN40 ......N80 ...N90 G26 Turn off work field limitationN100 ......N190 ...N200 G27 Turn on the work field limitationN210...N240 ...N250 G24 Y+4000 Program a new lower limit value

for the Y axisN260 ......

5.2.3 G38, G39 Programmable axis motion mirror

Syntax: G38 ... The instruction G38 enables motion paths to be mirrored.

Programming: The function mirror is activated with the modally effective instruction G38 together with the address characters of the axes whose programmed motion paths are to be mirrored. In each case an arbitrary value must follow the address characters of the axes. This value has no effect on the program. Two examples follow:

Example 1 (Mirror activated with instruction G38): Program 1 (P1) without mirror:

N10 X0 Y0 F1000N20 X5 Y1N30 X7N40 Y2N50 X5 M30

Program 2 (P2); mirror the motion paths of the X-axis: N10 X0 Y0 F1000N20 X5 Y1N30 G38 X1N40 X7N50 Y2N60 X5 M30

Program 3 (P3); mirror the motion paths of the Y-axis: N10 X0 Y0 F1000N20 X5 Y1N30 G38 Y1N40 X7N50 Y2

Page 186: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 186/376

N60 X5 M30

Program 4 (P4); mirror the motion paths of the X- and the Y-axis: N10 X0 Y0 F1000N20 X5 Y1N30 G38 X1 Y1N40 X7N50 Y2N60 X5 M30

Figure 5-41: Programmable mirror, effect of the programs P1 to P4

Additional Notes:

• The mirror function is turned off by programming the instruction G39 or by programming G38 without coordinate specification.

• Repeated programming of G38, in each case with different axis address characters has the effect that positioning is always carried out only on the mirrored motion paths of the axis or the axes which were programmed in each last G38-block before the programming of the corresponding motion path.

• The starting point of a mirrored block to be positioned is always the destination point of the preceding motion block.

Page 187: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 187/376

• If the function mirror is turned off at another position to the one at which it was turned on, then a part position offset via G92 becomes automatically active for the difference in the route.

Example 2 (Mirror with prior setting of an axis value using G92): N10 G1 X0 Y0 F1000N20 G1 X5 Y5N30 G92 X0 Shift the Y axis to the current

position X5/N40 G38 X1N50 G1 X10 Y5N60 G39 Turn off mirroringN70 G4 Block without effect (dummy

block), necessary before G92without axis coordinates

N80 G92 Cancel part position offsetN90 M30 Program end

Figure 5-42: Mirror with prior setting of an axis value using G92

Page 188: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 188/376

When the G39 turns off axis mirroring and the axes have not returned to their initial mirror positions, there is a shift in the part coordinate system that is saved in the G92 offsets. At the time of the G39, the zero of the �new� part coordinate system (via G92) will be such that the current axis position is maintained. The CNC will display this part zero shift to the operator by maintaining its presentation in the Position display of the axis data. The End point display will continue to be the axis position in the part coordinate system as it always is. This difference in values could be confusing but it is important for the operator to be aware that when the G39 is not done in the same position as the G38 the part coordinate system will be shifted by that amount. Several examples below illustrate this CNC behavior.

N10 G92 (CANCEL ANY G92 OFFSETS)N20 G0 X0N30 G38 X1N40 X1N50 G39N60 X0N70 X2N80 G92 (CANCEL G92 OFFSETS)N90 M30

This is how the CNC will display the X axis positions during these blocks (with a different number of trailing zeroes depending on G70 or G71 context).

Block Position End point N20 0.0 0.0 N30 0.0 0.0 N40 -1.0 +1.0 N50 -1.0 +1.0 N60 -2.0 0.0 N70 0.0 +2.0 N80 0.0 0.0 In N30, the part coordinate system is rotating about X0 because the G38 was at X0.0.

In N40, X is moving in the opposite direction due to the mirroring. The command is X+1 but it was at X0 so it moves to X-1. The End point value indicates its position in the current part coordinate system while the Position value indicates its position in the �shifted� coordinate system. The axis �really� is at the Position value. The End point value always represents the end point for the current block in the current part coordinate system.

In N50, mirroring is being turned off. The block End point remains the same so X is at the same, unchanged position within the current part coordinate system. Because the X position when turning off mirroring was not at its original position in the part coordinate system, there is now a �2.0 offset in X. There is no change to the display of axis positions because nothing has changed in either context. The position in the current part coordinate system is unchanged (End point) and the position where it really is in the part coordinate system is also unchanged (Position).

Page 189: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 189/376

In N60, X is moving to a new position. The End point shows its location in this (shifted) part coordinate system while the Position shows its real position.

In N70, X moves again, with the same rules in the display.

In N80, G92 cancels the offsets and the X End Point now matches its Position because the offset has been removed and the Position was indicating where it really was in the �unshifted� part coordinate system.

The following is another example this handling of the displayed shift in the part coordinate system due to mirroring.

N10 G92 (CANCEL ANY G92 OFFSETS)N20 G0 X1N30 G38 X1N40 X0N50 G39N60 X0N70 X2N80 G92 (CANCEL G92 OFFSETS)N90 M30

Block Position End point N20 +1.0 +1.0 N30 +1.0 +1.0 N40 +2.0 0.0 N50 +2.0 0.0 N60 +2.0 0.0 N70 +4.0 +2.0 N80 +4.0 +4.0 In N30, the part coordinate system is rotating about X1 because the G38 was at X1.0.

In N40, X is moving in the opposite direction due to the mirroring. The command is to X0 but it was at X+1 so it moves to X+2. The End point value indicates its position in the current part coordinate system while the Position value indicates its position in the �shifted� coordinate system. The axis �really� is at the Position value. The End point value always represents the end point for the current block in the current part coordinate system.

In N50, mirroring is being turned off. Because the X position when turning off mirroring was not at its original position in the part coordinate system, there is now a +2.0 offset in X. The position in the current part coordinate system is unchanged (End point) and the position where it really is in the part coordinate system is also unchanged (Position).

In N60, X is commanded to its same position in the part coordinate system so it does not move.

Page 190: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 190/376

In N70, X is moving to a new position. The End point shows its location in the (shifted) part coordinate system while the Position shows its real position

In N80, G92 cancels the offsets and the End Point now matches its Position because the offset has been removed and the Position was indicating where it really was in the �unshifted� part coordinate system.

5.2.4 G51, G52 Part rotation

Syntax: G51 R.. Degree G52 R.. Radiant

It is possible to rotate a complete program or a part of a program within an active plane. The center of rotation is programmable. G51 or G52 activates the function. The angle of rotation is defined by means of the address R. A positive value means a rotation in the mathematical negative sense (counter clockwise) while a negative value means a rotation in the mathematical positive sense (clockwise).

If G90 is active the value is interpreted as absolute, in the case of G91 it is interpreted as incremental.

The rotation is always performed within the plane that is defined by G17-G20. The center of rotation is defined in a G51 or G52 block by means of the address of the corresponding axes, defining the plane.

If there is no explicit definition of the center of rotation, the rotation is performed around the zero point of the plane.

The part rotation is deactivated by control reset, end of the program, a change of the plane by a programmed G17-G20 or by means of G92 without axis information.

Two examples of part rotation follow:

Example 1 (Part rotation): Main program P1: N10 X4 Y4 F100N20 L1 Q2N30 M30

Subprogram P2: N10 G90N20 X8 Y4 F100N30 Y7N40 X4N50 Y4N60 G51 R90 Activation of part rotation. Angle of

rotation 90 degreesN70 M30

Page 191: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 191/376

Figure 5-43: Part rotation in the case of active G90

Example 2 (Part rotation):

Main program P1: N10 X6 Y5 F1000N20 G92 X0 Y0 Setting of zero pointN30 L3 Q2N40 M30

Subprogram P2: N10 G90N20 G1 X2 Y-1N30 G3 X3 Y0 I1N40 G1 X2N50 Y-1N60 X0 Y0N70 G91N80 G51 R90N90 M30

Page 192: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 192/376

Figure 5-44: Part rotation in combination with incremental programming (G91)

Page 193: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 193/376

5.2.5 G50 Scaling

Syntax: G50 R� The instruction Scaling is a "work piece orientated function". It enables a proportional enlargement or reduction of a programmed work piece contour to a given scale factor.

Programming: The function scaling is programmed with the instruction G50 together with a scale factor R. The scale factor must be >0. A scale factor <0 is rejected with the error message 18.

Scale factors affect all subsequently programmed motion path and radii but only in the active plane. A scale factor of 0.5, for example, has the effect that all motion path and radii programmed subsequently are halved, and a scale factor of 2 has the affect that all motion paths and radii subsequently programmed are doubled.

Note: The scale factor programmed with the address R is incremental when G91 (relative programming) is active. MACHINEMATE assumes a scale factor of 1 if no scale factor has been input.

Example 1 (Scaling): ....N50 G90...N80 G50 R0.5....N100 G91.....N120 G50 R0.25 -> effective scale factor = 0.75

Example 2 (Scaling): ....N50 G90...N80 G91.....N100 G50 R0.25 -> effective scale factor = 1.25

Example 3 (Scaling): The work piece contour K1 in Figure 5-45 has been produced using the program P1 with G90 active. The contour K2 has been produced using the program P2. This program is identical to program P1 except for the scale factor of 0.5 in the N20 block.

Program P1 Program P2 N10 G90 F1000 N10 G90 F1000N20 X20 Y20 N20 X20 R0.5 Y20 G50N30 X40 N30 X40N40 Y40 N40 Y40N50 X20 N50 X20N60 Y20 N60 Y20N70 M30 N70 M30

Page 194: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 194/376

A programmed scaling function is deleted by CONTROL RESET (the scale factor is set to 1). Positioning information can be programmed in G50 blocks at the same time (see example above).

Figure 5-45: Scaling with absolute and relative dimension input

In the operating mode AUTOMATIC, the destination point values obtained by the NC program by scaling are displayed in the display window as end points during processing of NC block for which a scale factor is active.

Note: The instruction G50 has no effect on part position offsets programmed with instructions on tool tip radius, tool length compensations, rotational axes or work field limits programmed with instructions from G24 to G27.

Page 195: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 195/376

5.3 Dresser, wheel or tool tip radius compensation (DWRC)

This section describes the operation of the dresser, wheel or tool tip radius compensations. This feature is often used in grinding or turning applications. This section does not include a description of the standard D- and H-compensation tables, to be found in section 4.3. For brevity, sometimes this feature will be called DWRC, an acronym for Dresser, Wheel or tool tip Radius Compensation.

5.3.1 Entering compensation values in tables

For DWRC, two tables are used for entering compensation values. For the length offsets the H-compensation table is used. For the tool tip radius and its orientation values the D-compensation table is used.

5.3.1.1 Wheel length offsets

Wheel gauge point on spindle from which wheel offsets are normally measured

Wheel gauge point on spindle from which wheel offsets are normally measured

This point is selected by the length offsets as control point

X le

ngth

offs

et

Z Length offset Z

Length offset

X le

ngth

offs

et

This point is selected by the length offsets as control point

Figure 5-46: Grinding wheel offset definitions

In a grinding application, the wheel length offsets are entered in the H-compensation data. The H-table entries from 1 to 64 can be used for DWRC. Each table entry consists of two axis values, Z and X.

Page 196: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 196/376

In a turning application, the turret offsets are entered in the same table.

5.3.1.2 Dresser / Wheel radius offsets

The dresser, wheel or tool tip radius offsets are entered in the D-compensation data. The D-compensation entries from 1 to 128 can be used for DWRC. The D-compensation values contain the extra information for the DWRC feature, the orientation direction for this compensation value. The values for the orientation are from 0 to 9. The correlation between orientation and orientation value is displayed in the figure below, for a wheel or a dresser/lathe. The figures are drawn for a machine with a wheel/turret moved by X and Z axes and with a stationary part or dresser (so orientation 1 is used when the grinding wheel is moving into the part in the X+ and Z+ direction; the same interpretation applies for the dresser or tool tip orientation 1 for X+,Z+). If the machine has a part or dresser that moves by an axis then the relative movement between the two partners must be taken into account. The axis moving a part or dresser is the same as an imaginary axis moving the wheel in the opposite direction.

Figure 5-47: Grinding wheel radius orientation definitions

Page 197: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 197/376

Figure 5-48: Dresser or tool tip radius orientation definitions

The orientation is entered in a row with the D-Correction value. When this D-table data is in a file, the orientation value (0 to 9) is distinguished from the D-correction(s) value with the character �R�. For example, these lines in a file are possible:

D001 = +1.000 +0.010 R1 (D-Correction, wear value, orientation)

D001 = +1.000 R1 (D-Correction, orientation, no wear value)

The figure below demonstrates the values which have to be set in the D- and H-tables to allow the correct compensation for the corner radius of a wheel.

Page 198: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 198/376

HX

HZ

RS

P (control point)

Sx

z

Wheel gaugepoint

Figure 5-49: Grinding wheel control point and gauge point definitions

The wheel corner radius (Rs) and its orientation value (4 in the case) have to be set in D-compensation table. Tool offset values of X (Hx) and Z (Hz) axes have to be set in the H-table. In the figure Hx value is positive and Hz value is negative (i.e., the H-offset is an offset from the control point to the wheel gauge point). The corner radius center of a wheel (S) can be set as a control point of a dresser/wheel. In the case the corner orientation value 0 or 9 has to be set in the D-compensation table.

5.3.2 Dresser Wheel Radius Compensation

5.3.2.1 Definitions

The following terms are used within DWRC:

Outside-corners An angle between two intersecting programmed paths is referred to as an

outside corner if, in the direction of travel, the angle measured clockwise

from the second path into the first is greater then 180 degrees. If one or

both of the two moves are circular. The angle is measured from a line

tangent to the path(s) at their point of intersection.

Inside-corners An angle between two intersecting programmed paths is referred to as an

inside corner if, in the direction of travel, the angle measured clockwise from

the second path into the first is less than or equal then 180 degrees. If one

or both of the two moves are circular. The angle is measured from a line

tangent to the path(s) at their point of intersection.

Page 199: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 199/376

Figure 5-50: Inside corner definition

Grinding wheels or dressers can have rounded edges which means there is a difference between the machining edge and the control point. This causes a difference between the programmed contour and the actual final contour of the part or the dressed wheel. The DWRC is able to compensate this difference.

There are three types of DWRC entry and exit moves with this compensation. The table below gives an overview of the main differences between the three compensation move types.

Type of move Type A Type B Type C Entry move to compensation

The path is the shortest possible path to its offset position.

The path stays at least one radius away from the start-point of the next block at all times. Extra motion blocks can be generated in an attempt to preventing gouging of the part as can occur in type A.

The entry move is the shortest possible path to its the intersection point of the equidistant lines.

Dresser / wheel path

No difference between type A , type B and type C during compensation.

Exit move from compensation

Exit move is the shortest path to the end-point for both inside and outside corners.

The exit move path is the shortest path to the end-point for inside corners only. For outside-corners, the path stays at least one radius away from the end point.

The shortest path is taken from the intersection point of the equidistant lines to the end-point of the exit move for both inside and outside corners.

Table 5-4: Differences between DWRC entry/exit move types A, B, C

5.3.2.2 Programming the compensation

The following G-Codes are used for programming DWRC. They are the same G-codes for path compensation described in section 5.1.1. These G-codes will apply DWRC rather than the conventional tool radius path compensation when a radius orientation is defined by the modal D-code.

Page 200: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 200/376

G-Code Dresser / wheel radius compensation G40 Compensation off G41 Path compensation left of the work piece contour.

Compensation entry / exit move type is defined in a machine parameter.

G42 Path compensation right of the work piece contour. Compensation entry / exit move type is defined in a machine parameter.

G43 Path compensation left of the work piece contour with an altered approach. Compensation entry / exit move type is defined in a machine parameter.

G44 Path compensation right of the work piece contour with an altered approach. Compensation entry / exit move type is defined in a machine parameter.

Table 5-5: G-codes for DWRC path compensation

To activate the DWRC the orientation value in the D-correction table has to be a value in the range from 1 to 8. The values 0 or 9 disable this DWRC compensation and result in a normal length and path correction according to the usual rules.

The dresser-wheel compensation is activated by programming H and D-words for the tool configuration. This format is as follows:

Ddd Hhh

were the number of digits for H and D depend on the number of correction table entries. Normally the ranges are 128 D-values and 64 H-values.

5.3.3 DWRC application schemes

The four basic application schemes or types:

• Dresser radius compensation

• Corner radius compensation

• Entire wheel radius compensation

• Tool tip radius compensation

All the application schemes mentioned above use the same tables to store values. The first three schemes are commonly for grinders while the fourth is for lathes.

Note: The active plane has to be correctly programmed for these application schemes. Usually the Z-X plane (G18) is used for the dresser radius, corner radius and tool tip radius compensations while the X-Y plane (G17) is used for the entire wheel radius compensation.

Page 201: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 201/376

DWRC Scheme

Length offsets (H-correction)

Part coordinate offsets (G54-G59, G92)

DWRC compensation

Dresser radius Shifted on Z and X axes to wheel control point

Shifted to point of dresser tip

On radius of diamond dresser

Corner radius Shifted on Z and X axes to wheel control point

Shifted to point on part being machined.

On radius of wheel corner where Z/X length offset is located

Entire wheel radius

Shifted on Z to wheel control point; Y offset is taken into account with DWRC.

Shifted to point on part being machined.

On entire radius of wheel

Tool tip radius Shifted on Z and X to tool control point.

Shifted to point on part being machined.

On radius of tool tip

Table 5-6: Application schemes for DWRC path compensation

5.3.3.1 Dresser radius compensation

With this scheme, the CNC can compensate dressing errors from the radius of the dresser tip. The radius of the dresser tip is entered in the Dresser / Wheel radius offset table (D-Compensation).

Figure 5-51: Dress/wheel radius compensation example

Usually the grinding wheel moves across the dresser. The wheel becomes the part and the dresser is the shaping tool. The axis motion is then opposite to the dresser

Page 202: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 202/376

motion. If the dresser is mounted to independently moving axes then the inversion of motion as just described is not done.

5.3.3.2 Corner radius compensation

The errors resulting from the rounded corners of the grinding wheel can be compensated. The corner radius must be selected from the D-table for the correct point of control. The programmer is responsible that the correct combination is selected and in this way one, two or more corners can be programmed for one wheel.

Figure 5-52: Wheel corner radius compensation example

5.3.3.3 Entire wheel radius compensation

The CNC can also compensate errors resulting from the entire radius of the grinding wheel. The radius of the grinding wheel is to be entered in the radius table. (There is no need to enter an orientation because orientation values are not used in this scheme.) No X-length offset has to be entered. For compensation only Z-length offset and the radius value is needed.

5.3.3.4 Tool tip radius compensation

The CNC can also compensate errors resulting from the tool tip radius of the lathe cutting tool. The tool tip radius and its orientation are entered in the D-table. The H-table X and Z-length offsets are associated with the turret position (nothing to do with the tool radius). An illustration of this type of compensation is shown above (Figure 5-

Page 203: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 203/376

51) but in this case the diamond dresser tip example in the upper right corner of the figure represents the tool tip used in turning and the grinding wheel in the lower left of the figure represents the part being turned.

5.3.4 NC block formats

The DWRC is programmed with the following format:

Gcc Xpppp Zpppp Drr Hll

With:

cc One of the activation G-Codes: 41, 42, 43, 44 pppp Any position the axes are to be positioned to. ll Number of the length offset which is to be used (00-64); 00

deactivates the length compensation. rr Number of the radius / orientation set which is to be used (00-

99). 00 deactivates the path compensation. The DWRC can be activated in several ways:

Program block CommentActivation within one block

N10 G41 D12 H11X10 Y5

� Sets compensation left of the workpiece, selects DWRC offset number 12,length offset 11, activates thecompensation entry move, moves axes toX10 X5 (with DWRC).

Activation within two blocksN10 D12 H11

N20 G41 X10 Y5

Selects DWRC offset number 12, lengthoffset 11.Sets compensation left of the workpiece, activates the compensation entrymove, moves axes to X10 X5 (with DWRC).

Activation within three blocksN10 D12 H11N20 G41N30 X10 Y5

Selects DWRC offset number 12, lengthoffset 11.Sets compensation left of the workpiece.Activates the compensation entry move,moves axes to X10 X5 (with DWRC).

Activation within three blocksN10 G41N20 D12 H11N30 X10 Y5

Sets compensation left of the workpiece.Selects DWRC offset number 12, lengthoffset 11.Activates the compensation entry move,moves axes to X10 X5 (with DWRC).

Table 5-7: Activations of DWRC path compensation

Page 204: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 204/376

5.3.4.1 Intermediate block types

In certain instances, the control generates a non programmed move called an intermediate block. This block improves the performance and cutting quality. The user can program the type of intermediate block as linear or circular by programming a G45 (for linear intermediate blocks) or G46 (for circular intermediate blocks). These G-Codes are modal. The initial state (default) or the state after a control-reset is always G45. These two G-Codes can be programmed anywhere in the program but they must be programmed before or in a block that causes an intermediate block to have their effect.

Figure 5-53: Linear and circular intermediate blocks

5.3.5 Compensation Entry/Exit Move Types

Three compensation entry/exit move types are defined. These move types refer to different entry and exit moves when activating DWRC, while the path during active compensation will not differ. The figure below shows the main differences of the compensation move types. There are three identical pictures, where one of the compensation move types is enhanced and the two other move types are displayed in gray only. This is done to see the specific features of each compensation move type in comparison to the others. These pictures show also the contour of a work-piece which would be the result.

Page 205: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 205/376

Type B entry move

With this entrymove type, the tool is always left at least one radius away from the start point of the next block.

Type C entry move

With this entrymove type, the tool moves to the intersection point of the equidistant lines of the entry block and the first compensated block.

For this example no angle short cut is applied.

Type A entry move

With this entrymove type, the tool moves to the offset point of the start point of the next block.

Programmed Path

Start Point

Compensated PathIntersection point of equidistant lines Offset point

Type A Entry Path

Type B Entry Path

Type C Entry Path

Up to threeintermediateblocksin case oftype C entry

dd

d

d

d

Workpiece

Programmed Path

Start Point

Compensated PathIntersection point of equidistant lines Offset point

Type A Entry Path

Type B Entry Path

Type C Entry Path

Up to threeintermediateblocksin case oftype C entry

dd

d

d

d

Workpiece

Programmed Path

Start Point

Compensated PathIntersection point of equidistant lines Offset point

Type A Entry Path

Type B Entry Path

Type C Entry Path

Up to threeintermediateblocksin case oftype C entry

Workpiecedd

d

d

d

Figure 5-54: The three compensation entry move types (overview)

Page 206: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 206/376

It is important to repeat that the path during compensation will be equal for all three move types. The path will maintain the tool one tool radius to the left or right from the programmed path, depending on the active DWRC G-code (G41 to G44).

5.3.5.1 Move Type A Compensation

The type A Compensation is characterized by entry and exit moves which start or end at the offset points. The paths during compensation are not different from the type B or type C compensations. Two machine parameters define which entry or exit move type is used when activating DWRC by one of the four G-codes (41 to 44).

The following pictures show different entry moves. The path ends at the offset point, which is at a right angle on the left or right side of the next programmed move in the active plane. Type A compensation entry moves do not generate any intermediate blocks.

Figure 5-55: Compensation entry moves type A, linear to linear

Page 207: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 207/376

Figure 5-56: Compensation entry moves type A, linear to circular

Figure 5-57: Compensation entry moves type A, circular to linear

Page 208: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 208/376

Figure 5-58: Compensation entry moves type A, circular to circular

The last move before switching off the compensation is done always to the offset point of the endpoint of the last compensated block.

5.3.5.2 Move Type B Compensation

Type B entry moves guarantee that the tool is kept off at minimum one radius from the start point of the first compensated block. The following picture gives some examples.

Page 209: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 209/376

Figure 5-59: Compensation entry moves type B, linear to linear

When circular intermediate blocks are selected (i.e., G46 is modal), then in case of entry move type B only one circular intermediate block is generated. This behavior is shown in its figure below.

Page 210: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 210/376

Figure 5-60: Compensation entry moves type B, circular intermediate blocks

5.3.5.3 Move Type C Compensation

The type C Compensation is characterized by entry and exit moves which start or end at the intersection point of the equidistant lines of the entry move and the first compensated block.

In the following some examples for type C entry moves are shown, where the end or start moves are at the intersection points of the equidistant lines.

Page 211: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 211/376

Figure 5-61: Compensation entry moves type C, linear to linear

Similar to the entry moves, the last compensated block ends at the intersection point of the equidistant lines.

5.3.6 Special Cases

5.3.6.1 Changing compensation direction or sign

In the following the behavior of the control is described when changing the compensation direction (i.e., switching between G41 and G42) within a program. Changing compensation direction can result in the tool crossing over the programmed path as compensation changes from left to right or vice versa.

Move Type A: Setting up the compensation as a new move

When this feature is active, a change in the compensation direction result that the block in which the change is programmed will be treated as an entry block.

Move Type B: No new entry move

In this case, the control generates two points:

Point 1: The final wheel / dresser position before compensation direction is changed. This point is at right angle to the end point of the programmed path offset by one dresser / wheel

Page 212: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 212/376

radius.

Point 2: Dresser / wheel position for the start of the first block using the new compensation direction. The point is at right angle to the start point of the motion block that changes the compensation direction and is offset by one dresser / wheel radius.

5.3.6.2 Non-motion blocks

Non-motion blocks are the blocks without movement information for the axes in the active plane. Such blocks can make it difficult for the control to calculate the compensation path correctly. If the next block is a non-motion block then the compensated path of the current block ends at the offset point of that block.

The NC programmer should avoid usage of non-motion blocks during active DWRC.

Note: Cycle blocks (i.e., blocks that start with * before the N, to identify a special syntax; this syntax is defined in section 6) are not considered non-motion blocks in this situation and can be used during active DWRC with no problem.

Note: Some non-motion blocks cannot change the compensated path if they are programmed between two tangential blocks.

Two examples:

Program block Comment

Compensation direction change in a cycle block

N10 G41 D1 X10 Set compensation left of work piece.*N20 D1=-D1 change sign of the compensation value.

This is not a non-motion block.N30 Y20 Continue with DWRC active

Non-motion blocks between tangential blocks

N10 G41 D1 X10 Set compensation left of work piece.N20 X20 First of two tangential blocksN30 G4 Non-motion blockN40 G4 Non-motion blockN50 Y20 Second of two tangential blocks

Page 213: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 213/376

6 General Cycle Programming 6.1 Introduction

The general cycle programming for the MACHINEMATE allows calculations to be done with parameters that may then be used for the regular NC programming. The syntax of these blocks is different than that of the regular blocks. The cycle blocks can not result in motion like a regular block; the cycle blocks affect only parameter values and, with the use of the IF and GO instructions, the selection of the next NC block to execute.

6.2 Application of Cycle Blocks Using cycle blocks considerably extends the application spectrum of MACHINEMATE, ensuring a clear separation between �normal� programming and cycle programming. Cycle blocks allow the machine tool manufacturer and CNC users to simplify constantly recurring setting-up procedures and quality improvement measures during production and in many cases even to automate such processes.

Above all, technology-adapted operator controls and data inputs can be realized and canned cycles for standard processes such as, cutting, drilling etc. can be provided. It is also possible to generate NC programs with cycle blocks (e.g., by Teach In).

6.2.1 Cycle programming

The cycle programming syntax contains the necessary instructions to access the following tables available in the CNC:

• Length compensations H1-H128

• Path compensations D1-D128

• Part position offsets G54-G59

• P-parameters P1-P1000

• Axis positions (read only)

• Input/output bit (for PLC)

To enable calculation functions to be executed, many calculation operations (basic calculations, root, trigonometric functions, etc.) are available.

Page 214: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 214/376

6.2.2 Integrating Cycle Blocks in an NC Program

The handling of cycle block differs from the handling of "normal" program blocks only in that the character * is placed before the block number.

Example: N30 G1 X... N40 G2 X... *N50... *N60... N70... Thus �normal� program blocks and cycle blocks can be mixed at will. The MACHINEMATE recognizes a cycle block by the preceding asterisk.

During the processing of cycle blocks, the cycle interpreter in the implemented cycle level is activated. If cycle instructions, which do not belong to the implemented cycle level, are used, the error message 259 appears. This must be acknowledged by CONTROL RESET, whereby the program is aborted.

Parameters can also be programmed in the form "=Pxxx" in the NC program, with nearly all types of program words instead of the digit string:

*N100 P20=85000 N110 G0 X=P20 instead of

N110 G0 X85 This assumes that the parameters used at the relevant point in time have the correct value (P20=85000 based on a presetting of 3 decimal places for the X-axis).

Note: The allocation of values to parameters can be made either while setting up in the operating mode DATA (function F4: Modify → F2: Cycle Parameters) or by using cycle blocks in the NC program.

6.2.3 Comments

Cycle blocks can be explained by attaching comments. This is especially important for long-term program documentation. The cycle interpreter recognizes comments by the character /. Everything positioned to the right of this character in the relevant cycle block is not interpreted for the program processing.

Example: *N50... /this is a comment

Page 215: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 215/376

6.2.4 Cycle block syntax

During the programming of cycle blocks, the following instructions, addresses and operations can be used:

Access to CNC table values

Dx Path compensation, x=1, ..., 128 DWx Path compensation wear offset, x=1, ..., 128 Gxa Part position offset, x=54…59, a = axis identification Hx Length compensation, x=1, ..., 128 HWx Length compensation wear offset, x=1, ..., 128 Hxa Length compensation, x=1, ..., 64, a = axis identification HWxa Length compensation wear offset, x=1, ..., 64, a = axis identification Ibx Input bit, x=1 ... 8 Obx Output bit, x=1 ... 8 Px Parameters, x=1 ... 1000 xxxxxxx.xxxxxxxx Constant (typically up to 8 digits) Type and number of compensations available

depend on the control options! Ava Axis set position, a= axis letter A Axis set position, a= axis letter Mva Axis actual position, a= axis letter Ax ASCII parameters, x= 1..20

Calculation operations and functions

= Allocation; e.g., of a numerical value to a parameter - Minus sign +, -, *,: Basic calculations (add, subtract, multiply, divide) <, >, = Comparison operations ABS Absolute value ATN Arc tangent COS Cosine of angle DGR Conversion to degrees INT Conversion to integer MOD Modulus function (remainder) RAD Conversion to radians SIN Sine of angle SQT Square root

General programming instructions

DO Execute instruction, in connection with IF GO Jump instruction to block number IF Conditional instruction /TEXT

Comments in a cycle block

Page 216: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 216/376

Special instructions

SEL Select, additional functions Table 6-1: Cycle programming: parameters and instructions

6.2.5 Basic rules for processing of instructions

The instruction block of the cycle interpreters is modeled on the BASIC programming language. The maximum block length is 128 characters inclusive of the END label and checksum, if preset. Cycle blocks are marked with the symbol * before the block number to identify them.

G10

Precedingblocks

Dynamic blockbuffer

Axis Control

Cycle Interpreter

NC Blocks

G1...

Interpreter process Interpolator process

2

3

1

4

Figure 6-1: Transfer of the NC blocks to the interpolator process

Page 217: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 217/376

The MACHINEMATE processes NC program blocks via block buffers. If the NC program contains cycle blocks in which the complete execution of the preceding positioning instructions must be guaranteed (such as checking an axis position), then a G10 block must be inserted.

Error messages that may appear during the processing of cycle programs can be found in this chapter under "Possible errors".

A NC block first passes through two block buffers in the interpreter process. The first block buffer activates the cycle interpreter as soon as a cycle block is recognized. The interpreter�s block look ahead fills the dynamic block buffer (steps 1 and 2 in the figure above) with non-cycle blocks. The NC blocks arrive in the dynamic block buffer of the interpolator. The interpolator�s execution and removal of blocks (step 3 in the figure above) is separate from the interpreter�s block look ahead.

If a G10 code is programmed, it is recognized in the first block buffer (step 4 in the figure above). The transition of this G10 block to the dynamic block buffer is inhibited, halting the block look ahead on this block. The interpreter�s block look ahead is again enabled only when there are no more blocks in the dynamic block buffer (from the interpreter process to the interpolator process) .

Example: N120 G1 X100 F100N130 G10*N140 P1 = MVX

Explanation:

A G10 block is necessary so block N140 is not processed (which references the current X position) until all NC blocks before it (including N130) are finished.

6.2.6 Numbers and variables

Numbers and variables in different forms can be used within cycle blocks. The following are admissible as numbers:

• Whole numbers between -99999999 and 99999999

• Floating point numbers with a maximum of eight positions before and after the decimal point, whereby only the first seven of the positions entered are significant.

Leading zeros may be written with numbers. If there are no digits after the decimal point, omit the decimal point.

Variables can be used in the form of free and fixed parameters. Free parameters are the P-parameters (P1, P2, etc.). These can be used to store any numbers and to form calculation formulae. Fixed parameters are the CNC parameters (H, D, G, etc.), with which control-specific and machine-specific data can be accessed.

Page 218: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 218/376

Numbers and variables can be combined with calculation operations but the individual number formats used must be compatible.

The P-parameters can be used in "normal" NC blocks instead of numbers. When allocating numbers to parameters using cycle blocks, it must be ensured that the digit string matches the preset number of decimal places of the relevant NC address.

Example: *N50 P1=50000, P2=1000, P3=100 N60 G1 X=P1 Y=P2 F=P3 The N60 block above has the same effect as N60 G1 X50 Y1 F100, when 3 decimal places are preset for the axis values and 0 decimal places for the feed rates.

ASCII parameters A1, A2, ..., A20 The 20 ASCII parameters are used in a similar way to the P-parameters. The ASCII codes 0 to 255 can be allocated to the individual parameters as values. Values exceeding the value range are not recognized. ASCII parameters can be indexed by P-parameters. See the following three examples.

Example: *N100 A1=65, A2=66, A3=67

The addresses A, B, and C are allocated as ASCII values to the ASCII parameters A1, A2 and A3.

Example: *N100 A1=65, P1=2

*N110 A2=A1+P1

A1 takes the ASCII value of the address A; P1 takes the numerical value 2. A2 takes the ASCII value of A1 that has been increased by 2 (the ASCII value of the address C).

Example: *N200 IF A1=A2 DO P30=0

If the ASCII values of A1 and A2 are the same, then set parameter P30 to 0.

6.2.7 Calculation operations and functions

The following notes and list apply to calculation operations applicable to the parameter cycles.

• The parameters Px, Py and Pz represent arbitrary constants and variables when they stand to the right of the = sign.

• The angle data for SIN, COS, ATN is given in radians. With an expression with several calculation operations the processing is done from left to right, whereby

Page 219: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 219/376

any preceding negative signs are always associated with the concerned number or variable and are not seen as calculation operations.

• Brackets or parentheses are not allowed (performed left-to-right).

• Several expressions can be written in a program block if a comma separates them.

Px = Py Allocation Px receives the value of Py Px = Py+Pz Addition Px = sum of Py and Pz Px = Py-Pz Subtraction Px = difference of Py and Pz Px = Py * Pz Multiplication Px = product of Py and Pz Px = Py: Pz Division Px = quotient of Py and Pz Px = ABS Py Absolute value Px = absolute value of Py Px = ATN Py Arc tangent Px = Arc tangent of Py Px = COS Py Cosine Px = Cosine of Py Px = DGR Px Degrees Px is converted from radians to degrees Px = INT Py Round Px = rounded integer value Px = RAD Px Radians Px is converted from degrees to radians Px = SIN Py Sine Px = sine of Py Px = SQT Py Square root Px = root from Py Px = Py MOD Pz Modulus function Px = remainder of the division Py: Pz

Table 6-2: Calculation operations and functions

Example: *N10 P1=5, P2=2 *N20 P3=P1+P2 In N10 the value 5 is assigned to P1 and the value 2 to P2. In N20 the sum of P1 and P2 is formed and assigned to P3. The value 7 is therefore stored in P3.

Example: *N10 P1=4 *N20 P1=SQT P1 In N10 the value 4 is assigned to the parameter P1. In N20 the square root of 4 is calculated, and P1=2.

Example: *N10 P1=3.141593 *N20 P1=COS P1 In N10 the value 3.141593 is assigned to the parameter P1. In N20 the cosine of P1 is calculated and P1= -1.

Example: *N10 P1=90 *N20 P2=RAD P1 *N30 P2=SIN P2 The value 90 is assigned to the parameter P1 in N10 and in N20 is converted into radians so that N30 supplies the result P2=1.

Page 220: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 220/376

Example: *N10 P1=1 *N20 P2=ATN P1 *N30 P2=DGR P2 In N20, P2 has the value 0.7853982 (Radians). In N30 this value is converted to degrees. The result is that P2=45.

Example: *N10 P1=60 *N20 P1=RAD P1 *N30 P1=SIN P1: COS P1 *N40 P1=ATN P1 *N50 P1=DGR P1 In N10, a value is assigned to P1. This value is converted in N20 to radians. In N30 the tangent (sine/cosine) is calculated. In N40 the arc tangent of this is calculated. In N50 this result is converted to degrees, so that P1 receives the value 60 again.

Example: *N10 P1=-12.9 *N20 P1=ABS P1 In N10 the value -12.9 is assigned to P1. In N20 the absolute value is formed from this value, i.e., P1=12.9

Example: *N10 P1=1.495, P2=3.55, P3=-3.5 *N20 P1=INT P1, P2=INT P2, P3=INT P3 In N10 the value 1.495 is assigned to P1, the value 3.55 to P2 and the value -3.5 to P3. In N20, P1 has the value 1, P2 has the value 3 and P3 have the value -3. The operation INT converts a floating point number to an integer by rounding down.

Example: *N10 P1=13 *N20 P2=5 *N30 P3=P1 MOD P2 The result is 3, since P1:P2 = 13:5 = 2 remainder 3.

Example: *N10 P1=-13 *N20 P2=5 *N30 P3=P1 MOD P2 MOD calculates the positive remainder to the next smallest whole multiple of P2 and the result is 2.

Example: *N10 P1=5 *N20 P2=7 *N30 P3=3

Page 221: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 221/376

*N40 P4=P1 + P2 MOD P3 The result in P4 will be 0 because of the order of operations as always right to left. The evaluation order is first 5+7 and then the MOD 3. In order to avoid compatibility problems, cycle blocks should always be written so that this evaluation is clear. Sometimes the clearest programming is through the use of several blocks.

6.2.7.1 Operation sequence

When calculating operations, attention must be paid to the sequence of the individual operations. Operations are processed from left to right. The following examples help to explain the rules for calculating operations.

All the following examples use P1=30, P2=100, P3=RAD P1, P4=2, P5=4, P6=3.

Example: *N20 P10=P1 *-P2

In usual notation:

P10 = P1 * (- P2) = -3000

Example: *N30 P10=-P1 *-SIN P3+-12

In usual notation:

P10=-P1 * (-SIN P3) + (-12) =-30 * (-SIN 0.524)-12=3

Example: *N40 P10=P1+P2+SIN P3

In usual notation:

P10 = 30 + 100 + SIN 0.524 = 130.5

Example: *N50 P10=SIN P3

In usual notation:

P10 = SIN (RAD P1) = SIN 0.524 = 0.5

Example: *N60 P10=12+P1

In usual notation:

Page 222: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 222/376

P10 = 12 + 30 = 42

Example: *N70 P10=P1+P2 * SIN P3-18.3

In usual notation:

P10 = ((P1 + P2) * SIN P3)-18.3 = 46.7

Example: *N80 P10=P1+P2 * P4+SQT P5 * P6

In usual notation:

P10 = (((P1 + P2) * P4) + SQT (P5)) * P6 = (((30 + 100) * 2) + SQT (4)) * 3 = 786

Example: *N90 P3=4, P3=SQT P3+P3+2 *N95 P3=4, P3=SQT P3, P3=P3+2 The calculation in N90 gives P3=8, the calculation in N95 gives P3=4. This is because Result variables are only changed at the end of each complete calculation operation.

6.2.7.2 Possible calculation errors

If calculation errors occur it is generally because of the following:

• Division by zero

• Root of a negative number

• Overflow: Number > 99999999

• Spelling errors (e.g., P1=SON P1)

• Index too large (e.g., P1=6000, PP1=3 and only 1000 parameters set-up)

6.2.8 Use of P-parameters

In the standard equipment 1000 P-parameters (P1, P2, up to P1000) are available. If a numerical value is assigned to a parameter during the execution of a cycle program, then this value is retained until a new value is assigned to this parameter. This value also remains stored when the CNC is switched off.

P-Parameters can be programmed in NC blocks instead of numerical values. The current numerical value, which is momentarily stored under the respective parameter number, is first assigned to the parameter during processing when the relevant NC

Page 223: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 223/376

block is processed. It is possible to change the parameter values during installation in the operating mode DATA or in the NC program through cycle blocks.

P-Parameters can be combined with all available calculation operations (see examples in the previous chapter).

6.2.8.1 Technological or machine values

If technological values are stored in P-parameters (e.g., axis coordinates such as lengths or angles, feed rates or rotational speeds) then the numerical values also fundamentally contain the preset fixed decimal places. The number of decimal places is determined by the machine tool manufacturer machine parameters.

Example: The resolution for linear movement is one thousandth of a millimeter (3 decimal places).

*N70 P12=50500, P13=1000 N80 G1 X=P12 Y=P13 F=P13

The line N80 is equivalent to:

N80 G1 X50.5 Y1 F1000

With a machine parameter change in the control configuration, it is also possible for the parameters to take their intended values, so there is no decimal point shifting required, so N70 could be P12=50.5,P13=1.0 and N80 would result in the same execution except that F=P13 would be F1. This manual assumes the default setting for cycle parameters which means this �no decimal point� programming is active.

6.2.8.2 Indexed P-parameters

The indexed parameter is recognized by the notation double-P. PPx designates the parameter whose number is positioned in Px.

Example: *N10 P1=5, PP1=7

The cycle block produces P5=7.

Note: When using indexed parameters it must be ensured that the index parameter (e.g., P1 with PP1) contains a meaningful value; otherwise the error message 262 is output. A parameter used as an index may not be indexed itself (because indexing of indexes is not possible).

Page 224: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 224/376

6.2.8.3 Reserved parameters

The first 200 parameters can be used to easily communicate to the PLC. Therefore, we recommend that the first 200 parameters be reserved for that purpose.

A contiguous block of 50 parameters is reserved for special functions. The location of this reserved parameter block can be preset using a machine parameter. The default location is P10-P59. Refer to the control manufacturer's documentation.

Important: For reasons of safety, the 50 reserved parameters should not be used for other purposes. Since the default start of this block is parameter 10, practically the first 60 cycle parameters are not available for user applications (with the first 10 being used for the canned drilling cycles). The following list contains the assignment of some reserved parameters to the corresponding special functions; the remaining reserved parameters are intended for more specific purposes or for future expansions. (For each, the value of x is the number of the first reserved parameter, whose assignment is carried out by setup data).

Parameters Assignment/meaning P (x+0) reservedP (x+1) reserved

P (x+2) Contains start parameter number for SEL:80for the set of 15 active G-codes

P (x+3) toP (x+7)

Reserved

P (x+8) 0, if CONTROL RESET was triggeredP (x+9) 0, if operating mode memory or DATA chosenP (x+10) 0, if CONTROL RESET was triggered manuallyP (x+11) toP (x+18)

Analog value read in with SEL:61 - SEL:68for A/D channel 1 to channel 8

P (x+19) toP (x+20)

Reserved

P (x+21) toP (x+23)

Analog value output with SEL:71 - SEL:73for D/A channel 1 to channel 3

P (x+24) toP (x+49)

User cycle parameters (one for each letterin the work cycle block)

Table 6-3: Reserved cycle parameters

The user cycle parameters (at the end of the table above) allow the programmer to access the NC statement fields within a work cycle, where the value with each letter in the block is passed to its corresponding cycle parameter.

For example, if the code G920 is assigned to be the first work cycle and its work cycle subprogram is assigned to be 900001, then this subprogram can interpret the values provided with the work cycle G-code. A statement of N1G920 (assuming the default assignment for the reserved parameters is starting at P10, so �x� in the table is 10) results in P47 having a value of 1 (since N is the 14th letter of the alphabet and with an A value going to P34 so the N value goes to P47) and P40 having a value of

Page 225: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 225/376

920 (since G is the 7th letter). The work cycle must recognize that the number of decimal places for the particular parameter affects the user cycle parameter values. A statement of N1G920Z5.5 where Z has 4 decimal places results in P59 having a value of 55000 in the work cycle. However this does not prevent the work cycle from directly passing on axis commands since a subsequent statement in the work cycle of N20Z=P59 would move Z to 5.5 as expected (if G90 is modal), as described in section 6.2.2.

A letter that is not present in the work cycle block will be given an invalid value, approximate 1 x 10^308. Typically, the work cycle subprogram monitors for letters that are not present by checking for a large number, like this

*N100 IF P34>99999999 GO 200

Where the work cycle will jump ahead to block N200 if the letter A (whose value goes to P34) is missing with the work cycle G-code.

6.2.9 Use of CNC parameters

6.2.9.1 Summary of the CNC parameters

Dx Path compensation, x = comp number (1-128)DWx Path compensation wear offset, x = comp number

(1-128)Hx Length compensation, x = comp number (1-128)HWx Length compensation wear offset, x = comp

number (1-128)Hxa Length compensation, x = comp number (1-64),

a = axis letterHWxa Length compensation wear offset, x = comp

number (1-64), a = axis letterGxa Part position offset, x = 54-59, a = axis

letterIBx Input bit from PLC, x = 1 to 8OBx Output bit to the PLC, x = 1 to 8a Read current axis position, a = axis letterAVa Read current axis position, a = axis letterMVa Read current axis position (including any

following error), a = axis letter

Table 6-4: Summary of CNC data as cycle parameters

The number of available H and D compensations depends on whether the corresponding option is available.

The allocation of values to these CNC parameters (e.g., *N200 H1X=12) causes a table entry to be updated in the length compensation 1 for the X-axis. Thus an already existing entry, which could have come from the tool presetter, is overwritten (the above value corresponds to 0.012 mm for example with G71 modal). Numerical

Page 226: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 226/376

values within the CNC parameters can also be replaced by P-parameters (without indexing).

Example: *N300 P1=5 *N310 HP1X=22 HP1X is equivalent here to H5X.

6.2.9.2 Length compensation Hx, Hxa

Up to 128 H-compensations can be set or read with the parameters Hxa. If only one compensation axis is available, then the parameters are H1, H2, ... H128. If there are two compensation axes, the parameters are H1X, H2X and H1Y, H2Y etc., depending on which axes are set up. The wear compensation values are also available to read or write. If only one compensation axis is available then the wear parameters are HW1, HW2, � HW128. If there are two compensation axes, the parameters are H1X, H2X and H1Y, H2Y etc., up to 64 sets, with the axis letters depending on which axes are set up (with the accompanying wear offset parameters as HW1X, etc.).

Example: *N10 H1=P1

Entry of an H-compensation is possible like this when the H-table is configured for only one axis. The H-table compensation 1 takes the value of P1.

Example: *N10 H1Y=P1

Entry of the H-compensation for the Y-axis if H-compensation is defined for 2 axes.

Example: *N10 P2=1 *N20 HP2X=12

Allocation of the value 12 (increments) to the H-compensation 1 of the X-axis.

6.2.9.3 Path compensation Dx

Up to 128 D-compensations (D1, ..., D128) can be set or read with the parameters Dx. The wear compensation values are also available to read or write with the parameters DW1 to DW128.

Example: *N10 P1=D12

Page 227: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 227/376

*N20 D120=P20

Storage of the compensation value D12 in the parameter P1 (N10) and assignment of the compensation value D120 with the content of the parameter P20 (N20).

Example: *N30 P1=5 *N40 DP1=18400

The result of the indexing in N40 is D5 = 18 400. The compensation value stored in D5 is 18.4 mm when G71 is model (would be 1.84 inches with G70 modal). The code DR is used to reference the dresser wheel orientation in the D-table.

6.2.9.4 Part position offset Gxa

Six part position offsets (G54-G59) are available per axis. The axis address (e.g., X, Y, and Z) must always be indicated here. The compensation number can also be given here via the P-parameter.

Example: *N100 G54Z=53000, G54X=0, G54Y=0, P1=54 N110 G=P1

N100: Table entry and N110: Activate G54 offset of Z = 53 mm.

6.2.9.5 Input/output bits (cycle byte) OBx, IBx

For the programming of parameter cycles a standard interface of 2 sets of 8 bits are available for the communication with the machine PLC. The following notation is used:

• IB1-IB8 stands for: read PLC interface input bit 1-8, IN_CYCB_01

• OB1-OB8 stands for: write PLC interface output bit 1-8, ON_CYCB01.

• The bit number can also be given via parameters (e.g., IBPX). Upon execution, a test is made on the value stored in the parameter. For values smaller than 1 or larger than 8, the error message 262 appears.

IBx is only admissible in expressions after IF (e.g., IF IB1=1 GO 50); direct allocation to parameters (e.g., P1=IB1) is not possible. In the latter case the error message 261 appears.

The output bits 1-8 are set to 0 at CONTROL RESET. It can however be set that the output bits retain their values at CONTROL RESET in the PLC.

Page 228: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 228/376

Example: *N30 OB3=1

The output bit 3 is set to 1.

Example: *N30 IF IB2=0 DO...

The input bit 2 is scanned to see if it contains 0.

Example: *N30 P5=P2 MOD 8+1, OBP5=0

A value is assigned to the parameter P5 between 1 and 8, and then the corresponding output bit is set to 0.

Example: The following cycle block causes the execution to wait until the bit 3 in the PLC interface is set to 0 by the PLC:

*N230 IF IB3 >0 GO 230 *N240... /here the PLC has set the bit 3 to zero

Input bits and output bits can only have the values 0 or 1. Values not equal to 1 are treated as 0 during the allocation. Reading and describing the PLC interface is meaningful for some applications, for example:

• Using measuring probes and other measuring devices

• Scanning the page at part tables

• Overwriting the feedrate by PLC

6.2.9.6 Current position of axes

The current set positions of the axes can be directly assigned to parameters. These values are always in machine coordinates, so if an axis position is offset by G92 or by the part zero offsets (one of G54 to G59), the axis position will still be in machine coordinates.

The axis letter can be used to obtain the current programmed position for the axis. The symbol AVx, where x is the letter of the axis, will also get the current programmed position. The symbol MVx, where x is the letter of the axis, will get the current axis position (its commanded position with any following error that is present).

Example: *N250 P1= AVx, P2= AVy

Page 229: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 229/376

*N260 P3= X The current set position of the X-axis (without following error of the position control) is stored in the parameter P1, the current set position of the Y-axis is stored in parameter P2 and the current set position of the X-axis is stored in parameter P3.

6.2.10 Conditional instructions and jump instructions

As with many other programming languages conditional codes can also be programmed for the parameter cycles. This entails the use of the IF question to test for a state and the execution of a following action based on the result of the question (via the DO instruction or GO instruction).

6.2.10.1 IF Question

Example: It is desired to execute the calculation P2=P1 * 2 if P1=5:

Question Action state *N10 IF P1=5 DO P2=P1 * 2

• If the condition is satisfied, the subsequent instruction from "DO" to the end of the block is executed.

• If the condition is not satisfied, all instructions located between "DO" and the end of the block are jumped over.

• A question is made up of two operands between which a comparison operator is positioned. P-parameters, CNC parameters or numbers can represent operands.

The following characters can be used as comparison operators:

= : equal to > : greater than < : less than

An action can be made up of a jump instruction (GO) or an End symbol (DO) followed by one or more cycle instructions, where DO only has an effect on the current block.

6.2.10.2 Jumps

The jump instruction GO block number causes the program to jump to the NC block with the corresponding block number. It operates as a conditional instruction (with IF) and as an unconditional instruction (without IF). If the NC block which is programmed as a jump destination is not found, the error message 69 appears.

Page 230: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 230/376

Example: *N10 GO 200

This is an unconditional instruction. It causes the program processing to be continued at block N200.

Example: *N10 IF P1=30 GO P1

This is a conditional instruction. If the parameter P1 has the value 30, a jump is executed to N30.The block number can be given either as an absolute number or via parameters.

Example: *N10 GO 200

or *N10 P1=200 *N20 GO P1

or *N10 P1=200 *N20 P2=1 *N30 GO PP2

All three previous examples result in a jump being made to block N200. For this function it is important that block numbering in ascending order is kept or is guaranteed by the editor. It is possible to jump to either a higher or a lower block.

Note: With MDI (manual data input), no jump instructions may be used.

6.2.10.3 Loops

Loops can be programmed using the IF instruction together with GO. The number of loop passes can be determined by a P-parameter.

Example: *N50 P1=10 N60� N70... N80... N90... . . . *N140... *N150 P1=P1-1, IF P1 > 0 GO 60 ... Explanation:

Page 231: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 231/376

N50: 10 loop passes are defined

N60-N140: This program part is to be repeatedlyexecuted.

N150: Jump to block N60 if P1 is greater thanor equal to 0.

The programming becomes even more flexible by the use of indexed parameters together with loops (see next example).

Example: All parameters from P1 to P800 are to be set to zero.

� *N100 P1=800 *N110 PP1=0, P1=P1-1, IF P1 > 0 GO 110 *N120 P1=0 ... P1 is used as an index. The line N110 is repeated 799 times.

6.2.11 Possible errors

The most important error messages, which can appear during the cycle programming are listed below together with notes on causes of errors and their removal.

6.2.11.1 Error message No. 260

Cycle error in block No. ____, Key word incorrect

Error Recognition: By the syntax-test

• After editing a block

• By running in test mode

Possible causes of error: • Non-admissible operator or start of key word

• Point used where it is not allowed

• Too many digits before or after the decimal point

• Index too large

• False axis address

Error removal: Correct the cycle block

Page 232: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 232/376

Example: HXP1 instead of HP1X

6.2.11.2 Error message No. 261

Cycle error in block No. _____, Instruction incorrect

Error recognition: By the syntax-test

• After editing a block

• By running in test mode

Possible causes of error: The composition of key words does not produce a cycle block.

Error removal: Correct the cycle block.

Example: • N20 P1=IB1 instead of *N20 IF IB1=P1 DO...

6.2.11.3 Error message No. 262

Cycle error in block No. ____, Index too large/small

Error recognition: By execution when using a parameter as index

Possible causes of error: Index too large or too small

Error removal: • Index as number (not as parameter): check syntax

• Index as parameter: examine parameter value

6.2.11.4 Error message No. 263

Cycle error in block No. ____, Parameter content incorrect

Error recognition: By execution

Page 233: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 233/376

Possible causes of error: • Division by zero

• Root of a negative number

• Integer overflow

• Integer underflow

Error removal: • Examine parameter value

• Correct program

6.2.12 Instructions

6.2.12.1 Instruction: IF < comparison > < action >

Function: Conditional instruction

Description: If the comparison is satisfied, the programmed action is executed. In the question two operands (parameters, input bits or constants) are combined with a comparison operator. Possible comparison operators:

= is equal to > is greater than < is less than

Table 6-5: IF comparison operators

Description: An IF instruction will always be followed by one of these two instructions:

GO instruction, [instruction], ...

DO instruction, [instruction], ...

Example: *N10 IF P1 > P2 GO 100

If the parameter P1 contains a value larger than P2, jump to block N100.

Example: *N20 IF P1=P2 DO P1=10

Page 234: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 234/376

Explanation: If the parameter P1 contains the same value as P2, set P1=10.

6.2.12.2 Instruction: GO < block-no. >

Function: Jump to the block number

Description: The processing of the NC program is to be continued at the block number indicated. Use together with IF instruction as a conditional jump or without IF as an unconditional jump.

Example: *N50 GO 210

Jump to program block N210.

Note: No jumps may be programmed in MDI. If the jump destination is not found, error message 69 is given.

6.2.12.3 Instruction: DO < instruction>

Function: �Execute!�

Description: The relevant instruction is to be executed. DO is used only with an IF instruction.

Example: *N60 IF P1=0 DO P1=10, P2=1

Explanation: If the parameter P1 contains the value 0, set it to the new value 10. Parameter P2 is then set (independently) to 1.

6.2.12.4 Instruction: SEL < instruction>

Function: �Select a function�

Description: The selected function is to be executed.

Parameters:

Page 235: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 235/376

nn identifies the special function to select

SEL: 0 Deactivation of all SEL-special functions SEL: 10 Parameter transformation OFF SEL: 11 Parameter transformation ON SEL: 61-68 Read in analog value via channel 1 to 8 of the AD-board to

its cycle parameter (one per AD channel) SEL: 70 Switch off DA-Output SEL: 71 Request for DA-output for channel 1 of the DA-board from

its cycle parameter (one per DA channel) SEL: 72 Request for DA-output for channel 2 of the DA-board SEL: 73 Request for DA-output for channel 3 of the DA-board SEL: 80 The active G-codes of the 15 G-code groups are copied to

15 parameters. The number of the first of the 15 parameters used for this is placed in the reserved parameter area at P (x+2).

Table 6-6: Summary of cycle block SEL functions

Please reference table 6-3 for the relevant cycle parameters for these respective SEL function selections.

Example: SEL: 80 *N110 P192=10 *N120 SEL: 80 ... It is assumed for this example that the reserved parameter area starts at parameter 190. In block 120 the active G-codes of the 15 groups are written in the parameter table starting from the parameter number determined by the setting of P192 (x+2, where x is the start of the special reserved block of 50 parameters), written in block 110. In this case, the parameters P10 to P24 are used because the value of 10 is used in the (x+2) parameter.

To enable the part program for A/D or D/A access (i.e., SEL:nn is 61 to 73), there is a machine parameter in the control configuration that must be properly set up defining which cycle parameter is used for the input from the A/D or for the output for the D/A (see 6.2.8.3 for information about this block of cycle parameters).

Page 236: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 236/376

6.3 Work Cycles

6.3.1 General notes

Up to 8 user-defined work cycles can be created. Their configuration consists of 1) defining the first of the set of 8 G-codes and 2) defining the subprogram number for each G-code (since they are specified individually these numbers do not have to be consecutive). The part program calls these work cycles by their G-code.

Parameters from A to Z can be passed from these cycles where the values are stored in the Reserved Parameter area from P34 to P59 (by default; this area can be assigned to a different set of cycle parameters). These user cycle parameters are described in section 6.2.8.3.

These work cycles are G-codes that invoke specific subprograms. The work cycles are not drilling cycles, which have a modal behavior (i.e., within a drilling cycle each axis move block results in another drilling cycle until the G80 cancels the cycle). The work cycles run only once, when invoked by its G-code in an NC statement.

6.3.2 Example

If the first work cycle G-code is defined to be 920 and the first work cycle subprogram is defined to be P900001, then a part program statement like N10G920X1.1Z3.3 will immediately call the subprogram P900001, with the parameters within that NC statement.

Within the subprogram P900001, the cycle parameters can be checked for values and then processed. If the letter is not present in the statement, then the cycle parameter is given a very large (nearly infinite value) value of about +1.2345E+308. This behavior allows the work cycle to react to the presence or omission of any letters within the NC statement. For example, if the letter A is assumed to have 3 decimal places then a field of A4 with the G920 results in P34 having a value of 4000.

Page 237: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 237/376

7 Drilling Cycles 7.1 Introduction

The programming of drilling processes can be simplified using the drilling cycles. The available selection of drilling cycles covers the most important standard cases. The programmer only has to define a few parameters in order to adapt the drilling cycles to a particular application.

The cycle programming of the cycle level 1 must used for the drilling cycle parameters.

The drilling cycles are recognized as independent subroutines in a protected area of the NC part program memory with the program numbers P999981 to P999989. However, their call is made in a simplified form through G-codes G81 to G89. The drilling cycles cannot be changed or cancelled.

The machine tool manufacturer can change the program sequence in the individual drilling cycles if required. Refer to the control manufacturer's documentation to determine if this is the case.

Call and set-up of the drilling cycles are modeled according to DIN 66025.

Note: G-Codes and program numbers for work cycles can be preset and thus could have been changed by the machine tool manufacturer. For details about this, please refer to the machine tool manufacturer's documentation. This description of the drilling cycles however is based on the default values for G-codes (G80-G89) and program numbers (P999981-P999989).

Page 238: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 238/376

7.2 Use of the drilling cycles A drilling cycle in an NC part program is always programmed in the following steps:

• Allocate the parameters

• Select the desired drilling cycle

• Move to the drilling position in X and Y (once or repeatedly)

• Automatically call up and execute the selected drilling cycle after reaching the drilling position

• Deselect the drilling cycle

7.2.1 Allocation of the parameters/definition of terms

• Before a drilling cycle is selected, feed rate, spindle speed and the parameters with the geometric data of the respective drilling cycle must be programmed. Specific parameters are for example motion distances and dwell times. The drilling cycles use the parameters P1 to P15. Always allocate the correct parameters to the corresponding drilling cycle.

• If not all parameters are allocated with values, no error message is output. Within the drilling cycle all parameters which are necessary are used unchecked. Error messages due to incorrect or non-allocated parameters can first appear during the execution.

• The reference plane lies at the safety clearance above the work piece surface. Above this plane it is possible to move vertically in the rapid traverse. Below this plane, rapid traverse is only possible in the Z+ direction (or away from the work piece). The feed movements start from the reference plane. See Figure 7-1.

• The retract plane is the plane to which the spindle moves at the end of the drilling cycle. The spindle is then at the position to move between holes. See Figure 7-1.

• The final hole depth is obtained from the measuring point of the tool. For example, this is the drill tip for a twist drill or an arbitrary point on the top surface for a machine reamer. See Figure 7-1.

• The cycle parameters are assigned values based on no decimal points. The cycle parameter value must consider the number of decimal places for the particular parameter.

Page 239: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 239/376

If a cycle parameter is given a dimension in inches (usually 4 digits after the decimal point), then the dimension is multiplied by 10,000. For example, a final hole depth of 1.25 inches would be defined with a cycle parameter value of 12500.

If a cycle parameter is given a dimension in millimeters (usually 3 digits after the decimal point), then the dimension is multiplied by 1000. For example, a final hole depth of 1.25 mm would be defined with a cycle parameter value of 1250.

If a cycle parameter is given a value for time in milliseconds but the F word provides time in seconds (usually 3 digits after the decimal point), then the value as seconds is multiplied by 1000. For example, a dwell time of 0.25 seconds would be defined with a cycle parameter value of 250.

Retract Plane

Reference Plane

Final hole depth

Figure 7-1: Reference plane, retract plane and final hole depth

Each drilling cycle description includes an example of NC blocks, a figure illustrating the steps of the cycle and a description of the sequence. Each figure shows where the Z-axis zero-plane is (at the left of the part), to help identify the respective parameters values in the sequence.

Page 240: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 240/376

7.2.2 Selection of the desired drilling cycle

By programming the G-codes G81 to G89 the corresponding subroutine is selected. The cycle itself is first selected automatically after the positioning of the X or Y-axis (see below). The feed-in of the drilling cycles is always made in the Z direction.

Note: After termination of the drilling cycle with G80, the G00-code (linear interpolation in the rapid traverse) is always active. If destination point coordinates are programmed in a following NC block without a G-code, then a move to these points is made in the rapid traverse.

No drilling cycle is performed on the block with the G81 to G89 unless the block also contains an X or Y coordinate. If X or Y is in the G8x block then that axis motion will occur before the actual drilling cycle at that X/Y position. With no X or Y in the block the first execution of the drilling cycle occurs on the next block having an X or Y command (see the example below).

7.2.3 Move to the drilling position in X and Y (once or repeatedly)

A drilling cycle is independently called up after each positioning of the X or the Y-axis as long as it has been selected. This is true as long as one of the following G-codes is modally effective:

G00 Linear interpolation in the rapid traverse

G01 Linear interpolation in the feed rate

G02 Circular or helical interpolation with specified center point in the clockwise direction

G03 Circular and helical interpolation with specified center point in the counter-clockwise direction

G07 Tangential circular interpolation

G12 Circular or helical interpolation with specified radius in the clockwise direction

G13 Circular or helical interpolation with specified radius in the counter-clockwise direction

G33 Thread cutting, constant rise

G34 Thread cutting, variable rise

Note: Drilling cycles cannot be used during modally effective G06 (spline interpolation).

Page 241: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 241/376

Example: N30 G1 F1000 S500*N40 P2=500000, P3=420000*N50 P10=600000, P4=1000N60 G82N70 X20 Y20N80 X40 Y70N90 G80N100...

The definitions of the parameters are created in the program blocks N40 and N50. These definitions are used in the subsequent cycle (NC subroutine). In N60 the drilling cycle G82 is activated (spot facing with dwell time). The drilling cycle is first processed after the position programmed in N70 is reached. G00 (rapid traverse) is effective after the termination of the drilling cycle. The following NC block causes a further processing of the drilling cycle at a new X/Y position. The cycle is deactivated again with the instruction G80.

The above program was running in G70 (inch mode). In that context, N40 assigned the reference plane (P2) to 50.0 inches and the final hole depth (P3) to 42.0 inches. N50 assigned the retract plane (P10) to 60.0 inches and the dwell (P4) to 1 second (or 1000 milliseconds). N70 performed the cycle at X of 20.0 inches and Y of 20.0 inches. N80 performed the cycle at X of 40.0 inches and Y of 70.0 inches.

If the above program was run in G71 (metric mode), then N40 assigned the reference plane (P2) to 500.0 mm and the final hole depth (P3) to 420.0 mm. N50 assigned the retract plane (P10) to 600.0 mm and the dwell (P4) to 1 second (or 1000 milliseconds). N70 performed the cycle at X of 20.0 mm and Y of 20.0 mm. N80 performed the cycle at X of 40.0 mm and Y of 70.0 mm.

Page 242: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 242/376

7.2.4 Deselecting of the drilling cycle

An activated drilling cycle is deselected either by the program word G80 or by calling up another drilling cycle.

Note: No motion occurs during the G80 block unless it also contains an axis coordinate. If the G80 block contains an X or Y coordinate the G80 occurs first (canceling the drilling cycle). If an axis command is in the G80 block then that axis motion will occur after the drilling cycle is cancelled. That axis motion with the G80 is never part of the previous drilling cycle.

When using the G-codes G80-G89 to call up drilling cycles, the following overlapping with other functions exist:

• 5-axis transformation

• Corner jump, contour accuracy (Look Ahead)

• Activation of positioning axes

If one or more of these functions are available in your control configuration, then other G-codes must have been assigned by the machine tool manufacturer either to these functions or to the call up of drilling cycles. For further information about this, please refer to the control manufacturer's documentation.

As a consequence of programming drilling cycles as NC subroutines, the execution of the drilling cycles is limited to one main and four subroutine planes. Thus, drilling cycles cannot be executed from the 4th subroutine plane outwards. However, an execution from the main program plane or from the 1st to 3rd subroutine planes is possible. The execution (the implicit subroutine call up) is made after the programmed positions have been reached.

Page 243: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 243/376

7.3 G80 Cancel the drilling cycle Syntax: G80

The function drilling cycles is deselected with the program word G80. Positioning instructions following G80 therefore cause no more cycle call up for that drilling cycle.

7.4 G81 Drilling to final depth Syntax: G81

The program word G81 selects the drilling cycle drilling to final depth. The feed values and rotational speeds defined in the NC program are used in the drilling cycle. The following three parameters must be defined before calling up this cycle:

P2 Reference plane, absolute Z coordinate

P3 Final hole depth, absolute Z coordinate

P10 Retract plane, absolute Z coordinate

Example:

...*N40 P2=25000, P3=10000*N50 P10=30000N60 G81N70 X10 Y15N80 G80N90 ...

The above program was running in G70 (inch mode). In that context, N40 assigned the reference plane (P2) to 2.5 inches and the final hole depth (P3) to 1.0 inches. N50 assigned the retract plane (P10) to 3.0 inches. N70 performed the cycle at X of 10.0 inches and Y of 15.0 inches.

Page 244: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 244/376

Figure 7-2: Drilling cycle G81

Sequence of drilling cycle G81: 1. Rapid traverse in the Z direction to the reference plane (P2).

2. Drill to the final hole depth (P3) using the current feed rate.

3. Pull out in rapid traverse to the retract plane (P10).

Page 245: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 245/376

7.5 G82 Spot facing with dwell time Syntax: G82

The program word G82 selects the drilling cycle spot facing with dwell time. The feed values and rotational speeds defined in the NC program are used in the drilling cycle. Four parameters must be defined before calling up this cycle:

P2 Reference plane, absolute Z coordinate

P3 Final hole depth, absolute Z coordinate

P4 Dwell time in ms

P10 Retract plane, absolute Z coordinate

Example: N30 ...*N40 P2=25000, P3=10000*N50 P4=1000, P10=30000N60 G82N70 X10 Y15N80 G80N90 ...

The above program was running in G70 (inch mode). In that context, N40 assigned the reference plane (P2) to 2.5 inches and the final hole depth (P3) to 1.0 inches. N50 assigned the dwell (P4) to 1 second (or 1000 milliseconds) and the retract plane (P10) to 3.0 inches. N70 performed the cycle at X of 10.0 inches and Y of 15.0 inches.

Page 246: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 246/376

Figure 7-3: Drilling cycle G82

Sequence of drilling cycle G82: 1. Rapid traverse in the Z direction to the reference plane (P2).

2. Drill to the final hole depth (P3) using the current feed rate.

3. Wait for the dwell time (P4) to elapse before breaking contact with work piece.

4. Pull out in rapid traverse to the retract plane (P10).

Page 247: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 247/376

7.6 G83 Deep hole drilling Syntax: G83

The program word G83 selects the drilling cycle deep hole drilling with shaving removal. The feed values and rotational speeds defined in the NC program are taken over in the drilling cycle. Seven parameters must be defined before calling up this cycle:

P1 First delivery, incremental value

P2 Reference plane, absolute Z coordinate

P3 Final hole depth, absolute Z coordinate

P4 Dwell time in ms

P5 Further feed-in, incremental value

P6 Safety clearance, incremental value

P10 Retract plane, absolute Z coordinate

Example: N30...*N40 P1=12500, P2=25000*N45 P3=2500, P4=1000*N50 P5=5000, P6=2500*N55 P10=30000N60 G83N70 X10 Y15N80 G80N90...

The above program was running in G70 (inch mode). In that context, N40 assigned the first delivery plane (P1) to 1.25 inches and the reference plane (P2) to 2.5 inches. N45 assigned the final hole depth (P3) to 0.25 inches and the dwell (P4) to 1 second (or 1000 milliseconds). In that context, N50 assigned the further feed increment (P5) to 0.5 inches and the safety clearance increment (P6) to 0.25 inches. N55 assigned the retract plane (P10) to 3.0 inches. N70 performed the cycle at X of 10.0 inches and Y of 15.0 inches.

Note that the parameter P14 is used during this canned cycle for the calculation of the intermediate Z depth. P14 is treated as a temporary variable and its value is never maintained from before to after the drilling cycle.

Page 248: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 248/376

Figure 7-4: Drilling cycle G83

Sequence of drilling cycle G83: 1. Rapid traverse in the Z direction to the reference plane (P2).

2. Drill using the current feed rate with the first feed-in value (P1) to depth 1.

3. Pull out in rapid traverse to the reference plan (P2).

4. To allow the drill bit to cool, the Z-axis remains on the reference plane (P2) during the dwell time (P4).

5. Move in rapid traverse to P1-P6 (first feed-in minus safety clearance) in the hole.

6. Drill to the depth 2: P6+P5 (safety clearance plus feed-in) using the current feed rate.

7. Pull out in rapid traverse to the reference plane (P2).

8. To allow the drill bit to cool, the Z-axis remains on the reference plane (P2) during the dwell time (P4).

Page 249: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 249/376

9. Move in rapid traverse to P1+P5-P6 (first feed-in plus further feed-in minus safety clearance) in the hole.

10. Drill using the current feed rate to the next depth of P6+P5 (safety clearance plus feed-in). Drill using the current feed-in plus n times the further feed-in) exceeds the final hole depth (P3).

11. Pull out in rapid traverse to the retract plane (P10).

7.7 G84 Thread cutting with balanced chuck Syntax: G84

The program word G84 selects the drilling cycle thread cutting with balanced chuck. This is also called a simple tapping cycle. The feed values and rotational speeds defined in the NC program are taken over in the drilling cycle. Four parameters must be defined before calling up this cycle:

P2 Reference plane, absolute Z coordinate

P3 Final hole depth, absolute Z coordinate

P4 Dwell time in ms

P10 Retract plane, absolute Z coordinate

Example: N30 ...*N40 P2=25000, P3=10000*N50 P4=1000, P10=30000N60 G84N70 X10 Y15N80 G80N90 ...

The above program was running in G70 (inch mode). In that context, N40 assigned the reference plane (P2) to 2.5 inches and the final hole depth (P3) to 1.0 inches. N50 assigned the dwell (P4) to 1 second (or 1000 milliseconds) and the retract plane (P10) to 3.0 inches. N70 performed the cycle at X of 10.0 inches and Y of 15.0 inches.

Page 250: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 250/376

Figure 7-5: Drilling cycle G84

Sequence of drilling cycle G84: 1. Rapid traverse in the Z direction to the reference plane (P2).

2. Drill using the current feed rate and clockwise rotating spindle (M03) to the final hole depth (P3).

3. Reverse spindle (the direction of rotation changes). A pause is made for the dwell time (P4).

4. Pull out using the current feed rate to the reference plane (P2). Reverse spindle. The spindle�s direction of rotation is again clockwise.

5. Move in rapid traverse to the retract plane (P10)

Page 251: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 251/376

7.8 G85 Reaming Syntax: G85

The program word G85 selects the drilling cycle reaming. The feed values and rotational speeds defined in the NC program are taken over in the drilling cycle. Four parameters must be defined before calling up this cycle:

P2 Reference plane, absolute Z coordinate

P3 Final hole depth, absolute Z coordinate

P4 Dwell time in ms

P10 Retract plane, absolute Z coordinate

Example: N30 ...*N40 P2=25000, P3=10000*N50 P4=1000, P10=30000N60 G85N70 X10 Y15N80 G80N90 ...

The above program was running in G70 (inch mode). In that context, N40 assigned the reference plane (P2) to 2.5 inches and the final hole depth (P3) to 1.0 inches. N50 assigned the dwell (P4) to 1 second (or 1000 milliseconds) and the retract plane (P10) to 3.0 inches. N70 performed the cycle at X of 10.0 inches and Y of 15.0 inches.

Page 252: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 252/376

Figure 7-6: Drilling cycle G85

Sequence of drilling cycle G85: 1. Rapid traverse in the Z direction to the reference plane (P2).

2. Drill using the current feed rate to the final hole depth (P3).

3. Wait for the dwell time (P4) to elapse.

4. Pull out using the current feed rate to the reference plane (P2).

5. Move in rapid traverse to the retract plane (P10).

Page 253: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 253/376

7.9 G86 Bore out Syntax: G86

The program word G86 selects the drilling cycle �bore out". The boring out is followed by an orientated spindle retraction which is offset in the X, Y direction. This prevents the inner contour of soft materials from being damaged when the boring bar is pulled out. A spindle with feedback must be provided for this function. The feed values and rotational speeds defined in the NC program are taken over in the drilling cycle. Six parameters must be defined before calling up the cycle:

P2 Reference plane, absolute Z coordinate

P3 Final hole depth, absolute Z coordinate

P4 Dwell time in ms

P8 Incremental lift distance in the X axis, sign dependent

P9 Incremental lift distance in the Y axis, sign dependent

P10 Retract plane, absolute Z coordinate

Example: ...

*N40 P2=25000, P3=10000*N50 P4=1000, P8=1000*N55 P9=1000, P10=30000N60 G86N70 X10 Y15N80 G80N90 ...

The above program was running in G70 (inch mode). In that context, N40 assigned the reference plane (P2) to 2.5 inches and the final hole depth (P3) to 1.0 inches. N50 assigned the dwell (P4) to 1 second (or 1000 milliseconds) and the X lift distance (P8) to 0.1 inch. N55 assigned the Y lift distance (P9) to 0.1 inch and the retract plane (P10) to 3.0 inches. N70 performed the cycle at X of 10.0 inches and Y of 15.0 inches.

Page 254: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 254/376

Figure 7-7: Drilling cycle G86

Sequence of drilling cycle G86: 1. Rapid traverse in the Z direction to the reference plane (P2).

2. Bore to the final hole depth (P3) using the current feed rate.

3. Wait for the dwell time (P4) to elapse.

4. Move away 0.1 in or .1 mm using the current feed rate.

5. Spindle is orientated to 0 degrees (M19).

6. The lift distance (P8 and/or P9) moves spindle in the X and/or Y-axis.

7. Pull out to the retract plane (P10) in rapid traverse.

Page 255: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 255/376

7.10 G87 Reaming with measuring stop Syntax: G87

The program word G87 selects the drilling cycle reaming with measuring stop. Note that the area of the retract plane must guarantee sufficient space for measuring. Seven parameters must be defined before calling up this drilling cycle:

P2 Reference plane, absolute Z coordinate

P3 Final hole depth, absolute Z coordinate

P4 Dwell time in ms

P10 Retract plane, absolute Z coordinate

P11 Processing feed rate

P12 Retract feed rate

P13 First reamed depth, absolute Z coordinate

Example: N30 ...*N40 P2=25000, P3=10000*N45 P4=1000, P10=30000*N50 P11=6000, P12=4000*N55 P13=17500N60 G87N70 X10 Y15N80 G80N90 ...

The above program was running in G70 (inch mode). In that context, N40 assigned the reference plane (P2) to 2.5 inches and the final hole depth (P3) to 1.0 inches. N50 assigned the dwell (P4) to 1 seconds (1000 msec) and the retract plane (P10) to 3.0 inches. N50 assigned the processing feed rate (P11) to 6.0 IPM and retract feed rate (P12) to 4.0 IPM. N55 assigned the first reamed depth (P13) to 1.75 inches. N70 performed the cycle at X of 10.0 inches and Y of 15.0 inches.

Page 256: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 256/376

Figure 7-8: Drilling cycle G87

Sequence of the drilling cycle G87: 1. Rapid traverse in the Z direction to the reference plane (P2).

2. Ream with the processing feed rate (P11) to the first reamed depth (P13).

3. Pull out to the retract plane (P10) with the retract feed rate (P12).

4. Halt feed rate to allow measuring of the hole. Press START to continue with the processing.

5. Rapid traverse to the reference plane (P2).

6. Ream with the processing feed rate (P11) to the final hole depth (P3).

7. Wait for the dwell time (P4) to elapse.

8. Pull out with the retract feed rate (P12) to the reference plane (P2).

9. Move to the retract plane (P10) in rapid traverse.

Important: After leaving the drilling cycle, G87 the retract feed rate is active.

Page 257: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 257/376

7.11 G88 Bore out with spindle halt Syntax: G88

The program word G88 selects the drilling cycle bore out with spindle halt. The feed values and rotational speeds defined in the NC program are taken over in the drilling cycle. Four parameters must be defined before calling up this cycle:

P2 Reference plane, absolute Z coordinate

P3 Final hole depth, absolute Z coordinate

P4 Dwell time in ms

P10 Retract plane, absolute Z coordinate

Example: N30 ...*N40 P2=25000, P3=10000*N50 P4=1500, P10=30000N60 G88N70 X10 Y15N80 G80N90 ...

The above program was running in G70 (inch mode). In that context, N40 assigned the reference plane (P2) to 2.5 inches and the final hole depth (P3) to 1.0 inches. N50 assigned the dwell (P4) to 1.5 second (or 1500 milliseconds) and the retract plane (P10) to 3.0 inches. N70 performed the cycle at X of 10.0 inches and Y of 15.0 inches.

Page 258: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 258/376

Figure 7-9: Drilling cycle G88

Sequence of drilling cycle G88: 1. Rapid traverse in the Z direction to the reference plane (P2).

2. Bore to the final hole depth (P3) using the current feed rate.

3. Stop the spindle (M05)

4. Wait for the dwell time (P4) to elapse.

5. Pull out to the retract plane (P10) in rapid traverse with stopped spindle.

Page 259: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 259/376

7.12 G89 Bore out with intermediate halt Syntax: G89

The program word G89 selects the drilling cycle bore out with intermediate halt. The feed values and rotational speeds defined in the NC program are used in the drilling cycle. Six parameters must be defined before calling up this cycle:

P2 Reference plane, absolute Z coordinate

P3 Final hole depth, absolute Z coordinate

P4 Dwell time in ms

P10 Retract plane, absolute Z coordinate

P13 First drilling depth, absolute Z coordinate

P15 Second drilling plane, absolute Z coordinate

Example: N30 ...*N40 P2=25000, P3=10000*N50 P4=1000, P10=30000*N55 P13=17500, P15=12500N60 G89N70 X10 Y15N80 G80N90 ...

The above program was running in G70 (inch mode). In that context, N40 assigned the reference plane (P2) to 2.5 inches and the final hole depth (P3) to 1.0 inches. N50 assigned the dwell (P4) to 1 second (or 1000 milliseconds) and the retract plane (P10) to 3.0 inches. N55 assigned the first drilling depth (P13) to 1.75 inches and the second drilling plane (P15) to 1.25 inches. N70 performed the cycle at X of 10.0 inches and Y of 15.0 inches.

Page 260: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 260/376

Figure 7-10: Drilling cycle G89

Sequence of drilling cycle G89: 1. Rapid traverse in the Z direction to the reference plane (P2).

2. Bore to the final hole depth (P13) using the current feed rate.

3. Rapid traverse in the Z direction to the second drilling plane (P15).

4. Bore to the final hole depth (P3) using the current feed rate.

5. Wait for the dwell time (P4) to elapse.

6. Pull out in rapid traverse to the retract plane (P10).

Page 261: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 261/376

7.13 Example: base plate A base plate with four threaded holes is used here as an example. The drilling cycles can be used to process this panel, making the NC program considerably shorter and clearer.

Figure 7-11: Example: Base plate

Page 262: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 262/376

The following is used to program the four threaded holes in the base plate:

N10 (BASE PLATE)N20 G00 X0 Y0 Z400 Positioning instructionN30 F200 M03 S1000 Technological data*N40 P2=20000, P3=3000 Parameter definitions*N50 P10=30000N60 G81 Cycle: Drill to final depthN70 X10 Y10 Drilled hole 1N80 X40 Drilled hole 2N90 Y30 Drilled hole 3N100 X10 Drilled hole 4N110 M0 Unconditional haltN120 M5 Spindle halt, tool changeN130 F150 S300 Technological data*N140 P3=5000, P4=1000 Parameter definitionsN150 G84 Cycle: Thread cutting with

balanced chuckN160 Y10 Threaded hole 1N170 X40 Threaded hole 2N180 Y30 Threaded hole 3N190 X10 Threaded hole 4N200 G80 Deactivate the function drilling

cycleN210 Z400 Positioning instructionN220 X00 Y00N230 M30 Program end

The drilling cycles G81 (Drill to final depth) and G84 (Thread cutting with balanced chuck) are used in the NC program. Before calling up the respective drilling cycle, the specific parameters were defined. Note that the value of the final hole depth P3 is different in the two drilling cycles. A feed rate and cutting speed reduction was also programmed before the cycle thread cutting. The values of the reference plane and the retract plane do not need to be redefined before calling up G84. These values were already assigned and are unchanged.

Sequence of the processing Move to the coordinate X10 Y10 in rapid traverse.

Rapid traverse in the Z direction to the reference plane (P2).

Drill to the final hole depth (P3) using the current feed rate.

Pull out to the retract plane (P10) in rapid traverse.

Move to the coordinate X40 Y10 in rapid traverse and repeat steps 2 to 4.

Move to the coordinate X40 Y30 in rapid traverse and repeat steps 2 to 4.

Move to the coordinate X10 Y30 in rapid traverse and repeat the steps 2 to 4.

Page 263: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 263/376

Interrupt program (unconditional halt) and halt spindle for tool change; continue the program by pressing the START button.

Move to the coordinate X10 Y10 in rapid traverse and rapid traverse to the reference plane (P2) in the Z direction.

Drill using the current feed rate and clockwise rotating spindle (M03) to the new final hole depth (P3).

Reverse spindle. The direction of rotation changes and a pause for the dwell time (P4) is made.

Pull out to the reference plane (P2) using the current feed rate.

Reverse spindle (spindle has clockwise direction of rotation).

Move to the retract plane (P10) in rapid traverse.

Repeat the steps 12 to 17 at the other three drilling positions.

Page 264: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 264/376

8 Program Optimization 8.1 Hints for rational program creation

8.1.1 Subroutines

If the same contour element frequently appears in a contour, then it should be programmed in a subroutine. The subroutine can then be called up at each position of the main program at which the contour element is required.

8.1.2 Modally effective instructions

Modally effective instructions should not be programmed again if they are already active. Following this recommendation gives the following advantages:

• Less memory space required

• Shorter program processing time

• Shorter program transfer time

8.1.3 Value allocation to NC addresses using parameters

If certain values (e.g., feed rate or spindle speed) repeatedly change during the processing of an NC program, assign parameters to these values instead of programming them with firm values in the program. These parameters can then be allocated with values at the start of the program. When these values are altered later in the program, a search does not have to be made for all the program positions at which the concerned size was programmed. Instead, only the corresponding parameters at the start of the program have to be assigned with new values. An example is below:

*N... P1=1000*N... P2= 500N... ...N... ... F=P1N... ...N... ... F=P2N... ...

Page 265: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 265/376

8.2 Hints for Processing Programs

8.2.1 Look Ahead

The function Look Ahead should always be activated by programming G09 at the beginning of an NC program, as long as on technological grounds there is nothing against processing the program with "Look Ahead" (see also point "Activation of special functions using a subroutine").

Avoid programming any PLC codes (i.e., usually the M, S and T codes) in blocks with short axis motion because the CNC must hold that block long enough for the PLC to get its code(s) from the block. This delay for the PLC will affect the path performance for blocks with very short axis motion when the time for the block�s axis motion is less than the time for the PLC code(s).

8.2.2 Programmable acceleration at Look Ahead

When Look Ahead is active the control recognizes, over several NC blocks away, when the axes must be slowed down or sped up. The acceleration with active Look Ahead is made so that the maximum velocity at the start of the block is reached as quickly as possible. If the NC block currently to be executed is followed by a block in which a lower path velocity has been programmed, then the braking is not made at the beginning of the following block, but during the execution of the preceding one. This can result in rapidly successive acceleration and braking processes.

The function programmable acceleration can be used with active "Look Ahead" to obtain a leveling of the axis accelerations. This puts the machine tool under less stress and increases processing accuracy.

8.2.3 Activation of special functions using a subroutine

Always program the real contour geometry description as the main program. By comparison, functions necessary for the processing (e.g., MACHINEMATE specific functions such as Look Ahead, spline interpolation, part position offsets) should be stored in a resident subroutine, at the end of which a conditional hold is programmed with M01. This provides the following advantages:

• Specific functions (e.g., Look Ahead) can be quickly and easily activated in standard programs using a subroutine call up.

• After aborting a program (e.g., due to tool breakage), all the necessary modal values for the program continuation may still be active. The main program is then only reprocessed up to the conditional halt in the subroutine. The main program is then interrupted and, using a manual block selection, continued at the desired position.

Page 266: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 266/376

8.3 Hints for Avoiding Errors

8.3.1 Protection of subroutines against call up as main program

In order to avoid processing subroutines as main programs by mistake, when the subroutines are not intended for this, no F word should be programmed in these subroutines. If a subroutine without F word is selected as main program, the error message 199 appears and the subroutine is not processed.

8.3.2 Functions not automatically reset at the program end

If modally effective functions that are not automatically reset at the end (e.g., G92, G81, G100 and other transformation instructions) are used in programs, then the instructions that deactivate these functions should be programmed at the program start. This ensures that these functions are no longer effective after a program restart (e.g., after having to abort because of tool breakage).

8.3.3 Circular interpolation

Output error messages will occur during circular interpolation if three decimal places are set up in the control and a post processor that only considers two decimal places reads programs in.

The control always checks at circular interpolation that the distance from the circle start point to the circle center point corresponds exactly to the distance from the circle end point to the circle center point. The control outputs an error message if this is not the case. Since the post processor rounds values up or down, these distances may not exactly correspond to each other. Such problems can be avoided by using the instructions G12/G13 (circular interpolation with specified radius) instead of the instructions G02/G03 (circular interpolation with specified center point).

8.3.4 Avoid dummy blocks at subroutine call up

Subroutine call-ups within closed contours should be programmed in the last motion block before the desired subroutine processing and not in separate NC blocks.

Example:

... ...N50 X70 Y80 instead of: N50 X70 Y80N60 Y90 Q100 instead of: N60 Y90... instead of: N70 Q100

Page 267: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 267/376

8.3.5 Avoid dummy blocks at subroutine end

The end of program instructions M02 or M30 in subroutines should be incorporated in the last motion block of the subroutine instead of being programmed in separate NC blocks. Continuous block processing is obtained at subroutine repetitions of the individual subroutine loops and a pause at the end of each subroutine loop is avoided.

Example: Main program: ...N20 G9N30 G90N40 G1 X. . Y. . Position over work pieceN50 G91 Z-10 Q17 L9 Feed-in to work piece-upper edge,

call up subroutine, 9 repetitionsN60 Z30...

Subroutine P17: N1 G2 I5 Z-2 M30

If the M30 in the subroutine was programmed in a separate block the helix would not be processed continuously and M30 would be interpreted as a dummy-block. This would result in a standstill after each revolution of the helix.

8.3.6 Avoid dummy blocks at path compensation

Path compensations are normally activated with the instructions G41-G44 and deselected with the instruction G40. If the activation or deactivation of a path compensation is to be made simultaneously with a change of the interpolation type (e.g., exchange G01 <-> G02), then two NC blocks would have to be programmed. One NC block would be programmed for the change of the interpolation type and one would be programmed for the activation or deactivation of the path compensation. This is because two G-codes must not be contained in the same NC block. The G40-G44-blocks would be dummy-blocks in this case.

Dummy-blocks can be avoided in such cases as follows:

• The instruction for the activation of the path compensation is already programmed in a block, together with D0 or the address of an empty compensation value memory before the change of the interpolation type. In the block in which the path compensation is to be active, only the D word of the compensation value memory that contains the desired compensation value is programmed.

Page 268: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 268/376

• Analog programming to deselect path compensation is done by not programming G40 in a separate block, but instead by programming D0 or D together with the address of an empty compensation value memory in the first motion block which should be processed without path compensation.

Example: Acceptable: ...N90 G1 X0 Y0 F1000N100 Y10N110 G43 D1 Activate the path compensation

(dummy-block)N120 G2 X10 I5 Block, which should be processed with

path compensationN130 G40 Deactivation of the path compensation

(dummy-block)N140 G1 Y0

Better: ...N90 G1 X0 Y0 F1000N100 Y10 G43 D0 Activate the path compensation with

compensation value 0N120 G2 X10 I5 D1 Activate compensation value the

compensation value memories 1N120 G1 Y0 D0 Activate compensation value 0

8.3.7 Collision free movement

To ensure collision free movement to a point, use the instructions of cycle level II. This enable the current axis values to be read.

8.3.8 Contour accuracy (G186)

When Look Ahead is active, a contour accuracy that has been programmed with G186 together with a K word is only effective with circular interpolation (using G02/G03, G12/G13 or G07) and not with linear and spline interpolation.

Page 269: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 269/376

9 Programming Various CNC Features/Capabilities Note that some of these features are optional and not available in all controls. Others are standard features but are not enabled until the system integrator changes the appropriate machine parameters to activate and configure the particular feature.

9.1 Angled Wheel Transformation Some machines can have linear axes which are not orthogonal to each other. These so called angled wheel axes can be used for certain applications, such as certain grinders. Usually angled wheel axes machines are difficult to be program using standard NC statements. This Angled Wheel transformation feature allows the easier programming of such a machines, in the same manner as usual machines with orthogonal Cartesian axes.

9.1.1 Angled wheel transformation syntax G220 angled-wheel transformation OFF, programming with machine

coordinates. G221 normal motion angled wheel transformation ON, programming with axes

addresses X, Y, Z or other defined in machine parameters; is an axis (or axes) an angled-wheel axis or not is defined in machine parameters as well. Programming is done using virtual orthogonal Cartesian coordinate system which axes could be equal or not to physically axes.

G222 two step motion angled-wheel transformation ON; virtual orthogonal Cartesian coordinates are used for programming and are displayed in MMI; first angled-wheel axis is moved in the first step if programmed movement is away from the part; all other axes are moved in the second step

G223 two step motion angled-wheel transformation ON; movement behaviour is opposite to G222 � first angled-wheel axis is moved in the second step, if programmed direction is away from the part

Real time normal motion Angled-Wheel transformation is activated with the instruction G221. It allows programming in virtual normal Cartesian coordinate system even by machines with angled-wheel axes. This virtual coordinate system is a part coordinate system which is defined for programming. It can have two (usually X and Z or X and Y for 2D programming) or three axes (usually X, Y, Z).

Instruction G221 is a modal one and once being programmed it allows us to use standard instructions for axes movements: G0 or G1 for linear interpolation, G2 or G3 for circle interpolation. Polar-/barrel cam transformation (instructions G100 - G108, G14, G15) is not possible with G221 Angled-Wheel transformation active.

G220 deactivates the angled wheel transformation. It means all given axes coordinates are machine coordinates for corresponding axes. The transformation is not performed so the programming is done in the machine coordinates.

Page 270: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 270/376

Two step motion Angled-Wheel transformation (activated with G222 or G223) means that each programmed motion block is separated in two steps. Depending on active angled-wheel G-code and programmed first angled-wheel axis (usually X) direction all first angled-wheel axis (usually X) movement can take place in the first step (G222) or in the second step (G223). Corresponding all others axes motion take place in second (G222) or in the first step (G223). In two step motion mode axes are programmed in virtual orthogonal Cartesian coordinates. The CNC generates the intermediate blocks to realise two step axes motion. Angled-wheel transformation G-codes G220-G223 have to be programmed alone in the program line. Axes movements programmed in the same line are ignored. Following G-codes are not allowed in two step motion mode: - circular interpolation (G2,G3, G12, G13) - radius compensation (G41-G44) - Threading blocks (G33, G34) - spline interpolation (G6)

9.1.1.1 Example of G220 and G221

Figure 9-1: Relationship between two linear axes with Angled Wheel Transformation

X (virtual)

X (physical)

Y (physical)

Y (virtual)

10

20

30

10 20 30

N5, N10

N20

N30 N40

N50N60

α = 30o

β = 60o

Page 271: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 271/376

A simple example illustrates usage of angled wheel transformation. In the figure above is a machine with two physical axes: X axis (as an angled wheel axis) and Y axis (as a normal linear axis). Often in grinders the normal linear axis will be Z.

Program example with G221:

N5 G0 X0 Y0 N10 G221 N20 G0 X10 Y20 N30 G1 Y30 F100 N40 X20 N50 Y20 N60 X10 M30

N5 � physical axes homing (may be necessary for some machine) N10 - switching in angled wheel mode. All commanded coordinates after switching are related to virtual axes. PA CNC calculates necessary physical axes movements automatically. N20 � movements to commanded positions of both virtual axes with maximal velocity. N30 - movement of virtual Y axis. N40 � movement of virtual X axis. Note: by this movement both physically axes have to be moved. It is done automatically. N50-N60 � further axes movements and program end. Program example with G220 The same axes movements can be programmed by switching off the Angled-Wheel transformation (G220 instruction active).

N5 G0 X0 Y0 N10 G220 N20 G0 X11.547 Y14.2265 N30 G1 Y24.2265 F100 N40 X23.094 Y18.453 N50 Y8.453 N60 X11.547 Y14.2265 M30

This simple example shows the same programming without G221 instruction is possible (however not so simply). But for more complicated cases (e.g., circular interpolation, etc.) it can be much more complex task and so using Angled-Wheel transformation is preferable.

9.1.1.2 Example of G220 and G222

Page 272: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 272/376

Figure 9-2: Example for G222, two step move for Angled Wheel Transformation The figure above shows the difference between a two-step move (G222) and the interpolated move (G221). Program example with G222:

N5 G0 X0 Y0 N10 G222 N20 G0 X10 Y20 N30 X30 M30

N5 � physical axes homing (may be necessary for some machine)

N10 - switching in two step angled wheel mode.

N20 � movements to commanded positions in two step (dashed line in the fig. 2 ); angled axis is moved in the first step, other axis is moved in the second step. PA CNC generates intermediate block for the second step.

N30 - movements to commanded positions and program end.

Solid line demonstrated G221 command behaviour in the same program.

Program example with G220

X (virtual)

X (physical)

Y (physical)

Y (virtual)

10

20

30

10 20 30

α = 30o

β = 60o

First step

Second step

First step

Second step

N5, N10

N20

N30, N40

G-211 movement

G-212 movement

Page 273: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 273/376

The same axes movements can be programmed by switching off the Angled-Wheel transformation (G220 instruction active).

N5 G0 X0 Y0 N10 G220 N20 G0 X11.547 N25 X14.226

N30 X34.641 N35 Y2.679 M30 The same movement can be programmed by without the angled-wheel transformation but the program is more complicated even in this simple example.

9.1.1.3 G92 offset

Even with angled-wheel transformation active, G92 axes offset can be active. By transformation between current machine coordinates (G220) and Cartesian coordinates (G221), G92 offset values remain the same. Switching between normal motion mode (G221) and two step motion mode (G222) is also possible.

9.1.2 Axes sequence by two step mode

In two step mode, the axes sequence is depending on the programmed first angled-wheel axis (usually X) direction. Motions of the axes by different G-codes are described in the table below.

Note: by calculating whether X axis is programmed away from the part spindle center line (assumed to be X 0.0) the CNC takes programmed values. No G92 offset is taken into account. If such behaviour is not right in some NC program places than earlier programmed two step motion G-code can be changed to it opposite (G222 to G223).

G-Code X axis is programmed away from

the part spindle center line X axis is programmed towards the part spindle center line

G222 STEP 1: all first angled-wheel axis (X) motion takes place STEP 2: all other axes motion takes place (Y, Z and other axes programmed)

STEP 1: all other axes motion takes place (Y, Z and other axes programmed) STEP 2: all first angled-wheel axis (X) motion takes place

G223 STEP 1: all other axes motion takes place (Y, Z and other axes programmed) STEP 2: all first angled-wheel axis (X) motion takes place

STEP 1: all first angled-wheel axis (X) motion takes place STEP 2: all other axes motion takes place (Y, Z and other axes programmed)

Table 9-1: Angled Wheel Transformation two-step motion description

Page 274: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 274/376

9.1.3 Mirroring

Angled-wheel axes can be mirroring by active angled-wheel transformation. Mirroring works in normal motion mode as well in two step motion mode.

Note: normally mirroring should be switching off in the position in which it has been switching on. If it is not the case, after switching off the mirroring with G38 or G39 an extra G92 without any parameters has to be programmed to remove all G92 related axis offsets.

9.1.4 H and G compensation

The values of H- and G5x-compensations can be set (using the Data mode displays). With an active angled-wheel transformation (G221-G223) these values for programmed axes are interpreted as given in Cartesian coordinate.

9.2 Automatic Spindle Gear Step (Range) Selection The Automatic Spindle Gear Step (or range) Selection feature supports different gear ratios in the spindle transmission. The desired gear range can be directly specified with an associated M-code or the appropriate gear range can be determined from the programmed spindle speed.

9.2.1 General

The programming of the spindle gear step (or range or stage) switching for different spindle speeds is achieved using M-codes:

M40 = automatic switching - computed from the programmed spindle speed.

M40 = effective at the time the machine is turned on. M41..M46 = programmed switching. A maximum of 6 stages is possible.M40-M46 = modally effective code M03 = spindle turning clockwise M04 = spindle turning counter-clockwise M05 = spindle stop

Note

The function �Automatic Gear Step Selection� is only possible for the main spindle. The first spindle in the system is termed the �Main spindle�.

Page 275: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 275/376

9.2.2 M40 is Active

If M40 is active, the speed stage is selected via the programmed S-word. A minimum and maximum speed for every speed stage is specified in the machine parameters.

Stage by stage (begin with speed stage 1) applies:

The defined maximum speed is compared with the programmed spindle speed. The first stage is valid where: the programmed spindle speed is smaller than or equal to the maximum speed for the range. A speed stage with the applicable minimum speed = 0 will be treated as not specified. If the programmed spindle speed is greater than the largest applicable maximum spindle speed, the speed will be automatically limited to the maximum allowable value. G92 and the spindle override have no influence on the selected speed stage.

9.2.3 M41 to M46 is Active

This allows a speed stage to be directly selected. A maximum of 6 levels are possible. The gear ratio of each step is set in the machine parameters. The speed stage selected via M41-M46 has priority over the programmed S-value; i.e., the spindle speed will be limited to the speed interval corresponding to the selected stage if necessary.

Note:

Definition of the transmission ratio (machine parameter):

Motor speed = spindle speed * Transmission Ratio

9.2.4 Switchover procedure between gear ranges

The switchover procedure is initiated if the programmed speed stage does not agree with the PLC feedback message concerning the currently applied speed stage (see PLC-CNC Interface signals IN_GEAR01 to IN_GEAR06). Five temporary blocks are created for this. (The following is displayed at the block display on the screen: AUTOMATICALLY INTERMEDIATED BLOCK).

The first temporary block decelerates the spindle to the gear change speed (which can be different for each gear range). A delay is also calculated, based on the speed change (with a full delay for a change from top speed in the range).

The second temporary block provides the programmed gear range as an M-Code to the PLC (with the programmed S-code). The NC block transfer is blocked as long as it takes to obtain feedback from the gearbox (via the PLC) that it is in the selected speed range.

The third and fourth temporary blocks are G10 blocks to suppress the block look

Page 276: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 276/376

ahead feature during the spindle gear shift.

The fifth temporary block accelerates the spindle to the programmed speed. A delay is also calculated, based on the speed change (with a full delay for a change to top speed in the new range). After this delay, normal NC block processing continues.

Notes:

The waiting time is only considered during speed stage changes but not during other speed change operations.

Switching to counter-clockwise and clockwise turning can be achieved if the PLC signal IN_REV (in IN_SPINDLE) is continuously reversed by the PLC.

9.2.5 G96 is Active

As long as G96 is active and the spindle is turning it is not possible to execute a gearing level change. If M40-M46 is programmed, an error message is output:

NC ADDRESS M WRONG!

One of M40 to M46 can be programmed into the G96 switch-on block. The S-word, however, has no function if M40 is active.

The speed stage can be changed (only via the M-code, not via the S-code) while M05 is active if the spindle that has been programmed using M05 was stopped. The actual change is carried out if the spindle is switched on via M03/M04.

In case of G96 Mxx S200 in one block (where xx = 41 to 46), the spindle first accelerates to the speed that was programmed last (i.e., before the speed stage change). Only then S200 is taken into consideration.

9.2.6 G92 is Active

In case of G92, the S-word for the speed stage is ignored. The M-word is relevant.

9.2.7 G33/G34 is Active

As for G96 but the S word is also relevant.

The PLC signal IN_NULLV always provides for a spindle stop; also in case of M40-M46.

S0 has no effect on the current speed stage if M40 is in operation.

Page 277: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 277/376

9.3 Barrel Cam Transformation The Barrel Cam Transformation feature requires associated additions to a typical NC program to obtain the desired behavior.

9.3.1 General

Using the instructions G102 and G106 the barrel cam transformation is activated. Following the instruction G102 the specified coordinates are interpreted as Cartesian coordinates and following the instruction G106 as polar coordinates or cylinder coordinates.

The barrel cam transformation also offers the possibility of switching between absolute dimension input (G90) and incremental dimension input (G91).

If other axis addresses were specified for the polar transformation as substitutes for X and Y, then they also have to be used with active G106. When G102 is active, however, the axis addresses X and Y are used, as with G101. If no other axis addresses were specified as substitutes for X and Y, then the instruction G106 with the axis addresses X and Y is available.

Example: A groove is to be milled into the curved surface of a cylinder. During the milling process the cylinder must rotate about its center axis. Simultaneously linear axes must be moved. In order to achieve the desired groove, the movements of the rotational axis and the linear axes must be exactly in coordination with each other, which is relatively complicated. The barrel cam transformation is a simplification for the programming of such processes.

The curved surface of the cylinder is unwrapped or developed to form a plane that serves as an interpolation plane for compensations and the feed rate during barrel cam transformation.

Within this plane the complete range of geometric options of the MachineMate are available.

9.3.2 Barrel cam transformation using Cartesian coordinates G102 Syntax:

G102 R ...

Activation of the barrel cam transformation with specification of Cartesian coordinates is achieved using the instruction G102 together with the cylinder radius in the form of an R word.

Example: G102 R80.05

Page 278: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 278/376

In this NC block a reference cylinder with a radius of 80.05 is specified for the following processing steps.

When G102 is active the values programmed together with the axis addresses X and Y are to be interpreted as follows:

The value programmed together with the axis address Y indicates the position in the direction of the cylinder axis. The value programmed together with the axis address X indicates the position in the direction of the cylinder's curve.

XY

X

Y

Figure 9-3: Interpretation of the X and Y values when G102 is active.

Y

X

0-20

-40

2040

R 80,5

-20 0 20

N 50

N 70N 30

N 40

N 60

Figure 9-4: Barrel cam transformation

The X-values result in rotations of the rotational axis, the Y-values in linear travel movements in the positive or the negative direction of the Y-axis, i.e., in the axial direction of the curved cylinder surface.

Page 279: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 279/376

Program example with G102:

N10 G102 R80.5N20 X20 Y20 F500N30 X0N40 Y-20N50 X40N60 Y20N70 X0 M30

The program shown above results in the travel movements displayed as arrows in the figure above.

9.3.3 Barrel cam transformation with cylinder coordinates G106 Syntax:

G106 R...

As in the case of polar transformation, the barrel cam trans-formation also offers the possibility of programming the rotations of the rotational axis by specifying an angle instead of by specifying the Cartesian coordinates as was shown in the above example.

To enable this the instruction G106 is to be programmed instead of G102. When G106 is active, the same axis addresses must be used as for active G105 (see above).

For the following example, it is assumed that for the rotational axis the axis address C was specified and for the linear axis the axis address V. When G106 is active, the values programmed together with the axis address C are then interpreted as angles and the values programmed together with the axis address V are interpreted as the positions, in the axial direction of the cylinder curved surface, to which the linear axis is to be moved.

To find out which axis addresses are specified for the axes in your particular control, please see the documentation provided by the machine tool manufacturer. The following example can be easily adjusted to suit your individual configuration simply by replacing the axis addresses used in the example by those specified in your control.

Program example with G106

N10 G106 R80.5N20 C14.235 V20N30 C0N40 V-20N50 C28.47N60 V20N70 C0 M30

Page 280: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 280/376

R 80,5

-20 0 20

N 50

N 70N 30

N 40

N 60

V

C28,47°

14,235°0°

Figure 9-5: Meaning of the C and V values when G106 is active

This program leads exactly to the same result like the program example for G102.

9.3.4 Illegal G-codes during Barrel Cam

The instructions G74 �programmable homing�, �mirror� and G0 �rapid traverse� are not possible when barrel cam transformation is active. The error messages 108 or 241 are displayed. This is also displayed if an attempt is made to activate or switch off the transformation when G92-offset is still active. This also applies to offsets that arise due to mirroring. It is therefore recommended before activating or switching off the transformation to always program G92 in case an offset of the program zero point was previously active.

9.3.5 Real time radius compensation G103, G107

In standard barrel cam transformation, the cylinder surface is seen as an interpolation plane where path compensation in particular is active. Real time radius compensation is slightly different in that the compensation normally carried out on the rotational axis is transferred to another linear axis. This linear axis - here referred to as the U-axis - together with the cylinder longitudinal axis (Y-axis) forms the osculation plane on the cylinder pattern. The axis allocation must therefore be seen as follows.

Page 281: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 281/376

YX

U

Figure 9-6: Osculation plane � axis allocations for the cylinder

The function is activated analogously to G102, G103 and G106 with the G-codes G107. After a block such as:

N100 G103 R80.5

the usual barrel cam transformation G102 is activated first of all. The process deviates from G102 only when path compensation is then activated.

A brief example should clarify this.

Example: N10 X0 Y0 F500N15 G20 I1 J2N20 G103 R80N30 X30N40 Y20N45 D1=5000N50 G41 Y40 D1N70 G12 X50 Y60 K20N80 G1 X50 Y60 K20N85 G1 X80N90 G12 X100 Y40 K20N100 G1 Y30N110 G1 Y30N110 G40 Y20N120 G100N130 X0 Y0 M30

The path programmed in this example is sketched in the following figure. The X/Y plane here is the developed cylinder pattern.

Page 282: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 282/376

Y

X20° 50° 80° 100°

20

40

60K 20 K 20

360

D1DX

DY

Figure 9-7: Real-time radius compensation

The compensated path is indicated by dashes. It should be noted that the indicated paths DX are traveled by the U-axis. In contrast to conventional path compensation, the uncompensated path is interpolated. The compensation components DX and DY are first calculated during interpolation, whereby every interpolated point is displaced vertically by the compensation value.

Limitations:

1. While real time compensation is active, no blocks without travel information may be programmed in the active plane.

2. In order to avoid jumps in the U-axis or Y-axis, it is imperative to program tangential transitions between the travel blocks.

3. When processing curved contours, the velocity differs from the programmed velocity.

4. The U-axis may not be programmed once G103 or G107 are programmed. Error message 145 is output if this does occur.

5. Similarly to polar transformation, the axis limits of the U-axis and V-axis are monitored in real time for real time radius compensation. If the axis limits are violated, an error message is output and the interpolation is stopped.

9.3.6 Barrel cam transformation with centerline deviation of an additional axis and real time radius compensation, G104, G108

This is an additional option to G103 and G107.

Page 283: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 283/376

In addition to the compensation components for the X-axis, the U-axis travels for an additional value that is obtained from the following equation using the movement of the cylinder longitudinal axis.

Um = A + √K2 - (Y-B)2 | A < 0 (1) Um = A - √K2 - (Y-B)2 | A > 0

A: axis distance B: lever distance K: lever radius

The meaning of the individual parameters is explained in the following sketch that includes these parameters.

Activation takes place in an NC block of the form

G104 R80.5 A80 K100 B20

C

VA

RBK

Z

U

Figure 9-8: Barrel cam transformation with centerline deviation

The above figure also clearly shows the purpose of this function, which is chiefly used for processing a guide groove in a symmetrical cylinder. It is assumed here that a roller moves in the groove, and that the roller is firmly connected to a lever attached to a fixed point. Any movement in the longitudinal direction of the cylinder necessitates a circular movement of the roller in the U-Y plane. This movement is simulated by deviation from the center point. The picture also reveals the significance of real time radius compen-sation for this case.

Since the roller is moved in the U-Y plane, it is important that the projection of the guide groove in the U-Y plane has the correct width, i.e., the compensations must be relative to this plane. From this it is also clear that an equidistant path in the U-Y plane is not equidistant on the cylinder surface.

In addition to pure X components with G103/107, with path compensation a further component is considered which results from the centerline deviation.

Page 284: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 284/376

Limitations: The limitations are the same as for G103/107. In addition it is monitored whether a meaningful centerline deviation is possible according to the equation (1). If in this equation the term under the root is negative, then the error message �Axis limit U� is output. This is always the case when the guide groove is extended so far in the Y direction that a roller fixed onto a lever with length K can no longer reach this point.

9.3.7 Switching between machine coordinates with barrel cam transformation.

When changing over from operation in machine coordinates (G100) to the barrel cam transformation (G105) and vice versa, no compensation (no G-, D- or H- compensation) must be active. It is not possible to change over directly to the barrel cam transformation from the polar transformation. G100 must always be programmed before changing the transformation type. If an attempt is made to program an axis position in a block with a switching G-code, error message 145 is displayed.

9.3.8 End of program and change of the operating mode.

At the end of the program the operating mode is always switched back to operation in machine coordinates. Simultaneously, a G92-offset, possibly active for the rotational axis, is calculated. When changing over from the operating mode �MANUAL� to �AUTOMATIC� the position of the rotational axis is always reduced to a value between 0 and 360.

Page 285: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 285/376

9.4 Diameter Programming

9.4.1 Programming The "diameter programming" function enables the programming of the diameter of the work piece to be processed and the display of the point of contact referring to the diameter or to the radius dimension.

Figure 9-9: Diameter Programming D1, D2 Diameter programming R1, R2 Radius programming

9.4.1.1 Syntax

G191 Activate the diameter programming and display the point of contact referring to diameter dimension.

G192 Only display the point of contact referring to diameter dimension; programmed values are in radius dimension.

G193 Only display the point of contact in radius dimension; programmed values are in radius dimension.

G190 Deactivate the diameter programming (display shows the tool reference point in radius, programmed values are in radius).

The G-codes appertain to a group (only one code of the group is in effect at a time) and they are modal effective. Using the G191 command, diameter programming is activated. It is deactivated using G190. The display of the axis programmed for diameter processing is also modified. The location of the point of contact is displayed with reference to the diameter dimension.

Page 286: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 286/376

A short overview gives the following table:

Active G-code Programmed values Display

G190 Radius dimension Tool reference point in radius dimension G191 Diameter dimension Tool contact point in diameter dimension G192 Radius dimension Tool contact point in diameter dimension G193 Radius dimension Tool contact point in radius dimension Table 9-2: Diameter programming G-codes

In the examples, it is always assumed that the axis with address letter X is the diameter programmable axis.

9.4.1.2 Negative orientation

The behavior of the function in the case of negative radius is applied by the machine parameter DiameterAppl.

DiameterAppl Bit 1 = 0

With DiameterAppl Bit 1 = 0 the orientation of the diameter programmable axis to the tool spindle is determined by the axis position achieved before. If this position is negative then the diameter corresponding to the negative axis position is computed.

Note:

Only the end positions of programmed paths are checked whether the zero point is crossed when DiameterAppl Bit 1 = 0. Certain motions might possibly cross the zero point of the axis.

Example:

Programming a circle with start and end point in the positive range and a radius which is smaller than the distance of the center point from the zero point of the axis will lead to a motion through the zero point: N10 G191 Activate diameter programmingN20 G1 X20 Y100 Move to the start position at X20 / Y100N30 G3 X20 Y20 I0 J-80 Circular interpolation (counter

clockwise) to the end point at X20 /Y20. Axis moves through the zero point.

Page 287: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 287/376

Figure 9-10: Diameter Programming with negative orientation DiameterAppl Bit 1 = 1 With DiameterAppl Bit 1 = 1 positive and negative values of the diameter will be allowed. In this case it is possible to start from negative position and move through the zero-positions or program negative positions.

9.4.1.3 Commands that are not allowed

The G38 "Mirroring" and G101-G106 "Polar/Cylinder transformation" commands are not permissible for diameter programmable axis. Error message 241 is output. Error message 241 is also output if one of the diameter programmable axes is one axis on the active G17-G20 "Plane selection" plane and G14-G16 "Polar programming" or G51 "Part rotation" is active. Error message 435 is output if during active diameter programming a negative value is programmed for a diameter programmable axis.

9.4.1.4 Incremental dimension programming

When incremental dimension programming is modal, programmed values interpreted as follows: DiameterAppl Bit 1 = 0 Positive values always increment the diameter, negative values always decrement the diameter.

Example:

N10 X-100 Move to position X-100N20 Gl91 Activate the diameter programming and display X-200

(diameter)N30 G91 Activate incremental dimension programmingN40 X100 Increment the diameter by 100. Axis moves to –150

(radius dimension) display shows X-300.

Page 288: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 288/376

DiameterAppl Bit 1 = 1 Positive values lead to a motion of the axis in positive direction and negative values lead to a motion in negative direction. In this mode, the position of the axis is incremented.

Example:

N10 X-100 Move to position X-100N20 G191 Activate the diameter programming and display X-200

(diameter)N30 G91 Activate incremental dimension programmingN40 X100 Increment position by 100. Axis moves to –50

(radius dimension) display shows X-100.

9.4.1.5 Part position offsets

When part position offsets (G53 to G59; see chapter 5.1.2) are used, the machine parameter DiameterCorr value determines whether the G corrections are considered at the determination of the contact point or not. DiameterCorr = 0 The G corrections are not considered at the determination of the contact point. The display shows the value relative to the origin. DiameterCorr ≠≠≠≠ 0 The G corrections are considered at the determination of the contact point. The display shows the value relative to the part position offset.

9.4.2 Control reset, end of program After power on, control reset and end of NC program the value in the machine parameter DiameterResetState defines which diameter programming mode (G190 - G193) is active.

9.4.3 Display functions The "diameter programming" function enables the display of the point of contact referring to the diameter or to the radius dimension. G190 Display of tool reference point in radius dimension G191/G192 Display of point of contact in diameter dimension G193 Display of point of contact in radius dimension

Page 289: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 289/376

Figure 9-11: Diameter Programming Point of Contact

9.4.4 Programming conditions When using diameter programming (G191), note the following conditions listed in the table. In the subsequent notes, it is always assumed that the axis with address letter X is the diameter programmable axis.

Item Notes X axis command specified with a diameter value Incremental command (G91) specified with a diameter value Cycle parameters in X axis command (X=P12) specified with a diameter value Set X axis value (G92) specified with a diameter value X Part position offset (G54-G59) specified with a diameter value Circular parameters (I, J, and K) specified with a radius value exception: G2 or

G3 For these commands it depends on the setting of bit 2 in the machine parameter DiameterAppl. Bit 2 = 0 � radius value Bit 2 = 1 � diameter value This is valid if the axis to which the parameter belongs is diameter programmable. For example I to X, J to Y, etc.

Feed rate along X (F word) specified in radius/min specified in radius/rev

X axis position display displayed in diameter dimension Tool radius compensation (D) specified in radius dimension Tool length compensation (H) specified in diameter dimension

Table 9-3: Diameter programming conditions

Page 290: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 290/376

9.4.5 Programming Examples In the subsequent examples, it is always assumed that the axis with address letter X is the diameter programmable axis.

9.4.5.1 Example program using G191

N10 G1 X0 F4000 Moving of the X-axis to the X0 position(orientation)

N20 G191 Activate the diameter programmingN30 X200 Move to position X100 (radius) and display

X200 (diameter)N40 G190 Deactivate the diameter programming and

switch-over of the display to X100N50 M30

9.4.5.2 Programming example with G192

N10 G1 X100 F4000 Moving of the x-axis to the X100 position(orientation)

N20 G192 Display of the tool tangential pointreferring to the X200 diameter; no motion.

N30 X200 Move to X200 (radius) and display the X400position (diameter)

N40 G190 Deactivate the diameter programming andswitch-over of the display to X200

N50 M30

9.4.5.3 Programming example with G193

N10 G1 X100 F4000 Moving of the X-axis to the X100 position(orientation)

N20 G191 Activate the diameter programming and displayX200 (diameter)

N30 G193 Display of the tangential point at the actualdiameter X100 (radius). Programmed values arein radius.

N40 X200 Move to X200 and display X200N50 G190 Deactivate diameter programming (Display

shows the tool reference point, programmedvalues are in radius

N60 M30

9.4.5.4 Example program with negative orientation

With DiameterAppl Bit 1 = 0 N10 G1 X-100 F4000 Move the X-axis to the X-100 position

(orientation)

Page 291: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 291/376

N20 G191 Activate the diameter programming anddisplay X-200 (diameter). There is nomoving.

N30 X100 Move to position X-50 (radius) and displayX-100 (diameter)

N40 G190 Deactivate the diameter programming andswitch-over of the display to X-50

N50 M30

9.5 Distance Regulation

The Distance Regulation feature requires associated additions to a typical NC program to obtain the desired behavior.

9.5.1 G265 Axis selection Syntax:

G265 X... Y... Z... Axis selection

The axes to be distance regulated and their direction vectors can be preset. A new axis selection can additionally be programmed with the code G265.

The values programmed with the address letters of the axes determine the new direction vector. These values are standardized internally.

Example: ...Nxx G265 X0.5 Y0.5...

The new axis selection is valid from Nxx with the standardized direction vector (0.71, 0.71, 0).

Note:

If more than three axes are programmed, this is indicated by error message 433.

A new axis selection may only be programmed with inactive distance regulation, otherwise error message 432 is output. The activation code may be located in the same block as G265� and all other information in this NC block is ignored.

The axis selection programmed by G265 ... is reset to the presetting at deactivation of distance regulation and at Control Reset.

9.5.2 M140 / M141 activation/deactivation of distance regulation Syntax:

M140 Distance regulation ON using the preset BCD code M141 Distance regulation OFF

Page 292: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 292/376

Distance regulation is activated by the code M140. The effect is that the distance between tool tip and work piece is regulated to a constant value when a programmed path is traveled. This enables compensation of deviations in the actual work piece geometry from the programmed work piece geometry. An NC block with M140 may contain path information.

With 5-axis machines when transformation is active regulation is performed in the work piece direction when all transformed linear axes have been distance-regulated. If an axis in the current selection is not affected by transformation (e.g., a 3-axis machine), this is not further regulated with active transformation. The offset built up by this time is maintained. If not all axes involved in transformation are distance regulated then the regulation is in the direction of the current direction vector.

Example: N10 X0 Y0 Z0 F1000N20 G81N30 M140 X20

NC block N20 activates 5-axis transformation and N30 activates distance regulation. Regulation is in the work piece direction if the first three axes of the machine are preset.

M141 deactivates distance regulation again. The NC block may not contain any further codes or path information. When distance regulation is deactivated, there is no compensating movement to the programmed position. The position resulting from distance regulation is used for the next NC block as the starting position, by means of a synchronization process. This prevents damage to the tool tip and the work piece.

9.5.3 Monitoring the axis limits

When distance regulation is active the axis limits of distance-regulated axes are monitored in real time. If during processing of an NC block a point is reached where the axis limits are exceeded, interpolation is stopped and error message 211 is displayed.

9.5.4 G74 is invalid

G74 Homing is not allowed with active distance regulation. Error message 431 is displayed.

Note:

With active distance regulation, if the Feed enable or Drive ON signal is removed for one of the axes to be regulated, the offset built up by then is retained. The voltage value continues to be read in, but regulation no longer takes place. Regulation is only continued when the Feed enable or Drive ON signal is re-applied.

Page 293: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 293/376

9.6 Feed Influencing via Probe Signals The Feed Influencing via Probe Signals feature requires associated additions to a typical NC program to obtain the desired behavior using a probe. This feature is similar to the M80 (delete remaining path) described earlier except that there are external programmable input signals possible for the probe inputs rather than dedicated probe input used for the M80.

9.6.1 General

There are 16 rapid inputs (2 bytes) available and there are three ways of influencing the feedrate. The probe input bit among the possible two bytes is indicated in the part program using an M-code for each bit.

M151 � probe input byte 1, bit 1 is the active probe signal M152 � probe input byte 1, bit 2 is the active probe signal M153 � probe input byte 1, bit 3 is the active probe signal M154 � probe input byte 1, bit 4 is the active probe signal M155 � probe input byte 1, bit 5 is the active probe signal M156 � probe input byte 1, bit 6 is the active probe signal M157 � probe input byte 1, bit 7 is the active probe signal M158 � probe input byte 1, bit 8 is the active probe signal M161 � probe input byte 2, bit 1 is the active probe signal M162 � probe input byte 2, bit 2 is the active probe signal M163 � probe input byte 2, bit 3 is the active probe signal M164 � probe input byte 2, bit 4 is the active probe signal M165 � probe input byte 2, bit 5 is the active probe signal M166 � probe input byte 2, bit 6 is the active probe signal M167 � probe input byte 2, bit 7 is the active probe signal M168 � probe input byte 2, bit 8 is the active probe signal

9.6.1.1 Influencing the feedrate without Stop

No stop occurs in the axis feed movement. The rapid input signal just causes a block transfer. Thus a change in the feedrate is possible through the application of external digital signals.

9.6.1.2 Influencing the feedrate with stop and return movement

The feed movement is stopped immediately without any slope in the axial speed curve (a �hard� stop). In the case that a return movement has been programmed, this occurs afterwards. The change of program line occurs after this.

9.6.1.3 Influencing the feedrate with Stop

Page 294: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 294/376

In this instance the feed movement is not stopped immediately (a �soft� stop), but is stopped by inserting a new nominal value.

9.6.2 Programming

With a G170, G171 or G172 (applicable) the following options can be activated in advance. The choice of one given option excludes the use of the other.

Syntax: G170 (without axis information) no return motion,

block transfer with an instantaneous “hard”stop

G170 X0.1 Y0.01 (with axis information) instantaneous “hard”stop and then return motion in the X-axis byabout 0.1, in Y-axis by about 0.01

G171 Block transfer without StopG172 (without axis information) block transfer with

a “soft” stop without return motionG172 X0.1 Y0.01 (with axis information) block transfer with a

“soft” stop and return motion in X-axis byabout 0.1, in Y-axis by about 0.01

Example:

N10 G170 Define no return motion.N20 G1 X100 F100 M151 Proceed in the direction of X100 and

upon recognition of input 1, perform ablock transfer and initiate aninstantaneous “hard” stop of the axes,display X100.

N20 G170 Y0.2 Define a return movement of Y = 0.2 mm.N30 Y100 M152 Proceed in the direction of Y100 and

upon recognition of Input 2 initiate areturn motion of the axes and a blocktransfer, display Y100.

N40 G171 Definition without stop.N50 X0 M153 Proceed in the direction of XO and upon

recognition of Input 3 initiate blocktransfer, display X0.

N60 G172 Define a Stop.N70 Y0 M154 Proceed in the direction Y0 and upon

recognition of Input 4 a “soft” stop ofthe axes is initiated, display Y0.

N99 M30

Since the movement on the return path occurs without a slope, monitoring of the maximum permitted stroke per axis occurs. This path is computed as follows from several machine parameters:

Return path = GainSpeedFactor * FastIOReturnMaxAppl

Page 295: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 295/376

The machine parameter factor FastIOReturnMaxAppl is assigned according to the situation. If the path goes into overrun, an error message is given and the pre-processing of the program line stops.

Note:

G170 is active after a control reset.

The enabling of the probing logic (G170 to G172 and also M170, M171) must be done when G01 is modal and when the modal feedrate is greater than 0. If both of these conditions are not met then error message 196 will result.

9.6.3 Programming measurement probe logic

A bit mask can be defined by programming the NC or the PLC. If the bit so released is used, the function �measurement probe logic� is initiated and causes the following.

Note:

M159 indicates that the PLC cannot define the bit mask for the probe signals; M159 is active after a control reset.

M160 indicates that the PLC can define the bit mask for the probe signals.

9.6.4 Masking out input bits via the PLC

The PLC can deactivate certain input bits using two further interface bytes. The bit activated by NC programming is only active if the corresponding bit of the interface byte is being used. If that bit is not used, then activation by the NC programming will be ignored. This function is only active after applying the corresponding interface bytes (see Instructions for Start Up and for programming the PLC Interface)

9.6.5 G92 and setting the remaining distance to zero

After a control reset, the remaining distance offset and the zero point coordinate offset (G92) remain intact. With a G92 statement, without axis information, the remaining distance offset is set to null. The remaining distance offset is also set to null when activating M171, the function �Stop pre-processing the program line�.

9.6.6 Measurement probe logic via the interface signal

In this case the function �measurement probe logic� is activated via a fast input signal. Since this measurement signal does not lead to an immediate storage of the measured position, the positioning precision is not as great as when the activation occurs due to a measurement input.

Page 296: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 296/376

9.6.7 Dwell time

The function �Digital Measuring Signals� is also effective for a programmed dwell time.

Example: N10 G1 F500N20 G4 F5000 M161 When input 9 (byte 2 bit 1) is recognized,

program line N20 is stopped and a blocktransfer to program line N30 occurs.

N30 X100 M162N99 M30

9.6.8 Programming with Stop on block pre-processing

This function �stop the pre-processing of program lines� is activated in NC programming using an M code. This operates modally, that is until it is deactivated. If the function �Digital Inputs� is activated, then, for example, it is possible to have branching to subroutines and similar possibilities. The preprocessing of program lines will continue after the next program block transfer.

M170 do not stop the pre-processing of program lines – a subsequent G92 in a block alone will not remove the G92 offset introduced by the probe contact

M171 the pre-processing of program lines is stopped – this is needed if the program or subroutine will perform a G92 to extract the axis offset from a probe contact

Note:

M170 is effective after a control reset.

9.7 Feed Interpolation

The Feed Interpolation feature requires another code (an E-value) within the program to obtain the desired behavior.

9.7.1 Function and handling

The �Feed Interpolation� function guarantees that the path velocity can be continuously changed during the processing of an NC block. During the processing of an NC block, a programmed feed modification is interpolated in parallel to and depending on the path interpolation.

The following applies:

Fcur: = Fold + (Fnew - fold) * (Scur/ Stot) Fcur = current feed Fold = Feed of the previous block Fnew = Feed of the current block Scur = path of the current NC block already traversed

Page 297: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 297/376

Stot = total path of the current block

The function works in the NC block in which the setup NC address is programmed.

Example: Feed interpolation is setup using the NC address E.

NC program:

N010 G01 X100 F200N020 G01 X50 F100N030 G01 X30 F50 E1. . .N100 G01 X100 F200 E1 N010 = X runs with 0.2 m/min to 100 mm N020 = X runs with 0.1 m/min to 50 mm N030 = X starts with 0.1 m/min and reduces the speed so it is 0.05 m/min at the end of

the block (at 30 mm). N100 = X starts with 0.05 m/min and increases the speed so it is 0.2 m/min at the end of

block (at 100 mm). Note:

When traversing with acc/dec slopes, the target speeds are not accomplished to a 100 percent since the deceleration is activated before reaching the end of block.

The CNC does not verify whether the acceleration limits of individual axes are exceeded by this function.

The feed override also works while the function is active.

The function can also be programmed together with the rotational speed interpolation (the �electronic gear�).

The function can be used for linear and circular interpolations.

Page 298: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 298/376

9.8 Handwheels in Automatic mode

9.8.1 General

This function allows one or several axes with the handwheel in Automatic mode to move. The movement of the selected axis results in an offset to the programmed movement. The axes could be selected with the NC-program block or via PLC interface signal. The offset values of the handwheel movement can be transferred to a block of cycle parameters.

9.8.2 Programming

M200, M201-M208, M209, M210, M211

Syntax:

M200

With M200 the handwheel in automatic mode function will be activated.

The following M-code functions, with the axis selection via the NC-block (M201-M211) or via the PLC-interface signals, can only be activated after the M200 is activated:

M201-M208 With this M-code the axis-selection of axis 1 (M201) to axis 8 (M208) will be activated.

M209 This M-code activates several axes. The axis selections and their handwheel factors will be programmed with the NC-axes addresses present in this block. The default increment is 1 micron per handwheel click. For example, if an axis will handwheel in G70/inch mode and an increment of 0.0001� is desired, then the block sequence of N100M200 followed by N110M209X2.54 (for a factor of 2.54) will result in each click moving X 0.0001�. M209 with no axis selection/factor disables previously any active selection.

M210 With this M-code the input of the handwheel counts will be suppressed. The offsets established with the handwheel are still active but the reading of the handwheel will stop. The input of the handwheel is activated again with M201-M208.

M211 This M-code switches off the handwheel function. The handwheel offset itself is not active any longer and the values of the handwheel offsets will be transferred to a block of cycle parameters. Any handwheel offsets will be removed and the programmed positions will match the current positions.

Upon the M211, all eight of the cycle parameters will be written with the current offsets from the handwheel activity. The start of this block of 8 parameters is configurable.

Page 299: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 299/376

After M211 several intermediate blocks will be created.

If the M211 block also has a distance programmed then the error message 434 is displayed.

Example:

N10 G1 F1000 Default feedrateN20 M200 Activation of the handwheel functionN30 M201 X100 M201 - the handwheel offsetting for X-axis

is activated while X movesN40 X100 Y50 X-axis handwheel is still activeN50 M202 X50 M202 - the handwheel offsetting for Y-axis

is activated while X movesN60 M209 Handwheel offsetting ignored for both X-

and Y-axesN70 M210 Reading of the handwheel not activeN80 X55 Y100 Handwheel offset values are still active

because the handwheel function is stillactive but not reading

N90 M211 Handwheel function will be deactivated,removing any handwheel offsets

N100 M30

9.8.3 End of program and control reset

The handwheel function will be switched off at the end of program and after a control reset.

A transfer of the handwheel offsets to a block of cycle parameters will not occur during these events (like done with M211).

9.8.4 Cycle-Stop, Cycle-Off

With the cycle-stop or cycle-off conditions during an active part program, the selected axis can still be moved with the handwheel.

Example:

N10 G1 F1000N20 X100N30 M201 Handwheel with X.N40 M00 M00 results in a programmed stop. The selected

axis (X) can still be moved with the handwheel.With a subsequent "cycle start" the blockprocessing will continue with the next block(with handwheel offset in X, if any).

N90 M30

Page 300: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 300/376

9.9 Infinitely Rotating Round (or Rotary) Axis The Infinitely Rotating Round (or rotary) Axis feature requires several changes or additions to a typical NC program to obtain the desired behavior.

9.9.1 General

The function �Infinitely rotating round axis� handles the endless moving of an axis in one direction. In this scenario, the position of the axis is reduced automatically to the range of 0 to 360 for the round axis, without any influence on the axis motion. In particular, this reduction has no effect on the moving of other axes (including linear axes) of the control.

Altogether, there are three different variants of the infinitely rotating round axis:

• Normal round axis

• Round axis drives always on the shortest way to the programmed position (such as a tool magazine axis).

• Modulo round axis.

In the following paragraphs, the features and the NC programming of all three variants are described.

Altogether eight round axes are possible, but the number of modulo round axes is restricted to three.

9.9.2 Programming

The programming of a round axis follows mainly in analogy to that of linear axes. How certain movements of round axes must be programmed is different on the three variants of round axis.

Like for a linear axis, the NC programming is done with the address letter of the axis. For the modulo round axis the number of revolutions can be programmed additionally by means of a fixed address letter.

For a round axis it is characteristic that after a complete revolution of the axis the same machine position is reached. Therefore, any position of a round axis is uniquely determined by a value, which is in the interval 0° to 360°.

Note: Depending on default values the travel range corresponding to one revolution of round axes can be different. Nevertheless, in the following it is assumed that one revolution of the axis corresponds to 360°.

Page 301: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 301/376

9.9.3 Normal round axis

The programming of the normal round axis is done in the usual way with the address letter of the axis. The programmed value determines the axis end position. However, the sign is not considered, but it determines only the rotation direction of the round axis. For example, the A axis drives after programming of

N.. A90to the position A = 90° with positive rotation direction. Alternately, if one is programming N.. A-90

the position A = 90° is reached with negative rotation direction (see figure below).

Figure 9-12: Rotations of a normal round axis

On active G90 (absolute coordinate programming) the programmable positions are limited to the range 0° up to 360°. If a greater value is programmed a corresponding error message is generated. That means in one NC block maximum one rotation can be driven. If more than one rotation shall be driven in one NC block, first G91 (relative coordinate programming) has to be activated. On active G91 the programmable value is not limited and hence more than one rotation can be driven in one block. The programmable values for a round axis are presented in the table below. (The values in the table are not the absolute positions in degrees but only the values that can be programmed.)

Active range A G90 -360 < = A < = 360 G91 any value

Table 9-4: Programmable values for a round axis

Page 302: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 302/376

For example the A axis has the position A = 90°, then it is driving after programming of

N.. G91 A370

to the absolute position A = 90° + 370° = 460° ⇔ 100° with positive rotation. (That corresponds to the movement of 1 rotation plus 10°.) On reaching the position A = 360° the axis value is reduced to 0°. This is also visible in the axis display of MMI.

If one is programming

N.. G91 A-740

the A axis drives 2 revolutions plus 20° with negative rotation.

The absolute position A = 0° can be programmed in two different ways. If it shall be driven to A = 0° with positive rotation, one must program A0 or A360. The axis drives to A = 0° with negative rotation, if one programs A-0 or A-360.

Example: In the following program example it is assumed, that X and Y are linear axes of the machine and A is a round axis.

N10 G90 X0 Y0 A0 F1000N20 X10 Y20 A90N30 X20 Y30 A-315N40 G91 X50 Y50 A360N50 M30 In the block N10 all axes move to the position 0. After that the linear axes drive to X = 10 mm, Y = 20 mm and the round axis to A = 90°. In the next block N30 the axes drive to X = 20 mm, Y = 30 mm and the round axis to A = 315°. On that movement the A axis rotates in negative direction. In the block N40 relative coordinate programming is activated. The linear axes drive 50 mm and reach the positions X = 70 mm, Y = 80 mm. The round axis makes one rotation in positive direction. The movements of the axes are presented in the figure below.

Page 303: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 303/376

Figure 9-13: Rotations of A axis (normal round)

9.9.4 Tool magazine round axis

The tool magazine round axis drives always the shortest way to the programmed position. Thus the round axis drives up to one-half rotation in one NC block (180°). The programmable values are different for absolute and relative coordinate programming, respectively, in the table below.

Active Range A G90 0° < = A < = 360° G91 -360° < = A < = 360°

Table 9-5: Programmable values for a tool magazine axis

If other values are programmed in a NC program an error message is generated.

How a programmed position is approached depends on the actual position of the round axis. For example, the position A = 90° is reached with positive rotation after programming of

N.. G90 A90

if the previous position was A = 0°. If the previous position was A = 180°, the position A = 90° is reached with negative rotation direction.

On active relative coordinate programming the round axis drives the programmed angle relative to the previous position. If the programmed angle is greater than a half rotation of 180°, the rotating direction is reversed. For example after programming of

N.. G91 A315

Page 304: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 304/376

the axis is not rotating from 0° to 315° with positive direction if the previous position was A = 0°, but it rotates with an angle of 45° in negative direction (see figure below).

Figure 9-14: Tool magazine round axis

9.9.5 Modulo round axis

The programming of the modulo round axis is different of that of the other round axis types. Additionally to the programming of position, it is possible to specify the rotation or revolution number (sometimes also called the round number). The rotation number is the same as the number of axis revolutions. The programming of rotation number is accomplished with an extra address letter. The standard letters for that programming are I, J and K for the three possible modulo axes, respectively. However, the default values can also be other address letters.

It is not possible to program in a NC block only the rotation number of a modulo axis, but it has to be programmed simultaneously a value for the position (normal address letter of the axes). For example, the position of the axis is A = 45° (I = 0) and two complete rotations are required so this statement is required:

N.. A45 I2

On active relative coordinate programming (G91) the programmed axis position as well as the programmed rotation number is evaluated incrementally. That means after programming of

N.. G91 A45 I3

the modulo axis drives 3 rotations plus an angle of 45° with positive rotation direction (see the figure below, where 3 rounds = 3 rotations).

Page 305: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 305/376

Figure 9-15: Modulo round axis

In the axis display on the MMI the programmed rotation number of the end point as well as the actual rotation number are shown in addition to the position. The rotation numbers (or the number of revolutions) that are displayed on the MMI are limited to the range -999 to 999. However, this limitation has no effect on the travel range of modulo axes, but only for rotation numbers that are outside the interval the corresponding maximum values are displayed. Moreover, the actual rotation numbers are simultaneously available in cycle parameters. It depends on default values which cycle parameters are used. These cycle parameters can be accessed in a NC program in order to influence the program execution depending on the actual rotation numbers of modulo axes.

The rotation counters of modulo axes are reset to zero on control reset and on program end.

The traveling rotation numbers of modulo axes is principally unlimited (see the following remark). In contrary to that the value that is programmed with the normal axis letter cannot be arbitrary. The possible values are listed in the table below.

Active Range A G90 0° < = A < 360° G91 any value

Table 9-6: Programmable values for a modulo axis

Page 306: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 306/376

Note:

The maximal rotation number that can be traveled in one NC block is limited. The limitation depends on the resolution of the round axis and from units that correspond to one revolution of the axis. For example the maximal rotation number is R = 41 for a round axis with a resolution of three digits after the point (µ resolution) and a rotary number of 360°. For higher resolutions of the axis the maximal rotation number is reduced correspondingly. If a rotation number outside the maximal range is programmed, a corresponding error message is generated. This limitation is only valid for the rotation number that can be traveled in one NC block. However, the total traveling rotation number is not limited.

The cycle parameters, which are used for the storage of rotation counters, should not be used for other purposes. That means, if the rotation counters are requested in the NC program, these cycle parameters must not be used elsewhere, otherwise an incorrect execution of the NC program results.

Page 307: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 307/376

9.10 Multiple Spindles The Multiple Spindles feature requires associated changes or additions to a typical NC program.

9.10.1 General

The first spindle in the system is termed �Main spindle�. The additional spindles, up to a maximum of five, are called �Minor spindles�. The function �Automatic gear shifting� is only possible for the main spindle. The minor spindles feature all other spindle functions apart from this, i.e., feedback, spindle orientation, feed rate in mm/rev, constant cutting speed, constant circumferential speed, thread cutting and spindle/rotational axis switchover.

9.10.2 Spindle programming

Spindle programming is performed with an M-code and an S-value. The spindle last programmed is always the active spindle. The programmed S-value refers to the currently active spindle. All programmed rotational speeds and directions are maintained. If several spindles have set up the same axis or D/A channel, the output is made to the spindle last programmed.

For the main spindle (first spindle) the previous M codes are used.

M03 spindle 1 on, clockwise M04 spindle 1 on, counter clockwise M05 spindle 1 off, spindle stop

The M-Codes for the other spindles are usually found in the 200 range (but the first M-code for each spindle is configurable).

M213 spindle 2 on, clockwise M214 spindle 2 on, counter clockwise M215 spindle 2 off, spindle stop M223 spindle 3 on, clockwise M224 spindle 3 on, counter clockwise M225 spindle 3 off, spindle stop

The S-value does not have to be reprogrammed after each spindle change. If no S-value is specified after a spindle change, the last S-value programmed for this spindle is valid.

Example: N10 M213 S4000 spindle 2, clockwise, S = 4000 rpmN20 S2000 spindle 2, clockwise, S = 2000 rpmN30 M03 S800 spindle 1, clockwise, S = 800 rpmN40 M214 spindle 2, counter clockwise S = 2000 rpmN99 M30

Page 308: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 308/376

9.10.3 Thread cutting, G33 and G34

The function �Thread cutting� is activated with G33 and G34 for the selected spindle. The function remains active for the spindle after it is deselected; i.e., the spindle�s actual rotational speed is used for calculating the feed rate. Thread cutting is only ever active for one spindle at a time. Activation for another spindle is made after reprogramming G33 or G34. The spindle does not have to be reselected for deactivation, i.e., to alter the interpolation type (e.g., G01).

Note: The function �Thread cutting� can only be activated for spindles with feedback.

Example: N10 M213 S8000N20 M03 S400N30 G33 X10 I1 thread cutting with spindle 1N40 X20 I2 following threadN50 M213 S800 continue thread cutting with spindle 1N60 X30 I1 no following threadN70 G33 X40 I1 thread cutting with spindle 2N..N9999 M30

9.10.4 Spindle speed override rotary switch, G63

The position of the spindle rotary switch has a direct effect on all spindles.

The function G63 �Spindle rotary switch off� and G66 �Spindle rotary switch on� are also directly effective for all spindles. The spindle percentage value programmed at G63 with S becomes effective for all spindles immediately.

By means of special machine parameters, the spindle rotary switch can be adjusted so that it does not affect individual spindles; i.e., the spindle rotary switch has no influence on the rotational speed of spindles, which are appropriately set up. The percentage value programmed with G63 also has no influence on the rotational speed.

9.10.5 Spindle speed restriction, G92

There are three possible rotational speed restrictions:

• setup spindle restriction,

• grinding wheel restriction and

• G92 spindle restriction

If all are simultaneous effective, the smallest restriction is used.

Page 309: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 309/376

Example: N10 M03 S1000 spindle 1 rotates with S=1000 rpmN20 G92 S500 spindle 1 is restricted to S=500 rpmN30 M213 S3000 spindle 2 rotates with S=3000 rpm,

restriction is not activeN40 G92 S2000 spindle 2 is restricted to S=2000 rpmN50 M03 S1200 spindle 1 is restricted to S=500 rpmN60 G92 restriction is lifted for spindle 1

N...N9999 M30

The spindle restriction programmed with G92 still remains effective after CONTROL RESET and end of program. The restriction can only be lifted by programming G92 or by restarting the CNC.

An S-value primarily affects G92.

Example: N10 M03 S1000N20 G92 S1500 gives a spindle restriction for the first

spindle to S=1500 rpm. The rotationalspeed is not changed.

N..N99 M30

Note: Any part position offsets programmed with G92 are also reset.

9.10.6 Feed rate in mm / rev, or in / rev, G95

The function �Feed rate in mm/rev or in/rev� is activated for the current spindle with G95 and can only be active for one spindle. The function remains active for this spindle after it is deselected, i.e., the actual speed of the spindle is used to calculate the feed rate.

Reprogramming G95 can become active for another spindle. The spindle does not have to be reselected for deactivation with G94.

Note: The code G95 can only be applied for spindles with feedback.

Example: N10 M03 S100N20 G95 F1 X10 Rotational speed of spindle 1 is usedN30 M213 S300 X20 spindle 2 is the active spindle,

rpm of spindle 1 is still usedN40 G95 F2 rpm of spindle 2 is usedN50 X30N60 G94 G95 is deactivatedN..N99 M30

Page 310: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 310/376

9.10.7 G93, G96 and G97

The rotational speed of a spindle can be determined in three different ways:

• G97 S = spindle speed in RPM

• G96 S = constant cutting speed in m/min or feet/min

• G93 S = constant circumferential speed m/min or feet/min

These functions are all mutually exclusive. After CONTROL RESET, the state that was set up is active.

Note: Programming of one of the three G-Codes automatically deactivates the previously active function.

9.10.7.1 Constant cutting speed, G96

The function �Constant cutting speed� can be simultaneously active for several spindles. For the calculation of the cutting speed the position of the setup transverse axis for each spindle is used.

For the active spindle, the function �Constant cutting speed� can be activated with G96. The function remains active for the spindle after it is deselected. This spindle must be reselected to deactivate the function using G97 or G93 and for re-programming the cutting speed (S-value).

An additional activation for the function �Constant cutting speed� is possible for another spindle after the activation of the spindle using G96.

As long as no S-value has been programmed with G97, the current spindle speed is retained.

Example: N10 M03N20 G96 S100 F10 X20 speed of spindle 1 is at cutting speed

of S = 100 rpmN30 M213 X10 spindle 2 is the active spindle, speed

of spindle 1 is at cutting speed of S=100 rpm

N40 G96 S30 F20 speed of spindle 2 is at cutting speedof S = 30 rpm. Speed of spindle 1 isstill at cutting speed of S=100 rpm

N50 X5N60 G97 G96 is deactivated for spindle 2. Speed

of spindle 1 is still at cutting speedof S =100 rpm.

N99 M30

Page 311: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 311/376

9.10.7.2 Constant circumferential speed of a grinding wheel, G93

This function is activated using G93 for the current spindle and deactivated using G96 or G97. The circumferential speed of the grinding wheel is programmed using an S-value and the grinding wheel diameter is programmed with K.

K is only recognized as grinding wheel diameter using G93. If G93 is not programmed in the same block, K is taken as circular interpolation.

By programming the tool number (e.g., T11) the active spindle can be assigned a grinding wheel and also a grinding wheel diameter. This assignment using tool numbers has priority over a programmed K-value.

The function remains active for the spindle even after it is deselected. To deactivate or to reprogram the circumferential speed (S-value) or that of the grinding wheel (K-word), this spindle must be reselected.

The function �Constant circumferential speed� can only be activated additionally for another spindle after activating that spindle.

The rotational speed is determined by the CNC depending on the programmed circumferential speed and the current diameter. The rotational speed is automatically re-calculated after each change of the diameter. If no S-value is programmed after deactivation, the current rotational speed is retained.

In addition to monitoring the rotational speed, the maximum allowable circumferential speed can only be assigned to the spindle by tool programming. If the monitoring limit is exceeded, depending on the setup, further block processing is stopped and only error message 445 is output (see machine parameter description).

The function �Constant circumferential speed of grinding wheel� can be activated simultaneously for several spindles.

Calculation formula for rotational speed S

programmed S-value S = 2 Radius * π Example:

N10 M03N20 G93 S100 F10S100 K20

rotational speed of spindle 1 is adaptedto circumferential speed from S =100 rpmand the radius 10 mm

N30 M213 X10 spindle 2 is the active spindle, rpm ofspindle 1 is continued withcircumferential speed (S =100 rpm)

Page 312: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 312/376

N40 G93 S30 F20 T4 rpm of spindle 2 is adapted tocircumferential speed from S =30 rpm andthe radius of grinding wheel 4, rpm ofspindle 1 is continued withcircumferential speed from S =100 rpm

N50 X5N60 G97 G93 is deactivated for spindle 2 rpm of

spindle 1 is still adapted tocircumferential speed from S =100 rpm

N99 M30

9.10.8 Spindle orientation, M19

When M19 is programmed the setup stop speed is output as new set speed for the active spindle. In addition, a spindle with feedback is oriented at the position programmed with S. This is performed as soon as the stop speed is reached. The S-value indicates the angle between spindle marker and required set position.

Note: Spindle orientation is possible for all spindles and for several spindles at once.

Example: N20 M03N30 M19 S90 Spindle stop at marker position + 90 degreesN40 M19 S270 Spindle stop at marker position +270 degreesN99 M30

9.10.9 Spindle / rotational axis switchover

The function �Spindle / rotational axis switchover� set up one or more spindles to an axis channel. Any of the spindles in the system can be used. For programming, see the section �Switchover Spindle-rotational axis�.

9.10.10 Gear stages

The function �Gear stages� is only allowed for the main spindle (first spindle). For programming, see the section �Spindle Gear Stage Selection�.

Page 313: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 313/376

9.11 Parallel Axes The Parallel Axes feature requires two G-codes to activate and deactivate the feature.

9.11.1 Syntax G21 Activate parallel axesG22 Deactivate parallel axes

The activation of the parallel axes function is done by programming G21. The parallel axes defined with machine parameters (see machine parameter CharacterApplTab) are driven corresponding the respective leading axis. Depending on the mirroring of the leading axis the parallel axes drives contrary parallel or parallel to the leading axis. The parallel axes function works relative to the power-on position; that means the parallel axes only runs the difference to the power-on position parallel or contrary parallel to the leading axis. If it is desired to run the parallel axis parallel to the mirrored leading axis this has to be programmed explicitly with G38. The current position of the parallel axis is not shown on the display. After deactivation of the parallel axes function via G22 the parallel axis is normally moved out of power-on position. The distance the parallel axis is moved out of power-on position internally has the same effect as the programming of G92 for a new zero adjustment. Therefore it is recommended to program G92 without axes information after deactivation of the parallel axes function to set the machine back to its original coordinates.

Note:

With G21 active a programming of the parallel axes results in an error message. In connection with G38 the parallel axes may be programmed. An axis is supposed to be programmed even it is within an active level and a circle interpolation type (G02, G03, G12, G13, G07) is active.

In manual mode the parallel axes always are autonomous axes. Therefore it is not possible to move them simultaneously with the respective leading axes.

When programming a parallel axis with G74 (programmable reference point drive on) G22 must be programmed in advance.

In contrary to the gantry-axes function the parallel axes function generally does not result in a parallel movement of the machine axes, if the leading axis is a transformed axis.

9.11.2 Program examples

Page 314: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 314/376

9.11.2.1 Example 1

Possible error message on activation of the parallel axes:

N10 G17 Level selection, e.g., X, Y-levelN20 G02 Circular interpolationN30 G21 Error message if X or Y is a parallel axis...

9.11.2.2 Example 2

Assumption:

Four axes control with the axes X, Y, U and V. On activation of the parallel axes U is parallel to X and V is parallel to Y.

N10 G01 X100 Y0 U0 V100 F1000 Move to position:X= 100, Y= 0, U= 0, V= 100

N20 G21 Activation of parallel axesN30 X0 Y100 Move to position:

(no information on display)X= 0, Y= 100, U= -100, V= 200

N40 Y200 Move to position:X= 0, Y= 200, U= -100, V= 300

N50 G22 Deactivation of parallel axesN60 G92 Reset the axes position to

machine position

9.11.2.3 Example 3

N10 G01 X100 Y0 U0 V100 F1000 Move to positionN20 G38 X1 Mirroring X-axisN30 G21N40 X0 Y100 Move to position:

X= 200, Y= 100, U= -100, V= 200X and U move anti-parallel

N50 G22 Deselect parallel axes functionN60 G92 Reset the axes to the original

machine coordinates

Page 315: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 315/376

9.12 Polar Transformation The Polar Transformation feature requires associated additions to a typical NC program to obtain the desired behavior.

9.12.1 General Syntax:

G101 Polar transformation ON, programming with axes X, YG105 Polar transformation ON, programming with other axis

lettersG100 Polar transformation OFF

The real-time polar transformation is activated with the instruction G101. It allows the programming of processing steps involving both a rotational and a linear axis. Here the relative orientation of rotational and linear axes (i.e., of tool and work piece) is constantly changing. The real-time polar transformation enables processing steps to be programmed in a coordinate system that rotates with the rotational axis (i.e., work piece orientated). This is illustrated below using the example of a square contour that would be very costly to achieve without real-time polar transformation.

If neither G14 nor G15 is activated, the programming is done using Cartesian coordinates. If G90 is active, programming is done using the absolute dimension, if G91 is active programming is done using incremental dimensions. Either G70 (programming in imperial format) or G71 (programming in metric format) can be active.

To be able to program in polar coordinates after G101, the instruction G14 �polar coordinate programming using absolute dimensions� or the instruction G15 �polar coordinate programming using incremental dimensions� must be selected in addition to G101. The polar transformation is deactivated with the instruction G100.

When polar transformation (G101) with polar coordinate programming (G14 or G15) is active, then the values programmed in connection with the axis address X are interpreted as angles, and the values programmed in connection with the axis address Y as radii. The prerequisite for programming with the axis addresses X and Y is that the plane G17 is active.

To organize NC programs more clearly, the possibility exists to assign other axis addresses to the angle or radius value, e.g., �C� instead of �X� and �V� instead of �Y�. If these newly assigned axis addresses are to be used in programming, then the instruction G105 is to be programmed instead of G101. Exactly the same applies to this instruction as for the instruction G101 apart from the changing of axis addresses.

Thus the allocation of new axis addresses is only meaningful if programming is done using polar coordinates. These new axis addresses are also to be used with the barrel cam transformation with active G106.

Page 316: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 316/376

If the machine tool manufacturer has made use of the possibility to allocate other axis addresses, please refer to machine tool manufacturer's documentation for details about this.

In all of the following examples the axis addresses X and Y are used. By substituting the instruction G101 by G105 and the axis addresses X and Y by the letters allocated in your configuration you can easily adjust the examples to suit your individual needs.

9.12.2 Examples

A square contour is to be machined from a work piece that is clamped onto a rotational table. The figure below shows the location of the points to be moved to, in (work piece oriented) polar coordinates and in Cartesian coordinates.

Example for the polar transformation using polar coordinates programming (G14):

X

Y

90°

180°

270°

-10 10

10

-10

X0 Y20 / X90° / Y20 * 2

X20 Y-20 / X315° /

N20 N60

N30

N40

N50

X-20 Y20 / X135° / Y20 * 2

X20 Y20 / X45° / Y20 * 2

X-20 Y-20 / X225° / Y20 * 2

20 * 2

Y20 * 2

Figure 9-16: Motion path for G101 example: processing a square contour

Program example with G14:

N5 G101 N10 G14 X90 Y20 F500 N20 X135 Y28.284 28.284 corresponds to 20x√2 N30 X225 N40 X315 N50 X45 N60 X90 Y20 M30

Page 317: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 317/376

Program example without G14:

N5 G101N10 X0 Y20 F500N20 X-20N30 Y-20N40 X20N50 Y20N60 X0 M30

Assuming that the rotational axis is at the position 0° at the start of the program, then the NC blocks N5 - N60 produce the following processing sequence:

270°

180°

90°

linear axis

tool

rotational axis

abrasion

Figure 9-17: Square contour of a work piece before real-time polar

transformation

The different processing steps are shown in the following illustrations.

Page 318: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 318/376

270°

180°

90°

135°

225°

315°

45°

135°

225°

315°

45°

block N10

block N30

block N20

Page 319: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 319/376

45°

315°

225°

135°

360°

45°

315°

225°

135°

90°270°

180°

block N40

block N50

block N60

Figure 9-18: Square contour of a work piece during real-time polar transformation

Page 320: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 320/376

Explanation of the example:

The process is performed shown in the figure above (Figure 9-18).

If G14 is programmed or not this only determines whether the destinations of the individual travel movements are entered in polar coordinates or in Cartesian coordinates (compare Figure 9-17).

Note: Setting work piece zero points:

When G101 or G105 is active the zero position offsets programmed with the instructions G54 to G59 are only relative to the Cartesian interpolations plane and not to the machine axes. A new zero position programmed with G92 is also relative to this plane. It is possible to offset the zero position of the radial axis using an H-compensation. The misalignment between the zero position of the linear axis and the center point of the rotational axis is given with the H-compensation.

Example: N10 G101N20 H1...

The program section in this example causes the value of the compensation memory H1 to be taken into account as part position offset for the radial axis (Y axis).

A further option must also be mentioned in this context. In order not to limit the use of the H-compensations too much, it is possible to set up a separating line in the compensation memory. This makes it possible to use a part of the compensations for another axis. The separating line could be set up at the compensation value H15 for example.

The table could be set up so that the compensation values are normally effective on the Z-axis. If the following blocks are programmed in an NC program:

N10 G101…Nxx H10 then the compensation H10 is effective on the Z-axis.

If, on the other hand, the following sequence is programmed:

N10 G101…Nxx H16 then the compensation is effective throughout as a zero position offset of the Y axis, even when in the table the compensation value is allocated to the Z axis.

Page 321: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 321/376

If H16 is programmed outside of the transformation (i.e., when G100 is active) then H16 is also effective on the Z-axis.

To find out if such a separation of the compensation memory has been determined, please refer to the machine manufacturer's documentation.

Zero position offsets for the rotational axis can be programmed using the part rotation function (G51, G52).

9.12.3 Monitoring the axis limits

During polar transformation the �look ahead� monitoring of the axis limits is not active, however, the axis limits of the linear axis are still monitored in real-time.

If, during the processing of an NC block, a point is reached at which the axis limits would be exceeded, the interpolation is stopped and the error message 211 is displayed.

9.12.4 Illegal G-codes

The instructions G74 �Programmable homing�, G38 �Mirror� and G0 �Rapid traverse� are not possible when polar transformation is active. The error message 108 or 241 is output.

This is also output if an attempt is made to activate or switch off the transformation when G92-offset is still active. This also applies to offsets which arise due to mirroring.

It is therefore recommendable before activating or switching off the transformation always to program G92, in case an offset of the program zero point was previously active.

9.12.5 Switching operations in machine coordinates with polar transformation

When changing over from operation in machine coordinates (G100) to the polar transformation (G101) and vice versa, compensation (G-, D- or H- compensation) must not be active.

It is not possible to change over directly to the barrel cam transformation from the polar transformation. G100 must always be programmed before changing the transformation type.

The radial axis must always be at a position > 0 when the polar transformation is activated.

Page 322: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 322/376

If this is not the case the error message 145 is output. This is also output if an attempt is made to program an axis position in a block with a change over G-code.

9.12.6 Switching of the limits of the axes

In polar transformation, it is also possible to switch the monitoring of the axis limits for radial axes to a second pair of axis limits. Please refer to the documentation from your machine tool manufacturer to determine whether this option has been used. The primary purpose of this function is to allow the same work piece to be processed with different tools that are located on spindles in different dimensions.

9.12.7 End of program and change of the operating mode.

At the end of the program the operating mode is always switched back to operation in machine coordinates.

Simultaneously, a G92-offset, possibly active for the rotational axis, is calculated. When changing over from the operating mode �MANUAL� to �AUTOMATIC� the position of the rotational axis is always reduced to a value between 0 and 360.

9.12.8 Machine error compensation for polar transformation

Displacements of the machine coordinate system can be compensated for using this function. This is to avoid contour errors on machines whose coordinate zero point differs from the center of rotation of the rotational axis. The coordinate values of the machine's zero point with respect to the center of rotation are directly specified by G101/G105, for example:

G101 X10 Y20.

The address letters for the rotational and radial axes must be used when programming (i.e., X and Y in the above example). Axis letters are then only accepted from the CNC with G101/G105 when the function �machine error compensation for polar transformation� is possible.

If no value for X or Y is given with G101/G105, then the default values preset for this are used, for example:

G101 X10 or just G101

In the first example the value 10 is used for X and the default value is used for Y. In the second example the default values for both X and Y are used. How the programmed or default values are interpreted can be specified.

There are three possibilities:

Page 323: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 323/376

• The coordinate values are either interpreted as Cartesian coordinates (when G90/G91 is active) or as polar coordinates (G14/G15 active).

• The coordinate values are always interpreted as polar coordinates

• The coordinate values are always interpreted as Cartesian coordinates.

With polar coordinates the angle is programmed with X and the radius with Y.

The zero point of the machine's coordinate system can be preset or programmed. This means a suitable part position offset can be preset for any machine yet can also be changed at any time by the program, if the machine's zero point changes during opera-tion, e.g., due to the effect of temperature.

There are two different versions of machine error compensation. A presetting is used to specify which version is used.

In program version 1 a simple displacement of the Cartesian coordinates is made. The relationship between the machine's coordinate system (X', Y') and the work piece coordinate system (X, Y) in this instance is shown in the following figure:

X

Y

X'

Y'

U

V

Figure 9-19: Displacement of Cartesian coordinates

The displacement of the coordinate system is labeled U and V. These are also the values that are to be programmed with G101 or are to be preset. A complicated correction of the angle and radius of the machine coordinates is made in program version 2. The following figure depicts how the correction values for the radius r and the angle a are calculated from the machine's coordinate system displacements U and V.

Page 324: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 324/376

X

Y

U

VRr

a

Figure 9-20: Machine error compensation

The angular change a is determined by the displacement V in the Y direction. The radius correction consists of two components. The first component is dependent on the angular change and the second on the displacement U in the X direction.

Note: In contrast to the programmed values, the default coordinate values are to be given in internal machine coordinates.

9.12.9 Speed monitoring at polar transformation

The speed of the rotational and radial axes will be monitored, so that no magnification of the speed of the axes can occur.

It can be preset, if only the rotational axis or the radial axis or both axes should be monitored. The speed of the path of each NC block will be limited in this way, that the preset values for the speed of the axes will not be exceeded

There are several possible error messages for speed monitoring:

error 490: program fault; speed of the rotational axis is unlimited possible reason: it should be moved to the zero point of the machine; this is not

possible at polar transformation because at this point the speed of the rotational axis is not defined.

error 491: program fault; speed of the radial axis is unlimited possible reason: it should be moved to the zero point of the coordinate system;

this is not possible at polar transformation because at this point the speed of the rotational axis is not defined.

Page 325: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 325/376

9.13 Positioning Axis The Positioning Axis feature requires a different part program approach as a Positioning Axis is not capable of all the interpolation variations.

9.13.1 Introduction

Positioning axes are NC axes that are interpolated individually and with independent feed. The interpolation of a positioning axis is performed asynchronously to the interpolation and to block changes of other positioning or path axes. Positioning axes can be moved in three ways:

• in the 'Manual' and 'Reference point' NC operating modes in the same way as path axes;

• in the 'Automatic' NC operating mode via a NC program, parallel or alternative to path axes programs. Here, the �positioning part� of the NC program is not executed at first but only written to the �positioning memory�. The movement of the positioning axes is activated only by the PLC via an interface signal to the CNC after the axes have previously been enabled by the NC program using G188.

• via PLC-movement commands.

Note: Positioning axes are defined by machine parameters and can never be interpolated in the path operating mode.

A maximum of 32 positioning axes are possible.

With path axes also available, the processing (programming, implementation) of the positioning axes is partially different.

Page 326: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 326/376

9.13.2 Programming

Positioning axes can be programmed in the same way as path axes, e.g., using the NC block format. Within a NC program, both axis types can be programmed individually or commonly; i.e., a NC program can consist of a positioning section and/or a interpolating path section. The positioning section must always be at the beginning of the NC program. The positioning section can also be concluded by M2/M30, by G188, and in case of additional path axes by programming a path axis character. Within the positioning section, the positioning axes must be programmed separately; i.e., the positioning section embodies exactly one positioning section per programmed positioning axis. The positioning sections must keep the applied axis order of the positioning axes. A positioning section is concluded by programming another positioning axis character or by beginning the interpolated axes section. The following has to be noted while programming the positioning axes:

• only the following G-codes are possible: G00, G01, G04, G53 - G59, G63, G66, G70, G71, G90, G91, G98;

• all modally effective G-codes, all feed values and H-correction numbers are not automatically reset at the end of a positioning section or start of interpolating path section; an F-word must be programmed in the first block containing G01;

• at a certain axis position, a signal can be output to the PLC using G98. The length of the signal is programmed in F in milliseconds and also acts as a dwell time. Together with G98, traversing information is ignored;

• if a positioning axis is not programmed, its positioning memory is erased;

• the entire positioning memory is erased if an error occurs during programming.

While executing a NC program with a positioning section in the 'Automatic' NC operation mode, the traversing and dwell time blocks of the individual positioning axes are processed and written into the positioning memory. However, these are not executed! In the basic state, the size of the positioning memory has a capacity of 50 blocks per positioning axis, i. e. for every positioning axis, the positioning section of the NC program can have a maximum length of 50 NC blocks.

Page 327: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 327/376

9.13.2.1 Execution of motion

From the PLC program, the start of the positioning blocks occurs via an interface signal to the CNC (IN_POS_01 to IN_POS_05) and it is only processed in the 'Automatic' NC operating mode.

If the H- and G-correction value memory are changed in the CNC between 2 executions, the positioning memory are not automatically changed too but must be refilled by a renewed processing of the positioning program.

Using 'Cycle stop'

active positioning commands from CNC are halted, and

using 'Cycle Start'

the axes are restarted.

9.13.2.2 Execution in case of additional path axes

If additional path axes are available then the execution of the movement and dwell time blocks of the individual positioning axes stored in the positioning memory must be enabled via G188 in an NC program in the 'Automatic' NC operating mode. After G188 has been activated, every positioning axis can be individually activated via an input signal at any times. The activated positioning axes are independently interpolated of each other and of the path axes with their programmed feed. The program end of the active program can be reached only if all of the movements and dwell time blocks stored in the positioning memory have been processed; i.e., all programmed positioning axes must have been activated.

After the positioning axes have executed their programmed blocks, an end of program (M2/M30) must be active before issuing the next enable using G188 or homing must have been activated, i.e., G188 may only be activated once in an NC program.

9.13.2.3 Axis information without additional path axes

If no additional path axes are available, the axes can be activated as soon as the programming and/or the filling of positioning memories occurred.

Page 328: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 328/376

9.13.2.4 Examples

Definitions: P1: Positioning axis program P2: Path axis program X, Y Path axes U, V Positioning axes P1(Positioning part to positioning axis U)N10 G54N20 G0 U0N30 G1 U-25 F400N40 G4 F100N50 G0 U0N60 U-25N70 G1 U-40N80 G98 F200N90 G0 U100(Positioning part to positioning axis V)N100 G0 V0N110 G1 V-100 F280N120 G98 F200N130 G0 V100N140 M30

In P1, the positioning axes are only programmed and the positioning memory filled. The blocks N10-N90 generate the positioning section for U, the blocks N100-N130 the positioning section for V. The blocks N80 and N120 signal the processing end of the individual positioning axes to the PLC program.

P2N10 G0 X0 Y0N20 G1 X200N30 G188 MxxN40 G2 X200 I150

N200 M30

In P2 in block N30, the positioning memory is released for processing by G188. Using Mxx, the release is communicated to the PLC that activates the positioning axes now via the individual input signals. Mxx is an M-code arbitrarily to be defined that is here interpreted as an enable signal for the positioning axes by the PLC program. G188 and/or a path part could also be positioned following N130 in P1.

Page 329: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 329/376

9.14 Programmable Oscillation The Oscillation feature requires several M and G-codes within the NC program to obtain the desired behavior.

9.14.1 Preparation set

The sinusoidal oscillation is prepared with a G35 block. The specification of at least one oscillation axis with a deviation length and one oscillation frequency is absolutely necessary. Dwell times and the number of deviations can also be programmed as required. The frequency, number of deviations and dwell times are likely to be different for each axis. A different preparation block must be programmed for each axis-specific assignment. All oscillation data can be described by parameter whereby a parameter that has the value 0 means that this date has not been programmed. Only the deviation lengths are processed with signs. All other data are assumed to be absolute values.

Example:

N10 G35 X+5 Y 10 E4 I1000 J1000 Fl

9.14.2 Erasing oscillation data

The data defined with G35 can only be erased by a renewed start of the CNC or a G35 block that does not contain information.

9.14.3 Deviation lengths

The amplitude of the oscillation deviation is specified by the programmed axis value in a G35 block. The oscillation direction is determined here by the sign of the axis value. If no oscillation axis is programmed in a G35 block, then the block will be rejected with error message 272. A separate G35 block must be coded for each axis if a separate oscillation profile is required for each axis.

The deviation length must be at least 2 increments in size. Otherwise, error message 274 will be issued.

9.14.4 Number of deviations

The number of deviations is programmed using a NC address. It is usually the letter �E�. The value of the E word specifies the number of oscillation deviations to be executed. If the two axes are to have different deviation numbers, these must be programmed in two separate G35 program blocks.

Example: N10 G35 X+5 E4 Fl X-axis four oscillation deviationsN20 G35 Y-10 E2 F1 Y-axis two oscillation deviations

Page 330: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 330/376

9.14.5 Frequency

The frequency of oscillation is defined by the F word. The standard unit of measure for the frequency is deviations/minute. A scaling factor can be specified that the F word can be multiplied by in order to also program small frequencies (see the application data description). If the two axes are to have different frequencies, these must be programmed in two separate G35 program blocks.

Example: N10 G35 X+5 F2 X-axis 2 deviations/minN20 G35 Y-10 F1 Y-axis 1 deviations/min.

At least four servo loops must be available per deviation. In this way the frequency is limited at the upper end.

15000 maximum frequency = servo time The G35 block will be rejected with error message 274 if no frequency is programmed.

9.14.6 Dwell times

Dwell times can be programmed at the starting point and at the amplitude point of oscillation deviations. The NC addresses I (starting point) and J (amplitude point) are available for this purpose. By default, the times are stated in milliseconds (see the application data description).

If the axes are to have different dwell times, these must be separately programmed in two separated G35 program blocks.

Example: N10 G35 X+5 I1000 J1000 F1 X-axis 1 second dwell at starting

point and at the amplitude point,N20 G35 Y-10 J2000 F1 Y-axis 2 seconds dwell time only at

the amplitude point.

9.14.7 Behavior in case of programming errors

With programming errors, an active oscillation will continue to run until the program stops in the home position. By default, the last oscillation deviation is discontinued on all oscillation axes. It is also applicable to still execute the current deviation after reaching the home position (see the application data description).

9.14.8 Behavior in case of Emergency Stop

With an Emergency Stop, an active oscillation will be unconditionally discontinued and synchronized to the programmed final point.

Page 331: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 331/376

9.14.9 M20 Start M-code

The start M-code can be programmed at any point within the NC program and initiates an oscillation start. Only then the oscillation data contained in the preparation block are processed. The Start M-code can be programmed straight into the G35 block. It should not be programmed before the G35 block since otherwise old oscillation data can be activated.

Example: N10 G35 X+5 Y-10 E4 I1000 J1000 Fl M20

M20 is the specified start M-code. The oscillation data have already been prepared before the oscillation is started.

9.14.10 M21 End M-code

The end M-code is the only way to stop the oscillation while an NC program is being executed. This can be placed anywhere in the NC program.

Note: Even when the axes carry out no further oscillatory movements since the programmed number of deviations has been attained, the oscillation can only be considered as completed when the End M-code has been recognized.

Upon recognizing the End M-code, the oscillation is discontinued and synchronized to the current nominal position. In this case, there is assurance that a Start M-code programmed into the next NC block will be carried out since there are no further oscillations active (see the application data description). With a synchronized deviation abort it should be noted that the starting point for further oscillations has been changed (due to the synchronization). In applications where this effect is undesirable, the block preparation before a new Start M-code should be stopped using M00 programming or by using signals output by the PLC until a previously activated oscillation is actually finished.

Example: N10 G35 X+5 Y 10 E4 I1000 J1000 Fl M20N20 M21N30 M0N40 M20N..

M20 or M21 are the specified Start or End M-codes (see the application data description). At M0, no deviation abort with synchronization and no oscillation stop are applied. In this way, the M0 start can be delayed until the first oscillation is finished and the second oscillation in N40 does not get lost. An M0 start can be avoided by programming a sufficiently long dwell time into N30.

Example:

Page 332: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 332/376

N10 G35 X+5 Y 10 E4 I1000 J1000 Fl M20N20 M21N30 G4 F250000N40 M20N..

Frequency 1 deviation/minute, dwell time 250 seconds.

One can omit block N30 and under some circumstances obtain a more dynamic time behavior by removing the transfer enable via the PLC during the period from the recognition of the Start M-code to the end of the active oscillation in N10.

9.14.11 M00 Programming

By default, M00 only stops the interpolation until there is a restart but not the oscillation. In order to also achieve the dependency of the oscillation on an interpolation, there is application data available that can also be used to facilitate an oscillation stop (see the application data description).

9.14.12 Program end / home position

To exit a program using program end or home position causes the end of the oscillation even if no End M-code has been processed yet in the NC program. The last deviation will also be executed as standard. It is, however, possible to specify a deviation abort with synchronization using application data (see the commissioning instructions).

The deviation abort is activated when the event occurs.

Note: In the NC program one must ensure that the oscillation does not negatively affect the axial dynamics since the software does not monitor these effects. Should an axis violate its software limits during the oscillation, the axis will be held at its axis limit and its oscillation value will be erased.

9.14.13 Error messages 274 �Oscillation: NC address F incorrect�

This error message is generated if either no frequency or an excessively high frequency is programmed.

274 �Oscillation: NC address X incorrect� For this error, the X-axis is an oscillation axis. The CNC generates this error message if, during the basic preparation, the X-axis is still oscillating or the programmed deviation length is too small.

272 �Oscillation: program error!�

Page 333: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 333/376

This error image is shown when there is no oscillation axis programmed in the G35 block.

9.15 Switchover Spindle-Rotary Axis

The Switchover Spindle-Rotary Axis feature requires two M-codes to establish the servo context (either spindle or rotary axis) within the NC program.

9.15.1 General

The function �Switchover spindle/rotary axis� enables a programmable switchover between the spindle and rotary axis functions of a rotational axis within an NC program. Any rotational axis present in a CNC station can be defined via machine parameters as a switchover axis.

In this application, one axis and one spindle (or spindle group) share an output channel (i.e., the analog D/A voltage with encoder feedback).

9.15.2 Programming

The switchover between spindle and rotary axis is programmed using specific M-codes. The M-codes M280 and M290 are used as default (but they can be changed via machine parameters).

M280 Rotary axis operation on M290 Spindle on

Example 1:

In this example, C is the switchover axis.

N10 M280 Rotary axis operation onN20 G1 X0 Z0 F1000N30 M290 spindle onN40 M03 S800 spindle programmedN50 X10 F1000N60 Z20N70 G04 F2000 S400 M04N80 X5N90 M280 spindle offN100 X0 C20N110 M30

Example 2:

In this example, C and A are the switchover axes, where spindle 1 uses the channel of the C-axis, while spindles 2 and 3 use the channel of the A-axis.

N10 M280 Rotary axis operation C-axisN20 G1 X0 Z0 F1000N30 M290 Spindle operation C-axis on

Page 334: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 334/376

N40 M03 S800 Spindle programmedN50 X10 A0 F1000N60 A30 Z20N70 M291 Spindle operation A-axis onN80 M214 S1000 spindle 2 clockwiseN90 G04 F2000 S400 M04 spindle 1 counter-clockwiseN100 X5N110 M280 spindle 1 offN120 X0 C20 M224 S500 spindle 3 counter-clockwiseN130 X100 C0 M19 S90 spindle 3 positioningN140 M281 spindles 2 and 3 offN150 M30

Note:

The spindle cannot be programmed during the rotational axis operation (i.e., M3, M4, M5 and M19 are not allowed when the servo is the rotary axis). If spindle functions are programmed the error message 377 is output.

Conversely, the rotational axis cannot be programmed with spindle functions; if that is programmed, the error message 376 is output.

9.15.3 Spindle running

9.15.3.1 General

When operating the switchover axis as a spindle, the behavior, programming, functional extent and display correspond to that of a spindle.

While the spindle is running, the rotational axis measuring system is suppressed. The axis position of the rotary axis is not counted in the display while in the spindle function. The last interpolated axis position is displayed.

9.15.3.2 Behavior at switch over

The following is executed when a switch back to axis operation is made. The actual switchover block (M280, M281, etc.) is passed onto the active plane without any reaction from the CNC. This can be used for a PLC reaction.

Following this, an intermediate block with spindle stop and set-up delay is generated. This should guarantee a spindle standstill. When G95 (feed in mm/rev.) is active, a switch back to G94 is made automatically.

Page 335: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 335/376

The actual switchover block is then generated. This block switches over to the rotary axis operation, i.e., the axis is controlled again and the instantaneous axis position (actual position) is displayed. With the appropriate setting up, a further reduction of the axis position to 0 to 360 degrees can be achieved (see machine parameter descriptions for the switchover feature).

9.15.3.3 Reaction to a measuring system error

If no measuring system or gate-array error has occurred during spindle function, then, depending on the setting up, the instantaneous position is retained and the reference point and/or the starting position (position of the switchover axis before switching on the spindle function is moved as well. The starting position is approached in rapid traverse.

If a measuring system or gate-array error has occurred, then, with the appropriate setting up, a reference cycle is executed or the starting position is moved as well. If no automatic homing (move to reference point) has been set up for the axis, the error message 444 is output. With a mandatory homing axis, homing is forced. With a non-mandatory homing axis, the above warning is output but the NC processing is not stopped.

9.15.3.4 Rotary axis operation

When the switchover axis is a rotary axis, the behavior, programming, functional extent and display correspond to that expected of a standard axis.

9.15.3.5 Control reset or end of program

At power on, the switchover axis is treated as a rotary axis. This is necessary so that homing is possible for the rotary axis. The selected operating mode (rotary axis or spindle) is retained after control reset and end of program. The operating mode of the switchover axis can only be changed by NC programming or by a PLC interface signal in MANual operation.

9.15.3.6 Manual operation

In MANual operation, the switchover axis can only be moved in rotary axis operation. No positioning of the switchover axis is made while the spindle is running. The error message 376 is output.

Page 336: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 336/376

9.16 Thread Cutting The Thread Cutting feature requires associated additions to a typical NC program to obtain the desired behavior.

9.16.1 General

During thread cutting the feed velocity is calculated depending on the spindle rotary speed. The programmed F-word has no effect. Feed under F becomes effective again when G01, G02, G03 or G07 are programmed.

To ensure that the tool is applied at the same place for several cuts, the thread begins always at the Spindle-position 0 (the marker pulse from its encoder).

For several continuous thread blocks, the spindle command is placed only in the first block.

9.16.2 Spindle Control

If during thread cutting G08 is active the spindle speed will be decreased to zero at the end of each block and at the beginning of the next block accelerated again.

The spindle speed is synchronous to the thread axes; i.e., it stops at the end of the block as well.

If G09 is active at thread cutting at the end of the thread block only at changing of the direction of the linear axes or the spindle it will be decelerated.

Right-hand or left-hand threads are determined by the rotation direction of the spindle (programming with M03 or M04 respectively).

9.16.3 Programming thread with uniform pitch, G33

With G33 the following threads with uniform pitch can be cut:

• Plain thread

• Cylindrical thread

• Conical thread

• Cylindrical thread with controlled running out

• Conical thread with controlled running out

Page 337: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 337/376

9.16.4 Programming thread with dynamic pitch, G34

With G34 the following threads with dynamic pitch cut:

• Cylindrical thread

• Conical thread

9.16.5 Definition of the thread block

X: Length of thread for plain threads

X-component of the running out distance.

Z: Z-component of the thread length.

I: X-component of the thread pitch.

K: Z-component of the thread pitch.

J: Z-component of the running out distance change of pitch/thread lead in the direction of thread.

The following combinations and values are possible:

Thread G X Z I K J

Plain thread 33 <> 0 -- > 0 -- -- Cylindrical thread 33 -- <> 0 -- > 0 -- Cylindrical thread with controlled running out

33 <> 0 <> 0 -- > 0 > 0

Conical thread 33 -- <> 0 <> 0 > 0 -- Conical thread with controlled running out

33 <> 0 <> 0 <> 0 > 8 > 0

Cylindrical thread with dynamic pitch

34 -- <>0 -- >0 <> 0

Conical thread with dynamic pitch 34 -- <> 0 <> 0 > 0 <> 0

-- means the address may not be programmed!

Other combinations and value ranges are rejected.

Table 9-7: Definition of a G33/G34 thread block

Page 338: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 338/376

Note that the plain thread in X requires a special axis configuration. Threading is normally done in Z (i.e., cylindrical and conical threads). If the plain thread is possible in the machine (i.e., to thread in X) then that machine will not thread in Z.

They are mutually exclusive features (plain threading or not). The threading in X is shown in the table above in case such a special machine requires this application.

9.16.6 Programming cylindrical thread, G33, G34

Note: the part program statements precede the figure with its results. This section�s sequence is NC code then its figure, NC code then its figure, etc. Figure 9-21 shows the raw part, prior to the execution of the NC code that results in the following figures.

Figure 9-21: Work piece before G33 processing

N40 G01 X+2 Z+12N50 G33 Z+4 K+1

Page 339: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 339/376

Figure 9-22: Work piece after processing with G33

N40 G01 X+2 Z+12N50 G33 X+1 Z+4 J+4 K+1

Figure 9-23: Work piece with controller running out (G33)

N40 G01 X+2 Z+12N50 G34 Z+4.5 J0.25 K+1

Page 340: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 340/376

Figure 9-24: Work piece with increasing pitch (G34)

N40 G01 X+2 Z+12N50 G34 Z4.5 J-0.25 K+2

Figure 9-25: Work piece with decreasing pitch (G34)

Page 341: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 341/376

9.16.7 Programming conical thread G33, G34

Note: the part program statements precede the figure with its results. This section�s sequence is NC code then its figure, NC code then its figure, etc. Figure 9-26 shows the raw part, prior to the execution of the NC code that results in the following figures.

Figure 9-26: Work piece before processing with G33

N40 X+1 Z+12N50 G33 Z+4 I+0.5 K+1

Figure 9-27: Work piece after processing with G33

Page 342: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 342/376

N40 G01 X+1 Z+12N50 G33 X+1 Z+4 I+0.5 J+44 K+1

Figure 9-28: Work piece with controlled running out (G33)

9.16.8 Programming lag free thread, G133, G134

The meaning of the function �Lag free thread cutting� is to eliminate lags and resulting path errors in the axes involved at thread cutting caused by regulation.

If the function �Lag free thread cutting� is properly set up, thread cutting blocks will be moved lag free using G33/G34.

Before the first activation the zero-lag function has to learn the characteristics of the involved axes. The learning function has to be switched on with G133. For example with following NC program:

N10 G1 X0 Z0 F300N20 G133N30 X10N40 Z10N50 G134N60 M30

With G133 basic factors for the zero-lag function in the interpolator-loop will be calculated and the learning function switched on. The basic factors of the axes for thread cutting will be optimized automatically at the following blocks. In the display the lag for the corresponding axes should oscillate around zero (LAG-display active). The KV-display will be adjusted during the movement of the axes to the value 100.

Page 343: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 343/376

If the KV-values (activate LAG-display as display function) of both axes are getting stable near the value 100.0 the learning process can be terminated with G134.

During an active learning function. no thread cutting blocks can be programmed with G33/G34 and no new feed can be programmed as well.

Note: • If the learning function is activated later again with G133, the previous learned

and stored zero-lag factors will be overwritten with the basic factors. This means, that the learning function must be repeated once again completely.

• The G-code necessary to switch on the learning function can be pre-set. To switch off, the number following the pre-set value, will be used. G133 should be used. At thread cutting G08 must be active as well

Example: N100 G08N110 G01 F5000 X100 Z100 M03 S500N120 G33 Z120 K1N130 G1 X ..N140 ..

Page 344: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 344/376

9.17 Turning Cycles or Stock Removal Cycles The Turning Cycles feature requires associated additions to a typical NC program to obtain the desired behavior.

9.17.1 General

The stock removal cycles provide an easy way of roughly turning. The CNC programmer only has to program the desired shape. The CNC then creates a multiple repetitive cycle for stock removal and roughly turning of the shape.

The programmed tool path can also be used for the finishing cut with the help of the finishing cycle G270.

9.17.2 G271 Stock removal in turning

9.17.2.1 Syntax

G271 U... R...G271 P... Q... U... W...

The stock removal cycle in turning is prepared by the optional Block

G271 U... R... The U value gives the depth of cut for stock removal. The direction of cut is indicated by the sign of the W value in the activating block.

The R value gives the escaping amount. Both U and R values have to be programmed without a sign and their values are taken as a programmed radius.

Both values are modal and if one of them or the whole preparing block is omitted, the values in the machine parameters TurningDepthOfCut and TurningEscapeAmount are taken for the turning cycle.

The cycle is activated by the Block

G271 P... Q... U... W...

The P value gives the number of the first block for the finishing shape.

The Q value gives the number of the last block for the finishing shape. The blocks in between are replaced by the multiple repetitive cycle.

Page 345: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 345/376

The U value gives the finishing allowance in radial direction (X). The sign of this value gives the direction of the allowance relative to the shape. The sign also designates the direction in which the levels of stock removal are changed. In the case of diameter programming the value is to be specified in diameter dimension.

The W value gives size and direction of finishing allowance in longitudinal direction (Z).

If a finishing allowance of zero is desired for U or W (or both), the sign has to be programmed together with the zero (for example: W+0 or W-0) in order to define the direction in which the levels of stock removal are changed. If a zero is programmed without sign, it is assumed as �positive�.

The modal feedrate (F), spindle speed (S) and spindle direction (M3/M4) are provided either before these G271 blocks or in the second of the two G271 blocks. They are not specified in any of the blocks within the cycle.

9.17.2.2 Example

N50 G0 X45 Z0N60 G271 U10 R5N61 G271 P100 Q200 U.5 W1 S1200 F.8 M4N100 G1 X10N110 Z-30N120 X30 Z-50N130 X40N140 Z-80N200 X45 Z-80

Z

X

d(G0)(G1)

u

w

e

e: escape amountu: radial finishingw: longitudinal finishing

d: depth of cut

Programcommand

Figure 9-29: Stock removal

Page 346: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 346/376

The turning cycle starts with the actual position before the block N100, i.e., with X45 Z0. The programmed allowances in positive X- and Z-direction, U.5 and W1, are added to the programmed positions.

For this roughly cutting shape three stock removal cycles on the X-levels 35.5, 25.5 and 15.5 are computed. First the tool moves to the start position X45.5 Z1.

The three cycles for stock removal are processed and then the shape for roughly cutting is processed with the positions X10.5 Z1; X10.5 Z-29; X30.5 Z-49; X40.5 Z-49; X40.5 Z-79; X45.5 Z-79.

The cycle ends at the starting position, i.e., the position before the block N100.

9.17.2.3 Direction of allowance

u>0 w>0 u>0 w<0

u<0 w>0 u<0 w<0

Z

X

Figure 9-30: Stock removal: direction of allowance

9.17.2.4 Effective G-codes

When G271 is active, only the programmed radial (X) and longitudinal (Z) position and the interpolation types G00, G01, G02, G03, G12 and G13 are taken into account.

All other programmed values, such as feed- or spindle speed values and all programmed G-codes are ineffective in stock removal.

Feed and spindle speed are constant with the first cycle block active rate.

If a finishing cycle is turned with the same blocks, no other G-codes than the ones for the interpolation type should be activated between the first cycle block and the finishing cycle G270. Otherwise the shape could be destroyed.

Page 347: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 347/376

In the blocks of the stock removal cycle, cycle programming (*N...) and subprograms (or subroutines) are forbidden.

9.17.3 G272 Stock removal in facing

9.17.3.1 Syntax

G272 W... R...G272 P... Q... U... W...

The cycle for stock removal in facing is prepared by the optional Block

G272 W... R...

The W value gives the depth of cut for stock removal. The direction of cut is designated by the sign of the U value in the activating block.

The R value gives the escaping amount. Both values have to be programmed without sign and values are taken as radius programmed.

Both values are modal and if one of them or the whole preparing block is omitted, the values in the machine parameters FacingDepthOfCut and FacingEscapeAmount are taken for the turning cycle.

The cycle is activated by the Block:

G272 P... Q... U... W...

The P value gives the number of the first block for the finishing shape.

The Q value gives the number of the last block for the finishing shape. The blocks in between are replaced by the multiple repetitive cycles.

The U value gives the finishing allowance in radial direction (X). The sign of this value gives the direction of the allowance relative to the shape. The sign also designates the direction in which the levels of stock removal are changed. In the case of diameter programming the value is specified in diameter dimension.

The W value gives size and direction of finishing allowance in longitudinal direction (Z).

If a finishing allowance of zero is desired for U or W (or both), the sign has to be programmed together with the zero (for example: W+0 or W-0) in order to define the direction in which the levels of stock removal are changed. If a zero is programmed without sign, it is assumed as �positive�.

Page 348: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 348/376

When G272 is active only the programmed radial (X) and longitudinal (Z) position and the interpolation types are taken into account. All other programmed values, such as feed- or spindle speed values are ineffective.

The modal feedrate (F), spindle speed (S) and spindle direction (M3/M4) are provided either before this G272 or in the G272 block. They are not specified in any of the blocks within the cycle.

9.17.3.2 Example

...N50 G0 X0 Z45N60 G272 P100 Q200 U-.8 W1.3 S1100 F1 M3N100 G1 Z10N110 X30N120 X50 Z20N200 X50 Z45

de

e: escape amountu: radial finishingw: longitudinal finishing

X

Z

w

u

d: depth of cut

Programcommand

Figure 9-31: Stock removal in facing

The stock removal cycle starts at the actual position before block N100. Then three stock removal cycles are turned and afterwards the roughing shape is turned.

The cycle ends at the starting position.

9.17.4 Direction of allowance

Page 349: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 349/376

u>0 w>0u>0 w<0

u<0 w>0u<0 w<0

Z

X

Figure 9-32: Stock removal in facing: direction of removal

9.17.4.1 Effective G-codes

When G271 is active, only the programmed radial (X) and longitudinal (Z) position and the interpolation types G00, G01, G02, G03, G12 and G13 are taken into account.

All other programmed values, such as feed- or spindle speed values and all programmed G-codes are ineffective in stock removal. Feed and spindle speed are constant with the first cycle block active rate.

If a finishing cycle is turned with the same blocks, no other G-codes than the ones for the interpolation type should be activated between the first cycle block and the finishing cycle G270. Otherwise the shape could be destroyed.

In the blocks of the stock removal cycle, cycle programming (*N...) and subprograms (or subroutines) are forbidden. Such statements must precede the cycle.

Page 350: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 350/376

9.17.5 G270 Finishing Cycle

After roughly turning the programmed blocks can be used for a finishing cut.

9.17.5.1 Syntax

G270 P... Q...

The P value gives the first block for the finishing cut.

The Q value gives the last block for the finishing cut.

For an exact finishing cut after a stock removal cycle, the numbers of first and last block in G270 and G271/G272 must be identical. The start position of the finishing block must be identical to the position before the first block in stock removal. This can be achieved by programming G270 directly after the last block of stock removal.

All G-codes and other instructions in the finishing cycle blocks are effective.

9.17.5.2 Example

...N50 G0 X45 Z0N61 G271 P100 Q200 U.5 W1 S1200 F.8 M4N100 G1 X10N110 Z-30 F1N120 X30 Z-50 F1.5N130 X40N140 Z-80N200 X45 Z-80N210 G270 P100 Q200N220......

After the stock removal cycle G271, the exact finishing shape is turned, i.e., the CNC moves from the start point (X45 Z0) to the positions in the blocks N100 to N200. Then it returns to the start point of the cycle (X45 Z0) and then continues with the next block (N220).

Page 351: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 351/376

9.17.6 G274 Peck finishing cycle

9.17.6.1 Syntax

G274 R...G274 X... Z... U... V... R ...

The turning cycle for peck finishing is prepared by the first block above (block G274 R...) and the actual cycle is initiated by the second block above.

The initial R-value defines the return amount for the cycle. This R-value is modal and if this block is omitted, the preset value in the machine parameter TurningReturnAmount is applied.

The cycle is activated by the second block above (with the X, Z, U, V, R, F).

The X value defines the end point in radial direction (X).

The Z value defines the end point in longitudinal direction (Z).

The U value defines the movement amount in radial direction (X). No sign is allowed for this parameter.

The V value defines the movement amount in the longitudinal direction (Z).

The R value defines the escaping amount. This value is normally given by the relief amount of the tool at the bottom of the cut. The sign is given by the direction of the movement to X. However, if X and P are omitted, then the relief direction can be specified by the desired sign.

Note While both the escaping amount and the return amount are programmed by code R, the meanings of them are determined by the presence of address X

Note The cycle is initiated by the G274 statement with the X specification.

The following picture shows how the programmed values result in the machining procedure for the cycle.

Page 352: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 352/376

Z

X

X : programmed Endp

Startpoint

0 < V1 <= V 0 < R1 <= R

Z: programmed Endpoint

V V1

R

R1

R (return amount)

Figure 9-33: G274 peck finishing cycle

9.17.6.2 Effective G-codes

When G274 is active, only the programmed radial position (X) and longitudinal (Z) position are taken into account.

Feed and spindle speed are constant with the values that are modal before the first cycle block.

9.17.7 G275 Outer diameter/internal diameter turning cycle

9.17.7.1 Syntax

The G275 turning cycle operates as shown in the figure below. This cycle is equivalent to G274 except that X is replaced by Z. Chip breaking is possible in this cycle, and grooving in X axis and peck drilling in X axis (in this case Z and Q are omitted) are also possible.

G275 R...G275 X... Z... U... V... R...

The X, Z, U, V, R explanations are provided for G274.

Page 353: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 353/376

Z

0 < V1 <= V 0 < R1 <= R

V V1

R

R1

Figure 9-34: G275 inner/outer diameter turning cycle

9.17.7.2 Effective G-codes

When G275 is active, only the programmed radial position (X) and longitudinal (Z) position are taken into account.

Feed and spindle speed are constant with the values that are modal before the first cycle block.

9.17.8 G276 Multiple pass threading cycle

9.17.8.1 Syntax

G276 Pmmaa. V... R... mm: Repetitive count in finishing (1 to 99).

This value is modal and is not changed until another value is assigned. aa: Angle of tool tip

One of six kinds of angle, 0°, 60°, 55°, 30° and 29° can be selected and specified by 2-digit number. This value is modal and is not changed until another value is assigned. When no value is programmed, the Machine parameter TurningTooltipAngle is applied.

Mm and aa are specified by address P at the same time. When mm = 2 and aa = 60°, specify as shown below:

P0260 (where mm = 02 and aa = 60)

Page 354: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 354/376

The V value defines the minimum cutting depth. When the cutting depth of one cycle operation becomes smaller than this limit, the cutting depth is clamped at this value. This designation is modal and is not changed until another value is programmed. When no value is programmed, the machine parameter TurningMinimumCuttingDepth is applied.

R defines the finishing allowance. This value is modal and is not changed until another value is programmed. When no value is programmed, the machine parameter TurningFinishingAllowance is applied.

G276 X... Z... I... U... V... K... J...

I defines the difference of thread radius in X, the direction per lead.

If I has a value of 0 (zero), an ordinary straight thread cut is made.

The absolute difference in X from the beginning to the end of the thread is given by ∆X = I * γ with γ = Z / K.

U defines the height of thread. This value is the radius value in X-axis direction.

V defines the depth of cut in first cut (radius value).

J defines the chamfering amount. This value is modal and is not changed until the other value is programmed.

K defines the lead of thread.

Note The meaning of the data specified by address U, V and R will be determined by the presence of X and Z.

Note The cycle machining is performed by G276 with X and Z specification.

By using this cycle, one edge cutting is performed and the load on the tool tip is reduced. Making the cutting depth �d� for the first path and �d*sqrt(n)� for the n-th path, the cutting amount per one cycle is held constant.

Page 355: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 355/376

Z

X

U (thread heightJI*k

Figure 9-35: G276 multiple pass thread turning cycle

The difference of the thread radius is given by the amount of leads K multiplied by I.

How the different cuts occur depends on the parameter values as shown in the following picture:

V height of f

1st

2nd

3rd

nth

V * sqrt(n) = P

Tool tip

Figure 9-36: G276 threading cycle and tool tip parameters

9.17.9 Error messages

315 Machine parameter TurningGCodeAppl faulty

Page 356: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 356/376

The function Turning Cycles is not configured in the system.

708 Turning Cycles: Parameter wrong If depth of Cut <= 0 or escape amount < 0. If U- or W-value is not programmed

in the activating block G271/G272.

709 Turning Cycles: Block number wrong If P or Q in the activating block G271/G272 is not programmed.

710 Turning Cycles: Block not found If there exists no block with the in P or Q programmed number.

711 Turning Cycles: Cycle programming *N not allowed No Cycle programming *N... is allowed in the turning cycles.

712 Turning Cycle: Circular level not allowed The activated plane (G17, G18, G19) includes other axes than X and Z (the

applied radial and longitudinal axes).

713 Turning Cycle: Too many blocks

9.17.10 Part program display

The part program display is modified while turning cycles are active in order to clarify the progress of the turning cycles to the user. The following is valid:

Line 1: This line shows the block that has caused the actual turning cycle.

Line 2: The second line shows the block that defines the contour element that is actually processed.

Line 3: This line shows the element or block that is to be processed after the actual contour element.

At entering turning cycles, the block with G271 (or G272) is displayed a second time. At this time the CNC moves to the start point with additional finishing allowance.

At the end of turning cycles (G271 or G272) the block with G271 (or G272) is displayed again. With this block active, the CNC moves back to the start point.

When finishing is active (G270) the block with G270 appears a second time at the end of the finishing cycle. With this block active the CNC moves to the point from which turning cycles were started.

Blocks that define contour-elements parallel to the tool moving axes are not displayed.

Page 357: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 357/376

10 Programming MachineMate Special Features MachineMate offers a number of special features. These features have their own programming rules. These are all special features and are not available on all controls. They would be part of the original purchase of the control, part of the original CNC software configuration.

10.1 Lathe T-code Programming This special feature allows the NC part programmer to use just a T-Code to make the turret position selection and the offset selection. This is a change to the default behavior described for the T-code in section 4.3.3. The purpose of this feature is to convert a T-code into a new T-code for just the turret position with the correct D and H-codes as well. With this feature, the NC programmer will follow the same rule as for some other controls, where the T-code identifies all three codes rather than using the three letters on this control. Several examples, 1. 2-digit offset selection (typical):

N10 T0203 -> N10 T02 D03 H03 or

N10 T0357 -> N10 T03 D57 H57

2. 1-digit offset selection (alternate):

N10 T75 -> N10 T7 D5 H5 If the number of digits in the T-code is not more than the number of digits provided for the offset (e.g., T1), then the T-code is assumed to be just the turret selection with no offset selection. Note:

No D or H value is expected to be present on the line with the T value since the T value will call out the appropriate D and H values (based on the rule above). Those values from the T value will override any other D or H that is present on the line. This is change to the programming technique described in 4.3.3.

This feature has the configurable option for the number of digits in the offset selection (either 1 or 2; 2 is the default setting). All programs will be expected to use one or the other T-code format.

Page 358: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 358/376

10.2 Programming a Rotary-only Motion in G70 This special feature allows the NC part programmer to use the specified feedrate in a block of rotary-only motion to be treated as degrees/minute, rather than inches/min when G70 is modal. This is a change to the default behavior described for the feedrate in section 2.1.3. The default behavior for the CNC when in G71 (metric) is that the linear axes move in millimeters and the rotary axes move in degrees. One millimeter is 1000 microns and one degree is considered equivalent to 1000 microns. Therefore an interpolated move with a linear axis moving 1 mm and a rotary axis moving 1 degree will have both axes moving at the same rate, where the combined path of both results in the correct feedrate, in mm/min. The default behavior for the CNC when in G70 (inch) is that the linear axes move in inches and the rotary axes move in degrees. One inch is 25400 microns and one degree is considered equivalent to 1000 microns. Therefore an interpolated move with a linear axis moving 1 inch and a rotary axis moving 25.4 degrees will have both axes moving at the same rate, where the combined path of both results in the correct feedrate, in in/min. The end result of this default behavior is that the rotary axis will move 25.4 times faster than would be expected if the feedrate value had been considered to be degrees/minute. This special feature allows the path feedrate to be interpreted as degrees/minute when the active block meets the following criteria: 1) G70 is modal and 2) The block contains only rotary axis motion.

Under these circumstances, the feedrate context is changed to be degrees/minute rather than inches/minute. For example, a block (with G90 modal for absolute programming) like: N100 G1 F10 A90 will result in the rotary A-axis moving to a position of 90 degrees at the rate of 10 degrees/minute. Without this feature enabled, the same block of G1F10A90 with G70 modal (so F10 means 10 inches/minute) would result in a rotary feedrate of 254 degrees/minute. The modal feedrate value is not affected by this block or this special feature, so if the next block was N110 X10 then X would move at 10 inches/minute.

10.3 G93 for Programming a Mix of Linear and Rotary Motion

This special feature allows the NC part programmer to use the specified feedrate in a block to be treated as a time rather than as a motion/time. This is a change to the default behavior described for the feedrate in section 2.1.3. This G93 special feature is assumed to replace the default G93 behavior for constant circumferential speed (CCS; see 9.8.7.2); both G93 features cannot exist at the same time. This G93 is typically used on milling machines with one or more rotary axes while CCS would be used on grinders.

Page 359: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 359/376

The default behavior for the CNC moving a rotary axis is described in the above section (10.2). Basically a degree is considered 1000 microns and the number of degrees in the rotary motion is considered relative to any linear motion (in mm or inches) in the same block when interpolating them together or alone. This G93 feature allows the path feedrate to be programmed in a block with G93 and the feedrate value is interpreted as a time. This feature is often called inverse time programming, as the units for the G93 F-value are 1/minute. The programmed F value comes from a calculation (see below) by the programmer. The F value is the result of the desired feedrate (in inches/minute for G70 or in mm/minute for G71) divided by the actual distance moved in the block (in inches for G70 or in mm for G71). The common usage for G93 is an NC block having both a linear and a rotary axis motion. This G93 defines the feedrate to be in the units of 1/minute, so the programmer is specifying the time for a block, not the path velocity for the block (as in G94). The part programmer can account for the diameter of the part in the feedrate calculation so that the actual path velocity at the part surface (i.e., the angular velocity in conjunction with the part diameter) is taken into account by the part program. For example (with G70 modal for inch dimensions and G91 modal for incremental programming): N100 G93 X5 B90 F5 the X move of 5 inches and the B move of 90 degrees will require 0.2 minutes or 12 seconds (from the 1/5 minute, since F is programmed in units of 1/minute). If the part had a diameter of 18 inches then the programmed path velocity at the part surface for this motion will be about 75 inches/minute. Other G93F examples would be F1 for 1 minute or F0.333 for 3 minutes. The G94 programming (i.e., feedrate as in/min or mm/min) defines the path velocity for the linear/rotary combination from just the combination of linear (in or mm) and rotary (degrees) units. The calculation of the G93 feedrate value comes from the formula: G93F = 1 / ( Actual_move_distance / Desired_feed_rate ) Actual_move_distance comes from this formula: Actual_move_distance = square_root( ((D * Pi)/(360 / A))^2 + L^2 ) where: D = diameter_of_part A = angular_move L = linear_move Pi = the constant pi (3.14159�) D and L are in the same units (inches or mm). The Desired_feed_rate is in the similar units (inches/min or mm/min). A is in degrees. The result of ( Actual_move_distance / Desired_feed_rate ) will be the number of minutes required for the motion.

Page 360: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 360/376

The NC programmer is making this calculation so that the CNC provides the desired path feedrate with the correct angular velocity (i.e., by taking into account the cutter�s distance from the center of rotation).

Since the formula for the G93 F-value has the time in the denominator, the G93 feature is often called �inverse time� feedrate programming. The CNC will take the programmed F-value, determine the distance moved in the block and then display both the actual and programmed feedrates in the correct G94 units (either mm/minute or inches/minute). Note that this G93 applies only to the NC block it is in. This G93 is not modal. The NC programmer should provide a G94F block prior to the next G1 block to make sure the correct feedrate (in the correct units of distance/time, not 1/time) is applied after this special interpolation block.

10.4 Canned Drilling Cycle Letter Programming This special feature allows the NC part programmer to use conventional letters to specify the parameters for each canned cycle rather than the more versatile cycle parameters provided by the CNC. The default syntax for the canned cycles is defined in section 7. With this programming feature, the NC programmer configures the G8x canned cycle on the G8x line itself, rather than in the preceding NC statement(s) with the cycle parameter values. This syntax is very similar to that used in many other controls.

10.4.1 Canned Cycle Programming with Letters not Parameters The programming details for the respective canned cycles are below. Check Section 7 for the description of the canned cycle operations. Note that Z, R and K are common to all of the canned cycles and W is used for all canned cycles except G81 (which has no dwell time). Many other CNC vendors� canned cycles allow just Z and R to be defined so K (the reference plane between the retract plane and the part) is optional in all the canned cycles. Since a dwell is not always required for a particular cycle, W (the dwell time) is also optional in all cycles that allow it. Several other letters (F, I, J, U and V) are used for the different canned cycles but the meaning of the individual letter depends on the associated canned cycle. For G81 (see 7.4),

Z defines the final depth for the cycle, in an absolute dimension, R defines the retract plane for the cycle, in an absolute dimension K defines the reference plane for the cycle, in an absolute dimension

(optional; reference plane = retract plane if K is not present). For G82 (see 7.5),

Z defines the final depth for the cycle, in an absolute dimension, R defines the retract plane for the cycle, in an absolute dimension

Page 361: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 361/376

K defines the reference plane for the cycle, in an absolute dimension (optional; reference plane = retract plane if K is not present),

W defines the dwell time in the cycle, as a programmed time (as G4Fx) (optional; 0 if W is not present).

For G83 (see 7.6),

Z defines the final depth for the cycle, in an absolute dimension, R defines the retract plane for the cycle, in an absolute dimension K defines the reference plane for the cycle, in an absolute dimension

(optional; reference plane = retract plane if K is not present), W defines the dwell time in the cycle, as a programmed time (as G4Fx)

(optional; 0 if W is not present), U defines the incremental motion within the cycle, in an incremental value, V defines the first increment motion within the cycle, in an incremental value

(optional; U-value is used for first increment if V is not present), I defines the safety clearance value for the cycle, in an incremental value

(optional; 0 if I is not present). For G84 (see 7.7),

Z defines the final depth for the cycle, in an absolute dimension, R defines the retract plane for the cycle, in an absolute dimension K defines the reference plane for the cycle, in an absolute dimension

(optional; reference plane = retract plane if K is not present), W defines the dwell time in the cycle, as a programmed time (as G4Fx)

(optional; 0 if W is not present). For G85 (see 7.8),

Z defines the final depth for the cycle, in an absolute dimension, R defines the retract plane for the cycle, in an absolute dimension K defines the reference plane for the cycle, in an absolute dimension

(optional; reference plane = retract plane if K is not present), W defines the dwell time in the cycle, as a programmed time (as G4Fx)

(optional; 0 if W is not present). For G86 (see 7.9),

Z defines the final depth for the cycle, in an absolute dimension, R defines the retract plane for the cycle, in an absolute dimension K defines the reference plane for the cycle, in an absolute dimension

(optional; reference plane = retract plane if K is not present), W defines the dwell time in the cycle, as a programmed time (as G4Fx)

(optional; 0 if W is not present), I defines the X offset motion in the cycle, in an incremental value, J defines the Y offset motion in the cycle, in an incremental value.

For G87 (see 7.10),

Z defines the final depth for the cycle, in an absolute dimension, R defines the retract plane for the cycle, in an absolute dimension K defines the reference plane for the cycle, in an absolute dimension

(optional; reference plane = retract plane if K is not present), W defines the dwell time in the cycle, as a programmed time (as G4Fx)

(optional; 0 if W is not present), F defines the retract feedrate within the cycle, as a feedrate value, (optional; modal feed rate is used if F is not present), U defines the first reamed depth in the cycle, in an absolute dimension.

Page 362: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 362/376

For G88 (see 7.11), Z defines the final depth for the cycle, in an absolute dimension, R defines the retract plane for the cycle, in an absolute dimension K defines the reference plane for the cycle, in an absolute dimension

(optional; reference plane = retract plane if K is not present), W defines the dwell time in the cycle, as a programmed time (as G4Fx)

(optional; 0 if W is not present). For G89 (see 7.12),

Z defines the final depth for the cycle, in an absolute dimension, R defines the retract plane for the cycle, in an absolute dimension K defines the reference plane for the cycle, in an absolute dimension

(optional; reference plane = retract plane if K is not present), W defines the dwell time in the cycle, as a programmed time (as G4Fx)

(optional; 0 if W is not present), U defines the first depth in the cycle, in an absolute dimension, V defines the second depth in the cycle, in an absolute dimension.

10.4.2 Canned Cycle Programming: Cross Reference to Section 7 Section 7 of this NC Part Programming Manual describes the respective canned cycles, as well as the cycle parameters that are required for each canned cycle. Here is the conversion between the letters in this feature and the associated cycle parameters for each cycle described in the section 7. For G81, Z -> P3, R -> P10, K -> P2. If no K then P2=R. For G82, Z -> P3, R -> P10, K -> P2, W �> P4.

If no K then P2=R. If no W then P4=0. For G83, Z -> P3, R -> P10, K -> P2, W -> P4, U -> P5, V -> P1, I -> P6. If no K then P2=R. If no W then P4=0. If no V then P1=U. If no I then P6=0. For G84, Z -> P3, R -> P10, K -> P2, W -> P4.

If no K then P2=R. If no W then P4=0. For G85, Z -> P3, R -> P10, K -> P2, W -> P4.

If no K then P2=R. If no W then P4=0. For G86, Z -> P3, R -> P10, K -> P2, W -> P4, I -> P8, J -> P9.

If no K then P2=R. If no W then P4=0. For G87, Z -> P3, R -> P10, K -> P2, W -> P4, F -> P12, U -> P13, modal F -> P11. If no K then P2=R. If no W then P4=0. If no F then P12= modal F. For G88, Z -> P3, R -> P10, K -> P2, W -> P4.

If no K then P2=R. If no W then P4=0. For G89, Z -> P3, R -> P10, K -> P2, W -> P4, U -> P13, V -> P15.

If no K then P2=R. If no W then P4=0.

10.4.3 Canned Cycle Programming Examples The NC Part Programming Manual (section 7.4) has an example for programming a G81 cycle. The example shows the G81 with a reference plane at 2.5 inches, the final hole depth at 1.0 inch and the retract plane at 3.0 inches. To program the G81 cycle for the same results with this feature, this syntax would be used:

Page 363: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 363/376

< Omit lines N40 and N50 > N60 G81 Z1 R3 K2.5 or N60 G81 Z1.0000 R3.0000 K2.5000 There is also an example for programming a G83 cycle (section 7.6 in the manual). To program the G83 cycle for the same results as the example with this feature, this syntax would be used: < Omit lines N40 through N55 > N60 G83 Z1 K2.5 R3 W1 U0.5 V1.25 I0.25 There is also an example for a complete program, including a series of operations for both the G81 and G84 cycles in section 7.13. That example assumes G71 so to program the canned cycles for the same results as the example with this feature, this syntax would be used: < Omit lines N40 through N55 > N60 G81 Z3 K20 R30 . . . < Omit line N140 > N150 G84 Z5 K20 R30 W1 Note:

None of these letters for canned cycle parameters are modal. For example, an R parameter for a G81 will not apply to a subsequent G82. Each G81-G89 statement must define that specific canned cycle�s required parameters with its letters.

None of these canned cycle parameters can be changed with just that letter during the individual steps before the G80. To change any of the cycle parameters, another complete G8x line is required. For example, a line after the G81 and before the G80 could not specify just an R (e.g., N75 R5.3) to redefine the retract plane for the subsequent G81 holes. To change a cycle parameter value (like R) for the canned cycles, either a cycle block (e.g., *N75 P2=25000) or another complete G8x statement (with the Z, R, (optional) K and any other required letters) is required.

10.5 Two-axes Collinear Tracking Programming This special feature, sometimes called the Collinear Axes Tracking Feature, allows the NC part programmer to manage two collinear axes, Z and W, by programming the axis to move and the target is the distance to the part, rather than the distance to move that axis. This feature continually tracks two collinear axes, W and Z. The absolute programming of either axis results in the programming of the collinear axes distance rather than either individual axis. This feature is similar to that found on other CNC controls. This feature assumes there is a primary tracking axis. The primary axis determines the motion when both axes are programmed in the same NC block in absolute dimensions. The default tracking axis is W. To change this behavior, G700 directs tracking on W while G701 directs tracking on Z.

Page 364: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 364/376

When either axis is programmed in absolute dimension mode (G90), the axis is moved such that at the end of the move the collinear distance is equal to the programmed position. For example, with an NC statement of

N100 G90 Z10.0 Z will be moved to a location such that the W/Z collinear distance is 10.0 inches. With this feature enabled, the programmer must recognized a new way to program these two collinear axis (�new� being different than all the other axes in the machine). See the G92 comments below. There is a new simple rule for any W or Z block in G90:

The W or Z value is the new distance from the tool to the part. The W or Z value is NOT the new axis position.

When both axes are programmed in G90, the actual motion depends on the tracking axis. If the control is tracking on W, then Z will move as directed while W is moved such that its final position results in the W/Z collinear distance being equal to the W programmed position. If the control is tracking on Z, then the opposite occurs. When either axis (or both) is programmed in incremental dimension mode (G91), each axis is moved as directed and the collinear distance is adjusted accordingly. The Collinear Axes Tracking Feature's axis position display overlay (with the current Collinear Distance shown in Position column) will be present whenever the CNC screen is in either the MANUAL or AUTOMATIC display modes. This behavior is controlled from the PLC application. The offset data shown in the axis position display overlay is the tool length compensation value (from the active H parameter value). The tool length compensation value affects only the collinear axes distance. It does not affect the position of either W or Z axis. There are several special programming considerations for this feature. M12 M12 is a command to move Z to that absolute position, regardless of the current Z position or the current collinear distance. The W/Z collinear distance is updated accordingly during this move. M12 is valid only with G90 modal (absolute position programming); otherwise it is a programming error. (Without the M12, the Z value in the block would be treated as the new collinear distance, not just the position for Z.) This M12 is essentially a feature override, allowing the operator to temporarily program and move Z to a particular position (just like any other axis (not W or Z) in this machine). G92 The interpretation of the G92 statement depends on the tracking axis. The default tracking axis is W so in that case a G92 W results in the W value becoming the new collinear distance (affected by the Z position) and the W G92 offset is given the appropriate value (for the new W position). A G92 Z results in that change to

Page 365: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 365/376

the Z G92 offset and the collinear distance is calculated for the current Z and W positions. The opposite interpretations of W and Z for G92 occur when the default tracking axis is Z. When both axes are in the same G92 statement, the non-tracking axis has its position updated first for the specified G92 offset and then the tracking axis has its position and G92 offset updated for the specified new collinear distance. As is expected, a G92 with no axes in the statement results in the cancellation of all G92 axis offsets. After that action, the W/Z collinear distance is updated according to the current W and Z positions. The common use of G92 in combination with this feature is the G92 will define the distance from the end of the tool to the part surface. By doing either a G92Z0 or G92W0 when the tool tip is just touching the part surface, the collinear axis position is defined to be 0 at part surface (and a G92 offset is applied to that axis so that its new position in G92 part coordinates is 0.0). If a subsequent block is either Z1 or W1 (in G90) then the tool tip would be moved one inch from the surface (with the axis letter defining which axis is moving the tool tip to that target position). If a subsequent block is either Z-1 or W-1 then the tool tip would be moved one inch into the part.

10.6 Extended Part Offsets Programming This special feature, often called the extended part offsets feature, allows the NC part programmer to manage more than the usual set of six part zero offsets, described in section 5.1.2. The standard part offsets are available in the part program by the G54 to G59 codes; G53 cancels the active set. The CNC has a built-in table editor to enable the configuration of these six sets of part offsets. With this special feature, the part program can access a larger range of offsets than six. The part program syntax for this additional set of part zero offsets is similar to that used in other controls for their similar feature, like

N1230 G54 P1 The above P1 with the G54 specifies the index to one of the additional sets of these part zero offsets. This feature can be configured with its range for this set. Each additional set of G54Px offsets will support four axes. Typically this range for Px will be from 1 up to either 48 to 300 (so the NC syntax is from G54 P1 all the way up to either G54 P48 to G54 P300). G54P0 will be treated the same as just G54. Error 145 results if the G54 P-value is too large for the configuration. The system integrator will define what is the range of acceptable Px values for G54.

10.6.1 Programming the additional Part Offsets In addition to the Px with the G54, there is another part programming change that is required for this feature to properly handle the interaction of these additional offsets with those that are built-in (G54 to G59). There must be a G10 block before and after the G54 NC code segments in the part program.

Page 366: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 366/376

For example:

. . .N1220 G10N1230 G54 P1 (G54 EXTENDED SET 1)N1240 Z15 G0. . .N1380 G10N1390 G54 P7 (G54 EXTENDED SET 7)N1400 Z14 G0. . .N1700 G10N1710 G58N1720 Z14 G0. . .N1940 G53N1950 M30

Note that there is a G10 in the block immediately before the G54 (with or without an accompanying P-value) and there is another G10 in the block immediately before the next G-code in the range of G53 to G59. This G10 is only required for the G54, not G53 or G55 to G59. This rule results in the requirement for the G10's in N1220 and N1380 for the G54 in N1230 and G10's in N1380 and N1700 for the G54 in N1390. No G10 is needed for the G58 in N1710 or the G53 in N1940. This G10 is required in the part program because the CNC, upon the G54Px block, will be updating the G54 set of part offsets (the real G54 set is saved to several cycle parameters while the new set of G54 offsets is retrieved from its storage in cycle parameters). If the G10 is not included in the part program then those changes being done during the block look ahead could affect preceding blocks under certain circumstances (like an MDI in the middle of the program execution). This use of G10 is required only when there is at least one block with G54Px in the part program. If a part program remains within the standard six sets of part zero offsets (i.e., G54 to G59) then there is no requirement for the G10 to be associated with G54 (before and after).

10.6.2 Managing the additional part offsets The quantity of this extended set of part zero offsets is determined by the system integrator. The common ranges are either 48 or 300, similar to that on other controls. This special feature using a set of 300 also requires more than the standard set of cycle parameters (the default is 1000 of those). When a particular G54Px is active or modal, using the Data � Modify Zero Offsets to change the G54 axis offsets will change the offsets for that G54Px set. Upon a control reset or a change in the modal G53-G59, the set of offsets for the modal G54Px will be saved to the appropriate memory (in the cycle parameters). Therefore these additional sets of part offsets can be managed by the operator in two ways: 1) Data � Modify Zero Offsets � to modify the active part offset. 2) Data � Modify Cycle Parameters � to modify the (inactive) part offsets in their storage locations.

Page 367: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 367/376

Note: If no part offset is active and if the G54 values are edited using option 1, upon a subsequent use of G54Px those values from the table are saved to the storage locations. The usual procedure for editing G54 offsets (or G54P0) is assumed to be with the Zero Offsets table editor. Option 1 takes precedence over option 2. If a G54Px part offset is active and if the G54 values are edited using option 1, upon a change in the active part zero offset (G53 to G59 or another G54Px) then those values from the table are saved to the storage locations. The usual procedure for editing G54 offsets is assumed to be with the Zero Offsets table editor. If the second option (editing cycle parameters) is used while that particular G54Px part zero offset is active, then upon its deactivation those changes will be lost because the first option will always copy the currently active offset values into the storage locations for the active offset. Remember that option 1 takes precedence over option 2. If the second option is used when the particular offset is not active (Px, where X is not 0) then no conflict exists. The potential conflict between operator options 1 and 2 exists only while a particular G54Px is active. The same conditions apply to the PLC writing either the active part offsets values or the cycle parameters. Just as the operator can manage these offsets in two ways, the PLC can write them in either manner via its CNC interface signals. While any of the G54 to G59 offsets will include all configured axes, these additional sets include offsets for only the first four axes. That is a significant limitation of this feature, though other controls have similarly offered up to four axes per part zero offset. If the offsets are changed for the fifth or higher axes when the G54Px is active, those changes will be lost (when saved to the storage locations). They will be active only as long as the G53-G59 is not changed (either in an NC block with G53-G59 or with a control reset). If offsets are required for the fifth axis (or higher) then those axis offsets must be managed manually since they will never be saved to the storage locations. This feature for more part zero offsets is not intended to be used on machines requiring more than four axes per each part offset. If the operator or programmer wishes to save the extended set of part zero offsets to a data file then the complete set of cycle parameters must be saved to a file. The extended set of offsets are stored in a block of cycle parameters. The file for the part zero offsets table will always consist of only the G54 to G59 offsets, the standard set of six rows in the CNC table.

Page 368: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 368/376

Index ABS ...................................................... 219 Absolute dimension........................ 41, 171 Acceleration

Programmable .................................. 100 A-code .................................................. 218 Address letter.......................................... 16 Analog

Input ......................................... 224, 235 Output....................................... 224, 235

Angle cut off......................................... 149 Approach block .................................... 140 ART (Advanced Regulation Technology)

.......................................................... 134 ASCII characters .................................... 31 ASCII code range ................................. 218 ATN...................................................... 219 Automatically intermediated block ...... 275 AV ................................................. 215, 229 Axis

Feed .................................................... 33 Gantry................................................. 36 Helical ................................................ 52 Letter ......................................... 215, 229 Longitudinal ..................................... 280 Major .................................................. 48 Minor.................................................. 48 Orientation.................................... 33, 36 Position............................................. 228 Resettable rotational ........................... 37 Rotary................................................. 35 Software travel limits ......................... 38 Work field travel limits .................... 183

Barrel cam transformation Cartesian coordinates ....................... 277 Centerline deviation ......................... 282 Cylinder coordinates ........................ 279 General ............................................. 277 Osculation plane............................... 281 Radius compensation........................ 280

BCD-code............................................... 22 Block

Layout................................................. 15 Number............................................... 15

Read over............................................ 24 Slash (/) .............................................. 15 Suppression ........................................ 24

Block checksum ..................................... 29 Block length ........................................... 28 Block read over (/).................................. 24 Block start

Cycle programming............................ 28 Ignore ................................................. 28 Normal................................................ 28

Canned cycles...............See Drilling cycles Carriage return.................See Character, cr Cartesian coordinate............................. 178 Center of circular arc.............................. 47 Character

*.................................................. 28, 214 /..................................... 15, 28, 214, 215 @.. ................................................ 28, 29 A..35, 218, 236, 283, 301, 303, 304, 333 ASCII set ............................................ 31 B.. ....................................... 35, 100, 283 C.. ......................... 35, 73, 279, 315, 333 cr................................................... 27, 28 D.. .... 105, 106, 109, 139, 145, 150, 196,

213, 215, 217, 226, 267, 281, 321, 357

E.. ................................. 82, 88, 297, 329 F..... 87, 97, 98, 114, 118, 266, 297, 309,

326, 330, 336, 360 G.. ......................... 17, 20, 168, 236, 321 H.. .... 105, 108, 109, 195, 213, 215, 217,

274, 320, 321, 357 I... 47, 176, 181, 304, 330, 337, 354, 360 J...47, 176, 181, 304, 330, 337, 354, 360 K.. .... 47, 49, 50, 61, 65, 85, 86, 87, 268,

283, 304, 311, 337, 354, 360 L.. ................................................. 24, 75 lf.. ........................................... 27, 28, 29 M.. ................................................ 22, 62 N.. ................................................. 15, 28 P......... 27, 213, 215, 217, 218, 222, 344,

347, 350, 353, 365 Q.. ............................... 25, 344, 347, 350

Page 369: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 369/376

R.. ...... 88, 190, 193, 277, 306, 323, 344, 347, 351, 354, 360

S....... 101, 102, 103, 104, 174, 275, 276, 307, 309, 310, 311, 312

T.. ..................... 109, 114, 121, 311, 357 U.. ...... 35, 114, 115, 116, 121, 131, 132,

282, 283, 314, 323, 328, 344, 345, 347, 351, 354, 360

V.. ...... 35, 114, 116, 118, 121, 125, 279, 314, 315, 323, 328, 351, 354, 360

W.. .............. 35, 344, 345, 347, 360, 363 X..33, 182, 271, 314, 337, 345, 347, 351 Y.. ............................... 33, 182, 271, 314 Z.. 33, 74, 182, 271, 337, 345, 347, 351,

360, 363 Checksum......................................... 28, 29 Circle center ........................................... 47 Circular interpolation ....................... 46, 50 Clockwise ......................................... 46, 50 Comment ........................................ 26, 215 Compensation

End point radius ............................... 150 Path..................... 66, 106, 135, 226, 267 Path during spline interpolation ....... 150 Path velocity..................................... 152 Real-time radius ................. 90, 150, 280 Real-time radius with 5-axes.............. 94 Tool data........................................... 105 Tool length ....................... 107, 108, 226 Tool tip radius .......................... 105, 106

Conditional instruction......................... 229 Constant circumferential speed ............ 311 Constant cutting speed ......................... 310 Constant surface speed ......................... 103 Contour accuracy............................ 85, 268 Contour error .......................................... 77 Control reset ...... 17, 20, 22, 24, 68, 74, 98,

100, 114, 128, 167, 170, 175, 184, 190, 194, 214, 227, 288, 291, 305, 309, 310, 335

Corner acceleration ................................ 82 Corner deviation..................................... 88 Corner smoothing ..................................... 88 Corner smoothing with radius

compensation...................................... 91 Correction table number............... 106, 108 COS ...................................................... 219

Counter-clockwise............................ 46, 50 CSS....................................................... 103 Curvature accleration ............................. 87 Curvature accuracy................................. 87 Curvature activation ............................... 86 Curvature bend angle ............................. 91 Curvature radius ..................................... 88 Cycle block..................................... 27, 213 Cycle parameter.................... 222, 224, 236 Cycle programming 27, 224, 236, 347, 349 D-code .................................. 213, 215, 226 DGR ..................................................... 219 Diameter Programming .............................. 285 Distance regulation............................... 291

Activate/deactivate ................................ 291 Axis selection ................................... 291

DO ................................. 215, 229, 233, 234 Drilling cycles

Bore out ............................................ 253 Bore out with intermediate halt........ 259 Bore out with spindle halt ................ 257 Cycle parameter values .................... 238 Deep hole drilling............................. 247 Deselecting ....................................... 242 Drill to depth .................................... 243 Final hole depth................................ 238 Introduction ...................................... 237 Reaming ........................................... 251 Reaming with measuring stop .......... 255 Reference plane ................................ 238 Retract plane..................................... 238 Spot facing with dwell...................... 245 Termination ...................................... 240 Thread cutting or tapping ................. 249

DTAB................................................... 106 Dummy block....... 164, 187, 217, 266, 267 Dummy checksum.................................. 30 Dummy coordinate................................. 64 Dwell ...................................................... 87 DWRC

Activation ......................................... 203 Application schemes ........................ 200 Dresser, wheel, tool tip radius

compensation................................ 195 Entry/exit move types....................... 199 G-codes............................................. 199 Orientations ...................................... 196

Page 370: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 370/376

Tables for compensation .................. 195 Dynamic block buffer....................... 66, 76 End of program...........................See M002 Error

108...................................... 65, 280, 321 114...................................................... 51 121.................................................... 152 145 ............................ 282, 284, 322, 365 18...................................................... 193 196.................................................... 295 199.............................................. 98, 266 204.................................................... 181 209.................................................... 152 211........................ 38, 73, 184, 292, 321 241.................................... 280, 287, 321 257...................................................... 65 259.................................................... 214 260.................................................... 231 261............................................ 227, 232 262.................................... 223, 227, 232 263.................................................... 232 272............................................ 329, 333 274............................................ 329, 332 30........................................................ 32 315.................................................... 356 32........................................................ 76 376............................................ 334, 335 377.................................................... 334 431.................................................... 292 432.................................................... 291 433.................................................... 291 435..................................................... 287 444.................................................... 335 445.................................................... 311 490.................................................... 324 491.................................................... 324 54........................................................ 69 69.............................................. 229, 234 708.................................................... 356 709.................................................... 356 710.................................................... 356 711.................................................... 356 712.................................................... 356 816...................................................... 26 871.................................................... 104 98...................................................... 160

Errors

Cycle programming.......................... 231 Example program

Base plate ......................................... 261 External program.................................... 27 Fast output signals................................ 113 Feed ................................................ 43, 113 Feed influencing with probe signals..... 293 Feed interpolation................................. 296 Feed override ON/OFF........................... 98 Feed rate ............................... 43, 47, 59, 97 File format

First line.............................................. 26 Length compensation (H)................. 108 NC program........................................ 28 Part position offset table................... 168 Path compensation (D) ..................... 106 Program number................................. 26 Subroutine name................................. 25

Floating point precision........................ 217 G000.... 39, 64, 98, 99, 240, 269, 280, 321,

326, 346, 349 G001.... 43, 57, 64, 86, 240, 269, 308, 326,

336, 346, 349, 358 G002...... 46, 48, 57, 64, 86, 161, 180, 182,

240, 266, 268, 269, 336, 346, 349 G003 46, 57, 160, 163, 180, 182, 240, 266,

268, 269, 336, 346, 349 G004............................. 65, 81, 87, 98, 332 G005....................................................... 62 G006................................. 62, 64, 240, 270 G007............. 52, 57, 59, 86, 240, 268, 336 G008..................... 79, 85, 86, 97, 336, 338 G009................................. 79, 86, 265, 336 G010....................................... 76, 217, 366 G011........................................... 66, 77, 81 G012.. 50, 57, 86, 180, 240, 266, 268, 346,

349 G013.. 50, 57, 64, 180, 240, 266, 268, 346,

349 G014............. 175, 178, 180, 269, 287, 315 G015............................. 175, 178, 269, 315 G016..................................... 175, 178, 182 G017...... 47, 136, 175, 176, 178, 180, 190,

200, 287 G018..................................... 176, 180, 200 G019............................................. 176, 180 G020............... 48, 176, 178, 180, 181, 182

Page 371: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 371/376

G021 ...................................................... 313 G022 ...................................................... 313 G024............................................. 183, 194 G025..................................................... 183 G026..................................................... 183 G027..................................................... 183 G033 98, 99, 102, 152, 240, 270, 276, 308,

336 G034..................................... 240, 308, 337 G035..................................................... 329 G038..................... 185, 274, 287, 313, 321 G039..................................................... 186 G04096, 105, 139, 143, 145, 154, 180, 267 G041...... 52, 109, 139, 140, 142, 154, 161,

163, 267, 270 G042....... 52, 139, 140, 142, 154, 160, 161 G043............................................. 139, 142 G044..................................... 139, 142, 161 G045..................................................... 204 G046............................................. 204, 209 G050............................................. 180, 193 G051............................. 180, 190, 287, 321 G052..................................... 180, 190, 321 G053..................... 166, 167, 288, 326, 365 G054. 53, 72, 166, 168, 174, 213, 227, 320 G054P ................................................. 365 G055............................................. 166, 168 G059............................................. 320, 326 G063............................... 98, 101, 308, 326 G066............................... 98, 101, 308, 326 G070....... 97, 170, 184, 315, 326, 358, 359 G071............... 97, 170, 184, 315, 326, 359 G072....................................................... 77 G073................................................. 77, 79 G074.... 53, 79, 98, 99, 102, 152, 280, 292,

313, 321 G075....................................................... 86 G076....................................................... 87 G078..................................... 66, 68, 69, 72 G079................................................. 66, 68 G080............................................. 242, 243 G081............................. 237, 243, 266, 360 G082............................................. 245, 360 G083............................................. 247, 361 G084............................................. 249, 361 G085............................................. 251, 361 G086............................................. 253, 361

G087............................................. 255, 361 G088............................................. 257, 362 G089............................................. 259, 362 G090 40, 41, 171, 184, 190, 301, 315, 326,

364 G091 42, 69, 171, 184, 190, 193, 301, 304,

315, 326 G092.. 37, 53, 57, 58, 65, 72, 76, 101, 103,

152, 166, 173, 178, 187, 190, 266, 273, 276, 280, 284, 295, 296, 308, 313, 320, 321, 364

G093............................................. 310, 358 G094............................... 97, 309, 334, 359 G095........................... 79, 87, 97, 309, 334 G096..................................... 103, 276, 310 G097............................................. 104, 310 G098..................................................... 326 G100.............................. 269, 284, 315, 321 G101............................................. 315, 321 G102..................................................... 277 G103..................................................... 280 G104..................................................... 282 G105............................................. 279, 315 G106............................................. 279, 315 G107..................................................... 280 G108..................................................... 282 G110............................. 113, 118, 131, 132 G111............. 114, 115, 116, 118, 121, 125 G112..................... 115, 116, 118, 121, 125 G113............................. 115, 116, 121, 125 G114..................................................... 121 G115..................................................... 121 G116............................................. 130, 132 G117............................................. 130, 132 G133..................................................... 342 G134..................................................... 343 G150........................................................ 94 G151........................................................ 94 G152........................................................ 94 G160..................................................... 134 G170..................................................... 294 G171..................................................... 294 G172..................................................... 294 G181....................................................... 91 G182....................................................... 91 G186........... 49, 52, 61, 65, 82, 85, 87, 268 G188..................................... 325, 326, 327

Page 372: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 372/376

G190...................................................... 285 G191.............................................. 285, 289 G192...................................................... 285 G193...................................................... 285 G200........................................................ 88 G201.................................................. 88, 92 G202.................................................. 88, 92 G203.................................................. 88, 93 G210............................................. 131, 132 G220...................................................... 269 G221...................................................... 269 G222...................................................... 269 G223...................................................... 269 G265..................................................... 291 G270............................. 344, 346, 349, 350 G271............................. 344, 346, 349, 350 G272............................................. 347, 350 G274..................................................... 351 G275..................................................... 352 G276..................................................... 354 G310............................................. 131, 132 G700 .................................................... 363 G701 .................................................... 363 G-code ............................................ 20, 236 GO................................. 215, 229, 233, 234 GTAB................................................... 168 Handwheel in automatic mode............. 298 H-code .................................. 213, 215, 226 Helical interpolation............................... 52 HTAB................................................... 108 IB 215, 227 IF comparisons ..................................... 233 IF.. ......................................... 215, 229, 233 Ignore block............................................ 24 Imperial ........................................ See Inch IN_CYCLB_01 .................................... 227 IN_GEAR01......................................... 275 IN_POS_01 .......................................... 327 Inch....................................................... 170 Incremental dimension ................... 42, 171 Input bit from PLC ............................... 227 Instruction......................................... 15, 17 INT ....................................................... 219 Integer range......................................... 217 Intermediate block........................ 146, 204 Interpolation

Circular........... 46, 50, 86, 152, 266, 268

Linear ............................. 39, 43, 86, 152 Precision stop ..................................... 77 Spline...................... 62, 64, 86, 150, 152 Tangential circular.............................. 59

Interpolation parameter .......................... 50 Jump instruction ................................... 229 KV display............................................ 342 KV factor................................................ 77 Laser power control.......See Power control Laser shutter control............................. 128 L-code............................................... 24, 75 Letter ....................................See Character Line feed...........................See Character, lf Linear interpolation .....................See G001 Look ahead ............... 77, 79, 100, 265, 268 Loop ....................................................... 24 M000 ................................ 75, 76, 112, 331 M001 .............................................. 75, 265 M00222, 24, 25, 27, 32, 75, 114, 174, 190,

267, 326, 327 M003 .................................... 101, 307, 336 M004 .................................... 101, 307, 336 M005 ............................................ 101, 307 M006............................................ 110, 111 M012.................................................... 364 M019 .................................... 101, 104, 312 M020 .................................................... 331 M021 .................................................... 331 M030 ..........................................See M002 M040 .................................................... 274 M041 .................................................... 274 M046 .................................................... 274 M070 ................................................ 62, 63 M071 ................................................ 62, 63 M072 ................................................ 62, 63 M073 ................................................ 62, 64 M080 .............................................. 53, 293 M081........................................................ 20 M101 .................................................... 128 M102 .................................................... 128 M103 .................................................... 128 M104 .................................................... 128 M105 .................................................... 128 M106 .................................................... 128 M107 .................................................... 128 M108 .................................................... 128 M109 .................................................... 128

Page 373: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 373/376

M111 .................................................... 128 M112 .................................................... 128 M113 .................................................... 128 M114 .................................................... 128 M115 .................................................... 128 M116 .................................................... 128 M117 .................................................... 128 M118 .................................................... 128 M121 .................................................... 131 M128 .................................................... 131 M140...................................................... 291 M141...................................................... 291 M151.............................................. 293, 294 M152.............................................. 293, 294 M153.............................................. 293, 294 M154.............................................. 293, 294 M155...................................................... 293 M156...................................................... 293 M157...................................................... 293 M158...................................................... 293 M159 .................................................... 295 M160 .................................................... 295 M161.............................................. 293, 296 M162.............................................. 293, 296 M163...................................................... 293 M164...................................................... 293 M165...................................................... 293 M166...................................................... 293 M167...................................................... 293 M168...................................................... 293 M170...................................................... 296 M171 ............................................ 295, 296 M200 .................................................... 298 M201...................................................... 298 M209...................................................... 298 M210...................................................... 298 M211...................................................... 298 M213...................................................... 307 M214...................................................... 307 M215...................................................... 307 M223...................................................... 307 M224...................................................... 307 M225...................................................... 307 M280 .................................................... 333 M290 .................................................... 333 Major axis............................................. 181 M-code ................................................... 22

Metric ................................................... 170 Minor axis ............................................ 181 Mirror ................................................... 185 MOD..................................................... 219 Modal ..................................................... 17 MSG..................................................... 112 Multiple spindles .................................. 307 MV ................................................. 215, 229 NC block ......................See Program block Non-modal.............................................. 17 OB ................................................. 215, 227 ON_CYCB01 ....................................... 227 Operation sequence .............................. 221 Optional halt........................................... 75 Output bit to PLC ................................. 227 P01........................................................ 247 P02....... 243, 245, 247, 249, 251, 253, 255,

257, 259 P03....... 243, 245, 247, 249, 251, 253, 255,

257, 259 P04 245, 247, 249, 251, 253, 255, 257, 259 P05........................................................ 247 P06........................................................ 247 P08........................................................ 253 P09........................................................ 253 P10....... 243, 245, 247, 249, 251, 253, 255,

257, 259 P11........................................................ 255 P12........................................................ 255 P13................................................ 255, 259 P14........................................................ 247 P15........................................................ 259 P34........................................................ 225 P59........................................................ 225 P900001................................................ 236 P999981................................................ 237 Parallel axes.......................................... 313 Part position offset .......................... 215, 227 Part position offset table number ......... 168 Part reference........................................ 173 Part rotation .......................................... 190 Polar coordinate.................................... 175 Polar transformation............................. 315 Pole point...................................... 178, 182 Positioning axis .................................... 325 Power control ....................................... 113

Fast output signals............................ 128

Page 374: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 374/376

Multiple output channels.................. 131 Pulsing output................................... 130

PP ......................................................... 223 Probe....................................................... 53

Contact processing ............................. 57 Program

BCD functions.................................... 22 Block .................................................. 15 Conditional stop ................................. 75 End ..................................................... 75 Interruption......................................... 75 Repeat................................................. 24 Unconditional stop ............................. 75 Word................................................... 16

Program checksum ................................. 29 Program number............................... 26, 28 Programmable Acceleration..................See

Acceleration,Programmable Programmable homing ........................... 53 Programmable oscillation..................... 329 Programming

Absolute dimensions ........................ 171 Additional part offsets ................... 365 Angled wheel transformation................ 269 Axes with no spindle.......................... 35 Axis mirror ....................................... 185 Axis rotation....................................... 37 Barrel cam transformation....... 277, 279,

280, 282 Circular interpolation with circle center

........................................................ 46 Circular interpolation with radius ...... 50 Collinear axes tracking ................. 363 Contour accuracy................................ 85 Corner acceleration ............................ 82 Corner smoothing ................................. 88 Curvature............................................ 86 Diameter turning cycle (inner/outer) 352 Distance regulation........................... 291 Drilling cycles .................................. 237 Dwell .................................................. 87 DWRC.............................................. 199 Feed axes ............................................ 34 Feed interpolation............................. 297 Feed override...................................... 98 Feedrate .............................................. 97 Finishing cycle (turning) .................. 350

G092................................................... 72 Handwheel in automatic mode......... 298 Helical interpolation........................... 52 Inch format ....................................... 170 Incremental dimensions.................... 171 Interpolation with precistion stop....... 77 Inverse time with G93 ................... 358 Laser power control.......................... 113 Laser shutter control......................... 128 Lathe diameter...................................... 285 Lathe T-code .................................. 357 Look ahead ................................. 79, 265 Metric format.................................... 170 Multiple pass threading cycle (turning)

...................................................... 354 Multiple spindles .............................. 307 Operator stop ...................................... 75 Oscillation ........................................ 329 Parallel axes...................................... 313 Part coordinates ................................ 173 Part position offsets.......................... 166 Part rotation ...................................... 190 Part scaling ....................................... 193 Path compensation.................... 135, 139 Peck finishing cycle (turning) .......... 351 Plane for 2-axis operations............... 180 Polar coordinates .............................. 175 Polar transformation......................... 315 Positioning axis ................................ 326 Power control ................................... 113 Probe input for feedrate.................... 293 Rotary in G70 ................................. 358 Rotary with G93 ............................. 358 Rotating axes .................................... 300 Round axis........................................ 300 Safe zone .......................................... 183 Spindle.............................................. 101 Spindle gear range selection............. 274 Spindle speed override ..................... 101 Spline definition ................................. 62 Spline interpolation ............................ 64 Stock removal (turning) ............... 344, 347 Switchover Spindle/Rotary axis ....... 333 Tangential circular interpolation ........ 59 Tangential lead-in angle ..................... 73 Tangential orientation ........................ 66 Thread cutting .................................. 336

Page 375: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 375/376

To avoid errors ................................. 266 Turning cycles .................................. 344 Work cycles...................................... 236

Programming summary G-codes............................................... 20 Geometric instructions ....................... 23 M-codes.............................................. 22 Positioning instructions ...................... 23 Program execution instructions.......... 23 Technical instructions ........................ 23

PST-code ................................................ 27 RAD ..................................................... 219 Radius..................................................... 50 Rapid traverse..............................See G000 Repeat program ...................................... 24 Retreat block ................................ 143, 164 Rotation number................................... 304

Range................................................ 305 Round (or rotary) axis .......................... 300 Round axis

Modulo ............................................. 300 Normal.............................................. 300 Resettable rotational ........................... 37 Shortest way ..................................... 300

Safe zone Lower limits ..................................... 183 Upper limits...................................... 183

Scaling.................................................. 193 SEL........................................................ 216 SEL functions....................................... 235 Set axis coordinate ............................... 173 SIN ....................................................... 219 Slash code............................................... 15 Speed .......................................... 43, 47, 59 Spindle

Clockwise ......................................... 101 Counter-clockwise............................ 101 Gear range selection ................... 269, 274 OFF................................................... 101 ON .................................................... 101 Orientation........................ 101, 104, 312 Override............................................ 101 Reversal ............................................ 104 RPM ................................................. 104 Speed limitation................................ 103

Spindle speed..............................See Speed Spline

Deactivate........................................... 64 Definition ........................................... 62 Interpolation ....................................... 62 Path velocity....................................... 65 Tangential transition........................... 62 Type.............................................. 62, 64

SQT ...................................................... 219 Station identifier ......................................... 28 Stock removal cycles............................ 344 Subprogram ........................See Subroutine Subroutine 24, 25, 264, 266, 267, 347, 349

File name ............................................ 25 Levels ................................................. 25

Subroutine levels .................................. 242 Switchover spindle and rotary axis ...... 333 T0 ................................................. 110, 112 Tangent

Angle offset ........................................ 69 Lead-in ............................................... 68 Vector ................................................. 68 Vector angle ....................................... 68

Tangential circular interpolation ............ 59 Tangential setting ................................... 66 T-code ......................................... 109, 357 Temporary NC block............................ 275 Thread cutting

Conical............................................... 341 Cylindrical .......................................... 338 General ............................................. 336 Lag free thread ................................. 342 Length of thread ............................... 337 Pitch.................................................. 337 Run out ............................................. 337 Spindle control ......................... 336, 338

Time span ............................................. 113 Tool management.............................. 110 Traverse instruction.....................See G000 Turning cycles ...................................... 344 U00....................................................... 116 U01....................................................... 116 U02....................................................... 116 U03....................................................... 116 U09....................................................... 116 U10....................................................... 116 U20....................................................... 119 U30....................................................... 121 U31....................................................... 121

Page 376: Part Programming Manual MACHINEMATEjinhoe/Notes/SKMP4722 Modern... · 1 BASICS OF NC PROGRAMMING ... 4.2.2 M03, M04 Spindle ON, Clockwise or Counter-Clockwise ... Part Programming

MACHINEMATE®

Part Programming Manual page 376/376

U32....................................................... 121 U33....................................................... 121 U41....................................................... 125 U42....................................................... 125 U43....................................................... 125

Voltage ......................................... 113, 116 Wear offset............................................. 215 Whole number range ............................ 217 Work cycle ................................... 224, 236 Work field limits ..................See Safe zone