Wearable device wearing state detection method and device and storage medium

By using infrared sensors in wearable devices to detect the power spectrum characteristics of the reflected infrared signal in the wearable device, the problems of low detection accuracy and high power consumption in the prior art are solved, and high-precision wear state detection is achieved and power consumption is reduced.

CN119896462APending Publication Date: 2025-04-29BEIJING XIAOMI MOBILE SOFTWARE CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202311402280.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-10-26
Publication Date
2025-04-29

AI Technical Summary

Technical Problem

In the prior art, when using infrared sensors to detect wearable devices, there are problems of low detection accuracy and high power consumption.

Method used

By controlling the infrared sensor of the wearable device to emit infrared signals and detect the reflected infrared signals, the power spectrum characteristics of the infrared signals detected by the infrared sensor in multiple different time windows are determined, and the wearing state is judged. Specific methods include extracting the main frequency in the power spectrum, calculating its standard deviation and information entropy characteristics, and weighting these characteristics to determine the power spectrum characteristics.

Benefits of technology

It achieves the problem of avoiding the sampling rate sensitivity, reducing detection power consumption, and obtaining high-precision wear status detection results.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119896462A_ABST
    Figure CN119896462A_ABST
Patent Text Reader

Abstract

The invention relates to a wearable device wearing state detection method and device and a storage medium. The wearable device wearing state detection method comprises the following steps: controlling an infrared sensor of the wearable device to emit an infrared signal, and detecting the reflected infrared signal; determining power spectrum characteristics of infrared signals detected by the infrared sensor in a plurality of different time windows; determining that the wearable device is in a wearing state in response to determining that the power spectrum feature meets a condition; the condition is determined based on a power spectrum characteristic of a preset physiological parameter after the infrared signal is reflected by a living body. According to the invention, the wearing detection based on the infrared signal can be realized, the power consumption required by the detection is reduced, and the detection accuracy is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of mobile device algorithms and wearable algorithm fields, and in particular to a method, device and storage medium for detecting the wearing state of a wearable device. Background Art

[0002] In the related art, there are a variety of algorithms for detecting the wearing state based on data detected by sensors such as capacitive sensors, infrared sensors, green light photoplethysmography (PPG), and acceleration sensors. However, the methods of using infrared sensors for wearing state detection in the related art have problems such as low detection accuracy and high power consumption. Summary of the invention

[0003] In order to overcome the problems existing in the related art, the present disclosure provides a method, an apparatus and a storage medium for detecting the wearing state of a wearable device.

[0004] According to a first aspect of an embodiment of the present disclosure, a method for detecting a wearing state of a wearable device is provided, comprising:

[0005] Control the infrared sensor of the wearable device to emit an infrared signal and detect the reflected infrared signal; determine the power spectrum characteristics of the infrared signal detected by the infrared sensor in multiple different time windows; in response to determining that the power spectrum characteristics meet the conditions, determine that the wearable device is in a wearing state; the conditions are determined based on the power spectrum characteristics of the preset physiological parameters determined after the infrared signal is reflected by the living body.

[0006] In one embodiment, determining the power spectrum characteristics of the infrared signal detected by the infrared sensor in a plurality of different time windows includes:

[0007] Determine the power spectrum of the infrared signal detected by the infrared sensor in multiple different time windows; extract a preset number of main frequencies from the power spectrum of the multiple different time windows, the main frequency being the maximum peak value in which the difference between peaks in the power spectrum is less than a first threshold; determine the standard deviation characteristics of the preset number of main frequencies, and determine the information entropy characteristics of the preset number of main frequencies, and weight the standard deviation characteristics and the information entropy characteristics to obtain the power spectrum characteristics, the information entropy characteristics characterize the uncertainty of the preset number of main frequencies in determining the preset physiological parameters, and the standard deviation characteristics represent the degree of discreteness of the preset number of main frequencies.

[0008] In one implementation, the power spectrum feature is a power spectrum feature value greater than 0;

[0009] The determining that the power spectrum feature meets a condition includes:

[0010] In response to the power spectrum characteristic value being less than a first threshold, the correct value is saved in a first array, otherwise the erroneous value is saved in the first array; in response to the power spectrum characteristic value being greater than a second threshold, the correct value is saved in a second array, otherwise the erroneous value is saved in the second array; the first threshold is used to distinguish whether the power spectrum characteristic satisfies a stable condition, and the second threshold is used to distinguish whether the power spectrum characteristic satisfies an unstable condition.

[0011] If the number of the first array is greater than the number of the second array, it is determined that the power spectrum feature meets the condition.

[0012] In one implementation, extracting a preset number of main frequencies from the power spectra of the multiple different time windows includes:

[0013] Based on the frequency domain information, a predefined number of spectrum peaks are obtained, where the spectrum peaks are frequency values ​​with amplitudes greater than those of adjacent points;

[0014] In response to obtaining a predefined number of spectral peaks for the first time, the value closest to the default value of the main frequency is selected as the main frequency, and the default value of the main frequency is a frequency value of a preset value; in response to obtaining a predefined number of spectral peaks for a non-first time, the value closest to the previous main frequency is selected as the main frequency; the main frequency is saved in a third array to obtain a preset number of main frequencies; a first counter is set, and the first counter is used to indicate the storage position of the latest data in the third array; in response to the value of the first counter reaching the length of the third array, the first counter is cleared, and storage is performed again from the starting position of the third array.

[0015] In one embodiment, obtaining a predefined number of spectral peaks comprises:

[0016] In response to the amplitude corresponding to the current frequency being greater than the amplitude corresponding to the adjacent frequency and greater than the preset amplitude, the current frequency is set as a spectrum peak; in response to the existence of multiple continuous frequencies whose amplitudes are equal and greater than the amplitudes corresponding to the adjacent frequencies, the minimum frequency among the multiple continuous frequencies is set as the spectrum peak.

[0017] In one embodiment, the detecting the reflected infrared signal includes:

[0018] Acquire measurement data of the acceleration sensor; in response to the measurement data of the acceleration sensor being less than a first acceleration threshold and detecting a reflected infrared signal, save the infrared signal to a fourth array; set a second counter, the second counter being used to indicate the storage position of the latest data in the fourth array; in response to the measurement data of the acceleration sensor being greater than the acceleration threshold, clear the data in the fourth array and reset the second counter; in response to the value of the second counter reaching the length of the fourth array, reset the second counter and store again from the starting position of the fourth array.

[0019] In one implementation, the information entropy features of the preset number of main frequencies may be determined based on a probability value of each main frequency in the preset number of main frequencies being within a preset interval.

