JP2013029319A - Slave device, electronic apparatus system, master device, time synchronization method, and program - Google Patents

Slave device, electronic apparatus system, master device, time synchronization method, and program Download PDF

Info

Publication number
JP2013029319A
JP2013029319A JP2011163534A JP2011163534A JP2013029319A JP 2013029319 A JP2013029319 A JP 2013029319A JP 2011163534 A JP2011163534 A JP 2011163534A JP 2011163534 A JP2011163534 A JP 2011163534A JP 2013029319 A JP2013029319 A JP 2013029319A
Authority
JP
Japan
Prior art keywords
message
time
master device
slave device
receiving
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.)
Withdrawn
Application number
JP2011163534A
Other languages
Japanese (ja)
Inventor
Shuzo Yanagi
修三 柳
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.)
NEC Saitama Ltd
Original Assignee
NEC Saitama Ltd
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 NEC Saitama Ltd filed Critical NEC Saitama Ltd
Priority to JP2011163534A priority Critical patent/JP2013029319A/en
Publication of JP2013029319A publication Critical patent/JP2013029319A/en
Withdrawn legal-status Critical Current

Links

Images

Abstract

PROBLEM TO BE SOLVED: To prevent time synchronization precision of initial start time of a slave device from being reduced, to reduce a load to a network, and to shorten the time up to time synchronism, in time synchronization between a master device and a plurality of slave devices through a network.SOLUTION: When the value of a counter 11 exceeds a value indicating stabilization of an oscillator 15, a determination part 12 determines a busy state of a master device, but when the master device is not in the busy state, a transmission part 13 transmits a first message to the master device. A reception part 14 receives a second message and a follow-up message including the transmission time of the second message. A processing part 17 corrects an offset of a timer 16 on the basis of the difference between the transmission time and reception time of the second message. The transmission part 13 transmits a third message to the master device. The reception part 14 receives a fourth message including the reception time of the third message. The processing part 17 corrects propagation delay of the timer 16 on the basis of the difference between the reception time and transmission time of the third message.

Description

本発明は、マスタ装置と時刻同期を行うスレーブ装置、時刻同期を行うマスタ装置と複数のスレーブ装置とで構成する電子機器システム、スレーブ装置と時刻同期を行うマスタ装置、マスタ装置とスレーブ装置との時刻同期方法およびプログラムに関する。   The present invention relates to a slave device that performs time synchronization with a master device, an electronic device system that includes a master device that performs time synchronization and a plurality of slave devices, a master device that performs time synchronization with a slave device, and a master device and a slave device. The present invention relates to a time synchronization method and a program.

Ethernet(登録商標)等のネットワークを用いた時刻同期方法として、IEEE1588規格によるマスタ装置からスレーブ装置への時刻パケットの通信(PTP:Precision Time Protocol)による方法がある。IEEE1588方式において、ネットワークで接続されたマスタ装置とスレーブ装置とで構成される場合、スレーブ装置の時刻同期精度は、スレーブ装置に実装された発振器の安定度及びマスタ装置との時刻パケット通信を行うネットワークの負荷状態に依存する。   As a time synchronization method using a network such as Ethernet (registered trademark), there is a method by time packet communication (PTP: Precision Time Protocol) from a master device to a slave device according to the IEEE 1588 standard. In the IEEE 1588 system, when configured by a master device and a slave device connected via a network, the time synchronization accuracy of the slave device is the network that performs the time packet communication with the stability of the oscillator mounted on the slave device and the master device. Depends on the load state.

ここで、マスタ装置とネットワーク上で接続されているスレーブ装置が電源起動後に新規に時刻パケット通信により時刻同期を行う場合、スレーブ装置の電源起動初期には、時刻同期精度はスレーブ装置内部の発振器の安定度に依存する。電源起動後の時間経過によってスレーブ装置内部の発振器の安定度が向上すると、時刻同期精度はマスタ装置との時刻パケット通信を行うネットワークの負荷状態に依存する。これは、スレーブ装置の電源起動直後では発振器が安定していないため、たとえばマスタ装置から受信した時刻に対し、スレーブ装置の発振器の安定度が低いことによる誤差が加わり、マスタ装置との正確なオフセット時間差が求められないためである。   Here, when a slave device connected to the master device on the network newly performs time synchronization by time packet communication after the power is turned on, the time synchronization accuracy is the value of the oscillator in the slave device at the initial stage of power-on of the slave device. Depends on stability. When the stability of the oscillator in the slave device is improved as time elapses after the power is turned on, the time synchronization accuracy depends on the load state of the network that performs time packet communication with the master device. This is because the oscillator is not stable immediately after power-on of the slave device, so for example, an error due to the low stability of the oscillator of the slave device is added to the time received from the master device, and an accurate offset from the master device This is because the time difference cannot be obtained.

スレーブ装置に実装された発振器の周波数が電源起動後の時間経過とともに安定し、時刻同期に支障のない精度の範囲内になることにより、この問題は回避される。一方、ネットワークによるマスタ装置とスレーブ装置との間の時刻パケット通信は、1つのマスタ装置に接続されるスレーブ装置が多いほど、ネットワーク負荷が大きくなる。また、時刻パケット通信以外のデータパケット通信の影響を受けることにより、さらにネットワーク負荷が大きくなる。ネットワーク負荷が大きいほど揺らぎが大きくなり、揺らぎの大きさによっては1回のパケット通信では時刻精度が低い場合がある。このため、通常は複数回の時刻パケット通信の結果を用いて時刻精度を高めることになる。   This problem is avoided by the fact that the frequency of the oscillator mounted on the slave device stabilizes with the passage of time after the power is turned on and falls within the accuracy range that does not interfere with time synchronization. On the other hand, in the time packet communication between the master device and the slave device via the network, the network load increases as the number of slave devices connected to one master device increases. Further, the network load is further increased due to the influence of data packet communication other than time packet communication. The greater the network load, the greater the fluctuation. Depending on the magnitude of the fluctuation, the time accuracy may be low in one packet communication. For this reason, the time accuracy is usually increased by using a result of a plurality of time packet communications.

特許文献1では、ネットワークのトラフィックを不必要に増加させることなく、応答性よく時刻補正をすることができる技術が開示されている。特許文献1のクライアント装置では、時刻補正要求の送信間隔は誤差に基づいて決定される。送信間隔は、誤差が大きいときは短く、誤差が小さいときは長くなるように決定される。したがって、ネットワークのトラフィックを不必要に増加させることなく、時刻補正をすることができる。   Patent Document 1 discloses a technique that can correct the time with high responsiveness without unnecessarily increasing network traffic. In the client device of Patent Literature 1, the time correction request transmission interval is determined based on an error. The transmission interval is determined so as to be short when the error is large and long when the error is small. Therefore, time correction can be performed without unnecessarily increasing network traffic.

特許文献2では、スレーブ装置でマスタ装置との時刻同期化を正確に実現する電子機器システムが提案されている。特許文献2の電子機器システムでは、スレーブ装置の時計部の時刻補正を、従来のように誤差が含まれるオフセット(Offset)の演算結果を使用しないで行うことにより、スレーブ装置ではマスタ装置との時刻同期化を高精度で実現する。   Patent Document 2 proposes an electronic device system that accurately realizes time synchronization with a master device using a slave device. In the electronic device system of Patent Document 2, the time correction of the clock unit of the slave device is performed without using the calculation result of the offset (Offset) including the error as in the conventional case, so that the slave device is connected to the time of the master device. Synchronize with high accuracy.

特許文献3には、スレーブ装置においてマスタ装置との完全な時刻同期化を実現する電子機器システムが提示されている。この電子機器システムでは、マスタ装置からスレーブ装置に時刻情報がカウンタ値で送られることで、マスタ装置でカウンタ値を例えばナノセコンド(ns)単位の値に変換する処理、およびスレーブ装置でナノセコンド(ns)単位の値をカウンタ値に変換する処理は行われない。そのため、マスタ装置からスレーブ装置に供給される時刻情報は、変換時の演算誤差を含まない正確な時刻情報となる。これにより、スレーブ装置ではマスタ装置との時刻同期化をより高精度に実現できる。   Patent Document 3 presents an electronic device system that realizes complete time synchronization with a master device in a slave device. In this electronic device system, time information is sent as a counter value from the master device to the slave device, so that the master device converts the counter value into a value in units of nanoseconds (ns), for example, and the slave device uses the nanosecond ( ns) The unit value is not converted into a counter value. Therefore, the time information supplied from the master device to the slave device is accurate time information that does not include a calculation error during conversion. Thereby, the slave device can realize time synchronization with the master device with higher accuracy.

特開2007−214670号公報JP 2007-214670 A 特開2010−190635号公報JP 2010-190635 A 特開2010−197320号公報JP 2010-197320 A

IEEE1588を用いたネットワーク構成によるマスタ装置と複数のスレーブ装置の運用環境下で、新たにスレーブ装置を接続する場合、スレーブ装置を電源起動すると、スレーブ装置に実装された発振器の周波数が安定していない状態で、かつ既に運用されているネットワーク負荷の環境下でマスタ装置との時刻パケット通信を行うこととなるため、所定の時刻同期精度を満足するまでの同期引き込み時間が長くなる可能性がある。   When a slave device is newly connected in an operating environment of a master device with a network configuration using IEEE 1588 and a plurality of slave devices, when the slave device is powered on, the frequency of the oscillator mounted on the slave device is not stable In this state, the time packet communication with the master device is performed under an already operated network load environment, and therefore there is a possibility that the synchronization pull-in time until a predetermined time synchronization accuracy is satisfied is prolonged.

特許文献1〜3に記載の技術は、IEEE1588を用いたネットワーク構成によるマスタ装置と複数のスレーブ装置の時刻同期において、スレーブ装置の初期起動時の時刻同期精度の低下を防ぎ、ネットワークへの負荷を軽減し、かつ、時刻同期までの時間を短縮するものではない。   The techniques described in Patent Documents 1 to 3 prevent a decrease in time synchronization accuracy at the time of initial startup of a slave device in time synchronization between a master device and a plurality of slave devices with a network configuration using IEEE 1588, and reduce the load on the network. It does not reduce the time to time synchronization.

本発明は、上述のような事情に鑑みてなされたもので、マスタ装置と複数のスレーブ装置とのネットワークを介する時刻同期において、スレーブ装置の初期起動時の時刻同期精度の低下を防ぎ、ネットワークへの負荷を軽減し、かつ、時刻同期までの時間を短縮することができるスレーブ装置、電子機器システム、マスタ装置、時刻同期方法およびプログラムを提供することを目的とする。   The present invention has been made in view of the circumstances as described above. In the time synchronization through the network between the master device and the plurality of slave devices, the time synchronization accuracy at the time of initial activation of the slave device is prevented, and the network is provided. An object of the present invention is to provide a slave device, an electronic device system, a master device, a time synchronization method, and a program that can reduce the load on the device and reduce the time until time synchronization.

本発明の第1の観点に係るスレーブ装置は、
マスタ装置とネットワークを介して時刻同期を行うスレーブ装置であって、
時刻情報を生成するタイマと、
前記時刻情報を生成するためのクロックを発生させる発振器と、
所定の間隔でカウントアップするカウンタと、
前記カウンタの値が所定の値を超えた場合に、前記マスタ装置が他のスレーブ装置と時刻同期を行っているビジー状態であるか否かを判定する判定手段と、
前記判定手段が前記ビジー状態でないと判定した場合、前記マスタ装置に時刻同期の開始を要求する第1メッセージを送信する第1送信手段と、
前記マスタ装置から、前記マスタ装置と前記スレーブ装置との間のオフセット時間差を求めるための第2メッセージと、前記第2メッセージが前記マスタ装置から送信された時刻を含むフォローアップメッセージとを受信する第1受信手段と、
前記第1受信手段が前記第2メッセージを受信した時刻と、前記フォローアップメッセージに含まれる前記第2メッセージが前記マスタ装置から送信された時刻とに基づいて、前記オフセット時間差を算出するオフセット算出手段と、
前記第1受信手段が前記マスタ装置から前記フォローアップメッセージを受信したのちに、前記マスタ装置に前記マスタ装置と前記スレーブ装置との間の伝搬遅延時間を求めるための第3メッセージを送信する第2送信手段と、
前記マスタ装置から前記第3メッセージを前記マスタ装置が受信した時刻を含む第4メッセージを受信する第2受信手段と、
前記第2送信手段が前記第3メッセージを送信した時刻と、前記第4メッセージに含まれる前記第3メッセージを前記マスタ装置が受信した時刻とに基づいて、前記伝搬遅延時間を算出する遅延時間算出手段と、
前記オフセット時間差および前記伝搬遅延時間に基づいて、前記タイマの時刻を補正する補正手段と、
を備えることを特徴とする。
A slave device according to the first aspect of the present invention provides:
A slave device that performs time synchronization with a master device via a network,
A timer for generating time information;
An oscillator for generating a clock for generating the time information;
A counter that counts up at predetermined intervals;
A determination means for determining whether or not the master device is busy performing time synchronization with other slave devices when the value of the counter exceeds a predetermined value;
A first transmission unit configured to transmit a first message requesting the master device to start time synchronization when the determination unit determines that the busy state is not present;
A second message for receiving an offset time difference between the master device and the slave device and a follow-up message including a time when the second message is transmitted from the master device from the master device. One receiving means;
Offset calculating means for calculating the offset time difference based on the time when the first receiving means receives the second message and the time when the second message included in the follow-up message is transmitted from the master device. When,
After the first receiving means receives the follow-up message from the master device, a second message is transmitted to the master device for determining a propagation delay time between the master device and the slave device. A transmission means;
Second receiving means for receiving a fourth message including a time at which the master device has received the third message from the master device;
Delay time calculation for calculating the propagation delay time based on the time at which the second transmission means transmits the third message and the time at which the master device receives the third message included in the fourth message. Means,
Correction means for correcting the time of the timer based on the offset time difference and the propagation delay time;
It is characterized by providing.

本発明の第2の観点に係る電子機器システムは、
ネットワークを介して時刻同期を行うマスタ装置と2以上のスレーブ装置とを備える電子機器システムであって、
前記スレーブ装置はそれぞれ、
時刻情報を生成するタイマ、
前記時刻情報を生成するためのクロックを発生させる発振器、
所定の間隔でカウントアップするカウンタ、
前記カウンタの値が所定の値を超えた場合に、前記マスタ装置が他のスレーブ装置と時刻同期を行っているビジー状態であるか否かを判定する判定手段、
前記判定手段が前記ビジー状態でないと判定した場合、前記マスタ装置に時刻同期の開始を要求する第1メッセージを送信する第1送信手段、
前記マスタ装置から、前記マスタ装置と前記スレーブ装置との間のオフセット時間差を求めるための第2メッセージと、前記第2メッセージが前記マスタ装置から送信された時刻を含むフォローアップメッセージとを受信する第1受信手段、
前記第1受信手段が前記第2メッセージを受信した時刻と、前記フォローアップメッセージに含まれる前記第2メッセージが前記マスタ装置から送信された時刻とに基づいて、前記オフセット時間差を算出するオフセット算出手段、
前記第1受信手段が前記マスタ装置から前記フォローアップメッセージを受信したのちに、前記マスタ装置に前記マスタ装置と前記スレーブ装置との間の伝搬遅延時間を求めるための第3メッセージを送信する第2送信手段、
前記マスタ装置から前記第3メッセージを前記マスタ装置が受信した時刻を含む第4メッセージを受信する第2受信手段、
前記第2送信手段が前記第3メッセージを送信した時刻と、前記第4メッセージに含まれる前記第3メッセージを前記マスタ装置が受信した時刻とに基づいて、前記伝搬遅延時間を算出する遅延時間算出手段、および、
前記オフセット時間差および前記伝搬遅延時間に基づいて、前記タイマの時刻を補正する補正手段、
を含み、
前記マスタ装置は、
前記スレーブ装置から前記第1メッセージを受信する第3受信手段、
前記第3受信手段が前記スレーブ装置から前記第1メッセージを受信すると、前記第2メッセージと、前記フォローアップメッセージとを、前記第1メッセージを受信した相手の前記スレーブ装置である対象スレーブ装置に送信する第3送信手段、
前記第3送信手段が前記第2メッセージを前記対象スレーブ装置に送信すると、前記ビジー状態であることを示す第5メッセージを、前記対象スレーブ装置以外の前記スレーブ装置に送信する第4送信手段、
前記対象スレーブ装置から前記第3メッセージを受信する第4受信手段、および、
前記第4受信手段が前記対象スレーブ装置から前記第3メッセージを受信すると、前記対象スレーブ装置に前記第4メッセージを送信する第5送信手段、
を含むことを特徴とする。
An electronic device system according to a second aspect of the present invention is:
An electronic device system including a master device that performs time synchronization via a network and two or more slave devices,
Each of the slave devices is
A timer that generates time information,
An oscillator for generating a clock for generating the time information;
A counter that counts up at predetermined intervals,
A determination unit that determines whether or not the master device is busy performing time synchronization with another slave device when the value of the counter exceeds a predetermined value;
A first transmission unit configured to transmit a first message requesting the master device to start time synchronization when the determination unit determines that the busy state is not present;
A second message for receiving an offset time difference between the master device and the slave device and a follow-up message including a time when the second message is transmitted from the master device from the master device. 1 receiving means,
Offset calculating means for calculating the offset time difference based on the time when the first receiving means receives the second message and the time when the second message included in the follow-up message is transmitted from the master device. ,
After the first receiving means receives the follow-up message from the master device, a second message is transmitted to the master device for determining a propagation delay time between the master device and the slave device. Transmission means,
Second receiving means for receiving a fourth message including a time at which the master device has received the third message from the master device;
Delay time calculation for calculating the propagation delay time based on the time at which the second transmission means transmits the third message and the time at which the master device receives the third message included in the fourth message. Means and
Correction means for correcting the time of the timer based on the offset time difference and the propagation delay time;
Including
The master device is
Third receiving means for receiving the first message from the slave device;
When the third receiving unit receives the first message from the slave device, the second message and the follow-up message are transmitted to the target slave device that is the slave device of the other party that received the first message. Third transmitting means for
A fourth transmission unit configured to transmit a fifth message indicating the busy state to the slave device other than the target slave device when the third transmission unit transmits the second message to the target slave device;
Fourth receiving means for receiving the third message from the target slave device; and
Fifth transmission means for transmitting the fourth message to the target slave device when the fourth reception means receives the third message from the target slave device;
It is characterized by including.

