background image

3   M Code

3 - 12

NJ/NY-series G code Instructions Reference Manual (O031)

Spindle Axis Rotation Function 

(S function)

This instruction specifies a rotational speed of the spindle axis.

 

Specifies the rotational speed of the spindle axis with a number (0 or positive number) next to S code.

The unit of rotational speed is r/min (revolutions per minute).

The spindle axis is not operated simply by specifying the rotational speed.

To run the spindle axis, use the Auxiliary Function Output (M03/M04).

When the spindle axis is rotated by auxiliary function output (M03/M04) and if the S-code value is 
changed, it is reflected on the spindle axis speed immediately.

Modal/Non-modal

Modal

Instruction format

S{data}

Relevant M codes

M03, M04

Summary of Contents for NJ501-5300

Page 1: ...Machine Automation Controller Industrial PC Platform NJ NY series G code Instructions Reference Manual NJ501 5300 NY532 5400 O031 E1 02...

Page 2: ...f the information contained in this publication Sysmac and SYSMAC are trademarks or registered trademarks of OMRON Corporation in Japan and other countries for OMRON factory automation products Micros...

Page 3: ...series listed in Related Manuals on page 21 for functions common to NY532 Series including NY532 1 This manual is intended for the following personnel who must also have knowledge of electrical sys te...

Page 4: ...s Manual NJ NX series Instructions Reference Manual NJ NX series CPU Unit Motion Control User s Manual NJ NX series Motion Control Instructions Reference Manual NJ NX series CPU Unit Built in EtherCA...

Page 5: ...to the products with the manuals that are indicated with triangles Purpose of use Manual Basic information NJ series CPU Unit Hardware User s Manual NJ NX series CPU Unit Software User s Manual NJ NX...

Page 6: ...series Panel PCs Introduction to NY series Box PCs Setting devices and hardware Using motion control Using EtherCAT Using EtherNet IP Making setup 1 1 Refer to the NY series Industrial Panel PC Indus...

Page 7: ...Join the Units so that the connectors fit exactly 2 The yellow sliders at the top and bottom of each Unit lock the Units together Move the sliders toward the back of the Units as shown below until the...

Page 8: ...ot to do to ensure proper operation and performance Additional Information Additional information to read as required This information is provided to increase understanding and ease of operation Versi...

Page 9: ...7 Sections in this Manual NJ NY series G code Instructions Reference Manual O031 1 2 3 4 A 1 2 3 4 A Basic Information on NC Programming G Code M Code PROGRAM CODES Appendices Sections in this Manual...

Page 10: ...onsiderations 13 Disclaimers 13 Safety Precautions 14 Precautions for Safe Use 15 Precaution for Correct Use 16 Regulations and Standards 17 Versions 18 Checking Versions 18 Related Manuals 21 Termino...

Page 11: ...g 2 55 G68 G69 Coordinate System Rotation 2 57 Utilities 2 59 G74 Left handed Tapping Cycle 2 60 G80 Fixed Cycle Cancel 2 62 G84 Tapping Cycle 2 63 G98 Fixed Cycle Return to Initial Level 2 66 G99 Fix...

Page 12: ...o while 4 6 4 3 User Variables 4 7 4 3 1 Local Variables L 4 7 4 3 2 Coordinate System Global Variables Q 4 7 4 3 3 Global Variables P 4 7 4 3 4 Variable Indirection 4 7 Appendices A 1 Program Parsing...

Page 13: ...11 CONTENTS NJ NY series G code Instructions Reference Manual O031...

Page 14: ...e price of the non complying Product provided that in no event shall Omron be responsible for warranty repair indemnity or any other claims or expenses regarding the Products unless Omron s analysis c...

Page 15: ...hall not be responsible for the user s programming of a programmable Product or any consequence thereof Data presented in Omron Company websites catalogs and other materials is provided as a guide for...

Page 16: ...cautions Refer to the following manuals for safety precautions NJ series CPU Unit Hardware User s Manual Cat No W500 NY series Industrial Panel PC Hardware User s Manual Cat No W557 NJ NY series NC In...

