Time synchronization device, time synchronization system, time synchronization method and recording medium

By designing a time synchronization device that follows the PTP protocol of IEEE 1588 specification and prohibiting time correction within a specific period, the problem of different time synchronization accuracy of different switching devices is solved, and lower time error and higher time synchronization accuracy are achieved.

CN115735351BActive Publication Date: 2025-05-09MITSUBISHI ELECTRIC CORP
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202080102456.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-07-01
Publication Date
2025-05-09
Estimated Expiration
2040-07-01

AI Technical Summary

Technical Problem

When switching devices of different manufacturers and specifications are used for time synchronization, the accuracy of time synchronization may be different, resulting in a larger error between the corrected time and the reference time.

Method used

A time synchronization device is designed. When connected to the time storage device, the device follows the PTP protocol of IEEE 1588 specification and performs time synchronization with other unconnected time synchronization devices. The device includes a synchronization information sending unit, a request information receiving unit, a response information sending unit, and a time correction unit to correct the time by calculating the transmission delay time.

Benefits of technology

By prohibiting time correction within a specific period, the transmission delay time error between the time synchronization devices is reduced, thereby reducing the time error and improving the accuracy of time synchronization.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115735351B_ABST
    Figure CN115735351B_ABST
Patent Text Reader

Abstract

A first slave device (300) is connected between a host device (200) storing a reference time and a second slave device (400), and synchronizes the time with the host device (200) together with the second slave device (400) in accordance with PTP. A first synchronization information sending unit (332) sends a Sync message and a Follow_Up message to the second slave device (400), a first request information receiving unit (313) receives a Delay_Req message from the second slave device (400), and a first response information sending unit (333) sends a Delay_Resp message to the second slave device (400). A first time correction unit (320) corrects the time based on a transmission delay time with the host device (200) calculated from a time determined when information is sent and received with the host device (200) during a period different from a period from when the Sync message is sent to when the Delay_Req message is received.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to a time synchronization device, a time synchronization system, a time synchronization method and a program. Background Art

[0002] The time synchronization system that synchronizes the time of devices in the network is used in various industries such as the financial industry, manufacturing industry, and communication industry. In addition, in such a time synchronization system, it is known to use PTP (Precision Time Protocol) specified by IEEE (Institute of Electrical and Electronics Engineers) 1588. PTP is a specification for the time synchronization of a slave that receives a message sent by a master clock (GMC, Gland Master Clock), i.e., a so-called master, with a master. In PTP, a device with high-precision time in the network acts as a master, and devices other than the master act as slaves. In addition, in PTP, if the network is large-scale, a slave acts as a boundary clock (BC, Boundary Clock), and the boundary clock relays the message received from the master to other connected slaves.

[0003] As an example of a time synchronization system using such PTP, Patent Document 1 discloses a wireless communication system having a baseband unit provided in a wireless base station, a data packet forwarding network including a plurality of switch devices, and a host which is a reference time supply source for the data packet forwarding network. In Patent Document 1, the switch device functions as a boundary clock, and the reference time is supplied from the host to the baseband unit via 8 switch devices. In addition, in Patent Document 1, the allowable amount of the time error in the baseband unit is calculated based on a predetermined upper limit value of the time error relative to the reference time of the host, the number of switch devices passing from the host, and the time error of each switch device on the path. In addition, Patent Document 1 illustrates a case where the time error of each switch device on the path is 50ns and is the same.

[0004] Patent Document 1: Japanese Patent Application Publication No. 2018-088646 Summary of the invention

[0005] In the wireless communication system described in Patent Document 1, it is considered that the accuracy of time synchronization is the same by using the same switch device. However, in a time synchronization system using the Internet, for example, each switch device has a different owner, and the manufacturer, specifications, etc. of the switch device are different, so the accuracy of time synchronization may also be different. In the case of using multiple switch devices with different accuracy of time synchronization, it is highly likely that the timing of time synchronization is set for each switch device. When the timing of time synchronization is set for each switch device, there is a possibility that the error between the corrected time and the reference time becomes larger even if the switch device and the baseband unit correct the time. For example, in the case where the second switch device sends and receives a message from the first switch device, so that the second switch device corrects the time, when the timing of time synchronization is set for each switch device, when the second switch device and the first switch device send and receive a message, the first switch device may correct the time. In this case, the message received by the second switch device sometimes includes information related to the time before correction of the first switch device and information related to the time after correction. If the second switch device corrects the time based on this information, there is a problem that the error between the corrected time and the reference time becomes larger.

[0006] The present invention has been made in view of the above-mentioned situation, and an object of the present invention is to reduce the error in time.

[0007] In order to achieve the above-mentioned purpose, the time synchronization device of the present invention is connected to a time storage device for storing time, and performs time synchronization with other time synchronization devices that are not connected to the time storage device in accordance with the PTP (Precision Time Protocol) of the IEEE (Institute of Electrical and Electronics Engineers) 1588 specification. The time synchronization device has a synchronization information sending unit, a request information receiving unit, a response information sending unit, and a time correction unit. The synchronization information sending unit sends synchronization information related to time synchronization to other time synchronization devices. After the synchronization information sending unit sends the synchronization information, the request information receiving unit receives the request information sent from other time synchronization devices. The response information sending unit sends the response information corresponding to the request information received by the request information receiving unit to other time synchronization devices. The time correction unit corrects the time based on the transmission delay time between the time storage device and the time storage device during a period different from the period from the time when the synchronization information sending unit sends the synchronization information to the time when the request information receiving unit receives the request information. The transmission delay time between the time storage device and the time storage device is calculated based on the time determined when sending and receiving information between the time storage device and the time storage device.

[0008] Effects of the Invention

[0009] According to the present invention, the time synchronization device does not correct the time during the period from when the synchronization information is sent to the other time synchronization device to when the request information is received from the other time synchronization device. Therefore, even if the time synchronization device and the other time synchronization device each set the timing of the time synchronization, in the other time synchronization device, it is possible to prevent the transmission delay time calculated during this period from causing an error. Therefore, compared with the time synchronization device that corrects the time during the period from when the synchronization information is sent to the other time synchronization device to when the request information is received from the other time synchronization device, the error of the time of the other time synchronization device can be reduced. BRIEF DESCRIPTION OF THE DRAWINGS

[0010] Figure 1 It is an overall explanatory diagram of a time synchronization system according to an embodiment of the present invention.

[0011] Figure 2 It is a diagram showing the functional configuration of the time synchronization system according to the present embodiment.

[0012] Figure 3 This is a block diagram showing the hardware configuration of the first slave device and the second slave device according to the present embodiment.

[0013] Figure 4 This is a flowchart showing the flow of the first time synchronization process according to the present embodiment.

[0014] Figure 5 This is a flowchart showing the flow of the second time synchronization process according to the present embodiment.

[0015] Figure 6 This is a sequence diagram showing an example of message transmission and reception in the time synchronization system according to the present embodiment.

[0016] Figure 7 This is a sequence diagram showing an example of message transmission and reception in a conventional time synchronization system.

[0017] Figure 8 This is a diagram showing an example of changes in time errors in a conventional time synchronization system.

[0018] Fig. 9 This is a diagram showing an example of changes in the time error in the time synchronization system according to the present embodiment.

