BS EN 61131-3:2013
$215.11
Programmable controllers – Programming languages
Published By | Publication Date | Number of Pages |
BSI | 2013 | 234 |
IEC 61131-3:2013 specifies the syntax and semantics of a unified suite of programming languages for programmable controllers (PCs). This suite consists of two textual languages, Instruction List (IL) and Structured Text (ST), and two graphical languages, Ladder Diagram (LD) and Function Block Diagram (FBD). This third edition cancels and replaces the second edition, published in 2003 and constitutes a technical revision. It includes the following significant technical changes: It is a compatible extension of the second edition. The main extensions are new data types and conversion functions, references, name spaces and the object oriented features of classes and function blocks.
PDF Catalog
PDF Pages | PDF Title |
---|---|
6 | English CONTENTS |
11 | 1 Scope 2 Normative references 3 Terms and definitions |
20 | 4 Architectural models 4.1 Software model Figures Figure 1 โ Software model |
21 | 4.2 Communication model |
23 | Figure 3 โ Combination of programmable controller language elements |
24 | 5 Compliance 5.1 General 5.2 Feature tables 5.3 Implementerโs compliance statement |
25 | Figure 4 โ Implementerโs compliance statement (Example) |
26 | 6 Common elements 6.1 Use of printed characters 6.1.1 Character set 6.1.2 Identifiers 6.1.3 Keywords Tables Table 1 โ Character set Table 2 โ Identifiers |
27 | 6.1.4 Use of white space 6.1.5 Comments Table 3 โ Comments |
28 | 6.2 Pragma 6.3 Literals โ External representation of data 6.3.1 General 6.3.2 Numeric literals and string literals Table 4 โ Pragma |
29 | Table 5 โ Numeric literals |
30 | 6.3.3 Character string literals Table 6 โ Character string literals |
31 | 6.3.4 Duration literal Table 7 โ Two-character combinations in character strings Table 8 โ Duration literals |
32 | 6.3.5 Date and time of day literal 6.4 Data types 6.4.1 General 6.4.2 Elementary data types (BOOL, INT, REAL, STRING, etc.) Table 9 โ Date and time of day literals |
33 | Table 10 โ Elementary data types |
35 | 6.4.3 Generic data types |
36 | 6.4.4 User-defined data types Figure 5 โ Hierarchy of the generic data types |
37 | Figure 6 โ Initialization by literals and constant expressions (Rules) Table 11 โ Declaration of user-defined data types and initialization |
48 | Table 12 โ Reference operations |
49 | 6.5 Variables 6.5.1 Declaration and initialization of variables |
50 | Table 13 โ Declaration of variables |
51 | 6.5.2 Variable sections Table 14 โ Initialization of variables |
52 | Figure 7 โ Variable declaration keywords (Summary) |
53 | 6.5.3 Variable length ARRAY variables Figure 8 โ Usage of VAR_GLOBAL, VAR_EXTERNAL and CONSTANT (Rules) |
54 | Table 15 โ Variable-length ARRAY variables |
55 | 6.5.4 Constant variables |
56 | 6.5.5 Directly represented variables ( % ) Table 16 โ Directly represented variables |
58 | 6.5.6 Retentive variables (RETAIN, NON_RETAIN) |
59 | Figure 9 โ Conditions for the initial value of a variable (Rules) |
60 | 6.6 Program organization units (POUs) 6.6.1 Common features for POUs |
62 | Table 17 โ Partial access of ANY_BIT variables |
65 | Figure 10 โ Formal and non-formal representation of call (Examples) |
67 | Table 18 โ Execution control graphically using EN and ENO |
69 | Figure 11 โ Data type conversion rules โ implicit and/or explicit (Summary) |
70 | Figure 12 โ Supported implicit type conversions |
72 | 6.6.2 Functions |
74 | Table 19 โ Function declaration |
76 | Table 20 โ Function call |
78 | Table 21 โ Typed and overloaded functions |
80 | Table 22 โ Data type conversion function |
82 | Table 23 โ Data type conversion of numeric data types |
84 | Table 24 โ Data type conversion of bit data types |
85 | Table 25 โ Data type conversion of bit and numeric types |
87 | Table 26 โ Data type conversion of date and time types |
88 | Table 27 โ Data type conversion of character types |
89 | Table 28 โ Numerical and arithmetic functions |
90 | Table 29 โ Arithmetic functions |
91 | Table 30 โ Bit shift functions Table 31 โ Bitwise Boolean functions |
92 | Table 32 โ Selection functions d |
93 | Table 33 โ Comparison functions |
94 | Table 34 โ Character string functions |
95 | Table 35 โ Numerical functions of time and duration data types |
96 | Table 36 โ Additional functions of time data types CONCAT and SPLIT |
100 | Table 37 โ Function for endianess conversion Table 38 โ Functions of enumerated data types |
101 | 6.6.3 Function blocks Table 39 โ Validate functions |
102 | Table 40 โ Function block type declaration |
106 | Table 41 โ Function block instance declaration |
107 | Table 42 โ Function block call |
110 | Figure 13 โ Usage of function block input and output parameters (Rules) |
111 | Figure 14 โ Usage of function block input and output parameters (Illustration of rules) |
114 | Table 43 โ Standard bistable function blocksa |
115 | Table 44 โ Standard edge detection function blocks Table 45 โ Standard counter function blocks |
117 | Table 46 โ Standard timer function blocks |
118 | Figure 15 โ Standard timer function blocks โ timing diagrams (Rules) |
119 | 6.6.4 Programs Table 47 โ Program declaration |
120 | 6.6.5 Classes |
121 | Figure 16 โ Overview of inheritance and interface implementation |
122 | Table 48 โ Class |
124 | Table 49 โ Class instance declaration |
127 | Table 50 โ Textual call of methods โ Formal and non-formal parameter list |
130 | Figure 17 โ Inheritance of classes (Illustration) |
139 | 6.6.6 Interface Table 51 โ Interface |
140 | Figure 18 โ Interface with derived classes (Illustration) |
145 | Figure 19 โ Inheritance of interface and class (Illustration) |
148 | 6.6.7 Object oriented features for function blocks Table 52 โ Assignment attempt |
149 | Table 53 โ Object oriented function block |
151 | Figure 20 โ Function block with optional body and methods (Illustration) |
153 | Figure 21 โ Inheritance of function block body with SUPER() (Example) |
154 | 6.6.8 Polymorphism |
157 | 6.7 Sequential Function Chart (SFC) elements 6.7.1 General 6.7.2 Steps |
158 | Table 54 โ SFC step |
159 | 6.7.3 Transitions |
160 | Table 55 โ SFC transition and transition condition |
162 | 6.7.4 Actions Table 56 โ SFC declaration of actions |
164 | Table 57 โ Step/action association |
165 | Table 58 โ Action block Table 59 โ Action qualifiers |
167 | Figure 22 โ ACTION_CONTROL function block โ External interface (Summary) |
168 | Figure 23 โ ACTION_CONTROL function block body (Summary) |
170 | 6.7.5 Rules of evolution Figure 24 โ Action control (Example) Table 60 โ Action control features |
171 | Table 61 โ Sequence evolution โ graphical |
176 | Figure 25 โ SFC evolution (Rules) |
177 | Figure 26 โ SFC errors (Example) |
178 | 6.8 Configuration elements 6.8.1 General |
179 | Figure 27 โ Configuration (Example) |
180 | Table 62 โ Configuration and resource declaration |
182 | 6.8.2 Tasks Figure 28 โ CONFIGURATION and RESOURCE declaration (Example) |
184 | Table 63 โ Task |
188 | 6.9 Namespaces 6.9.1 General 6.9.2 Declaration |
191 | Figure 29 โ Accessibility using namespaces (Rules) |
193 | Table 64 โ Namespace |
194 | 6.9.3 Usage 6.9.4 Namespace directive USING Table 65 โ Nested namespace declaration options |
196 | Table 66 โ Namespace directive USING |
197 | 7 Textual languages 7.1 Common elements 7.2 Instruction list (IL) 7.2.1 General 7.2.2 Instructions Figure 30 โ Common textual elements (Summary) |
198 | 7.2.3 Operators, modifiers and operands |
199 | Table 67 โ Parenthesized expression for IL language Table 68 โ Instruction list operators |
200 | 7.2.4 Functions and function blocks |
201 | Table 69 โ Calls for IL language |
203 | 7.3 Structured Text (ST) 7.3.1 General 7.3.2 Expressions Table 70 โ Standard function block operators for IL language |
204 | Table 71 โ Operators of the ST language |
205 | 7.3.3 Statements Table 72 โ ST language statements |
210 | 8 Graphic languages 8.1 Common elements 8.1.1 General |
211 | 8.1.2 Representation of variables and instances |
213 | 8.1.3 Representation of lines and blocks |
214 | 8.1.4 Direction of flow in networks |
215 | 8.1.5 Evaluation of networks |
216 | 8.1.6 Execution control elements |
217 | 8.2 Ladder diagram (LD) 8.2.1 General Table 73 โ Graphic execution control elements |
218 | 8.2.2 Power rails 8.2.3 Link elements and states 8.2.4 Contacts Table 74 โ Power rails and link elements |
219 | Table 75 โ Contacts |
220 | 8.2.5 Coils Table 76 โ Coils |
221 | 8.2.6 Functions and function blocks 8.2.7 Order of network evaluation 8.3 Function Block Diagram (FBD) 8.3.1 General 8.3.2 Combination of elements |
222 | 8.3.3 Order of network evaluation |
223 | Annex A (normative) Formal specification of the languages elements |
230 | Annex B (informative) List of major changes and extensions of the third edition |
231 | Bibliography |