Page 17: ...or Safe Use Refer to the following manuals for precautions for safe use NJ series CPU Unit Hardware User s Manual Cat No W500 NY series Industrial Panel PC Hardware User s Manual Cat No W557 NJ NY ser...

Page 18: ...Correct Use Refer to the following manuals for precautions for correct use NJ series CPU Unit Hardware User s Manual Cat No W500 NY series Industrial Panel PC Hardware User s Manual Cat No W557 NJ NY...

Page 19: ...ode Instructions Reference Manual O031 Regulations and Standards Refer to the following manuals for regulations and standards NJ series CPU Unit Hardware User s Manual Cat No W500 NY series Industrial...

Page 20: ...the ID information indications or with the Sysmac Studio The unit version is given on the ID information indication on the side of the product Checking the Unit Version of an NJ series CPU Unit The ID...

Page 21: ...The Production Information Dialog Box is displayed Checking the Unit Version of an NY series Controller You can use the Production Information while the Sysmac Studio is online to check the unit vers...

Page 22: ...ght click EtherCAT under Configurations and Setup and select Edit from the menu The EtherCAT Tab Page is displayed 2 Right click the master on the EtherCAT Tab Page and select Display Production Infor...

Page 23: ...NJ301 NJ101 Learning about motion control set tings and program ming concepts The settings and operation of the CPU Unit and programming concepts for motion control are described NJ NX series Motion...

Page 24: ...igning instal lation and maintenance Mainly hardware infor mation is provided An introduction to the entire NY series system is provided along with the following informa tion on the Industrial Box PC...

Page 25: ...manual provides an introduction and pro vides information on the configuration fea tures and setup NY series IPC Machine Con troller Industrial Panel PC Industrial Box PC Built in Eth erNet IP Port Us...

Page 26: ...Terminology 24 NJ NY series G code Instructions Reference Manual O031 Terminology Term Description NJ501 1 Represents NJ501 1300 1400 1500...

Page 27: ...History A manual revision code appears as a suffix to the catalog number on the front and back covers of the manual Revision code Date Revised content 01 October 2017 Original production 02 July 2018...

Page 28: ...Revision History 26 NJ NY series G code Instructions Reference Manual O031...

Page 29: ...O031 This section provides the list of available instructions and the descriptions of parame ters and modal Instructions 1 2 G Codes 1 2 M Codes 1 4 Instruction Parameters 1 5 G Code Descriptions 1 7...

Page 30: ...e machine coordinate sys tem 01 Rapid Position ing G01 G00 Rapid Positioning Performs a point to point operation in the minimum time by following the restrictions of CNC motor set tings G01 Linear Int...

Page 31: ...te System Selection No Work Coordinate System is selected all coordinate axis have zero offset G54 1st Work Coordinate System selection Changes the current coordinate system to a speci fied one define...

Page 32: ...he NC program to enable reset mode Spindle Axis M03 Spindle CW Operates the Spindle axis in the positive direction at the speci fied speed M04 Spindle CCW Operates the Spindle axis in the negative dir...

Page 33: ...s G04 0 F 100 000 G G code Valid G code I X axis arc center command units G02 G03 1 000 000 I 1 000 000 X axis scaling magnification G51 0 00001 I 10 000 10 000 I 0 00001 J Y axis arc center command...

Page 34: ...Target Y axis position com mand units G00 G01 G02 G03 1 000 000 Y 1 000 000 Y axis middle point command units G28 G30 1 000 000 Y 1 000 000 X axis center command units G50 G50 1 G68 1 000 000 Y 1 000...

Page 35: ...parsing The influential range varies depending on the word A word that only has an effect in the block where it is written is called non modal and one that continues to have an effect when omitted in...

Page 36: ...d Enter the command as N 1 1 N is a constant from 1 to 31 Note that the optional block skip can be used for G codes only It cannot be used for program codes Optional Skip Block G17 G91 G01 ta1000 td10...

Page 37: ...ed The former is called non modal G code and the latter modal G code Modal G codes are summarized into some G code groups The group is called a modal group In the same modal group G codes that cannot...

Page 38: ...1 Basic Information on NC Programming 1 10 NJ NY series G code Instructions Reference Manual O031...

