Threshold adjustment method for infrared tracking sensor and electronic device
By acquiring the path and non-path area signals of the infrared tracking sensor, adaptively adjusting the threshold, solving the problem of signal inconsistency caused by individual differences and aging of the infrared tracking sensor, improving navigation accuracy and adaptability, and simplifying user operations.
Patent Information
- Application Number
- CN202011318269.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-11-23
- Publication Date
- 2025-08-08
- Estimated Expiration
- 2040-11-23
AI Technical Summary
During the navigation process, existing infrared tracking sensors have inconsistent signal acquisition due to individual differences and aging, which affects navigation accuracy and poor adaptability to fixed threshold adjustments, especially in scenarios where path color distinction is not obvious.
By acquiring the acquired signals of the path area and the non-path area by the infrared tracking sensor, adaptively adjusting the threshold value, and using the signal difference or average value to calculate the threshold value, to achieve independent threshold adjustment of each sensor.
Reduces consistency requirements for infrared tracking sensors, improves navigation accuracy and adaptability, simplifies user operations, and reduces the time and effort of manual adjustments.
Smart Images

Figure CN112697167B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of electronic technology, and in particular to a threshold adjustment method for an infrared tracking sensor and electronic equipment. Background Art
[0002] There are many ways to move electronic devices, such as visual navigation, laser navigation, etc., but in some special scenarios such as fixed moving paths, using infrared tracking sensors for navigation is also a more appropriate approach.
[0003] In order to ensure the accuracy of navigation using infrared tracking sensors, it is necessary to ensure a high degree of consistency among the infrared tracking sensors, that is, for the two different situations of inside and outside the path, the signals collected by different infrared tracking sensors should be able to be clearly distinguished. However, there are individual differences in infrared tracking sensors when they leave the factory. For example, even for products from the same batch, there are differences in the readings of the same area by each infrared tracking sensor. In addition, the infrared tracking sensor uses a photodiode to receive signals, where the photodiode retains the amplification characteristics of the diode. As the working time increases, the degree of aging of each infrared tracking sensor is inconsistent due to individual differences, which can easily lead to large differences in the analog-to-digital readings corresponding to each infrared tracking sensor. As a result, the signals collected by different infrared tracking sensors for different situations cannot be clearly distinguished, which in turn affects the accuracy of navigation using the infrared tracking sensor.
[0004] Currently, infrared tracking sensors are generally used to distinguish between inside and outside the path by setting a fixed threshold. However, this method has poor adaptability to scenes with paths of different colors. For example, it may perform well in scenes with clear path colors, but it is extremely prone to errors in scenes with unclear path colors. In this case, the user can manually adjust the threshold and then determine the accuracy of the adjustment through testing, but this may require multiple adjustments, wasting time and effort. Summary of the Invention
[0005] The present invention provides a threshold adjustment method for an infrared tracking sensor, which is used to reduce the consistency requirements for the infrared tracking sensor. A first aspect of an embodiment of the present invention provides a threshold adjustment method for an infrared tracking sensor, wherein an electronic device includes an infrared tracking sensor, and the method includes:
[0006] Acquire a first acquisition signal of the infrared tracking sensor for the path area and a second acquisition signal for the non-path area;
[0007] Adjusting a threshold of the infrared tracking sensor according to the first acquisition signal and the second acquisition signal.
[0008] Optionally, adjusting the threshold of the infrared tracking sensor according to the first acquisition signal and the second acquisition signal includes:
[0009] Using half of the difference between a first analog-to-digital reading corresponding to the first acquisition signal and a second analog-to-digital reading corresponding to the second acquisition signal as a first threshold value of the infrared tracking sensor; or
[0010] The first analog-to-digital reading is used as the starting reading point of the infrared tracking sensor, and 1 / 2 of the difference between the first analog-to-digital reading and the second analog-to-digital reading is used as the second threshold value of the infrared tracking sensor; or
[0011] taking the first analog-to-digital reading value plus half of the difference between the first analog-to-digital reading value and the second analog-to-digital reading value as a third threshold value of the infrared tracking sensor; or
[0012] The first analog-to-digital reading value is used as the starting reading point, and the first analog-to-digital reading value plus 1 / 2 of the difference between the first analog-to-digital reading value and the second analog-to-digital reading value is used as the fourth threshold of the infrared tracking sensor.
[0013] Optionally, before the infrared tracking sensor collects the first signal from the path area and the second signal from the non-path area, the method further includes:
[0014] receiving a control signal causing the electronic device to enter a calibration mode;
[0015] In response to the control signal, the infrared tracking sensor is controlled to rotate to collect signals from the path area and the non-path area respectively.
[0016] Optionally, before the infrared tracking sensor collects the first signal from the path area and the second signal from the non-path area, the method further includes:
[0017] receiving a control signal causing the electronic device to enter a calibration mode;
[0018] In response to the control signal, the electronic device is controlled to rotate so that the infrared tracking sensor collects signals from the path area and the non-path area respectively.
[0019] Optionally, before the infrared tracking sensor collects the first signal from the path area and the second signal from the non-path area, the method further includes:
[0020] receiving a control signal causing the electronic device to enter a calibration mode;
[0021] In response to the control signal, the infrared tracking sensor is controlled to continuously collect signals until two collected signals with a difference greater than a preset value are collected.
[0022] Optionally, after adjusting the threshold of the infrared tracking sensor according to the first acquisition signal and the second acquisition signal, the method further includes:
[0023] Sending a prompt signal, wherein the prompt signal includes at least one of sound, picture, video or light.
[0024] Optionally, after adjusting the threshold of the infrared tracking sensor according to the first acquisition signal and the second acquisition signal, the method further includes:
[0025] During the tracking process of the electronic device, controlling the N infrared tracking sensors to collect signals;
[0026] Comparing the analog-to-digital readings corresponding to all collected signals with the threshold value;
[0027] According to the comparison result, the electronic device is controlled to perform tracking motion.
[0028] A second aspect of an embodiment of the present invention provides an electronic device, including an infrared tracking sensor, a memory and a processor, wherein the memory can store a program, and when the program is executed by the processor, the processor can execute the threshold adjustment method as described in the first aspect.
[0029] Optionally, the infrared tracking sensor includes an electrically connected photoelectric sensor device and an analog-to-digital conversion circuit.
[0030] A third aspect of an embodiment of the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores a program. When the program is executed by the processor, the processor is enabled to perform the threshold adjustment method as described in the first aspect.
[0031] According to the specific embodiments provided by the present invention, the present invention discloses the following technical effects:
[0032] An embodiment of the present invention adopts a technical solution of obtaining a first acquisition signal of an infrared tracking sensor for a path area and a second acquisition signal for a non-path area, and adjusting the threshold of the infrared tracking sensor according to the first acquisition signal and the second acquisition signal. It can be seen that since the threshold of the infrared tracking sensor is determined based on the acquisition signals for the path area and the non-path area, the threshold is adaptively adjusted according to the real-time working conditions of the infrared tracking sensor. Therefore, the threshold of each infrared tracking sensor in the electronic device is only related to its own real-time working conditions. There is no need to set the thresholds of all infrared tracking sensors in the electronic device to the same value. The differences in the acquisition signals caused by the differences between the infrared tracking sensors can be significantly ignored, thereby reducing the consistency requirements of the electronic device for the infrared tracking sensor. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0034] Figure 1 A schematic diagram of navigation using an infrared tracking sensor according to an embodiment of the present invention;
[0035] Figure 2 A flowchart of a threshold adjustment method for an infrared tracking sensor provided in the first aspect of an embodiment of the present invention;
[0036] Figure 3 A schematic diagram of a module of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION
[0037] The following will be combined with the accompanying drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the embodiments described are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field are within the scope of protection of the present invention.
[0038] To better understand the present invention, in this embodiment, we will first introduce the specific process of using infrared tracking sensors for navigation. Figure 1 , Figure 1 A schematic diagram of navigation using an infrared tracking sensor provided in an embodiment of the present invention, such as Figure 1As shown, the electronic device 10 is provided with three infrared tracking sensors 101, 102 and 103, wherein 101 and 102 respectively block the movement path L, and the infrared tracking sensor 103 is set in the path L, which is a black line on a white background. When the electronic device 10 moves in the direction indicated by the arrow, if the signals collected by the three infrared tracking sensors indicate that 101 and 102 are both outside L, and the signal collected by 103 indicates that 103 is inside L, then the electronic device 10 should be controlled to move straight; if the collected signals indicate that 101 is inside L and 102 is outside L, then the electronic device 10 should be controlled to turn left; if the collected signals indicate that 101 is outside L and 102 is inside L, then the electronic device 10 should be controlled to turn right; if the collected signals indicate that 101, 102 and 103 are all inside L, then it indicates that the electronic device has reached the end of the path and should stop moving.
[0039] In other embodiments, those skilled in the art may use more infrared tracking sensors to improve the accuracy of the movement of the electronic device according to different driving methods, and this is not limited here.
[0040] It should be noted that the signal received by the infrared tracking sensor will be affected by the distance and the material of the reflective surface. During the tracking process of the electronic device, the distance between the infrared tracking sensor and the reflective surface will be kept stable. Therefore, when path L is used as the reflective surface, the two collected signals obtained by the infrared tracking sensor when collecting signals from the black line of path L and the white area outside the path will be different due to the different reflective surfaces. Since the photodiode used by the infrared tracking sensor retains the amplification characteristics of the diode, the collected signals of each infrared tracking sensor have inconsistent amplification factors due to inconsistent aging conditions, etc., resulting in large differences in the analog-to-digital readings corresponding to the two collected signals collected from path L and outside the path by different infrared tracking sensors, thereby failing to meet the consistency requirements of electronic equipment for infrared tracking sensors.
[0041] Please refer to Figure 2 , Figure 2 This is a flowchart of a threshold adjustment method for an infrared tracking sensor provided in the first aspect of an embodiment of the present invention, which is applied to an electronic device including an infrared tracking sensor, such as Figure 2 As shown, the method includes:
[0042] S1: Acquire the first acquisition signal of the infrared tracking sensor for the path area and the second acquisition signal for the non-path area; specifically, control the infrared tracking sensor on the electronic device to Figure 1The path L shown in the figure and the area outside the path L are used for signal collection, that is, the first collection signal of the path area and the second collection signal of the non-path area by the infrared tracking sensor can be obtained; it should be noted that, in this embodiment, the area where the path L is located is black, and the non-path area, that is, the area outside the path L, is white. In other embodiments, the colors of the path L and the area outside the path L are not limited to this and can be set according to actual needs, and are not limited here.
[0043] S2: Adjust the threshold of the infrared tracking sensor according to the first acquisition signal and the second acquisition signal; in this embodiment, the analog-to-digital reading value corresponding to the acquisition signal of the infrared tracking sensor in the area where the black line in path L is located should be a lower value, and the analog-to-digital reading value corresponding to the acquisition signal of the non-path area outside path L should be a higher value. In this way, according to the first acquisition signal and the second acquisition signal, the threshold of each infrared tracking sensor in the electronic device can be adaptively adjusted, and there is no need to set a fixed threshold for the infrared tracking sensor in the electronic device or manually adjust the threshold as needed, thereby reducing the consistency requirements of the electronic device for the infrared tracking sensor.
[0044] For example, the analog-to-digital reading value corresponding to the first acquisition signal of the infrared tracking sensor 101 in the path area is 200, and the analog-to-digital reading value corresponding to the second acquisition signal in the non-path area can be 3500. At this time, the threshold value of the infrared tracking sensor 101 can be set to (3500-200) / 2=1650, that is, during the tracking movement of the electronic device, if the analog-to-digital reading value corresponding to the acquisition signal obtained by the infrared tracking sensor 101 is less than or equal to 1650, it can be determined that the current area is a path area, otherwise it is a non-path area. similarly, the analog-to-digital reading value corresponding to the first acquisition signal of the infrared tracking sensor 102 in the path area is 400, and the analog-to-digital reading value corresponding to the second acquisition signal in the non-path area is 5600, then the threshold value of the infrared tracking sensor 102 is set to (5600-400) / 2=2600, that is, during the tracking movement of the electronic device, if the analog-to-digital reading value corresponding to the acquisition signal obtained by the infrared tracking sensor 102 is less than or equal to 2600, then it can be determined that the current area is a path area, otherwise it is a non-path area.
[0045] By analogy, whether it is the remaining infrared tracking sensors 103 in the electronic device of this embodiment or more infrared tracking sensors in the electronic device of other embodiments, the threshold of each infrared tracking sensor in the electronic device can be adjusted according to the above method. In this way, regardless of the individual differences of the infrared tracking sensors at the time of leaving the factory or the inconsistent degree of aging caused by the increase in working time, each infrared tracking sensor can adaptively adjust the threshold according to the real-time working conditions, resulting in differences in analog-to-digital readings. There is no need to set a fixed threshold for the infrared tracking sensor in the electronic device or manually adjust the threshold as needed, thereby reducing the consistency requirements of the electronic device for the infrared tracking sensor.
[0046] From the above, it can be seen that the threshold adjustment method of the infrared tracking sensor introduced in this embodiment can not only be applied to a single infrared tracking sensor on an electronic device and achieve good results, but can also be applied to multiple infrared tracking sensors. The threshold of each infrared tracking sensor can be adjusted separately at the same time, and the multiple infrared tracking sensors will not affect each other.
[0047] In summary, it can be seen that since the threshold of the infrared tracking sensor is determined based on the collected signals of the path area and the non-path area, the threshold can be adaptively adjusted according to the real-time working conditions of the infrared tracking sensor. Therefore, the threshold of each infrared tracking sensor in the electronic device is only related to its own real-time working conditions. There is no need to set the thresholds of all infrared tracking sensors in the electronic device to the same value. The differences in the collected signals caused by the differences between the various infrared tracking sensors can be significantly ignored, thereby reducing the consistency requirements of the electronic device for the infrared tracking sensors.
[0048] From the above, it can be seen that the threshold adjustment method of the infrared tracking sensor introduced in this embodiment can be applied individually to each infrared tracking sensor on the electronic device and achieve good results. The thresholds of multiple infrared tracking sensors can also be adjusted at the same time without affecting each other.
[0049] In a specific implementation, adjusting the threshold of the infrared tracking sensor according to the first acquisition signal and the second acquisition signal may include:
[0050] Using 1 / 2 of the difference between a first analog-to-digital reading corresponding to the first acquisition signal and a second analog-to-digital reading corresponding to the second acquisition signal as a first threshold value of the infrared tracking sensor; or
[0051] The first analog-to-digital reading is used as the starting reading point of the infrared tracking sensor, and 1 / 2 of the difference between the first analog-to-digital reading and the second analog-to-digital reading is used as the second threshold value of the infrared tracking sensor; or
[0052] The first analog-to-digital reading value plus 1 / 2 of the difference between the first analog-to-digital reading value and the second analog-to-digital reading value is used as the third threshold value of the infrared tracking sensor; or
[0053] The first analog-to-digital reading value is used as a starting reading point, and the first analog-to-digital reading value plus 1 / 2 of the difference between the first analog-to-digital reading value and the second analog-to-digital reading value is used as a fourth threshold of the infrared tracking sensor.
[0054] Specifically, there are four ways to adjust the threshold of the infrared tracking sensor. This is explained using the example of the analog-to-digital reading of 200 for the first acquisition signal and 3500 for the second acquisition signal:
[0055] The first type: the first threshold value T1 = (3500-200) / 2 = 1650; that is, if the analog-to-digital reading value of the signal collected by the infrared tracking sensor 101 is less than or equal to 1650, the area currently scanned by the infrared tracking sensor 101 is a path area, otherwise it is a non-path area;
[0056] The second method is as follows: the second threshold value T2 = (3500 - 200) / 2 = 1650, and 200 is the starting reading point of the infrared tracking sensor 101, that is, the analog-to-digital reading value corresponding to the path area is [200, 1650]. For example, if the analog-to-digital reading value of the signal collected by the infrared tracking sensor 101 is 500, then the area currently scanned by the infrared tracking sensor 101 is the path area. If the analog-to-digital reading value is 2000, then the area currently scanned is the non-path area. Of course, at this time, the second analog-to-digital reading value can also be set as the ending reading point of the infrared tracking sensor 101, or positive infinity can be set as the ending reading point of the infrared tracking sensor 101. There is no limitation here.
[0057] The third method: the third threshold value T3 = 200 + (3500 - 200) / 2 = 1850. This method differs from the first method in that the third threshold value T3 is calculated by adding the first analog-to-digital reading value to the first threshold value T1. This is equivalent to starting the calculation with the first analog-to-digital reading value as the starting point, while ignoring the analog-to-digital reading value (0, 200) that the infrared tracking sensor 101 does not actually correspond to. This means that the third threshold value T3 is more accurate than the first threshold value T1.
[0058] Fourth threshold: The fourth threshold T4 = 200 + (3500 - 200) / 2 = 1850, and the first mode reading value is used as the starting reading point. It can be compared to the third adjustment method. The value of the fourth threshold T4 is the first analog-to-digital reading value added to the second threshold T2, that is, the analog-to-digital reading value corresponding to the path area is [200, 1850]. Similarly, the analog-to-digital reading value (0, 200) that the acquisition signal of the infrared tracking sensor 101 does not actually correspond to is ignored. That is, the fourth threshold T4 is more accurate than the second threshold T2. The specific judgment process will not be repeated here.
[0059] In a specific implementation process, there are multiple ways to control the infrared tracking sensor 101 to obtain the first acquisition signal and the second acquisition signal. Specifically, the following methods may be used:
[0060] The first method is to receive a control signal that causes the electronic device to enter a calibration mode; in response to the control signal, the infrared tracking sensor is controlled to rotate, and signals are collected in the path area and the non-path area respectively.
[0061] Specifically, the user can start the electronic device to enter the calibration mode through the remote control, the application of the mobile terminal or the button on the electronic device, or the electronic device automatically enters the calibration mode, and the electronic device can receive the control signal for controlling the electronic device to enter the calibration mode. The calibration mode refers to the mode in which the infrared tracking sensor 101 of the electronic device adjusts the threshold value. In this way, after the electronic device receives the control signal, it can control the infrared tracking sensor 101 to rotate, so that the infrared tracking sensor 101 collects signals from the path area and the non-path area respectively, and then can obtain the first collection signal and the second collection signal; of course, this method requires the infrared tracking sensor 101 to be set on a rotatable platform or structure on the electronic device. Through the introduction of this embodiment, technical personnel in this field can select a suitable rotatable platform or structure according to actual conditions, which will not be repeated here; it should be noted that, with respect to the scenario in which the method provided in the embodiment of the present invention is applied to multiple infrared tracking sensors, please continue to refer to Figure 1 The rotation directions of the infrared tracking sensors 101, 102 and 103 can turn left or right as shown by the arrows, but the rotation directions of the infrared tracking sensors 101, 102 and 103 will not affect each other, and the threshold adjustment of each infrared tracking sensor has good independence.
[0062] The second method is to receive a control signal that causes the electronic device to enter a calibration mode; in response to the control signal, control the electronic device to rotate so that the infrared tracking sensor collects signals in the path area and the non-path area respectively;
[0063] Specifically, similar to the first method, after the electronic device receives the control signal for controlling the electronic device to enter the calibration mode, it can control the electronic device itself to rotate, so that the infrared tracking sensor 101 can rotate as the electronic device rotates. Similarly, the infrared tracking sensor 101 can respectively collect signals in the path area and the non-path area, and then obtain the first collection signal and the second collection signal, without the need for a platform or structure specifically used to support the infrared tracking sensor.
[0064] The third method: receiving a control signal that causes the electronic device to enter a calibration mode; responding to the control signal, controlling the infrared tracking sensor to continuously collect signals until two collected signals are collected with a difference greater than a preset value;
[0065] Specifically, after the electronic device receives the control signal for controlling the electronic device to enter the calibration mode, the infrared tracking sensor 101 starts to continuously collect signals. At this time, the user can hold the electronic device and scan the infrared tracking sensor 101 at the path area where the path L is located and the non-path area outside the path L. In this way, the electronic device controls the infrared tracking sensor to continuously collect signals, and can also enable the infrared tracking sensor 101 to collect signals from the path area and the non-path area respectively, and then obtain the first collection signal and the second collection signal, and there is no need for a platform or structure specifically for carrying the infrared tracking sensor, nor is there a need to set up a special control program to control the rotation of the electronic device.
[0066] Through the introduction of this embodiment, technicians in this field can choose other appropriate methods to control the infrared tracking sensor 101 to obtain the first acquisition signal and the second acquisition signal according to actual conditions to meet the needs of actual conditions, which will not be repeated here.
[0067] It can be seen that whether the electronic device enters calibration mode in response to a user control signal or automatically enters calibration mode each time the electronic device is powered on, the infrared tracking sensor is automatically calibrated, eliminating the need for the user to manually select an appropriate judgment threshold for the infrared tracking sensor based on actual conditions. This not only ensures the accuracy of the electronic device during tracking, but also simplifies user operation and reduces the user's requirements for using the electronic device. Of course, it should be noted that the calibration mode in this embodiment is merely a name; the calibration mode can also be a correction mode, an adjustment mode, and so on, which is not limited here.
[0068] In a specific implementation process, after adjusting the threshold of the infrared tracking sensor according to the first acquisition signal and the second acquisition signal, the method further includes: issuing a prompt signal, the prompt signal including at least one of sound, picture, video or light.
[0069] Specifically, after the electronic device completes the threshold adjustment of the infrared tracking sensor, it may send a prompt to the user through at least one of sound, picture, video or light, so that the user can control the electronic device to perform the corresponding tracking movement after the electronic device completes the calibration of the infrared tracking sensor.
[0070] In a specific implementation process, after adjusting the threshold of the infrared tracking sensor according to the first acquisition signal and the second acquisition signal, the method further includes: during the tracking process of the electronic device, controlling all infrared tracking sensors on the electronic device to acquire signals; comparing the analog-to-digital reading values corresponding to all acquisition signals with the respective thresholds of each infrared tracking sensor; and controlling the electronic device to perform tracking movement based on the comparison results.
[0071] Specifically, please refer to Figure 1 During the tracking process of the electronic device 10, the three infrared tracking sensors on the electronic device 10 are controlled to collect corresponding collection signals, and the analog-to-digital readings corresponding to the collection signals are compared with the threshold values of the three infrared tracking sensors; according to the comparison results, the electronic device is controlled to perform tracking movement. For example, if the threshold value of the infrared tracking sensor 101 is adjusted to 1650, the threshold value of the infrared tracking sensor 102 is adjusted to 2000, and the threshold value of the infrared tracking sensor 103 is adjusted to 2800 through the method introduced in this embodiment, and the analog-to-digital reading value corresponding to the collection signal of the infrared tracking sensor 101 is 500, which is less than the threshold value of the infrared tracking sensor 101 itself, then it is determined that the area where the infrared tracking sensor 101 collects signals is a non-path area. If the analog-to-digital reading value corresponding to the collection signal of the infrared tracking sensor 102 is 2500, which is greater than the threshold value of the infrared tracking sensor 102 itself, then It is determined that the area where the infrared tracking sensor 101 collects signals is the path area. If the analog-to-digital reading value corresponding to the signal collected by the infrared tracking sensor 103 is 3500, which is greater than the threshold value of the infrared tracking sensor 103 itself, then the area where the infrared tracking sensor 101 collects signals is determined to be the path area. It can be seen that only the infrared tracking sensor 101 scans the path area, and the infrared tracking sensor 102 and the infrared tracking sensor 103 both scan the non-path area. Therefore, it is determined that the electronic device has deviated from the path L at this time, and it is necessary to control the electronic device to turn left and return to going straight on the path L before continuing to move forward. It can be clearly seen that the threshold values of the three infrared tracking sensors are different, but they can also ensure the correct tracking movement of the electronic device, thereby achieving the purpose of ignoring the differences in the collected signals caused by the differences of each infrared tracking sensor, thereby reducing the consistency requirements of the electronic device on the infrared tracking sensors.
[0072] From the above, it can be seen that since the threshold of the infrared tracking sensor is determined based on the collected signals of the path area and the non-path area, the threshold is adaptively adjusted according to the real-time working conditions of the infrared tracking sensor. Therefore, the threshold of each infrared tracking sensor in the electronic device is only related to its own real-time working conditions. There is no need to set the thresholds of all infrared tracking sensors in the electronic device to the same value. The differences in the collected signals caused by the differences between the various infrared tracking sensors can be significantly ignored, thereby reducing the consistency requirements of the electronic device for the infrared tracking sensor.
[0073] The second aspect of the embodiment of the present invention further provides an electronic device, please refer to Figure 3 , Figure 3 A schematic diagram of a module of an electronic device provided by an embodiment of the present invention, such as Figure 3 As shown, the electronic device 30 includes N infrared tracking sensors 301, a memory 302 and a processor 303. The memory 302 can store programs. When the program is executed by the processor 303, the processor 303 can execute the threshold adjustment method as described in the first aspect.
[0074] In a specific implementation, the infrared tracking sensor includes an electrically connected photoelectric sensor element and an analog-to-digital conversion circuit. The photoelectric sensor element can be a photodiode or a phototransistor, etc., without limitation. The analog-to-digital conversion circuit is well known to those skilled in the art and will not be described in detail here.
[0075] The third aspect of the embodiment of the present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a program, and when the program is executed by a processor, the processor is enabled to execute the threshold adjustment method of the first aspect as described above.
[0076] From the above, it can be seen that since the threshold of the infrared tracking sensor is determined based on the collected signals of the path area and the non-path area, the threshold is adaptively adjusted according to the real-time working conditions of the infrared tracking sensor. Therefore, the threshold of each infrared tracking sensor in the electronic device is only related to its own real-time working conditions. There is no need to set the thresholds of all infrared tracking sensors in the electronic device to the same value. The differences in the collected signals caused by the differences between the various infrared tracking sensors can be significantly ignored, thereby reducing the consistency requirements of the electronic device for the infrared tracking sensor.
[0077] Through the above embodiments and descriptions of specific implementation methods, it can be seen that those skilled in the art can clearly understand that the present invention can be implemented by means of software plus a necessary general-purpose hardware platform. Based on this understanding, the technical solution of the present invention, or the portion that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a storage medium such as ROM / RAM, a magnetic disk, an optical disk, etc., and includes a number of instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods of various embodiments of the present invention or certain portions of the embodiments.
[0078] Each embodiment in this specification is described in a progressive manner. The same or similar parts between the embodiments can be referred to each other. Each embodiment focuses on the differences from other embodiments. In particular, for the system embodiment, since it is basically similar to the method embodiment, the description is relatively simple. For the relevant parts, refer to the partial description of the method embodiment. The system embodiment described above is only exemplary, wherein the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or they may be distributed on multiple network units. Some or all of the modules can be selected according to actual needs to achieve the purpose of the solution of this embodiment. A person of ordinary skill in the art can understand and implement it without making any creative efforts.
[0079] The above is a detailed introduction to a testing method for a robotic arm, a robotic arm, and a testing system thereof provided by the present invention. Specific examples are used herein to illustrate the principles and implementation methods of the present invention. The description of the above embodiments is only intended to help understand the method and core ideas of the present invention. At the same time, for those skilled in the art, according to the ideas of the present invention, there may be changes in the specific implementation methods and application scopes. In summary, the contents of this specification should not be understood as limiting the present invention.
Claims
1. A threshold adjustment method for an infrared tracking sensor, characterized in that: Applied to an electronic device including an infrared tracking sensor, the method includes: Receiving a control signal causing the electronic device to enter a calibration mode; wherein the calibration mode is a mode causing the infrared tracking sensor to adjust a threshold value, and the user activates the electronic device to enter the calibration mode or the electronic device automatically enters the calibration mode each time it is powered on; In response to the control signal, obtaining a first acquisition signal of the infrared tracking sensor for the path area and a second acquisition signal for the non-path area; Adjust the threshold of the infrared tracking sensor according to the first acquisition signal and the second acquisition signal; wherein, the first analog-to-digital reading value corresponding to the first acquisition signal is used as the starting reading point, and the first analog-to-digital reading value plus 1 / 2 of the difference between the first analog-to-digital reading value and the second analog-to-digital reading value corresponding to the second acquisition signal is used as the fourth threshold of the infrared tracking sensor.
2. The threshold adjustment method according to claim 1, wherein: The adjusting the threshold of the infrared tracking sensor according to the first acquisition signal and the second acquisition signal includes: Using half of the difference between the first analog-to-digital reading value and the second analog-to-digital reading value as a first threshold value of the infrared tracking sensor; or The first analog-to-digital reading is used as the starting reading point of the infrared tracking sensor, and 1 / 2 of the difference between the first analog-to-digital reading and the second analog-to-digital reading is used as the second threshold value of the infrared tracking sensor; or The first analog-to-digital reading value plus 1 / 2 of the difference between the first analog-to-digital reading value and the second analog-to-digital reading value is used as the third threshold of the infrared tracking sensor.
3. The threshold adjustment method according to claim 1, wherein: The step of obtaining, in response to the control signal, a first acquisition signal of the infrared tracking sensor for the path area and a second acquisition signal for the non-path area includes: The infrared tracking sensor is controlled to rotate to collect signals from the path area and the non-path area respectively.
4. The threshold adjustment method according to claim 1, wherein: The step of obtaining, in response to the control signal, a first acquisition signal of the infrared tracking sensor for the path area and a second acquisition signal for the non-path area includes: The electronic device is controlled to rotate so that the infrared tracking sensor collects signals from the path area and the non-path area respectively.
5. The threshold adjustment method according to claim 1, wherein: The step of obtaining, in response to the control signal, a first acquisition signal of the infrared tracking sensor for the path area and a second acquisition signal for the non-path area includes: The user holds the electronic device to control the infrared tracking sensor to continuously collect signals until two collected signals with a difference greater than a preset value are collected.
6. The threshold adjustment method according to claim 1, wherein: After adjusting the threshold of the infrared tracking sensor according to the first acquisition signal and the second acquisition signal, the method further includes: Sending a prompt signal, wherein the prompt signal includes at least one of sound, picture, video or light.
7. The threshold adjustment method according to any one of claims 1 to 6, wherein: After adjusting the threshold of the infrared tracking sensor according to the first acquisition signal and the second acquisition signal, the method further includes: During the tracking process of the electronic device, controlling all infrared tracking sensors on the electronic device to collect signals; Compare the analog-to-digital readings corresponding to all collected signals with the respective thresholds of each infrared tracking sensor; According to the comparison result, the electronic device is controlled to perform tracking motion.
8. An electronic device, characterized in that: The method comprises N infrared tracking sensors, a memory and a processor, where N is a positive integer greater than or equal to 1, and the memory is capable of storing a program. When the program is executed by the processor, the processor is capable of executing the threshold adjustment method according to any one of claims 1 to 7.
9. The electronic device according to claim 8, wherein The infrared tracking sensor includes a photoelectric sensor device and an analog-to-digital conversion circuit that are electrically connected.
10. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a program, and when the program is executed by a processor, the processor is enabled to perform the threshold adjustment method according to any one of claims 1 to 7.
Citation Information
Patent Citations
Grayscale sensor and tracking control method based on grayscale sensor
CN103970136A
Gray level tracking sensor based on fuzzy PI, and reference voltage adjustment method thereof
CN110007624A
Gray scale sensor for automatically calculating average gray-value
CN203849614U