CN113727429A - Cross-network-group clock synchronization method and device, storage medium and terminal - Google Patents

Cross-network-group clock synchronization method and device, storage medium and terminal Download PDF

Info

Publication number
CN113727429A
CN113727429A CN202110996696.8A CN202110996696A CN113727429A CN 113727429 A CN113727429 A CN 113727429A CN 202110996696 A CN202110996696 A CN 202110996696A CN 113727429 A CN113727429 A CN 113727429A
Authority
CN
China
Prior art keywords
identification number
equipment
network group
target network
synchronization
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202110996696.8A
Other languages
Chinese (zh)
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.)
Shanghai Yogo Robot Co Ltd
Original Assignee
Shanghai Yogo Robot 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 Shanghai Yogo Robot Co Ltd filed Critical Shanghai Yogo Robot Co Ltd
Priority to CN202110996696.8A priority Critical patent/CN113727429A/en
Publication of CN113727429A publication Critical patent/CN113727429A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W56/00Synchronisation arrangements
    • H04W56/001Synchronization between nodes
    • H04W56/0015Synchronization between nodes one node acting as a reference for the others
    • 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

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Mobile Radio Communication Systems (AREA)

Abstract

The invention discloses a clock synchronization method, a clock synchronization device, a storage medium and a terminal for cross-network groups, wherein the method comprises the following steps: when the device enters any one of a plurality of network groups established based on a TDMA protocol, acquiring a main device identification number from the broadcast of the target network group; comparing the first identification number of the equipment with the identification number of the main equipment, judging whether the equipment is the new main equipment of the target network group, and if not, carrying out time sequence synchronization according to the clock and the time sequence synchronization rule of the current main equipment; if yes, main equipment marking is carried out on the first identification number, and all equipment of the target network group is driven to carry out time sequence synchronization by taking the equipment as new main equipment. Based on the clock synchronization method of the invention, after the equipment reaches the network node for the first time and is synchronized, the network can store the optimal synchronization time sequence, and when the equipment enters again, the equipment can directly start to send data in a broadcast mode without synchronization again, thereby saving network resources and improving communication efficiency.

Description