[0020] According to a second aspect of an embodiment of the present disclosure, there is provided a wearable device wearing state detection device, comprising:

[0021] A detection unit is used to control the infrared sensor of the wearable device to emit an infrared signal and detect the reflected infrared signal; a determination unit is used to determine the power spectrum characteristics of the infrared signal detected by the infrared sensor in multiple different time windows; a processing unit is used to determine that the wearable device is in a wearing state in response to determining that the power spectrum characteristics meet the conditions; the conditions are determined based on the power spectrum characteristics of the preset physiological parameters determined after the infrared signal is reflected by the living body.

[0022] In one implementation, the determining unit determines the power spectrum characteristics of the infrared signal detected by the infrared sensor in a plurality of different time windows in the following manner:

[0023] Determine the power spectrum of the infrared signal detected by the infrared sensor in multiple different time windows; extract a preset number of main frequencies from the power spectrum of the multiple different time windows, the main frequency being the maximum peak value in which the difference between peaks in the power spectrum is less than a first threshold; determine the standard deviation characteristics of the preset number of main frequencies, and determine the information entropy characteristics of the preset number of main frequencies, and weight the standard deviation characteristics and the information entropy characteristics to obtain the power spectrum characteristics, the information entropy characteristics characterize the uncertainty of the preset number of main frequencies in determining the preset physiological parameters, and the standard deviation characteristics represent the degree of discreteness of the preset number of main frequencies.

[0024] In one implementation, the power spectrum feature is a power spectrum feature value greater than 0; the determining unit determines that the power spectrum feature meets the condition in the following manner, including:

[0025] In response to the power spectrum feature value being less than a first threshold, the correct value is saved in the first array, otherwise the erroneous value is saved in the first array; in response to the power spectrum feature value being greater than a second threshold, the correct value is saved in the second array, otherwise the erroneous value is saved in the second array; the first threshold is used to distinguish whether the power spectrum feature satisfies a stable condition, and the second threshold is used to distinguish whether the power spectrum feature satisfies an unstable condition; if the number of the first array is greater than the number of the second array, it is determined that the power spectrum feature meets the condition.

[0026] In one implementation, the determining unit extracts a preset number of main frequencies from the power spectra of the multiple different time windows in the following manner:

[0027] Based on the frequency domain information, a predefined number of spectrum peaks are obtained, and the spectrum peaks are frequency values ​​with amplitudes greater than those of adjacent points; in response to the first acquisition of a predefined number of spectrum peaks, a value closest to a default value of the main frequency is selected as the main frequency, and the default value of the main frequency is a frequency value of a preset value; in response to the non-first acquisition of a predefined number of spectrum peaks, a value closest to the previous main frequency is selected as the main frequency; the main frequency is saved in a third array, and a preset number of main frequencies are obtained; a first counter is set, and the first counter is used to indicate the storage position of the latest data in the third array; in response to the value of the first counter reaching the length of the third array, the first counter is cleared, and storage is performed again from the starting position of the third array.

[0028] In one embodiment, the determining unit obtains a predefined number of spectral peaks in the following manner:

[0029] In response to the amplitude corresponding to the current frequency being greater than the amplitude corresponding to the adjacent frequency and greater than the preset amplitude, the current frequency is set as a spectrum peak; in response to the existence of multiple continuous frequencies whose amplitudes are equal and greater than the amplitudes corresponding to the adjacent frequencies, the minimum frequency among the multiple continuous frequencies is set as the spectrum peak.

[0030] In one embodiment, the detection unit detects the reflected infrared signal in the following manner:

[0031] Acquire measurement data of the acceleration sensor; in response to the measurement data of the acceleration sensor being less than a first acceleration threshold and detecting a reflected infrared signal, save the infrared signal to a fourth array; set a second counter, the second counter being used to indicate the storage position of the latest data in the fourth array; in response to the measurement data of the acceleration sensor being greater than the acceleration threshold, clear the data in the fourth array and reset the second counter; in response to the value of the second counter reaching the length of the fourth array, reset the second counter and store again from the starting position of the fourth array.

[0032] In one implementation, the information entropy features of the preset number of main frequencies may be determined based on a probability value of each main frequency in the preset number of main frequencies being within a preset interval.

[0033] According to a third aspect of an embodiment of the present disclosure, there is provided a wearable device, including:

[0034] A processor; a memory for storing processor executable instructions; wherein the processor is configured to: execute the wearable device wearing state detection method described in the first aspect or any one of the embodiments of the first aspect.

[0035] According to a fourth aspect of an embodiment of the present disclosure, a storage medium is provided, in which instructions are stored. When the instructions in the storage medium are executed by a processor of a terminal, the terminal can perform the method described in the first aspect or any one of the implementations of the first aspect.

[0036] The technical solution provided by the embodiments of the present disclosure may include the following beneficial effects: by sending and detecting the returned infrared signal, the wearing status is judged based on the power spectrum characteristics of the infrared sensor, which can avoid the problem of sensitivity to the sampling rate, and can reduce the detection power consumption while obtaining high-precision wearing status detection results.

[0037] It is to be understood that the foregoing general description and the following detailed description are exemplary and explanatory only and are not restrictive of the present disclosure. BRIEF DESCRIPTION OF THE DRAWINGS

[0038] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.

[0039] Figure 1 The present invention is a flowchart of a method for detecting a wearing state of a wearable device according to an exemplary embodiment.

[0040] Figure 2 The figure is a flow chart of a method for detecting power spectrum characteristics of an infrared signal according to an exemplary embodiment.

[0041] Figure 3 The present invention is a flowchart of a method for determining whether a power spectrum feature meets a condition according to an exemplary embodiment.

[0042] Figure 4 The figure is a flow chart showing a method for extracting a main frequency according to an exemplary embodiment.

[0043] Figure 5 The figure is a flow chart showing a method for obtaining a predefined number of spectrum peaks according to an exemplary embodiment.

[0044] Figure 6 The figure is a flow chart showing a method for detecting a reflected infrared signal according to an exemplary embodiment.

[0045] Figure 7 The present invention is a flowchart of a method for detecting a wearing state of a wearable device according to an exemplary embodiment.

[0046] Figure 8 The present invention is a block diagram of a device for detecting a wearing state of a wearable device according to an exemplary embodiment.

[0047] Fig. 9The invention is a block diagram of an apparatus for detecting a wearing state of a wearable device according to an exemplary embodiment. DETAILED DESCRIPTION

