Iec 61131-3 Second edition 2003-01 Programmable controllers – Part 3: Programming languages


Table 27 - Standard selection functions


Download 1.35 Mb.
Pdf ko'rish
bet55/158
Sana17.06.2023
Hajmi1.35 Mb.
#1528208
1   ...   51   52   53   54   55   56   57   58   ...   158
Bog'liq
ourdev 569653

Table 27 - Standard selection functions
d
No.
Graphical form
Explanation/example
1
+-----+
| SEL |
BOOL--|G |--ANY
ANY---|IN0 |
ANY---|IN1 |
+-----+
Binary selection
c
:
OUT := IN0 if G = 0
OUT := IN1 if G = 1
EXAMPLE:
A := SEL(G:=0,IN0:=X,IN1:=5) ;
2a
+-----+
| MAX |
ANY_ELEMENTARY--| |--ANY_ELEMENTARY
: ---| |
ANY_ELEMENTARY--| |
+-----+
Extensible maximum function:
OUT := MAX (IN1,IN2, ...,INn)
EXAMPLE:
A := MAX(B,C,D) ;
2b
+-----+
| MIN |
ANY_ELEMENTARY--| |--ANY_ELEMENTARY
: ---| |
ANY_ELEMENTARY--| |
+-----+
Extensible minimum function:
OUT := MIN (IN1,IN2, ...,INn)
EXAMPLE:
A := MIN(B,C,D) ;
3
+-------+
| LIMIT |
ANY_ELEMENTARY--|MN |--ANY_ELEMENTARY
ANY_ELEMENTARY--|IN |
ANY_ELEMENTARY--|MX |
+-------+
Limiter:
OUT := MIN(MAX(IN,MN),MX)
EXAMPLE:
A := LIMIT(IN:=B,MN:=0,MX:=5);
4
e
+-----+
| MUX |
ANY_INT--|K |----ANY
ANY------| |
: ------| |
ANY------| |
+-----+
Extensible multiplexer 
a, b, c
:
Select one of N inputs
depending on input K
EXAMPLE:
A := MUX(0, B, C, D);
would have the same effect as
A := B ;
NOTE 1
The notations IN1, IN2, ..., INn refer to the inputs in top-to-bottom order; OUT refers
to the output.
NOTE 2
Usage examples and descriptions are given in the ST language defined in 3.3.

The unnamed inputs in the MUX function shall have the default names IN0, IN1,...,INn-1 in
top-to-bottom order, where n is the total number of these inputs. These names may, but need not,
be shown in the graphical representation.

The MUX function can be typed as defined in 2.5.1.4 in the form MUX_*_**, where * is the type
of the K input and ** is the type of the other inputs and the output.

It is allowed, but not required, that the manufacturer support selection among variables of derived
data types,
as defined in 2.3.3, in order to claim compliance with this feature.
d
It is an error if the inputs and the outputs to one of these functions are not all of the same actual
data type, with the exception of the G input of the SEL function and the K input of the MUX function.
e
It is an error if the actual value of the K input of the MUX function is not within the range {0..n-1}.
Copyright International Electrotechnical Commission 
Provided by IHS under license with IEC
Not for Resale
No reproduction or networking permitted without license from IHS
--``````-`-`,,`,,`,`,,`---


– 62 –
61131-3 
 IEC:2003(E)

Download 1.35 Mb.

Do'stlaringiz bilan baham:
1   ...   51   52   53   54   55   56   57   58   ...   158




Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling