Parametric Programming?
Parametric programming is not the most commonly used programming tool but it is a very powerful technique which will greatly enhance a program’s capacity to include complex routines.
Parametric programming combines manual programming with computer programming techniques similar to those found in BASIC,
‘C’ or PASCAL.
Computer-related features such as variables, arithmetic expressions, and looping are all made available.
One of the most popular implementations of parametric programming is Custom Macro B (used by Fanuc and Fanuc-compatible controls) . The Advanced Programming Language [APL] is another.
There are many applications for this type of programming which range from the simple inclusion of a variable, to the creation of
routines which deliver complex motions.
If a number of similar parts are being manufactured by constantly editing the same CNC program then , using the techniques provided by parametric programming , a single program can be created which suits all.
Built-in canned cycles don’t always provide the precise functions you require. Parametric programming allows you to develop special purpose routines for operations like thread milling and contour pocketing etc. In essence you can design your own canned cycles.
Parametric programming can also be used to create complex motion. Unfortunately most CNC machines do not include spiral interpolation but this can be generated using parametric functions as can any other form of interpolation you might need to initiate.
Parametric programming puts a new dimension on part programming giving creative and innovative programmers a tool to make the best use of the machine’s capabilities.
Example:
To stress what can be done with parametric programming, here is a simple example for a machining centre application. It will machine a hole of any size at any location. Notice how similar this program is to a program written in BASIC.
V01=0.5 ; Cutter rad
V02=3.0 ; X position of hole
V03=1.5 ; Y position of hole
V04=.5 ; Depth of counterbored hole
V07=2.5 ; Diameter of counterbored hole
F150 ; Feedrate 150 in/min
X (V02) Y (V03) ; Rapid to hole centre X3.0 Y1.5
Z0 ; Move tool to top of work
F4 ; cutting feedrate
Z (0-(V04)) ;
X ( (V02+(V07/2)) -V01) ; move to edge of hole ( (3 + (2.5/2))-0.5) = 3.75
I ; incremental mode
G02 X0 Y0 I (0-((V07/2)-V01)) J0 ; machine c’bore
A ; absolute mode
G01 X (V02) Y (V03) ; move back to hole centre
F150 ; rapid feed
Z.1 ; Z clearance height
X0 Y0 ;
E ; program end