[0019] Fig.10 This is a sequence diagram showing an example of message transmission and reception in the time synchronization system according to a modification example of the present embodiment. DETAILED DESCRIPTION

[0020] Hereinafter, a time synchronization device, a time synchronization system, a time synchronization method and a program according to an embodiment of the present invention will be described in detail with reference to the accompanying drawings. In addition, the same reference numerals are given to the same or corresponding parts in the drawings.

[0021] The time synchronization system according to the embodiment of the present invention is a system that synchronizes the time of a slave device connected to a master device with the time of the master device in accordance with PTP, the master device is an example of a time storage device, and the slave device is an example of a time synchronization device. In addition, in the time synchronization system that synchronizes the time in accordance with PTP, a message as an example of time information is sent and received between the master device and the slave device, and the slave device calculates the transmission delay time of the message between the master device and the slave device to correct the time.

[0022] Specifically, first, the master device sequentially sends a Sync message (Sync Message) and a Follow_Up message (Follow Up Message) as an example of synchronization information related to time synchronization to the slave device. In addition, the Follow_Up message contains information that can identify the first time T1 when the Sync message is sent. Then, after the slave device receives the Sync message and identifies the second time T2 received, it receives the Follow_Up message and identifies the first time T1. Then, the slave device identifies the third time T3, which is the time when the Delay_Req message (Delay Request Message) as an example of request information is sent to the master device, and the request information requests information used to calculate the transmission delay time based on the synchronization information. Then, after the master device receives the Delay_Req message and identifies the fourth time T4 received, it sends a Delay_Resp message (Delay Response message) as an example of response information to the request information to the slave device. In addition, the Delay_Resp message includes information that can identify the fourth time T4, which is the time when the Delay_Req message is received. Next, the slave device receives the Delay_Resp message and identifies the fourth time T4. Then, the slave device calculates the transmission delay time based on the determined first time T1, second time T2, third time T3, and fourth time T4, and corrects the time. In addition, when the transmission delay time is set to d and the correction amount of the time is set to tc, the transmission delay time d is calculated using the mathematical formula shown in the following (1), and the correction amount of the time tc is calculated using the mathematical formula shown in the following (2).

[0023] d = {(T4-T1)-(T3-T2)} / 2…(1)

[0024] tc=T1+d…(2)

[0025] Therefore, in the time synchronization system according to the present embodiment described below, messages are similarly transmitted and received between the master device and the slave device, and the slave device calculates the transmission delay time of the message with the master device to correct the time.

[0026] Figure 1 It is an overall explanatory diagram of a time synchronization system according to an embodiment of the present invention.

[0027] like Figure 1 As shown, the time synchronization system 100 according to the present embodiment includes a host device 200 as an example of a time storage device. In addition, the time synchronization system 100 includes a first slave device 300 as an example of a first time synchronization device, and the first slave device 300 is an example of a time synchronization device connected to the host device 200. In addition, the time synchronization system 100 includes a second slave device 400 as an example of a second time synchronization device, and the second slave device 400 is an example of another time synchronization device that is not connected to the host device 200 but connected to the first slave device 300.

[0028] The host device 200, the first slave device 300, and the second slave device 400 can transmit and receive data via a LAN (Local Area Network). Specifically, the host device 200 has a master port 201, the first slave device 300 has a slave port 301 and a master port 302, and the second slave device 400 has a slave port 401 and a master port 402. Moreover, the host device 200 is connected to the slave port 301 of the first slave device 300 via the LAN through the master port 201, and can transmit and receive data related to time synchronization with the first slave device 300. In addition, the first slave device 300 is also connected to the slave port 401 of the second slave device 400 via the LAN through the master port 302, similarly to the host device 200, and can transmit and receive data with the second slave device 400.

[0029] The host device 200 is, for example, a computer that functions as a host in PTP, and stores the highest quality clock as a reference time in the time synchronization system 100. In addition, as long as the reference time is stored in PTP, the host device 200 is not limited to the host, and for example, it can also be a computer that functions as a boundary clock with no error with the reference time of the host. Specifically, first, the host device 200 sends a Sync message and a Follow_Up message to the first slave device 300 in sequence. Then, after receiving the Delay_Req message from the first slave device 300, the host device 200 sends a Delay_Resp message to the first slave device 300.

[0030] Figure 2 It is a diagram showing the functional configuration of the time synchronization system according to the present embodiment.

[0031] The first slave device 300 and the second slave device 400 are, for example, computers that function as boundary clocks in PTP. Figure 2 As shown, the first slave device 300 includes a first time information receiving unit 310 as an example of a time information receiving unit that receives time information based on the reference time transmitted from the master device 200. In addition, the first slave device 300 includes a first time correction unit 320 as an example of a time adjustment unit that corrects the time, and a first time information sending unit 330 as an example of a time information sending unit that sends the time information to the second slave device 400.

[0032] The first time information receiving unit 310 includes a first synchronization information receiving unit 311 as an example of a synchronization information receiving unit that receives synchronization information sent from the host device 200, and a first response information receiving unit 312 as an example of a response information receiving unit that receives response information sent from the host device 200. In addition, the first time information receiving unit 310 includes a first request information receiving unit 313 as an example of a request information receiving unit that receives request information sent from the second slave device 400.

[0033] The first time information sending unit 330 includes a first request information sending unit 331 as an example of a request information sending unit that sends request information to the master device 200. In addition, the first time information sending unit 330 includes a first synchronization information sending unit 332 as an example of a synchronization information sending unit that sends synchronization information to the second slave device 400, and a first response information sending unit 333 as an example of a response information sending unit that sends response information to the second slave device 400.

[0034] Specifically, the first synchronization information receiving unit 311 receives the Sync message and the Follow_Up message sent from the host device 200. In addition, the first request information sending unit 331 sends the Delay_Req message to the host device 200. In addition, the first response information receiving unit 312 receives the Delay_Resp message sent from the host device 200. In addition, the first synchronization information sending unit 332 sends the Sync message and the Follow_Up message to the second slave device 400. In addition, the first request information receiving unit 313 receives the Delay_Req message sent from the second slave device 400. In addition, the first response information sending unit 333 sends the Delay_Resp message to the second slave device 400.

[0035] The first time correction unit 320 corrects the time based on the transmission delay time d between the host device 200 calculated from the times Ta1 to Ta4 determined when the message is transmitted and received with the host device 200 through the first synchronization information receiving unit 311, the first request information sending unit 331, and the first response information receiving unit 312. Specifically, the first time correction unit 320 starts the time correction from the timing when the first response information receiving unit 312 completes the reception of the Delay_Resp message. First, the first time correction unit 320 determines the second time Ta2 when the first synchronization information receiving unit 311 receives the Sync message. Next, the first time correction unit 320 determines the first time Ta1 when the host device 200 transmits the Sync message based on the Follow_Up message received by the first synchronization information receiving unit 311. Next, the first time correction unit 320 determines the third time Ta3 when the first request information sending unit 331 sends the Delay_Req message to the host device 200. Next, the first time correction unit 320 determines the fourth time Ta4 when the host device 200 receives the Delay_Req message based on the Delay_Resp message received by the first response information receiving unit 312. Then, the first time correction unit 320 calculates the transmission delay time d using the mathematical formula shown in (1) above by setting T1=Ta1, T2=Ta2, T3=Ta3, T4=Ta4, calculates the correction amount tc using the mathematical formula shown in (2) above, and corrects the time based on the calculated correction amount tc.