Page 39: ...ons Reference Manual O031 This section describes the specifications of the G code Interpolation Functions 2 3 Dwell 2 15 Feed Functions 2 17 Coordinate System 2 27 Reference Point 2 35 Compensation Fu...

Page 40: ...2 G Code 2 2 NJ NY series G code Instructions Reference Manual O031...

Page 41: ...es G code Instructions Reference Manual O031 2 Interpolation Functions Instruction Name Page G00 Rapid Positioning P 2 4 G01 Linear Interpolation P 2 6 G02 G03 Circular Interpolation P 2 8 G31 Skip Fu...

Page 42: ...e specifications for the Absolute Dimension G90 and Incremental Dimension G91 Modal Non modal Modal Modal group 01 Rapid Positioning Instruction format G00 X Y Z A B C Relevant G codes G90 G91 Paramet...

Page 43: ...de Instructions Reference Manual O031 G00 Rapid Positioning 2 Programming Example The following program performs positioning with the absolute dimensions N010 G90 Absolute dimension N011 G00 X100 Y50...

Page 44: ...ime ms td Deceleration Time Specifies the deceleration time ms ts Jerk Time Specifies the jerk time ms X Target X axis Position Specifies the destination position command units on the X axis Y Target...

Page 45: ...emental Dimension G91 G01 uses the following settings for its operation The F command calculates velocity by using X Y and Z axis If the user selects A B or C axis the axis is operated at the rotation...

Page 46: ...cceleration time ms td Deceleration Time Specifies the deceleration time ms ts Jerk Time Specifies the jerk time ms X Target X axis Position Specifies the destination position command units on the X a...

Page 47: ...refer to the programming example of G64 Continuous path Mode on page 2 22 When this command is executed the arc path is calculated on the XY YZ or ZX plane If you select an axis other than those comp...

Page 48: ...40 Y50 R 40 F300 When radius 0 a circle larger than a semicircle is drawn The following shows circular interpolation with Arc radius specification radius 0 N010 G91 Incremental dimension N011 G17 XY P...

Page 49: ...Y10 J30 Third rotation of spiral interpolation N06 M05 N07 M30 End of program Helical interpolation N01 G17 G64 G91 F1000 N02 M03 S300 N03 G02 J50 Z10 First rotation of helical interpolation N04 J50...

Page 50: ...00 N02 M03 S300 N03 G02 Y10 J50 Z10 First rotation of conical interpolation N04 Y10 J40 Z10 Second rotation of conical interpolation N05 Y10 J30 Z10 Third rotation of conical interpolation N06 M05 N07...

Page 51: ...ion G91 The velocity must be specified as the Skip Velocity CNC motor setting For details refer to the NJ NY series NC Integrated Controller User s Manual Cat No O030 The user can read the posi tions...

Page 52: ...ength that was calculated refer to the How to Enable Tool Replacement in the NJ NY series NC Integrated Controller User s Manual Cat No O030 Use of M101 for transferring the captured data to the seque...

Page 53: ...2 15 NJ NY series G code Instructions Reference Manual O031 2 Dwell Instruction Name Page G04 Dwell P 2 16...

Page 54: ...functions controlled by sequence control programs If no parameter is specified Dwell of 0 second the default value will be executed The following program waits for 10 seconds between linear interpolat...

Page 55: ...s Instruction Name Page F Function Feedrate Function F function P 2 18 ta td ts Acceleration Time Deceleration Time Jerk Time P 2 19 G09 Exact Stop P 2 20 G61 Exact Stop Mode P 2 21 G64 Continuous pat...

Page 56: ...gative value cannot be specified The velocity is specified in command units min the feedrate per minute The positioning axis is not operated simply by specifying the feedrate Use a feed command to mov...

Page 57: ...fter the ta code Specify the deceleration time with a numeric value after the td code Specify the jerk time with a numeric value after the ts code The unit of time is in milliseconds For relationship...

Page 58: ...h the next block such as cutting corners with an acute angle This code is only valid for the current block Among movement commands between multiple blocks the following program prevents blending opera...

Page 59: ...e corner and cut ting corners with an acute angle during operation When G61 is commanded deceleration is applied to the end point of the cutting block then an in position check of each block is execut...

