In the upper part of the editor there is the parameter table. In this
example the 2 integer values value1 and value2 are to be compared
together
. Since both values are read only by the function, these are to
be defined as "in".
1.
Select the ‘in
à
’ row at the ‘parameter table’ and enter at the
field ‘Name’ "value1". Press the [Return] key.
ð
The cursor jumps to the column with the data type.
2. The data type may either directly be entered or be selected from
a list of available data types by pressing the [Return] key
. Set
the data type to INT and press the [Return] key.
ð
Now the cursor jumps to the ‘Comment’ column.
3. Here enter "1. compare value" and press the [Return] key
.
ð
A new ‘in
à
’ row is created and the cursor jumps to ‘Name’ .
4. Proceed for value2 in the same way as described for value1.
5. Save the block. A note that the interface of the block was
changed may be acknowledged with [Y
es].
ð
The parameter table shows the following entries, now:
Enter the program
As requested in the job definition, the corresponding output is acti-
vated depending on the comparison of value1 and value2. For each
comparison operation a separate network is to be created.
1. The program is to be created as FBD (function block diagram).
Here change to the FBD view by clicking at ‘FBD’ .
2. Click to the input field designated as "<empty>". The available
operations may be added to your project by drag&drop from the
hardware catalog or by double click at them in the hardware cat-
alog.
3. Open in the catalog the category "Comparator" and add the
operation ‘CMP==I’ to your network.
VIPA System 300SWinPLC7
Example project engineering > Project engineering
HB140 | CPU | 314-6CF03 | GB | 16-43 210