Earphone detection adjustment method and device, ear clamping type earphone and storage medium
By setting the LED light source and photodiode in the ear clip headphones, and adjusting their fit degree with the motor, combining historical and current signal-to-noise ratio for motor adjustment, the problem of short battery life and poor accuracy of the health detection of ear clip headphones is solved, achieving higher signal-to-noise ratio and longer battery life.
Patent Information
- Application Number
- CN202311531385.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-11-16
- Publication Date
- 2025-05-16
AI Technical Summary
In health testing, the ear clip earphones have problems such as short battery life and poor detection accuracy. The main reason is that the LED light sources and photodiodes cannot effectively receive light signals, and the signal-to-noise ratio is reduced.
By setting the LED light source and photodiode in the clamped earphones, and adjusting the fit between the LED light source and photodiode and the user's ears with the motor, forming a transmissive PPG detection, combining the historical and current signal-to-noise ratio for motor adjustment, finding the optimal signal-to-noise ratio.
It effectively improves the signal-to-noise ratio of PPG signals, extends the battery life of the headphones, and enhances the accuracy of health detection.
Smart Images

Figure CN120018005A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of earphone technology, and in particular to an earphone detection and adjustment method, an earphone detection and adjustment device, an earphone clip and a storage medium. Background Art
[0002] Headphones are commonly used accessories for portable terminal devices such as mobile phones and tablets. Due to the portability of headphones, many headphones have also added health detection functions, which can detect the user's heart rate, blood oxygen and other physiological indicators in real time to provide feedback to the user on the current health status. Generally, headphones mainly use PPG (Photoplethysmography) to detect heart rate and blood oxygen, that is, using LED light sources and photodiodes to detect the attenuated light reflected and absorbed by human blood and tissues, thereby recording the changes in blood vessel volume during the cardiac cycle, and then determining physiological indicators such as heart rate and blood oxygen.
[0003] Wearing in-ear headphones and semi-in-ear headphones for a long time will make people feel uncomfortable such as ear canal swelling, stuffiness, etc., and will affect the human ear's hearing to a certain extent. Therefore, clip-on headphones, which adopt the most natural listening method, are becoming more and more popular among consumers.
[0004] When the clip-on earphones are used for health detection in the above manner, the inventors found in actual applications that due to the different thickness and contours of different people's ears, the photodiodes behind the ears of the clip-on earphones cannot receive most of the light signals from the LED light source, and the PPG signal strength becomes low. It is necessary to increase the power of the LED light source to compensate, which will greatly reduce the battery life of the earphones. At the same time, due to the different shapes of people's auricles, there is a problem of light leakage after the user wears it, thereby introducing ambient light interference, further reducing the signal-to-noise ratio of the PPG signal, and thus making the accuracy of health detection poor. Summary of the invention
[0005] The present application provides an earphone detection adjustment method, device, earphones and storage medium, which solve the problems of poor battery life and poor accuracy of health detection of earphones in related technologies. The present solution can use LED light sources and photodiodes to form transmissive PPG detection, and effectively adjust the fit between the LED light source and the photodiode and the user's ear, reduce ambient light interference, better improve the signal-to-noise ratio of the PPG signal, and make the accuracy of health detection higher.
[0006] In a first aspect, the present application provides an earphone detection and adjustment method, which is applied to an earphone, the earphone is communicatively connected to a terminal device, a first end of the earphone is provided with an LED light source, a second end of the earphone is provided with a photodiode, and the earphone further includes a motor for controlling the rotation of one end of the earphone, so that the LED light source and the photodiode are respectively located on both sides of the user's ear, and the earphone detection and adjustment method includes:
[0007] In response to a received start signal sent by the terminal device, determining whether the clip-on earphone is in a wearing state;
[0008] When it is determined that the ear clip earphone is in a wearing state, query whether there is a historical signal-to-noise ratio;
[0009] If there is a historical signal-to-noise ratio, obtain the current signal-to-noise ratio and determine whether the current signal-to-noise ratio is less than the historical signal-to-noise ratio;
[0010] If the current signal-to-noise ratio is less than the historical signal-to-noise ratio or there is no historical signal-to-noise ratio, the motor is adjusted based on a preset motor adjustment strategy to determine the optimal signal-to-noise ratio and enable the health detection function.
[0011] In a second aspect, the present application further provides an earphone detection and adjustment device, which is applied to an earphone, the earphone is communicatively connected to a terminal device, a first end of the earphone is provided with an LED light source, a second end of the earphone is provided with a photodiode, and the earphone further includes a motor for controlling the rotation of one end of the earphone, so that the LED light source and the photodiode are respectively located on both sides of the user's ear, and the earphone detection and adjustment device includes:
[0012] A wearing detection module, configured to determine whether the clip-on earphone is in a wearing state in response to a received start signal sent by the terminal device;
[0013] A history query module, configured to query whether there is a historical signal-to-noise ratio when determining that the clip-on earphone is in a wearing state;
[0014] A record comparison module is configured to obtain a current signal-to-noise ratio and determine whether the current signal-to-noise ratio is less than the historical signal-to-noise ratio if there is a historical signal-to-noise ratio;
[0015] The motor regulation module is configured to regulate the motor based on a preset motor regulation strategy to determine the optimal signal-to-noise ratio and enable a health detection function if the current signal-to-noise ratio is less than the historical signal-to-noise ratio or there is no historical signal-to-noise ratio.
[0016] In a third aspect, the present application further provides an ear-clip headphone, comprising:
[0017] one or more processors;
[0018] The storage device is used to store one or more programs. When the one or more programs are executed by one or more processors, the one or more processors implement the earphone detection and adjustment method provided in the above embodiment.
[0019] In a fourth aspect, the present application further provides a storage medium, which stores computer executable instructions, and the computer executable instructions are used to execute the headphone detection and adjustment method provided in the above embodiment when executed by a processor.
[0020] The clip-on earphones of the present application can use LED light sources and photodiodes to form transmissive PPG detection, and combine the historical signal-to-noise ratio with the current signal-to-noise ratio to determine whether to adjust the motor. When the motor needs to be adjusted, the optimal signal-to-noise ratio is found and the degree of fit between the LED light source and the photodiode and the user's ear is adjusted, so that the LED light source and the photodiode are more closely fitted to the user's ear, while the power of the LED light source can be effectively reduced, which helps to extend the battery life of the earphones. In addition, it can effectively reduce ambient light interference, better improve the signal-to-noise ratio of the PPG signal, and make the accuracy of health detection higher. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] Figure 1 A schematic diagram of the steps of a headphone detection and adjustment method provided in an embodiment of the present application;
[0022] Figure 2 A schematic diagram of the steps for adjusting a motor provided in an embodiment of the present application;
[0023] Figure 3 A schematic diagram of the steps of an earphone detection and adjustment device provided in an embodiment of the present application;
[0024] Figure 4 A schematic structural diagram of an ear-clip headset provided in one embodiment of the present application. DETAILED DESCRIPTION
[0025] The embodiments of the present application are further described in detail below in conjunction with the accompanying drawings and examples. It is to be understood that the specific embodiments described herein are only used to explain the embodiments of the present application, rather than to limit the embodiments of the present application. It should also be noted that, for ease of description, only the parts related to the embodiments of the present application rather than all structures are shown in the accompanying drawings, and those skilled in the art should be able to think of it after reading the specification of this application that as long as the technical features do not contradict each other, any combination of the technical features can constitute an optional implementation method.
[0026] The terms "first", "second", etc. in the specification and claims of the present application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than those illustrated or described here, and the objects distinguished by "first", "second", etc. are generally a class, and the number of objects is not limited. For example, the first object can be one or more. In addition, "and / or" in the specification and claims represents at least one of the connected objects, and the character " / " generally represents that the objects associated with each other are in an "or" relationship. In the description of the present application, "multiple" means two or more, and "several" means one or more.
[0027] The headset mainly uses PPG (Photoplethysmography) to detect heart rate and blood oxygen. When light passes through the skin tissue and then reflects to the photosensor, the light is attenuated to a certain extent. When there is no significant movement in the measurement area, the absorption of light by muscles, bones, veins and other connecting tissues is basically unchanged, but blood is different. Since there is blood flowing in the arteries, the absorption of light naturally changes. When the optical signal is converted into an electrical signal, the electrical signal obtained can be divided into a DC signal and an AC signal because the absorption of light by the artery changes while the absorption of light by other tissues remains basically unchanged. Therefore, extracting the AC signal can reflect the characteristics of blood flow.
[0028] In actual applications, it was found that due to the different thickness and contours of ears of different people, the photodiode acting as a photosensor behind the ear of the clip-on earphones cannot receive most of the light signals from the LED light source, resulting in lower PPG signal strength. At the same time, due to the different shapes of people's auricles, there is a problem of light leakage after the user wears them, thereby introducing ambient light interference, further reducing the signal-to-noise ratio of the PPG signal, and thus greatly reducing the battery life of the earphones and the accuracy of their health detection is also poor.
[0029] To this end, the present application provides an earphone detection and adjustment method, which is applied to a clip-on earphone. And the clip-on earphone provided by the present solution is communicatively connected to a terminal device, for example, by wireless means such as Bluetooth, infrared, or by wired means. An LED light source is provided at the first end of the clip-on earphone, and a photodiode is provided at the second end of the clip-on earphone. The clip-on earphone also includes a motor for controlling the rotation of one end of the clip-on earphone, so that the LED light source and the photodiode are respectively located on both sides of the user's ear. It can be understood that the above-mentioned clip-on earphone can clamp the two ends of the clip-on earphone on the user's ears through the motor, and make the LED light source and the photodiode respectively located at the two ends fit the user's ears more closely, reduce the entry of ambient light, and form a transmissive PPG detection scheme.
[0030] It should be noted that the transmission PPG principle is similar to the above-mentioned reflective PPG principle, but the signal intensity of the light signal received by the transmission method is greater, which helps to improve the signal-to-noise ratio of the PPG signal.
[0031] Figure 1 This is a schematic diagram of the steps of the headphone detection and adjustment method provided in an embodiment of the present application. The headphone detection and adjustment method of this solution can be applied to the above-mentioned clip-on headphones to improve the signal-to-noise ratio of the PPG signal. The specific steps are as follows:
[0032] Step S110: In response to a received start signal sent by the terminal device, determine whether the earphone is in a wearing state.
[0033] It is understandable that the ear clip earphone is connected to the terminal device for communication, and it starts the earphone detection and adjustment according to the start signal sent by the terminal device, for example, the user controls the ear clip earphone to start the earphone detection and adjustment through the software application on the mobile phone. Of course, the ear clip earphone can also feedback corresponding data to the terminal device.
[0034] After receiving the start signal sent by the terminal device, the ear clip earphone needs to detect its own state to determine whether it is in the wearing state, that is, to determine whether the user is wearing the ear clip earphone. For example, in one embodiment, the ear clip earphone also includes an infrared sensor or a capacitive sensor for detecting the wearing state. It can be understood that the infrared sensor is a sensor that can detect the intensity of infrared radiation. Therefore, when the user wears the ear clip earphone, the infrared sensor can detect the change in the intensity of infrared radiation caused by the user, and the ear clip earphone can obtain corresponding data, that is, the first detection data, through the infrared sensor.
[0035] The capacitive sensor is a sensor that can convert pressure changes into capacitance changes. Therefore, when the user wears the clip-on earphone, the capacitive sensor can convert the pressure during wearing into capacitance changes, and the clip-on earphone can obtain the corresponding data through the capacitive sensor, that is, the first detection data.
[0036] A corresponding first preset threshold is also set corresponding to the first detection data. For example, a corresponding threshold is set for the detection data of the infrared sensor, and the threshold is the infrared radiation intensity value when no one is wearing it; of course, a corresponding threshold is also set for the detection data of the capacitive sensor, and the threshold is the capacitance when no one is wearing it.
[0037] Exemplarily, when the detection data of the corresponding infrared sensor is greater than the corresponding threshold value, it is determined that the ear clip earphone is in the wearing state. In addition, generally, the greater the pressure on the capacitive sensor, the smaller the capacitance thereof. Correspondingly, when the detection data of the corresponding capacitive sensor is less than the corresponding threshold value, it is determined that the ear clip earphone is in the wearing state.
[0038] Step S120: When it is determined that the ear clip earphone is in the wearing state, query whether there is a historical signal-to-noise ratio.
[0039] When the clip-on earphones are worn, it is necessary to further query whether there is a historical signal-to-noise ratio. It can be understood that the historical signal-to-noise ratio is the signal-to-noise ratio of the PPG signal when the user or the previous wearer uses the clip-on earphones for health checks. The clip-on earphones record it so that the earphones can be adjusted in time when the user or the wearer uses it again to meet the signal-to-noise ratio requirements.
[0040] Furthermore, since the thickness and contour of ears of different people are different, and even the thickness of the same ear in different positions is different, the historical signal-to-noise ratio can be used to compare and determine whether the user's wearing position is the same as the historical wearing position, or to determine whether the wearer and the historical wearer are the same person.
[0041] In addition, it is also conceivable that the ear clip earphones are communicatively connected to the terminal device, and the historical signal-to-noise ratio can be stored in the terminal device. When the ear clip earphones need to query whether there is a historical signal-to-noise ratio, they can initiate a query request to the terminal device to determine whether the terminal device stores the historical signal-to-noise ratio.
[0042] Step S130: If there is a historical signal-to-noise ratio, obtain the current signal-to-noise ratio and determine whether the current signal-to-noise ratio is less than the historical signal-to-noise ratio.
[0043] The current signal-to-noise ratio is the signal-to-noise ratio obtained by the clip-on earphones when they are worn. Therefore, when the historical signal-to-noise ratio is stored, the current signal-to-noise ratio is compared with the historical signal-to-noise ratio to determine whether the current signal-to-noise ratio is less than the historical signal-to-noise ratio. It is understandable that the larger the signal-to-noise ratio, the higher the accuracy of the health detection. Therefore, when the current signal-to-noise ratio is greater than or equal to the historical signal-to-noise ratio, the clip-on earphones can determine that the current signal-to-noise ratio meets the detection requirements without further adjustment.
[0044] It can be imagined that the calculation of the signal-to-noise ratio can be calculated by the processor of the clip-on earphone itself, or the clip-on earphone can send the PPG signal to the terminal device, and the terminal device calculates and requires the terminal device to feedback the calculated signal-to-noise ratio.
[0045] Step S140: If the current signal-to-noise ratio is less than the historical signal-to-noise ratio or there is no historical signal-to-noise ratio, the motor is adjusted based on a preset motor adjustment strategy to determine the optimal signal-to-noise ratio and enable a health detection function.
[0046] For any of the situations where the current signal-to-noise ratio is less than the historical signal-to-noise ratio or there is no historical signal-to-noise ratio, the clip-on earphones need to adjust the motor, such as using a preset motor adjustment strategy, to determine the optimal signal-to-noise ratio, that is, to find the maximum signal-to-noise ratio under the corresponding step, so as to facilitate better health detection.
[0047] Figure 2 A schematic diagram of the steps for adjusting the motor provided in an embodiment of the present application, wherein the clip-on earphone controls the motor in different directions in sequence to determine the optimal signal-to-noise ratio, and the specific steps are as follows:
[0048] Step S210: adjust the motor along a first preset direction until the stepping of the motor reaches a first preset maximum stepping in the first preset direction.
[0049] Step S220: Based on the first preset step, adjust the motor along the second preset direction, and determine the detection signal-to-noise ratio corresponding to each step, until the step of the motor reaches a second preset maximum step in the second preset direction.
[0050] Step S230: Compare the detection signal-to-noise ratios corresponding to each step to determine the optimal signal-to-noise ratio and the target step corresponding to the optimal signal-to-noise ratio from the acquired detection signal-to-noise ratios.
[0051] Step S240: Based on the target step, the motor is adjusted and the health detection function is enabled with an optimal signal-to-noise ratio.
[0052] It can be understood that the first preset direction and the second preset direction are associated with the direction in which the motor bearing rotates, and the ear clip earphone can control the two ends of the earphone to move closer or farther apart through the rotation of the motor bearing, that is, the first preset direction and the second preset direction are two opposite directions. Therefore, when the motor is adjusted by one step, the position of the second end of the ear clip earphone relative to the first end changes synchronously accordingly.
[0053] It can also be imagined that, whether the two ends of the earphones are brought closer to each other or farther away from each other, the ear-clip earphones have corresponding limitations to prevent the earphones from being clamped too tightly or too loosely on the user's ears, that is, there are corresponding step limitations in the first preset direction and the second preset direction.
[0054] In this regard, the ear clip earphone adjusts the motor along the first preset direction until the step of the motor reaches the first preset maximum step in the first preset direction, wherein the first preset maximum step is the step limit of the motor in the first preset direction. Then, the ear clip earphone adjusts the motor along the second preset direction based on the first preset step, that is, the motor is adjusted in the second preset direction at intervals of the first preset step each time, and a detection signal-to-noise ratio is recorded after each step, until the step of the motor reaches the second preset maximum step in the second preset direction, wherein the second preset maximum step is the step limit of the motor in the second preset direction.
[0055] The clip-on earphones compare the corresponding detection signal-to-noise ratios at each step to select the target signal-to-noise ratio as the optimal signal-to-noise ratio, such as taking the signal-to-noise ratio with the largest value as the target signal-to-noise ratio. The clip-on earphones also record the target step corresponding to the optimal signal-to-noise ratio, so as to adjust the motor based on the target step, so that the clip-on earphones can turn on the health detection function with the optimal signal-to-noise ratio, thereby effectively improving the accuracy of health detection. And because the LED light source and the photodiode fit the user's ears more closely, the clip-on earphones do not need to increase the power of the LED light source, which helps to extend the battery life of the earphones.
[0056] It should be noted that the ear clip earphone is provided with a corresponding control mainboard to connect with the motor and realize the regulation and control of the motor by sending corresponding electrical signals. Moreover, the regulation of the motor can also be actively initiated by the user through the terminal device, so that the ear clip earphone operates based on the above motor regulation strategy.
[0057] From the above, it can be seen that the ear-clip headphones can use LED light sources and photodiodes to form transmissive PPG detection, and combine the historical signal-to-noise ratio with the current signal-to-noise ratio to determine whether to adjust the motor. When the motor needs to be adjusted, the optimal signal-to-noise ratio is found and the degree of fit between the LED light source and the photodiode and the user's ear is adjusted. This makes the LED light source and the photodiode fit the user's ear more closely, while effectively reducing the power of the LED light source, which helps to extend the battery life of the headphones. In addition, it can effectively reduce ambient light interference, better improve the signal-to-noise ratio of the PPG signal, and make health detection more accurate.
[0058] In some embodiments, the clip-on earphones can use the detection data obtained by the photodiode to determine whether the clip-on earphones are in a wearing state. It can be understood that the photodiode is used to convert the light from the LED light source through the user's ear into an electrical signal. The greater the light intensity of the received light, the greater the converted electrical signal (such as current) is. Therefore, the clip-on earphones are provided with a corresponding receiving threshold corresponding to the photodiode, that is, the corresponding threshold is set corresponding to the converted electrical signal. After obtaining the detection data corresponding to the photodiode, such as using the converted current value as the detection data, the detection data and the receiving threshold are correspondingly compared, so that the clip-on earphones can determine whether the user is wearing the clip-on earphones.
[0059] In some embodiments, the first preset direction may be a first direction that brings the second end of the clip-on earphone closer to the first end of the clip-on earphone, or the first preset direction may be a second direction that brings the second end of the clip-on earphone away from the first end of the clip-on earphone.
[0060] Taking the first preset direction as the first direction mentioned above as an example, the process of adjusting the motor of the clip-on earphone to obtain the optimal signal-to-noise ratio is exemplarily described. The clip-on earphone first adjusts the motor so that the second end of the clip-on earphone is constantly close to the first end of the clip-on earphone until the step of the motor reaches the maximum step in this direction. It can be imagined that the maximum step is the step limit in this direction, so that the two ends of the clip-on earphone are too tight. Then, the clip-on earphone controls the motor in the opposite direction, even if the second end of the clip-on earphone is far away from the first end of the clip-on earphone, but in this process, the clip-on earphone records a detection signal-to-noise ratio at each step, and then determines multiple detection signal-to-noise ratios. Therefore, by comparing the obtained detection signal-to-noise ratios, the clip-on earphone can determine the optimal signal-to-noise ratio therefrom, such as selecting the detection signal-to-noise ratio with the largest value as the optimal signal-to-noise ratio, so as to adjust the motor again according to the target step corresponding to the optimal signal-to-noise ratio, so that the clip-on earphone can perform health detection with the optimal signal-to-noise ratio.
[0061] Therefore, the clip-on earphones can determine the corresponding optimal signal-to-noise ratio for different wearers by continuously adjusting the motor, so that when the clip-on earphones perform health checks on different wearers, the LED light source and the photodiode can fit the wearer's ear better, which helps to extend the battery life of the earphones and reduce ambient light interference, and achieve health detection more accurately.
[0062] In some embodiments, the ear clip earphone is also adjusted based on a second preset step in the process of adjusting the motor along the first preset direction, and the second preset step is different from the first preset step, so that the ear clip earphone can determine the detection signal-to-noise ratio at each step in the process of adjusting the motor along the first preset direction, thereby expanding the number of detection signal-to-noise ratios obtained. Therefore, the ear clip earphone can obtain more detection signal-to-noise ratios, so as to better find the optimal signal-to-noise ratio, thereby helping to improve the accuracy of health detection.
[0063] In some embodiments, after each time the optimal signal-to-noise ratio is determined, the ear clip headphones update the historical signal-to-noise ratio once, such as using the optimal signal-to-noise ratio as the updated historical signal-to-noise ratio, so that the ear clip headphones can quickly start health detection when the current user wears them next time, and provide health detection with better accuracy, which helps to improve the user experience.
[0064] Figure 3 This is a schematic diagram of the steps of an earphone detection and adjustment device provided in an embodiment of the present application. The earphone detection device is used to execute the earphone detection and adjustment method provided in the above embodiment, and has functional modules and beneficial effects corresponding to the execution method. As shown in the figure, the earphone detection and adjustment module includes a wearing detection module 301, a history query module 302, a record comparison module 303 and a motor adjustment module 304.
[0065] Among them, the wearing detection module 301 is configured to determine whether the clip-on earphones are in a wearing state in response to a received start signal sent by the terminal device; the history query module 302 is configured to query whether there is a historical signal-to-noise ratio when it is determined that the clip-on earphones are in a wearing state; the record comparison module 303 is configured to obtain the current signal-to-noise ratio and determine whether the current signal-to-noise ratio is less than the historical signal-to-noise ratio if there is a historical signal-to-noise ratio; the motor adjustment module 304 is configured to adjust the motor based on a preset motor adjustment strategy to determine the optimal signal-to-noise ratio and turn on the health detection function if the current signal-to-noise ratio is less than the historical signal-to-noise ratio or there is no historical signal-to-noise ratio.
[0066] Therefore, the clip-on earphones can use the LED light source and the photodiode to form a transmissive PPG detection. When the user wears the clip-on earphones, the clip-on earphones search for the historical signal-to-noise ratio through the history query module 302, and determine whether to adjust the motor in combination with the comparison result of the historical signal-to-noise ratio and the current signal-to-noise ratio by the record comparison module 303. When the motor needs to be adjusted, the optimal signal-to-noise ratio is found based on the motor adjustment module 304, and the fit between the LED light source and the photodiode and the user's ear is adjusted, so that the LED light source and the photodiode are more closely fitted to the user's ear, and the power of the LED light source can be effectively reduced, which helps to extend the battery life of the earphones. In addition, it can also effectively reduce ambient light interference, better improve the signal-to-noise ratio of the PPG signal, and make the accuracy of health detection higher.
[0067] On the basis of the above embodiment, the ear-clip earphone further includes an infrared sensor or a capacitive sensor for detecting the wearing state, and the wearing detection module 301 is further configured as follows:
[0068] First detection data corresponding to the infrared sensor or the capacitive sensor is obtained, and the first detection data is compared with a first preset threshold value to determine whether the clip-on earphone is in a wearing state.
[0069] Based on the above embodiment, the wearing detection module 301 is further configured as follows:
[0070] Acquire second detection data corresponding to the photodiode, and compare the second detection data with a second preset threshold value to determine whether the clip-on earphone is in a wearing state.
[0071] Based on the above embodiment, the motor adjustment module 304 is further configured as follows:
[0072] Adjusting the motor along a first preset direction until the stepping of the motor reaches a first preset maximum stepping in the first preset direction;
[0073] Based on the first preset step, the motor is adjusted along the second preset direction, and the detection signal-to-noise ratio corresponding to each step is determined until the step of the motor reaches a second preset maximum step in the second preset direction, and the second preset direction is opposite to the first preset direction;
[0074] Comparing the detection signal-to-noise ratios corresponding to each step, so as to determine the optimal signal-to-noise ratio and the target step corresponding to the optimal signal-to-noise ratio among the acquired detection signal-to-noise ratios;
[0075] Based on the target step, the motor is regulated and the health check function is turned on with the best signal-to-noise ratio.
[0076] Based on the above embodiment, the first preset direction is a first direction that brings the second end of the clip-on earphone closer to the first end of the clip-on earphone or a second direction that brings the second end of the clip-on earphone away from the first end of the clip-on earphone.
[0077] Based on the above embodiment, the motor adjustment module 304 is further configured as follows:
[0078] In the process of adjusting the motor along the first preset direction, based on the second preset step, the detection signal-to-noise ratio corresponding to each step is determined.
[0079] On the basis of the above embodiment, the earphone detection and adjustment device further includes a data updating module, and the data updating module is configured as follows:
[0080] After the optimal signal-to-noise ratio is determined, the historical signal-to-noise ratio is updated based on the optimal signal-to-noise ratio.
[0081] It is worth noting that in the embodiment of the above-mentioned headphone detection and adjustment device, each module is divided only according to functional logic, but is not limited to the above-mentioned division, as long as the corresponding functions can be realized; in addition, the specific name of each module is only for the convenience of distinguishing each other, and is not used to limit the scope of protection of this application.
[0082] Figure 4 The present invention provides a schematic diagram of the structure of a clip-on earphone according to an embodiment of the present invention. The device is used to execute the earphone detection and adjustment method provided in the above embodiment, and has functional modules and beneficial effects corresponding to the execution method. As shown in the figure, the clip-on earphone includes a processor 401, a memory 402, an input device 403 and an output device 404. The number of processors 401 can be one or more, and one processor 401 is taken as an example in the figure; the processor 401, the memory 402, the input device 403 and the output device 404 can be connected by a bus or other means, and the connection through a bus is taken as an example in the figure. The memory 402, as a computer-readable storage medium, can be used to store software programs, computer executable programs and modules, such as program instructions / modules corresponding to the earphone detection and adjustment method in the embodiment of the present invention. The processor 401 executes various corresponding functional applications and data processing by running the software programs, instructions and modules stored in the memory 402, that is, the above-mentioned earphone detection and adjustment method is realized.
[0083] The memory 402 may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system and at least one application required for a function; the data storage area may store data recorded or created during use, etc. In addition, the memory 402 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, or other non-volatile solid-state storage device. In some embodiments, the memory 402 may further include a memory remotely arranged relative to the processor 401, and these remotely arranged memories may be connected to the terminal device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0084] The input device 403 can be used to input corresponding digital or character information to the processor 401, and to generate key signal input related to the user settings and function control of the device; the output device 404 can be used to send or display key signal output related to the user settings and function control of the device.
[0085] An embodiment of the present application further provides a storage medium storing computer executable instructions, which, when executed by a processor, are used to perform relevant operations in the headphone detection and adjustment method provided in any embodiment of the present application.
[0086] Computer-readable storage media include permanent and non-permanent, removable and non-removable media that can be implemented by any method or technology to store information. Information can be computer-readable instructions, data structures, program modules or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technology, compact disk read-only memory (CD-ROM), digital versatile disk (DVD) or other optical storage, magnetic cassettes, magnetic disk storage or other magnetic storage devices or any other non-transmission media that can be used to store information that can be accessed by a computing device.
[0087] It should also be noted that the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, commodity or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, commodity or device. In the absence of more restrictions, the elements defined by the sentence "comprises a ..." do not exclude the existence of other identical elements in the process, method, commodity or device including the elements.
[0088] Note that the above are only preferred embodiments of the present application and the technical principles used. Those skilled in the art will understand that the present application is not limited to the specific embodiments described herein, and that various obvious changes, readjustments and substitutions can be made by those skilled in the art without departing from the scope of protection of the present application. Therefore, although the present application is described in more detail through the above embodiments, the present application is not limited to the above embodiments, and may include more other equivalent embodiments without departing from the concept of the present application, and the scope of the present application is determined by the scope of the appended claims.
Claims
1. A method for detecting and adjusting an earphone, characterized in that: The invention is applied to an earphone, wherein the earphone is communicatively connected to a terminal device, a first end of the earphone is provided with an LED light source, a second end of the earphone is provided with a photodiode, and the earphone further comprises a motor for controlling the rotation of one end of the earphone, so that the LED light source and the photodiode are respectively located at two sides of the ear of the user, and the method comprises: In response to a received start signal sent by the terminal device, determining whether the clip-on earphone is in a wearing state; When it is determined that the clip-on earphone is in a wearing state, querying whether there is a historical signal-to-noise ratio; If the historical signal-to-noise ratio exists, obtaining a current signal-to-noise ratio and determining whether the current signal-to-noise ratio is less than the historical signal-to-noise ratio; If the current signal-to-noise ratio is less than the historical signal-to-noise ratio or the historical signal-to-noise ratio does not exist, the motor is adjusted based on a preset motor adjustment strategy to determine an optimal signal-to-noise ratio and enable a health detection function.
2. The headphone detection and adjustment method according to claim 1, characterized in that: The ear clip earphone further includes an infrared sensor or a capacitive sensor for detecting a wearing state, and the step of determining whether the ear clip earphone is in a wearing state in response to a received start signal sent by the terminal device includes: Acquire first detection data corresponding to the infrared sensor or the capacitive sensor, and compare the first detection data with a first preset threshold to determine whether the clip-on earphone is in a wearing state.
3. The headphone detection and adjustment method according to claim 1, characterized in that: The step of determining whether the earphone is in a wearing state in response to the received start signal sent by the terminal device comprises: Acquire second detection data corresponding to the photodiode, and compare the second detection data with a second preset threshold to determine whether the clip-on earphone is in a wearing state.
4. The headphone detection and adjustment method according to claim 1, characterized in that: If the current signal-to-noise ratio is less than the historical signal-to-noise ratio or the historical signal-to-noise ratio does not exist, adjusting the motor based on a preset motor adjustment strategy to determine the optimal signal-to-noise ratio includes: adjusting the motor along a first preset direction until the stepping of the motor reaches a first preset maximum stepping in the first preset direction; Based on the first preset step, adjusting the motor along a second preset direction, and determining the detection signal-to-noise ratio corresponding to each step, until the step of the motor reaches a second preset maximum step in the second preset direction, the second preset direction being a direction opposite to the first preset direction; Comparing the detection signal-to-noise ratios corresponding to each step, so as to determine the optimal signal-to-noise ratio and the target step corresponding to the optimal signal-to-noise ratio in the acquired detection signal-to-noise ratios; Based on the target step, the motor is adjusted and a health detection function is enabled at the optimal signal-to-noise ratio.
5. The headphone detection and adjustment method according to claim 4, characterized in that: The first preset direction is a first direction that makes the second end of the clip-on earphone approach the first end of the clip-on earphone or a second direction that makes the second end of the clip-on earphone move away from the first end of the clip-on earphone.
6. The earphone detection and adjustment method according to claim 4 or 5, characterized in that: After adjusting the motor along the first preset direction until the stepping of the motor reaches a first preset maximum stepping in the first preset direction, the method further comprises: In the process of adjusting the motor along the first preset direction, based on the second preset step, the detection signal-to-noise ratio corresponding to each step is determined.
7. The earphone detection and adjustment method according to claim 1 or 4, characterized in that: The method further comprises: After the optimal signal-to-noise ratio is determined, the historical signal-to-noise ratio is updated based on the optimal signal-to-noise ratio.
8. An earphone detection and adjustment device, characterized in that: The invention is applied to an earphone, wherein the earphone is communicatively connected to a terminal device, a LED light source is arranged at a first end of the earphone, a photodiode is arranged at a second end of the earphone, and the earphone further comprises a motor for controlling the rotation of one end of the earphone, so that the LED light source and the photodiode are respectively located at two sides of the ear of the user, and the device comprises: a wearing detection module, configured to determine whether the clip-on earphone is in a wearing state in response to a received start signal sent by the terminal device; A history query module, configured to query whether there is a historical signal-to-noise ratio when it is determined that the clip-on earphone is in a wearing state; a record comparison module, configured to obtain a current signal-to-noise ratio and determine whether the current signal-to-noise ratio is less than the historical signal-to-noise ratio if the historical signal-to-noise ratio exists; The motor adjustment module is configured to adjust the motor based on a preset motor adjustment strategy to determine the optimal signal-to-noise ratio and enable a health detection function if the current signal-to-noise ratio is less than the historical signal-to-noise ratio or the historical signal-to-noise ratio does not exist.
9. An ear-clip headphone, characterized in that: include: one or more processors; A storage device, used to store one or more programs, when one or more of the programs are executed by one or more of the processors, so that one or more of the processors implement the headphone detection and adjustment method as described in any one of claims 1-7.
10. A storage medium storing computer executable instructions, characterized in that: When the computer executable instructions are executed by a processor, they are used to perform the earphone detection and adjustment method according to any one of claims 1 to 7.