1、BSI Standards PublicationIndustrial communication networks Fieldbus specificationsPart 4-21: Data-link layer protocol specification Type 21 elementsBS EN 61158-4-21:2012Incorporating corrigendum June 2013National forewordThis British Standard is the UK implementation of EN 61158-4-21:2012. It is ide
2、ntical to IEC 61158-4-21:2010. Together with BS EN 61158-3-21:2012, BS EN 61158-5-21:2012 and BS EN 61158-6-21:2012, it supersedes DD IEC/PAS 62573:2008, which is withdrawn.The UK participation in its preparation was entrusted to Technical Com-mittee AMT/7, Industrial communications: process measure
3、ment and control, including fieldbus.A list of organizations represented on this committee can be obtained on request to its secretary.This publication does not purport to include all the necessary provisions of a contract. Users are responsible for its correct application. The British Standards Ins
4、titution 2013.Published by BSI Standards Limited 2013ISBN 978 0 580 79704 0 ICS 25.040.40; 33.040.40; 35.100.20Compliance with a British Standard cannot confer immunity from legal obligations.This British Standard was published under the authority of the Standards Policy and Strategy Committee on 30
5、 June 2012.Amendments/corrigenda issued since publicationDate Text affectedBRITISH STANDARDBS EN 61158-4-21:201231 July 2013 Correction to supersession information in the national forewordEUROPEAN STANDARD EN 61158-4-21 NORME EUROPENNE EUROPISCHE NORM May 2012 CENELEC European Committee for Electrot
6、echnical Standardization Comit Europen de Normalisation Electrotechnique Europisches Komitee fr Elektrotechnische Normung Management Centre: Avenue Marnix 17, B - 1000 Brussels 2012 CENELEC - All rights of exploitation in any form and by any means reserved worldwide for CENELEC members. Ref. No. EN
7、61158-4-21:2012 E ICS 25.040.40; 35.100.20; 35.110 English version Industrial communication networks - Fieldbus specifications - Part 4-21: Data-link layer protocol specification - Type 21 elements (IEC 61158-4-21:2010) Rseaux de communication industriels - Spcifications des bus de terrain - Partie
8、4-21: Spcification du protocole de la couche de liaison de donnes - Elments de Type 21 (CEI 61158-4-21:2010) Industrielle Kommunikationsnetze - Feldbusse - Teil 4-21: Protokollspezifikation des Data Link Layer (Sicherungsschicht) - Typ 21-Elemente (IEC 61158-4-21:2010) This European Standard was app
9、roved by CENELEC on 2012-03-28. CENELEC members are bound to comply with the CEN/CENELEC Internal Regulations which stipulate the conditions for giving this European Standard the status of a national standard without any alteration. Up-to-date lists and bibliographical references concerning such nat
10、ional standards may be obtained on application to the CEN-CENELEC Management Centre or to any CENELEC member. This European Standard exists in three official versions (English, French, German). A version in any other language made by translation under the responsibility of a CENELEC member into its
11、own language and notified to the CEN-CENELEC Management Centre has the same status as the official versions. CENELEC members are the national electrotechnical committees of Austria, Belgium, Bulgaria, Croatia, Cyprus, the Czech Republic, Denmark, Estonia, Finland, France, Germany, Greece, Hungary, I
12、celand, Ireland, Italy, Latvia, Lithuania, Luxembourg, Malta, the Netherlands, Norway, Poland, Portugal, Romania, Slovakia, Slovenia, Spain, Sweden, Switzerland, Turkey and the United Kingdom. BS EN 61158-4-21:2012EN 61158-4-21:2012 - 2 - Foreword The text of document 65C/605/FDIS, future edition 1
13、of IEC 61158-4-21, prepared by SC 65C, “Industrial networks“, of IEC/TC 65, “Industrial-process measurement, control and automation“ was submitted to the IEC-CENELEC parallel vote and approved by CENELEC as EN 61158-4-21:2012. The following dates are fixed: latest date by which the document has to b
14、e implemented at national level by publication of an identical national standard or by endorsement (dop) 2012-12-28 latest date by which the national standards conflicting with the document have to be withdrawn (dow) 2015-03-28 Attention is drawn to the possibility that some of the elements of this
15、document may be the subject of patent rights. CENELEC and/or CEN shall not be held responsible for identifying any or all such patent rights. Endorsement notice The text of the International Standard IEC 61158-4-21:2010 was approved by CENELEC as a European Standard without any modification. In the
16、official version, for Bibliography, the following notes have to be added for the standards indicated: IEC/TR 61158-1:2010 NOTE Harmonized as CLC/TR 61158-1:2010 (not modified). IEC 61158-2:2010 NOTE Harmonized as EN 61158-2:2010 (not modified). IEC 61158-5-21:2010 NOTE Harmonized as EN 61158-5-21:20
17、12 (not modified). IEC 61158-6-21:2010 NOTE Harmonized as EN 61158-6-21:2012 (not modified). BS EN 61158-4-21:2012- 3 - EN 61158-4-21:2012 Annex ZA (normative) Normative references to international publications with their corresponding European publications The following documents, in whole or in pa
18、rt, are normatively referenced in this document and are indispensable for its application. For dated references, only the edition cited applies. For undated references, the latest edition of the referenced document (including any amendments) applies. NOTE When an international publication has been m
19、odified by common modifications, indicated by (mod), the relevant EN/HD applies. Publication Year Title EN/HD Year IEC 61158-3-21 2010 Industrial communication networks - Fieldbus specifications - Part 3-21: Data-link layer service definition - Type 21 elements EN 61158-3-21 2012 ISO/IEC 7498-1 - In
20、formation technology - Open Systems Interconnection - Basic Reference Model: The Basic Model - - ISO/IEC 7498-3 - Information technology - Open Systems Interconnection - Basic Reference Model: Naming and addressing - - ISO/IEC 8802-3 2000 Information technology - Telecommunications and information e
21、xchange between systems - Local and metropolitan area networks - Specific requirements - Part 3: Carrier sense multiple access with collision detection (CSMA/CD) access method and physical layer specifications - - ISO/IEC 10731 1994 Information technology - Open Systems Interconnection - Basic refer
22、ence model - Conventions for the definition of OSI services - - BS EN 61158-4-21:2012 2 61158-4-21 IEC:2010(E) CONTENTS INTRODUCTION.8 1 Scope.10 1.1 General .10 1.2 Specifications10 1.3 Procedures10 1.4 Applicability.10 1.5 Conformance.11 2 Normative references .11 3 Terms, definitions, symbols and
23、 abbreviations11 3.1 Reference model terms and definitions11 3.2 Service convention terms and definitions.13 3.3 Common terms and definitions 14 3.4 Symbols and abbreviations17 4 Overview of the data-link protocol.18 4.1 General .18 4.2 Overview of medium access control 18 4.3 Service assumed from t
24、he physical layer.19 4.4 DLL architecture19 4.5 Data type 21 4.6 Local parameters and variables.23 5 General structure and encoding38 5.1 Overview .38 5.2 MAPDU structure and encoding.38 5.3 Common MAC frame structure, encoding and elements of procedure 39 5.4 Order of bit transmission .47 5.5 Inval
25、id DLPDU.47 6 DLPDU structure and procedure .48 6.1 General .48 6.2 Common DLPDU Field 48 6.3 DL-DATA Transfer.48 6.4 DL-SPDATA Transfer 51 6.5 Network control messages 53 7 DLE elements of procedure 59 7.1 Overall structure59 7.2 DL-protocol machine (DLPM) 59 7.3 DLL management Protocol 69 8 Consta
26、nts and error codes .102 8.1 General .102 8.2 Constants102 8.3 Data-link layer error codes 104 Bibliography105 Figure 1 Relationships of DLSAPs, DLSAP-addresses, and group DL-addresses.15 Figure 2 Interaction of PhS primitives with DLE19 BS EN 61158-4-21:201261158-4-21 IEC:2010(E) 3 Figure 3 Data-li
27、nk layer architecture 20 Figure 4 Common MAC frame format for Type 21 DLPDU39 Figure 5 MAC frame format for other protocols.39 Figure 6 Version and Length field 40 Figure 7 DST_addr field.41 Figure 8 SRC_addr field.42 Figure 9 Frame Control Field .43 Figure 10 Extension field .45 Figure 11 DSAP fiel
28、d .46 Figure 12 Source service access point field .46 Figure 13 Length of group mask and extension information47 Figure 14 Group mask option field .47 Figure 15 Common DLPDU field 48 Figure 16 Building a DT DLPDU.49 Figure 17 DT DLPDU structure 49 Figure 18 SPDT DLPDU structure 52 Figure 19 NCM_LA D
29、LPDU structure .54 Figure 20 DLL structure and elements .59 Figure 21 State transition diagram of the DLPM .63 Figure 22 State transition diagram of DLM .73 Table 1 DLL components .20 Table 2 UNSIGNEDn data type .22 Table 3 INTEGERn data type.23 Table 4 DLE configuration parameters .24 Table 5 Queue
30、s to support data transfer 25 Table 6 Variables to support SAP management .26 Table 7 Variables to support device information management26 Table 8 DLentity identifier 27 Table 9 Device Flags .27 Table 10 DLM state27 Table 11 Device Unique Identification 28 Table 12 Unique identification of device co
31、nnected to R-port1 .28 Table 13 Unique identification of device connected to R-port2 .28 Table 14 MAC address.28 Table 15 Port information.29 Table 16 Protocol version 29 Table 17 Device type .30 Table 18 Device description.30 Table 19 Hop count30 Table 20 Variables to support managing network infor
32、mation.31 Table 21 Topology .31 Table 22 Collision count.31 BS EN 61158-4-21:2012 4 61158-4-21 IEC:2010(E) Table 23 Device count .32 Table 24 Topology change count .32 Table 25 Last topology change time.32 Table 26 RNMP device UID .32 Table 27 RNMS device UID .33 Table 28 LNM device UID for R-port1
33、33 Table 29 LNM device UID for R-port2 33 Table 30 Network flags 34 Table 31 Variables and counter to support managing path information.35 Table 32 Hop count for R-port1 direction36 Table 33 Hop count for R-port2 direction36 Table 34 Preferred R-port 36 Table 35 Destination R-port .36 Table 36 In ne
34、t count .37 Table 37 In net time .37 Table 38 Out net count 38 Table 39 Out net time 38 Table 40 Version and Length .41 Table 41 Destination DLentity identifier41 Table 42 Source DLentity identifier 42 Table 43 Frame control43 Table 44 Extension 45 Table 45 Destination service access point .46 Table
35、 46 source service access point.46 Table 47 DT DLPDU parameters49 Table 48 Primitives exchanged between DLS-user and DLE to send a DT DLPDU.51 Table 49 Primitives exchanged between DLS-user and DLEs to receive a DT DLPDU .51 Table 50 SPDT DLPDU Parameters.52 Table 51 Primitive exchanged between DLS-
36、User and DLEs to send an SPDT DLPDU .53 Table 52 Primitives exchanged between DLS-user and DLEs to receive an SPDT DLPDU .53 Table 53 NCM_LA DLPDU parameters.54 Table 54 NCM_AT DLPDU parameters 55 Table 55 NCM_LS DLPDU parameters.56 Table 56 NCM_RS DLPDU parameters 57 Table 57 NCM_AR DLPDU parameter
37、s 58 Table 58 Primitives exchanged between DLPM and DLS-user60 Table 59 Parameters exchanged between DLPM and DLS-user.61 Table 60 Primitives exchanged between DLPM and DLM .62 Table 61 Parameters used with primitives exchanged between DLPM and DLM.63 Table 62 DLPM state table.64 Table 63 DLPM funct
38、ions table 68 Table 64 Primitives exchanged between DLM and DLS-user70 BS EN 61158-4-21:201261158-4-21 IEC:2010(E) 5 Table 65 Parameters used with primitives exchanged between DLM and DLS-user71 Table 66 Primitive exchanged between DLM and DMAC 71 Table 67 Parameters used with primitives exchanged b
39、etween DLM and DMAC 72 Table 68 Primitive exchanged between DLM and DPHY.72 Table 69 Parameters used with primitives exchanged between DLM and DPHY.72 Table 70 DLM state table .75 Table 71 DLM function table 100 Table 72 DLL constants .103 Table 73 Type 21 DLL error codes .104 BS EN 61158-4-21:2012
40、8 61158-4-21 IEC:2010(E) INTRODUCTION This part of IEC 61158 is one of a series produced to facilitate the interconnection of automation system components. It is related to other standards in the set as defined by the “three-layer” fieldbus reference model described in IEC/TR 61158-1. The data-link
41、protocol provides the data-link service by making use of the services available from the physical layer. The primary aim of this standard is to provide a set of rules for communication expressed in terms of the procedures to be carried out by peer data-link entities (DLEs) at the time of communicati
42、on. These rules for communication are intended to provide a sound basis for development in order to serve a variety of purposes: a) as a guide for implementors and designers; b) for use in the testing and procurement of equipment; c) as part of an agreement for the admittance of systems into the ope
43、n systems environment; d) as a refinement to the understanding of time-critical communications within OSI. This standard is concerned, in particular, with the communication and interworking of sensors, effectors and other automation devices. By using this standard together with other standards posit
44、ioned within the OSI or fieldbus reference models, otherwise incompatible systems may work together in any combination. NOTE Use of some of the associated protocol types is restricted by their intellectual-property-right holders. In all cases, the commitment to limited release of intellectual-proper
45、ty-rights made by the holders of those rights permits a particular data-link layer protocol type to be used with physical layer and application layer protocols in type combinations as specified explicitly in the profile parts. Use of the various protocol types in other combinations may require permi
46、ssion of their respective intellectual-property-right holders. The International Electrotechnical Commission (IEC) draws attention to the fact that it is claimed that compliance with this document may involve the use of patents concerning Type 21 elements and possibly other types given in subclause
47、4.1, 4.2 and 7.3 as follows: KR 0789444 LS A communication packet processing apparatus and method for ring topology ethernet network capable of preventing permanent packet looping KR 0732510 LS Network system KR 0870670 LS Method for determining a Ring Manager Node IEC takes no position concerning t
48、he evidence, validity and scope of these patent rights. The holder of these patent rights has assured the IEC that he/she is willing to negotiate licences either free of charge or under reasonable and non-discriminatory terms and conditions with applicants throughout the world. In this respect, the
49、statement of the holder of these patent rights is registered with IEC. Information may be obtained from: LS: LS Industrial Systems Co., Ltd. LS Tower 1026-6 Hogye-dong, Dongan-gu, Anyang-si, Gyeonggi-do 431-848 Republic of Korea Attention is drawn to the possibility that some of the elements of this document may be the subject of