[0048] Here, exemplary embodiments will be described in detail, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, unless otherwise indicated, the same numbers in different drawings represent the same or similar elements. The implementations described in the following exemplary embodiments do not represent all implementations consistent with the present disclosure.

[0049] In the accompanying drawings, the same or similar reference numerals throughout represent the same or similar elements or elements with the same or similar functions. The described embodiments are part of the embodiments of the present disclosure, rather than all of the embodiments. The embodiments described below with reference to the accompanying drawings are exemplary and are intended to be used to explain the present disclosure, and should not be construed as limitations on the present disclosure. Based on the embodiments in the present disclosure, all other embodiments obtained by ordinary technicians in the field without creative work are within the scope of protection of the present disclosure. The embodiments of the present disclosure are described in detail below in conjunction with the accompanying drawings.

[0050] The wearable device wearing state detection method provided by the embodiment of the present disclosure is applied to the application scenario of wearable device wearing detection. It is implemented in C language, compiled into a static link library by a PC device, and integrated into the wearable product firmware, which is closely related to hardware, driver, and firmware.

[0051] In the related art, there is a scheme for using multiple sensors (capacitive sensor, infrared sensor, acceleration sensor) to perform wearing detection on the detected data. For example, the wearable device includes an infrared proximity sensor and a control circuit, wherein: the control circuit is used to start the infrared proximity sensor when the acceleration sensor detects an insertion action; and when the infrared proximity sensor is in a proximity state, determine that the wearable device is in a wearing state.

[0052] However, the sampling rate of various sensors in the related art is not less than 25 Hz, and the power consumption of detection is high, which cannot meet the needs of long-term wearing detection. If a signal device with a sampling rate lower than 25 Hz is used for testing, the detection method in the related art cannot determine accurate wearing detection results.

[0053] In view of this, an embodiment of the present disclosure provides a method for detecting the wearing status of a wearable device. In the method for detecting the wearing status of a wearable device provided by the present disclosure, an infrared signal is sent by an infrared sensor, and an infrared signal reflected back by a body part of the wearer is received, and the power spectrum characteristics of the reflected infrared signal are extracted. When it is detected that the power spectrum characteristics meet the conditions, it is determined that the wearable device is in a wearing state.

[0054] Figure 1 is a flow chart of a method for detecting a wearing state of a wearable device according to an exemplary embodiment. Figure 1 As shown, the following steps are included.

[0055] In step S11, the infrared sensor of the wearable device is controlled to emit an infrared signal, and the reflected infrared signal is detected.

[0056] In the disclosed embodiment, the infrared signal emitted by the infrared sensor is infrared light of a specific wavelength. When the infrared light is irradiated onto the wearer's skin, part of the light will be absorbed by the capillaries on the surface of the skin, and the remaining light will be reflected back to the sensor. Therefore, the wavelength and intensity of the infrared signal light received by the infrared sensor can obtain the wearer's physiological signals, such as heart rate, blood oxygen saturation, etc.

[0057] In step S12, power spectrum characteristics of infrared signals detected by the infrared sensor in a plurality of different time windows are determined.

[0058] In the disclosed embodiment, infrared signals of multiple time windows can be acquired by means of a sliding window. For example, by setting the sliding window size to 4 seconds, the sliding step to 1 second, and the number of slides to 3, infrared signals corresponding to three time windows of 0-4 seconds, 1-5 seconds, and 2-6 seconds can be acquired.

[0059] In step S13, in response to determining that the power spectrum feature meets the condition, it is determined that the wearable device is in a wearing state.

[0060] In the disclosed embodiment, the condition is determined based on the power spectrum characteristics of the preset physiological parameters determined after the infrared signal is reflected by the living body.

[0061] In the disclosed embodiment, whether the wearable device is in a wearing state can be determined based on at least one power spectrum feature. It should be understood that using multiple power spectrum features to determine the wearing state can make the determination result more accurate and avoid misjudgment due to a single result.

[0062] In the disclosed embodiment, the main frequency in the power spectrum can be selected to extract characteristic values ​​that can reflect the degree of change of the main frequency from multiple main frequencies, and whether the wearable device is in a wearing state can be determined based on the multiple characteristic values.

[0063] Figure 2 is a flow chart of a method for detecting infrared signal power spectrum characteristics according to an exemplary embodiment. Figure 2 As shown, the following steps are included.

[0064] In step S21, the power spectra of infrared signals detected by the infrared sensor in a plurality of different time windows are determined.

[0065] In the disclosed embodiment, as the time window changes, the infrared sensor can receive multiple sets of power spectrum data of infrared signals in different time windows, wherein the power spectrum is a representation of the power signal in the frequency domain. In other words, the power spectrum is used to represent the change of signal power with frequency in a unit frequency band.

[0066] In the embodiment of the present disclosure, the infrared signal data received by the infrared sensor can be converted from time domain information to frequency domain information, wherein the frequency domain information of the infrared signal data is the power spectrum. The power spectrum of the external signal data can be obtained by conventional time-frequency domain conversion, such as Welch power spectrum, FFT, wavelet transform, etc. It should be understood that the embodiment of the present disclosure can also truncate the signal by setting a truncation function, such as a triangular window, a Hamming window, a Hanning window, a Gaussian window, etc., to reduce the leakage of spectrum energy.

[0067] In step S22, a preset number of main frequencies are extracted from the power spectra of a plurality of different time windows.

[0068] In the disclosed embodiment, the main frequency is the peak frequency in the power spectrum with the smallest corresponding amplitude difference from the default main frequency value or the main frequency of the power spectrum in the previous time window. For example, there are 3 peaks in the power spectrum of the current time window, 30kHz, 60kHz, and 90kHz. If there is a previous time window, the main frequency of its corresponding power spectrum is 80kHz, and the main frequency of the power spectrum of the current time window is 90kHz. By extracting a preset number of main frequencies from the power spectra of multiple different time windows, it is possible to extract the main frequency data in multiple time windows with the smallest change from the main frequency of the previous time window.

[0069] In step S23, the standard deviation characteristics of the preset number of main frequencies are determined, and the information entropy characteristics of the preset number of main frequencies are determined, and the standard deviation characteristics and the information entropy characteristics are weighted to obtain the power spectrum characteristics.

[0070] In the disclosed embodiment, the information entropy feature characterizes the uncertainty of the preset physiological parameter determined by the preset number of main frequencies, and the standard deviation feature represents the degree of discreteness of the preset number of main frequencies. It should be understood that other statistics that can measure the uncertainty and discreteness of the preset number of main frequencies can also be used to obtain the power spectrum feature, such as signal-to-noise ratio, range and variance.

