JP5626589B2 - Network device and time synchronization method in the same device - Google Patents

Network device and time synchronization method in the same device Download PDF

Info

Publication number
JP5626589B2
JP5626589B2 JP2011078741A JP2011078741A JP5626589B2 JP 5626589 B2 JP5626589 B2 JP 5626589B2 JP 2011078741 A JP2011078741 A JP 2011078741A JP 2011078741 A JP2011078741 A JP 2011078741A JP 5626589 B2 JP5626589 B2 JP 5626589B2
Authority
JP
Japan
Prior art keywords
time
time information
master system
synchronization
slave system
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.)
Active
Application number
JP2011078741A
Other languages
Japanese (ja)
Other versions
JP2012211881A (en
Inventor
雅人 山路
雅人 山路
石井 庸介
庸介 石井
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.)
Yokogawa Electric Corp
Original Assignee
Yokogawa Electric Corp
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 Yokogawa Electric Corp filed Critical Yokogawa Electric Corp
Priority to JP2011078741A priority Critical patent/JP5626589B2/en
Publication of JP2012211881A publication Critical patent/JP2012211881A/en
Application granted granted Critical
Publication of JP5626589B2 publication Critical patent/JP5626589B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Electric Clocks (AREA)
  • Synchronisation In Digital Transmission Systems (AREA)

Description

本発明は、時刻情報配信元と通信を行って時刻情報を取得するマスタシステムと、マスタシステムから時刻情報の提供を受けて時刻同期を行なうスレーブシステムとの間で高精度な時刻同期を行う、ネットワーク機器、および同機器における時刻同期方法に関する。   The present invention performs highly accurate time synchronization between a master system that communicates with a time information distribution source to acquire time information, and a slave system that receives time information from the master system and performs time synchronization. The present invention relates to a network device and a time synchronization method in the device.

図7(a)に従来のスター型ネットワークシステムの構成例が示されている。図7(a)によれば、このスター型ネットワークシステムは、無線装置a1,a2,a3と、この、無線装置a1,a2,a3を上位のネットワークに接続されるアクセスポイントAと、無線装置b1,b2,b3と、この無線装置b1,b2,b3を上位のネットワークに接続するアクセスポイントBとから構成されている。   FIG. 7A shows a configuration example of a conventional star network system. According to FIG. 7A, this star network system includes wireless devices a1, a2, and a3, an access point A that connects the wireless devices a1, a2, and a3 to an upper network, and a wireless device b1. , B2 and b3 and an access point B which connects the wireless devices b1, b2 and b3 to a higher-level network.

この構成によれば、各無線装置a1,a2.a3,b1,b2,b3は、ある特定の1台のアクセスポイントA(またはB)との間でのみ通信を行う。例えば、TDMA(Time Division Multiple Access)通信方式を利用する場合、アクセスポイントA(B)と、その配下に接続される無線装置a1,a2,a3(b1,b2,b3)とは、それぞれが自身で持つ時刻情報等を利用してタイミング制御を行なう。   According to this configuration, each wireless device a1, a2,. a3, b1, b2, and b3 communicate only with one specific access point A (or B). For example, when using a TDMA (Time Division Multiple Access) communication method, each of the access point A (B) and the wireless devices a1, a2, a3 (b1, b2, b3) connected to the access point A (B) Timing control is performed using time information and the like possessed by.

しかしながら、図7(b)に示されるように、通信の信頼性の向上等を目的に各無線装置a1,a2,a3,b1,b2,b3が複数のアクセスポイントA,Bと接続することにより代替経路を構成可能なネットワークの場合、所謂、通信経路の冗長性を持つネットワークの場合、ネットワーク全体で通信タイミングの制御を行う必要がある。例えば、無線装置alがアクセスポイントAと通信している間は、無線装置a2,a3だけでなく、無線装置b1,b2,b3も同様にアクセスポイントAとは通信を行うことができない。また、周波数ホップするネットワークでは、通信のタイミングで双方の無線装置で同じ周波数を使うように設定されている必要がある。これを実現するためには、ネットワークを構成するアクセスポイントや無線装置が共通の時刻情報を持ち、この時刻情報にしたがって、通信タイミングや使用周波数の制御を行う必要がある。   However, as shown in FIG. 7B, the wireless devices a1, a2, a3, b1, b2, b3 are connected to a plurality of access points A, B for the purpose of improving communication reliability. In the case of a network that can constitute an alternative route, in the case of a network having a so-called communication route redundancy, it is necessary to control the communication timing in the entire network. For example, while the wireless device al is communicating with the access point A, not only the wireless devices a2 and a3 but also the wireless devices b1, b2 and b3 cannot communicate with the access point A. Further, in a frequency hopping network, it is necessary that both wireless devices be set to use the same frequency at the timing of communication. In order to realize this, it is necessary for the access points and wireless devices constituting the network to have common time information, and to control the communication timing and the use frequency according to this time information.

また、図7(a)に示した代替経路のない簡単なネットワーク構成であっても、無線の通信干渉を考えた場合、ネットワーク全体の時刻同期が必要になる。具体的に、図7(a)に示すネットワーク構成では、アクセスポイン間(例えば、アクセスポイントAとアクセスポイントBとの間)、無線装置と隣のアクセスポイント間(例えば、無線装置b1とアクセスポイントA)、互いに異なるアクセスポイントに接続されている無線装置間(例えば、無線装置a3と無線装置b1)に通信干渉が発生する可能性のある状況では、干渉回避のためにネットワーク全体の通信タイミングの制御が要求される。   In addition, even in the simple network configuration without an alternative route shown in FIG. 7A, time synchronization of the entire network is necessary when wireless communication interference is considered. Specifically, in the network configuration shown in FIG. 7A, between access points (for example, between access point A and access point B), between a wireless device and an adjacent access point (for example, wireless device b1 and access point) A) In a situation where communication interference may occur between wireless devices connected to different access points (for example, wireless device a3 and wireless device b1), the communication timing of the entire network may be reduced to avoid interference. Control is required.

このため、従来の時刻同期システムは、多くの場合、アクセスポイントが接続される上位のネットワークに時刻リファレンスとなるタイムサーバを設置し、アクセスポイントは、そのタイムサーバから通信タイミング制御に必要な時刻同期情報を受信し、それを無線装置に中継する。このようにしてネットワークを構成する機器全体の時刻同期をはかることで、ネットワーク全体にわたる通信タイミングの制御を行うことが可能になり、通信干渉の解決や省電力制御などが実現できる。   For this reason, in many cases, the conventional time synchronization system installs a time server as a time reference in an upper network to which the access point is connected, and the access point synchronizes time required for communication timing control from the time server. Receive information and relay it to the wireless device. In this way, by synchronizing the time of all the devices constituting the network, it is possible to control the communication timing over the entire network, and it is possible to realize communication interference resolution and power saving control.

図8、図9に、従来の時刻同期システムのシステム構成例が示されている。図8に示すシステム構成によれば、時刻同期システムは、タイムサーバ400と、マスタシステム301と、スレーブシステム302との3つのエンティティにより構成され、これらの間で時刻同期が行なわれる。マスタシステム301とスレーブシステム302は、いずれもアクセスポイント300内に含まれ、マスタシステム301は、タイムサーバ400とアクセスポイント300間で時刻情報のやり取りを行う部分であり、スレーブシステム302は、マスタシステム301から時刻情報を受け取り、これを無線ネットワークに通知する部分である。   8 and 9 show system configuration examples of a conventional time synchronization system. According to the system configuration shown in FIG. 8, the time synchronization system includes three entities, a time server 400, a master system 301, and a slave system 302, and time synchronization is performed among these entities. Both the master system 301 and the slave system 302 are included in the access point 300. The master system 301 is a part that exchanges time information between the time server 400 and the access point 300. The slave system 302 is a master system. This is a part that receives time information from 301 and notifies this to the wireless network.

マスタシステム301は、タイムサーバ400とネットワーク401等によって接続され、例えば、NTP(Network Time Protocol)のような時刻同期のための通信プロトコルを用い、タイムサーバ400から時刻情報の配信を受ける(図8のa)。次に、マスタシステム301は、タイムサーバ400と同期した時刻情報をスレーブシステム303に対してシリアル通信路303を経由して通知する(図8のb)ことにより、マスタシステム301およびスレーブシステム302はタイムサーバ400と時刻同期を行う。   The master system 301 is connected to the time server 400 via the network 401 or the like, and receives time information from the time server 400 using a communication protocol for time synchronization such as NTP (Network Time Protocol) (FIG. 8). A). Next, the master system 301 notifies the slave system 303 of time information synchronized with the time server 400 via the serial communication path 303 (b in FIG. 8), so that the master system 301 and the slave system 302 Time synchronization with the time server 400 is performed.

このときのマスタシステム301とスレーブシステム302との間を伝播する通信フレームのフォーマット形式の一例が図10に示されている。図10によれば、時刻情報を通知するコマンド識別子(CMD)に、同期のための時刻情報(2010/01/01/
12:34:56:789)が付加され構成される。この通信フレームをスレーブシステム302が受信することにより、スレーブシステム302が内部の時刻情報を更新する。
An example of a format format of a communication frame that propagates between the master system 301 and the slave system 302 at this time is shown in FIG. According to FIG. 10, a command identifier (CMD) for notifying time information is added to time information for synchronization (2010/01/01 /
12: 34: 56: 789) is added. When the slave system 302 receives this communication frame, the slave system 302 updates the internal time information.

なお、上記した時刻同期システムは、スレーブシステム302がタイムサーバ400から直接時刻情報を取得することができず、必ずマスタシステム301を経由する必要があることを前提とするものである。例えば、タイムサーバ400とマスタシステム301はNTPクライアント機能を有するシステムであり、スレーブシステム302は、マスタシステム301と連携して動作し、タイムサーバ400やマスタステム301と同期した時刻情報を必要とするデバイスである。具体的に、スレーブシステム302は、センサモジュールや無線モジュール等である。   The time synchronization system described above is based on the premise that the slave system 302 cannot acquire time information directly from the time server 400 and must always pass through the master system 301. For example, the time server 400 and the master system 301 are systems having an NTP client function, and the slave system 302 operates in cooperation with the master system 301 and requires time information synchronized with the time server 400 and the master system 301. It is a device. Specifically, the slave system 302 is a sensor module, a wireless module, or the like.

例えば、スレーブシステム302がセンサモジュールであった場合、ある一定のタイミングや期間ごとにスレーブシステム302自身でセンシングを行い、その結果を蓄積し、あるいはマスタシステム301に通知する動作が考えられる。このとき、センシングを行った時間を高い精度で記録しておく必要があるアプリケーションにおいては、スレーブシステム302が高い精度で時刻情報を維持する必要がある。また、スレーブシステム302が無線モジュールである場合、データの送受信タイミングを決定するためには、データの送受を行う無線モジュール同士が時刻同期している必要がある。特に、TDMA通信方式では無線機同士の時刻同期が極めて重要であり、その精度は通信方式に依存する。一般的な使い方として、タイムサーバ等のあるリファレンスと各無線モジュールがリファレンスとなる時刻情報に同期して無線通信タイミングを決定する。   For example, when the slave system 302 is a sensor module, an operation of sensing by the slave system 302 itself at a certain fixed timing or period, accumulating the result, or notifying the master system 301 can be considered. At this time, in an application that needs to record the sensing time with high accuracy, the slave system 302 needs to maintain time information with high accuracy. When the slave system 302 is a wireless module, the wireless modules that transmit and receive data must be time-synchronized to determine the data transmission / reception timing. In particular, in the TDMA communication method, time synchronization between wireless devices is extremely important, and the accuracy depends on the communication method. As a general usage, a wireless communication timing is determined in synchronization with a reference such as a time server and time information that each wireless module serves as a reference.

