Earplug detection method and audio device
By detecting the acoustic characteristics of earbuds through microphones and speakers in the audio device, and automatically adjusting software parameters, the problem of users having difficulty distinguishing earbuds is solved, thus improving the audio output quality and user experience of the headphones.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- HUAWEI TECH CO LTD
- Filing Date
- 2024-10-31
- Publication Date
- 2026-05-01
AI Technical Summary
Users may have difficulty distinguishing between different models of ear tips, which can negatively impact the user experience due to the headphone's audio output.
The acoustic transmission path characteristics of the earbuds are detected by the microphones and speakers in the audio device to determine the material and size of the earbuds, and the software parameters are automatically adjusted to match the earbud characteristics.
It improves the headphone user experience, ensures audio output quality and noise reduction, reduces manual operation by the user, and allows for timely replacement of damaged earplugs.
Smart Images

Figure CN121967990A_ABST
Abstract
Description
A method and audio device for earplug detection Technical Field
[0001] This application relates to the field of terminal technology, and in particular to a method for earphone detection and an audio device. Background Technology
[0002] Currently, some audio devices (such as headphones) come with ear tips for users to wear. Ear tips make wearing audio devices more comfortable. However, users may own multiple different models of ear tips, and although these models differ in features (such as size and material), it can be difficult for users to distinguish them visually. If a user accidentally uses the wrong ear tips, the different characteristics of each model will affect the headphone's audio output, thus impacting the user's headphone experience. Summary of the Invention
[0003] This application provides a method and audio device for earphone detection, which can determine the characteristics of the earphone, making it convenient for users to adjust software parameters or replace the earphone.
[0004] In a first aspect, this application provides a method for earplug detection, applied to a first audio device. The first audio device includes a first microphone, a first speaker, and a first earplug disposed thereon. The housing of the first audio device includes a first sound outlet, the first earplug is disposed around the first sound outlet, and the housing of the first audio device also includes a first pickup hole. The method includes: the first audio device detecting that it is located inside an audio device compartment, and the audio device compartment being closed; the first audio device playing a first audio signal through the first speaker; the first audio device acquiring a second audio signal through the first microphone; and the first audio device determining the characteristics of the first earplug based on the characteristics of the second audio signal.
[0005] In some implementations, the second audio is the audio produced after the first audio has passed through an earpiece configured in the audio device 100. Specifically, the first audio device determines the characteristics of the first earpiece configured in the first audio device based on the characteristics of the second audio and the characteristics of the standard audio.
[0006] The audio device includes headphones, which can be placed inside a headphone case. After the headphones are placed in the case and the case is closed, a sealed cavity is formed inside the case, within which the acoustic transmission path from the speaker to the microphone is relatively stable. Since the frequency response characteristics of the acoustic transmission path from the speaker to the microphone differ depending on the ear tips (e.g., different materials and / or sizes), the frequency response characteristics of this acoustic transmission path can be obtained by playing audio through the speaker and detecting the audio through the microphone, thus determining the characteristics of the ear tips. Through this solution, the audio device can easily determine the characteristics of the ear tips configured in the headphones inside the case, allowing users to adjust software parameters or replace ear tips in a timely manner. For example, users can adjust the headphone's software parameters to match the current ear tips, providing a better listening experience. These software parameters can include one or more of the following: impedance matching parameters, frequency response curve compensation parameters, and distortion compensation parameters.
[0007] In conjunction with the first aspect, in some implementations, the first audio device determines the feature of the first earbud as the first feature based on the features of the second audio. The method further includes: the first audio device playing sound using a first parameter, the first parameter corresponding to the first feature, the first feature including the size of the first earbud being a first size, and / or the material of the first earbud being a first material.
[0008] Upon detecting the earbud characteristics of the headphones configured in the current audio device, the first audio device / or the electronic device connected to the audio device can automatically change the headphone's software parameters to the corresponding first parameters. This adaptively matches the corresponding software parameters based on the earbud characteristics, avoiding manual operation by the user and providing convenience and speed.
[0009] In conjunction with the first aspect, in some implementations, the first audio device determines the characteristics of the first earbud based on the characteristics of the second audio, specifically including: the first audio device determines the material and / or size of the first earbud based on the similarity between the characteristics of the second audio and the characteristics of standard audio data.
[0010] The standard audio includes: the audio captured after a specific audio signal, passed through undamaged earplugs, is played by an audio device equipped with undamaged earplugs of different materials and sizes. Since the single variable in acquiring the characteristics of various standard audio signals is the size and / or material of the earplugs, the characteristics of one standard audio signal can correspond to one material and one size. The process of acquiring the second audio signal is similar to that of acquiring the standard audio signal, and the characteristics of the second audio signal are also affected by the material and / or size of the earplugs. If the characteristics of the second audio signal are highly similar to the characteristics of a certain standard audio signal, it indicates that the characteristics of the earplugs configured in the first audio device during the acquisition of the second audio signal are highly consistent with the characteristics of the earplugs corresponding to the characteristics of that certain standard audio signal. Through this scheme, the audio device can accurately determine the characteristics of the configured earplugs.
[0011] Specifically, audio features can include the frequency response curve of the audio. The similarity of features between two audio files can include the similarity of their frequency response curves. Specifically, the similarity of the frequency response curves of two audio files can refer to the ratio of the frequency band range where the difference in amplitude across each frequency band is less than a first preset amplitude difference to the total frequency band range. The similarity of the frequency response curves of two audio files can also refer to the ratio of the frequency band range where the difference in amplitude across each frequency band within a specific frequency band is less than a second preset amplitude difference to the total specific frequency band range. Beyond the above methods, similarity can also be determined through: calculating Euclidean distance; employing a dynamic time warping algorithm; determining cross-correlation; comparing feature points, which can include peaks, valleys, etc.; extracting parameters that represent the frequency response curve through model fitting and comparing the differences in these parameters, etc.
[0012] In conjunction with the first aspect, in some implementations, the first audio device determines the characteristics of the first earbud based on the characteristics of the second audio, specifically including: when the similarity between the characteristics of the second audio and the characteristics of the first standard audio data is greater than a first threshold, the first audio device determines that the material of the first earbud is the first material, and the first standard audio data belongs to standard audio data.
[0013] Similarly, the earphone material corresponding to the features of the first standard audio data is the first material. That is, when acquiring the first standard audio data, the audio device is configured with earphones made of the first material. The fact that the similarity between the features of the second audio and the features of the first standard audio data is greater than a first threshold indicates that, among all standard audios, the features of the second audio are most similar to the features of the first standard audio. Therefore, it can be determined that the material of the first earphone affecting the features of the second audio is the same as the material of the earphone affecting the features of the first standard audio, both being the first material. In this way, the audio device can determine the material of the first earphone relatively accurately.
[0014] In conjunction with the first aspect, in some implementations, after the first audio device determines that the material of the first earbud is the first material, the method further includes: if the first material is different from the target material, the first audio device outputs first information; or, after the first audio device establishes a communication connection with the first electronic device, the first audio device sends a first message to the first electronic device.
[0015] The target material can be the material tested by the developers during the development phase of the first audio device to be the most suitable material for the earbuds, or it can be the material of the earbuds set by the user, or it can be the material of the earbuds determined after the earbud detection method provided in the previous embodiment of this application was executed. That is, before executing the earbud detection method this time, the audio device 100 determines that the material of the configured earbuds is the target material. If the first material is different from the target material, the audio device can output first information to inform the user that the earbud material is the first material. The audio device can also send a first message to the electronic device if a communication connection has been established. The electronic device can then remind the user of the earbud material information configured by the audio device by displaying the user interface shown in Figure 3A or Figure 3B. In this way, the user can know the material of the earbuds of the current first audio device.
[0016] In conjunction with the first aspect, in some implementations, the first audio device outputting the first information specifically includes: after detecting that a user is wearing the first audio device, the first audio device outputs the first information. When the audio device determines that the earbud material is the first material within the earphone compartment, when the user removes the audio device from the earphone compartment and wears it in their ear canal, the user can be informed of the current earbud material via voice announcement during the wearing process.
[0017] In conjunction with the first aspect, in some implementations, the first audio device determines the characteristics of the first earbud based on the characteristics of the second audio, specifically including: when the similarity between the characteristics of the second audio and the characteristics of the second standard audio data is greater than a second threshold, the first audio device determines the size of the first earbud to be the first size, and the second standard audio data belongs to standard audio data.
[0018] Similarly, the earphone size corresponding to the features of the aforementioned second standard audio data is the first size. In other words, when acquiring the second standard audio data, the audio device is configured with earphones of the first size. The fact that the similarity between the features of the second audio and the features of the second standard audio data is greater than a second threshold indicates that, among all standard audios, the features of the second audio are most similar to those of the second standard audio. Therefore, it can be determined that the size of the first earphone affecting the features of the second audio is the same as the size of the earphone affecting the features of the second standard audio, both being the first size. In this way, the audio device can determine the size of the first earphone relatively accurately.
[0019] In conjunction with the first aspect, in some implementations, after the first audio device determines that the size of the first earbud is the first size, the method further includes: if the first size is different from the target size, the first audio device outputs second information; or, after the first audio device establishes a communication connection with the first electronic device, the first audio device sends a second message to the first electronic device.
[0020] The target size can be the size of the earbuds set by the user, or it can be the size of the earbuds determined after the last execution of the earbud detection method provided in this application embodiment. That is, before executing the earbud detection method this time, the audio device 100 determines the size of the configured earbuds as the target size. If the first size differs from the target size, the audio device can output second information to inform the user that the earbud size is the first size. The audio device can also send a second message to the electronic device if a communication connection is established. The electronic device can then display a user interface to remind the user of the earbud size information configured on the audio device. In this way, the user can know the current earbud size of the first audio device.
[0021] In conjunction with the first aspect, in some implementations, the first audio device determines the characteristics of the first earbud based on the characteristics of the second audio, specifically including: when the similarity between the characteristics of the second audio and the characteristics of each standard audio data in the standard audio data is less than a third threshold, the first audio device determines that the first earbud is faulty.
[0022] The above situation illustrates that the characteristics of any one standard audio in all standard audio data are not very similar to the characteristics of the second audio. In other words, the characteristics of the first earbud affecting the characteristics of the second audio are different from the characteristics of the earbud affecting the characteristics of the second standard audio. Therefore, the first earbud can be considered faulty. A faulty first earbud can include one or more of the following: the first earbud is broken; the size and material of the first earbud are different from the size and material corresponding to the standard audio; or the speaker and / or microphone in the first audio device is faulty. This allows the user to know whether the earbuds of the current first audio device are broken.
[0023] Furthermore, if the audio device detects that the user has not replaced the earbuds after determining that they are damaged, that is, if the audio device 100 detects earbud damage again after determining that the earbuds are damaged, the audio device 100 can use some compensation algorithms to reduce the impact of earbud damage on the user's use of the audio device 100.
[0024] By implementing the above method, the characteristics of the earbuds can be determined. Not only can the characteristics of each earbud configured in the first audio device be determined simultaneously, but they can also be determined separately. Furthermore, the user can be prompted whether the earbuds need to be replaced. After the user replaces the earbuds according to the prompt, the objective impact on the fit of the first audio device can be reduced, thereby improving the user's experience when using the first audio device.
[0025] In conjunction with the first aspect, in some implementations, the first audio device includes a first sub-audio device and a second sub-audio device. The first sub-audio device includes a first microphone and a first speaker, and is equipped with a first earpiece. The housing of the first sub-audio device includes a first sound outlet and a first pickup hole. The second sub-audio device includes a second microphone and a second speaker, and is equipped with a second earpiece. The housing of the second sub-audio device includes a second sound outlet, and the second earpiece is disposed around the second sound outlet. The housing of the second sub-audio device also includes a second pickup hole. The method further includes: the first audio device playing the first audio through the second speaker; the first audio device acquiring a third audio through the second microphone; and the first audio device determining the characteristics of the second earpiece based on the characteristics of the third audio. Thus, the process of playing the first audio, acquiring the second audio, and determining the characteristics of the earpiece can be achieved by a single sub-audio device included in the first audio device. Furthermore, the earpiece detection method provided in this application embodiment can also be implemented when only one sub-audio device is placed in the audio device compartment.
[0026] In conjunction with the first aspect, in some implementations, the first audio device includes a first sub-audio device and a second sub-audio device. The first sub-audio device includes a second microphone and the first speaker, and is equipped with a first earpiece. The housing of the first sub-audio device includes a first sound outlet and a second sound pickup outlet. The second sub-audio device includes a first microphone and a second speaker, and is equipped with a second earpiece. The housing of the second sub-audio device includes a second sound outlet, and the second earpiece is disposed around the second sound outlet. The housing of the second sub-audio device also includes the first sound pickup outlet. The method further includes: the first audio device playing the first audio through the second speaker; the first audio device acquiring a third audio through the second microphone; and the first audio device determining the characteristics of the second earpiece based on the characteristics of the third audio. Thus, the first audio can also be played by one sub-audio device included in the first audio device, while the second audio can be acquired by the other included sub-audio device.
[0027] In conjunction with the first aspect, in some implementations, the first audio device determines the characteristics of the first earphone based on the characteristics of the second audio, specifically including: the first audio device determining the characteristics of the first earphone based on the similarity between the characteristics of the second audio and the characteristics of standard audio data through the first sub-audio device or the second sub-audio device; the first audio device determining the characteristics of the second earphone based on the characteristics of the third audio, specifically including: the first audio device determining the characteristics of the second earphone based on the similarity between the characteristics of the second audio and the characteristics of standard audio data through the first sub-audio device or the second sub-audio device. In one possible implementation, the entity performing the determination of earphone characteristics is not limited to any one of the sub-audio devices in the first audio device, but can also be a server or electronic device.
[0028] Secondly, this application provides an audio device that can be housed in an audio device compartment. When the audio device is a first audio device, the first audio device includes a first microphone, a first speaker, and a first earpiece. The housing of the first audio device includes a first sound outlet, and the first earpiece is disposed around the first sound outlet. The housing of the first audio device also includes a first pickup hole. The first audio device further includes a memory, a processor, and computer instructions stored in the memory. The processor executes the computer program to implement the earpiece detection method in the first aspect and any possible implementation thereof.
[0029] In conjunction with the second aspect, in some implementations, the first audio device includes a first sub-audio device and a second sub-audio device. The first sub-audio device includes a second microphone and the first speaker. The first sub-audio device is equipped with the first earpiece. The housing of the first sub-audio device includes the first sound outlet and the first sound pickup hole. The second sub-audio device includes the first microphone and the second speaker. The second sub-audio device is equipped with the second earpiece. The housing of the second sub-audio device includes the second sound outlet. The second earpiece is disposed around the second sound outlet. The housing of the second sub-audio device also includes the second sound pickup hole.
[0030] In conjunction with the second aspect, in some implementations, the first audio device includes a first sub-audio device and a second sub-audio device. The first sub-audio device includes a second microphone and the first speaker. The first sub-audio device is equipped with the first earpiece. The housing of the first sub-audio device includes the first sound outlet and the second sound pickup outlet. The second sub-audio device includes the first microphone and the second speaker. The second sub-audio device is equipped with the second earpiece. The housing of the second sub-audio device includes the second sound outlet. The second earpiece is disposed around the second sound outlet. The housing of the second sub-audio device also includes the first sound pickup outlet.
[0031] Thirdly, embodiments of this application provide a computer-readable storage medium storing a computer program that, when executed by a processor, implements the method described in the first aspect or any of the embodiments of the first aspect.
[0032] Fourthly, embodiments of this application provide a computer program product comprising computer instructions that, when executed by a processor, implement the method described in the first aspect or any of the embodiments of the first aspect.
[0033] The beneficial effects of the second to fourth aspects can be referenced from the beneficial effects of the first aspect mentioned above. Attached Figure Description
[0034] Figure 1A is a schematic diagram of the form of an audio device provided in an embodiment of this application;
[0035] Figure 1B shows several frequency response curves provided in the embodiments of this application;
[0036] Figure 2 is a schematic flowchart of an earplug detection method provided in an embodiment of this application;
[0037] Figures 3A and 3B illustrate several user interfaces provided in the embodiments of this application;
[0038] Figure 4 is a structural schematic diagram of an audio device provided in an embodiment of this application;
[0039] Figure 5 is a schematic diagram of the structure of an earphone in an audio device provided in an embodiment of this application;
[0040] Figure 6 is a schematic diagram of the software module of an earphone in an audio device provided in an embodiment of this application;
[0041] Figure 7 is a schematic diagram of the structure of an electronic device provided in an embodiment of this application;
[0042] Figure 8 is a schematic flowchart of an earplug detection method provided in an embodiment of this application. Detailed Implementation
[0043] The technical solutions in the embodiments of this application will be clearly and thoroughly described below with reference to the accompanying drawings. In the description of the embodiments of this application, unless otherwise stated, " / " means "or," for example, A / B can mean A or B; the word "and / or" in the text is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone. Furthermore, in the description of the embodiments of this application, "multiple" refers to two or more than two.
[0044] Hereinafter, the terms "first" and "second" are used for descriptive purposes only and should not be construed as implying or suggesting relative importance or implicitly indicating the number of indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature, and in the description of the embodiments of this application, unless otherwise stated, "multiple" means two or more.
[0045] In this embodiment, the audio device can be used for inputting and / or outputting audio. The audio device may include a microphone and a speaker. The audio device may also be equipped with earplugs. When a user wears the audio device, the earplugs are located inside the user's ear canal. The earplugs can be used to isolate external noise, provide a closed environment, improve user comfort, and enhance sound quality, etc. The audio device can be headphones, including but not limited to Bluetooth headphones (e.g., true wireless stereo (TWS) headphones). Of course, the audio device can also be other audio devices equipped with earplugs, such as hearing aids, etc. The following description uses TWS headphones as an example of the audio device.
[0046] The following is a schematic diagram of the form of the audio device provided in the embodiments of this application.
[0047] As shown in Figure 1A, the audio device 100 may include headphones 11 and 12. The audio device 100 may also be placed inside a storage compartment 13 (or audio device compartment). The storage compartment 13 may include a storage compartment cover 13a and a storage compartment body 13b. The storage compartment 13 can be in an open or closed state. The storage compartment 13 can accommodate headphones 11 and 12. Specifically, the storage compartment 13 can accommodate both headphones 11 and 12 simultaneously, or it can accommodate only one of headphones 11 and 12, with the other headphone located outside the storage compartment 13. The space within the storage compartment 13 that accommodates headphones 11 and 12 can be the same space or two separate spaces, depending on the design of the storage compartment 13 during the development phase. Specifically, when the storage compartment 13 is in the closed state, the space within the storage compartment 13 that accommodates headphones 11 and the space that accommodates headphones 12 can be the same space or two separate spaces. The storage compartment 13 can also be used to charge headphones 11 and 12.
[0048] The earphone 11 includes a microphone 11a, a speaker 11b, and an earphone housing 11c. The earphone 11 is equipped with an earbud 11d, which is detachable and replaceable. The earphone housing 11c has a pickup hole 11e and a sound outlet hole 11f. The earbud 11d surrounds the sound outlet hole 11f. Both the microphone 11a and the speaker 11b are located within the earphone housing 11c. The internal cavity of the earphone housing 11c can be divided into a front cavity and a rear cavity. The front cavity is the cavity in front of the speaker 11b within the earphone housing 11c, and the rear cavity is the cavity behind the speaker 11b within the earphone housing 11c. The earbud 11d can cover all or part of the earphone housing 11c that constitutes the front cavity. The speaker 11b outputs sound in the direction in front of it, and the opposite direction is in the direction behind it. When the user wears the earphone 11, the front cavity of the earphone 11 is inside the user's external auditory canal, and the earplug 11d is also inside the user's external auditory canal.
[0049] The number of microphones 11a can be one or more. Microphones 11a can be used to capture audio, such as the user's voice, ambient noise around the headphones 11, etc. Specifically, microphones 11a can capture sound through the pickup hole 11e. The number of speakers 11b can be one or more. Speakers 11b can be used to output audio, such as music, voice, etc. A diaphragm is provided inside or at the front of the speaker 11b. Specifically, speaker 11b can capture sound through the sound outlet 11f.
[0050] Optionally, the earphone 11 may also include one or more of the following: one or more holes, and a bone conduction sensor. For example, the one or more holes may include hole 11g and hole 11h (not shown in Figure 1A). Hole 11g may be a through hole located on the earphone housing 11c for connecting the outside of the earphone housing 11c to the front cavity of the earphone. Hole 11g can balance the air pressure inside and outside the earphone 11, improving the user's listening experience. Hole 11h may be a through hole located on the earphone housing 11c for connecting the outside of the earphone housing 11c to the rear cavity of the earphone. Hole 11h can balance the air pressure inside and outside and allow for ventilation.
[0051] The structure of earphone 12 is identical to that of earphone 11, and earphone 12 also includes: microphone 12a, speaker 12b, and earphone shell 12c. Earphone 12 is equipped with ear tips 12d. When earphone 11 is worn in the user's right ear, earphone 12 is worn in the user's left ear; when earphone 11 is worn in the user's left ear, earphone 12 is worn in the user's right ear. For a detailed description of earphone 12, please refer to the description of earphone 11 above, which will not be repeated here.
[0052] In one possible implementation, one of the earphones 11 and 12 includes a microphone, while the other earphone does not.
[0053] In this embodiment of the application, Figure 1A is merely an illustrative example. The audio device 100 may also have other forms, such as the audio device 100 including only one earphone. Furthermore, the earphones 11 and 12 may also have other forms, which are not limited here.
[0054] In some implementations, the fit of the audio device 100 when worn can affect the audio input or output of the audio device 100.
[0055] The fit of the audio device 100 is affected by one or more of the following factors:
[0056] Factor 1: The position of the audio device 100 worn in the ear canal
[0057] During the development of the audio device 100, the correct position for wearing it in the ear canal can be designed for different models and types of audio devices 100. An audio device 100 in this correct position provides a better fit compared to audio devices 100 in other positions. However, if the user's wearing motion is incorrect, the audio device 100 may not be positioned correctly in the ear canal. Therefore, the position of the audio device 100 in the ear canal may affect its fit.
[0058] Factor 2, Features of the earbuds configured in audio device 100
[0059] The characteristics of earplugs include one or more of the following: material, size, and whether they are damaged.
[0060] Earplugs can be made of materials including, but not limited to, silicone, foam, protein leather, genuine leather, velvet, etc. Different materials have different absorption and reflection capabilities for audio. Different materials also have different advantages and disadvantages. For example, silicone earplugs offer good comfort but poor noise isolation. Foam earplugs offer good noise isolation but poor comfort. During the development of the audio device 100, suitable earplug materials can be pre-defined for different models and types of audio devices 100. During the development of the audio device 100, various sizes of earplugs can be set. For example, earplug sizes can include small, medium, and large. Different sizes of earplugs will affect the fit between the audio device 100 and the ear canal. Earplug damage can include: earplugs becoming incomplete due to external factors; earplugs aging and deforming due to prolonged use. For example, after one year of use, the short axis of the earplug increases by 11.3%, and the long axis increases by 12.5%. Therefore, earplugs of different materials, sizes, and damage conditions may affect the fit of the audio device 100, thereby affecting the audio played by the audio device 100 that the user hears.
[0061] The following section, using Figure 1B as an example, explains the impact of different earphone models on audio quality.
[0062] Figure 1B shows the frequency response curves of an audio signal after passing through six different types of ear tips. Type 1 represents a small silicone ear tip, Type 2 represents a small silicone ear tip, Type 3 represents a medium silicone ear tip, Type 4 represents a large silicone ear tip, Type 5 represents a small foam ear tip, and Type 6 represents a medium foam ear tip.
[0063] Referring to Figure 1B, different earphone models have varying degrees of impact on audio across all frequency bands. Earphones made of the same material have similar effects on audio across some frequency bands, but significantly different effects on audio across others. For example, the audio affected by silicone earphones has a loudness of approximately -50dB at 4kHz. The audio affected by model 1 earphones has a loudness of approximately -60dB at 1kHz, and the audio affected by model 4 earphones has a loudness of approximately -53dB at 1kHz. Earphones made of different materials have significantly different effects on audio across all frequency bands. The audio affected by model 1 earphones has a loudness of approximately -62dB at 100Hz, and the audio affected by model 5 earphones has a loudness of approximately -32dB at 100Hz.
[0064] In the embodiments of this application, the earplug models mentioned above are only illustrative examples, and may include more or fewer earplug models. The impact of each earplug model on audio is only illustrative and is not limited thereto.
[0065] Factor 3: The user's external auditory canal
[0066] Different users may have different ear canal sizes and shapes. The fit of the audio device 100 when worn in user A's ear canal may differ from the fit when worn in user B's ear canal. Therefore, the user's ear canal can also affect the fit of the audio device.
[0067] In some implementations, the audio characteristics affected by the fit of the audio device 100 may include one or more of the following: sound quality, noise reduction effect, and call quality. Specifically, the fit of the audio device 100 affects the quality of the audio output by the user. For example, after outputting the same audio using unused earbuds of the same material and size and earbuds that have been used for one year, two audio samples are collected, one after each of the two types of earbuds. The frequency response curves of these two audio samples are obtained, namely, the frequency response curve corresponding to the unused earbuds and the frequency response curve corresponding to the earbuds used for one year. Then, the amplitude difference between the two frequency response curves in multiple frequency bands is determined, i.e., the difference obtained by subtracting the latter from the former. The amplitude difference reflects the degree of impact of earbud aging on the audio. Specifically, the amplitude difference is 0.48dB in the 50Hz-315Hz frequency band, -0.04dB in the 315Hz-1kHz frequency band, -2.75dB in the 1kHz-3.15kHz frequency band, and -0.26dB in the 3.15kHz-16kHz frequency band. This demonstrates that the characteristics of the earbuds have a certain impact on the audio quality output by the audio device 100. The fit of the audio device 100 also affects the noise reduction effect when the user uses it; a poor fit results in poor noise reduction, while a good fit results in good noise reduction. The fit of the audio device 100 also affects the user experience when using the call function, especially the acquisition effect of the microphone and the bone conduction sensor of the audio device 100.
[0068] In some implementations, factors 1 and 3 above have a subjective impact on the fit of the audio device 100, meaning that the position of the audio device 100 worn in the ear canal will vary depending on the user, and the ear canals of different users may also be different. Factor 2 above has an objective impact on the fit of the audio device 100, meaning that the characteristics of the earplug in the audio device 100 will not change depending on the user of the wearable device 100.
[0069] To reduce the objective impact on the fit of the audio device 100, this application provides an earplug detection method. In this method, the characteristics of the earplug of the audio device 100 can be determined based on the characteristics of the audio collected by the audio device 100 and the characteristics of standard audio. The audio collected by the audio device 100 refers to the audio after the specific audio played by the audio device 100 passes through the earplug of the audio device 100.
[0070] By implementing the above method, the audio device 100 can determine the characteristics of the earbuds and remind the user of these characteristics, making it convenient for the user to adjust or replace the earbuds. This reduces the objective impact on the fit of the audio device 100.
[0071] Before performing the method provided in the embodiments of this application, the audio device 100 may acquire features of a standard audio corresponding to the features of an earphone. For example, Table 1 illustrates the features of the standard audio corresponding to the features of an earphone acquired by the audio device 100.
[0072]
[0073] Table 1
[0074] Referring to Table 1, the audio device 100 acquires the characteristics of six standard audio signals. Specifically, feature 1 corresponds to the model number of the audio device 100 (referred to as model 1), and the corresponding earphone features are material 1, size 1, and undamaged. Feature 2 corresponds to the model number of the audio device 100, and the corresponding earphone features are material 1, size 2, and undamaged. Feature 3 corresponds to the model number of the audio device 100, and the corresponding earphone features are material 1, size 3, and undamaged. Feature 4 corresponds to the model number of the audio device 100, and the corresponding earphone features are material 2, size 1, and undamaged. Feature 5 corresponds to the model number of the audio device 100, and the corresponding earphone features are material 2, size 1, and undamaged. Feature 6 corresponds to the model number of the audio device 100, and the corresponding earphone features are material 2, size 1, and undamaged.
[0075] In this embodiment of the application, Table 1 above is only an illustrative example. The audio device 100 can also acquire more features of standard audio, and the features of standard audio can also correspond to more features of earphones. This is not a limitation.
[0076] In other words, in this case, the characteristics of a standard audio corresponds to the model of an audio device and the characteristics of a pair of earphones. Different models of audio devices with the same earphone configuration correspond to different standard audio characteristics, and the same model of audio device with different earphone configurations also corresponds to different standard audio characteristics.
[0077] The following describes the specific process for obtaining the characteristics of standard audio, using characteristic 1 of the standard audio shown in Table 1 as an example. Here, earplug X1 can be an undamaged earplug with material 1 and size 1. The model of audio device a is the same as the model of audio device 100.
[0078] Step a1: Configure the audio device a of earbud X1 to play specific audio through the speaker. The specific audio is a preset audio.
[0079] Step a2: Collect the audio of a specific audio signal after it has passed through the earphone X1.
[0080] Step a3: Based on the audio collected in step a2 above, determine the feature 1 of the standard audio corresponding to earphone X1. Specifically, execute steps a1 and a2 above multiple times, and then model the audio collected multiple times to obtain the feature 1 of the standard audio.
[0081] Based on the above steps a1 to a3, it can be determined that the characteristic 1 of the standard audio is obtained when the audio device a is equipped with earphone X1. Therefore, the characteristic 1 of the standard audio corresponds to the model of the audio device a and the state of the earphone X1.
[0082] Similarly, the features of other standard audio in Table 1 can also be obtained based on steps a1 to a3 described above. For example, by replacing earplug X1 with earplug X2 in steps 1 to a3, feature 2 of the standard audio in Table 1 can be determined. Earplug X1 can be an undamaged earplug with material 1 and size 2. In other words, each time steps a1 to a3 are performed, a feature of the standard audio corresponding to the feature of the earplug used in the process can be obtained.
[0083] Steps a1 to a3 described above can be performed by audio device a. Optionally, step a3 can also be performed by the server. Audio device 100 can receive the characteristics of standard audio sent by the server. The characteristics of the standard audio received by audio device 100 can be simply referred to as the characteristics of the standard audio of audio device 100. The characteristics of the standard audio shown in Table 1 can be obtained by configuring earphones in different states and repeatedly performing steps a1 to a3, assuming that the model of audio device a is the same as the model of audio device 100.
[0084] In addition to the features of the standard audio shown in Table 1 above, the audio device 100 can also acquire features of the standard audio that correspond to headphone identifiers. Headphone identifiers are used to identify one of the headphones in the audio device 100. For example, identifier 1 is used to identify headphone 11, and identifier 2 is used to identify headphone 12.
[0085] For example, Table 2 illustrates the characteristics of standard audio acquired by the audio device 100, corresponding to headphone status and headphone identifier.
[0086]
[0087] Table 2
[0088] Referring to Table 2, the audio device 100 acquires 12 standard audio characteristics. Specifically, characteristic 1 corresponds to the model number of the audio device 100, the corresponding earbud characteristics are material 1, size 1, and undamaged, and the corresponding headphone identifier is identifier 1. Characteristic 2 corresponds to the model number of the audio device 100, the corresponding earbud characteristics are material 1, size 2, and undamaged, and the corresponding headphone identifier is identifier 1. Characteristic 3 corresponds to the model number of the audio device 100, the corresponding earbud characteristics are material 1, size 3, and undamaged, and the corresponding headphone identifier is identifier 1. Characteristic 4 corresponds to the model number of the audio device 100, the corresponding earbud characteristics are material 2, size 1, and undamaged, and the corresponding headphone identifier is identifier 1. Characteristic 5 corresponds to the model number of the audio device 100, the corresponding earbud characteristics are material 2, size 1, and undamaged, and the corresponding headphone identifier is identifier 1. Characteristic 6 corresponds to the model number of the audio device 100, the corresponding earbud characteristics are material 2, size 1, and undamaged, and the corresponding headphone identifier is identifier 1, and so on.
[0089] In this embodiment of the application, Table 2 above is only an illustrative example. The audio device 100 can also acquire more features of standard audio, and the features of standard audio can also correspond to more features of earphones. This is not a limitation.
[0090] In other words, in this case, the characteristics of a standard audio device correspond to the model of an audio device, the characteristics of an earphone, and the identifier of a headphone.
[0091] The following describes the specific process of obtaining the characteristics of standard audio, using feature 1 of the standard audio shown in Table 2 as an example. Earplug X1 can be an undamaged earplug with material 1 and size 1. The model of audio device a is the same as that of audio device 100. Audio device a can include headphones 21 and 22. Headphone 21 includes a microphone 21a, a speaker 21b, and a headphone housing 21c. Headphone 22 includes a microphone 22a, a speaker 22b, and a headphone housing 22c. Headphone 21 can be referred to in the above description of headphones 11 in Figure 1A. Headphone 22 can be referred to in the description of headphones 12 in Figure 1A. Audio device a can also be placed in storage compartment 23. Storage compartment 23 can include a storage compartment body 23a and a storage compartment cover 23b. Storage compartment 23 can be referred to in the description of storage compartment 13 in Figure 1A. The headphone identifier for headphone 21 is identifier 1, and the headphone identifier for headphone 22 is identifier 2.
[0092] Step b1: Configure the audio device a of the earphone X1 to play a specific audio through the speaker 21b. The specific audio is a preset audio.
[0093] Step b2: Collect the audio of a specific audio signal after it has passed through the earphone X1 mentioned above.
[0094] Step b3: Based on the audio collected in step b2 above, determine feature 1 of the standard audio corresponding to earphone X1. Specifically, execute steps 1 and 2 above multiple times, and then model the audio collected multiple times to obtain feature 1 of the standard audio.
[0095] Based on steps b1 to b3 above, it can be determined that the characteristic 1 of the standard audio is obtained when the earphone 21 of the audio device a is equipped with earplug X1. Therefore, the characteristic 1 of the standard audio corresponds to the model of the audio device a, the state of the earplug X1, and the identification of the earphone 21.
[0096] Similarly, the characteristics of other standard audio in Table 2 can also be obtained based on steps a1 to a3 described above. For example, by replacing earplug X1 with earplug X2 in steps b1 to b3, characteristic 2 of the standard audio in Table 2 can be determined. Earplug X1 can be an undamaged earplug with material 1 and size 2. As another example, by replacing speaker 21b with speaker 22b in steps b1 to b3, characteristic 7 of the standard audio in Table 2 can be determined. Optionally, the earplug and speaker mentioned in steps b1 to b3 can be replaced simultaneously to determine the characteristics of the standard audio in Table 2.
[0097] In other words, each time steps b1 to b3 are executed, a standard audio characteristic corresponding to the characteristics of the earphones used in the execution process and the headphone identifier of the headphone to which the speaker belongs can be obtained.
[0098] Steps b1 to b3 described above can be performed by audio device a. Optionally, step b3 can also be performed by a server. The characteristics of the standard audio shown in Table 2 can be obtained by repeatedly executing steps b1 to b3, with different earbud configurations and different headphones in audio device a playing the specific audio, provided that the model of audio device a is the same as that of audio device 100.
[0099] To reduce the impact of the surrounding environment on the accuracy of acquiring the characteristics of the aforementioned standard audio, the earpieces, speakers, and microphone of the audio device a should be in a sealed environment when performing steps a1 and a2, or steps b1 and b2. For example, when performing steps a1 and a2, or steps b1 and b2, the earphones 21 and / or 22 of the audio device a should be in the storage compartment 23, and the storage compartment 23 should be closed.
[0100] The following describes how to detect whether storage compartment 23 is in an open or closed state.
[0101] Detecting whether storage compartment 23 is in an open or closed state can be understood as detecting the open / closed state of storage compartment 23.
[0102] A status detection magnet may be installed in the storage compartment cover 23b. The storage compartment body 23a may include a first magnetic field sensor, which can be used to detect the magnetic flux of the status detection magnet in the storage compartment cover 23b. The magnetic flux of the status detection magnet detected by the first magnetic field sensor is proportional to the distance between the first magnetic field sensor and the status detection magnet. The magnetic flux detected by the first magnetic field sensor is at its maximum when the storage compartment 23 is closed; the magnetic flux detected by the first magnetic field sensor is at its minimum when the storage compartment 23 is fully open.
[0103] As the storage compartment 23 gradually opens from a closed state, the distance between the first magnetic field sensor and the state detection magnet gradually increases, and the magnetic flux detected by the first magnetic field sensor tends to decrease. When the magnetic flux detected by the first magnetic field sensor is less than a first threshold value, the storage compartment can be considered to be in an open state.
[0104] Conversely, as the storage compartment 23 gradually closes from the open state, the distance between the first magnetic field sensor and the state detection magnet gradually decreases, and the magnetic flux detected by the first magnetic field sensor tends to increase. When the magnetic flux detected by the first magnetic field sensor exceeds the second threshold value, the storage compartment 23 can be considered to be in the closed state.
[0105] In one possible implementation, the positions of the first magnetic field sensor and the state detection magnet can be interchanged. That is, the first magnetic field sensor can be in the storage compartment cover 23b, and the state detection magnet can be in the storage compartment body 23a.
[0106] The opening and closing state of the storage compartment 23 can be detected not only by the aforementioned state detection magnet and the first magnetic field sensor, but also by other detection methods. For example, paired contact detection springs can be configured on the storage compartment body 23a and the storage compartment cover 23b, and the state of the storage compartment 23 can be determined based on the detected contact. As another example, paired infrared transmitters and receivers can be configured on the storage compartment body 23a and the storage compartment cover 23b, and the state of the storage compartment 23 can be determined based on the received signal strength.
[0107] The following describes how to detect whether earphones 21 and / or earphones 22 are in storage compartment 23.
[0108] The aforementioned detection of whether earphones 21 and / or 22 are in the storage compartment 23 can be referred to as presence detection. The presence state of audio device a can include: both ears in the compartment, one ear in the compartment, and neither ear in the compartment. For example, the state of one ear in the compartment can be further divided into the state of earphone 21 in the compartment and the state of earphone 22 in the compartment.
[0109] In one possible implementation, the presence detection can be performed by the storage compartment 23. The storage compartment 23a may have a magnetic field sensor, referred to as a second magnetic field sensor, for detecting changes in the magnetic flux of the headphone magnet in the audio device a. Further, the storage compartment 13b may be equipped with two second magnetic field sensors, respectively used to detect the presence status of headphones 21 and 22. The magnetic flux of the headphone magnet detected by the second magnetic field sensor may be proportional to the distance between the second magnetic field sensor and the headphone magnet. When the magnetic flux detected by the second magnetic field sensor is large, for example, greater than a certain threshold, the headphones are considered to be in the storage compartment; when the magnetic flux detected by the second magnetic field sensor is small, for example, less than a certain threshold, the headphones are considered to be out of the storage compartment.
[0110] In another possible implementation, the presence detection can be performed by earphones 21 and 22. Earphones 21 and 22 may have a magnetic field sensor, referred to as a third magnetic field sensor, for detecting changes in the magnetic flux of the state-detection magnet in the storage compartment 23a. The magnetic flux detected by the third magnetic field sensor may be proportional to the distance between the third magnetic field sensor and the state-detection magnet. When the earphones are in the compartment, the magnetic flux detected by the third magnetic field sensor is larger, for example, greater than a certain threshold; when the earphones are not in the compartment, the magnetic flux detected by the third magnetic field sensor is smaller, for example, less than the certain threshold.
[0111] In addition to the features of the standard audio shown in Table 1 above, the audio device 100 can also acquire features of the standard audio corresponding to the in-situ state. For example, Table 3 illustrates the features of the standard audio acquired by the audio device 100 corresponding to the headphone state and the in-situ state.
[0112]
[0113] Table 3
[0114] Referring to Table 3, the audio device 100 acquires 12 standard audio characteristics. Among them, the device model corresponding to characteristic 1 is the model of the audio device 100, the corresponding earphone characteristics are material 1, size 1, undamaged, and the corresponding in-situ state is single ear in the chamber, etc.
[0115] In this embodiment of the application, Table 3 above is only an illustrative example. The audio device 100 can also acquire more features of standard audio, and the features of standard audio can also correspond to more features of earphones. This is not a limitation.
[0116] In other words, in this case, the characteristics of a standard audio corresponds to the model of an audio device, the characteristics of an earphone, and the state of being in place.
[0117] The specific process for obtaining the features of the standard audio shown in Table 3 is similar to the specific process for obtaining the features of the standard audio shown in Table 1.
[0118] The difference lies in the fact that before obtaining the features of the standard audio shown in Table 3, it is necessary to determine whether the in-situ state is single-ear or dual-ear. If the in-situ state is single-ear, then the in-situ state corresponding to the features of the standard audio obtained after performing steps a1 to a2 above is single-ear in-situ. If the in-situ state is dual-ear, then the in-situ state corresponding to the features of the standard audio obtained after performing steps a1 to a2 above is dual-ear in-situ. For example, feature 1 of the standard audio shown in Table 3 is obtained when the audio device a is equipped with earbud X1 in single-ear mode.
[0119] In addition to the features of the standard audio shown in Table 2 above, the audio device 100 can also acquire features of the standard audio corresponding to an in-situ state. For example, Table 4 illustrates the features of the standard audio acquired by the audio device 100 corresponding to headphone status, in-situ state, and headphone identifier.
[0120]
[0121]
[0122] Table 4
[0123] Referring to Table 4, the audio device 100 acquires 16 standard audio characteristics. Among them, the device model corresponding to characteristic 1 is the model of the audio device 100, the corresponding earbud characteristics are material 1, size 1, undamaged, the corresponding headphone identifier is identifier 1, and the corresponding presence status is single ear in the compartment, etc.
[0124] In this embodiment of the application, Table 4 above is only an illustrative example. The audio device 100 can also acquire more features of standard audio, and the features of standard audio can also correspond to more features of earphones. This is not limited.
[0125] In other words, in this case, the characteristics of a standard audio corresponds to the model of an audio device, the characteristics of an earphone, a headphone identifier, and an in-situ status.
[0126] The specific process for obtaining the features of the standard audio shown in Table 4 differs from the specific process for obtaining the features of the standard audio shown in Table 2. Before obtaining the features of the standard audio shown in Table 4, it is necessary to determine whether the in-situ state is single-ear or dual-ear. If the in-situ state is single-ear, the in-situ state corresponding to the features of the standard audio obtained after executing steps b1 to b2 above is single-ear. If the in-situ state is dual-ear, the in-situ state corresponding to the features of the standard audio obtained after executing steps b1 to b2 above is dual-ear. For example, feature 1 of the standard audio shown in Table 4 is obtained when the earphone 21 of audio device a is equipped with earplugs X1 in a single-ear configuration.
[0127] In some implementations, the characteristics of the standard audio of the audio device 100 may include one or more of the following: the characteristics of the standard audio shown in Table 1, the characteristics of the standard audio shown in Table 2, the characteristics of the standard audio shown in Table 3, and the characteristics of the standard audio shown in Table 4. In the embodiments of this application, the characteristics of the standard audio stored by the audio device 100 may also be referred to as the characteristics of the standard audio data.
[0128] The method for earplug detection provided in the embodiments of this application is described below.
[0129] Figure 2 illustrates a schematic flowchart of a method for detecting earplugs according to an embodiment of this application. The method includes:
[0130] S201, the audio device 100 plays the first audio through a speaker.
[0131] In some implementations, after acquiring the characteristics of the standard audio of various audio devices 100, the audio device 100 determines the in-situ state of the audio device 100 and whether the storage compartment 13 is in a closed state before executing S201.
[0132] Specifically, the audio device 100 will only begin executing S201 when it is in a dual-ear or single-ear configuration and the storage compartment 13 is closed. This allows for audio playback in a sealed environment, preventing the surrounding environment from affecting the determined earbud characteristics and reducing errors during the execution of S203.
[0133] For instructions on how to determine whether storage compartment 13 is in a closed state, please refer to the above description regarding determining whether storage compartment 23 is in a closed state. For instructions on how to determine the presence status of audio device 100, please refer to the above description regarding detecting the presence status of audio device a, and will not be repeated here.
[0134] In some implementations, the audio device 100 can play the first audio through either speaker 11b or speaker 12b. Specifically, if both earphones 11 and 12 are located in the storage compartment 13, the audio device 100 can play the first audio through either speaker 11b or speaker 12b. If earphone 11 is located in the storage compartment 13 but earphone 12 is not, the audio device 100 can play the first audio through speaker 11b. If earphone 12 is located in the storage compartment 13 but earphone 11 is not, the audio device 100 can play the first audio through speaker 12b.
[0135] The first audio mentioned above is the same audio as the specific audio in steps a1 and b1 mentioned above.
[0136] S202, Audio device 100 acquires a second audio signal via a microphone.
[0137] The aforementioned microphone can be referred to as a feedback microphone (FB MIC). The second audio signal is the audio received after the first audio signal has passed through an earpiece configured in the audio device 100.
[0138] In some implementations, the audio device 100 can acquire the second audio through either microphone 11a or microphone 12a. Specifically, if both earphones 11 and 12 are located in the storage compartment 13, the audio device 100 can acquire the second audio through either microphone 11a or microphone 12a. If earphone 11 is located in the storage compartment 13 but earphone 12 is not, the audio device 100 can acquire the second audio through microphone 11a. If earphone 12 is located in the storage compartment 13 but earphone 11 is not, the audio device 100 can acquire the second audio through microphone 12a. This method of acquiring audio in a closed environment avoids the influence of the surrounding environment on the determined characteristics of the earphones, reducing errors during the execution of S203.
[0139] In one possible implementation, the structure of the storage compartment 13 restricts the microphone used in S202. If the space in the storage compartment 13 that houses the earphone 11 is the same space as the space that houses the earphone 12, the audio device 100 can capture the second audio through either microphone 11a or microphone 12a. If the space in the storage compartment 13 that houses the earphone 11 is two separate spaces from the space that houses the earphone 12, then if the first audio in S201 is played by speaker 11b, the audio device 100 captures the second audio only through microphone 11a; if the first audio in S201 is played by speaker 12b, the audio device 100 captures the second audio only through microphone 12a.
[0140] S203, the audio device 100 determines the characteristics of the earphone disposed in the audio device 100 based on the characteristics of the second audio.
[0141] Specifically, the audio device 100 determines the characteristics of the earpiece disposed in the audio device 100 based on the characteristics of the second audio and the characteristics of the standard audio.
[0142] In some implementations, before executing S201, the audio device 100 has acquired the characteristics of various standard audios of the audio device 100. These standard audios include: the audio of a specific audio source after a first audio source is played by an audio device a equipped with undamaged earplugs of different materials and sizes, and the audio source after passing through the undamaged earplugs. For details, please refer to the characteristics of the standard audios shown in Tables 1, 2, and 3 above. How to acquire the characteristics of the standard audios of various audio devices 100 can be found in the above-mentioned descriptions and will not be repeated here. Before executing S203, the audio device 100 can acquire the characteristics of the second audio source based on the second audio source.
[0143] In some implementations, since the second audio signal passes through an earplug in the audio device 100, the second audio signal may be affected by the earplug configured in the audio device 100. Different earplug states may have different degrees of influence on the second audio signal. For the above considerations, the characteristics of the earplug configured in the audio device 100 can be determined based on the characteristics of the second audio signal and the characteristics of the standard audio signal.
[0144] The following describes how to determine the characteristics of the earpieces configured in the audio device 100.
[0145] Specifically, the audio device 100 compares the features of the second audio with the features of the acquired multiple standard audios.
[0146] If a standard audio (referred to as standard audio a) is determined from a variety of standard audios whose features are most similar to those of the second audio (for example, standard audio a whose features are more similar to those of the second audio than the value 'a'), then it can be determined that the features of the earphone configured in the audio device 100 are completely or partially consistent with the features of the earphone corresponding to the standard audio a. That is, by executing S203, it can be determined that the material of the earphone configured in the audio device 100 is consistent with the material of the earphone corresponding to the standard audio a; or, it can be determined that the size of the earphone configured in the audio device 100 is consistent with the size of the earphone corresponding to the standard audio a; or, it can be determined that the damage condition of the earphone configured in the audio device 100 is consistent with the damage condition of the earphone corresponding to the standard audio a, meaning neither is damaged; or, it can be determined that the material, size, and damage condition of the earphone configured in the audio device 100 are consistent with the material, size, and damage condition of the earphone corresponding to the standard audio a.
[0147] In one possible implementation, the audio device 100 can determine that the material of the earbud disposed in the audio device 100 is the same as the material of the earbud corresponding to standard audio b, wherein the similarity of the features of the second audio to standard audio b is greater than the value of b. The audio device 100 can also determine that the size of the earbud disposed in the audio device 100 is the same as the size of the earbud corresponding to standard audio c, wherein the similarity of the features of the second audio to standard audio c is greater than the value of c. The values a, b, and c can all be the same, all pairs of values can be the same, or all values can be different. The specific values of a, b, and c can be determined based on the features of various standard audios of the audio device 100.
[0148] In other words, when the audio device 100 determines the features of the earphone, the similarity value (e.g., value a) used when executing S203 once to determine all the features of the earphone can be the same as or different from the similarity value (e.g., value b, value c) used when executing S203 once to determine only one of the features of the earphone.
[0149] If none of the multiple standard audio samples has features most similar to the features of the second audio sample, for example, if the similarity between the features of any of the multiple standard audio samples and the features of the second audio sample is less than the value d, then it can be determined that the earpiece configured in the audio device 100 is damaged. The value d can be the same as, or different from, the values a, b, and c mentioned above, or it can be any one of them; there is no limitation on this. In some implementations, the value a can be referred to as the first threshold and the second threshold, and the value d can be referred to as the third threshold. Optionally, the value b can be referred to as the first threshold, and the value c can be referred to as the second threshold.
[0150] In one possible implementation, if none of the multiple standard audio samples has characteristics most similar to the second audio sample, it can be understood as an earbud malfunction in the audio device 100. An earbud malfunction in the audio device 100 may include one or more of the following: the earbud in the audio device 100 is broken; the size and material of the earbud in the audio device 100 are different from the size and material corresponding to the standard audio sample; or the speaker and / or microphone in the audio device 100 malfunctions. In this embodiment, the above-mentioned earbud malfunction scenarios are only illustrative and may include more or fewer scenarios.
[0151] The following describes how to determine the characteristics of the earphones configured in the audio device 100 when the characteristics of the audio are frequency response curves.
[0152] In some implementations, the characteristics of audio may include the frequency response curve of the audio. The similarity of the characteristics of two audio files may include the similarity of their frequency response curves. Specifically, the similarity of the frequency response curves of two audio files may refer to the ratio of the frequency band range where the amplitude difference between the two frequency response curves at each frequency band is less than a first preset amplitude difference to the total frequency band range. The similarity of the frequency response curves of two audio files may also refer to the ratio of the frequency band range where the amplitude difference between the two frequency response curves at each frequency band within a specific frequency band range is less than a second preset amplitude difference to the total frequency band range.
[0153] Generally, the frequency range audible to the human ear is 20Hz to 20kHz. The aforementioned "all frequency bands" can refer to 20Hz to 20kHz, 0Hz to 15kHz, or other frequency bands, depending on the algorithm used to obtain the frequency response curve of the audio or the computational power of the processing unit. To reduce computational load, a specific frequency band range can be a portion of the aforementioned "all frequency bands," and this characteristic frequency band range can be the frequency band range that has a significant impact on the audio audible to the human ear. For example, when the "all frequency bands" are 20Hz to 20kHz, the specific frequency band range can refer to 20Hz to 10kHz. The aforementioned first preset amplitude difference is generally set relatively small, for example, 1dB. In the embodiments of this application, the aforementioned "all frequency bands," "specific frequency bands," and "first preset amplitude difference" are merely illustrative examples and are not intended to limit the scope of the application.
[0154] For example, in the case that the entire frequency range is 20Hz to 20kHz, the first preset amplitude difference is 1dB, and the value of a is 98%, the similarity between the features of the standard audio a and the features of the second audio is less than the value of a can mean that the proportion of the frequency range in which the amplitude difference between the frequency response curve of the standard audio a and the frequency response curve of the second audio is less than 1dB in each frequency band is less than 98% in the 20Hz to 20kHz range.
[0155] For example, in the case that the entire frequency range is 20Hz to 20kHz, the first preset amplitude difference is 1dB, and the d value is 95%, the similarity between the characteristics of any standard audio and the characteristics of the second audio among multiple standard audios is less than the d value can mean that the proportion of the frequency response curve of any standard audio among multiple standard audios with an amplitude difference of less than 1dB in each frequency band is less than 95% in the range of 20Hz to 20kHz.
[0156] The method for determining the similarity of the frequency response curves of two audio files is not limited to the specific method described above. Other methods include: calculating the Euclidean distance; employing a dynamic time warping algorithm; determining cross-correlation; comparing feature points, which may include peaks, valleys, etc.; extracting parameters that represent the frequency response curves through model fitting and comparing the differences in these parameters. This application does not limit the scope of this method.
[0157] In the embodiments of this application, the audio features may also include other features, which are not limited thereto.
[0158] Furthermore, the specific content corresponding to the characteristics of the standard audio of the audio device 100 will affect the characteristics of the standard audio used in S203 and the characteristics of the determined earphone. The speaker (e.g., speaker 11b or speaker 12b) used by the audio device 100 in S201 will also affect the characteristics of the standard audio used in S203 and the characteristics of the determined earphone.
[0159] The following describes how the characteristics of the standard audio used in S203 and the characteristics of the determined earphones are affected.
[0160] When the characteristics of the standard audio of the audio device 100 only correspond to the model of the audio device 100 and the characteristics of the earphone, without corresponding headphone identification and presence status, that is, when the audio device 100 obtains the characteristics of the standard audio shown in Table 1 above, the audio device 100 can determine the characteristics of the earphone to which the speaker playing the first audio belongs. For example, if the audio device 100 plays the first audio through the speaker 11b, the characteristics of the standard audio used in S203 are the six characteristics from feature 1 to feature 6 in Table 1, and the characteristics of the earphone determined in S203 are the characteristics of the earphone disposed on the headphone 11.
[0161] Optionally, when the audio device 100 acquires the characteristics of the standard audio shown in Table 1 above, the audio device 100 does not need to consider which speaker the audio device 100 is using to play the first audio in S201. Instead, it can directly determine the characteristics of all earbuds configured in the audio device 100 in S203. For example, if the audio device 100 plays the first audio through speaker 11b or speaker 12b, then the earbud characteristics determined in S203 are the characteristics of the earbuds configured on headphone 11 and headphone 12. This reduces the computational load and allows for the determination of all earbud characteristics at once. This is based on the consideration that when a user knows the earbud characteristics and considers replacing the earbuds, they generally replace both earbuds on both headphones with new ones.
[0162] When the characteristics of the standard audio of the audio device 100 correspond to the model of the audio device 100 and the characteristics of the earphones, and also correspond to the headphone identifier, that is, when the audio device 100 obtains the characteristics of the standard audio shown in Table 2 above, the audio device 100 needs to consider in S201 which speaker the audio device 100 is playing the first audio through, for example, whether the first audio is played through speaker 11b or speaker 12b. Then, the audio device 100 can determine the characteristics of the earphones to which the speaker playing the first audio belongs.
[0163] Specifically, if the audio device 100 plays the first audio through a speaker in a single earphone, the features of the standard audio used in S203 correspond to the earphone identifier of the single earphone, and the features of the earbud determined in S203 are the features of the earbud configured on the single earphone. For example, if the audio device 100 plays the first audio through speaker 11b, the features of the standard audio used in S203 are features 1-6 (a total of 6 features) in Table 2, and the features of the earbud determined in S203 are the features of the earbud configured on earphone 11. If the audio device 100 plays the first audio through speaker 12b, the features of the standard audio used in S203 are features 7-12 (a total of 6 features) in Table 2, and the features of the earbud determined in S203 are the features of the earbud configured on earphone 12.
[0164] When the characteristics of the standard audio of the audio device 100 correspond to the model of the audio device 100 and the characteristics of the earphone, and also correspond to the in-situ state, that is, when the audio device 100 obtains the characteristics of the standard audio shown in Table 3 above, the audio device 100 needs to determine the in-situ state of the audio device 100 at this time when executing S201, such as both ears in the charging case or one ear in the charging case. Then, the audio device 100 can determine the characteristics of the earphone to which the speaker playing the first audio belongs.
[0165] If the audio device 100 plays the first audio through a speaker in a single earphone, and the in-situ state is single earphone in the storage compartment, then the features of the standard audio used in S203 correspond to the in-situ state of single earphone in the storage compartment, and the features of the earbud determined in S203 are the features of the earbud disposed on the single earphone. For example, if the audio device 100 plays the first audio through speaker 11b, and earphone 11 is located in the storage compartment 13 while earphone 12 is not located in the storage compartment 13, then the features of the standard audio used in S203 are features 1-6 (a total of 6 features) in Table 3, and the features of the earbud determined in S203 are the features of the earbud disposed on earphone 11. If the audio device 100 plays the first audio through speaker 12b, and earphone 12 is located in the storage compartment 13 while earphone 11 is not located in the storage compartment 13, then the features of the standard audio used in S203 are features 1-6 (a total of 6 features) in Table 3, and the features of the earbud determined in S203 are the features of the earbud disposed on earphone 12.
[0166] If the audio device 100 plays the first audio through a speaker in a single earphone, and the in-situ state is binaural, then the features of the standard audio used in S203 correspond to the in-situ state of binaural, and the features of the earbud determined in S203 are the features of the earbud disposed on the single earphone. For example, if the audio device 100 plays the first audio through speaker 11b, and both earphones 11 and 12 are located in the storage compartment 13, then the features of the standard audio used in S203 are features 7-12 (a total of 6 features) in Table 3, and the features of the earbud determined in S203 are the features of the earbud disposed on earphone 11. If the audio device 100 plays the first audio through speaker 12b, and both earphones 11 and 12 are located in the storage compartment 13, then the features of the standard audio used in S203 are features 7-12 (a total of 6 features) in Table 3, and the features of the earbud determined in S203 are the features of the earbud disposed on earphone 12.
[0167] When the characteristics of the standard audio of the audio device 100 correspond to the model of the audio device 100 and the characteristics of the earphone, and also correspond to the headphone identification and the in-situ status, that is, when the audio device 100 obtains the characteristics of the standard audio shown in Table 4 above, the audio device 100 needs to consider in S201 which speaker the audio device 100 is using to play the first audio and the in-situ status of the audio device 100 at this time. Then, the audio device 100 can determine the characteristics of the earphone to which the speaker playing the first audio belongs.
[0168] If the audio device 100 plays the first audio through a speaker in a single earphone, and the in-situ state is single earphone in the storage compartment, then the features of the standard audio used in S203 correspond to the earphone identifier of the single earphone and the in-situ state of single earphone in the storage compartment. Furthermore, the features of the earbud determined in S203 are the features of the earbud configured on the single earphone. For example, if the audio device 100 plays the first audio through speaker 11b, and earphone 11 is located in the storage compartment 13 while earphone 12 is not located in the storage compartment 13, then the features of the standard audio used in S203 are the six features listed in Table 3 (features 1-4), and the features of the earbud determined in S203 are the features of the earbud configured on earphone 11.
[0169] If the audio device 100 plays the first audio through a speaker in a single earphone, and the in-situ state is binaural, then the features of the standard audio used in S203 correspond to the earphone identifier of the single earphone and the in-situ state of binaural. Furthermore, the features of the earbud determined in S203 are those of the earbud disposed on the single earphone. For example, if the audio device 100 plays the first audio through speaker 11b, and both earphones 11 and 12 are located in the storage compartment 13, then the features of the standard audio used in S203 are the four features (features 9-12) in Table 4, and the features of the earbud determined in S203 are those of the earbud disposed on earphone 11.
[0170] In this way, the audio device 100 can determine the characteristics of the earphone more precisely based on the features of the second audio and the features of the standard audio, resulting in more accurate determination of the earphone's characteristics. Furthermore, the audio device 100 does not need to compare all the acquired features of the standard audio with the features of the second audio, reducing the computational load.
[0171] It is worth noting that during the execution of S201 to S203, the storage compartment 13 remains closed. If the audio device 100 detects a change in the opening or closing state of the storage compartment 13 during the execution of S201 to S203, it terminates the process shown in Figure 2. For example, during the execution of S201 to S203, the audio device 100 may receive a user operation, and the storage compartment 13 switches from the closed state to the open state. At this time, the audio device 100 terminates the process shown in Figure 2. In this way, terminating the process after the storage compartment 13 switches to the open state can reduce the impact of the surrounding environment on the execution result. The audio device 100 can wait until it switches to the closed state again before determining whether to re-execute the process shown in Figure 2. Furthermore, after the user opens the storage compartment 13, they may use the headphones 11 and / or headphones 12; terminating the above process can also avoid affecting the user's normal use of the audio device 100.
[0172] In one possible implementation, the executing entity of S203 is not limited to the audio device 100; the executing entity of S203 can also be a server.
[0173] In this scenario, the audio device 100 does not need to acquire the characteristics of its standard audio before executing S201. The server only needs to acquire the characteristics of the audio device 100's standard audio before executing S203. After executing S202, the audio device 100 can send the acquired second audio to the server. The server then acquires the characteristics of the second audio based on the second audio and compares these characteristics with the characteristics of the audio device 100's standard audio to determine the characteristics of the earphones configured in the audio device 100. Furthermore, after executing S202, the audio device 100 can also send playback information to the server. This playback information may include: the earphone identifier of the headphones to which the speaker used by the audio device 100 in executing S201 belongs, and the presence status of the audio device 100.
[0174] Similarly, furthermore, the specific content corresponding to the standard audio characteristics of the audio device 100 obtained by the server will affect the characteristics of the standard audio used by the server when executing S203, and the characteristics of the determined earphone. The playback information sent by the audio device 100 will also affect the characteristics of the standard audio used by the server when executing S203, and the characteristics of the determined earphone. For details, please refer to the above description of how the characteristics of the standard audio used in S203 and the characteristics of the determined earphone are affected, which will not be repeated here.
[0175] In another possible implementation, the executing entity of S203 is not limited to the one described above; it can also be the electronic device 200. The electronic device 200 can be an electronic device that establishes a communication connection with the audio device 100. This communication connection can include wired connections and wireless connections. The wireless connection can be a short-range connection such as a high-fidelity wireless communication (Wi-Fi) connection, Bluetooth connection, infrared connection, NFC connection, or ZigBee connection, or it can be a long-range connection. Long-range connections include, but are not limited to, long-range connections based on mobile networks using 2G, 3G, 4G, 5G, and subsequent standard protocols.
[0176] In this scenario, the audio device 100 does not need to acquire the characteristics of its standard audio before executing S201. The electronic device 200 only needs to acquire the characteristics of the audio device 100's standard audio before executing S203. After executing S202, the audio device 100 can send the acquired second audio to the electronic device 200. Then, the electronic device 200 acquires the characteristics of the second audio based on the second audio and compares these characteristics with the characteristics of the audio device 100's standard audio to determine the characteristics of the earphone configured in the audio device 100. Furthermore, after executing S202, the audio device 100 can also send playback information to the electronic device 200. This playback information may include: the earphone identifier of the headphones to which the speaker used by the audio device 100 in executing S201 belongs, and the presence status of the audio device 100.
[0177] Similarly, furthermore, the specific content corresponding to the characteristics of the standard audio from the audio device 100 acquired by the electronic device 200 will affect the characteristics of the standard audio used by the electronic device 200 when executing S203, and the characteristics of the determined earphone. The playback information sent by the audio device 100 will also affect the characteristics of the standard audio used by the electronic device 200 when executing S203, and the characteristics of the determined earphone. For details, please refer to the above description of how the characteristics of the standard audio used in S203 and the characteristics of the determined earphone are affected, which will not be repeated here.
[0178] Optionally, S204, the audio device 100 outputs a prompt message related to the characteristics of the earpiece.
[0179] In some implementations, after executing S203 above, the audio device 100 may also output a prompt message. This prompt message is related to the characteristics of the determined earphone. Optionally, after executing S203 above, the prompt message may also be output by the electronic device 200. In this way, the user can be informed of the various states of the current earphone, so that the user can replace the earphone later.
[0180] When the audio device 100 outputs a prompt message, the prompt message may be generated by the audio device 100 after the audio device 100 executes S203, or it may be generated by the server and sent to the audio device 100 after the server executes S203, or it may be generated by the electronic device 200 and sent to the audio device 100 after the electronic device 200 executes S203.
[0181] When the electronic device 200 outputs a prompt message, this prompt message may be generated based on a message including earpiece features sent by the audio device 100 to the electronic device 200 after the audio device 100 executes S203; it may also be generated by the server and sent to the electronic device 200 after the server executes S203; or it may be generated by the electronic device 200 itself after executing S203. In this embodiment, the method of generating the above-mentioned prompt message is not limited.
[0182] The aforementioned prompts may include voice prompts, text prompts, etc. When the audio device 100 outputs a prompt, the prompt may be a voice prompt. When the electronic device 200 outputs a prompt, the prompt may be a voice prompt or a text prompt. In this embodiment, the output method of the prompt is not limited.
[0183] In some implementations, the characteristics of the earphone determined in S203 are different, and the above prompt information is also different.
[0184] Specifically, when the determined earbud feature is material A1, if material A1 is different from the preset material A2, a prompt message is generated to suggest updating the earbud material. This prompt message can be referred to as the first message. The preset material A2 can be the material that developers tested and determined to be the most suitable earbud material during the development phase of the audio device 100, or it can be the earbud material A2 that the user sets themselves. For example, the output form of the prompt message can be a voice playback saying "The current earbud material is not good; you can replace it with earbuds of material A2," or it can be a text message displayed in the user interface of the electronic device 200 saying "The current earbud material is not good; you can replace it with earbuds of material A2."
[0185] Specifically, when the determined earbud feature is size B3, if size B3 is different from the preset size B4, a prompt message is generated to suggest updating the earbud size. This prompt message can be referred to as the second message. The preset size B4 can be a user-defined earbud size B4. For example, the prompt message can be output as a voice message saying "The current earbud size is not suitable; you can replace it with earbuds of size B4," or it can be displayed as a text message "The current earbud size is not suitable; you can replace it with earbuds of size B4" in the user interface of the electronic device 200.
[0186] Optionally, when the determined earbud feature is size B1, if size B1 is different from the preset size B2, and the duration of leakage in the audio device 100 exceeds the preset duration, a prompt message is generated to suggest replacing the earbud size. The preset size B2 can be the maximum size B2 of headphones that developers tested could be configured on the audio device 100 during the development phase of the audio device 100, or it can be the maximum size B2 among various sizes of earbuds available on the market for use with various headphones. For example, the prompt message can be output as a voice message saying "The current earbud size is too small; you can replace it with a larger size earbud," or it can be displayed as a text message in the user interface of the electronic device 200 saying "The current earbud size is too small; you can replace it with a larger size earbud."
[0187] When the audio device 100 is placed inside a user's ear canal, and the earplugs mounted on the audio device 100 do not fit snugly into the user's ear canal, the audio device 100 is in a leaky state. The audio device 100 can determine whether it is placed inside the user's ear canal using one or more of the following: a proximity sensor, an infrared distance sensor, a capacitive sensor, and a skin sensor. Specifically, the infrared distance sensor can determine whether it is placed inside the user's ear canal by emitting infrared light and receiving the reflected infrared signal, and by determining the distance between the audio device 100 and the object causing the reflection based on the strength of the infrared signal. The capacitive sensor can determine whether it is placed inside the user's ear canal by detecting the capacitance value of the human body. The skin sensor can determine whether it is placed inside the user's ear canal by distinguishing the ear from other flat surfaces.
[0188] When placed inside a user's ear canal, the audio device 100 can detect whether there is a leakage in real time. The audio device 100 can determine whether the earbuds mounted on it fit the user's ear canal using a pressure sensor or an infrared sensor installed within it. Specifically, the pressure sensor can determine whether there is a leakage by detecting changes in pressure. The infrared sensor can determine whether there is a leakage by emitting infrared light and receiving the reflected infrared signal, and by determining the strength of the infrared signal.
[0189] In the embodiments of this application, the above-described method for determining whether a state of leakage is present is merely illustrative, and other methods may also be included to determine whether a state of leakage is present, without limitation.
[0190] Specifically, when the earbuds are identified as damaged, a prompt message can be generated to suggest replacing them. For example, the prompt message can be output as a voice message saying "The current earbuds are damaged and can be replaced with new ones," or it can be displayed as a text message saying "The current earbuds are damaged and can be replaced with new ones" in the user interface of the electronic device 200.
[0191] In one possible implementation, if the audio device detects that the user has not replaced the earbuds after the earbuds have been determined to be damaged, that is, if the audio device 100 detects the earbuds being damaged again after the earbuds have been determined to be damaged, the audio device 100 can use some algorithms to reduce the impact of the earbud damage on the user's use of the audio device 100.
[0192] Furthermore, the aforementioned prompt information will differ depending on the earphone configured with the earphone whose features are determined in S203. For example, when the earphone configured on the earphone 11 is determined to be damaged, the prompt information is used to indicate that the earphone configured on the earphone 11 is damaged. For example, the output form of the prompt information may be a voice message saying "The current left earphone is damaged and can be replaced with a new earphone," or it may be a text message displaying "The current left earphone is damaged and can be replaced with a new earphone" in the user interface of the electronic device 200.
[0193] In the embodiments of this application, the specific content included in the above prompt information is only for illustrative purposes. Other content can also be used to prompt, and there is no limitation on this.
[0194] Optionally, the software parameters of S205 and audio device 100 can be updated.
[0195] In one possible implementation, if the earphone's material is determined in S203, no prompt message needs to be generated, and the software parameters can be changed. For example, the software parameters may include one or more of the following: impedance matching parameters, frequency response curve compensation parameters, and distortion compensation parameters. The audio device 100 can store multiple software parameters, each corresponding to a specific earphone material. For example, software parameter D1 corresponds to material D1. This correspondence can be determined by the developers during the development phase of the audio device 100. Specifically, when headphones equipped with earphones of material D1 input or output audio, using software parameter D1 yields better results than using other software parameters. Therefore, after the earphone material is determined in S203, the audio device 100 can change the software parameters to those corresponding to the determined earphone material. This improves the performance of the audio device 100 when inputting or outputting audio.
[0196] Furthermore, a software parameter can also correspond to an earbud material and / or an earbud size. In one possible implementation, if the earbud characteristics determined in S203 are the earbud material and / or earbud size, no prompt message may be generated, and the software parameter can be changed. For example, software parameter D2 corresponds to material D2 and / or size D3. This correspondence can be determined by the developers during the development phase of the audio device 100, wherein headphones equipped with earbuds of material D2 and size D3 perform better with software parameter D2 than with other software parameters when inputting or outputting audio.
[0197] In one possible implementation, after the audio device 100 executes the above-described S201-S203 and obtains the characteristics of the earbud disposed in the headphones 11, the earbud detection method provided in this application embodiment may further include: the audio device 100 playing a first audio signal through the speaker 12b of the headphones 12; the audio device 100 acquiring a third audio signal through a microphone, the third audio signal being the audio signal after the first audio signal has passed through the earbud disposed in the headphones 12; and the audio device 100 determining the characteristics of the earbud disposed in the headphones 12 based on the characteristics of the third audio signal and the characteristics of the standard audio signal.
[0198] After the audio device 100 executes the above-described S201-S203 steps and obtains the characteristics of the earbud disposed in the earphone 12, the earbud detection method provided in this application embodiment may further include: the audio device 100 playing a first audio signal through the speaker 11b of the earphone 11; the audio device 100 acquiring a third audio signal through a microphone, the third audio signal being the audio signal after the first audio signal passes through the earbud disposed in the earphone 11; and the audio device 100 determining the characteristics of the earbud disposed in the earphone 11 based on the characteristics of the third audio signal and the characteristics of the standard audio signal.
[0199] In other words, after the audio device 100 obtains the features of the earbud configured in one of the headphones, the audio device 100 can repeatedly execute the above S201-S203 to obtain the features of the earbud configured in another headphone.
[0200] In one possible implementation, when the audio device 100 includes only one earphone, the presence state of the audio device 100 is only divided into one earphone in the earbud and one earphone not in the earbud. The features of the standard audio received by the audio device 100 may only include the features corresponding to the standard audio shown in Table 1. In this case, the earphone detection method provided in this application embodiment includes: the audio device 100 plays a first audio through the speaker of the earphone, and the audio device 100 collects audio through the microphone of the earphone. The collected audio is the audio after the first audio has passed through the earphone configured in the audio device 100. The audio device 100 determines the features of the earphone configured in the audio device 100 based on the features of the collected audio and the features of the standard audio. Furthermore, before playing the first audio, the audio device 100 needs to determine the presence state of the audio device 100 and whether the storage compartment 13 is in a closed state. When the presence state of the audio device 100 is one earphone in the earbud and the storage compartment 13 is in a closed state, the first audio is played.
[0201] By implementing the above method, the characteristics of the earbuds can be determined. Not only can the characteristics of each earbud disposed in the audio device 100 be determined simultaneously, but the characteristics of each earbud disposed in the audio device 100 can also be determined separately. Furthermore, the user can be prompted whether the earbuds need to be replaced. After the user replaces the earbuds according to the prompt, the objective impact on the fit of the audio device 100 can be reduced, thereby improving the user's experience when using the audio device 100.
[0202] The following describes the user interface of some electronic devices 200 provided in the embodiments of this application.
[0203] Figure 3A exemplarily illustrates the user interface before and after the material of the earbuds of the audio device 100 (e.g., headphones M1) is changed from foam to silicone.
[0204] Figures 3A(a) and (b) are both user interfaces used to set the headphones M1 in the electronic device 200. Among them, option 301 in the user interface 300 shown in Figure 3A(a) is the same as option 311 in the user interface 310 shown in Figure 3B(b), both indicating sponge material, and option 302 is the same as option 312, both indicating silicone material.
[0205] First, the electronic device 200 can respond to a click operation on option 301, selecting the material of the earphone M1 as foam, and displaying the user interface 300 showing the selected option 301. During the selection of the earphone material, the earphone M1 establishes a communication connection with the electronic device 200.
[0206] Then, after the electronic device 200 displays the user interface 300, if the user changes the material of the earbud in the earphone M1 to silicone, or if the user selects the wrong material of the earbud in the earphone M1, that is, the material of the earbud in the earphone M1 is silicone, then after the user puts the earphone M1 back into the storage compartment, the audio device 100 can determine that the earbud material of the earphone M1 is silicone according to the earbud detection method provided in the embodiments of this application. At this time, the earphone M1 is disconnected from the electronic device 200.
[0207] Next, after confirming that the earbud material of the earphone M1 is silicone, the earphone M1 can re-establish a communication connection with the electronic device 200. At this time, the electronic device 200 has automatically changed the material of the earphone M1 to silicone and displays the user interface 310. In the user interface 320, option 312 is selected.
[0208] In one possible implementation, the earbud material information shown in Figure 3A is not limited to being presented in the relevant settings interface of the earphone M1, but can also be presented in a pop-up window. The presentation form of the earbud material information only needs to satisfy that the electronic device 200 can present the earbud material information determined by the earphone M1 after establishing a communication connection with the earphone M1, and there is no limitation on this.
[0209] Figure 3B illustrates, for example, the user interface before and after the material of the earbuds of the audio device 100 (e.g., headphones M1) is changed from foam to silicone.
[0210] Figures 3B(a) and (b) are user interfaces in the electronic device 200 that display pop-up information about the material of the earphone M1. Specifically, material information 321 in user interface 320 shown in Figure 3B(a) is consistent with material information 331 in user interface 330 shown in Figure 3B(b), both indicating sponge material; material information 322 is consistent with material information 332, both indicating silicone material.
[0211] First, before the electronic device displays the user interface 320 shown in FIG3B(a), the earphone M1 determines that the earphone material of the earphone M1 is sponge using the earphone detection method provided in the embodiments of this application.
[0212] Then, the earphone M1 establishes a communication connection with the electronic device 200. The electronic device 200 can obtain the earbud material information sent by the earphone M1 and display the user interface 320. In the user interface 320, the material information 321 indicating the sponge material is selected.
[0213] Next, after the user interface 320 is displayed on the electronic device 200, if the user changes the material of the earbuds in the earphone M1 to silicone, then after the user puts the earphone M1 back into the storage compartment, the audio device 100 can determine that the earbud material of the earphone M1 is silicone according to the earphone detection method provided in the embodiments of this application. At this time, the earphone M1 is disconnected from the electronic device 200.
[0214] Finally, after confirming that the earbud material of the earphone M1 is silicone, the earphone M1 can re-establish a communication connection with the electronic device 200. At this time, the electronic device 200 has automatically changed the material of the earphone M1 to silicone and displays the user interface 330. In the user interface 330, the material information 332 indicating silicone is selected.
[0215] In one possible implementation, the earbud material information shown in Figure 3B is not limited to being presented in a pop-up window, but can also be presented in the relevant settings interface of the earphone M1. The presentation form of the earbud material information only needs to satisfy the following: after the electronic device 200 establishes a communication connection with the earphone M1, it can present the earbud material information determined by the earphone M1. There is no limitation on this.
[0216] In this application embodiment, the information used to indicate the possible earbud material of the earphone M1 includes not only the two earbud materials mentioned above, but also more materials. Furthermore, the information on the earbud material can be presented in the form of text, or in other ways such as images, without limitation.
[0217] As shown in Figures 3A and 3B, once the audio device 100 determines the material of the earbuds configured in the audio device 100, it can send this material information to the electronic device 200. If the material of the earbuds configured in the audio device 100 displayed in the electronic device 200 is inconsistent with the determined material, the displayed material information can be replaced with the determined material. In this way, the user can accurately obtain the material information of the earbuds currently in the audio device 100.
[0218] The structure of the audio device 100 provided in the embodiments of this application is described below.
[0219] Figure 4 illustrates a schematic diagram of the structure of an audio device 100 provided in an embodiment of this application.
[0220] The audio device 100 includes headphones 110 and 120, and can be placed in a storage compartment 130. The electronic components of the audio device 100 are mainly concentrated in headphones 110 and 120. Headphone 110 can be headphone 11 as shown in Figure 1A, and headphone 120 can be headphone 12 as shown in Figure 1A. The storage compartment 130 can be the storage compartment 13 as shown in Figure 1A.
[0221] As shown in Figure 4, the earphone 110 may include a processor 111, a magnetic field sensor 112, and an interface 113. The earphone 120 may include a processor 121, a magnetic field sensor 122, and an interface 123. The storage compartment 130 may include a processor 131, a magnet 132, a magnet 133, an interface 134, and an interface 135.
[0222] When the earphone 110 is placed in the storage compartment 130, the interface 134 in the storage compartment 130 can connect to the interface 113 in the earphone 110. The interface 134 can be an electrical connector in the storage compartment 130, such as a communication electrode or charging electrode within the storage compartment 130. The structure of the interface 134 can mate with or contact the interface 113 of the earphone 110 to achieve an electrical connection (or physical connection) between the storage compartment 130 and the earphone 110. The interface 113 can be an electrical connector of the earphone 110, such as a communication electrode or charging electrode at the end of the ear stem of the earphone 110. The interface 113 can be a spring pin, spring contact, conductive block, conductive patch, conductive sheet, pin, plug, contact pad, jack, or socket, etc., within the electrical connector. This application embodiment does not limit the method of setting the interfaces 134 and 113. The processors 131 and 111 can transmit information or charge the battery in the earphone 110 through the interfaces 134 and 113.
[0223] Magnets 132 in the storage compartment 130 can be distributed on the storage compartment cover and / or near the location where the earphones 110 are placed. The positions of the magnets 132 correspond to the positions of the earphones 110 within the storage compartment 130, such that the magnitude of the magnetic induction intensity (e.g., magnetic flux) detected by the magnetic field sensor 112 when the earphones 110 enter and leave the storage compartment 130 is primarily generated by the magnets 132. Similarly, magnets 133 in the storage compartment 130 can be distributed on the cover and / or near the location where the earphones 120 are placed. The positions of the magnets 133 correspond to the positions of the earphones 120 within the storage compartment 130, such that the magnitude of the magnetic induction intensity (e.g., magnetic flux) detected by the magnetic field sensor 122 when the earphones 120 enter and leave the storage compartment 130 is primarily generated by the magnets 133.
[0224] The presence of the earphone 110 can be detected by the magnetic field sensor 112. The presence of the earphone 120 can be detected by the magnetic field sensor 122.
[0225] In some embodiments, a magnetic field sensor may be provided in the storage compartment 130, and magnets may be provided in the earphones 110 and 120. The storage compartment 130 can detect whether the earphones 110 and 120 have entered or left the storage compartment 130 through the magnetic field sensor.
[0226] The method for electrically connecting the earphone 120 to the storage compartment 130 when it is placed in the storage compartment 130 can be referred to the method for electrically connecting the earphone 110 to the storage compartment 130 described above. It will not be repeated here.
[0227] As not shown, the storage compartment 130 may also include a wireless communication module. This module can support data exchange between the storage compartment 130 and other electronic devices via wireless communication methods including Bluetooth, GNSS, WLAN, FM, NFC, and IR. Additionally, the wireless communication module can be connected to an antenna to receive electromagnetic waves, frequency-modulate and filter the signals, and then send the processed signal to the processor 131. The wireless communication module can also receive signals to be transmitted from the processor 131, frequency-modulate and amplify them, and then convert them into electromagnetic waves for radiation via the antenna. The wireless communication module can also work with a wireless charging coil to wirelessly charge the audio device 100.
[0228] As not shown, the storage compartment 130 may also have a power module. The power module can be used to provide power to the storage compartment 130, power the various modules in the storage compartment 130, and support the storage compartment 130 in receiving charging input, etc.
[0229] As not shown, the storage compartment 130 may also have a wireless charging coil to obtain power from an external power source (such as a wireless charging dock) via wireless charging.
[0230] As not shown, the storage compartment cover of storage compartment 130 may also have a magnetic field sensor, and a status detection magnet may be installed in the storage compartment of storage compartment 130. This magnetic field sensor can be used to detect the magnetic flux of the status detection magnet in the storage compartment. The magnitude of this magnetic flux can be used by processor 131 to determine whether storage compartment 130 is in an open or closed state. The positions of the magnetic field sensor and the status detection magnet can be interchanged; that is, the magnetic field sensor can be in the storage compartment, and the status detection magnet can be in the storage compartment cover.
[0231] Figure 4 only illustrates the storage compartment 130 of the audio device 100 provided in this embodiment of the application. In actual applications, the storage compartment 130 may include more or fewer components. Implementation details of the storage compartment 130 can be found in the foregoing chapters, and will not be elaborated upon here.
[0232] The structures of headphones 110 and 120 shown in Figure 4 can be completely identical. Here, we will take headphones 110 as an example to introduce the structure of headphones in the audio device 100.
[0233] As shown in Figure 5, the headset 110 may include a processor 111, a memory 114, a wireless communication module 115, an audio input / output circuit 116, a power module 117, an interface 113, a sensor module 118, etc. The power module 117 may include a power management module 117A and a battery 117B. The interface 113 may include an electrical connector 113A.
[0234] The memory 114 can be used to store program code. For example, program code for charging the headphones 110, wirelessly pairing the headphones 110 with other electronic devices, or wirelessly communicating between the headphones 110 and electronic devices. The memory 114 can also store a Bluetooth address for uniquely identifying the wireless audio device. Additionally, the memory 114 can store connection data of electronic devices previously successfully paired with the headphones 110. For example, this connection data can be the Bluetooth address of an electronic device that has been successfully paired with the headphones 110. Based on this connection data, the headphones 110 can automatically pair with the electronic device without needing to configure the connection, such as performing authentication. The aforementioned Bluetooth address can be a media access control (MAC) address.
[0235] The processor 111 can be used to execute the program code stored in the memory 114, and call relevant modules to implement the functions of the earphone 110 in this embodiment. For example, it can implement the charging function, wireless communication function, audio output function, audio input function, and presence detection function of the earphone 110. Specifically, the processor 111 can be an integrated control chip, or it can be composed of a circuit including various active and / or passive components, and the circuit is configured to perform the functions belonging to the processor 111 described in this embodiment. The processor of the earphone 110 can be a microcontroller unit (MCU).
[0236] In some embodiments, processor 111 may include one or more interfaces. Processor 111 may be connected to other components of headset 110 through these one or more interfaces.
[0237] The wireless communication module 115 can be used to support data exchange between the headset 110 and other electronic devices via wireless communication technologies such as Bluetooth, GNSS, WLAN, FM, NFC, and IR. In some embodiments, the wireless communication module 115 can be a Bluetooth chip. The headset 110 can pair with and establish a wireless connection with the Bluetooth chips of other electronic devices through this Bluetooth chip to achieve wireless communication between the headset 110 and other electronic devices. For example, in this embodiment, the wireless communication module 115 can be used to send prompt information related to the characteristics of the earbuds to the electronic devices that have established a wireless connection (such as a Bluetooth connection) with the headset 110 after the processor 111 determines the characteristics of the earbuds.
[0238] In addition, the wireless communication module 115 can also be connected to an antenna. The wireless communication module 115 receives electromagnetic waves via the antenna, modulates and filters the electromagnetic wave signals, and sends the processed signal to the processor 111. The wireless communication module 115 can also receive signals to be transmitted from the processor 111, modulate and amplify them, and then convert them into electromagnetic waves for radiation via the antenna.
[0239] The audio input / output circuit 116 can be connected to a sound acquisition device such as a microphone to process the sound and convert it into an audio signal, which is then transmitted to the processor for further processing. The audio input / output circuit 116 can also be connected to a sound playback device such as a speaker to convert the audio signal from the processor into a sound output. This enables functions such as making and receiving phone calls, playing music, and using a voice assistant.
[0240] The power module 117 can be used to provide power to the headset 110, power the various modules of the headset 110, and support the headset 110 to receive charging input, etc.
[0241] Interface 113 can be used to provide a wired connection for charging or communication between the earphone 110 and the storage compartment 130. In some embodiments, the earphone 110 may have multiple interfaces 113. In some embodiments, interface 113 may include an electrical connector 113A. When the earphone 110 is placed in the storage compartment 130, the earphone 110 can establish an electrical connection with the electrical connector in the storage compartment 130 through the electrical connector 113A. After the electrical connection is established, the storage compartment 130 can charge the battery 117B in the earphone 110 through the current transmission function of the electrical connector 113A and the electrical connector in the storage compartment 130. For example, the electrical connector 113A can be a spring pin, spring contact, conductive block, conductive patch, conductive sheet, pin, plug, contact pad, jack, or socket, etc. The specific type of electrical connector 113A is not limited in the embodiments of this application.
[0242] The sensor module 118 may include, for example, a proximity light sensor 118A, an infrared sensor 118B, a capacitive sensor 118C, a bone conduction sensor 118D, a pressure sensor 118E, and a magnetic field sensor 112. In some embodiments, the processor 111 may use the proximity light sensor 118A, the infrared sensor 118B, and the capacitive sensor 118C to determine whether the earphone 110 is being worn by a user. In some embodiments, the processor 111 may use the bone conduction sensor 118D to acquire the vibration signal of the acoustic bone block, parse the voice signal, and realize the voice function. In some embodiments, the processor 111 may use the pressure sensor 118E to acquire the pressure change to determine whether there is a leakage. In some embodiments, the processor 111 may determine the presence status of the earphone 110 based on the change in magnetic induction intensity detected by the magnetic field sensor 112. The magnetic field sensor 112 may be a Hall sensor or a magnetometer.
[0243] In some embodiments, the earphone 110 housing may also be provided with a magnet (such as a magnet) for placing the earphone 110 into the storage compartment 130. For example, the outer surface of the earphone 110 may also include components such as buttons, indicator lights (which can indicate battery level, incoming / outgoing calls, pairing mode, etc.), a display screen (which can display relevant information to the user), and a dustproof mesh (which can be used with the earpiece). The buttons may be physical buttons or touch buttons (used in conjunction with a touch sensor), used to trigger operations such as power on, power off, pause, play, record, start charging, and stop charging.
[0244] The structure illustrated in Figure 5 does not constitute a specific limitation on the headset 110. In practical applications, the headset 110 may include more or fewer components than those shown in Figure 4, or combine some components, or separate some components, or have different component arrangements. The components shown in Figure 4 can be implemented in hardware, software, or a combination of software and hardware.
[0245] Figure 6 illustrates, by way of example, a schematic diagram of the software module of the headphones 110 in the audio device 100 provided in this application.
[0246] As shown in Figure 6, the earphone 110 includes: a processing module 410, an audio input module 420, an audio output module 430, a storage module 440, a sensor data acquisition module 450, and a communication module 460.
[0247] The audio output module 430 is used to play the first audio. The audio input module 420 is used to acquire the second audio, which is the audio after the first audio has passed through an earpiece configured in the audio device 100. The processing module 410 is used to obtain the features of the second audio based on the second audio. The processing module 410 can also be used to determine the features configured in the earpiece based on the features of the second audio and the features of the standard audio obtained from the storage module 440. The determined features of the earpiece can represent the features of the earpiece configured in the headphones 110 and / or headphones 120. For details, please refer to the relevant description of S203 above, which will not be repeated here. The determined features of the earpiece may include one or more of the following: the material of the earpiece, its size, and whether it is damaged. Specifically, the processing module 410 can determine the features of the earpiece by comparing the similarity between the features of the second audio and the features of the standard audio.
[0248] Storage module 440 is used to store the characteristics of the standard audio of audio device 100. For example, storage module 440 may store one or more of the following: the characteristics of the standard audio shown in Table 1, the characteristics of the standard audio shown in Table 2, the characteristics of the standard audio shown in Table 3, and the characteristics of the standard audio shown in Table 4.
[0249] The communication module 460 is used to receive the characteristics of standard audio from the audio device 100 sent by the server.
[0250] The sensor data acquisition module 450 is used to acquire various sensor data, such as proximity sensor data, infrared sensor data, capacitive sensor data, bone conduction sensor data, pressure sensor data, and magnetic field sensor data. The processing module 410 is used to determine whether the earphone 110 is located in the user's ear canal based on one or more of the proximity sensor data, infrared sensor data, and capacitive sensor data. The processing module 410 is used to determine whether the earphone 110 is located in the storage compartment 130 based on the magnetic field sensor data. The processing module 410 is used to determine whether the earphone 110 is in a leaking state based on the pressure sensor data.
[0251] The processing module 410 can also be used to generate prompt information based on the determined characteristics of the earpiece. The audio output module 430 is used to output audio based on the prompt information generated by the processing module 410. Optionally, the communication module 460 is used to send the prompt information generated by the processing module 410 to the electronic device 200.
[0252] The processing module 410 can also be used to adjust the software parameters used by the audio device 100. Specifically, when the processing module 410 determines that the earphone's feature is a first feature, it can adjust the software parameters used by the audio device 100 when playing or capturing audio to a first parameter. The first parameter corresponds to the first feature, which includes the size of the first earphone being a first size, and / or the material of the first earphone being a first material.
[0253] Optionally, the communication module 460 is used to receive prompt information generated based on the determined characteristics of the earpiece sent by the server or electronic device 200. The audio output module 430 is used to output audio based on the prompt information received by the communication module 460.
[0254] In some implementations, audio device 100 may be referred to as a first audio device. When audio device 100 includes two headphones, one of the headphones, such as headphone 11, may be referred to as a first sub-audio device, and the other headphone, such as headphone 12, may be referred to as a second sub-audio device. Storage compartments included in audio device 100, such as storage compartment 13, may be referred to as audio device compartments. If the space in storage compartment 13 that houses headphone 11 and the space that houses headphone 12 are two separate spaces, one space may be referred to as the first audio device compartment, and the other space may be referred to as the second audio device compartment.
[0255] The structure of the electronic device 200 provided in the embodiments of this application is described below.
[0256] Figure 7 illustrates a schematic diagram of the structure of an electronic device 200 provided in an embodiment of this application.
[0257] The following description uses electronic device 200 as an example to illustrate the embodiment. It should be understood that the electronic device 200 shown in FIG. 7 is merely an example, and the electronic device 200 may have more or fewer components than those shown in FIG. 7, may combine two or more components, or may have different component configurations. The various components shown in the figure can be implemented in hardware, software, or a combination of hardware and software, including one or more signal processing and / or application-specific integrated circuits.
[0258] For example, electronic device 200 may be a mobile phone, tablet computer, desktop computer, laptop computer, handheld computer, notebook computer, ultra-mobile personal computer (UMPC), netbook, as well as cellular phone, personal digital assistant (PDA), augmented reality (AR) device, virtual reality (VR) device, artificial intelligence (AI) device, wearable device, in-vehicle device, smart home device and / or smart city device. This application embodiment does not impose any special restrictions on the specific type of electronic device 200.
[0259] Electronic device 200 may include: processor 210, external memory interface 220, internal memory 221, universal serial bus (USB) interface 230, charging management module 240, power management module 241, battery 242, antenna 1, antenna 2, mobile communication module 250, wireless communication module 260, audio module 270, speaker 270A, receiver 270B, microphone 270C, headphone jack 270D, sensor module 280, button 290, motor 291, indicator 292, camera 293, display screen 294, and subscriber identification module (SIM) card interface 295, etc. The sensor module 280 may include a pressure sensor 280A, a gyroscope sensor 280B, a barometric pressure sensor 280C, a magnetic sensor 280D, an accelerometer sensor 280E, a distance sensor 280F, a proximity sensor 280G, a fingerprint sensor 280H, a temperature sensor 280J, a touch sensor 280K, an ambient light sensor 280L, a bone conduction sensor 280M, etc.
[0260] It is understood that the structures illustrated in the embodiments of the present invention do not constitute a specific limitation on the electronic device 200. In other embodiments of this application, the electronic device 200 may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
[0261] Processor 210 may include one or more processing units, such as application processor (AP), modem processor, graphics processing unit (GPU), image signal processor (ISP), controller, memory, video codec, digital signal processor (DSP), baseband processor, and / or neural network processing unit (NPU). Different processing units may be independent devices or integrated into one or more processors.
[0262] The controller can be the nerve center and command center of the electronic device 200. The controller can generate operation control signals based on the instruction opcode and timing signals to control the fetching and execution of instructions.
[0263] The processor 210 may also include a memory for storing instructions and data. In some embodiments, the memory in the processor 210 is a cache memory. This memory can store instructions or data that the processor 210 has just used or that are used repeatedly. If the processor 210 needs to use the instruction or data again, it can directly retrieve it from the memory. This avoids repeated accesses, reduces the waiting time of the processor 210, and thus improves the efficiency of the system.
[0264] In some implementations, processor 210 may be used to determine the characteristics of an earpiece configured in audio device 100. Processor 210 may also be used to adjust software parameters used by audio device 100 to a first parameter, which corresponds to the first characteristic, the first characteristic including that the size of the first earpiece is a first size, and / or that the material of the first earpiece is a first material.
[0265] In some embodiments, the processor 210 may include one or more interfaces. Interfaces may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver / transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input / output (GPIO) interface, a subscriber identity module (SIM) interface, and / or a universal serial bus (USB) interface, etc.
[0266] It is understood that the interface connection relationships between the modules illustrated in the embodiments of the present invention are merely illustrative and do not constitute a structural limitation on the electronic device 200. In other embodiments of this application, the electronic device 200 may also employ different interface connection methods or combinations of multiple interface connection methods as described in the above embodiments.
[0267] The charging management module 240 is used to receive charging input from the charger.
[0268] The power management module 241 is used to connect the battery 242, the charging management module 240, and the processor 210. The wireless communication function of the electronic device 200 can be implemented through the antenna 2, the mobile communication module 250, the wireless communication module 260, the modem processor, and the baseband processor.
[0269] Antenna 2 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in electronic device 200 can be used to cover one or more communication frequency bands. Different antennas can also be multiplexed to improve antenna utilization. For example, antenna 2 can be multiplexed as a diversity antenna for a wireless local area network. In some other embodiments, the antenna can be used in conjunction with a tuning switch.
[0270] The mobile communication module 250 can provide solutions for wireless communication, including 2G / 3G / 4G / 5G, applied to the electronic device 200. The mobile communication module 250 may include at least one filter, switch, power amplifier, low noise amplifier (LNA), etc. The mobile communication module 250 can receive electromagnetic waves via the antenna 2, and perform filtering, amplification, and other processing on the received electromagnetic waves before transmitting them to the modem processor for demodulation. The mobile communication module 250 can also amplify the signal modulated by the modem processor and convert it into electromagnetic waves for radiation via the antenna 2. In some embodiments, at least some functional modules of the mobile communication module 250 may be housed in the processor 210. In some embodiments, at least some functional modules of the mobile communication module 250 and at least some modules of the processor 210 may be housed in the same device.
[0271] The modem processor may include a modulator and a demodulator. The modulator modulates the low-frequency baseband signal to be transmitted into a mid-to-high frequency signal. The demodulator demodulates the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After processing by the baseband processor, the low-frequency baseband signal is transmitted to the application processor. The application processor outputs sound signals through an audio device (not limited to speaker 270A, receiver 270B, etc.) or displays images or videos through the display screen 294. In some embodiments, the modem processor may be a separate device. In other embodiments, the modem processor may be independent of the processor 210 and may be housed in the same device as the mobile communication module 250 or other functional modules.
[0272] The wireless communication module 260 can provide solutions for wireless communication applications on the electronic device 200, including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), and infrared (IR) technologies. The wireless communication module 260 can be one or more devices integrating at least one communication processing module. The wireless communication module 260 receives electromagnetic waves via antenna 2, performs frequency modulation and filtering of the electromagnetic wave signals, and sends the processed signal to processor 210. The wireless communication module 260 can also receive signals to be transmitted from processor 210, perform frequency modulation and amplification, and convert them into electromagnetic waves for radiation via antenna 2.
[0273] In some embodiments, the antenna 2 of the electronic device 200 is coupled to the mobile communication module 250, and the antenna 2 is coupled to the wireless communication module 260, enabling the electronic device 200 to communicate with networks and other devices via wireless communication technology. The wireless communication technology may include Global System for Mobile Communications (GSM), General Packet Radio Service (GPRS), Code Division Multiple Access (CDMA), Wideband Code Division Multiple Access (WCDMA), Time Division Code Division Multiple Access (TD-SCDMA), Long Term Evolution (LTE), BT, GNSS, WLAN, NFC, FM, and / or IR technologies, etc. The GNSS may include the Global Positioning System (GPS), the Global Navigation Satellite System (GLONASS), the BeiDou Navigation Satellite System (BDS), the Quasi-Zenith Satellite System (QZSS), and / or satellite-based augmentation systems (SBAS).
[0274] Electronic device 200 implements display functions through a GPU, a display screen 294, and an application processor. The GPU is a microprocessor for image processing, connected to the display screen 294 and the application processor. The GPU is used to perform mathematical and geometric calculations and for graphics rendering. Processor 210 may include one or more GPUs, which execute program instructions to generate or modify display information.
[0275] Display screen 294 is used to display images, videos, etc. Display screen 294 includes a display panel. The display panel can be a liquid crystal display (LCD). The display panel can also be manufactured using organic light-emitting diodes (OLEDs), active-matrix organic light-emitting diodes (AMOLEDs), flexible light-emitting diodes (FLEDs), miniled, microled, micro-oled, quantum dot light-emitting diodes (QLEDs), etc. In some embodiments, electronic device 200 may include two or N displays 294, where N is a positive integer greater than 2.
[0276] In some implementations, display screen 294 can be used to display the user interface shown in Figures 3A and 3B.
[0277] Electronic device 200 can perform shooting functions through ISP, camera 293, video codec, GPU, display screen 294 and application processor.
[0278] The external storage interface 220 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 200. The external memory card communicates with the processor 210 through the external storage interface 220 to perform data storage functions. For example, music, video, and other files can be saved on the external memory card.
[0279] Internal memory 221 can be used to store computer executable program code, which includes instructions. Processor 210 executes various functional applications and data processing of electronic device 200 by running the instructions stored in internal memory 221. Internal memory 221 may include a program storage area and a data storage area. The program storage area may store the operating system, at least one application program required for a function (such as sound playback, image playback, etc.), etc. The data storage area may store data created during the use of electronic device 200 (such as audio data, phonebook, etc.). Furthermore, internal memory 221 may include high-speed random access memory and may also include non-volatile memory, such as at least one disk storage device, flash memory device, universal flash storage (UFS), etc.
[0280] Electronic device 200 can implement audio functions such as music playback and recording through audio module 270, speaker 270A, receiver 270B, microphone 270C, headphone jack 270D, and application processor.
[0281] The sensor module 280 may include a pressure sensor 280A, a gyroscope sensor 280B, a barometric pressure sensor 280C, a magnetic sensor 280D, an accelerometer sensor 280E, a proximity sensor 280G, a fingerprint sensor 280H, a temperature sensor 280J, a touch sensor 280K, an ambient light sensor 280L, a bone conduction sensor 280M, etc.
[0282] Buttons 290 include a power button, volume buttons, etc. Buttons 290 can be mechanical buttons or touch-sensitive buttons. Electronic device 200 can receive button input and generate key signal inputs related to user settings and function control of electronic device 200.
[0283] Motor 291 can generate vibration alerts. Motor 291 can be used for incoming call vibration alerts or for touch vibration feedback. For example, different vibration feedback effects can be corresponding to touch operations applied to different applications (such as taking photos, playing audio, etc.). Motor 291 can also correspond to different vibration feedback effects for touch operations applied to different areas of the display screen 294. Different application scenarios (such as time reminders, receiving messages, alarm clocks, games, etc.) can also correspond to different vibration feedback effects. The touch vibration feedback effect can also be customized.
[0284] Indicator 292 can be an indicator light, which can be used to indicate charging status, power changes, messages, missed calls, notifications, etc.
[0285] The SIM card interface 295 is used to connect a SIM card. The SIM card can be inserted into or removed from the SIM card interface 295 to make contact with or separate from the electronic device 200. The electronic device 200 can support 2 or N SIM card interfaces, where N is a positive integer greater than 2.
[0286] The structure illustrated in Figure 7 does not constitute a specific limitation on the electronic device 200. In other embodiments of this application, the electronic device 200 may include more or fewer components than illustrated, or combine some components, or split some components, or have different component arrangements. The components shown in Figure 5 may be implemented in hardware, software, or a combination of software and hardware.
[0287] The following describes a method for earplug detection provided by an embodiment of this application.
[0288] Figure 8 illustrates a schematic flowchart of an earplug detection method provided in an embodiment of this application.
[0289] The method includes:
[0290] S501. Determine whether the audio device 100 is in the storage compartment and whether the storage compartment is closed.
[0291] When it is determined that the audio device 100 is located inside the storage compartment and the storage compartment is closed, step S503 can be executed. Theoretically, the audio device 100 can play audio even if it is located elsewhere. The reason for determining that the audio device 100 is located inside the storage compartment and that the storage compartment is closed is that the headphone case forms a sealed cavity, within which the acoustic transmission path from the speaker to the microphone is relatively stable. This allows for a more accurate reflection of the influence of the earphone's characteristics on the acquired audio, resulting in a more accurate determination of the earphone's characteristics.
[0292] For instructions on how to determine whether the storage compartment 23 is in a closed state, please refer to the above description regarding whether the storage compartment 23 is in a closed state. For instructions on how to determine whether the audio device 100 is located inside the storage compartment, please refer to the above description regarding the detection of the presence status of the audio device a, which will not be repeated here.
[0293] S502, Play specific audio.
[0294] The specific audio may refer to the first audio. Specifically, the audio device 100 can play the specific audio through the speaker 11b or the speaker 12b. For details, please refer to the relevant description in S201 above, which will not be repeated here.
[0295] S503. Compare the features of the acquired audio with the features of the pre-stored standard audio.
[0296] Before executing S501, the audio device 100 has already executed S503-1.
[0297] S503-1. Obtain the features of the standard audio corresponding to the features of various earphones obtained through modeling.
[0298] Specifically, the characteristics of the standard audio acquired by the audio device 100 may include one or more of the following: the characteristics of the standard audio shown in Table 1, the characteristics of the standard audio shown in Table 2, the characteristics of the standard audio shown in Table 3, and the characteristics of the standard audio shown in Table 4.
[0299] Specifically, the audio device can perform a similarity comparison between the features of the acquired audio (i.e., the second audio) and the features of the standard audio. The similarity of the features of the two audios can include the similarity of their frequency response curves. Specifically, the similarity of the frequency response curves of the two audios can refer to the ratio of the frequency band range where the amplitude difference between the two frequency response curves in each frequency band is less than a first preset amplitude difference to the total frequency band range. The similarity of the frequency response curves of the two audios can also refer to the ratio of the frequency band range where the amplitude difference between the two frequency response curves in each frequency band within a specific frequency band range is less than a second preset amplitude difference to the specific frequency band range. For details on how to perform the similarity comparison, please refer to the relevant description in S203 above; it will not be repeated here.
[0300] S504. Determine the characteristics of the earplugs.
[0301] For details on how to determine the characteristics of the earplugs, please refer to the relevant description in S203 above, which will not be repeated here.
[0302] When the characteristic of the earbud is determined to be the material of the earbud, for example, when the material of the earbud is a first material, if the first material is inconsistent with the target material, the audio device 100 can execute S505.
[0303] When it is determined that the earplug is damaged, the audio device 100 can execute S506.
[0304] When the characteristic of the earbud is determined to be the earbud size, the audio device 100 can execute S507.
[0305] S505, it is recommended that users change the earbud material or change the software parameters.
[0306] When the earbud material differs from the target material, the audio device 100 can output a prompt message to remind the user to change the earbud material to the target material. Alternatively, if the user does not change the earbud material, the audio device 100 can automatically change the software parameters to those corresponding to the determined earbud material. For example, before executing S501, the audio device 100 uses software parameters corresponding to the target material. After executing S505, the audio device 100 uses software parameters corresponding to the first material.
[0307] Furthermore, when the material of the earbud is different from the target material, the audio device 100 can also send a message to the electronic device 200, which then outputs a prompt message. For example, the prompt message output by the electronic device 200 can be referred to the relevant descriptions in Figures 3A and 3B above.
[0308] S506, it is recommended that users replace the ear tips.
[0309] A broken earphone indicates that the current earphone will negatively impact the user's use of the audio device 100. To minimize the impact of a broken earphone, it is advisable to use a complete, unbroken earphone with the audio device 100 whenever possible. Therefore, the audio device 100 can output a prompt message to remind the user to use a complete, unbroken earphone. Furthermore, if the user does not replace the earphone, the audio device 100 can also employ compensation algorithms to reduce the impact of a broken earphone on the audio output or input of the audio device 100.
[0310] S507, it is recommended that users replace the ear tips with larger ones.
[0311] When the size of the earbud is not the maximum size preset in the audio device 100, and the audio device 100 is in a state of leakage for a long time during use, that is, when there is room to replace the current size of the earbud of the audio device 100 with a larger size, and the current size of the earbud of the audio device 100 is too small relative to the user's ear canal, the audio device 100 can output a prompt message to remind the user to adjust the earbud of the audio device 100 to a larger size.
[0312] Optionally, when the earbud size differs from the target size, the audio device 100 can output a prompt message to remind the user to replace the earbuds with earbuds of the target size. Alternatively, if the user does not replace the earbuds, the audio device 100 can automatically change the software parameters to those corresponding to the determined earbud size. For example, before executing S501, the audio device 100 uses software parameters corresponding to the target size. After executing S507, the audio device 100 uses software parameters corresponding to the determined earbud size.
[0313] By implementing the above method, the characteristics of the earbuds can be determined. Not only can the characteristics of each earbud configured in the audio device 100 be determined simultaneously, but they can also be determined separately. Furthermore, the user can be prompted whether the earbuds need to be replaced. After the user replaces the earbuds according to the prompt, the objective impact on the fit of the audio device 100 can be reduced, thereby improving the user's experience when using the audio device 100. Through this solution, the audio device can easily determine the characteristics of the earbuds configured in the earphones inside the case, facilitating timely adjustment of software parameters or replacement of earbuds by the user.
[0314] This application provides an audio device including a microphone, a speaker, a memory, a processor, and a computer program stored in the memory. The processor executes the computer program to implement the above-described earplug detection method.
[0315] This application also provides a computer-readable storage medium storing a computer program, which, when executed by a processor, can implement the steps in the above-described method embodiments.
[0316] This application also provides a computer program product, including a computing program, which, when run on a computer, enables the computer to perform the steps in the various method embodiments described above.
[0317] This application also provides a chip system, which includes a processing circuit interface circuit. The interface circuit receives code instructions and transmits them to the processing circuit. The processing circuit executes the code instructions to enable the chip system to implement the steps of any method embodiment of this application. The chip system can be a single chip or a chip module composed of multiple chips.
[0318] The above-described embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit it. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application.
Claims
1. A method for detecting earplugs, characterized in that, An application is made to a first audio device, the first audio device including a first microphone and a first speaker, the first audio device being configured with a first earpiece, the housing of the first audio device including a first sound outlet, the first earpiece being disposed around the first sound outlet, and the housing of the first audio device further including a first pickup hole. The method includes: the first audio device detecting that the first audio device is located inside an audio device compartment, and the audio device compartment being closed; the first audio device playing a first audio through the first speaker; the first audio device acquiring a second audio through the first microphone; and the first audio device determining the characteristics of the first earpiece based on the characteristics of the second audio.
2. The method according to claim 1, characterized in that, The first audio device determines the feature of the first earbud as a first feature based on the features of the second audio. The method further includes: the first audio device playing sound using a first parameter, the first parameter corresponding to the first feature, the first feature including the size of the first earbud being a first size, and / or the material of the first earbud being a first material.
3. The method according to claim 1 or 2, characterized in that, The first audio device determines the characteristics of the first earbud based on the characteristics of the second audio, specifically including: the first audio device determines the material and / or size of the first earbud based on the similarity between the characteristics of the second audio and the characteristics of standard audio data.
4. The method according to any one of claims 1-3, characterized in that, The first audio device determines the features of the first earbud based on the features of the second audio, specifically including: when the similarity between the features of the second audio and the features of the first standard audio data is greater than a first threshold, the first audio device determines that the material of the first earbud is the first material, and the first standard audio data belongs to standard audio data.
5. The method according to claim 4, characterized in that, After the first audio device determines that the material of the first earbud is the first material, the method further includes: if the first material is different from the target material, the first audio device outputs first information; or, after the first audio device establishes a communication connection with the first electronic device, the first audio device sends a first message to the first electronic device.
6. The method according to claim 5, characterized in that, The first audio device outputs the first information specifically including: after detecting that the user is wearing the first audio device, the first audio device outputs the first information.
7. The method according to any one of claims 1-6, characterized in that, The first audio device determines the features of the first earbud based on the features of the second audio, specifically including: when the similarity between the features of the second audio and the features of the second standard audio data is greater than a second threshold, the first audio device determines that the size of the first earbud is the first size, and the second standard audio data belongs to standard audio data.
8. The method according to claim 7, characterized in that, After the first audio device determines that the size of the first earbud is the first size, the method further includes: if the first size is different from the target size, the first audio device outputs second information; or, after the first audio device establishes a communication connection with the first electronic device, the first audio device sends a second message to the first electronic device.
9. The method according to any one of claims 1-8, characterized in that, The first audio device determines the characteristics of the first earbud based on the characteristics of the second audio, specifically including: when the similarity between the characteristics of the second audio and the characteristics of each standard audio data in the standard audio data is less than a third threshold, the first audio device determines that the first earbud is faulty.
10. The method according to any one of claims 1-9, characterized in that, The first audio device includes a first sub-audio device and a second sub-audio device. The first sub-audio device includes a first microphone and a first speaker. The first sub-audio device is equipped with a first earpiece. The housing of the first sub-audio device includes a first sound outlet and a first sound pickup hole. The second sub-audio device includes a second microphone and a second speaker. The second sub-audio device is equipped with a second earpiece. The housing of the second sub-audio device includes a second sound outlet. The second earpiece is disposed around the second sound outlet. The housing of the second sub-audio device also includes a second sound pickup hole. The method further includes: the first audio device playing the first audio through the second speaker; the first audio device collecting a third audio through the second microphone; and the first audio device determining the characteristics of the second earpiece based on the characteristics of the third audio.
11. The method according to any one of claims 1-9, characterized in that, The first audio device includes a first sub-audio device and a second sub-audio device. The first sub-audio device includes a second microphone and a first speaker. The first sub-audio device is equipped with a first earpiece. The housing of the first sub-audio device includes a first sound outlet and a second sound pickup outlet. The second sub-audio device includes the first microphone and a second speaker. The second sub-audio device is equipped with a second earpiece. The housing of the second sub-audio device includes a second sound outlet. The second earpiece is disposed around the second sound outlet. The housing of the second sub-audio device also includes the first sound pickup outlet. The method further includes: the first audio device playing the first audio through the second speaker; the first audio device collecting a third audio through the second microphone; and the first audio device determining the characteristics of the second earpiece based on the characteristics of the third audio.
12. The method according to any one of claims 10 or 11, characterized in that, The first audio device determines the features of the first earbud based on the features of the second audio, specifically including: the first audio device determining the features of the first earbud based on the similarity between the features of the second audio and the features of standard audio data through the first sub-audio device or the second sub-audio device; the first audio device determines the features of the second earbud based on the features of the third audio, specifically including: the first audio device determining the features of the second earbud based on the similarity between the features of the second audio and the features of standard audio data through the first sub-audio device or the second sub-audio device.
13. The method according to any one of claims 1-2, characterized in that, The characteristics of audio include its frequency response curve.
14. An audio device, characterized in that, The audio device can be housed in an audio device compartment. When the audio device is a first audio device, the first audio device includes a first microphone, a first speaker, and a first earpiece. The housing of the first audio device includes a first sound outlet, and the first earpiece is disposed around the first sound outlet. The housing of the first audio device also includes a first pickup hole. The first audio device further includes a memory, a processor, and computer instructions stored in the memory. The processor executes the computer program to implement the method of any one of claims 1-13.
15. The audio device according to claim 14, characterized in that, The first audio device includes a first sub-audio device and a second sub-audio device. The first sub-audio device includes a second microphone and a first speaker. The first sub-audio device is equipped with a first earpiece. The housing of the first sub-audio device includes a first sound outlet and a first sound pickup hole. The second sub-audio device includes the first microphone and a second speaker. The second sub-audio device is equipped with a second earpiece. The housing of the second sub-audio device includes a second sound outlet. The second earpiece is disposed around the second sound outlet. The housing of the second sub-audio device also includes a second sound pickup hole.
16. The audio device according to claim 14, characterized in that, The first audio device includes a first sub-audio device and a second sub-audio device. The first sub-audio device includes a second microphone and a first speaker. The first sub-audio device is equipped with a first earpiece. The housing of the first sub-audio device includes a first sound outlet and a second sound pickup outlet. The second sub-audio device includes the first microphone and a second speaker. The second sub-audio device is equipped with a second earpiece. The housing of the second sub-audio device includes a second sound outlet. The second earpiece is disposed around the second sound outlet. The housing of the second sub-audio device also includes the first sound pickup outlet.
17. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the method of any one of claims 1-13.
18. A computer program product, characterized in that, The computer program product includes computer instructions that, when executed by a processor, implement the method of any one of claims 1-13.