Siemens NAN 67 Series Manual de Serviço Página 54

  • Descarregar
  • Adicionar aos meus manuais
  • Imprimir
  • Página
    / 318
  • Índice
  • MARCADORES
  • Avaliado. / 5. Com base em avaliações de clientes
Vista de página 53
4-2
Ladder Logic (LAD) for S7-300 and S7-400
C79000-G7076-C504-02
4.1 Creating Data Blocks – Overview
Data blocks (DBs) are used to handle data which is why they do not have a
code section. Programming data blocks involves the following :
S Declaration table: The declaration table is where you specify the data
structure of the data block.
S Block properties: These include extra information such as time stamp,
programming language and path name, which is all entered by the system
itself. You can also add information about the name, family, version and
author and you can assign system attributes for blocks (see Chapter 5).
A user program can have the following data blocks:
S Shared DBs can be accessed by all logic blocks in the program. The data
remains stored in the data block even when it has been closed.
If you require several shared DBs of the same data structure, you can
create them with the help of a UDT. These are data blocks with an
associated user-defined data type.
S Instance DBs are associated with specific function blocks and are
structured according to the declaration table of the FB. You can only
create an instance DB if the corresponding function block exists. They are
data blocks with an associated function block.
Depending on the type of data block you want to create, different methods
are used.
Shared data blocks can be created as follows:
S Define the structure for a single data block. For this you must define the
variables and data types in the desired order. This structure only applies to
this DB.
S Define the structure for the data block with the help of a user-defined data
type. In this case the UDT structure defines the data structure of the DB.
A user data type can be assigned to a number of data blocks.
Create an instance data block and then:
S Assign an existing function block to the data block. In this case the
declaration section of the function block defines the structure of the data
block. A number of instance data blocks can be assigned to one function
block.
Data Blocks
Types of Data
Blocks
Methods of
Creating Data
Blocks
Creating Data Blocks and User-Defined Data Types
Vista de página 53
1 2 ... 49 50 51 52 53 54 55 56 57 58 59 ... 317 318

Comentários a estes Manuais

Sem comentários