マスタシステム301、スレーブシステム302は、ともにシステム内部において同期した時刻情報を維持する。具体的に、各システムに内蔵された水晶振動子等をクロック源とし、これを内部でカウントすることで同期後の時刻情報を維持する。一般に、クロック源となるデバイスには許容誤差が規定されており、この精度に依存した誤差を含みながら時刻情報の維持を行う。具体例として、許容誤差が±100ppmのクロックを搭載したデバイスは、1分間に、(60sec)*(±100ppm)=±6msだけ時刻がずれる可能性がある。このため、システムで要求されている時刻精度を維持するためには1回の時刻同期だけでなく、クロック源の精度に応じた頻度で時刻情報を再同期する必要がある。   Both the master system 301 and the slave system 302 maintain time information synchronized within the system. Specifically, the quartz resonator or the like built in each system is used as a clock source, and the time information after synchronization is maintained by counting this internally. Generally, an allowable error is defined for a device serving as a clock source, and time information is maintained while including an error depending on the accuracy. As a specific example, a device equipped with a clock having an allowable error of ± 100 ppm may be shifted in time by (60 sec) * (± 100 ppm) = ± 6 ms in one minute. Therefore, in order to maintain the time accuracy required by the system, it is necessary to resynchronize the time information with a frequency corresponding to the accuracy of the clock source as well as one time synchronization.

装置間で時刻情報を再同期させることにより時刻のずれを解消し、正確な情報処理を行う時刻同期システムについて従来から多数の特許出願がなされている。例えば、特許文献1には、親局と子局との間で信号を伝送する際に生じる遅延時間を、信号送出時間と信号受信時間とから算出して時刻合わせを行う技術が開示されている。また、特許文献2には、コンピュータと端末間の時刻同期をとるために、事前に測定したデータ転送時間を基に、相手方にデータ転送する時刻を決定し、その時刻を相手方に通知する技術が開示されている。また、特許文献3には、主電子制御装置が時刻同期のための設定値を他の電子制御装置に送信し、他の電子制御装置がその設定値を受信すると割り込機能を有効にし、次に主装置から同じ通信路を介して送信される信号を受信することによって時刻同期を行う割り込み処理を実行する技術が開示されている。   Many patent applications have been filed for time synchronization systems that eliminate time lag by resynchronizing time information between devices and perform accurate information processing. For example, Patent Document 1 discloses a technique for performing time adjustment by calculating a delay time generated when a signal is transmitted between a master station and a slave station from a signal transmission time and a signal reception time. . Patent Document 2 discloses a technique for determining the time for data transfer to the other party based on the data transfer time measured in advance and notifying the other party of the time in order to synchronize the time between the computer and the terminal. It is disclosed. In Patent Document 3, the main electronic control unit transmits a set value for time synchronization to another electronic control unit, and when the other electronic control unit receives the set value, the interrupt function is enabled, In particular, there is disclosed a technique for executing an interrupt process for performing time synchronization by receiving a signal transmitted from a main apparatus via the same communication path.

特開平5−161181号公報JP-A-5-161181 特開平5−216837号公報JP-A-5-216837 特開2004−234098号公報Japanese Patent Laid-Open No. 2004-234098

ところで、スレーブシステムがタイムサーバと高精度な時刻同期を求める状況において、従来の時刻同期方法を適用した場合では、同期精度に影響するいくつかの問題が存在する。一つは、マスタシステムとスレーブシステムに接続された通信バスの仕様により時刻情報の通知に長い時間を要し、あるいは通知に必要な時間が一定でない場合、マスタシステムが図10に示した時刻情報を通知する通信フレームを生成し、それをスレーブシステムに送信している間に、通信バスを経由することに起因して発生する遅延により、時刻情報データがスレーブシステム到達時に既にずれてしまっていることである。   By the way, in the situation where the slave system requires highly accurate time synchronization with the time server, there are some problems that affect the synchronization accuracy when the conventional time synchronization method is applied. One is that when the time information notification takes a long time due to the specifications of the communication bus connected to the master system and the slave system, or the time required for the notification is not constant, the master system displays the time information shown in FIG. The time information data has already shifted when it arrives at the slave system due to the delay caused by passing through the communication bus while generating the communication frame to notify the slave system and sending it to the slave system. That is.

具体的に、1msの時刻同期が要求されるシステムにおいて、マスタシステムとスレーブシステムが38.4kbpsの仕様で接続され、時刻情報の通知に16オクテットのコマンド送受が必要である場合を考える。この場合、時刻情報の通知に、16(octets)×8(bit/octtet)÷115.2(bps)=3.3(ms)だけ時間を要する。実際の通信においてはこの時間に、更に、ソフトウエアの処理や通信プロトコルに関わる各種のオーバーヘッドが加わることになる。この状況で通知された時刻情報をそのままスレーブシステムにセットした場合、マスタシステムとスレーブシステムとの間で要求される精度の時刻同期が成り立たなくなる。   Specifically, in a system that requires time synchronization of 1 ms, consider a case where a master system and a slave system are connected with a specification of 38.4 kbps, and 16-octet command transmission / reception is required for notification of time information. In this case, it takes time to notify the time information by 16 (octets) × 8 (bit / octet) ÷ 115.2 (bps) = 3.3 (ms). In actual communication, various overheads related to software processing and communication protocols are added to this time. When the time information notified in this situation is set in the slave system as it is, the time synchronization with the accuracy required between the master system and the slave system cannot be established.

また、このことは、図8に示すマスタシステム301とスレーブシステム302とは別に、例えば、時刻情報を維持するリアルタイムクロック等、時刻情報を格納するシステムを接続した場合においても同様の問題が発生する。すなわち、通信バスを経由して直接時刻情報の送受を行う場合、時刻同期精度の観点から常に問題が生じうる。   In addition, the same problem occurs when a system that stores time information, such as a real-time clock that maintains time information, is connected separately from the master system 301 and the slave system 302 shown in FIG. . That is, when transmitting and receiving time information directly via a communication bus, a problem can always arise from the viewpoint of time synchronization accuracy.

一方、常に遅延が一定であることが保証される場合は、スレーブシステムに時刻情報をセットするときに、この遅延分を差し引きすることで同期精度を保つことができるが、遅延時間が一定でない場合はこの方法を利用することができない。具体的に、マスタシステムとスレーブシステムとの間の通信遅延を予め見積もることができない例として、同期情報通知のデータと、センサデータや無線データ等そのアプリケーションデータが同じ通信路で送受されている場合、アプリケーションデータが送受信中であるという理由によりマスタシステム側から所望のタイミングでスレーブシステムに時刻情報を通知することができないことが考えられる。この結果として時刻情報の通知に必要な時間が他の通信状況に影響されてしまい、同期の精度が低下する。   On the other hand, when it is guaranteed that the delay is always constant, the synchronization accuracy can be maintained by subtracting this delay when setting the time information in the slave system, but the delay time is not constant Cannot use this method. Specifically, as an example in which the communication delay between the master system and the slave system cannot be estimated in advance, the synchronization information notification data and its application data such as sensor data and wireless data are transmitted and received on the same communication path It is conceivable that time information cannot be notified from the master system side to the slave system at a desired timing because application data is being transmitted / received. As a result, the time required for notification of time information is affected by other communication conditions, and the accuracy of synchronization decreases.

また、同期情報通知のための通信が他の通信に対して優先的に実行できない場合も考えられる。これは、時刻同期情報の通知にアプリケーション通信を一時的に停止することで回避することができる。しかしながら、一般的に時刻同期情報はマスタシステムとスレーブシステムとの間の通信において補助的な位置づけ、つまり、本来、マスタシステム間で通信させたいセンサデータや無線データなどと比べて優先度が低い通信である。このため、本来通信させたいアプリケーションデータに優先して同期情報を送ることは、システム面、アプリケーション面に影響を与える可能性がある。   Further, there may be a case where communication for notification of synchronization information cannot be executed with priority over other communication. This can be avoided by temporarily stopping application communication for notification of time synchronization information. However, in general, time synchronization information is positioned as an auxiliary in communication between the master system and the slave system, that is, communication with a lower priority than sensor data or wireless data originally intended to be communicated between the master systems. It is. For this reason, sending the synchronization information in preference to the application data to be originally communicated may affect the system and application aspects.

本発明は、上記した課題を解決するためになされたものであり、マスタシステムとスレーブシステムとの間の通信遅延や通信状況に依存することなく定期的な時刻同期が可能な、ネットワーク機器、および同機器における時刻同期方法を提供することを目的とする。   The present invention has been made to solve the above-described problems, and is a network device capable of performing periodic time synchronization without depending on communication delay or communication status between a master system and a slave system, and An object is to provide a time synchronization method in the same device.

上記した課題を解決するために本発明は、時刻情報配信元と通信を行って時刻情報を取得するマスタシステムと、前記マスタシステムから時刻情報の提供を受けて時刻同期を行なうスレーブシステムとからなるネットワーク機器であって、前記マスタシステムと前記スレーブシステムとの間で通信を行なう通信パスとは別に、前記マスタシステムから前記スレーブシステムに対して同期信号を送信する送信パスを設け、前記マスタシステムは、
前記スレーブシステムに対し、前記通信パスを介して予め定められた単位時刻の精度で前記時刻情報を通知する時刻情報送信部と、前記時刻情報を通知した後、前記通知した時刻に前記送信パスを介して前記単位時刻以下の時刻情報をリセットする前記同期信号を送信する同期信号送信部と、を備え、前記スレーブシステムは、前記同期信号を受信した時点で、内部で計時している時刻を前記通知された時刻情報に設定し直して計時を再開する時刻同期制御部、を備え、前記時刻同期制御部にて、前記マスタシステムの時刻に比べ前記スレーブシステムの時刻に遅れが生じている場合は前記単位時刻以下の時刻情報の切り上げ処理を行い、前記マスタシステムに比べ前記スレーブシステムの時刻に進みが生じている場合は前記単位時刻以下の時刻情報の切り下げ処理を行なうことを特徴とする。
In order to solve the above-described problems, the present invention comprises a master system that communicates with a time information distribution source to acquire time information, and a slave system that receives time information from the master system and performs time synchronization. A network device, wherein a transmission path for transmitting a synchronization signal from the master system to the slave system is provided separately from a communication path for performing communication between the master system and the slave system. ,
A time information transmitting unit for notifying the slave system of the time information with a predetermined unit time accuracy via the communication path; and notifying the time information after transmitting the time information. A synchronization signal transmitting unit that transmits the synchronization signal that resets the time information of the unit time or less via the slave system, and the slave system receives the time counted internally at the time when the synchronization signal is received. A time synchronization control unit that resets to the notified time information and resumes timing, and in the time synchronization control unit, when the time of the slave system is delayed compared to the time of the master system Perform round-up processing of time information below the unit time, and if the advance of the time of the slave system occurs compared to the master system, the time below the unit time And performing devaluation process time information.

本発明によれば、通信パスとは別に、マスタシステムからスレーブシステムに対して同期信号を送信する独立した送信パスを設けることにより、マスタシステムでは、通信パスを介して時刻情報を通知した後、通知した時刻に送信パスを介して単位時刻以下の時刻情報をリセットする同期信号を定期的に送信する。そして、スレーブシステムでは、同期信号を受信した時点で、内部で計時している時刻を通知された時刻情報に設定し直して計時を再開する。このため、マスタシステムとスレーブシステム間の時刻情報通知のための遅延に起因する時刻同期のずれを回避することが出来、同期信号により、マスタシステムやスレーブシステムの処理状況、あるいはマスタシステムとスレーブシステムとの間の通信状況に依存しない同期信号のやりとりが可能なネットワーク機器を提供することができる。また、本発明によれば、単位時刻以下の時刻情報の切り上げあるいは切り下げ処理によって時刻設定が行なわれるため、スレーブシステム側の時刻設定が容易になる。
According to the present invention, apart from the communication path, by providing an independent transmission path for transmitting a synchronization signal from the master system to the slave system, in the master system, after notifying the time information via the communication path, At the notified time, a synchronization signal for resetting time information equal to or less than the unit time is periodically transmitted via the transmission path. In the slave system, when the synchronization signal is received, the time measured internally is reset to the notified time information, and the time measurement is resumed. For this reason, it is possible to avoid a time synchronization shift caused by a delay for notifying time information between the master system and the slave system. It is possible to provide a network device capable of exchanging synchronization signals independent of the communication status between the two. Further, according to the present invention, the time setting is performed by rounding up or down the time information below the unit time, so the time setting on the slave system side becomes easy.