本発明の第3の観点に係るマスタ装置は、
2以上のスレーブ装置とネットワークを介して時刻同期を行うマスタ装置であって、
前記スレーブ装置から時刻同期の開始を要求する第1メッセージを受信する第3受信手段と、
前記第3受信手段が前記スレーブ装置から前記第1メッセージを受信すると、前記マスタ装置と前記スレーブ装置との間のオフセット時間差を求めるための第2メッセージと、前記第2メッセージを送信した時刻を含むフォローアップメッセージとを、前記第1メッセージを受信した相手の前記スレーブ装置である対象スレーブ装置に送信する第3送信手段と、
前記第3送信手段が前記第2メッセージを前記対象スレーブ装置に送信すると、前記ビジー状態であることを示す第5メッセージを、前記対象スレーブ装置以外の前記スレーブ装置に送信する第4送信手段と、
前記対象スレーブ装置から前記マスタ装置と前記スレーブ装置との間の伝搬遅延時間を求めるための第3メッセージを受信する第4受信手段と、
前記第4受信手段が前記対象スレーブ装置から前記第3メッセージを受信すると、前記対象スレーブ装置に前記第3メッセージを受信した時刻を含む第4メッセージを送信する第5送信手段と、
を備えることを特徴とする。
The master device according to the third aspect of the present invention is:
A master device that performs time synchronization with two or more slave devices via a network,
Third receiving means for receiving a first message for requesting start of time synchronization from the slave device;
When the third receiving unit receives the first message from the slave device, the third receiving unit includes a second message for obtaining an offset time difference between the master device and the slave device, and a time when the second message is transmitted. A third transmission means for transmitting a follow-up message to a target slave device that is the slave device of the other party that received the first message;
A fourth transmission unit configured to transmit a fifth message indicating the busy state to the slave device other than the target slave device when the third transmission unit transmits the second message to the target slave device;
A fourth receiving means for receiving a third message for obtaining a propagation delay time between the master device and the slave device from the target slave device;
When the fourth receiving unit receives the third message from the target slave device, a fifth transmitting unit that transmits a fourth message including the time when the third message is received to the target slave device;
It is characterized by providing.

本発明の第4の観点に係る時刻同期方法は、
ネットワークを介して時刻同期を行うマスタ装置と2以上のスレーブ装置とを備える電子機器システムにおいて、時刻情報を生成するためのクロックを発生させる発振器と、所定の間隔でカウントアップするカウンタとを備える前記スレーブ装置が実行する
前記カウンタの値が所定の値を超えた場合に、前記マスタ装置が他のスレーブ装置と時刻同期を行っているビジー状態であるか否かを判定する判定ステップと、
前記判定ステップで前記ビジー状態でないと判定した場合、前記マスタ装置に時刻同期の開始を要求する第1メッセージを送信する第1送信ステップと、
前記マスタ装置が実行する
前記スレーブ装置から前記第1メッセージを受信する第3受信ステップと、
前記第3受信ステップで前記スレーブ装置から前記第1メッセージを受信すると、前記マスタ装置と前記スレーブ装置との間のオフセット時間差を求めるための第2メッセージと、前記第2メッセージを送信した時刻を含むフォローアップメッセージとを、前記第1メッセージを受信した相手の前記スレーブ装置である対象スレーブ装置に送信する第3送信ステップと、
前記第3送信ステップで前記第2メッセージを前記対象スレーブ装置に送信すると、前記ビジー状態であることを示す第5メッセージを、前記対象スレーブ装置以外の前記スレーブ装置に送信する第4送信ステップと、
前記対象スレーブ装置が実行する
前記マスタ装置から、前記第2メッセージと、前記フォローアップメッセージとを受信する第1受信ステップと、
前記第1受信ステップで前記第2メッセージを受信した時刻と、前記フォローアップメッセージに含まれる前記第2メッセージが前記マスタ装置から送信された時刻とに基づいて、前記オフセット時間差を算出するオフセット算出ステップと、
前記第1受信ステップで前記マスタ装置から前記フォローアップメッセージを受信したのちに、前記マスタ装置に前記マスタ装置と前記スレーブ装置との間の伝搬遅延時間を求めるための第3メッセージを送信する第2送信ステップと、
前記マスタ装置が実行する
前記対象スレーブ装置から前記第3メッセージを受信する第4受信ステップと、
前記第4受信ステップで前記対象スレーブ装置から前記第3メッセージを受信すると、前記対象スレーブ装置に前記第3メッセージを受信した時刻を含む前記第4メッセージを送信する第5送信ステップと、
前記対象スレーブ装置が実行する
前記マスタ装置から前記第4メッセージを受信する第2受信ステップと、
前記第3メッセージを送信した時刻と、前記第4メッセージに含まれる前記第3メッセージを前記マスタ装置が受信した時刻とに基づいて、前記伝搬遅延時間を算出する遅延時間算出ステップと、
前記オフセット時間差および前記伝搬遅延時間に基づいて、前記タイマの時刻を補正する補正ステップと、
を備えることを特徴とする。
The time synchronization method according to the fourth aspect of the present invention is:
In an electronic device system including a master device that performs time synchronization via a network and two or more slave devices, the oscillator includes a clock that generates a clock for generating time information, and a counter that counts up at a predetermined interval A determination step of determining whether or not the master device is busy performing time synchronization with another slave device when the value of the counter executed by the slave device exceeds a predetermined value;
A first transmission step of transmitting a first message requesting the master device to start time synchronization when it is determined that the busy state is not determined in the determination step;
A third receiving step for receiving the first message from the slave device, which is executed by the master device;
When the first message is received from the slave device in the third receiving step, a second message for obtaining an offset time difference between the master device and the slave device and a time at which the second message is transmitted are included. A third transmission step of transmitting a follow-up message to a target slave device that is the slave device of the other party that received the first message;
A fourth transmission step of transmitting a fifth message indicating the busy state to the slave device other than the target slave device when the second message is transmitted to the target slave device in the third transmission step;
A first receiving step of receiving the second message and the follow-up message from the master device, executed by the target slave device;
Offset calculating step for calculating the offset time difference based on the time when the second message is received in the first receiving step and the time when the second message included in the follow-up message is transmitted from the master device. When,
A second message for transmitting a third message for determining a propagation delay time between the master device and the slave device after receiving the follow-up message from the master device in the first receiving step; Sending step;
A fourth reception step of receiving the third message from the target slave device, executed by the master device;
When receiving the third message from the target slave device in the fourth reception step, a fifth transmission step of transmitting the fourth message including the time when the third message is received to the target slave device;
A second receiving step for receiving the fourth message from the master device, executed by the target slave device;
A delay time calculating step of calculating the propagation delay time based on a time when the third message is transmitted and a time when the master device receives the third message included in the fourth message;
A correction step of correcting the time of the timer based on the offset time difference and the propagation delay time;
It is characterized by providing.

本発明の第5の観点に係るプログラムは、コンピュータを、
時刻情報を生成するタイマ、
前記時刻情報を生成するためのクロックを発生させる発振器、
所定の間隔でカウントアップするカウンタ、
前記カウンタの値が所定の値を超えた場合に、前記マスタ装置が他のスレーブ装置と時刻同期を行っているビジー状態であるか否かを判定する判定手段、
前記判定手段が前記ビジー状態でないと判定した場合、前記マスタ装置に時刻同期の開始を要求する第1メッセージを送信する第1送信手段、
前記マスタ装置から、前記マスタ装置と前記スレーブ装置との間のオフセット時間差を求めるための第2メッセージと、前記第2メッセージが前記マスタ装置から送信された時刻を含むフォローアップメッセージとを受信する第1受信手段、
前記第1受信手段が前記第2メッセージを受信した時刻と、前記フォローアップメッセージに含まれる前記第2メッセージが前記マスタ装置から送信された時刻とに基づいて、前記オフセット時間差を算出するオフセット算出手段、
前記第1受信手段が前記マスタ装置から前記フォローアップメッセージを受信したのちに、前記マスタ装置に前記マスタ装置と前記スレーブ装置との間の伝搬遅延時間を求めるための第3メッセージを送信する第2送信手段、
前記マスタ装置から前記第3メッセージを前記マスタ装置が受信した時刻を含む第4メッセージを受信する第2受信手段、
前記第2送信手段が前記第3メッセージを送信した時刻と、前記第4メッセージに含まれる前記第3メッセージを前記マスタ装置が受信した時刻とに基づいて、前記伝搬遅延時間を算出する遅延時間算出手段、および、
前記オフセット時間差および前記伝搬遅延時間に基づいて、前記タイマの時刻を補正する補正手段、
として機能させることを特徴とする。
A program according to a fifth aspect of the present invention provides a computer,
A timer that generates time information,
An oscillator for generating a clock for generating the time information;
A counter that counts up at predetermined intervals,
A determination unit that determines whether or not the master device is busy performing time synchronization with another slave device when the value of the counter exceeds a predetermined value;
A first transmission unit configured to transmit a first message requesting the master device to start time synchronization when the determination unit determines that the busy state is not present;
A second message for receiving an offset time difference between the master device and the slave device and a follow-up message including a time when the second message is transmitted from the master device from the master device. 1 receiving means,
Offset calculating means for calculating the offset time difference based on the time when the first receiving means receives the second message and the time when the second message included in the follow-up message is transmitted from the master device. ,
After the first receiving means receives the follow-up message from the master device, a second message is transmitted to the master device for determining a propagation delay time between the master device and the slave device. Transmission means,
Second receiving means for receiving a fourth message including a time at which the master device has received the third message from the master device;
Delay time calculation for calculating the propagation delay time based on the time at which the second transmission means transmits the third message and the time at which the master device receives the third message included in the fourth message. Means and
Correction means for correcting the time of the timer based on the offset time difference and the propagation delay time;
It is made to function as.

本発明によれば、マスタ装置と複数のスレーブ装置とのネットワークを介する時刻同期において、スレーブ装置の初期起動時の時刻同期精度の低下を防ぎ、ネットワークへの負荷を軽減し、かつ、時刻同期までの時間を短縮することができる。   According to the present invention, in time synchronization via a network between a master device and a plurality of slave devices, a decrease in time synchronization accuracy at the time of initial startup of the slave device is prevented, a load on the network is reduced, and time synchronization is also achieved. Can be shortened.

本発明の実施の形態に係る電子機器システムの構成例を示すブロック図である。It is a block diagram which shows the structural example of the electronic device system which concerns on embodiment of this invention. PTPを用いた時刻同期を説明する図である。It is a figure explaining the time synchronization using PTP. 実施の形態に係るスレーブ装置の構成の一例を示すブロック図である。It is a block diagram which shows an example of a structure of the slave apparatus which concerns on embodiment. 実施の形態に係る電子機器システムにおける時刻同期の一例を説明する図である。It is a figure explaining an example of the time synchronization in the electronic device system which concerns on embodiment. 実施の形態に係るスレーブ装置の時刻同期の動作の一例を示すフローチャートである。It is a flowchart which shows an example of the operation | movement of the time synchronization of the slave apparatus which concerns on embodiment. 実施の形態に係るスレーブ装置の判定処理の動作の一例を示すフローチャートである。It is a flowchart which shows an example of the operation | movement of the determination process of the slave apparatus which concerns on embodiment. 他の実施の形態に係るスレーブ装置の時刻同期の動作の一例を示すフローチャートである。It is a flowchart which shows an example of the operation | movement of the time synchronization of the slave apparatus which concerns on other embodiment. 他の実施の形態に係るスレーブ装置の時刻同期の動作の一例を示すフローチャートである。It is a flowchart which shows an example of the operation | movement of the time synchronization of the slave apparatus which concerns on other embodiment. 他の実施の形態に係る電子機器システムにおける時刻同期の一例を説明する図である。It is a figure explaining an example of the time synchronization in the electronic device system which concerns on other embodiment. 実施の形態に係るスレーブ装置のハードウェア構成例を示すブロック図である。It is a block diagram which shows the hardware structural example of the slave apparatus which concerns on embodiment.

本実施の形態において、第1メッセージはAnnounce Message 1、第2メッセージはAnnounce Message 2、フォローアップメッセージはFollow Up Message、第3メッセージはDelay Request Message、第4メッセージはDelay Response Message、第5メッセージは、Announce Message 3である。   In this embodiment, the first message is Announce Message 1, the second message is Announce Message 2, the follow-up message is Follow Up Message, the third message is Delay Request Message, the fourth message is Delay Response Message, and the fifth message is Announce Message 3.

以下、本発明を実施するための形態について図を参照して詳細に説明する。なお図中、同一または同等の部分には同一の符号を付す。   Hereinafter, embodiments for carrying out the present invention will be described in detail with reference to the drawings. In the drawings, the same or equivalent parts are denoted by the same reference numerals.

図1は、本発明の実施の形態に係る電子機器システムの構成例を示すブロック図である。電子機器システム100は、ネットワーク上のマスタ装置M1とX個のスレーブ装置S1〜SXとから構成される。マスタ装置M1は、スレーブ装置S1〜SXに対してそれぞれパス21〜Xで接続されており、それぞれのスレーブ装置S1〜SXに対して時刻同期を行う。本実施の形態では、時刻同期としてIEEE1588を採用しており、PTPによって時刻同期を行う。PTPでは、システムが備えるすべての装置のタイマのうち、最も正確なタイマに同期する。すなわち、最も正確なタイマを有する装置をマスタ装置とし、それ以外の装置をスレーブ装置とする。このため、マスタ装置は変更される可能性がある。   FIG. 1 is a block diagram illustrating a configuration example of an electronic device system according to an embodiment of the present invention. The electronic device system 100 includes a master device M1 on the network and X slave devices S1 to SX. The master device M1 is connected to the slave devices S1 to SX via paths 21 to X, respectively, and performs time synchronization with respect to the respective slave devices S1 to SX. In this embodiment, IEEE 1588 is adopted as time synchronization, and time synchronization is performed by PTP. PTP synchronizes with the most accurate timer among the timers of all devices included in the system. That is, the device having the most accurate timer is the master device, and the other devices are slave devices. For this reason, the master device may be changed.

図2は、PTPを用いる時刻同期を説明する図である。IEEE1588規格で定義されたPTPによる時刻同期の一般的な動作フローの例を示す。ここでは、マスタ装置がSync Messageを送出したときのマスタ装置の時刻を00:00として説明する。まず、マスタ装置から時刻00:00にマスタ装置とスレーブ装置との間のオフセット時間差を求めるためのSync Messageをスレーブ装置へ送出する。次に、マスタ装置から時刻00:00にSync Messageを送出したことを伝えるFollow Up Messageをスレーブ装置へ送出する。   FIG. 2 is a diagram for explaining time synchronization using PTP. An example of a general operation flow of time synchronization by PTP defined in the IEEE 1588 standard is shown. Here, it is assumed that the time of the master device when the master device sends a Sync Message is 0:00. First, the master device transmits a Sync Message for obtaining an offset time difference between the master device and the slave device to the slave device at time 0:00. Next, a Follow Up Message is transmitted from the master device to the slave device indicating that the Sync Message has been transmitted at time 0:00.

スレーブ装置は、時刻00:06にSync Messageを受信し、時刻00:08にFollow UP Messageを受信する。スレーブ装置は、Sync Messageを受信した時刻00:06と、Follow UP Messageに含まれるマスタ装置からSync Messageが送出された時刻00:00とに基づいて、オフセット時間差{00:06−00:00=00:06}を算出し、時刻00:08からオフセット時間差00:06を引いて、時刻00:02にするオフセット補正を行なう。   The slave device receives a Sync Message at time 00:06 and receives a Follow UP Message at time 00:08. The slave device, based on the time 00:06 at which the Sync Message is received and the time 00:00 at which the Sync Message is transmitted from the master device included in the Follow UP Message, the offset time difference {00: 06-00: 00 = 00:06} is calculated, and offset correction 00:06 is subtracted from time 00:08 to perform offset correction at time 00:02.

次に、マスタ装置とスレーブ装置の間の伝搬遅延時間を求めるために、スレーブ装置からオフセット補正後の時刻00:06にマスタ装置とスレーブ装置との間の伝搬遅延時間を求めるためのDelay Request Messageをマスタ装置へ送出する。マスタ装置は、時刻00:12にDelay Request Messageを受信したことを伝えるDelay Response Messageを時刻00:13にスレーブ装置へ送出する。   Next, in order to obtain the propagation delay time between the master device and the slave device, a Delay Request Message for obtaining the propagation delay time between the master device and the slave device at time 00:06 after offset correction from the slave device. Is sent to the master device. The master device sends a Delay Response Message that tells that the Delay Request Message has been received at time 00:12 to the slave device at time 00:13.

スレーブ装置は、オフセット補正後の時刻00:13にDelay Response Messageを受信する。スレーブ装置は、Delay Request Messageを送信したオフセット補正後の時刻00:06と、Delay Response Messageに含まれるマスタ装置がDelay Request Messageを受信した時刻00:12とに基づいて、マスタ装置とスレーブ装置との伝搬遅延時間{(00:12−00:06)/2=00:03}を算出し、オフセット補正後の時刻00:15に伝搬遅延時間00:03を足して、時刻00:18にする伝搬遅延補正を行なう。以上によりマスタ装置とスレーブ装置の時刻同期が行なわれる。   The slave device receives the Delay Response Message at time 00:13 after the offset correction. Based on the time 00:06 after offset correction at which the Delay Request Message was transmitted and the time 00:12 at which the master device included in the Delay Response Message received the Delay Request Message, the slave device The propagation delay time {(00: 12-00: 06) / 2 = 00: 03} is calculated, and the propagation delay time 00:03 is added to the time 00:15 after offset correction to obtain the time 00:18. Propagation delay correction is performed. Thus, time synchronization between the master device and the slave device is performed.

図3は、実施の形態に係るスレーブ装置の構成の一例を示すブロック図である。スレーブ装置S1は、カウンタ11、判定部12、送信部13、受信部14、発振器15、タイマ16および処理部17を備える。スレーブ装置S2〜SXも同様の構成である。   FIG. 3 is a block diagram illustrating an example of a configuration of the slave device according to the embodiment. The slave device S1 includes a counter 11, a determination unit 12, a transmission unit 13, a reception unit 14, an oscillator 15, a timer 16, and a processing unit 17. The slave devices S2 to SX have the same configuration.

カウンタ11は、スレーブ装置S1を起動すると、所定の間隔で(たとえば1秒ごと)にカウントアップする。カウンタ11は、カウンタ値を判定部12に送る。   When the slave device S1 is activated, the counter 11 counts up at a predetermined interval (for example, every second). The counter 11 sends the counter value to the determination unit 12.

判定部12は、カウンタ11から受け取ったカウンタ値が所定の値以上になった場合、マスタ装置M1が他のスレーブ装置と時刻同期を行っているビジー状態であるか否かを判定する判定処理を行う。所定の値とは、たとえば、タイマ16にクロックを供給する発振器15が安定するまでの時間を示す値、あるいは、発振器15が安定する時間から判定処理を実行する最短時間を引いた時間を示す値であって、あらかじめ設定されている。   When the counter value received from the counter 11 exceeds a predetermined value, the determination unit 12 performs a determination process for determining whether the master device M1 is in a busy state in which time synchronization is performed with another slave device. Do. The predetermined value is, for example, a value indicating a time until the oscillator 15 that supplies a clock to the timer 16 is stabilized, or a value indicating a time obtained by subtracting the shortest time for executing the determination process from the time when the oscillator 15 is stabilized. And it is preset.