Page 60: ...an in position check is executed in the following cases G00 Rapid Positioning G09 Exact Stop Block with no movement command in the next block This does not apply to Multi block Acceleration Decelerat...

Page 61: ...ng Example This shows the path of X Y plane Shows the speed waveforms The parameters shown in the figure are values ta 1000 td 1000 and ts 500 that have been specified in the NC program 0 40 X Y N07 8...

Page 62: ...it operates in the Exact Stop Mode If the multi block acceleration deceleration rate is disabled accelerate to the feedrate in the first block and decelerate in the last block For this reason if the...

Page 63: ...with a series of infinitesimal movements when the multi block acceleration deceleration rate is enabled or disabled Programming Example N01 G17 G64 G91 G01 F100 N02 M03 S300 N03 G500 Enables multi blo...

Page 64: ...G17 G64 G91 G01 F100 N02 M03 S300 N03 G501 Disables multi block acceleration deceleration rate N04 X1 N05 X1 N06 X1 N07 X1 N08 X1 N09 X1 N10 X1 N11 X1 N12 X1 N13 X1 N14 M05 N15 M30 0 Feedrate Time N0...

Page 65: ...ries NC Integrated Controller User s Manual Cat No O030 Instruction Name Page G52 Local Coordinate System Set P 2 28 G53 Dimension Shift Cancel P 2 29 G54 to G59 Select Work Coordinate System P 2 30 G...

Page 66: ...ordinate System Setting Set a Local Coordinate Sys tem G52 X Y Z A B C Release a Local Coordinate System G52 X0 Y0 Z0 A0 B0 C0 Relevant G codes G50 G51 G50 1 G51 1 G68 G69 G54 to G59 Parameters Parame...

Page 67: ...ic Input G20 G21 Tool Offset G43 G44 G49 and Cutter Compensation G40 G41 G42 must be released prior to execution of this command Modal Non modal Non modal Modal group 00 Non modal Instruction format G...

Page 68: ...ling G50 G51 Mirroring G50 1 G51 1 and Coordinate System Rotation G68 G69 For offset settings of work coordinate system refer to the Work Coordinate System Offset Parameters of NJ NY series NC Control...

Page 69: ...ane selection and each G code Modal Non modal Modal Modal group 02 Plane Instruction format X Y Plane G17 Z X Plane G18 Y Z Plane G19 Relevant G codes G02 G03 G41 G42 G68 G69 Parameters Function Preca...

Page 70: ...settings of the CNC coordinate system command values and the unit of current val ues You can select inch or mm for the unit For example for the maximum velocity of a CNC coordi nate system only the i...

Page 71: ...position mode for all axes in the CNC coordinate system and moves the axes to a specified position in the current coordinate system Executing G91 enables Incremental position mode for all axes in the...

Page 72: ...2 G Code 2 34 NJ NY series G code Instructions Reference Manual O031...

Page 73: ...2 35 NJ NY series G code Instructions Reference Manual O031 2 Reference Point Instruction Name Page G28 Return to Reference Point P 2 36 G30 Return to 2nd 3rd and 4th Refer ence Point P 2 38...

Page 74: ...51 1 and Coordinate System Rotation G68 G69 During motion between the middle point and reference point this command also releases Zero Shift G54 to G59 temporarily It maintains the current status of I...

Page 75: ...ation the tool moves to the middle position 10 10 and returns to the reference point 0 0 Programming Example N01 G17 G91 G64 F1000 N02 M03 S500 N03 G00 X10 Y20 N04 G01 X40 N05 Y10 N06 X 40 N07 Y 10 N0...

Page 76: ...Z A B C Return to 2nd Reference Point G30 P2 X Y Z A B C Return to 3rd Reference Point G30 P3 X Y Z A B C Return to 4th Reference Point G30 P4 X Y Z A B C Relevant G codes G90 G91 G50 G51 G50 1 G51 1...

Page 77: ...ns Reference Manual O031 2 Compensation Functions Instruction Name Page G40 G41 G42 Cutter Compensation P 2 40 G43 G44 G49 Tool Offset P 2 51 G50 G51 Scaling P 2 53 G50 1 G51 1 Mirroring P 2 55 G68 G6...