本発明において、前記単位時刻の精度は、前記通信の遅延による影響を無視出来ることを特徴とする。本発明によれば、アプリケーションが要求する精度に依存せず、比較的ラフな精度の時刻通知で、マスタシステムとスレーブシステム間の時刻情報通知のための遅延に起因する時刻同期のずれを回避することができる。   In the present invention, the accuracy of the unit time is characterized in that the influence of the communication delay can be ignored. According to the present invention, it is possible to avoid a time synchronization shift caused by a delay for notifying time information between the master system and the slave system by using a relatively rough time notification without depending on the accuracy required by the application. be able to.

本発明において、前記マスタシステムは、前記同期信号送信部にて、前記送信パスを介して次の同期信号を送信した後、前記スレーブシステムに設定すべき前記単位時刻以下のアライメント値を示すアライメント信号を送信し、前記スレーブシステムは、前記時刻同期制御部にて前記アライメント信号を受信すると、内部で計時している時刻をリセットし、前記アライメント値に再設定して計時を再開することを特徴とする。本発明によれば、アライメント信号を送信するタイミングを予めスレーブシステムに通知しておくことで任意のタイミングで同期信号のやりとりが可能になる。このため、マスタシステムで同期信号を送信するのが困難であり、あるいは同期信号を定期的に送信することが困難な場合であってもスレーブシステム側での時刻同期が可能になる。   In the present invention, the master system transmits an alignment value not more than the unit time to be set in the slave system after transmitting the next synchronization signal through the transmission path in the synchronization signal transmission unit. When the slave system receives the alignment signal at the time synchronization control unit, the slave system resets the time measured internally, resets the alignment value, and restarts the time measurement. To do. According to the present invention, the synchronization signal can be exchanged at an arbitrary timing by notifying the slave system in advance of the timing for transmitting the alignment signal. For this reason, even if it is difficult to transmit the synchronization signal in the master system or it is difficult to transmit the synchronization signal periodically, time synchronization on the slave system side becomes possible.

また、本発明は、時刻情報配信元と通信を行って時刻情報を取得するマスタシステムと、前記マスタシステムから時刻情報の提供を受けて時刻同期を行なうスレーブシステムとからなるネットワーク機器であって、前記スレーブシステムに対し、前記マスタシステムとは非同期に所定の間隔でタイミング信号を送信するタイミングジェネレータを備え、前記マスタシステムは、前記スレーブシステムに対し、前記時刻情報の他に、前記時刻情報の単位時刻以下の時刻をリセットする同期信号と、前記単位時刻以下のアライメント値を示すアライメント信号とを送信する同期情報送信部を備え、前記スレーブシステムは、前記マスタシステムから前記同期信号を受信すると、内部で計時している時刻を前記マスタシステムから通知される時刻情報に再設定して計時を再開し、前記タイミングジェネレータから送信される前記タイミング信号の到来を待って、前記内部で計時している時刻を、前記マスタシステムから受信した前記アライメント信号が示すアライメント値に設定する時刻同期制御部、を備えることを特徴とする。   The present invention is a network device comprising a master system that communicates with a time information distribution source to acquire time information, and a slave system that receives time information from the master system and performs time synchronization. The slave system includes a timing generator that transmits a timing signal at a predetermined interval asynchronously with the master system, and the master system provides the slave system with a unit of the time information in addition to the time information. A synchronization information transmitting unit that transmits a synchronization signal that resets a time that is less than or equal to a time and an alignment signal that indicates an alignment value that is less than or equal to the unit time, and when the slave system receives the synchronization signal from the master system, Time information notified from the master system To the alignment value indicated by the alignment signal received from the master system, after the timing signal transmitted from the timing generator has arrived, And a time synchronization control unit to be set.

本発明によれば、スレーブシステムに対しマスタシステムとは非同期に所定の間隔でタイミング信号を送信するタイミングジェネレータを備え、マスタシステムが、時刻情報の他に、時刻情報の単位時刻以下の時刻をリセットする同期信号と、アライメント値を送信する。これを受けてスレーブシステムが、内部で計時している時刻を受信した時刻情報に再設定して計時を再開し、タイミングジェネレータから所定の間隔で送信されるタイミング信号の到来を待って、受信したアライメント値を設定する。このため、マスタシステムが高優度の割り込みを処理中である等、アライメント信号の送信が待たされる場合であっても、タイミングジェネレータによりマスタシステムの処理状況とは無関係に一定のタイミングでアライメント信号の送信が可能になるため、時刻同期を優先して処理することが可能なネットワーク機器を提供することができる。   According to the present invention, a timing generator that transmits a timing signal to a slave system at a predetermined interval asynchronously with the master system is provided, and the master system resets the time below the unit time of the time information in addition to the time information. A synchronization signal to be transmitted and an alignment value are transmitted. In response, the slave system resets the internally timed time to the received time information, restarts timekeeping, and waits for the arrival of a timing signal transmitted at a predetermined interval from the timing generator. Set the alignment value. For this reason, even if the master system is processing a high-priority interrupt, such as when an alignment signal is sent, the timing generator does not send the alignment signal at a fixed timing regardless of the processing status of the master system. Since transmission becomes possible, it is possible to provide a network device capable of processing with priority given to time synchronization.

本発明において、前記マスタシステムは、前記スレーブシステムに前記時刻情報を送信する前に、前記タイミングジェネレータに対し、前記タイミング信号の送出間隔を設定することを特徴とする。本発明によれば、マスタシステムがタイミングジェネレータのタイミング信号の送出間隔をコントロールすることにより、スレーブシステムに対して任意のタイミングでアライメント関係の信号を送信することができる。   In the present invention, the master system sets the transmission interval of the timing signal to the timing generator before transmitting the time information to the slave system. According to the present invention, the master system can transmit an alignment-related signal at an arbitrary timing to the slave system by controlling the timing signal transmission interval of the timing generator.

また、本発明は、時刻情報配信元と通信を行って時刻情報を取得するマスタシステムと、前記マスタシステムから時刻情報の提供を受けて時刻同期を行なうスレーブシステムとからなるネットワーク機器における時刻同期方法であって、前記マスタシステムが、前記スレーブシステムに対し、前記マスタシステムと前記スレーブシステムとを接続する通信パスを介して前記通信の遅延による影響が無視できる単位時刻の精度で前記時刻情報を通知するステップと、前記マスタシステムが、前記時刻情報を通知した後、前記通知した時刻に、前記マスタシステムと前記スレーブシステムとを接続する前記通信パスとは独立して設けられる送信パスを介して前記単位時刻以下の時刻情報をリセットするステップと、前記スレーブシステムが、前記同期信号を受信した時点で、内部で計時している時刻を前記通知された時刻情報に設定し直して計時を再開するステップと、を有することを特徴とする。   The present invention also provides a time synchronization method in a network device comprising a master system that communicates with a time information distribution source to acquire time information, and a slave system that receives time information from the master system and performs time synchronization. The master system notifies the slave system of the time information with a unit time accuracy that can ignore the influence of the communication delay through a communication path connecting the master system and the slave system. And after the master system notifies the time information, the transmission time provided independently of the communication path connecting the master system and the slave system at the notified time. Resetting time information below unit time, and the slave system, Upon receiving the period signal, and having a a step restarts the timing reconfigure the time instant being clocked by the internal to the notified time information.

本発明によれば、マスタシステムでは、通信パスを介して時刻情報を通知した後、通知した時刻に通信パスとは独立して設けられる送信パスを介して単位時刻以下の時刻情報をリセットする同期信号を定期的に送信し、スレーブシステムでは、同期信号を受信した時点で、内部で計時している時刻を通知された時刻情報に設定し直して計時を再開する。このため、マスタシステムとスレーブシステム間の時刻情報通知の為の遅延に起因する時刻同期のずれを回避することが出来、同期信号により、マスタシステムやスレーブシステムの処理状況、あるいはマスタシステムとスレーブシステムとの間の通信状況に依存しない同期信号のやりとりが可能になる。   According to the present invention, in the master system, after notifying the time information via the communication path, the time information of the unit time or less is reset via the transmission path provided independently of the communication path at the notified time. The slave system periodically transmits a signal, and at the time when the slave system receives the synchronization signal, it resets the internally timed time to the notified time information and restarts timekeeping. For this reason, it is possible to avoid a time synchronization shift caused by a delay in notifying time information between the master system and the slave system, and the processing status of the master system or the slave system or the master system and the slave system is determined by the synchronization signal. Synchronization signals can be exchanged without depending on the communication status between the two.

本発明は、時刻情報配信元と通信を行って時刻情報を取得するマスタシステムと、前記マスタシステムから時刻情報の提供を受けて時刻同期を行なうスレーブシステムと、前記スレーブシステムに、前記マスタシステムとは非同期に所定の間隔でタイミング信号を送信するタイミングジェネレータと、を備えたネットワーク機器における時刻同期方法であって、前記マスタシステムが、前記スレーブシステムに対し、前記時刻情報の他に、前記時刻情報の単位時刻以下の時刻をリセットする同期信号と、前記単位時刻以下のアライメント値を示すアライメント信号を送信するステップと、前記スレーブシステムが、前記マスタシステムから前記同期信号を受信すると、内部で計時している時刻を前記マスタシステムから送信される時刻情報に再設定して計時を再開するステップと、前記スレーブシステムが、前記タイミングジェネレータから送信される前記タイミング信号の到来を待って、前記内部で計時している時刻を前記マスタシステムから受信した前記アライメント信号が示すアライメント値に設定するステップと、を有することを特徴とする。   The present invention provides a master system that communicates with a time information distribution source to acquire time information, a slave system that receives time information from the master system and performs time synchronization, the slave system, the master system, Is a time synchronization method in a network device including a timing generator that asynchronously transmits a timing signal at a predetermined interval, wherein the master system sends the time information to the slave system in addition to the time information. A synchronization signal that resets a time that is less than or equal to a unit time, an alignment signal that indicates an alignment value that is less than or equal to the unit time, and an internal clock when the slave system receives the synchronization signal from the master system. To the time information sent from the master system. A step of setting and restarting the timing; and when the slave system receives the timing signal transmitted from the timing generator and receives the time measured internally from the master system, And a step of setting the alignment value to be indicated.

本発明によれば、マスタシステムが、時刻情報の他に、時刻情報の単位時刻以下の時刻をリセットする同期信号と、アライメント値を送信し、これを受けたスレーブシステムが、内部で計時している時刻を受信した時刻情報に再設定して計時を再開し、タイミングジェネレータから所定の間隔で送信されるタイミング信号の到来を待ってマスタシステムから受信したアライメント値を設定する。このため、マスタシステムが高優度の割り込みを処理中である等、アライメント信号の送信が待たされる場合であっても、タイミングジェネレータによりマスタシステムの処理状況とは無関係に一定のタイミングでアライメント関連の信号の送信が可能になるため、時刻同期を優先して処理することが可能になる。   According to the present invention, in addition to the time information, the master system transmits a synchronization signal for resetting a time equal to or lower than the unit time of the time information and an alignment value, and the slave system that receives this signal internally measures the time. The time is restarted by resetting the current time to the received time information, and the alignment value received from the master system is set after the arrival of the timing signal transmitted at a predetermined interval from the timing generator. For this reason, even if the master system is processing a high-priority interrupt, such as when an alignment signal transmission is awaited, the timing generator does not relate to the processing status of the master system. Since the signal can be transmitted, the time synchronization can be processed with priority.