[0036] In addition, the first synchronization information sending unit 332 sends synchronization information based on the corrected time during the period from when the first time correction unit 320 corrects the time to when the first synchronization information receiving unit 311 receives the new synchronization information. For example, the first synchronization information sending unit 332 starts sending the synchronization information from the timing when the first time correction unit 320 completes the time correction. Specifically, the first synchronization information sending unit 332 starts sending the Sync message at the timing when the first time correction unit 320 completes the time correction.

[0037] In addition, the first time adjustment unit 320 cannot perform time adjustment during the period from when the first synchronization information sending unit 332 sends the Sync message to when the first request information receiving unit 313 receives the Delay_Req message. For example, the first slave device 300 may turn on a flag that prohibits time adjustment during the period from when the first synchronization information sending unit 332 sends the Sync message to when the first request information receiving unit 313 receives the Delay_Req message, and the first time adjustment unit 320 does not perform time adjustment during the period when the flag is turned on.

[0038] The second slave device 400 includes a second time information receiving unit 410 as an example of a time information receiving unit that receives the time information transmitted from the first slave device 300, and a second time adjustment unit 420 as an example of a time adjustment unit that adjusts the time. In addition, the second slave device 400 includes a second time information sending unit 430 as an example of a time information sending unit that sends the time information.

[0039] The second time information receiving unit 410 includes a second synchronization information receiving unit 411 as an example of a synchronization information receiving unit that receives synchronization information transmitted from the first slave device 300, and a second response information receiving unit 412 as an example of a response information receiving unit that receives response information transmitted from the first slave device 300. In addition, the second time information receiving unit 410 includes a second request information receiving unit 413 as an example of a request information receiving unit that receives request information transmitted from a third slave device (not shown) when the second slave device 400 is connected.

[0040] The second time information sending unit 430 includes a second request information sending unit 431 as an example of a request information sending unit that sends request information to the first slave device 300. In addition, the second time information sending unit 430 includes a second synchronization information sending unit 432 as an example of a synchronization information sending unit that sends synchronization information to the third slave device when the third slave device is connected, and a second response information sending unit 433 as an example of a response information sending unit that sends response information to the third slave device.

[0041] Specifically, the second synchronization information receiving unit 411 receives the Sync message and the Follow_Up message sent by the first synchronization information sending unit 332. In addition, the second request information sending unit 431 sends the Delay_Req message to the first request information receiving unit 313. In addition, the second response information receiving unit 412 receives the Delay_Resp message sent by the first response information sending unit 333. In addition, the second synchronization information sending unit 432 sends the Sync message and the Follow_Up message to the third slave device. In addition, the second request information receiving unit 413 receives the Delay_Req message sent from the third slave device. In addition, the second response information sending unit 433 sends the Delay_Resp message to the third slave device.

[0042] The second time correction unit 420, like the first time correction unit 320, corrects the time based on the transmission delay time d with the first slave device 300 calculated from the times Tb1 to Tb4 determined when the message is transmitted and received with the first slave device 300 through the second synchronization information receiving unit 411, the second request information sending unit 431, and the second response information receiving unit 412. Specifically, the second time correction unit 420 starts the time correction from the timing when the second response information receiving unit 412 completes the reception of the Delay_Resp message. First, the second time correction unit 420 determines the second time Tb2 when the second synchronization information receiving unit 411 receives the Sync message. Then, the second time correction unit 420 determines the first time Tb1 when the first synchronization information sending unit 332 sends the Sync message based on the Follow_Up message received by the second synchronization information receiving unit 411. Next, the second time correction unit 420 determines the third time Tb3 when the second request information sending unit 431 sends the Delay_Req message to the first request information receiving unit 313. Next, the second time correction unit 420 determines the fourth time Tb4 when the second response information receiving unit 412 receives the Delay_Req message based on the Delay_Resp message received by the second response information receiving unit 412. Then, the second time correction unit 420 calculates the transmission delay time d using the mathematical formula shown in (1) above, calculates the correction amount tc using the mathematical formula shown in (2) above, and corrects the time based on the calculated correction amount tc, similarly to the first time correction unit 320, by setting T1=Tb1, T2=Tb2, T3=Tb3, and T4=Tb4.

[0043] Furthermore, when the third slave device is connected to the second slave device 400, the second synchronization information sending unit 432 sends synchronization information based on the corrected time in the period from when the second time correction unit 420 corrects the time to when the second synchronization information receiving unit 411 receives new synchronization information, similarly to the first synchronization information sending unit 332. For example, the second synchronization information sending unit 432 starts sending synchronization information from the timing when the second time correction unit 420 completes the time correction. Specifically, the second synchronization information sending unit 432 starts sending the Sync message at the timing when the second time correction unit 420 completes the time correction.

[0044] In addition, similarly to the first time adjustment unit 320, the second time adjustment unit 420 turns on a flag prohibiting time adjustment, thereby preventing time adjustment from being performed during the period from when the second synchronization information sending unit 432 sends a Sync message to when the second request information receiving unit 413 receives a Delay_Req message.

[0045] Figure 3 This is a block diagram showing the hardware configuration of the first slave device and the second slave device according to the present embodiment.

[0046] Figure 1 , Figure 2 The first slave device 300 and the second slave device 400 shown in FIG. Figure 3 The hardware configuration shown. The first slave device 300 includes a control unit 51, a main storage unit 52, an external storage unit 53, and a transceiver unit 54. In addition, the second slave device 400 includes a control unit 51, a main storage unit 52, an external storage unit 53, and a transceiver unit 54, similarly to the first slave device 300. In addition, although not shown in the figure, the master device 200 may also include a control unit 51, a main storage unit 52, an external storage unit 53, and a transceiver unit 54, similarly to the first slave device 300 and the second slave device 400.

[0047] The control unit 51 executes processing in accordance with the control program 59. The control unit 51 has a CPU (Central Processing Unit). The control unit 51 functions as the first time adjustment unit 320 of the first slave device 300 in accordance with the control program 59. In addition, the control unit 51 functions as the second time adjustment unit 420 of the second slave device 400 in accordance with the control program 59.

[0048] The main storage unit 52 loads the control program 59 and is used as a work area of ​​the control unit 51. The main storage unit 52 has a RAM (Random-Access Memory).

[0049] The external storage unit 53 stores the control program 59 in advance. The external storage unit 53 supplies the data stored in the program to the control unit 51 in accordance with the instruction of the control unit 51, and stores the data supplied from the control unit 51. The external storage unit 53 has a non-volatile memory such as a flash memory, a HDD (Hard Disk Drive), or a SSD (Solid State Drive).

[0050] The transceiver 54 transmits and receives information. The transceiver 54 has information communication components such as a network terminal device connected to the network and a wireless communication device. The transceiver 54 functions as the first time information receiving unit 310, the first synchronization information receiving unit 311, the first response information receiving unit 312, the first request information receiving unit 313, the first time information sending unit 330, the first request information sending unit 331, the first synchronization information sending unit 332, and the first response information sending unit 333 of the first slave device 300. In addition, the transceiver 54 functions as the second time information receiving unit 410, the second synchronization information receiving unit 411, the second response information receiving unit 412, the second request information receiving unit 413, the second time information sending unit 430, the second request information sending unit 431, the second synchronization information sending unit 432, and the second response information sending unit 433 of the second slave device 400.

