Method for establishing time synchronization mechanism between a host and multiple slaves

By using time tag counters and synchronization signals in ultrasonic radar systems, the problem of time inconsistency between slaves is solved, and time synchronization between the master and multiple slaves is achieved, ensuring the accuracy of the echo signal.

CN119766383APending Publication Date: 2025-04-04ZHUHAI YOUHANG TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411981518.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-31
Publication Date
2025-04-04

AI Technical Summary

Technical Problem

In the application scenario of ultrasonic radar, due to the inconsistent time information between multiple slaves, there is an error in the calculation of the echo signal. It is necessary to design a mechanism to realize the time synchronization between the host and multiple slaves.

Method used

By setting up an ESI interface on the host, sending a synchronization signal to the slave, counting with a time tag counter, and packing the counter's time value back to the host to establish time synchronization between the host and multiple slaves.

Benefits of technology

Time synchronization between the master and multiple slaves is realized, ensuring accurate calculation of the echo signal and reducing errors.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119766383A_ABST
    Figure CN119766383A_ABST
Patent Text Reader

Abstract

The present invention provides a method for establishing a time synchronization mechanism between a host and a plurality of slaves so that the time between the host and a plurality of slaves is synchronized. The method of the present invention comprises the following steps: a. the host (1) sends a synchronization signal to all slaves (2) simultaneously through an ESI interface (11), and all slaves receive the synchronization signal at the same time. Once the slave detects the synchronization signal, the time tag counter of the slave itself is triggered to continue counting at the rising edge of the end of the synchronization signal until it is cleared and triggered to count again by the next received synchronization signal; b. when the host (1) enables the slave (2) to perform ultrasonic echo detection, when the slave receives the echo, the time value of the current time tag counter is recorded, and the time value is packaged together with the echo data to the host, thereby establishing time synchronization between the host and the plurality of slaves. The present invention is used in the field of communication technology.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of communication technology, and in particular to a method for establishing a time synchronization mechanism between a host and a plurality of slaves. Background Art

[0002] With the development of science and technology, automobile technology has become more and more mature. The number of cars in various countries is also increasing. Safe driving of cars has always been a research topic that major automobile manufacturers have invested a lot of manpower and material resources in. When a car is driving on the road, it uses devices such as laser radar, millimeter wave radar, ultrasonic radar, etc. installed on the car to monitor the road conditions in real time to ensure the safety of the car. In the application scenario of ultrasonic radar, the number of ultrasonic chips is generally large. In the ultrasonic detection scenario, it is generally composed of 1 host and multiple slaves, and multiple slaves are connected in series in the form of daisy chain. In an ultrasonic transmitting and receiving array composed of multiple slaves, a specific slave needs to send and receive echo signals, and the remaining slaves only receive ultrasonic echo signals. In such a slave distribution structure, the time when all slaves receive the echo is not absolutely consistent, and there will be time deviations. This deviation leads to errors in calculating the echo signal. For this reason, it is necessary to design a mechanism and method to synchronize the time information between the host and each slave, and thereby accurately calculate the echo detection information of each slave, so as to accurately calculate the complete information of the echo signal array of the slave network. Summary of the invention

[0003] The technical problem to be solved by the present invention is to overcome the deficiencies of the prior art and provide a method for establishing a time synchronization mechanism between a host and a plurality of slaves so that the time between the host and the plurality of slaves is synchronized.

[0004] The technical solution adopted by the present invention is a method for establishing a time synchronization mechanism between a host and multiple slaves. In the method, a plurality of ESI interfaces are provided on the ultrasonic host, each of the ESI interfaces is connected to the input end of the first slave in a slave group consisting of at least two slaves, and the input ends and output ends of the multiple slaves in each slave group are connected in a daisy chain form with the head and tail ends connected. The method for establishing a time synchronization mechanism between the host and the multiple slaves comprises the following steps: a. The host sends a synchronization signal to the input end of the first slave in all the slave groups through the ESI interface at the same time. When the first slave in the slave group detects the synchronization signal and the rising edge or falling edge of the synchronization signal ends, the time tag counter of the slave itself is triggered to continue counting until it is cleared by the next received synchronization signal and triggers re-counting; b. After the first slave in the slave group receives the synchronization signal, it sends the synchronization signal to all other slaves in the slave group at the same time. When all slaves in the slave group detect the synchronization signal and the rising edge or falling edge of the synchronization signal ends, the time tag counters of all slaves in the slave group are triggered to continue counting until they are cleared by the next received synchronization signal and trigger re-counting; c. When the host enables the first slave in the slave group to perform ultrasonic echo detection, the remaining slaves in the slave group send echo data to the first slave in the slave group. When all the slaves in the slave group receive the echo, the time value of the current time tag counter is recorded, and the time value is packaged as the ultrasonic echo signal clock together with the echo data and sent to the host, thereby establishing time synchronization between the host and multiple slaves.