本発明によれば、マスタシステムとスレーブシステムとの間の通信遅延や通信状況に依存することなく定期的な時刻同期が可能な、ネットワーク機器、および同機器における時刻同期方法を提供することができる。   According to the present invention, it is possible to provide a network device capable of performing periodic time synchronization without depending on communication delay and communication status between the master system and the slave system, and a time synchronization method in the device. .

本発明の実施の形態1に係るネットワーク機器の構成を示すブロック図である。It is a block diagram which shows the structure of the network device which concerns on Embodiment 1 of this invention. 本発明の実施の形態1に係るネットワーク機器により生成される通信フレームの構成を示す図である。It is a figure which shows the structure of the communication frame produced | generated by the network device which concerns on Embodiment 1 of this invention. 本発明の実施の形態1に係るネットワーク機器による時刻同期の動作を時間軸上で示した図である。It is the figure which showed the operation | movement of the time synchronization by the network device which concerns on Embodiment 1 of this invention on the time axis. 本発明の実施の形態2に係るネットワーク機器の構成を示すブロック図である。It is a block diagram which shows the structure of the network apparatus which concerns on Embodiment 2 of this invention. 本発明の実施の形態2に係るネットワーク機器の動作を時系列に示した動作シーケンス図である。It is the operation | movement sequence diagram which showed the operation | movement of the network device which concerns on Embodiment 2 of this invention in time series. 本発明の実施の形態2に係るネットワーク機器の応用例の構成を示すブロック図である。It is a block diagram which shows the structure of the application example of the network device which concerns on Embodiment 2 of this invention. 従来のスター型ネットワークシステムの接続構成例を示す図である。It is a figure which shows the example of a connection structure of the conventional star type | mold network system. 従来のネットワーク機器の時刻同期方法を説明するために引用した図である。It is the figure quoted in order to demonstrate the time synchronization method of the conventional network device. 図8に示すマスタシステムとスレーブシステムが実装されるアクセスポイントの構成を示す図である。It is a figure which shows the structure of the access point by which the master system and slave system which are shown in FIG. 8 are mounted. 従来のネットワーク機器で転送される時刻同期のための通信フレームのフォーマットを示す図である。It is a figure which shows the format of the communication frame for the time synchronization transferred with the conventional network device.

以下、添付図面を参照して本発明を実施するための実施の形態(以下、単に本実施形態という)について詳細に説明する。   Hereinafter, an embodiment for carrying out the present invention (hereinafter simply referred to as the present embodiment) will be described in detail with reference to the accompanying drawings.

(実施形態1の構成)
図1は、本実施形態1に係るネットワーク機器20Aの構成を示すブロック図である。図1によれば、ネットワーク機器20Aは、時刻情報配信元であるタイムサーバ10と通信を行って時刻情報を取得するマスタシステム21Aと、マスタシステム21Aから時刻情報の提供を受けて時刻同期を行なうスレーブシステム22Aとからなる。特徴は、マスタシステム21Aとスレーブシステム22Aとの間で通信を行なう通信パス23とは別に、マスタシステム21Aからスレーブシステム22Aに対して同期信号を送信する送信パス24を設けたことにある。
(Configuration of Embodiment 1)
FIG. 1 is a block diagram illustrating a configuration of a network device 20A according to the first embodiment. According to FIG. 1, the network device 20A communicates with the time server 10 that is a time information distribution source to acquire time information, and receives time information from the master system 21A to perform time synchronization. It consists of a slave system 22A. A feature is that a transmission path 24 for transmitting a synchronization signal from the master system 21A to the slave system 22A is provided in addition to the communication path 23 for performing communication between the master system 21A and the slave system 22A.

マスタシステム21Aは、スレーブシステム22Aに対し、通信パス23を介して通信の遅延による影響が無視できる単位時刻の精度で時刻情報を通知する時刻情報送信部211と、この時刻情報を通知した後、通知した時刻に送信パス24を介して単位時刻以下の時刻情報をリセットする同期信号を定期的に送信する同期信号送信部212と、を備えている。また、スレーブシステム22Aは、同期信号を受信した時点で、内部で計時している時刻を通知された時刻情報に設定し直して計時を再開する時刻同期制御部221、を備えている。   The master system 21A notifies the slave system 22A of the time information transmission unit 211 for notifying the time information with unit time accuracy that can ignore the influence of the communication delay via the communication path 23, and after notifying the time information, A synchronization signal transmission unit 212 that periodically transmits a synchronization signal that resets time information equal to or less than the unit time through the transmission path 24 at the notified time. In addition, the slave system 22A includes a time synchronization control unit 221 that resets the time measured internally to the notified time information when the synchronization signal is received, and restarts the time measurement.

なお、タイムサーバ10とネットワーク機器20A(マスタシステム21A)とは、ネットワーク30等で接続され、マスタシステム21Aは、NTPのような時刻同期のためのプロトコルを用いてタイムサーバ10から時刻情報の配信を受けるものとする。   The time server 10 and the network device 20A (master system 21A) are connected by a network 30 or the like, and the master system 21A distributes time information from the time server 10 using a protocol for time synchronization such as NTP. Shall receive.

(実施形態1の動作)
図1に示すネットワーク機器20Aでは、まず、時刻同期のための通信プロトコルなどを用い、タイムサーバ10とマスタシステム21Aとの間で上記した時刻同期を行う(ステップS11)。その後、マスタシステム21Aでは、時刻情報送信部211がスレーブシステム22Aに対して通信パス23を用いたシリアル通信によって、例えば、図2(a)に示すフォーマットを持つ通信フレームを送信することにより時刻情報の通知を行う(ステップS12)。
(Operation of Embodiment 1)
In the network device 20A shown in FIG. 1, first, the time synchronization described above is performed between the time server 10 and the master system 21A using a communication protocol for time synchronization (step S11). Thereafter, in the master system 21A, the time information transmission unit 211 transmits the communication information having the format shown in FIG. 2A, for example, by serial communication using the communication path 23 to the slave system 22A. Is notified (step S12).

このとき、通知する時刻情報は、マスタシステム21Aとスレーブシステム22Aとの間で通信遅延が発生することから、アプリケーションで要求される精度で通知することはしない。例えば、通信の遅延による影響が無視できる程度のラフな精度の時刻を通知するものでよい。具体的に、1ミリ秒の時刻精度が必要なアプリケーションにおいて、図2(a)に示すように、スレーブシステム22Aに、「2010/01/01,12:34:56」のように、秒単位の時刻を通知している。これに対し、従来の時刻同期方法では、図10に、「2010/01/01,12:34:56:789」として示したようにアプリケーションが要求するミリ秒単位で通知している。   At this time, the time information to be notified is not notified with accuracy required by the application because a communication delay occurs between the master system 21A and the slave system 22A. For example, it is possible to notify a time with rough accuracy to such an extent that the influence of communication delay can be ignored. Specifically, in an application that requires time accuracy of 1 millisecond, as shown in FIG. 2A, the slave system 22A has a unit of seconds such as “2010/01/01, 12:34:56”. The time is notified. In contrast, in the conventional time synchronization method, notification is made in units of milliseconds requested by the application as shown as “2010/01/01, 12: 34: 56: 789” in FIG.

続いて、時刻情報送信部211は、マスタシステム21Aの時刻が先に指定したタイミングで、スレーブシステム22Aに対し、通信パス23とは独立して設けられる送信パス24を介して同期信号を送信する(ステップS13)。通常、この信号はスレーブシステム22Aに対する割り込み信号として実現することが一般的であるが、マスタシステム21Aが所望のタイミングでスレーブシステム22Aに信号を送信し、スレーブシステム22Aがその信号に直ちに処理できる仕組みであれば、割り込みでなくてもよい。   Subsequently, the time information transmission unit 211 transmits a synchronization signal to the slave system 22A via the transmission path 24 provided independently of the communication path 23 at the timing specified in advance by the time of the master system 21A. (Step S13). Normally, this signal is generally realized as an interrupt signal for the slave system 22A. However, the master system 21A transmits a signal to the slave system 22A at a desired timing, and the slave system 22A can immediately process the signal. If so, it does not have to be an interrupt.

スレーブシステム22Aでは、時刻同期制御部221が、マスタシステム21Aの同期信号送信部212から同期信号を受信したタイミングで、スレーブシステム22A自身で計時している時刻を、予め設定された時刻に設定してカウントを開始する。このようにして、時刻情報の同期処理を行った後、マスタシステム21Aとスレーブシステム22Aは、それぞれのシステム21A、22Aに実装されている仕組みを使用して時刻を維持する。一般的に、時刻維持は、それぞれのシステム21A、22Aに搭載されているクロックをカウントすることで実現される。しかしながら、使用するクロック源によりその特性はさまざまであり、一度正確に時刻同期をしたとしてもしばらく経過すると、マスタシステム21Aとスレーブシステム22Aとの間で時刻のずれが発生する。このため定期的な同期処理の実行が必要である。   In the slave system 22A, at the timing when the time synchronization control unit 221 receives the synchronization signal from the synchronization signal transmission unit 212 of the master system 21A, the time measured by the slave system 22A itself is set to a preset time. Start counting. After performing the time information synchronization process in this way, the master system 21A and the slave system 22A maintain the time using a mechanism implemented in each of the systems 21A and 22A. In general, time keeping is realized by counting clocks mounted in the respective systems 21A and 22A. However, the characteristics vary depending on the clock source used, and even if time synchronization is performed once, a time lag occurs between the master system 21A and the slave system 22A after a while. For this reason, it is necessary to periodically execute synchronization processing.

図3(a)は、マスタシステム21Aとスレーブシステム22Aとの間における時刻同期方法をタイムシーケンスで示した図である。図中、時間軸方向に示される数値は、ms単位の時間を表している。つまり、“993”は、各システム21A、22A内部で秒未満の時刻が993msとなるタイミングを示している。図3(a)に時刻ずれ(Δt)と示したように、スレーブシステム22Aがマスタシステム21Aに対して0.3ms程度遅延している状況において、マスタシステム21Aから自身の持つ時刻のミリ秒単位が0になるタイミングにて同期信号としての時刻リセット信号(R)を送出する。スレーブシステム22Aの時刻同期制御部221は、この信号のタイミングにあわせてミリ秒単位の時刻を0にリセットしてカウントを再開する。このようにして時刻リセット信号(R)送信後の時刻のずれを補正することができる。   FIG. 3A is a diagram showing a time synchronization method in a time sequence between the master system 21A and the slave system 22A. In the figure, the numerical value shown in the time axis direction represents time in ms units. That is, “993” indicates the timing at which the time less than a second becomes 993 ms in each of the systems 21A and 22A. As indicated by the time lag (Δt) in FIG. 3A, in the situation where the slave system 22A is delayed by about 0.3 ms from the master system 21A, the master system 21A has its own time in milliseconds. A time reset signal (R) as a synchronization signal is sent at a timing when becomes zero. The time synchronization control unit 221 of the slave system 22A resets the time in milliseconds to 0 in accordance with the timing of this signal, and restarts counting. In this way, the time lag after the time reset signal (R) is transmitted can be corrected.

なお、スレーブシステム22A側の時刻設定の方法として、時刻同期制御部221は、マスタシステム21Aに比べてスレーブシステム22Aの方が遅れている場合、ミリ秒単位の切り上げの処理を行う。逆に、スレーブシステム22Aの方が進んでいる場合は、ミリ秒単位の切捨て処理を行う。   As a time setting method on the slave system 22A side, the time synchronization control unit 221 performs round-up processing in milliseconds when the slave system 22A is behind the master system 21A. Conversely, when the slave system 22A is advanced, a truncation process in milliseconds is performed.

