WO2024130608A1 - 飞行时间测量方法、装置、激光测距装置及存储介质 - Google Patents

飞行时间测量方法、装置、激光测距装置及存储介质 Download PDF

Info

Publication number
WO2024130608A1
WO2024130608A1 PCT/CN2022/140829 CN2022140829W WO2024130608A1 WO 2024130608 A1 WO2024130608 A1 WO 2024130608A1 CN 2022140829 W CN2022140829 W CN 2022140829W WO 2024130608 A1 WO2024130608 A1 WO 2024130608A1
Authority
WO
WIPO (PCT)
Prior art keywords
flight
ambient light
detection unit
flight time
value
Prior art date
Application number
PCT/CN2022/140829
Other languages
English (en)
French (fr)
Inventor
谭伟
臧军领
Original Assignee
深圳市速腾聚创科技有限公司
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 深圳市速腾聚创科技有限公司 filed Critical 深圳市速腾聚创科技有限公司
Priority to PCT/CN2022/140829 priority Critical patent/WO2024130608A1/zh
Publication of WO2024130608A1 publication Critical patent/WO2024130608A1/zh

Links

Images

Definitions

  • Time of flight (TOF) measurement technology has important applications in the fields of autonomous driving, face recognition, 3D gesture recognition, etc.
  • the transmitter emits a pulse signal
  • the detector such as a single photon avalanche diode (SPAD)
  • the detector transmits the pulse electrical signal to a sampling circuit, such as a time-to-digital converter (TDC), and the sampling circuit records the time of the pulse electrical signal.
  • TDC time-to-digital converter
  • the histogram data is obtained based on the time statistics of the pulse electrical signal recorded by the sampling circuit, and the histogram data is written into the storage unit.
  • the histogram data written into the storage unit needs to be output to the signal processing part of the subsequent stage for processing.
  • the signal processing part determines the flight time based on the histogram data to calculate the distance between the laser and the object based on the flight time.
  • the optical signal received by the detector may contain ambient light signals in addition to the echo light signals.
  • the detection unit may not be able to correctly distinguish which of the received signals are ambient light signals and which are echo light signals, resulting in the ambient light signals being used as echo light signals to calculate the flight time, and thus the correct flight time cannot be identified.
  • the embodiments of the present application provide a flight time measurement method, apparatus, terminal device and computer-readable storage medium to solve the problem that the current flight time measurement process is affected by ambient light signals, resulting in poor detection performance.
  • the present application provides a flight time measurement method, comprising:
  • the histogram data includes Z flight moments and Z count values corresponding to each of the Z flight moments, where Z is a positive integer greater than 1;
  • the first preset time period and the second preset time period are located in a single detection cycle; in the first preset time period, the light-emitting unit corresponding to the detection unit does not emit a pulse light signal; in the second preset time period, the light-emitting unit corresponding to the detection unit emits N pulse light signals, where N is a positive integer greater than 1.
  • the present application further provides a flight time measurement device, which adopts the above-mentioned flight time measurement method; the flight time measurement device comprises:
  • a first statistical unit used for counting photon events of the detection unit within a first preset time period to generate an ambient light value
  • a second statistical unit is used to count the photon events of the detection unit within a second preset time period to generate histogram data; wherein the histogram data includes Z flight moments and Z count values corresponding to each of the Z flight moments, where Z is a positive integer greater than 1;
  • a calculation unit configured to subtract the ambient light value from the Z count values to generate Z processing values corresponding to the Z count values
  • a determination unit for determining a flight time according to the Z processed values
  • the first preset time period and the second preset time period are located in a single detection cycle; in the first preset time period, the light-emitting unit corresponding to the detection unit does not emit a pulse light signal; in the second preset time period, the light-emitting unit corresponding to the detection unit emits N pulse light signals, where N is a positive integer greater than 1.
  • an embodiment of the present application provides a laser ranging device, comprising: a transmitter, a detector, a processor, a communication interface, a memory and a communication bus; the processor communicates with the transmitter and the detector through the communication interface; the processor, the communication interface and the memory communicate with each other through the communication bus; the transmitter comprises one or more light-emitting units for emitting pulsed light signals; the detector comprises one or more detection units for receiving light signals; the memory is used to store computer programs or instructions; the processor is used to execute the computer programs or instructions in the memory to implement the flight time measurement method as described above.
  • an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium stores at least one executable instruction, and when the executable instruction is executed by a processor, the flight time measurement method as described above is implemented.
  • an embodiment of the present application provides a computer program product.
  • the computer program product is run on a laser ranging device, the laser ranging device executes the above-mentioned time of flight measurement method.
  • the embodiments of the present application provide a flight time measurement method, device, terminal and storage medium, which generate ambient light values by counting photon events of a detection unit within a first preset time period, and generate histogram data by counting photon events of the detection unit within a second preset time period; then subtract the ambient light values from multiple count values in the histogram data to obtain multiple processing values corresponding to the multiple count values; and then determine the flight time based on the multiple processing values, so that the count value of the echo light signal in the histogram data can be kept basically unchanged, the count value of the ambient light signal is attenuated, the signal-to-noise ratio of the detection unit is improved, the correct flight time is determined, and the accuracy of measuring the flight time is effectively improved.
  • FIG1A is a schematic diagram of an architecture of a flight time measurement device provided in an embodiment of the present application.
  • FIG1B is a schematic diagram showing the principle of generating histogram data by a flight time measurement device provided in an embodiment of the present application
  • FIG2 is a schematic diagram of a flow chart of a method for measuring time of flight provided in an embodiment of the present application
  • FIG. 3 is a timing diagram of a light emitting unit emitting a light signal and a detection unit receiving a light signal in a method for measuring a time of flight provided in an embodiment of the present application;
  • FIG4 is another schematic diagram of a structural block diagram of a flight time measurement device provided in an embodiment of the present application.
  • FIG5 is a schematic diagram of a structural block diagram of a first statistical unit provided in an embodiment of the present application.
  • FIG6 is a schematic diagram of a structure of a first statistical unit provided in an embodiment of the present application.
  • FIG8 is another schematic diagram of the structure of a flight time measurement device provided in an embodiment of the present application.
  • FIG. 9 is a schematic diagram of the structure of a terminal device provided in an embodiment of the present application.
  • references to “one embodiment” or “some embodiments” etc. described in the specification of the present application mean that one or more embodiments of the present application include specific features, structures or characteristics described in conjunction with the embodiment.
  • the statements “in one embodiment”, “in some embodiment embodiments”, “in some other embodiments”, “in some other embodiments”, etc. that appear in different places in this specification do not necessarily refer to the same embodiment, but mean “one or more but not all embodiments", unless otherwise specifically emphasized in other ways.
  • the terms “including”, “comprising”, “having” and their variations all mean “including but not limited to”, unless otherwise specifically emphasized in other ways.
  • FIG1A is an architecture diagram of a time-of-flight measurement system provided by the present application.
  • the time-of-flight measurement system includes an emitter 60, a detector 10, a sampling module 20, and a storage module 40;
  • the emitter 60 includes a light-emitting unit 601
  • the detector 10 includes a detection unit 101
  • the sampling module includes a sampling unit 201
  • the storage module 40 includes a storage unit 401.
  • the transmitter 60 includes one or more light emitting units 601, each light emitting unit 601 corresponds to one or more detection units 601, and is used to emit pulsed light signals.
  • the detector 10 includes one or more detection units 101, and the detection unit 101 can use a single photon avalanche diode (SPAD) or a silicon photomultiplier (SIPM) to detect the echo light signal; the sampling unit 201 is connected to the detection unit 101 for time-of-flight data.
  • the sampling unit 201 can use a time-to-digital converter (TDC).
  • TDC time-to-digital converter
  • the basic process of the above-mentioned time-of-flight measurement system for time-of-flight measurement is as follows: the light-emitting unit 601 emits a pulse light signal to the detection area; the detection unit 101 corresponding to the light-emitting unit 601 receives the echo light signal and converts the echo light signal into an echo electrical signal, wherein the echo light signal is an optical signal returned after the pulse light signal emitted by the light-emitting unit 601 is reflected by an obstacle in the detection area; the sampling unit 201 is connected to the detection unit 101, and is used to generate time-of-flight data according to the electrical signal output by the detection unit 101, and the time-of-flight data is used to indicate each flight moment and the number of photons corresponding to each flight moment, and further can indicate the arrival time of the echo light signal.
  • the arrival time of the echo light signal is stored in the storage unit 401.
  • the time-of-flight TOF is obtained according to the emission time of the pulse light signal and the arrival time of the echo light signal, and then the distance of the obstacle can be calculated according to the constant light speed and the time-of-flight TOF.
  • the detection unit 101 when the detection unit 101 does not receive the echo light signal at a certain flight time in the flight time statistical period, the detection unit 101 will not output the echo electrical signal to the sampling unit 101, and accordingly, the number of photons corresponding to the flight time output by the sampling unit 101 is 0; and when the detection unit 101 receives the echo light signal at a certain flight time, the detection unit 101 will output the echo electrical signal to the sampling unit 201 at the flight time, and accordingly, the number of photons corresponding to the flight time output by the sampling unit 101 is >0, and the flight time corresponding to the photon number >0 is the arrival time of the echo light signal.
  • the optical signal received by the detection unit 101 may contain an ambient light signal in addition to the echo light signal.
  • the detection unit 101 cannot effectively distinguish which of the received signals are ambient light signals and which are echo light signals.
  • TCSPC time-correlated single photon counting
  • the main principle is that a single detection cycle includes multiple flight time statistical cycles T tof , and the light-emitting unit 601 emits a pulse light signal at the start time of the multiple flight time statistical cycles T tof , that is, the light-emitting unit 601 emits a pulse light signal multiple times in a single detection cycle.
  • the detection unit 101 detects the echo light signal in multiple flight time statistical cycles T tof , that is, the detection unit 101 detects the echo light signal multiple times in a single detection cycle; since the movement speed of the obstacle is much smaller than the speed of light, the distance of the obstacle in the same detection cycle can be regarded as remaining unchanged, that is, the flight time TOF remains unchanged, therefore, in multiple flight time statistical cycles, the arrival time of the echo light signal has the characteristics of coherence or consistency, and in multiple flight time statistical cycles T tof , the arrival time of the ambient light signal has randomness, and after experiencing multiple flight time statistical cycles T tof , the echo light signal can stand out from the ambient light signal.
  • a single detection cycle includes N flight time statistical cycles T tof , where N is a positive integer greater than 1.
  • the echo light signal received by the detection unit 101 in each flight time statistical cycle T tof is represented by a rectangle filled with oblique lines, and the received ambient light signal is represented by a rectangle filled with gray.
  • the light emitting unit 101 emits light at the start time of the first flight time statistical cycle T tof to the Nth flight time statistical cycle T tof , and emits N pulse light signals; the detection unit 101 performs N echo light signal detections in N flight time statistical cycles.
  • the detection unit 101 in addition to receiving the echo light signal in each flight time statistical cycle T tof , the detection unit 101 also receives multiple ambient light signals, and the position of the echo light signal remains basically unchanged, while the position of each ambient light signal is relatively messy.
  • the photon events of the detection unit 101 in a flight time statistical cycle T tof constitute a flight time data set, wherein the horizontal axis of the flight time data set represents each flight time in a flight time statistical cycle, and the vertical axis represents the number of photons corresponding to each flight time.
  • the position of the signal on the horizontal axis of the flight time data set represents the arrival time of the light signal (ambient light signal or echo light signal), and the value of the signal on the vertical axis of the flight time data set represents the number of photons of the light signal (ambient light signal or echo light signal);
  • the flight time data sets of the first flight time statistical period T tof to the Nth flight time statistical period T tof are superimposed, that is, the number of photons corresponding to the first flight time statistical period T tof to the Nth flight time statistical period T tof at the same flight time are accumulated to obtain the count value corresponding to each flight time; wherein, the count value of a certain flight time is equal to the accumulated value of the number of photons corresponding to the first flight time statistical period T tof to the Nth flight time statistical period T tof at the flight time.
  • the histogram (histogram) below FIG1B can be generated according to the count values of each flight time in the flight time statistical period T tof .
  • the horizontal axis of the histogram represents each flight time in the flight time statistical period T tof
  • the vertical axis of the histogram represents the count value corresponding to each flight time.
  • the flight time corresponding to the maximum count value in the histogram is the arrival time of the echo light signal, that is, the flight time.
  • the correct flight time measured depends on correctly identifying the peak position of the count value in the histogram, and then identifying the correct arrival time of the echo light signal.
  • SBNR signal-to-background noise ratio
  • the photons of the echo light signal received by the detection unit 101 decrease as the distance increases, while the photons of the ambient light received remain unchanged as the distance changes, the signal-to-noise ratio will be small, affecting the peak position of the count value identified by the back-end circuit, which may cause the back-end circuit to recognize the peak incorrectly, causing detection errors, and thus greatly reducing the detection accuracy.
  • the embodiment of the present application provides a flight time measurement method, which generates an ambient light value by counting the photon events of the detection unit 101 within a first preset time period T1 , wherein the light-emitting unit 601 corresponding to the detection unit 101 does not emit light within the first preset time period T1 ; and generates histogram data by counting the photon events of the detection unit 101 within a second preset time period T2 , wherein the second preset time period T2 includes N flight time statistical periods T tof , N is a positive integer greater than 1, and the light-emitting unit 601 corresponding to the detection unit 101 emits N pulse light signals at the start time of the N flight time statistical periods T tof ; then, the ambient light value is subtracted from the multiple count values in the histogram data respectively to obtain multiple processing values corresponding to the multiple count values; finally, the flight time is determined according to the multiple processing values, so that the count value of the echo light signal in the histogram data can be
  • FIG. 2 is a schematic diagram of a method for measuring time of flight provided in an embodiment of the present application.
  • the method includes but is not limited to the following steps:
  • a single detection cycle includes a first preset time period T 1 and a second preset time period T 2 .
  • the detection unit 101 performs ambient light detection in the first preset time period T 1 , and performs N detections of echo light signals in the second preset time period T 2 ; in the first preset time period T 1 , the light emitting unit 601 corresponding to the detection unit 101 does not emit light, so as to realize ambient light detection in the first preset time period T 1 .
  • the light emitting unit 601 does not emit light
  • the light signal received by the detection unit 101 in the first preset time period T 1 does not include the echo light signal
  • the photon event of the detection unit 101 in the first preset time period T 1 is generated by the ambient light.
  • the ambient light value is used to indicate the average number of ambient light photons received by the detection unit 101 at each flight moment during the process of performing N echo light signal detections by the detection unit 101, that is, the average number of ambient light photons included in the count values corresponding to each flight moment in the histogram data.
  • the detection unit 101 receives (T 1 /t 0 ) flight moments of ambient light photons in the first preset time period T 1.
  • the ambient light value amb1 can be set according to the average number of ambient light photons S2 received at each flight moment in the process of the detection unit 101 detecting the N echo light signals, thereby indicating the average number of ambient light photons received at each flight moment in the process of the detection unit 101 detecting the N echo light signals.
  • counting the photon events of the detection unit within the first preset time period to generate an ambient light value includes:
  • an ambient light value is generated.
  • the calculation formula of the ambient light value is:
  • the first photon number cumulative value is the photon number cumulative value Sum of the ambient light received by the detection unit 101 within the first preset time period T1 ;
  • is a gain coefficient, ⁇ is a real number, and ⁇ 1 or ⁇ >1, and the gain coefficient ⁇ is used to multiply the first photon number cumulative value of the ambient light by a number less than 1 or greater than 1, so as to adjust the size and proportion of the ambient light influence.
  • the bias coefficient ⁇ is used to add a static bias to the photon number of the ambient light, so as to achieve the subtraction of the ambient light photon number in each count value of the histogram data, and eliminate the static environment background noise, further improving the signal-to-noise ratio.
  • the gain coefficient ⁇ may be set by the following formula:
  • the present application does
  • the gain coefficient ⁇ is proportional to the number of reception times N when the detection unit 101 detects the echo light signal, and is inversely proportional to the first preset time period T1 .
  • the specific value of the gain coefficient ⁇ can be set according to actual needs, and the present application does not limit the specific value of the gain coefficient ⁇ .
  • the bias coefficient ⁇ can be set according to the static environment background noise obtained from actual testing, and the present application does not limit the specific value of the bias coefficient ⁇ .
  • the ambient light value is calculated as follows:
  • amb1 N*[Sum/(T 1 /t 0 )]
  • the longer the first preset time period T1 is, the closer the average number of ambient light photons S0 received at each flight moment when the detection unit 101 is detecting ambient light is to the actual average number of ambient light photons received at each flight moment; accordingly, the average number of ambient light photons S2 received at each flight moment when the detection unit 101 is detecting N echo light signals is closer to the actual number of ambient light photons received at each flight moment when the detection unit 101 is detecting N echo light signals.
  • the first preset time period T1 is within a single detection cycle.
  • the duration of a single detection cycle cannot be extended indefinitely, and accordingly, the first preset time period T1 cannot be extended indefinitely.
  • the first preset time period T1 satisfies: t0 ⁇ T1 ⁇ the duration of a single detection cycle.
  • T tof the value range of the first preset time period T 1 is: T tof ⁇ T 1 ⁇ N*T tof .
  • T tof is the above-mentioned flight time statistical period
  • T tof i*T c
  • T c j*t 0
  • i and j are both positive integers greater than 1
  • T c is the clock cycle
  • t 0 is the duration of each flight moment
  • N is the number of times the detection unit 101 detects the echo optical signal in a single detection cycle, and is also the number of times the light emitting unit 101 emits the pulse optical signal in a single detection cycle.
  • the first preset time period T1 may be set by the following formula:
  • T 1 u 1 *T tof ;
  • u 1 is a positive integer, and 1 ⁇ u 1 ⁇ N.
  • the first preset time period T 1 is divided into u 1 *i clock cycles T c
  • the first preset time period T 1 is divided into u 1 *i*j flight moments. Since each flight moment corresponds to a photon number, accordingly, the first preset time period T 1 corresponds to u 1 *i*j photon numbers.
  • the number i of clock cycles T c included in the flight time statistical period T tof and the number j of flight moments included in each clock cycle T c are usually preset values.
  • the setting of u 1 the setting of the first preset time period T1 can be completed, and the setting method is very simple.
  • the first preset time period T1 is divided into K clock cycles; accumulating the number of photons received by the detection unit in the first preset time period to generate a first photon number accumulated value includes:
  • each initial photon number accumulation value is the accumulation value of the number of ambient light photons received by the detection unit in one clock cycle
  • Sum is the first photon number cumulative value
  • K is the number of clock cycles T c included in the first preset time period T 1 , that is, the number of initial photon number cumulative values
  • K is a positive integer
  • K T 1 /T c
  • k is a positive integer
  • sk is the kth initial photon number cumulative value, that is, the cumulative value of the number of ambient light photons received by the detection unit 101 in the kth clock cycle of the first preset time period T 1.
  • the data format can be set according to the data type.
  • the data format of the gain coefficient a is U4.6
  • the data format of the bias coefficient ⁇ is U10.0
  • the data format of the accumulated value Sum of the number of photons of ambient light received by the detection unit 101 in the first preset time period is U11.0
  • the data format of the ambient light value amb1 is U11.0.
  • the method further includes: storing the ambient light value in a storage unit.
  • the ambient light value amb1 is stored in a storage space at address a0 in the storage unit 401.
  • the detection unit after the detection unit counts the photon events within the first preset time period to generate the ambient light value, it also includes: performing a limit saturation process on the ambient light value.
  • the ambient light value amb1 that has undergone the limit saturation processing is stored in the storage space with the address a0 in the storage unit 401.
  • the limit saturation process is to prevent data overflow caused by too long photon number statistics time. If the data (the first photon number cumulative value) exceeds the maximum value of the data that can be stored in the required data format, the maximum value is used to represent the data (i.e., the first photon number cumulative value); if the first photon number cumulative value exceeds the minimum value of the data that can be stored in the required data format, the minimum value is used to represent the data (i.e., the first photon number cumulative value).
  • the histogram data includes Z flight times and Z count values corresponding to the Z flight times, where Z is a positive integer greater than 1.
  • the second preset time period T 2 includes N flight time statistical periods T tof
  • the light emitting unit 601 corresponding to the detection unit 101 emits N pulse light signals at the start time of the N flight time statistical periods T tof .
  • the detection unit 101 receives N light signals in the first flight time statistical period T tof to the Nth flight time statistical period T tof to detect N echo light signals.
  • the light emitting unit 601 emits a pulse light signal at the start time of the 1st flight time statistical period T tof to the Nth flight time statistical period T tof
  • the light signal received by the detection unit 101 within the 1st flight time statistical period T tof to the Nth flight time statistical period T tof includes an echo light signal and an ambient light signal
  • the photon event of the detection unit 101 within the 1st flight time statistical period T tof to the Nth flight time statistical period T tof is generated by the echo light signal and the ambient light signal.
  • the count values in the histogram data are respectively used to indicate the cumulative values of the number of photons corresponding to the same flight time in the N flight time statistical periods T tof .
  • the histogram data can be generated by superimposing the N flight time data sets corresponding to the N flight time statistical periods T tof .
  • the second preset time period T2 includes N flight time statistical cycles T tof .
  • Each flight time statistical cycle T tof includes i clock cycles T c , and each clock cycle T c is divided into j flight moments.
  • the second preset time period T2 also includes N emission time intervals T21 , and the N emission time intervals Ttx are respectively located before the start time of the N flight time statistical periods Ttf .
  • the light emitting unit 601 emits light in each emission time interval Ttx to transmit N pulse light signals at the start time of the first flight time statistical period Ttf to the Nth flight time statistical period Ttf .
  • tx_en is a first control signal, used to trigger the light emitting unit 601 to emit N pulse light signals within the second preset time period T 2.
  • tof_en is a first receiving control signal, used to trigger the detection unit 102 to detect N echo light signals within the second preset time period T 2.
  • env_en is a second control signal, used to trigger the detection unit 101 to perform ambient light detection within the first preset time period T 1 .
  • tx_en includes N first high-level pulses Pulse1 in a single detection cycle, the pulse width of each first high-level pulse Pulse1 is equal to the emission time interval T tx , and the time interval between the falling edges of two adjacent first high-level pulses Pulse1 is equal to the flight time statistical period T tof .
  • the N first high-level pulses Pulse1 are evenly spaced in the second preset time period T 2 , and the first first high-level pulse Pulse1 is located at the start time of the second preset time period T 2.
  • tx_en triggers the light-emitting unit 601 to emit N pulse light signals through the high level of the N first high-level pulses Pulse1.
  • tof_en includes N second high-level pulse signals Pulse2 in a single detection cycle, and the pulse width of each first high-level pulse Pulse1 is equal to the flight time statistical period T tof .
  • the rising edges of the N second high-level pulse signals Pulse2 are respectively aligned with the falling edges of the N first high-level pulses Pulse1.
  • the falling edges of the 1st second high-level pulse signal Pulse2 to the N-1st second high-level pulse signal Pulse2 are respectively aligned with the rising edges of the 2nd first high-level pulse signal Pulse1 to the rising edges of the Nth first high-level pulse signal Pulse1.
  • tof_en triggers the receiving unit 101 to detect the echo optical signal N times through the high levels of the N second high-level pulse signals Pulse2.
  • env_en includes a third high-level pulse signal Pulse3 in a single detection cycle.
  • the pulse width of the third high-level pulse signal Pulse3 is equal to the first preset time period T2 .
  • the falling edge of the third high-level pulse signal Pulse3 is aligned with the rising edge of the first first high-level pulse Pulse1, that is, the end time of the first preset time period T1 is equal to the start time of the second preset time period T2 .
  • env_en triggers the receiving unit 101 to detect the ambient light signal through the high level of the third high-level pulse signal Pulse3. Further, counting the photon events of the detection unit in the second preset time period and generating histogram data includes:
  • the N flight time data sets are stacked to generate histogram data.
  • N flight time data sets are used to indicate the photon events of the detection unit 101 in N flight time statistical periods T tof , that is, the 1st flight time statistical period T tof to the Nth flight time statistical period T tof .
  • Each flight time data set includes each flight time period of a flight time statistical period T tof and the number of photons corresponding to each flight time period.
  • the horizontal axis of the flight time data set represents each flight moment in a flight time statistical period T tof
  • the vertical axis represents the number of photons corresponding to each flight moment.
  • the position of the optical signal (ambient light signal or echo optical signal) on the horizontal axis of the flight time data set represents the arrival time of the optical signal
  • the value of the optical signal on the vertical axis of the flight time data set is used to indicate the number of photons.
  • the N flight time data sets are superimposed to align the N flight time data sets according to the flight time, and then accumulate the number of photons at the same flight time, that is, accumulate the N groups of photon numbers corresponding to each flight time, so that each count value in the histogram data is used to indicate the accumulated value of the number of photons corresponding to each flight time after the N flight time data sets are superimposed.
  • each flight time statistical cycle T tof includes i clock cycles T c
  • each clock cycle T c is divided into j flight moments. Accordingly, the number of flight moments included in each flight time data set is equal to i*j, and the i*j flight moments correspond to i*j photon numbers. Accordingly, the flight moments Z included in the histogram data are i*j, and the Z flight moments correspond to i*j count values.
  • the method further includes: storing the histogram data in a storage unit.
  • the histogram data is stored in the storage space with addresses a1 to ai in the storage unit 401.
  • Each storage space includes j sub-storage spaces.
  • the j sub-storage spaces in the storage space with address a1 are used to store the j count values corresponding to the j flight moments in the first clock cycle
  • the j sub-storage spaces in the storage space with address a2 are used to store the j count values corresponding to the j flight moments in the second clock cycle...
  • the j sub-storage spaces in the storage space with address ai are used to store the j count values corresponding to the j flight moments in the i-th clock cycle, so that the i*j sub-storage spaces formed by the i storage spaces respectively store the i*j count values in the histogram data.
  • the ambient light value is subtracted from the Z count values to generate Z processing values corresponding to the Z count values respectively, including:
  • An ambient light value and Z count values are received, and the Z count values are respectively subtracted from the ambient light value to generate Z processed values.
  • obtaining and outputting the ambient light value and Z count values includes:
  • outputting Z count values in sequence according to the flight times is according to the i*j flight times in each flight time statistical period T tof , that is, outputting Z count values corresponding to each flight time in sequence according to the Z flight times.
  • obtaining Z count values and outputting the Z count values in sequence according to the flight time sequence in each flight time statistical period includes:
  • each group of count values includes j count values corresponding to j flight moments included in one clock cycle;
  • j count values corresponding to the j flight times included in each clock cycle are output in sequence.
  • sequentially acquiring i groups of count values corresponding to i clock cycles in the order of clock cycles is sequentially acquiring i groups of count values corresponding to i clock cycles stored in the storage unit 401 in the order of i clock cycles in each flight time statistical period T tof .
  • j count values corresponding to the j flight times included in each clock cycle are output in sequence.
  • j count values are output in sequence according to the flight time sequence in each clock cycle.
  • i groups of count values corresponding to i clock cycles are respectively stored in storage spaces with addresses a 1 to a i in the storage unit 401.
  • Obtaining i groups of count values corresponding to i clock cycles stored in the storage unit in sequence according to the clock cycle sequence in each flight time statistical cycle includes: obtaining i groups of count values stored in storage spaces with addresses a 1 to a i in the storage unit in sequence according to the clock cycle sequence in each flight time statistical cycle.
  • the ambient light value is stored in the storage space with address a0 of the storage unit 401, and obtaining and outputting the ambient light value includes: obtaining the ambient light value from the storage space with address a0 in the storage unit, and outputting the obtained ambient light value.
  • the output time of the ambient light value covers the output time of the Z count values, so as to facilitate the subtraction operation between each count value and the ambient light value.
  • the output time of the Z count values can be determined in the design stage, for example, the output time range of the Z count values is preset to be t 21 ⁇ t 22 .
  • the output time range of the ambient light value is made to be t 11 ⁇ t 12 , wherein t 11 ⁇ t 21 , t 12 > t 22 , so that the output time of the ambient light value covers the output time of the Z count values, thereby facilitating the subtraction operation of each count value from the ambient light value.
  • the ambient light value and Z count values may be received by a subtractor, and the Z count values may be subtracted from the ambient light value to generate Z processing values.
  • the method further includes: performing a limit saturation process on the Z processed values.
  • the limit saturation process is to prevent the data (i.e., the count value) from overflowing due to the long photon counting time. If the data exceeds the maximum value of the data that can be stored in the required data format, the maximum value is used to represent the data; if the data exceeds the minimum value of the data that can be stored in the required data format, the minimum value is used to represent the data.
  • the flight time is determined according to the time corresponding to the peak position in the Z processed values.
  • the flight time ranging method provided in the embodiment of the present application generates an ambient light value by counting the photon events of the detection unit 101 in the first preset time period, and generates histogram data by counting the photon events of the detection unit 101 in the second preset time period; then the ambient light value is subtracted from the multiple count values in the histogram data to obtain multiple processed values; the correct flight time of the obstacle can be determined according to the time corresponding to the peak position in the multiple processed values, so that the count value of the echo light signal in the histogram data can be kept basically unchanged, the count value of the ambient light signal is attenuated, the signal-to-noise ratio of the detection unit 101 is improved, the correct peak position is easily identified, and the accuracy of the detection unit 101 in measuring the flight time is effectively improved.
  • an embodiment of the present application provides a flight time measurement device, which uses a first statistical unit 301 to count the photon events of the detection unit 101 within a first preset time period to generate an ambient light value, and uses a second statistical unit 302 to count the photon events of the detection unit 101 within a second preset time period to generate histogram data; then, the calculation unit 501 subtracts the ambient light value from the multiple count values in the histogram data to obtain multiple processed values; and then the obstacle flight time is determined according to the time corresponding to the peak position in the multiple processed values by the determination unit 502, so that the count value of the echo light signal in the histogram data can be kept basically unchanged, the count value of the ambient light signal is attenuated, the signal-to-noise ratio of the detection unit 101 is improved, the correct peak position is identified, and the accuracy of the detection unit 101 in measuring the flight time is effectively improved.
  • FIG 4 is a schematic diagram of a structural block diagram of a flight time measurement device provided in an embodiment of the present application.
  • the flight time measurement device shown in Figure 4 can implement the flight time measurement method of the embodiment shown in Figure 3.
  • the flight time measurement device shown in Figure 4 includes a first statistical unit 301, a second statistical unit 302, a calculation unit 501 and a determination unit 502.
  • the first statistical unit 301 is used to count the photon events of the detection unit 101 within the first preset time period T1 to generate an ambient light value.
  • a single detection cycle includes a first preset time period T 1 and a second preset time period T 2 .
  • the detection unit 101 performs ambient light detection in the first preset time period T 1 , and performs N detections of echo light signals in the second preset time period T 2 ; in the first preset time period T 1 , the light emitting unit 601 corresponding to the detection unit 101 does not emit light, so as to realize ambient light detection in the first preset time period T 1 .
  • the light emitting unit 601 does not emit light
  • the light signal received by the detection unit 101 in the first preset time period T 1 does not include the echo light signal
  • the photon event of the detection unit 101 in the first preset time period T 1 is generated by the ambient light.
  • the ambient light value ambl is used to indicate the average number of ambient light photons received by the detection unit 101 at each flight moment during the process of the detection unit 101 performing N echo light signal detections, that is, the average value of the number of ambient light photons included in the count value corresponding to each flight moment in the histogram data.
  • the principle of the first statistical unit 301 generating the ambient light value is:
  • the detection unit 101 receives (T 1 /t 0 ) flight moments of ambient light photons in the first preset time period T 1.
  • the ambient light value amb1 can be set according to the average number of ambient light photons S2 received at each flight moment in the process of the detection unit 101 detecting the N echo light signals, thereby indicating the average number of ambient light photons received at each flight moment in the process of the detection unit 101 detecting the N echo light signals.
  • the first statistical unit 301 includes:
  • a first accumulating unit 3011 is used to accumulate the number of photons received by the detection unit within a first preset time period to generate a first photon number accumulated value
  • the first generating unit 3012 is used to generate an ambient light value according to the first photon number accumulation value.
  • the calculation formula of the ambient light value is:
  • the first photon number cumulative value is the first photon number cumulative value Sum of the ambient light received by the detection unit 101 within the first preset time period T1 ;
  • is a gain coefficient, ⁇ is a real number, and ⁇ 1 or ⁇ >1, and the gain coefficient ⁇ is used to multiply the first photon number cumulative value of the ambient light by a number less than 1 or greater than 1, so as to adjust the size and proportion of the ambient light influence.
  • the bias coefficient ⁇ is used to add a static bias to the photon number of the ambient light, so as to eliminate the artificial static environmental background noise when the ambient light value is subtracted from the histogram data, and to improve the signal-to-noise ratio as much as possible.
  • the first generating unit 3012 includes:
  • a first multiplier MUL is used to receive a first photon number accumulated value Sum and a gain coefficient ⁇ , and perform a multiplication operation on the first photon number accumulated value Sum and the gain coefficient ⁇ to generate a product ⁇ *Sum of the first photon number accumulated value Sum and the gain coefficient ⁇ ;
  • the gain coefficient ⁇ may be set by the following formula:
  • the present application does
  • the gain coefficient ⁇ is proportional to the number of reception times N when the detection unit 101 detects the echo light signal, and is inversely proportional to the first preset time period T1 .
  • the specific value of the gain coefficient ⁇ can be set according to actual needs.
  • the bias coefficient ⁇ can be set according to the static environment background noise obtained from the actual test, and the present application does not limit the specific value of the bias coefficient ⁇ .
  • the ambient light value is calculated as follows:
  • amb1 N*[Sum/(T 1 /t 0 )]
  • the first generating unit 3012 includes a second multiplier (not shown).
  • the second multiplier is used to receive the first photon number cumulative value Sum and the coefficient N*[Sum/(T 1 /t 0 )], and perform multiplication operation on the first photon number cumulative value Sum and the coefficient N*[Sum/(T 1 /t 0 )] to generate an ambient light value.
  • the longer the first preset time period T1 is, the closer the average number of ambient light photons S0 received at each flight moment when the detection unit 101 is detecting ambient light is to the actual average number of ambient light photons received at each flight moment; accordingly, the average number of ambient light photons S2 received at each flight moment when the detection unit 101 is detecting N echo light signals is closer to the actual number of ambient light photons received at each flight moment when the detection unit 101 is detecting N echo light signals.
  • the first preset time period T1 is within a single detection cycle.
  • the duration of a single detection cycle cannot be extended indefinitely, and accordingly, the first preset time period T1 cannot be extended indefinitely.
  • the first preset time period T1 satisfies: t0 ⁇ T1 ⁇ the duration of a single detection cycle.
  • T tof the value range of the first preset time period T 1 is: T tof ⁇ T 1 ⁇ N*T tof .
  • T tof is the above-mentioned flight time statistical period
  • T tof i*T c
  • T c j*t 0
  • i and j are both positive integers greater than 1
  • T c is the clock cycle
  • t 0 is the duration of each flight moment
  • N is the number of times the detection unit 101 detects the echo optical signal in a single detection cycle, and is also the number of times the light emitting unit 101 emits the pulse optical signal in a single detection cycle.
  • the first preset time period T1 may be set by the following formula:
  • T 1 u 1 *T tof ;
  • u 1 is a positive integer, and 1 ⁇ u 1 ⁇ N.
  • the first preset time period T 1 is divided into u 1 *i clock cycles T c
  • the first preset time period T 1 is divided into u 1 *i*j flight moments. Since each flight moment corresponds to a photon number, accordingly, the first preset time period T 1 corresponds to u 1 *i*j photon numbers.
  • the number i of clock cycles T c included in the flight time statistical period T tof and the number j of flight moments included in each clock cycle T c are usually preset values.
  • the setting of the first preset time period T 1 can be completed, which simplifies the setting method of the first preset time period T 1 .
  • the first accumulating unit 3011 includes:
  • the second accumulation unit 30111 is used to accumulate the number of photons of the detection unit in each clock cycle of the first preset time period in sequence according to the clock sequence, and generate K initial photon number accumulation values in sequence; wherein each initial photon number accumulation value is the accumulation value of the number of ambient light photons received by the detection unit in one clock cycle;
  • the third accumulating unit 30112 is used to accumulate K initial photon number accumulated values to generate a first photon number accumulated value; the first photon number accumulated value Sum satisfies:
  • T 1 u 1 *i*T c
  • K u 1 *i.
  • the third accumulator unit 30112 includes a first data selector MUX, a second accumulator A2 and a first register; the first data selector MUX includes a first input terminal, a second input terminal, an output terminal and a control terminal; the first input terminal of the first data selector MUX is used to receive the K initial photon number accumulation values outputted sequentially by the second accumulator 30111 in the order of the clock cycle, the second input terminal of the first data selector MUX receives data 0, the control terminal of the first data selector MUX receives a first statistical control signal, and the output terminal of the first data selector MUX is connected to an input terminal of the second accumulator A2; the second accumulator A2 includes two input terminals and an output terminal, and one input terminal of the second accumulator A2 is connected to the first data selector MUX.
  • the output end of the selector MUX is connected, the other input end of the second accumulator A2 is connected to the feedback end of the first register, and the output end of the second accumulator A2 is connected to the input end of the first register;
  • the first register includes an input end, an output end and a feedback end;
  • the input end of the first register is connected to the output end of the second accumulator A2, and the output end of the first register is connected to the first generating unit 3012 for outputting the first photon number accumulated value Sum;
  • the feedback end of the first register is connected to the other input end of the second accumulator A2.
  • the working process of the third accumulator 30112 is as follows: the first statistical control signal controls the first data selector MUX to sequentially select the K initial photon number cumulative values output by the second accumulator 30111 in the order of the clock cycle for output, and after the first data selector MUX completes the output of the K initial photon number cumulative values, controls the first data selector MUX to select data 0 for output; for example, in the 1st to Kth clock cycles, the first statistical control signal is at a high level, and the high-level first statistical control signal is used to control the first data selector MUX to select the data at the first input end, that is, the second accumulator 30111 selects the K initial photon number cumulative values output by the second accumulator 30111 in the order of the clock cycle.
  • the K initial photon number cumulative values output in a periodic sequence are output; after exceeding the Kth clock cycle, the first statistical control signal is switched to a low level, and the low-level first statistical control signal is used to control the first data selector MUX to select the data of the second input terminal, that is, data 0 for output; the first data selector MUX outputs the K initial photon number cumulative values to the second accumulator A2 in sequence; the second accumulator A2 cooperates with the first register to perform K-1 accumulation processes to achieve the accumulation of the K initial photon number cumulative values, generate the first photon number cumulative value, and then the first register outputs the photon number cumulative value to the first generation unit 3012. Among them, the second accumulator A2 cooperates with the first register to perform K-1 accumulation processes as follows:
  • the first accumulation process the second accumulator A2 outputs the received first initial photon number accumulation value to the first register, and the first register feeds back the first initial photon number accumulation value to the second accumulator A2.
  • the second accumulator A2 receives the second initial photon number accumulation value
  • the second accumulator A2 adds the second initial photon number accumulation value to the first initial photon number accumulation value to generate the first accumulation result
  • the second accumulator A2 outputs the first accumulation result to the first register again.
  • Second accumulation process the first register feeds back the first accumulation result to the second accumulator A2, and when the second accumulator A2 receives the third initial photon number accumulation value, the second accumulator A2 adds the third initial photon number accumulation value and the first accumulation result to generate a second accumulation result, and the second accumulator A2 outputs the second accumulation result to the first register again;
  • the first register feeds back the K-2th accumulation result (the accumulated value of the 1st to K-1th initial photon number accumulated values) to the second accumulator A2, and when the second accumulator A2 receives the Kth initial photon number accumulated value, the second accumulator A2 adds the Kth initial photon number accumulated value and the K-2th accumulation result to generate the K-1th accumulation result (the accumulated value of the 1st to Kth initial photon number accumulated values), that is, the first photon number accumulated value.
  • Each clock cycle includes four flight moments, and the four flight moments correspond to four photon numbers P 0 , P 1 , P 2 , and P 3 , respectively.
  • Each initial accumulated value is the four photon numbers P 0 , P 1 , P 2 , and P 3 corresponding to the four flight moments included in a clock cycle.
  • the second accumulation unit 30111 includes three accumulators, wherein the first accumulator is used to perform an addition operation on P0 and P1 to obtain the sum of P0 and P1 ; the second accumulator is used to perform an addition operation on P2 and P3 to obtain the sum of P2 and P3 ; the third accumulator is connected to the output end of the first accumulator and the output end of the second accumulator, and is used to perform an addition operation on the sum of P0 and P1 and the sum of P2 and P3 to obtain the sum of four photon numbers P0 , P1 , P2 , and P3 corresponding to the four flight moments included in each clock cycle, that is, the accumulated value of the initial photon number corresponding to each clock cycle.
  • the data format can be set according to the data type.
  • the data format of the gain coefficient a is U4.6
  • the data format of the bias coefficient ⁇ is U10.0
  • the data format of the first photon number accumulated value Sum of the ambient light received by the detection unit 101 in the first preset time period is U11.0
  • the data format of the ambient light value amb1 is U11.0.
  • the flight time measurement device further includes a storage unit 401 ; the ambient light value ambl generated by the first statistical unit 301 is stored in the storage unit 401 .
  • the ambient light value amb1 is stored in a storage space at address a0 in the storage unit 401.
  • the flight time measurement device further includes a first position limiting saturation unit (not shown), the input end of the first position limiting saturation unit is connected to the first statistical unit 301, the output end of the first position limiting saturation unit is connected to the storage unit 401, the first position limiting saturation unit performs position limiting saturation processing on the ambient light value amb1, and the ambient light value amb1 processed by the first position limiting saturation unit is stored in the storage unit 401.
  • the ambient light value amb1 processed by the position limiting saturation is stored in the storage space with the address a0 in the storage unit 401.
  • the limit saturation process is to prevent data overflow caused by too long photon number statistics time. If the data (the first photon number cumulative value) exceeds the maximum value of the data that can be stored in the required data format, the maximum value is used to represent the data (i.e., the first photon number cumulative value); if the first photon number cumulative value exceeds the minimum value of the data that can be stored in the required data format, the minimum value is used to represent the data (i.e., the first photon number cumulative value).
  • the second statistical detection unit 302 is used to count the photon events of the detection unit 101 within a second preset time period to generate histogram data.
  • the histogram data includes Z flight times and Z count values corresponding to the Z flight times, where Z is a positive integer greater than 1.
  • the second preset time period T 2 includes N flight time statistical periods T tof
  • the light emitting unit 601 corresponding to the detection unit 101 emits N pulse light signals at the start time of the N flight time statistical periods T tof .
  • the detection unit 101 receives N light signals in the first flight time statistical period T tof to the Nth flight time statistical period T tof to detect N echo light signals.
  • the light emitting unit 601 emits a pulse light signal at the start time of the 1st flight time statistical period T tof to the Nth flight time statistical period T tof
  • the light signal received by the detection unit 101 within the 1st flight time statistical period T tof to the Nth flight time statistical period T tof includes an echo light signal and an ambient light signal
  • the photon event of the detection unit 101 within the 1st flight time statistical period T tof to the Nth flight time statistical period T tof is generated by the echo light signal and the ambient light signal.
  • the count values in the histogram data are respectively used to indicate the cumulative values of the number of photons corresponding to the same flight time in the N flight time statistical periods T tof .
  • the histogram data can be generated by superimposing the N flight time data sets corresponding to the N flight time statistical periods T tof .
  • the second preset time period T2 includes N flight time statistical cycles T tof .
  • Each flight time statistical cycle T tof includes i clock cycles T c , and each clock cycle T c is divided into j flight moments.
  • the second preset time period T2 also includes N emission time intervals T21 , and the N emission time intervals Ttx are respectively located before the start time of the N flight time statistical periods Ttf .
  • the light emitting unit 601 emits light in each emission time interval Ttx to transmit N pulse light signals at the start time of the first flight time statistical period Ttf to the Nth flight time statistical period Ttf .
  • tx_en is a first control signal, used to trigger the light emitting unit 601 to emit N pulse light signals within the second preset time period T 2.
  • tof_en is a first receiving control signal, used to trigger the detection unit 102 to detect N echo light signals within the second preset time period T 2.
  • env_en is a second control signal, used to trigger the detection unit 101 to perform ambient light detection within the first preset time period T 1 .
  • tx_en includes N first high-level pulses Pulse1 in a single detection cycle, the pulse width of each first high-level pulse Pulse1 is equal to the emission time interval T tx , and the time interval between the falling edges of two adjacent first high-level pulses Pulse1 is equal to the flight time statistical period T tof .
  • the N first high-level pulses Pulse1 are evenly spaced in the second preset time period T 2 , and the first first high-level pulse Pulse1 is located at the start time of the second preset time period T 2.
  • tx_en triggers the light-emitting unit 601 to emit N pulse light signals through the high level of the N first high-level pulses Pulse1.
  • tof_en includes N second high-level pulse signals Pulse2 in a single detection cycle, and the pulse width of each first high-level pulse Pulse1 is equal to the flight time statistical period T tof .
  • the rising edges of the N second high-level pulse signals Pulse2 are respectively aligned with the falling edges of the N first high-level pulses Pulse1.
  • the falling edges of the 1st second high-level pulse signal Pulse2 to the N-1st second high-level pulse signal Pulse2 are respectively aligned with the rising edges of the 2nd first high-level pulse signal Pulse1 to the rising edges of the Nth first high-level pulse signal Pulse1.
  • tof_en triggers the receiving unit 101 to detect the echo optical signal N times through the high levels of the N second high-level pulse signals Pulse2.
  • env_en includes a third high-level pulse signal Pulse3 in a single detection cycle.
  • the pulse width of the third high-level pulse signal Pulse3 is equal to the first preset time period T2 .
  • the falling edge of the third high-level pulse signal Pulse3 is aligned with the rising edge of the first first high-level pulse Pulse1, that is, the end time of the first preset time period T1 is equal to the start time of the second preset time period T2 .
  • Env_en triggers the receiving unit 101 to detect the ambient light signal through the high level of the third high-level pulse signal Pulse3.
  • the second statistical unit 302 generates histogram data by superimposing N flight time data sets.
  • N flight time data sets are used to indicate the photon events in N flight time statistical cycles, i.e., the first flight time statistical cycle T tof to the Nth flight time statistical cycle T tof , of the detection unit 101 within the second preset time period T 2.
  • Each flight time data set includes each flight time period of a flight time statistical cycle and the number of photons corresponding to each flight time period.
  • the horizontal axis of the flight time data set represents each flight moment in a flight time statistical cycle, and the vertical axis represents the number of photons corresponding to each flight moment.
  • the position of the light signal (ambient light signal or echo light signal) on the horizontal axis of the flight time data set represents the arrival time of the light signal
  • the value of the light signal on the vertical axis of the flight time data set is used to indicate the number of photons.
  • superimposing N flight time data sets is to align the N flight time data sets according to the flight time, and then accumulate the number of photons at the same flight time, that is, to accumulate the number of photons of N groups corresponding to each flight time, so as to realize that each count value in the histogram data is used to indicate the accumulated value of the number of photons corresponding to each flight time after the N flight time data sets are superimposed.
  • each flight time statistical cycle T tof includes i clock cycles T c
  • each clock cycle T c is divided into j flight moments. Accordingly, the number of flight moments included in each flight time data set is equal to i*j, and the i*j flight moments correspond to i*j photon numbers. Accordingly, the flight moments Z included in the histogram data are i*j, and the Z flight moments correspond to i*j count values.
  • the histogram data generated by the second statistical unit 302 is stored in the storage unit 401 .
  • the histogram data is stored in the storage space with addresses a1 to ai in the storage unit 401.
  • Each storage space includes j sub-storage spaces.
  • the j sub-storage spaces in the storage space with address a1 are used to store the j count values corresponding to the j flight moments in the first clock cycle
  • the j sub-storage spaces in the storage space with address a2 are used to store the j count values corresponding to the j flight moments in the second clock cycle...
  • the j sub-storage spaces in the storage space with address ai are used to store the j count values corresponding to the j flight moments in the i-th clock cycle, so that the i*j sub-storage spaces formed by the i storage spaces respectively store the i*j count values in the histogram data.
  • Each clock cycle includes four flight times, and the four flight times correspond to four photon numbers P 0 , P 1 , P 2 , and P 3 , respectively.
  • the second statistical unit 302 includes four statistical sub-units 3020 - 3023 .
  • the first-path statistical unit 3020 includes an accumulator A20, a selector MUX20, a storage unit wdat20 and a readout unit rdat20; one input end of the accumulator A20 is used to receive the number of photons P0 corresponding to the first flight moment of each clock cycle of the detection unit 101 in each flight time statistical cycle, the other input end of the accumulator A0 is connected to the readout unit rdat20, the output end of the accumulator A0 is connected to an input end of the selector MUX220, the other input end of MUX20 receives data 0, the output end of the selector MUX20 is connected to the storage unit wdat20, the storage unit wdat20 is configured to be connected to the first sub-storage space in the storage space with addresses a1 ⁇ ai in the storage unit 401, and the readout unit rdat20 is also configured to be connected to the first sub-stor
  • the first flight time statistical cycle stage the selector MUX20 selects the output result of the accumulator A0 for output under the control of the second statistical control signal; first, the accumulator A20 receives the photon number P0 corresponding to the first flight moment of the first clock cycle in the first flight time statistical cycle, and outputs it to the storage unit wdat20 through the selector MUX20, and the storage unit wdat20 stores the photon number P0 in the first sub-storage space of the storage space with the address a1 under the control of the storage control signal; the accumulator A20 receives the photon number P0 corresponding to the first flight moment and outputs it to the storage unit wdat20 through the selector MUX20, and the storage unit wdat20 stores the photon number P0 in the first sub-storage space of the storage space with the address a2 under the control of the storage control signal...
  • the storage unit wdat20 stores the photon number P 0 into the first sub-storage space of the storage space with the address ai under the control of the storage control signal.
  • the second flight time statistical cycle stage while the accumulator A20 receives the photon number P0 corresponding to the first flight moment of the first clock cycle in the second flight time statistical cycle, the read-out unit rdat20 reads out the data stored in the first sub-storage space of the storage space with the address a1 under the control of the read-out control signal (that is, the photon number P0 corresponding to the first flight moment of the first clock cycle of the first flight time statistical cycle of the detection unit 101), and sends it to the accumulator A20, so that the accumulator A20 can accumulate the photon number P0 corresponding to the first flight moment of the first clock cycle of the detection unit 101 in the first flight time statistical cycle and the second flight time statistical cycle respectively.
  • the accumulator A20 outputs the accumulated value to the storage unit wdat20 through the selector MUX20, and the storage control signal controls the storage unit wdat20 to store the accumulated value in the storage space with the address a1.
  • the read-out unit rdat20 reads out the data stored in the first sub-storage space of the storage space with the address ai under the control of the read-out control signal (that is, the photon number P0 corresponding to the first flight moment of the i-th clock cycle of the detection unit 101 in the first flight time statistical period), and sends it to the accumulator A20, so that the accumulator A20 can accumulate the photon number P0 corresponding to the first flight moment of the i-th clock cycle of the detection unit 101 in the first flight time statistical period and the second flight time statistical period, and the accumulator A
  • the first-path statistical unit 3020 completes the superposition of the number of photons P 0 corresponding to the first flight moment of each clock cycle of the detection unit 101 in the first flight time statistical cycle to the second flight time statistical cycle.
  • the first-path statistical unit 3020 continues to perform the superposition action of the 3rd flight time statistical cycle stage to the Nth flight time statistical cycle stage to complete the N-time superposition of the number of photons P 0 corresponding to the first flight moment of each clock cycle of the detection unit 101 in the 1st flight time statistical cycle to the Nth flight time statistical cycle.
  • the selector MUX20 selects the output data 0 to the storage unit wdat20 under the control of the second statistical control signal, and the first-path statistical unit 3020 stops the superposition action.
  • the second-path statistical unit 3021 completes N superpositions of the number of photons P1 corresponding to the second flight moment of each clock cycle in the 1st flight time statistical cycle to the Nth flight time statistical cycle by executing N superposition actions from the 1st flight time statistical cycle stage to the Nth flight time statistical cycle stage;
  • the third-path statistical unit 3022 completes N superpositions of the number of photons P2 corresponding to the third flight moment of each clock cycle in the 1st flight time statistical cycle to the Nth flight time statistical cycle by executing N superposition actions from the 1st flight time statistical cycle stage to the Nth flight time statistical cycle stage;
  • the fourth-path statistical unit 3023 completes N superpositions of the number of photons P2 corresponding to the fourth flight moment of each clock cycle in the 1st flight time statistical cycle to the Nth flight time statistical cycle by executing N superposition actions from the 1st flight time statistical cycle stage to the Nth flight time statistical cycle stage.
  • j may be another positive integer not equal to 4; accordingly, the second statistical unit 302 includes j-way statistical units.
  • the structure and working principle of each way statistical unit are substantially the same as the structure and working principle of the first sub-statistical unit 3020 described above, and are not described in detail here.
  • the present application does not limit the specific value of the number j of flight times included in each clock cycle Tc .
  • the calculation unit 501 is used to subtract the ambient light value from the Z count values respectively to generate Z processing values corresponding to each of the Z count values.
  • the storage unit 401 includes storage spaces with addresses a0 to ai , wherein the storage space with address a0 is used to store the ambient light value amb1, and the storage space with addresses a1 to ai is used to store the histogram data.
  • the calculation unit 501 includes:
  • An acquisition and output unit 5011 is used to acquire and output the ambient light value and Z count values
  • the subtractor 5012 is used to receive the ambient light value and Z count values, and perform subtraction operations on the Z count values from the ambient light value to generate Z processed values.
  • the acquisition and output unit 5011 includes:
  • the first acquisition and output unit 50111 is used to acquire and output the ambient light value
  • the second acquisition and output unit 50112 is used to acquire Z count values and output the Z count values in sequence according to the flight time sequence.
  • outputting Z count values in sequence according to the flight times is according to the i*j flight times in each flight time statistical period T tof , that is, outputting Z count values corresponding to each flight time in sequence according to the Z flight times.
  • obtaining Z count values and outputting the Z count values in sequence according to the flight time sequence in each flight time statistical period includes:
  • each group of count values includes j count values corresponding to j flight moments included in one clock cycle;
  • j count values corresponding to the j flight times included in each clock cycle are output in sequence.
  • sequentially acquiring i groups of count values corresponding to i clock cycles in the order of clock cycles is sequentially acquiring i groups of count values corresponding to i clock cycles stored in the storage unit 401 in the order of i clock cycles in each flight time statistical period T tof .
  • the j count values corresponding to the j flight times included in each clock cycle are output in sequence.
  • the j count values are output in sequence according to the order of flight times in each clock cycle.
  • the second acquisition and output unit 50112 may adopt a shift register, which is configured to sequentially acquire i groups of count values corresponding to i clock cycles stored in the storage unit 401 according to the clock cycle sequence in the flight time statistical cycle, wherein each group of count values includes j count values corresponding to j flight moments included in one clock cycle; the shift register is used to shift and output the received multiple parallel data, so as to sequentially output the j count values included in each group of count values acquired according to the flight moment sequence in the clock cycle.
  • a shift register which is configured to sequentially acquire i groups of count values corresponding to i clock cycles stored in the storage unit 401 according to the clock cycle sequence in the flight time statistical cycle, wherein each group of count values includes j count values corresponding to j flight moments included in one clock cycle; the shift register is used to shift and output the received multiple parallel data, so as to sequentially output the j count values included in each group of count values acquired according to the flight moment sequence in the clock cycle.
  • the shift register when the shift register acquires the first group of count values corresponding to the first clock cycle stored in the storage unit 401, that is, the j count values corresponding to the j flight moments included in the first clock cycle, the shift register shifts and outputs the j count values according to the flight moment sequence in the clock cycle, so as to sequentially output the j count values included in the first group of count values acquired according to the flight moment sequence in the clock cycle.
  • the shift register When the shift register obtains the second group of count values corresponding to the second clock cycle stored in the storage unit 401, that is, the j count values corresponding to each of the j flight moments included in the second clock cycle, the shift register shifts and outputs the j count values in the order of flight moments in the clock cycle, so that the j count values included in the second group of count values are obtained and output in sequence in the order of flight moments in the clock cycle...
  • the shift register obtains the i-th group of count values corresponding to the i-th clock cycle stored in the storage unit 401, that is, the j count values corresponding to each of the j flight moments included in the i-th clock cycle
  • the shift register shifts and outputs the j count values in the order of flight moments in the clock cycle, so that the j count values included in the i-th group of count values are obtained and output in sequence in the order of flight moments in the clock cycle.
  • the shift register can obtain Z count values and output Z count values
  • the j count values corresponding to the j flight moments included in each clock cycle are hist_dat0, hist_dat1, ..., hist_dat(j-1) respectively.
  • the second acquisition and output unit 50112 acquires the j count values hist_dat0, hist_dat1, ..., hist_dat(j-1) corresponding to each clock cycle
  • the j count values hist_dat0, hist_dat1, ..., hist_dat(j-1) are shifted and output in the order of the flight moments, so that the subtractor 5012 can sequentially subtract the j count values hist_dat0, hist_dat1, ..., hist_dat(j-1) from the ambient light value amb1 in the order of the flight moments, and obtain j processing values corresponding to the j count values hist_dat0, hist_dat1, ..., hist_dat(j-1).
  • i groups of count values corresponding to i clock cycles are respectively stored in storage spaces with addresses a 1 to a i in the storage unit 401.
  • the shift register is configured to point to the addresses a 1 to a i in sequence according to the clock cycle sequence in each flight time statistical cycle, so as to obtain the i groups of count values stored in the storage spaces with addresses a 1 to a i in the storage unit according to the clock cycle in each flight time statistical cycle.
  • the ambient light value ambl is stored in the storage space with address a0 in the storage unit 401, and the first acquisition and output unit 50111 acquires the ambient light value from the storage space with address a0 in the storage unit, and outputs the acquired ambient light value ambl.
  • the output time of the ambient light value covers the output time of the Z count values, so as to facilitate the subtraction operation between each count value and the ambient light value.
  • the output time of the Z count values can be determined in the design stage, for example, the output time range of the Z count values is preset to be t 21 ⁇ t 22 .
  • the output time range of the ambient light value is made to be t 11 ⁇ t 12 , wherein t 11 ⁇ t 21 , t 12 > t 22 , so that the output time of the ambient light value covers the output time of the Z count values, thereby facilitating the subtraction operation of each count value from the ambient light value.
  • the subtractor 5012 receives the ambient light value and Z count values, and performs subtraction operations on the Z count values from the ambient light value to generate Z processed values.
  • the flight time measurement device also includes a second limit saturation unit (not shown), the input end of the second limit saturation unit is connected to the output end of the calculation unit 501, and the output end is connected to the input end of the determination unit 502, for performing limit saturation processing on the Z processed values, and outputting the Z processed values after the limit saturation processing to the determination unit 502.
  • a second limit saturation unit (not shown)
  • the input end of the second limit saturation unit is connected to the output end of the calculation unit 501
  • the output end is connected to the input end of the determination unit 502, for performing limit saturation processing on the Z processed values, and outputting the Z processed values after the limit saturation processing to the determination unit 502.
  • the limit saturation process is to prevent the data (i.e., the processing value) from overflowing due to the long photon counting time. If the data exceeds the maximum value of the data that can be stored in the required data format, the maximum value is used to represent the data; if the data exceeds the minimum value of the data that can be stored in the required data format, the minimum value is used to represent the data.
  • the determining unit 502 is configured to determine the flight time according to the Z processing values.
  • the determination unit 502 can determine the flight time of the obstacle according to the time corresponding to the peak position in the Z processed values.
  • the determination unit 502 can determine the flight time of the obstacle according to the time corresponding to the peak position in the Z processed values after position limiting saturation processing.
  • the flight time measurement device counts the photon events of the detection unit 101 within a first preset time period through a first statistical unit 301 to generate an ambient light value, and counts the photon events of the detection unit 101 within a second preset time period through a second statistical unit 302 to generate histogram data; then, the ambient light value is subtracted from the multiple count values in the histogram data to obtain multiple processed values; the flight time of the obstacle is determined according to the time corresponding to the peak position in the multiple processed values, so that the count value of the echo light signal in the histogram data can be kept basically unchanged, the count value of the ambient light signal is attenuated, the signal-to-noise ratio of the detection unit 101 is improved, the correct peak position is identified, and the accuracy of the detection unit 101 in measuring the flight time is effectively improved.
  • the above-mentioned flight time measurement device also includes an emitter 60, a detector 10, a sampling module 20 and a storage module 40;
  • the emitter includes a light emitting unit 601 for emitting a light signal.
  • the detector 10 includes a detection unit 101 for receiving a light signal and converting the received light signal into an electrical signal.
  • the sampling module includes a sampling unit 201 for generating flight time data according to the electrical signal converted by the detection unit 101, and the flight time data is used to indicate the flight time and the number of photons corresponding to the flight time.
  • the storage module 40 includes the above-mentioned storage unit 401 for storing ambient light values and histogram data.
  • FIG9 shows a schematic structural diagram of a laser ranging device provided in an embodiment of the present application.
  • the laser ranging device may include: a transmitter 60, a detector 10, a processor 910, a communications interface 920, a memory 930, and a communication bus 940.
  • the transmitter 60 includes one or more light-emitting units 601 for emitting pulsed light signals.
  • the detector 10 includes one or more detection units 101 for receiving light signals. Each light-emitting unit 601 corresponds to one or more detection units 101.
  • the processor 910, the communications interface 920, and the memory 930 communicate with each other through the communication bus 940.
  • the communications interface 920 is used to communicate with network elements of other devices such as clients or other servers.
  • the memory 930 is used to store computer programs or instructions 903 for implementing the above method embodiments (i.e., flight time measurement methods) or the device embodiments (i.e., flight time test devices) of the various modules.
  • the processor 910 is connected to the transmitter 60 and the detector 10 via the communication interface 920 and is used to call the computer program or instruction 903 to execute the operations of the above method embodiment, such as S11 to S14 shown in FIG. 2 .
  • the laser ranging device provided in the present application generates a point cloud map through the flight time determined by the above-mentioned method embodiments or device embodiments, and obtains parameters such as the distance, direction, height, speed, posture and shape of the obstacle by processing the point cloud map, thereby realizing the laser detection function, and can be applied to navigation avoidance, obstacle recognition, ranging, speed measurement, automatic driving and other scenarios of products such as automobiles, robots, logistics vehicles and inspection vehicles.
  • the emitter 60 includes a light emitting unit 601.
  • the emitter 60 can be a vertical cavity surface emitting laser (Vertical-Cavity Surface-Emitting Laser, VCSEL), an edge emitting laser (Edge Emitting Laser, EEL), a light emitting diode (Light Emitting Diode, LED), a micro light emitting diode (Micro Light Emitting Diode, Micro LED), a pulsed laser deposition (Pulsed Laser Deposition, PLD) or a laser diode (Laser Diode, LD), etc., and the present application does not limit the type of the emitter 60.
  • VCSEL Vertical-Cavity Surface-Emitting Laser
  • EEL Edge emitting laser
  • a light emitting diode Light Emitting Diode
  • LED Light Emitting Diode
  • Micro LED Micro Light Emitting Diode
  • PLD Pulsed Laser Deposition
  • PLD laser diode
  • Laser Diode Laser Dio
  • the emitter 60 includes a plurality of light emitting units 601; the plurality of light emitting units 601 may be arranged in an array, that is, the emitter 60 may be a laser array.
  • the emitter 60 may be a vertical-cavity surface-emitting laser (VCSEL) array, an edge emitting laser (EEL) array, a light emitting diode (LED) array, a micro light emitting diode (Micro LED) array, a pulsed laser deposition (PLD) array or a laser diode (LD) array, etc., and the present application does not limit the type of the emitter 60.
  • VCSEL vertical-cavity surface-emitting laser
  • EEL edge emitting laser
  • LED light emitting diode
  • Micro LED micro light emitting diode
  • PLD pulsed laser deposition
  • LD laser diode
  • the detector 10 includes a detection unit 101.
  • the detector 10 may be a single photon avalanche diode (SPAD) or a silicon photomultiplier (SIPM), and the present application does not limit the type of the detector 10.
  • the detector 10 includes a plurality of detection units 101, and the plurality of detection units 101 are arranged in an array, that is, the detector 10 may be a detector array.
  • the detector 10 may be a single photon avalanche diode (SPAD) array or a silicon photomultiplier (SIPM) array, and the present application does not limit the type of the detector 10.
  • the transmitter 60 includes a plurality of light emitting units 601
  • the plurality of light emitting units 601 may emit light in sequence to scan and emit the pulse light signal to the detection area to scan obstacles in the detection area. Accordingly, the detection unit 101 in the detector 10 is used to detect the echo light signal reflected by the obstacles in the detection area.
  • the processor 910 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application specific integrated circuits (ASIC), off-the-shelf programmable gate arrays (FPGAs), or a plurality of other processors.
  • CPU central processing unit
  • DSP digital signal processors
  • ASIC application specific integrated circuits
  • FPGAs off-the-shelf programmable gate arrays
  • the general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc.
  • the memory 930 may be an internal storage unit of the laser distance measuring device, such as a hard disk or memory of the laser distance measuring device.
  • the memory 930 may also be an external storage device of the laser distance measuring device, such as a plug-in hard disk, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), etc. equipped on the laser distance measuring device.
  • the memory 930 may also include both an internal storage unit and an external storage device of the laser distance measuring device.
  • the memory 930 is used to store the computer program and other programs and data required by the terminal device.
  • the memory 930 may also be used to temporarily store data that has been output or is to be output.
  • the embodiment of the present application further provides a computer-readable storage medium.
  • the computer-readable storage medium stores at least one executable instruction, and when the executable instruction is executed by a processor, the above-mentioned flight time measurement method is implemented.
  • An embodiment of the present application provides a computer program product.
  • the laser ranging device can implement the above-mentioned flight time measurement method when executing the computer program product.
  • the technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example.
  • the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the terminal device is divided into different functional units or modules to complete all or part of the functions described above.
  • the functional units and modules in the embodiment can be integrated into a processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
  • the above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units.

