Disclosure of Invention
The embodiment of the application provides distance testing equipment and a distance testing system, and aims to reduce interference between two-channel wireless receiving and transmitting units.
An object of an embodiment of the present application is to provide a distance testing apparatus, which includes a first wireless unit, a second wireless unit, a first carrier unit, a second carrier unit, a modulation unit, and a first demodulation unit;
the first carrier unit is used for generating a first carrier signal, the second carrier unit is used for generating a second carrier signal, and the frequency of the first carrier signal is different from that of the second carrier signal;
the first wireless unit is electrically connected with the first carrier unit through the modulation unit, and the modulation unit is used for modulating a modulation signal to be sent through the first carrier signal to obtain a first distance test signal;
the second wireless unit is electrically connected with the second carrier unit through the first demodulation unit, and the first demodulation unit is used for demodulating the received second distance test signal through the second carrier signal to obtain a first demodulation signal.
Optionally, the distance testing apparatus further includes a signal conversion unit, a second demodulation unit, and a third carrier unit;
the third carrier unit is used for generating a third carrier signal, the frequency of the third carrier signal is the same as that of the second carrier signal, and the phase difference is a preset angle;
the second wireless unit is electrically connected with the third carrier unit through the second demodulation unit, and the second demodulation unit is used for demodulating and modulating the second distance test signal through the third carrier signal to obtain a second demodulation signal;
the signal conversion unit is electrically connected with the first demodulation unit and the second demodulation unit and is used for processing the first demodulation signal and the second demodulation signal to acquire information carried in the second distance test signal.
Optionally, the signal conversion unit includes an analog-to-digital conversion module and a decoding module;
the decoding module is electrically connected with the first demodulation unit and the second demodulation unit through the analog-to-digital conversion module;
the analog-to-digital conversion module is used for sampling the first demodulation signal and the second demodulation signal and delivering the sampling result to the decoding module for processing.
Optionally, the signal conversion unit further comprises a gain module;
the analog-to-digital conversion module is electrically connected with the first demodulation unit and the second demodulation unit through the gain module;
the gain module is configured to amplify the first demodulation signal and the second demodulation signal and send the amplified first demodulation signal and the amplified second demodulation signal to the analog-to-digital conversion module for processing.
Optionally, the distance testing apparatus further comprises a gain control unit;
the gain control unit is electrically connected with the gain module and used for controlling the gain multiple of the gain module.
Optionally, the signal conversion unit further includes a filtering module;
the decoding module is electrically connected with the analog-to-digital conversion module through the filtering module;
and the filtering module is used for sending the sampling result to the decoding module after filtering the sampling result.
Optionally, the distance testing apparatus further comprises a frequency generation unit;
the frequency generation unit is electrically connected with the first carrier unit, the second carrier unit and the third carrier unit and is used for providing clock signals for the first carrier unit, the second carrier unit and the third carrier unit.
Optionally, the distance testing apparatus further includes an encoding unit and a pulse generating unit;
the coding unit is electrically connected with the modulation unit through the pulse generation unit;
the pulse generating unit is used for converting the data to be sent of the coding unit into the modulation signal to be sent, and sending the modulation signal to the modulation unit.
Optionally, the distance test apparatus further comprises a wired communication unit.
It is a further object of an embodiment of the present application to provide a distance testing system, comprising at least 2 distance testing devices; the 2 distance test devices are respectively a first distance test device and a second distance test device;
a first distance test signal sent by a first wireless unit of the first distance test equipment is received by a second wireless unit of the second distance test equipment;
the second distance test signal transmitted by the first wireless unit of the second distance test device is received by the second wireless unit of the first distance test device.
Compared with the prior art, the method has the following beneficial effects:
according to the distance testing device and the distance testing system, the first carrier unit and the second carrier unit are used for providing the first carrier signal and the second carrier signal with different frequencies for the modulation unit and the first demodulation unit respectively. Therefore, interference between the modulation unit and the first demodulation unit is avoided in the process of transmitting the first distance test signal and receiving the second distance test signal.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are some embodiments of the present application, but not all embodiments. The components of the embodiments of the present application, generally described and illustrated in the figures herein, can be arranged and designed in a wide variety of different configurations.
Thus, the following detailed description of the embodiments of the present application, presented in the accompanying drawings, is not intended to limit the scope of the claimed application, but is merely representative of selected embodiments of the application. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures.
In the description of the present application, it is noted that the terms "first", "second", "third", and the like are used merely for distinguishing between descriptions and are not intended to indicate or imply relative importance.
In the description of the present application, it is further noted that, unless expressly stated or limited otherwise, the terms "disposed," "mounted," "connected," and "connected" are to be construed broadly, e.g., as meaning either a fixed connection, a removable connection, or an integral connection; can be mechanically or electrically connected; they may be connected directly or indirectly through intervening media, or they may be interconnected between two elements. The specific meaning of the above terms in the present application can be understood in a specific case by those of ordinary skill in the art.
As described in the background section, to reduce interference in communications between two-channel radios. The embodiment of the application provides a distance test device.
Referring to fig. 1, fig. 1 is a schematic structural diagram of a distance detection apparatus according to an embodiment of the present disclosure. The distance test apparatus includes a first radio unit 120, a second radio unit 110, a first carrier unit 520, a second carrier unit 510, a modulation unit 220, and a first demodulation unit 210.
The first carrier unit 520 is configured to generate a first carrier signal, and the second carrier unit 510 is configured to generate a second carrier signal, where the first carrier signal and the second carrier signal have different frequencies.
The first wireless unit 120 is electrically connected to the first carrier unit 520 through the modulation unit 220, and the modulation unit 220 is configured to modulate a modulation signal to be transmitted through the first carrier signal to obtain a first distance test signal.
The second wireless unit 110 is electrically connected to the second carrier unit through the first demodulation unit 210, and the first demodulation unit 210 is configured to demodulate the received second distance test signal through the second carrier signal to obtain a first demodulated signal.
Referring to fig. 1 again, the distance detecting apparatus further includes a pulse generating unit 400 and a coding unit 600, and the coding unit 600 passes through the pulse generating unit 400 and the modulating unit 220. It should be understood that the modulated signal to be transmitted is obtained by the pulse generating unit 400 processing the encoded data of the encoding unit 600. Further, the modulation unit 220 is configured to perform modulation processing on the modulation signal to be sent through the first carrier signal to obtain a first distance test signal.
In particular, please refer to fig. 2, in one possible example. The first carrier signal is a sine wave with a preset frequency, the modulation signal to be transmitted is a square wave signal (0 represents low level, and 1 represents high level) corresponding to the encoded data, and the modulation signal is loaded to the first carrier signal to be modulated, so that a first distance test signal is obtained.
In this way, the first carrier unit 520 and the second carrier unit 510 provide the first carrier signal and the second carrier signal with different frequencies to the modulation unit 220 and the first demodulation unit 210, respectively. Interference between the modulation unit 220 and the first demodulation unit 210 is avoided during the process of transmitting the first distance test signal and receiving the first distance test signal.
Optionally, referring to fig. 3, the distance testing apparatus further includes a third carrier unit 530, a second demodulation unit, and a signal conversion unit 300.
The third carrier unit 530 is configured to generate a third carrier signal, where the third carrier signal has the same frequency as the second carrier signal and has a phase difference of a preset angle.
The second wireless unit 110 is further electrically connected to the third carrier unit through the second demodulation unit, and the second demodulation unit is configured to demodulate the second distance test signal through the third carrier signal to obtain a second demodulation signal.
The signal conversion unit 300 is electrically connected to the first demodulation unit 210 and the second demodulation unit, and is configured to process the first demodulation signal and the second demodulation signal to obtain information carried in the second distance test signal.
For example, in one possible example, the distance detection device implements the distance test by transmitting a wireless signal with another distance detection device. Since the signal itself fluctuates during the demodulation process, the preset angle is 90 ° in order to make the second distance test signal easily detected at any time.
In this way, the second demodulation unit demodulates the second distance test signal through the third carrier signal to obtain a second demodulated signal. The signal conversion unit 300 processes the first demodulation signal and the second demodulation signal to obtain information carried in the second distance test signal.
It should be appreciated that when two co-frequency carrier signals are demodulated from the second range test signal, the result of the demodulation is related to the phase difference of the co-frequency carrier signals. If the phase difference is 90 °, the first demodulation signal is complementary to the second demodulation signal, so that when the first demodulation signal is weaker, the second demodulation signal is necessarily stronger to compensate for the weaker first demodulation signal.
Optionally, referring to fig. 4, the signal conversion unit 300 includes an analog-to-digital conversion module 310 and a decoding module 330. The decoding module 330 is electrically connected to the first demodulating unit 210 and the second demodulating unit through the analog-to-digital converting module 310. The analog-to-digital conversion module 310 is configured to sample the first demodulation signal and the second demodulation signal, and deliver the sampling result to the decoding module 330 for processing.
It should be understood that the first demodulated signal and the second demodulated signal are analog signals, and need to be sampled by the analog-to-digital conversion module 310 to obtain their corresponding digital signals. Further, the decoding module 330 processes the digital signal obtained by sampling to extract the information carried in the second distance test signal.
Optionally, the signal conversion unit 300 further includes a filtering module 320, and the decoding module 330 is electrically connected to the analog-to-digital conversion module 310 through the filtering module 320. The filtering module 320 is configured to filter the sampling result and send the result to the decoding module 330.
It should be understood that other wireless signals present in the natural environment may interfere with the second range test signal. Other wireless signals are filtered by the filtering module 320, so that the decoding module 330 can accurately extract the information carried in the second distance test signal.
Optionally, the signal conversion unit 300 further includes a gain module 340, and the analog-to-digital conversion module 310 is electrically connected to the first demodulation unit 210 and the second demodulation unit through the gain module 340. The gain module 340 is configured to amplify the first demodulated signal and the second demodulated signal, and then send the amplified first demodulated signal and the amplified second demodulated signal to the analog-to-digital conversion module 310 for processing.
In this way, the gain module 340 amplifies the first demodulation signal and the second demodulation signal, so as to further reduce the influence on the test result when the second distance test signal is weak.
Optionally, the distance testing apparatus further comprises a frequency generation unit 700; the frequency generating unit 700 is electrically connected to the first carrier unit 520, the second carrier unit 510 and the third carrier unit 530, and is configured to provide clock signals for the first carrier unit 520, the second carrier unit 510 and the third carrier unit 530.
The frequency generating unit 700 may also be electrically connected to the analog-to-digital converting module 310, and is configured to provide a high-frequency clock signal to the analog-to-digital converting module 310, so as to improve the conversion accuracy.
It should be noted that the first carrier unit 520, the second carrier unit 510, and the third carrier unit 530 may be 3 independent hardware, or may be a plurality of functional units integrated in a single hardware, and a user may select the functional units according to actual requirements.
Optionally, the distance testing apparatus further includes a gain control unit 800, and the gain control unit 800 is electrically connected to the gain module 340 for controlling the gain multiple of the gain module 340.
It should be appreciated that the gain module 340 may cause a large power consumption while amplifying the first demodulated signal and the second demodulated signal. Therefore, the user adjusts the gain factor of the gain module 340 to a proper range according to the estimated test distance through the gain control unit 800. In this way, the relationship between power consumption and test distance is balanced.
Optionally, the distance test apparatus further comprises a wired communication unit. Such as SPI bus, serial bus, IIC bus, etc.
Optionally, an embodiment of the present application further provides a distance testing system, which includes 2 distance testing devices, where the 2 distance testing devices are a first distance testing device 1110 and a second distance testing device 1120, respectively.
Referring to fig. 5, the first distance testing apparatus 1110 is configured to send the first distance testing signal to the second distance testing apparatus 1120 and record a first sending time.
The second distance testing device 1120 is configured to receive the first distance testing signal and record a first receiving time; and transmits a second distance test signal to the first distance test apparatus 1110, and records a second transmission time.
The first distance testing device 1110 is further configured to receive the second distance testing signal, record a second receiving time, and calculate and obtain a distance between the first distance testing device 1110 and the second distance testing device 1120 according to the first sending time, the second sending time, the first receiving time, and the second receiving time.
Specifically, let the first transmission time be t1The first receiving time is t2The second transmission time is t3The second receiving time is t4First distance test apparatus 1110 and the sameThe distance between the second distance test devices 1120 is L, then L can be expressed as:
wherein C is the propagation speed of the wireless signal in the air, t3-t2The time it takes for the second distance test equipment 1120 to process the first distance test signal.
It is worth mentioning that the distance testing device further comprises a memory, a processor and other components. The memory, processor and elements are electrically connected to each other, directly or indirectly, to enable data transfer or interaction. For example, the components may be electrically connected to each other via one or more communication buses or signal lines.
The Memory may be, but is not limited to, a Random Access Memory (RAM), a Read Only Memory (ROM), a Programmable Read-Only Memory (PROM), an Erasable Read-Only Memory (EPROM), an electrically Erasable Read-Only Memory (EEPROM), and the like. The memory is used for storing programs, and the processor executes the programs after receiving the execution instructions.
The processor may be an integrated circuit chip having signal processing capabilities. The Processor may be a general-purpose Processor, and includes a Central Processing Unit (CPU), a Network Processor (NP), and the like; but may also be a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), a Field Programmable Gate Array (FPGA) or other programmable logic device, discrete gate or transistor logic device, discrete hardware components. The various methods, steps, and logic blocks disclosed in the embodiments of the present application may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
In summary, the distance testing apparatus and system provided in the embodiments of the present application provide the first carrier signal and the second carrier signal with different frequencies for the modulation unit and the first demodulation unit through the first carrier unit and the second carrier unit, respectively. Therefore, interference between the modulation unit and the first demodulation unit is avoided in the process of transmitting the first distance test signal and receiving the second distance test signal.
It is noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
The above description is only for various embodiments of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily conceive of changes or substitutions within the technical scope of the present application, and all such changes or substitutions are included in the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.