なお、図3(a)において、同期信号送信部212は、ミリ秒単位が0のタイミングで時刻リセット信号(R)を送出したが、マスタシステム21Aの時刻がxミリ秒のときに時刻リセット信号(R)を送信し、そのことが予めスレーブシステム22Aで把握しているのであれば、ミリ秒単位が0のときに信号を出す必要はない。図2(b)に、その場合に同期信号送信部212からスレーブシステム22Aに送信される通信フレームのフォーマットが、図3(b)に、その場合のマスタシステム21Aとスレーブシステム22Aとの間における時刻同期方法が時間軸上に示されている。これは、マスタシステム21Aの時刻のミリ秒単位が0となるときに時刻リセット信号を送信することが困難であり、または時刻リセット信号を一定の間隔で送信することが困難であった場合の対応であり、マスタシステム21A側に対して予め図2(b)に示すフォーマットにしたがい、次のアライメント信号を入力したときにスレーブシステム22A側で設定すべきミリ秒単位の数値を指定しておく方法である。   In FIG. 3A, the synchronization signal transmission unit 212 transmits the time reset signal (R) at a timing of 0 in milliseconds, but the time reset signal when the time of the master system 21A is x milliseconds. If (R) is transmitted and this is known in advance by the slave system 22A, it is not necessary to issue a signal when the millisecond unit is 0. FIG. 2B shows the format of the communication frame transmitted from the synchronization signal transmission unit 212 to the slave system 22A in that case. FIG. 3B shows the format between the master system 21A and the slave system 22A in that case. The time synchronization method is shown on the time axis. This is a case where it is difficult to transmit the time reset signal when the millisecond unit of the time of the master system 21A is 0, or it is difficult to transmit the time reset signal at regular intervals. In accordance with the format shown in FIG. 2 (b) in advance for the master system 21A side, a numerical value in milliseconds that should be set on the slave system 22A side when the next alignment signal is input. It is.

具体的に、図2(b)に示す通信フレームは、スレーブシステム22Aがアライメント信号を受信したときに、ミリ秒単位の時刻を「789ms(アライメント値)」に再設定するという情報をマスタシステム21が指示するコマンドである。マスタシステム21Aの同期信号送信部212は、図3(b)に示すように、マスタシステム21Aが持つミリ秒単位の時刻が789msになるタイミングでアライメント信号(Ali)を送出する。これを受けたスレーブシステム22Aは、時刻同期制御部221が、スレーブシステム22A自身でカウントしていた時間情報をリセットし、ミリ秒単位の時刻を、予め設定された「789ms」にセットしなおしてカウントを再開する。   Specifically, in the communication frame shown in FIG. 2B, when the slave system 22A receives the alignment signal, information indicating that the time in milliseconds is reset to “789 ms (alignment value)”. Is the command indicated. As shown in FIG. 3B, the synchronization signal transmission unit 212 of the master system 21A transmits an alignment signal (Ali) at a timing when the time in milliseconds of the master system 21A becomes 789 ms. Receiving this, the slave system 22A resets the time information counted by the slave system 22A itself by the time synchronization control unit 221 and resets the time in milliseconds to the preset “789 ms”. Resume counting.

なお、上記の例ではミリ秒単位の例を扱ったが、例えば、10ミリ秒、100ミリ秒単位のようにもっと荒い単位時刻であっても、あるいは10マイクロ秒、100マイクロ秒等、より細かな単位時刻であってもかまわない。いずれにしてもシステム21、22間で必要とされる時刻同期精度でこのシーケンスを実行すればよい。   In the above example, an example of a millisecond unit has been dealt with. For example, even in a rougher unit time such as a unit of 10 milliseconds or 100 milliseconds, or a finer unit such as 10 microseconds or 100 microseconds. It may be a unit time. In any case, this sequence may be executed with the time synchronization accuracy required between the systems 21 and 22.

(実施形態1の効果)
以上説明のように、本実施形態1に係るネットワーク機器20Aによれば、マスタシステム21Aとスレーブシステム22Aとの間の時刻情報通知のための通信遅延に起因する時刻同期のずれを回避することができる。また、マスタシステム21Aはスレーブシステム22Aに対し、通信パス23とは独立して設けられる送信パス24を介して同期信号(アライメント信号)を送信することにより、マスタシステム21Aやスレーブシステム22Aの処理状況や両システム21A、22A間の通信状況に依存しない同期情報のやり取りが可能になる。更には、予めアライメント信号を送信するタイミングをスレーブシステム22A側に通知しておくことにより、任意のタイミングで同期信号を送受信することが可能になる。
(Effect of Embodiment 1)
As described above, according to the network device 20A according to the first embodiment, it is possible to avoid a time synchronization shift caused by a communication delay for notifying time information between the master system 21A and the slave system 22A. it can. Further, the master system 21A transmits a synchronization signal (alignment signal) to the slave system 22A via the transmission path 24 provided independently of the communication path 23, whereby the processing status of the master system 21A and the slave system 22A In addition, it is possible to exchange synchronization information independent of the communication status between the two systems 21A and 22A. Further, by notifying the slave system 22A side of the timing for transmitting the alignment signal in advance, the synchronization signal can be transmitted and received at an arbitrary timing.

(実施形態2の構成)
上記した実施形態1に係るネットワーク機器20Aでは、時刻リセット信号やアライメント信号(以下、総称してアライメント信号という)は、コマンドによって発行される。このように、アライメント信号がソフトウエアにより生成されるか、あるいはマスタシステム21Aが非リアルタイム環境で動作している場合には、アライメント信号を送信するタイミングでのマスタシステム21Aの内部処理状況によってはアライメント信号の送出が遅延する場合がある。例えば、マスタシステム21Aが高優先度の割り込み処理を実行中等である。これを回避するためには、アライメント信号の送出を優先的に処理する方法が必要である。これを保証する仕組みについて実施形態2として以下に説明する。
(Configuration of Embodiment 2)
In the network device 20A according to the first embodiment described above, a time reset signal and an alignment signal (hereinafter collectively referred to as an alignment signal) are issued by a command. As described above, when the alignment signal is generated by software or the master system 21A is operating in a non-real-time environment, the alignment may be performed depending on the internal processing status of the master system 21A at the timing of transmitting the alignment signal. Signal transmission may be delayed. For example, the master system 21A is executing a high priority interrupt process. In order to avoid this, a method for preferentially processing alignment signal transmission is required. A mechanism for guaranteeing this will be described below as a second embodiment.

図4は、本実施形態2に係るネットワーク機器20Bの構成を示すブロック図である。図4によれば、ネットワーク機器20Bは、時刻情報配信元であるタイムサーバ10と通信を行って時刻情報を取得するマスタシステム21Bと、マスタシステム21Bから時刻情報の提供を受けて時刻同期を行なうスレーブシステム22Bとからなる。図1に示す実施形態1との差異は、上記構成に、スレーブシステム22Bに対し、マスタシステム21Bとは非同期に所定の間隔でタイミング信号を送信する、アライメント信号源としてのタイミングジェネレータ25を付加したことにある。図1に示す実施形態1のスレーブシステム22A側との構成上の差異は、送信パス24に代わって、タイミングジェネレータ25が接続されていることにある。   FIG. 4 is a block diagram illustrating a configuration of the network device 20B according to the second embodiment. According to FIG. 4, the network device 20B communicates with the time server 10 that is a time information distribution source to acquire time information, and receives time information from the master system 21B to perform time synchronization. It consists of a slave system 22B. The difference from the first embodiment shown in FIG. 1 is that a timing generator 25 as an alignment signal source that transmits a timing signal at a predetermined interval asynchronously with the master system 21B is added to the slave system 22B in the above configuration. There is. The difference in configuration from the slave system 22 </ b> A side of the first embodiment shown in FIG. 1 is that a timing generator 25 is connected instead of the transmission path 24.

マスタシステム21Bは、スレーブシステム22Bに対し、時刻情報の他に、時刻情報の単位時刻以下の時刻をリセットする同期信号及び/又は、単位時刻以下のアライメント値を示すアライメント信号を送信する同期信号送信部213と、スレーブシステム22Bに時刻情報を送信する前に、タイミングジェネレータ25に対してタイミング信号の送出間隔を設定するタイミング信号送出間隔設定部214と、を備えている。また、スレーブシステム22Bは、マスタシステム21Bから同期信号を受信すると、内部で計時している時刻をマスタシステム21Bから通知される時刻情報に再設定して計時を再開し、タイミングジェネレータ25から送信されるタイミング信号の到来を待って、内部で計時している時刻を、マスタシステム21Bから受信したアライメント信号が示すアライメント値に設定する時刻同期制御部222、を備えている。   The master system 21B transmits to the slave system 22B, in addition to the time information, a synchronization signal that resets a time that is less than the unit time of the time information and / or an alignment signal that indicates an alignment value that is less than the unit time. And a timing signal transmission interval setting unit 214 that sets a timing signal transmission interval to the timing generator 25 before transmitting time information to the slave system 22B. When the slave system 22B receives the synchronization signal from the master system 21B, the slave system 22B resets the time measured internally to the time information notified from the master system 21B, restarts the time measurement, and is transmitted from the timing generator 25. A time synchronization control unit 222 that waits for the arrival of the timing signal and sets the time measured internally to the alignment value indicated by the alignment signal received from the master system 21B.

なお、アライメント信号源として、マスタシステム21Bとスレーブシステム22Bの外部に接続されるタイミングジェネレータ25は、ある決められたタイミングにおいてアライメント値設定のためのタイミング信号を送出できるものであれば、マイクロプロセッサを含む別システムであってもIC(Integrated Circuit)単体であってもかまわない。タイミングジェネレータ25の具体例として、RTC(Real Time Clock)の採用が考えられる。通常このようなICには、例えば、1秒間隔等、定間隔で信号を送出する機能があり、この機能をアライメント信号として使用するものとする。時刻の正確性が必要な場合、高精度な温度補償型水晶を搭載したRTCを利用する。   As an alignment signal source, the timing generator 25 connected to the outside of the master system 21B and the slave system 22B can be a microprocessor as long as it can send a timing signal for setting an alignment value at a predetermined timing. It may be a separate system or an IC (Integrated Circuit) alone. As a specific example of the timing generator 25, an RTC (Real Time Clock) may be adopted. Usually, such an IC has a function of transmitting a signal at regular intervals, for example, at intervals of 1 second, and this function is used as an alignment signal. When time accuracy is required, an RTC equipped with a highly accurate temperature compensated crystal is used.

(実施形態2の動作)
以下、図4に示す本実施形態2に係るネットワーク機器20Bの動作について、図5示す動作シーケンス図を参照して詳細に説明する。
(Operation of Embodiment 2)
Hereinafter, the operation of the network device 20B according to the second embodiment shown in FIG. 4 will be described in detail with reference to the operation sequence diagram shown in FIG.

まず、マスタシステム21Bでは、タイムサーバ10とネットワーク30を介して通信を行うことにより時刻同期のための情報を取得する(ステップS101)。次に、マスタシステム21Bでは、タイミング信号送出間隔設定部214が、タイミングジェネレータ25に対してアライメント値を設定するトリガとなるタイミング信号の送出間隔を設定する(ステップS102)。その後、マスタシステム21Bでは、同期信号送信部213が、スレーブシステム22Bに対して時刻情報を(ステップS103)、続いて時刻リセットやアライメント値等、アライメントに関する情報を送信する(ステップS104)。   First, in the master system 21B, information for time synchronization is acquired by communicating with the time server 10 via the network 30 (step S101). Next, in the master system 21B, the timing signal transmission interval setting unit 214 sets a transmission interval of timing signals serving as a trigger for setting an alignment value for the timing generator 25 (step S102). Thereafter, in the master system 21B, the synchronization signal transmission unit 213 transmits time information to the slave system 22B (step S103), and then transmits information related to alignment, such as time reset and alignment values (step S104).