Landscapes

  • Optical Radar Systems And Details Thereof (AREA)

Abstract

一种飞行时间测量方法、装置、激光测距装置及存储介质,适用于飞行时间测量技术领域。该方法包括:统计探测单元在第一预设时间段内的光子事件,生成环境光数值(S11);统计探测单元在第二预设时间段内的光子事件,生成直方图数据,其中,直方图数据包括Z个飞行时刻以及Z个飞行时刻各自对应的Z个计数值(S12);将Z个计数值分别减去环境光数值,生成与Z个计数值各自对应的Z个处理值(S13);根据Z个处理值确定飞行时间(S14)。该方法通过将多个计数值分别减去环境光数值,得到多个处理值,可以使直方图数据中回波光信号的计数值基本保持不变,环境光信号的计数值得到衰减,提高探测单元的信噪比,便于确定正确的飞行时间,有效提高测量飞行时间的准确度。

Description

飞行时间测量方法、装置、激光测距装置及存储介质 技术领域
本申请属于飞行时间测量技术领域,尤其涉及一种飞行时间测量方法、装置、激光测距装置及存储介质。
背景技术
飞行时间(time of flight,TOF)测量技术在自动驾驶、人脸识别、3D手势识别等领域有着重要的应用。在飞行时间测量***中,发射器发射脉冲信号,探测器,比如单光子雪崩二极管(single photon avalanche diode,SPAD)接收到回波光信号进行光电转换和雪崩效应产生脉冲电信号,探测器将脉冲电信号传递给采样电路,比如时间转换器(time-to-digital converter,TDC),由采样电路记录脉冲电信号的时间。再根据采样电路记录的脉冲电信号的时间统计得到直方图数据,并将直方图数据写入存储单元,写入存储单元的直方图数据则需要输出给后级的信号处理部分进行处理,由信号处理部分根据直方图数据确定飞行时间,以根据飞行时间计算激光器与物体之间的距离。
但是,由于探测器的高灵敏度特性,探测器接收的光信号除回波光信号之外,还可能存在环境光信号。探测单元可能无法正确区分接收到的信号哪些是环境光信号,哪些是回波光信号,导致将环境光信号当成回波光信号去计算飞行时间,从而无法识别正确的飞行时间。
发明内容
本申请实施例提供了一种飞行时间测量方法、装置、终端设备及计算机可读存储介质,以解决目前的飞行时间的测量过程受环境光信号影响,导致探测性能差的问题。
第一方面,本申请提供了一种飞行时间测量方法,包括:
统计探测单元在第一预设时间段内的光子事件,生成环境光数值;
统计探测单元在第二预设时间段内的光子事件,生成直方图数据;其中,所述直方图数据包括Z个飞行时刻以及Z个飞行时刻各自对应的Z个计数值,Z为大于1的正整数;
将Z个所述计数值分别减去所述环境光数值,生成与Z个所述计数值各自对应的Z个处理值;
根据Z个处理值确定飞行时间;
其中,所述第一预设时间段和所述第二预设时间段位于单个探测周期内;在所述第一预设时间段内,与所述探测单元对应的发光单元不发射脉冲光信号;在所述第二预设时间段内,与所述探测单元对应的发光单元发射N次脉冲光信号,N为大于1的正整数。
第二方面,本申请还提供了一种飞行时间测量装置,该飞行时间测量装置采用上述飞行时间测量方法;所述飞行时间测量装置包括:
第一统计单元,用于统计探测单元在第一预设时间段内的光子事件,生成环境光 数值;
第二统计单元,用于统计探测单元在第二预设时间段内的光子事件,生成直方图数据;其中,所述直方图数据包括Z个飞行时刻以及Z个飞行时刻各自对应的Z个计数值,Z为大于1的正整数;
计算单元,用于将Z个所述计数值分别减去所述环境光数值,生成与Z个所述计数值各自对应的Z个处理值;
确定单元,用于根据Z个处理值确定飞行时间;
其中,所述第一预设时间段和所述第二预设时间段位于单个探测周期内;在所述第一预设时间段内,与所述探测单元对应的发光单元不发射脉冲光信号;在所述第二预设时间段内,与所述探测单元对应的发光单元发射N次脉冲光信号,N为大于1的正整数。
第三方面,本申请实施例提供一种激光测距装置,包括:发射器、探测器、处理器、通信接口、存储器以及通信总线;所述处理器通过所述通信接口与所述发射器和所述探测器进行通信;所述处理器、通信接口以及存储器通过所述通信总线完成相互间的通信;所述发射器包括一个或多个发光单元,用于发射脉冲光信号;所述探测器包括一个或多个探测单元,用于接收光信号;所述存储器用于存储计算机程序或指令;所述处理器用于执行所述存储器中的计算机程序或指令实现如上所述的飞行时间测量方法。
第四方面,本申请实施例提供一种计算机可读存储介质,所述计算机可读存储介质存储有至少一可执行指令,所述可执行指令被处理器执行时实现如上所述的飞行时间测量方法。
第五方面,本申请实施例提供一种计算机程序产品,当计算机程序产品在激光测距装置上运行时,使得激光测距装置执行上述飞行时间测量方法。
本申请实施例与现有技术相比存在的有益效果是:
本申请实施例提供了一种飞行时间测量方法、装置、终端及存储介质,通过统计探测单元在第一预设时间段内的光子事件,生成环境光数值,以及统计探测单元在第二预设时间段内的光子事件,生成直方图数据;然后将直方图数据中的多个计数值分别减去环境光数值,得到与多个计数值一一对应的多个处理值;再根据多个处理值确定飞行时间,从而可以使直方图数据中回波光信号的计数值基本保持不变,环境光信号的计数值得到衰减,提高探测单元的信噪比,便于确定正确的飞行时间,有效提高测量飞行时间的准确度。
附图说明
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。
图1A是本申请实施例提供的飞行时间测量装置的一种架构示意图;
图1B是本申请实施例提供的飞行时间测量装置生成直方图数据的原理示意图;
图2是本申请实施例提供的一种飞行时间测量方法的流程示意图;
图3是本申请实施例提供的一种飞行时间测量方法中发光单元发射光信号和探测单元接收光信号的时序示意图;
图4是本申请实施例提供的飞行时间测量装置的另一种结构框图示意图;
图5是本申请实施例提供的第一统计单元的一种结构框图示意图;
图6是本申请实施例提供的第一统计单元的一种结构示意图;
图7是本申请实施例提供的第二统计单元的一种结构示意图;
图8是本申请实施例提供的飞行时间测量装置的另一种结构示意图;
图9是本申请实施例提供的一种终端设备的结构示意图。
具体实施方式
以下描述中,为了说明而不是为了限定,提出了诸如特定***结构、技术之类的具体细节,以便透彻理解本申请实施例。然而,本领域的技术人员应当清楚,在没有这些具体细节的其它实施例中也可以实现本申请。在其它情况中,省略对众所周知的***、装置、电路以及方法的详细说明,以免不必要的细节妨碍本申请的描述。
需要说明的是,当一个单元被称为是“连接于”另一个单元,它可以是直接连接到另一个单元或间接连接至该另一个单元上。应当理解,在本申请说明书和所附权利要求书中使用的术语“和/或”是指相关联列出的项中的一个或多个的任何组合以及所有可能组合,并且包括这些组合。另外,在本申请说明书和所附权利要求书的描述中,术语“第一”、“第二”、“第三”、“第四”等仅用于区分描述,而不能理解为指示或暗示相对重要性。
还应当理解,在本申请说明书中描述的参考“一个实施例”或“一些实施例”等意味着在本申请的一个或多个实施例中包括结合该实施例描述的特定特征、结构或特点。由此,在本说明书中的不同之处出现的语句“在一个实施方式中”、“在一些实施例实施方式”、“在其他一些实施方式中”、“在另外一些实施方式中”等不是必然都参考相同的实施例,而是意味着“一个或多个但不是所有的实施方式”,除非是以其他方式另外特别强调。术语“包括”、“包含”、“具有”及它们的变形都意味着“包括但不限于”,除非是以其他方式另外特别强调。
请参阅图1A,图1A为本申请提供的一种飞行时间测量***的架构图。如图1所示,飞行时间测量***包括发射器60、探测器10、采样模组20以及存储模组40;发射器60包括发光单元601,探测器10包括探测单元101,采样模组包括采样单元201,存储模组40包括存储单元401。
在一些实施方式中,发射器60包括一个或多个发光单元601,每个发光单元601与一个或多个探测单元601对应,用于发射脉冲光信号。探测器10包括一个或多个探 测单元101,探测单元101可以采用单光子雪崩二极管(Single Photon Avalanche Diode,SPAD)或硅光电倍增管(Silicon photomultiplier,SIPM),用于探测回波光信号;采样单元201与探测单元101连接,用于飞行时间数据。采样单元201可以采用时间数字转换器(Time-to-Digital Converters,TDC)。
上述飞行时间测量***进行飞行时间测量的基本过程为:发光单元601向探测区域发射脉冲光信号;与该发光单元601对应的探测单元101接收回波光信号,并将回波光信号转换成回波电信号,其中,回波光信号为发光单元601发射的脉冲光信号被探测区域内的障碍物反射后返回的光信号;采样单元201与探测单元101连接,用于根据探测单元101在输出的电信号,生成飞行时间数据,飞行时间数据用于指示各个飞行时刻以及各个飞行时刻对应的光子数,进而可以指示回波光信号的到达时间。存储单元401中存储有回波光信号的到达时间。根据脉冲光信号的发射时间以及回波光信号的到达时间得到飞行时间TOF,进而根据恒定的光速和飞行时间TOF便可计算障碍物的距离。
理论上,当探测单元101在飞行时间统计周期中的某个飞行时刻未接收到回波光信号时,探测单元101不会输出回波电信号给采样单元101,相应地,采样单元101输出的该飞行时刻对应的光子数为0;而当探测单元101在某个飞行时刻接收到回波光信号时,探测单元101在该飞行时刻会输出回波电信号给采样单元201,相应地,采样单元101输出的该飞行时刻对应的光子数>0,光子数>0对应的飞行时刻即为回波光信号的到达时间。
然而,在实际的测量过程中,由于探测单元101的高灵敏度特性,探测单元101接收的光信号除回波光信号之外,还可能存在环境光信号。探测单元101并不能有效区分接收到的信号哪些是环境光信号,哪些是回波光信号。为了降低环境光信号对飞行时间测量结果的影响,相关技术采用时间相干单光子计数(time-correlated single photon counting,TCSPC)来测量飞行时间。其主要原理是单个探测周期内包括多个飞行时间统计周期T tof,发光单元601在多个飞行时间统计周期T tof的起始时间均发射脉冲光信号,即发光单元601在单个探测周期内多次发射脉冲光信号,相应地,探测单元101在多个飞行时间统计周期T tof内均进行回波光信号的探测,即探测单元101在单个探测周期内进行了多次回波光信号的探测;由于障碍物的运动速度远小于光速,同一个探测周期内障碍物的距离可视为保持不变,即飞行时间TOF保持不变,因此,在多个飞行时间统计周期中,回波光信号的到达时间具有相干性或一致性的特性,而 在多个飞行时间统计周期T tof中,环境光信号的到达时间具有随机性,在经历多个飞行时间统计周期T tof之后,回波光信号就能在环境光信号中脱颖而出。
例如:单个探测周期包括N个飞行时间统计周期T tof,N为大于1的正整数,探测单元101在各个飞行时间统计周期T tof内接收到的回波光信号使用斜线填充的矩形表示,接收到的环境光信号使用灰色填充的矩形表示。发光单元101在第1飞行时间统计周期T tof~第N飞行时间统计周期T tof的起始时间进行发光,发射N次脉冲光信号;探测单元101在N个飞行时间统计周期内进行N次回波光信号探测。从图1B中看出,探测单元101在各个飞行时间统计周期T tof内除接收到回波光信号之外,还会接收到多个环境光信号,回波光信号的位置基本保持不变,而各个环境光信号的位置比较杂乱。探测单元101在一个飞行时间统计周期T tof内的光子事件组成一个飞行时间数据集合,其中,飞行时间数据集合的横轴表示一个飞行时间统计周期中的各个飞行时刻,纵轴表示各个飞行时刻对应的光子数。信号在飞行时间数据集合的横轴上的位置表示光信号(环境光信号或回波光信号)的到达时间,信号在飞行时间数据集合的纵轴上的数值表示光信号(环境光信号或回波光信号)的光子数;将第1飞行时间统计周期T tof~第N飞行时间统计周期T tof的飞行时间数据集合进行叠加处理,即将第1飞行时间统计周期T tof~第N飞行时间统计周期T tof在同一飞行时刻对应的光子数进行累加,得到各个飞行时刻对应的计数值;其中,某个飞行时刻的计数值等于第1飞行时间统计周期T tof~第N飞行时间统计周期T tof在该飞行时刻对应的光子数的累加值。根据飞行时间统计周期T tof中各个飞行时刻的计数值即可生成图1B下方的直方图(histogram)。直方图的横轴表示飞行时间统计周期T tof中的各个飞行时刻,直方图的纵轴表示各个飞行时刻对应的计数值,直方图中最大计数值对应的飞行时刻即为回波光信号的到达时间,即飞行时间。
可以理解,对于上述飞行时间测量***而言,其测量得到正确的飞行时间取决于正确识别出在直方图中计数值的峰值位置,进而识别出回波光信号的正确到达时间。当环境光较弱和障碍物的距离较小的时候,信噪比(signal-to-background noise ratio,SBNR)较大,回波光信号对应的直方图的峰值容易的经过多个飞行时间统计周期后得到。然而,当环境光的光强较强或者目标物体的距离较大,探测单元101接收到的回波光信号的光子随距离变大而变少,而接收到的环境光的光子随距离的变化保持不变的时候,信噪比就会较小,影响后端电路识别计数值的峰值位置,可能导致后端电路峰值识别错误,造成探测错误,进而使探测正确率大幅下降。
为了解决上述问题,第一方面,本申请实施例提供了一种飞行时间测量方法,通过统计探测单元101在第一预设时间段T 1内的光子事件,生成环境光数值,其中,与该探测单元101对应的发光单元601在第一预设时间段T 1内不发光;以及统计探测单元101在第二预设时间段T 2内的光子事件,生成直方图数据,其中,第二预设时间段T 2包括N个飞行时间统计周期T tof,N为大于1的正整数,与该探测单元101对应的发光单元601在N个飞行时间统计周期T tof的起始时间发射N次脉冲光信号;再将直方图数据中的多个计数值分别减去环境光数值,得到与多个计数值一一对应的多个处理值;最后根据多个处理值确定飞行时间,从而可以使直方图数据中回波光信号的计数值基本保持不变,环境光信号的计数值得到衰减,提高探测单元101的信噪比,便于确定正确的飞行时间,有效提高测量飞行时间的准确度。
请参见图2,图2是本申请实施例提供的一种飞行时间测量方法的流程示意图,该方法包括但不限于如下步骤:
S11,统计探测单元在第一预设时间段内的光子事件,生成环境光数值。
如图3所示,在本申请中,单个探测周期包括第一预设时间段T 1和第二预设时间段T 2。探测单元101在第一预设时间段T 1内进行环境光探测,探测单元101在第二预设时间段T 2内进行N次回波光信号的探测;在第一预设时间段T 1内,与探测单元101对应的发光单元601不发光,以实现在第一预设时间段T 1内进行环境光探测。由于发光单元601不发光,探测单元101在第一预设时间段T 1内接收的光信号不包括回波光信号,探测单元101在第一预设时间段T 1内的光子事件由环境光产生。
在一些实施方式中,环境光数值用于指示探测单元101进行N次回波光信号探测的过程中,探测单元101在各个飞行时刻平均接收的环境光光子数,即直方图数据中,各个飞行时刻对应的计数值所包括的环境光光子数平均值。
进一步地,本申请实施例提供的飞行时间测量方法生成环境光数值的原理为:
假设,通过统计得到探测单元101在第一预设时间段T 1内接收的环境光的光子数累加值为Sum,环境光数值为ambl。采样单元201(比如TDC)进行采样的时钟周期为T c,每个时钟周期被划分为j个飞行时刻,每个飞行时刻的时长为t 0,其中,j为大于1的正整数,t 0=T c/j。
可以理解的是,探测单元101在第一预设时间段T 1内接收了(T 1/t 0)个飞行时刻的环境光光子。探测单元101在每个飞行时刻平均接收的环境光光子数S 0=[Sum/(T 1/t 0)]。因此,可以设定探测单元101在进行单次回波光信号的探测过程中,每个飞行时刻平 均接收的环境光光子数S 1=S 0=[Sum/(T 1/t 0)]。即,根据探测单元101在第一预设时间段T 1内接收的环境光的第一光子数累加值Sum,可获得探测单元101在进行环境光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 0。相应地,根据探测单元101在进行环境光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 0,可以设定探测单元101在进行单次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 1=S 0
[Sum/(T 1/t 0)],进而根据探测单元101在进行单次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 1,可以设定探测单元101在进行N次回波光信号的探测过程中,各个飞行时刻平均接收的环境光光子数S 2=N*S 1=N*
[Sum/(T 1/t 0)]。而环境光数值ambl可以根据探测单元101在进行N次回波光信号的探测过程中,各个飞行时刻平均接收的环境光光子数S 2进行设置,从而实现指示在探测单元101进行N次回波光信号探测的过程中,探测单元101在各个飞行时刻平均接收的环境光光子数。
示例性的,假设第一预设时间段T 1=20ns,时钟周期T c=2ns,j=4,即每个时钟周期T c划分为四个飞行时刻,每个飞行时刻的时间间隔t 0=2ns/4=500ps。
因此,探测单元101在第一预设时间段T 1内接收40(其中,40=20ns/500ps)个飞行时刻的光子数。探测单元101在进行环境光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 0=(Sum/40)。相应地,可以设定探测单元101在进行单次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 1=(Sum/40)。进而,可以设定探测单元101在进行N次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 2=N*(Sum/40)。此时,环境光数值ambl可根据探测单元101在进行N次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 2,即N*(Sum/40)进行设置。
进一步地,统计探测单元在第一预设时间段内的光子事件,生成环境光数值包括:
累加探测单元在第一预设时间段内接收的光子数,生成第一光子数累加值;
根据第一光子数累加值,生成环境光数值。环境光数值的计算式为:
ambl=β+α*Sum
其中,上述第一光子数累加值即为探测单元101在第一预设时间段T 1内接收的环境光的光子数累加值Sum;α为增益系数,α为实数,且α<1或α>1,增益系数α用于将环境光的第一光子数累加值乘一个小于1或大于1的数,从而可以调节环境光影响的大小和占比。偏置系数β用于为环境光的光子数增加一个静态偏置量,从而实现 减去直方图数据的各个计数值中的环境光光子数的同时,还可以消除静态环境底噪,进一步地提高信噪比。
在一些实施方式中,上述增益系数α可以是通过以下公式进行设置:
α=N*[1/(T 1/t 0)]
此时,α*Sum=N*[Sum/(T 1/t 0)]=S 2。环境光数值ambl=β+S 2,即,环境光数值等于探测单元101在进行N次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 2加上偏置系数β,用于实现减去直方图数据的各个计数值中的环境光光子数的同时,还能消除静态环境底噪,进一步地提高信噪比。
在其他可选的实施方式中,增益系数α也可以为接近N*[1/(T 1/t 0)]的数值,比如N*[1/(T 1/t 0)]*α 0,α 0为接近1的实数,比如α 0=0.99、0.98、0.97等,相应地,α=0.99*N*[1/(T 1/t 0)],α=0.98*N*[1/(T 1/t 0)],α=0.97*N*[1/(T 1/t 0)]等,或者α 0=1.01、1.02、1.03等,相应地,α=1.01*N*[1/(T 1/t 0)],α=1.02*N*[1/(T 1/t 0)],α=1.03*N*[1/(T 1/t 0)]等,本申请对增益系数α的具体数值并不进行限制。
由上述方案可知,增益系数α与探测单元101进行回波光信号的探测时的接收次数N成正比,与第一预设时间段T 1成反比。增益系数α的具体数值可以根据实际需求进行设置,本申请对于增益系数α的具体数值并不进行限制。偏置系数β可以根据实际测试所得的静态环境底噪进行设置,本申请对于偏置系数β的具体数值并不进行限制。
在另外一些实施方式中,环境光数值的计算式为:
ambl=N*[Sum/(T 1/t 0)]
此时,环境光数值ambl=N*[Sum/(T 1/t 0)]=S 2,即,环境光数值等于探测单元101在进行N次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 2
理论上来说,第一预设时间段T 1越长,探测单元101在进行环境光探测的过程中,每个飞行时刻平均接收的环境光光子数S 0越接近实际上每个飞行时刻平均接收的环境光光子数;相应地,探测单元101在进行N次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 2,越接近探测单元101在进行N次回波光信号的探测过程中,实际上每个飞行时刻接收的环境光光子数。
实际上,在本申请的实施例中,第一预设时间段T 1位于单个探测周期内。为了保证在单个探测周期内,飞行时间的一致性,单个探测周期的时长不可能无限延长,相应地,第一预设时间段T 1不可能无限延长。其中,第一预设时间段T1满足:t 0<T1<单个探测周期的时长。
进一步地,第一预设时间段T 1的取值范围为:T tof≤T 1<N*T tof。其中T tof为上述飞行时间统计周期,且T tof=i*T c,T c=j*t 0,i和j均为大于1的正整数,T c为时钟周期,t 0为每个飞行时刻的时长;N为探测单元101在单个探测周期中进行回波光信号探测的次数,也为发光单元101在单个探测周期中发射脉冲光信号的次数。
优选地,在一些实施方式中,第一预设时间段T1可以是通过以下公式进行设置:
T 1=u 1*T tof
其中,u 1为正整数,且1≤u 1<N。
进一步地,由于T tof=i*T c,T c=j*t 0,可知T 1=u 1*i*T c=u 1*i*j*t 0,即,第一预设时间段T 1分为u 1*i个时钟周期T c,且第一预设时间段T 1分为u 1*i*j个飞行时刻。由于每个飞行时刻对应一个光子数,相应地,第一预设时间段T 1对应u 1*i*j个光子数。
此时,增益系数α可以是通过公式:α=N*[1/(T 1/t 0)]=N*[1/(u 1*i*j)]进行设置。其中,飞行时间统计周期T tof所包括的时钟周期T c的数量i以及每个时钟周期T c所包括的飞行时刻的数量j为通常为预先设定的数值,此时,通过设置u 1的数值,便可完成第一预设时间段T1的设置,设置方法非常简单。
进一步地,第一预设时间段T 1分为K个时钟周期;累加探测单元在第一预设时间段内接收的光子数,生成第一光子数累加值包括:
按照时钟周期顺序依次累加探测单元在第一预设时间段的每个时钟周期内的光子数,并依次生成K个初始光子数累加值;其中,每个初始光子数累加值为探测单元在一个时钟周期内接收的环境光光子数的累加值;
累加K个初始光子数累加值,生成第一光子数累加值;第一光子数累加值满足:
Figure PCTCN2022140829-appb-000001
其中,Sum为第一光子数累加值,K为第一预设时间段T 1所包括的时钟周期T c的个数,也即初始光子数累加值的个数,K为正整数,且K=T 1/T c;k为正整数,且1≤k≤K;s k为第k个初始光子数累加值,即探测单元101在第一预设时间段T 1的第k个时钟周期内接收的环境光光子数的累加值。其中,当T 1=u 1*i*T c时,K=u 1*i。
还需要说明的是,可以根据数据类型设置数据格式。例如,增益系数a的数据格式为U4.6,偏置系数β的数据格式为U10.0;探测单元101在第一预设时间段内接收的环境光的光子数累加值Sum的数据格式为U11.0,环境光数值ambl的数据格式为U11.0。
进一步地,统计探测单元在第一预设时间段内的光子事件,生成环境光数值之后,还包括:将环境光数值存入存储单元。
在一些具体的实施方式中,环境光数值ambl存储在存储单元401中地址为a 0的存储空间。
进一步地,统计探测单元在第一预设时间段内的光子事件,生成环境光数值之后,还包括:对环境光数值进行限位饱和处理。
此时,将经过限位饱和处理的环境光数值ambl存入存储单元401中地址为a 0的存储空间。
其中,限位饱和处理是为了防止光子数统计时间过长导致数据溢出。如果数据(第一光子数累加值)超出了要求的数据格式能存储的数据的最大值,则使用最大值去表示这个数据(即第一光子数累加值),如果第一光子数累加值超出了要求的数据格式能存储的数据的最小值,则使用最小值去表示这个数据(即第一光子数累加值)。
S12,统计探测单元在第二预设时间段内的光子事件,生成直方图数据。
其中,直方图数据包括Z个飞行时刻以及Z个飞行时刻对应的Z个计数值,Z为大于1的正整数。如图3所示,第二预设时间段T 2包括N个飞行时间统计周期T tof,与该探测单元101对应的发光单元601在N个飞行时间统计周期T tof的起始时间发射N次脉冲光信号。探测单元101在第1个飞行时间统计周期T tof~第N个飞行时间统计周期T tof接收N次光信号,以实现N次回波光信号的探测。由于发光单元601在第1个飞行时间统计周期T tof~第N个飞行时间统计周期T tof的起始时间发射脉冲光信号,探测单元101在第1个飞行时间统计周期T tof~第N个飞行时间统计周期T tof内接收的光信号包括回波光信号和环境光信号,探测单元101在第1个飞行时间统计周期T tof~第N个飞行时间统计周期T tof内的光子事件由回波光信号和环境光信号产生。直方图数据中的计数值分别用于指示N个飞行时间统计周期T tof中相同飞行时刻对应的光子数的累加值。具体地,可以通过对N个飞行时间统计周期T tof各自对应的N个飞行时间数据集合进行叠加处理后,生成直方图数据。
进一步地,第二预设时间段T 2包括N个飞行时间统计周期T tof。其中,每个飞行时间统计周期T tof包括i个时钟周期T c,每个时钟周期T c分为j个飞行时刻。相应地,直方图数据的横轴(时间轴)所包括的飞行时刻Z=i*j,Z个飞行时刻对应i*j个计数值。
如图3所示,第二预设时间段T 2还包括N个发射时间间隔T 21,N个发射时间间隔T tx分别位于N个飞行时间统计周期T tof的起始时间之前。发光单元601在每个发射时间间隔T tx进行发光,以实现在第1个飞行时间统计周期T tof~第N个飞行时间统计 周期T tof的起始时间发射N次脉冲光信号。
如图3所示,tx_en为第一控制信号,用于触发发光单元601在第二预设时间段T 2内发射N次脉冲光信号。tof_en为第一接收控制信号,用于触发探测单元102在第二预设时间段T 2内进行N次回波光信号的探测。env_en为第二控制信号,用于触发探测单元101在第一预设时间段T 1内进行环境光探测。
在一种具体的实施方式中,tx_en在单个探测周期内包括N个第一高电平脉冲Pulse1,每个第一高电平脉冲Pulse1的脉宽均等于发射时间间隔T tx,相邻两个第一高电平脉冲Pulse1的下降沿之间的时间间隔等于飞行时间统计周期T tof。N个第一高电平脉冲Pulse1等间隔地分布在第二预设时间段T 2内,且第1个第一高电平脉冲Pulse1位于第二预设时间段T 2的起始时间。tx_en通过N个第一高电平脉冲Pulse1的高电平触发发光单元601发射N次脉冲光信号。
在一种具体的实施方式中,tof_en在单个探测周期内包括N个第二高电平脉冲信号Pulse2,每个第一高电平脉冲Pulse1的脉宽均等于飞行时间统计周期T tof。N个第二高电平脉冲信号Pulse2的上升沿分别与N个第一高电平脉冲Pulse1下将沿对齐。第1个第二高电平脉冲信号Pulse2的下降沿~第N-1个第二高电平脉冲信号Pulse2的下降沿分别与第2个第一高电平脉冲信号Pulse1的上升沿~第N个第一高电平脉冲信号Pulse1的上升沿对齐。tof_en通过N个第二高电平脉冲信号Pulse2的高电平触发接收单元101进行N次回波光信号的探测。
在一种具体的实施方式中,env_en在单个探测周期内包括一个第三高电平脉冲信号Pulse3。第三高电平脉冲信号Pulse3的脉宽等于第一预设时间段T 2。第三高电平脉冲信号Pulse3的下降沿与第1个第一高电平脉冲Pulse1的上升沿对齐,即第一预设时间段T 1的结束时间等于第二预设时间段T 2的起始时间。env_en通过第三高电平脉冲信号Pulse3的高电平触发接收单元101进行环境光信号的探测。进一步地,统计探测单元在第二预设时间段内的光子事件,生成直方图数据包括:
对N个飞行时间数据集合进行叠加处理,生成直方图数据。
其中,N个飞行时间数据集合用于指示探测单元101在N个飞行时间统计周期T tof,即第1个飞行时间统计周期T tof~第N个飞行时间统计周期T tof内的光子事件。每个飞行时间数据集合包括一个飞行时间统计周期T tof的各个飞行时段以及各个飞行时段对应的光子数。飞行时间数据集合的横轴表示一个飞行时间统计周期T tof中的各个飞行时刻,纵轴表示各个飞行时刻对应的光子数。光信号(环境光信号或回波光信号) 在飞行时间数据集合的横轴上的位置表示光信号的到达时间,光信号在飞行时间数据集合的纵轴上的数值用于指示光子数。具体地,对N个飞行时间数据集合进行叠加处理为将N个飞行时间数据集合按照飞行时刻进行对齐,然后将同一飞行时刻的光子数进行累加,即将每个飞行时刻对应的N组光子数进行累加,以实现直方图数据中的各个计数值分别用于指示N个飞行时间数据集合进行叠加处理后,各个飞行时刻对应的光子数累加值。
进一步地,由于每个飞行时间统计周期T tof包括i个时钟周期T c,每个时钟周期T c分为j个飞行时刻。相应地,每个飞行时间数据集合所包括的飞行时刻的数量等于i*j,i*j个飞行时刻分别对应i*j个光子数。相应地,直方图数据所包括的飞行时刻Z=i*j,Z个飞行时刻对应i*j个计数值。
进一步地,统计探测单元在第二预设时间段内的光子事件,生成直方图数据之后,还包括:将直方图数据存入存储单元。
在一些具体的实施方式中,直方图数据存储在存储单元401中地址为a 1~a i的存储空间。每个存储空间包括j个子存储空间。其中,地址为a 1的存储空间中的j个子存储空间用于存储第1个时钟周期中的j个飞行时刻对应的j个计数值,地址为a 2的存储空间中的j个子存储空间用于存储第2个时钟周期中的j个飞行时刻对应的j个计数值……地址为a i的存储空间中的j个子存储空间用于存储第i个时钟周期中的j个飞行时刻对应的j个计数值,以通过i个存储空间形成的i*j个子存储空间分别存储直方图数据中i*j个计数值。
S13,将Z个计数值分别减去环境光数值,生成与Z个计数值各自对应的Z个处理值。
进一步地,将Z个计数值分别减去环境光数值,生成与Z个计数值各自对应的Z个处理值包括:
获取及输出环境光数值和Z个计数值;
接收环境光数值和Z个计数值,并将Z个计数值分别与环境光数值进行减法运算,生成Z个处理值。
在一些实施方式中,获取及输出环境光数值和Z个计数值包括:
获取Z个计数值,并按照飞行时刻顺序依次输出Z个计数值;
获取及输出环境光数值。
具体地,按照飞行时刻顺序依次输出Z个计数值为按照每个飞行时间统计周期T tof 中i*j个飞行时刻,即,Z个飞行时刻的顺序依次输出Z个飞行时刻各自对应Z个计数值。
进一步地,获取Z个计数值,并按照每个飞行时间统计周期中的飞行时刻顺序依次输出Z个计数值包括:
按照时钟周期顺序依次获取i个时钟周期所对应的i组计数值,其中,每组计数值包括一个时钟周期所包括的j个飞行时刻各自对应的j个计数值;
按照飞行时刻顺序,依次输出每个时钟周期所包括的j个飞行时刻各自对应的j个计数值。
具体地,按照时钟周期顺序依次获取i个时钟周期所对应的i组计数值为按照每个飞行时间统计周期T tof中,i个时钟周期的顺序依次获取存储单元401中存储的i个时钟周期所对应的i组计数值。
具体地,按照飞行时刻顺序,依次输出每个时钟周期所包括的j个飞行时刻各自对应的j个计数值为在获取到每组计数值所包括的j个计数值以后,按照每个时钟周期中的飞行时刻顺序,依次输出j个计数值。
具体地,i个时钟周期所对应的i组计数值分别存储在存储单元401的地址为a 1~a i的存储空间中。按照每个飞行时间统计周期中的时钟周期顺序依次获取存储单元中存储的i个时钟周期所对应的i组计数值包括:按照每个飞行时间统计周期中的时钟周期顺序依次获取存储单元中地址为a 1~a i的存储空间所存储的i组计数值。
具体地,环境光数值存储在存储单元401的地址为a 0的存储空间中,获取及输出环境光数值包括:从存储单元中地址为a 0的存储空间中获取环境光数值,并输出所获取的环境光数值。
进一步地,输出环境光数值时,环境光数值的输出时间覆盖Z个计数值的输出时间,便于实现将每个计数值与环境光数值进行减法运算。
具体地,在设计阶段可以确定Z个计数值的输出时间,比如说,预先设置Z个计数值的输出时间范围为t 21~t 22。通过设置环境光数值的获取时间,使环境光数值的输出时间范围为t 11~t 12,其中,t 11<t 21,t 12>t 22,即可实现环境光数值的输出时间覆盖Z个计数值的输出时间,进而便于实现将每个计数值与环境光数值进行减法运算。
在一些具体的实施方式中,可以通过减法器接收环境光数值和Z个计数值,并将Z个计数值分别与环境光数值进行减法运算,生成Z个处理值。
进一步地,将Z个计数值分别减去环境光数值,生成与Z个计数值各自对应的Z 个处理值之后,还包括:对Z个处理值进行限位饱和处理。
其中,限位饱和处理是为了防止光子数统计时间过长导致数据(即计数值)溢出。如果数据超出了要求的数据格式能存储的数据的最大值,则使用最大值去表示这个数据,如果数据超出了要求的数据格式能存储的数据的最小值,则使用最小值去表示这个数据。
S14,根据Z个处理值确定飞行时间。
在一些具体的实施方式中,根据Z个处理值中峰值位置对应的时间确定飞行时间。本申请实施例提供的飞行时间测距方法通过统计探测单元101在第一预设时间段内的光子事件,生成环境光数值,并通过统计探测单元101在第二预设时间段内的光子事件,生成直方图数据;然后将直方图数据中多个计数值分别减去环境光数值,得到多个处理值;根据多个处理值中峰值位置对应的时间便可确定障碍物正确的飞行时间,从而可以使直方图数据中回波光信号的计数值基本保持不变,环境光信号的计数值得到衰减,提高探测单元101的信噪比,便于识别正确的峰值位置,有效提高探测单元101测量飞行时间的精确度。
应理解,上述实施例中各步骤的序号的大小并不意味着执行顺序的先后,各过程的执行顺序应以其功能和内在逻辑确定,而不应对本申请实施例的实施过程构成任何限定。
为了解决上述问题,第二方面,本申请实施例提供了一种飞行时间测量装置,该飞行时间测量装置通过第一统计单元301统计探测单元101在第一预设时间段内的光子事件,生成环境光数值,并通过第二统计单元302统计探测单元101在第二预设时间段内的光子事件,生成直方图数据;然后通过计算单元501将直方图数据中多个计数值分别减去环境光数值,得到多个处理值;再通过确定单元502根据多个处理值中峰值位置对应的时间确定障碍物飞行时间,从而可以使直方图数据中回波光信号的计数值基本保持不变,环境光信号的计数值得到衰减,提高探测单元101的信噪比,便于识别正确的峰值位置,有效提高探测单元101测量飞行时间的精确度。
请参见图4,图4是本申请实施例提供的一种飞行时间测量装置的结构框图示意图。图4所示的飞行时间测量装置可以实现图3所示实施例的飞行时间测量方法。图4所示的飞行时间测量装置包括第一统计单元301、第二统计单元302、计算单元501以及确定单元502。
具体地,第一统计单元301用于统计探测单元101在第一预设时间段T 1内的光子 事件,生成环境光数值。
如图3所示,在本申请中,单个探测周期包括第一预设时间段T 1和第二预设时间段T 2。探测单元101在第一预设时间段T 1内进行环境光探测,探测单元101在第二预设时间段T 2内进行N次回波光信号的探测;在第一预设时间段T 1内,与探测单元101对应的发光单元601不发光,以实现在第一预设时间段T 1内进行环境光探测。由于发光单元601不发光,探测单元101在第一预设时间段T 1内接收的光信号不包括回波光信号,探测单元101在第一预设时间段T 1内的光子事件由环境光产生。
在一些实施方式中,环境光数值ambl用于指示探测单元101进行N次回波光信号探测的过程中,探测单元101在各个飞行时刻平均接收的环境光光子数,即直方图数据中,各个飞行时刻对应的计数值所包括的环境光光子数平均值。
进一步地,本申请实施例提供的飞行时间测量装置中,第一统计单元301生成环境光数值的原理为:
假设,通过统计得到探测单元101在第一预设时间段T 1内接收的环境光的第一光子数累加值为Sum,环境光数值为ambl。采样单元201(比如TDC)进行采样的时钟周期为T c,每个时钟周期被划分为j个飞行时刻,每个飞行时刻的时长为t 0,其中,j为大于1的正整数,t 0=T c/j。
可以理解的是,探测单元101在第一预设时间段T 1内接收了(T 1/t 0)个飞行时刻的环境光光子。探测单元101在每个飞行时刻平均接收的环境光光子数S 0=[Sum/(T 1/t 0)]。因此,可以设定探测单元101在进行单次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 1=S 0=[Sum/(T 1/t 0)]。即,根据探测单元101在第一预设时间段T 1内接收的环境光的第一光子数累加值Sum,可获得探测单元101在进行环境光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 0。相应地,根据探测单元101在进行环境光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 0,可以设定探测单元101在进行单次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 1=S 0
[Sum/(T 1/t 0)],进而根据探测单元101在进行单次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 1,可以设定探测单元101在进行N次回波光信号的探测过程中,各个飞行时刻平均接收的环境光光子数S 2=N*S 1=N*
[Sum/(T 1/t 0)]。而环境光数值ambl可以根据探测单元101在进行N次回波光信号的探测过程中,各个飞行时刻平均接收的环境光光子数S 2进行设置,从而实现指示在探 测单元101进行N次回波光信号探测的过程中,探测单元101在各个飞行时刻平均接收的环境光光子数。
示例性的,假设第一预设时间段T 1=20ns,时钟周期T c=2ns,j=4,即每个时钟周期T c划分为四个飞行时刻,每个飞行时刻的时间间隔t 0=2ns/4=500ps。
因此,探测单元101在第一预设时间段T 1内接收40(其中,40=20ns/500ps)个飞行时刻的光子数。探测单元101在进行环境光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 0=(Sum/40)。相应地,可以设定探测单元101在进行单次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 1=(Sum/40)。进而,可以设定探测单元101在进行N次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 2=N*(Sum/40)。此时,环境光数值ambl可根据探测单元101在进行N次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 2,即N*(Sum/40)进行设置。
进一步地,如图5和图6所示,第一统计单元301包括:
第一累加单元3011,用于累加探测单元在第一预设时间段内接收的光子数,生成第一光子数累加值;
第一生成单元3012,用于根据第一光子数累加值,生成环境光数值。环境光数值的计算式为:
ambl=β+α*Sum
其中,上述第一光子数累加值为探测单元101在第一预设时间段T 1内接收的环境光的第一光子数累加值Sum;α为增益系数,α为实数,且α<1或α>1,增益系数α用于将环境光的第一光子数累加值乘一个小于1或大于1的数,从而可以调节环境光影响的大小和占比。偏置系数β用于为环境光的光子数增加一个静态偏置量,从而在直方图数据减去环境光数值时能消除人为的静态环境底噪,尽可能的提高信噪比。
如图6所示,在一些具体的实施方式中,第一生成单元3012包括:
第一乘法器MUL,用于接收第一光子数累加值Sum和增益系数α,并对第一光子数累加值Sum和增益系数α进行乘法运算,生成第一光子数累加值Sum和增益系数α的乘积α*Sum;
第一累加器A1,用于接收偏置系数β以及第一光子数累加值Sum和增益系数α的乘积α*Sum,生成环境光数值ambl。其中,环境光数值ambl=β+α*Sum。
在一些可选的实施方式中,上述增益系数α可以是通过以下公式进行设置:
α=N*[1/(T 1/t 0)]
此时,α*Sum=N*[Sum/(T 1/t 0)]=S 2。环境光数值ambl=β+S 2,即,环境光数值等于探测单元101在进行N次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 2加上偏置系数β,用于实现减去直方图数据的各个计数值中的环境光光子数的同时,还能消除静态环境底噪,进一步地提高信噪比。
在其他可选的实施方式中,增益系数α也可以为接近N*[1/(T 1/t 0)]的数值,比如N*[1/(T 1/t 0)]*α 0,α 0为接近1的实数,比如α 0=0.99、0.98、0.97等,相应地,α=0.99*N*[1/(T 1/t 0)],α=0.98*N*[1/(T 1/t 0)],α=0.97*N*[1/(T 1/t 0)]等,或者α 0=1.01、1.02、1.03等,相应地,α=1.01*N*[1/(T 1/t 0)],α=1.02*N*[1/(T 1/t 0)],α=1.03*N*[1/(T 1/t 0)]等,本申请对增益系数α的具体数值并不进行限制。
由上述方案可知,增益系数α与探测单元101进行回波光信号的探测时的接收次数N成正比,与第一预设时间段T 1成反比。增益系数α的具体数值可以根据实际需求进行设置。偏置系数β可以根据实际测试所得的静态环境底噪进行设置,本申请对于偏置系数β的具体数值并不进行限制。
在另外一些实施方式中,环境光数值的计算式为:
ambl=N*[Sum/(T 1/t 0)]
进一步地,第一生成单元3012包括第二乘法器(未图示)。第二乘法器用于接收第一光子数累加值Sum和系数N*[Sum/(T 1/t 0)],并对第一光子数累加值Sum和系数N*[Sum/(T 1/t 0)]进行乘法运算,生成环境光数值。此时,环境光数值ambl=N*[Sum/(T 1/t 0)]=S 2,即,环境光数值等于探测单元101在进行N次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 2
理论上来说,第一预设时间段T 1越长,探测单元101在进行环境光探测的过程中,每个飞行时刻平均接收的环境光光子数S 0越接近实际上每个飞行时刻平均接收的环境光光子数;相应地,探测单元101在进行N次回波光信号的探测过程中,每个飞行时刻平均接收的环境光光子数S 2,越接近探测单元101在进行N次回波光信号的探测过程中,实际上每个飞行时刻接收的环境光光子数。
实际上,在本申请的实施例中,第一预设时间段T 1位于单个探测周期内。为了保证在单个探测周期内,飞行时间的一致性,单个探测周期的时长不可能无限延长,相应地,第一预设时间段T 1不可能无限延长。其中,第一预设时间段T1满足:t 0<T1<单个探测周期的时长。
进一步地,第一预设时间段T 1的取值范围为:T tof≤T 1<N*T tof。其中T tof为上述飞行时间统计周期,且T tof=i*T c,T c=j*t 0,i和j均为大于1的正整数,T c为时钟周期, t 0为每个飞行时刻的时长;N为探测单元101在单个探测周期中进行回波光信号探测的次数,也为发光单元101在单个探测周期中发射脉冲光信号的次数。
优选地,在一些实施方式中,第一预设时间段T1可以是通过以下公式进行设置:
T 1=u 1*T tof
其中,u 1为正整数,且1≤u 1<N。
进一步地,由于T tof=i*T c,T c=j*t 0,可知T 1=u 1*i*T c=u 1*i*j*t 0,即,第一预设时间段T 1分为u 1*i个时钟周期T c,且第一预设时间段T 1分为u 1*i*j个飞行时刻。由于每个飞行时刻对应一个光子数,相应地,第一预设时间段T 1对应u 1*i*j个光子数。
此时,增益系数α可以是通过公式:α=N*[1/(T 1/t 0)]=N*[1/(u 1*i*j)]进行设置。其中,飞行时间统计周期T tof所包括的时钟周期T c的数量i以及每个时钟周期T c所包括的飞行时刻的数量j为通常为预先设定的数值,此时,通过设置u 1的数值,便可完成第一预设时间段T 1的设置,简化了第一预设时间段T 1的设置方法。
进一步地,第一预设时间段T 1分为K个时钟周期;第一累加单元3011包括:
第二累加单元30111,用于按照时钟顺序依次累加探测单元在第一预设时间段的每个时钟周期内的光子数,并依次生成K个初始光子数累加值;其中,每个初始光子数累加值为探测单元在一个时钟周期内接收的环境光光子数的累加值;
第三累加单元30112,用于累加K个初始光子数累加值,生成第一光子数累加值;第一光子数累加值Sum满足:
Figure PCTCN2022140829-appb-000002
其中,K为第一预设时间段所包括的时钟周期的个数,也是初始光子数累加值进行累加的次数,K为正整数,且K=T 1/T c;k为正整数,且1≤k≤K;s k为第k个初始光子数累加值,即探测单元101在第一预设时间段T 1的第k个时钟周期内环境光光子数的累加值。当T 1=u 1*i*T c时,K=u 1*i。
如图6所示,在一种具体的实施方式中,第三累加单元30112包括第一数据选择器MUX、第二累加器A2和第一寄存器;第一数据选择器MUX包括第一输入端、第二输入端、一个输出端和一个控制端;第一数据选择器MUX的第一输入端用于接收第二累加单元30111按照时钟周期顺序依次输出的K个初始光子数累加值,第一数据选择器MUX的第二输入端接收数据0,第一数据选择器MUX的控制端接收第一统计控制信号,第一数据选择器MUX的输出端与第二累加器A2的一个输入端连接;第二累加器A2包括两个输入端和一个输出端,第二累加器A2的一个输入端与第一数据选 择器MUX的输出端连接,第二累加器A2的另一个输入端与第一寄存器的反馈端连接,第二累加器A2的输出端与第一寄存器的输入端连接;第一寄存器包括一个输入端、一个输出端和一个反馈端;第一寄存器的输入端与第二累加器A2的输出端连接,第一寄存器的输出端与第一生成单元3012连接,用于输出第一光子数累加值Sum;第一寄存器的反馈端与第二累加器A2的另一个输入端连接。
第三累加单元30112的工作过程为:第一统计控制信号控制第一数据选择器MUX按照时钟周期顺序依次选择第二累加单元30111输出的K个初始光子数累加值进行输出,并在第一数据选择器MUX完成K个初始光子数累加值的输出以后,控制第一数据选择器MUX选择数据0进行输出;比如说,在第1~第K个时钟周期内,第一统计控制信号为高电平,高电平的第一统计控制信号用于控制第一数据选择器MUX选择第一输入端的数据,即第二累加单元30111按照时钟周期顺序依次输出的K个初始光子数累加值进行输出;当超过第K个时钟周期以后,第一统计控制信号切换为低电平,低电平的第一统计控制信号用于控制第一数据选择器MUX选择第二输入端的数据,即数据0进行输出;第一数据选择器MUX将K个初始光子数累加值依次输出给第二累加器A2;第二累加器A2和第一寄存器配合,进行K-1次累加过程,以实现累加K个初始光子数累加值,生成第一光子数累加值,再有第一寄存器将光子数累加值输出给第一生成单元3012。其中,第二累加器A2和第一寄存器配合,进行K-1次累加的过程如下:
第一次累加过程:第二累加器A2将所接收的第1个初始光子数累加值输出给第一寄存器,由第一寄存器将第1个初始光子数累加值反馈给第二累加器A2,等到第二累加器A2接收到第2个初始光子数累加值时,由第二累加器A2将第2个初始光子数累加值和第1个初始光子数累加值进行加法运算,生成第一次累加结果,且第二累加器A2将第一次累加结果再次输出给第一寄存器;
第二次累加过程:第一寄存器将第一次累加结果反馈给第二累加器A2,等到第二累加器A2接收到第3个初始光子数累加值时,由第二累加器A2将第3个初始光子数累加值和第一次累加结果进行加法运算,生成第二次累加结果,且第二累加器A2将第二次累加结果再次输出给第一寄存器;
多次执行上述过程,直至进入第K-1次累加过程:第一寄存器将第K-2次累加结果(第1个~第K-1个初始光子数累加值的累加值)反馈给第二累加器A2,等到第二累加器A2接收到第K个初始光子数累加值时,由第二累加器A2将第K个初始光子 数累加值和第K-2次累加结果进行加法运算,生成第K-1次累加结果(第1个~第K个初始光子数累加值的累加值),即第一光子数累加值。
如图6所示,在一种具体的实施方式中,j=4。每个时钟周期包括四个飞行时刻,四个飞行时刻分别对应四个光子数P 0、P 1、P 2、P 3。每个初始累加值为一个时钟周期所包括的四个飞行时刻各自对应的四个光子数P 0、P 1、P 2、P 3。第二累加单元30111包括三个累加器,其中,第一个累加器用于对P 0和P 1做加法运算,得到P 0和P 1的和值;第二个累加器用于对P 2和P 3做加法运算,得到对P 2和P 3的和值;第三个累加器与第一累加器的输出端和第二个累加器的输出端连接,用于对P 0和P 1的和值以及P 2和P 3的和值做加法运算,得到每个时钟周期所包括的四个飞行时刻各自对应的四个光子数P 0、P 1、P 2、P 3的和值,即每个时钟周期对应的初始光子数累加值。
还需要说明的是,可以根据数据类型设置数据格式。例如,增益系数a的数据格式为U4.6,偏置系数β的数据格式为U10.0;探测单元101在第一预设时间段内接收的环境光的第一光子数累加值Sum的数据格式为U11.0,环境光数值ambl的数据格式为U11.0。
进一步地,如图4所示,飞行时间测量装置还包括存储单元401;第一统计单元301生成的环境光数值ambl存入存储单元401。
在一些具体的实施方式中,环境光数值ambl存储在存储单元401中地址为a 0的存储空间。
进一步地,飞行时间测量装置还包括第一限位饱和单元(未图示),第一限位饱和单元的输入端与第一统计单元301连接,第一限位饱和单元的输出端与存储单元401连接,第一限位饱和单元对环境光数值ambl进行限位饱和处理,经过第一限位饱和单元处理后的环境光数值ambl存入存储单元401。具体地,经过限位饱和处理的环境光数值ambl存入存储单元401中地址为a 0的存储空间。
其中,限位饱和处理是为了防止光子数统计时间过长导致数据溢出。如果数据(第一光子数累加值)超出了要求的数据格式能存储的数据的最大值,则使用最大值去表示这个数据(即第一光子数累加值),如果第一光子数累加值超出了要求的数据格式能存储的数据的最小值,则使用最小值去表示这个数据(即第一光子数累加值)。
具体地,第二统计探测单元302用于统计探测单元101在第二预设时间段内的光子事件,生成直方图数据。
其中,直方图数据包括Z个飞行时刻以及Z个飞行时刻对应的Z个计数值,Z为 大于1的正整数。如图3所示,第二预设时间段T 2包括N个飞行时间统计周期T tof,与该探测单元101对应的发光单元601在N个飞行时间统计周期T tof的起始时间发射N次脉冲光信号。探测单元101在第1个飞行时间统计周期T tof~第N个飞行时间统计周期T tof接收N次光信号,以实现N次回波光信号的探测。由于发光单元601在第1个飞行时间统计周期T tof~第N个飞行时间统计周期T tof的起始时间发射脉冲光信号,探测单元101在第1个飞行时间统计周期T tof~第N个飞行时间统计周期T tof内接收的光信号包括回波光信号和环境光信号,探测单元101在第1个飞行时间统计周期T tof~第N个飞行时间统计周期T tof内的光子事件由回波光信号和环境光信号产生。直方图数据中的计数值分别用于指示N个飞行时间统计周期T tof中相同飞行时刻对应的光子数的累加值。具体地,可以通过对N个飞行时间统计周期T tof各自对应的N个飞行时间数据集合进行叠加处理后,生成直方图数据。
进一步地,第二预设时间段T 2包括N个飞行时间统计周期T tof。其中,每个飞行时间统计周期T tof包括i个时钟周期T c,每个时钟周期T c分为j个飞行时刻。相应地,直方图数据的横轴(时间轴)所包括的飞行时刻Z=i*j,Z个飞行时刻对应i*j个计数值。
如图3所示,第二预设时间段T 2还包括N个发射时间间隔T 21,N个发射时间间隔T tx分别位于N个飞行时间统计周期T tof的起始时间之前。发光单元601在每个发射时间间隔T tx进行发光,以实现在第1个飞行时间统计周期T tof~第N个飞行时间统计周期T tof的起始时间发射N次脉冲光信号。
如图3所示,tx_en为第一控制信号,用于触发发光单元601在第二预设时间段T 2内发射N次脉冲光信号。tof_en为第一接收控制信号,用于触发探测单元102在第二预设时间段T 2内进行N次回波光信号的探测。env_en为第二控制信号,用于触发探测单元101在第一预设时间段T 1内进行环境光探测。
在一种具体的实施方式中,tx_en在单个探测周期内包括N个第一高电平脉冲Pulse1,每个第一高电平脉冲Pulse1的脉宽均等于发射时间间隔T tx,相邻两个第一高电平脉冲Pulse1的下降沿之间的时间间隔等于飞行时间统计周期T tof。N个第一高电平脉冲Pulse1等间隔地分布在第二预设时间段T 2内,且第1个第一高电平脉冲Pulse1位于第二预设时间段T 2的起始时间。tx_en通过N个第一高电平脉冲Pulse1的高电平触发发光单元601发射N次脉冲光信号。
在一种具体的实施方式中,tof_en在单个探测周期内包括N个第二高电平脉冲信 号Pulse2,每个第一高电平脉冲Pulse1的脉宽均等于飞行时间统计周期T tof。N个第二高电平脉冲信号Pulse2的上升沿分别与N个第一高电平脉冲Pulse1下将沿对齐。第1个第二高电平脉冲信号Pulse2的下降沿~第N-1个第二高电平脉冲信号Pulse2的下降沿分别与第2个第一高电平脉冲信号Pulse1的上升沿~第N个第一高电平脉冲信号Pulse1的上升沿对齐。tof_en通过N个第二高电平脉冲信号Pulse2的高电平触发接收单元101进行N次回波光信号的探测。
在一种具体的实施方式中,env_en在单个探测周期内包括一个第三高电平脉冲信号Pulse3。第三高电平脉冲信号Pulse3的脉宽等于第一预设时间段T 2。第三高电平脉冲信号Pulse3的下降沿与第1个第一高电平脉冲Pulse1的上升沿对齐,即第一预设时间段T 1的结束时间等于第二预设时间段T 2的起始时间。env_en通过第三高电平脉冲信号Pulse3的高电平触发接收单元101进行环境光信号的探测。
进一步地,第二统计单元302通过叠加N个飞行时间数据集合,生成直方图数据。
其中,N个飞行时间数据集合用于指示探测单元101在第二预设时间段T 2内N个飞行时间统计周期,即第1飞行时间统计周期T tof~第N个飞行时间统计周期T tof内的光子事件。每个飞行时间数据集合包括一个飞行时间统计周期的各个飞行时段以及各个飞行时段对应的光子数。飞行时间数据集合的横轴表示一个飞行时间统计周期中的各个飞行时刻,纵轴表示各个飞行时刻对应的光子数。光信号(环境光信号或回波光信号)在飞行时间数据集合的横轴上的位置表示光信号的到达时间,光信号在飞行时间数据集合的纵轴上的数值用于指示光子数。具体地,叠加N个飞行时间数据集合为将N个飞行时间数据集合按照飞行时刻进行对齐,然后将同一飞行时刻的光子数进行累加,即将每个飞行时刻对应的N组光子数进行累加,以实现直方图数据中的各个计数值分别用于指示N个飞行时间数据集合进行叠加处理后,各个飞行时刻对应的光子数累加值。进一步地,由于每个飞行时间统计周期T tof包括i个时钟周期T c,每个时钟周期T c分为j个飞行时刻。相应地,每个飞行时间数据集合所包括的飞行时刻的数量等于i*j,i*j个飞行时刻分别对应i*j个光子数。相应地,直方图数据所包括的飞行时刻Z=i*j,Z个飞行时刻对应i*j个计数值。
进一步地,第二统计单元302生成的直方图数据存入存储单元401。
在一些具体的实施方式中,直方图数据存储在存储单元401中地址为a 1~a i的存储空间。每个存储空间包括j个子存储空间。其中,地址为a 1的存储空间中的j个子存储空间用于存储第1个时钟周期中的j个飞行时刻对应的j个计数值,地址为a 2的 存储空间中的j个子存储空间用于存储第2个时钟周期中的j个飞行时刻对应的j个计数值……地址为a i的存储空间中的j个子存储空间用于存储第i个时钟周期中的j个飞行时刻对应的j个计数值,以通过i个存储空间形成的i*j个子存储空间分别存储直方图数据中i*j个计数值。
如图7所示,在一种具体的实施方式中,j=4。每个时钟周期包括四个飞行时刻,四个飞行时刻分别对应四个光子数P 0、P 1、P 2、P 3。第二统计单元302包括四路子统计单元3020~3023。以第一路子统计单元3020为例,第一路子统计单元3020包括累加器A20、选择器MUX20、存入单元wdat20以及读出单元rdat20;累加器A20的一个输入端用于接收探测单元101在每个飞行时间统计周期中各个时钟周期的第一个飞行时刻对应的光子数P 0,累加器A0的另一个输入端与读出单元rdat20连接,累加器A0的输出端与选择器MUX220的一个输入端相连,MUX20的另一个输入端接收数据0,选择器MUX20的输出端与存入单元wdat20连接,存入单元wdat20被配置为与存储单元401中地址为a 1~a i的存储空间中的第一个子存储空间连接,读出单元rdat20还被配置为与存储单元401中地址为a 1~a i的存储空间中的第一个子存储空间连接。第一路子统计单元3020的叠加过程如下:
第1个飞行时间统计周期阶段:选择器MUX20在第二统计控制信号的控制下选择累加器A0的输出结果输出;首先,累加器A20接收第一个飞行时间统计周期中第1个时钟周期的第一个飞行时刻对应的光子数P 0,并通过选择器MUX20输出给存入单元wdat20,存入单元wdat20在存入控制信号的控制下将光子数P 0存入地址为a 1的存储空间的第一个子存储空间;累加器A20接收到第一个飞行时刻对应的光子数P 0通过选择器MUX20输出给存入单元wdat20,存入单元wdat20在存入控制信号的控制下将该光子数P 0存入地址为a 2的存储空间的第一个子存储空间……直到累加器A20接收到第i个时钟周期的第一个飞行时刻对应的光子数P 0通过选择器MUX20输出给存入单元wdat20,存入单元wdat20在存入控制信号的控制下将该光子数P 0存入地址为ai的存储空间的第一个子存储空间。
第2个飞行时间统计周期阶段:累加器A20接收第2个飞行时间统计周期中的第1个时钟周期的第一个飞行时刻对应的光子数P 0的同时,读出单元rdat20在读出控制信号的控制下读出地址为a 1的存储空间的第一个子存储空间所存储的数据(即探测单元101在第1个飞行时间统计周期的第1个时钟周期的第一个飞行时刻对应的光子数P 0),并发送给累加器A20,以使累加器A20可以对探测单元101在第1个飞行时间 统计周期和第2个飞行时间统计周期各自的第1个时钟周期的第一个飞行时刻对应的光子数P 0进行累加,累加器A20通过选择器MUX20将累加值输出给存入单元wdat20,存入控制信号控制存入单元wdat20将该累加值存入地址为a 2的存储空间的第一个子存储空间…..直至,累加器A20接收到第2个飞行时间统计周期的第i个时钟周期的第一个飞行时刻对应的光子数P 0的同时,读出单元rdat20在读出控制信号的控制下读出地址为a i的存储空间的第一个子存储空间所存储的数据(即探测单元101在第1个飞行时间统计周期的第i个时钟周期的第一个飞行时刻对应的光子数P 0),并发送给累加器A20,以使累加器A20可以对探测单元101在第1个飞行时间统计周期和第2个飞行时间统计周期各自的第i个时钟周期的第一个飞行时刻对应的光子数P 0进行累加,累加器A20通过选择器MUX20将累加值输出给存入单元wdat20,存入控制信号控制控制存入单元wdat20将该累加值存入地址为a i的存储空间的第一个子存储空间;第一路子统计单元3020完成探测单元101在第1个飞行时间统计周期~第2个飞行时间统计周期中各个时钟周期的第一个飞行时刻对应的光子数P 0的叠加。
接下来,第一路子统计单元3020继续执行第3个飞行时间统计周期阶段~第N个飞行时间统计周期阶段的叠加动作,以完成对探测单元101在第1个飞行时间统计周期~第N个飞行时间统计周期中各个时钟周期的第一个飞行时刻对应的光子数P 0的N次叠加。当第一路子统计单元3020完成探测单元101在第1个飞行时间统计周期~第N个飞行时间统计周期对应各个时钟周期的第一个飞行时刻对应的光子数P 0的N次叠加以后,选择器MUX20在第二统计控制信号的控制下选择输出数据0给存入单元wdat20,第一路子统计单元3020停止叠加动作。
同理可得,第二路子统计单元3021通过执行第1个飞行时间统计周期阶段~第N个飞行时间统计周期阶段的N次叠加动作,以完成对探测单元101在第1个飞行时间统计周期~第N个飞行时间统计周期中各个时钟周期的第二个飞行时刻对应的光子数P 1的N次叠加;第三路子统计单元3022通过执行第1个飞行时间统计周期阶段~第N个飞行时间统计周期阶段的N次叠加动作,以完成对探测单元101在第1个飞行时间统计周期~第N个飞行时间统计周期中各个时钟周期的第三个飞行时刻对应的光子数P 2的N次叠加;第四路子统计单元3023通过执行第1个飞行时间统计周期阶段~第N个飞行时间统计周期阶段的N次叠加动作,以完成对探测单元101在第1个飞行时间统计周期~第N个飞行时间统计周期中各个时钟周期的第四个飞行时刻对应的光子数P 3的N次叠加;第二路子统计单元3021、第三路子统计单元3022和第四路子统计单 元3023进行叠加的基本原理同第一路子统计单元3020相同,此处不再赘述。
在其他实施方式中,j可以为不等于4的其他正整数;相应地,第二统计单元302包括j路子统计单元。每一路子统计单元的结构和工作原理与上述第一子统计单元3020的结构和工作原理基本相同,在此不再赘述。本申请对于每个时钟周期T c包括的飞行时刻的数量j的具体数值并不进行限制。
具体地,计算单元501用于将Z个计数值分别减去环境光数值,生成与Z个计数值各自对应的Z个处理值。
如图8所示,存储单元401包括地址为a 0~a i的存储空间。其中,地址为a 0的存储空间用于存储环境光数值ambl。地址为a 1~a i的存储空间用于存储直方图数据。
进一步地,如图8所示,计算单元501包括:
获取及输出单元5011,用于获取及输出环境光数值和Z个计数值;
减法器5012,用于接收环境光数值和Z个计数值,并将Z个计数值分别与环境光数值进行减法运算,生成Z个处理值。
如图8所示,在一些具体的实施方式中,获取及输出单元5011包括:
第一获取及输出单元50111,用于获取及输出环境光数值;
第二获取及输出单元50112,用于获取Z个计数值,并按照飞行时刻顺序依次输出Z个计数值。
具体地,按照飞行时刻顺序依次输出Z个计数值为按照每个飞行时间统计周期T tof中i*j个飞行时刻,即,Z个飞行时刻的顺序依次输出Z个飞行时刻各自对应Z个计数值。
进一步地,获取Z个计数值,并按照每个飞行时间统计周期中的飞行时刻顺序依次输出Z个计数值包括:
按照时钟周期顺序依次获取i个时钟周期所对应的i组计数值,其中,每组计数值包括一个时钟周期所包括的j个飞行时刻各自对应的j个计数值;
按照飞行时刻顺序,依次输出每个时钟周期所包括的j个飞行时刻各自对应的j个计数值。
具体地,按照时钟周期顺序依次获取i个时钟周期所对应的i组计数值为按照每个飞行时间统计周期T tof中,i个时钟周期的顺序依次获取存储单元401中存储的i个时钟周期所对应的i组计数值。
具体地,按照飞行时刻顺序,依次输出每个时钟周期所包括的j个飞行时刻各自 对应的j个计数值为在获取到每组计数值所包括的j个计数值以后,按照每个时钟周期中的飞行时刻顺序,依次输出j个计数值。
在一种具体的实施方式中,第二获取及输出单元50112可以采用移位寄存器,移位寄存器被配置为按照飞行时间统计周期中的时钟周期顺序依次获取存储单元401中存储的i个时钟周期所对应的i组计数值,其中,每组计数值包括一个时钟周期所包括的j个飞行时刻各自对应的j个计数值;移位寄存器用于对接收的多个并行数据进行移位输出,以将获取到每组计数值所包括的j个计数值,按照时钟周期中的飞行时刻顺序进行依次输出。比如说,当移位寄存器获取到存储单元401中存储的第1个时钟周期所对应的第1组计数值,即第1个时钟周期所包括的j个飞行时刻各自对应的j个计数值时,移位寄存器按照时钟周期中飞行时刻顺序对j个计数值进行移位输出,以将获取到第1组计数值所包括的j个计数值,按照时钟周期中的飞行时刻顺序进行依次输出。当移位寄存器获取到存储单元401中存储的第2个时钟周期所对应的第2组计数值,即第2个时钟周期所包括的j个飞行时刻各自对应的j个计数值时,移位寄存器按照时钟周期中飞行时刻顺序对j个计数值进行移位输出,以将获取到第2组计数值所包括的j个计数值,按照时钟周期中的飞行时刻顺序进行依次输出…当移位寄存器获取到存储单元401中存储的第i个时钟周期所对应的第i组计数值,即第i个时钟周期所包括的j个飞行时刻各自对应的j个计数值时,移位寄存器按照时钟周期中飞行时刻顺序对j个计数值进行移位输出,以将获取到第i组计数值所包括的j个计数值,按照时钟周期中的飞行时刻顺序进行依次输出,通过上述i次移位输出,移位寄存器可以实现获取Z个计数值,并按照每个飞行时间统计周期中的飞行时刻顺序依次输出Z个计数值。
如图8所示,每个时钟周期所包括的j个飞行时刻各自对应的j个计数值分别为hist_dat0、hist_dat1、……、hist_dat(j-1)。第二获取及输出单元50112获取到每个时钟周期对应的j个计数值hist_dat0、hist_dat1、……、hist_dat(j-1)后,将j个计数值hist_dat0、hist_dat1、……、hist_dat(j-1)按照飞行时刻顺序进行移位输出,以使减法器5012可以按照飞行时刻顺序依次将j个计数值hist_dat0、hist_dat1、……、hist_dat(j-1)与环境光数值ambl进行减法运算,得到j个计数值hist_dat0、hist_dat1、……、hist_dat(j-1)一一对应的j个处理值。
具体地,i个时钟周期所对应的i组计数值分别存储在存储单元401的地址为a 1~a i的存储空间中。移位寄存器被配置为按照每个飞行时间统计周期中的时钟周期顺序依 次指向地址a 1~a i,以按照每个飞行时间统计周期中的时钟周期获取存储单元中地址为a 1~a i的存储空间所存储的i组计数值。
具体地,环境光数值ambl存储在存储单元401的地址为a 0的存储空间中,第一获取及输出单元50111从存储单元中地址为a 0的存储空间中获取环境光数值,并输出所获取的环境光数值ambl。
进一步地,第一获取及输出单元50111输出环境光数值时,环境光数值的输出时间覆盖Z个计数值的输出时间,便于实现将每个计数值与环境光数值进行减法运算。
具体地,在设计阶段可以确定Z个计数值的输出时间,比如说,预先设置Z个计数值的输出时间范围为t 21~t 22。通过设置环境光数值的获取时间,使环境光数值的输出时间范围为t 11~t 12,其中,t 11<t 21,t 12>t 22,即可实现环境光数值的输出时间覆盖Z个计数值的输出时间,进而便于实现将每个计数值与环境光数值进行减法运算。
在一些具体的实施方式中,减法器5012接收环境光数值和Z个计数值,并将Z个计数值分别与环境光数值进行减法运算,生成Z个处理值。
进一步地,飞行时间测量装置还包括第二限位饱和单元(未图示),第二限位饱和单元的输入端与计算单元501的输出端连接,输出端与确定单元502的输入端连接,用于对Z个处理值进行限位饱和处理,并将经过限位饱和处理的Z个处理值输出给确定单元502。
其中,限位饱和处理是为了防止光子数统计时间过长导致数据(即处理值)溢出。如果数据超出了要求的数据格式能存储的数据的最大值,则使用最大值去表示这个数据,如果数据超出了要求的数据格式能存储的数据的最小值,则使用最小值去表示这个数据。
具体地,确定单元502用于根据Z个处理值确定飞行时间。
在一些具体的实施方式中,确定单元502根据Z个处理值中峰值位置对应的时间便可确定障碍物的飞行时间。当飞行时间测量装置包括第二限位饱和单元时,确定单元502根据经过限位饱和处理的Z个处理值中峰值位置对应的时间便可确定障碍物的飞行时间。
本申请实施例提供的飞行时间测量装置通过第一统计单元301统计探测单元101在第一预设时间段内的光子事件,生成环境光数值,并通过第二统计单元302统计探测单元101在第二预设时间段内的光子事件,生成直方图数据;然后将直方图数据中多个计数值分别减去环境光数值,得到多个处理值;根据多个处理值中峰值位置对应 的时间确定障碍物的飞行时间,从而可以使直方图数据中回波光信号的计数值基本保持不变,环境光信号的计数值得到衰减,提高探测单元101的信噪比,便于识别正确的峰值位置,有效提高探测单元101测量飞行时间的精确度。
进一步,上述飞行时间测量测量装置还包括发射器60、探测器10、采样模组20和存储模组40;发射器包括发光单元601,用于发射光信号。探测器10包括探测单元101,用于接收光信号,并将接收的光信号转换成电信号。采样模组包括采样单元201,用于根据探测单元101转换所得的电信号,生成飞行时间数据,飞行时间数据用于指示飞行时刻以及飞行时刻对应的光子数。存储模组40包括上述存储单元401,用于存储环境光数值和直方图数据。
图9示出了本申请一实施例还提供的激光测距装置的结构示意图。
如图9所示,该激光测距装置可以包括:发射器60、探测器10、处理器(processor)910、通信接口(Communications Interface)920、存储器(memory)930、以及通信总线940。其中,发射器60包括一个或多个发光单元601,用于发射脉冲光信号。探测器10包括一个或多个探测单元101,用于接收光信号。每个发光单元601与一个或多个探测单元101对应。处理器910、通信接口920、以及存储器930通过通信总线940完成相互间的通信。通信接口920用于与其它设备比如客户端或其它服务器等的网元通信。存储器930用于存储实现以上方法实施例(即飞行时间测量方法),或者装置实施例(即飞行时间测试装置)各个模块的计算机程序或指令903。处理器910通过通信接口920与发射器60和探测器10连接,用于调用该计算机程序或指令903,执行以上方法实施例的操作,例如图2所示的S11~S14。
本申请提供的激光测距装置通过上述方法实施例或装置实施例确定的飞行时间,生成形成点云图,并通过对点云图进行处理,获得障碍物的距离、方位、高度、速度、姿态和形状等参数,从而实现激光探测功能,进而可应用于汽车、机器人、物流车、巡检车等产品的导航规避、障碍物识别、测距、测速、自动驾驶等场景。
具体地,在一些实施方式中,发射器60包括一个发光单元601。此时,发射器60可以采用垂直腔面发射激光器(Vertical-Cavity Surface-Emitting Laser,VCSEL)、边发射激光器(Edge Emitting Laser,EEL)、发光二极管(Light Emitting Diode,LED)、微发光二极管(Micro Light Emitting Diode,Micro LED)、脉冲激光沉积(Pulsed Laser Deposition,PLD)或激光二极管(Laser Diode,LD)等,本申请对发射器60的类型并不进行限制。
在另外一些实施方式中,发射器60包括多个发光单元601;多个发光单元601可以呈阵列设置,即发射器60可以为激光器阵列。此时,发射器60可以采用垂直腔面发射激光器(Vertical-Cavity Surface-Emitting Laser,VCSEL)阵列、边发射激光器(Edge Emitting Laser,EEL)阵列、发光二极管(Light Emitting Diode,LED)阵列、微发光二极管(Micro Light Emitting Diode,Micro LED)阵列、脉冲激光沉积(Pulsed Laser Deposition,PLD)阵列或激光二极管(Laser Diode,LD)阵列等,本申请对发射器60的类型并不进行限制。
在一些实施方式中,探测器10包括一个探测单元101。此时,探测器10可以采用单光子雪崩二极管(Single Photon Avalanche Diode,SPAD)或硅光电倍增管(Silicon photomultiplier,SIPM),本申请对探测器10的类型并不进行限制。在另外一些实施方式中,探测器10包括多个探测单元101,多个探测单元101呈阵列设置,即探测器10可以为探测器阵列。此时,探测器10可以采用单光子雪崩二极管(Single Photon Avalanche Diode,SPAD)阵列或硅光电倍增管(Silicon photomultiplier,SIPM)阵列,本申请对探测器10的类型并不进行限制。
进一步地,当发射器60包括多个发光单元601时,多个发光单元601可以依次发光,以实现将脉冲光信号扫描发射至探测区域,以扫描探测区域内的障碍物。相应地,探测器10中的探测单元101用于探测位于探测区域内的障碍物反射的回波光信号。
具体地,所称处理器910可以是中央处理单元(Central Processing Unit,CPU),还可以是其他通用处理器、数字信号处理器(Digital Signal Processor,DSP)、专用集成电路(Application Specific Integrated Circuit,ASIC)、现成可编程门阵列
(Field-Programmable Gate Array,FPGA)或者其他可编程逻辑器件、分立门或者晶体管逻辑器件、分立硬件组件等。通用处理器可以是微处理器或者该处理器也可以是任何常规的处理器等。
所述存储器930可以是所述激光测距装置的内部存储单元,例如激光测距装置的硬盘或内存。所述存储器930也可以是所述激光测距装置的外部存储设备,例如所述激光测距装置上配备的插接式硬盘,智能存储卡(Smart Media Card,SMC),安全数字(Secure Digital,SD)卡,闪存卡(Flash Card)等。进一步地,所述存储器930还可以既包括所述激光测距装置的内部存储单元也包括外部存储设备。所述存储器930用于存储所述计算机程序以及所述终端设备所需的其他程序和数据。所述存储器930还可以用于暂时地存储已经输出或者将要输出的数据。
本申请实施例还提供了一种计算机可读存储介质。计算机可读存储介质存储有至少一可执行指令,可执行指令被处理器执行时实现上述飞行时间测量方法。
本申请实施例提供了一种计算机程序产品,当计算机程序产品在激光测距装置上运行时,使得激光测距装置执行时可实现上述飞行时间测量方法。
所属领域的技术人员可以清楚地了解到,为了描述的方便和简洁,仅以上述各功能单元、模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能单元、模块完成,即将所述终端设备的内部结构划分成不同的功能单元或模块,以完成以上描述的全部或者部分功能。实施例中的各功能单元、模块可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中,上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。另外,各功能单元、模块的具体名称也只是为了便于相互区分,并不用于限制本申请的保护范围。上述***中单元、模块的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。在上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述或记载的部分,可以参照其它实施例的相关描述。
本领域普通技术人员可以意识到,结合本文中所公开的实施例描述的各示例的单元及算法步骤,能够以电子硬件、或者计算机软件和电子硬件的结合来实现。这些功能究竟以硬件还是软件方式来执行,取决于技术方案的特定应用和设计约束条件。专业技术人员可以对每个特定的应用来使用不同方法来实现所描述的功能,但是这种实现不应认为超出本申请的范围。
以上所述实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员应当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围,均应包含在本申请的保护范围之内。