[0005] Furthermore, the synchronization signal is a single reset pulse or a time synchronization code. If the pulse form detection time from high to low continues to exceed a certain set time, it is determined to be a single reset pulse. If a set character sequence is detected, it is determined to be a time synchronization code.

[0006] Furthermore, the counting clock of the time tag counter and the ultrasonic echo signal clock are homologous clocks or the same clock.

[0007] Furthermore, in step b, after the host sends a synchronization signal, the host starts to send various commands to the slave to perform ultrasonic measurement and echo data reading. The data sent back by the slave carries the time value information of the time tag counter. For the first slave in the slave group, it is necessary to record the time value when the ultrasonic wave is initiated and the time value when it receives the echo; for the remaining slaves in the slave group that receive the synchronization signal, record the time value when the echo is received.

[0008] Furthermore, after the host sends out a synchronization signal, a time synchronization calibration step is also included: after the host sends out a synchronization signal, each of the slaves triggers the time tag counter in turn according to the connected daisy chain order to start working, and the host then sends a time calibration signal to all slaves, the time calibration signal consists of a start code, a measurement period and an end code, each slave receives the time calibration signal sent by the host and starts recording the start time after the start code ends, and records the end time after receiving the end code, and the difference between the end time and the start time is used as the time difference and sent back to the host; after the host receives the time differences from all the slaves, it compares all the time differences to determine the clock speed and deviation size of each slave.

[0009] Beneficial effects of the present invention: In the method of the present invention, a time synchronization signal is sent from the host to each slave, and the time tag counter is used for counting. When echo detection is performed, the time value of the time tag counter is packaged together and sent back to the host, so that a time synchronization relationship between the host and multiple slaves can be established. Since the packaged time value is only a snapshot of the time tag counter of the slave, for the entire system, the host side can accurately obtain the time when the echo of the slave at each receiving end and the initiation time of the slave at the sending end, thereby realizing time synchronization between the host and multiple slaves. BRIEF DESCRIPTION OF THE DRAWINGS

[0010] Figure 1 It is a circuit connection topology diagram between the host and the slave in the present invention. DETAILED DESCRIPTION

[0011] like Figure 1 As shown, in the method of the present invention, a plurality of ESI interfaces 11 are provided on the ultrasonic host 1, each of the ESI interfaces 11 is connected to the input terminal DI of the first slave in a group of at least two slaves 2, and the input terminals DI and output terminals DO of the multiple slaves in each slave group are connected in a daisy chain form with the head and tail ends connected, that is, the ESI interface 11 of each host 1 and a group of slaves 2 are a daisy chain topology. By analogy, multiple daisy chain structures can be formed in a communication system. The method for establishing a time synchronization mechanism between a host and multiple slaves comprises the following steps: a. The host 1 sends a synchronization signal to the input terminal DI of the first slave 2 in all the slave groups through the ESI interface at the same time. When the first slave 2 in the slave group detects the synchronization signal and the rising edge or falling edge of the synchronization signal ends, the time tag counter 3 of the slave itself is triggered to continue counting until it is cleared by the next received synchronization signal and triggers re-counting; b. After the first slave 2 in the slave group receives the synchronization signal, it sends the synchronization signal to all other slaves in the slave group at the same time. When all slaves in the slave group detect the synchronization signal and the rising edge or falling edge of the synchronization signal ends, the time tag counters 3 of all slaves in the slave group are triggered to continue counting until they are cleared by the next received synchronization signal and trigger re-counting; c. When the host 1 enables the first slave in the slave group to perform ultrasonic echo detection, the remaining slaves in the slave group send echo data to the first slave in the slave group. When all the slaves in the slave group receive the echo, they record the time value of the current time tag counter 3, and package the time value together with the echo data as the ultrasonic echo signal clock and send it to the host 1, thereby establishing time synchronization between the host and multiple slaves.

[0012] Specifically, the synchronization signal is a single reset pulse or a time synchronization code. If the pulse form detection time from high to low continues to exceed a certain set time, it is determined to be a single reset pulse. If a set character sequence is detected, it is determined to be a time synchronization code.

[0013] The counting clock of the time tag counter 3 and the ultrasonic echo signal clock are homologous clocks or the same clock.

[0014] In step b, after the host sends out a synchronization signal, the host starts to send various commands to the slave to perform ultrasonic measurement and echo data reading. The data sent back by the slave contains the time value information of the time tag counter. For the first slave in the slave group, it is necessary to record the time value when the ultrasonic wave is initiated and the time value when it receives the echo; for the remaining slaves in the slave group that receive the synchronization signal, record the time value when the echo is received.

