Measuring device for measuring distance of user and related measuring method
By combining distance sensors and infrared IR radiation sensors in the measurement equipment, the calibration curve converts the temperature signal into distance signals, the problem of high-precision measurement of user distance at low energy consumption is solved, and efficient and accurate distance measurement is achieved.
Patent Information
- Application Number
- CN202411324100.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Priority Date
- 2024-09-17
- Filing Date
- 2024-09-23
- Publication Date
- 2025-03-28
AI Technical Summary
The prior art is difficult to measure the distance between the user and the electronic device with high accuracy under low energy consumption conditions, especially when automatic control of the electronic device functions is required.
Using a measuring device including a distance sensor and an infrared IR radiation sensor, the measurement method is realized through the control unit, and the temperature signal of the infrared sensor is converted into a distance signal using the calibration curve, and is regularly calibrated and updated to ensure measurement accuracy.
It realizes high-precision measurement of user distance under low energy consumption, reduces power consumption, and ensures the accuracy and reliability of the measurement equipment.
Smart Images

Figure CN119716898A_ABST
Abstract
Description
Technical Field
[0001] The present disclosure relates to a measuring device for measuring the distance of a user. In addition, it relates to an electronic device including the measuring device, to a measuring method implemented by the measuring device, and to a related computer program product. Background Art
[0002] It is well known that energy consumption is a key parameter that needs to be evaluated in the design of electronic devices (such as PCs, speakers, smart appliances, Internet of Things (IoT) devices), where energy consumption needs to be minimized without reducing the functionality that these electronic equipment can provide.
[0003] Therefore, these electronic devices are usually automatically controlled according to some external factors (such as the presence of a user near the electronic device) in order to minimize energy consumption. For example, the screen of the PC can be automatically activated or deactivated based on whether the user is close to the PC, and in particular based on whether he / she is in the use position of the PC (i.e. within a predefined distance range from the PC and in front of the screen). In this way, the time that the PC screen remains on when the PC is not actually used is minimized, and this allows reducing the overall energy consumption of the PC.
[0004] There are several known solutions for automatically controlling such an electronic device based on the measurement of distance or at least based on whether a user is present in the same electronic device.
[0005] For example, it is known to use "thermal MOS" TMOS sensors to detect the presence of a user in a predetermined area.
[0006] The TMOS sensor is a known infrared sensor suitable for detecting the presence and movement of a user. In particular, the TMOS detects the intensity of infrared IR radiation emitted by a hot body (e.g., a user of an electronic device) present in the field of view (FoV) of the TMOS. The TMOS has low energy consumption (e.g., about 20 μA) and a wide field of view (e.g., a detection angle of about 80°), but cannot generally be used to measure the distance between a person and the sensor because the intensity of the IR radiation does not depend only on the distance between the user and the sensor, but also on external factors such as ambient temperature and humidity and drifts over time. In general, this is due to the fact that this IR sensor cannot measure the absolute distance between the user and the TMOS sensor, but can detect the intensity of the IR radiation generated by objects that emit IR radiation (which indicates their temperature and is related to their distance from the TMOS sensor).
[0007] For this reason, TMOS is not used in applications that require accurate measurement of the user's distance, but is used to detect whether the user is within a predefined distance range.
[0008] A sensor that is often used to measure the distance of an object or a person is a Time of Flight (ToF) sensor. A ToF sensor can be based on different technologies, such as ultrasound or optical.
[0009] In the exemplary case of an ultrasonic ToF sensor, it includes a transmitter configured to transmit ultrasound toward an object to be detected, and a receiver configured to receive ultrasound that has been reflected by the object to be detected after being transmitted by the transmitter. The ultrasonic ToF sensor measures the flight time of ultrasound (i.e., the time interval that elapses between the transmission of ultrasound by the transmitter and the reception of ultrasound by the receiver), and calculates the distance of the object relative to the ToF sensor based on the measured flight time. The operating principle of an optical ToF sensor is completely similar to that of an ultrasonic ToF sensor, but it is not based on the transmission and reception of ultrasound waves, but on the emission and reception of optical radiation (for example, the transmitter may include a "single photon avalanche diode" SPAD).
[0010] Thus, a ToF sensor allows measuring the distance of an object (e.g., a person) present within the field of view of the ToF sensor. A ToF sensor has a high accuracy in measuring the distance of a user from the sensor, but also has a high power consumption (e.g., about 20 mA) and a very narrow field of view (e.g., a detection angle of about 25°).
[0011] For these reasons, ToF sensors are often used to measure distance, although the problems listed above make their use less than ideal in several applications (eg, low power applications).
[0012] Therefore, it is necessary to detect the distance between the user and electronic equipment (e.g., PC) with high accuracy and without high energy consumption so as to automatically control the functions of the electronic equipment (e.g., automatically turning on and off the PC screen according to the presence or absence of the user). Summary of the invention
[0013] According to the present disclosure, a measuring device, an electronic apparatus, a measuring method, and a computer program product are provided. BRIEF DESCRIPTION OF THE DRAWINGS
[0014] For a better understanding of the present disclosure, preferred embodiments will now be described, by way of non-limiting examples only, with reference to the accompanying drawings, in which:
[0015] Figure 1 is a schematic perspective view of an electronic device including a measuring apparatus according to one embodiment;
[0016] Figure 2 According to an embodiment Figure 1 A schematic diagram of the electronics and further details of the measuring device;
[0017] Figure 3 is a graph showing a calibration curve obtained by a measuring device according to one embodiment; and
[0018] Figure 4 is a block diagram illustrating a measurement method performed by a measurement device according to one embodiment.
[0019] Specifically, the drawings are shown with reference to a three-axis Cartesian system defined by an X-axis, a Y-axis, and a Z-axis that are orthogonal to each other.
[0020] In the following description, elements common to different embodiments have been indicated with the same reference numerals. DETAILED DESCRIPTION
[0021] Figure 1 Shows the user (in Figure 2 An electronic device 10 that can be used is shown by reference numeral 11 in the figure.
[0022] Figure 1 An exemplary and non-limiting case is shown in which the electronic device 10 is a PC (and therefore also indicated by reference numeral 10 hereinafter). Hereinafter, this exemplary case will be considered, but other types of electronic devices 10 may also be considered similarly. For illustrative and non-limiting purposes, the electronic device 10 may also be a speaker, a smart home appliance, an IoT device, a tablet computer, etc.
[0023] The PC 10 comprises a measuring device 20 , which is better described below and is configured to measure the distance of the user 11 from the PC 10 .
[0024] Specifically, the measuring device 20 extends at the main surface 12 of the PC 10 , and when the user 11 is present and in a use position (or interest position, predefined position) of the PC 10 , the user 11 faces the main surface 12 of the PC 10 .
[0025] In detail, the use location is a location where the user 11 can use the PC 10, or more generally a set of locations. For example, the use location is identified by the fact that the user 11 is in front of the PC 10 and is at a distance from the PC 10 that is less than a threshold distance. In more detail, the distance between the user 11 and the measuring device 20 (in Figure 2 The threshold distance (shown with reference numeral D in FIG. 1 ) may be considered as the distance between the user 11 and the PC 10, and the threshold distance may be equal to approximately 80 centimeters for illustrative and non-limiting purposes.
[0026] For example, PC 10 includes a screen 14 that defines a portion of major surface 12 and is configured as follows: Figure 1As shown in FIG. 1 , the measuring device 20 may extend over the screen 14 , for example, laterally to the camera 16 of the PC 10 .
[0027] In this way, when the user 11 is in the use position of the PC 10 , the user 11 faces the measuring device 20 , and the measuring device 20 can thus measure the distance D between it and the user 11 .
[0028] refer to Figure 2 , the measuring device 20 will now be described in more detail.
[0029] The measuring device 20 comprises a control unit 22, a distance sensor 24, and an infrared IR radiation sensor 26. In the following, the IR radiation sensor 26 is also referred to more simply as IR sensor 26.
[0030] According to an exemplary embodiment, the control unit 22 (such as a microprocessor, a microcontroller, or a dedicated computing unit) is an electronic control unit, which may include a data storage unit (not shown, such as a memory, for example, a non-volatile memory) for storing the acquired data and a processing unit (not shown) for processing the acquired data coupled to each other. In a manner not shown and known per se, the control unit may also include one or more of the following components: an electrical energy storage module (for example, a battery), a power management module for managing electrical energy, a digital front-end interface module with a distance sensor 24 and an IR sensor 26, a communication module (for example, a radio communication module based on Bluetooth technology).
[0031] The distance sensor 24 and the IR sensor 26 are coupled (eg, electrically coupled) to the control unit 22. For example, the distance sensor 24 and the IR sensor 26 are coupled to the control unit 22 through a digital front end interface module of the control unit 22 of a known type.
[0032] For example, the distance sensor 24 and the IR sensor 26 may optionally be of the micro-electromechanical system MEMS type. In other words, they may be manufactured using known micro-fabrication techniques for processing semiconductor materials (such as silicon, for example). Nevertheless, other technologies may also be similarly considered.
[0033] The distance sensor 24 is of a known type and is configured to measure a distance D between the user 11 and the measuring device 20 when the user 11 is in a field of view 24 ′ of the distance sensor 24 .
[0034] Specifically, the distance sensor 24 is a time-of-flight (ToF) sensor, for example, an ultrasonic or optical ToF sensor.
[0035] Hereinafter, a case where the distance sensor 24 is an optical ToF sensor is exemplarily considered, however, other types of ToF sensors (eg, ultrasonic sensors) or distance sensors may be considered.
[0036] In use, the distance sensor 24 generates a distance signal S d , distance signal S d is received by the control unit 22 and when the user 11 is in the field of view 24 ′, the distance signal S d The distance D of the user 11 from the distance sensor 24 (ie from the measuring device 10 ) is indicated.
[0037] The IR sensor 26 is an IR radiation sensor configured to detect IR radiation emitted by an emitter (ie a hot body, in particular the user 11 ) when the emitter is in a field of view 26 ′ of the IR sensor 26 .
[0038] In particular, the IR sensor 26 is a “thermal MOS” TMOS sensor of a known type, which operates as a detector of IR radiation emitted by the user 11 .
[0039] In particular, TMOS is a field effect transistor device of a known type and is often used in sensor applications to determine the amount of radiation (particularly IR radiation) emitted by an emitter (here the user 11). An emitter is any thermal body that emits IR radiation, such as a person or an animal. The radiation emitted by the emitter and received by the TMOS results in the generation of charge carriers at the conductive channel of the TMOS and thus in a corresponding change in the output current of the TMOS; the latter can be related to the degree of radiation emitted by the object under inspection, so that the radiation emitted by the emitter can be measured.
[0040] In general, the TMOS allows detecting the presence or absence of a user 11 in its field of view 26'.
[0041] According to the embodiment exemplarily considered below, the TMOS present in the measuring device 10 is an infrared temperature sensor TMOS sold by STMicroelectronics with the reference code STHS34PF80 (more details can be found at the address https: / / www.st.com / en / mems-and-sensors / infrared-ir-sensors.html).
[0042] In particular, the TMOS sensor (specifically the STHS34PF80 from STMicroelectronics) is able to generate a temperature signal that is correlated to the presence or absence of the user 11 in the field of view 26'.
[0043] The temperature signal is a signal that is indicative of the temperature of an entity (a living being such as a person, or an inanimate but hot object such as a heating device) present in the field of view 26 ′ of the IR sensor 26 .
[0044] Thus, the temperature signal is determined based on both the IR radiation emitted by the user 11 present in the field of view 26′ of the TMOS sensor and the IR radiation that may generally be present in the environment in which the TMOS sensor is located even in the absence of a living being. In other words, the temperature signal has a baseline that depends on the amount of ambient IR radiation measured by the TMOS sensor when there is no user 11 in the field of view 26′ (e.g., due to electromagnetic noise of the environment in which the TMOS sensor is located, the air temperature around the TMOS sensor, etc.), and changes relative to this baseline when the TMOS sensor detects IR radiation emitted by the user 11 (which adds to the already present ambient IR radiation). Thus, a peak in the temperature signal of the TMOS sensor relative to its baseline indicates the presence of the user 11 in the field of view 26′ of the IR sensor 26.
[0045] In particular, in a manner known per se, the TMOS sensor may be of temperature compensated type.
[0046] In the embodiment considered here in which the TMOS sensor is the STHS34PF80 from STMicroelectronics, the temperature signal corresponds to the signal T indicated in the data sheet of the TMOS sensor. object (or even T obj Therefore, in the following, the temperature signal is denoted by the reference symbol T object To indicate.
[0047] Thus, in use, the IR sensor 26 generates a temperature signal T object , which temperature signal is received by the control unit 22 and indicates the intensity of the IR radiation emitted by the user 11 and detected by the IR sensor 26 when the user 11 is in the field of view 26′. Considering that the IR radiation detected by the IR sensor 26 is proportional to the intensity of the IR radiation emitted by the emitter, but is also inversely proportional to the distance between the IR sensor 26 and the emitter, the temperature signal T object is related to the distance D of the user 11 from the IR sensor 26 (ie, from the measuring device 10). Therefore, and as better described below, it is possible to obtain the temperature signal T object Start by measuring the distance D.
[0048] Specifically, Figure 3 The temperature signal T is shown as the distance between the user 11 and the measuring device 10 changes. object . Figure 3The curve shown in is better described below.
[0049] For example, in the present application, the TMOS sensor may be operated at an "output data rate" (ODR) equal to about 8 Hz.
[0050] like Figure 2 As shown in FIG. 1 , the distance sensor 24 and the IR sensor 26 extend at the main surface 12 so that when the user 11 is in the use position of the PC 10 , the distance sensor 24 and the IR sensor 26 face the user 11 .
[0051] For example, distance sensor 24 and IR sensor 26 are transverse to each other relative to major surface 12 .
[0052] The fields of view 24′ and 26′ of the distance sensor 24 and the IR sensor 26 overlap each other at the use position of the PC 10. In other words, the fields of view 24′ and 26′ have an overlapping area 28 that includes the use position of the PC 10, so that when the user 11 is in the use position of the PC 10, the user 11 is detected by both the distance sensor 24 and the IR sensor 26.
[0053] For example, the field of view 24' of the distance sensor 24 has a detection angle (or opening angle) α equal to about 25°. 1 , and the field of view 26 ′ of the IR sensor 26 has a corresponding detection angle (or opening angle) α equal to about 80° 2 .
[0054] Considering that the distance sensor 24 and the IR sensor 26 have a substantially negligible mutual distance (not shown) (e.g., which may be less than a few centimeters), it turns out that the extension of the overlapping area 28 is almost equal to the smaller of the fields of view 24′ and 26′ (here, the field of view 24′). For the same reason, it can be considered that the distance between the user 11 and the distance sensor 24 and the distance between the user 11 and the IR sensor 26 are substantially equal to each other and that they define the distance D between the user 11 and the PC 10. It has been found that this is particularly the case when there is a high degree of overlap of the fields of view 24′ and 26′ with each other, as described above. However, it is clear that the exact value of the distance D between the user 11 and the PC 10 can be calculated starting from the distance between the user 11 and the distance sensor 24 and / or from the distance between the user 11 and the IR sensor 26, depending on the actual arrangement of the distance sensor 24 and / or the IR sensor 26 in the PC 10 and known triangulation techniques.
[0055] In use, the control unit 22 implements the Figure 4 The measurement method described is 50.
[0056] Specifically, in use, the control unit 22 generates a temperature signal T based on the temperature signal T obtained by the IR sensor 26. object To determine the distance D between the user 11 and the measuring device 20 .
[0057] The measuring method 50 identifies a calibration mode 50 a , a calibrated mode 50 b , and a calibration update mode 50 c of the measuring device 20 .
[0058] When the measuring device 20 is switched on or provided with a measurement start signal, the measuring device 20 is initially operated in a calibration mode 50a in order to be calibrated. As better described below, during calibration, the distance signal S is acquired. d and temperature signal T object , and based on these signals, generate a calibration curve (specifically, Figure 3 The reference symbol C c An example is shown), where the temperature signal T object The value of is associated with the corresponding value of the distance D, so that the temperature signal T object The distance D is determined. Thus, in this mode both the distance sensor 24 and the IR sensor 26 are always active.
[0059] After the calibration mode 50a, the measuring device 20 operates in the calibrated mode 50b. In the calibrated mode 50b, the temperature signal T object , and based on the signal and the calibration curve C c , determine the distance D. Furthermore, in this mode, it is periodically verified whether the calibration update condition is confirmed, which means that the calibration previously performed in the calibration mode 50a needs to be updated. Specifically, and as better described below, the temperature signal T object and distance signal S d Both are acquired periodically and based on these signals the calibration update condition is verified.Thus, in this mode the IR sensor 26 is always active and the distance sensor 24 is only periodically active.
[0060] When the calibration update condition is confirmed, the measuring device 20 operates in the calibration update mode 50c. In the calibration update mode 50c, based on the newly acquired distance signal S d and temperature signal T object The value of , the measuring device 20 is calibrated again to obtain the updated calibration curve C cSpecifically, the calibration of the measuring device 20 may be updated according to changes in the environmental conditions of the location where the PC 10 is located (e.g., turning on an air conditioner or heating system, which changes the air temperature around the PC 10), which may affect the measurements of the IR sensor 26 and / or the distance sensor 24, making them inaccurate and thus requiring recalibration. Therefore, in this mode, both the distance sensor 24 and the IR sensor 26 are always active.
[0061] In the calibration curve C c After the update of the calibration curve C, the measuring device 20 c Again operating in calibrated mode 50b.
[0062] Figure 4 An embodiment of a measuring method 50 is shown in detail.
[0063] In step S10 of the calibration mode 50a, the control unit 22 obtains the distance signal S via the distance sensor 24. d , and obtain the temperature signal T through the IR sensor 26 object Specifically, at the considered instant, there is a distance signal S d and temperature signal T object The corresponding values obtained are also indicated as S in the following text. d,i and T object,i , where i is the index corresponding to the time instant under consideration. In other words, this pair of values corresponds to measurements performed simultaneously. These values S d,i and T object,i respectively indicate the distance D between the user 11 and the measuring device 20 measured by the distance sensor 24, and the IR radiation emitted by the user 11 and detected by the IR sensor 26. For example, these values S d,i and T object,i They may be electrical quantities (e.g., voltage or current values) indicating the distance D measured by the distance sensor 24 and the IR radiation emitted by the user 11 and detected by the IR sensor 26, or they may correspond to information of the distance D measured by the distance sensor 24 and information of the IR radiation emitted by the user 11 and detected by the IR sensor 26, respectively.
[0064] In step S12 (following step S10) of the calibration mode 50a, the control unit 22 calculates the distance signal S d The measured value S d,i And the distance signal S d The stored value S buffer,k To calculate the minimum distance signal difference S d,mindist , store value S buffer,kIn particular, it has been stored in a buffer (for example, present in a data storage unit of the control unit 22).
[0065] As better described below, the buffer is configured to store K (eg, approximately 20) value pairs S d,i and T object,i , that is, K values T object,i and K corresponding values S d,i , each value S d,i A corresponding value D indicating the distance D between the user 11 and the measuring device 20 i .
[0066] Minimum distance signal difference S d,mindist is defined as the measurement value S taken at the considered instant i d,i With each stored value S present in the buffer buffer,k Specifically, the minimum distance signal difference S d,mindist is possible by storing the value S buffer,k and the measured value S d,i The distance value obtained by converting the minimum difference (for example, electrical quantity) calculated from the beginning of the calculation of the distance value into the distance value, or the distance value can be obtained by converting the stored value S buffer,k and the measured value S d,i (e.g., electrical quantity) is converted into a distance and then the minimum difference thereof is calculated to obtain a distance value. In other words, the minimum distance signal difference S d,mindist Calculated according to the following mathematical expression:
[0067] S d,mindist =min(|S d,i -S buffer,k |), where k = 1,…,K
[0068] Therefore, the minimum distance signal difference S d,mindist Indicates the measured value S d,i With the stored value S buffer,k proximity.
[0069] At step S14 (following step S12) of the calibration mode 50a, the control unit 22 verifies that the value S d,i The calculated minimum distance signal difference S d,mindist Is it greater than the minimum threshold difference S d,th (For example, a distance equal to about 30 mm).
[0070] If the minimum distance signal difference S d,mindist Not greater than the minimum threshold difference S d,th , the measurement method 50 returns to step S10, and the value pair S d,i and Tobject,i is not stored in the buffer because it is too close and similar to a value pair already stored in the buffer, i.e., it refers to a value D at distance D. i , the value D i Too close to a value of distance D having a corresponding value pair already stored in the buffer corresponding thereto.
[0071] If the minimum distance signal difference S d,mindist Greater than the minimum threshold difference S d,th , the method continues to step S16 (following step S14) of the calibration mode 50a, in which the new measured value pair S is stored therein. d,i and T object,i to update the buffer, since this value pair is far enough away and therefore different from the value pairs already stored in the buffer, i.e., it refers to a value D at distance D i , the value D i The value of the distance D is far enough away to have a corresponding value pair corresponding thereto already stored in the buffer.
[0072] In the first iteration of the measurement method 50, in which the buffer is empty, the first measurement value pair S d,i and T object,i is stored in the buffer. In subsequent iterations, only when new measurements are made to S d,i and T object,i They are stored in the buffer only when the conditions of step S14 are met.
[0073] At step S18 (following step S16) of the calibration mode 50a, the control unit 22 verifies whether the buffer is full, ie whether it is full and therefore whether K pairs of values S are stored therein. d,i and T object,i .
[0074] If the buffer is not full, the measuring method 50 returns to step S10 so that the buffer can continue to be filled.
[0075] If the buffer is full, the method continues with step S20 of calibration mode 50a (following step S18), in which the previously described and Figure 3 The calibration curve C is shown in c .
[0076] Specifically, from the distance signal S already stored in the buffer d The value (hereinafter also referred to as S buffer,k , where k=1, ..., K), the corresponding value D of the distance D is determined in a manner known per se (eg by means of a known transfer function) buffer,k Alternatively, if the distance signal S already stored in the bufferd The value of S buffer,k If the distance information is already available, this intermediate step can be omitted because the distance information is already available (in this case, S buffer,k =D buffer,k ).
[0077] Since the data stored in the buffer is buffer,k Start calculating each value D buffer,k are coupled to the temperature signal T stored in the buffer object The corresponding value (hereinafter also referred to as T buffer,k In this way, the value pairs D associated with each other are defined. buffer,k and T buffer,k A collection of .
[0078] like Figure 3 As shown in buffer,k and T buffer,k Each pair in can be graphically represented as a corresponding point in a two-dimensional graph having the distance D measured by the distance sensor 24 on the abscissa axis and the temperature signal T measured by the IR sensor 26 on the ordinate axis. object .
[0079] Then, the control unit 22 interpolates the points of the set (ie, by performing a pair of value pairs D buffer,k and T buffer,k The calibration curve C is determined by interpolation c This allows obtaining the distance D measured by the distance sensor 24 and the temperature signal T measured by the IR sensor 26 object Therefore, the calibration curve C c Each value of the distance D measured by the distance sensor 24 is compared with the temperature signal T measured by the IR sensor 26. object , and vice versa.
[0080] The interpolation can be performed based on several known mathematical functions. For example, the interpolation function can be an exponential function, a first-order polynomial function, a second-order polynomial function or a third-order polynomial function. Nevertheless, other known interpolation functions can also be used. Specifically, it has been confirmed that the second-order polynomial function and the third-order polynomial function are functions that allow the best interpolation accuracy to be achieved among the interpolation functions mentioned in this article.
[0081] The interpolation function may be selected in a design step of the measuring device 20 and may therefore be predefined and fixed, or it may depend on the value pair D buffer,k and T buffer,kIn the second case, the value D in the stored set can be selected from the interpolation function described previously to best interpolate the value D in the stored set. buffer,k and T buffer,k The selection of the curve with the optimized interpolation is carried out in a manner known per se.
[0082] Therefore, the calibration mode 50a is based on the calibration curve C at step S20. c At this point, in fact, the measuring device 20 is calibrated, because there are components available for the temperature signal T acquired by the IR sensor 26. object Start measuring the distance D accurately.
[0083] After step S20 , the measuring method 50 continues with the calibrated mode 50 b of the measuring device 20 .
[0084] Specifically, in step S22 (following step S20) of the calibrated mode 50b, the control unit 22 obtains the temperature signal T via the IR sensor 26. object The new value T object,i As mentioned above, the new value T object,i The new value D of the distance D of the user 11 from the measuring device 20 i Therefore, in step S22, the distance sensor 24 is inactive, ie it does not perform any measurements.
[0085] In step S24 (following step S22) of the calibrated mode 50b, the control unit 22 calculates the temperature signal T object The new value T object,i and calibration curve C c Determine the new value D of distance D i Specifically, the new value D i is the calibration curve C c The temperature signal T object The new measurement value T object,i The corresponding distance D value.
[0086] After determining the new distance D based on the measurements performed by the IR sensor 26, the measuring method 50 continues with step S26 (following step S24) of the calibrated mode 50b, in which the control unit 22 verifies whether it is necessary to perform a calibration control (also called periodic calibration control) to verify the previously calculated calibration curve C c reliability.
[0087] The calibration control is performed periodically, ie each time a calibration control interval has elapsed since the last calibration control was performed. For example, the calibration control interval may be equal to about 5 seconds.
[0088] Therefore, at step S26, it is verified whether the calibration control interval has elapsed since the last check whether it is necessary to perform the calibration control.
[0089] If the calibration control interval has not yet elapsed, the measurement method 50 continues with step S34 of the calibrated mode 50b, which will be better described below.
[0090] On the contrary, if the calibration control interval has passed, the measuring method 50 continues to step S28 (following step S26) of the calibrated mode 50b, in which the control unit 22 acquires the distance signal S via the distance sensor 24. d The new value S d,i Therefore, at step S28, the distance sensor 24 is active.
[0091] In step S30 (following step S28) of the calibrated mode 50b, the control unit 22 calculates the distance signal error D err .
[0092] Distance signal error D err Based on the temperature signal T object and distance signal S d The new measurement value T object,i and S d,i The value of the distance D obtained initially (ie, the value obtained when steps S22 and S28 were most recently performed).
[0093] Specifically, in order to calculate the distance signal error D err , according to the calibration curve C c and the temperature signal T obtained at step S22 object The measured value T object,i To determine the estimated value of distance D object,i (Similar to what is done in step S24). In addition, according to the distance signal S obtained in step S28 d The value of S d,i To determine the value of distance D d,i (Similar to the operation done in step S10).
[0094] Since the distance sensor 24 has a higher distance D measurement accuracy than the IR sensor 26, it is assumed here that the value D d,i is consistent with the actual distance D at the iteration moment considered, i.e. it is a correct and true measurement. Thus, with respect to the measurements made by the distance sensor 24, a correct or abnormal operating state of the IR sensor 26 is determined, such that an abnormal operation corresponds to the measurement obtained from the IR sensor 26 (by applying the calibration curve C c ) and a significant relative offset in the distance measurements obtained from the distance sensor 24.
[0095] Therefore, the distance signal error D err is defined as the estimated value (or estimated distance value) D obtained by the IR sensor 26 object,i The value obtained by the distance sensor 24 (or the measured distance value) D d,i In other words, the distance signal error D err It is calculated according to the following mathematical expression:
[0096] D err =|D object,i -D d,i |
[0097] Therefore, the distance signal error D err The difference between the measurements of the distance D operated by the IR sensor 26 and the distance sensor 24 is indicated, wherein the measurement of the distance sensor 24 is used as a reference for the measurement of the actual distance D.
[0098] At step S32 (following step S30) of the calibrated mode 50b, the control unit 22 verifies that the value D object,i The calibration curve C c The first unreliability condition corresponds to a calibration anomaly detected by verifying the data of the distance sensor 24 (for simplicity, therefore also referred to as an anomaly of the distance sensor 24).
[0099] Specifically, check the distance signal error D err Is it greater than the distance signal threshold error D? err,th (e.g., equal to about 200 mm). When this condition is verified, it is used to calculate the value D object,i The calibration curve C c may be unreliable and therefore require entering calibration update mode 50c for further checks and, if a need is detected after these checks, updating the calibration curve C c .
[0100] Therefore, if the calibration curve C c The first unreliability condition is confirmed and thus the calibration curve C c is likely unreliable, the measurement method 50 then continues with step S50 of a calibration update mode 50c, which will be better discussed below.
[0101] On the contrary, if the calibration curve C c If the first unreliability condition is not confirmed, the measurement method 50 proceeds to step S34 of the calibrated mode 50b (following step S32 by a "No" output of step S32 and following step S26 by a "No" output of step S26).
[0102] At step S34, the control unit 22 calculates the minimum temperature signal difference T object,mindist .
[0103] Minimum temperature signal difference T object,mindist is based on the temperature signal T previously acquired when step S22 was most recently executed. object The measured value T object,i And the temperature signal T stored in the buffer object The storage value T buffer,k Specifically, the minimum temperature signal difference T object,mindist is defined as the measurement value T obtained at step S22 object,i With each stored value T present in the buffer buffer,k In other words, the minimum temperature signal difference T object,mindist Calculated according to the following mathematical expression:
[0104] T object,mindist =min(|T object,i -T buffer,k |), where k = 1,…,K
[0105] Therefore, the minimum temperature signal difference T object,mindist Indicates the measured value T object,i With the stored value T buffer,k proximity.
[0106] At step S36 (following step S34) of the calibrated mode 50b, the control unit 22 verifies that the value D object,i The calibration curve C c The second unreliability condition corresponds to a calibration anomaly detected by verifying the data of the IR sensor 26 (for simplicity, it is also referred to as an anomaly of the IR sensor 26). Specifically, the detection of the second unreliability condition is based on the measurement value T object,i With the stored value T buffer,k The proximity check is because if the temperature data T object,i The calibration curve C was previously used to calculate c Data T buffer,k If the difference is too large, the calibration curve C c For the value D object,i The calculation may be inaccurate.
[0107] Specifically, at step S36, the minimum temperature signal difference T is checked. object,mindist Is it greater than the minimum temperature signal threshold difference T object,th (e.g., equal to about 250 LSB). When this condition is verified, the measurement T of the IR sensor 26object,i The calibration curve C c Data T buffer,k The difference is too large, and therefore it is necessary to enter the calibration update mode 50c to update the calibration curve C c .
[0108] Therefore, if the second unreliability condition is verified and therefore the measured value T object,i The calibration curve C c Data T buffer,k If the difference is too great, the measurement method 50 proceeds to step S54 of the calibration update mode 50c, which will be better discussed below.
[0109] On the contrary, if the second unreliability condition is not verified and therefore the measured value T object,i The calibration curve C c Data T buffer,k If close enough, the measurement method 50 returns to step S22.
[0110] Generally speaking, the conditions checked at steps S32 and S36 define the previously described calibration update conditions, which are required to understand whether the measurement of distance D performed at step S24 is reliable, or whether it is unreliable and therefore requires entering calibration update mode 50c for possible calibration update.
[0111] In step S38 of the calibration update mode 50c, the control unit 22 obtains the distance signal S through the distance sensor 24 and the IR sensor 26. d and temperature signal T object The new value S d,i and T object,i , similar to what has been described in step S10.
[0112] At step S40 (following step S38) of the calibration update mode 50c, the control unit 22 determines a new value D of the distance D. i For example, this can be done based on the measurement performed by the IR sensor 26 at step S38, similar to what has been described in step S24. However, as will be better described below, this determination can also be done in a different way, for example based on the distance signal S acquired at step S38 d The value of S d,i .
[0113] In step S42 (following step S40) of the calibration update mode 50c, the control unit 22 calculates the new value S obtained in step S38 based on the new value S d,i and T object,i Calculate the distance signal error D again err, similar to what has been described in step S30.
[0114] In step S44 (following step S42) of the calibration update mode 50c, the control unit 22 calculates the distance signal error D based on the distance signal error D calculated in step S42. err , the abnormal condition (ie, the first unreliability condition) of the distance sensor 24 is verified again in a manner similar to that already described in step S32. Specifically, the distance signal error D err Is it greater than the distance signal threshold error D? err,th .
[0115] If the abnormal condition of the distance sensor 24 is not confirmed at step S44, the measurement method 50 proceeds to step S46 (following step S44) of the calibration update mode 50c.
[0116] At step S46 , the control unit 22 updates the value of the count index n by decreasing the value of the count index n by one unit.
[0117] Specifically, each time the method enters the calibration update mode 50c from the calibrated mode 50b, the count index n is initialized to an initial value (e.g., 0). The count index n is updated during the calibration update mode 50c and can vary between a predefined minimum value (e.g., the initial value) and a predefined maximum value (or a predefined number) N (e.g., 15).
[0118] At step S48 (following step S46 ) of the calibration update mode 50 c , the control unit 22 verifies whether the first update condition (or the minimum update condition) is confirmed.
[0119] Specifically, if the count index n assumes a predefined minimum value (eg, 0), the first update condition is confirmed.
[0120] If the first update condition is confirmed, the measurement method 50 returns to step S22 of the calibrated mode 50b because the duration of the detected abnormality of the distance sensor 24 is insufficient to indicate that the calibration curve C c A true lack of reliability that requires a new calibration (ie, it has not been detected for N time instances).
[0121] In contrast, if the first update condition is not confirmed, the measurement method 50 returns to step S38.
[0122] In contrast, if the abnormal condition of the distance sensor 24 of step S44 is confirmed, the measurement method 50 proceeds to step S50 of the calibration update mode 50c (thus, this step follows step S44 through the output "yes" of step S44 and follows step S32 through the output "yes" of step S32).
[0123] At step S50 , the control unit 22 updates the value of the count index n by increasing the value of the count index n by one unit.
[0124] Specifically, since the method directly proceeds to step S50 (i.e., this step is the first step executed when entering the calibration update mode 50c) in the case where the abnormal condition of the distance sensor 24 is confirmed at step S32, the count index n is increased by one unit immediately after being initialized to the initial value. This avoids the possibility that the count index n is updated to a value less than the initial value at step S46 and thus a counting error occurs.
[0125] At step S52 (following step S50 ) of the calibration update mode 50 c , the control unit 22 verifies whether the second update condition (or the maximum update condition) is confirmed.
[0126] Specifically, if the count index n is assumed to be a predefined maximum value N (eg, 15), that is, if the abnormality duration is sufficient to indicate that the calibration curve C c If there is a genuine lack of reliability such that a new calibration is required (ie if it has been detected within N time instances), then a second update condition is confirmed.
[0127] If the second update condition is not confirmed, the measurement method 50 returns to step S38.
[0128] If, on the contrary, the second update condition is confirmed, the measurement method 50 proceeds to step S54 of the calibration update mode 50c (following step S52 by a "yes" output of step S52 and following step S36 by a "yes" output of step S36).
[0129] In other words, steps S38-S52 allow verifying whether the abnormal condition of the distance sensor 24 is confirmed within a predefined number N of mutually successive (not necessarily consecutive) time moments, and therefore whether it persists long enough to indicate that the calibration curve C c There is a genuine lack of reliability that requires a new calibration.
[0130] At step S54, the control unit 22 stores the new measurement value pair S d,i and T object,i To update the buffer to replace the least recent value pair (ie, the oldest value pair stored in the buffer).
[0131] In the case of an abnormality in the distance sensor 24, this newly stored pair may be the most recently acquired pair, and thus the value pair S obtained when step S38 was most recently executed. d,i and T object,iAlternatively, in the case of an abnormality in the IR sensor 26, the newly stored pair may be the new value pair S obtained at this step. d,i and T object,i In other words, in the second case, step S54 may include obtaining a new value pair S d,i and T object,i , similar to what has been described previously in steps S10 and S38, the new value pair is then stored in a buffer.
[0132] At step S56 (following step S54) of the calibration update mode 50c, the control unit 22 updates the calibration curve C based on the buffer that has been updated in step S54. c This takes place in a manner completely similar to that already described previously in step S20.
[0133] After step S56 , the measuring method 50 returns to step S22 , since the measuring device 20 is calibrated again.
[0134] In addition, and with Figure 4 In a manner not shown in the figure, the measuring device 20 can generate an output signal indicating the value of the distance D. The output signal can be received by the PC 10 (or by an external device operably coupled to the measuring device 20) and can be used to control one or more functions of the PC 10 (or the external device). For example, the screen of the PC 10 can be automatically activated or deactivated according to the distance D measured between the user 11 and the PC 10.
[0135] Specifically, the output signal may be equal to the value D calculated in the last step performed between steps S24 and S40 at any time. object,i (The IR sensor 26 is thus still used.) Alternatively, when the distance sensor 24 is inactive, the output signal may be equal to the value D calculated in the last step performed between steps S24 and S40. object,i , and when the distance sensor 24 is active, the output signal may be equal to the value D obtained in the last step performed between steps S30 and S42 d,i : In this case, the output signal is generally equal to the measurement obtained using the IR sensor 26, unless the measurement of the distance sensor 24 (which still has a higher accuracy) is available.
[0136] The aforementioned measuring method 50 may be implemented by the control unit 22 via a corresponding computer program product.
[0137] Advantages provided by the present disclosure are apparent from an examination of the features of the present disclosure made in light of the present disclosure.
[0138] The measuring device 20 and the measuring method 50 allow the distance D between the user 11 and the measuring device 20 to be measured with high accuracy and low power consumption.
[0139] In fact, the measurement of the distance D is performed by the IR sensor 26 (which has low energy consumption), while the distance sensor 24 (which has accurate measurement but high energy consumption) is only used to calibrate the measurement of the IR sensor 26, to regularly verify whether there are anomalies in the measurements performed, and to recalibrate the measurement of the IR sensor 26 if necessary.
[0140] Specifically, since the calibration curve C c A correlation between the measurements of the IR sensor 26 and the measurements of the distance sensor 24 is provided, so that the distance D can be measured based on the IR sensor 26 with a measurement accuracy that is substantially comparable to the known case where the measurement is performed using the distance sensor 24. In addition, since the measurement is performed using the IR sensor 26, the power consumption is significantly reduced (e.g., up to about 1000 times) compared to the known case where the distance sensor 24 is used.
[0141] Furthermore, the calibration update mode 50c ensures that the values measured by the IR sensor 26 are compared with those previously stored in the buffer and used to calculate the calibration curve C. c In the event that the values of φ differ too much, the calibration is updated to bring the measurements of the measuring device 20 back to the desired level of accuracy.
[0142] In addition, the calibration curve C is detected at step S32. c In the case of potential unreliability of the measurement result, if an anomaly is confirmed for N consecutive samples, a calibration update is performed so that any isolated and transient abnormal result does not lead to an unnecessary calibration update. This allows the energy consumption of the measuring device 20 to be further reduced.
[0143] Furthermore, it has been verified that the measurements of the measuring device 20 allow distinguishing the presence of the user 11 with respect to other objects present in the fields of view 24 ′ and 26 ′, such as inanimate objects. In this way, the measurements performed are selective for the user 11 .
[0144] Finally, it is obvious that modifications and variations may be made to the disclosure described and illustrated herein without thereby departing from the scope of the present disclosure. For example, the different embodiments described may be combined with each other to provide further solutions.
[0145] In addition, the calibration curve C described in steps S26-S56 may be omitted. c Regular inspection and subsequent updating are carried out to further reduce the energy consumption of the measuring device 20.
[0146] In addition, although the distance signal S has been described aboved The value of S d,i Indicates the corresponding value D of the distance D d,i And thus steps S30 and S42 include starting from the value S d,i Start to determine the value D d,i But obviously, the value S d,i may already directly correspond to the value of the distance D, and thus the determination of the value D may be omitted. d,i In other words, in this case the distance sensor 24 generates information about the distance D directly at the output, which information is used to calculate the distance signal error D in a manner similar to what has been described above. err .
[0147] In addition, when entering the calibration update mode 50c after detecting an abnormal condition of the distance sensor 24 at step S32, the count index n can also be initialized to a value greater than the predefined minimum value (specifically, the value is equal to the predefined minimum value more than one unit, and therefore exemplarily 1 here) and proceed directly to step S38. In other words, through this different initialization, steps S50 and S52 do not need to be performed before entering step S38, and therefore the method can directly proceed to the action of step S38. This further simplifies the measurement method 50.
[0148] A measuring device (20) is used to measure a distance (D) between the measuring device (20) and a user (11), the measuring device (20) can be summarized as comprising: a distance sensor (24) configured to measure the distance (D) when the user (11) is within a field of view (24') of the distance sensor (24), and to generate a distance signal (S) indicating the distance (D). d ); an infrared IR radiation sensor (26) configured to detect IR radiation emitted by a user (11) when the user (11) is within a corresponding field of view (26′) of the IR radiation sensor (26), and to generate a temperature signal (T) indicative of the IR radiation detected and associated with a distance (D) from the user (11); object ), the field of view (24′) of the distance sensor (24) and the field of view (26′) of the IR radiation sensor (26) at least partially overlap each other; and a control unit (22), which is coupled to the distance sensor (24) and the IR radiation sensor (26) and is configured to: in a calibration mode (50a) of the measuring device (20), respectively obtain a distance signal (S) through the distance sensor (24) and the IR radiation sensor (26) d ) and temperature signal (T object ), and based on the distance signal (S d ) and temperature signal (T object ) to generate a calibration curve (C c), the calibration curve (C c )The temperature signal (T object ) is associated with the corresponding value of the distance (D); and in a calibrated mode (50b) of the measuring device (20), a temperature signal (T object ), and based on the temperature signal (T object ) and calibration curve (C c )Determine the distance (D).
[0149] The control unit (22) may also be configured to: in the calibrated mode (50b) of the measuring device (20), periodically acquire a distance signal (S) via the distance sensor (24) d ), and based on the distance signal (S) acquired in the calibrated mode (50b) d ) and temperature signal (T object ) verifying the calibration update condition; and if the calibration update condition is confirmed, then in the calibration update mode (50c) of the measuring device (20), based on the distance signal (S d ) and temperature signal (T object ) Update the calibration curve (C c ).
[0150] The IR radiation sensor (26) may be a "thermal MOS" TMOS, wherein the distance sensor (24) may be a time-of-flight sensor.
[0151] The electronic device (10) is usable by a user (11) and may be summarized as including a measuring apparatus (20).
[0152] The field of view (24') of the distance sensor (24) and the field of view (26') of the IR radiation sensor (26) may at least partially overlap each other at a use position of the user (11), wherein the electronic device (10) may be used by the user (11).
[0153] The electronic device (10) may be configured to control a function of the electronic device (10) according to the distance (D) measured by the measuring device (20).
[0154] A measuring method (50) for measuring a distance (D) between a measuring device (20) and a user (11), the measuring device (20) can be summarized as comprising: a distance sensor (24) for measuring the distance (D) when the user (11) is within a field of view (24') of the distance sensor (24), and generating a distance signal (S) indicating the distance (D) d); an infrared IR radiation sensor (26) for detecting IR radiation emitted by a user (11) when the user (11) is within a corresponding field of view (26′) of the IR radiation sensor (26), and generating a temperature signal (T) indicative of the IR radiation detected and associated with a distance (D) to the user (11); object ), the field of view (24′) of the distance sensor (24) and the field of view (26′) of the IR radiation sensor (26) at least partially overlap each other; and a control unit (22) coupled to the distance sensor (24) and the IR radiation sensor (26); the measuring method (50) is executed by the control unit (22) and comprises the following steps: in a calibration mode (50a) of the measuring device (20): acquiring (S10) a distance signal (S11) via the distance sensor (24) and the IR radiation sensor (26), respectively d ) and temperature signal (T object ); and based on the distance signal (S d ) and temperature signal (T object ) generates (S12-S20) calibration curve (C c ), the calibration curve (C c )The temperature signal (T object ) and the corresponding value of the distance (D) are associated with each other; and in a calibrated mode (50b) of the measuring device (20): acquiring (S22) a temperature signal (T object ); and based on the temperature signal (T object ) and calibration curve (C c )determine (S24) the distance (D).
[0155] Generate (S12-S20) calibration curve (C c The step of ) may include: for the distance signal (S) acquired at the considered time instant d ) and temperature signal (T object ) for each value pair (S d,i ,T object,i ): Calculate (S12) the corresponding minimum distance signal difference (S d,mindist ), which indicates the distance signal (S d ) value (S d,i ) and the distance signal (S d ) of the corresponding multiple storage values (S buffer,k ) between the minimum difference between the multiple differences calculated in absolute value; verify (S14) the corresponding minimum distance signal difference (S d,mindist ) is greater than the minimum threshold difference (S d,th ); If the minimum distance signal difference (S d,mindist ) is greater than the minimum threshold difference (S d,th), then by storing the distance signal (S d ) and temperature signal (T object ) value pair (S d,i ,T object,i ) to update (S16) the buffer; verify (S18) the distance signal (S d ) and temperature signal (T object ) of a predefined number (K) of value pairs (S d,i ,T object,i ) is stored in the buffer; and if the distance signal (S d ) and temperature signal (T object ) of a predefined number (K) of value pairs (S d,i ,T object,i ) is stored in the buffer, then based on the distance signal (S d ) and temperature signal (T object ) value pair (S d,i ,T object,i ) and the interpolation performed to calculate (S20) the calibration curve (C c ).
[0156] Calculate (S20) calibration curve (C c The step of ) may include: based on the distance signal (S d ) and temperature signal (T object ) value pair (S d,i ,T object,i ), select an interpolation function from multiple predefined interpolation functions to perform interpolation.
[0157] The measuring method (50) may further comprise the following steps: in the calibrated mode (50b) of the measuring device (20): regularly acquiring (S26, S28) a distance signal (S26) via the distance sensor (24); d ); and based on the distance signal (S) acquired in the calibrated mode (50b) d ) and temperature signal (T object ) to verify (S30-S36) the calibration update condition; if the calibration update condition is confirmed, then in the calibration update mode (50c) of the measuring device (20): based on the distance signal (S d ) and temperature signal (T object ) Update (S54-S56) the calibration curve (C c ).
[0158] Periodically obtain (S26, S28) the distance signal (S dThe step of: verifying (S26) whether a calibration control interval has passed since the last verification of the calibration update condition; and if the calibration control interval has passed, acquiring (S28) the distance signal (S d ).
[0159] The step of verifying (S30-S36) the calibration update condition may include: if the calibration control interval has passed, based on the distance signal (S30-S36) acquired in the calibrated mode (50b), d ) and temperature signal (T object ) to verify (S30, S32) the abnormal condition of the distance sensor (24); if the calibration control interval has not passed or if the abnormal condition of the distance sensor (24) has not been confirmed, based on the temperature signal (T) obtained in the calibrated mode (50b) object ) to verify (S34, S36) the abnormal condition of the IR radiation sensor (26), wherein, if the abnormal condition of the distance sensor (24) has been confirmed, the measurement method (50) may also include: in the calibration update mode (50c) of the measurement device (20), verifying (S38-S52) whether the abnormal condition of the distance sensor (24) is confirmed within a predefined number (N) of consecutive time moments, and wherein if the abnormal condition of the distance sensor (24) is confirmed within the predefined number (N) of consecutive time moments or if the abnormal condition of the IR radiation sensor (26) is confirmed, performing an update (S54-S56) of the calibration curve (C c ) steps.
[0160] The step of verifying (S30, S32) the abnormal condition of the distance sensor (24) may include: based on the distance signal (S d ) and temperature signal (T object ) value (S d,i ,T object,i ), calculate (S30) the distance signal error (D err ), the distance signal error (D err ) indicates the temperature signal (T object ) value (T object,i ) starts with determining the estimated distance value (D object,i ) and distance signal (S d ) value (S d,i ) related measured distance value (D d,i ) between the absolute value difference; and verify (S32) the distance signal error (D err ) is greater than the distance signal threshold error (D err,th), wherein the step of verifying (S34, S36) the abnormal condition of the IR radiation sensor (26) may include: based on a temperature signal (T object ) value (T object,i ), calculate (S34) the minimum temperature signal difference (T object,mindist ), the minimum temperature signal difference (T object,mindist ) indicates the temperature signal (T object ) value (T object,i ) and temperature signal (T object ) of the corresponding plurality of stored values (T buffer,k ) between the minimum difference between the plurality of differences calculated in absolute value; and verifying (S36) the minimum temperature signal difference (T object,mindist ) is greater than the minimum temperature signal threshold difference (T object,th ), wherein the step of verifying (S38-S52) whether the abnormal condition of the distance sensor (24) can be confirmed within a predefined number (N) of time moments may include: a. acquiring (S38) distance signals (S4) by the distance sensor (24) and the IR radiation sensor (26), respectively; d ) and temperature signal (T object )'s new value (S d,i ,T object,i ), again based on the temperature signal (T object )'s new value (T object,i ) and the calibration curve (C c ) determines (S40) the distance (D), again based on the distance signal (S d ) and temperature signal (T object )'s new value (S d,i ,T object,i ) calculate (S42) the distance signal error (D err ); b. Verify (S44) the new distance signal error (D err ) is greater than the distance signal threshold error (D err,th ); c. If the new distance signal error (D err ) is not greater than the distance signal threshold error (D err,th ), then update (S46) the count index (n) by reducing the value of the count index (n), and verify (S48) whether the count index (n) is a predefined minimum value; d. If the count index (n) is not the predefined minimum value, repeat steps ad; e. If the new distance signal error (D err ) is greater than the distance signal threshold error (D err,th), then updating (S50) the counting index (n) by increasing the value of the counting index (n), and verifying (S52) whether the counting index (n) is a predefined maximum value associated with the predefined number (N); and f. if the counting index (n) is not the predefined maximum value, repeating steps af, wherein if the counting index (n) is the predefined maximum value, updating (S54-S56) the calibration curve (C c ) steps.
[0161] Update (S54-S56) the calibration curve (C c The step of storing (S54) the distance signal (S d ) and temperature signal (T object )'s new value pair (S d,i ,T object,i ), as the oldest value pair (S d,i ,T object,i ) replacement; and by based on the distance signal (S stored in the updated buffer d ) and temperature signal (T object ) value pair (S d,i ,T object,i ) and recalculate (S56) the calibration curve (C c ).
[0162] The computer program product may be stored in a control unit (22) of the measuring device (20), the computer program being designed such that, when executed, the control unit (22) becomes configured to carry out the measuring method (50).
[0163] The various embodiments described above can be combined to provide additional embodiments. These and other changes can be made to the embodiments according to the above detailed description. In general, in the appended claims, the terms used should not be interpreted as limiting the claims to the specific embodiments disclosed in the specification and claims, but should be interpreted as including all possible embodiments and the full range of equivalents enjoyed by these claims. Therefore, the claims are not limited by this disclosure.
Claims
1. A measuring device, comprising: A distance sensor, wherein the distance sensor is configured to: When the user is within the field of view of the distance sensor, measuring the distance between the measurement device and the user, and generating a distance signal, the distance signal indicating the distance; Infrared IR sensor, the IR sensor is configured to: detecting IR radiation emitted by the user when the user is within a field of view of the IR sensor, the field of view of the distance sensor and the field of view of the IR sensor at least partially overlapping each other, and generating a temperature signal indicative of the IR radiation; and a controller coupled to the distance sensor and the IR sensor, and configured to: In the calibration mode of the measuring device, receiving the distance signal and the temperature signal, and generating a calibration curve based on the distance signal and the temperature signal, the calibration curve relating values of the temperature signal to corresponding values of the distance, and In the calibrated mode of the measuring device, receiving the temperature signal, and The distance is determined based on the temperature signal and the calibration curve.
2. The measuring device according to claim 1, wherein the controller is configured to: In the calibrated mode of the measuring device, periodically receiving the distance signal, and verifying a calibration update condition based on the distance signal and the temperature signal acquired in the calibrated mode; and If the calibration update condition is confirmed, the calibration curve is updated based on the distance signal and the temperature signal in a calibration update mode of the measuring device. 3 . The measuring device according to claim 1 , wherein the IR sensor is a thermal MOS (TMOS), and the distance sensor is a time-of-flight sensor.
4. An electronic device capable of being used by a user, the electronic device comprising: The measuring device according to claim 1. 5 . The electronic device of claim 4 , wherein a field of view of the distance sensor and a field of view of the IR sensor at least partially overlap each other at a use position of the user. 6 . The electronic device according to claim 4 , wherein the electronic device is configured to control a function of the electronic device according to the distance measured by the measuring device.
7. A method comprising: When the user is in the field of view of the distance sensor, the distance sensor measures the distance between the measuring device and the user; generating a distance signal by the distance sensor, the distance signal indicating the distance; When the user is within the field of view of an infrared (IR) sensor, IR radiation emitted by the user is detected by the IR sensor, the field of view of the distance sensor at least partially overlapping the field of view of the IR sensor; generating a temperature signal by the IR sensor, the temperature signal being indicative of the IR radiation; In the calibration mode of the measuring device in question: receiving, by a controller, the distance signal and the temperature signal; and generating a calibration curve based on the distance signal and the temperature signal, the calibration curve relating values of the temperature signal to corresponding values of the distance; as well as In the calibrated mode of the measuring device in question: receiving the temperature signal; and The distance is determined based on the temperature signal and the calibration curve.
8. The method of claim 7, wherein generating the calibration curve comprises: For a value pair of the distance signal and the temperature signal, determining a minimum range signal difference, the minimum range signal difference indicating a minimum difference between a plurality of differences calculated in absolute value between the value of the range signal and a corresponding plurality of stored values of the range signal, the corresponding plurality of stored values of the range signal being stored in a buffer; determining whether the minimum distance signal difference is greater than a minimum threshold difference; in response to determining that the minimum distance signal difference is greater than the minimum threshold difference, updating the buffer by storing the pair of values of the distance signal and the temperature signal; determining whether a predefined number of value pairs of the distance signal and the temperature signal are stored in the buffer; as well as In response to determining that the predefined number of value pairs of the distance signal and the temperature signal are stored in the buffer, the calibration curve is calculated by interpolation performed based on the value pairs of the distance signal and the temperature signal stored in the buffer.
9. The method of claim 8, wherein calculating the calibration curve comprises: Based on the value pairs of the distance signal and the temperature signal stored in the buffer, an interpolation function is selected among a plurality of predefined interpolation functions to perform the interpolation.
10. The method according to claim 7, comprising: In the calibrated mode of the measuring device: periodically acquiring the distance signal through the distance sensor; as well as verifying a calibration update condition based on the distance signal and the temperature signal acquired in the calibrated mode; as well as If the calibration update condition is confirmed, then in the calibration update mode of the measuring device: The calibration curve is updated based on the distance signal and the temperature signal.
11. The method according to claim 10, wherein periodically acquiring the distance signal comprises: verifying whether a calibration control interval has elapsed since a last verification of said calibration update condition; as well as If the calibration control interval has elapsed, the distance signal is acquired.
12. The method of claim 11, wherein verifying the calibration update condition comprises: if the calibration control interval has elapsed, verifying an abnormal condition of the distance sensor based on the distance signal and the temperature signal acquired in the calibrated mode; as well as if the calibration control interval has not elapsed or if the abnormal condition of the distance sensor has not been confirmed, verifying the abnormal condition of the IR sensor based on the temperature signal acquired in the calibrated mode, Wherein, if the abnormal condition of the distance sensor has been confirmed, the method further comprises: in the calibration update mode of the measuring device, verifying whether the abnormal condition of the distance sensor has been confirmed within a predefined number of successive time moments, and Therein, if the abnormal condition of the distance sensor is confirmed within the predefined number of mutually successive time moments or if the abnormal condition of the IR sensor is confirmed, updating the calibration curve is performed.
13. The method of claim 12, wherein verifying the abnormal condition of the distance sensor comprises: calculating a distance signal error based on the value of the distance signal and the value of the temperature signal acquired in the calibrated mode, the distance signal error indicating an absolute value difference between an estimated distance value determined starting from the value of the temperature signal and a measured distance value, the measured distance value being related to the value of the distance signal; as well as Verify whether the distance signal error is greater than the distance signal threshold error, Wherein verifying the abnormal condition of the IR sensor comprises: calculating, based on the value of the temperature signal acquired in the calibrated mode, a minimum temperature signal difference indicating a minimum difference between a plurality of differences calculated in absolute values between the value of the temperature signal and a corresponding plurality of stored values of the temperature signal; and Verifying whether the minimum temperature signal difference is greater than a minimum temperature signal threshold difference, wherein verifying whether the abnormal condition of the distance sensor is confirmed within the predefined number of time moments comprises: a. acquiring a new value of the distance signal and a new value of the temperature signal through the distance sensor and the IR sensor, determining the distance based on the new value of the temperature signal and the calibration curve, and calculating the distance signal error based on the new value of the distance signal and the new value of the temperature signal; b. Verify whether the new distance signal error is greater than the distance signal threshold error; c. if the new distance signal error is not greater than the distance signal threshold error, updating the count index by reducing the value of the count index, and verifying whether the count index is the same as a predefined minimum value; d. If the count index is not the same as the predefined minimum value, repeat steps ad; e. if the new distance signal error is greater than the distance signal threshold error, updating the count index by increasing the value of the count index, and verifying whether the count index is the same as a predefined maximum value, the predefined maximum value being associated with the predefined number; and f. If the count index is not the same as the predefined maximum value, repeat steps af, and Wherein if the count index is the same as the predefined maximum value, updating the calibration curve is performed.
14. The method of claim 8, wherein updating the calibration curve comprises: storing in the buffer a new value pair of the distance signal and the temperature signal as a replacement for the oldest value pair stored in the buffer; as well as The calibration curve is recalculated by interpolation performed based on the value pairs of the distance signal and the temperature signal stored in the updated buffer.
15. A computer-readable storage medium having executable instructions stored thereon, which when executed by a controller cause the controller to: In the calibration mode of the measuring device: When a user is within the field of view of the distance sensor, receiving a distance signal indicating a distance between a measuring device and the user, the distance being measured by the distance sensor; receiving a temperature signal indicative of IR radiation detected by the IR sensor and emitted by the user when the user is within a field of view of an infrared (IR) sensor, the field of view of the distance sensor at least partially overlapping the field of view of the IR sensor; and generating a calibration curve based on the distance signal and the temperature signal, the calibration curve relating values of the temperature signal to corresponding values of the distance; and In the calibrated mode of the measuring device in question: receiving the temperature signal; and The distance is determined based on the temperature signal and the calibration curve.
16. The computer-readable storage medium of claim 15, wherein generating the calibration curve comprises: For a value pair of the distance signal and the temperature signal, determining a minimum range signal difference, the minimum range signal difference indicating a minimum difference between a plurality of differences calculated in absolute value between the value of the range signal and a corresponding plurality of stored values of the range signal, the corresponding plurality of stored values of the range signal being stored in a buffer; determining whether the minimum distance signal difference is greater than a minimum threshold difference; in response to determining that the minimum distance signal difference is greater than the minimum threshold difference, updating the buffer by storing the pair of values of the distance signal and the temperature signal; determining whether a predefined number of value pairs of the distance signal and the temperature signal are stored in the buffer; and In response to determining that the predefined number of value pairs of the distance signal and the temperature signal are stored in the buffer, the calibration curve is calculated by interpolation performed based on the value pairs of the distance signal and the temperature signal stored in the buffer.
17. The computer readable storage medium of claim 16, wherein calculating the calibration curve comprises: Based on the value pairs of the distance signal and the temperature signal stored in the buffer, an interpolation function is selected among a plurality of predefined interpolation functions to perform the interpolation.
18. The computer-readable storage medium of claim 15, wherein the executable instructions, when executed by the controller, cause the controller to: In the calibrated mode of the measuring device: acquiring the distance signal periodically through the distance sensor; and verifying a calibration update condition based on the distance signal and the temperature signal acquired in the calibrated mode; and If the calibration update condition is confirmed, then in the calibration update mode of the measuring device: The calibration curve is updated based on the distance signal and the temperature signal.
19. The computer-readable storage medium of claim 18, wherein periodically acquiring the distance signal comprises: verifying whether a calibration control interval has elapsed since a last verification of said calibration update condition; as well as If the calibration control interval has elapsed, the distance signal is acquired.
20. The computer-readable storage medium of claim 19, wherein verifying the calibration update condition comprises: if the calibration control interval has elapsed, verifying an abnormal condition of the distance sensor based on the distance signal and the temperature signal acquired in the calibrated mode; as well as if the calibration control interval has not elapsed or if the abnormal condition of the distance sensor has not been confirmed, verifying the abnormal condition of the IR sensor based on the temperature signal acquired in the calibrated mode, Wherein, if the abnormal condition of the distance sensor has been confirmed, the method further comprises: in the calibration update mode of the measuring device, verifying whether the abnormal condition of the distance sensor has been confirmed within a predefined number of successive time moments, and Therein, if the abnormal condition of the distance sensor is confirmed within the predefined number of mutually successive time moments or if the abnormal condition of the IR sensor is confirmed, updating the calibration curve is performed.