送信部13は、マスタ装置M1に各種Messageを送信する。送信部13は、判定部12がビジー状態でないと判定した場合に、時刻同期の開始を要求するAnnounce Message 1をマスタ装置M1に送信する。送信部13は、判定部12がビジー状態であると判定した場合は、Announce Message 1をマスタ装置M1に送信しない。   The transmission unit 13 transmits various messages to the master device M1. When the determination unit 12 determines that the determination unit 12 is not busy, the transmission unit 13 transmits Announce Message 1 for requesting the start of time synchronization to the master device M1. When the determination unit 12 determines that the determination unit 12 is busy, the transmission unit 13 does not transmit the Announce Message 1 to the master device M1.

受信部14は、マスタ装置M1から各種メッセージを受信する。受信部14は、マスタ装置M1から、マスタ装置M1とスレーブ装置S1との間のオフセット時間差を求めるためのAnnounce Message 2を受信し、Announce Message 2がマスタ装置M1から送信された時刻を含むFollow UP Messageを受信する。受信部14は、マスタ装置M1から受信したAnnounce Message 2およびFollow UP Messageを処理部17に送る。   The receiving unit 14 receives various messages from the master device M1. The receiving unit 14 receives an Announce Message 2 for obtaining an offset time difference between the master device M1 and the slave device S1 from the master device M1, and includes a Follow UP including the time when the Announce Message 2 is transmitted from the master device M1. Receive a Message. The receiving unit 14 sends the Announce Message 2 and Follow UP Message received from the master device M1 to the processing unit 17.

送信部13は、受信部14がマスタ装置M1からFollow UP Messageを受信すると、送信部13は、マスタ装置M1とスレーブ装置S1との間の伝搬遅延時間を求めるためのDelay Request Messageをマスタ装置M1に送信する。   When the receiving unit 14 receives the Follow UP Message from the master device M1, the transmitting unit 13 sends a Delay Request Message for obtaining a propagation delay time between the master device M1 and the slave device S1 to the master device M1. Send to.

受信部14は、マスタ装置M1がDelay Request Messageを受信した時刻を含むDelay Response Messageを受信する。受信部14は、マスタ装置M1から受信したDelay Response Messageを処理部17に送る。また、受信部14は、マスタ装置M1からビジー状態であることを示すAnnounce Message 3を受信した場合は、Announce Message 3を判定部12に送る。   The receiving unit 14 receives a Delay Response Message including the time when the master device M1 receives the Delay Request Message. The receiving unit 14 sends the Delay Response Message received from the master device M1 to the processing unit 17. In addition, when the receiving unit 14 receives the Announce Message 3 indicating that the master device M1 is busy, the receiving unit 14 sends the Announce Message 3 to the determination unit 12.

送信部13は、判定部12がビジー状態でないと判定してから、時刻同期のための各Messageを送信するので、衝突を考慮する必要がなく、通常の時刻パケット通信よりも送信間隔を短くして送信することができる。   Since the transmission unit 13 transmits each message for time synchronization after the determination unit 12 determines that it is not busy, there is no need to consider a collision, and the transmission interval is made shorter than normal time packet communication. Can be sent.

発振器15は、時刻情報を生成するためのクロックを発生させてタイマ16に供給する。   The oscillator 15 generates a clock for generating time information and supplies it to the timer 16.

タイマ16は、発振器15から供給されるクロックに基づいて計時し、時刻情報を生成する。なお、タイマ16はカウンタ11により構成され、カウンタ11は、発振器15が発生させるクロックに従ってカウントアップしてもよい。   The timer 16 measures time based on the clock supplied from the oscillator 15 and generates time information. Note that the timer 16 may include a counter 11, and the counter 11 may count up according to a clock generated by the oscillator 15.

処理部17は、受信部14から受け取ったFollow UP Messageに含まれるAnnounce Message 2がマスタ装置M1から送信された時刻と、受信部14がAnnounce Message 2を受信した時刻との差に基づいて、オフセット時間差を算出し、タイマ16の時刻のオフセット補正を行う。また、処理部17は、受信部14から受け取ったDelay Response Messageに含まれるマスタ装置M1がDelay Request Messageを受信した時刻と、送信部13がDelay Request Messageを送信した時刻との差に基づいて、伝搬遅延時間を算出し、タイマ16の伝搬時間補正を行う。このようにして、処理部17は、タイマ16の時刻とマスタ装置M1の時刻とを同期させる。   The processing unit 17 performs an offset based on the difference between the time when the Announce Message 2 included in the Follow UP Message received from the receiving unit 14 is transmitted from the master device M1 and the time when the receiving unit 14 receives the Announce Message 2. The time difference is calculated and the offset of the time of the timer 16 is corrected. Further, the processing unit 17 is based on the difference between the time when the master device M1 included in the Delay Response Message received from the receiving unit 14 receives the Delay Request Message and the time when the transmitting unit 13 transmits the Delay Request Message. The propagation delay time is calculated and the propagation time of the timer 16 is corrected. In this way, the processing unit 17 synchronizes the time of the timer 16 with the time of the master device M1.

図4は、実施の形態に係る電子機器システムにおける時刻同期を説明する図である。図4の例では、便宜上、電子機器システム100は、マスタ装置1とスレーブ装置S1およびスレーブ装置S2とで構成され、スレーブ装置S1の時刻同期を実行する場合を示す。   FIG. 4 is a diagram for explaining time synchronization in the electronic device system according to the embodiment. In the example of FIG. 4, for convenience, the electronic device system 100 includes a master device 1, a slave device S <b> 1, and a slave device S <b> 2, and shows a case where time synchronization of the slave device S <b> 1 is executed.

スレーブ装置S1が起動すると、カウンタ11がカウントアップを開始する。カウンタ11のカウンタ値がN以上になってから、受信部14がAnnounce Message 3を受信せずに所定の時間(10秒)経過すると、判定部12は、マスタ装置M1が他のスレーブ装置と時刻同期を行っているビジー状態ではないと判定する。カウンタ値Nは、タイマ16にクロックを供給する発振器15が安定するまでの時間を示す値、あるいは、発振器15が安定する時間から判定処理を実行する最短時間を引いた時間を示す値である。   When the slave device S1 is activated, the counter 11 starts counting up. When a predetermined time (10 seconds) elapses without the reception unit 14 receiving the Announce Message 3 after the counter value of the counter 11 becomes equal to or greater than N, the determination unit 12 determines that the master device M1 It is determined that the synchronization is not busy. The counter value N is a value indicating a time until the oscillator 15 that supplies a clock to the timer 16 is stabilized, or a value indicating a time obtained by subtracting the shortest time for executing the determination process from the time when the oscillator 15 is stabilized.

判定部12がビジー状態ではないと判定した時刻00:15に、送信部13は、時刻同期の開始を要求するAnnounce Message 1をマスタ装置M1に送信する。マスタ装置M1は、時刻00:03にAnnounce Message 1を受信すると、時刻00:04に、マスタ装置M1とスレーブ装置S1との間のオフセット時間差を求めるためのAnnounce Message 2をスレーブ装置S1に対して送信する。同時に、マスタ装置M1がビジー状態になったことを示すAnnounce Message 3をスレーブ装置S2に対して送信する。そして、Announce Message 2を送出した時刻00:04を含むFollow UP Messageを時刻00:05にスレーブ装置S1へ送出する。   At time 00:15 when the determination unit 12 determines that the state is not busy, the transmission unit 13 transmits an Announce Message 1 requesting the start of time synchronization to the master device M1. When master device M1 receives Announce Message 1 at time 00:03, master device M1 provides Announce Message 2 for obtaining an offset time difference between master device M1 and slave device S1 to slave device S1 at time 00:04. Send. At the same time, an Announce Message 3 indicating that the master device M1 is busy is transmitted to the slave device S2. Then, a Follow UP Message including the time 00:04 at which the Announce Message 2 is transmitted is transmitted to the slave device S1 at the time 00:05.

スレーブ装置S1の受信部14は、時刻00:22にAnnounce Message 2を受信し、時刻00:23にFollow UP Messageを受信する。処理部17は、受信部14がAnnounce Message 2を受信した時刻00:22と、Follow UP Messageに含まれるマスタ装置からAnnounce Message 2が送信された時刻00:04とに基づいて、マスタ装置とのオフセット時間差{00:22−00:04=00:18}を算出し、時刻00:23からオフセット時間差00:18を引いて、時刻00:05にするオフセット補正を行なう。   The receiving unit 14 of the slave device S1 receives the Announce Message 2 at time 00:22 and receives the Follow UP Message at time 00:23. Based on the time 00:22 when the receiving unit 14 receives the Announce Message 2 and the time 00:04 when the Announce Message 2 is transmitted from the master device included in the Follow UP Message, the processing unit 17 Offset time difference {00: 22−00: 04 = 00: 18} is calculated, and offset correction is performed by subtracting offset time difference 00:18 from time 00:23 to time 00:05.

次に、スレーブ装置S1の送信部13は、オフセット補正後の時刻00:06にマスタ装置とスレーブ装置の間の伝搬遅延時間を求めるためのDelay Request Messageをマスタ装置M1に送信する。マスタ装置は、Delay Request Messageを受信した時刻00:12を含むDelay Response Messageを時刻00:13にスレーブ装置S1に送信する。   Next, the transmission unit 13 of the slave device S1 transmits a Delay Request Message for obtaining a propagation delay time between the master device and the slave device to the master device M1 at time 00:06 after the offset correction. The master device transmits a Delay Response Message including time 00:12 at which the Delay Request Message is received to the slave device S1 at time 00:13.

スレーブ装置S1の受信部14は、オフセット補正後の時刻00:13にDelay Response Messageを受信する。処理部17は、送信部13がDelay Request Messageを送信したオフセット補正後の時刻00:06と、Delay Response Messageに含まれるマスタ装置M1がDelay Request Messageを受信した時刻00:12とに基づいて、マスタ装置M1とスレーブ装置S1との伝搬遅延時間{(00:12−00:06)/2=00:03}を算出し、オフセット補正後の時刻00:15に伝搬遅延時間00:03を足して、時刻00:18にする伝搬遅延補正を行なう。以上によりマスタ装置とスレーブ装置の時刻同期が行なわれる。   The receiving unit 14 of the slave device S1 receives the Delay Response Message at time 00:13 after the offset correction. Based on the time 00:06 after the offset correction when the transmission unit 13 transmitted the Delay Request Message and the time 00:12 when the master device M1 included in the Delay Response Message received the Delay Request Message, The propagation delay time {(00: 12-00: 06) / 2 = 00: 03} between the master device M1 and the slave device S1 is calculated, and the propagation delay time 00:03 is added to the time 00:15 after offset correction. Thus, propagation delay correction at time 00:18 is performed. Thus, time synchronization between the master device and the slave device is performed.

一方、スレーブ装置S2は、カウンタ11のカウンタ値がN以上になってから、所定の時間(10秒)が経過するよりも前の時刻00:02にマスタ装置M1からAnnounce Message 3を受信する。これにより、判定部12は、ビジー状態であると判定する。その後、所定の時間(10秒)が経過する時刻00:12までにAnnounce Message 3を受信しないので、判定部12は、ビジー状態が解除されたと判定する。判定部12がビジー状態でないと判定したので、送信部13は、時刻00:13に時刻同期の開始を要求するAnnounce Message 1をマスタ装置M1に送信する。   On the other hand, the slave device S2 receives the Announce Message 3 from the master device M1 at time 00:02 before a predetermined time (10 seconds) elapses after the counter value of the counter 11 becomes N or more. Thereby, the determination part 12 determines with it being a busy state. Thereafter, since the Announce Message 3 is not received by the time 00:12 when the predetermined time (10 seconds) elapses, the determination unit 12 determines that the busy state has been released. Since the determination unit 12 determines that it is not busy, the transmission unit 13 transmits an Announce Message 1 requesting the start of time synchronization to the master device M1 at time 00:13.

図5は、実施の形態に係るスレーブ装置の時刻同期の動作の一例を示すフローチャートである。ここでは、スレーブ装置S1の時刻同期の動作の一例を説明する。スレーブ装置S2〜SXも同様の時刻同期の動作を行う。スレーブ装置S1の電源が起動すると同時にスレーブ装置S1内部のカウンタ11が起動し(ステップS11)、カウントアップを開始する。カウンタ値がN以上になっていない場合には(ステップS12;NO)、発振器15の安定度が悪く時刻同期に使用できないものとし、時刻同期を開始せずにステップS12を繰り返す。カウンタ値Nは、タイマ16にクロックを供給する発振器15が安定するまでの時間を示す値、あるいは、発振器15が安定する時間から判定処理を実行する最短時間を引いた時間を示す値である。   FIG. 5 is a flowchart illustrating an example of the time synchronization operation of the slave device according to the embodiment. Here, an example of the operation of time synchronization of the slave device S1 will be described. The slave devices S2 to SX perform the same time synchronization operation. At the same time as the power supply of the slave device S1 is activated, the counter 11 in the slave device S1 is activated (step S11), and count-up is started. If the counter value is not greater than or equal to N (step S12; NO), it is assumed that the stability of the oscillator 15 is poor and cannot be used for time synchronization, and step S12 is repeated without starting time synchronization. The counter value N is a value indicating a time until the oscillator 15 that supplies a clock to the timer 16 is stabilized, or a value indicating a time obtained by subtracting the shortest time for executing the determination process from the time when the oscillator 15 is stabilized.

カウンタ値がN以上になった場合には(ステップS12;YES)、発振器15の安定度が時刻同期に使用できる安定度に達したものとし、判定部12は、マスタ装置M1が他のスレーブ装置と時刻同期を行っているビジー状態であるか否かを判定する(ステップS13)。   When the counter value is greater than or equal to N (step S12; YES), it is assumed that the stability of the oscillator 15 has reached the stability that can be used for time synchronization, and the determination unit 12 determines that the master device M1 is another slave device. It is determined whether or not the time is synchronized with the time (step S13).

判定部12がビジー状態であると判定した場合(ステップS13;YES)、マスタ装置M1のビジー状態が解除されるまで、ステップS13を繰り返す。判定部12がビジー状態でないと判定した場合(ステップS13;NO)、送信部13は、時刻同期の開始を要求するAnnounce Message 1をマスタ装置M1に送信する(ステップS14)。   When the determination part 12 determines with it being a busy state (step S13; YES), step S13 is repeated until the busy state of the master apparatus M1 is cancelled | released. When the determination unit 12 determines that it is not busy (step S13; NO), the transmission unit 13 transmits Announce Message 1 for requesting the start of time synchronization to the master device M1 (step S14).

マスタ装置M1は、スレーブ装置S1からのAnnounce Message 1を受信すると、マスタ装置M1とスレーブ装置S1との間のオフセット時間差を求めるためのAnnounce Message 2をスレーブ装置S1に対して送信する。同時に、マスタ装置M1がビジー状態になったことを示すAnnounce Message 3をその他のスレーブ装置に対して送信する。あるいは、マスタ装置M1は、ステーブ装置S1との時刻同期を開始してビジー状態になったことを、その他のスレーブ装置に報知するために、ステーブ装置S1を宛先とするAnnounce Message 2をブロードキャストしてもよい。そして、マスタ装置M1は、Announce Message 2を送信した時刻を含むFollow UP Messageをスレーブ装置S1に送信する。   When master device M1 receives Announce Message 1 from slave device S1, master device M1 transmits Announce Message 2 for obtaining an offset time difference between master device M1 and slave device S1 to slave device S1. At the same time, an Announce Message 3 indicating that the master device M1 is in a busy state is transmitted to the other slave devices. Alternatively, the master device M1 broadcasts an Announce Message 2 destined for the stave device S1 in order to notify other slave devices that time synchronization with the stave device S1 has started and is in a busy state. Also good. Then, the master device M1 transmits a Follow UP Message including the time when the Announce Message 2 is transmitted to the slave device S1.

マスタ装置M1は、複数のスレーブ装置からAnnounce Message 1を同時に受信した場合は、これらのスレーブ装置のうちいずれかを無作為に選出し、選出したスレーブ装置に対してAnnounce Message 2を送信してもよい。この場合、マスタ装置M1は、選出しなかったスレーブ装置に対してAnnounce Message 3を送信する。選出されなかったスレーブ装置は、Announce Message 3を受信すると、マスタ装置M1がビジー状態であると判定し、その後マスタ装置M1がビジー状態でなくなったと判定した場合にあらためてAnnounce Message 1を送信する。   When the master device M1 receives the Announce Message 1 from a plurality of slave devices at the same time, the master device M1 randomly selects any one of these slave devices and transmits the Announce Message 2 to the selected slave device. Good. In this case, master device M1 transmits Announce Message 3 to the slave device that has not been selected. When the slave device that has not been selected receives the Announce Message 3, it determines that the master device M1 is busy, and then transmits the Announce Message 1 again when it is determined that the master device M1 is no longer busy.

スレーブ装置S1の受信部14がマスタ装置M1からAnnounce Message 2を受信し(ステップS15)、マスタ装置M1からAnnounce Message 2が送信された時刻を含むFollow UP Messageを受信すると(ステップS16)、処理部17は、Follow UP Messageに含まれるマスタ装置M1からAnnounce Message 2が送信された時刻と、受信部14がAnnounce Message 2を受信した時刻とに基づいてオフセット時間差を算出し(ステップS17)、タイマ16のオフセット補正を行う(ステップS18)。   When the receiving unit 14 of the slave device S1 receives the Announce Message 2 from the master device M1 (Step S15) and receives a Follow UP Message including the time when the Announce Message 2 is transmitted from the master device M1 (Step S16), the processing unit 17 calculates an offset time difference based on the time when the Announce Message 2 is transmitted from the master device M1 included in the Follow UP Message and the time when the receiving unit 14 receives the Announce Message 2 (Step S17). Offset correction is performed (step S18).

次に、送信部13は、マスタ装置M1とスレーブ装置S1との間の伝搬遅延時間を求めるためのDelay Request Messageを通常の時刻パケット通信よりも短い送信間隔でマスタ装置M1に送信する(ステップS19)。ここでの送信間隔とは、受信部14がFollow UP Messageを受信してから送信部13がDelay Request Messageを送信するまでの時間である。他のスレーブ装置からマスタ装置M1にMessageが送信されることがないので、通常の時刻パケット通信よりも送信間隔を短くしたDelay Request Messageをマスタ装置M1に送信することが可能となる。これにより、時刻同期完了までの期間を通常よりも短くすることが可能となる。   Next, the transmission unit 13 transmits a Delay Request Message for obtaining a propagation delay time between the master device M1 and the slave device S1 to the master device M1 at a transmission interval shorter than normal time packet communication (step S19). ). Here, the transmission interval is the time from when the receiving unit 14 receives the Follow UP Message to when the transmitting unit 13 transmits the Delay Request Message. Since a Message is not transmitted from another slave device to the master device M1, it is possible to transmit a Delay Request Message having a transmission interval shorter than that of normal time packet communication to the master device M1. As a result, it is possible to shorten the period until the time synchronization is completed.

マスタ装置M1は、スレーブ装置S1からのDelay Request Messageを受信すると、Delay Request Messageを受信した時刻を含むDelay Response Messageをスレーブ装置S1に送信する。   When receiving the Delay Request Message from the slave device S1, the master device M1 transmits a Delay Response Message including the time when the Delay Request Message is received to the slave device S1.