[0051] In the first slave device 300, the main storage unit 52, the external storage unit 53, and the transceiver unit 54 are all connected to the control unit 51 via the internal bus 50. In addition, in the second slave device 400, similarly to the first slave device 300, the main storage unit 52, the external storage unit 53, and the transceiver unit 54 are all connected to the control unit 51 via the internal bus 50.

[0052] Figure 1 , Figure 2The first slave device 300 shown uses the main storage unit 52, the external storage unit 53, and the transceiver unit 54 as resources through the control unit 51, thereby realizing the functions of the first time information receiving unit 310, the first synchronization information receiving unit 311, the first response information receiving unit 312, the first request information receiving unit 313, the first time adjustment unit 320, the first time information sending unit 330, the first request information sending unit 331, the first synchronization information sending unit 332, and the first response information sending unit 333. For example, the first slave device 300 executes the first time information receiving step as an example of the time information receiving step performed by the first time information receiving unit 310. In addition, the first slave device 300 performs a first synchronization information receiving step as an example of a synchronization information receiving step performed by the first synchronization information receiving unit 311, a first response information receiving step as an example of a response information receiving step performed by the first response information receiving unit 312, and a first request information receiving step as an example of a request information receiving step performed by the first request information receiving unit 313. In addition, the first slave device 300 performs a first time adjustment step as an example of a time adjustment step performed by the first time adjustment unit 320. In addition, the first slave device 300 performs a first time information sending step as an example of a time information sending step performed by the first time information sending unit 330. In addition, the first slave device 300 performs a first request information sending step as an example of a request information sending step performed by the first request information sending unit 331, a first synchronization information sending step as an example of a synchronization information sending step performed by the first synchronization information sending unit 332, and a first response information sending step as an example of a response information sending step performed by the first response information sending unit 333.

[0053] Furthermore, the second slave device 400 uses the main storage unit 52, the external storage unit 53, and the transceiver unit 54 as resources through the control unit 51, thereby realizing the functions of the second time information receiving unit 410, the second synchronization information receiving unit 411, the second response information receiving unit 412, the second request information receiving unit 413, the second time adjustment unit 420, the second time information sending unit 430, the second request information sending unit 431, the second synchronization information sending unit 432, and the second response information sending unit 433. For example, the second slave device 400 executes the first time information receiving step as an example of the time information receiving step performed by the second time information receiving unit 410. In addition, the second slave device 400 performs the second synchronization information receiving step as an example of the synchronization information receiving step performed by the second synchronization information receiving unit 411, the second response information receiving step as an example of the response information receiving step performed by the second response information receiving unit 412, and the second request information receiving step as an example of the request information receiving step performed by the second request information receiving unit 413. In addition, the second slave device 400 performs the second time adjustment step as an example of the time adjustment step performed by the second time adjustment unit 420. In addition, the second slave device 400 performs the second time information sending step as an example of the time information sending step performed by the second time information sending unit 430. In addition, the second slave device 400 performs the second request information sending step as an example of the request information sending step performed by the second request information sending unit 431, the second synchronization information sending step as an example of the synchronization information sending step performed by the second synchronization information sending unit 432, and the second response information sending step as an example of the response information sending step performed by the second response information sending unit 433.

[0054] In addition, in the first slave device 300 and the second slave device 400, the data input and output are performed by the transceiver unit 54, and the input data does not need to be supplied to the operation unit of the control unit 51, but such an operation unit may be provided. In this case, the operation unit may include information input components such as a keyboard, a mouse, a touch panel, and an operation button.

[0055] In addition, the first slave device 300 and the second slave device 400 do not need a display unit for displaying input and output data, but may have such a display unit. In this case, the display unit may have a display device such as an LCD (Liquid Crystal Display) or an organic EL (Electro-Luminescence) display.

[0056] Figure 4 This is a flowchart showing the flow of the first time synchronization process according to the present embodiment.

[0057] Next, use Figure 4 The flowchart shown in FIG. 1 illustrates the operation of synchronizing the time of the first slave device 300 with the master device 200. First, Figure 4 As shown, the first slave device 300 determines whether the first synchronization information receiving unit 311 has received the Sync message and the Follow_Up message from the master device 200 (step S101). If the Sync message and the Follow_Up message are not received (step S101; N), the first slave device 300 repeats the process of step S101 until the first synchronization information receiving unit 311 receives the Sync message and the Follow_Up message. On the other hand, if the Sync message and the Follow_Up message are received (step S101; Y), the first request information sending unit 331 sends the Delay_Req message to the master device 200 (step S102).

[0058] After sending the Delay_Req message, the first slave device 300 determines whether the first response information receiving unit 312 has received the Delay_Resp message from the master device 200 (step S103). If the Delay_Resp message is not received (step S103; N), the first slave device 300 repeats the process of step S103 until the first response information receiving unit 312 receives the Delay_Resp message. On the other hand, if the Delay_Resp message is received (step S103; Y), the first time adjustment unit 320 starts the time adjustment using the first time Ta1, the second time Ta2, the third time Ta3, and the fourth time Ta4 determined by the transmission and reception of the message (step S104). After starting the time adjustment, the first slave device 300 determines whether the first time adjustment unit 320 has completed the time adjustment (step S105). If the time adjustment is not completed (step S105; N), the first slave device 300 repeats the process of step S105 until the first time adjustment unit 320 completes the time adjustment. On the other hand, if the time adjustment is completed (step S105; Y), the first synchronization information sending unit 332 sends a Sync message and a Follow_Up message to the second slave device 400 in sequence (step S106).

[0059] After sending the Follow_Up message, the first slave device 300 determines whether the first request information receiving unit 313 has received a Delay_Req message from the second slave device 400 (step S107). If the Delay_Req message is not received (step S107; N), the first slave device 300 repeats the process of step S107 until the first request information receiving unit 313 receives a Delay_Req message from the second slave device 400. On the other hand, if the Delay_Req message is received (step S107; Y), the first response information sending unit 333 sends a Delay_Resp message to the second slave device 400 (step S108), and the first time synchronization process ends.

[0060] Figure 5 This is a flowchart showing the flow of the second time synchronization process according to the present embodiment.

[0061] Next, use Figure 5 The flowchart shown in FIG. 1 illustrates the operation of synchronizing the second slave device 400 with the master device 200 via the first slave device 300. First, Figure 5 As shown, the second slave device 400 determines whether the second synchronization information receiving unit 411 has received the Sync message and the Follow_Up message from the first slave device 300 (step S201). If the Sync message and the Follow_Up message are not received (step S201; N), the second slave device 400 repeats the process of step S201 until the second synchronization information receiving unit 411 receives the Sync message and the Follow_Up message. On the other hand, if the Sync message and the Follow_Up message are received (step S201; Y), the second request information sending unit 431 sends the Delay_Req message to the first slave device 300 (step S202).