[0015] After the host sends a synchronization signal, it also includes a time synchronization calibration step: after the host sends a synchronization signal, it also includes a time synchronization calibration step: after the host sends a synchronization signal, each of the slaves triggers the time tag counter in turn according to the connected daisy chain order to start working, and the host then sends a time calibration signal to all slaves, the time calibration signal consists of a start code, a measurement period and an end code, each slave receives the time calibration signal sent by the host and starts to record the start time after the start code ends, and then records the end time after receiving the end code, and the difference between the end time and the start time is used as the time difference and sent back to the host; after the host receives the time differences of all the slaves, it compares all the time differences to determine the clock speed and deviation size of each slave.

[0016] In the present invention, a time synchronization signal is sent from the host to each slave, which is counted by a time tag counter. When echo detection is performed, a time synchronization relationship between the host and multiple slaves can be established by packaging the time value of the time tag counter and sending it back to the host. Since the packaged time value is only a snapshot of the time tag counter of the slave, for the entire system, the host can accurately obtain the time when the echo of the slave at each receiving end and the initiation time of the slave at the sending end, thereby realizing time synchronization between the host and multiple slaves.

[0017] Finally, it should be emphasized that the above is only a preferred embodiment of the present invention and is not intended to limit the present invention. For those skilled in the art, the present invention may have various changes and modifications. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.

Claims

1. A method for establishing a time synchronization mechanism between a host and a plurality of slaves, wherein a plurality of ESI interfaces (11) are provided on an ultrasonic host (1), each of the ESI interfaces (11) correspondingly connected to an input terminal (DI) of a first slave in a slave group consisting of at least two slaves (2), and the input terminals (DI) and output terminals (DO) of the plurality of slaves in each slave group are connected head-to-tail in a daisy chain form, characterized in that: The method for establishing a time synchronization mechanism between a host and a plurality of slaves comprises the following steps: a. the host (1) simultaneously sends a synchronization signal to the input terminal (DI) of the first slave (2) in all the slave groups through the ESI interface (11); when the first slave (2) in the slave group detects the synchronization signal and at the rising edge or falling edge of the end of the synchronization signal, the time tag counter (3) of the slave itself is triggered to continue counting until it is cleared by the next synchronization signal received and triggers re-counting; b. After the first slave (2) in the slave group receives the synchronization signal, it simultaneously sends the synchronization signal to all other slaves in the slave group. When all slaves in the slave group detect the synchronization signal and the rising edge or falling edge of the synchronization signal ends, the time tag counters (3) of all slaves in the slave group are triggered to continue counting until they are cleared by the next synchronization signal received and triggered to count again; c. When the host (1) enables the first slave (2) in the slave group to perform ultrasonic echo detection, the remaining slaves in the slave group send echo data to the first slave in the slave group, and when all the slaves (2) in the slave group receive the echo, the time value of the current time tag counter (3) is recorded, and the time value is packaged as an ultrasonic echo signal clock together with the echo data and sent to the host (1), thereby establishing time synchronization between the host and multiple slaves.

2. The method for establishing a time synchronization mechanism between a host and a plurality of slaves according to claim 1, characterized in that: The synchronization signal is a single reset pulse or a time synchronization code. If the pulse form detection time from high to low continues to exceed a certain set time, it is determined to be a single reset pulse. If a set character sequence is detected, it is determined to be a time synchronization code.

3. The method for establishing a time synchronization mechanism between a host and a plurality of slaves according to claim 1, characterized in that: The counting clock of the time tag counter (3) and the ultrasonic echo signal clock are homologous clocks or the same clock.

4. The method for establishing a time synchronization mechanism between a host and a plurality of slaves according to claim 1, characterized in that: In step b, after the host sends out a synchronization signal, the host starts to send various commands to the slave to perform ultrasonic measurement and echo data reading. The data sent back by the slave contains the time value information of the time tag counter. For the first slave in the slave group, it is necessary to record the time value when the ultrasonic wave is initiated and the time value when it receives the echo; for the remaining slaves in the slave group that receive the synchronization signal, record the time value when the echo is received.

5. The method for establishing a time synchronization mechanism between a host and a plurality of slaves according to claim 1, characterized in that: After the host sends out the synchronization signal, it also includes a time synchronization calibration step: after the host sends out the synchronization signal, each of the slaves triggers the time tag counter in turn according to the connected daisy chain order to start working, and the host then sends a time calibration signal to all slaves, the time calibration signal consists of a start code, a measurement period and an end code, each slave receives the time calibration signal sent by the host and starts to record the start time after the start code ends, and records the end time after receiving the end code, and the difference between the end time and the start time is used as the time difference and sent back to the host; after the host receives the time differences of all the slaves, it compares all the time differences to determine the clock speed and deviation size of each slave.