Page 78: ...ctions compensate the path by considering the tool diameter This command does not have any parameters to set Modal Non modal Modal Modal group 07 Tool radius Instruction format Cancels tool compensati...

Page 79: ...l G41 is Cutter Compensation Left and G42 is Cutter Compensa tion Right The compensation cannot be started with Circular Interpolation G02 G03 The travel distance at startup must be greater than the c...

Page 80: ...tool edge This makes the velocity dif ferent between the tool center and the commanded path The user can select the tool center path after correction or the tool edge path contacting with the com man...

Page 81: ...and automatically adds an arc with the same radius as the cutter radius Tool diameter compensation Corner circular interpolation Added Arc Start of Correction at Inside the Corner X Y Path after corre...

Page 82: ...ted circular interpolation operation Tool center path Tool center path Startup move Startup move Cutter Compensation Cutter Compensation Cutter Compensation Programmed path Programmed path Arc added A...

Page 83: ...ar interpolation operation Linear interpolation operation Circular interpolation operation Tool center path Tool center path Cutter Compensation Cutter Compensation Cutter Compensation Cutter Compensa...

Page 84: ...ensation Cutter Compensation Cutter Compensation Programmed path Programmed path Linear interpolation operation Arc added Circular interpolation operation Circular interpolation operation Circular int...

Page 85: ...interpolation operation Circular interpolation operation Circular interpolation operation Tool center path Tool center path Cutter Compensation Cutter Compensation Cutter Compensation Cutter Compensa...

Page 86: ...tection For details refer to the NJ NY series NC Integrated Controller User s Manual Cat No O030 Detection of Overcut Programmed path Programmed path Move of cancel Move of cancel Corrected linear int...

Page 87: ...operations from the start to the end of cutter compensation The operations consist of the following three steps Prevention of Overcut Programming Example 1 Startup operation Movement to the cutting s...

Page 88: ...p operation and cancel operation G00 cannot be used for the startup operation The travel distance of the startup operation and the cancel operation must be equal to or greater than the cutter radius E...

Page 89: ...ition in the positive direction G44 in the negative direction and G49 terminates the correction The extent of cor rection depends on the selected tool Modal Non modal Modal Modal group 08 Tool length...

Page 90: ...is an example When using this command refer to the instruction manual provided by the machine tool manufacturer Programming Example N01 G17 G64 G90 G01 F100 N02 M100 VA1 Tool change Tool ID 1 Tool len...

Page 91: ...the omitted value is handled as the same size P parameter is prioritized over I J and K parameters Modal Non modal Modal Modal group 11 Scaling Instruction format Disables scaling G50 Enables scaling...

Page 92: ...ouble N14 M98 P1000 Cuts the figure of double size indicated by the solid line in the following figure N15 G50 Disables scaling N16 G01 X0 Y0 N17 M98 P1000 Cuts the figure of original size indicated b...

Page 93: ...ion format X Y and Z parameters indicate the symmetric axes If any of them is omitted the axis is not mirrored The values of X Y and Z parameters are handled as absolute posi tions Modal Non modal Mod...

Page 94: ...ogramming Example N11 G64 G90 G01 F100 N12 M03 S300 N13 G51 1 X30 Line symmetry to X 30 N14 M98 P1000 Cuts the mirrored figure by calling the subprogram indicated by the solid line in the following fi...

Page 95: ...es are handled as absolute positions R indi cates a rotation angle and if it is omitted an error occurs The user can select XY ZX or YZ plane by using the G17 G18 or G19 Modal Non modal Modal Modal gr...

Page 96: ...X10 Y0 R90 Sets the rotation angle to 90 N15 M98 P1000 Cuts the rotated figure indicated by the solid line in the following figure N16 G69 Disables rotation N17 M98 P1000 Cuts the unrotated figure ind...

Page 97: ...ference Manual O031 2 Utilities Instruction Name Page G74 Left handed Tapping Cycle P 2 60 G80 Fixed Cycle Cancel P 2 62 G84 Tapping Cycle P 2 63 G98 Fixed Cycle Return to Initial Level P 2 66 G99 Fix...