Claims (15)

  1. 一种飞行时间测量方法,其特征在于,包括:
    统计探测单元在第一预设时间段内的光子事件,生成环境光数值;
    统计探测单元在第二预设时间段内的光子事件,生成直方图数据;其中,所述直方图数据包括Z个飞行时刻以及Z个飞行时刻各自对应的Z个计数值,Z为大于1的正整数;
    将Z个所述计数值分别减去所述环境光数值,生成与Z个所述计数值各自对应的Z个处理值;
    根据Z个处理值确定飞行时间;
    其中,所述第一预设时间段和所述第二预设时间段位于单个探测周期内;在所述第一预设时间段内,与所述探测单元对应的发光单元不发射脉冲光信号;在所述第二预设时间段内,与所述探测单元对应的发光单元发射N次脉冲光信号,N为大于1的正整数。
  2. 根据权利要求1所述的飞行时间测量方法,其特征在于,所述统计探测单元在第一预设时间段内的光子事件,生成环境光数值包括:
    累加所述探测单元在所述第一预设时间段内接收的光子数,生成第一光子数累加值;
    根据所述第一光子数累加值,生成所述环境光数值;所述环境光数值的计算式为:
    ambl=β+α*Sum
    其中,Sum为所述第一光子数累加值;
    α为增益系数,α为实数,且α<1或α>1;
    β为偏移系数,β为实数。
  3. 根据权利要求2所述的飞行时间测量方法,其特征在于,所述增益系数α通过以下公式进行设置:
    α=N*[1/(T 1/t 0)]
    其中,T 1为所述第一预设时间段;
    t 0=Tc/j;Tc为时钟周期,j为每个时钟周期所包括的飞行时刻。
  4. 根据权利要求2所述的飞行时间测量方法,其特征在于:所述第一预设时间段包括K个时钟周期;所述累加探测单元在第一预设时间段内接收的光子数,生成第一光子数累加值包括:
    按照时钟周期顺序依次累加所述探测单元在所述第一预设时间段的每个时钟周期内的光子数,并依次生成K个初始光子数累加值;
    累加所述K个初始光子数累加值,生成所述第一光子数累加值;所述第一光子数累加值满足:
    Figure PCTCN2022140829-appb-100001
    其中,K为大于1的正整数;每个所述初始光子数累加值为所述探测单元在一个时钟周期内接收的光子数的累加值;k为正整数,且1≤k≤K,s k为所述探测单元在所述第一预设时间段的第k个时钟周期内接收的光子数的累加值。
  5. 根据权利要求1所述的飞行时间测量方法,其特征在于,所述统计探测单元在第一预设时间段内的光子事件,生成环境光数值之后,还包括:
    将所述环境光数值存入存储单元。
  6. 根据权利要求1所述的飞行时间测量方法,其特征在于,所述统计探测单元在第二预设时间段内的光子事件,生成直方图数据包括:
    对N个飞行时间数据集合进行叠加处理,生成直方图数据根据权利要求1所述的飞行时间测量方法,其特征在于,所述统计探测单元在第二预设时间段内的光子事件,生成直方图数据包括:
    对N个飞行时间数据集合进行叠加处理,生成直方图数据;
    其中,所述第二预设时间段包括N个飞行时间统计周期,每个所述飞行时间数据集合用于指示所述探测单元在一个所述飞行时间统计周期内的光子事件。
  7. 根据权利要求6所述的飞行时间测量方法,其特征在于,所述统计探测单元在第二预设时间段内的光子事件,生成直方图数据之后,还包括:
    将所述直方图数据存入存储单元。
  8. 根据权利要求1所述的飞行时间测量方法,其特征在于,所述将Z个计数值分别减去环境光数值,生成与Z个计数值各自对应的Z个处理值包括:
    获取及输出所述环境光数值和Z个所述计数值;
    接收所述环境光数值和Z个所述计数值,并将Z个所述计数值分别与所述环境光数值进行减法运算,生成Z个所述处理值。
  9. 根据权利要求8所述的飞行时间测量方法,其特征在于,所述获取及输出环境光数值和Z个计数值包括:
    获取Z个所述计数值,并按照飞行时刻顺序依次输出Z个所述计数值;
    获取及输出所述环境光数值。
  10. 根据权利要求9所述的飞行时间测量方法,其特征在于,所述获取Z个计数值,并按照飞行时刻顺序依次输出Z个计数值包括:
    按照时钟周期顺序依次获取i个时钟周期所对应的i组计数值,其中,每组计数值包括一个时钟周期所包括的j个飞行时刻各自对应的j个计数值;
    按照飞行时刻顺序,依次输出每个时钟周期所包括的j个飞行时刻各自对应的j个计数值。
  11. 根据权利要求1所述的飞行时间测量方法,其特征在于,所述将Z个计数值分别减去环境光数值,生成与Z个计数值各自对应的Z个处理值之后,还包括:
    对Z个所述处理值进行限位饱和处理。
  12. 一种飞行时间测量装置,其特征在于,采用权利要求1至11任一项所述的飞行时间测量方法;所述飞行时间测量装置包括:
    第一统计单元,用于统计探测单元在第一预设时间段内的光子事件,生成环境光数值;
    第二统计单元,用于统计探测单元在第二预设时间段内的光子事件,生成直方图数据;其中,所述直方图数据包括Z个飞行时刻以及Z个飞行时刻各自对应的Z个计数值,Z为大于1的正整数;
    计算单元,用于将Z个所述计数值分别减去所述环境光数值,生成与Z个所述计数值各自对应的Z个处理值;
    确定单元,用于根据Z个处理值确定飞行时间;
    其中,所述第一预设时间段和所述第二预设时间段位于单个探测周期内;在所述第一预设时间段内,与所述探测单元对应的发光单元不发射脉冲光信号;在所述第二预设时间段内,与所述探测单元对应的发光单元发射N次脉冲光信号,N为大于1的正整数。
  13. 根据权利要求12所述的飞行时间测量装置,其特征在于,还包括:
    发射器,包括一个或多个发光单元;所述发光单元用于发射脉冲光信号;
    探测器,包括一个或多个探测单元;所述探测单元用于接收光信号;
    每个所述发光单元对应一个或多个所述探测单元。
  14. 一种激光测距装置,其特征在于,包括:发射器、探测器、处理器、通信接口、存储器以及通信总线;所述处理器通过所述通信接口与所述发射器和所述探测器进行通信;所述处理器、通信接口以及存储器通过所述通信总线完成相互间的通信;
    所述发射器包括一个或多个发光单元,用于发射脉冲光信号;
    所述探测器包括一个或多个探测单元,用于接收光信号;
    所述存储器用于存储计算机程序或指令;
    所述处理器用于执行所述存储器中的计算机程序或指令实现如权利要求1至11任一项所述的方法。
  15. 一种计算机可读存储介质,所述计算机可读存储介质存储有至少一可执行指令,所述可执行指令被处理器执行时实现如权利要求1-11任一项所述的方法。
