1、 IEC 61588 Edition 2.0 2009-02 INTERNATIONAL STANDARD Precision clock synchronization protocol for networked measurement and control systems IEC 61588:2009(E) IEEE Std. 1588(E):2008 IEEE 1588 THIS PUBLICATION IS COPYRIGHT PROTECTED Copyright 2008 IEEE All rights reserved. IEEE is a registered tradem
2、ark in the U.S. Patent 35.110, 35.240.50 PRICE CODE ISBN 2-8318-1026-3IEEE 1588 Foreword.xi IEEE introduction. xiv 1. Overview 1 1.1 Scope . 1 1.2 Purpose 2 1.3 Layout of the document. 2 2. Normative references 3 3. Definitions, acronyms, and abbreviations 4 3.1 Definitions . 4 3.2 Acronyms and abbr
3、eviations . 7 4. Conventions 8 4.1 Descriptive lexical form syntax . 8 4.2 Word usage 9 4.3 Behavioral specification notation 10 5. Data types and on-the-wire formats in a PTP system. 11 5.1 General 11 5.2 Primitive data type specifications 11 5.3 Derived data type specifications 12 5.4 On-the-wire
4、formats 15 6. Clock synchronization model . 16 6.1 General 16 6.2 Principle assumptions about the network and implementation recommendations. 16 6.3 PTP systems. 17 6.4 PTP message classes 17 6.5 PTP device types . 18 6.6 Synchronization overview . 29 6.7 PTP communications overview . 37 7. Characte
5、rization of PTP entities . 41 7.1 Domains. 41 7.2 PTP timescale 41 7.3 PTP communications. 42 7.4 PTP communication media 46 7.5 PTP ports . 47 7.6 PTP device characterization 53 7.7 PTP timing characterization 61 8. PTP data sets 63 8.1 General specifications for data set members . 63 8.2 Data sets
6、 for ordinary and boundary clocks. 65 8.3 Data sets for transparent clocks . 74 9. PTP for ordinary and boundary clocks . 76 9.1 General protocol requirements for PTP ordinary and boundary clocks. 76 9.2 State protocol. 76 9.3 Best master clock algorithm 83 9.4 Grandmaster clocks . 92 9.5 Message pr
7、ocessing semantics 93 9.6 Changes in the local clock . 107 10. PTP for transparent clocks 107 10.1 General requirements for both end-to-end and peer-to-peer transparent clocks 107 10.2 End-to-end transparent clock requirements . 108 CONTENTS Published by IEC under licence from IEEE. 2008 IEEE. All r
8、ights reserved. IEC 61588:2009(E) IEEE 1588-2008(E) i 10.3 Peer-to-peer transparent clock requirements 108 11. Clock offset, path delay, residence time, and asymmetry corrections 108 11.1 General specifications 108 11.2 Computation of clock offset in ordinary and boundary clocks 109 11.3 Delay reque
9、st-response mechanism. 110 11.4 Peer delay mechanism . 112 11.5 Transparent clock residence time correction for PTP version 2 events . 117 11.6 Asymmetry correction for PTP version 2 event messages. 120 12. Synchronization and syntonization of clocks . 122 12.1 Syntonization. 122 12.2 Synchronizatio
10、n. 123 13. PTP message formats . 124 13.1 General 124 13.2 General message format requirements. 124 13.3 Header 124 13.4 Suffix . 128 13.5 Announce message 128 13.6 Sync and Delay_Req messages 130 13.7 Follow_Up message 130 13.8 Delay_Resp message . 130 13.9 Pdelay_Req message . 131 13.10 Pdelay_Res
11、p message 131 13.11 Pdelay_Resp_Follow_Up message 132 13.12 Signaling message . 132 13.13 Management message 133 14. TLV entity specifications . 133 14.1 General requirements. 133 14.2 Experimental TLVs . 134 14.3 Vendor and standard organization extension TLVs. 135 15. Management . 135 15.1 General
12、 135 15.2 PTP management mechanism 136 15.3 Processing of management messages 136 15.4 Management message format 137 15.5 Management TLVs 138 16. General optional features 158 16.1 Unicast message negotiation (optional). 158 16.2 Path trace (optional). 163 16.3 Alternate timescales (optional) 165 17
13、. State configuration options. 169 17.1 General 169 17.2 Data types for options 169 17.3 Grandmaster clusters (optional). 170 17.4 Alternate master (optional) 172 17.5 Unicast discovery (optional) 173 17.6 Acceptable master table (optional) 175 18. Compatibility requirements 177 18.1 Compatibility b
14、etween version 2 and future versions 177 18.2 Compatibility between version 1 and version 2. 177 18.3 Message formats and data types 178 18.4 Naming changes 183 18.5 Restrictions on mixed version 1 and version 2 systems. 183 Published by IEC under licence from IEEE. 2008 IEEE. All rights reserved. I
15、EC 61588:2009(E) IEEE 1588-2008(E) ii ii 19. Conformance 184 19.1 Conformance objective 184 19.2 PTP conformance requirements. 184 19.3 PTP profiles . 185 Annex A (informative) Using PTP. 187 Annex B (informative) Timescales and epochs in PTP19 7 Annex C (informative) Examples of residence and asymm
16、etry corrections. 200 Annex D (normative) Transport of PTP over User Datagram Protocol over Internet Protocol Version 4 . 219 Annex E (normative) Transport of PTP over User Datagram Protocol over Internet Protocol Version 6 221 Annex F (normative) Transport of PTP over IEEE 802.3 /Ethernet. 223 Anne
17、x G (normative) Transport of PTP over DeviceNET . 225 Annex H (normative) Transport of PTP over ControlNET 228 Annex I (normative) Transport of PTP over IEC 61158 Type 10 230 Annex J (normative) Default PTP profiles . 237 Annex K (informative) Security protocol (experimental) 24 1 Annex L (informati
18、ve) Transport of cumulative frequency scale factor offset (experimental) 264 Annex M (informative) Bibliography. 268 Annex N (informative) List of partcipants. 270 Published by IEC under licence from IEEE. 2008 IEEE. All rights reserved. IEC 61588:2009(E) IEEE 1588-2008(E) iii TABLES Table 1 Primiti
19、ve PTP data types . 12 Table 2 domainNumber 41 Table 3 networkProtocol enumeration . 46 Table 4 Non-EUI-64 addressTechnology enumeration 51 Table 5 clockClass specifications. 55 Table 6 clockAccuracy enumeration 56 Table 7 timeSource enumeration 57 Table 8 PTP state enumeration.73 Table 9 Delay mech
20、anism enumeration . 74 Table 10 PTP portState definition 77 Table 11 Event applicability in boundary clocks 83 Table 12 Information sources for data set comparison algorithm 88 Table 13 Updates for state decision code M1 and M2 . 91 Table 14 Updates for state decision code M3. 91 Table 15 Updates fo
21、r state decision code P1, and P2 . 91 Table 16 Updates for state decision code S1 92 Table 17 Source identity comparisons 95 Table 18 Common message header 124 Table 19 Values of messageType field. 125 Table 20 Values of flagField 126 Table 21 correctionField semantics 127 Table 22 References for se
22、quenceId value exceptions . 127 Table 23 controlField enumeration. 128 Table 24 Values of logMessageInterval field. 128 Table 25 Announce message fields 129 Table 26 Sync and Delay_Req message fields . 130 Table 27 Follow_Up message fields 130 Table 28 Delay_Resp message fields . 130 Table 29 Pdelay
23、_Req message fields . 131 Table 30 Pdelay_Resp message fields 131 Table 31 Pdelay_Resp_Follow_Up message fields 132 Table 32 Acceptance of signaling messages 132 Table 33 Signaling message fields . 133 Published by IEC under licence from IEEE. 2008 IEEE. All rights reserved. IEC 61588:2009(E) IEEE 1
24、588-2008(E) ivTable 34 tlvType values . 134 Table 35 Organization specific TLV fields 135 Table 36 Acceptance of management messages. 136 Table 37 Management message fields 137 Table 38 Values of the actionField. 138 Table 39 Management TLV fields 139 Table 40 managementId values 140 Table 41 CLOCK_
25、DESCRIPTION management TLV data field 141 Table 42 clockType specification. 142 Table 43 USER_DESCRIPTION management TLV data field . 144 Table 44 INITIALIZE management TLV data field 145 Table 45 INITIALIZATION_KEY enumeration . 145 Table 46 Fault log severityCode enumeration 145 Table 47 FAULT_LOG
26、 management TLV data field 146 Table 48 TIME management TLV data field . 147 Table 49 CLOCK_ACCURACY management TLV data field . 147 Table 50 DEFAULT_DATA_SET management TLV data field. 148 Table 51 PRIORITY1 management TLV data field. 148 Table 52 PRIORITY2 management TLV data field. 149 Table 53 D
27、OMAIN management TLV data field. 149 Table 54 SLAVE_ONLY management TLV data field . 149 Table 55 CURRENT_DATA_SET management TLV data field 149 Table 56 PARENT_DATA_SET management TLV data field . 150 Table 57 TIME_PROPERTIES_DATA_SET management TLV data field 151 Table 58 UTC_PROPERTIES management
28、 TLV data field 152 Table 59 TRACEABILITY_PROPERTIES management TLV data field. 152 Table 60 TIMESCALE_PROPERTIES management TLV data field . 152 Table 61 PORT_DATA_SET management TLV data field. 153 Table 62 LOG_ANNOUNCE_INTERVAL management TLV data field. 154 Table 63 ANNOUNCE_RECEIPT_TIMEOUT mana
29、gement TLV data field. 154 Table 64 LOG_SYNC_INTERVAL management TLV data field 154 Table 65 DELAY_MECHANISM management TLV data field . 155 Table 66 LOG_MIN_PDELAY_REQ_INTERVAL management TLV data field 155 Table 67 VERSION_NUMBER management TLV data field. 155 Table 68 TRANSPARENT_CLOCK_DEFAULT_DA
30、TA_SET management TLV data field. 156 Published by IEC under licence from IEEE. 2008 IEEE. All rights reserved. IEC 61588:2009(E) IEEE 1588-2008(E) v Table 69 PRIMARY_DOMAIN management TLV data field. 156 Table 70 TRANSPARENT_CLOCK_PORT_DATA_SET management TLV data field. 157 Table 71 MANAGEMENT_ERR
31、OR_STATUS TLV format 157 Table 72 managementErrorId enumeration 158 Table 73 REQUEST_UNICAST_TRANSMISSION TLV format 160 Table 74 GRANT_UNICAST_TRANSMISSION TLV format 161 Table 75 CANCEL_UNICAST_TRANSMISSION TLV format 161 Table 76 ACKNOWLEDGE_CANCEL_UNICAST_TRANSMISSION TLV format . 162 Table 77 U
32、NICAST_NEGOTIATION_ENABLE management TLV data field . 162 Table 78 PATH_TRACE TLV format . 164 Table 79 PATH_TRACE_LIST management TLV data field . 164 Table 80 PATH_TRACE_ENABLE management TLV data field 164 Table 81 ALTERNATE_TIME_OFFSET_INDICATOR TLV format . 166 Table 82 ALTERNATE_TIME_OFFSET_EN
33、ABLE management TLV data field 167 Table 83 ALTERNATE_TIME_OFFSET_NAME management TLV data field 167 Table 84 ALTERNATE_TIME_OFFSET_MAX_KEY management TLV data field 168 Table 85 ALTERNATE_TIME_OFFSET_PROPERTIES management TLV data field 168 Table 86 GRANDMASTER_CLUSTER_TABLE management TLV data fie
34、ld 171 Table 87 Alternate master attributes. 173 Table 88 ALTERNATE_MASTER management TLV data field 173 Table 89 UNICAST_MASTER_TABLE management TLV data field. 174 Table 90 UNICAST_MASTER_MAX_TABLE_SIZE management TLV data field . 175 Table 91 Operation of acceptable master table option . 176 Tabl
35、e 92 ACCEPTABLE_MASTER_TABLE management TLV data field. 176 Table 93 ACCEPTABLE_MASTER_MAX_TABLE_SIZE management TLV data field. 177 Table 94 ACCEPTABLE_MASTER_TABLE_ENABLED management TLV data field 177 Table 95 Version 1 stratum to version 2 class 178 Table 96 Version 2 clockClass to version 1 str
36、atum 178 Table 97 Version 1 to version 2 translation of grandmasterIsPreferred field. 179 Table 98 Version 2 to version 1 translation of the priority1 field 179 Table 99 Version 1 clock identifier to version 2 clockAccuracy 179 Table 100 Version 2 clockAccuracy to version 1 clock identifier. 179 Tab
37、le 101 Version 1 to version 2 translation of grandmasterIsBoundaryClock field 180 Table 102 Version 2 to version 1 translation of the priority2 field 180 Table 103 Version 1 control field and version 2 messageType field mappings 180 Table 104 Translation of flagField from version 1 to version 2 181
38、Published by IEC under licence from IEEE. 2008 IEEE. All rights reserved. IEC 61588:2009(E) IEEE 1588-2008(E) vi Table 105 Translation of flagField from version 2 to version 1 181 Table 106 Version 2 fields with no version 1 counterpart. 182 Table 107 Version 1 fields with no version 2 counterpart.
39、183 Table 108 Name correspondence. 183 Table 109 Mixed system restrictions. 184 Table B.1 Relationships between timescales. 199 Table C.1 Interpretation of Figure C.1 key values 202 Table C.2 Interpretation of Figure C.2 key values 203 Table C.3 Interpretation of Figure C.3 key values 205 Table C.4
40、Interpretation of Figure C.4 key values 207 Table C.5 Interpretation of Figure C.5 key values 209 Table C.6Interpretation of Figure C.6 key values 210 Table C.7Interpretation of Figure C.7 key values 211 Table C.8Interpretation of Figure C.8 key values 213 Table C.9Interpretation of Figure C.9 key v
41、alues 215 Table C.10Interpretation of Figure C.10 key values. 217 Table C.11Interpretation of Figure C.11 key values. 218 Table D.1 IPv4 multicast addresses. 219 Table D.2 transportSpecific field values . 220 Table E.1 IPv6 multicast addresses . 222 Table F.1 Multicast MAC addresses . 223 Table F.2
42、Ethernet transport specific field.22 4 Table G.1 DeviceNet clockIdentity octets 0 through 7 226 Table G.2 DeviceNet headers for all PTP message packets 226 Table H.1 ControlNet clockIdentity octets 2 through 7. 228 Table I.1 Mapping of messages. 231 Table I.2 IEEE 802.3 DLPDU syntax . 232 Table I.3
43、Multicast MAC address 233 Table I.4 LT (Length/Type). 234 Table I.6 Mapping of the parameter and attribute names 235 Table I.7 Translation of flagField from PTP version 2 to PROFINET 236 Table K.1 flagField.SECURE flag 242 Table K.2 AUTHENTICATION TLV 260 Table K.3 algorithmId values 261 Table K.4 ICV and pad length. 261 Table K.5 AUTHENTICATION_CHALLENGE TLV 262 Published by IEC under licence from IEEE. 2008 IEEE. All rights reserved. IEC 61588:2009(E) IEEE 1588-2008(E) vii