DE10191695B4 - Method and communication control unit for multimaster clock synchronization in a distributed real-time computer system - Google Patents

Method and communication control unit for multimaster clock synchronization in a distributed real-time computer system Download PDF

Info

Publication number
DE10191695B4
DE10191695B4 DE10191695T DE10191695T DE10191695B4 DE 10191695 B4 DE10191695 B4 DE 10191695B4 DE 10191695 T DE10191695 T DE 10191695T DE 10191695 T DE10191695 T DE 10191695T DE 10191695 B4 DE10191695 B4 DE 10191695B4
Authority
DE
Germany
Prior art keywords
time
master
slave
local
synchronization
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Lifetime
Application number
DE10191695T
Other languages
German (de)
Other versions
DE10191695D2 (en
Inventor
Hermann Kopetz
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Tttech Computertechnik AG
Original Assignee
FTS Computertechnik GmbH
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by FTS Computertechnik GmbH filed Critical FTS Computertechnik GmbH
Publication of DE10191695D2 publication Critical patent/DE10191695D2/en
Application granted granted Critical
Publication of DE10191695B4 publication Critical patent/DE10191695B4/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04JMULTIPLEX COMMUNICATION
    • H04J3/00Time-division multiplex systems
    • H04J3/02Details
    • H04J3/06Synchronising arrangements
    • H04J3/0635Clock or time synchronisation in a network
    • H04J3/0638Clock or time synchronisation among nodes; Internode synchronisation
    • H04J3/0658Clock or time synchronisation among packet nodes
    • H04J3/0661Clock or time synchronisation among packet nodes using timestamps
    • H04J3/0664Clock or time synchronisation among packet nodes using timestamps unidirectional timestamps
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F1/00Details not covered by groups G06F3/00 - G06F13/00 and G06F21/00
    • G06F1/04Generating or distributing clock signals or signals derived directly therefrom
    • G06F1/14Time supervision arrangements, e.g. real time clock

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Synchronisation In Digital Transmission Systems (AREA)
  • Multi Processors (AREA)

Abstract

Verfahren zum Aufbau einer globalen Zeitbasis in einem verteilten Echtzeitcomputersystem bestehend aus einer Anzahl von Knotenrechnern (110, 120, 130, 140, 150), die über einen oder mehrere Broadcast Kommunikationskanäle (101) verbunden sind, wobei
• der lokale Oszillator eines Knotenrechners die Dauer eines Microticks (301) der lokalen Zeit eines Knotenrechners bestimmt,
• während eines a priori definierten Zeitintervalls ein ausgezeichneter Knotenrechner (110) die Rolle des aktiven Zeitmasters übernimmt,
• alle anderen Knotenrechner (120, 130, 140, 150) die Rolle eines Zeitslaves übernehmen,
• der aktive Zeitmaster (110) die einheitliche Macroticklänge (350) der globalen Zeit festlegt, und
• das Verhältnis Microtick zu Macrotick in jedem Knotenrechner unterschiedlich sein kann,
dadurch gekennzeichnet, dass
der aktive Zeitmaster (110) das Sendeereignis einer Synchronisationsnachricht, die in ihrem Datenfeld den Macrotick des globalen Synchronisationsereignisses enthält, so festlegt, dass das Zeitintervall zwischen dem globalen Synchronisationsereignis (412), das von allen korrekten Zeitslaves beobachtet werden...
A method for establishing a global time base in a distributed real-time computer system comprising a number of node computers (110, 120, 130, 140, 150) connected via one or more broadcast communication channels (101), wherein
The local oscillator of a node computer determines the duration of a microtick (301) of the local time of a node computer,
During an a priori defined time interval, an excellent node computer (110) assumes the role of the active time master,
All other node computers (120, 130, 140, 150) assume the role of a time slave,
• the active time master (110) sets the uniform macro-tempo length (350) of the global time, and
The ratio of microtick to macrotick can be different in each node computer,
characterized in that
the active time master (110) determines the transmission event of a synchronization message containing in its data field the global synchronization event macro-tick so as to determine the time interval between the global synchronization event (412) observed by all the correct time slaves ...

Figure 00000001
Figure 00000001

Description

Die Erfindung betrifft ein Verfahren zum Aufbau einer globalen Zeitbasis in einem verteilten Echtzeitcomputersystem bestehend aus einer Anzahl von Knotenrechnern die über einen oder mehrere Broadcast Kommunikationskanäle verbunden sind, wobei der lokale Oszillator eines Knotenrechners die Dauer eines Microticks der lokalen Zeit eines Knotenrechners bestimmt, während eines a priori definierten Zeitintervalls ein ausgezeichneter Knotenrechner die Rolle des aktiven Zeitmasters übernimmt, alle anderen Knotenrechner die Rolle eines Zeitslaves übernehmen, der aktive Zeitmaster die einheitliche Macroticklänge der globalen Zeit festlegt, und das Verhältnis Microtick zu Macrotick in jedem Knotenrechner unterschiedlich sein kann.The The invention relates to a method for establishing a global time base in a distributed real-time computer system consisting of a number from node computers over one or more broadcast communication channels are connected, wherein the local oscillator of a node computer the duration of a microtick the local time of a node computer determined during a a priori defined time interval an excellent node computer the role of the active time master takes over, all other node computers take on the role of a time slave, the active time master the uniform Macrotick length global time, and the ratio of microtick to macrotick may be different in each node computer.

In einem verteilten fehlertoleranten Echtzeitcomputersystem, bestehend aus einer Anzahl von Knotenrechnern die über ein Echtzeitkommunikationssystem verbunden sind, beispielsweise über ein CAN-Kommunikationsnetzwerk („Control Area Network"), müssen die Knotenrechner oft zeitlich koordinierte Aufgaben vornehmen. Um diese zeitliche Koordination der verteilten Aktionen zu erleichtern, ist es sinnvoll, eine systemweite globale Zeitbasis aufzubauen. Diese globale Zeit soll auch mit dem extern vorgegebenen Zeitstandard, der physikalischen Sekunde, abgestimmt sein. Eine effiziente Uhrensynchronisation von hoher Genauigkeit ist daher von großem wirtschaftlichen Wert.In a distributed fault tolerant real-time computer system consisting from a number of node computers via a real-time communication system are connected, for example via a CAN communication network ("Control Area Network"), the Node computers often perform temporally coordinated tasks. Around It is time-lapse coordination to facilitate the distributed actions makes sense to build a system-wide global time base. This global Time should also comply with the externally specified time standard, the physical one Second, be tuned. An efficient clock synchronization of high accuracy is therefore of great economic value.

Die DE 4140 017 A1 offenbart ein Verfahren zur Erzeugung einer globalen Zeitbasis in einer Datenverarbeitungsanlage. Hierfür wird ein Rechnerknoten mit seiner lokalen Zeit als Referenzknoten definiert, der ein Synchronisierungsobjekt aussendet, das im Wesentlichen gleichzeitig an den anderen Rechnerknoten empfangen wird. In dem Verfahren ist es möglich, dass jeder Rechnerknoten die Relation seiner lokalen Zeitbasis zur Referenzzeitbasis und zu den lokalen Zeitbasen der anderen Rechnerknoten feststellen kann.The DE 4140 017 A1 discloses a method for generating a global time base in a data processing system. For this purpose, a computer node is defined with its local time as a reference node, which emits a synchronization object that is received substantially simultaneously at the other computer nodes. In the method it is possible that each computer node can determine the relation of its local time base to the reference time base and to the local time bases of the other computer nodes.

Die DE 199 33 753 A1 zeigt ein Verfahren und eine Vorrichtung zum Verteilen von verfolgbaren Zeitwerten für einen Satz von Knoten in einem Computernetzwerk. Jeder Knoten umfasst einen Slavetaktgeber, der einen Slavezeitwert unter Verwendung eines Synchronisierungsprotokolls synchronisiert. In dem Netz gibt es einen Masterknoten, der einen Mastertaktgeber aufweist, der einen Masterzeitwert mit dem verfolgbaren Zeitwert synchronisiert und über die Kommunikationsverbindung verteilt.The DE 199 33 753 A1 shows a method and apparatus for distributing trackable time values for a set of nodes in a computer network. Each node includes a slave clock that synchronizes a slave time value using a synchronization protocol. In the network there is a master node having a master clock which synchronizes a master time value with the trackable time value and distributes it over the communication link.

Schließlich zeigt die EP 0 470 199 B1 ein Verfahren zur Synchronisierung der Zeit in einem Computernetzwerk. In dem Netz ist ein Hauptzeitgeber vorgesehen, der die Zeitinformationen an die anderen Einheiten überträgt, um die lokalen Zeitgeber mit den übertragenen Zeitinformationen des Hauptzeitgebers zu synchronisieren. Jede Einheit weist einen Oszillator auf, der an den jeweiligen Zeitgeber eine Impulsfolge ausgibt, wobei eine Einstellvorrichtung vorgesehen ist, die die vom Oszillator ausgegebene Impulsfolge in Abhängigkeit von den Zeitinformationen des Hauptzeitgebers einstellt, so dass der jeweilige lokale Zeitgeber ein genaues Takten der Zeit des Hauptzeitgebers zwischen den übertragenen Zeitinformationen ermöglicht.Finally, the shows EP 0 470 199 B1 a method for synchronizing the time in a computer network. A main timer is provided in the network, which transmits the time information to the other units to synchronize the local timers with the transmitted time information of the main timer. Each unit has an oscillator which outputs a pulse train to the respective timer, wherein an adjusting device is provided which adjusts the oscillator output pulse train in response to the timing information of the main timer, so that the respective local timer precise clocking the time of the main timer between the transmitted time information allows.

Es ist Aufgabe der Erfindung, ein effizientes Verfahren zum Aufbau einer globalen Zeitbasis sowie eine Kommunikationskontrolleinheit zu dessen Durchführung zu schaffen, womit eine systemweite, globale Zeit aufgebaut werden kann, welche auch mit einem externen Zeitstandard, wie der physikalischen Sekunde, abstimmbar ist.It It is an object of the invention to provide an efficient method of construction a global time base and a communication control unit for its implementation creating a system-wide, global time can, which also with an external time standard, like the physical second, is tunable.

Diese Aufgabe wird mit dem eingangs erwähnten Verfahren dadurch gelöst, dass erfindungsgemäß der aktive Zeitmaster das Sendeereignis einer Synchronisationsnachricht, die in ihrem Datenfeld den Macrotick des globalen Synchronisationsereignisses enthält, so festlegt, dass das Zeitintervall zwischen dem globalen Synchronisationsereignis, das von allen korrekten Zeitslaves beobachtet werden kann, und dem Beginn des Macroticks, der im Datenfeld der Synchronisationsnachricht angegeben ist, a priori bekannt ist.These The object is achieved by the method mentioned in the fact that According to the invention, the active Time master the send event of a synchronization message, the in their data field, the macrotick of the global synchronization event contains so that the time interval between the global synchronization event, the can be observed from all correct time slaves, and the beginning the macro key specified in the data field of the synchronization message, a priori is known.

Das hier vorgeschlagene Verfahren zur Uhrensynchronisation in einem verteilten Echtzeitcomputersystem baut auf dem US-Patent US 4 866 606 A vom 12. September 1989 mit dem Titel „Loosely Coupled Distributed Computer System with Node Synchronization for Precision in Real-Time Applications" auf. Mit dem neuen, erfindungsgemäßen Verfahren lässt sich allerdings die Granularität eines Macroticks auch bei Verwendung von Oszillatoren unterschiedlicher Frequenz in den Kontenrechnern einheitlich so festlegen, dass sie mit der Granularität eines vorgegebenen externen Zeitstandards in fixer Beziehung steht. Damit wird mit dem erfindungsgemäßen Verfahren auf einfache Weise die interne und externe Uhrensynchronisation vereinigt.The method proposed here for clock synchronization in a distributed real-time computer system is based on the US patent US 4 866 606 A of September 12, 1989, entitled "Loosely Coupled Distributed Computer System with Node Synchronization for Precision in Real-Time Applications." However, the granularity of a Macrotick can be used in the accounts computers with the use of oscillators of different frequencies with the new method according to the invention uniformly set so that it is in fixed relation with the granularity of a given external time standard.Thus the internal and external clock synchronization is combined in a simple way with the method according to the invention.

Weitere vorteilhafte Ausgestaltungsformen des erfindungsgemäßen Verfahrens sind den Unteransprüchen zu entnehmen.Further advantageous embodiments of the method according to the invention are the dependent claims refer to.

Das vorab beschriebene Ziel und andere neue Eigenschaften der vorliegenden Erfindung werden in der Zeichnung näher erläutert. In dieser zeigtThe previously described objective and other novel features of the present invention Invention will be explained in more detail in the drawing. In this shows

1 die Struktur eines verteilten Computersystems mit fünf Knotenrechnern, die über einen Bus verbunden sind, 1 the structure of a distributed computer system with five node computers connected by a bus,

2 die Struktur eines Knotenrechners, bestehend aus einem Host Computer und einer Kommunikationskontrolleinheit mit dem Anschluss zum Bus, 2 the structure of a node computer, consisting of a host computer and a communication control unit with the connection to the bus,

3 den Zusammenhang zwischen den lokalen Microticks und den globalen Macroticks, 3 the relationship between the local microticks and the global macroticks,

4 den Ablauf der Ereignisse im Zeitbereich bei der Synchronisation eines Slave-Knotens durch den Zeit Master, und 4 the sequence of events in the time domain during the synchronization of a slave node by the time master, and

5 die Intervalle auf der Zeitachse, während der ein Standby Master eine Synchronisationsnachricht senden darf. 5 the intervals on the timeline during which a standby master is allowed to send a synchronization message.

Im folgenden Abschnitt wird eine Realisierung des neuen Verfahrens an einem Beispiel mit fünf Knotenrechnern, die über einen gemeinsamen Bus kommunizieren, gezeigt. Die Objekte in den Abbildungen sind so nummeriert, dass die erste der dreistelligen Objektziffern immer die Bildnummer angibt.in the following section will be a realization of the new procedure on an example with five node computers, the above communicate a common bus, shown. The objects in the Illustrations are numbered so that the first of the three-digit Object numbers always indicates the picture number.

Die 1 zeigt ein System von fünf Knotenrechnern 110, 120, 130, 140 und 150, die über einen gemeinsamen Bus 101, z. B. über einen CAN-Bus („Control Area Network"), Daten austauschen. Der Knotenrechner 110 ist der aktuelle Zeitmaster, der die anderen vier Knotenrechner 120, 130, 140, 150 periodisch resynchronisiert. Einer dieser vier Knotenrechner, beispielweise der Knotenrechner 120, kann die Rolle eines Standby Masters einnehmen, der die zentrale Uhrensynchronisation übernimmt, falls der Knotenrechner 110 ausfällt.The 1 shows a system of five node computers 110 . 120 . 130 . 140 and 150 that have a common bus 101 , z. Eg via a CAN bus ("Control Area Network"), exchange data 110 is the current time master, which is the other four node computers 120 . 130 . 140 . 150 periodically resynchronized. One of these four node computers, for example the node computer 120 , can take the role of a standby master, which takes over the central clock synchronization, if the node computer 110 fails.

Weiters zeigt die 2 den inneren Aufbau eines Knotenrechners, etwa von Knotenrechner 110. Ein Knotenrechner besteht aus zwei Subsystemen, einem Host Computer 201 und einem Kommunikationskontroller 202, der mittels einer Leitung 203 mit dem gemeinsamen Bus 101 verbunden ist. Jeder Knotenrechner muss über einen lokalen Zeitzähler verfügen, der vom lokalen Oszillator des Knotenrechners getrieben wird und dessen Granularität die Microtickgranularität des Knotenrechners festlegt. Erfindungsgemäß kann ein Teil oder das gesamte beschriebene Verfahren im Kommunikationskontroller 202 in Software oder Hardware realisiert werden.Furthermore, the shows 2 the internal structure of a node computer, such as node computer 110 , A node computer consists of two subsystems, a host computer 201 and a communication controller 202 that by means of a wire 203 with the common bus 101 connected is. Each node computer must have a local time counter which is driven by the local oscillator of the node computer and whose granularity determines the microtick granularity of the node computer. According to the invention, some or all of the described method may be used in the communication controller 202 be realized in software or hardware.

Die 3 zeigt den Zusammenhang zwischen den globalen Macroticks 310, 320, 330 und den lokalen Microticks 301 (siehe Kopetz, H. (1997). Real-Time Systems, Design Principles for Distributed Embedded Applications; ISBN: 0-7923-9894-7, Third printing 1999. Boston. Kluwer Academic Publishers, Seite 48) an. Die Macroticks 310, 320, 330 bauen die globale Zeitbasis im verteilten System auf. Der Abstand 350 von zwei globalen Macroticks 310, 320; 320, 330 soll sich nach Möglichkeit an der physikalischen Sekunde orientieren. Es ist vorteilhaft, für den Abstand 350 eine ganzzahlige negative Zweierpotenz der physikalischen Sekunde (siehe Kopetz, Seite 51) zu wählen. Der Abstand zwischen den Microticks 301 wird von den Eigenschaften des sich in einem Knotenrechner befindenden lokalen Oszillators bestimmt und ändert sich aufgrund von physikalischen Einflüssen (beispielweise der Temperatur des Oszillators). Im allgemeinen Fall ist die Relation MMR von Microticks zu Macroticks nicht ganzzahlig. In 5 beispielsweise hat diese Relation MMR einen Wert zwischen 13 und 14. Im allgemeinen Fall hat jeder Knotenrechner eine unterschiedliche MMR, die durch die Eigenschaften des lokalen Oszillators des Knotenrechners vorgegeben ist und sich über die Zeit ändern kann.The 3 shows the relationship between the global macroticks 310 . 320 . 330 and the local microticks 301 (See Kopetz, H. (1997) Real-Time Systems, Design Principles for Distributed Embedded Applications, ISBN: 0-7923-9894-7, Third Printing 1999. Boston, Kluwer Academic Publishers, page 48). The Macroticks 310 . 320 . 330 build the global time base in the distributed system. The distance 350 of two global macroticks 310 . 320 ; 320 . 330 should be based on the physical second if possible. It is beneficial for the distance 350 To select an integer negative power of two of the physical second (see Kopetz, page 51). The distance between the microticks 301 is determined by the characteristics of the local oscillator in a node computer and changes due to physical influences (for example the temperature of the oscillator). In the general case, the relation MMR from Microticks to Macroticks is not integer. In 5 For example, this relation MMR has a value between 13 and 14. In the general case, each node computer has a different MMR, which is predetermined by the properties of the local oscillator of the node computer and may change over time.

In der 4 ist der Ablauf der Ereignisse während eines Synchronisationsvorganges gezeigt. Die Zeitachse 400 zeigt den Fortschritt der Zeit von links nach rechts an. Die senkrechten Linien, die die Zeitachse 400 schneiden, stellen die signifikanten Ereignisse während der Synchronisation dar. Zum Zeitpunkt 410 beginnt der Zeitmaster 110 eine Synchronisationsnachricht zu senden, die das abstrakte Synchronisationsereignis 412, ausgedrückt in Macroticks, beinhaltet.In the 4 the sequence of events during a synchronization process is shown. The timeline 400 indicates the progress of time from left to right. The vertical lines representing the timeline 400 cut, represent the significant events during synchronization. At the time 410 begins the time master 110 to send a synchronization message containing the abstract synchronization event 412 , expressed in Macroticks.

Bei der in 4 gezeigten Realisierung, bei der das globale Synchronisationsereignis der Beginn des Macroticks ist, der in der Synchronisationsnachricht enthalten ist, wählt der Masterknoten 110, der die Synchronisation vornimmt, den Sendezeitpunkt 410 so, dass das Eintreffen des Endes der Synchronisationsnachricht 411 möglichst nahe zum globalen Synchronisationsereignis 412 bei den Slaveknoten liegt. Aufgrund von Digitalisierungsfehlern und dem Jitter des Masters kann das Ende der Synchronisationsnachricht 411 vom globalen Synchronisationsereignis 412 abweichen.At the in 4 In the embodiment shown, in which the global synchronization event is the beginning of the macrotick contained in the synchronization message, the master node selects 110 that makes the synchronization, the transmission time 410 such that the arrival of the end of the synchronization message 411 as close as possible to the global synchronization event 412 is at the slave node. Due to digitization errors and the jitter of the master, the end of the synchronization message 411 from the global synchronization event 412 differ.

Da im Slaveknoten das Ende der Synchronisationsnachricht 411 als globales Synchronisationsereignis 412 interpretiert wird, ist die Variabilität der Länge des Zeitintervalls zwischen dem globalen Synchronisationsereignis 412 und dem Eintreffen des Endes der Synchronisationsnachricht 411 mitbestimmend für die Genauigkeit der Synchronisation. Eine a priori bekannte konstante Abweichung zwischen dem Eintreffen des Endes der Synchronisationsnachricht 411 und des globalen Synchronisationsereignisses 412 kann im Synchronisationsalgorithmus korrigiert werden.Because in the slave node the end of the synchronization message 411 as a global synchronization event 412 is the variability of the length of the time interval between the global synchronization event 412 and the arrival of the end of the synchronization message 411 determining the accuracy of the synchronization. An a priori known constant deviation between the arrival of the end of the synchronization message 411 and the global synchronization event 412 can be corrected in the synchronization algorithm.

In einer anderen Realisierung kann auch der Beginn des Sendens oder der Beginn des Empfangs einer Nachricht als globales Synchronisationsereignis 412 festgelegt werden.In another implementation may also be the beginning of the transmission or the beginning of the reception of a message as a global synchronization event 412 be determined.

Da in CAN-Systemen die Bit-Länge einer Nachricht, auch die der Synchronisationsnachricht, vom Dateninhalt abhängt, muss der Zeitmaster nach Festlegung des globalen Synchronisationsereignisses (ausgedrückt in globalen Macroticks) die exakte Länge der Synchronisationsnachricht, ausgedrückt in lokalen Microticks des Masters, berechnen und unter Berücksichtigung der bekannten Übertragungsgeschwindigkeit des Masters den Sendezeitpunkt 410 bestimmen. Das Ereignis 413 entspricht dem Empfangsinterrupt der Synchronisationsnachricht beim Slave. In der Interruptbehandlungsroutine des Ereignisses 413 muss der Slave den alten Wert seines lokalen Zeitzählers sichern und die Länge des Intervalls 421, ausgedrückt in Microticks des Slaves, als Initialisierungswert in den lokalen Zeitzähler des Slaves eintragen, bevor der lokale Zeitzähler zum Zeitpunkt 414 erneut gestartet wird.Since in CAN systems the bit length of a message, including the synchronization message, depends on the data content, the time master, after determining the global synchronization event (expressed in global macroticks), must calculate the exact length of the synchronization message, expressed in local master microticks, and taking into account the master's known transmission speed 410 determine. The event 413 corresponds to the receive interrupt of the synchronization message at the slave. In the interrupt handling routine of the event 413 the slave must save the old value of its local time counter and the length of the interval 421 , expressed in microticks of the slave, as an initialization value in the local time counter of the slave enter before the local time counter at the time 414 is restarted.

Schließlich ist in 5 gezeigt, wie auf der Zeitachse 500a priori nicht überlappende Zeitintervalle definiert werden, die jeweils abwechselnd dem Master – die Intervalle <510, 511> und <520, 521>) – bzw. einem Standby-Master – die Intervalle <512, 513> und <522, 523>) – zugeordnet sind. Normalerweise sendet der Master nach dem Timeout die nächste Synchronisationsnachricht. Sollte innerhalb des Timeoutintervalls 532 der Standby Master keine Synchronisationsnachricht vom Master empfangen haben, so kann er innerhalb des Intervalls <522, 523> eine Synchronisationsnachricht senden. Empfängt ein Slave während des Intervalls 533 keine Synchronisationsnachricht, so stoppt der Slave jede weitere Sendeoperation, bis er eine neue Synchronisationsnachricht empfangen hat. Diese Unterbrechung der Sendetätigkeit des Slaves ist notwendig, um ein freies Zeitfenster für die Übertragung der nächsten Synchronisationsnachricht vom Master zu schaffen. Wenn der aktive Master zum gewählten Sendezeitpunkt 410 die Synchronisationsnachricht nicht senden kann, weil z. B. der Bus belegt ist, so muss er den Sendeauftrag abbrechen und ein neues globales Synchronisationsereignis 412 festlegen. Dieser Vorgang ist zu wiederholen, bis das Ende des dem Master zugewiesenen Synchronisationsintervalls, z. B. das Ende des Intervalls <520, 521>, erreicht ist. Da mit Ende des Zeitintervalls 533 alle Slaves ihre Sendeaufträge abbrechen, wird mit hoher Wahrscheinlichkeit eine Synchronisationsnachricht des Master vor dem Ende des Intervalls 532 erfolgreich sein.Finally, in 5 shown as on the timeline 500a Priori non-overlapping time intervals are defined, each alternately the master - the intervals < 510 . 511 > and < 520 . 521 >) - or a standby master - the intervals < 512 . 513 > and < 522 . 523 >) - are assigned. Normally, after the timeout, the master sends the next synchronization message. Should be within the timeout interval 532 If the standby master has not received a synchronization message from the master, it can do so within the interval < 522 . 523 > send a synchronization message. Receives a slave during the interval 533 no synchronization message, the slave stops every further send operation until it has received a new synchronization message. This interruption of the transmission activity of the slave is necessary to provide a free time window for the transmission of the next synchronization message from the master. If the active master is at the selected transmission time 410 can not send the synchronization message because z. If the bus is busy, it must cancel the send job and a new global synchronization event 412 establish. This process should be repeated until the end of the synchronization interval assigned to the master, e.g. B. the end of the interval < 520 . 521 >, is reached. Because with the end of the time interval 533 all slaves cancel their send jobs, most likely a synchronization message from the master before the end of the interval 532 be successful.

