GE PACSystems RX7i Cpu Programmer's Reference Manual page 25

Hide thumbs Also See for PACSystems RX7i:
Table of Contents

Advertisement

Chapter 2. Program Organization
Type
BOOL
BYTE
INT, UINT, and WORD
DINT, REAL, and
DWORD
LREAL
function block
1
UDFB
1
User Defined Type
(UDT)
The PACSystems default parameter passing mechanisms correspond to the way that parameterized
subroutine block (PSB) parameters are passed on 90-70 controllers. The parameter passing
mechanisms of formal parameters cannot be changed from their default values.
Arguments, or actual parameters, are passed into a parameterized block whenever a parameterized
block call is executed. In general, arguments to formal parameters may come from any memory type,
may be data flow, and may be constants (when the formal parameter's LENGTH is 1). The following
list contains the restrictions on arguments relative to this general rule:
%S memory addresses cannot be used as arguments to any output parameter. This is because
user logic is not allowed to write to %S memory.
Indirect references used as arguments are resolved immediately before the parameterized block
is called, and the corresponding direct reference is passed into the block. For example, where
%R1 contains the value 10 and @R1 is used as an argument to a call, immediately before calling
the block, @R1 is resolved to be %R10, and %R10 is passed in as the argument to the block.
During execution of the block, the argument remains as %R10, regardless of whether the value in
%R1 changes.
In general, formal parameters within a parameterized block may be used with any instruction or with
any block call, as long as their TYPE and LENGTH are compatible with what the instruction, function,
or block call requires. The following list contains the restrictions on formal parameters relative to
this general rule:
Formal parameters cannot be used on legacy transitional contacts or coils, or on FAULT, NOFLT,
HIALM, or LOALM contacts. However, formal parameters can be used on IEC transitional
contacts and coils.
Formal BOOL input parameters cannot be used on coils or as output arguments to a function or
to a block call.
Formal parameters cannot be used with the DO I/O function.
Formal parameters cannot be used with indirect referencing.
1
A maximum of 16 input parameters can be of type function block or UDFB.
10
PACSystems* RX7i, RX3i and RSTi-EP CPU Programmer's Reference Manual
Length
Default Parameter Passing Mechanism
INPUTS: by reference
1 to 256
OUTPUTS: by value result; except Y0, which is by initial-value result
INPUTS: by reference
1 to 1024
OUTPUTS: by reference
INPUTS: by reference
1 to 512
OUTPUTS: by reference
INPUTS: by reference
1 to 256
OUTPUTS: by reference
INPUTS: by reference
1 to 128
OUTPUTS: by reference
INPUTS: by reference
1
OUTPUTS: not allowed
INPUTS: by reference
1
OUTPUTS: not allowed
INPUTS: by reference
1 to 1024
OUTPUTS: not allowed
GFK-2950C

Advertisement

Table of Contents
loading

This manual is also suitable for:

Pacsystems rx3iPacsystems rsti-ep

Table of Contents