[0062] After sending the Delay_Req message, the second slave device 400 determines whether the second response information receiving unit 412 has received the Delay_Resp message from the first slave device 300 (step S203). If the Delay_Resp message is not received (step S203; N), the second slave device 400 repeats the process of step S203 until the second response information receiving unit 412 receives the Delay_Resp message. On the other hand, if the Delay_Resp message is received (step S203; Y), the second time adjustment unit 420 starts the time adjustment using the first time Tb1, the second time Tb2, the third time Tb3, and the fourth time Tb4 determined by the transmission and reception of the message (step S204). After starting the time adjustment, the second slave device 400 determines whether the second time adjustment unit 420 has completed the time adjustment (step S205). If the time adjustment is not completed (step S205; N), the second slave device 400 repeats the process of step S205 until the second time adjustment unit 420 completes the time adjustment. On the other hand, if the time adjustment is completed (step S205; Y), if the third slave device is not connected, the second slave device 400 ends the second time synchronization process.

[0063] In addition, although not shown in the figure, if a third slave device is connected, the second slave device 400 performs the same processing as steps S106 to S108 of the first time synchronization processing, and the second time synchronization processing is completed. Specifically, the second synchronization information sending unit 432 sends a Sync message and a Follow_Up message to the third slave device in sequence. Moreover, when the second request information receiving unit 413 receives a Delay_Req message from the third slave device, the second response information sending unit 433 sends a Delay_Resp message to the third slave device, and the second time synchronization processing is completed.

[0064] Figure 6 This is a sequence diagram showing an example of message transmission and reception in the time synchronization system according to the present embodiment.

[0065] Next, use Figure 6 The timing chart shown in the figure explains the timing at which the master device 200, the first slave device 300, and the second slave device 400 transmit and receive messages and the first slave device 300 and the second slave device 400 adjust the time in the time synchronization system. Figure 6As shown, the host device 200 sends a Sync message to the first slave device 300 at the first time Ta1, and the first slave device 300 receives the Sync message at the second time Ta2. In addition, after sending the Sync message, the host device 200 sends a Follow_Up message that can identify the first time Ta1 to the first slave device 300, and the first slave device 300 receives the Follow_Up message and identifies the first time Ta1.

[0066] After receiving the Follow_Up message, the first slave device 300 sends a Delay_Req message to the host device 200 at the third time Ta3, and the host device 200 receives the Delay_Req message at the fourth time Ta4. In addition, after receiving the Delay_Req message, the host device 200 sends a Delay_Resp message that can identify the fourth time Ta4 to the first slave device 300, and the first slave device 300 receives the Delay_Resp message and identifies the fourth time Ta4.

[0067] Therefore, the first slave device 300 measures the first time Ta1, the second time Ta2, the third time Ta3, and the fourth time Ta4 during the period from when the host device 200 sends the Sync message to when the host device 200 receives the Delay_Req message, and finally receives the Delay_Resp message that can determine the fourth time Ta4, thereby being able to calculate the transmission delay time d. In the following, the period from when the host device 200 sends the Sync message to when the Delay_Req message is received is set as the transmission delay measurement period between the first slave device 300 and the host device 200.

[0068] After receiving the Delay_Resp message during the transmission delay measurement period with the master device 200, the first slave device 300 uses the mathematical formula shown in (1) above to calculate the transmission delay time d using the measured first moment Ta1, second moment Ta2, third moment Ta3, and fourth moment Ta4. In addition, the first slave device 300 uses the mathematical formula shown in (2) above to calculate the correction amount tc using the calculated transmission delay time d, and corrects the moment based on the calculated correction amount tc. In the following, the period from when the first slave device 300 starts calculating the transmission delay time d to when the moment is corrected is defined as the moment correction period of the first slave device 300.

[0069] After the time correction period has passed, the first slave device 300 sends a Sync message to the second slave device 400 at the first time Tb1, and the second slave device 400 receives the Sync message at the second time Tb2 and starts the transmission delay measurement period. In addition, after sending the Sync message, the first slave device 300 sends a Follow_Up message that can determine the first time Tb1 to the second slave device 400, and the second slave device 400 receives the Follow_Up message and determines the first time Tb1. In addition, the second slave device 400 sends a Delay_Req message to the first slave device 300 at the third time Tb3 after receiving the Follow_Up message, and the first slave device 300 receives the Delay_Req message at the fourth time Tb4.

[0070] After receiving the Delay_Req message, the first slave device 300 sends a Delay_Resp message capable of determining the fourth time Tb4 to the second slave device 400. The second slave device 400 receives the Delay_Resp message and determines the fourth time Tb4, thereby terminating the transmission delay measurement period. In addition, the first slave device 300 is prohibited from recalibrating the time during the period from when the Sync message is sent to when the Delay_Req message is received, that is, during the transmission delay measurement period between the first slave device 300 and the second slave device 400. In the following, the period from when the first slave device 300 sends the Sync message to when the Delay_Req message is received is sometimes described as a time correction prohibition period of the first slave device 300.

[0071] After receiving the Delay_Resp message during the transmission delay measurement period with the first slave device 300, the second slave device 400 starts the time correction period and uses the mathematical formula shown in (1) above to calculate the transmission delay time d using the measured first time Tb1, second time Tb2, third time Tb3, and fourth time Tb4. Furthermore, the second slave device 400 uses the mathematical formula shown in (2) above to calculate the correction amount tc using the calculated transmission delay time d, corrects the time based on the calculated correction amount tc, and ends the time correction period.

[0072] As described above, according to the time synchronization system 100 of the present embodiment, the first slave device 300 is connected between the master device 200 storing the reference time and the second slave device 400 , and synchronizes the time with the master device 200 together with the second slave device 400 in accordance with PTP.

[0073] The first synchronization information sending unit 332 sends a Sync message and a Follow_Up message to the second slave device 400 in sequence. In addition, the first request information receiving unit 313 receives a Delay_Req message sent from the second slave device 400 after the first synchronization information sending unit 332 sends the Follow_Up message. In addition, the first response information sending unit 333 sends a Delay_Resp message corresponding to the Delay_Req message received by the first request information receiving unit 313 to the second slave device 400. In addition, the first time correction unit 320 corrects the time based on the transmission delay time d between the host device 200 and the host device 200 calculated from the times Ta1 to Ta4 determined when the message is sent and received with the host device 200, during a period different from the transmission delay measurement period from the time when the first synchronization information sending unit 332 sends the Sync message to the time when the first request information receiving unit 313 receives the Delay_Req message.

[0074] Thus, during the period from when the first slave device 300 sends a Sync message to the second slave device 400 to when the first slave device 300 receives a Delay_Req message from the second slave device 400, that is, during the transmission delay measurement period with the second slave device 400, the first slave device 300 does not correct the time. Therefore, even if the first slave device 300 and the second slave device 400 each set a timing for time synchronization, the second slave device 400 can prevent an error in the transmission delay time calculated during this period. Therefore, compared with a time synchronization system that corrects the time during the period from when the first slave device sends a Sync message to the second slave device to when the Delay_Req message is received from the second slave device, the error in the time of the second slave device 400 can be reduced.

[0075] Here, the IEEE 1588 specification does not specify the timing of the boundary clock performing time correction and the timing of sending messages to the slave device connected to the boundary clock. Therefore, in the existing time synchronization system that performs time synchronization in accordance with PTP, there is a problem that the accuracy of time synchronization is different because each slave device that functions as a boundary clock has different manufacturers, specifications, etc. For example, in the existing time synchronization system, during the period when the first slave device that functions as a boundary clock and the second slave device are sending and receiving messages, that is, during the transmission delay measurement period between the first slave device and the second slave device, the first slave device may send and receive messages with the master device to correct the time.