Cross-network-group clock synchronization method and device, storage medium and terminal
[ technical field ] A method for producing a semiconductor device
The present invention relates to the field of near field communication, and in particular, to a method and an apparatus for clock synchronization across network groups, a storage medium, and a terminal.
[ background of the invention ]
In the near field communication networking, a plurality of devices form a near field network in a TDMA mode, namely a network group is formed, and the time sequence of the devices in the network group is synchronized. In the prior art, there is a master device in each network group, all slave devices need to perform timing synchronization with the master device, and the generation rules of the master devices are different, so that the entire network group resynchronization exists in communication across the network groups. That is, in an actual application scenario, if a device needs to move between network groups, the whole network group needs to resynchronize a clock once every time the device enters the network group, which is inefficient and consumes a large amount of resources in the network group.
[ summary of the invention ]
The invention provides a clock synchronization method, a clock synchronization device, a clock synchronization storage medium and a clock synchronization terminal for cross-network groups, which solve the technical problems of high resource consumption and low efficiency.
The technical scheme for solving the technical problems is as follows: a method of clock synchronization across a network group, comprising the steps of:
step 1, acquiring an identification number generation rule, a master equipment generation rule and a time sequence synchronization rule which are commonly adopted by a plurality of network groups established based on a TDMA protocol;
step 2, generating a first identification number of the cost device by adopting the identification number generation rule;
step 3, when the device enters any one target network group in the multiple network groups established based on the TDMA protocol, acquiring a corresponding main device identification number from the broadcast of the target network group;
step 4, comparing the first identification number with the identification number of the main device, and judging whether the device is a new main device of the target network group according to a comparison result and the main device generation rule, if not, executing step 5, and if so, executing step 6;
step 5, performing time sequence synchronization to the target network group according to the clock of the current master device and the time sequence synchronization rule;
and 6, marking the first identification number by master equipment, broadcasting in the target network group to drive all the equipment of the target network group to update the current master equipment identification number to the first identification number, and performing time sequence synchronization by taking the equipment as new master equipment.
In a preferred embodiment, the method further comprises a communication step, specifically: and storing the current main equipment identification number of the target network group in a local place, and broadcasting the first identification number of the current main equipment identification number and the current main equipment identification number corresponding to the network group in communication.
In a preferred embodiment, the method further comprises a step of crossing the network, specifically comprising:
step 7, when the device moves out of a first target network group of the plurality of network groups and enters a second target network group of the plurality of network groups, acquiring a corresponding main device identification number A from the broadcast of the second target network group;
step 8, comparing the current master equipment identification number B of the equipment with the master equipment identification number A of the second target network group, and judging whether to update the current master equipment of the second target network group according to the comparison result and the master equipment generation rule, if not, executing step 9, and if so, executing step 10;
step 9, performing timing synchronization to the second target network group according to the clock of the current master device in the second target network group and the timing synchronization rule;
and step 10, marking the current master equipment identification number B of the equipment by master equipment, broadcasting in the second target network group to drive all the equipment of the second target network group to update the stored master equipment identification number A to be the current master equipment identification number B of the equipment, and performing time sequence synchronization by taking the equipment as new master equipment.
In a preferred embodiment, the identification number generation rule is: and generating an identification number uniquely corresponding to each device according to the random number, the CPU serial number of the device in the network group and/or the configuration parameters of the device.
In a preferred embodiment, the master device generates rules as follows: and sequencing the plurality of devices of each network group according to the sequence of the identification numbers from large to small, and taking the device with the largest identification number in each network group as the main device of the corresponding network group.
In a preferred embodiment, the timing synchronization rule is: and taking the clock of the master device as zero time, and sequencing the slave devices of the corresponding network group in different time slots according to the size sequence of the identification numbers so as to complete the time sequence synchronization of the corresponding network group.
A second aspect of the embodiments of the present invention provides a clock synchronization apparatus across a network group, including a first obtaining module, an identification number generating module, a second obtaining module, a first determining module, and a first synchronization module,
the first acquisition module is used for acquiring an identification number generation rule, a master equipment generation rule and a time sequence synchronization rule which are commonly adopted by a plurality of network groups established on the basis of a TDMA protocol;
the identification number generation module is used for generating a first identification number of the cost device by adopting the identification number generation rule;
the second obtaining module is used for obtaining a corresponding main equipment identification number from the broadcast of a target network group when the equipment enters any one of a plurality of network groups established based on a TDMA protocol;
the first judging module is used for comparing the first identification number with the identification number of the main equipment, judging whether the equipment is the new main equipment of the target network group or not according to the comparison result and the main equipment generating rule, and if not, driving the first synchronization module to carry out time sequence synchronization on the target network group according to the clock of the current main equipment and the time sequence synchronization rule; if yes, the first synchronization module is driven to carry out main equipment marking on the first identification number, the first identification number is broadcasted in the target network group, all equipment of the target network group is driven to update the current main equipment identification number to be the first identification number, and the equipment is used as new main equipment to carry out time sequence synchronization.
In a preferred embodiment, the system further comprises a third acquiring module, a second judging module and a second synchronizing module,
the third obtaining module is configured to obtain a corresponding master device identification number a from a broadcast of a second target network group when the device moves out of the first target network group of the multiple network groups and enters the second target network group of the multiple network groups;
the second judging module is used for comparing a current master equipment identification number B of the equipment with a master equipment identification number A of the second target network group, judging whether to update the current master equipment of the second target network group according to a comparison result and the master equipment generating rule, and if not, driving the second synchronizing module to perform time sequence synchronization on the second target network group according to a clock of the current master equipment in the second target network group and the time sequence synchronization rule; if yes, the second synchronization module is driven to carry out main equipment marking on the current main equipment identification number B of the equipment, the second target network group broadcasts, all the equipment of the second target network group are driven to update the stored main equipment identification number A to be the current main equipment identification number B of the equipment, and the equipment is used as new main equipment to carry out time sequence synchronization.
A third aspect of embodiments of the present invention provides a computer-readable storage medium storing a computer program, which when executed by a processor, implements the above-described method for clock synchronization across network groups.
A fourth aspect of the embodiments of the present invention provides a terminal, including the computer-readable storage medium and a processor, where the processor implements the steps of the above method for clock synchronization across network groups when executing a computer program on the computer-readable storage medium.
The invention provides a clock synchronization method, a clock synchronization device, a storage medium and a terminal of a cross-network group.
In order to make the aforementioned and other objects, features and advantages of the present invention comprehensible, preferred embodiments accompanied with figures are described in detail below.
[ description of the drawings ]
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings needed to be used in the embodiments will be briefly described below, it should be understood that the following drawings only illustrate some embodiments of the present invention and therefore should not be considered as limiting the scope, and for those skilled in the art, other related drawings can be obtained according to the drawings without inventive efforts.
FIG. 1 is a flow diagram of a method for clock synchronization across a network group in one embodiment;
FIG. 2 is a block diagram of a clock synchronization apparatus across a network group in one embodiment;
fig. 3 is an internal structural diagram of the terminal in one embodiment.
[ detailed description ] embodiments
In order to make the objects, technical solutions and advantageous effects of the present invention more clearly apparent, the present invention is further described in detail below with reference to the accompanying drawings and the detailed description. It should be understood that the detailed description and specific examples, while indicating the preferred embodiment of the invention, are intended for purposes of illustration only and are not intended to limit the scope of the invention.
In an embodiment, as shown in fig. 1, a flowchart of a method for clock synchronization across network groups is provided, where the present embodiment is described by taking the method as an example for a target mobile robot, and includes the following steps:
step 1, a target mobile robot acquires an identification number generation rule, a master equipment generation rule and a time sequence synchronization rule which are commonly adopted by a plurality of network groups established on the basis of a TDMA protocol.
In a specific embodiment, each mobile robot generates an identification number based on the same identification number generation rule, and the identification number is globally unique, that is, the identification numbers of any two mobile robots are different and the identification number remains unchanged in the communication process. Then, the mobile robots give up the master device according to a preset master device generation rule during networking, and meanwhile, other slave devices perform time sequence synchronization to the master device according to a preset time sequence synchronization rule. After synchronization is completed, each mobile robot in the network stores the master device identification number of the master device locally and broadcasts in real time in the communication, and the broadcast can be marked as XID.
The identification number generation rule, the master device generation rule and the timing synchronization rule can be set according to actual needs, but the identification number generation rules, the master device generation rules and the timing synchronization rules of all network groups are completely the same and are consistent in the whole communication process.
In a preferred embodiment, the identification number generation rule is: and generating an identification number uniquely corresponding to each device according to the random number, the CPU serial number of the device in the network group and/or the configuration parameters of the device. In an optional embodiment, the multiple devices in each network group are sorted according to the descending order of the absolute value of the identification number, and the device with the largest identification number in each network group is taken as the master device of the corresponding network group. Then, the clock of the master device is used as zero time, and the slave devices of the corresponding network group are sequenced in different time slots according to the size sequence of the identification numbers, so as to complete the time sequence synchronization of the corresponding network group.
And then executing step 2, and generating the first identification number of the cost device by the target mobile robot by adopting the identification number generation rule.
And 3, when the target mobile robot enters any one of the plurality of network groups established based on the TDMA protocol, acquiring the corresponding main equipment identification number, namely XID information from the broadcast of the target network group.
And then executing step 4, comparing the first identification number with the identification number of the main device, judging whether the device is a new main device of the target network group according to the comparison result and the main device generation rule, and executing step 5 and step 6.
In step 5 of a preferred embodiment, when the identification number of the master device of the target network is greater than the first identification number of the device, the master device of the target network does not need to be updated, and the target mobile robot performs timing synchronization on the target network group according to the clock of the current master device in the target network and the timing synchronization rule. In step 6 of a preferred embodiment, when the master device identification number of the target network is smaller than the first identification number of the device, the target mobile robot performs master device tagging on the first identification number of the target mobile robot, broadcasts the first identification number in the target network group, and after all devices, that is, other mobile robots, of the target network group receive the broadcast, updates the first identification number of the target mobile robot to a new master device identification number XID, and performs timing synchronization by using the target mobile robot as a new master device.
At this time, the target mobile robot enters the target network, and can communicate with other mobile robots or other devices in the target network. In the communication process, the target mobile robot stores the current main equipment identification number of the target network group locally as other equipment, and broadcasts the first identification number of the target mobile robot and the current main equipment identification number corresponding to the network group in communication.
In a preferred embodiment, when the target mobile robot moves out of a first target network group of the plurality of network groups and enters a second target network group of the plurality of network groups, the method comprises the steps of:
and 7, the target mobile robot acquires the corresponding main equipment identification number A from the broadcast of the second target network group. When the target mobile robot moves out of the first target network group and enters the second target network group, the broadcast of the second target network group is received, and the broadcast contains the main equipment identification number information of the second target network group, namely the XID information.
Step 8, the target mobile robot compares the current master device identification number B of the device (i.e. the master device identification number B of the first target network group) with the master device identification number a of the second target network group, determines whether to update the current master device of the second target network group according to the comparison result and the master device generation rule, and executes step 9 and step 10.
In step 9 of a preferred embodiment, when the current master device identification number B of the target mobile robot is smaller than the master device identification number a of the second target network group, the target mobile robot performs timing synchronization to the second target network group according to the clock of the current master device in the second target network group and the timing synchronization rule, and at this time, the XID of the target robot, that is, the current master device identification number, is changed to the master device identification number a of the second target network group.
When the target mobile robot crosses the network again, namely the target mobile robot moves out of the second target network group and re-enters the first target network group, the XID synchronization of the network group 1 and the network group 2 can be completed by repeating the steps, and the time sequence synchronization problem during the communication of the cross-multi network groups is completed.
In step 10 of a preferred embodiment, when the current master id number B of the target mobile robot is greater than the master id number a of the second target network group, the target mobile robot performs master tagging on its current master id number B, and broadcasts in the second target network group, drives all mobile robots of the second target network group to update the stored master id number a to the current master id number B of the target mobile robot, and performs timing synchronization with the target mobile robot as a new master, that is, the XID of the second target network group is changed to the current XID of the target mobile robot, that is, the XID of the first target network group.
At this time, when the target mobile robot crosses the network again, that is, moves out of the second target network group and reenters the first target network group, the XID of the target mobile robot is not changed, so that the target mobile robot can directly enter the first target network group. And because the first target network group and the second target network group are synchronized to the same XID at present, all the devices of the first target network group and the second target network group can be accessed to the network for communication at any time if the devices move across networks.
The above embodiments provide a clock synchronization method across network groups, where after a device reaches a network node for the first time and performs synchronization, the network stores an optimal synchronization timing sequence, and when the device enters again, the device can directly start to send data in a broadcast mode without resynchronization, thereby saving network resources and improving communication efficiency.
It should be understood that, the sequence numbers of the steps in the foregoing embodiments do not imply an execution sequence, and the execution sequence of each process should be determined by its function and inherent logic, and should not constitute any limitation to the implementation process of the embodiments of the present invention.
Fig. 2 is a schematic structural diagram of a clock synchronization apparatus across network groups according to another embodiment of the present invention, as shown in fig. 2, including a first obtaining module 100, an identification number generating module 200, a second obtaining module 300, a first determining module 400, and a first synchronization module 500,
the first obtaining module 100 is configured to obtain an identification number generation rule, a master device generation rule, and a timing synchronization rule that are commonly used by a plurality of network groups established based on a TDMA protocol;
the identification number generation module 200 is configured to generate a first identification number of the cost device by using the identification number generation rule;
the second obtaining module 300 is configured to obtain a corresponding master device identification number from a broadcast of a target network group when the device enters any target network group in a plurality of network groups established based on a TDMA protocol;
the first determining module 400 compares the first identification number with the identification number of the master device, and determines whether the device is a new master device of the target network group according to the comparison result and the master device generation rule, if not, the first synchronizing module 500 is driven to perform timing synchronization on the target network group according to the clock of the current master device and the timing synchronization rule; if yes, the first synchronization module 500 is driven to perform master device marking on the first identification number, and broadcast in the target network group, so as to drive all devices of the target network group to update the current master device identification number to the first identification number, and perform time sequence synchronization by using the device as a new master device.
In a preferred embodiment, the clock synchronization apparatus further includes a communication module, where the communication module is specifically similar to locally storing the current master device identification number of the target network group, and broadcasts the first identification number of the communication module and the current master device identification number corresponding to the network group in communication at the same time.
In a preferred embodiment, the clock synchronization apparatus further includes a cross-network module, which specifically includes a third obtaining module, a second determining module and a second synchronization module,
the third obtaining module is configured to obtain a corresponding master device identification number a from a broadcast of a second target network group when the device moves out of the first target network group of the multiple network groups and enters the second target network group of the multiple network groups;
the second judging module is used for comparing a current master equipment identification number B of the equipment with a master equipment identification number A of the second target network group, judging whether to update the current master equipment of the second target network group according to a comparison result and the master equipment generating rule, and if not, driving the second synchronizing module to perform time sequence synchronization on the second target network group according to a clock of the current master equipment in the second target network group and the time sequence synchronization rule; if yes, the second synchronization module is driven to carry out main equipment marking on the current main equipment identification number B of the equipment, the second target network group broadcasts, all the equipment of the second target network group are driven to update the stored main equipment identification number A to be the current main equipment identification number B of the equipment, and the equipment is used as new main equipment to carry out time sequence synchronization.
The above embodiments provide a clock synchronization apparatus across network groups, where after a device reaches a network node for the first time and performs synchronization, the network stores an optimal synchronization timing sequence, and when the device enters again, the device can directly start to send data in a broadcast mode without resynchronization, thereby saving network resources and improving communication efficiency.
In one embodiment, the present invention also provides a computer-readable storage medium having stored thereon a computer program which, when executed by a processor, implements the above-described method of clocking across network groups.
Fig. 3 is an internal structure diagram of a terminal in one embodiment, which may be a mobile robot, or other mobile terminal or fixed terminal. As shown in fig. 3, the apparatus comprises a memory 81 and a processor 80, the memory 81 stores a computer program 82, and the processor 80 implements the steps of the clock method across network groups described above when executing the computer program 82.
It will be understood by those skilled in the art that fig. 3 is only one example of the terminal of the present invention, and is not limited to the terminal, and may include more or less components than those shown, or combine some components, or different components, for example, the terminal may further include a power management module, an arithmetic processing module, an input/output device, a network access device, a bus, etc.
The Processor 80 may be a Central Processing Unit (CPU), other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field-Programmable Gate Array (FPGA) or other Programmable logic device, discrete Gate or transistor logic device, discrete hardware component, or the like. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
The storage 81 may be an internal storage unit of the terminal, such as a hard disk or a memory. The memory 81 may also be an external storage device of the terminal, such as a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), and the like. Further, the memory 81 may also include both an internal storage unit and an external storage device. The memory 81 is used to store computer programs and other programs and data required by the terminal. The memory 81 may also be used to temporarily store data that has been output or is to be output.
It will be apparent to those skilled in the art that, for convenience and simplicity of description, the foregoing functional units and modules are merely illustrated in terms of division, and in practical applications, the foregoing functional allocation may be performed by different functional units and modules as needed, that is, the internal structure of the terminal is divided into different functional units or modules to perform all or part of the above described functions. Each functional unit and module in the embodiments may be integrated in one processing unit, or each unit may exist alone physically, or two or more units are integrated in one unit, and the integrated unit may be implemented in a form of hardware, or in a form of software functional unit. In addition, specific names of the functional units and modules are only for convenience of distinguishing from each other, and are not used for limiting the protection scope of the present application. The specific working processes of the units and modules in the above-mentioned apparatus refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the above embodiments, the descriptions of the respective embodiments have respective emphasis, and reference may be made to the related descriptions of other embodiments for parts that are not described or illustrated in a certain embodiment.
Those of ordinary skill in the art will appreciate that the various illustrative elements and method steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
In the embodiments provided in the present invention, it should be understood that the disclosed terminal/terminal device and method can be implemented in other ways. For example, the above-described terminal/terminal device embodiments are merely illustrative, and for example, a module or a unit may be divided into only one logic function, and may be implemented in other ways, for example, a plurality of units or components may be combined or integrated into another device, or some features may be omitted or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, terminals or units, and may be in an electrical, mechanical or other form.
Units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present invention may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit. The integrated unit can be realized in a form of hardware, and can also be realized in a form of a software functional unit.
The invention is not limited solely to that described in the specification and embodiments, and additional advantages and modifications will readily occur to those skilled in the art, so that the invention is not limited to the specific details, representative apparatus, and illustrative examples shown and described herein, without departing from the spirit and scope of the general concept as defined by the appended claims and their equivalents.

