CN111769895B - Multi-device timing method and system and device timing method and device - Google Patents

Multi-device timing method and system and device timing method and device Download PDF

Info

Publication number
CN111769895B
CN111769895B CN201910258077.1A CN201910258077A CN111769895B CN 111769895 B CN111769895 B CN 111769895B CN 201910258077 A CN201910258077 A CN 201910258077A CN 111769895 B CN111769895 B CN 111769895B
Authority
CN
China
Prior art keywords
time
timing module
devices
timing
real
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
CN201910258077.1A
Other languages
Chinese (zh)
Other versions
CN111769895A (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.)
Xian Novastar Electronic Technology Co Ltd
Original Assignee
Xian Novastar Electronic Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Xian Novastar Electronic Technology Co Ltd filed Critical Xian Novastar Electronic Technology Co Ltd
Priority to CN201910258077.1A priority Critical patent/CN111769895B/en
Publication of CN111769895A publication Critical patent/CN111769895A/en
Application granted granted Critical
Publication of CN111769895B publication Critical patent/CN111769895B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04JMULTIPLEX COMMUNICATION
    • H04J3/00Time-division multiplex systems
    • H04J3/02Details
    • H04J3/06Synchronising arrangements
    • H04J3/0635Clock or time synchronisation in a network
    • H04J3/0638Clock or time synchronisation among nodes; Internode synchronisation
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04BTRANSMISSION
    • H04B1/00Details of transmission systems, not covered by a single one of groups H04B3/00 - H04B13/00; Details of transmission systems not characterised by the medium used for transmission
    • H04B1/69Spread spectrum techniques
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D30/00Reducing energy consumption in communication networks
    • Y02D30/70Reducing energy consumption in communication networks in wireless communication networks

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Synchronisation In Digital Transmission Systems (AREA)
  • Electric Clocks (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The embodiment of the invention discloses a multi-equipment timing method and system and an equipment timing method and device. The multi-device timing method is suitable for application to a system comprising a plurality of devices, for example comprising: an acquisition step, wherein each device selects one of a plurality of timing modules configured by the device to periodically acquire target time; and setting the current system time according to the target time by each device. The aim of time synchronization of multiple devices is fulfilled under different environments.

Description

Multi-device timing method and system and device timing method and device
Technical Field
The invention relates to the technical field of equipment timing and synchronous broadcasting control; in particular to a multi-device timing method, a multi-device timing system, a device timing method and a device timing device.
Background
The current timing mode of the computer operating system is to calculate the total seconds from 1970/01/01, but the computer hardware is mainly based on the time inside the BIOS, and the two times are different due to the frequency problem of each chip. In order to avoid that the time deviation is bigger and bigger due to long-time running of the device, the timing of the computer operating system and the computer hardware is very important.
Timing by means of network time protocol (Network Time Protocol, NTP) enables time synchronization between the computer operating system and the computer hardware; the principle is as follows: the method comprises the steps of selecting a plurality of main host machine adjustment time, synchronizing clocks of the plurality of host machines, and then opening network service to enable more computer terminals to be in clock synchronization with the plurality of host machines through online connection.
On the other hand, synchronous playing of a plurality of asynchronous playing boxes (or called display screen asynchronous control systems) is realized, and accuracy of system time of the plurality of asynchronous playing boxes must be ensured. However, since the timing mode of the network time protocol requires that the asynchronous playing box must be connected to the network, the synchronous playing of multiple terminal devices under various environments is needed to be solved under the condition that the network cannot be connected to other remote areas.
Disclosure of Invention
Therefore, the embodiment of the invention provides a multi-equipment timing method, a multi-equipment timing system, an equipment timing method and an equipment timing device, so that the technical effect of realizing time synchronism of a plurality of equipment in different environments in a proper mode is realized.
In one aspect, embodiments of the present invention provide a multi-device timing method, suitable for application to a system including a plurality of devices; the multi-device timing method comprises the following steps: an acquisition step, wherein each device selects one of a plurality of timing modules configured by the device to periodically acquire target time; and setting the current system time according to the target time by each device.
According to the embodiment of the disclosure, through mixing multiple timing modules and according to different timing mechanisms of different timing modules, the multiple devices adopt proper timing modules in different environments, so that the purpose of timing of the multiple devices is achieved, and the synchronization of time of the multiple devices is ensured.
In one embodiment of the invention, the step of obtaining comprises: the plurality of devices respectively select real-time clock timing modules in the plurality of timing modules which are respectively configured, wherein the real-time clock timing module of each device is connected with a real-time clock chip of the device, and the real-time clock timing module periodically generates the target time according to the time of the respective real-time clock chip according to a third time interval.
In one embodiment of the invention, the step of obtaining comprises: the plurality of devices respectively select network time protocol timing modules in the plurality of timing modules configured respectively, and periodically receive time from the same time server as the respective target time according to a second time interval.
In one embodiment of the invention, the step of obtaining comprises: one of the plurality of devices serves as a master device, and devices other than the master device among the plurality of devices serve as slave devices; the master device selects a wireless spread spectrum communication timing module in the timing modules configured by the master device and sends out the current system time in a wireless spread spectrum communication mode; each slave device selects a wireless spread spectrum communication timing module in the plurality of timing modules configured by the slave device, and the wireless spread spectrum communication timing module periodically acquires the current system time sent outwards by the master device as the target time according to a first time interval.
The embodiment of the disclosure provides three timing modules, wherein the wireless spread spectrum communication module realizes the time synchronization of multiple devices in a wireless mode, and the mode is suitable for the situation that the distance between multiple devices is relatively close, and the multiple devices can perform data transmission through wireless spread spectrum communication, such as multiple display devices distributed in the same square or market; the network time protocol timing module is used for timing the multiple devices in a mode of acquiring target time from the same time server, the multiple devices are connected with a network, the target time can be acquired from the time server, and the network time protocol timing module is suitable for the situation that the network condition is good and the distance between the multiple devices is far; the real-time synchronization timing module achieves time synchronization of a plurality of devices by guaranteeing time accuracy of each device, and the method is suitable for the situation that the distance between the devices is far and the devices are not connected with the Internet, such as a plurality of power devices distributed in a mountain area.
In another aspect, an embodiment of the present invention provides a multi-device timing system, including: a plurality of broadcasting devices;
each broadcasting device is provided with a plurality of timing modules; when each broadcasting device performs the acquisition operation, a plurality of timing modules configured by the broadcasting device are respectively used for periodically acquiring the target time at different time intervals when being selected in an alternative mode; and setting the current system time according to the target time when each broadcasting device performs time setting operation.
In another aspect, an embodiment of the present invention provides a device timing method, including: an acquisition step of periodically acquiring target time when a plurality of timing modules are selected in an alternative way, wherein the plurality of timing modules comprise a plurality of real-time clock timing modules, a network time protocol timing module and a wireless spread spectrum communication timing module, the real-time clock timing modules are connected with a real-time clock chip and are used for periodically generating the target time according to the output time of the real-time clock chip according to a third time interval, the network time protocol timing module is used for periodically receiving time from a time server according to a second time interval as the target time, and the wireless spread spectrum communication timing module is used for periodically receiving externally input time according to a first time interval as the target time in a wireless spread spectrum communication way; and setting the current system time according to the target time.
In still another aspect, an apparatus for calibrating time of a device provided by an embodiment of the present invention includes: an acquisition module configured to periodically acquire a target time when selected in a selective manner, wherein the plurality of timing modules include a plurality of real-time clock timing modules, a network time protocol timing module, and a wireless spread spectrum communication timing module, the real-time clock timing module being connected to a real-time clock chip and configured to periodically generate the target time according to a time output from the real-time clock chip at a third time interval when selected, the network time protocol timing module being configured to periodically receive a time from a time server at the second time interval as the target time when selected, and the wireless spread spectrum communication timing module being configured to periodically receive an externally input time as the target time at a first time interval when selected; and the time setting module is used for setting the current system time according to the target time.
In summary, in the foregoing embodiment of the present invention, a plurality of timing modules are set in the device, and the plurality of timing modules are selected to obtain the target time in an alternative manner to set the current system time of the device, so that the method can cope with timing of multiple devices in various application scenarios, and further time synchronization between the multiple devices is easy to be achieved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for the description of the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a schematic flow chart of a multi-device timing method according to a first embodiment of the present invention.
Fig. 2 is a schematic diagram of a multi-device architecture when selecting a timing module for wireless spread spectrum communication according to a first embodiment of the present invention.
Fig. 3 is a schematic structural diagram of a multi-device timing system according to a second embodiment of the present invention.
Fig. 4 is a schematic flow chart of a device timing method according to a third embodiment of the present invention.
Fig. 5 is a schematic structural diagram of a timing device of an apparatus according to a fourth embodiment of the present invention.
Fig. 6 is a schematic diagram of the configuration of the acquisition module in fig. 5.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present invention, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
[ first embodiment ]
Referring to fig. 1, a first embodiment of the present invention provides a multi-device timing method, which is suitable for applying a system with multiple devices (such as multiple asynchronous playing boxes, but the present invention is not limited thereto), so as to achieve consistency or trend of consistency of system time of the multiple devices. The method comprises the following steps:
s101, acquiring, namely periodically acquiring target time by selecting one of a plurality of timing modules configured by the equipment.
Specifically, each device is configured with the same plurality of timing modules, one of the plurality of timing modules is selected, the target time is periodically acquired through the selected timing module, and the target time of each device is the same or substantially the same.
S102, setting the current system time according to the target time by each device in the time setting step.
Specifically, each device obtains the same target time through step S101, and pairs the system time of the device according to the target time, so that the system time of all devices is consistent.
The time synchronization of the multiple devices under various environments is realized by using multiple time correcting modules in a mixing way, and the purpose of time consistency of the multiple devices is realized. The correct time setting of the multiple devices can be achieved by selecting the appropriate one of the timing modules that it configures when the multiple devices are in different environments.
In one embodiment, the step of obtaining in S101 includes: and the plurality of devices respectively select a real-time clock timing module in the plurality of timing modules respectively configured, and the real-time clock timing module periodically acquires the time output by each real-time clock chip as the target time according to a third time interval.
Specifically, one of the plurality of timing modules is a real-time clock timing module, and the plurality of devices simultaneously select the real-time clock timing module. Firstly, each device periodically generates the target time according to the time output by a real-time clock chip of the device by a real-time clock timing module according to a third time interval; because the real-time clock chip has a certain error, the time output by the real-time clock chip needs to be corrected, the accuracy of the corrected time is greatly improved, the corrected time is taken as the target time, and the step of timing in the step S102 is executed.
Since the hardware error of the real-time clock chip cannot be eliminated, the output time of the real-time clock chip is periodically corrected at the third time interval, and the corrected time is taken as the target time. When the time of all the devices is equivalent to the accuracy of each time period, the time of all the devices reaches consistency, and the aim of multi-device time synchronization is fulfilled.
At present, the error of the real-time clock chip in one day is within ±2 seconds, so that the third time interval can be relatively long, for example, the acquisition step of S101 and the time setting step of S102 are executed in units of hours, and through a great amount of experiments by the inventor, the time setting requirement of multiple devices can be met by the third time interval of 1 hour.
The real-time clock timing module is a functional module realized in a software mode, and is an algorithm or a program capable of correcting the output time of the real-time clock chip.
In one embodiment, the step of obtaining in S101 includes: the plurality of devices respectively select a network time protocol timing module in the plurality of timing modules respectively configured, and the network time protocol timing module periodically receives time from the same time service as respective target time according to a second time interval.
Specifically, one of the plurality of timing modules is a network time protocol timing module. Multiple devices select the network time protocol timing module simultaneously. First, each device connects to the same time server, such as a national time service center server, through a network time protocol timing module, and periodically acquires the time of the time server at a second time interval, takes the time of the time server as the respective target time, and then performs the time setting step of S102. The time of all the devices is consistent with the time of the time server, and the time synchronization of multiple devices is realized.
When the network time protocol timing module is selected, the dependence of the mode on the network is great, in order to ensure the synchronization of the time of a plurality of devices and realize the time synchronization of the plurality of devices, the time of a time server is required to be frequently acquired by the network time protocol timing module as the target time, and the target time is set as the system time by the devices. The second time interval is thus set relatively short, in seconds, but cannot be set too short since too frequent access to the time server would consume more resources of the device system, which is set to at least 5 seconds through extensive experiments by the inventors.
The network time protocol timing module may be an internet interface, such as an ethernet interface, which can ensure that the device connects to the internet and accesses the time server.
In one embodiment, as shown in fig. 2, the step of obtaining in S101 includes: one of the plurality of devices serves as a master device 1, devices other than the master device 1 serve as slave devices 2, and the master device 1 transmits the current system time outwardly in a wireless spread spectrum communication manner; each slave device 2 selects a wireless spread spectrum communication timing module from the plurality of timing modules configured by itself, and the wireless spread spectrum communication timing module periodically acquires the current system time as the target time at a first time interval.
Specifically, one of the plurality of timing modules is a wireless spread spectrum communication timing module. Multiple devices simultaneously select a wireless spread spectrum communication timing module. Selecting one device from a plurality of devices as a master device 1, and the rest devices as slave devices 2 of the master device 1; the master device 1 transmits own system time outwards in a wireless spread spectrum communication mode through a wireless spread spectrum communication module, and each slave device 2 is within the wireless spread spectrum communication range of the master device 1 and can receive the system time; each of the slave devices 2 receives the system time through a wireless spread spectrum communication module and performs a time synchronization step of S102. The master device 1 may not perform the time-setting step of S102.
When the timing module of the wireless spread spectrum communication is selected, one master device with proper position is required to be selected, so that all slave devices can receive the system time sent by the master device through the wireless spread spectrum communication mode, the system time is the system time of the master device, and after all slave devices take the system time as target time and perform the time setting step through 102, the system time of all the slave devices is kept synchronous with the system time of the master device, thereby realizing the purpose of multi-device time setting.
On the other hand, the master device can also acquire the time of the time server through the network time protocol timing module, and the master device sends the server time through a wireless spread spectrum communication mode, and all slave devices of the master device receive the server time as the target time.
In still another aspect, the master device may further generate a time according to the output time of the real-time clock chip through the real-time clock timing module, and the master device sends the generated time through a wireless spread spectrum communication manner, where all slave devices of the master device accept the generated time as the target time.
Setting a master device and a slave device to perform master device and slave device pairing through a wireless spread spectrum communication timing module, and selecting a first time interval to take minutes as a unit, such as 2 minutes, for a large number of experiments by the inventor; if the first time interval is set to be shorter, the power consumption of the wireless spread spectrum communication timing module is larger, and if the first time interval is set to be longer, the accuracy of timing can be affected.
The timing module for wireless spread spectrum communication can select a Lora module, lora is an abbreviation of Long Range, which is a Long-distance wireless transmission technology based on a spread spectrum technology, and is also one of a plurality of LPWAN communication technologies, and LPWAN is an abbreviation of Low Power Wide Area Network (low power consumption wide area network). Of course, the Lora module can also be replaced by other wireless communication modules, such as a bluetooth module or a Wi-Fi module.
In one embodiment, the plurality of devices includes three timing modules, a wireless spread spectrum communication timing module, a network time protocol timing module, and a real-time clock timing module. When the timing module is selected, all the devices preferably select the wireless spread spectrum communication timing module; when all the devices cannot select the wireless spread spectrum communication timing module, selecting a network time protocol timing module; and when all the devices cannot select the wireless spread spectrum communication timing module and the wireless spread spectrum communication timing module, selecting the real-time clock timing module.
In particular, this mode may be implemented by means of manual selection and/or software selection. When the wireless spread spectrum communication timing module is realized in a manual selection mode, the first component, the second component and the third component are respectively corresponding to the wireless spread spectrum communication timing module, the network time protocol timing module and the real-time clock timing module; when the first component is triggered, a wireless spread spectrum communication timing module is selected, when the second component is triggered, a network time protocol timing module is selected, and when the third component is triggered, a real-time clock timing module is selected. When the method is realized in a software selection mode, the first judging component and the second judging component are respectively used for judging whether the wireless spread spectrum communication timing module can be selected or not and judging whether the network time protocol timing module can be selected or not, and then the proper timing module is selected by the software through the selection logic.
Further, the inventors conducted verification experiments for the above three embodiments as follows:
1. 40 pieces of equipment are distributed in a certain public place, wherein 39 pieces of equipment are distributed by taking 1 piece of equipment as the center; the 40 devices are provided with a wireless spread spectrum communication timing module, a network time protocol timing module and a real-time clock timing module. The 40 devices all select a wireless spread spectrum communication timing module, wherein the device at the central position is taken as a master device, the other 39 devices are taken as slave devices, and the first time period is selected to be 2 minutes. The system time of 40 devices was consistent over a week.
2. The existing 200 devices, the 200 devices are distributed in at least 1 city, the devices are separated by about 10 km, and the 200 devices are provided with a wireless spread spectrum communication timing module, a network time protocol timing module and a real-time clock timing module. 200 pieces of equipment all select a network time protocol timing module, the 200 pieces of equipment acquire time from a national time service center server and perform time synchronization, and the first time interval is selected to be 5 seconds. And observing the system time of 200 devices after one week.
3. 1000 existing devices, 1000 devices are distributed in a mountain area, the distance between the devices is about 50 km, and the 1000 devices are provided with a wireless spread spectrum communication timing module, a network time protocol timing module and a real-time clock timing module. The 1000 devices all select a real-time clock timing module, and the third time interval is 1 hour. The system time of 1000 devices was consistent over a 1 week period.
[ second embodiment ]
Referring to fig. 3, in a second embodiment of the present invention, a multi-device timing system is provided, where the multi-device timing system 10 includes a plurality of broadcasting devices 11, and each broadcasting device 11 includes a plurality of timing modules; each of the broadcasting apparatuses 11 selects one from a plurality of timing modules, and periodically acquires the target time at corresponding time intervals, and each of the broadcasting apparatuses sets its current system time according to the target time.
Specifically, each timing module is provided with a corresponding time interval.
The broadcasting device 11 may be a plurality of LED display screen asynchronous devices with an operating system (for example, an Android or Linux operating system, etc.) with higher time-setting requirements, for example, the broadcasting device 11 is an asynchronous broadcasting box. The asynchronous playing box comprises an embedded processor (such as a microprocessor based on ARM core) and a programmable logic device (such as an FPGA) connected with the embedded processor, and a plurality of timing modules.
In one embodiment, as shown in FIG. 3, the broadcast control device 11 includes a plurality of wireless spread spectrum communication timing modules 111, a network time protocol timing module 112, and a real-time clock timing module 113.
In one aspect, when the plurality of broadcasting devices 11 select the wireless spread spectrum communication timing module 111, the wireless spread spectrum communication timing module 111 periodically receives the external input time as the target time in a manner of wireless spread spectrum communication at a first time interval.
Specifically, the method comprises the following steps: one of the plurality of broadcasting devices 11 is selected as a master broadcasting device, the rest of the broadcasting devices 11 are slave broadcasting devices of the master broadcasting device, the master broadcasting device is ensured to send out own system time in a wireless spread spectrum communication mode, all the slave broadcasting devices periodically acquire the system time of the master broadcasting device through a wireless spread spectrum communication timing module 111 according to a first time interval, all the slave broadcasting devices take the system time of the master broadcasting device as target time of the slave broadcasting device, then all the slave broadcasting devices pair the system time of the slave broadcasting device according to the target time, and the consistency of all the slave broadcasting devices and the master broadcasting device time is ensured, so that the aim of pairing of the plurality of broadcasting devices 11 is achieved.
Specifically, the method further comprises the following steps: the time information is issued by a certain device in a wireless spread spectrum communication mode, the plurality of broadcasting devices 11 are all in a certain wireless spread spectrum communication range, the plurality of broadcasting devices 11 periodically acquire the time information through a wireless spread spectrum communication timing module 111 according to a first time interval, the time information is used as the target time, all the broadcasting devices 11 pair the system time according to the target time, all the broadcasting devices 11 are guaranteed to be consistent with the time information, and the aim of the pair synchronization of all the broadcasting devices 11 is achieved. The device has a wireless spread spectrum communication timing module 111 which is the same as that of all broadcasting devices 11, and the device is equivalent to the master broadcasting device 11 in the above mode, and the time of the device issued by the wireless spread spectrum communication mode can be the system time or the self-set time; for example, a device is a computer configured with a wireless spread spectrum communication timing module 111.
The wireless spread spectrum communication timing module 111 and the first time interval have been described in the first embodiment and will not be described in detail here.
On the other hand, when the plurality of broadcasting devices 11 select the network time protocol timing module 112, the network time protocol timing module 112 periodically receives time from the same time server at the second time interval as the target time.
Specifically, all broadcasting devices 11 access the same time server, for example, a national time service center server, through the network time protocol timing module 112, all broadcasting devices 11 periodically receive time from the same time service according to a second time interval through the network time protocol timing module 112, the time is taken as a target time, and then all broadcasting devices 11 pair the own system time according to the target time, so that the synchronization of a plurality of broadcasting devices 11 is realized.
The network time protocol timing module 112 and the second time period have been described in the first embodiment and will not be described in detail here.
In still another aspect, when the plurality of broadcasting devices 11 select the real-time clock timing module 113, the real-time clock timing module 113 is connected to the real-time clock chip of the broadcasting device 11, and the real-time clock timing module 113 periodically generates the target time according to the time output by the real-time clock chip at a third time interval.
Specifically, all the broadcasting devices 11 periodically correct the time output by the real-time clock chip through the real-time clock timing module 113 according to the third time interval to obtain corrected time, the corrected time is used as the target time, and then all the broadcasting devices 11 pair the own system time according to the target time, so that the synchronization of a plurality of broadcasting devices 11 is realized.
The real-time clock timing module 113 and the third time period have been described in detail in the first embodiment, and will not be described here.
[ third embodiment ]
Referring to fig. 4, a third embodiment of the present invention provides a device timing method, which includes the following steps:
s103, an acquisition step, namely selecting one from a plurality of timing modules, and periodically acquiring target time by the selected timing module;
the timing modules comprise a plurality of wireless spread spectrum communication timing modules, a network time protocol timing module and a real-time clock timing module;
s1031, when a wireless spread spectrum communication timing module is selected, the wireless spread spectrum communication timing module is used for periodically receiving the time of external output in a wireless spread spectrum communication mode as the target time according to a first time interval;
s1032, when the network time protocol timing module is selected, the network time protocol timing module is used for periodically receiving time from the time server as the target time according to the second time interval;
s1033, when the real-time clock timing module is selected, wherein the real-time clock timing module is connected with the real-time clock chip, and the real-time clock timing module is used for periodically generating the target time according to the output time of the real-time clock chip at a third time interval.
S104, the device sets the current system time of the device according to the target time obtained in S103, and the time setting is completed.
Specifically, the manner in which the device obtains the target time through the wireless spread spectrum communication timing module, obtains the target time through the network time protocol timing module, and obtains the target time through the real-time clock timing module, which are both described in detail in the first embodiment and the second embodiment, and will not be described here.
In one embodiment, the first time interval is less than the third time interval and greater than the second time interval.
Specifically, the first time interval, the second time interval, and the third time interval are all described in detail in the first embodiment, and will not be described here.
[ fourth embodiment ]
Referring to fig. 5, which is a fourth embodiment of the present invention, there is provided an apparatus timing device 20, including: an acquisition module 21 and a time synchronization module 22.
An acquisition module 21, configured to select one from a plurality of timing modules configured to periodically acquire a target time.
As shown in fig. 6, the acquisition module 21 includes a plurality, e.g., two or three, of a wireless spread spectrum communication timing module 211, a network time protocol timing module 212, and a real-time clock timing module 213.
When the wireless spread spectrum communication timing module 211 is selected, the wireless spread spectrum communication timing module 211 periodically accepts the time of the external input in a wireless spread spectrum communication mode according to a first time interval, and takes the time of the external input as the target time.
Wherein when the network time protocol timing module 212 is selected, the network time protocol timing module 212 periodically receives time from the time server at a second time interval and takes the received time as the target time.
When the real-time clock timing module 213 is selected, the real-time clock timing module 213 is connected to the real-time clock chip, and the real-time clock timing module 213 generates the target time according to the time output by the real-time clock chip at a third time interval.
Specifically, the manner in which the device acquires the target time through the wireless spread spectrum communication timing module 211, acquires the target time through the network time protocol timing module 212, and acquires the target time through the real-time clock timing module 213 is described in detail in the first embodiment, and will not be described here.
In one embodiment, the first time interval is less than the third time interval and greater than the second time interval.
Specifically, the first time interval, the second time interval, and the third time interval are all described in detail in the first embodiment, and will not be described here.
In the several embodiments provided in the present invention, it should be understood that the disclosed systems, devices, and methods may be implemented in other manners. For example, the apparatus embodiments described above are merely illustrative, e.g., the partitioning of elements is merely a logical functional partitioning, and there may be additional partitioning in actual implementation, e.g., multiple elements or components may be combined or integrated into another system, or some features may be omitted, or not implemented. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be an indirect coupling or communication connection via some interfaces, devices or units, which may be in electrical, mechanical or other form.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in the embodiments of the present invention may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit. The integrated units may be implemented in hardware or in hardware plus software functional units.
The integrated units implemented in the form of software functional units described above may be stored in a computer readable storage medium. The software functional unit is stored in a storage medium, and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to perform part of the steps of the methods according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a random access Memory (Random Access Memory, RAM), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
Finally, it should be noted that: the above embodiments are only for illustrating the technical solution of the present invention, and are not limiting; although the invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical scheme described in the foregoing embodiments can be modified or some technical features thereof can be replaced by equivalents; such modifications and substitutions do not depart from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims (10)

1. A multi-device timing method, adapted to be applied to a system comprising a plurality of devices; the multi-device timing method comprises the following steps:
an acquisition step, wherein each device selects one of a plurality of timing modules configured by the device to periodically acquire target time; and
setting the current system time according to the target time by each device;
the timing modules comprise a plurality of real-time clock timing modules, a network time protocol timing module and a wireless spread spectrum communication timing module;
wherein the obtaining step includes:
the plurality of devices respectively select the wireless spread spectrum modules configured by the devices to perform multi-device timing, one of the plurality of devices is used as a master device, and devices except the master device in the plurality of devices are used as slave devices;
the master device obtains the time of a time server through the network time protocol timing module and sends the time of the time server through a wireless spread spectrum communication mode; each slave device receives the time of the time server as the target time; or alternatively, the process may be performed,
the master device obtains the generation time through the real-time clock timing module and sends the generation time through the wireless spread spectrum communication mode; each of the slave devices receives the generated time as the target time;
responding to the fact that the plurality of devices cannot select the self-configured wireless spread spectrum communication timing module to perform multi-device timing, the plurality of devices respectively select the self-configured network time protocol timing module, and the plurality of devices respectively periodically acquire the target time through the self-configured network time protocol timing module;
responding to the fact that the plurality of devices cannot select the self-configured wireless spread spectrum communication timing module to perform multi-device timing, and the plurality of devices cannot select the self-configured network time protocol timing module to acquire the target time, the plurality of devices respectively select the self-configured real-time clock timing module, and the plurality of devices respectively acquire generation time periodically through the self-configured real-time clock timing module and take the generation time as the target time;
the real-time clock timing module periodically acquires output time, and corrects the output time to acquire the generation time.
2. The multi-device timing method as set forth in claim 1, wherein said obtaining step includes:
responding to the plurality of devices to respectively select the real-time clock timing modules in the plurality of timing modules which are respectively configured, wherein the real-time clock timing module of each device is connected with a real-time clock chip of the device, and the real-time clock timing module periodically acquires the output time according to the time of the respective real-time clock chip according to a third time interval.
3. The multi-device timing method as set forth in claim 1, wherein said obtaining step includes:
and in response to the plurality of devices respectively selecting the network time protocol timing modules of the plurality of timing modules respectively configured, periodically receiving time from the same time server as the respective target time at a second time interval.
4. The multi-device timing method as set forth in claim 1, wherein said obtaining step includes:
the master device selects the wireless spread spectrum communication timing module in the timing modules configured by the master device and sends out the current system time in the wireless spread spectrum communication mode;
each slave device selects a wireless spread spectrum communication timing module in the plurality of timing modules configured by the slave device, and the wireless spread spectrum communication timing module periodically acquires the current system time sent outwards by the master device as the target time according to a first time interval.
5. A device timing system, comprising:
a plurality of broadcasting devices;
each broadcasting device is provided with a plurality of timing modules;
when each broadcasting device performs the acquisition operation, a plurality of timing modules configured by the broadcasting device are respectively used for periodically acquiring target time at different time intervals when being selected in an alternative mode; and
setting current system time according to the target time when each broadcasting device performs time setting operation;
the timing modules comprise a plurality of real-time clock timing modules, a network time protocol timing module and a wireless spread spectrum communication timing module;
each broadcasting control device comprises:
when the wireless spread spectrum modules configured by the broadcasting devices are selected to perform multi-device calibration, one of the broadcasting devices is used as a master broadcasting device, and broadcasting devices except the master broadcasting device are used as slave broadcasting devices;
the master broadcasting equipment acquires the time of a time server through the network time protocol timing module and transmits the time of the time server through a wireless spread spectrum communication mode; each slave broadcasting device receives the time of the time server as the target time; or alternatively, the process may be performed,
the main broadcasting control equipment acquires generation time through the real-time clock timing module and sends the generation time through the wireless spread spectrum communication mode; each slave control device receives the generated time as the target time;
the broadcasting devices can not select the self-configured wireless spread spectrum communication timing module to perform multi-broadcasting device timing, the broadcasting devices respectively select the self-configured network time protocol timing module, and the broadcasting devices respectively obtain the target time periodically through the self-configured network time protocol timing module;
the broadcasting devices cannot select the self-configured wireless spread spectrum communication timing module to perform multi-broadcasting device timing, the broadcasting devices cannot select the self-configured network time protocol timing module to acquire the target time, the broadcasting devices respectively select the self-configured real-time clock timing module, and the broadcasting devices respectively acquire the generation time periodically through the self-configured real-time clock timing module and take the generation time as the target time;
the real-time clock timing module periodically acquires output time, and corrects the output time to acquire the generation time.
6. The device timing system of claim 5, wherein,
the real-time clock timing module is connected with the real-time clock chip and is used for periodically acquiring the output time according to the output time of the real-time clock chip at a third time interval when being selected;
the network time protocol timing module is configured to periodically receive time from the time server as the target time at a second time interval when selected,
the time correction module is used for periodically receiving the time input from the outside in a wireless spread spectrum communication mode according to a first time interval when the time is selected as the target time;
wherein the first time interval is less than the third time interval and greater than the second time interval.
7. A method for calibrating a device, comprising:
an acquisition step of periodically acquiring target time when a plurality of timing modules are selected in an alternative way, wherein the plurality of timing modules comprise a plurality of real-time clock timing modules, a network time protocol timing module and a wireless spread spectrum communication timing module, the real-time clock timing modules are connected with a real-time clock chip and are used for periodically generating the target time according to the output time of the real-time clock chip according to a third time interval, the network time protocol timing module is used for periodically receiving time from a time server according to a second time interval as the target time, and the wireless spread spectrum communication timing module is used for periodically receiving externally input time according to a first time interval as the target time in a wireless spread spectrum communication way; and
setting time setting, namely setting current system time according to the target time;
wherein the obtaining step includes:
the plurality of devices respectively select the wireless spread spectrum modules configured by the devices to perform multi-device timing, one of the plurality of devices is used as a master device, and devices except the master device in the plurality of devices are used as slave devices;
the master device obtains the time of a time server through the network time protocol timing module and sends the time of the time server through a wireless spread spectrum communication mode; each slave device receives the time of the time server as the target time; or alternatively, the process may be performed,
the master device obtains the generation time through the real-time clock timing module and sends the generation time through the wireless spread spectrum communication mode; each of the slave devices receives the generated time as the target time;
responding to the fact that the plurality of devices cannot select the self-configured wireless spread spectrum communication timing module to perform multi-device timing, the plurality of devices respectively select the self-configured network time protocol timing module, and the plurality of devices respectively periodically acquire the target time through the self-configured network time protocol timing module;
responding to the fact that the plurality of devices cannot select the self-configured wireless spread spectrum communication timing module to perform multi-device timing, and the plurality of devices cannot select the self-configured network time protocol timing module to acquire the target time, the plurality of devices respectively select the self-configured real-time clock timing module, and the plurality of devices respectively acquire generation time periodically through the self-configured real-time clock timing module and take the generation time as the target time;
the real-time clock timing module periodically acquires output time, and corrects the output time to acquire the generation time.
8. The device timing method as set forth in claim 7, wherein said first time interval is less than said third time interval and greater than said second time interval.
9. A device timing apparatus, comprising:
an acquisition module configured to periodically acquire a target time when selected in a selective manner, wherein the plurality of timing modules include a plurality of real-time clock timing modules, a network time protocol timing module, and a wireless spread spectrum communication timing module, the real-time clock timing module being connected to a real-time clock chip and configured to periodically generate the target time according to a time output from the real-time clock chip at a third time interval when selected, the network time protocol timing module being configured to periodically receive a time from a time server at the second time interval as the target time when selected, and the wireless spread spectrum communication timing module being configured to periodically receive an externally input time as the target time at a first time interval when selected; and
the time setting module sets the current system time according to the target time;
wherein, the acquisition module is further used for: the plurality of devices respectively select the wireless spread spectrum modules configured by the devices to perform multi-device timing, one of the plurality of devices is used as a master device, and devices except the master device in the plurality of devices are used as slave devices; the master device obtains the time of a time server through the network time protocol timing module and sends the time of the time server through a wireless spread spectrum communication mode; each slave device receives the time of the time server as the target time; or the master device obtains the generation time through the real-time clock timing module and sends the generation time through the wireless spread spectrum communication mode; each of the slave devices receives the generated time as the target time; the plurality of devices cannot select the self-configured wireless spread spectrum communication timing module to perform multi-device timing, the plurality of devices respectively select the self-configured network time protocol timing module, and the plurality of devices respectively periodically acquire the target time through the self-configured network time protocol timing module; the plurality of devices cannot select the self-configured wireless spread spectrum communication timing module to perform multi-device timing, the plurality of devices cannot select the self-configured network time protocol timing module to acquire the target time, the plurality of devices respectively select the self-configured real-time clock timing module, and the plurality of devices respectively acquire the generation time periodically through the self-configured real-time clock timing module and take the generation time as the target time; the real-time clock timing module periodically acquires output time, and corrects the output time to acquire the generation time.
10. The device timing apparatus of claim 9, wherein the first time interval is less than the third time interval and greater than the second time interval.
CN201910258077.1A 2019-04-01 2019-04-01 Multi-device timing method and system and device timing method and device Active CN111769895B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910258077.1A CN111769895B (en) 2019-04-01 2019-04-01 Multi-device timing method and system and device timing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910258077.1A CN111769895B (en) 2019-04-01 2019-04-01 Multi-device timing method and system and device timing method and device

Publications (2)

Publication Number Publication Date
CN111769895A CN111769895A (en) 2020-10-13
CN111769895B true CN111769895B (en) 2023-09-12

Family

ID=72718822

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910258077.1A Active CN111769895B (en) 2019-04-01 2019-04-01 Multi-device timing method and system and device timing method and device

Country Status (1)

Country Link
CN (1) CN111769895B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114390492A (en) * 2020-10-20 2022-04-22 Oppo广东移动通信有限公司 Timing method, device, equipment and storage medium
CN113176742A (en) * 2021-03-24 2021-07-27 广东芬尼克兹节能设备有限公司 Centralized control method and device among multiple devices

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103389890A (en) * 2013-07-19 2013-11-13 西安诺瓦电子科技有限公司 Playing control device, and multi-display terminal synchronous playing control system and method
CN205017341U (en) * 2015-10-22 2016-02-03 贵州电网有限责任公司电力调度控制中心 Synchronous timing device of multi -mode
CN106912100A (en) * 2017-03-14 2017-06-30 东北大学 Appliance network method for synchronizing time based on TPSN and TSync
CN108847913A (en) * 2018-06-28 2018-11-20 深圳市欧瑞博科技有限公司 A kind of smart machine and its method of time service

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9794903B2 (en) * 2013-09-23 2017-10-17 Ziva Corp. Synchronization of distributed nodes

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103389890A (en) * 2013-07-19 2013-11-13 西安诺瓦电子科技有限公司 Playing control device, and multi-display terminal synchronous playing control system and method
CN205017341U (en) * 2015-10-22 2016-02-03 贵州电网有限责任公司电力调度控制中心 Synchronous timing device of multi -mode
CN106912100A (en) * 2017-03-14 2017-06-30 东北大学 Appliance network method for synchronizing time based on TPSN and TSync
CN108847913A (en) * 2018-06-28 2018-11-20 深圳市欧瑞博科技有限公司 A kind of smart machine and its method of time service

Also Published As

Publication number Publication date
CN111769895A (en) 2020-10-13

Similar Documents

Publication Publication Date Title
US11659510B2 (en) Clock synchronisation between devices using message timestamps
US8705578B2 (en) Method and system for implementing time synchronization in local area network (LAN)
JP5913596B2 (en) Method and apparatus for wireless network time synchronization
US10560361B2 (en) Distributed database for synchronizing the accessibility of nodes and shared devices
US9514073B2 (en) Device and method for global time information in event-controlled bus communication
CN111769895B (en) Multi-device timing method and system and device timing method and device
JP2012074799A (en) Communication system, communication interface device, and synchronization method
US20170195076A1 (en) Clock Synchronization Method and Apparatus
JP7401656B2 (en) METHODS, APPARATUS AND SYSTEM AND STORAGE MEDIA FOR SELECTING CLOCK SOURCES
CN102035638A (en) Clock source selection processing method, device and system
CN112787742B (en) Clock synchronization method and device, wireless earphone and readable storage medium
CN110679184B (en) Method and device for providing timing for communication network
CN110830138B (en) Information processing method, electronic equipment and server
CN107547160B (en) A kind of method for synchronizing time and device
CN113541842B (en) Multi-shooting range system time synchronization method and device
CN112511255B (en) Time synchronization method and device
CN102983959B (en) Method for realizing one-step mode and two-step mode for PTP (precision time synchronization protocol) in a plurality of MAC
GB2454937A (en) Acquiring time references for a telecommunications basestation from a time server
JP6490971B2 (en) Time synchronization system
JP6503271B2 (en) Time synchronization system
CN104980265B (en) System whens for that will the wait method synchronous with supervisory clock system
JP2018157340A (en) Radio communication device, program, and method
EP3972160B1 (en) Time synchronization method, service board, and network device
TWM518437U (en) Clock synchronization system of power management
JP2024053608A (en) Time synchronization device, time synchronization method, and time synchronization program

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
CB02 Change of applicant information

Address after: 710075 DEF101, Zero One Square, Xi'an Software Park, No. 72 Zhangbajie Science and Technology Second Road, Xi'an High-tech Zone, Shaanxi Province

Applicant after: XI'AN NOVASTAR TECH Co.,Ltd.

Address before: 710075 DEF101, Zero One Square, Xi'an Software Park, No. 72 Zhangbajie Science and Technology Second Road, Xi'an High-tech Zone, Shaanxi Province

Applicant before: Xi'an NovaStar Tech Co.,Ltd.

CB02 Change of applicant information
GR01 Patent grant
GR01 Patent grant