[0076] Figure 7 This is a sequence diagram showing an example of message transmission and reception in a conventional time synchronization system.

[0077] For example, Figure 7 As shown, in the existing time synchronization system, consider the case where the first slave device receives the Delay_Resp message from the master device after sending the Sync message and the Follow_Up message to the second slave device. In this case, the time correction is sometimes completed before the first slave device receives the Delay_Req message from the second slave device. In this case, after sending the Follow_Up message that can determine the first moment Tb1 based on the moment before correction, the first slave device sends the Delay_Resp message that can determine the fourth moment Tb4 based on the moment after correction. As a result, the first slave device completes the time correction during the transmission delay measurement period between the first slave device and the second slave device, and the second slave device uses the first moment Tb1 based on the moment before correction of the first slave device and the fourth moment Tb4 based on the moment after correction to perform time correction.

[0078] Figure 8 : is a diagram showing an example of changes in time error in a conventional time synchronization system. Figure 8 The change in the time difference between the first slave device and the master device is exemplified by the single-dashed chain line, and the change in the time difference between the second slave device and the master device is exemplified by the double-dashed chain line.

[0079] In this case, if Figure 8 As shown, first, after the first slave device sends a Sync message at the 11th timing t11, it sends a Follow_Up message that can identify the first time Tb1 based on the time before correction to the second slave device. Then, after the second slave device receives the Sync message at the 12th timing t12 and identifies the second time Tb2, it receives the Follow_Up message and identifies the first time Tb1.

[0080] Next, the first slave device starts time correction at the 13th timing t13 and completes time correction at the 14th timing t14. Next, the second slave device sends a Delay_Req message to the first slave device at the 15th timing t15 to determine the third time Tb3. Next, the first slave device receives the Delay_Req message at the 16th timing t16 and sends a Delay_Resp message that can determine the fourth time Tb4 based on the corrected time to the second slave device at the 17th timing t17. Next, the second slave device receives the Delay_Resp message at the 18th timing t18, completes the measurement from the first time Tb1 to the fourth time Tb4, starts time correction, and completes time correction at the 19th timing t19.

[0081] The results, such as Figure 8As shown, there is a problem that even if the first slave device performs time correction and resets the time difference with the master device to 0, if the second slave device performs time correction, the time difference β will remain. In addition, if the time difference before correction between the first slave device and the master device is set to α, and the transmission delay time of the remaining time difference β after correction is set to d', the transmission delay time d' is a value calculated using the mathematical formula shown in the following (3), and the time difference β is a value calculated using the mathematical formula shown in the following (4).

[0082] d′={(Tb4+α-Tb1)-(Tb3-Tb2)} / 2=d+α / 2…(3)

[0083] β=d′-d=α / 2…(4)

[0084] Fig. 9 : is a diagram showing an example of a change in the time error in the time synchronization system according to the present embodiment. Fig. 9 and Figure 8 Similarly, the change in the time difference between the first slave device and the master device is illustrated by a single-dashed line, and the change in the time difference between the second slave device and the master device is illustrated by a double-dashed line.

[0085] In contrast, in the time synchronization system 100 according to the present embodiment, the second slave device 400 performs time correction using the first time Tb1 and the fourth time Tb4 based on the corrected time of the first slave device 300. Specifically, Fig. 9 As shown, first, the first slave device 300 starts time adjustment at the 21st timing t21, completes time adjustment at the 22nd timing t22, and after sending the Sync message, sends a Follow_Up message that can identify the first time Tb1 based on the corrected time to the second slave device 400.

[0086] Next, the second slave device 400 receives the Sync message at the 23rd timing t23 and determines the second time Tb2, and then receives the Follow_Up message and determines the first time Tb1. Next, the second slave device 400 sends the Delay_Req message to the first slave device 300 at the 24th timing t24 and determines the third time Tb3. Next, the first slave device 300 receives the Delay_Req message at the 25th timing t25, and sends the Delay_Resp message that can determine the fourth time Tb4 based on the corrected time to the second slave device 400 at the 26th timing t26. Next, the second slave device 400 receives the Delay_Resp message at the 27th timing t27, completes the measurement from the first time Tb1 to the fourth time Tb4, starts the time correction, and completes the time correction at the 28th timing t28.

[0087] The results, such as Fig. 9 As shown, if the first slave device 300 performs time adjustment and resets the time difference with the master device 200 to 0, even if the second slave device 400 performs time adjustment, the time difference with the master device 200 is reset to 0.

[0088] As a result, the time synchronization system 100 according to the present embodiment solves the problems in the above-mentioned conventional time synchronization system.

[0089] In particular, according to the time synchronization system 100 involved in this embodiment, in the first slave device 300, the transmission delay measurement period between it and the second slave device 400 is a time correction prohibited period, for example, the flag prohibiting time correction is set to on, and the first time correction unit 320 is controlled to be unable to correct the time.

[0090] This makes it possible to reliably prevent the first slave device 300 from correcting the time during the transmission delay measurement period with the second slave device 400 .

[0091] In addition, in the present embodiment, the time correction prohibition period is set as the transmission delay measurement period with the second slave device 400, that is, the period from when the first slave device 300 sends the Sync message to the second slave device 400 to when the first slave device 300 receives the Delay_Req message from the second slave device 400, but the present invention is not limited thereto. For example, the time correction prohibition period may also be set as the period from when the first slave device 300 sends the Sync message to the second slave device 400 to when the first slave device 300 receives the Delay_Req message from the second slave device 400 and sends the Delay_Resp message to the second slave device 400.

[0092] Furthermore, according to the time synchronization system 100 according to the present embodiment, the first synchronization information transmission unit 332 starts transmitting the Sync message to the second slave device 400 at the timing when the first time adjustment unit 320 completes the time adjustment.

[0093] Thus, the transmission delay measurement period between the first slave device 300 and the second slave device 400 can be started from the timing when the first slave device 300 completes the time correction, and the second slave device 400 can calculate the transmission delay time based on the corrected time of the first slave device 300 to correct the time. In addition, compared with the time synchronization system that does not start sending the Sync message to the slave device from the timing when the time correction is completed, the period during which the time error between the second slave device 400 and the host device 200 occurs can be reduced.

[0094] In addition, as shown in the present embodiment, it is preferred that the Sync message be sent to the second slave device 400 from the timing when the first slave device 300 completes the time correction, but the present invention is not limited thereto as long as the first slave device 300 does not perform the time correction during the transmission delay measurement period between the first slave device 300 and the second slave device 400. For example, the first synchronization information sending unit 332 may start sending the Sync message to the second slave device 400 after the first time correction unit 320 completes the time correction and after a predetermined period has passed. In addition, for example, the first synchronization information sending unit 332 may start sending the Sync message to the second slave device 400 before the first time correction unit 320 starts the time correction.

[0095] Fig.10 This is a sequence diagram showing an example of message transmission and reception in the time synchronization system according to a modification example of the present embodiment.