[0071] In the disclosed embodiment, the power spectrum feature is obtained by linearly weighting the information entropy feature and the standard deviation feature, so that the power spectrum feature can represent the discrete features and uncertain features of a preset number of main frequencies.

[0072] In the embodiment of the present disclosure, after determining the power spectrum characteristics of a preset number of main frequencies, it can be determined whether the power spectrum characteristics meet the conditions through the first array and the second array.

[0073] Figure 3is a flow chart of a method for determining whether a power spectrum feature meets a condition according to an exemplary embodiment. Figure 3 As shown, the following steps are included.

[0074] In step S31, in response to the power spectrum eigenvalue being smaller than the first threshold, the correct value is stored in the first array, otherwise the wrong value is stored in the first array.

[0075] In the disclosed embodiment, the first threshold is used to distinguish whether the power spectrum feature satisfies the stability condition. For example, when it is detected that the power spectrum feature is less than the first threshold, "TURE" is saved to the first array, otherwise, "FALSE" is saved to the first array.

[0076] In step S32, in response to the power spectrum eigenvalue being greater than the second threshold, the correct value is stored in the second array, otherwise the wrong value is stored in the second array.

[0077] In the disclosed embodiment, the second threshold is used to distinguish whether the power spectrum feature satisfies the unstable condition. For example, when it is detected that the power spectrum feature is less than the first threshold, "FALSE" is saved to the second array, otherwise, "TURE" is saved to the first array. It should be understood that the value of the first threshold is less than or equal to the value of the second threshold, that is, the power spectrum feature does not exist in the case where it satisfies both the stable condition and the unstable condition.

[0078] In step S33, if the proportion of correct values ​​in the first array is greater than half and the proportion of correct values ​​in the second array is less than half, it is determined that the power spectrum feature meets the condition.

[0079] In the disclosed embodiment, whether the power spectrum feature meets the conditions is determined based on the proportion of correct values ​​in the first array and the second array. The number of elements contained in the first array and the second array may be different. For example, since it is relatively simple to determine whether the power spectrum feature is stable, the length of the first array may be set to 10, while it is relatively difficult to determine whether the power spectrum feature is unstable, the length of the second array may be set to 20.

[0080] Figure 4 is a flow chart showing a method for extracting a main frequency according to an exemplary embodiment. Figure 4 As shown, the following steps are included.

[0081] In step S41, a predefined number of spectrum peaks are obtained based on information in the power spectrum.

[0082] In the embodiment of the present disclosure, the spectrum peak is a frequency value whose amplitude is greater than that of the adjacent points. The spectrum peak can be saved by using a circular buffer to reduce the memory size required to save the spectrum peak.

[0083] In step S42, in response to obtaining a predefined number of spectrum peaks for the first time, a value closest to a default value of the main frequency is selected as the main frequency.

[0084] In the embodiment of the present disclosure, the default value of the main frequency is a preset frequency value. When a predefined number of spectrum peaks are obtained for the first time, the predefined number of spectrum peaks are compared with the default value of the main frequency to obtain the spectrum peak closest to the default value of the main frequency, and the frequency value of the spectrum peak is set as the main frequency of the frequency spectrum of the current time window.

[0085] In step S43, in response to obtaining a predefined number of spectrum peaks not for the first time, a value closest to the previous main frequency is selected as the main frequency.

[0086] In the embodiment of the present disclosure, when a predefined number of spectral peaks are obtained but not for the first time, that is, the main frequency of the power spectrum corresponding to the previous time window already exists, the predefined number of spectral peaks are compared with the main frequency of the power spectrum corresponding to the existing most recent time window, and the frequency of the spectral peak closest to the main frequency of the power spectrum corresponding to the existing most recent time window is set as the main frequency of the power spectrum corresponding to the current time window.

[0087] In step S44, the main frequencies are saved in a third array to obtain a preset number of main frequencies.

[0088] In the disclosed embodiment, the acquired main frequency is stored in a third array, wherein the third array may be a circular array, so as to reduce the extra power consumption caused by ordinary displacement.

[0089] In step S45, a first counter is set.

[0090] In the embodiment of the present disclosure, the first counter is used to indicate the storage location of the latest data in the third array. The initial value of the first counter is 0, and the value of the first counter is modified in response to storing data in the third array. By setting the first counter, it is helpful to realize the cyclic reading of the third array.

[0091] In step S46, in response to the value of the first counter reaching the length of the third array, the first counter is cleared and storage is performed again from the starting position of the third array.

[0092] In the embodiment of the present disclosure, when the third array is full, the first counter is cleared, which means that storage starts again from the starting position of the third array. The third array and the first counter are used to implement cyclic storage of the third array.

[0093] Figure 5 is a flow chart showing a method for obtaining a predefined number of spectrum peaks according to an exemplary embodiment. Figure 5 As shown, the following steps are included.

[0094] In step S51, in response to the amplitude corresponding to the current frequency being greater than the amplitude corresponding to the adjacent frequency and greater than a preset amplitude, the current frequency is set as a spectrum peak.

[0095] In the disclosed embodiment, the amplitude corresponding to the current frequency is greater than the amplitude corresponding to the adjacent frequency, that is, the "peak" in the power spectrum. If it is detected that the amplitude corresponding to the current frequency is greater than the amplitude corresponding to the adjacent frequency, it is detected whether the amplitude corresponding to the current frequency is greater than the preset amplitude. If it is greater than the preset amplitude, the current frequency is set to the spectrum peak and saved.

[0096] In the disclosed embodiment, the spectrum peaks can be stored in an array, and the spectrum peaks in the array are stored in the order of frequency. For example, when the current frequency is detected as a spectrum peak, it is saved in the peak array. Assuming that the peak array can store up to 4 spectrum peaks, when the peak array is full, the frequency value of the current spectrum peak is sorted with the frequency values ​​stored in the array, and the spectrum peak with the smallest frequency is discarded, and the remaining spectrum peaks are arranged in order of size, so that the array stores multiple spectrum peaks with the largest frequency in the current power spectrum.

[0097] In step S52, in response to the existence of a plurality of continuous frequencies having amplitudes that are equal to and greater than amplitudes corresponding to adjacent frequencies, the minimum frequency among the plurality of continuous frequencies is set as a spectrum peak.