Claims (10)

1. A method of clock synchronization across a network group, comprising the steps of:
step 1, acquiring an identification number generation rule, a master equipment generation rule and a time sequence synchronization rule which are commonly adopted by a plurality of network groups established based on a TDMA protocol;
step 2, generating a first identification number of the cost device by adopting the identification number generation rule;
step 3, when the device enters any one target network group in the multiple network groups established based on the TDMA protocol, acquiring a corresponding main device identification number from the broadcast of the target network group;
step 4, comparing the first identification number with the identification number of the main device, and judging whether the device is a new main device of the target network group according to a comparison result and the main device generation rule, if not, executing step 5, and if so, executing step 6;
step 5, performing time sequence synchronization to the target network group according to the clock of the current master device and the time sequence synchronization rule;
and 6, marking the first identification number by master equipment, broadcasting in the target network group to drive all the equipment of the target network group to update the current master equipment identification number to the first identification number, and performing time sequence synchronization by taking the equipment as new master equipment.
2. The method for clock synchronization across network groups according to claim 1, further comprising a communication step, specifically: and storing the current main equipment identification number of the target network group in a local place, and broadcasting the first identification number of the current main equipment identification number and the current main equipment identification number corresponding to the network group in communication.
3. The method for clock synchronization across network groups according to claim 2, further comprising a step of network crossing, specifically comprising:
step 7, when the device moves out of a first target network group of the plurality of network groups and enters a second target network group of the plurality of network groups, acquiring a corresponding main device identification number A from the broadcast of the second target network group;
step 8, comparing the current master equipment identification number B of the equipment with the master equipment identification number A of the second target network group, and judging whether to update the current master equipment of the second target network group according to the comparison result and the master equipment generation rule, if not, executing step 9, and if so, executing step 10;
step 9, performing timing synchronization to the second target network group according to the clock of the current master device in the second target network group and the timing synchronization rule;
and step 10, marking the current master equipment identification number B of the equipment by master equipment, broadcasting in the second target network group to drive all the equipment of the second target network group to update the stored master equipment identification number A to be the current master equipment identification number B of the equipment, and performing time sequence synchronization by taking the equipment as new master equipment.
4. The method for clock synchronization across network groups according to any of claims 1-3, wherein the identification number generation rule is: and generating an identification number uniquely corresponding to each device according to the random number, the CPU serial number of the device in the network group and/or the configuration parameters of the device.
5. The method for clock synchronization across network groups according to claim 4, wherein the master device generates rules as: and sequencing the plurality of devices of each network group according to the sequence of the identification numbers from large to small, and taking the device with the largest identification number in each network group as the main device of the corresponding network group.
6. The method for clock synchronization across network groups according to claim 5, wherein the timing synchronization rule is: and taking the clock of the master device as zero time, and sequencing the slave devices of the corresponding network group in different time slots according to the size sequence of the identification numbers so as to complete the time sequence synchronization of the corresponding network group.
7. A clock synchronization device of a cross-network group is characterized by comprising a first acquisition module, an identification number generation module, a second acquisition module, a first judgment module and a first synchronization module,
the first acquisition module is used for acquiring an identification number generation rule, a master equipment generation rule and a time sequence synchronization rule which are commonly adopted by a plurality of network groups established on the basis of a TDMA protocol;
the identification number generation module is used for generating a first identification number of the cost device by adopting the identification number generation rule;
the second obtaining module is used for obtaining a corresponding main equipment identification number from the broadcast of a target network group when the equipment enters any one of a plurality of network groups established based on a TDMA protocol;
the first judging module is used for comparing the first identification number with the identification number of the main equipment, judging whether the equipment is the new main equipment of the target network group or not according to the comparison result and the main equipment generating rule, and if not, driving the first synchronization module to carry out time sequence synchronization on the target network group according to the clock of the current main equipment and the time sequence synchronization rule; if yes, the first synchronization module is driven to carry out main equipment marking on the first identification number, the first identification number is broadcasted in the target network group, all equipment of the target network group is driven to update the current main equipment identification number to be the first identification number, and the equipment is used as new main equipment to carry out time sequence synchronization.
8. The clock synchronization apparatus across network groups according to claim 7, further comprising a third obtaining module, a second judging module and a second synchronization module,
the third obtaining module is configured to obtain a corresponding master device identification number a from a broadcast of a second target network group when the device moves out of the first target network group of the multiple network groups and enters the second target network group of the multiple network groups;
the second judging module is used for comparing a current master equipment identification number B of the equipment with a master equipment identification number A of the second target network group, judging whether to update the current master equipment of the second target network group according to a comparison result and the master equipment generating rule, and if not, driving the second synchronizing module to perform time sequence synchronization on the second target network group according to a clock of the current master equipment in the second target network group and the time sequence synchronization rule; if yes, the second synchronization module is driven to carry out main equipment marking on the current main equipment identification number B of the equipment, the second target network group broadcasts, all the equipment of the second target network group are driven to update the stored main equipment identification number A to be the current main equipment identification number B of the equipment, and the equipment is used as new main equipment to carry out time sequence synchronization.
9. A computer-readable storage medium, in which a computer program is stored, which, when executed by a processor, implements the method for clock synchronization across network groups according to any one of claims 1 to 6.
10. A terminal comprising the computer-readable storage medium of claim 9 and a processor which, when executing the computer program on the computer-readable storage medium, carries out the steps of the method of clock synchronization across network groups according to any of claims 1-6.
CN202110996696.8A 2021-08-27 2021-08-27 Cross-network-group clock synchronization method and device, storage medium and terminal Pending CN113727429A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110996696.8A CN113727429A (en) 2021-08-27 2021-08-27 Cross-network-group clock synchronization method and device, storage medium and terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110996696.8A CN113727429A (en) 2021-08-27 2021-08-27 Cross-network-group clock synchronization method and device, storage medium and terminal