[0096] For example, Fig.10 As shown in FIG. 1 , the Sync message may be sent to the second slave device 400 before the first slave device 300 sends the Delay_Req message to the host device 200. In this case, the first slave device 300 may send the Delay_Req message to the host device 200 after sending the Sync message to the second slave device 400, and then send the Follow_Up message to the second slave device 400, and then receive the Delay_Req message from the second slave device 400 after receiving the Delay_Resp message from the host device 200. In this case, Fig.10As shown in FIG. 1 , the period of measuring the transmission delay between the first slave device 300 and the second slave device 400 until the Delay_Req message is received from the second slave device 400 is a period during which the time adjustment of the first slave device 300 is prohibited. Therefore, the first slave device 300 may not start the time adjustment even if it receives the Delay_Resp message from the master device 200, but may start the time adjustment after the period has passed after the Delay_Req message is received from the second slave device 400.

[0097] Furthermore, according to the time synchronization system 100 according to the present embodiment, the first time adjustment unit 320 starts the time adjustment from the timing when the first response information receiving unit 312 completes the reception of the Delay_Resp message.

[0098] Thus, compared with a time synchronization system in which the first slave device does not start time adjustment from the timing when the reception of the Delay_Resp message is completed, the period during which the time error between the first slave device 300 and the host device 200 is generated can be reduced. In addition, compared with a time synchronization system in which the first slave device does not start time adjustment from the timing when the reception of the Delay_Resp message is completed, it is easy to complete time adjustment before the first slave device 300 receives a new Sync message from the host device 200. In addition, compared with a time synchronization system in which the first slave device does not start time adjustment from the timing when the reception of the Delay_Resp message is completed, it is possible to complete time adjustment at an earlier timing and start the transmission delay measurement period with the second slave device 400 based on the corrected time. As a result, the period during which the time error between the second slave device 400 and the host device 200 is generated can be reduced.

[0099] In addition, as shown in the present embodiment, it is preferred that the first slave device 300 starts the time adjustment from the timing when the reception of the Delay_Resp message is completed, but the present invention is not limited to this as long as the first slave device 300 does not perform the time adjustment during the transmission delay measurement period between the first slave device 300 and the second slave device 400. For example, the first time adjustment unit 320 may start the time adjustment after the first response information receiving unit 312 completes the reception of the Delay_Resp message and a predetermined period has passed.

[0100] Furthermore, according to the time synchronization system 100 according to the present embodiment, the second time adjustment unit 420 starts the time adjustment from the timing when the second response information receiving unit 412 completes the reception of the Delay_Resp message.

[0101] Thus, compared with a time synchronization system in which the second slave device does not start time adjustment from the timing when the reception of the Delay_Resp message is completed, the period during which the time error between the second slave device 400 and the master device 200 is generated can be reduced. In addition, compared with a time synchronization system in which the second slave device does not start time adjustment from the timing when the reception of the Delay_Resp message is completed, it is easy to complete time adjustment before the second slave device 400 receives a new Sync message from the first slave device 300. In addition, compared with a time synchronization system in which the second slave device does not start time adjustment from the timing when the reception of the Delay_Resp message is completed, time adjustment can be completed at an earlier timing, and when the third slave device is connected to the second slave device 400, the transmission delay measurement period between the third slave device and the master device 200 can be started based on the corrected time. As a result, the period during which the time error between the third slave device and the master device 200 is generated can be reduced.

[0102] In addition, as shown in this embodiment, it is preferred that the second slave device 400 starts the time adjustment from the timing when the reception of the Delay_Resp message is completed, but the present invention is not limited to this as long as the second slave device 400 does not perform the time adjustment during the transmission delay measurement period between the second slave device and the third slave device. For example, the second time adjustment unit 420 may start the time adjustment after the second response information receiving unit 412 completes the reception of the Delay_Resp message and a predetermined period has passed.

[0103] In addition, as shown in the present embodiment, when the third slave device is connected to the second slave device 400, it is preferred that the Sync message be sent to the third slave device from the timing when the second slave device 400 completes the time correction, but the present invention is not limited to this as long as the second slave device 400 does not perform the time correction during the transmission delay measurement period between the second slave device and the third slave device. For example, the second synchronization information sending unit 432 may start sending the Sync message to the third slave device after the second time correction unit 420 completes the time correction and a predetermined period has passed.

[0104] In addition, in this embodiment, the synchronization information is sent in a so-called Two-Step manner in which a Follow_Up message that can identify the first time T1 when the Sync message is sent is sent after the Sync message is sent, but the present invention is not limited thereto. For example, the synchronization information may be sent in a so-called One-Step manner in which a Sync message that can identify the first time T1 as the sending time is sent without sending a Follow_Up message.

[0105] In addition, in the present embodiment, the first slave device 300 as an example of a time synchronization device is connected to the host device 200, but the connection target of the first slave device 300 is not limited to the host device 200 as long as it is a time storage device. For example, the first slave device 300 can also be connected to an upper slave device as an example of a time storage device. Here, the upper slave device refers to a slave device having fewer relay stations of the boundary clock to the host than the first slave device 300. Therefore, the upper slave device, like the first slave device 300 and the second slave device 400, needs to be a computer that functions as a boundary clock in PTP. That is, the time storage device is not limited to the host device 200 that functions as a host, but can also be an upper slave device that functions as a boundary clock. In addition, when the connection target of the first slave device 300 is set to an upper slave device, if the upper slave device is the same as the first slave device 300 and is configured not to correct the time during the transmission delay measurement period between the upper slave device and the first slave device 300, the effect of the present invention can be achieved.

[0106] Furthermore, in the present embodiment, a linear connection in which the host device 200, the first slave device 300, the second slave device 400, the third slave device, ... are connected in a linear manner constitutes a LAN network, but the form of the LAN network is not limited thereto. For example, it may be a ring connection in which the host device 200 and a plurality of slave devices including the first slave device 300 and the second slave device 400 are connected in a ring shape. Also, for example, it may be a tree connection in which a plurality of slave devices are connected in a tree shape with the master device 200 as the root. Also, for example, it may be a bus connection in which the host device 200 and a plurality of slave devices are connected to one bus, or it may be a star connection in which one hub is connected. Also, for example, it may be a grid connection in which the host device 200 and a plurality of slave devices are connected in a grid shape. In these cases, the effects of the present invention can also be achieved by setting the slave device directly connected to the host device 200 as the first slave device 300 and setting the slave device directly connected to the first slave device 300 instead of the host device 200 as the second slave device 400 .

[0107] In addition, the core part of the processing of the first slave device 300 and the second slave device 400 can be realized by using a general computer system instead of a dedicated system. The first slave device 300 and the second slave device 400 have a control unit 51, a main storage unit 52, an external storage unit 53, a transceiver unit 54, an internal bus 50, etc. For example, a computer program for executing the above-mentioned operation can be stored in a computer-readable recording medium such as a floppy disk, a DVD-ROM (Read-Only Memory), etc. and distributed, and the computer program can be installed in a computer to configure the first slave device 300 and the second slave device 400 that execute the above-mentioned processing. In addition, the computer program can be stored in advance in a storage device of a server device on a communication network such as the Internet, and it can be downloaded by a general computer system to configure the first slave device 300 and the second slave device 400.

