Navigation

  • Page 1

    CNC SYSTEMOSP-P200M/P200MA/P20MOSP-P200M-R/P200MA-R/P20M-RPROGRAMMING MANUAL(10th Edition)Pub No. 5228-E-R9 (ME33-018-R10) Oct. 2010

  • Page 2

    5228-E P-(i)SAFETY PRECAUTIONSSAFETY PRECAUTIONSThe machine is equipped with safety devices which serve to protect personnel and the machine itself fromhazards arising from unforeseen accidents. However, operators must not rely exclusively on these safetydevices: they must also become fully famil...

  • Page 3

    5228-E P-(ii)SAFETY PRECAUTIONS3.Precautions Relating to Operation(1) After turning on the power, carry out inspection and adjustment in accordance with the dailyinspection procedure described in this instruction manual.(2) Use tools whose dimensions and type are appropriate for the work undertak...

  • Page 4

    5228-E P-(iii)SAFETY PRECAUTIONS6.Precautions during Maintenance Inspection and When Trouble OccursIn order to prevent unforeseen accidents, damage to the machine, etc., it is essential to observe thefollowing points when performing maintenance inspections or during checking when trouble hasoccur...

  • Page 5

    5228-E P-(iv)SAFETY PRECAUTIONSc.The control enclosure contains the NC unit, and the NC unit has a printed circuit boardwhose memory stores the machining programs, parameters, etc. In order to ensure that thecontents of this memory will be retained even when the power is switched off, the memoryi...

  • Page 6

    5228-E P-(v)SAFETY PRECAUTIONS8.Symbols Used in This ManualThe following warning indications are used in this manual to draw attention to information ofparticular importance. Read the instructions marked with these symbols carefully and follow them.indicates an imminently hazardous situation whic...

  • Page 7

    5228-E P-(i)INTRODUCTIONINTRODUCTIONThank you very much for choosing our NC system. This NC system is an expandable CNC with variousfeatures. Major features of the NC system are described below. (1) Compact and highly reliableThe CNC system has become compact and highly reliable because of advan...

  • Page 8

    5228-E P-(i)TABLE OF CONTENTSTABLE OF CONTENTS 13,SECTION 1 13,PROGRAM CONFIGURATIO 13,NS 13,.............................................................1 13,1. 13,Program Types and Ex 13,tensions............................................................................................... ...

  • Page 9

    5228-E P-(ii)TABLE OF CONTENTS 43,5. 43,Following Error Check 43,........................................................................................................... 43,31 44,6. 44,Positioning (G00) 44,......................................................................................

  • Page 10

    5228-E P-(iii)TABLE OF CONTENTS 110,5. 110,Three-dimensional Tool Offset 110, (G43, 110, G44) (Optional) 110,........................................................... 110,98 110,5-1. 110,Three-dimensional Tool Offset Start- 110,up 110,...........................................................

  • Page 11

    5228-E P-(iv)TABLE OF CONTENTS 144,2-3. 144,Positioning at Calculated Patt 144,ern Points 144,...................................................................... 144,132 144,2-4. 144,Others........................................................................................................

  • Page 12

    5228-E P-(v)TABLE OF CONTENTS 198,1. 198,User Task 1 198,......................................................................................................................... 198,186 198,1-1. 198,Branch Function 198,...........................................................................

  • Page 13

    5228-E P-1SECTION 1 PROGRAM CONFIGURATIONSSECTION 1 PROGRAM CONFIGURATIONS1.Program Types and ExtensionsFor OSP-E100M/E10M, four kinds of programs are used: schedule programs, main programs,subprograms, and library programs. The following briefly explains these four kinds of programs.Schedule ...

  • Page 14

    5228-E P-2SECTION 1 PROGRAM CONFIGURATIONS2.Program NameAll programs are assigned a program name or a program number, and a desired program can becalled and executed by simply specifying the program name or number.A program name that contains only alphabetic characters is called a program label...

  • Page 15

    5228-E P-3SECTION 1 PROGRAM CONFIGURATIONS3.Sequence NameAll blocks in a program are assigned a sequence name that begins with address character “N”followed by an alphanumeric sequence.Functions such as a sequence search function, a sequence stop function and a branching functioncan be used...

  • Page 16

    5228-E P-4SECTION 1 PROGRAM CONFIGURATIONS4.Program Format4-1.Word ConfigurationA word is defined as an address character followed by a group of numeric values, an expression, ora variable name. If a word consists of an expression or a variable, the address character must befollowed by an equa...

  • Page 17

    5228-E P-5SECTION 1 PROGRAM CONFIGURATIONS4-3.ProgramA program consists of several blocks.4-4.Programmable Range of Address CharactersThe programmable ranges of numerical values of individual address characters are shown in thefollowing table.AddressFunctionProgrammable RangeRemarksMetricInchOP...

  • Page 18

    5228-E P-6SECTION 1 PROGRAM CONFIGURATIONS5.Mathematical Operation FunctionsMathematical operation functions are used to convey logical operations, arithmetic operations, andtrigonometric functions. A table of the operation symbols is shown below. Operation functions canbe used together with ...

  • Page 19

    5228-E P-7SECTION 1 PROGRAM CONFIGURATIONSLogical Operations• Exclusive OR (EOR) c = a EOR bIf the two corresponding values agree, EOR outputs 0.If the two values do not agree, EOR outputs 1.• Logical OR (OR) c = a OR bIf both corresponding values are 0, OR outputs 0.If not,...

  • Page 20

    5228-E P-8SECTION 1 PROGRAM CONFIGURATIONS• Arc tangent (1) (ATAN)θ = ATAN [b/a]Arc tangent (2) (ATAN2)θ = ATAN2 [b/a]ME33018R1000300080001• Integer implementation (ROUND, FIX, FUP)Converts a specified value into an integer (in units of microns) by rounding off, truncating, orraising the ...

  • Page 21

    5228-E P-9SECTION 1 PROGRAM CONFIGURATIONS7.Program Branch Function (Optional)[Function]The program branch function executes or ignores the program branch command specified in a partprogram according to the ON/OFF setting of the PROGRAM BRANCH switch on the machine panel.The function correspond...

  • Page 22

    5228-E P-10SECTION 1 PROGRAM CONFIGURATIONS9.Message Function (Optional)[Function]For conditional branching it may be necessary to display a message, depending on the processingat the destination of the branching. The message function is used in such cases, and the messageis displayed in enlar...

  • Page 23

    5228-E P-11SECTION 1 PROGRAM CONFIGURATIONS(2) Operation MethodsSelect the operation method using the pop-up window MAIN PROGRAM SELECT (MEMORYMODE) that appears when calling a program to be run. The operation method can be alsoselected by the setting at the NC optional parameter (word) No. 11....

  • Page 24

    5228-E P-12SECTION 1 PROGRAM CONFIGURATIONS• When selecting an operation method, also select the program size and whether theprogram has a sub program branch or not (only in the case of operation A and B). Thetable below shows the relation between the operation method and the program size.(3)...

  • Page 25

    5228-E P-13SECTION 2 COORDINATE SYSTEMS AND COORDINATE COMMANDSSECTION 2 COORDINATE SYSTEMS AND COORDI-NATE COMMANDS1.Coordinate System1-1.Coordinate Systems and ValuesIn order to move a cutting tool to a target position, a coordinate system must be established tospecify the target position usi...

  • Page 26

    5228-E P-14SECTION 2 COORDINATE SYSTEMS AND COORDINATE COMMANDS1-3.Work Coordinate SystemThe coordinate system used to machine workpieces is referred to as the work coordinate system.• Work coordinate systems are established and stored with work coordinate system numbers inthe memory before s...

  • Page 27

    5228-E P-15SECTION 2 COORDINATE SYSTEMS AND COORDINATE COMMANDS2.Coordinate Commands2-1.Numerically Controlled Axes• The following table lists the addresses to be specified to control the axes.• An axis movement command consists of an axis address, a sign indicating the direction of theaxis...

  • Page 28

    5228-E P-16SECTION 2 COORDINATE SYSTEMS AND COORDINATE COMMANDS• The positive directions of the linear and rotary axes are defined as follows:ME33018R1000400050001The definition of the coordinate axes and directions conforms to ISO R841.ISO: International Organization of Standardization2-2.Un...

  • Page 29

    5228-E P-17SECTION 2 COORDINATE SYSTEMS AND COORDINATE COMMANDS2-2-3. Numeric Values (inch / metric switchable as optional function)As the unit for specifying program values, “mm”, “deg.”, “sec”, etc. are used. For these units, adecimal point may be used.• Cautions on using a dec...

  • Page 30

    5228-E P-18SECTION 2 COORDINATE SYSTEMS AND COORDINATE COMMANDS• NC optional parameter (bit) No. 3, bit 0 to bit 7 and No. 4, bit 0Parameter No.Bit No.ContentsWith Check MarkWithout Check Mark30Sets the unit system of length, “inch” or “mm”. (*2)inchmm1Sets the unit of 1 mm, 1 inch, 1...

  • Page 31

    5228-E P-19SECTION 2 COORDINATE SYSTEMS AND COORDINATE COMMANDS• Examples of parameter setting are given below.(●: With check mark, O: Without check mark)• mm systemME33018R1000400090002• inch systemME33018R1000400090003An asterisk (*) in the table indicates setting of “0” or “1...

  • Page 32

    5228-E P-20SECTION 2 COORDINATE SYSTEMS AND COORDINATE COMMANDSThe following is a comparison how a numeric value is interpreted according to whether or not adecimal point is used when “µm / mm unit system” is selected.Command ElementValue“mm unit system” elementX100100 µm–X=100100 ...

  • Page 33

    5228-E P-21SECTION 2 COORDINATE SYSTEMS AND COORDINATE COMMANDS2-3.Travel Limit Commands (G22, G23) (Optional)Since the NC is equipped with absolute position encoders, it is possible to set the travel limit with thesoftware. That is, if the travel limit is set as an absolute value by the softw...

  • Page 34

    5228-E P-22SECTION 2 COORDINATE SYSTEMS AND COORDINATE COMMANDS• Setting the travel limits by a program[Programming format]ME33018R1000400100002The numeric values entered are processed as coordinate values in the work coordinatesystem.“α”, “β”, and “γ” above do not represent an...

  • Page 35

    5228-E P-23SECTION 2 COORDINATE SYSTEMS AND COORDINATE COMMANDS2-4.Home Position Command (G30)[Function]The term “home position” refers to a particular position that can be set for individual machines. Thehome position command is used to move the axes to the preset home position.The home p...

  • Page 36

    5228-E P-24SECTION 2 COORDINATE SYSTEMS AND COORDINATE COMMANDS2-5.Absolute and Incremental Commands (G90, G91)For the designation of axis movement distance, two types of commands (absolute commands,incremental commands) are available.(1) Absolute CommandsG90 specifies the absolute dimensioning...

  • Page 37

    5228-E P-25SECTION 2 COORDINATE SYSTEMS AND COORDINATE COMMANDS2-6.Coordinate Recalculation Command (G97)[Function]After changing the home position (G30) or the coordinate system (G15, G16, G92, etc.), it is usuallynecessary to issue G90 (absolute command) to position each axis (to define the c...

  • Page 38

    5228-E P-26SECTION 3 FEED FUNCTIONSSECTION 3 FEED FUNCTIONS1.Rapid FeedIn the rapid feed mode, each of the axes moves at the specified rapid feedrate independently ofother axes that are moved at the same time. Note that rapid feedrate differs depending on themachine specification. Consequentl...

  • Page 39

    5228-E P-27SECTION 3 FEED FUNCTIONS• Since the clamp feedrate is set in units of “mm/min” it is converted into a value in “mm/rev” unitsusing the following formula:fm = fr × Nwhere,N = spindle speed (rpm)fm = feedrate (mm/min)fr = feedrate (mm/rev)2-3.F1-digit Feed Function (Optional...

  • Page 40

    5228-E P-28SECTION 3 FEED FUNCTIONS2-4.F0 Command During Cutting FeedF0 commands during the cutting feed are activated. When "F0", "F0.0", or "F0." is specified, the NCoperates considering the setting value of the optional parameter long word No. 62 as an F command...

  • Page 41

    5228-E P-29SECTION 3 FEED FUNCTIONS3.Exact Stop Check Function (G09, G61, G64)[Function]• During axis feed control, the calculated value always precedes the actual value when an axis ismoving to the target point. Therefore, if the calculated value is at the target point, the actualvalue is b...

  • Page 42

    5228-E P-30SECTION 3 FEED FUNCTIONS4.Automatic Acceleration and DecelerationAt the start and end of axis movements, axis feedrate is automatically accelerated and decelerated.(1) Automatic Acceleration/Deceleration in Positioning Mode / Manual Feed ModeAxis feed is accelerated and decelerated i...

  • Page 43

    5228-E P-31SECTION 3 FEED FUNCTIONS5.Following Error CheckFollowing error is defined as the difference between the command value output from the NC and theoutput of the position encoder. A DIFF over alarm occurs if a following error exceeds a certain valueduring rapid feed or cutting feed of a...

  • Page 44

    5228-E P-32SECTION 3 FEED FUNCTIONS6.Positioning (G00)[Function]The axes move from the present position to the target position at rapid feedrate. During thismovement, axes are automatically accelerated and decelerated.[Programming format]G00 IP__In the positioning operation executed in the G00...

  • Page 45

    5228-E P-33SECTION 3 FEED FUNCTIONS7.Uni-directional Positioning (G60)[Function]• In the positioning called by G00, positional error is unavoidable if positioning is executed indifferent directions due to backlash in the axis feed mechanism. If positioning is alwaysexecuted in the same direc...

  • Page 46

    5228-E P-34SECTION 3 FEED FUNCTIONS• G60 is a modal command.• Uni-directional positioning is not valid for a cycle axis or shift movement in a fixed cycle.• Uni-directional positioning is not valid on an axis for which no pass-over amount is set.• Mirror image is not applied to the posi...

  • Page 47

    5228-E P-35SECTION 3 FEED FUNCTIONS<“inch” input>ME33018R1000500110003• When the F command (F=1) to the rotary axis in the inch system is issued, whether to interpret"F1" as 1 deg/min or as 25.4 deg/min is set by NC optional parameter (bit) No. 15, bit 7.9.Plane Selection ...

  • Page 48

    5228-E P-36SECTION 3 FEED FUNCTIONS[Details]• Whether a basic axis (X, Y, Z) or a parallel axis (U, V, W) is selected is determined by the axisaddresses specified in the block containing G17, G18 or G19.Examples:ME33018R1000500120003• In blocks where none of G17, G18, and G19 are specified,...

  • Page 49

    5228-E P-37SECTION 3 FEED FUNCTIONS10.Circular Interpolation (G02, G03)[Function]The circular interpolation function moves a tool from the actual position to the specified positionalong an arc at the specified feedrate.[Programming format]ME33018R1000500130001Xp = X-axis or U-axisYp = Y-axis or...

  • Page 50

    5228-E P-38SECTION 3 FEED FUNCTIONS• The end point is defined by either an absolute value or an incremental value according to G90or G91.The center point of an arc is determined by the I, J, and K values which correspond to Xp, Yp,and Zp, respectively. Their coordinate values are always spec...

  • Page 51

    5228-E P-39SECTION 3 FEED FUNCTIONS• If more than one end point is possible, the one which is reached first in the designated arcdirection is selected.Example:ME33018R1000500130006The operations explained above also apply when designation of a vertical axis is omitted.• The center of an arc...

  • Page 52

    5228-E P-40SECTION 3 FEED FUNCTIONS11.Helical Cutting (G02, G03) (Optional)[Function]Helical cutting or helical interpolation may be executed by synchronizing circular interpolation withlinear interpolation of the axis which intersects at right angles the plane in which the arc is defined.[Prog...

  • Page 53

    5228-E P-41SECTION 4 PREPARATORY FUNCTIONSSECTION 4 PREPARATORY FUNCTIONSG codes consisting of address character G and a three-digit number (00 to 399) set the mode that specifieshow the commands are executed.Instead of using address character G, some G codes are expressed by mnemonics. A mnem...

  • Page 54

    5228-E P-42SECTION 4 PREPARATORY FUNCTIONS2.Programmable Mirror Image (G62) (Optional)[Function]The mirror image function creates a geometry which is symmetric around a specific axis. In additionto the mirror image switch on the machine panel, the programmable image function creates mirrorimag...

  • Page 55

    5228-E P-43SECTION 4 PREPARATORY FUNCTIONS(1) If work is selected at local/work coordinate system select of NC optional parameter (MIRRORIMAGE)ME33018R1000600030004(2) If local is selected at local/work coordinate system of NC optional parameter (MIRROR IMAGE)ME33018R1000600030005X - YX' - Y': ...

  • Page 56

    5228-E P-44SECTION 4 PREPARATORY FUNCTIONS3.Work Coordinate System Selection (G15, G16)[Function]20 sets of work coordinate systems are supplied as a standard feature and this can be expanded to50, 100 or 200 sets optionally.[Programming format]Modal G code: G15 Hn (0 ≤ n ≤ 200)Once a new w...

  • Page 57

    5228-E P-45SECTION 4 PREPARATORY FUNCTIONS4.Work Coordinate System Change (G92)[Function]The work coordinate system change function changes the work coordinate system.[Programming format]G92 IP__[Details]• G92 automatically changes the work zero offset value of the presently selected work coo...

  • Page 58

    5228-E P-46SECTION 4 PREPARATORY FUNCTIONS6.Coordinate System Conversion Functions6-1.Parallel Shift and Rotation of Coordinate Systems (G11, G10)[Function]The parallel shift / rotation function shifts or rotates a work coordinate system. The new coordinatesystem defined by shifting or rotatin...

  • Page 59

    5228-E P-47SECTION 4 PREPARATORY FUNCTIONS[Example program]If a local coordinate system is used, the example workpiece shown below would be programmed asindicated in the example program.ME33018R1000600070001 ..................................................Machine coordinate systemZero...

  • Page 60

    5228-E P-48SECTION 4 PREPARATORY FUNCTIONS6-2.Copy Function (COPY, COPYE)[Function]The copy function is used to facilitate part machining by repeating the same pattern with parallelshift and rotation.First, specify parallel shift and rotation of a local coordinate system using COPY instead of G...

  • Page 61

    5228-E P-49SECTION 4 PREPARATORY FUNCTIONS[Example program]ME33018R1000600080001Start point of arcEnd point of arcG11G01COPYG01G03G01COPYE∗ : Circular interpolation commands must not be specified in the block immediately after the COPY block and the one immediately before the COPYE block...

  • Page 62

    5228-E P-50SECTION 4 PREPARATORY FUNCTIONS7.Workpiece Geometry Enlargement / Reduction Function (G51, G50) (Optional)[Function]The workpiece geometry enlargement / reduction function enlarges or reduces the geometrydefined by a program in reference to the point specified in a local coordinate s...

  • Page 63

    5228-E P-51SECTION 4 PREPARATORY FUNCTIONSe.The following Z-axis movements in a fixed cycle:• In-feed and retraction amounts in deep hole drilling cycle (G73, G83)• X, Y shift amounts in fine boring or back boring (G76, G87)Example:Cutter radius compensation and enlargement and reduction of...

  • Page 64

    5228-E P-52SECTION 5 S, T, AND M FUNCTIONSSECTION 5 S, T, AND M FUNCTIONSThis section describes the S, T, and M codes which specify necessary machine operations other than axismovement commands.S: Spindle speedT: Tool number for tool change cycleM: Turning solenoids and other similar devices on...

  • Page 65

    5228-E P-53SECTION 5 S, T, AND M FUNCTIONS3.M Code Function[Function]The M code function outputs an M code number, consisting of a three-digit number and address M,and the strobe to the PLC. The programmable range of M codes is from 0 to 511.3-1.Examples of M CodesThe followings are examples o...

  • Page 66

    5228-E P-54SECTION 5 S, T, AND M FUNCTIONS(6) M54 (Fixed Cycle - Return to Point R Level)In various fixed cycles, this command sets the return position of the cycle axis at the positionspecified by R command.For details, refer to SECTION 7, “Fixed Cycle Operations”.(7) M132, M133 (Single Bl...

  • Page 67

    5228-E P-55SECTION 5 S, T, AND M FUNCTIONS(17) M134, M135 (Spindle Speed Override Valid / Invalid)Even in the status in which spindle speed override control from the PLC is valid, the spindlespeed override function can be made invalid (M134) or valid (M135) with these commands.(18) M136, M137 (...

  • Page 68

    5228-E P-56SECTION 6 OFFSET FUNCTIONSSECTION 6 OFFSET FUNCTIONS1.Tool Length Offset Function (G53 - G59)[Function]The tool length offset function compensates for the position of a cutting tool so that the tip of thecutting tool is located at the programmed position.Available G Codes[Programming...

  • Page 69

    5228-E P-57SECTION 6 OFFSET FUNCTIONS2.Cutter Radius Compensation (G40, G41, G42)2-1.Cutter Radius Compensation Function[Function]The cutter radius compensation function automatically compensates for the cutter radius.Programming the geometry of a workpiece as it is will not result in a correct...

  • Page 70

    5228-E P-58SECTION 6 OFFSET FUNCTIONS• The terms “inside” and “outside” are defined as follows:The angle made between consecutive tool paths is measured at the workpiece side and “inside”and “outside” are defined by the magnitude of this angle. If the angle is larger than 180...

  • Page 71

    5228-E P-59SECTION 6 OFFSET FUNCTIONS2-2.Tool Movement in Start-up2-2-1. Inside Corner Cutting (θ ≥ 180°)(1) Straight line - Straight lineME33018R1000800030001(2) Straight line - ArcME33018R10008000300022-2-2. Obtusely Angled Corner - Outside Cutting (90° ≤ θ ≤ 180°)(1) Straight line...

  • Page 72

    5228-E P-60SECTION 6 OFFSET FUNCTIONS2-2-3. Acutely Angled Corner - Outside Cutting (θ < 90°)(1) Straight line - Straight lineME33018R1000800050001(2) Straight line - ArcME33018R1000800050002(3) ExceptionOutside cutting at an acute angle of 1° or less is considered to be “inside” as s...

  • Page 73

    5228-E P-61SECTION 6 OFFSET FUNCTIONS2-2-4. Start-up with Imaginary Approach DirectionIf the block which starts up the cutter radius compensation includes any I__, J__, or K__ belongingto the offset plane (I__, J__ in the case of G17 plane), the axes move to the target point specified inthis b...

  • Page 74

    5228-E P-62SECTION 6 OFFSET FUNCTIONS2-3.Tool Movement in Cutter Radius Compensation Mode[Supplement]This section describes operations from the operation that begins after entering in the tool offsetmode until just before canceling the cutter radius compensation mode.Example: Consecutive 4 bloc...

  • Page 75

    5228-E P-63SECTION 6 OFFSET FUNCTIONS2-3-1. Inside Cutting (θ ≥ 180°)(1) Straight line - Straight lineME33018R1000800080001(2) Straight line - ArcME33018R1000800080002(3) Arc - Straight lineME33018R1000800080003

  • Page 76

    5228-E P-64SECTION 6 OFFSET FUNCTIONS(4) Arc - arcME33018R1000800080004(5) ExceptionThere is an exception in processing where inside cutting at 1 degree or less for the straight line- straight line configuration is replaced by outside cutting (this is explained later) because theordinary method...

  • Page 77

    5228-E P-65SECTION 6 OFFSET FUNCTIONS2-3-2. Obtusely Angled Corner - Outside Cutting (90° ≤ θ ≤ 180°)(1) Straight line - Straight lineME33018R1000800090001(2) Straight line - ArcME33018R1000800090002(3) Arc - Straight lineME33018R1000800090003(4) Arc - arcME33018R1000800090004

  • Page 78

    5228-E P-66SECTION 6 OFFSET FUNCTIONS2-3-3. Acutely Angled Corner - Outside Cutting (θ < 90°)(1) Straight line - Straight lineME33018R1000800100001(2) Straight line - ArcME33018R1000800100002(3) Arc - Straight lineME33018R1000800100003

  • Page 79

    5228-E P-67SECTION 6 OFFSET FUNCTIONS(4) Arc - arcME33018R10008001000042-3-4. Inside Cutting, with Failure to Find Cross PointAs shown in the illustration below, there may be situations in which a cross point exists with a smallcompensation amount (D1), but not with a large compensation amount ...

  • Page 80

    5228-E P-68SECTION 6 OFFSET FUNCTIONS2-4-1. Inside Cutting (θ ≥ 180°)(1) Straight line - Straight lineME33018R1000800130001(2) Arc - Straight lineME33018R10008001300022-4-2. Obtusely Angled Corner - Outside Cutting (90° ≤ θ ≤ 180°)(1) Straight line - Straight lineME33018R100080014000...

  • Page 81

    5228-E P-69SECTION 6 OFFSET FUNCTIONS2-4-3. Acutely Angled Corner - Outside Cutting (θ < 90°)(1) Straight line - Straight lineME33018R1000800150001(2) Arc - Straight lineME33018R1000800150002(3) ExceptionOutside cutting at an acute angle of 1 degree or less is considered to be “inside”...

  • Page 82

    5228-E P-70SECTION 6 OFFSET FUNCTIONS2-4-4. Independent G40 CommandG40 given independently will position the axes at a point shifted in the vertical direction by anamount equivalent to the compensation amount (D) from the position specified in the precedingblock.Straight lineME33018R10008001600...

  • Page 83

    5228-E P-71SECTION 6 OFFSET FUNCTIONSIf no cross point exists, positioning is executed to the point obtained by a vertical shift by thecompensation amount from the target point specified in the block immediately preceding the G40block.ME33018R10008001700022-5.Changing Compensation Direction in ...

  • Page 84

    5228-E P-72SECTION 6 OFFSET FUNCTIONS2-5-1. With Cross Point(1) Straight line - Straight lineME33018R1000800190001(2) Straight line - ArcME33018R1000800190002(3) Arc - Straight lineME33018R1000800190003(4) Arc - ArcME33018R1000800190004

  • Page 85

    5228-E P-73SECTION 6 OFFSET FUNCTIONS2-5-2. Without Cross Point(1) Straight line - Straight lineME33018R1000800200001(2) Straight line - ArcME33018R10008002000022-5-3. Circular Arc Forming an Overlapping CircleIf an overlapping circle (exceeding a full circle) is generated as the result of offs...

  • Page 86

    5228-E P-74SECTION 6 OFFSET FUNCTIONS2-6.Cutter Radius Compensation Type A2-6-1. OverviewPrograms are often created using hypothetical cutter radius first and then used by setting the cutterradius compensation for the difference between the hypothetical and actual cutter radiuses. In theOSP sys...

  • Page 87

    5228-E P-75SECTION 6 OFFSET FUNCTIONS2-6-3. Tool Movement at the Beginning of Cutter Radius CompensationInside cutting θ ≥ 180°Tool moves to the position of the vector vertical to the next command's origin irrespective of cutterradius compensation types.(1) Straight line - Straight lineME33...

  • Page 88

    5228-E P-76SECTION 6 OFFSET FUNCTIONSObtusely Angled Corner - Outside Cutting (90° ≤ θ < 180°)In Type B, as is conventionally done, the tool detours by calculating an extension point as shownbelow.(1) Straight line - Straight lineME33018R1000800240003(2) Straight line - ArcME33018R10008...

  • Page 89

    5228-E P-77SECTION 6 OFFSET FUNCTIONSAcutely Angled Corner - Outside Cutting (θ < 90°)In Type B, as is conventionally done, the tool detours by calculating an extension point as shownbelow.(1) Straight line - Straight lineME33018R1000800240007(2) Straight line - ArcME33018R1000800240008In ...

  • Page 90

    5228-E P-78SECTION 6 OFFSET FUNCTIONS2-6-4. Tool Movement at the End of Cutter Radius CompensationInside cutting θ ≥ 180°Tool moves to the position of the vector vertical to the previous command's end irrespective of cutterradius compensation types.(1) Straight line - Straight lineME33018R1...

  • Page 91

    5228-E P-79SECTION 6 OFFSET FUNCTIONSObtusely Angled Corner - Outside Cutting (90° ≤ θ < 180°)In Type B, as is conventionally done, the tool detours by calculating an extension point as shownbelow.(1) Straight line - Straight lineME33018R1000800250003(2) Straight line - ArcME33018R10008...

  • Page 92

    5228-E P-80SECTION 6 OFFSET FUNCTIONSAcutely Angled Corner - Outside Cutting (θ < 90°)In Type B, as is conventionally done, the tool detours by calculating an extension point as shownbelow.(1) Straight line - Straight lineME33018R1000800250007(2) Straight line - ArcME33018R1000800250008In ...

  • Page 93

    5228-E P-81SECTION 6 OFFSET FUNCTIONS2-7.Notes on Cutter Radius Compensation2-7-1. Specifying the Cutter Radius Compensation Amount• The compensation amount is specified as a D command. A D command is usually specifiedwith G41 or G42 in the same block. If no D command is included in a G41 o...

  • Page 94

    5228-E P-82SECTION 6 OFFSET FUNCTIONS2-7-5. Under-cuttingUnder-cutting may occur when cutting a step with a height smaller than the cutter radius.ME33018R10008003000012-7-6. Cautions on Corner Cutting• When cutting an outside corner, a polygonal tool path is generated. The axis move mode and...

  • Page 95

    5228-E P-83SECTION 6 OFFSET FUNCTIONS• If the tool path inserted to cut a corner is very small (∆Vx ≤ ∆V and ∆Vy ≤ ∆V in the illustration),the second point defining this movement is disregarded.ME33018R1000800310002In this manner, the additional minute axis movement may be reduced...

  • Page 96

    5228-E P-84SECTION 6 OFFSET FUNCTIONS2-7-7. Interference[Supplement]How the interference check is executed is explained below using several examples.(1) Interference not foundIn this example, no interference is found in the first check (N4 → N5 and P4 → P5). Therefore,no checks are made on ...

  • Page 97

    5228-E P-85SECTION 6 OFFSET FUNCTIONS(2) Interference check resulting in a path changeIn this example, the following directions of movement are checked and disregarded becauseinterference is discovered: N4 - N5, P4 - P5, P3 - P6 and P2 - P7. However, since interferenceis not found in the check...

  • Page 98

    5228-E P-86SECTION 6 OFFSET FUNCTIONS(5) Minute arc and quasi-full circleA minute arc is defined as an arc in which the horizontal and vertical distances from start to endpoint is smaller than the value set at ERROR DATA RESULTING FROM CUTTER R COMP.CAL. of NC optional parameter (cutter R compe...

  • Page 99

    5228-E P-87SECTION 6 OFFSET FUNCTIONSFor these two types of arcs, special interference checks are provided. “Problem” conditionsdetected in minute arcs and quasi-full circles by an interference check are not consideredinterference, but are regarded as operational errors. In the case of a ...

  • Page 100

    5228-E P-88SECTION 6 OFFSET FUNCTIONS2-7-8. Manual Data Input• If the cutter radius compensation mode is set while in the MDI mode, or if the MDI mode is setin the cutter radius compensation mode, execution of a block of commands including an axismovement command is not allowed immediately af...

  • Page 101

    5228-E P-89SECTION 6 OFFSET FUNCTIONS2-7-9. Zero Cutter Radius Compensation Amount(1) During start-upThe cutter radius compensation mode is established when G41 or G42 is executed in thecancel mode, and the cutter radius compensation mode start-up operation is executed with acutter radius compe...

  • Page 102

    5228-E P-90SECTION 6 OFFSET FUNCTIONS3.Cutter Radius Compensation Mode Override Function3-1.Automatic Override at Corners[Function]In the cutter radius compensation mode, depth of cut may increase while cutting the inside of acorner, resulting in an increased tool load. To reduce the load appl...

  • Page 103

    5228-E P-91SECTION 6 OFFSET FUNCTIONSME33018R1000800350001• Requirements for turning ON the override functionThe override function will be turned ON if both of the two blocks that form a corner satisfy thefollowing requirements.• The block is specified in the cutter radius compensation mode...

  • Page 104

    5228-E P-92SECTION 6 OFFSET FUNCTIONS3-2.Circular Arc Inside Cutting Override[Function]In the cutter radius compensation mode, feedrate is normally controlled so that the feedrate on thetool path (the path along which the tool center moves) will be the specified feedrate. When cuttingthe insid...

  • Page 105

    5228-E P-93SECTION 6 OFFSET FUNCTIONS4.Tool Radius Compensation G39 CommandIn the tool radius compensation, corner circular interpolation whose radius is compensation amountis possible by issuing G39 command during the offset mode. G39 command can be generatedautomatically in the NC by switchin...

  • Page 106

    5228-E P-94SECTION 6 OFFSET FUNCTIONS4-2.Corner Circular InterpolationCorner circular interpolation whose radius is compensation amount is possible by issuing G39command. G39 is a one-shot G code.• FormatME33018R1000800390001• G39 without I, J, K commandWhen G39 command is issued, the corne...

  • Page 107

    5228-E P-95SECTION 6 OFFSET FUNCTIONSME33018R10008003900034-2-1. Restrictions• A command for movement is impossible in G39 block. If issued, "Alarm B 2621 Corner circularinterpolation command 3" occures.• When changing the compensation amount, it will become valid at the end of th...

  • Page 108

    5228-E P-96SECTION 6 OFFSET FUNCTIONS4-3.Corner Circular Interpolation Command Automatic InsertionG39 (corner circular interpolation) command can be generated automatically in the NC during offsetmode of tool radius compensation. The last vector of the arc automatically inserted is vertical to ...

  • Page 109

    5228-E P-97SECTION 6 OFFSET FUNCTIONS4-3-2. Others• When changing the compensation amount, it will become valid at the end of the block afterdrawing circular arc by G39.ME33018R1000800430001• Speed of corner circular arcThe speed of corner circular interpolation generated automatically is s...

  • Page 110

    5228-E P-98SECTION 6 OFFSET FUNCTIONS5.Three-dimensional Tool Offset (G43, G44) (Optional)The three-dimensional tool offset function executes tool offset in three dimensions based on the axismove commands and the I, J, and K values which specify the tool offset direction.5-1.Three-dimensional T...

  • Page 111

    5228-E P-99SECTION 6 OFFSET FUNCTIONS• Even with a tool offset amount of zero (D00), the three-dimensional offset mode will be started,but no offset movement will take place.ME33018R10008004500035-2.Three-dimensional Tool Offset VectorIn the three-dimensional tool offset mode, a three-dimensi...

  • Page 112

    5228-E P-100SECTION 6 OFFSET FUNCTIONSDefault: 0Setting range: 0 to ±99999.999 mm or 0 to ±3937.0078 inchesParameter: NC optional parameter (long word) No. 7[Details]In a block where none of I, J, and K is specified, the same vector as the one generated in theprevious block is generated.• I...

  • Page 113

    5228-E P-101SECTION 6 OFFSET FUNCTIONS5-3.Canceling Three-dimensional Tool OffsetG43 is used to cancel the three-dimensional tool offset mode.a.Canceling in a block with axis commandsME33018R1000800470001b.Canceling in a block without other commandsME33018R1000800470002c.Setting tool offset num...

  • Page 114

    5228-E P-102SECTION 6 OFFSET FUNCTIONS5-5.Relationship with Other G Functions• G codes that must not be specified in the three-dimensional tool offset mode.G15, G16, G40, G41, G42, G92G codes for area machiningG codes for coordinate system parallel shift/rotationG codes calling a fixed cycle...

  • Page 115

    5228-E P-103SECTION 7 FIXED CYCLESSECTION 7 FIXED CYCLESA fixed cycle refers to the function which can define a series of operations executed along the tool in-feed axis(hereafter referred to as the cycle axis), like drilling, boring and tapping, by one block of commands. Whenrepeating the sam...

  • Page 116

    5228-E P-104SECTION 7 FIXED CYCLES1.Table of Fixed Cycle FunctionsG CodeFunctionSpindle Rotation at Positioning PointHole Machining OperationOperation at Hole Bottom LevelRetraction OperationSpindle Rotation at Return LevelG71Specifies the return level—————G73High speed deep hole dril...

  • Page 117

    5228-E P-105SECTION 7 FIXED CYCLES2.Fixed Cycle OperationsAll fixed cycle functions are composed of the following six operations:ME33018R1000900030001Operation 1 is referred to as the positioning operation and operations 2 to 6 are referred to as thecycle axis operation.Fixed cycles including a...

  • Page 118

    5228-E P-106SECTION 7 FIXED CYCLES2-1.Determining the Positioning Plane and the Cycle Axis(1) Determining the positioning plane and the cycle axis by commandsThe positioning plane may be determined by selecting a plane using G17, G18, and G19. Thecycle axis is then chosen as the axis which is ...

  • Page 119

    5228-E P-107SECTION 7 FIXED CYCLES2-2.Controlling the Return LevelThere are three different tool return levels when one fixed cycle operation ends; Return to the upperlimit level (M52), Return to the specified point level (M53), Return to the point R level (M54).ME33018R1000900050001• Selecti...

  • Page 120

    5228-E P-108SECTION 7 FIXED CYCLES• When the fixed cycle mode is canceled by G80, the interpolation mode (G00, G01, G02, G03,or G60) valid before entering the fixed cycle mode is restored and M05 is generated.Example:ME33018R10009000600012-4.Cycle Operation ConditionsIn the fixed cycle mode, ...

  • Page 121

    5228-E P-109SECTION 7 FIXED CYCLES3.General Rules for Programming Fixed CyclesThis section describes the general rules on specifying hole machining data which is specified inblocks containing a fixed cycle call G code, G73 to G76 and G81 to G89. The following explanationassumes that the positi...

  • Page 122

    5228-E P-110SECTION 7 FIXED CYCLESc.G74, G84 modeSpecifies the dwell period at the point R level.The relationship between the length of time and the value to be specified is the sameas that for G04.If a negative value is set in the above mode a. or b., the NC ignores the negative sign.When chan...

  • Page 123

    5228-E P-111SECTION 7 FIXED CYCLES3-2.Command Items Necessary for Fixed Cycle Function CommandsThe table below shows the command items that must be specified for the individual fixed cycles.ME33018R1000900100001*: The positioning plane and the cycle axis are assumed to be the X-Y plane and Z-ax...

  • Page 124

    5228-E P-112SECTION 7 FIXED CYCLES• The shift amount must be specified for the fixed cycle called by G76 and G87, otherwise analarm occurs.3-3.Absolute Programming Mode and Incremental Programming Mode(1) Specifying point R and point ZHow the points R and Z are defined differs depending on th...

  • Page 125

    5228-E P-113SECTION 7 FIXED CYCLES3-4.Positional Relationship among Return Point Level, Point R Level and Point Z LevelThe positional relationship among the three levels along the cycle axis direction must comply withone of the two cases shown below. (The only exception is G87 back boring, whe...

  • Page 126

    5228-E P-114SECTION 7 FIXED CYCLES(2) I, J, and K CommandsI, J, and K commands are used when the cycle axis is not fixed by parameter.The shift amount and direction of the tool should be specified using (I, J), (K, I), or (J, K)depending on the selected positioning plane. The shift direction i...

  • Page 127

    5228-E P-115SECTION 7 FIXED CYCLES3-7.Relationships between Fixed Cycle Functions and Other Func-tions(1) Axis Movement Call Mode (MODIN, MODOUT)If the fixed cycle mode and the axis movement call mode overlap, the MODIN command will callaxis movements after the cycle axis operation has been com...

  • Page 128

    5228-E P-116SECTION 7 FIXED CYCLES3-8.Notes for Programming a Fixed Cycle• In a fixed cycle (G74, G84, G86) mode in which spindle rotation is controlled, if a holemachining cycle is consecutively executed for holes arranged in short intervals with shortdistance between the specified point lev...

  • Page 129

    5228-E P-117SECTION 7 FIXED CYCLES• If the slide hold function is turned on during a tapping cycle (G74, G84), cycle motiondoes not stop until the completion of operation 5, even though the SLIDE HOLD lamplights immediately after pressing the SLIDE HOLD button. If it is pressed duringoperati...

  • Page 130

    5228-E P-118SECTION 7 FIXED CYCLES5.High Speed Deep Hole Drilling Cycle (G73)[Programming format]G73 X__Y__Z__R__P__Q__F__ME33018R1000900180001Machining Sequence(1) Positioning along the X- and Y-axis at a rapid feedrate(2) Positioning to the point R level at a rapid feedrate(3) Drilling by the...

  • Page 131

    5228-E P-119SECTION 7 FIXED CYCLES6.Reverse Tapping Cycle (G74)[Programming format]G74 X__Y__Z__R__P__Q__F__ME33018R1000900190001Machining Sequence(1) Positioning along the X- and Y-axis at a rapid feedrate(2) Positioning to the point R level at a rapid feedrate(3) Tapping to the point Z level ...

  • Page 132

    5228-E P-120SECTION 7 FIXED CYCLES7.Fine Boring (G76)[Programming format]G76 X__Y__Z__R__Q__(I__J__) P__F__ME33018R1000900200001Machining Sequence(1) Positioning along the X- and Y-axis at a rapid feedrate(2) Positioning to the point R level at a rapid feedrate(3) Boring to the point Z level at...

  • Page 133

    5228-E P-121SECTION 7 FIXED CYCLES[Details]• Retraction amount at the point Z levelThe amount the Z-axis retracts upward from the point Z level is set at SHIFT DIRECTION ANDAXIS IN G76, G87 of the NC optional parameter (FIXED CYCLE).• Shift amounta.Q is used to specify the shift amount if t...

  • Page 134

    5228-E P-122SECTION 7 FIXED CYCLES9.Drilling Cycle (G81, G82)[Programming format]ME33018R1000900220001G81 and G82 are used in the same manner.Machining Sequence(1) Positioning along the X- and Y-axis at a rapid feedrate(2) Positioning to the point R level at a rapid feedrate(3) Drilling to the ...

  • Page 135

    5228-E P-123SECTION 7 FIXED CYCLES10.Deep Hole Drilling Cycle (G83)[Programming format]G83 X__Y__Z__R__Q__(I__J__) P__F__• Programming using QME33018R1000900230001• Programming using I and JME33018R1000900230002If a Q value is programmed in the same block as I and J values, the Q value will...

  • Page 136

    5228-E P-124SECTION 7 FIXED CYCLES[Setting values]Retraction amount d1:Set at RETRACTION POSITIONING FROM LEVEL ‘R’ TO WORK IN G83 CYCLE (DEEP HOLE) ofthe NC optional parameter (fixed cycle).Retraction amount d2:Set at RETRACTION IN G73 CYCLE (HIGH-SPEED DEEP HOLE) OR G83 CYCLE (DEEP HOLE)W...

  • Page 137

    5228-E P-125SECTION 7 FIXED CYCLES[Details]According to the value of I, J, cutting is performed as follows. If either I or J is specified, the otherone is considered as "0" is specified.• No Q designationME33018R1000900230003• Q designated with I and J in the same blockOperation s...

  • Page 138

    5228-E P-126SECTION 7 FIXED CYCLES[Details]• Dwell is not executed if a P and/or Q value is not specified.Units of P and Q values are the same as used for the G04 mode dwell command.• A feed override is disregarded during reverse tapping operation.• If the SLIDE HOLD button is pressed dur...

  • Page 139

    5228-E P-127SECTION 7 FIXED CYCLES13.Boring Cycle (G86)[Programming format]G86 X__Y__Z__R__P__F__ME33018R1000900260001Machining Sequence(1) Positioning along the X- and Y-axis at a rapid feedrate(2) Positioning to the point R level at a rapid feedrate(3) Boring to the point Z level at the speci...

  • Page 140

    5228-E P-128SECTION 7 FIXED CYCLES14.Back Boring Cycle (G87)Note that this cycle differs somewhat from other fixed cycles.[Programming format]G87 X__Y__Z__R__Q__ (I__J__) P__F__ME33018R1000900270001[Setting values]Retraction amount at the point Z level: Set at retraction for G76/G87 (fine borin...

  • Page 141

    5228-E P-129SECTION 8 COORDINATE CALCULATION FUNCTION (PATTERN FUNCTION)SECTION 8 COORDINATE CALCULATION FUNCTION (PATTERN FUNCTION)The coordinate calculation function calculates the coordinate values of points on a line, grid, or circle usingone command.Combining this function with the fixed c...

  • Page 142

    5228-E P-130SECTION 8 COORDINATE CALCULATION FUNCTION (PATTERN FUNCTION)2.General Rules of Coordinate Calculation2-1.Programming Format for Coordinate CalculationThe programming format is as indicated below.(Mnemonic code)Hp__ Vp__ I__ J__ K__ P__ Q__ R__Hp, Vp: Represent the coordinate values ...

  • Page 143

    5228-E P-131SECTION 8 COORDINATE CALCULATION FUNCTION (PATTERN FUNCTION)(2) Parameters used for coordinate calculationParameters used by a coordinate calculation function must be designated in the same block asthe mnemonic code that specified the specific coordinate calculation function. These...

  • Page 144

    5228-E P-132SECTION 8 COORDINATE CALCULATION FUNCTION (PATTERN FUNCTION)2-2.Plane on Which Coordinate Calculation is Performed, and Motion AxesCoordinate values are calculated on the plane which is selected when a pattern command isdesignated, and positioning at each calculated point is execute...

  • Page 145

    5228-E P-133SECTION 8 COORDINATE CALCULATION FUNCTION (PATTERN FUNCTION)3.Omit (OMIT)[Function]This function is normally used in combination with other coordinate calculation functions and deletesoutput of the coordinate value which is calculated using the coordinate calculation function.[Progr...

  • Page 146

    5228-E P-134SECTION 8 COORDINATE CALCULATION FUNCTION (PATTERN FUNCTION)4.Restart (RSTRT)[Function]This function restarts machining from a required point among the points for which coordinate valuesare calculated using the coordinate calculation function.Generally, the restart data (RSTRT comma...

  • Page 147

    5228-E P-135SECTION 8 COORDINATE CALCULATION FUNCTION (PATTERN FUNCTION)5.Line at Angle (LAA)[Function]This function calculates the coordinate values of points arranged at irregular intervals (d1, d2, andso forth) on a line which forms an angle θ to the horizontal axis. Here, the actual posit...

  • Page 148

    5228-E P-136SECTION 8 COORDINATE CALCULATION FUNCTION (PATTERN FUNCTION)6.Grid (GRDX, GRDY)[Function]This function calculates the coordinate values of points arranged in the grid pattern, composed ofthe points (nx) placed at an interval of (dx) in parallel with the horizontal axis and of the po...

  • Page 149

    5228-E P-137SECTION 8 COORDINATE CALCULATION FUNCTION (PATTERN FUNCTION)[Details]• The maximum number of points on a grid ((nx + 1) x (ny + 1) - 1) is 65535.• The number of the last point is (nx + 1) x (ny + 1) - 1.• The coordinate values of the reference point are not output.7.Double Gri...

  • Page 150

    5228-E P-138SECTION 8 COORDINATE CALCULATION FUNCTION (PATTERN FUNCTION)[Details]• When “dx2” is equal to “dx1/2”, designation of Q can be omitted. Similarly, when “dy2” is equalto “dy1/2”, designation of R can be omitted. Note that the mark is the same as dx1, dy1.• The ma...

  • Page 151

    5228-E P-139SECTION 8 COORDINATE CALCULATION FUNCTION (PATTERN FUNCTION)Example 2:ME33018R10010001100038.Square (SQRX, SQRY)[Function]This function calculates the coordinate values of points arranged in the square pattern, composed ofthe points (nx) placed at an interval of (dx) parallel to the...

  • Page 152

    5228-E P-140SECTION 8 COORDINATE CALCULATION FUNCTION (PATTERN FUNCTION)[Programming format]ME33018R1001000120001[Details]• The maximum number of points on a square (2(nx + ny) - 1) is 65535.• The coordinate values of the reference point are not output.SQRXHp__Vp__ I ± dx J ± dy Knx P...

  • Page 153

    5228-E P-141SECTION 8 COORDINATE CALCULATION FUNCTION (PATTERN FUNCTION)9.Bolt Hole Circle (BHC)[Function]This function calculates the coordinate values of the points arranged on the circumference of a circlethat has its center at the actual position or a point defined by the specified coordina...

  • Page 154

    5228-E P-142SECTION 8 COORDINATE CALCULATION FUNCTION (PATTERN FUNCTION)10.Arc (ARC)[Function]This function calculates the coordinate values of the points arranged on the circumference of a circlethat has its center at the actual position or a point defined by the specified coordinate values. ...

  • Page 155

    5228-E P-143SECTION 9 AREA MACHINING FUNCTIONSSECTION 9 AREA MACHINING FUNCTIONSArea machining functions are used to machine the top, periphery or inside surface of a rectangular area witha single command. The area to be machined must be formed by four straight lines which intersect at rightan...

  • Page 156

    5228-E P-144SECTION 9 AREA MACHINING FUNCTIONS2-2.Tool Movements(1) Face milling (FMILR)ME33018R1001100040001(2) Face milling (FMILF)ME33018R1001100040002(3) Round milling (RMILO)ME33018R1001100040003Point R levelReference pointPoint R levelReference pointPoint R levelReference point

  • Page 157

    5228-E P-145SECTION 9 AREA MACHINING FUNCTIONS(4) Round milling (RMILI)ME33018R1001100040004(5) Pocket milling (PMIL)ME33018R1001100040005(6) Pocket milling (PMILR)ME33018R1001100040006Reference pointReference pointReference point

  • Page 158

    5228-E P-146SECTION 9 AREA MACHINING FUNCTIONS3.Area Machining Plane and Cycle Axis• The plane in which operations 1 and 4, defined in “Basic Operations”, are executed isdetermined by the designation of G17, G18, or G19 for plane selection. Hereafter, the selectedplane is called the area...

  • Page 159

    5228-E P-147SECTION 9 AREA MACHINING FUNCTIONS4.General RulesThe following explanations assume that the area machining plane is the XY plane and that theinfeed axis is the Z-axis. The explanation is similar for the other planes.4-1.Programming Format (General Command Format)(Mnemonic code) Xp_...

  • Page 160

    5228-E P-148SECTION 9 AREA MACHINING FUNCTIONS4-2.Area Machining Functions and Commands to be UsedME33018R1001100080001[Explanation of the above table]• Addresses designated with a single circle (A) may be omitted. If omitted, the coordinate valueof the current position is used.• Addresses...

  • Page 161

    5228-E P-149SECTION 9 AREA MACHINING FUNCTIONS4-3.Data Entry in Incremental/Absolute ModeFour addresses for an area machining function must be specified depending on the selecteddimensioning mode, incremental or absolute. They are: the coordinate values of the reference point(Xp, Yp), the fini...

  • Page 162

    5228-E P-150SECTION 9 AREA MACHINING FUNCTIONS4-5.Definition of Machining Area (I, J)The machining area is defined by I and J values, and the signs of I and J values. How the areas aredefined according to the signs specified preceding the I and J values is shown below.The areas are defined ind...

  • Page 163

    5228-E P-151SECTION 9 AREA MACHINING FUNCTIONS5.Face Milling Functions (FMILR, FMILF)[Function]The face milling function uses the specified coordinate values as a reference point and cyclicallymachines the workpiece surface at a certain depth of cut (Q) over the range specified by the X- andY-a...

  • Page 164

    5228-E P-152SECTION 9 AREA MACHINING FUNCTIONSTool-ON type (Tool remains on workpiece) (FMILR)ME33018R1001100130002Tool-OFF type (Tool moves off of workpiece) (FMILF)ME33018R1001100130003FMILF X0 Y0 Z I0 J0 K P Q R D FIn the FMILF mode, although the Z-axis moves in the same way as in the FMILR ...

  • Page 165

    5228-E P-153SECTION 9 AREA MACHINING FUNCTIONSPositioning of a cutter(1) First positioningME33018R1001100130004• In the narrower direction of a workpiece, the cutter is positioned so that the specified widthof cutting* is engaged on the workpiece.Width of cutting = (Shorter side + 5 mm / n)...

  • Page 166

    5228-E P-154SECTION 9 AREA MACHINING FUNCTIONS(3) Cutting path along the shorter sides of a workpiece (from the reference point)ME33018R1001100130007(4) Final cutting pathME33018R1001100130008For both the FMILR and the FMILF, the cutter is positioned so that the periphery of the cutterprojects ...

  • Page 167

    5228-E P-155SECTION 9 AREA MACHINING FUNCTIONS(6) Tool path for the workpiece with width smaller than cutting widthME33018R1001100130010• Positioning point• Along the shorter side of the workpiece, positioning is performed so that the cutterperiphery projects 5 mm (0.20 in.) from the workpi...

  • Page 168

    5228-E P-156SECTION 9 AREA MACHINING FUNCTIONS6.Pocket Milling (PMIL, PMILR)The pocket milling function is classified into two types: zigzag (PMIL) and spiral (PMILR). Thesetwo types of functions are described below.6-1.Zigzag Pattern Pocket Milling Function (PMIL)[Function]The zigzag pattern...

  • Page 169

    5228-E P-157SECTION 9 AREA MACHINING FUNCTIONSMachining SequenceBefore starting the PMIL operation, the function checks if the programmed operation is possiblebased on the programmed pocket shape and the specified cutter diameter. An alarm occurs if thefollowing is not satisfied.Shorter side -...

  • Page 170

    5228-E P-158SECTION 9 AREA MACHINING FUNCTIONS(2) The infeed axis Z is positioned to the point R level at a rapid feedrate.ME33018R1001100150003(3) Starting at the point R level, the Z-axis is fed by the specified depth of cut, Q, at the feedratespecified by FB.ME33018R1001100150004(4) The insi...

  • Page 171

    5228-E P-159SECTION 9 AREA MACHINING FUNCTIONS(6) Step (5) above is repeated until the final finish allowance remains on the finish surface. Finally,the cutter machines a rectangular pocket 1 mm (0.04 in.) wider than the machined pocket. Inthe final cycle, the feedrate specified by F is used....

  • Page 172

    5228-E P-160SECTION 9 AREA MACHINING FUNCTIONS6-2.Spiral Pattern Pocket Milling Function (PMILR)[Function]The spiral pattern pocket milling function uses the specified coordinate values as a reference pointand cyclically machines the rectangular pocket range specified by the X- and Y-axis lengt...

  • Page 173

    5228-E P-161SECTION 9 AREA MACHINING FUNCTIONSMachining SequenceBefore starting the PMILR operation, the function checks if the programmed operation is possiblebased on the programmed pocket shape and the specified cutter diameter. An alarm occurs if thefollowing is not satisfied.Shorter side ...

  • Page 174

    5228-E P-162SECTION 9 AREA MACHINING FUNCTIONSTaking the start point specified in the program as the reference point, the system determines arectangle from the lengths specified by l and J. In this rectangle, the system defines anotherrectangle by leaving finish allowance K on four sides, then...

  • Page 175

    5228-E P-163SECTION 9 AREA MACHINING FUNCTIONS(5) The cutter returns to the initial positioning point (X, Y, Z) at a rapid feedrate. It is then positionedfrom the point R level to a point 1 mm (0.04 in.) above the surface level machined in theprevious machining cycle at a feedrate of FA. Then...

  • Page 176

    5228-E P-164SECTION 9 AREA MACHINING FUNCTIONS7.Round Milling Functions (RMILO, RMILI)[Function]The round milling function uses the specified coordinate values as a reference point and cyclicallymachines the rectangle specified by the X- and Y-axis lengths (I and J), which has stock Q to beremo...

  • Page 177

    5228-E P-165SECTION 9 AREA MACHINING FUNCTIONS• Before starting the RMILO operation, the function checks the relationship between the finishallowance and the stock to be removed. An alarm occurs if the following is not satisfied.Q ≥ KME33018R1001100170002RMILO X0 Y0 Z-50 I500 J300 K0.2 P70...

  • Page 178

    5228-E P-166SECTION 9 AREA MACHINING FUNCTIONSRMILI - Internal Cutting• The first positioning point (A) is the point where the cutter periphery is 5 mm (0.20 in.) awayfrom the edge of the blank workpiece.• Before starting the RMILI operation, the function checks the relationship between the...

  • Page 179

    5228-E P-167SECTION 9 AREA MACHINING FUNCTIONSAlong the shorter side direction, the cutter engages the workpiece by the cutting width(cutter diameter × P).Along the longer side direction, the cutter periphery is located 5 mm (0.20 in.) away fromthe workpiece edge.• Internal cutting (RMILI):M...

  • Page 180

    5228-E P-168SECTION 9 AREA MACHINING FUNCTIONS• External cutting (RMILO):Since the cutter is positioned, in the first positioning, at a point where it is engaged with theworkpiece by the specified cutting width, the round milling cycle can be started from thefirst positioning point.• Intern...

  • Page 181

    5228-E P-169SECTION 9 AREA MACHINING FUNCTIONS• Machining with a single cutME33018R1001100170010• Without Q (stock) commandME33018R1001100170011(6) Retraction from workpieceIn the RMILI (internal cutting) mode, the cutter retracts inward from the workpiece as it is incontact with the workpi...

  • Page 182

    5228-E P-170SECTION 10 SUBPROGRAM FUNCTIONSSECTION 10 SUBPROGRAM FUNCTIONS1.OverviewProgramming sometimes uses similar patterns repeatedly or uses patterns already programmed forother operations. The subprogram function allows such patterns which are used repeatedly to bestored as subprograms ...

  • Page 183

    5228-E P-171SECTION 10 SUBPROGRAM FUNCTIONSb.Maker subprogramThe specified subprogram is searched for in all the files in the system memory: with anextension of MSB.• If a subprogram file contains more than one subprogram of the same name, then only the onefound first is valid.Example 1:ME330...

  • Page 184

    5228-E P-172SECTION 10 SUBPROGRAM FUNCTIONSExample 3:ME33018R1001200020004[Other]• The allowable maximum number of subprograms that can be used or called for one program is126.• In the block which contains a subprogram call command, only a program name, “/” (block skip)and/or a sequence...

  • Page 185

    5228-E P-173SECTION 10 SUBPROGRAM FUNCTIONS• Comments can not be used between a CALL statement and program name.Example) CALL (**) OTEST2.Simple Call (CALL)[Function]The simple call function executes the specified subprogram when the CALL command is specified.[Programming format]ME33018R10012...

  • Page 186

    5228-E P-174SECTION 10 SUBPROGRAM FUNCTIONSExample 2:ME33018R1001200030003• Main program:ME33018R1001200030004• Subprogram (Positioning):ME33018R1001200030005• Subprogram (Cutting):ME33018R1001200030006End pointO1N1 G90 G00 X20 Y20N2 CALL OSUB Q3 LX=10 LI=25 LP=4& ...

  • Page 187

    5228-E P-175SECTION 10 SUBPROGRAM FUNCTIONSProgrammers must record the following:• Program name: OSUB• Number of repetitions: No. of elements in the Y-axis direction• Variables to be passedLX: Cutting distance of a pattern (X-axis direction)LY: Cutting distance of a pattern (Y-axis direc...

  • Page 188

    5228-E P-176SECTION 10 SUBPROGRAM FUNCTIONS[Details]Nesting subprogram call in the call after axis move modeIt is possible to call subprograms in as many as eight levels without canceling a call after axis movecommand. This is called “nesting”: how the call after axis move command is execu...

  • Page 189

    5228-E P-177SECTION 10 SUBPROGRAM FUNCTIONSb.Subprogram O3 is called by other MODIN command.ME33018R1001200040006In item (2) above, the relationship between O3 and O2 is the case explained in item (1) andthat between O1 and O2 is the case explained in item (2).Example: ME33018R1001200040007Exec...

  • Page 190

    5228-E P-178SECTION 10 SUBPROGRAM FUNCTIONS• When setting variables to be specified following a MODIN command, if a local variable is usedat the right side of the setting, the following point must be taken into consideration when thesubprogram is called by axis move commands specified in a pr...

  • Page 191

    5228-E P-179SECTION 10 SUBPROGRAM FUNCTIONSb.When a drilling cycle is executed using the fixed cycle function, drilling is carried out atpoints N2 and N3.ME33018R1001200040010c.It is possible to skip drilling at the N2 and N3 blocks by specifying NCYL.In the example above, subprograms OCYC and ...

  • Page 192

    5228-E P-180SECTION 10 SUBPROGRAM FUNCTIONS4.G and M Code Macro FunctionsG Code Macro Function[Function]A subprogram may be called using a G code instead of the CALL or MODIN/MODOUT command.The feature to call a subprogram using a G code is called the G code macro function.With a G code macro, ...

  • Page 193

    5228-E P-181SECTION 10 SUBPROGRAM FUNCTIONSCommon Items• An alarm will occur if the parameter setting does not include the program name thatcorresponds to the specified G or M code macro, or if that name is not defined by the system.An alarm will also occur if that program is not included in ...

  • Page 194

    5228-E P-182SECTION 10 SUBPROGRAM FUNCTIONSThe command “G111X30Y20I10J30K5” gives the result shown below:ME33018R1001200050005

  • Page 195

    5228-E P-183SECTION 10 SUBPROGRAM FUNCTIONS5.Program Call Function Using Variables5-1.OutlineThis function consists of the following two functions.Items which are not described here are the same as those described in the conventional sub-program function. Therefore, read this manual in conjunct...

  • Page 196

    5228-E P-184SECTION 10 SUBPROGRAM FUNCTIONS5-2-2. Program Command FormatCALL O= [Expression] Q___ [Argument setting] (PN = ____)MODIN O= [Expression] Q___ [Argument setting] (PN = ____)The designation must be made in this order, excluding "PN"."PN" may be designated in or be...

  • Page 197

    5228-E P-185SECTION 10 SUBPROGRAM FUNCTIONS• If "PN" has already been used for another purpose, set "1" at the NC optional parameter (bit)No. 69, bit 4.This "PN"-related function can be made invalid.• This function only becomes effective with operation method A...

  • Page 198

    5228-E P-186SECTION 11 USER TASKSECTION 11 USER TASK1.User Task 1User task 1 was developed to allow users to use the high speed processing function by themselves.User task 1 consists of the following three functions:• Branch function• Variable function• Math function1-1.Branch Function•...

  • Page 199

    5228-E P-187SECTION 11 USER TASK• If operation method A is selected by the parameter setting, branching can be done quickly bydesignating sequence labels as the destination of a branch command. However, this quickbranching is possible only up to 30 sequence labels from the beginning of a pro...

  • Page 200

    5228-E P-188SECTION 11 USER TASK[Programming format]ME33018R1001300020005There are six types of qualifications available as indicated below.OperatorMeaningExample of IF StatementContentsRuleLTLess Than, <IF [VC1 LT 5] N100Jump to N100 when VC1 is less than 5.Provide a space on either sid...

  • Page 201

    5228-E P-189SECTION 11 USER TASK1-2.Variable Function[Function]The variable function allows the use of variables in the data section of an expression such as X =VC1 instead of directly specifying a numerical value such as X100. This gives programs moreflexibility and versatility, since assigni...

  • Page 202

    5228-E P-190SECTION 11 USER TASKa.When a variable is assigned to an addressAssigning an undefined variable is equivalent to omitting the address. The use of anundefined variable in the right member causes an alarm.ME33018R1001300030002b.When an undefined variable is used in the operational exp...

  • Page 203

    5228-E P-191SECTION 11 USER TASK• Array VariablesAn array is a set of data having the same elements. The array name should be immediatelyfollowed by a subscript enclosed by [ ] to represent a specific element.Variables that permit the use of an array• An array may not be used for local var...

  • Page 204

    5228-E P-192SECTION 11 USER TASK1-2-1. Common VariablesVariables which are used in common for schedule programs, main programs and subprograms arereferred to as common variables, and they may be referenced or updated in any of these programs.ME33018R1001300040001[Programming format]ME33018R1001...

  • Page 205

    5228-E P-193SECTION 11 USER TASK• Backup range can be specified with the following parameters.<NC optional parameter (word).>All the common variables are to be backed up if "First = Last = 0" is specified. (Default)No common variables are to be backed up if the first number sp...

  • Page 206

    5228-E P-194SECTION 11 USER TASK1-2-2. Local VariablesLocal variables may be used in a main program or a subprogram. They are valid only for aparticular program and may be set, referenced, or updated only in this particular program.Therefore, it is not permissible to reference or update a loca...

  • Page 207

    5228-E P-195SECTION 11 USER TASK• Addresses specified to assign arguments of G code macro instructions are set using a variablename with “P” at its start and are regarded as a local variable for type 2.Example:Specifying “G111 X100 Y200 P5;”Set local variables as PX = 100, PY = 200, a...

  • Page 208

    5228-E P-196SECTION 11 USER TASK1-4.System VariablesVariables which are determined by the system are referred to as system variables, and they may bereferenced or updated in schedule programs, main programs and subprograms. A system variableis referenced or updated after the execution of the s...

  • Page 209

    5228-E P-197SECTION 11 USER TASK1-4-1. Read/Write System Variables(1) Zero OffsetVZOF* [expression]*: Axis name X - Z, U - W, A - CExpression: Work coordinate system numberAllowable range: 1 to number of work coordinate system setsThe zero offset values for the work coordinate system indicated ...

  • Page 210

    5228-E P-198SECTION 11 USER TASK• mm unit systemVC1 = 20For details, refer to “General Rule for Conversion between Inches and Millimeters”. (Note: “inch system” refers to the English measurement system.)(3) Cutter Radius Compensation ValuesVTOFD[expression]Expression: Cutter radius c...

  • Page 211

    5228-E P-199SECTION 11 USER TASK• mm unit systemProgrammable travel end limit (+) = 500 mm• Example 2:Reading programmable travel end limit (+) of X-axisVC1 = VPPLX (Programmable travel end limit (+) is 500 mm)• µm unit systemVC1 = 500000• mm unit systemVC1 = 500For details, refer to ...

  • Page 212

    5228-E P-200SECTION 11 USER TASK[Supplement](6) Printer ControlVPCNTSetting range: Binary, 8 bits (1 byte); 0 – 255This is used with a print statement.To change a page, for example, set the “change page” code and output it to the printer alongwith the print statement.If this system variab...

  • Page 213

    5228-E P-201SECTION 11 USER TASK(8) Automation Specification Judgment Result 2VOK2Setting range: Binary, 8 bits (1 byte); 0 – 255This is used with a print statement.It is convenient to use this system variable to print the total result of gauging.The relationship between the setting value for...

  • Page 214

    5228-E P-202SECTION 11 USER TASKThe relationship between the setting value for VINTG and the print output is indicated below. Inany case, the output consists of twelve characters.ME33018R1001300080004When PRINT XX is executed, the displayed data will be [0.000] in mm unit system.(11) Printer C...

  • Page 215

    5228-E P-203SECTION 11 USER TASK(12) Tool Length/Breakage Switching FlagVFSTSetting range: Binary, 8 bits (1 byte); 0 – 255The basic operation mode for automatic tool length offset and automatic tool breakagedetection can be designated.The relationship between each bit and the operation modes...

  • Page 216

    5228-E P-204SECTION 11 USER TASK• Example 2:Reading the synchronized tapping torque monitor parameter No. 3VC1 = VTMNO(15) Spindle Overload Monitor Parameter No.VSLNOSetting range: 1 – 5For the spindle overload monitor function, the spindle overload monitor parameter number canbe read/writt...

  • Page 217

    5228-E P-205SECTION 11 USER TASK• mm unit systemThe maximum feedrate of 20 µm is set for parameter No. 3.• Example 2:Reading the maximum feedrate set for F-1 digit parameter feed No. 3.Assume that the maximum feedrate set for F-1 digit parameter feed number 3 is 20 mm.VC1 = VPF1F[3]• µm...

  • Page 218

    5228-E P-206SECTION 11 USER TASK(19) Tool Management DataVTLD* [expression]*: 1 to 8Expression: Tool offset numberAllowable range: 1 to number of tool data setsReading/writing of the tool management data with the expression can be indicated. Theobjective to be read or written is designated by ...

  • Page 219

    5228-E P-207SECTION 11 USER TASK• When tool life is judged on the basis of accumulated cutting time (tool life mode: 1 to3): 0 ≤ h1 ≤ 32767 (unit: min.)• When tool life is judged on the basis of count data (tool life mode: 4 to 6):0 ≤ h1 ≤ 32767• When tool life management is not e...

  • Page 220

    5228-E P-208SECTION 11 USER TASK• Example:VMPC1 = #80H.....Sampling of data under no-load condition for load data No. 1VMPC1 = #81H.....Sampling of data under no-load condition for load data No. 2VMPC1 = #82H.....Sampling of data under no-load condition for load data No. 3 :VMPC1 = #8FH.....

  • Page 221

    5228-E P-209SECTION 11 USER TASK• Bit 61: Air cut reduction for load data No. 2 ON0: Air cut reduction for load data No. 2 OFF• Bit 51: Air cut reduction for load data No. 3 ON0: Air cut reduction for load data No. 3 OFF• Bit 41: Air cut reduction for load data No. 4 ON0: Air cut reductio...

  • Page 222

    5228-E P-210SECTION 11 USER TASK• Bit 11: Adaptive control for load data No. 7 ON0: Adaptive control for load data No. 7 OFF• Bit 01: Adaptive control for load data No. 8 ON0: Adaptive control for load data No. 8 OFF1-4-2. Read/Write System Variables Requiring Special Attention in WritingCA...

  • Page 223

    5228-E P-211SECTION 11 USER TASK(2) Negative Travel End Limit ValueVNSL**: Axis nameX to Z, U to W, A to CThe travel limit in the negative direction for the axis indicated by the axis name can be read/written. This sets the data for user parameter “N PROG LIMIT MC” that is accessible in th...

  • Page 224

    5228-E P-212SECTION 11 USER TASK• Example:Reading X-axis in-position widthAssume that the in-position width of the X-axis is 0.003 mm.VC1 = VINPX• µm unit systemVC1 = 3• mm unit systemVC1 = 0.003(5) In-position Width for Home PositionVHPI**: Axis nameX to Z, U to W, A to CThe in-position...

  • Page 225

    5228-E P-213SECTION 11 USER TASK(7) Home Position LocationVHPP* [expression]*: Axis nameX to Z, U to W, A to CExpression: Home position numberAllowable value: 1 – 32The home position location can be read and written by indicating the home position numberwith the expression and also by indicat...

  • Page 226

    5228-E P-214SECTION 11 USER TASK(9) Active Tool NumberVTLCNThe tool number of the tool presently set in the spindle can be read and written.• Example:Reading the active tool numberVC1 = VTLCN[Supplement](10) Next Tool NumberVTLNNThe tool number of the next tool can be read and written.• Exa...

  • Page 227

    5228-E P-215SECTION 11 USER TASK• mm unit systemVC1 = 3750 VC2 = 1250 VC3 = 2 VC4 = 450(2) Actual Position DataVAPA**: Axis nameX to Z, U to W, A to CThe actual value (APA) of the axis designated by the axis name can be read. For this operation,the unit system is as set at NC optional paramet...

  • Page 228

    5228-E P-216SECTION 11 USER TASK(4) Active Tool NumberVATOLThe tool management number (tool kind + tool number) of the tool presently set in the spindlecan be read. The data is two-byte data; the upper six bits show the tool kind and the lower tenbits represent the tool number.Tool kind (Some ...

  • Page 229

    5228-E P-217SECTION 11 USER TASK(5) Next Tool NumberVNTOLThe tool management number (tool kind + tool number) of the tool to be used next can be read.The data is two-byte data; the upper six bits show the tool kind and the lower ten bits representthe tool number.Tool kind (Some tool kinds canno...

  • Page 230

    5228-E P-218SECTION 11 USER TASK(6) Number of Coordinate Systems and Tool Data Sets (NC specification code No. 2)VSPCOThe 1-byte specification code data which indicates the number of coordinate systems and tooldata sets can be read. The relationship between the bit data and the specifications ...

  • Page 231

    5228-E P-219SECTION 11 USER TASK(10) Program Unit SystemVINCHThe unit system (set for NC optional parameter (INPUT UNIT SYSTEM), or NC optionalparameter (bit) No. 3, bit 0 to bit 7 and No. 4, bit 0) used for the program which is beingexecuted can be read.• Example:If the setting unit for &quo...

  • Page 232

    5228-E P-220SECTION 11 USER TASK• NC optional parameter (bit) No. 3, bit 0 to bit 7 and No. 4, bit 0(11) Sequence Restart FlagVRSTTThe flag that is turned on when the restart search command (RS) is executed in the automaticmode and turned off after the designated sequence is located can be re...

  • Page 233

    5228-E P-221SECTION 11 USER TASK(12) Operating Time CounterVDTIM[α, β]ME33018R1001300100006The time counted by counters and their set values are read.• Example:The sequence jumps to N010 when the cutting time reaches 10 hours.ME33018R1001300100007(13) Work CounterVWRKC[α, β]ME33018R100130...

  • Page 234

    5228-E P-222SECTION 11 USER TASK(14) G CodeVGCOD[expression]Expression: Group number of the G codeAllowable range: 1 – 96The mode of the present G code groups can be read.The value to be read is the numerical value of a G code. However, “254” is read for G00.• Example 1:In the G00 mode...

  • Page 235

    5228-E P-223SECTION 11 USER TASK• Example 1:Reading the feedrate in units of mm/min to variable VFCOD/10 when the programming unitsystem “mm” and G94 mode is active.VC1 =VFCOD/10• Example 2:Reading the feedrate in units of inch/rev to variable VC1 when the programming unitsystem “inch...

  • Page 236

    5228-E P-224SECTION 11 USER TASK(20) Internal Clock• Example:To turn on the 60 minute timerThe example below assumes that the duration after turning on the power supply is muchsmaller than two minutes.VC1 = VRMNTNA1 VC2 = VRMNT - VC1IF [VC2 GE 60] NA2GOTO NA1(21) Manual Intervention Shift Amo...

  • Page 237

    5228-E P-225SECTION 11 USER TASK(23) Spindle Overload Monitor ParameterVSLDT[a,b]a: Spindle overload monitor parameter No.Setting range: 1 to 5b: Spindle overload monitor parameter typeSetting range: 1 to 31...Maximum load value (%) for spindle overload monitor parameter2...Continuously overloa...

  • Page 238

    5228-E P-226SECTION 11 USER TASK(26) PPC Parameters (for the PPC specification)When multiple number of workpieces is set on a pallet with PPC set ON, this system variable isused to indicate the positions where the workpieces are set. The parameter must be set fromthe PPC panel beforehand.VPPCP...

  • Page 239

    5228-E P-227SECTION 11 USER TASKExample programME33018R1001300100013(27) Automatic Crossrail Positioning M CodeVECWMThe M code number corresponding to the present crossrail position where the crossrail waspositioned using an automatic crossrail positioning M code can be read.5 crossrail positio...

  • Page 240

    5228-E P-228SECTION 11 USER TASK(29) The value of Year/Month/Day/Hour/Minute/SecondVTIME [Formula]When VTIME [1] is executed, the value of "Year" is read and the values of "Month/Day/Hour/Minute/Second" are stored. When VTIME [formula] (formula = 2 to 6) is executed, the sto...

  • Page 241

    5228-E P-229SECTION 11 USER TASK(31) Tool Number (Pot Designation)VPTNO [expression]Expression: Pot numberSetting range: 1 to max number of potsTool number stored in the pot specified in the expression can be read.• Example 1: Reading tool number in the pot number 3 (assuming tool number in t...

  • Page 242

    5228-E P-230SECTION 11 USER TASK(36) Number of daysVQDATVQDAT is to read days on the assumption that January 1, 1980 is one (1).(37) Number of secondsVRTIMVRTIM is to read seconds on the assumption that "0:00:00 am" is zero (0).(38)Current position of machine coordinate systemVMCA*Val...

  • Page 243

    5228-E P-231SECTION 11 USER TASK1-4-4. General Rule for Automatic Conversion between Inches and MillimetersAutomatic conversion follows the settings at the NC optional parameter (INPUT UNIT SYSTEM).(1) NC Optional Parameter (INPUT UNIT SYSTEM), part program unit system “LENGTH UNITSYSTEM”...

  • Page 244

    5228-E P-232SECTION 11 USER TASK(4) How numerical values are interpreted according to the setting for NC optional parameter(INPUT UNIT SYSTEM) is summarized in the table below.Variables (local variables, common variables, system variables) in the right member of theexpression are handled in the...

  • Page 245

    5228-E P-233SECTION 11 USER TASK1-4-5. Supplements• Specifying a read only system variable at the left side will cause an alarm.• Setting of EMPTY for system variables will cause value “0” to be set.• System variables can be read and written even in the machine lock mode.• Do not us...

  • Page 246

    5228-E P-234SECTION 11 USER TASK2.User Task 2User task 2 allows the use of system variables, and logical and function operations, in addition to thefunctions available with user task 1. Selection of the I/O variable function is also possible.2-1.I/O VariablesThe I/O variables can reference or ...

  • Page 247

    5228-E P-235SECTION 11 USER TASK2-1-1. Input Variables (VDIN)ME33018R1001300150001*: Data at 1000 to 1004 is cleared to zero (0) when the power supply is turned on; it is not cleared by the NC reset operation.Reading the 1 byte data; n = 9 to 16 corresponds to bits 0 through 7Reading the 1 byte...

  • Page 248

    5228-E P-236SECTION 11 USER TASK2-1-2. Output Variable (VDOUT)ME33018R1001300160001Outputs the 1 byte data; n = 9 to 16 corresponds to bits 0 through 7Outputs the 1 byte data; n = 1 to 8 corresponds to bits 0 through 7Outputs the 1 word data; n = 1 to 16 corresponds to bits 0 through 15Used t...

  • Page 249

    5228-E P-237SECTION 11 USER TASK2-1-3. Alarm MessageUser designated sub messages for user defined alarms can be displayed on the screen.Sub message designations can be set at system variable VUACM.VUACM[Format]VUACM[n]n: Subscript expression in the range from 1 to 16.VUACM[1] = ‘character-str...

  • Page 250

    5228-E P-238SECTION 11 USER TASK2-1-4. Supplements• VDIN variables can be designed only in the right part of an operation command. If they arespecified in the left part, an alarm occurs.• VDOUT variables can be designated only in the left part of an operation command. If they arespecified ...

  • Page 251

    5228-E P-239SECTION 11 USER TASK2-1-5. Application Example of Input/Output VariablesAssume that the information concerning the kind of data is output from the CNC to an externaldevice and the corresponding one byte data is input to the CNC from the external device.This input and output process ...

  • Page 252

    5228-E P-240SECTION 11 USER TASK2-2.Math FunctionsVarious types of operations using variables are possible. These functions can be programmed inthe same way as general calculations.[Programming format]Address character, Variables = ExpressionThe math function of user task 2 supports logical an...

  • Page 253

    5228-E P-241SECTION 11 USER TASK2-2-2. FunctionsOperationMath NameOperation ExampleVC1RemarkSINSineVC1 = SIN[30]0.5COSCosineVC1 = COS[VC2]0.5TANTangentVC1 = TAN[45]1ASINArcsineVC1 = ASIN[0.5]30ACOSArccosineVC1 = ACOS[0.5]60ATANArc tangent (1)VC1 = ATAN[1]45Value range: –90° to 90° (*4)ATAN...

  • Page 254

    5228-E P-242SECTION 11 USER TASK(*5)The value of ATAN2[b,a] represents the angle of the point defined by the coordinate values (a,b). Its range is from –180° to 180°.Example:VC2 = ATAN2[1, [-START[3]]](*6)If the value of VDIN[17] is “01011001” (BCD), the result of operation is VC1 = 59...

  • Page 255

    5228-E P-243SECTION 12 SCHEDULE PROGRAMSSECTION 12 SCHEDULE PROGRAMS 1.OverviewSchedule programs permit different types of workpieces to be machined continuously without anyoperator intervention by using a pallet changer, or other automated loading and unloading units.• A schedule program spe...

  • Page 256

    5228-E P-244SECTION 12 SCHEDULE PROGRAMS2.PSELECT Block[Function]A PSELECT block selects and executes main programs for a workpiece to be machined.• This function searches a specified main program file for a specified main program to beselected as a machining program. This function also sear...

  • Page 257

    5228-E P-245SECTION 12 SCHEDULE PROGRAMS• An alarm will occur if M02 or M30, indicating the end of the program, is not specified in thespecified main program.(3) fs: Subprogram file nameME33018R1001400020003• Entry of “fs” may be omitted when:a.No subprogram call command is specified i...

  • Page 258

    5228-E P-246SECTION 12 SCHEDULE PROGRAMS(5) OP: Option specificationsa.Specification of S optionME33018R1001400020005This is the command not to search for subprograms.An S option significantly reduces the time needed to execute the PSELECT command.This option is effective only for main program...

  • Page 259

    5228-E P-247SECTION 12 SCHEDULE PROGRAMS• Program requirements in each program running method*1. Time varies with the selected program size.3.Branch BlockThe branching function of the schedule program, which is identical to SECTION 11, 1-1. “BranchFunctions”, falls into GOTO and IF block...

  • Page 260

    5228-E P-248SECTION 12 SCHEDULE PROGRAMS(2) IF Block[Function]The IF block conditionally changes program sequences. If the condition is ‘true’, the sequencebranches to the destination of a jump. If the condition is ‘false’, it proceeds to the nextsequence.[Programming format]Commands ...

  • Page 261

    5228-E P-249SECTION 13 OTHER FUNCTIONSSECTION 13 OTHER FUNCTIONS 1.Table Index SpecificationFor the additional axis index specification, 5 index specification and 1 index specification areavailable.The following explanation assumes that the B-axis is installed as the fourth axis.1-1.5-Degree In...

  • Page 262

    5228-E P-250SECTION 13 OTHER FUNCTIONS• In the G01 mode, a B command should be programmed in a block not containing other axismovement commands. In this case, the B command is executed at a rapid feedrate (G00mode). In the G00 mode, it can be programmed with other axis movement commands in ...

  • Page 263

    5228-E P-251SECTION 13 OTHER FUNCTIONS• In the G01 mode, a B command should be programmed in a block not containing other axismovement commands. In this case, the B command is executed at a rapid feedrate (G00mode). In the G00 mode, it can be programmed with other axis movement commands in ...

  • Page 264

    5228-E P-252SECTION 13 OTHER FUNCTIONS1-3.0.001 Degree Commands (Optional)With the 0.001° command specification, selection is possible whether the axis is treated as a rotaryaxis which allows the designation for operation within the range up to 360 degrees, or treatedsimilarly to a linear axis...

  • Page 265

    5228-E P-253SECTION 13 OTHER FUNCTIONS• Example 2:If “G91 G01 B360 Z-50 F100” is specified.ME33018R10015000500031-3-2. Multi-turn Command[Programming Format]ME33018R10015000600010.001° (0.0001°) unit: –9999.999 ≤ B ≤ 9999.999 (–9999.9999 ≤ B ≤ 9999.9999)The unit system confo...

  • Page 266

    5228-E P-254SECTION 13 OTHER FUNCTIONS2.Angular Commands[Function]An angular command allows a target point to be defined by a coordinate value of one axis in thespecified plane and the angle a line makes with the horizontal axis.[Programming Format]ME33018R1001500070001The unit of an angle comm...

  • Page 267

    5228-E P-255SECTION 13 OTHER FUNCTIONS3.Manual Shift Amount Cancel Command[Function]The manual shift amount cancel command cancels the total distance moved in manual interventionduring automatic operation by a command in the program without using switches on the operationpanel.The manual shift ...

  • Page 268

    5228-E P-256SECTION 13 OTHER FUNCTIONS• OperationsME33018R1001500080004Positioning is performed to the position where the manual shift amount is added to thecalculated value. That is, the axes move from the previous calculated positionaccording to the specified command with the manual shift ...

  • Page 269

    5228-E P-257SECTION 13 OTHER FUNCTIONS[Details]• An alarm occurs if the manual shift amount cancel command (MICAN) is executed in the cutterradius compensation mode or the 3D offset mode.• Before executing sequence re-start, the manual shift amount must be canceled. Note thatmanual shift a...

  • Page 270

    5228-E P-258SECTION 13 OTHER FUNCTIONS4.Print Format Function[Function]When executing print statement, the print format can be specified by this function.Printing by print commands with format specification (PRINTF and SPRINTF), print according to theformat specified the system variable VFMT [...

  • Page 271

    5228-E P-259SECTION 14 FILE MANAGEMENTSECTION 14 FILE MANAGEMENT1.Files(1) Programs are executed after they have been stored in the NC memory.(2) The memory has a storage space of 2 GB and can store a number of programs at the sametime.(3) To facilitate the handling of stored programs, each is ...

  • Page 272

    5228-E P-260SECTION 14 FILE MANAGEMENT2.Various FilesFiles may be equivalent to document files or account books, and each file for the same workpiecetype is assigned a name (file name), which consists of the main file name and an extension.A file name should consist of up to 16 alphanumeric cha...

  • Page 273

    5228-E P-261SECTION 15 APPENDIXSECTION 15 APPENDIX1.G Code Table (Including Optional Functions)G CodeG GroupFunctionsG00 ***1PositioningG01 ***Linear interpolationG02Circular interpolation - Helical cutting (CW)G03Circular interpolation - Helical Cutting (CCW)G04 **2DwellG09 **18Exact stopG10 ...

  • Page 274

    5228-E P-262SECTION 15 APPENDIXG6114Exact stop mode ONG6219Programmable mirror image modeG64 *14Cutting mode ONG6824Slope coordinate OFFG69Slope coordinate ONG7121Designation of return level for M53G7223Designation of pattern reference point (start position) for the coordinate calculation funct...

  • Page 275

    5228-E P-263SECTION 15 APPENDIXG11332G code macro CALL typeG114G115G116G117G118G119G120G130 *92High-speed contouring control OFFG131High-speed contouring control ONG133 *89Constant peripheral speed control OFFG134Constant peripheral speed control ONG137 *61Contour machining mode OFFG138Contour ...

  • Page 276

    5228-E P-264SECTION 15 APPENDIXG178 *1Fixed thread cutting cycle in the 1st axis direction on a planeG179Fixed thread cutting cycle in the 2nd axis direction on a planeG180 *Attachment rotation offset cancelG18165Attachment rotation offset; FrontwardG182Attachment rotation offset; LeftwardG183A...

  • Page 277

    5228-E P-265SECTION 15 APPENDIX2.Table of Mnemonic Codes (Including Optional Functions)Mnemonic CodeGroupFunctionsEIN73Program interruption function; ValidDINProgram interruption function; InvalidRTIProgram interruption function; End codeREAD63READ/WRITE GET/PUT function; Reading from an extern...

  • Page 278

    5228-E P-266SECTION 15 APPENDIXCALL27Subprogram, Simple callRTSSubprogram, Simple call End codeMODINSubprogram, Call after positioning mode “ON”MODOUTSubprogram, Call after positioning mode “OFF”GOTO28Branch command, Unconditional jumpIFBranch command, Conditional jumpDEF62Animation fun...

  • Page 279

    5228-E P-267SECTION 15 APPENDIXPRMDO33I-MAP-B function; Solid shape machining (convex pyramid)PRMDII-MAP-B function; Solid shape machining (concave pyramid)CONEOI-MAP-B function; Solid shape machining (convex cone)CAMCVI-MAP-B function; Solid shape machining (cam curves interpolation)PGENDI-MAP...

  • Page 280

    5228-E P-268SECTION 15 APPENDIX3.M Code TableM Code GroupFunctionExecution Timing(In Reference to Axis Movement Command)Modal/One shotRemarksM001Program stopAfterOne shot Spindle and coolant stop(Can be selected by parameter setting)01Optional stopAfterOne shot0218End of programAfterOne shot NC...

  • Page 281

    5228-E P-269SECTION 15 APPENDIX4011High/middle-high/middle-low/low rangeAt the same timeModalSpindle gears are automatically determined by spindle speed command.41High/middle-high/middle-low rangeAt the same timeModal42High/middle-high rangeAt the same timeModal43High rangeAt the same timeModal...

  • Page 282

    5228-E P-270SECTION 15 APPENDIX71Manual attachment tool changeAfterOne shot72Horizontal spindle tool change preparationAfterModal7315Swivel head, front positionAfterOne shot74Swivel head, left positionAfterOne shot75Swivel head, rear positionAfterOne shot76Swivel head, right positionAfterOne sh...

  • Page 283

    5228-E P-271SECTION 15 APPENDIX11565th-axis rotary table CWAt the same timeModal1165th-axis rotary table CCWAt the same timeModal1182Spindle orientation (reverse)AfterModal119Spindle orientation (forward/reverse)AfterModal120Work shower ONAt the same timeModal121Attachment air blow ON/Tool nose...

  • Page 284

    5228-E P-272SECTION 15 APPENDIX15420Sensor air blow OFFAfterModal155Sensor air blow ONAt the same timeModal157AAC (2 st.), No next toolAfterOne shot158AAC (2 st.), Next tool clearAfterOne shot159AAC (2 st.), Preparation for the next toolAfterOne shot160PPC pallet loadingAfterOne shot161PPC pall...

  • Page 285

    5228-E P-273SECTION 15 APPENDIX20126M code macroAt the same timeOne shot20220320420520620720820921021121221321421521621721821922023042Tool length offset direction; Used as it isAt the same timeModal231Tool length offset direction; Used after reversing the directionAt the same timeModal232413D t...

  • Page 286

    5228-E P-274SECTION 15 APPENDIX281Work clamp (fixture 2)At the same timeModal282Work unclamp (fixture 2)At the same timeModal287Work clamp (fixture 3)At the same timeModal288Work unclamp (fixture 3)At the same timeModal289Pallet identificationAt the same timeOne shot29245Chamfering OFFAt the sa...

  • Page 287

    5228-E P-275SECTION 15 APPENDIX340Work seating monitor ONAt the same timeModal341Work seating monitor OFFAt the same timeModal342Work seating confirmation air ONAt the same timeModal343Work seating confirmation air OFF At the same timeModal34659B-axis rotation interlock validAt the same timeMod...

  • Page 288

    5228-E P-276SECTION 15 APPENDIXThe commanded state of the following M codes may be displayed in the M code field (BLOCK).Note: In the M code column, modal state of up to 26 M codes is displayed.• M03, 04, 05, 19• M08• M06, 77• M12• M07• M26, 27• M10, 11• M30• M15, 16• M50, 5...

  • Page 289

    5228-E P-277SECTION 15 APPENDIX4.Table of Reserved Local Variable WordsABSDRAWHANOEXRSAGDROUNDHBNOINCRSQCOANDDSHCNOTRSQRIARCEINHORNNPRSQROATANEMPTYHSOMITRSTRTATAN2EORIFORRTBCDEQKAPCIRRTIBHC FAKBPMILRTMCRBOUNSFCLCONIPNRTMDICALLFILCONOPREGSAVECAMCVFIXLEPRINTSCCHFCFMILFLMVPRMDISINCHFRFMILRLMWPRMDO...

  • Page 290

    5228-E P-278SECTION 15 APPENDIX5.Table of System VariablesSystem VariableFormatSetting RangeSubscriptRead / WriteInch / mm ConversionZero offset dataVZOF* [expression]0 to ±99999.999Work coordinate system numberR / WAutomatically convertedTool length offset dataVTOFH [expression]0 to ±999.999...

  • Page 291

    5228-E P-279SECTION 15 APPENDIXSpecification code for subprograms (NC specification code No. 24)VSPSBRead onlyNot changedMachine lockVMLOKRead onlyNot changedPrinter controlVPCNTBinary 8 bits(1 byte)R / WNot changedAutomating specification judgment result 1VOK1Binary 8 bits(1 byte)R / WNot chan...

  • Page 292

    5228-E P-280SECTION 15 APPENDIXExecuting G codeVGCOD [expression]1 to 96Read onlyNot changedExecuting M codeVMCOD [expression]1 to 64Read onlyNot changedExecuting S codeVSCODRead onlyNot changedExecuting F codeVFCODRead onlyNot changedExecuting D codeVDCODRead onlyNot changedExecuting H codeVHC...

  • Page 293

    5228-E P-281SECTION 15 APPENDIXTool management dataTool life flagVTLD4 [expression]0 to 255Tool management numberR / WNot changedTool management dataSecond tool offset numberVTLD5 [expression]0 to 320Tool management numberR / WNot changedTool management dataThird tool offset numberVTLD6 [expres...

  • Page 294

    5228-E P-282SECTION 15 APPENDIX*: Represents an axis name such as X, Y and ZAttachment spindle; Synchronized tapping torque monitor parameter No.VTMNB1 to 5R / WNot changedAttachment spindle; Synchronized tapping torque monitor parameterVTMDB[expression]1 to 1271 to 5Read onlyNot changedBC-axis...

  • Page 295

    LIST OF PUBLICATIONSPublication No.DateEdition5228-EApril 20051st5228-E-R1April 20062nd5228-E-R2February 20073rd5228-E-R3April 20074th5228-E-R4August 20075th5228-E-R5January 20086th5228-E-R6June 20087th5228-E-R7August 20088th5228-E-R8April 20099th5228-E-R9October 201010thThis manual may be at var...

x