Publications (1)

Publication Number Publication Date
CN113727429A true CN113727429A (en) 2021-11-30

Family

ID=78678581

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110996696.8A Pending CN113727429A (en) 2021-08-27 2021-08-27 Cross-network-group clock synchronization method and device, storage medium and terminal

Country Status (1)

Country Link
CN (1) CN113727429A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11606155B2 (en) * 2016-12-30 2023-03-14 Huawei Technologies Co., Ltd. Method for exchanging time synchronization packet and network apparatus
CN117295148A (en) * 2023-11-22 2023-12-26 泉州艾奇科技有限公司 Time synchronization method, central control host and wireless device

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US11606155B2 (en) * 2016-12-30 2023-03-14 Huawei Technologies Co., Ltd. Method for exchanging time synchronization packet and network apparatus
CN117295148A (en) * 2023-11-22 2023-12-26 泉州艾奇科技有限公司 Time synchronization method, central control host and wireless device
CN117295148B (en) * 2023-11-22 2024-02-23 泉州艾奇科技有限公司 Time synchronization method, central control host and wireless device

Similar Documents

Publication Publication Date Title
CN113727429A (en) Cross-network-group clock synchronization method and device, storage medium and terminal
CN114281521B (en) Method, system, equipment and medium for optimizing deep learning heterogeneous resource communication efficiency
CN109902056A (en) A kind of method, apparatus of serial transmission, equipment and computer readable storage medium
EP4145729A1 (en) Port state configuration method, apparatus, system, and storage medium
CN109857190A (en) A kind of clock signal processing method, device, equipment and readable storage medium storing program for executing
CN108429597A (en) Electronic equipment, method for synchronizing time and module
CN104717023A (en) Communication performance predictable 1553B bus engineering telemetric data acquiring method
CN109788034B (en) Configuration method for gateway access equipment, electronic equipment and storage medium
CN116233200A (en) Electric energy meter communication method and system based on subsequent frame dynamic registration
CN108170493B (en) System module loading method, system and device
CN114756379B (en) Method and system for task training based on hybrid accelerator card
CN110888892A (en) Block synchronization method, device and storage medium
CN113301141B (en) Deployment method and system of artificial intelligence support framework
CN111310393B (en) Simulation clock generation method and related product
CN102932208A (en) Site monitoring method and device
CN110738017A (en) Distributed integrated circuit simulation method and device, computing equipment and storage medium
CN113760809B (en) Configuration method, system and device of GPIO interface and readable storage medium
CN106412657B (en) A kind of method and system of set-top box programming sequence code
CN105357243A (en) Remote interaction method and apparatus with device in the Internet of things
CN109510682A (en) A kind of pond server system BMC clock synchronizing method, device, terminal and storage medium
CN111767999A (en) Data processing method and device and related products
CN111988310B (en) IEC61850 protocol-based data acquisition method and device
CN112860663B (en) System configuration method, device, equipment and storage medium
CN112311833B (en) Data updating method and device
CN106648824A (en) Broadcast processing method and broadcast processing device

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