[0098] In the embodiment of the present disclosure, when there are multiple continuous frequencies with amplitudes that are equal and greater than the amplitudes corresponding to adjacent frequencies, that is, when there is a "flat-top peak" phenomenon, the minimum frequency among the multiple continuous frequencies is set as the spectrum peak for storage. For example, if the current frequency amplitude is greater than the amplitude of the previous unit frequency, if multiple frequencies with equal amplitudes appear successively, the amplitudes of the subsequent frequencies will continue to be detected until a frequency with unequal amplitudes appears, and then it is determined whether the current frequency is a spectrum peak. Avoid saving multiple identical spectrum peaks, which will affect subsequent calculations.

[0099] In the disclosed embodiment, whether the received infrared data is usable can be determined by using the acceleration data acquired by the acceleration sensor.

[0100] Figure 6 is a flow chart showing a method for detecting a reflected infrared signal according to an exemplary embodiment. Figure 6 As shown, the following steps are included.

[0101] In step S61 , measurement data of the acceleration sensor is acquired.

[0102] In the disclosed embodiment, the measurement data of the acceleration sensor can be used to detect the acceleration information of the object, and the motion state of the object can be acquired based on the acceleration information.

[0103] In step S62 , in response to the measurement data of the acceleration sensor being less than the first acceleration threshold and the reflected infrared signal being detected, the infrared signal is saved in a fourth array.

[0104] In the embodiment of the present disclosure, the detected reflected infrared signal is saved in a fourth array, wherein the elements that may be included in the fourth array may be set as required, so as to facilitate the storage of the infrared signal.

[0105] In step S63, a second counter is set.

[0106] In the disclosed embodiment, the second counter is used to indicate the storage location of the latest data in the fourth array. The initial value of the second counter is 0. In response to new data being stored in the fourth array, the value of the second counter is changed.

[0107] In step S64, in response to the measurement data of the acceleration sensor being greater than the acceleration threshold, the data in the fourth array is cleared and the second counter is reset.

[0108] In the disclosed embodiment, the acceleration threshold may be a preset value used to measure whether the amplitude of the movement is too large. When it is detected that the measurement data of the acceleration sensor is greater than the acceleration threshold, it is determined that the current amplitude of the movement is too large, which will affect the power spectrum calculation of the normal signal and have a negative impact on the subsequent liveness detection. Therefore, the data in the fourth array is cleared, the second counter is reset, and the infrared signal is stored again.

[0109] In step S65, in response to the value of the second counter reaching the length of the fourth array, the second counter is cleared and storage is performed again from the starting position of the fourth array.

[0110] In the disclosed embodiment, when the value of the second counter reaches the length of the fourth array, it indicates that the fourth array is full, and the second counter is cleared, that is, data is stored from the starting position of the fourth array. This has the advantage of reducing storage space.

[0111] Figure 7 The present invention is a flowchart of a method for detecting a wearing state of a wearable device according to an exemplary embodiment.

[0112] In an exemplary embodiment, infrared data with a sampling rate of 5Hz is used, and the characteristics of human pulse information can be detected mainly by optical signals. Through extraction, combination and other methods, it is determined whether the user or the obstructing object is alive. Specifically, the three-axis acceleration and infrared data are acquired point by point, and then go through preprocessing, power spectrum, extraction of stable main frequency, main frequency stability characteristics and live judgment modules, and finally output the wearing status.

[0113] The preprocessing module mainly includes two steps, namely smoothing denoising and trend item removal.

[0114] In the smoothing and denoising process, after the acceleration data and infrared signal are found, smoothing and denoising are performed, the main function of which is to remove high-frequency noise and make the data waveform smoother. The filtering and denoising methods include but are not limited to finite impulse response (FIR) and infinite impulse response (IIR) low-pass filters, mean filters, etc.

[0115] After smoothing and denoising, trend items are removed to remove low-frequency noise in the acceleration data or infrared signals. For example, gravity acceleration information is removed from the acceleration data, and the value of the infrared signal reflected back by the skin is removed from the infrared signal.

[0116] In the power spectrum calculation module, there are mainly three key processes, namely, motion and stillness detection, infrared data cache circular buffer and power spectrum calculation.

[0117] In the process of motion detection, it mainly relies on the preprocessed acceleration signal, and judges according to the window of every 0.4s, which is divided into 4 levels: completely still, that is, there is no data with an amplitude exceeding the threshold 0 in the current window, which is set as feature 0; there is a slight vibration, or the mean difference between two adjacent windows exceeds the threshold 1, it is set as micro-motion feature 1; there is a small movement, or the movement amplitude in the current window exceeds the threshold 2, it is set as a small feature 2; finally, there is a large movement, or the movement amplitude in the current window exceeds the threshold 3, it is set as a large feature 3.

[0118] The motion features are classified according to the above levels. When the motion feature is less than or equal to feature 1, the subsequent power spectrum calculation can be performed. Otherwise, it is considered that the motion amplitude is large, which will affect the power spectrum calculation of the normal signal and easily have a negative impact on the subsequent liveness detection.

[0119] In the process of caching the infrared data in the circular buffer, the IR data output by the pre-processing module is cached. In order to reduce the extra power consumption of ordinary shifting, the circular buffer is used for updating. At the same time, the buffer is selectively stored and cleared according to the results of motion detection. For example, when there is a large movement, the cache is cleared. When there is a small or no movement, the data is stored in the buffer in order for subsequent calculations.

[0120] In the process of power spectrum calculation, the purpose is to convert the time domain IR signal to the frequency domain, so as to extract the frequency domain information better and extract more effective features. The calculation methods of frequency domain conversion include but are not limited to Welch power spectrum, FFT, wavelet transform, etc. At the same time, in order to reduce the spectrum energy leakage, different truncation functions are used to truncate the signal, that is, to add window functions. The types of window functions include but are not limited to triangular window, Hamming window, Hanning window, Gaussian window, etc.

[0121] In the stable main frequency extraction module, it is mainly divided into three processes, namely spectrum peak detection, effective characteristic sorting, and stable main frequency selection.

[0122] In the process of spectrum peak detection, the power spectrum data of each window IR data is continuously monitored according to the logic of peak detection. If the current frequency point is greater than the value of the adjacent point on the left, greater than the value of the adjacent point on the right, and greater than the peak threshold, the current point value is considered to be the peak value. Considering the case where the amplitudes corresponding to consecutive adjacent frequencies are equal, the current frequency point value is greater than the value of the adjacent point on the left. If multiple equal point values ​​appear continuously, the right adjacent point moves backward with the frequency until an unequal point value appears, and then judges whether the current frequency point value is the peak value.

[0123] During the validity sorting process, each time a valid peak point is detected, its frequency information idx is stored in the peak array. The peak array can store up to 4 peak positions. If the peak array is empty, it is directly stored as the first position point. If the peak array is not empty, the stored peak and the currently detected peak are compared. According to the logic of insertion sorting, the currently detected peak is stored in the corresponding position according to the relationship from large to small peaks.