PCT/CN2022/140829 2022-12-21 2022-12-21 飞行时间测量方法、装置、激光测距装置及存储介质 WO2024130608A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
PCT/CN2022/140829 WO2024130608A1 (zh) 2022-12-21 2022-12-21 飞行时间测量方法、装置、激光测距装置及存储介质

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2022/140829 WO2024130608A1 (zh) 2022-12-21 2022-12-21 飞行时间测量方法、装置、激光测距装置及存储介质

Publications (1)

Publication Number Publication Date
WO2024130608A1 true WO2024130608A1 (zh) 2024-06-27

Family

ID=91587358

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2022/140829 WO2024130608A1 (zh) 2022-12-21 2022-12-21 飞行时间测量方法、装置、激光测距装置及存储介质

Country Status (1)

Country Link
WO (1) WO2024130608A1 (zh)

Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9127942B1 (en) * 2012-09-21 2015-09-08 Amazon Technologies, Inc. Surface distance determination using time-of-flight of light
KR20160092137A (ko) * 2015-01-26 2016-08-04 주식회사 히타치엘지 데이터 스토리지 코리아 티오에프 방식의 거리 측정 장치에서 제어 방법
CN109196377A (zh) * 2016-06-02 2019-01-11 夏普株式会社 光传感器及电子设备
CN109219758A (zh) * 2016-06-02 2019-01-15 夏普株式会社 光传感器、电子设备
CN110501691A (zh) * 2019-08-13 2019-11-26 Oppo广东移动通信有限公司 Tof模组的噪声滤除方法、tof模组及装置
CN113075672A (zh) * 2021-03-03 2021-07-06 深圳市灵明光子科技有限公司 测距方法及***、计算机可读存储介质
CN113504542A (zh) * 2021-07-07 2021-10-15 奥比中光科技集团股份有限公司 距离测量***及计算被测物反射率的方法、装置、设备
CN114637019A (zh) * 2022-05-18 2022-06-17 杭州宇称电子技术有限公司 一种基于时间分段自适应计数量化的抗环境光方法
CN114637020A (zh) * 2022-05-18 2022-06-17 杭州宇称电子技术有限公司 一种用于飞行时间法距离测量的抗环境光方法

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9127942B1 (en) * 2012-09-21 2015-09-08 Amazon Technologies, Inc. Surface distance determination using time-of-flight of light
KR20160092137A (ko) * 2015-01-26 2016-08-04 주식회사 히타치엘지 데이터 스토리지 코리아 티오에프 방식의 거리 측정 장치에서 제어 방법
CN109196377A (zh) * 2016-06-02 2019-01-11 夏普株式会社 光传感器及电子设备
CN109219758A (zh) * 2016-06-02 2019-01-15 夏普株式会社 光传感器、电子设备
CN110501691A (zh) * 2019-08-13 2019-11-26 Oppo广东移动通信有限公司 Tof模组的噪声滤除方法、tof模组及装置
CN113075672A (zh) * 2021-03-03 2021-07-06 深圳市灵明光子科技有限公司 测距方法及***、计算机可读存储介质
CN113504542A (zh) * 2021-07-07 2021-10-15 奥比中光科技集团股份有限公司 距离测量***及计算被测物反射率的方法、装置、设备
CN114637019A (zh) * 2022-05-18 2022-06-17 杭州宇称电子技术有限公司 一种基于时间分段自适应计数量化的抗环境光方法
CN114637020A (zh) * 2022-05-18 2022-06-17 杭州宇称电子技术有限公司 一种用于飞行时间法距离测量的抗环境光方法