スレーブ装置S1の受信部14がマスタ装置M1からDelay Response Messageを受信すると(ステップS20)、処理部17は、Delay Response Messageに含まれるマスタ装置M1がDelay Request Messageを受信した時刻と、送信部13がDelay Request Messageを送信した時刻とに基づいて伝搬遅延時間を算出し(ステップS21)、タイマ16の伝搬遅延補正を行い(ステップS22)、処理を終了する。   When the reception unit 14 of the slave device S1 receives the Delay Response Message from the master device M1 (Step S20), the processing unit 17 transmits the time when the master device M1 included in the Delay Response Message receives the Delay Request Message, and the transmission unit 13 Calculates the propagation delay time based on the time when the Delay Request Message is transmitted (step S21), corrects the propagation delay of the timer 16 (step S22), and ends the process.

図6は、実施の形態に係るスレーブ装置の判定処理の動作の一例を示すフローチャートである。ここでは、スレーブ装置S1が図6のステップS13行う判定処理の動作の一例を説明する。スレーブ装置S2〜SXも同様の判定処理の動作を行う。スレーブ装置S1の受信部14がマスタ装置M1からAnnounce Message 3を受信した場合(ステップS31;YES)、判定部12は、ビジー状態であると判定し(ステップS32)、ステップS33を実行する。受信部14がマスタ装置M1からAnnounce Message 3を受信しない場合(ステップS31;NO)、所定の時間経過したか否かを判定する(ステップS33)。   FIG. 6 is a flowchart illustrating an example of operation of determination processing of the slave device according to the embodiment. Here, an example of the operation of the determination process performed by the slave device S1 in step S13 of FIG. 6 will be described. The slave devices S2 to SX perform the same determination processing operation. When the receiving unit 14 of the slave device S1 receives the Announce Message 3 from the master device M1 (step S31; YES), the determining unit 12 determines that the busy state is set (step S32) and executes step S33. When the receiving unit 14 does not receive the Announce Message 3 from the master device M1 (step S31; NO), it is determined whether or not a predetermined time has passed (step S33).

ここでの所定の時間とは、マスタ装置M1からAnnounce Message 3が送信される間隔の最大値よりも長い時間である。図5のフローのように、ステップS18〜ステップS20を1度のみ実行することが決まっている場合は、Announce Message 3が送信されてから時刻同期が終了するまでの時間の最大値よりも長い時間に設定する。すなわち、所定の時間とは、マスタ装置M1のビジー状態が解除されたと想定しうる時間である。   The predetermined time here is a time longer than the maximum value of the interval at which the Announce Message 3 is transmitted from the master device M1. When it is determined that steps S18 to S20 are executed only once as in the flow of FIG. 5, the time is longer than the maximum time from when the Announce Message 3 is transmitted until the time synchronization ends. Set to. That is, the predetermined time is a time that can be assumed that the busy state of the master device M1 is released.

所要時間が経過していない場合には(ステップS33;NO)、ステップS31に戻り、ステップS31〜ステップS33を繰り返す。所要時間が経過した場合には(ステップS33;YES)、ビジー状態でないと判定し(ステップS34)、処理を終了する。   If the required time has not elapsed (step S33; NO), the process returns to step S31, and steps S31 to S33 are repeated. If the required time has elapsed (step S33; YES), it is determined that the state is not busy (step S34), and the process ends.

以上説明したように、本実施の形態の電子機器システム100によれば、スレーブ装置の電源起動後の発振器が安定するまでの所定の時間はマスタ装置との時刻パケット通信を実施しないようにしたことにより、初期起動時の時刻同期精度の劣化を防ぐことができ、ネットワークへの負荷を軽減することができる。さらに、マスタ装置がビジー状態でないことを確認してから、時刻同期を開始するので、衝突を考慮する必要がなく、通常の時刻パケット通信よりも送信間隔を短くしてメッセージを送信することができ、時刻同期までの時間を短縮することができる。   As described above, according to the electronic device system 100 of the present embodiment, the time packet communication with the master device is not performed for a predetermined time until the oscillator is stabilized after the slave device is powered on. Thus, it is possible to prevent deterioration in time synchronization accuracy at the time of initial startup, and to reduce the load on the network. Furthermore, since time synchronization is started after confirming that the master device is not busy, there is no need to consider collisions, and messages can be transmitted with a shorter transmission interval than normal time packet communication. The time until time synchronization can be shortened.

上述の実施の形態では、スレーブ装置は、発振器15が安定するのを待って、時刻同期を行った。しかし本発明はこれに限らず、発振器15が安定する前から伝搬遅延時間の算出を繰り返し行って、所定の回数行ったときに、その結果から発振器15が安定したときの伝搬遅延時間を予測してもよい。また、発振器15が安定する前から伝搬遅延時間の算出を繰り返し行って、前回の伝搬遅延時間と今回の伝搬遅延時間との差が閾値以下になった場合に、伝搬遅延時間の算出の繰り返しを終了してもよい。   In the above-described embodiment, the slave device performs time synchronization after the oscillator 15 is stabilized. However, the present invention is not limited to this, and when the propagation delay time is repeatedly calculated before the oscillator 15 is stabilized and is performed a predetermined number of times, the propagation delay time when the oscillator 15 is stabilized is predicted from the result. May be. Further, the calculation of the propagation delay time is repeatedly performed before the oscillator 15 is stabilized, and the calculation of the propagation delay time is repeated when the difference between the previous propagation delay time and the current propagation delay time is equal to or less than the threshold value. You may end.

図7は、他の実施の形態に係るスレーブ装置の時刻同期の動作の一例を示すフローチャートである。図7の実施の形態では、発振器15が安定する前から伝搬遅延時間の算出を繰り返し行って、所定の回数行ったときに、その結果から発振器15が安定したときの伝搬遅延時間を予測する。ここでは、スレーブ装置S1の時刻同期の動作の一例を説明する。スレーブ装置S2〜SXも同様の時刻同期の動作を行う。スレーブ装置S1の電源が起動すると同時にスレーブ装置S1内部のカウンタ11が起動し(ステップS41)、カウントアップを開始する。カウンタ値がN1以上になっていない場合には(ステップS42;NO)、ステップS42を繰り返す。カウンタ値N1は、発振器15が安定する時間よりも短い時間を示す値、あるいは、発振器15が安定する時間から判定処理を実行する最短時間を引いた時間よりも短い時間を示す値である。   FIG. 7 is a flowchart illustrating an example of a time synchronization operation of a slave device according to another embodiment. In the embodiment of FIG. 7, the propagation delay time is repeatedly calculated before the oscillator 15 is stabilized, and when a predetermined number of times is performed, the propagation delay time when the oscillator 15 is stabilized is predicted from the result. Here, an example of the operation of time synchronization of the slave device S1 will be described. The slave devices S2 to SX perform the same time synchronization operation. At the same time as the power supply of the slave device S1 is activated, the counter 11 in the slave device S1 is activated (step S41), and count-up is started. If the counter value is not greater than or equal to N1 (step S42; NO), step S42 is repeated. The counter value N1 is a value indicating a time shorter than the time when the oscillator 15 is stabilized or a value indicating a time shorter than the time obtained by subtracting the shortest time for executing the determination process from the time when the oscillator 15 is stabilized.

カウンタ値がN1以上になった場合には(ステップS42;YES)、判定部12は、マスタ装置M1が他のスレーブ装置と時刻同期を行っているビジー状態であるか否かを判定する(ステップS43)。判定部12がビジー状態であると判定した場合(ステップS43;YES)、マスタ装置M1のビジー状態が解除されるまで、ステップS43を繰り返す。マスタ装置M1がビジー状態でない場合(ステップS43;NO)、送信部13は、時刻同期の開始を要求するAnnounce Message 1をマスタ装置M1に送信する(ステップS44)。   When the counter value is equal to or greater than N1 (step S42; YES), the determination unit 12 determines whether the master device M1 is in a busy state in which time synchronization is performed with another slave device (step S42). S43). When the determination part 12 determines with it being a busy state (step S43; YES), step S43 is repeated until the busy state of the master apparatus M1 is cancelled | released. When the master apparatus M1 is not busy (step S43; NO), the transmission unit 13 transmits Announce Message 1 for requesting the start of time synchronization to the master apparatus M1 (step S44).

マスタ装置M1は、スレーブ装置S1からのAnnounce Message 1を受信すると、マスタ装置M1とスレーブ装置S1との間のオフセット時間差を求めるためのAnnounce Message 2をスレーブ装置S1に対して送信する。同時に、マスタ装置M1がビジー状態になったことを示すAnnounce Message 3をその他のスレーブ装置に対して送信する。あるいは、マスタ装置M1は、ステーブ装置S1との時刻同期を開始してビジー状態になったことを、その他のスレーブ装置に報知するために、ステーブ装置S1を宛先とするAnnounce Message 2をブロードキャストしてもよい。そして、マスタ装置M1は、Announce Message 2を送信した時刻を含むFollow UP Messageをスレーブ装置S1に送信する。   When master device M1 receives Announce Message 1 from slave device S1, master device M1 transmits Announce Message 2 for obtaining an offset time difference between master device M1 and slave device S1 to slave device S1. At the same time, an Announce Message 3 indicating that the master device M1 is in a busy state is transmitted to the other slave devices. Alternatively, the master device M1 broadcasts an Announce Message 2 destined for the stave device S1 in order to notify other slave devices that time synchronization with the stave device S1 has started and is in a busy state. Also good. Then, the master device M1 transmits a Follow UP Message including the time when the Announce Message 2 is transmitted to the slave device S1.

スレーブ装置S1の受信部14がマスタ装置M1からAnnounce Message 2を受信し(ステップS45)、マスタ装置M1からAnnounce Message 2が送信された時刻を含むFollow UP Messageを受信すると(ステップS46)、処理部17は、Follow UP Messageに含まれるマスタ装置M1からAnnounce Message 2が送信された時刻と、受信部14がAnnounce Message 2を受信した時刻とに基づいてオフセット時間差を算出し(ステップS47)、タイマ16のオフセット補正を行う(ステップS48)。   When the receiving unit 14 of the slave device S1 receives the Announce Message 2 from the master device M1 (Step S45) and receives a Follow UP Message including the time when the Announce Message 2 is transmitted from the master device M1 (Step S46), the processing unit 17 calculates an offset time difference based on the time when the Announce Message 2 is transmitted from the master device M1 included in the Follow UP Message and the time when the receiving unit 14 receives the Announce Message 2 (Step S47). Offset correction is performed (step S48).

次に、送信部13は、マスタ装置M1とスレーブ装置S1との間の伝搬遅延時間を求めるためのDelay Request Messageを通常の時刻パケット通信よりも短い送信間隔でマスタ装置M1に送信する(ステップS49)。ここでの送信間隔とは、受信部14がFollow UP Messageを受信してから送信部13がDelay Request Messageを送信するまでの時間である。   Next, the transmission unit 13 transmits a Delay Request Message for obtaining a propagation delay time between the master device M1 and the slave device S1 to the master device M1 at a transmission interval shorter than normal time packet communication (step S49). ). Here, the transmission interval is the time from when the receiving unit 14 receives the Follow UP Message to when the transmitting unit 13 transmits the Delay Request Message.

マスタ装置M1は、スレーブ装置S1からのDelay Request Messageを受信すると、Delay Request Messageを受信した時刻を含むDelay Response Messageをスレーブ装置S1に送信する。同時に、マスタ装置M1がビジー状態であることを示すAnnounce Message 3をその他のスレーブ装置に対して送信する。あるいは、マスタ装置M1は、ステーブ装置S1との時刻同期のためビジー状態であることを、その他のスレーブ装置に報知するために、ステーブ装置S1を宛先とするDelay Response Messageをブロードキャストしてもよい。   When receiving the Delay Request Message from the slave device S1, the master device M1 transmits a Delay Response Message including the time when the Delay Request Message is received to the slave device S1. At the same time, Announce Message 3 indicating that the master device M1 is busy is transmitted to the other slave devices. Alternatively, the master device M1 may broadcast a Delay Response Message destined for the stave device S1 in order to notify other slave devices that it is busy for time synchronization with the stave device S1.

スレーブ装置S1の受信部14がマスタ装置M1からDelay Response Messageを受信すると(ステップS50)、処理部17は、送信部13がDelay Request Messageを送信した時刻と、Delay Response Messageに含まれるマスタ装置M1がDelay Request Messageを受信した時刻とに基づいて伝搬遅延時間を算出する(ステップS51)。ステップS49〜ステップS51を所定の回数繰り返していない場合(ステップS52;NO)、ステップS49に戻り、ステップS49〜ステップS52を繰り返す。ステップS49〜ステップS51を所定の回数繰り返した場合(ステップS52;YES)、処理部17は、タイマ16の伝搬遅延補正を行う(ステップS52)。こうして、所定の回数分の伝搬遅延時間が算出される。   When the receiving unit 14 of the slave device S1 receives the Delay Response Message from the master device M1 (Step S50), the processing unit 17 transmits the time at which the transmitting unit 13 transmits the Delay Request Message and the master device M1 included in the Delay Response Message. The propagation delay time is calculated based on the time when the delay request message is received (step S51). When step S49 to step S51 are not repeated a predetermined number of times (step S52; NO), the process returns to step S49, and steps S49 to S52 are repeated. When step S49 to step S51 are repeated a predetermined number of times (step S52; YES), the processing unit 17 performs propagation delay correction of the timer 16 (step S52). Thus, the propagation delay time for a predetermined number of times is calculated.

処理部17は、所定の回数分の伝搬遅延時間から、発振器15が安定したときの伝搬遅延時間を予測し(ステップS53)、予測した伝搬遅延時間に基づいて、タイマ16の伝搬遅延補正を行い(ステップS54)、処理を終了する。   The processing unit 17 predicts the propagation delay time when the oscillator 15 is stabilized from the predetermined number of propagation delay times (step S53), and corrects the propagation delay of the timer 16 based on the predicted propagation delay time. (Step S54), the process ends.

所定の回数は、発振器15が安定したときの同期時刻を予測可能な程度の回数であればよい。また、処理部17は、発振器15が安定したときの伝搬遅延時間を予測して伝搬遅延補正を行うとともに、伝搬遅延補正の補正値に基づいて、発振器15が安定しないことによる誤差を算出し、改めてオフセット補正を行ってもよい。   The predetermined number of times may be a number enough to predict the synchronization time when the oscillator 15 is stabilized. Further, the processing unit 17 predicts the propagation delay time when the oscillator 15 is stabilized and performs propagation delay correction, and calculates an error due to the oscillator 15 not being stable based on the correction value of the propagation delay correction, Offset correction may be performed again.

図7の例では、所定の回数ステップS49〜ステップS52を繰り返す。このとき、送信部13は、通常の時刻パケット通信よりも短い送信間隔でDelay Request Messageをマスタ装置M1に送信する。ここでの送信間隔とは、受信部14がDelay Response Messageを受信してから送信部13が次のDelay Request Messageを送信するまでの時間である。   In the example of FIG. 7, step S49 to step S52 are repeated a predetermined number of times. At this time, the transmission unit 13 transmits a Delay Request Message to the master device M1 at a transmission interval shorter than normal time packet communication. Here, the transmission interval is the time from when the receiving unit 14 receives the Delay Response Message until the transmitting unit 13 transmits the next Delay Request Message.

この実施の形態によれば、スレーブ装置の発振器15が安定する前から複数回伝搬遅延時間を算出し、その伝搬遅延時間の変移から発振器15が安定したときの伝搬遅延時間を予測することにより、時刻同期までの時間をさらに短縮することができる。   According to this embodiment, the propagation delay time is calculated a plurality of times before the oscillator 15 of the slave device is stabilized, and the propagation delay time when the oscillator 15 is stabilized is predicted from the transition of the propagation delay time. The time until the time synchronization can be further shortened.

図8は、他の実施の形態に係るスレーブ装置の時刻同期の動作の一例を示すフローチャートである。図8の実施の形態では、発振器15が安定する前から伝搬遅延時間の算出を繰り返し行って、前回の伝搬遅延時間と今回の伝搬遅延時間との差が閾値以下になった場合に、伝搬遅延時間の算出の繰り返しを終了する。ここでは、スレーブ装置S1の時刻同期の動作の一例を説明する。スレーブ装置S2〜SXも同様の時刻同期の動作を行う。スレーブ装置S1の電源が起動すると同時にスレーブ装置S1内部のカウンタ11が起動し(ステップS61)、カウントアップを開始する。カウンタ値がN1以上になっていない場合には(ステップS62;NO)、ステップS62を繰り返す。カウンタ値N1は、発振器15が安定する時間よりも短い時間を示す値、あるいは、発振器15が安定する時間から判定処理を実行する最短時間を引いた時間よりも短い時間を示す値である。   FIG. 8 is a flowchart illustrating an example of a time synchronization operation of a slave device according to another embodiment. In the embodiment of FIG. 8, the propagation delay time is repeatedly calculated before the oscillator 15 is stabilized, and the propagation delay is calculated when the difference between the previous propagation delay time and the current propagation delay time is equal to or less than the threshold value. The time calculation is repeated. Here, an example of the operation of time synchronization of the slave device S1 will be described. The slave devices S2 to SX perform the same time synchronization operation. At the same time as the power supply of the slave device S1 is activated, the counter 11 in the slave device S1 is activated (step S61), and count-up is started. If the counter value is not greater than or equal to N1 (step S62; NO), step S62 is repeated. The counter value N1 is a value indicating a time shorter than the time when the oscillator 15 is stabilized or a value indicating a time shorter than the time obtained by subtracting the shortest time for executing the determination process from the time when the oscillator 15 is stabilized.

カウンタ値がN1以上になった場合には(ステップS62;YES)、判定部12は、マスタ装置M1が他のスレーブ装置と時刻同期を行っているビジー状態であるか否かを判定する(ステップS63)。判定部12がビジー状態であると判定した場合(ステップS63;YES)、マスタ装置M1のビジー状態が解除されるまで、ステップS63を繰り返す。マスタ装置M1がビジー状態でない場合(ステップS63;NO)、送信部13は、時刻同期の開始を要求するAnnounce Message 1をマスタ装置M1に送信する(ステップS64)。   When the counter value is equal to or greater than N1 (step S62; YES), the determination unit 12 determines whether the master device M1 is in a busy state in which time synchronization is performed with another slave device (step S62). S63). If the determination unit 12 determines that the busy state is present (step S63; YES), step S63 is repeated until the busy state of the master device M1 is released. When the master apparatus M1 is not busy (step S63; NO), the transmission unit 13 transmits Announce Message 1 for requesting the start of time synchronization to the master apparatus M1 (step S64).

