
Programming manual.
CNC 8070
14.
SUBROUTINES.
Subro
u
tine execu
ti
on.
·272·
(R
EF
: 1709)
14.3.4
#PCALL. Call to a global or local subroutine initializing parameters.
The #PCALL instruction calls a local or global subroutine. This type of call allows initializing
local parameters of the subroutine. When it is a global subroutine, its whole path may be
defined.
When there are two subroutines, one local and the other one global, with the same name,
the following criteria is applied. If the path has been defined in the call, the CNC will execute
the global subroutine, otherwise, it will execute the local one.
Programming format.
The programming format is:
#PCALL <path> sub <P0..Pn>
How to set local parameters.
Calling a subroutine allows for the 57 local parameters (P0 to P57) to be initializes. The
values of the parameters must be defined following the call statement and may be defined
in two ways. Both ways of setting local parameters are equivalent and may be combined in
the same block.
• The parameters P0 to P25 can also be defined using the letters from A to Z, so that "A"
is equal to P0, "B" to P1 and so forth and where "Z" is equal to P25.
• The parameters P26 to P52 can also be defined using the letters from "D0= " a "D31=",
so that "D0=" is equal to P26, "D1=" to P27 and so forth and where "D31=" is equal to P57.
Path definition.
Defining the path is optional. If defined, the CNC only looks for the subroutine in that folder;
if not defined, the CNC looks for the subroutine in the default folders. See
Local parameter nesting levels.
If local parameters are initialized in the #PCALL instruction, this instruction generates a new
nesting level for the local parameters. Remember that up to 7 parameter nesting levels are
possible within 20 subroutine nesting levels.
path
Optional. Subroutine location.
sub
Name of the subroutine
P0..Pn
Optional. Initializing parameters.
#PCALL C:\Cnc8070\Users\Prg\sub1.nc
#PCALL C:\Cnc8070\Users\sub2.nc A12.3 P10=6
#PCALL Sub3.nc A12.3 F45.3 P10=6
Programming example.
#PCALL subroutine.nc A12.3 F45.3 P10=6 D0=34.12 D1=5 P28=0
Summary of Contents for 8070 BL
Page 1: ... Ref 1709 8070 CNC Programming manual ...
Page 8: ...BLANK PAGE 8 ...
Page 12: ...BLANK PAGE 12 ...
Page 14: ...BLANK PAGE 14 ...
Page 26: ...BLANK PAGE 26 ...
Page 28: ...BLANK PAGE 28 ...
Page 30: ...BLANK PAGE 30 ...
Page 60: ...Programming manual CNC 8070 2 MACHINE OVERVIEW Home search 60 REF 1709 ...
Page 72: ...Programming manual CNC 8070 3 COORDINATE SYSTEM Coordinate programming 72 REF 1709 ...
Page 96: ...Programming manual CNC 8070 5 ORIGIN SELECTION Polar origin preset G30 96 REF 1709 ...
Page 178: ...Programming manual CNC 8070 9 TOOL PATH CONTROL MANUAL INTERVENTION Variables 178 REF 1709 ...
Page 304: ...Programming manual CNC 8070 16 C AXIS Machining of the turning side of the part 304 REF 1709 ...
Page 442: ...Programming manual CNC 8070 23 CNC VARIABLES 442 REF 1709 ...
Page 443: ...Programming manual CNC 8070 443 User notes REF 1709 ...