Programming manual
CNC 8055
CNC 8055i
PROGR
A
M CONTR
O
L
INSTRUCTIONS
14.
·M· & ·EN· M
ODELS
S
OFT
: V02.2
X
·405·
Sub
routine
i
n
stru
ctio
ns
14.5.1
Calls to subroutines using G functions
Subroutine calls are made using the CALL and PCALL instructions. In addition to using these
statements, it is also possible to make subroutine calls using specific G functions. This way, the calls
to subroutines are more similar to machine tool language.
Functions G180-G189 and G380-G399 can call the associated OEM and user subroutine as long
as they are global subroutines. G functions cannot be used to call local subroutines.
Up to 30 subroutines may be defined and associated with functions G180-G189 and G380-G399,
and it is also possible to initialize local parameters for each subroutine.
When executing one of these functions, its associated subroutine will be executed.
Functions G180-G189 and G380-G399 are not modal.
Programming format
The programming format is the following:
G180 <P0..Pn>
<P0..Pn> Optional. Initializing parameters.
Example:
G183 P1=12.3 P2=6
G187 A12.3 B45.3 P10=6
Defining local parameters.
The values of the parameters are defined after the call function and they may be defined using the
name of the parameter (P0-P25) or using letters (A-Z) so "A" is the same as P0 and "Z" is the same
as P25.
Plus, parameters may also be programmed as follows:
• S=P100
• SP100
In either case, local parameter P18(S) would assume the established global parameter value P100.
The definitions described here may be combined in the same block.
Nesting levels
If the functions initialize local parameters, this instruction generates a new nesting level .
The maximum parameter nesting level is 6, within the 15 nesting level of the subroutines, just like
PCALL instructions.
Identification via PLC
All the G functions are identified through GGS* read-only variables . GGSH and GGSP read-only
variables are used to identify the new G functions via PLC; these variables return the status of the
G functions.
Executing a call
Each function G180-G189 and G380-G399, has its corresponding subroutine associated with it.
Calling a G function means calling the subroutine of the same name.
Summary of Contents for 8055 EN
Page 1: ...CNC 8055 M EN Programming manual Ref 1711 Soft V02 2x...
Page 8: ...8 Programming manual CNC 8055 CNC 8055i SOFT V02 2X...
Page 12: ...12 CNC 8055 CNC 8055i Declaration of conformity and Warranty conditions...
Page 16: ...16 CNC 8055 CNC 8055i Version history...
Page 22: ...22 CNC 8055 CNC 8055i Returning conditions...
Page 24: ...24 CNC 8055 CNC 8055i Additional notes...
Page 26: ...26 CNC 8055 CNC 8055i Fagor documentation...
Page 448: ......
Page 464: ...464 Programming manual CNC 8055 CNC 8055i D M EN MODELS SOFT V02 2X Key code...
Page 466: ...466 Programming manual CNC 8055 CNC 8055i D M EN MODELS SOFT V02 2X Key code MC operator panel...
Page 467: ...Programming manual CNC 8055 CNC 8055i D M EN MODELS SOFT V02 2X 467 Key code...
Page 468: ...468 Programming manual CNC 8055 CNC 8055i D M EN MODELS SOFT V02 2X Key code...
Page 471: ...Programming manual CNC 8055 CNC 8055i D M EN MODELS SOFT V02 2X 471 Key code 11 LCD Monitor...
Page 472: ...472 Programming manual CNC 8055 CNC 8055i D M EN MODELS SOFT V02 2X Key code...
Page 478: ...478 Programming manual CNC 8055 CNC 8055i F M EN MODELS SOFT V02 2X Maintenance...
Page 479: ...Programming manual CNC 8055 CNC 8055i F SOFT V02 2X 479...
Page 480: ...480 Programming manual CNC 8055 CNC 8055i F SOFT V02 2X...
Page 481: ......