マスタ装置M1は、スレーブ装置S1からのAnnounce Message 1を受信すると、マスタ装置M1とスレーブ装置S1との間のオフセット時間差を求めるためのAnnounce Message 2をスレーブ装置S1に対して送信する。同時に、マスタ装置M1がビジー状態になったことを示すAnnounce Message 3をその他のスレーブ装置に対して送信する。あるいは、マスタ装置M1は、ステーブ装置S1との時刻同期を開始してビジー状態になったことを、その他のスレーブ装置に報知するために、ステーブ装置S1を宛先とするAnnounce Message 2をブロードキャストしてもよい。そして、マスタ装置M1は、Announce Message 2を送信した時刻を含むFollow UP Messageをスレーブ装置S1に送信する。   When master device M1 receives Announce Message 1 from slave device S1, master device M1 transmits Announce Message 2 for obtaining an offset time difference between master device M1 and slave device S1 to slave device S1. At the same time, an Announce Message 3 indicating that the master device M1 is in a busy state is transmitted to the other slave devices. Alternatively, the master device M1 broadcasts an Announce Message 2 destined for the stave device S1 in order to notify other slave devices that time synchronization with the stave device S1 has started and is in a busy state. Also good. Then, the master device M1 transmits a Follow UP Message including the time when the Announce Message 2 is transmitted to the slave device S1.

スレーブ装置S1の受信部14がマスタ装置M1からAnnounce Message 2を受信し(ステップS65)、マスタ装置M1からAnnounce Message 2が送信された時刻を含むFollow UP Messageを受信すると(ステップS66)、処理部17は、Follow UP Messageに含まれるマスタ装置M1からAnnounce Message 2が送信された時刻と、受信部14がAnnounce Message 2を受信した時刻とに基づいてオフセット時間差を算出し(ステップS67)、タイマ16のオフセット補正を行う(ステップS68)。   When the receiving unit 14 of the slave device S1 receives the Announce Message 2 from the master device M1 (Step S65) and receives a Follow UP Message including the time when the Announce Message 2 is transmitted from the master device M1 (Step S66), the processing unit 17 calculates an offset time difference based on the time when the Announce Message 2 is transmitted from the master device M1 included in the Follow UP Message and the time when the receiving unit 14 receives the Announce Message 2 (Step S67). Offset correction is performed (step S68).

次に、送信部13は、マスタ装置M1とスレーブ装置S1との間の伝搬遅延時間を求めるためのDelay Request Messageを通常の時刻パケット通信よりも短い送信間隔でマスタ装置M1に送信する(ステップS69)。ここでの送信間隔とは、受信部14がFollow UP Messageを受信してから送信部13がDelay Request Messageを送信するまでの時間である。   Next, the transmission unit 13 transmits a Delay Request Message for obtaining a propagation delay time between the master device M1 and the slave device S1 to the master device M1 at a transmission interval shorter than normal time packet communication (step S69). ). Here, the transmission interval is the time from when the receiving unit 14 receives the Follow UP Message to when the transmitting unit 13 transmits the Delay Request Message.

マスタ装置M1は、スレーブ装置S1からのDelay Request Messageを受信すると、Delay Request Messageを受信した時刻を含むDelay Response Messageをスレーブ装置S1に送信する。同時に、マスタ装置M1がビジー状態であることを示すAnnounce Message 3をその他のスレーブ装置に対して送信する。あるいは、マスタ装置M1は、ステーブ装置S1との時刻同期のためビジー状態であることを、その他のスレーブ装置に報知するために、ステーブ装置S1を宛先とするDelay Response Messageをブロードキャストしてもよい。   When receiving the Delay Request Message from the slave device S1, the master device M1 transmits a Delay Response Message including the time when the Delay Request Message is received to the slave device S1. At the same time, Announce Message 3 indicating that the master device M1 is busy is transmitted to the other slave devices. Alternatively, the master device M1 may broadcast a Delay Response Message destined for the stave device S1 in order to notify other slave devices that it is busy for time synchronization with the stave device S1.

スレーブ装置S1の受信部14がマスタ装置M1からDelay Response Messageを受信すると(ステップS70)、処理部17は、送信部13がDelay Request Messageを送信した時刻と、Delay Response Messageに含まれるマスタ装置M1がDelay Request Messageを受信した時刻とに基づいて伝搬遅延時間を算出する(ステップS71)。前回算出した伝搬遅延時間と、今回算出した伝搬遅延時間との差が閾値(たとえば1秒)以下でなかった場合(ステップS72;NO)、ステップS69に戻り、ステップS69〜ステップS72を繰り返す。前回算出した伝搬遅延時間と、今回算出した伝搬遅延時間との差が閾値(たとえば1秒)以下であった場合(ステップS72;YES)、処理部17は、今回算出した伝搬遅延時間に基づいて、タイマ16の伝搬遅延補正を行い(ステップS73)、処理を終了する。   When the reception unit 14 of the slave device S1 receives the Delay Response Message from the master device M1 (Step S70), the processing unit 17 transmits the time when the transmission unit 13 transmits the Delay Request Message and the master device M1 included in the Delay Response Message. The propagation delay time is calculated based on the time when the Delay Request Message is received (step S71). If the difference between the propagation delay time calculated last time and the propagation delay time calculated this time is not less than or equal to a threshold (for example, 1 second) (step S72; NO), the process returns to step S69, and steps S69 to S72 are repeated. When the difference between the propagation delay time calculated last time and the propagation delay time calculated this time is equal to or less than a threshold value (for example, 1 second) (step S72; YES), the processing unit 17 performs processing based on the propagation delay time calculated this time. Then, the propagation delay of the timer 16 is corrected (step S73), and the process is terminated.

ステップS51で判定する閾値は、0以上の値であって、求められている時刻同期精度の許容範囲内であればよい。また、処理部17は、値が収束した伝搬遅延時間に基づいて伝搬遅延補正を行うとともに、伝搬遅延補正の補正値に基づいて、発振器15が安定しないことによる誤差を算出し、改めてオフセット補正を行ってもよい。   The threshold value determined in step S51 may be a value equal to or greater than 0 and within the allowable range of time synchronization accuracy that is obtained. Further, the processing unit 17 performs propagation delay correction based on the propagation delay time when the value converges, calculates an error due to the unstableness of the oscillator 15 based on the propagation delay correction value, and performs offset correction again. You may go.

図8の例では、ステップS69〜ステップS72を繰り返す。このとき、送信部13は、通常の時刻パケット通信よりも短い送信間隔でDelay Request Messageをマスタ装置M1に送信する。ここでの送信間隔とは、受信部14がDelay Response Messageを受信してから送信部13が次のDelay Request Messageを送信するまでの時間である。   In the example of FIG. 8, step S69 to step S72 are repeated. At this time, the transmission unit 13 transmits a Delay Request Message to the master device M1 at a transmission interval shorter than normal time packet communication. Here, the transmission interval is the time from when the receiving unit 14 receives the Delay Response Message until the transmitting unit 13 transmits the next Delay Request Message.

この実施の形態によれば、スレーブ装置の発振器15が安定する前から伝搬遅延時間の算出を繰り返し行い、その伝搬遅延時間の値が所定の範囲まで収束したときの伝搬遅延時間の算出の繰り返しを終了することにより、時刻同期までの時間をさらに短縮することができる。   According to this embodiment, the propagation delay time is repeatedly calculated before the slave device oscillator 15 is stabilized, and the propagation delay time calculation is repeated when the propagation delay time value converges to a predetermined range. By ending, the time until time synchronization can be further shortened.

図9は、他の実施の形態に係る電子機器システムにおける時刻同期を説明する図である。図6、図7および図8のフローチャートを参照しながら、図9を用いて本実施の形態に係る電子機器システム100における時刻同期の動作フローの例を説明する。図9の例では、便宜上、電子機器システム100は、マスタ装置1とスレーブ装置S1およびスレーブ装置S2とで構成され、スレーブ装置S1の時刻同期を実行する場合を示す。   FIG. 9 is a diagram illustrating time synchronization in an electronic device system according to another embodiment. An example of an operation flow of time synchronization in electronic device system 100 according to the present embodiment will be described using FIG. 9 with reference to the flowcharts of FIGS. In the example of FIG. 9, for convenience, the electronic device system 100 includes a master device 1, a slave device S1, and a slave device S2, and shows a case where time synchronization of the slave device S1 is executed.

スレーブ装置S1が起動し(ステップS41、ステップS61)、スレーブ装置S1のカウンタ11のカウンタ値がN以上になり(ステップS42、ステップS62;YES)、Announce Message 3を受信せずに(ステップS31;NO)、所定の時間(12秒)経過すると(ステップS33;NO)、判定部12は、マスタ装置M1はビジー状態ではないと判定する(ステップS43、ステップS63;NO)。判定部12がビジー状態ではないと判定した時刻00:15に、送信部13は、時刻同期の開始を要求するAnnounce Message 1をマスタ装置M1に送信する(ステップS44、ステップS64)。マスタ装置M1は、時刻00:03にAnnounce Message 1を受信すると、時刻00:04に、マスタ装置M1とスレーブ装置S1との間のオフセット時間差を求めるためのAnnounce Message 2をスレーブ装置S1に対して送信する。同時に、マスタ装置M1がビジー状態になったことを示すAnnounce Message 3をスレーブ装置S2に対して送信する。そして、Announce Message 2を送出した時刻00:04を含むFollow UP Messageを時刻00:05にスレーブ装置S1へ送出する。   The slave device S1 is activated (step S41, step S61), the counter value of the counter 11 of the slave device S1 becomes N or more (step S42, step S62; YES), and the Announce Message 3 is not received (step S31; NO), when a predetermined time (12 seconds) elapses (step S33; NO), the determination unit 12 determines that the master device M1 is not busy (step S43, step S63; NO). At time 00:15 when the determination unit 12 determines that it is not busy, the transmission unit 13 transmits Announce Message 1 for requesting the start of time synchronization to the master device M1 (steps S44 and S64). When master device M1 receives Announce Message 1 at time 00:03, master device M1 provides Announce Message 2 for obtaining an offset time difference between master device M1 and slave device S1 to slave device S1 at time 00:04. Send. At the same time, an Announce Message 3 indicating that the master device M1 is busy is transmitted to the slave device S2. Then, a Follow UP Message including the time 00:04 at which the Announce Message 2 is transmitted is transmitted to the slave device S1 at the time 00:05.

スレーブ装置S1の受信部14は、時刻00:22にAnnounce Message 2を受信し(ステップS45、ステップS65)、時刻00:23にFollow UP Messageを受信する(ステップS46、ステップS66)。処理部17は、受信部14がAnnounce Message 2を受信した時刻00:22と、Follow UP Messageに含まれるマスタ装置からAnnounce Message 2が送信された時刻00:04とに基づいて、マスタ装置とのオフセット時間差{00:22−00:04=00:18}を算出し(ステップS47、ステップS67)、時刻00:23からオフセット時間差00:18を引いて、時刻00:05にするオフセット補正を行なう(ステップS48、ステップS68)。   The receiving unit 14 of the slave device S1 receives the Announce Message 2 at time 00:22 (step S45, step S65), and receives a Follow UP Message at time 00:23 (step S46, step S66). Based on the time 00:22 when the receiving unit 14 receives the Announce Message 2 and the time 00:04 when the Announce Message 2 is transmitted from the master device included in the Follow UP Message, the processing unit 17 Offset time difference {00: 22−00: 04 = 00: 18} is calculated (step S47, step S67), and offset correction is performed by subtracting offset time difference 00:18 from time 00:23 to time 00:05. (Step S48, Step S68).

次に、スレーブ装置S1の送信部13は、オフセット補正後の時刻00:06にマスタ装置とスレーブ装置の間の伝搬遅延時間を求めるためのDelay Request Messageをマスタ装置M1に送信する(ステップS49、ステップS69)。マスタ装置は、Delay Request Messageを受信した時刻00:12を含むDelay Response Messageを時刻00:13にスレーブ装置S1に送信する。   Next, the transmission unit 13 of the slave device S1 transmits a Delay Request Message for obtaining a propagation delay time between the master device and the slave device to the master device M1 at time 00:06 after the offset correction (Step S49, Step S69). The master device transmits a Delay Response Message including time 00:12 at which the Delay Request Message is received to the slave device S1 at time 00:13.

スレーブ装置S1の受信部14は、オフセット補正後の時刻00:13にDelay Response Messageを受信する(ステップS50、ステップS70)。処理部17は、送信部13がDelay Request Messageを送信したオフセット補正後の時刻00:06と、Delay Response Messageに含まれるマスタ装置M1がDelay Request Messageを受信した時刻00:12とに基づいて、マスタ装置M1とスレーブ装置S1との伝搬遅延時間{(00:12−00:06)/2=00:03}を算出する(ステップS51、ステップS71)。   The receiving unit 14 of the slave device S1 receives the Delay Response Message at time 00:13 after the offset correction (Steps S50 and S70). Based on the time 00:06 after the offset correction when the transmission unit 13 transmitted the Delay Request Message and the time 00:12 when the master device M1 included in the Delay Response Message received the Delay Request Message, The propagation delay time {(00: 12-00: 06) / 2 = 00: 03} between the master device M1 and the slave device S1 is calculated (step S51, step S71).

ここで、所定の回数(2回)伝搬遅延時間の算出を繰り返していない(ステップS52;NO)、あるいは、前回算出した伝搬遅延時間がないので(ステップS72;NO)、スレーブ装置S1の送信部13は、オフセット補正後の時刻00:13にマスタ装置とスレーブ装置の間の伝搬遅延時間を求めるためのDelay Request Messageをマスタ装置M1に再度送信する(ステップS49、ステップS69)。マスタ装置は、Delay Request Messageを受信した時刻00:20を含むDelay Response Messageを時刻00:21にスレーブ装置S1に送信する。   Here, the calculation of the propagation delay time is not repeated a predetermined number of times (twice) (step S52; NO), or there is no propagation delay time calculated last time (step S72; NO), so the transmission unit of the slave device S1 13 again transmits a Delay Request Message for obtaining the propagation delay time between the master device and the slave device to the master device M1 at time 00:13 after the offset correction (steps S49 and S69). The master device transmits a Delay Response Message including time 00:20 at which the Delay Request Message is received to the slave device S1 at time 00:21.

スレーブ装置S1の受信部14は、オフセット補正後の時刻00:21にDelay Response Messageを受信する(ステップS50、ステップS70)。処理部17は、送信部13がDelay Request Messageを送信したオフセット補正後の時刻00:14と、Delay Response Messageに含まれるマスタ装置M1がDelay Request Messageを受信した時刻00:20とに基づいて、マスタ装置M1とスレーブ装置S1との伝搬遅延時間{(00:20−00:14)/2=00:03}を算出する(ステップS51、ステップS71)。   The receiving unit 14 of the slave device S1 receives the Delay Response Message at time 00:21 after the offset correction (Steps S50 and S70). Based on the time 00:14 after offset correction when the transmission unit 13 transmits the Delay Request Message and the time 00:20 when the master device M1 included in the Delay Response Message receives the Delay Request Message, The propagation delay time {(00: 20-00: 14) / 2 = 00: 03} between the master device M1 and the slave device S1 is calculated (step S51, step S71).

所定の回数(2回)伝搬遅延時間の算出を繰り返した(ステップS52;YES)、ので、1回目に算出した伝搬遅延時間3秒と、2回目に算出した伝搬遅延時間3秒とに基づいて、発振器15が安定したときの伝搬遅延時間は3秒と予測する(ステップS53)。   Since the calculation of the propagation delay time is repeated a predetermined number of times (twice) (step S52; YES), based on the propagation delay time 3 seconds calculated for the first time and the propagation delay time 3 seconds calculated for the second time. The propagation delay time when the oscillator 15 is stabilized is predicted to be 3 seconds (step S53).

あるいは、前回算出した伝搬遅延時間3秒と、今回算出した伝搬遅延時間3秒との差が閾値(1秒)以下であるので(ステップS72;YES)、伝搬遅延時間は3秒とする。   Alternatively, since the difference between the previously calculated propagation delay time of 3 seconds and the currently calculated propagation delay time of 3 seconds is equal to or less than the threshold (1 second) (step S72; YES), the propagation delay time is set to 3 seconds.

処理部17は、オフセット補正後の時刻00:23に伝搬遅延時間00:03を足して、時刻00:26にする伝搬遅延補正を行なう(ステップS54、ステップS73)。以上によりマスタ装置とスレーブ装置の時刻同期が行なわれる。   The processing unit 17 performs propagation delay correction at time 00:26 by adding the propagation delay time 00:03 to time 00:23 after the offset correction (steps S54 and S73). Thus, time synchronization between the master device and the slave device is performed.

一方、スレーブ装置S2は、カウンタ11のカウンタ値がN以上になってから(ステップS42、ステップS62;YES)、所定の時間(12秒)が経過するよりも前の時刻00:02にマスタ装置M1からAnnounce Message 3を受信する(ステップS31;YES)。これにより、判定部12は、ビジー状態であると判定する(ステップS32)。また、所定の時間(12秒)が経過する前の時刻00:13にマスタ装置M1からAnnounce Message 3を受信する(ステップS31)。これにより、判定部12は、ビジー状態であると判定する(ステップS32)。さらに、所定の時間(12秒)が経過する前の時刻00:21にマスタ装置M1からAnnounce Message 3を受信する(ステップS31)。これにより、判定部12は、ビジー状態であると判定する(ステップS32)。そして、所定の時間(12秒)が経過する時刻00:33までにAnnounce Message 3を受信していないので(ステップS33;YES)、判定部12は、マスタ装置M1のビジー状態が解除されたと判定する(ステップS34)。判定部12がビジー状態でないと判定したので、送信部13は、時刻00:34に時刻同期の開始を要求するAnnounce Message 1をマスタ装置M1に送信する(ステップS44、ステップS64)。   On the other hand, the slave device S2 receives the master device at time 00:02 before a predetermined time (12 seconds) elapses after the counter value of the counter 11 becomes N or more (step S42, step S62; YES). Announce Message 3 is received from M1 (step S31; YES). Thereby, the determination part 12 determines with it being a busy state (step S32). Also, Announce Message 3 is received from master device M1 at time 00:13 before a predetermined time (12 seconds) elapses (step S31). Thereby, the determination part 12 determines with it being a busy state (step S32). Furthermore, the Announce Message 3 is received from the master device M1 at time 00:21 before a predetermined time (12 seconds) elapses (step S31). Thereby, the determination part 12 determines with it being a busy state (step S32). Then, since the Announce Message 3 has not been received by the time 00:33 when the predetermined time (12 seconds) elapses (step S33; YES), the determination unit 12 determines that the busy state of the master device M1 has been released. (Step S34). Since the determination unit 12 determines that it is not busy, the transmission unit 13 transmits Announce Message 1 for requesting the start of time synchronization to the master device M1 at time 00:34 (steps S44 and S64).