Nach dem Eintreffen einer Synchronisationsnachricht beim Slave errechnet sich der Slave die Abweichung zwischen der Uhr des Masters und dem lokalen Zeitzählers des Slaves nach folgender Formel Deviation = [old.TC – RL – (new.GSE – old.GSE)·old.MMR] wobei Deviation die Abweichung, ausgedrückt in lokalen Microticks des Slaves, zwischen der Uhr des Masters und dem lokalen Zeitzählers des Slaves in der vorangegangenen Runde angibt, old.TC den Wert des alten lokalen Zeitzählers des Slaves vor Beginn der neuen Synchronisationsrunde, RL den Wert der Receiver Latency 421 ausgedrückt in Microticks des Slaves, und new.GSE und old.GSE den Macrotick der neuen und der alten Synchronisationsnachricht bezeichnen.After the arrival of a synchronization message at the slave, the slave calculates the deviation between the clock of the master and the local time counter of the slave according to the following formula Deviation = [old.TC - RL - (new.GSE - old.GSE) · old.MMR] where Deviation indicates the deviation, expressed in local microticks of the slave, between the clock of the master and the local time counter of the slave in the previous round, old.TC the value of the old local time counter of the slave before the beginning of the new round of synchronization, RL the value of Receiver latency 421 expressed in microticks of the slave, and new.GSE and old.GSE denote the macrotick of the new and the old synchronization message.