[0108] In addition, when the functions of the first slave device 300 and the second slave device 400 are implemented by sharing the OS (operating system) and the application, or when they are implemented by the collaborative action of the OS and the application, only the application part may be stored in the recording medium or the storage device.

[0109] In addition, the computer program may be superimposed on a carrier wave and provided 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 provided via the network. Furthermore, the processing may be performed by starting the computer program and executing it in the same manner as other application programs under the control of the OS.

[0110] The present invention can be set to various embodiments and variations without departing from the broad spirit and scope of the present invention. In addition, the above-mentioned embodiments are used to illustrate the present invention and are not intended to limit the scope of the present invention. That is, the scope of the present invention is not the embodiments, but is represented by the claims. Moreover, various variations implemented within the scope of the claims and within the scope of the disclosure equivalent thereto are considered to be within the scope of the present invention.

[0111] Description of the label

[0112] 50 internal bus, 51 control unit, 52 main storage unit, 53 external storage unit, 54 transceiver unit, 59 control program, 100 time synchronization system, 200 host device, 201, 302, 402 master port, 300 first slave device, 301, 401 slave port, 310 first time information receiving unit, 311 first synchronization information receiving unit, 312 first response information receiving unit, 313 first request information receiving unit, 320 first time correction unit, 330 first time information Sending unit, 331 first request information sending unit, 332 first synchronization information sending unit, 333 first response information sending unit, 400 second slave device, 410 second time information receiving unit, 411 second synchronization information receiving unit, 412 second response information receiving unit, 413 second request information receiving unit, 420 second time correction unit, 430 second time information sending unit, 431 second request information sending unit, 432 second synchronization information sending unit, 433 second response information sending unit.

Claims

1. A time synchronization device connected to a time storage device that stores time, and synchronizes time with the time storage device together with other time synchronization devices that are not connected to the time storage device, The time synchronization device has: a synchronization information sending unit, which sends synchronization information related to time synchronization to the other time synchronization devices; a request information receiving unit for receiving request information based on the synchronization information and sent from the other time synchronization device after the synchronization information sending unit sends the synchronization information; a response information sending unit, which sends response information corresponding to the request information received by the request information receiving unit to the other time synchronization device; as well as a time correction unit that corrects the time based on a transmission delay time between the time storage device and the time storage device during a period different from a prescribed period after the synchronization information sending unit sends the synchronization information and until the request information receiving unit receives the request information, the transmission delay time being calculated based on a time determined when information is sent and received between the time storage device and the time storage device, and on the other hand, does not perform time correction even if information is sent and received between the time storage device and the time storage device during the prescribed period, During the predetermined period, the time synchronization device can transmit and receive information with the time storage device.

2. The time synchronization device according to claim 1, further comprising: a synchronization information receiving unit for receiving the synchronization information sent from the time storage device; a request information sending unit that sends the request information based on the synchronization information received by the synchronization information receiving unit to the time storage device; and a response information receiving unit for receiving the response information sent from the time storage device that has received the request information, When the response information receiving unit receives the response information within the predetermined period, the time adjustment unit starts the time adjustment after the request information receiving unit completes reception of the request information.

3. The time synchronization device according to claim 1 or 2, wherein: The synchronization information transmitting unit starts transmitting the synchronization information at a timing when the time adjustment unit completes the time adjustment.

4. A time synchronization system, comprising a time storage device for storing time, a first time synchronization device connected to the time storage device, and a second time synchronization device connected to the first time synchronization device, wherein the first time synchronization device and the second time synchronization device perform time synchronization with the time storage device, and in the time synchronization system, The first time synchronization device comprises: a first synchronization information receiving unit for receiving synchronization information related to time synchronization transmitted from the time storage device; a first request information sending unit that sends request information based on the synchronization information received by the first synchronization information receiving unit to the time storage device; a first response information receiving unit for receiving response information transmitted from the time storage device that has received the request information; a first time correction unit that corrects the time based on a transmission delay time with the time storage device, the transmission delay time with the time storage device being calculated based on a time determined when information is sent and received between the first synchronization information receiving unit, the first request information sending unit, and the first response information receiving unit and the time storage device; a first synchronization information sending unit, which sends the synchronization information to the second time synchronization device; a first request information receiving unit configured to receive the request information transmitted from the second time synchronization device after the first synchronization information transmitting unit transmits the synchronization information; and a first response information sending unit that sends the response information corresponding to the request information received by the first request information receiving unit to the second time synchronization device, The second time synchronization device comprises: a second synchronization information receiving unit configured to receive the synchronization information transmitted by the first synchronization information transmitting unit; a second request information sending unit that sends the request information based on the synchronization information received by the second synchronization information receiving unit to the first time synchronization device; a second response information receiving unit configured to receive the response information transmitted by the first response information transmitting unit; and a second time correction unit that corrects the time based on a transmission delay time with the first time synchronization device, the transmission delay time with the first time synchronization device being calculated based on a time determined when information is sent and received between the second synchronization information receiving unit, the second request information sending unit, and the second response information receiving unit and the first time synchronization device, The first time synchronization device can transmit and receive the information with the time storage device during a predetermined period after the first synchronization information transmission unit transmits the synchronization information and until the first request information reception unit receives the request information, but does not perform time adjustment even when transmitting and receiving information with the time storage device.

5. The time synchronization system according to claim 4, wherein: The second time adjustment unit starts adjusting the time from the timing when the second response information receiving unit completes reception of the response information.

6. A time synchronization method, which performs: a synchronization information sending step, sending synchronization information related to time synchronization to other time synchronization devices which are not connected to the time storage device storing the time but perform time synchronization with the time storage device; a request information receiving step, after the synchronization information is sent in the synchronization information sending step, receiving request information based on the synchronization information sent from the other time synchronization device; a response information sending step, sending the response information corresponding to the request information received in the request information receiving step to the other time synchronization device; as well as A time correction step, in which the time is corrected based on the transmission delay time with the time storage device during a specified period different from the period from when the synchronization information is sent in the synchronization information sending step to when the request information is received in the request information receiving step, wherein the time is calculated based on the time determined when information is sent and received with the time storage device, and on the other hand, during the specified period, the information can be sent and received with the time storage device, but the time correction is not performed even if information is sent and received with the time storage device.

7. A computer-readable recording medium storing a program for causing the computer to function as: a synchronization information sending unit that sends synchronization information related to time synchronization to other time synchronization devices that are not connected to the time storage device that stores the time and perform time synchronization with the time storage device; a request information receiving unit for receiving request information based on the synchronization information and sent from the other time synchronization device after the synchronization information sending unit sends the synchronization information; a response information sending unit, which sends response information corresponding to the request information received by the request information receiving unit to the other time synchronization device; as well as A time correction unit that corrects the time based on a transmission delay time with the time storage device during a specified period different from a period from when the synchronization information sending unit sends the synchronization information to when the request information receiving unit receives the request information, wherein the transmission delay time with the time storage device is calculated based on a time determined when information is sent and received with the time storage device, and on the other hand, during the specified period, the information can be sent and received with the time storage device, but the time correction is not performed even if information is sent and received with the time storage device.

Citation Information

Patent Citations

  • Time synchronization device and time synchronization method

    JP2018088646A

  • Time synchronization and routing method in wireless sensor network, and apparatus for enabling the method

    US20110002251A1