これを受けたスレーブシステム22Bでは、時刻同期制御部222が、内部の時刻を同期信号送信部213によってマスタシステム21Bから通知された時刻に設定し、スレーブシステム22B自身で時刻をカウントしながら、タイミングジェネレータ25からのアライメントを起動するタイミング信号の到来を待つ(ステップS105)。そして、スレーブシステム22Bでは、時刻同期制御部222が、タイミングジェネレータ25からアライメントを起動するタイミング信号が到達したことを契機に、内部でカウントしていた時刻をリセットし、マスタシステム21Bの同期信号送信部213から指定された時刻に指定されたアライメント値にしたがいアライメントする(ステップS106)。   In the slave system 22B that receives this, the time synchronization control unit 222 sets the internal time to the time notified from the master system 21B by the synchronization signal transmission unit 213, and counts the time while the slave system 22B itself counts the time. Waiting for the arrival of a timing signal for starting alignment from the generator 25 (step S105). In the slave system 22B, the time synchronization control unit 222 resets the time counted internally when the timing signal for starting the alignment arrives from the timing generator 25, and transmits the synchronization signal of the master system 21B. Alignment is performed according to the specified alignment value at the time specified by the unit 213 (step S106).

なお、タイミング信号の送出間隔、時刻情報の設定、アライメント値の設定は、搭載するシステムの構成や特性により、その順番を入れ替え、あるいは一部を省略してもよい。また、本実施形態2に係るネットワーク機器20Bでは、タイミング信号の送出間隔はマスタシステム21B(タイミング信号送出間隔設定部214)が設定したが、スレーブシステム22Bが設定しても良く、予めタイミングジェネレータ25に設定されている値を使用してもよい。更に、タイミングジェネレータ25により生成される、リセットやアライメント値を設定する契機になるタイミング信号は、スレーブシステム22Bにのみ供給されているが、マスタシステム21Bにも供給することで、アライメント関連の値を決定する際に利用することも可能である。   Note that the timing signal transmission interval, time information setting, and alignment value setting may be switched in order or may be partially omitted depending on the configuration and characteristics of the installed system. In the network device 20B according to the second embodiment, the timing signal transmission interval is set by the master system 21B (timing signal transmission interval setting unit 214). However, the slave system 22B may set the timing signal transmission interval. The value set in may be used. Furthermore, the timing signal generated by the timing generator 25 that triggers the reset or alignment value is supplied only to the slave system 22B, but by supplying the timing signal to the master system 21B as well, alignment related values can be obtained. It can also be used when making decisions.

(実施形態2の応用例)
上記したタイミングジェネレータ25を使用して時刻同期を行うネットワーク機器20Bの具体的な実装例として、図6に示すISA(International Society of Automation)100ネットワークのバックボーンルータ100を例示して説明する。
(Application example of Embodiment 2)
As a specific implementation example of the network device 20B that performs time synchronization using the timing generator 25 described above, a backbone router 100 of an ISA (International Society of Automation) 100 network illustrated in FIG. 6 will be described as an example.

ここでは、バックボーンルータ100には、バックボーン側のネットワーク処理を行うバックボーンネットワークシステム(BNS101)と、無線側の処理を行う無線ネットワークシステム(WNS102)の2つのシステムが搭載され、それぞれが別のプロセッサで動作する。タイムサーバは、不図示のバックボーン側に存在し、BNS101がこのタイムサーバと時刻同期を行い、さらに同期した時刻をWNS102に通知する場合の動作について説明する。   Here, the backbone router 100 is equipped with two systems: a backbone network system (BNS101) that performs network processing on the backbone side, and a wireless network system (WNS102) that performs processing on the wireless side, each of which is a separate processor. Operate. The time server exists on the backbone side (not shown), and the operation when the BNS 101 performs time synchronization with this time server and further notifies the WNS 102 of the synchronized time will be described.

本応用例において、バックボーンルータに含まれるBNS101の時刻管理部110、およびWNS102の時刻管理部120は、それぞれにおいて搭載された時刻カウントクロック源130、140を使用して時刻情報を維持する。しかしながら一般的なシステムにおいて、この時刻カウントクロック源130、140は、アプリケーションの要求に対して十分な精度を持っていないことが多く、この場合、要求された精度で時間を刻み続けることができない。このため、各システム101、102が持つ時刻スウントクロック源130、140とは別に、アプリケーション要求を満たす精度を持った高精度クロック源103をバックボーンルータに搭載し、一定、あるいはBNS101が設定した間隔で各システム101、102に対してタイムティックを供給する。このタイムティック供給は、各システム101、102に対して同時に通知する(Tick供給)。   In this application example, the time management unit 110 of the BNS 101 and the time management unit 120 of the WNS 102 included in the backbone router maintain time information using the time count clock sources 130 and 140 mounted in each. However, in a general system, the time count clock sources 130 and 140 often do not have sufficient accuracy with respect to application requirements, and in this case, the time count clock sources 130 and 140 cannot keep time with the required accuracy. For this reason, apart from the time sound clock sources 130 and 140 possessed by the systems 101 and 102, a high-accuracy clock source 103 having an accuracy satisfying the application requirements is mounted on the backbone router, and the interval set by the BNS 101 is fixed. The time tick is supplied to each of the systems 101 and 102. This time tick supply is simultaneously notified to the systems 101 and 102 (tick supply).

タイムティックは、各システム101、102の時刻管理部110、120がそれぞれ持つ外部クロック割り込み管理部112、122のそれぞれに接続され、各システム191、102のプロセッサは、このティックのタイミングで内部の時刻保持部111、121が持つ時刻情報をアライメントする。例えば、タイムティックが1秒間隔で設定された場合、1秒ごとに時刻情報のアライメントが行われる。以下に、タイムティックが1秒間隔で供給され、1ミリ秒の精度でWNS102が時刻同期する場合の動作説明を行う。   The time tick is connected to each of the external clock interrupt management units 112 and 122 included in the time management units 110 and 120 of the systems 101 and 102, and the processors of the systems 191 and 102 have internal time at this tick timing. The time information held by the holding units 111 and 121 is aligned. For example, when time ticks are set at intervals of 1 second, time information is aligned every second. In the following, an operation will be described when time ticks are supplied at 1 second intervals and the WNS 102 synchronizes time with an accuracy of 1 millisecond.

タイムサーバと同期したBNS101は、同期した時刻情報を時刻管理部110の時刻保持部111にセットし、時刻カウントクロック源130から供給されるクロックを基にミリ秒精度で時刻を刻む。その後、高精度クロック源103からティックが入力されたタイミングで、時刻保持部111が持つ時刻情報をミリ秒単位でキャプチャする。ここでは、一般的にマイコンなどに搭載されているタイマキャプチャ機能を使ってハードウエア的に取得する。   The BNS 101 synchronized with the time server sets the synchronized time information in the time holding unit 111 of the time management unit 110 and records the time with millisecond accuracy based on the clock supplied from the time count clock source 130. Thereafter, the time information held by the time holding unit 111 is captured in milliseconds at the timing when the tick is input from the high-accuracy clock source 103. Here, it is obtained by hardware using a timer capture function generally installed in a microcomputer or the like.

次に、BNS101は、キャプチャした時刻情報のミリ秒単位の時刻を「オフセット情報」としてWNS102に通知する。例えば、BNS101側でティックをキャプチャした時刻が12:34:56.789であった場合、789msをオフセット情報としてWNS102に通知する。この動作の事前、あるいは事後に、別途秒単位の時刻情報、ここでは、12:34:56の情報を通知する必要がある。   Next, the BNS 101 notifies the WNS 102 of the time in milliseconds of the captured time information as “offset information”. For example, when the time when the tick is captured at the BNS 101 side is 12: 34: 56.789, the WNS 102 is notified of 789 ms as offset information. Before or after this operation, it is necessary to separately notify time information in units of seconds, here, 12:34:56 information.

この情報を受信したWNS102は、ティックを受信したタイミングで自身の時刻管理部120が持つ時刻情報のミリ秒単位の時間を789msにアライメントし直すことでBNS101とミリ秒単位で時刻同期を行うことができる。この動作は、図3(b)に示したタイムシーケンス図にしたがう。   The WNS 102 that has received this information can synchronize the time with the BNS 101 in milliseconds by realigning the time in milliseconds of the time information held by its time management unit 120 to 789 ms at the timing of receiving the tick. it can. This operation follows the time sequence diagram shown in FIG.

なお、上記の応用例では、時刻情報をミリ秒単位で同期させる例を説明したが、アプリケーションの要求と時刻管理機能で格納可能な時刻精度に応じた精度を同じ仕組みで実現することができる。また、ここでは2つのシステム(BNS101とWNS102)間の同期に関する時刻同期の方法について説明したが、高精度クロック源103からのティック信号供給先を増やすことで3システム以上の時刻同期についても同じ方法で実現可能である。   In the application example described above, the time information is synchronized in milliseconds. However, the accuracy according to the time accuracy that can be stored by the application request and the time management function can be realized by the same mechanism. Although the method of time synchronization related to synchronization between two systems (BNS 101 and WNS 102) has been described here, the same method can be used for time synchronization of three or more systems by increasing the tick signal supply destination from the high-precision clock source 103. It is feasible.

(実施形態2の効果)
以上説明のように本実施形態2に係るネットワーク機器20Bによれば、スレーブシステム22Bに対しマスタシステム21Bとは非同期に所定の間隔でタイミング信号を送信するタイミングジェネレータ25を備え、マスタシステム21Bが、時刻情報の他に、時刻情報の単位時刻以下の時刻をリセットする同期信号と、アライメント値を送信する。これを受けてスレーブシステム22Bが、内部で計時している時刻を受信した時刻情報に再設定して計時を再開し、タイミングジェネレータ25から所定の間隔で送信されるタイミング信号の到来を待って、受信したアライメント値を設定する。
(Effect of Embodiment 2)
As described above, the network device 20B according to the second embodiment includes the timing generator 25 that transmits a timing signal to the slave system 22B at a predetermined interval asynchronously with the master system 21B. In addition to the time information, a synchronization signal for resetting a time equal to or less than the unit time of the time information and an alignment value are transmitted. In response to this, the slave system 22B resets the internally timed time to the received time information, restarts timekeeping, and waits for the arrival of a timing signal transmitted from the timing generator 25 at a predetermined interval. Set the received alignment value.

このため、マスタシステム21Bが高い優先度の割り込みを処理中である等、アライメント信号の送信が待たされる場合であっても、タイミングジェネレータ25により、マスタシステム21Bの処理状況とは無関係に一定のタイミングでアライメント信号の送信が可能になるため、時刻同期を優先して処理することが可能なネットワーク機器20Bを提供することができる。   For this reason, even when the transmission of the alignment signal is awaited, for example, when the master system 21B is processing a high priority interrupt, the timing generator 25 causes the constant timing regardless of the processing status of the master system 21B. Thus, it is possible to provide the network device 20B capable of processing with priority given to time synchronization.

本発明は、実施形態1、2ともに、タイムサーバ10と直接時刻同期することのできないスレーブシステム22A(22B)を、マスタシステム21A(21B)を経由させて所望の精度で時刻同期させるものであり、このような時刻同期が必要とされるネットワークにおいて、例えば、上位ネットワークから時刻情報を受信した無線ネットワーク機器としてのアクセスポイントが、その情報を無線機器に配信するためにアクセスポイント内部のアーキテクチャを提供するものである。具体的に、アクセスポイントを構成するマスタシステムとスレーブシステム間の時刻同期にフォーカスしたものであり、タイムサーバ10の有無はと無関係である。但し、実際の応用においては、タイムサーバ10のような役割が必要とされるケースが多く、また存在しなくてもその機能がマスタシステム21A(21B)に含まれるような構成が考えられるため、本実施形態ではいずれもタイムサーバ10の存在を示した。   In the first and second embodiments, the slave system 22A (22B) that cannot be directly synchronized with the time server 10 is time-synchronized with a desired accuracy via the master system 21A (21B). In such a network where time synchronization is required, for example, an access point as a wireless network device that has received time information from an upper network provides an internal architecture of the access point for distributing the information to the wireless device. To do. Specifically, the focus is on time synchronization between a master system and a slave system constituting the access point, and the presence or absence of the time server 10 is irrelevant. However, in actual applications, there are many cases where a role such as the time server 10 is required, and a configuration in which the function is included in the master system 21A (21B) even if it does not exist is conceivable. In the present embodiment, the existence of the time server 10 is shown in all cases.

