Iec 61131-3 Second edition 2003-01 Programmable controllers – Part 3: Programming languages
Table 28 - Standard comparison functions
Download 1.35 Mb. Pdf ko'rish
|
ourdev 569653
- Bu sahifa navigatsiya:
- 2.5.1.5.5 Character string functions
Table 28 - Standard comparison functions
Graphical form Usage examples +-----+ ANY_ELEMENTARY --| *** |--- BOOL : --| | ANY_ELEMENTARY --| | +-----+ (***) - Name or Symbol A := GT(B,C,D) ; or A := (B>C) & (C>D) ; No. Name a Symbol b Description 5 GT > Decreasing sequence: OUT := (IN1>IN2) & (IN2>IN3) & ... & (INn-1 > INn) 6 GE >= Monotonic sequence: OUT := (IN1>=IN2)&(IN2>=IN3)& ... & (INn-1 >= INn) 7 EQ = Equality: OUT := (IN1=IN2) & (IN2=IN3) & ... & (INn-1 = INn) 8 LE <= Monotonic sequence: OUT := (IN1<=IN2)&(IN2<=IN3)& ... & (INn-1 <= INn) 9 LT < Increasing sequence: OUT := (IN1 NE <> Inequality (non-extensible) OUT := (IN1 <> IN2) NOTE 1 The notations IN1, IN2, ..., INn refer to the inputs in top-to-bottom order; OUT refers to the output. NOTE 2 All the symbols shown in this table are suitable for use as operators in textual languages, as shown in tables 52 and 55. NOTE 3 Usage examples and descriptions are given in the ST language defined in 3.3. a When the named representation of a function is supported, this shall be indicated by the suffix “n” in the compliance statement. For example, “5n” represents the notation “GT”. b When the symbolic representation of a function is supported, this shall be indicated by the suffix “s” in the compliance statement. For example, “5s” represents the notation “>“. 2.5.1.5.5 Character string functions All the functions defined in 2.5.1.5.4 shall be applicable to character strings. For the purposes of comparison of two strings of unequal length, the shorter string shall be considered to be extended on the right to the length of the longer string by characters with the value zero. Comparison shall proceed from left to right, based on the numeric value of the character codes in the character set defined in 2.1.1. For example, the character string 'Z' shall be greater than the character string 'AZ', and 'AZ' shall be greater than 'ABC'. The standard graphical representations, function names and descriptions of additional functions of character strings shall be as shown in table 29. For the purpose of these operations, character positions within the string shall be considered to be numbered 1,2,...,L, beginning with the leftmost character position, where L is the length of the string. Copyright International Electrotechnical Commission Provided by IHS under license with IEC Not for Resale No reproduction or networking permitted without license from IHS --``````-`-`,,`,,`,`,,`--- 61131-3 IEC:2003(E) – 63 – It shall be an error if: - the actual value of any input designated as ANY_INT in table 29 is less than zero; - evaluation of the function results in an attempt to (1) access a non-existent character position in a string, or (2) produce a string longer than the implementation-dependent maximum string length. Download 1.35 Mb. Do'stlaringiz bilan baham: |
Ma'lumotlar bazasi mualliflik huquqi bilan himoyalangan ©fayllar.org 2024
ma'muriyatiga murojaat qiling
ma'muriyatiga murojaat qiling