Similar Documents

Publication Publication Date Title
CN109100702B (zh) 用于测量到对象的距离的光电传感器和方法
US10094915B2 (en) Wrap around ranging method and circuit
CN112255636A (zh) 一种距离测量方法、***及设备
CN110622038B (zh) 光传感器、电子设备、运算装置及对光传感器与检测对象物之间的距离进行测量的方法
US11327160B2 (en) Optical sensor and electronic device
CN112014824B (zh) 一种多脉冲抗干扰信号处理方法及装置
US20210181316A1 (en) Time-of-flight-based distance measurement system and method
CN113504542B (zh) 距离测量***及计算被测物反射率的方法、装置、设备
US10989814B2 (en) Method for managing dynamic range of an optical detection device, and corresponding device
CN112114324A (zh) 一种距离测量方法、装置、终端设备及存储介质
WO2022052606A1 (zh) 电子装置、电子装置的控制方法及计算机可读存储介质
US10416294B2 (en) Ranging device read-out circuit
US20230341529A1 (en) Target detection method, lidar and storage medium
CN114185057B (zh) 一种探测方法、装置和终端
CN112255635A (zh) 一种距离测量方法、***及设备
WO2024130608A1 (zh) 飞行时间测量方法、装置、激光测距装置及存储介质
CN112255637B (zh) 距离测量***及方法
EP4202477A2 (en) Lidar control method, terminal apparatus, and computer-readable storage medium
WO2022160622A1 (zh) 一种距离测量方法、装置及***
CN116256767A (zh) 一种激光雷达飞行时间测量方法及***
CN116338708A (zh) 飞行时间的测量方法、装置和***
CN113283569A (zh) 能够从时间-数字转换器接收tdc值的处理器
CN118041444B (zh) 一种用于计算光脉冲信号传输时间延迟的方法
CN112639515A (zh) 一种信号处理方法及装置
CN113614566A (zh) 测距方法、测距装置以及程序