なお、本実施形態に係るネットワーク機器20A、20Bは、TDMA方式にしたがい通信を行うシステム全般への適用が可能である。例えば、ネットワーク上に配置された時刻リファレンスに各通信ノードを同期させて通信させるようなシステムに同様な方法で応用することができる。   The network devices 20A and 20B according to the present embodiment can be applied to all systems that perform communication in accordance with the TDMA method. For example, the present invention can be applied in a similar manner to a system in which each communication node is synchronized and communicated with a time reference arranged on a network.

(ネットワーク機器における時刻同期方法)
なお、本発明の実施形態1に係るネットワーク機器における時刻同期方法は、例えば、図1において、時刻情報配信元と通信を行って時刻情報を取得するマスタシステム21Aと、前記マスタシステム21Aから時刻情報の提供を受けて時刻同期を行なうスレーブシステム22Aとからなるネットワーク機器20Aにおける時刻同期方法である。そして、前記マスタシステム21Aが、前記スレーブシステム22Aに対し、前記マスタシステム21Aと前記スレーブシステム22Aとを接続する通信パス23を介して前記通信の遅延による影響が無視できる単位時刻の精度で前記時刻情報を通知するステップ(S12)と、前記マスタシステム21Aが、前記時刻情報を通知した後、前記通知した時刻に、前記マスタシステム21Aと前記スレーブシステム22Aとを接続する前記通信パス23とは独立して設けられる送信パス24を介して前記単位時刻以下の時刻情報を定期的にリセットするステップ(S13)と、前記スレーブシステム22Aが、前記同期信号を受信した時点で、内部で計時している時刻を前記通知された時刻情報に設定し直して計時を再開するステップと、を有するものである。
(Time synchronization method for network devices)
The time synchronization method in the network device according to the first embodiment of the present invention includes, for example, a master system 21A that acquires time information by communicating with a time information distribution source in FIG. 1, and time information from the master system 21A. Is a time synchronization method in the network device 20A including the slave system 22A that performs time synchronization in response to the provision of. Then, the master system 21A has the unit time accuracy with respect to the slave system 22A with negligible influence of the communication delay through the communication path 23 connecting the master system 21A and the slave system 22A. Informing the information (S12), and after the master system 21A notifies the time information, it is independent of the communication path 23 connecting the master system 21A and the slave system 22A at the notified time. Step (S13) of periodically resetting the time information below the unit time via the transmission path 24 provided, and when the slave system 22A receives the synchronization signal, the time is internally measured. Resetting the time to the notified time information and restarting the timing. Is shall.

本実施形態1に係るネットワーク機器における時刻同期方法によれば、マスタシステム21Aでは、通信パス23を介して時刻情報を通知した後、通知した時刻に通信パス23とは独立して設けられる送信パス24を介して単位時刻以下の時刻情報をリセットする同期信号を定期的に送信し、スレーブシステム22Aでは、同期信号を受信した時点で、内部で計時している時刻を通知された時刻情報に設定し直して計時を再開する。このため、マスタシステム21Aとスレーブシステム22A間の時刻情報通知のための遅延に起因する時刻同期のずれを回避することが出来、同期信号により、マスタシステム21Aやスレーブシステム22Aの処理状況、あるいはマスタシステム21Aとスレーブシステム22Aとの間の通信状況に依存しない同期信号のやりとりが可能になる。   According to the time synchronization method in the network device according to the first embodiment, in the master system 21A, after notifying the time information via the communication path 23, the transmission path provided independently of the communication path 23 at the notified time. 24, a synchronization signal for resetting time information below the unit time is periodically transmitted, and the slave system 22A sets the internally timed time to the notified time information when the synchronization signal is received. Then restart timing. For this reason, it is possible to avoid a time synchronization shift caused by a delay for notifying the time information between the master system 21A and the slave system 22A, and the processing status of the master system 21A and the slave system 22A or the master by the synchronization signal. Synchronization signals can be exchanged without depending on the communication status between the system 21A and the slave system 22A.

また、本実施形態2に係るネットワーク機器における時刻同期方法は、例えば、図4において、時刻情報配信元と通信を行って時刻情報を取得するマスタシステム21Bと、前記マスタシステム21Bから時刻情報の提供を受けて時刻同期を行なうスレーブシステム22Bと、前記スレーブシステム22Bに、前記マスタシステム21Bとは非同期に所定の間隔でタイミング信号を送信するタイミングジェネレータ25と、を備えたネットワーク機器20Bにおける時刻同期方法である。そして、例えば、図5において、前記マスタシステム21Bが、前記スレーブシステム22Bに対し、前記時刻情報の他に、前記時刻情報の単位時刻以下の時刻をリセットする同期信号と、前記単位時刻以下のアライメント値を示すアライメント信号とを送信するステップ(S103、S104)と、前記スレーブシステム22Bが、前記マスタシステム21Bから前記同期信号を受信すると、内部で計時している時刻を前記マスタシステム21Aから送信される時刻情報に再設定して計時を再開するステップ(S105)と、前記スレーブシステム22Bが、前記タイミングジェネレータ25から送信される前記タイミング信号の到来を待って、前記内部で計時している時刻を前記マスタシステム21Bから受信した前記アライメント信号が示すアライメント値に設定するステップ(S106)と、を有するものである。   In addition, the time synchronization method in the network device according to the second embodiment includes, for example, a master system 21B that obtains time information by communicating with a time information distribution source in FIG. 4, and provides time information from the master system 21B. Time synchronization method in a network device 20B comprising: a slave system 22B that performs time synchronization in response to the reception, and a timing generator 25 that transmits a timing signal to the slave system 22B at a predetermined interval asynchronously with the master system 21B. It is. For example, in FIG. 5, the master system 21B, with respect to the slave system 22B, in addition to the time information, a synchronization signal that resets a time that is less than the unit time of the time information, and an alignment that is less than the unit time. A step of transmitting an alignment signal indicating a value (S103, S104), and when the slave system 22B receives the synchronization signal from the master system 21B, the time measured internally is transmitted from the master system 21A. Resetting the time information to the time information and restarting the time measurement (S105), the slave system 22B waits for the arrival of the timing signal transmitted from the timing generator 25, and sets the time measured internally. The alignment signal received from the master system 21B A step (S106) for setting the alignment values shown, and has a.

本実施形態2に係るネットワーク機器における時刻同期方法によれば、マスタシステム21Bが、時刻情報の他に、時刻情報の単位時刻以下の時刻をリセットする同期信号と、アライメント値を送信し、これを受けたスレーブシステム22Bが、内部で計時している時刻を受信した時刻情報に再設定して計時を再開し、タイミングジェネレータ25から所定の間隔で送信されるタイミング信号の到来を待ってマスタシステム21Bから受信したアライメント値を設定する。このため、マスタシステム21Bが高優先度の割り込みを処理中である等、アライメント信号の送信が待たされる場合であっても、タイミングジェネレータ25によりマスタシステム21Aの処理状況とは無関係に一定のタイミングでアライメント関連の信号の送信が可能になるため、時刻同期を優先して処理することが可能になる。   According to the time synchronization method in the network device according to the second embodiment, the master system 21B transmits, in addition to the time information, a synchronization signal that resets a time equal to or less than the unit time of the time information and an alignment value. The received slave system 22B resets the internally timed time to the received time information and restarts the timekeeping. The master system 21B waits for the arrival of a timing signal transmitted from the timing generator 25 at a predetermined interval. Set the alignment value received from. For this reason, even when the transmission of the alignment signal is awaited, such as when the master system 21B is processing a high-priority interrupt, the timing generator 25 does not depend on the processing status of the master system 21A at a constant timing. Since alignment-related signals can be transmitted, time synchronization can be prioritized for processing.

以上説明のように本発明のネットワーク機器および同機器を用いた時刻同期方法によれば、マスタシステムとスレーブシステムとの間の通信遅延や通信状況に依存することなく定期的な時刻同期を可能にする。本発明によれば、軽微なハードウエアの改変と、対応するソフトウエアの実装のみで実現できるため、従来の方法を採用するネットワーク機器の多くに適用が可能である。またハードウエアの実装コストは、従来の方法とほとんど変わることがない。   As described above, according to the network device and the time synchronization method using the device of the present invention, it is possible to perform periodic time synchronization without depending on the communication delay and communication status between the master system and the slave system. To do. According to the present invention, since it can be realized only by minor hardware modification and corresponding software implementation, it can be applied to many network devices adopting the conventional method. The hardware implementation cost is almost the same as the conventional method.

以上、本実施形態について説明したが、本発明の技術的範囲は上記実施形態に記載の範囲には限定されないことは言うまでもない。上記実施形態に、多様な変更又は改良を加えることが可能であることが当業者に明らかである。またそのような変更又は改良を加えた形態も本発明の技術的範囲に含まれ得ることが、特許請求の範囲の記載から明らかである。   As mentioned above, although this embodiment was described, it cannot be overemphasized that the technical scope of this invention is not limited to the range as described in the said embodiment. It will be apparent to those skilled in the art that various modifications or improvements can be added to the above embodiment. Further, it is apparent from the scope of the claims that the embodiments added with such changes or improvements can be included in the technical scope of the present invention.

10・・タイムサーバ、20A(20B)・・ネットワーク機器、21A(21B)・・マスタシステム、22A(22B)・・スレーブシステム、23・・通信パス、24・・送信パス、25・・タイミングジェネレータ、30・・ネットワーク、100・・バックボーンルータ、101・・バックボーンネットワークシステム(BNS)、102・・無線ネットワークシステム(WNS)、103高精度クロック源、110、120・・時刻管理部、111、121・・時刻保持部、112、122・・外部クロック割り込み管理部、130、140・・時刻カウントクロック源、211・・時刻情報送信部、212、213・・同期信号送信部、214・・タイミング信号送出間隔設定部、221、222・・時刻同期制御部   10. Time server, 20A (20B) Network equipment, 21A (21B) Master system, 22A (22B) Slave system, 23 Communication path, 24 Transmission path, 25 Timing generator , 30 ··· network, 100 ··· backbone router, 101 ··· backbone network system (BNS), 102 ··· wireless network system (WNS), 103 high precision clock source, 110, 120 ··· time management unit, 111, 121 ..Time holding unit, 112, 122 ..External clock interrupt management unit, 130, 140 ..Time count clock source, 211 ..Time information transmission unit, 212, 213 ..Synchronous signal transmission unit, 214. Sending interval setting unit, 221, 222 ..Time synchronization control unit

Claims (7)

