8 3
96-8000 rev R June 2007
Macros
MACROS
I
NTRODUCTION
This control feature is optional; call your dealer for information.
Macros add capabilities and flexibly to the control that are not possible with standard G-code. Some possible uses
are, families of parts, custom canned cycles, complex motions, and driving optional devices. The possibilities are
almost endless.
A Macro is any routine/subprogram that may be run multiple times. A macro statement can assign a value to a
variable or read a value from a variable, evaluate an expression, conditionally or unconditionally branch to another
point within a program, or conditionally repeat some section of program.
Here are a few examples of the applications for Macros. Rather than give macro code here, we will outline the
general applications that Macros can be used for.
• Tools For Immediate, On-Table Fixturing Many setup procedures can be semi-automated to assist
the machinist. Tools can be reserved for immediate situations that were not anticipated during tool design.
For instance, suppose a company uses a standard clamp with a standard bolthole pattern. If it is
discovered, after setup, that a fixture will need an additional clamp and if macro subroutine 2000 has been
programmed for drilling the bolt pattern of the clamp, then the following two-step procedure is all that is
needed for adding the clamp to the fixture.
1. Determine X, Y, and Z coordinates and angle where the clamp is to be placed by jogging the
machine to the proposed clamp position and reading the position coordinates from the machine
display.
2. Execute the following command in MDI mode:
G65 P2000 X??? Y??? Z??? A??? ;
Where “???” Are the values determined in Step 1.
Here, macro 2000 takes care of all the work since it was designed to drill the clamp bolthole
pattern at the specified angle of A. Essentially; the machinist has created a custom canned
cycle.
• Simple Patterns That Are Repeated Over And Over Again In The Shop Patterns that recur over
and over again can be defined using macros and stored. For example:
1) Bolt hole patterns
2) Slotting
3) Angular patterns, any number of holes, at any angle, with any spacing
4) Specialty milling such as soft jaws
5) Matrix Patterns, (e.g. 12 across and 15 down)
6) Fly cutting a surface, (e.g. 12 inches by 5 inches using a 3 inch fly cutter)
• Automatic Offset Setting Based On The Program With macros, coordinate offsets can be set in each
program so that setup procedures become easier and less error-prone (macro variables #2001-2800).
• Probing Probing enhances the capabilities of the machine in many ways, some examples are:
1) Profiling of a part to determine unknown dimensions for later machining.
2) Tool calibration for offset and wear values.
3) Inspection prior to machining to determine material allowance on castings.
4) Inspection after machining to determine parallelism and flatness values as well as location.
Summary of Contents for Mill
Page 12: ...96 8000 rev R June 2007 Safety 5 ...
Page 14: ...96 8000 rev R June 2007 Safety 7 LATHE WARNING DECALS ...
Page 15: ...8 Safety 96 8000 rev R June 2007 ...
Page 17: ...10 Introduction 96 8000 rev R June 2007 ...
Page 117: ...110 4 5 Axis Programming 96 8000 rev R June 2007 ...
Page 199: ...Settings 192 96 8000 rev R June 2007 ...