EasyManuals Logo
Home>Siemens>Control Systems>SINUMERIK 804D sl

Siemens SINUMERIK 804D sl Function Manual

Siemens SINUMERIK 804D sl
2050 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 #1170 background imageLoading...
Page #1170 background image
Detailed description
2.14 Useful tips on programming with STEP 7
Power Line Basic PLC Program (P3)
2-258 Function Manual, 08/2005 Edition, 6FC5397-0BP10-0BA0
2.14.3 ANY and POINTER
2.14.3.1 General
General
The following programming examples illustrate different programming mechanisms. They
demonstrate how input/output and transit variables (VAR_INPUT, VAR_OUTPUT,
VAR_IN_OUT) are accessed by data types "POINTER" or "ANY" within an FC or FB. The
access operations are described in such a way that a part symbolic method of programming
can be used.
2.14.3.2 Use of POINTER and ANY in FC if POINTER or ANY is available as parameter
Description of functions
FC 99 has inputs parameters that are defined as POINTER or ANY. The example shows a
body program via which the subcomponents of the POINTER or ANY can be accessed. In
this case, the DB parameterized with POINTER or ANY is opened and the address offset
stored as a cross area pointer in address register AR1, thus allowing access to data
elements of variables (generally structures and arrays) that are addressed via the POINTER,
ANY. This access operation is described at the end of the relevant program sequence in the
example. With data type ANY, it is also possible to execute a check or branch when the
variable is accessed based on the data type and the number of elements involved.
FUNCTION FC 99: VOID Comment
VAR_INPUT
Row : BYTE ;
Convert : BOOL ; //Activate numerical conversion
Addr: POINTER; //Points to variable
Addr1 : ANY ;
END_VAR
VAR_TEMP
dbchr : WORD ;
Number: WORD ;
type : BYTE ;
END_VAR
BEGIN
NETWORK
TITLE =
//POINTER
L P##Addr;
LAR1 ; //Retrieve pointer
L W [AR1,P#0.0]; //Retrieve DB number

Table of Contents

Other manuals for Siemens SINUMERIK 804D sl

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Siemens SINUMERIK 804D sl and is the answer not in the manual?

Siemens SINUMERIK 804D sl Specifications

General IconGeneral
BrandSiemens
ModelSINUMERIK 804D sl
CategoryControl Systems
LanguageEnglish

Related product manuals