Diese Abweichung wird nun dazu verwendet, die Microtick/Macrotick Relation MMR zu korrigieren. Damit wird erreicht, dass sich die Driftrate des Slaves an die Driftrate des Masters anpasst. Der neue Wert dieser Relation new.MMR ergibt sich zu new.MMR = old.MMR + Deviation·weightwobei weight die Gewichtung der Abweichung darstellt. Angenommen die Dauer einer Synchronisationsrunde 531 beträgt nsync Macroticks, und 2k < nsync < 2k+1,dann ist 2–(k+1) ein sinnvoller Wert für weight. Eine Multiplikation von Deviation mit 2–(k+1) lässt sich durch eine einfache Shift-Operation im Rechner realisieren.This deviation is now used to correct the Microtick / Macrotick Relation MMR. This ensures that the drift rate of the slave adapts to the drift rate of the master. The new value of this relation new.MMR results to new.MMR = old.MMR + Deviation · weight where weight represents the weight of the deviation. Suppose the duration of a synchronization round 531 is nsync macroticks, and 2 k <nsync <2 k + 1 . then 2 - (k + 1) is a meaningful value for weight. A multiplication of deviation with 2 - (k + 1) can be realized by a simple shift operation in the computer.

Mit dem vorgeschlagenen Synchronisationsverfahren lassen sich folgende Präzision und Macrotickgranularität realisieren:

  • • Angenommen die Microtickgranularität des Masters und des Slaves liegen bei einer μsec, ebenso der Latency Jitter in der Interruptbehandlung von Master und Slave. Dann beträgt die Konvergenzfunktion (Kopetz, p. 59) 4 μsec.
  • • Angenommen die Abweichung der Driftrate zwischen Master und Slave beträgt nach einer Initialisierungsphase, in der sich die MMRs der Slaves an den Master adaptiert haben, 10–5 und die Synchronisationsperiode ist 100 msec. Dann ist der Drift-offset 1 μsec, womit sich die Präzision zu 5 μsec ergibt. In einem solchen System ist es sinnvoll, für die Granularität eines Macroticks ein Intervall von 2–17 Sekunden, das sind ca 8 μsec, zu wählen.
With the proposed synchronization method, the following precision and macro-tug granularity can be realized:
  • • Suppose the microtick granularity of the master and the slave is one μsec, as well as the latency jitter in the interrupt handling of master and slave. Then the convergence function (Kopetz, p.59) is 4 μsec.
  • • Assuming that the drift rate deviation between master and slave is 10 -5 and the synchronization period is 100 msec after an initialization phase in which the slaves' MMRs have adapted to the master. Then the drift offset is 1 μsec, which results in the precision of 5 μsec. In such a system, it makes sense to choose an interval of 2 -17 seconds, which is about 8 μsec, for the granularity of a macrotick.

Wenn eine kleinere Granularität der Mikroticks und eine Reduzierung des Interruptjitter durch Hardwaremechanismen erreicht werden, lässt sich die Präzision und damit die Makrotickgranularität wesentlich reduzieren, sogar in den Bereich unter einer Mikrosekunde.If a smaller granularity the microticks and a reduction of the interrupt jitter by hardware mechanisms can be achieved, can be the precision and thus significantly reduce macrotick granularity, even in the range under a microsecond.

Das vorgestellte Verfahren zur Synchronisation der Uhren in einem verteilten Computersystem lässt sich sowohl in Software wie auch in Hardware realisieren. Es stellt eine einfache und wirtschaftliche neue Methode zum Aufbau einer globalen Zeit dar.The presented method for synchronizing the clocks in a distributed Computer system leaves to realize themselves both in software as well as in hardware. It puts a simple and economical new way to build a global time.

Claims (9)

Verfahren zum Aufbau einer globalen Zeitbasis in einem verteilten Echtzeitcomputersystem bestehend aus einer Anzahl von Knotenrechnern (110, 120, 130, 140, 150), die über einen oder mehrere Broadcast Kommunikationskanäle (101) verbunden sind, wobei • der lokale Oszillator eines Knotenrechners die Dauer eines Microticks (301) der lokalen Zeit eines Knotenrechners bestimmt, • während eines a priori definierten Zeitintervalls ein ausgezeichneter Knotenrechner (110) die Rolle des aktiven Zeitmasters übernimmt, • alle anderen Knotenrechner (120, 130, 140, 150) die Rolle eines Zeitslaves übernehmen, • der aktive Zeitmaster (110) die einheitliche Macroticklänge (350) der globalen Zeit festlegt, und • das Verhältnis Microtick zu Macrotick in jedem Knotenrechner unterschiedlich sein kann, dadurch gekennzeichnet, dass der aktive Zeitmaster (110) das Sendeereignis einer Synchronisationsnachricht, die in ihrem Datenfeld den Macrotick des globalen Synchronisationsereignisses enthält, so festlegt, dass das Zeitintervall zwischen dem globalen Synchronisationsereignis (412), das von allen korrekten Zeitslaves beobachtet werden kann, und dem Beginn des Macroticks, der im Datenfeld der Synchronisationsnachricht angegeben ist, a priori bekannt ist.Method for establishing a global time base in a distributed real-time computer system comprising a number of node computers ( 110 . 120 . 130 . 140 . 150 ) transmitted via one or more broadcast communication channels ( 101 ), where the local oscillator of a node computer determines the duration of a microtick ( 301 ) determines the local time of a node computer, • during an a priori defined time interval, an excellent node computer ( 110 ) assumes the role of the active time master, • all other node computers ( 120 . 130 . 140 . 150 ) assume the role of a time slaves, • the active time master ( 110 ) the uniform Macrotick length ( 350 ) of global time, and • the ratio of microtick to macrotick can be different in each node computer, characterized in that the active time master ( 110 ) specifies the send event of a synchronization message containing in its data field the macrotick of the global synchronization event, such that the time interval between the global synchronization event ( 412 ), which can be observed by all correct time slaves, and the beginning of the macrotick indicated in the data field of the synchronization message is known a priori. Verfahren nach Anspruch 1, dadurch gekennzeichnet, dass das Ende (411) des Eintreffens der Synchronisationsnachricht beim Zeitslave (120, 130, 140, 150) das globale Synchronisationsereignis (412) darstellt.Method according to claim 1, characterized in that the end ( 411 ) the arrival of the synchronization message at the time slave ( 120 . 130 . 140 . 150 ) the global synchronization event ( 412 ). Verfahren nach Anspruch 1 oder 2, dadurch gekennzeichnet, dass der aktive Zeitmaster (110) vor dem Senden die datenabhängige Nachrichtenlänge der aktuellen Synchronisationsnachricht berechnet und aus der ermittelten Nachrichtenlänge und der bekannten Übertragungsgeschwindigkeit des Senders den Abstand (420) des Sendezeitpunkts (410) der Nachricht von dem globalen Synchronisationsereignis (412), ausgedrückt in den lokalen Microticks des Senders, bestimmt.Method according to claim 1 or 2, characterized in that the active time master ( 110 ), the data-dependent message length of the current synchronization message is calculated before transmission, and the distance is determined from the determined message length and the known transmission speed of the transmitter ( 420 ) of the transmission time ( 410 ) the message from the global synchronization event ( 412 ), expressed in the transmitter's local microticks. Verfahren nach einem der Ansprüche 1 bis 3, dadurch gekennzeichnet, dass jeder Zeitslave das Zeitintervall (421) zwischen dem globalen Synchronisationsereignis (412) und einem Neustart (414) des lokalen Zeitzählers des Slaves, ausgedrückt in den lokalen Microticks des Empfängers, als Initialisierungswert des lokalen Zeitzählers des Slaves verwendet.Method according to one of claims 1 to 3, characterized in that each time slave the time interval ( 421 ) between the global synchronization event ( 412 ) and a restart ( 414 ) of the local time counter of the slave, expressed in the local microticks of the receiver, used as the initialization value of the local time counter of the slave. Verfahren nach einem der Ansprüche 1 bis 4, dadurch gekennzeichnet, dass ein Zeitslave nach der Resynchronisation das lokale Verhältnis Microtick/Macrotick aufgrund der Abweichung des lokalen Zeitzählers des Slaves vom Zeitmaster in der vorangegangenen Runde nach folgender Formel korrigiert, um eine Anpassung der Driftrate des Slaves an die Driftrate des Masters zu realisieren: Deviation = [old.TC – RL – (new.GSE – old.GSE)·old.MMR] new.MMR = old.MMR + Deviation·weight,wobei Deviation die Abweichung, ausgedrückt in lokalen Microticks des Slaves, zwischen der Uhr des Masters und dem lokalen Zeitzähler des Slaves in der vorangegangenen Runde angibt, old.TC den Wert des lokalen Zeitzählers des Slaves vor Beginn der neuen Synchronisationsrunde, RL den Wert der Receiver Latency (421), new.GSE und old.GSE den Inhalt der neuen und der alten Synchronisationsnachricht und weight die Gewichtung der Abweichung darstellen.Method according to one of claims 1 to 4, characterized in that a time slave after the resynchronization the local Microtick / Macrotick ratio due to the deviation of the local time counter of the slave from the time master in the previous round in the previous round corrected by the following formula to an adaptation of the drift rate of the slave to realize the drift rate of the master: Deviation = [old.TC - RL - (new.GSE - old.GSE) · old.MMR] new.MMR = old.MMR + Deviation · weight, where Deviation indicates the deviation, expressed in local microticks of the slave, between the master's clock and the slave's local time counter in the previous round, old.TC the value of the slave's local time counter before the beginning of the new round of synchronization, RL the value of the receiver Latency ( 421 ), new.GSE and old.GSE represent the contents of the new and old synchronization message and weight the weight of the deviation. Verfahren nach einem der Ansprüche 1 bis 5, dadurch gekennzeichnet, dass der Zeitmaster (110) die Übertragung der Synchronisationsnachricht abbricht, falls er feststellt, dass der errechnete Sendezeitpunkt (410) nicht realisiert werden konnte, da der Bus (101) zum Zeitpunkt des Sendens belegt war.Method according to one of claims 1 to 5, characterized in that the time master ( 110 ) terminates the transmission of the synchronization message if it determines that the calculated transmission time ( 410 ) could not be realized because the bus ( 101 ) was occupied at the time of sending. Verfahren nach einem der Ansprüche 1 bis 6, dadurch gekennzeichnet, dass auf der Zeitachse (400) a priori nicht überlappende Intervalle (<510, 511>, <512, 513>, <520, 521>, <522, 523>) abwechselnd dem aktiven Zeitmaster (110) und einem Standby Zeitmaster (120) zugewiesen werden, um nach Ausbleiben der erwarteten Synchronisationsnachricht im Intervall (<510, 511>, <520, 521>) des aktiven Masters dem Standby Master die Möglichkeit zu geben, eine Synchronisationsnachricht in dem ihm zugewiesenen Intervall (<512, 513>, <522, 523>) zu senden.Method according to one of claims 1 to 6, characterized in that on the time axis ( 400 ) a priori non-overlapping intervals (< 510 . 511 >, < 512 . 513 >, < 520 . 521 >, < 522 . 523 >) alternating the active time master ( 110 ) and a standby time master ( 120 ) to wait for the failure of the expected synchronization message in the interval (< 510 . 511 >, < 520 . 521 >) of the active master allows the standby master to send a synchronization message in the interval assigned to it (< 512 . 513 >, < 522 . 523 >). Verfahren nach einem der Ansprüche 1 bis 7, dadurch gekennzeichnet, dass der Zeitmaster (110) das Verhältnis Microtick/Macrotick so wählt, dass die Macroticklänge einer negativen Zweierpotenz der physikalischen Sekunde entspricht.Method according to one of claims 1 to 7, characterized in that the time master ( 110 ) selects the ratio Microtick / Macrotick so that the Macrotick length corresponds to a negative power of two of the physical second. Kommunikationskontrolleinheit zur Übermittlung von Nachrichten in einem verteilten Echtzeitcomputersystem, dadurch gekennzeichnet, dass eine oder mehrere der in Anspruch 1 bis 8 angegebenen Verfahren in Hardware realisiert werden.Communication control unit for transmission of messages in a distributed real-time computer system, thereby in that one or more of those specified in claims 1 to 8 Procedures to be implemented in hardware.
DE10191695T 2000-05-04 2001-04-30 Method and communication control unit for multimaster clock synchronization in a distributed real-time computer system Expired - Lifetime DE10191695B4 (en)

Applications Claiming Priority (3)

Application Number Priority Date Filing Date Title
AT0078500A AT408383B (en) 2000-05-04 2000-05-04 METHOD AND COMMUNICATION CONTROL UNIT FOR THE MULTIMASTER WATCH SYNCHRONIZATION IN A DISTRIBUTED REAL-TIME COMPUTER SYSTEM
ATA785/2000 2000-05-04
PCT/AT2001/000131 WO2001084286A2 (en) 2000-05-04 2001-04-30 Method and communication control unit for multimaster clock synchronisation in a distributed real time computer system

Publications (2)

Publication Number Publication Date
DE10191695D2 DE10191695D2 (en) 2003-06-12
DE10191695B4 true DE10191695B4 (en) 2009-07-23

Family

ID=3680906

Family Applications (1)

Application Number Title Priority Date Filing Date
DE10191695T Expired - Lifetime DE10191695B4 (en) 2000-05-04 2001-04-30 Method and communication control unit for multimaster clock synchronization in a distributed real-time computer system

Country Status (4)

Country Link
AT (1) AT408383B (en)
AU (1) AU2001252016A1 (en)
DE (1) DE10191695B4 (en)
WO (1) WO2001084286A2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
DE102010037906A1 (en) * 2010-09-30 2012-04-05 Schneider Electric Automation Gmbh Method and system for recording, synchronizing and analyzing data by means of spatially distributed analysis devices in a communication network

Families Citing this family (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
SE525273C2 (en) * 2002-01-07 2005-01-18 Kvaser Consultant Ab Distributed control and monitoring system
AT411948B (en) 2002-06-13 2004-07-26 Fts Computertechnik Gmbh COMMUNICATION PROCESS AND APPARATUS FOR TRANSMITTING TIME-CONTROLLED AND EVENT-CONTROLLED ETHERNET MESSAGES
DE10306788A1 (en) * 2003-02-18 2004-08-26 Brose Fahrzeugteile Gmbh & Co. Kommanditgesellschaft, Coburg Control method for two or more motor vehicle control units, especially blinker or indicator light controllers, whereby the timer circuits of the two controllers are synchronized using existing control bus signals
AT413308B (en) * 2003-09-10 2006-01-15 Fts Computertechnik Gmbh METHOD AND APPARATUS FOR CALIBRATING THE WATCH IN A DISTRIBUTED REAL-TIME SYSTEM
US8301885B2 (en) 2006-01-27 2012-10-30 Fts Computertechnik Gmbh Time-controlled secure communication
US8315274B2 (en) 2006-03-29 2012-11-20 Honeywell International Inc. System and method for supporting synchronous system communications and operations
DE102009037156A1 (en) * 2009-08-04 2011-02-17 Lenze Automation Gmbh Method for the synchronous recording and recording of process and / or status data and automation system
AT513314A1 (en) 2012-06-25 2014-03-15 Fts Computertechnik Gmbh Method for building optimal timed paths in a large computer network
CN112235068A (en) * 2020-10-14 2021-01-15 许继集团有限公司 Master-slave machine synchronization method and device for distributed power system
CN113612565B (en) * 2021-07-09 2024-03-15 芯来智融半导体科技(上海)有限公司 Development and debugging system, handshake method and device

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4866606A (en) * 1984-06-22 1989-09-12 Austria Miktosystem International Gmbh Loosely coupled distributed computer system with node synchronization for precision in real time applications
DE4140017A1 (en) * 1991-12-04 1993-06-09 Nec Electronics (Germany) Gmbh, 4000 Duesseldorf, De METHOD FOR GENERATING A GLOBAL TIME BASE AND DATA PROCESSING SYSTEM WITH DISTRIBUTED COMPUTER NODES
EP0470199B1 (en) * 1989-04-25 1998-07-08 Kvaser Consultant Ab Clock synchronisation in a computer system
DE19933753A1 (en) * 1998-07-22 2000-01-27 Hewlett Packard Co Distributed system application techniques using time synchronization technology

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4866606A (en) * 1984-06-22 1989-09-12 Austria Miktosystem International Gmbh Loosely coupled distributed computer system with node synchronization for precision in real time applications
EP0470199B1 (en) * 1989-04-25 1998-07-08 Kvaser Consultant Ab Clock synchronisation in a computer system
DE4140017A1 (en) * 1991-12-04 1993-06-09 Nec Electronics (Germany) Gmbh, 4000 Duesseldorf, De METHOD FOR GENERATING A GLOBAL TIME BASE AND DATA PROCESSING SYSTEM WITH DISTRIBUTED COMPUTER NODES
DE19933753A1 (en) * 1998-07-22 2000-01-27 Hewlett Packard Co Distributed system application techniques using time synchronization technology

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
DE102010037906A1 (en) * 2010-09-30 2012-04-05 Schneider Electric Automation Gmbh Method and system for recording, synchronizing and analyzing data by means of spatially distributed analysis devices in a communication network
DE102010037906B4 (en) * 2010-09-30 2014-02-27 Schneider Electric Automation Gmbh Method and system for recording, synchronizing and analyzing data by means of spatially distributed analysis devices in a communication network

Also Published As

Publication number Publication date
WO2001084286A8 (en) 2002-07-11
DE10191695D2 (en) 2003-06-12
WO2001084286A2 (en) 2001-11-08
AU2001252016A1 (en) 2001-11-12
ATA7852000A (en) 2001-03-15
AT408383B (en) 2001-11-26

Similar Documents

Publication Publication Date Title
EP0570557B1 (en) Process for generating a common time base for a system with decentralised computing units
EP2039568B1 (en) Method and device for data exchange between at least two subscribers connected by a bus system
DE4320137B4 (en) Synchronization of time of day clocks in a distributed processing network system
DE69408506T2 (en) Method and device for synchronizing clocks connected to a network
EP1471432B1 (en) Method and device for synchronizing the cycle time of a number of buses, and a corresponding bus system
DE10191695B4 (en) Method and communication control unit for multimaster clock synchronization in a distributed real-time computer system
DE3424866A1 (en) METHOD AND ARRANGEMENT FOR TRANSMITTING DATA, IN PARTICULAR IN AN AIRPLANE
EP2040402B1 (en) Method and device for data exchange between at least two subscribers connected by a bus system
DE112005000406T5 (en) A system and method for maintaining a common clock and a network segment
EP1763768B1 (en) Method and device for controlling a bus system, and corresponding bus system
DE69837431T2 (en) METHOD FOR PROVIDING TIME SYNCHRONIZATION IN A NETWORK
EP1039660A2 (en) Wireless network with user synchronisation
DE10327548B4 (en) Method and device for exchanging data via a bus system
WO2001011811A1 (en) Synchronisation method and system for clock signal sources, in particular in packet transmission communication systems
DE2728246A1 (en) METHOD AND CIRCUIT ARRANGEMENTS FOR BANDWIDTH ALLOCATION FOR LOOP TRANSMISSION SYSTEMS
DE69211781T2 (en) Method and device for synchronizing two or more time-multiplexed communication networks
DE10053525B4 (en) Method and system for the synchronization of subscribers of a communication connection
DE10249296A1 (en) Procedure for the synchronization of participants in a network
DE10241429B4 (en) Method for the synchronization of network nodes of a subnetwork
EP1168694A2 (en) Synchronous network
DE102004061343B4 (en) Network with multiple stations, station for such a network and method for synchronization of stations
DE102019125527B4 (en) Method for time synchronization in an Ethernet-based network
DE69131420T2 (en) DECISION BETWEEN MULTIPLE USERS IN A COMMON RESOURCE
EP3099020B1 (en) Method for data communication between a limited number of communication partners connected to a common communication network
DE102007020440A1 (en) Synchronization bus system, communication units for a synchronization bus system and method for exchanging messages for time synchronization

Legal Events

Date Code Title Description
8110 Request for examination paragraph 44
8364 No opposition during term of opposition
R081 Change of applicant/patentee

Owner name: TTTECH COMPUTERTECHNIK AG, AT

Free format text: FORMER OWNER: FTS COMPUTERTECHNIK GES.M.B.H., BADEN-SIEGENFELD, AT

R082 Change of representative

Representative=s name: K & H BONAPAT PATENTANWAELTE KOCH - VON BEHREN, DE

Representative=s name: K & H BONAPAT PATENTANWAELTE KOCH VON BEHREN &, DE

R071 Expiry of right