Anaheim DPJ72LC2 manual M00 Program Pause, M30 End of Program, M98, M99, M02 Subroutine Commands

Page 64

60

Section 4 System Programming

G02

X1.0

Y-1.0 I0.5 J-0.5 Moves the tool using counter-clockwise

 

 

 

circular interpolation to the Program

 

 

 

coordinate X=3.0, Y=4.0, Z=-2.0 with a

 

 

 

center point at Program coordinate X=2.5,

 

 

 

Y=4.5, Z=-2.0.

G90

 

 

All XYZ coordinates after this command

 

 

 

will be interpreted as Program coordinates.

G01

X1.0

Y2.0 Z-0.5

Moves the tool directly to the Program

 

 

 

coordinate X=1.0, Y=2.0, Z=-0.5.

M00 Program Pause

The M00 command pauses processing of the G-Code program. You can use this command anywhere in the program. By default, LC displays a dialog box to inform you that it has paused processing. You can control whether or not this dialog box appears using the Message on M00 Program Pause checkbox in the G/M Code Setup dialog box.

M30 End of Program

The M30 command ends processing of the G-Code program and automatically resets the program to the top.

M98, M99, M02 Subroutine Commands

Subroutines allow you to eliminate repetitive programming. LC supports the use of subroutines with the M98, M99, and M02 (or M30) commands. Use of these commands is best explained through a simple example. The following G-code program uses one subroutine called "mysub":

Example:

 

 

G01

X1 Y1 F10

First line of main program.

M98 Pmysub

Jump to subroutine “mysub”.

G01

X0 Y0

Continued execution after “mysub” ends.

M02

End of main program.

Omysub

First line of the subroutine called “mysub”.

G01

X2 Y2

Continued execution within the subroutine.

M99

End of subroutine “mysub”.

In the main program, the M98 command causes program execution to jump to the first line of the subroutine named "mysub". Notice that the letter "P" must immediately precede the name of the subroutine with no spaces.

Image 64
Contents User’s Guide Table of Contents Error! Bookmark not defined Page Product Support Thank YouSystem Requirements Installing LC Using the MouseIf you are using Windows 3.1 or If you are using Windows 95, 98 or NTChoosing Commands Using Standard Windows ControlsPull-Down Menus Command ButtonsText Boxes System Safety About this Manual Program OverviewPull Down Menu Bar File MenuMain Screen Features Controller Menu Main Screen Features To change the state of an output line View Menu Tool Position BoxHelp Menu Other Features ProgramMachine RelativeTo set new values within a coordinate system To zero each axisTool Path View Port To zero all axesControl Box Code Mode Jog Mode Point Mode Home Mode Message Box Program Listing BoxPage Windows Setup WindowsSetup File Software SetupSystem Settings To set your system settings Initial Setup Machine Tool Settings To set the Machine Tool Settings Initial Setup Feedrate and Ramping Settings To Set the Maximum Unramped FeedratesTo Set the Maximum Feedrates To Set the Ramping RateTo Set the Direction Change Delay To Set the Jog Rates Setting Machine ZeroTo Set the Maximum Arc Feedrate To Set Machine Zero Using Home Switches To Set Machine Zero Without Using Home SwitchesSetting Backlash To Set BacklashTooling Settings To Set Up the Tool LibraryInput Line Settings To Configure the Input LinesTo Configure the Output Lines Output Line SettingsTo define an M-code to control output lines Motor Signal Settings To Configure the Motor Signal LinesTo Configure G and M Code Handling Initial Setup Page Opening a G-Code Program Importing a DXF FileTo open an existing program To import a DXF fileTo choose a different file name or folder System Programming To open the editor Using the Program EditorTo edit a new program To save your program using the same file name To close the editorM Codes Supported Key Programming ConceptsMode Absolute vs. IncrementalM Code Reference G00 Rapid Tool PositioningG01 Linear Interpolated Cutting Move G02 Clockwise Circular Cutting MoveEnd G03 Counter Clockwise Circular Cutting Move End Center StartG04 Dwell G17, G18, G19 Arc Plane SelectionG20, G21 Inch Units and Metric Units G28 Return to Reference PointG29 Return from Reference Point System Programming System Programming System Programming System Programming G52 Local Coordinate System G90 Absolute Positioning Mode G91 Incremental Positioning ModeM00 Program Pause M98, M99, M02 Subroutine CommandsM30 End of Program MXX Miscellaneous Device Control Feedrate CommandProgram Comments System Programming Configuring LC Starting LC SoftwareWindows 3.1 or Windows 95, 98 or NTLoading a G-Code File Viewing the Tool Path Tutorial Animating the G-Code File Editing a G-Code File Connecting the Machine Online Using the Jog ControlsSetting Machine Zero Using the Point Move Setting Program Zero on the Machine Tool Testing the Program on the Machine Tool Exiting the Program Cutting the PartTurning off the Controller O Connections Typical Output Configuration Driver BLD72 Series Driver Motor ON/OFF Input Internally ConnectedSetting the Kick Current Driver Page Glossary Glossary Glossary