Page 98: ...e Modal Non modal Modal Modal group 09 Fixed cycle Instruction format G74 X Y Z R P K Relevant G codes G80 G98 G99 G90 G91 Parameters Parameter Name Description X Target X axis Position Specifies the...

Page 99: ...ns of spindle axis consult the instruction manual provided by the machine tool manufacturer Refer to the programming example of G84 Tapping Cycle on page 2 63 G74 Xx Yy Zz Rr Pp Kk if G91 and G98 are...

Page 100: ...Cycle Cancel This instruction cancels a fixed cycle This command does not have any parameters to set This command must be inserted into the end of a fixed cycle Modal Non modal Modal Modal group 09 F...

Page 101: ...r Left handed Tapping Cycle G74 This command is the same as Left handed Tapping cycle G74 except that the rotation direction of spindle axis is different This command interchanges Spindle CW M03 and S...

Page 102: ...rten the cycle time The command position follows the specifications for the Absolute Dimension G90 and Incremental Dimension G91 Absolute dimension Programming Example N01 G17 G64 G90 F100 S300 Absolu...

Page 103: ...polation G02 G03 is spec ified the Fixed Cycle is canceled Subprogram Call M98 is disabled Any code other than Left handed Tapping Cycle G74 Tapping Cycle G84 Fixed Cycle Return to Initial Level G98 a...

Page 104: ...e return position of a fixed cycle to the initial level This command does not have any parameters to set This command sets the return position of a fixed cycle to the initial level Refer to each comma...

Page 105: ...el This instruction sets the return position of a fixed cycle to the R point level This command does not have any parameters to set This command sets the return position of a fixed cycle to the R poin...

Page 106: ...near Interpolation G01 and Circular Interpolation G02 G03 Supporting the chamfer function Supporting the fillet function Coordinates after correction Original coordinates N01 G91 N02 G01 X3 Y 3 N03 G0...

Page 107: ...series G code Instructions Reference Manual O031 This section describes the specifications of the M code Auxiliary Function Output 3 3 Reservation Auxiliary Functions 3 7 Spindle Axis 3 11 Programming...

Page 108: ...3 M Code 3 2 NJ NY series G code Instructions Reference Manual O031...

Page 109: ...3 3 NJ NY series G code Instructions Reference Manual O031 3 Auxiliary Function Output Instruction Name Page M Auxiliary Function Output P 3 5...

Page 110: ...The output timing can be defined for each auxiliary function whether it is simultaneously with the move ment command or after completion of movement An auxiliary function defined to output after comp...

Page 111: ...nction Output that has parameters waits for completion of auxiliary function reset from the sequence control program in a block with the auxiliary function outputs setting Specify the parameters if yo...

Page 112: ...3 M Code 3 6 NJ NY series G code Instructions Reference Manual O031...

Page 113: ...3 7 NJ NY series G code Instructions Reference Manual O031 3 Reservation Auxiliary Functions Instruction Name Page M00 Program Stop P 3 8 M01 Optional Stop P 3 9 M02 M30 End of Program P 3 10...

Page 114: ...M00 Program Stop This instruction stops the NC program The NC program is stopped at the block where M00 is commanded The machine status modal status does not change after the stop until the operation...

Page 115: ...031 M01 Optional Stop 3 M01 Optional Stop This instruction stops the NC program by optional input As is the case with M00 execution of the NC program is stopped at the block where M01 is com manded su...

Page 116: ...nd the NC program Indicates the end of the NC program The NC program is stopped to enable reset mode When a block where M30 is specified is executed return to the head of the program Therefore the blo...

Page 117: ...e Instructions Reference Manual O031 3 Spindle Axis Instruction Name Page S Spindle Axis Rotation Function S function P 3 12 M03 Spindle CW P 3 13 M04 Spindle CCW P 3 14 M05 Spindle OFF P 3 15 M19 Spi...

Page 118: ...number next to S code The unit of rotational speed is r min revolutions per minute The spindle axis is not operated simply by specifying the rotational speed To run the spindle axis use the Auxiliary...

Page 119: ...spindle axis operation and the timing of completion of M03 refer to the instruction manual provided by the machine tool manufacturer For the acceleration deceleration at startup reversing and changin...

