A signal sampling circuit and target positioning method
By using n-level comparators and switching devices in the signal sampling circuit for step-by-step comparison, the target sampling signal range is screened out, which solves the problem of large power consumption in traditional signal sampling circuits, and achieves low power consumption and precise positioning.
Patent Information
- Application Number
- CN202111310151.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-11-03
- Publication Date
- 2024-11-12
- Estimated Expiration
- 2041-11-03
AI Technical Summary
In order to improve the sampling rate in traditional signal sampling circuits, each sampling channel needs to be connected to an ADC, resulting in analog-to-digital conversion of the signal data of all sampling channels simultaneously, resulting in greater power consumption.
A signal sampling circuit is adopted to receive the sampling signal of the same sensor unit through an n-level comparator, and the reference signal values connected to different stages are set to be different. A first switching device is set between adjacent two stages of comparators, and only closed The next stage comparator corresponding to the switching device continues to perform comparison operations, and does not perform disconnection, saving power consumption, and filtering out the target sample signal range through step by step comparison.
It realizes the power consumption of the signal sampling circuit, avoids unnecessary power consumption, and does not require an analog-to-digital converter, which occupies less than that of the traditional multi-channel sampling circuit, which can reduce the occupancy area of the sampling circuit.
Smart Images

Figure CN114039601B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of circuit technology, and in particular to a signal sampling circuit and a target positioning method. Background Art
[0002] At present, using digital signal processing systems for information processing has become a relatively common application. However, various physical objects or signals in the real environment are usually analog signals. In the signal sampling circuit, an analog-to-digital conversion circuit is required to complete the conversion of analog signals to digital signals.
[0003] However, in traditional signal sampling circuits, in order to increase the sampling rate, each sampling channel is connected to an ADC (analog-to-digital converter) to convert the analog signal into a digital signal, which will cause the signal data of all sampling channels to be converted into digital signals at the same time, resulting in higher power consumption of the signal sampling circuit. Summary of the invention
[0004] The embodiments of the present application provide a signal sampling circuit and a target positioning method, which do not require the use of an analog-to-digital converter and can reduce the power consumption of the signal sampling circuit.
[0005] According to a first aspect of an embodiment of the present application, a signal sampling circuit is provided, comprising:
[0006] Sensor unit;
[0007] n-level comparators, each group of the n-level comparators is used to receive a sampling signal from the same sensor unit, wherein n is a natural number greater than 1, and different levels of comparators have different reference signal values, and the same level of comparators in different groups of the n-level comparators have the same reference signal values;
[0008] A first switch device is provided between two adjacent comparators.
[0009] In some implementations, the signal sampling circuit further includes:
[0010] An output control unit is electrically connected to an output terminal of each of the comparators.
[0011] In some implementations, a second switch device is provided between the output control unit and the output terminal of each comparator.
[0012] In some implementations, the signal sampling circuit further includes:
[0013] A storage unit is electrically connected to the output terminal of each of the comparators through the second switching device.
[0014] In some implementations, the signal sampling circuit further includes:
[0015] A reference signal control unit is electrically connected to the reference signal input terminal of each stage of the comparator.
[0016] In some implementations, a third switch device is provided between the reference signal control unit and the reference signal input terminal of each stage of the comparator.
[0017] In some implementations, the reference signal value is a reference voltage value, and a voltage dividing unit is provided between reference voltage input terminals of two adjacent levels of comparators, and the voltage dividing unit includes a resistor.
[0018] In some embodiments, the sensor unit includes a sensor and a current-to-voltage converter, wherein the current-to-voltage converter is electrically connected between the sensor and each group of the n-stage comparators.
[0019] In some embodiments, the current-to-voltage converter includes a resistor, one end of the resistor is grounded, and the other end of the resistor is connected between the sensor and each group of the n-stage comparators.
[0020] In some implementations, the signal sampling circuit further includes:
[0021] A data processing unit is electrically connected to the output end of each comparator.
[0022] In some implementations, the signal sampling circuit further includes:
[0023] A fourth switch device is provided between the sensor unit and the sampling signal input terminal of each of the comparators, and the data processing unit is used to control the closing and opening of the fourth switch device.
[0024] In some implementations, the first switching device includes a MOS transistor.
[0025] A second aspect of the embodiments of the present application provides a target positioning method, using the signal sampling circuit as described in the first aspect, the method comprising:
[0026] Controlling the sensor unit to sample the target object and obtain a sampling signal;
[0027] The first-stage comparator performs a comparison operation based on the sampling signal and the reference signal value, and outputs a comparison result;
[0028] The comparison result output by the n-1th comparator controls the closing and opening of the first switch device between the n-1th comparator and the nth comparator;
[0029] The sampling positions of the sensor units corresponding to all comparison results output by the k-th level comparator are determined as target positions, wherein 1≤k≤n.
[0030] In some implementations, before determining that the sampling position of the sensor unit corresponding to all comparison results output by the k-th level comparator is the target position, the method further includes:
[0031] Traversing the result array based on the set array size to select a target array, wherein the result array includes the comparison results output by each of the comparators at the same level, and the target array is determined based on the number and position of the target results in the target array;
[0032] Control the next-level comparator corresponding to the comparator corresponding to the target array to perform a comparison operation;
[0033] The step of determining that the sampling position of the sensor unit corresponding to all comparison results output by the k-th level comparator is the target position includes:
[0034] The sampling position of the target sensor is determined as the target position, wherein the target sensor is determined by the target result in the target array corresponding to the k-th stage comparator.
[0035] In some implementations, the set array size corresponding to each level of the comparator for selecting the target array is different.
[0036] The signal sampling circuit and target positioning method provided by the embodiment of the present application, by setting each group of n-level comparators to receive the sampling signal of the same sensor unit, the reference signal values connected to the comparators of different levels are different, and a first switch device is set between two adjacent comparators, and the comparison result output by the upper comparator can control the closing and opening of the corresponding first switch device, and only the next comparator corresponding to the closed first switch device continues to perform the comparison operation, and the next comparator corresponding to the disconnected first switch device does not perform the comparison operation, so that only part of the next comparator performs the comparison operation, and the rest does not perform the comparison operation, which can save the power consumption of the sampling circuit and avoid unnecessary power consumption waste. In addition, by setting the reference signal values connected to the comparators of different levels to be different, the sampling signals of each sensor unit can be compared step by step, and all the sampling signals can filter out the target sampling signal range in the process of step by step comparison, and further can lock the sampling position of the sensor unit corresponding to the target sampling signal, and then obtain the position of the target object, which can realize the positioning and tracking function, without using an analog-to-digital converter, and only the comparators of some sampling channels are running, which can avoid the power consumption of all sampling channels in the existing sampling circuit performing analog-to-digital conversion at the same time. The occupied area of the n-stage comparator is also smaller than the area occupied by the analog-to-digital converter of the multi-channel sampling circuit in the prior art, and the occupied area of the sampling circuit can be reduced. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] Figure 1 A schematic structural block diagram of a signal sampling circuit provided in an embodiment of the present application;
[0038] Figure 2 A schematic structural diagram of another signal sampling circuit provided in an embodiment of the present application;
[0039] Figure 3 A schematic flow chart of a target positioning method provided in an embodiment of the present application;
[0040] Figure 4 A schematic diagram of a comparison result output by an n-level comparator provided in an embodiment of the present application;
[0041] Figure 5 A schematic diagram of a target array provided in an embodiment of the present application;
[0042] Figure 6 A schematic diagram of comparison results output by another n-level comparator provided in an embodiment of the present application. DETAILED DESCRIPTION
[0043] In order to better understand the technical solutions provided by the embodiments of this specification, the technical solutions of the embodiments of this specification are described in detail below through the accompanying drawings and specific embodiments. It should be understood that the embodiments of this specification and the specific features in the embodiments are detailed descriptions of the technical solutions of the embodiments of this specification, rather than limitations on the technical solutions of this specification. In the absence of conflict, the embodiments of this specification and the technical features in the embodiments can be combined with each other.
[0044] In this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply that there is any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that the process, method, article or equipment including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or equipment. In the absence of more restrictions, the elements limited by the statement "comprise one..." do not exclude the existence of other identical elements in the process, method, article or equipment including the elements. The term "more than two" includes two or more than two situations.
[0045] At present, the use of digital signal processing systems for information processing has become a common application. However, various physical objects or signals in the real environment are usually analog signals. In the signal sampling circuit, an analog-to-digital conversion circuit is needed to complete the conversion of analog signals to digital signals. However, in the traditional signal sampling circuit, in order to increase the sampling rate, each sampling channel is connected to an ADC to convert the analog signal into a digital signal, which will cause the signal data of all sampling channels to be converted to analog at the same time, resulting in high power consumption of the signal sampling circuit.
[0046] In view of this, an embodiment of the present application provides a signal sampling circuit and a target positioning method, which do not require the use of an analog-to-digital converter and can reduce the power consumption of the signal sampling circuit.
[0047] In a first aspect of an embodiment of the present application, a signal sampling circuit is provided. Figure 1 Schematic block diagram of a signal sampling circuit provided in an embodiment of the present application. Figure 1 As shown, the signal sampling circuit provided in the embodiment of the present application includes: a sensor unit 100, the sensor unit 100 can be a light sensor, a pressure sensor, a temperature sensor, etc., which is not specifically limited in the embodiment of the present application. An n-level comparator 200, where n is a natural number greater than 1, is exemplary, Figure 1In the n-level comparator shown, n=3, i.e., a 3-level comparator; each group of n-level comparators 200 is used to receive sampling signals from the same sensor unit 100, different levels of comparators are connected to different reference signal values, and the same level comparators between different groups of n-level comparators 200 are connected to the same reference signal values; a first switch device 300, the first switch device 300 is arranged between two adjacent levels of comparators.
[0048] For example, Figure 1 As shown, the signal sampling circuit may include multiple groups of n-level comparators 200, Figure 1 The three-level comparator is shown, and n=3 is used as an example for explanation. Each group of n-level comparators 200 includes a first-level comparator 210, a second-level comparator 220, and a third-level comparator 230; the reference signal value connected to the reference signal input terminal c of all the same-level comparators of all groups of n-level comparators 200 is the same, that is, all first-level comparators 210 are connected to the first reference signal Ref1, the reference signal input terminal c of all second-level comparators 220 is connected to the second reference signal Ref2, and the reference signal input terminal c of all third-level comparators 230 is connected to the third reference signal Ref3; the reference signal values connected to the comparators of different levels are different, that is, the values of the first reference signal Ref1, the second reference signal Ref2, and the third reference signal Ref3 can be different. The sampling signal input terminal e of each level comparator in the same group of n-level comparators 200 is connected to the same sensor unit 100, and a first switching device 300 is arranged between two adjacent levels of comparators. Specifically, the first switching device 300 can be arranged between the output terminal of the upper level comparator and the sampling signal input terminal of the lower level comparator. It should be noted that the upper level comparator is the comparator relatively close to the sensor unit 100 among the two adjacent levels of comparators, and the lower level comparator is the comparator relatively far away from the sensor unit 100, for example, between the first level comparator 210 and the second level comparator 220, the first level comparator 210 is the upper level comparator, and the second level comparator 220 is the lower level comparator. Specifically, a first switching device 300 is arranged between each first-level comparator 210 and each second-level comparator 220, and the first-level comparator 210, the second-level comparator 220 and the first switching device 300 are in a one-to-one relationship. A first switching device 300 is arranged between each second-level comparator 220 and each third-level comparator 230, and the second-level comparator 220, the third-level comparator 230 and the first switching device 300 are in a one-to-one relationship. Figure 1 The number of comparators, the number of first switch devices 300 , the number of sensor units 100 , and the value of n shown are all schematic and are not intended to be a specific limitation of the embodiments of the present application.
[0049] Example Figure 1 The working principle of the signal sampling circuit shown:
[0050] All sensor units 100 are sampled synchronously, and each sensor unit 100 obtains a corresponding sampling signal. The sampling signal is input into the first-stage comparator 210 through the sampling signal input terminal e of the correspondingly connected first-stage comparator 210. All first-stage comparators 210 perform comparison operations based on the first reference signal Ref1 and the corresponding input sampling signal to obtain a first-stage comparison result. The first-stage comparison result can be output through the output terminal b of the first-stage comparator 210. The first-stage comparison result output by the first-stage comparator 210 can control the closing and opening of the first switching device 300 correspondingly connected to the output terminal b. If the first-level comparison result output by the first-level comparator 210 controls the closing of the corresponding first switch device 300, the sampling signal input terminal e of the corresponding sensor unit 100 and the corresponding second-level sensor 220 is turned on through the closed first switch device 300, and the corresponding second-level comparator 220 can perform a comparison operation based on the second reference signal Ref2 and the corresponding input sampling signal to obtain a second-level comparison result; if the first-level comparison result output by the first-level comparator 210 controls the disconnection of the corresponding first switch device 300, the sampling signal input terminal e of the corresponding second-level comparator 220 cannot receive the sampling signal, and the corresponding second-level comparator 220 does not perform a comparison operation. Similarly, the second-level comparison result can control the closing and disconnection of the first switch device between the second-level comparator 220 and the third-level comparator 230. If the second-level comparison result output by the second-level comparator 220 controls the closing of the corresponding first switch device 300, the sampling signal input terminal e of the corresponding sensor unit 100 and the corresponding third-level sensor 230 is turned on through the closed first switch device 300, and the corresponding third-level comparator 230 can perform a comparison operation based on the third reference signal Ref3 and the corresponding input sampling signal to obtain a third-level comparison result; if the second-level comparison result output by the second-level comparator 220 controls the disconnection of the corresponding first switch device 300, the sampling signal input terminal e of the corresponding third-level comparator 230 does not receive the sampling signal, and the corresponding third-level comparator 230 does not perform a comparison operation. At this time, the third comparison result output by all third-level comparators 230 is the final sampling result.
[0051] It should be noted that the comparison results of the corresponding outputs of the comparators at the same level may partially control the closing of the first switch device 300 and partially control the opening of the first switch device 300. For example, among the first-level comparison results output by all comparators of the first-level comparator 210, three first-level comparison results can control the closing of the corresponding first switch device 300, and the remaining first-level comparison results all control the opening of the corresponding first switch device 300. In this case, the second-level comparator 220 corresponding to the closed first switch device 300 can perform the comparison operation, and the second-level comparator 220 corresponding to the opened first switch device 300 cannot perform the comparison operation. The comparator that cannot perform the comparison operation can be considered to be not operating and will not occupy circuit power consumption. The values of the first reference signal Ref1, the second reference signal Ref2 and the third reference signal Ref3 are different from each other. The first reference signal Ref1 can be set to be greater than the second reference signal Ref2, and the second reference signal Ref2 can be set to be greater than the third reference signal Ref3 according to the sampling requirements. In this way, the sampling signal can be compared and output step by step in the n-level comparator to obtain the final comparison result. By adopting this sampling signal processing mode, the target object can be located and tracked, that is, the number of sensor units 100 corresponding to each level of comparison results is reduced step by step, and the sampling position of the sensor unit 100 corresponding to the final comparison result can be used as the positioning and tracking position of the target object. The sampling signal that is not within the target sampling signal range is eliminated, and the corresponding comparator does not need to be operated. The comparator corresponding to the sampling signal selected step by step is retained for comparison operation, which can reduce the operation of unnecessary comparators, save the power consumption of the sampling circuit, and can obtain the position range of the target object corresponding to the target sampling signal range without using an analog-to-digital converter. It is easy to understand that the target sampling range can be a signal range set according to the sampling purpose, and the target object is the sampling object found according to the positioning and tracking needs. For example, a possible application scenario is to use a photosensitive sensor to locate and track the position of the eyeball in a VR device.
[0052] Exemplarily, the comparison result output by each comparator can be 0 or 1. For example, when the sampling signal is greater than the reference signal value, the comparison result output is 1, otherwise the output is 0, or, when the sampling signal is less than the reference signal value, the comparison result output is 1, otherwise the output is 0, then the analog sampling signal can be converted into a digital signal, and the n-level comparator 200 can replace the analog-to-digital converter. The sampling signal can be a current signal or a voltage signal, and the corresponding reference signal can be a current signal or a voltage signal, which is not specifically limited in the embodiment of the present application. Each sensor unit 100 and a correspondingly connected group of n-level comparators 200 can form a sampling channel, and multiple sensor units 100 form multiple sampling channels. The occupied area of the comparator is smaller than the occupied area of the analog-to-digital converter. Therefore, in the circuit that also meets the multi-channel sampling requirements, the area occupied by the n-level comparator of the embodiment of the present application is smaller than the area occupied by the analog-to-digital converter.
[0053] The signal sampling circuit provided in the embodiment of the present application is configured to receive the sampling signal of the same sensor unit 100 by setting each group of n-level comparators 200, and different levels of comparators are connected to different reference signal values. A first switch device 300 is set between two adjacent levels of comparators, and the comparison result output by the upper-level comparator can control the closing and opening of the corresponding first switch device 300. Only the next-level comparator corresponding to the closed first switch device 300 continues to perform the comparison operation, and the next-level comparator corresponding to the open first switch device 300 does not perform the comparison operation. Therefore, only part of the next-level comparators perform the comparison operation, and the rest do not perform the comparison operation, which can save the power consumption of the sampling circuit and avoid unnecessary power consumption waste. In addition, by setting different reference signal values connected to different levels of comparators, the sampling signals of each sensor unit 100 can be compared step by step. In the process of step by step comparison, all sampling signals can screen out the target sampling signal range, and further lock the sampling position of the sensor unit corresponding to the target sampling signal, thereby obtaining the position of the target object, and realizing the positioning and tracking function, without using an analog-to-digital converter, and only the comparators of some sampling channels are running, which can avoid the power consumption of all sampling channels in the existing sampling circuit performing analog-to-digital conversion at the same time. The occupied area of the n-level comparator 200 is also smaller than the area occupied by the analog-to-digital converter of the multi-channel sampling circuit in the prior art, which can reduce the occupied area of the sampling circuit.
[0054] In some embodiments, Figure 2 This is a schematic structural diagram of another signal sampling circuit provided in an embodiment of the present application. Figure 2 As shown, for example, the sensor unit 100 uses a photodiode D, and the first switch device 300 uses a first MOS tube M1. Figure 2The first MOS tube M1 shown is a PMOS, and the characteristics of PMOS are that it is turned on at a low level and turned off at a high level. The turning on of the first MOS tube M1 means the closing of the first switch device, and the turning off of the first MOS tube M1 means the disconnection of the first switch device. For example, the output end of the previous comparator is connected to the gate of the first MOS tube M1, the source of the first MOS tube M1 is connected to the photosensitive diode D, and the drain of the first MOS tube M1 is connected to the sampling signal input end e of the next comparator. When the comparison result output by the previous comparator is 0, the corresponding first MOS tube M1 can be controlled to turn on, the source and drain of the first MOS tube M1 are turned on, and the sampling signal input end e of the next comparator can receive the sampling signal for comparison operation; when the comparison result output by the previous comparator is 1, the corresponding first MOS tube M1 can be controlled to turn off, the source and drain of the first MOS tube M1 are in a disconnected state, and the sampling signal input end e of the next comparator cannot receive the sampling signal, and no comparison operation is performed. Then Figure 2 The application scenario of the signal sampling circuit shown in the figure can be an eye tracking application in a VR device. The photodiode D can sense the light reflected by the eyeball and can generate a current change according to the strength of the reflected light, thereby realizing the application of identifying the eyeball position. Specifically, an infrared light source can be set, and the eyeball reflects the infrared light. The reflected light at the eyeball position is different from the reflected light at other positions, which causes the current change of the photodiode D to be different, and the relevant sampling signal of the eyeball position can be obtained. Figure 2 The structure of the signal sampling circuit shown is only for illustration and is not intended to be a specific limitation of the embodiments of the present application.
[0055] In some embodiments, continue to refer to Figure 2 , the signal sampling circuit provided in the embodiment of the present application may also include: an output control unit 400, and the output control unit 400 is electrically connected to the output terminal b of each comparator. The output control unit 400 can be used to control whether the comparison result output by each comparator can be output to the storage unit for storage. The storage can be temporary storage or normal storage, which is not specifically limited in the embodiment of the present application. Exemplarily, the output control unit 400 for the output of the comparison result can be implemented by a controller and a switch device, and a second switch device is provided between the output control unit 400 and the output terminal b of each comparator.
[0056] In some embodiments, the signal sampling circuit provided in the embodiment of the present application further includes: a storage unit, which is electrically connected to the output terminal of each comparator through a second switch device. The setting of the output control unit 400 can select the comparison result output by any level of comparator as the final sampling result for output. For example, all the comparison results output by the first-level comparator can be used as the output result of the signal sampling circuit, and the output control unit 400 can use the controller to control the opening of the second switch device connected to the output terminal b of the first-level comparator 210, and then all the comparison results output by the first-level comparator 210 are output to the storage unit through the turned-on second switch device for storage. If all the comparison results output by the third-level comparator 230 are used as the output result of the signal sampling circuit, the second switch device connected to the output terminal b of the third-level comparator 230 can be controlled to be turned on, and the opening or closing of the second switch device corresponding to the first-level comparator 210 and the second switch device corresponding to the second-level comparator 220 can be specifically set according to the sampling requirements, and the embodiment of the present application is not specifically limited.
[0057] The signal sampling circuit provided in the embodiment of the present application can select the comparison result output by any level of comparator as the final sampling result for output by setting the output control unit 400. The collection of sampling signals is relatively flexible, and the number of comparator levels for output can be set according to specific needs. The signal sampling circuit has strong compatibility.
[0058] In some embodiments, the signal sampling circuit provided in the embodiment of the present application further includes: a reference signal control unit, the reference signal control unit is electrically connected to the reference signal input terminal of each level of comparator. The reference signal control unit can realize the input control of the reference signal through a switch device, for example, a third switch device is provided between the reference signal control unit and the reference signal input terminal of each level of comparator. The reference signal control unit can control the closing and disconnection of the third switch device through a controller to realize the control of whether the reference signal input terminal of each level of comparator inputs the reference signal, and can control the operation of each level of comparator. Exemplarily, the reference signal input terminals of all comparators of each level of comparator can be connected to the same third switch device, and the corresponding comparator of the same level can be controlled by controlling the closing or disconnection of the corresponding third switch device to control whether the comparison operation is performed. If there is no input of the reference signal, the comparator cannot perform the comparison operation. If there is an input of the reference signal, the comparator has the conditions for the comparison operation. Therefore, the setting of the reference signal control unit and the third switch device can control whether the corresponding comparator is turned on or not.
[0059] The signal sampling circuit provided in the embodiment of the present application, by setting a reference signal control unit and a third switching device, can control whether the corresponding connected comparator can perform a comparison operation by controlling the input of the reference signal, thereby realizing the operation control of the comparator, and can put the comparator that does not need to perform a comparison operation into a non-operating state such as a sleep state, thereby avoiding the ineffective operation of the comparator and saving circuit power consumption.
[0060] In some embodiments, the reference signal value is a reference voltage value, and a voltage divider unit is provided between the reference voltage input terminals of the adjacent two-stage comparators, and the voltage divider unit includes a resistor. The reference signal compared by the comparator in the signal sampling circuit provided in the embodiment of the present application may be a voltage signal, or a current signal or a signal in other forms, etc. The embodiment of the present application is exemplified by a voltage signal. When the reference signal is a voltage signal, the reference voltage value input to each level of the comparator may be different. In combination with the first switch device using PMOS, as the number of comparator stages increases, the corresponding reference voltage value also decreases or increases step by step, mainly depending on the comparison logic of the comparator. If the first switch device uses NMOS, the corresponding reference voltage value increases or decreases with the increase in the number of comparator stages, which also depends on the comparison logic of the comparator. When the reference voltage value decreases with the increase in the number of comparator stages, a voltage divider unit needs to be provided between the reference voltage values input by the adjacent two-stage comparators. A relatively simple voltage divider device may be a resistor, and the resistor voltage division is relatively conventional. The resistor in the voltage divider unit can divide a part of the reference voltage input by the previous level comparator, so the reference voltage input by the next level comparator is less than the reference voltage input by the previous level comparator.
[0061] The signal sampling circuit provided in the embodiment of the present application realizes different reference voltage values for inputs of comparators of different levels by setting a voltage divider unit between the reference voltage input terminals of two adjacent comparators, wherein the voltage divider unit includes a resistor. The circuit structure is easy to implement and has a simple circuit structure.
[0062] In some embodiments, the sensor unit includes a sensor and a current-to-voltage converter, and the current-to-voltage converter is electrically connected between the sensor and each group of n-level comparators. If the reference signal is a voltage signal, the sampling signal input into the comparator also needs to be a voltage signal. Usually, the sampling signal collected by the sensor unit is a current signal, and a current-to-voltage converter is required to convert the current signal into a voltage signal. The current-to-voltage converter may include a resistor, one end of the resistor is used for grounding, and the other end of the resistor is connected between the sensor and each group of n-level comparators. The current value obtained by the sensor sampling can be converted into a voltage signal through a resistor with one end grounded, that is, the potential at the connection point between the sensor and the other end of the resistor is the sampled voltage signal.
[0063] The signal sampling circuit provided in the embodiment of the present application is provided with a current-to-voltage converter to convert the current signal collected by the sensor into a voltage signal. The current-to-voltage converter can be realized by grounding one end and connecting the resistor of the sensor at the other end. It has a simple structure, low cost and is easy to implement.
[0064] In some embodiments, the signal sampling circuit provided in the embodiment of the present application further includes: a data processing unit, which is electrically connected to the output end of each comparator. A fourth switch device may be provided between the sensor unit and the sampling signal input end of each comparator, and the data processing unit is used to control the closing and opening of the fourth switch device. The data processing unit can be used to analyze and process the comparison results stored in the storage unit, then the data processing unit can be electrically connected to the storage unit, or the storage unit and the data processing unit can be provided in the same circuit module to share memory, or the data processing unit can be directly connected to the output end of each comparator to obtain the comparison result, and the embodiment of the present application is not specifically limited. The data processing unit can control the closing or opening of the fourth switch device at the sampling signal input end of the remaining comparators according to the analysis result of the current comparison result. If the remaining comparators are controlled according to the current analysis result without the need for comparison operation, the corresponding fourth switch device can be controlled to be disconnected so that the corresponding comparator cannot receive the sampling signal and cannot perform the comparison operation.
[0065] For example, continue to refer to Figure 2 The second switch device can also be a MOS tube, that is, a second MOS tube M2. The output control unit 400 is connected to the gate of each second MOS tube M2 to control the opening and closing of the second MOS tube M2. The source of the second MOS tube M2 is connected to the output terminal b of the corresponding comparator, and the drain d of the second MOS tube M2 can be connected to the storage unit or to the memory shared module of the storage unit and the data processing unit at the same time. Due to limited space, there are too many line connection lines. Figure 2The drain connection relationship of the second MOS tube M2 is not shown, and the storage unit and the data processing unit are not shown. The current-to-voltage converter may include a first resistor R1, one end of the first resistor R1 is grounded, and the other end of the first resistor R1 is connected to a photosensitive diode D, so that the current change of the photosensitive diode D can be converted into a potential change of the connection point between the first resistor R1 and the photosensitive diode D, that is, a change in the voltage value of the common potential point Q, and the current signal of the sampling signal can be converted into a voltage signal. Then, the voltage value of the common potential point Q is input from the sampling signal input terminal e of the comparator. A second resistor R2 is provided between the reference signal input terminal c of the first-stage comparator 210 and the reference signal input terminal c of the second-stage comparator 220, and a third resistor R3 is provided between the reference signal input terminal c of the second-stage comparator 220 and the reference signal input terminal c of the third-stage comparator 230. The second resistor R2 and the third resistor R3 are corresponding voltage dividing units, which are used to realize different reference voltage signal values input to each stage of the comparator. The total reference voltage is REF. After the voltage division of the fifth resistor R5, the first reference signal Ref1 is input into the first-level comparator 210. After the voltage division of the second resistor R2, the second reference signal Ref2 is obtained and input into the second-level comparator 220. After the voltage division of the third resistor R3, the third reference signal Ref3 is obtained and input into the third-level comparator 230. The reference signal input terminal c of each level of the comparator is connected to a third switch device SR. The third switch device SR can be a MOS tube, which is not specifically limited in the embodiment of the present application. The fourth resistor R4 can also be regarded as a voltage division function, and works together with the third resistor R3 to provide a third reference signal Ref3 to be input into the third-level comparator 230. Figure 2 The fourth switch device and the data processing unit are not shown. The fourth switch device may be a MOS tube, which is not specifically limited in the embodiment of the present application. Figure 2 The dotted line shown can represent the sampling target, and the photosensitive diode D is aligned with the sampling target to sample the signal. Using MOS tube as a switching device is easy to control and has high control accuracy. The device performance is mature and circuit integration is easy to achieve.
[0066] The signal sampling circuit provided in the embodiment of the present application can realize the comparison operation of the comparator or the dynamic adjustment of the result output by setting at least one of the first switching device, the output control unit, the second switching device, the reference signal control unit, the third switching device, the data processing unit and the fourth switching device, so as to realize rapid positioning of the target object and save circuit energy consumption.
[0067] A second aspect of the embodiment of the present application provides a target positioning method, using the signal sampling circuit as described in the first aspect, Figure 3 The following is a schematic flow chart of a target positioning method provided in an embodiment of the present application. Figure 3 As shown, the target positioning method provided in the embodiment of the present application includes:
[0068] S100: Control the sensor unit to sample the target object and obtain a sampling signal. The sampling signal may be a voltage signal, a current signal or a signal in other forms, which is not specifically limited in the embodiments of the present application. Control the sensor unit to sample the target object. If the sensor unit includes a photodiode, this step may be a process of energizing the signal sampling circuit. The photodiode will automatically sense the ambient light, energize the comparator, input the reference signal into the comparator, and the comparator can compare the sampling signal with the reference signal. Alternatively, a switch may be provided on the sensor unit to control whether the sensor unit is operating or not, which is not specifically limited in the embodiments of the present application.
[0069] S200: The first-stage comparator performs a comparison operation based on the sampling signal and the reference signal value, and outputs a comparison result. The comparison operation of the first-stage comparator can be performed automatically, and the comparison operation can be performed as long as the first reference signal Ref1 and the sampling signal are input into the first-stage comparator to obtain a comparison result. The operation of the comparator can also be controlled by controlling the input of the reference signal, which is not specifically limited in the embodiments of the present application.
[0070] S300: The comparison result output by the n-1th level comparator controls the closing and opening of the first switch device between the n-1th level comparator and the nth level comparator. The n-1th level comparator may be the upper level comparator of the two adjacent level comparators, and the nth level comparator is the lower level comparator. The comparison result output by the upper level comparator may control the closing and opening of the first switch device between the two adjacent level comparators.
[0071] S400: Determine the sampling position of the sensor unit corresponding to all comparison results output by the k-th level comparator as the target position, where 1≤k≤n. In the signal sampling circuit for target positioning, the comparison result output by any level comparator can be determined as the sampling result of the final target positioning according to the setting or according to the analysis of the comparison result of the existing output. 1≤k≤n, the k-th level comparator can be any level comparator, and due to the setting of the first switch device, the number of comparators for the comparison operation of the k-th level comparator may be less than or equal to the number of the first level comparators.
[0072] Exemplary, reference Figure 2 , the first switch device is PMOS, and the result output by each comparator is 0 or 1. 0 can be used as the target comparison result for target positioning. For example, Figure 4 A schematic diagram of a comparison result output by an n-level comparator provided in an embodiment of the present application. Figure 2 and Figure 4, all sensor units 100 form a 7×7 array, and the corresponding comparators of each level can also form a 7×7 array. Then the first-level comparison results output by the first-level comparator 210 can form a first-level result array (7×7 array). According to the first-level result array diagram, only four comparators in the first-level result array output a comparison result of 0, then the corresponding second-level comparator 220 will continue to perform the comparison operation of the sampling signal of the sampling channel, then only four comparators in the second-level comparator output a comparison result, and the comparison result output by the second-level comparator can have 2 bits, that is, the first bit is the comparison result output by the first-level comparator, and the second bit is the comparison result output by the second-level comparator itself. Figure 4 As shown, if only one comparator in the second-level result array output by the second-level comparator has a comparison result of 0, the second-level comparator can be used as the output comparator for final target positioning, and the second-level comparator is finally determined as the sampling result of the final target positioning, then k=2, and the sensor unit corresponding to the comparator whose output comparison result is 00 in the fourth row and fourth column of the 7×7 array can be regarded as the target sensor, and the positioning information of the sampling signal corresponding to the target sensor is the position information of the target object, and the target positioning is completed. Under the action of the first switch device, the second-level comparator corresponding to the first-level comparator whose output result is 1 does not need to perform a comparison operation, which can save the power consumption of the signal sampling circuit and improve the signal processing efficiency.
[0073] The target positioning method provided in the embodiment of the present application utilizes the signal sampling circuit of the first aspect, and by setting each group of n-level comparators 200 to receive the sampling signal of the same sensor unit 100, the reference signal values connected to the comparators of different levels are different, and a first switch device 300 is set between two adjacent comparators. The comparison result output by the upper-level comparator can control the closing and opening of the corresponding first switch device 300. Only the next-level comparator corresponding to the closed first switch device 300 continues to perform the comparison operation, and the next-level comparator corresponding to the open first switch device 300 does not perform the comparison operation. In this case, only part of the next-level comparators perform the comparison operation, and the rest do not perform the comparison operation, which can save the power consumption of the sampling circuit and avoid unnecessary power consumption waste. In addition, by setting different reference signal values connected to different levels of comparators, the sampling signals of each sensor unit 100 can be compared step by step. In the process of step by step comparison, all sampling signals can screen out the target sampling signal range, and further lock the sampling position of the sensor unit corresponding to the target sampling signal, thereby obtaining the position of the target object, and realizing the positioning and tracking function, without using an analog-to-digital converter, and only the comparators of some sampling channels are running, which can avoid the power consumption of all sampling channels in the existing sampling circuit performing analog-to-digital conversion at the same time. The occupied area of the n-level comparator 200 is also smaller than the area occupied by the analog-to-digital converter of the multi-channel sampling circuit in the prior art, which can reduce the occupied area of the sampling circuit.
[0074] In some implementations, before step S400, the following steps may also be included:
[0075] The result array is traversed based on the set array size to select a target array, wherein the result array includes comparison results output by each comparator in the same level comparator, and the target array is determined based on the number and position of the target results in the target array.
[0076] For example, Figure 5 A schematic diagram of a target array provided in an embodiment of the present application. Figure 5 As shown, illustratively, the comparison results output by the first-level comparator form a first-level result array, and the set array size may be 4×4, then the size of the target array is 4×4, and the target result is the comparison result output by the comparator is 0. The target array may be determined as the target array by traversing the first-level result array with an array size of 4×4, and finding the target result in the middle of the array of the set size, and the number of target results in the array is the largest.
[0077] The next level comparator corresponding to the comparator corresponding to the target array is controlled to perform a comparison operation. The next level comparator corresponding to the target array can be controlled by the data processing unit to perform a comparison operation, and other comparators do not perform a comparison operation, which can save the time of target positioning, and turn off the next level comparator corresponding to the sampling signal with less correlation, saving circuit energy consumption. The target array can be traversed and selected in the first level comparator, or it can be selected in the comparison results output by any level comparator, which is not specifically limited in the embodiments of the present application.
[0078] Step S400 includes:
[0079] The sampling position of the target sensor is determined as the target position, wherein the target sensor is determined by the target result in the target array corresponding to the k-th level comparator. The target result in the target array corresponding to the comparator as the final target positioning is the final target result, the sensor corresponding to the target result is the target sensor, and the sampling position corresponding to the target sensor is the position of the target object, so that the target positioning can be completed.
[0080] The target positioning method provided in the embodiment of the present application selects a target array by traversing the result array, which can limit the position range of the target object. Unnecessary comparators can be turned off, which will not occupy circuit energy consumption, and the energy consumption of the signal sampling circuit is low.
[0081] In some embodiments, the set array size for selecting the target array corresponding to each level of comparator is different. As the number of comparator levels increases, the size of the target array can be reduced step by step. For example, Figure 6 A schematic diagram of another comparison result output by an n-level comparator provided in an embodiment of the present application. Taking the eye tracking of a VR device as an example, combined with Figure 5 and Figure 6As shown, the target array size corresponding to the first-level result array is 4×4, and the target array size corresponding to the second-level result array is 4×2. The result of the comparator output is 0, which can be represented as the sampling signal corresponding to the eyeball. Then the target result is the comparison result of 0. The signal sampling circuit needs to screen the comparison result 0 step by step. Finally, in the third-level result array, there are 2 comparators whose comparison results are 0. Then there are 2 target results in the third-level result array. If the third-level comparator is used as the comparator for final target positioning, the sensors corresponding to these two target results can be taken as target sensors, that is, the sensor corresponding to the comparison result 000 output by the third-level comparator is the target sensor. There are two 000s in the third-level result array. Then the sampling positions of these two target sensors take the center value as the position information of the target object, that is, the center value of the sampling position corresponding to the sensor in the 4th row and 4th column and the sensor in the 5th row and 4th column in the sensor array is the positioning information of the target object, thereby completing the positioning of the target object. The target array selection process and data analysis process can be completed by using a data processing unit. For the next level comparator corresponding to the comparator corresponding to the target array, no comparison operation is performed, and the fourth switch device can be controlled by the data processing unit to complete the closing control of the comparator. A microcontroller can be provided in the data processing unit, which is not specifically limited in the embodiment of the present application.
[0082] The target positioning method provided in the embodiment of the present application can select different target array sizes in the result arrays output by comparators of different levels according to the characteristics of the target object by setting different set array sizes for selecting the target array. The range of the sampling signal of the target object is gradually narrowed, and the target object can be positioned more accurately without turning on all comparators and turning off comparators other than the next level comparator corresponding to the target array, thereby saving circuit energy consumption.
[0083] Although the preferred embodiments of this specification have been described, those skilled in the art may make additional changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications that fall within the scope of this specification.
[0084] Obviously, those skilled in the art can make various changes and modifications to this specification without departing from the spirit and scope of this specification. Thus, if these modifications and variations of this specification fall within the scope of the claims of this specification and their equivalents, this specification is also intended to include these modifications and variations.
Claims
1. A signal sampling circuit, characterized in that: include: Sensor unit; n-level comparators, each group of the n-level comparators is used to receive a sampling signal from the same sensor unit, wherein n is a natural number greater than 1, and different levels of comparators have different reference signal values, and the same level of comparators in different groups of the n-level comparators have the same reference signal values; A first switch device is provided between the 2nd to nth stage comparators and the sampling signal, and the first switch device is controlled by the output of the n-1th stage comparator.
2. The signal sampling circuit according to claim 1, characterized in that: Also includes: An output control unit is electrically connected to an output terminal of each of the comparators.
3. The signal sampling circuit according to claim 2, characterized in that: A second switch device is provided between the output control unit and the output terminal of each comparator.
4. The signal sampling circuit according to claim 3, characterized in that: Also includes: A storage unit is electrically connected to the output terminal of each of the comparators through the second switching device.
5. The signal sampling circuit according to claim 1, characterized in that: Also includes: A reference signal control unit is electrically connected to the reference signal input terminal of each stage of the comparator.
6. The signal sampling circuit according to claim 5, characterized in that: A third switch device is provided between the reference signal control unit and the reference signal input terminal of each stage of the comparator.
7. The signal sampling circuit according to claim 1, characterized in that: The reference signal value is a reference voltage value. A voltage dividing unit is provided between the reference voltage input terminals of two adjacent comparators, and the voltage dividing unit includes a resistor.
8. The signal sampling circuit according to claim 1, characterized in that: The sensor unit includes a sensor and a current-voltage converter, and the current-voltage converter is electrically connected between the sensor and each group of the n-stage comparators.
9. The signal sampling circuit according to claim 8, characterized in that: The current-to-voltage converter comprises a resistor, one end of which is grounded, and the other end of which is connected between the sensor and each group of the n-stage comparators.
10. The signal sampling circuit according to claim 1, characterized in that: Also includes: A data processing unit is electrically connected to the output end of each comparator.
11. The signal sampling circuit according to claim 10, characterized in that: Also includes: A fourth switch device is provided between the sensor unit and the sampling signal input terminal of each of the comparators, and the data processing unit is used to control the closing and opening of the fourth switch device.
12. The signal sampling circuit according to claim 1, characterized in that: The first switch device includes a MOS tube.
13. A target positioning method, characterized in that: Using the signal sampling circuit as described in any one of claims 1 to 12, the method comprises: Controlling the sensor unit to sample the target object and obtain a sampling signal; The first-stage comparator performs a comparison operation based on the sampling signal and the reference signal value, and outputs a comparison result; The comparison result output by the n-1th comparator controls the closing and opening of the first switch device between the n-1th comparator and the nth comparator; The sampling positions of the sensor units corresponding to all comparison results output by the k-th level comparator are determined as target positions, wherein 1≤k≤n.
14. The target positioning method according to claim 13, characterized in that: Before determining that the sampling position of the sensor unit corresponding to all comparison results output by the k-th level comparator is the target position, the method further includes: Traversing the result array based on the set array size to select a target array, wherein the result array includes the comparison results output by each of the comparators at the same level, and the target array is determined based on the number and position of the target results in the target array; Control the next-level comparator corresponding to the comparator corresponding to the target array to perform a comparison operation; The step of determining that the sampling position of the sensor unit corresponding to all comparison results output by the k-th level comparator is the target position includes: The sampling position of the target sensor is determined as the target position, wherein the target sensor is determined by the target result in the target array corresponding to the k-th stage comparator.
15. The target positioning method according to claim 14, characterized in that: The set array size corresponding to each level of the comparator for selecting the target array is different.
