EasyManuals Logo
Home>Siemens>Control Systems>SINUMERIK ONE MCP 2400.4c

Siemens SINUMERIK ONE MCP 2400.4c Programming Manual

Siemens SINUMERIK ONE MCP 2400.4c
1334 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #494 background imageLoading...
Page #494 background image
Actual parameters
When a subprogram is called, absolute values or variables (known as actual parameters) have
to be transferred to it.
As such, the actual parameters assign up-to-date values to the interface of the subprogram
when the latter is called.
Example:
Program code Comment
N10 DEF REAL WIDTH ; Variable definition
N20 WIDTH=20.0 ; Variable assignment
N30 CONTOUR(5.5, WIDTH) ; Subprogram call with actual parameters: 5.5
and WIDTH
...
N100 M30
3.2.1.6 Parameter transfer
Definition of a subprogram with parameter transfer
A subprogram with parameter transfer is defined using the PROC keyword and a complete list
of all the parameters expected by the subprogram.
Incomplete parameter transfer
When the subprogram is called, not all the parameters defined in the subprogram interface
have to be transferred explicitly. If a parameter is omitted, the default value "0" is transferred for
it.
So that the parameter sequence can be uniquely identified, however, the commas used as
parameter separators always have to be included. The last parameter is an exception. If it is
omitted from the call, the last comma can also be left out.
Example:
Subprogram:
Program code Comment
PROC SUB_PROG (REAL X, REAL Y, REAL Z) ; Formal parameters: X, Y, and Z
...
N100 RET
Main program:
Program code Comment
PROC MAIN_PROG
...
Work preparation
3.2 Subprogram technique
NC programming
494 Programming Manual, 12/2019, 6FC5398-2EP40-0BA0

Table of Contents

Other manuals for Siemens SINUMERIK ONE MCP 2400.4c

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Siemens SINUMERIK ONE MCP 2400.4c and is the answer not in the manual?

Siemens SINUMERIK ONE MCP 2400.4c Specifications

General IconGeneral
BrandSiemens
ModelSINUMERIK ONE MCP 2400.4c
CategoryControl Systems
LanguageEnglish

Related product manuals