図10は、実施の形態に係るスレーブ装置のハードウェア構成例を示すブロック図である。スレーブ装置S1〜SXは、図10に示すように、制御部31、主記憶部32、外部記憶部33、操作部34、表示部35および発振器36を備える。主記憶部32、外部記憶部33、操作部34、表示部35および発振器36はいずれも内部バス30を介して制御部31に接続されている。   FIG. 10 is a block diagram illustrating a hardware configuration example of the slave device according to the embodiment. As illustrated in FIG. 10, the slave devices S <b> 1 to SX include a control unit 31, a main storage unit 32, an external storage unit 33, an operation unit 34, a display unit 35, and an oscillator 36. The main storage unit 32, the external storage unit 33, the operation unit 34, the display unit 35, and the oscillator 36 are all connected to the control unit 31 via the internal bus 30.

制御部31はCPU(Central Processing Unit)等から構成され、外部記憶部33に記憶されている制御プログラム30に従って、カウンタ11、送信部13、受信部14、タイマ16および処理部17の各処理を実行する。   The control unit 31 includes a CPU (Central Processing Unit) and the like, and performs each process of the counter 11, the transmission unit 13, the reception unit 14, the timer 16, and the processing unit 17 in accordance with the control program 30 stored in the external storage unit 33. Run.

主記憶部32はRAM(Random-Access Memory)等から構成され、外部記憶部33に記憶されている制御プログラム30をロードし、制御部31の作業領域として用いられる。   The main storage unit 32 is constituted by a RAM (Random-Access Memory) or the like, loads the control program 30 stored in the external storage unit 33, and is used as a work area of the control unit 31.

外部記憶部33は、フラッシュメモリ、ハードディスク、DVD−RAM(Digital Versatile Disc Random-Access Memory)、DVD−RW(Digital Versatile Disc ReWritable)等の不揮発性メモリから構成され、スレーブ装置S1〜SXの処理を制御部31に行わせるためのプログラムをあらかじめ記憶し、また、制御部31の指示に従って、このプログラムが記憶するデータを制御部31に供給し、制御部31から供給されたデータを記憶する。   The external storage unit 33 includes a nonvolatile memory such as a flash memory, a hard disk, a DVD-RAM (Digital Versatile Disc Random-Access Memory), a DVD-RW (Digital Versatile Disc ReWritable), and performs processing of the slave devices S1 to SX. A program to be executed by the control unit 31 is stored in advance, and data stored by the program is supplied to the control unit 31 in accordance with an instruction from the control unit 31, and the data supplied from the control unit 31 is stored.

操作部34はキーボードやテンキーなどのポインティングデバイス等と、キーボードやテンキー等を内部バス30に接続するインタフェース装置から構成されている。さらに操作部34は音声入力装置を備えることとしてもよい。ユーザがカウンタ値Nや閾値時刻同期の間隔αなどの入力を行う場合は、操作部34を介して、指示が制御部31に供給される。   The operation unit 34 includes a pointing device such as a keyboard and a numeric keypad, and an interface device that connects the keyboard, numeric keypad, and the like to the internal bus 30. Furthermore, the operation unit 34 may include a voice input device. When the user inputs the counter value N or the threshold time synchronization interval α, an instruction is supplied to the control unit 31 via the operation unit 34.

表示部35は、CRT(Cathode Ray Tube)またはLCD(Liquid Crystal Display)などから構成され、制御部31から送られてきた情報を表示する。ユーザがカウンタ値Nや閾値時刻同期の間隔αなどの入力を行う場合は、表示部35は、操作画面を表示する。   The display unit 35 is configured by a CRT (Cathode Ray Tube), an LCD (Liquid Crystal Display), or the like, and displays information sent from the control unit 31. When the user inputs the counter value N or the threshold time synchronization interval α, the display unit 35 displays an operation screen.

発振器37は、所定の周波数のクロックを発生させて、制御部31に供給する。発振器37は、発振器15として機能する。   The oscillator 37 generates a clock having a predetermined frequency and supplies it to the control unit 31. The oscillator 37 functions as the oscillator 15.

図3に示すスレーブ装置S1(スレーブ装置S2〜SX)のカウンタ11、送信部13、受信部14、発振器15、タイマ16および処理部17の処理は、制御プログラム30が、制御部31、主記憶部32、外部記憶部33、操作部34、表示部35、発振器36および発振器37などを資源として用いて処理することによって実行する。   The processing of the counter 11, the transmission unit 13, the reception unit 14, the oscillator 15, the timer 16, and the processing unit 17 of the slave device S1 (slave devices S2 to SX) illustrated in FIG. The processing is executed by using the unit 32, the external storage unit 33, the operation unit 34, the display unit 35, the oscillator 36, the oscillator 37, and the like as resources.

その他、前記のハードウェア構成やフローチャートは一例であり、任意に変更および修正が可能である。   In addition, the hardware configuration and the flowchart described above are merely examples, and can be arbitrarily changed and modified.

制御部31、主記憶部32、外部記憶部33、操作部34、内部バス30などから構成される時刻同期処理を行う中心となる部分は、専用のシステムによらず、通常のコンピュータシステムを用いて実現可能である。たとえば、前記の動作を実行するためのコンピュータプログラムを、コンピュータが読み取り可能な記録媒体(フレキシブルディスク、CD−ROM、DVD−ROM等)に格納して配布し、当該コンピュータプログラムをコンピュータにインストールすることにより、前記の処理を実行するスレーブ装置S1〜SXを構成してもよい。また、インターネット等の通信ネットワーク上のサーバ装置が有する記憶装置に当該コンピュータプログラムを格納しておき、通常のコンピュータシステムがダウンロード等することでスレーブ装置S1〜SXを構成してもよい。   The central part that performs the time synchronization process including the control unit 31, the main storage unit 32, the external storage unit 33, the operation unit 34, the internal bus 30 and the like uses a normal computer system, not a dedicated system. Is feasible. For example, a computer program for executing the above operation is stored and distributed in a computer-readable recording medium (flexible disk, CD-ROM, DVD-ROM, etc.), and the computer program is installed in the computer. Thus, the slave devices S1 to SX that execute the above-described processing may be configured. In addition, the slave device S1 to SX may be configured by storing the computer program in a storage device included in a server device on a communication network such as the Internet and downloading the normal computer system.

また、スレーブ装置S1〜SXの機能を、OS(オペレーティングシステム)とアプリケーションプログラムの分担、またはOSとアプリケーションプログラムとの協働により実現する場合などには、アプリケーションプログラム部分のみを記録媒体や記憶装置に格納してもよい。   Further, when the functions of the slave devices S1 to SX are realized by sharing an OS (operating system) and an application program or by cooperation between the OS and the application program, only the application program portion is stored in a recording medium or a storage device. It may be stored.

また、搬送波にコンピュータプログラムを重畳し、通信ネットワークを介して配信することも可能である。たとえば、通信ネットワーク上の掲示板(BBS, Bulletin Board System)に前記コンピュータプログラムを掲示し、ネットワークを介して前記コンピュータプログラムを配信してもよい。そして、このコンピュータプログラムを起動し、OSの制御下で、他のアプリケーションプログラムと同様に実行することにより、前記の処理を実行できるように構成してもよい。   It is also possible to superimpose a computer program on a carrier wave and distribute it via a communication network. For example, the computer program may be posted on a bulletin board (BBS, Bulletin Board System) on a communication network, and the computer program may be distributed via the network. The computer program may be started and executed in the same manner as other application programs under the control of the OS, so that the above-described processing may be executed.

上記の実施形態の一部又は全部は、以下の付記のようにも記載されうるが、以下には限られない。   A part or all of the above-described embodiment can be described as in the following supplementary notes, but is not limited thereto.

(付記1)
マスタ装置とネットワークを介して時刻同期を行うスレーブ装置であって、
時刻情報を生成するタイマと、
前記時刻情報を生成するためのクロックを発生させる発振器と、
所定の間隔でカウントアップするカウンタと、
前記カウンタの値が所定の値を超えた場合に、前記マスタ装置が他のスレーブ装置と時刻同期を行っているビジー状態であるか否かを判定する判定手段と、
前記判定手段が前記ビジー状態でないと判定した場合、前記マスタ装置に時刻同期の開始を要求する第1メッセージを送信する第1送信手段と、
前記マスタ装置から、前記マスタ装置と前記スレーブ装置との間のオフセット時間差を求めるための第2メッセージと、前記第2メッセージが前記マスタ装置から送信された時刻を含むフォローアップメッセージとを受信する第1受信手段と、
前記第1受信手段が前記第2メッセージを受信した時刻と、前記フォローアップメッセージに含まれる前記第2メッセージが前記マスタ装置から送信された時刻とに基づいて、前記オフセット時間差を算出するオフセット算出手段と、
前記第1受信手段が前記マスタ装置から前記フォローアップメッセージを受信したのちに、前記マスタ装置に前記マスタ装置と前記スレーブ装置との間の伝搬遅延時間を求めるための第3メッセージを送信する第2送信手段と、
前記マスタ装置から前記第3メッセージを前記マスタ装置が受信した時刻を含む第4メッセージを受信する第2受信手段と、
前記第2送信手段が前記第3メッセージを送信した時刻と、前記第4メッセージに含まれる前記第3メッセージを前記マスタ装置が受信した時刻とに基づいて、前記伝搬遅延時間を算出する遅延時間算出手段と、
前記オフセット時間差および前記伝搬遅延時間に基づいて、前記タイマの時刻を補正する補正手段と、
を備えることを特徴とするスレーブ装置。
(Appendix 1)
A slave device that performs time synchronization with a master device via a network,
A timer for generating time information;
An oscillator for generating a clock for generating the time information;
A counter that counts up at predetermined intervals;
A determination means for determining whether or not the master device is busy performing time synchronization with other slave devices when the value of the counter exceeds a predetermined value;
A first transmission unit configured to transmit a first message requesting the master device to start time synchronization when the determination unit determines that the busy state is not present;
A second message for receiving an offset time difference between the master device and the slave device and a follow-up message including a time when the second message is transmitted from the master device from the master device. One receiving means;
Offset calculating means for calculating the offset time difference based on the time when the first receiving means receives the second message and the time when the second message included in the follow-up message is transmitted from the master device. When,
After the first receiving means receives the follow-up message from the master device, a second message is transmitted to the master device for determining a propagation delay time between the master device and the slave device. A transmission means;
Second receiving means for receiving a fourth message including a time at which the master device has received the third message from the master device;
Delay time calculation for calculating the propagation delay time based on the time at which the second transmission means transmits the third message and the time at which the master device receives the third message included in the fourth message. Means,
Correction means for correcting the time of the timer based on the offset time difference and the propagation delay time;
A slave device comprising:

(付記2)
前記第2送信手段が、前記マスタ装置に前記第3メッセージを送信し、
前記第2受信手段が、前記マスタ装置から前記第4メッセージを受信し、および、
前記遅延時間算出手段が、前記第2送信手段が前記第3メッセージを送信した時刻と、前記第4メッセージに含まれる前記第3メッセージを前記マスタ装置が受信した時刻とに基づいて、前記伝搬遅延時間を算出する、
伝搬遅延時間算出処理を所定の周期で繰り返し、
前記補正手段は、前記オフセット時間差と、前記伝搬遅延時間算出処理で算出した複数の前記伝搬遅延時間とに基づいて、前記タイマの時刻を補正することを特徴とする付記1に記載のスレーブ装置。
(Appendix 2)
The second transmission means transmits the third message to the master device;
The second receiving means receives the fourth message from the master device; and
The propagation time based on the time when the delay time calculating means transmits the third message by the second transmitting means and the time when the master device receives the third message included in the fourth message. Calculate the time,
Repeat the propagation delay time calculation process at a predetermined cycle,
The slave device according to appendix 1, wherein the correction unit corrects the time of the timer based on the offset time difference and the plurality of propagation delay times calculated by the propagation delay time calculation process.

(付記3)
前記伝搬遅延時間算出処理を繰り返し、前記伝搬遅延時間算出処理を所定の回数行って算出した複数の前記伝搬遅延時間に基づいて、前記発振器が安定したときの前記伝搬遅延時間を予測する予測手段をさらに備え、
前記補正手段は、前記オフセット時間差と、前記予測手段が予測した前記伝搬遅延時間とに基づいて、前記タイマの時刻を補正することを特徴とする付記2に記載のスレーブ装置。
(Appendix 3)
Predicting means for predicting the propagation delay time when the oscillator is stable based on the plurality of propagation delay times calculated by repeating the propagation delay time calculating process and performing the propagation delay time calculating process a predetermined number of times. In addition,
The slave device according to appendix 2, wherein the correction unit corrects the time of the timer based on the offset time difference and the propagation delay time predicted by the prediction unit.

(付記4)
前記伝搬遅延時間算出処理を繰り返し、前記伝搬遅延時間算出処理で算出した前記伝搬遅延時間と、それより前に算出した前記伝搬遅延時間との差が閾値以下になった場合に、
前記補正手段は、前記オフセット時間差と、最後に算出した前記伝搬遅延時間とに基づいて、前記タイマの時刻を補正することを特徴とする付記2に記載のスレーブ装置。
(Appendix 4)
When the propagation delay time calculation process is repeated, and the difference between the propagation delay time calculated in the propagation delay time calculation process and the propagation delay time calculated before is less than or equal to a threshold value,
3. The slave device according to appendix 2, wherein the correcting unit corrects the time of the timer based on the offset time difference and the last calculated propagation delay time.

(付記5)
前記所定の値は、前記スレーブ装置が起動してから前記発振器が安定することを示す時間を表す前記カウンタの値であることを特徴とする付記1に記載のスレーブ装置。
(Appendix 5)
2. The slave device according to claim 1, wherein the predetermined value is a value of the counter that represents a time indicating that the oscillator is stabilized after the slave device is activated.

(付記6)
ネットワークを介して時刻同期を行うマスタ装置と2以上のスレーブ装置とを備える電子機器システムであって、
前記スレーブ装置はそれぞれ、
時刻情報を生成するタイマ、
前記時刻情報を生成するためのクロックを発生させる発振器、
所定の間隔でカウントアップするカウンタ、
前記カウンタの値が所定の値を超えた場合に、前記マスタ装置が他のスレーブ装置と時刻同期を行っているビジー状態であるか否かを判定する判定手段、
前記判定手段が前記ビジー状態でないと判定した場合、前記マスタ装置に時刻同期の開始を要求する第1メッセージを送信する第1送信手段、
前記マスタ装置から、前記マスタ装置と前記スレーブ装置との間のオフセット時間差を求めるための第2メッセージと、前記第2メッセージが前記マスタ装置から送信された時刻を含むフォローアップメッセージとを受信する第1受信手段、
前記第1受信手段が前記第2メッセージを受信した時刻と、前記フォローアップメッセージに含まれる前記第2メッセージが前記マスタ装置から送信された時刻とに基づいて、前記オフセット時間差を算出するオフセット算出手段、
前記第1受信手段が前記マスタ装置から前記フォローアップメッセージを受信したのちに、前記マスタ装置に前記マスタ装置と前記スレーブ装置との間の伝搬遅延時間を求めるための第3メッセージを送信する第2送信手段、
前記マスタ装置から前記第3メッセージを前記マスタ装置が受信した時刻を含む第4メッセージを受信する第2受信手段、
前記第2送信手段が前記第3メッセージを送信した時刻と、前記第4メッセージに含まれる前記第3メッセージを前記マスタ装置が受信した時刻とに基づいて、前記伝搬遅延時間を算出する遅延時間算出手段、および、
前記オフセット時間差および前記伝搬遅延時間に基づいて、前記タイマの時刻を補正する補正手段、
を含み、
前記マスタ装置は、
前記スレーブ装置から前記第1メッセージを受信する第3受信手段、
前記第3受信手段が前記スレーブ装置から前記第1メッセージを受信すると、前記第2メッセージと、前記フォローアップメッセージとを、前記第1メッセージを受信した相手の前記スレーブ装置である対象スレーブ装置に送信する第3送信手段、
前記第3送信手段が前記第2メッセージを前記対象スレーブ装置に送信すると、前記ビジー状態であることを示す第5メッセージを、前記対象スレーブ装置以外の前記スレーブ装置に送信する第4送信手段、
前記対象スレーブ装置から前記第3メッセージを受信する第4受信手段、および、
前記第4受信手段が前記対象スレーブ装置から前記第3メッセージを受信すると、前記対象スレーブ装置に前記第4メッセージを送信する第5送信手段、
を含むことを特徴とする電子機器システム。
(Appendix 6)
An electronic device system including a master device that performs time synchronization via a network and two or more slave devices,
Each of the slave devices is
A timer that generates time information,
An oscillator for generating a clock for generating the time information;
A counter that counts up at predetermined intervals,
A determination unit that determines whether or not the master device is busy performing time synchronization with another slave device when the value of the counter exceeds a predetermined value;
A first transmission unit configured to transmit a first message requesting the master device to start time synchronization when the determination unit determines that the busy state is not present;
A second message for receiving an offset time difference between the master device and the slave device and a follow-up message including a time when the second message is transmitted from the master device from the master device. 1 receiving means,
Offset calculating means for calculating the offset time difference based on the time when the first receiving means receives the second message and the time when the second message included in the follow-up message is transmitted from the master device. ,
After the first receiving means receives the follow-up message from the master device, a second message is transmitted to the master device for determining a propagation delay time between the master device and the slave device. Transmission means,
Second receiving means for receiving a fourth message including a time at which the master device has received the third message from the master device;
Delay time calculation for calculating the propagation delay time based on the time at which the second transmission means transmits the third message and the time at which the master device receives the third message included in the fourth message. Means and
Correction means for correcting the time of the timer based on the offset time difference and the propagation delay time;
Including
The master device is
Third receiving means for receiving the first message from the slave device;
When the third receiving unit receives the first message from the slave device, the second message and the follow-up message are transmitted to the target slave device that is the slave device of the other party that received the first message. Third transmitting means for
A fourth transmission unit configured to transmit a fifth message indicating the busy state to the slave device other than the target slave device when the third transmission unit transmits the second message to the target slave device;
Fourth receiving means for receiving the third message from the target slave device; and
Fifth transmission means for transmitting the fourth message to the target slave device when the fourth reception means receives the third message from the target slave device;
An electronic device system comprising:

(付記7)
2以上のスレーブ装置とネットワークを介して時刻同期を行うマスタ装置であって、
前記スレーブ装置から時刻同期の開始を要求する第1メッセージを受信する第3受信手段と、
前記第3受信手段が前記スレーブ装置から前記第1メッセージを受信すると、前記マスタ装置と前記スレーブ装置との間のオフセット時間差を求めるための第2メッセージと、前記第2メッセージを送信した時刻を含むフォローアップメッセージとを、前記第1メッセージを受信した相手の前記スレーブ装置である対象スレーブ装置に送信する第3送信手段と、
前記第3送信手段が前記第2メッセージを前記対象スレーブ装置に送信すると、前記ビジー状態であることを示す第5メッセージを、前記対象スレーブ装置以外の前記スレーブ装置に送信する第4送信手段と、
前記対象スレーブ装置から前記マスタ装置と前記スレーブ装置との間の伝搬遅延時間を求めるための第3メッセージを受信する第4受信手段と、
前記第4受信手段が前記対象スレーブ装置から前記第3メッセージを受信すると、前記対象スレーブ装置に前記第3メッセージを受信した時刻を含む第4メッセージを送信する第5送信手段と、
を備えることを特徴とするマスタ装置。
(Appendix 7)
A master device that performs time synchronization with two or more slave devices via a network,
Third receiving means for receiving a first message for requesting start of time synchronization from the slave device;
When the third receiving unit receives the first message from the slave device, the third receiving unit includes a second message for obtaining an offset time difference between the master device and the slave device, and a time when the second message is transmitted. A third transmission means for transmitting a follow-up message to a target slave device that is the slave device of the other party that received the first message;
A fourth transmission unit configured to transmit a fifth message indicating the busy state to the slave device other than the target slave device when the third transmission unit transmits the second message to the target slave device;
A fourth receiving means for receiving a third message for obtaining a propagation delay time between the master device and the slave device from the target slave device;
When the fourth receiving unit receives the third message from the target slave device, a fifth transmitting unit that transmits a fourth message including the time when the third message is received to the target slave device;
A master device comprising:

(付記8)
前記第4送信手段は、前記第5送信手段が前記第4メッセージを送信する度に、前記対象スレーブ装置以外の前記スレーブ装置に前記第5メッセージを送信することを特徴とする付記7に記載のマスタ装置。
(Appendix 8)
The appendix 7 according to appendix 7, wherein the fourth transmitting unit transmits the fifth message to the slave device other than the target slave device every time the fifth transmitting unit transmits the fourth message. Master device.

(付記9)
ネットワークを介して時刻同期を行うマスタ装置と2以上のスレーブ装置とを備える電子機器システムにおいて、時刻情報を生成するためのクロックを発生させる発振器と、所定の間隔でカウントアップするカウンタとを備える前記スレーブ装置が実行する
前記カウンタの値が所定の値を超えた場合に、前記マスタ装置が他のスレーブ装置と時刻同期を行っているビジー状態であるか否かを判定する判定ステップと、
前記判定ステップで前記ビジー状態でないと判定した場合、前記マスタ装置に時刻同期の開始を要求する第1メッセージを送信する第1送信ステップと、
前記マスタ装置が実行する
前記スレーブ装置から前記第1メッセージを受信する第3受信ステップと、
前記第3受信ステップで前記スレーブ装置から前記第1メッセージを受信すると、前記マスタ装置と前記スレーブ装置との間のオフセット時間差を求めるための第2メッセージと、前記第2メッセージを送信した時刻を含むフォローアップメッセージとを、前記第1メッセージを受信した相手の前記スレーブ装置である対象スレーブ装置に送信する第3送信ステップと、
前記第3送信ステップで前記第2メッセージを前記対象スレーブ装置に送信すると、前記ビジー状態であることを示す第5メッセージを、前記対象スレーブ装置以外の前記スレーブ装置に送信する第4送信ステップと、
前記対象スレーブ装置が実行する
前記マスタ装置から、前記第2メッセージと、前記フォローアップメッセージとを受信する第1受信ステップと、
前記第1受信ステップで前記第2メッセージを受信した時刻と、前記フォローアップメッセージに含まれる前記第2メッセージが前記マスタ装置から送信された時刻とに基づいて、前記オフセット時間差を算出するオフセット算出ステップと、
前記第1受信ステップで前記マスタ装置から前記フォローアップメッセージを受信したのちに、前記マスタ装置に前記マスタ装置と前記スレーブ装置との間の伝搬遅延時間を求めるための第3メッセージを送信する第2送信ステップと、
前記マスタ装置が実行する
前記対象スレーブ装置から前記第3メッセージを受信する第4受信ステップと、
前記第4受信ステップで前記対象スレーブ装置から前記第3メッセージを受信すると、前記対象スレーブ装置に前記第3メッセージを受信した時刻を含む前記第4メッセージを送信する第5送信ステップと、
前記対象スレーブ装置が実行する
前記マスタ装置から前記第4メッセージを受信する第2受信ステップと、
前記第3メッセージを送信した時刻と、前記第4メッセージに含まれる前記第3メッセージを前記マスタ装置が受信した時刻とに基づいて、前記伝搬遅延時間を算出する遅延時間算出ステップと、
前記オフセット時間差および前記伝搬遅延時間に基づいて、前記タイマの時刻を補正する補正ステップと、
を備えることを特徴とする時刻同期方法。
(Appendix 9)
In an electronic device system including a master device that performs time synchronization via a network and two or more slave devices, the oscillator includes a clock that generates a clock for generating time information, and a counter that counts up at a predetermined interval A determination step of determining whether or not the master device is busy performing time synchronization with another slave device when the value of the counter executed by the slave device exceeds a predetermined value;
A first transmission step of transmitting a first message requesting the master device to start time synchronization when it is determined that the busy state is not determined in the determination step;
A third receiving step for receiving the first message from the slave device, which is executed by the master device;
When the first message is received from the slave device in the third receiving step, a second message for obtaining an offset time difference between the master device and the slave device and a time at which the second message is transmitted are included. A third transmission step of transmitting a follow-up message to a target slave device that is the slave device of the other party that received the first message;
A fourth transmission step of transmitting a fifth message indicating the busy state to the slave device other than the target slave device when the second message is transmitted to the target slave device in the third transmission step;
A first receiving step of receiving the second message and the follow-up message from the master device, executed by the target slave device;
Offset calculating step for calculating the offset time difference based on the time when the second message is received in the first receiving step and the time when the second message included in the follow-up message is transmitted from the master device. When,
A second message for transmitting a third message for determining a propagation delay time between the master device and the slave device after receiving the follow-up message from the master device in the first receiving step; Sending step;
A fourth reception step of receiving the third message from the target slave device, executed by the master device;
When receiving the third message from the target slave device in the fourth reception step, a fifth transmission step of transmitting the fourth message including the time when the third message is received to the target slave device;
A second receiving step for receiving the fourth message from the master device, executed by the target slave device;
A delay time calculating step of calculating the propagation delay time based on a time when the third message is transmitted and a time when the master device receives the third message included in the fourth message;
A correction step of correcting the time of the timer based on the offset time difference and the propagation delay time;
A time synchronization method comprising:

(付記10)
前記スレーブ装置が実行する
前記第2送信ステップと、
前記マスタ装置が実行する
前記第4受信ステップと、
前記第5送信ステップと、
前記対象スレーブ装置が実行する
前記第2受信ステップと、
前記遅延時間算出ステップと、
を含む伝搬遅延時間算出処理を所定の周期で繰り返し、
前記補正ステップでは、前記オフセット時間差と、前記伝搬遅延時間算出処理で算出した複数の前記伝搬遅延時間とに基づいて、前記タイマの時刻を補正することを特徴とする付記9に記載の時刻同期方法。
(Appendix 10)
The second transmission step executed by the slave device;
The fourth receiving step executed by the master device;
The fifth transmission step;
The second receiving step executed by the target slave device;
The delay time calculating step;
The propagation delay time calculation process including is repeated at a predetermined cycle,
The time synchronization method according to appendix 9, wherein in the correction step, the time of the timer is corrected based on the offset time difference and the plurality of propagation delay times calculated in the propagation delay time calculation process. .

(付記11)
前記伝搬遅延時間算出処理を繰り返し、前記伝搬遅延時間算出処理を所定の回数行って算出した複数の前記伝搬遅延時間に基づいて、前記発振器が安定したときの前記伝搬遅延時間を予測する予測ステップをさらに備え、
前記補正ステップでは、前記オフセット時間差と、前記予測手段が予測した前記伝搬遅延時間とに基づいて、前記タイマの時刻を補正することを特徴とする付記10に記載の時刻同期方法。
(Appendix 11)
Predicting the propagation delay time when the oscillator is stabilized based on the plurality of propagation delay times calculated by repeating the propagation delay time calculation process and performing the propagation delay time calculation process a predetermined number of times. In addition,
The time synchronization method according to claim 10, wherein in the correction step, the time of the timer is corrected based on the offset time difference and the propagation delay time predicted by the prediction means.

(付記12)
前記伝搬遅延時間算出処理を繰り返し、前記伝搬遅延時間算出処理で算出した前記伝搬遅延時間と、それより前に算出した前記伝搬遅延時間との差が閾値以下になった場合に、
前記補正ステップでは、前記オフセット時間差と、最後に算出した前記伝搬遅延時間とに基づいて、前記タイマの時刻を補正することを特徴とする付記10に記載の時刻同期方法。
(Appendix 12)
When the propagation delay time calculation process is repeated, and the difference between the propagation delay time calculated in the propagation delay time calculation process and the propagation delay time calculated before is less than or equal to a threshold value,
The time synchronization method according to claim 10, wherein in the correction step, the time of the timer is corrected based on the offset time difference and the propagation delay time calculated last.

(付記13)
前記所定の値は、前記スレーブ装置が起動してから前記発振器が安定することを示す時間を表す前記カウンタの値であることを特徴とする付記9に記載の時刻同期方法。
(Appendix 13)
The time synchronization method according to claim 9, wherein the predetermined value is a value of the counter indicating a time indicating that the oscillator is stabilized after the slave device is activated.

(付記14)
前記第4送信ステップでは、前記第5送信ステップで前記第4メッセージを送信する度に、前記対象スレーブ装置以外の前記スレーブ装置に前記第5メッセージを送信することを特徴とする付記9ないし13に記載の時刻同期方法。
(Appendix 14)
In the fourth transmission step, the fifth message is transmitted to the slave device other than the target slave device every time the fourth message is transmitted in the fifth transmission step. The time synchronization method described.

(付記15)
コンピュータを
時刻情報を生成するタイマ、
前記時刻情報を生成するためのクロックを発生させる発振器、
所定の間隔でカウントアップするカウンタ、
前記カウンタの値が所定の値を超えた場合に、前記マスタ装置が他のスレーブ装置と時刻同期を行っているビジー状態であるか否かを判定する判定手段、
前記判定手段が前記ビジー状態でないと判定した場合、前記マスタ装置に時刻同期の開始を要求する第1メッセージを送信する第1送信手段、
前記マスタ装置から、前記マスタ装置と前記スレーブ装置との間のオフセット時間差を求めるための第2メッセージと、前記第2メッセージが前記マスタ装置から送信された時刻を含むフォローアップメッセージとを受信する第1受信手段、
前記第1受信手段が前記第2メッセージを受信した時刻と、前記フォローアップメッセージに含まれる前記第2メッセージが前記マスタ装置から送信された時刻とに基づいて、前記オフセット時間差を算出するオフセット算出手段、
前記第1受信手段が前記マスタ装置から前記フォローアップメッセージを受信したのちに、前記マスタ装置に前記マスタ装置と前記スレーブ装置との間の伝搬遅延時間を求めるための第3メッセージを送信する第2送信手段、
前記マスタ装置から前記第3メッセージを前記マスタ装置が受信した時刻を含む第4メッセージを受信する第2受信手段、
前記第2送信手段が前記第3メッセージを送信した時刻と、前記第4メッセージに含まれる前記第3メッセージを前記マスタ装置が受信した時刻とに基づいて、前記伝搬遅延時間を算出する遅延時間算出手段、および、
前記オフセット時間差および前記伝搬遅延時間に基づいて、前記タイマの時刻を補正する補正手段、
として機能させることを特徴とするプログラム。
(Appendix 15)
A timer that generates time information for the computer,
An oscillator for generating a clock for generating the time information;
A counter that counts up at predetermined intervals,
A determination unit that determines whether or not the master device is busy performing time synchronization with another slave device when the value of the counter exceeds a predetermined value;
A first transmission unit configured to transmit a first message requesting the master device to start time synchronization when the determination unit determines that the busy state is not present;
A second message for receiving an offset time difference between the master device and the slave device and a follow-up message including a time when the second message is transmitted from the master device from the master device. 1 receiving means,
Offset calculating means for calculating the offset time difference based on the time when the first receiving means receives the second message and the time when the second message included in the follow-up message is transmitted from the master device. ,
After the first receiving means receives the follow-up message from the master device, a second message is transmitted to the master device for determining a propagation delay time between the master device and the slave device. Transmission means,
Second receiving means for receiving a fourth message including a time at which the master device has received the third message from the master device;
Delay time calculation for calculating the propagation delay time based on the time at which the second transmission means transmits the third message and the time at which the master device receives the third message included in the fourth message. Means and
Correction means for correcting the time of the timer based on the offset time difference and the propagation delay time;
A program characterized by functioning as

M1 マスタ装置
S1、S2、SX スレーブ装置
11 カウンタ
12 判定部
13 送信部
14 受信部
15 発振器
16 タイマ
17 処理部
31 制御部
32 主記憶部
33 外部記憶部
34 操作部
35 表示部
36 発振器
100 電子機器システム
M1 Master device S1, S2, SX Slave device
11 counter
12 Judgment part
13 Transmitter
14 Receiver
15 Oscillator
16 timer
17 Processing section
31 Control unit
32 Main memory
33 External storage
34 Operation unit
35 Display section
36 Oscillator
100 Electronic equipment system

Claims (10)