Page 120: ...rotation direction and the rotational speed that is set For the information on the spindle axis operation and the timing of completion of M04 refer to the instruction manual provided by the machine to...

Page 121: ...tion on the spindle axis operation and the timing of completion of M05 refer to the instruction manual provided by the machine tool manufacturer For the deceleration at stopping also refer to the inst...

Page 122: ...for the Spindle orientation position setting It is a positioning function specified the rotation position angle of a tool If the spindle axis is already activated it changes its speed to the Spindle o...

Page 123: ...spindle axis to a tool change posi tion from the state where the spindle axis is rotating while moving the tool rotation position to a posi tion where the tool can be changed Programming Example N01 G...

Page 124: ...3 M Code 3 18 NJ NY series G code Instructions Reference Manual O031...

Page 125: ...3 19 NJ NY series G code Instructions Reference Manual O031 3 Programming Instruction Name Page M98 Subprogram Call P 3 20 M99 Subprogram End P 3 21...

Page 126: ...output and the program stops running When you specify P1000 as shown in the following sample subprogram 1000 is called Also when you specify the number 10 after the L argument as shown in the followin...

Page 127: ...current program was called The M99 function behaves differently between when a subprogram is called by a subprogram and when it is called by a main program When the subprogram is called from a subpro...

Page 128: ...3 M Code 3 22 NJ NY series G code Instructions Reference Manual O031...

Page 129: ...2 Arithmetic operators 4 2 4 1 3 Functions 4 3 4 1 4 Condition comparators 4 5 4 1 5 Conditional join operators 4 5 4 2 Branch and Repetition 4 6 4 2 1 if else 4 6 4 2 2 switch case 4 6 4 2 3 while 4...

Page 130: ...t performs subtraction when used as a binary operator or conversion when used as a unary operator This operator is a binary operator that multiplies numbers 4 1 1 Operator priority Priority Operators...

Page 131: ...ssion Inverse hyperbolic cosine Positive real num ber 1 0 Positive real number Radian asin expression Arc sine arcsin of trigonomet ric function 1 0 to 1 0 Pi 2 to Pi 2 Radian asind expression Arc sin...

Page 132: ...bers log10 expression Logarithm of base 10 Positive real number All real numbers log2 expression Logarithm of base 2 Positive real number All real numbers pow expression expression Exponentiation All...

Page 133: ...rs are used to join truth values Logical negation operator always require 4 1 4 Condition comparators Syntax Operation exp1 exp2 Equality comparison operator exp1 exp2 None equality comparison operato...

Page 134: ...to the following commands If no case conditional sentence is found that matches the evaluated value of the switch expression the program execution jumps to the default branch If the default branch is...

Page 135: ...nd subsequent variables They are the sole 64 bit floating point arrays that can be shared inside the Controller The user can use from P0 to P32767 but cannot use P32768 and subsequent variables Indire...

Page 136: ...4 PROGRAM CODES 4 8 NJ NY series G code Instructions Reference Manual O031...

Page 137: ...A 1 A NJ NY series G code Instructions Reference Manual O031 A 1 Program Parsing by CNC Operator A 2 A 1 1 Intermediate code format A 2 A 1 2 Program Parsing Example A 4 Appendices...

Page 138: ...rmediate code format that is generated in program parsing by CNC Oper ator The intermediate codes are created as a text file having the pmc extension In the main program the open prog program number h...

Page 139: ...of block These M codes are necessary for the NC Integrated Controller for program interpretation and it is not necessary for users be conscious about it Therefore waiting for an M code or resetting it...

Page 140: ...ping Cycle N12 G99 X10 N13 G98 X10 N14 G80 End of Tapping Cycle N15 M05 N16 M30 End of program Subprogram N01 G04 P100 N02 M99 End of subprogram NC program after program parsing by CNC Operator Main p...

Page 141: ......

Page 142: ...IL 60169 U S A Tel 1 847 843 7900 Fax 1 847 843 7787 Regional Headquarters OMRON EUROPE B V Wegalaan 67 69 2132 JD Hoofddorp The Netherlands Tel 31 2356 81 300 Fax 31 2356 81 388 Contact www ia omron...

Reviews: