Technical data
Appendix
27.3 Data Types and Parameter Types
Programming with STEP 7
620 Manual, 05/2010, A5E02789666-01
In this example, FC100 has three parameters (in_par1, in_par2, and in_par3) declared as the ANY
data type.
• When FB10 calls FC100, FB10 transfers an integer (the static variable speed), a word
(MW100), and a double word to DB10 (DB10.DBD40).
• When FB11 calls FC100, FB11 transfers an array of real numbers (the temporary variable
"Thermo"), a Boolean value (M 1.3), and a timer (T2).
Specifying a Data Area for an ANY Parameter
You can assign not only individual addresses (for example, MW100) to an ANY parameter but you
can also specify a data area. If you want to assign a data area as the actual parameter, use the
following format of a constant to specify the amount of data to be transferred:
p# Area ID Byte.Bit Data Type Repetition Factor
For the data type element, you can specify all elementary data types and the data type
DATE_AND_TIME in the format for constants. If the data type is not BOOL, the bit address of 0
(x.0) must be specified. The following table illustrates examples of the format for specifying
memory areas to be transferred to an ANY parameter.
Actual Parameter Description
p# M 50.0 BYTE 10 Specifies 10 bytes in the byte memory area:
MB50 to MB59.
p# DB10.DBX5.0 S5TIME 3 Specifies 3 units of data of the data type S5TIME, that are located in
DB10:
DB byte 5 to DB byte 10.
p# Q 10.0 BOOL 4 Specifies 4 bits in the output area:
Q 10.0 to Q 10.3.