マスタ装置とネットワークを介して時刻同期を行うスレーブ装置であって、
時刻情報を生成するタイマと、
前記時刻情報を生成するためのクロックを発生させる発振器と、
所定の間隔でカウントアップするカウンタと、
前記カウンタの値が所定の値を超えた場合に、前記マスタ装置が他のスレーブ装置と時刻同期を行っているビジー状態であるか否かを判定する判定手段と、
前記判定手段が前記ビジー状態でないと判定した場合、前記マスタ装置に時刻同期の開始を要求する第1メッセージを送信する第1送信手段と、
前記マスタ装置から、前記マスタ装置と前記スレーブ装置との間のオフセット時間差を求めるための第2メッセージと、前記第2メッセージが前記マスタ装置から送信された時刻を含むフォローアップメッセージとを受信する第1受信手段と、
前記第1受信手段が前記第2メッセージを受信した時刻と、前記フォローアップメッセージに含まれる前記第2メッセージが前記マスタ装置から送信された時刻とに基づいて、前記オフセット時間差を算出するオフセット算出手段と、
前記第1受信手段が前記マスタ装置から前記フォローアップメッセージを受信したのちに、前記マスタ装置に前記マスタ装置と前記スレーブ装置との間の伝搬遅延時間を求めるための第3メッセージを送信する第2送信手段と、
前記マスタ装置から前記第3メッセージを前記マスタ装置が受信した時刻を含む第4メッセージを受信する第2受信手段と、
前記第2送信手段が前記第3メッセージを送信した時刻と、前記第4メッセージに含まれる前記第3メッセージを前記マスタ装置が受信した時刻とに基づいて、前記伝搬遅延時間を算出する遅延時間算出手段と、
前記オフセット時間差および前記伝搬遅延時間に基づいて、前記タイマの時刻を補正する補正手段と、
を備えることを特徴とするスレーブ装置。
A slave device that performs time synchronization with a master device via a network,
A timer for generating time information;
An oscillator for generating a clock for generating the time information;
A counter that counts up at predetermined intervals;
A determination means for determining whether or not the master device is busy performing time synchronization with other slave devices when the value of the counter exceeds a predetermined value;
A first transmission unit configured to transmit a first message requesting the master device to start time synchronization when the determination unit determines that the busy state is not present;
A second message for receiving an offset time difference between the master device and the slave device and a follow-up message including a time when the second message is transmitted from the master device from the master device. One receiving means;
Offset calculating means for calculating the offset time difference based on the time when the first receiving means receives the second message and the time when the second message included in the follow-up message is transmitted from the master device. When,
After the first receiving means receives the follow-up message from the master device, a second message is transmitted to the master device for determining a propagation delay time between the master device and the slave device. A transmission means;
Second receiving means for receiving a fourth message including a time at which the master device has received the third message from the master device;
Delay time calculation for calculating the propagation delay time based on the time at which the second transmission means transmits the third message and the time at which the master device receives the third message included in the fourth message. Means,
Correction means for correcting the time of the timer based on the offset time difference and the propagation delay time;
A slave device comprising:
前記第2送信手段が、前記マスタ装置に前記第3メッセージを送信し、
前記第2受信手段が、前記マスタ装置から前記第4メッセージを受信し、および、
前記遅延時間算出手段が、前記第2送信手段が前記第3メッセージを送信した時刻と、前記第4メッセージに含まれる前記第3メッセージを前記マスタ装置が受信した時刻とに基づいて、前記伝搬遅延時間を算出する、
伝搬遅延時間算出処理を所定の周期で繰り返し、
前記補正手段は、前記オフセット時間差と、前記伝搬遅延時間算出処理で算出した複数の前記伝搬遅延時間とに基づいて、前記タイマの時刻を補正することを特徴とする請求項1に記載のスレーブ装置。
The second transmission means transmits the third message to the master device;
The second receiving means receives the fourth message from the master device; and
The propagation time based on the time when the delay time calculating means transmits the third message by the second transmitting means and the time when the master device receives the third message included in the fourth message. Calculate the time,
Repeat the propagation delay time calculation process at a predetermined cycle,
2. The slave device according to claim 1, wherein the correction unit corrects the time of the timer based on the offset time difference and the plurality of propagation delay times calculated by the propagation delay time calculation process. .
前記伝搬遅延時間算出処理を繰り返し、前記伝搬遅延時間算出処理を所定の回数行って算出した複数の前記伝搬遅延時間に基づいて、前記発振器が安定したときの前記伝搬遅延時間を予測する予測手段をさらに備え、
前記補正手段は、前記オフセット時間差と、前記予測手段が予測した前記伝搬遅延時間とに基づいて、前記タイマの時刻を補正することを特徴とする請求項2に記載のスレーブ装置。
Predicting means for predicting the propagation delay time when the oscillator is stable based on the plurality of propagation delay times calculated by repeating the propagation delay time calculating process and performing the propagation delay time calculating process a predetermined number of times. In addition,
The slave device according to claim 2, wherein the correction unit corrects the time of the timer based on the offset time difference and the propagation delay time predicted by the prediction unit.
前記伝搬遅延時間算出処理を繰り返し、前記伝搬遅延時間算出処理で算出した前記伝搬遅延時間と、それより前に算出した前記伝搬遅延時間との差が閾値以下になった場合に、
前記補正手段は、前記オフセット時間差と、最後に算出した前記伝搬遅延時間とに基づいて、前記タイマの時刻を補正することを特徴とする請求項2に記載のスレーブ装置。
When the propagation delay time calculation process is repeated, and the difference between the propagation delay time calculated in the propagation delay time calculation process and the propagation delay time calculated before is less than or equal to a threshold value,
The slave device according to claim 2, wherein the correction unit corrects the time of the timer based on the offset time difference and the propagation delay time calculated last.
前記所定の値は、前記スレーブ装置が起動してから前記発振器が安定することを示す時間を表す前記カウンタの値であることを特徴とする請求項1に記載のスレーブ装置。   2. The slave device according to claim 1, wherein the predetermined value is a value of the counter representing a time indicating that the oscillator is stabilized after the slave device is activated. ネットワークを介して時刻同期を行うマスタ装置と2以上のスレーブ装置とを備える電子機器システムであって、
前記スレーブ装置はそれぞれ、
時刻情報を生成するタイマ、
前記時刻情報を生成するためのクロックを発生させる発振器、
所定の間隔でカウントアップするカウンタ、
前記カウンタの値が所定の値を超えた場合に、前記マスタ装置が他のスレーブ装置と時刻同期を行っているビジー状態であるか否かを判定する判定手段、
前記判定手段が前記ビジー状態でないと判定した場合、前記マスタ装置に時刻同期の開始を要求する第1メッセージを送信する第1送信手段、
前記マスタ装置から、前記マスタ装置と前記スレーブ装置との間のオフセット時間差を求めるための第2メッセージと、前記第2メッセージが前記マスタ装置から送信された時刻を含むフォローアップメッセージとを受信する第1受信手段、
前記第1受信手段が前記第2メッセージを受信した時刻と、前記フォローアップメッセージに含まれる前記第2メッセージが前記マスタ装置から送信された時刻とに基づいて、前記オフセット時間差を算出するオフセット算出手段、
前記第1受信手段が前記マスタ装置から前記フォローアップメッセージを受信したのちに、前記マスタ装置に前記マスタ装置と前記スレーブ装置との間の伝搬遅延時間を求めるための第3メッセージを送信する第2送信手段、
前記マスタ装置から前記第3メッセージを前記マスタ装置が受信した時刻を含む第4メッセージを受信する第2受信手段、
前記第2送信手段が前記第3メッセージを送信した時刻と、前記第4メッセージに含まれる前記第3メッセージを前記マスタ装置が受信した時刻とに基づいて、前記伝搬遅延時間を算出する遅延時間算出手段、および、
前記オフセット時間差および前記伝搬遅延時間に基づいて、前記タイマの時刻を補正する補正手段、
を含み、
前記マスタ装置は、
前記スレーブ装置から前記第1メッセージを受信する第3受信手段、
前記第3受信手段が前記スレーブ装置から前記第1メッセージを受信すると、前記第2メッセージと、前記フォローアップメッセージとを、前記第1メッセージを受信した相手の前記スレーブ装置である対象スレーブ装置に送信する第3送信手段、
前記第3送信手段が前記第2メッセージを前記対象スレーブ装置に送信すると、前記ビジー状態であることを示す第5メッセージを、前記対象スレーブ装置以外の前記スレーブ装置に送信する第4送信手段、
前記対象スレーブ装置から前記第3メッセージを受信する第4受信手段、および、
前記第4受信手段が前記対象スレーブ装置から前記第3メッセージを受信すると、前記対象スレーブ装置に前記第4メッセージを送信する第5送信手段、
を含むことを特徴とする電子機器システム。
An electronic device system including a master device that performs time synchronization via a network and two or more slave devices,
Each of the slave devices is
A timer that generates time information,
An oscillator for generating a clock for generating the time information;
A counter that counts up at predetermined intervals,
A determination unit that determines whether or not the master device is busy performing time synchronization with another slave device when the value of the counter exceeds a predetermined value;
A first transmission unit configured to transmit a first message requesting the master device to start time synchronization when the determination unit determines that the busy state is not present;
A second message for receiving an offset time difference between the master device and the slave device and a follow-up message including a time when the second message is transmitted from the master device from the master device. 1 receiving means,
Offset calculating means for calculating the offset time difference based on the time when the first receiving means receives the second message and the time when the second message included in the follow-up message is transmitted from the master device. ,
After the first receiving means receives the follow-up message from the master device, a second message is transmitted to the master device for determining a propagation delay time between the master device and the slave device. Transmission means,
Second receiving means for receiving a fourth message including a time at which the master device has received the third message from the master device;
Delay time calculation for calculating the propagation delay time based on the time at which the second transmission means transmits the third message and the time at which the master device receives the third message included in the fourth message. Means and
Correction means for correcting the time of the timer based on the offset time difference and the propagation delay time;
Including
The master device is
Third receiving means for receiving the first message from the slave device;
When the third receiving unit receives the first message from the slave device, the second message and the follow-up message are transmitted to the target slave device that is the slave device of the other party that received the first message. Third transmitting means for
A fourth transmission unit configured to transmit a fifth message indicating the busy state to the slave device other than the target slave device when the third transmission unit transmits the second message to the target slave device;
Fourth receiving means for receiving the third message from the target slave device; and
Fifth transmission means for transmitting the fourth message to the target slave device when the fourth reception means receives the third message from the target slave device;
An electronic device system comprising:
2以上のスレーブ装置とネットワークを介して時刻同期を行うマスタ装置であって、
前記スレーブ装置から時刻同期の開始を要求する第1メッセージを受信する第3受信手段と、
前記第3受信手段が前記スレーブ装置から前記第1メッセージを受信すると、前記マスタ装置と前記スレーブ装置との間のオフセット時間差を求めるための第2メッセージと、前記第2メッセージを送信した時刻を含むフォローアップメッセージとを、前記第1メッセージを受信した相手の前記スレーブ装置である対象スレーブ装置に送信する第3送信手段と、
前記第3送信手段が前記第2メッセージを前記対象スレーブ装置に送信すると、前記ビジー状態であることを示す第5メッセージを、前記対象スレーブ装置以外の前記スレーブ装置に送信する第4送信手段と、
前記対象スレーブ装置から前記マスタ装置と前記スレーブ装置との間の伝搬遅延時間を求めるための第3メッセージを受信する第4受信手段と、
前記第4受信手段が前記対象スレーブ装置から前記第3メッセージを受信すると、前記対象スレーブ装置に前記第3メッセージを受信した時刻を含む第4メッセージを送信する第5送信手段と、
を備えることを特徴とするマスタ装置。
A master device that performs time synchronization with two or more slave devices via a network,
Third receiving means for receiving a first message for requesting start of time synchronization from the slave device;
When the third receiving unit receives the first message from the slave device, the third receiving unit includes a second message for obtaining an offset time difference between the master device and the slave device, and a time when the second message is transmitted. A third transmission means for transmitting a follow-up message to a target slave device that is the slave device of the other party that received the first message;
A fourth transmission unit configured to transmit a fifth message indicating the busy state to the slave device other than the target slave device when the third transmission unit transmits the second message to the target slave device;
A fourth receiving means for receiving a third message for obtaining a propagation delay time between the master device and the slave device from the target slave device;
When the fourth receiving unit receives the third message from the target slave device, a fifth transmitting unit that transmits a fourth message including the time when the third message is received to the target slave device;
A master device comprising:
前記第4送信手段は、前記第5送信手段が前記第4メッセージを送信する度に、前記対象スレーブ装置以外の前記スレーブ装置に前記第5メッセージを送信することを特徴とする請求項7に記載のマスタ装置。   The said 4th transmission means transmits the said 5th message to said slave apparatuses other than the said target slave apparatus, whenever the said 5th transmission means transmits the said 4th message. Master device. ネットワークを介して時刻同期を行うマスタ装置と2以上のスレーブ装置とを備える電子機器システムにおいて、時刻情報を生成するためのクロックを発生させる発振器と、所定の間隔でカウントアップするカウンタとを備える前記スレーブ装置が実行する
前記カウンタの値が所定の値を超えた場合に、前記マスタ装置が他のスレーブ装置と時刻同期を行っているビジー状態であるか否かを判定する判定ステップと、
前記判定ステップで前記ビジー状態でないと判定した場合、前記マスタ装置に時刻同期の開始を要求する第1メッセージを送信する第1送信ステップと、
前記マスタ装置が実行する
前記スレーブ装置から前記第1メッセージを受信する第3受信ステップと、
前記第3受信ステップで前記スレーブ装置から前記第1メッセージを受信すると、前記マスタ装置と前記スレーブ装置との間のオフセット時間差を求めるための第2メッセージと、前記第2メッセージを送信した時刻を含むフォローアップメッセージとを、前記第1メッセージを受信した相手の前記スレーブ装置である対象スレーブ装置に送信する第3送信ステップと、
前記第3送信ステップで前記第2メッセージを前記対象スレーブ装置に送信すると、前記ビジー状態であることを示す第5メッセージを、前記対象スレーブ装置以外の前記スレーブ装置に送信する第4送信ステップと、
前記対象スレーブ装置が実行する
前記マスタ装置から、前記第2メッセージと、前記フォローアップメッセージとを受信する第1受信ステップと、
前記第1受信ステップで前記第2メッセージを受信した時刻と、前記フォローアップメッセージに含まれる前記第2メッセージが前記マスタ装置から送信された時刻とに基づいて、前記オフセット時間差を算出するオフセット算出ステップと、
前記第1受信ステップで前記マスタ装置から前記フォローアップメッセージを受信したのちに、前記マスタ装置に前記マスタ装置と前記スレーブ装置との間の伝搬遅延時間を求めるための第3メッセージを送信する第2送信ステップと、
前記マスタ装置が実行する
前記対象スレーブ装置から前記第3メッセージを受信する第4受信ステップと、
前記第4受信ステップで前記対象スレーブ装置から前記第3メッセージを受信すると、前記対象スレーブ装置に前記第3メッセージを受信した時刻を含む前記第4メッセージを送信する第5送信ステップと、
前記対象スレーブ装置が実行する
前記マスタ装置から前記第4メッセージを受信する第2受信ステップと、
前記第3メッセージを送信した時刻と、前記第4メッセージに含まれる前記第3メッセージを前記マスタ装置が受信した時刻とに基づいて、前記伝搬遅延時間を算出する遅延時間算出ステップと、
前記オフセット時間差および前記伝搬遅延時間に基づいて、前記タイマの時刻を補正する補正ステップと、
を備えることを特徴とする時刻同期方法。
In an electronic device system including a master device that performs time synchronization via a network and two or more slave devices, the oscillator includes a clock that generates a clock for generating time information, and a counter that counts up at a predetermined interval A determination step of determining whether or not the master device is busy performing time synchronization with another slave device when the value of the counter executed by the slave device exceeds a predetermined value;
A first transmission step of transmitting a first message requesting the master device to start time synchronization when it is determined that the busy state is not determined in the determination step;
A third receiving step for receiving the first message from the slave device, which is executed by the master device;
When the first message is received from the slave device in the third receiving step, a second message for obtaining an offset time difference between the master device and the slave device and a time at which the second message is transmitted are included. A third transmission step of transmitting a follow-up message to a target slave device that is the slave device of the other party that received the first message;
A fourth transmission step of transmitting a fifth message indicating the busy state to the slave device other than the target slave device when the second message is transmitted to the target slave device in the third transmission step;
A first receiving step of receiving the second message and the follow-up message from the master device, executed by the target slave device;
Offset calculating step for calculating the offset time difference based on the time when the second message is received in the first receiving step and the time when the second message included in the follow-up message is transmitted from the master device. When,
A second message for transmitting a third message for determining a propagation delay time between the master device and the slave device after receiving the follow-up message from the master device in the first receiving step; Sending step;
A fourth reception step of receiving the third message from the target slave device, executed by the master device;
When receiving the third message from the target slave device in the fourth reception step, a fifth transmission step of transmitting the fourth message including the time when the third message is received to the target slave device;
A second receiving step for receiving the fourth message from the master device, executed by the target slave device;
A delay time calculating step of calculating the propagation delay time based on a time when the third message is transmitted and a time when the master device receives the third message included in the fourth message;
A correction step of correcting the time of the timer based on the offset time difference and the propagation delay time;
A time synchronization method comprising:
コンピュータを
時刻情報を生成するタイマ、
前記時刻情報を生成するためのクロックを発生させる発振器、
所定の間隔でカウントアップするカウンタ、
前記カウンタの値が所定の値を超えた場合に、前記マスタ装置が他のスレーブ装置と時刻同期を行っているビジー状態であるか否かを判定する判定手段、
前記判定手段が前記ビジー状態でないと判定した場合、前記マスタ装置に時刻同期の開始を要求する第1メッセージを送信する第1送信手段、
前記マスタ装置から、前記マスタ装置と前記スレーブ装置との間のオフセット時間差を求めるための第2メッセージと、前記第2メッセージが前記マスタ装置から送信された時刻を含むフォローアップメッセージとを受信する第1受信手段、
前記第1受信手段が前記第2メッセージを受信した時刻と、前記フォローアップメッセージに含まれる前記第2メッセージが前記マスタ装置から送信された時刻とに基づいて、前記オフセット時間差を算出するオフセット算出手段、
前記第1受信手段が前記マスタ装置から前記フォローアップメッセージを受信したのちに、前記マスタ装置に前記マスタ装置と前記スレーブ装置との間の伝搬遅延時間を求めるための第3メッセージを送信する第2送信手段、
前記マスタ装置から前記第3メッセージを前記マスタ装置が受信した時刻を含む第4メッセージを受信する第2受信手段、
前記第2送信手段が前記第3メッセージを送信した時刻と、前記第4メッセージに含まれる前記第3メッセージを前記マスタ装置が受信した時刻とに基づいて、前記伝搬遅延時間を算出する遅延時間算出手段、および、
前記オフセット時間差および前記伝搬遅延時間に基づいて、前記タイマの時刻を補正する補正手段、
として機能させることを特徴とするプログラム。
A timer that generates time information for the computer,
An oscillator for generating a clock for generating the time information;
A counter that counts up at predetermined intervals,
A determination unit that determines whether or not the master device is busy performing time synchronization with another slave device when the value of the counter exceeds a predetermined value;
A first transmission unit configured to transmit a first message requesting the master device to start time synchronization when the determination unit determines that the busy state is not present;
A second message for receiving an offset time difference between the master device and the slave device and a follow-up message including a time when the second message is transmitted from the master device from the master device. 1 receiving means,
Offset calculating means for calculating the offset time difference based on the time when the first receiving means receives the second message and the time when the second message included in the follow-up message is transmitted from the master device. ,
After the first receiving means receives the follow-up message from the master device, a second message is transmitted to the master device for determining a propagation delay time between the master device and the slave device. Transmission means,
Second receiving means for receiving a fourth message including a time at which the master device has received the third message from the master device;
Delay time calculation for calculating the propagation delay time based on the time at which the second transmission means transmits the third message and the time at which the master device receives the third message included in the fourth message. Means and
Correction means for correcting the time of the timer based on the offset time difference and the propagation delay time;
A program characterized by functioning as
JP2011163534A 2011-07-26 2011-07-26 Slave device, electronic apparatus system, master device, time synchronization method, and program Withdrawn JP2013029319A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2011163534A JP2013029319A (en) 2011-07-26 2011-07-26 Slave device, electronic apparatus system, master device, time synchronization method, and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2011163534A JP2013029319A (en) 2011-07-26 2011-07-26 Slave device, electronic apparatus system, master device, time synchronization method, and program

Publications (1)

Publication Number Publication Date
JP2013029319A true JP2013029319A (en) 2013-02-07

Family

ID=47786507

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2011163534A Withdrawn JP2013029319A (en) 2011-07-26 2011-07-26 Slave device, electronic apparatus system, master device, time synchronization method, and program

Country Status (1)

Country Link
JP (1) JP2013029319A (en)

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101550552B1 (en) * 2014-09-19 2015-09-07 성균관대학교산학협력단 Apparatus for adjusting time synchronization period and method for determinating time synchronization period
KR101593822B1 (en) * 2014-09-02 2016-02-15 주식회사 엘지유플러스 Apparatus for providing communication service, control method thereof, recording medium for recording program for executing the control method, application saved in the recording medium for executing the control method being combined with hardware
JP2017096651A (en) * 2015-11-18 2017-06-01 日本電気株式会社 Time synchronization method, vibration sensor, vibration detection device, program, and recording medium
CN114489237A (en) * 2021-12-24 2022-05-13 北京万集科技股份有限公司 Time synchronization method, control system, and computer-readable storage medium
CN117560758A (en) * 2024-01-08 2024-02-13 深圳市城市公共安全技术研究院有限公司 Time synchronization correction method, device, equipment and storage medium

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR101593822B1 (en) * 2014-09-02 2016-02-15 주식회사 엘지유플러스 Apparatus for providing communication service, control method thereof, recording medium for recording program for executing the control method, application saved in the recording medium for executing the control method being combined with hardware
KR101550552B1 (en) * 2014-09-19 2015-09-07 성균관대학교산학협력단 Apparatus for adjusting time synchronization period and method for determinating time synchronization period
US10594424B2 (en) 2014-09-19 2020-03-17 Research & Business Foundation Sungkyunkwan University Time synchronization slave apparatus capable of adjusting time synchronization period, and method of determining time synchronization period
JP2017096651A (en) * 2015-11-18 2017-06-01 日本電気株式会社 Time synchronization method, vibration sensor, vibration detection device, program, and recording medium
CN114489237A (en) * 2021-12-24 2022-05-13 北京万集科技股份有限公司 Time synchronization method, control system, and computer-readable storage medium
CN117560758A (en) * 2024-01-08 2024-02-13 深圳市城市公共安全技术研究院有限公司 Time synchronization correction method, device, equipment and storage medium
CN117560758B (en) * 2024-01-08 2024-03-22 深圳市城市公共安全技术研究院有限公司 Time synchronization correction method, device, equipment and storage medium

Similar Documents

Publication Publication Date Title
JP6240048B2 (en) Communication apparatus and communication system
JP2013029319A (en) Slave device, electronic apparatus system, master device, time synchronization method, and program
JP6413787B2 (en) COMMUNICATION DEVICE, PROGRAM, AND METHOD
US10034241B2 (en) Wireless communication device and system
JP6488195B2 (en) Communication device for time synchronization
JP2013083451A (en) Time control device, time control method, and program
JP2013083450A (en) Time control device, time control method, and program
JP6132734B2 (en) Time synchronization system and apparatus
JP2016537842A (en) Method for synchronizing a node with a data sink and a node for forming a wireless network
JP2014027437A (en) Communication device, communication system, synchronization processing method, and program
JP6707209B1 (en) Time synchronization system, master device, slave device and program
JP2016139846A (en) Time synchronization system, master unit and slave unit, and time synchronization method
JP2013251878A (en) Communication device, control device, and program
JP6394452B2 (en) Wireless communication apparatus, wireless communication method, and program
JP2015188159A (en) Slave node, time synchronization method, and computer program
US20170117980A1 (en) Time synchronization for network device
JP6240635B2 (en) Wireless communication method and wireless communication system
JP6384318B2 (en) COMMUNICATION DEVICE, COMMUNICATION DEVICE SYNCHRONIZATION METHOD, COMMUNICATION PROGRAM, AND COMMUNICATION SYSTEM
JP2013175852A (en) Time synchronization system, master unit, slave unit, time synchronization method and time synchronization program
JP2015188152A (en) Slave node, control server, time synchronization destination determination method, and computer program
JP2012204912A (en) Clock synchronization device and clock synchronization method
JP2013074338A (en) Time server, terminal, time synchronization system, time synchronization method, and program
CN106507468B (en) A kind of wireless sensor network time synchronization method and system
JP2017183938A (en) Network system, communication device, and communication method
JP2013168884A (en) Time synchronization system, time transmission apparatus, time reception apparatus, time synchronization method and program

Legal Events

Date Code Title Description
A300 Withdrawal of application because of no request for examination

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20141007