[0124] In the process of selecting the stable main frequency, the stable main frequency is selected to ensure the stability of the calculated main frequency change. Assuming that the stable main frequency stab defaults to 1000Hz, the logic of selecting and updating is as follows: if it is the first window to select the main frequency, the default value is assigned; if it is not the first window to select the main frequency, according to the value of stab, the one closest to stab in the peak array is selected as the stable main frequency of the current window.

[0125] The stable main frequency is stored in the third array stable_arr, which is also stored in sequence according to the storage form of the circular buffer. Stable_arr can store up to 5 stable main frequencies, which are used in subsequent modules to calculate the changing characteristics of the stable main frequency.

[0126] In the module for obtaining the main frequency stability feature, the main frequency stability feature consists of two sub-features, namely the standard deviation of the continuous stable main frequency array and the information entropy, where the entropy is calculated based on the probability value of each main frequency in a preset number of main frequencies within a preset range.

[0127] Calculate the standard deviation of the stable main frequency array stable_arr to characterize the main frequency stability characteristics of several consecutive windows, recorded as the standard deviation characteristic

[0128] Entropy can be understood as the degree of disorder or chaos of a system. Information entropy is used in this exemplary embodiment, and the calculation method of information entropy is:

[0129]

[0130] Among them, pi represents the probability of a certain value. Generally, the value range is [0,1].

[0131] Traverse the stable main frequency values ​​of stable_arr and count the number of heart rate intervals. The heart rate intervals can be distributed as [0,50], [50,70], [70,90], [90,110]..., or as [0,40], [40,60], [60,80], [80,100]... The main purpose is to reduce the instability of the main frequency change according to the range rule.

[0132] Count the number of heart rate values ​​in each interval, and then calculate the entropy value corresponding to the current stable_arr according to the information entropy calculation formula, which is recorded as the information entropy feature.

[0133] The standard deviation feature and information entropy feature are linearly weighted to obtain the power spectrum feature, which is used to characterize the instability of the main frequency change. The value is generally greater than or equal to 0. The smaller the combined feature, the gentler the main frequency change and the stable distribution; the larger the combined feature, the more drastic the main frequency change and the unstable distribution.

[0134] In the living body judgment module, the change of continuous main frequency is judged according to the power spectrum characteristics, and the stable results are circulated in the first array. If the combined characteristics are less than the stable threshold 1, TRUE is stored in the first array, otherwise FALSE is stored; the unstable results are circulated in the second array. If the combined characteristics are greater than the unstable threshold 2, TRUE is stored in the second array, otherwise FALSE is stored.

[0135] The first array of stable result loop and the second array of unstable result loop respectively represent the results that meet the (in)stability threshold, and the array lengths are set to 10 and 20 respectively, which are used to determine the stability distribution under continuous time length.

[0136] If the proportion of TRUE in the first array of the loop reaches 50% or more, it is considered that the currently returned IR data is more likely to represent a living body; conversely, if the proportion of TRUE in the second array of the loop reaches 50% or more, it is considered that the currently returned IR data is more likely to represent a non-living body.

[0137] Finally, the current wearing status is confirmed based on the status returned by the continuous window decision, and the detection process ends.

[0138] Based on the same concept, an embodiment of the present disclosure also provides a wearing status detection device for a wearable device.

[0139] It is understandable that in order to realize the above functions, the wearable device wearing state detection device provided by the embodiment of the present disclosure includes hardware structures and / or software modules corresponding to the execution of each function. In combination with the units and algorithm steps of each example disclosed in the embodiment of the present disclosure, the embodiment of the present disclosure can be implemented in the form of hardware or a combination of hardware and computer software. Whether a function is executed in the form of hardware or computer software driving hardware depends on the specific application and design constraints of the technical solution. Those skilled in the art may use different methods to implement the described functions for each specific application, but such implementation should not be considered to exceed the scope of the technical solution of the embodiment of the present disclosure.

[0140] In the disclosed embodiment, by sending and detecting the returned infrared signal, the wearing status is judged based on the power spectrum characteristics of the infrared sensor. A 5Hz infrared signal can be used for wearing detection, avoiding the problem of sensitivity to the sampling rate, and reducing the detection power consumption while obtaining high-precision wearing detection results.

[0141] Figure 8 1 is a block diagram of a wearable device wearing state detection apparatus 100 according to an exemplary embodiment. Figure 8 The device includes a detection unit 101, a determination unit 102 and a processing unit 103.

[0142] The detection unit 101 is used to control the infrared sensor of the wearable device to emit infrared signals and detect the reflected infrared signals.

[0143] The determination unit 102 is used to determine the power spectrum characteristics of the infrared signal detected by the infrared sensor in a plurality of different time windows.

[0144] The processing unit 103 is configured to determine that the wearable device is in a wearing state in response to determining that the power spectrum feature meets the condition. In one embodiment, the condition is determined based on the power spectrum feature of a preset physiological parameter determined after the infrared signal is reflected by the living body.

[0145] In one embodiment, the determining unit 102 determines the power spectrum characteristics of the infrared signal detected by the infrared sensor in a plurality of different time windows in the following manner:

[0146] Determine the power spectrum of the infrared signal detected by the infrared sensor in multiple different time windows; extract a preset number of main frequencies from the power spectrum of multiple different time windows, the main frequency being the maximum peak value in which the difference between peaks in the power spectrum is less than a first threshold; determine the standard deviation characteristics of the preset number of main frequencies, and determine the information entropy characteristics of the preset number of main frequencies, and weight the standard deviation characteristics and the information entropy characteristics to obtain the power spectrum characteristics, the information entropy characteristics characterize the uncertainty of the preset number of main frequencies in determining the preset physiological parameters, and the standard deviation characteristics represent the degree of discreteness of the preset number of main frequencies.

[0147] In one implementation, the power spectrum feature is a power spectrum feature value greater than 0; the determination unit 102 determines that the power spectrum feature meets the condition in the following manner, including:

[0148] In response to a power spectrum feature value being less than a first threshold, the correct value is saved in a first array, otherwise an erroneous value is saved in the first array; in response to a power spectrum feature value being greater than a second threshold, the correct value is saved in a second array, otherwise an erroneous value is saved in the second array; the first threshold is used to distinguish whether the power spectrum feature satisfies a stable condition, and the second threshold is used to distinguish whether the power spectrum feature satisfies an unstable condition; if the number of the first array is greater than the number of the second array, it is determined that the power spectrum feature meets the condition.

[0149] In one implementation, the determination unit 102 extracts a preset number of main frequencies from the power spectra of a plurality of different time windows in the following manner:

[0150] Based on the frequency domain information, a predefined number of spectrum peaks are obtained, and the spectrum peak is a frequency value with an amplitude greater than that of adjacent points; in response to the first acquisition of the predefined number of spectrum peaks, the value closest to the default value of the main frequency is selected as the main frequency, and the default value of the main frequency is a frequency value of a preset value; in response to the non-first acquisition of the predefined number of spectrum peaks, the value closest to the previous main frequency is selected as the main frequency; the main frequency is saved in a third array, and a preset number of main frequencies are obtained; a first counter is set, and the first counter is used to indicate the storage position of the latest data in the third array; in response to the value of the first counter reaching the length of the third array, the first counter is cleared, and storage is performed again from the starting position of the third array.

[0151] In one implementation, the determination unit 102 obtains a predefined number of spectrum peaks in the following manner:

[0152] In response to the amplitude corresponding to the current frequency being greater than the amplitude corresponding to the adjacent frequency and greater than the preset amplitude, the current frequency is set as the spectrum peak; in response to the existence of multiple continuous frequencies whose amplitudes are equal and greater than the amplitudes corresponding to the adjacent frequencies, the minimum frequency among the multiple continuous frequencies is set as the spectrum peak.

[0153] In one implementation, the detection unit 101 detects the reflected infrared signal in the following manner:

[0154] Acquire measurement data of the acceleration sensor; in response to the measurement data of the acceleration sensor being less than a first acceleration threshold and detecting a reflected infrared signal, save the infrared signal to a fourth array; set a second counter, the second counter being used to indicate the storage position of the latest data in the fourth array; in response to the measurement data of the acceleration sensor being greater than the acceleration threshold, clear the data in the fourth array and reset the second counter; in response to the value of the second counter reaching the length of the fourth array, reset the second counter and store again from the starting position of the fourth array.

[0155] In one implementation, the information entropy features of a preset number of main frequencies may be determined based on a probability value of each main frequency in the preset number of main frequencies being within a preset interval.

[0156] Regarding the device in the above embodiment, the specific manner in which each module performs operations has been described in detail in the embodiment of the method, and will not be elaborated here.

[0157] Fig. 9 1 is a block diagram of an apparatus 200 for detecting the wearing state of a wearable device according to an exemplary embodiment. For example, the apparatus 200 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, etc.

[0158] Reference Fig. 9 , the device 200 may include one or more of the following components: a processing component 202 , a memory 204 , a power component 206 , a multimedia component 208 , an audio component 210 , an input / output (I / O) interface 212 , a sensor component 214 , and a communication component 216 .

[0159] The processing component 202 generally controls the overall operation of the device 200, such as operations associated with display, phone calls, data communications, camera operations, and recording operations. The processing component 202 may include one or more processors 220 to execute instructions to perform all or part of the steps of the above-described method. In addition, the processing component 202 may include one or more modules to facilitate interaction between the processing component 202 and other components. For example, the processing component 202 may include a multimedia module to facilitate interaction between the multimedia component 208 and the processing component 202.

[0160] The memory 204 is configured to store various types of data to support operations on the device 200. Examples of such data include instructions for any application or method operating on the device 200, contact data, phone book data, messages, pictures, videos, etc. The memory 204 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.

[0161] The power component 206 provides power to the various components of the device 200. The power component 206 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for the device 200.

[0162] The multimedia component 208 includes a screen that provides an output interface between the device 200 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touch, slide, and gestures on the touch panel. The touch sensor may not only sense the boundaries of the touch or slide action, but also detect the duration and pressure associated with the touch or slide operation. In some embodiments, the multimedia component 208 includes a front camera and / or a rear camera. When the device 200 is in an operating mode, such as a shooting mode or a video mode, the front camera and / or the rear camera may receive external multimedia data. Each front camera and rear camera may be a fixed optical lens system or have a focal length and optical zoom capability.

[0163] The audio component 210 is configured to output and / or input audio signals. For example, the audio component 210 includes a microphone (MIC), and when the device 200 is in an operation mode, such as a call mode, a recording mode, and a speech recognition mode, the microphone is configured to receive an external audio signal. The received audio signal can be further stored in the memory 204 or sent via the communication component 216. In some embodiments, the audio component 210 also includes a speaker for outputting audio signals.

[0164] I / O interface 212 provides an interface between processing component 202 and peripheral interface modules, such as keyboards, click wheels, buttons, etc. These buttons may include but are not limited to: a home button, a volume button, a start button, and a lock button.

[0165] The sensor assembly 214 includes one or more sensors for providing various aspects of the status assessment of the device 200. For example, the sensor assembly 214 can detect the open / closed state of the device 200, the relative positioning of components, such as the display and keypad of the device 200, the sensor assembly 214 can also detect the position change of the device 200 or a component of the device 200, the presence or absence of user contact with the device 200, the orientation or acceleration / deceleration of the device 200 and the temperature change of the device 200. The sensor assembly 214 can include a proximity sensor configured to detect the presence of a nearby object without any physical contact. The sensor assembly 214 can also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor assembly 214 can also include an accelerometer, a gyroscope sensor, a magnetic sensor, a pressure sensor or a temperature sensor.

[0166] The communication component 216 is configured to facilitate wired or wireless communication between the device 200 and other devices. The device 200 can access a wireless network based on a communication standard, such as WiFi, 2G or 3G, or a combination thereof. In an exemplary embodiment, the communication component 216 receives a broadcast signal or broadcast-related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 216 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module can be implemented based on radio frequency identification (RFID) technology, infrared data association (IrDA) technology, ultra-wideband (UWB) technology, Bluetooth (BT) technology and other technologies.

[0167] In an exemplary embodiment, the apparatus 200 may be implemented by one or more application-specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable gate arrays (FPGAs), controllers, microcontrollers, microprocessors or other electronic components to perform the above method.

[0168] In an exemplary embodiment, a non-transitory computer-readable storage medium including instructions is also provided, such as a memory 204 including instructions, and the instructions can be executed by the processor 220 of the device 200 to perform the above method. For example, the non-transitory computer-readable storage medium can be a ROM, a random access memory (RAM), a CD-ROM, a magnetic tape, a floppy disk, an optical data storage device, etc.

[0169] It is to be understood that in the present disclosure, "plurality" refers to two or more than two, and other quantifiers are similar. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. The character " / " generally indicates that the associated objects before and after are in an "or" relationship. The singular forms "a", "the" and "the" are also intended to include plural forms, unless the context clearly indicates other meanings.

[0170] It is further understood that the terms "first", "second", etc. are used to describe various information, but such information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other, and do not indicate a specific order or degree of importance. In fact, the expressions "first", "second", etc. can be used interchangeably. For example, without departing from the scope of the present disclosure, the first information can also be referred to as the second information, and similarly, the second information can also be referred to as the first information.

[0171] It can be further understood that, unless otherwise specified, “connection” includes a direct connection without other components between the two, and also includes an indirect connection with other components between the two.

[0172] It is further understood that, although the operations are described in a specific order in the drawings in the embodiments of the present disclosure, it should not be understood as requiring the operations to be performed in the specific order shown or in a serial order, or requiring the execution of all the operations shown to obtain the desired results. In certain environments, multitasking and parallel processing may be advantageous.

[0173] Those skilled in the art will readily appreciate other embodiments of the present disclosure after considering the specification and practicing the invention disclosed herein. This application is intended to cover any modifications, uses or adaptations of the present disclosure, which follow the general principles of the present disclosure and include common knowledge or customary technical means in the art that are not disclosed in the present disclosure.

[0174] It should be understood that the present disclosure is not limited to the precise structures that have been described above and shown in the drawings, and that various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the scope of the appended claims.

Claims

1. A method for detecting a wearing state of a wearable device, characterized in that: include: Control the infrared sensor of the wearable device to emit infrared signals and detect the reflected infrared signals; Determining power spectrum characteristics of infrared signals detected by the infrared sensor in a plurality of different time windows; In response to determining that the power spectrum feature meets a condition, determining that the wearable device is in a wearing state; The condition is determined based on the power spectrum characteristics of the preset physiological parameters determined after the infrared signal is reflected by the living body.

2. The method according to claim 1, characterized in that The step of determining the power spectrum characteristics of the infrared signal detected by the infrared sensor in a plurality of different time windows comprises: Determining a power spectrum of an infrared signal detected by the infrared sensor in a plurality of different time windows; Extracting a preset number of main frequencies from the power spectra of the multiple different time windows, the main frequency being a peak frequency in the power spectrum having the smallest corresponding amplitude difference with a main frequency default value or a main frequency of the power spectrum in the previous time window; Determine the standard deviation characteristics of the preset number of main frequencies, and determine the information entropy characteristics of the preset number of main frequencies, and weight the standard deviation characteristics and the information entropy characteristics to obtain the power spectrum characteristics, the information entropy characteristics characterize the uncertainty of the preset number of main frequencies in determining the preset physiological parameters, and the standard deviation characteristics represent the degree of discreteness of the preset number of main frequencies.

3. The method according to claim 2, characterized in that The power spectrum feature is a power spectrum feature value greater than 0; The determining that the power spectrum feature meets a condition includes: In response to the power spectrum characteristic value being less than a first threshold, storing a correct value in the first array, otherwise storing an incorrect value in the first array; In response to the power spectrum characteristic value being greater than a second threshold, storing a correct value in the second array, otherwise storing an incorrect value in the second array; The first threshold is used to distinguish whether the power spectrum feature meets the stable condition, and the second threshold is used to distinguish whether the power spectrum feature meets the unstable condition; If the proportion of correct values ​​in the first array is greater than half and the proportion of correct values ​​in the second array is less than half, it is determined that the power spectrum feature meets the condition.

4. The method according to claim 2 or 3, characterized in that: The extracting a preset number of main frequencies from the power spectra of the multiple different time windows includes: Based on the information in the power spectrum, a predefined number of spectrum peaks are obtained, wherein the spectrum peaks are frequency values ​​having amplitudes greater than those of adjacent points; In response to obtaining a predefined number of spectrum peaks for the first time, selecting a value closest to a default value of a main frequency as the main frequency, wherein the default value of the main frequency is a preset frequency value; In response to obtaining a predefined number of spectrum peaks not for the first time, selecting a value closest to the previous main frequency as the main frequency; The main frequencies are stored in a third array to obtain a preset number of main frequencies; Setting a first counter, wherein the first counter is used to indicate the storage position of the latest data in the third array; In response to the value of the first counter reaching the length of the third array, the first counter is cleared and storage is performed again from the starting position of the third array.

5. The method according to claim 4, characterized in that The obtaining of a predefined number of spectral peaks comprises: In response to an amplitude corresponding to a current frequency being greater than an amplitude corresponding to an adjacent frequency and greater than a preset amplitude, setting the current frequency as a spectrum peak; In response to the existence of a plurality of continuous frequencies corresponding to amplitudes that are equal to and greater than amplitudes corresponding to adjacent frequencies, a minimum frequency among the plurality of continuous frequencies is set as a spectrum peak.

6. The method according to claim 1, characterized in that The detecting of the reflected infrared signal comprises: Get the measurement data of the acceleration sensor; In response to the measurement data of the acceleration sensor being less than the first acceleration threshold and the reflected infrared signal being detected, the infrared signal is stored in a fourth array; Setting a second counter, wherein the second counter is used to indicate the storage position of the latest data in the fourth array; In response to the measurement data of the acceleration sensor being greater than the acceleration threshold, clearing the data in the fourth array and clearing the second counter; In response to the value of the second counter reaching the length of the fourth array, the second counter is cleared and storage is performed again from the starting position of the fourth array.

7. The method according to claim 2, characterized in that The information entropy features of the preset number of main frequencies may be determined based on a probability value of each main frequency in the preset number of main frequencies being within a preset interval.

8. A wearable device wearing status detection device, characterized in that: include: A detection unit, used to control the infrared sensor of the wearable device to emit infrared signals and detect the reflected infrared signals; A determination unit, used to determine power spectrum characteristics of infrared signals detected by the infrared sensor in a plurality of different time windows; a processing unit, configured to determine that the wearable device is in a wearing state in response to determining that the power spectrum feature meets a condition; The condition is determined based on the power spectrum characteristics of the preset physiological parameters determined after the infrared signal is reflected by the living body.

9. A wearable device, characterized in that: include: processor; a memory for storing processor-executable instructions; The processor is configured to: execute the method described in any one of claims 1 to 7.

10. A storage medium, characterized in that: The storage medium stores instructions, and when the instructions in the storage medium are executed by a processor of the terminal, the terminal is enabled to execute the method according to any one of claims 1 to 7.

Citation Information

Cited By

  • Phototherapy equipment control method and system based on wearing state, terminal and medium

    CN121197682A