時刻情報配信元と通信を行って時刻情報を取得するマスタシステムと、前記マスタシステムから時刻情報の提供を受けて時刻同期を行なうスレーブシステムとからなるネットワーク機器であって、
前記マスタシステムと前記スレーブシステムとの間で通信を行なう通信パスとは別に、前記マスタシステムから前記スレーブシステムに対して同期信号を送信する送信パスを設け、
前記マスタシステムは、前記スレーブシステムに対し、前記通信パスを介して予め定められた単位時刻の精度で前記時刻情報を通知する時刻情報送信部と、前記時刻情報を通知した後、前記通知した時刻に前記送信パスを介して前記単位時刻以下の時刻情報をリセットする前記同期信号を送信する同期信号送信部と、を備え、
前記スレーブシステムは、
前記同期信号を受信した時点で、内部で計時している時刻を前記通知された時刻情報に設定し直して計時を再開する時刻同期制御部、を備え、前記時刻同期制御部にて、前記マスタシステムの時刻に比べ前記スレーブシステムの時刻に遅れが生じている場合は前記単位時刻以下の時刻情報の切り上げ処理を行い、前記マスタシステムに比べ前記スレーブシステムの時刻に進みが生じている場合は前記単位時刻以下の時刻情報の切り下げ処理を行なうことを特徴とするネットワーク機器。
A network device composed of a master system that communicates with a time information distribution source to acquire time information, and a slave system that receives time information from the master system and performs time synchronization,
Apart from a communication path for performing communication between the master system and the slave system, a transmission path for transmitting a synchronization signal from the master system to the slave system is provided,
The master system notifies the slave system of the time information with a unit time accuracy determined in advance via the communication path, and notifies the time after the time information is notified. A synchronization signal transmitting unit that transmits the synchronization signal that resets time information equal to or less than the unit time via the transmission path, and
The slave system is
A time synchronization control unit that resets the time measured internally to the notified time information when the synchronization signal is received, and restarts the time measurement. When there is a delay in the time of the slave system compared to the time of the system, the time information below the unit time is rounded up, and when the advance of the time of the slave system occurs compared to the master system A network device characterized by performing a round-down process for time information below a unit time .
前記単位時刻の精度は、
前記通信の遅延による影響を無視できることを特徴とする請求項1記載のネットワーク機器。
The accuracy of the unit time is
2. The network device according to claim 1, wherein the influence of the communication delay can be ignored.
前記マスタシステムは、
前記同期信号送信部にて、前記送信パスを介して次の同期信号を送信した後、前記スレーブシステムに設定すべき前記単位時刻以下のアライメント値を示すアライメント信号を送信し、
前記スレーブシステムは、
前記時刻同期制御部にて前記アライメント信号を受信すると、内部で計時している時刻をリセットし、前記アライメント値に再設定して計時を再開することを特徴とする請求項1記載のネットワーク機器。
The master system is
In the synchronization signal transmission unit, after transmitting the next synchronization signal through the transmission path, transmits an alignment signal indicating an alignment value of the unit time or less to be set in the slave system,
The slave system is
2. The network device according to claim 1, wherein when the alignment signal is received by the time synchronization control unit, the time currently measured internally is reset, reset to the alignment value, and time measurement is resumed.
時刻情報配信元と通信を行って時刻情報を取得するマスタシステムと、前記マスタシステムから時刻情報の提供を受けて時刻同期を行なうスレーブシステムとからなるネットワーク機器であって、
前記スレーブシステムに対し、前記マスタシステムとは非同期に所定の間隔でタイミング信号を送信するタイミングジェネレータを備え、
前記マスタシステムは、前記スレーブシステムに対し、前記時刻情報の他に、前記時刻情報の単位時刻以下の時刻をリセットする同期信号、または前記単位時刻以下のアライメント値を示すアライメント信号を送信する同期情報送信部を備え、
前記スレーブシステムは、前記マスタシステムから前記同期信号を受信すると、内部で計時している時刻を前記マスタシステムから通知される時刻情報に再設定して計時を再開し、前記タイミングジェネレータから送信される前記タイミング信号の到来を待って、前記内部で計時している時刻を、前記マスタシステムから受信した前記アライメント信号が示すアライメント値に設定する時刻同期制御部、を備えることを特徴とするネットワーク機器。
A network device composed of a master system that communicates with a time information distribution source to acquire time information, and a slave system that receives time information from the master system and performs time synchronization,
A timing generator that transmits a timing signal at a predetermined interval asynchronously with the master system to the slave system,
The master system transmits to the slave system, in addition to the time information, a synchronization signal that resets a time that is less than or equal to the unit time of the time information, or synchronization information that indicates an alignment value that is less than or equal to the unit time. With a transmitter,
When the slave system receives the synchronization signal from the master system, the slave system resets the time measured internally to the time information notified from the master system, and restarts the time measurement, and is transmitted from the timing generator. A network device comprising: a time synchronization control unit that waits for the arrival of the timing signal and sets the time measured internally to an alignment value indicated by the alignment signal received from the master system.
前記マスタシステムは、
前記スレーブシステムに前記時刻情報を送信する前に、前記タイミングジェネレータに対し、前記タイミング信号の送出間隔を設定することを特徴とする請求項記載のネットワーク機器。
The master system is
5. The network device according to claim 4 , wherein a transmission interval of the timing signal is set for the timing generator before transmitting the time information to the slave system.
時刻情報配信元と通信を行って時刻情報を取得するマスタシステムと、前記マスタシステムから時刻情報の提供を受けて時刻同期を行なうスレーブシステムとからなるネットワーク機器における時刻同期方法であって、
前記マスタシステムが、
前記スレーブシステムに対し、前記マスタシステムと前記スレーブシステムとを接続する通信パスを介して前記通信の遅延による影響が無視できる単位時刻の精度で前記時刻情報を通知するステップと、
前記マスタシステムが、
前記時刻情報を通知した後、前記通知した時刻に、前記マスタシステムと前記スレーブシステムとを接続する前記通信パスとは独立して設けられる送信パスを介して前記単位時刻以下の時刻情報をリセットするステップと、
前記スレーブシステムが、
同期信号を受信した時点で、内部で計時している時刻を前記通知された時刻情報に設定し直して計時を再開するステップと、
を有することを特徴とするネットワーク機器における時刻同期方法。
A time synchronization method in a network device comprising a master system that communicates with a time information distribution source to acquire time information and a slave system that receives time information from the master system and performs time synchronization,
The master system is
Notifying the slave system of the time information with a unit time accuracy that can ignore the influence of the communication delay through a communication path connecting the master system and the slave system;
The master system is
After notifying the time information, the time information equal to or less than the unit time is reset at the notified time via a transmission path provided independently of the communication path connecting the master system and the slave system. Steps,
The slave system is
When the synchronization signal is received, the step of resetting the time internally measured to the notified time information and restarting the time measurement,
A time synchronization method in a network device, comprising:
時刻情報配信元と通信を行って時刻情報を取得するマスタシステムと、前記マスタシステムから時刻情報の提供を受けて時刻同期を行なうスレーブシステムと、前記スレーブシステムに、前記マスタシステムとは非同期に所定の間隔でタイミング信号を送信するタイミングジェネレータと、を備えたネットワーク機器における時刻同期方法であって、
前記マスタシステムが、
前記スレーブシステムに対し、前記時刻情報の他に、前記時刻情報の単位時刻以下の時刻をリセットする同期信号と、前記単位時刻以下のアライメント値を示すアライメント信号とを送信するステップと、
前記スレーブシステムが、
前記マスタシステムから前記同期信号を受信すると、内部で計時している時刻を前記マスタシステムから送信される時刻情報に再設定して計時を再開するステップと、
前記スレーブシステムが、
前記タイミングジェネレータから送信される前記タイミング信号の到来を待って、前記内部で計時している時刻を前記マスタシステムから受信した前記アライメント信号が示すアライメント値に設定するステップと、
を有することを特徴とするネットワーク機器における時刻同期方法。
A master system that communicates with a time information distribution source to acquire time information, a slave system that receives time information from the master system and performs time synchronization, and the slave system is asynchronous with the master system. A timing generator for transmitting a timing signal at intervals of a time synchronization method in a network device comprising:
The master system is
To the slave system, in addition to the time information, transmitting a synchronization signal for resetting a time equal to or less than the unit time of the time information, and an alignment signal indicating an alignment value equal to or less than the unit time;
The slave system is
When receiving the synchronization signal from the master system, resetting the time that is internally timed to time information transmitted from the master system,
The slave system is
Waiting for the arrival of the timing signal transmitted from the timing generator, and setting the time measured internally to an alignment value indicated by the alignment signal received from the master system;
A time synchronization method in a network device, comprising:
JP2011078741A 2011-03-31 2011-03-31 Network device and time synchronization method in the same device Active JP5626589B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2011078741A JP5626589B2 (en) 2011-03-31 2011-03-31 Network device and time synchronization method in the same device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2011078741A JP5626589B2 (en) 2011-03-31 2011-03-31 Network device and time synchronization method in the same device

Publications (2)

Publication Number Publication Date
JP2012211881A JP2012211881A (en) 2012-11-01
JP5626589B2 true JP5626589B2 (en) 2014-11-19

Family

ID=47265948

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2011078741A Active JP5626589B2 (en) 2011-03-31 2011-03-31 Network device and time synchronization method in the same device

Country Status (1)

Country Link
JP (1) JP5626589B2 (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104981742B (en) 2013-06-12 2017-09-19 富士电机株式会社 Dispensing device, dissemination system and distribution method
JP6907088B2 (en) * 2017-09-29 2021-07-21 三菱重工業株式会社 Synchronous communication network system, separation node, mother unit node and communication control method
JP7248044B2 (en) 2021-02-26 2023-03-29 株式会社安川電機 CONTROLLER, EQUIPMENT CONTROL SYSTEM, TIME SYNCHRONIZATION METHOD, AND TIME SYNCHRONIZATION PROGRAM

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS6378697A (en) * 1986-09-22 1988-04-08 Mitsubishi Electric Corp Remote supervisory and controlling equipment
JPH04277953A (en) * 1991-03-05 1992-10-02 Toshiba Corp Time synchronizer for lan
JPH05134062A (en) * 1991-11-11 1993-05-28 Toshiba Corp Time synchronizing method for process monitoring apparatus
JPH11295454A (en) * 1998-04-07 1999-10-29 Kokusai Electric Co Ltd Time synchronous control method and device
JP2001221874A (en) * 2000-02-14 2001-08-17 Toshiba Corp Time synchronization system
JP4123946B2 (en) * 2003-01-28 2008-07-23 株式会社デンソー Time synchronization system
JP4267967B2 (en) * 2003-05-14 2009-05-27 株式会社リコー Time setting method and time setting device
US20110222561A1 (en) * 2010-03-11 2011-09-15 General Electric Company Systems and methods for providing time synchronization

Also Published As

Publication number Publication date
JP2012211881A (en) 2012-11-01

Similar Documents

Publication Publication Date Title
EP1717978B1 (en) Time synchronization, deterministic data delivery and redundancy for cascaded nodes on full duplex ethernet networks
EP2801162B1 (en) Method and apparatus for communicating time information between time-aware devices
US10158444B1 (en) Event-driven precision time transfer
EP1525693B1 (en) Clock synchronizing method over fault-tolerant etherent
CN109565435B (en) System and method for network synchronization
KR101426325B1 (en) Network element for a packet-switched network
US8576883B2 (en) Measurement and adjustment of real-time values according to residence time in networking equipment without access to real time
EP2817902B1 (en) Method and network node for processing a precision time protocol
CN101447861B (en) IEEE 1588 time synchronization system and implementation method thereof
JP5328076B2 (en) Method and control system for synchronizing sub-units in time, and sub-unit capable of time synchronization
KR101636496B1 (en) Signal synchronization system, node synchronization system, signal synchronization method, and node synchronization method
CN106899370A (en) A kind of clock chain circuit changing method, device and base station
WO2011134371A1 (en) Method for synchronizing clocks and clock synchronization device
JP2014093540A (en) Communication device and synchronization method
JP5626589B2 (en) Network device and time synchronization method in the same device
WO2015125439A1 (en) Communication system, wireless communication apparatus, and wireless communication method
JP2005159754A (en) Transmission timing determining method, bus usage right arbitrating method, network system and program
CN114629586A (en) Network port PTP time service function extension device and extension method
US11831403B2 (en) Network interface card structure and clock synchronization method to precisely acquire heterogeneous PTP synchronization information for PTP synchronization network extension
JP7118324B1 (en) Transfer device and time synchronization system
CN105491433B (en) Audio video synchronization display methods and device and splice displaying system based on 1588V2 agreement
Luckinger et al. AUTOSAR-compliant clock synchronization over CAN using software timestamping
JP7008894B1 (en) Time synchronization dependent device, time sharing system, time sharing method and program
EP3814868B1 (en) Precision timing between systems
JP6528847B2 (en) Control network system, its node device

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20140106

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20140702

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20140708

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20140819

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20140904

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20140917

R150 Certificate of patent or registration of utility model

Ref document number: 5626589

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250