Earphone insertion detection circuit and electronic device

By introducing a control module and a water ingress detection module into the headphone insertion detection circuit, the problem of false headphone insertion detection was solved, the reliability of the headphone holder was improved, and the cost was reduced.

CN115988375BActive Publication Date: 2026-02-03SHANGHAI WINGTECH INFORMATION TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310064783.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-01-12
Publication Date
2026-02-03
Estimated Expiration
2043-01-12

AI Technical Summary

Technical Problem

Existing headphone insertion detection mechanisms are prone to false detections due to liquid ingress, affecting user experience and increasing costs.

Method used

An earphone insertion detection circuit is adopted, including a control module, a water ingress detection module, an earphone microphone detection module, and a switch module. By detecting the earphone and water ingress, the connection status between the earphone socket and the microphone detection module is controlled to prevent false detection.

Benefits of technology

This improves the reliability of the headphone jack, prevents false detections caused by liquid ingress, enhances the user experience, and reduces costs.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115988375B_ABST
    Figure CN115988375B_ABST
Patent Text Reader

Abstract

The application provides earphone insertion detection circuit and electronic equipment, wherein the earphone insertion detection circuit is connected with an earphone microphone detection module, a water inlet detection module and a switch module through a control module; the switch module is connected with the earphone microphone detection module and an earphone seat; the earphone microphone detection module is connected with the earphone seat; the earphone microphone detection module detects the insertion state of the earphone and the microphone and outputs a first detection signal; the water inlet detection module detects the water inlet condition and outputs a second detection signal; the control module outputs a first control signal to the switch module according to the first detection signal and the second detection signal; and the switch module controls the connection between the earphone seat and the earphone microphone detection module to be in a conduction state or a disconnected state according to the first control signal. The application prevents the earphone seat from being caused by liquid to cause earphone insertion false detection, and improves the reliability of the earphone seat.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of headphone testing, and more particularly to headphone insertion detection circuits and electronic devices. Background Technology

[0002] Headphones are an essential component of modern portable electronic devices, most of which support 3.5mm European standard OMTP (Open Mobile Terminal Platform) or American standard CTIA (Cellular Telecommunications Industry Association) headphones. Both NC (normally closed) and NO (normally opened) type jack headphones use mechanical insertion / removal detection, achieved by comparing the DET pin voltage of the headphone jack with a threshold voltage. However, this mechanism has some drawbacks. For example, NO-type headphone connectors are prone to false detection during protection testing due to liquid ingress, and in actual user use, this can lead to false detection and no sound from the earpiece. Users can only resolve the issue by using speaker mode or sending the device for immediate repair, directly impacting the user experience. Existing technologies can improve these issues by adding a grounding pin to the headphone jack, but this increases costs. Summary of the Invention

[0003] This application provides an earphone insertion detection circuit and electronic device to prevent false earphone insertion detection caused by liquid ingress into the earphone holder, thereby improving the reliability of the earphone holder.

[0004] In a first aspect, this application provides an earphone insertion detection circuit applied to an electronic device. The electronic device includes an earphone holder, and the circuit includes a control module, a water ingress detection module, an earphone microphone detection module, and a switch module. The control module is connected to the earphone microphone detection module, the water ingress detection module, and the switch module, respectively. The switch module is also connected to the earphone microphone detection module and the earphone holder, respectively. The earphone microphone detection module is also connected to the earphone holder. The earphone microphone detection module is used to detect the insertion status of the earphone and microphone in the earphone holder and output a first detection signal. The water ingress detection module is used to detect water ingress into the earphone holder. In the event of a second detection signal being output, the control module outputs a first control signal to the switch module based on the first and second detection signals. The switch module receives the first control signal and controls the connection between the headphone jack and the headphone microphone detection module to be either in a conducting or disconnected state based on the first control signal. Specifically, when the first detection signal indicates that neither the headphone nor the microphone is inserted into the headphone jack, and the second detection signal indicates that water has entered the headphone jack, the switch module controls the connection between the headphone jack and the headphone microphone detection module to be in the disconnected state based on the first control signal.

[0005] In the aforementioned headphone insertion detection circuit, a control module is connected to the headphone microphone detection module, a water ingress detection module, and a switch module. The switch module is also connected to both the headphone microphone detection module and the headphone socket. The headphone microphone detection module is further connected to the headphone socket. This allows the headphone microphone detection module to detect the insertion status of the headphone and microphone in the headphone socket and output a first detection signal. The water ingress detection module detects water ingress into the headphone socket and outputs a second detection signal. Based on the first and second detection signals, the control module outputs a first control signal to the switch module. The switch module controls the connection between the headphone socket and the headphone microphone detection module to be either on or off based on the first control signal. Compared to existing technologies, this application only disconnects the connection between the headphone socket and the headphone microphone detection module when no headphone or microphone is inserted into the headphone socket and water has entered the headphone socket. This prevents false headphone insertion detection due to liquid ingress into the headphone socket and improves the reliability of the headphone socket.

[0006] In one embodiment, the headphone microphone detection module includes a microphone detection submodule and an encoding control submodule. The microphone detection submodule is connected to the microphone pins of the headphone jack and the encoding control submodule. The encoding control submodule is also connected to the control module and the switch module. The microphone detection submodule is used to obtain the voltage of the microphone pins of the headphone jack and output a first level signal. The encoding control submodule is used to detect the level value of the first level signal and send the first detection signal to the control module. When the level value of the first level signal is within a preset voltage threshold, the first detection signal indicates that the microphone is inserted into the headphone jack; when the level value of the first level signal is outside the preset voltage threshold, the first detection signal indicates that the microphone is not inserted into the headphone jack.

[0007] In one embodiment, the headphone microphone detection module further includes a headphone detection submodule, which is connected to the headphone detection pin of the headphone holder and the switch module. The headphone detection submodule is used to obtain the voltage of the headphone detection pin of the headphone holder and output a second level signal. The encoding control submodule is used to detect the level values ​​of the first level signal and the second level signal and send the first detection signal to the control module. Wherein, when the second level signal is low and the level value of the first level signal is outside the preset voltage threshold, the first detection signal indicates that the headphone holder is not plugged in the headphone and the microphone.

[0008] In one embodiment, the headphone microphone detection module further includes a sound detection submodule, which is connected to the channel pins of the headphone jack and the encoding control submodule. The sound detection submodule is used to obtain the voltage of the channel pins of the headphone jack and output a third level signal. The encoding control submodule is used to detect the level values ​​of the first level signal, the second level signal, and the third level signal, and send the first detection signal to the control module. When both the second level signal and the third level signal are low and the level value of the first level signal is within the preset voltage threshold, the first detection signal indicates that the headphone jack is used to insert the headphone and the microphone.

[0009] In one embodiment, the control module is further configured to output a first control signal to the switch module when the second detection signal indicates that there is no water ingress in the earphone holder, the second level signal is high, or the level value of the first level signal is outside the preset voltage threshold, so that the switch module controls the connection between the earphone holder and the earphone microphone detection module to be in the conducting state according to the first control signal.

[0010] In one embodiment, the control module is further configured to, after outputting a first control signal to the switch module to cause the switch module to control the headphone holder and the headphone microphone detection module to be in a disconnected state, and upon detecting a second detection signal indicating that there is no water ingress in the headphone holder, control the switch module to restore the headphone holder and the headphone microphone detection module to a conducting state.

[0011] In one embodiment, the water ingress detection module is disposed outside the earphone insertion hole of the earphone holder, and waterproof foam is also disposed outside the water ingress detection module.

[0012] In one embodiment, when the electronic device is turned on, the control module sends a second control signal to the switch module, so that the switch module controls the connection between the headphone jack and the headphone microphone detection module to be in a conductive state according to the second control signal.

[0013] In one embodiment, the microphone detection submodule is an acoustic-to-electrical converter.

[0014] Secondly, this application provides an electronic device including the aforementioned headphone insertion detection circuit.

[0015] It should be understood that the second aspect of the embodiments of this application is consistent with the technical solution of the first aspect of the embodiments of this application, and the beneficial effects achieved by each aspect and the corresponding feasible implementation are similar, and will not be described again. Attached Figure Description

[0016] Figure 1 This is a schematic diagram of the structure of an electronic device provided in one embodiment of this application;

[0017] Figure 2 This is a schematic diagram of the structure of an earphone insertion detection circuit provided in one embodiment of this application;

[0018] Figure 3 This is a schematic diagram of the structure of an earphone insertion detection circuit provided in one embodiment of this application;

[0019] Figure 4 This is a schematic diagram of the structure of an earphone insertion detection circuit provided in one embodiment of this application;

[0020] Figure 5 This is a schematic diagram of the structure of an earphone insertion detection circuit provided in one embodiment of this application;

[0021] Figure 6 This is a schematic diagram of the structure of an earphone insertion detection circuit provided in one embodiment of this application;

[0022] Figure 7This is a schematic diagram of the structure of an electronic device provided in one embodiment of this application. Detailed Implementation

[0023] The technical solutions in this application will now be described with reference to the accompanying drawings.

[0024] To facilitate a clear description of the technical solutions in the embodiments of this application, the terms "first" and "second" are used in the embodiments of this application to distinguish identical or similar items with essentially the same function and effect. For example, "first instruction" and "second instruction" are used to distinguish different user instructions and do not limit their order. Those skilled in the art will understand that the terms "first" and "second" do not limit the quantity or execution order, and the terms "first" and "second" are not necessarily different.

[0025] It should be noted that, in this application, the words "exemplarily" or "for example" are used to indicate examples, illustrations, or explanations. Any embodiment or design described as "exemplarily" or "for example" in this application should not be construed as being more preferred or advantageous than other embodiments or designs. Specifically, the use of words such as "exemplarily" or "for example" is intended to present the relevant concepts in a specific manner.

[0026] Furthermore, "at least one" refers to one or more, while "more than one" refers to two or more. "And / or" describes the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can mean: A alone, A and B simultaneously, or B alone, where A and B can be singular or plural. The character " / " generally indicates that the preceding and following related objects are in an "or" relationship. "At least one of the following" or similar expressions refer to any combination of these items, including any combination of single or plural items. For example, at least one of a, b, and c can mean: a, or b, or c, or a and b, or a and c, or b and c, or a, b, and c, where a, b, and c can be single or multiple.

[0027] This invention provides an earphone insertion detection circuit, which can be applied to electronic devices such as mobile phones, tablets, laptops, PDAs, mobile internet devices (MIDs), wearable devices, virtual reality (VR) devices, augmented reality (AR) devices, smart screens, artificial intelligence (AI) speakers, earphones, terminals in industrial control, self-driving, remote medical surgery, smart grids, transportation safety, smart cities, smart homes, and personal digital assistants (PDAs). This application does not limit the scope of this invention.

[0028] The aforementioned electronic device includes an earphone holder, which is used to transmit electrical signals from the electronic device to earphones connected to the earphone holder.

[0029] For example, Figure 1 This is a schematic diagram of the system architecture of the electronic device provided in an embodiment of this application. Figure 1 As shown, the electronic device includes components such as a processor 110, a memory 120, a transceiver 130, a display unit 140, an input unit 150, a sensor 160, an audio circuit 170, a power supply module 180, and an earphone jack 190.

[0030] The processor 110 is the control center of the electronic device. It connects various parts of the electronic device via various interfaces and lines. By running or executing software programs and / or modules stored in the memory 120, and by calling data stored in the memory 120, it performs various functions and processes data, thereby providing overall monitoring of the electronic device. Optionally, the processor 110 may include one or more processing units; optionally, the processor 110 may integrate an application processor, which mainly handles operating devices, user interfaces, and application programs. Of course, it may also include other processors, which are not listed here.

[0031] The memory 120 can be used to store software programs and modules. The processor 110 executes various functional applications and data processing of the electronic device by running the software programs and modules stored in the memory 120. The memory 120 mainly includes a program storage area and a data storage area. The program storage area can store the operating device and application programs required for at least one function (such as sound playback function, image playback function, etc.). The data storage area can store data created according to the use of the electronic device (such as audio data, telephone book, etc.). In addition, the memory 120 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, or other volatile solid-state storage device.

[0032] Transceiver 130 can provide solutions for wireless communication applications in electronic devices, including wireless local area networks (WLANs) (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. Transceiver 130 can be one or more devices integrating at least one communication processing module; for example, it can integrate an antenna with a baseband processor, or it can integrate an antenna with a modem processor, etc., without limitation.

[0033] The display unit 140 can be used to display information input by the user or information provided to the user, as well as various menus of the electronic device. The display unit 140 can be configured in the form of a liquid crystal display (LCD), an organic light-emitting diode (OLED), or the like, and is not limited thereto.

[0034] The input unit 150 can be used to receive input numerical or character information, and to generate key signal inputs related to user settings and function control of the electronic device. Specifically, the input unit 150 can collect user operations on or near it and drive corresponding connected devices according to a pre-set program. Furthermore, the input unit 150 may include a touch panel, which can be implemented using various types such as resistive, capacitive, infrared, and surface acoustic wave touch panels. In addition to the touch panel, the input unit 150 may also include other input devices. Specifically, other input devices may include, but are not limited to, one or more of the following: function keys (such as volume control buttons, power buttons, etc.), trackballs, joysticks, etc.

[0035] Electronic devices may also include at least one sensor 160, such as a gyroscope sensor, a motion sensor, and other sensors. Motion sensors may include accelerometers for detecting the magnitude of acceleration in various directions, and when stationary, they can detect the magnitude and direction of gravity, which can be used for applications that identify the posture of electronic devices, such as screen orientation switching, related games, and magnetometer posture calibration. Other sensors that may be configured in electronic devices, such as pressure gauges, barometers, hygrometers, thermometers, infrared sensors, and fingerprint sensors, will not be elaborated upon here.

[0036] The audio circuit 170 may include a speaker and a microphone, providing an audio interface between the user and the electronic device. The audio circuit 170 can convert received audio data into electrical signals and transmit them to the speaker, where the speaker converts them into sound signals for output. On the other hand, the microphone converts collected sound signals into electrical signals, which are received by the audio circuit 170, converted into audio data, and then output to the processor 110 for processing. The audio data is then transmitted via the video circuit to, for example, another electronic device, or output to the memory 120 for further processing.

[0037] The headphone jack 190 is connected to the audio circuit 170. It can transmit the electrical signals converted from the audio data received by the audio circuit 170 to the headphone jack 190, and then output them to the headphones for playback. On the other hand, the headphone jack 190 can convert the collected sound signals into electrical signals and transmit them to the audio circuit 170. After receiving the electrical signals, the audio circuit 170 converts them into audio data, and then outputs the audio data to the processor 110 for processing. After processing, the audio data is sent to another electronic device via the video circuit, or the audio data is output to the memory 120 for further processing.

[0038] The electronic device also includes a power module 180 that supplies power to the various components. Optionally, the power module 180 can be logically connected to the processor 110 through a power management device, thereby enabling functions such as charging, discharging, and power consumption management through the power management device.

[0039] Although not shown, the electronic device may also include a camera. Optionally, the camera may be positioned in the front or rear of the electronic device, and this application embodiment does not limit this.

[0040] It is understood that the structures illustrated in the embodiments of this application do not constitute a specific limitation on the electronic device. In other embodiments of this application, the electronic device 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.

[0041] To make the objectives and technical solutions of this application clearer and more intuitive, the dual-path multiplexing coupler provided in the embodiments of this application will be described in detail below with reference to the accompanying drawings and examples. It should be understood that the specific embodiments described herein are merely illustrative of this application and are not intended to limit this application.

[0042] Figure 2 This is a schematic diagram of an earphone insertion detection circuit according to an embodiment of this application. This circuit can be applied to the above-described... Figure 1 The electronic device shown can also be applied to other scenarios, and this application does not limit the application to these scenarios.

[0043] like Figure 2 As shown, the above-mentioned headphone insertion detection circuit may include a control module 201, a water ingress detection module 202, a headphone microphone detection module 203, and a switch module 204. The control module 201 is connected to the headphone microphone detection module 203, the water ingress detection module 202, and the switch module 204, respectively. The switch module 204 is also connected to the headphone microphone detection module 203 and the headphone socket 190, respectively. The headphone microphone detection module 203 is also connected to the headphone socket 190.

[0044] The headphone and microphone detection module 203 is used to detect the insertion status of the headphone and microphone in the headphone jack 190 and output a first detection signal;

[0045] The water ingress detection module 202 is used to detect water ingress into the earphone holder 190 and output a second detection signal;

[0046] Control module 201 is used to output a first control signal to switch module 204 based on the first detection signal and the second detection signal;

[0047] The switch module 204 is used to receive a first control signal and control the connection between the headphone jack 190 and the headphone microphone detection module 203 to be in a conducting state or a disconnected state according to the first control signal.

[0048] It should be understood that the headphone jack 190 includes a ground pin, a microphone pin, a channel pin, and a headphone detection pin. The ground pin is used to connect to the ground terminal of the headphone to be inserted, the microphone pin is used to connect to the microphone terminal of the headphone to be inserted, the channel pin is used to connect to the corresponding channel terminal of the headphone to be inserted, and the headphone detection pin is used to determine whether a headphone is inserted in the headphone jack 190 based on the current voltage value of the detection pin.

[0049] The headphone jack 190 can be either normally open (NO) or normally closed (NC). If the headphone jack 190 is normally open, the headphone detection pin remains disconnected from the channel pin when no headphones are inserted. When headphones are inserted, the headphone detection pin becomes conductive through the headphone's channel terminal to the channel pin. Alternatively, if water or other conductive foreign objects enter the headphone jack 190, the headphone detection pin becomes conductive through the water to the channel pin. If the headphone jack 190 is normally closed, the process is reversed. When no headphones are inserted, the headphone detection pin remains conductive with the channel pin. When headphones are inserted, the headphone detection pin becomes disconnected from the channel pin. Therefore, the headphone detection pin can determine whether headphones are inserted based on its current voltage value, and it can also determine the current state of the headphone jack 190 based on the connection status between the headphone detection pin and the channel pin, such as whether headphones are inserted, whether headphones are inserted, or whether water has entered the headphone jack.

[0050] When the first detection signal indicates that no headphones or microphone are inserted into the headphone jack 190, and the second detection signal indicates that water has entered the headphone jack 190, the switch module 204 controls the connection between the headphone detection pin of the headphone jack 190 and the headphone / microphone detection module 203 to be disconnected according to the first control signal.

[0051] Optionally, the headphone jack 190 may further include left and right channel pins, meaning the headphone jack 190 can be compatible with a four-segment headphone connector, where the four-segment connector is divided into four segments by an insulating ring, including a ground terminal, a microphone terminal, a left channel terminal, and a right channel terminal. For example, when headphones are inserted into the headphone jack 190, the ground pin, microphone pin, and channel pin in the headphone jack 190 can be connected to the corresponding ground terminal, microphone terminal, and channel terminal on the headphone connector, respectively. The channel terminals include the aforementioned left and right channel terminals. Since the left channel terminal is generally located at the top of the headphone connector, the corresponding left channel pin is located at the innermost end of the headphone jack 190. Therefore, optionally, the headphone detection pin is specifically used to disconnect or connect to the left channel pin based on the insertion state of the headphone jack 190, thereby more accurately determining the state of the headphone jack 190.

[0052] Optionally, the aforementioned switch module 204 can be a Metal-Oxide-Semiconductor Field-Effect Transistor (MOS). In this case, the gate of the switch module 204 is connected to the control port of the control module 201, allowing the control module 201 to control the switching of the switch module 204. The source and drain of the switch module 204 are connected to the headphone detection pin of the headphone jack 190 and the detection port of the control module 201, respectively. Therefore, the connection between the control module 201 and the headphone detection pin is turned on or off depending on whether the switch module 204 is on or off. If the switch module 204 disconnects the connection between the control module 201 and the headphone detection pin, it is equivalent to the headphone / microphone detection module 203 no longer acquiring the headphone insertion status in the headphone jack 190. This allows the detection of headphone insertion to be stopped when the headphone jack 190 is wet and no headphone or microphone is inserted, thus avoiding false detections. Optionally, the switch module 204 can also be a manual switch, etc. After the first detection signal indicates that no headphones or microphone are inserted in the headphone jack, and the second detection signal indicates that water has entered the headphone jack, the connection between the control module 201 and the headphone detection pin can be disconnected according to the user's operation of the switch module 204.

[0053] Optionally, the control module 201 is further configured to send a second control signal to the switch module 204 when the electronic device is turned on, so that the switch module 204 controls the connection between the headphone jack 190 and the headphone microphone detection module 203 to be in a conductive state according to the second control signal.

[0054] For example, taking the control module 201 as the processor and the switch module 204 as the MOSFET, after the device is powered on, the processor can control the MOSFET to remain in the conducting state through general-purpose input / output (GPIO) to facilitate the detection of the headphone jack 190. Simultaneously, if the headphone jack 190 is in a state where water has entered and no headphones or microphone are inserted, the MOSFET will be switched from the conducting state to the de-conducting state.

[0055] Optionally, after the control module 201 outputs a first control signal to the switch module 204 to make the switch module 204 control the headphone jack 190 and the headphone microphone detection module 203 to be in a disconnected state, if the second detection signal is detected indicating that there is no water ingress in the headphone jack 190, the control module 204 restores the headphone jack 190 and the headphone microphone detection module 203 to a conducting state.

[0056] For example, the switch module 204 is in a conducting state except when the first detection signal indicates that no headphones or microphone are inserted into the headphone jack 190 and the second detection signal indicates that water has entered the headphone jack 190. However, when it receives the first detection signal indicating that no headphones or microphone are inserted into the headphone jack 190 and the second detection signal indicating that water has entered the headphone jack 190, it will switch from the conducting state to the disconnected state. At this time, the headphone / microphone detection module 203 and the water ingress detection module 202 will perform real-time detection and output the first detection signal and the second detection signal. When the control module 201 determines that the second detection signal indicates that there is no water ingress in the headphone jack 190, it controls the switch module 204 to restore the conducting state of the headphone jack 190 and the headphone / microphone detection module 203.

[0057] Optionally, the water inlet detection module 202 can be any sensor capable of detecting moisture. The specific selection of the sensor can be determined by those skilled in the art based on actual needs, and this application does not impose any restrictions.

[0058] Optionally, the water ingress detection module 202 is located outside the headphone insertion hole of the headphone holder 190, and a waterproof foam is also provided outside the water ingress detection module 202, which covers the entire headphone holder 190.

[0059] In the aforementioned headphone insertion detection circuit, the control module 201 is connected to the headphone microphone detection module 203, the water ingress detection module 202, and the switch module 204. The switch module 204 is also connected to the headphone microphone detection module 203 and the headphone socket 190. The headphone microphone detection module 203 is also connected to the headphone socket 190. This allows the headphone microphone detection module 203 to detect the insertion status of the headphone and microphone in the headphone socket 190 and output a first detection signal. The water ingress detection module 202 detects water ingress into the headphone socket 190 and outputs a second detection signal. The control module 201 outputs a first control signal to the switch module 204 based on the first and second detection signals. The switch module 204 controls the connection between the headphone socket 190 and the headphone microphone detection module 203 to be either in a conducting or disconnected state based on the first control signal. Compared to existing technologies, this application disconnects the connection between the headphone holder 190 and the headphone / microphone detection module 203 only when no headphones or microphone are inserted into the headphone holder 190 and water has entered the headphone holder 190. This prevents false headphone insertion detection caused by liquid ingress into the headphone holder 190 and improves the reliability of the headphone holder 190.

[0060] Figure 3 This is a schematic diagram of the structure of an earphone insertion detection circuit provided in one embodiment of this application. Figure 3As shown, the headphone microphone detection module 203 includes a microphone detection submodule 2031 and an encoding control submodule 2032. The microphone detection submodule 2031 is connected to the microphone pin of the headphone jack 190 and the encoding control submodule 2032. The encoding control submodule 2032 is also connected to the control module 201 and the switch module 204.

[0061] The microphone detection submodule 2031 is used to obtain the voltage of the microphone pin of the headphone jack 190 and output a first level signal;

[0062] The encoding control submodule 2032 is used to detect the level value of the first level signal and send the first detection signal to the control module 201;

[0063] Specifically, when the level value of the first level signal is within a preset voltage threshold, the first detection signal indicates that the earphone jack 190 is plugged into a microphone; when the level value of the first level signal is outside the preset voltage threshold, the first detection signal indicates that the earphone jack 190 is not plugged into a microphone.

[0064] Optionally, the microphone detection submodule 2031 may include a microphone port. The microphone port of the microphone detection submodule 2031 is connected to the microphone pin of the headphone jack 190 and can receive the audio signal generated by the microphone end of the headphone, thereby acquiring the voltage of the microphone pin of the headphone jack 190 and outputting a first level signal to the encoding control submodule 2032.

[0065] Optionally, the microphone detection submodule 2031 described above can be an acoustic-to-electric converter. In some embodiments, the acoustic-to-electric converter can be integrated into the encoding control submodule 2032.

[0066] Optionally, the aforementioned preset voltage threshold is determined according to the specific model of the headphones. The voltage variation range of the microphones for three-segment and four-segment headphones is different. That is, the voltage range of the first level signal is different depending on the model of the headphone jack 190. This can be set by those skilled in the art according to the actual situation, and no restrictions are imposed here.

[0067] For example, since the headphone jack 190 is passive, the control module 201 can provide power to the headphone jack 190 after being connected to it. When a headphone is inserted into the headphone jack 190, the microphone of the headphone acts as a pull-down resistor, and the voltage obtained by the microphone detection submodule 2031 is pulled down due to voltage division, keeping it within a preset voltage threshold. Therefore, after the microphone detection submodule 2031 receives the first level signal, it can determine whether a microphone is inserted into the headphone jack 190 based on the level value of the first level signal, and output the corresponding first detection signal to the control module 201. Since the microphone pin of the headphone jack 190 is located at the top of the headphone jack 190, it is less affected by liquid accumulation at the bottom. Therefore, after determining whether a microphone is inserted into the headphone jack 190 based on the first level signal, the insertion status of the headphone to be inserted can be determined based on the microphone's insertion status.

[0068] In the aforementioned headphone insertion detection circuit, a microphone detection submodule 2031 and an encoding control submodule 2032 are configured. The microphone detection submodule 2031 is connected to the microphone pin of the headphone jack 190 and the encoding control submodule 2032. The encoding control submodule 2032 is also connected to the control module 201, so that the encoding control submodule 2032 can collect the voltage of the microphone pin of the headphone jack 190 through the microphone detection submodule 2031, and then determine whether the headphone to be inserted is inserted into the headphone jack 190 based on the voltage.

[0069] Figure 4 This is a schematic diagram of the structure of an earphone insertion detection circuit provided in one embodiment of this application. Figure 4 As shown, the headphone microphone detection module 203 also includes a headphone detection submodule 2033, which is connected to the headphone detection pin and the switch module 204 of the headphone socket 190.

[0070] The headphone detection submodule 2033 is used to obtain the voltage of the headphone detection pin of the headphone jack 190 and output a second level signal;

[0071] The encoding control submodule 2032 is used to detect the level values ​​of the first level signal and the second level signal, and send the first detection signal to the control module 201;

[0072] Specifically, when the second level signal is low and the level value of the first level signal is outside the preset voltage threshold, the first detection signal indicates that the headphone jack 190 is not plugged in headphones and microphone.

[0073] Optionally, the above-mentioned headphone detection submodule 2033 may include a voltage acquisition port. The voltage acquisition port of the headphone detection submodule 2033 is connected to the headphone detection pin of the headphone socket 190, and can receive the voltage generated by the headphone detection pin of the headphone socket 190 and output a second level signal to the encoding control submodule 2032.

[0074] Optionally, the above-mentioned headphone detection submodule 2033 can be a digital-to-analog converter. In some embodiments, the digital-to-analog converter can be integrated into the encoding control submodule 2032.

[0075] Optionally, the level of the second level signal can be determined according to a corresponding preset voltage threshold. When the level of the second level signal is less than the preset voltage threshold, the second level signal is low; when the level of the second level signal is greater than the preset voltage threshold, the second level signal is high. The detection results represented by the low and high levels need to be determined according to the headphone jack model. For example, when the headphone jack 190 is a NO type headphone jack, a low level second level signal indicates that there are headphones or water in the headphone jack 190, and a high level second level signal indicates that there are no headphones or water in the headphone jack 190. When the headphone jack is an NC type headphone jack, a high level second level signal indicates that there are headphones or water in the headphone jack 190, and a low level second level signal indicates that there are no headphones or water in the headphone jack 190.

[0076] It should be understood that since the headphone jack 190 is passive, the control module 201, after being connected to the headphone jack 190, can provide power to the headphone jack 190. When a headphone is inserted into the headphone jack 190, the headphone detection pin of the headphone jack 190 is shorted to the channel pin. Therefore, the headphone detection submodule 2033 acquires the second level signal because the headphone detection pin is shorted to the channel pin. Taking the headphone jack 190 as a NO-type headphone jack as an example, the headphone detection pin is pulled low due to the shorting to the channel pin, forming a low-level signal. At the same time, when a headphone is inserted into the headphone jack 190, since the microphone of the headphone acts as a pull-down resistor, the first level signal acquired by the microphone detection submodule 2031 will be pulled low due to voltage division, keeping it within the preset voltage threshold. Therefore, after the encoding control submodule 2032 acquires the first level signal and the second level signal, it can determine whether the headphone to be inserted is inserted into the headphone jack 190 based on the first level signal and the second level signal.

[0077] For example, when the second level signal is less than the corresponding preset voltage threshold, the first level signal collected by the microphone detection submodule 2031 can be compared with the corresponding preset voltage threshold to further determine whether the lowering of the second level signal is caused by the insertion of headphones into the headphone jack 190, thereby ruling out the possibility that the lowering of the second level signal is caused by water ingress. After determining that the second level signal is lowered, the first level signal collected by the microphone detection submodule 2031 can be judged. If headphones are inserted into the headphone jack 190, the first level signal will be lowered due to voltage division. However, if the lowering of the second level signal is caused by water ingress, since the water inside the headphone jack 190 is generally not full, and the microphone pins of the headphone jack 190 are generally located near the top of the headphone jack 190, the first level signal usually will not change.

[0078] Optionally, the control module 201 is further configured to output a first control signal to the switch module 204 when the second detection signal indicates that there is no water ingress in the earphone jack 190, the second level signal is high, or the level value of the first level signal is outside the preset voltage threshold, so that the switch module 204 controls the connection between the earphone jack 190 and the earphone microphone detection module 203 to be in a conducting state according to the first control signal.

[0079] For example, when the encoding control submodule 2032 determines that the level value of the first level signal is outside the corresponding preset voltage threshold or the level value of the second level signal is high, it can send a first detection signal indicating that no headphones or microphone are inserted into the headphone jack 190 to the control module 201. When the second detection signal received by the control module 201 indicates that there is no water ingress in the headphone jack 190, it can output a first control signal to the switch module 204 so that the switch module 204 controls the connection between the headphone jack 190 and the headphone / microphone detection module 203 to be in a conductive state according to the first control signal.

[0080] In the aforementioned headphone insertion detection circuit, the encoding control submodule determines whether the headphone to be inserted is inserted into the headphone jack 190 by comprehensively judging the level values ​​of the first level signal and the second level signal, thereby improving the accuracy of the headphone insertion status judgment.

[0081] Figure 5 This is a schematic diagram of the structure of an earphone insertion detection circuit provided in one embodiment of this application. Figure 5 As shown, the headphone microphone detection module 203 also includes a sound detection submodule 2034, which is connected to the channel pins and the encoding control submodule 2032 of the headphone jack 190.

[0082] The sound detection submodule 2034 is used to obtain the voltage of the channel pins of the headphone jack 190 and output a third-level signal;

[0083] The encoding control submodule 2032 is used to detect the level values ​​of the first level signal, the second level signal and the third level signal, and send the first detection signal to the control module 201;

[0084] Specifically, when both the second and third level signals are low and the level of the first level signal is within a preset voltage threshold, the first detection signal indicates that the headphone jack 190 is used to insert headphones and a microphone.

[0085] Optionally, the sound detection submodule 2034 may include a voltage acquisition port. The voltage acquisition port of the sound detection submodule 2034 is connected to the channel pin of the headphone jack 190 and can receive the voltage generated by the channel pin of the headphone jack 190 and output a third level signal to the encoding control submodule 2032.

[0086] Optionally, the sound detection submodule 2034 can be a digital-to-analog converter. In some embodiments, the digital-to-analog converter can be integrated into the encoding control submodule 2032.

[0087] Optionally, the level of the third level signal can be determined according to the corresponding preset voltage threshold. When the level of the third level signal is less than the preset voltage threshold, the third level signal is low level; when the level of the third level signal is greater than the preset voltage threshold, the third level signal is high level.

[0088] For example, since the headphone jack 190 is passive, the control module 201 can provide power to the headphone jack 190 after being connected to it. When a headphone is inserted into the headphone jack 190, the headphone detection pin and the channel pin of the headphone jack 190 are shorted, so the third-level signal collected by the sound detection submodule 2034 will be pulled low due to the short circuit. At the same time, when a headphone is inserted into the headphone jack 190, since the microphone of the headphone acts as a pull-down resistor, the voltage obtained by the microphone detection submodule 2031 will be pulled low due to voltage division, keeping it within a preset voltage threshold. Therefore, after the encoding control submodule 2032 obtains the first-level signal, the second-level signal, and the third-level signal, it can determine whether the headphone to be inserted is inserted into the headphone jack 190 based on the first-level signal, the second-level signal, and the third-level signal. This avoids false detection of the headphone insertion status in the headphone jack 190 due to damage to the relevant pins of the headphone jack 190.

[0089] In the aforementioned headphone insertion detection circuit, the level values ​​of the first, second, and third level signals are comprehensively judged to determine whether the headphone to be inserted is inserted into the headphone socket. This avoids the problem of the earpiece being in place but not functional due to deformation of the headphone detection pins or channel pins in the headphone socket, thus improving the reliability of the product.

[0090] Figure 6 This is a schematic diagram of the structure of an earphone insertion detection circuit provided in one embodiment of this application. Figure 6 As shown, the headphone insertion detection circuit includes a water ingress detector K, a processor CPU, an encoder CODEC, and a MOSFET. The waterproof detection GPIO of the processor CPU is connected to the output terminal of the water ingress detector K. The switching control GPIO of the processor CPU is connected to the control terminal of the MOSFET. The processor CPU is connected to the encoder CODEC via an SPI (Serial Peripheral Interface) interface. The headset jack includes a ground pin GND, a detection pin DET, a left channel pin L, a right channel pin R, and a microphone pin MIC. The microphone pin MIC of the headset jack is connected to the microphone pin MIC of the encoder CODEC. The left channel pin L of the headset jack is connected to the left channel pin L of the encoder CODEC. The right channel pin R of the headset jack is connected to the right channel pin R of the encoder CODEC. The detection pin DET of the headset jack is connected to the detection pin DET of the encoder CODEC via a MOSFET. The ground pin GND of the headset jack is connected to the ground pin GND of the encoder CODEC.

[0091] Taking a NO-type headphone jack as an example, the specific implementation method includes:

[0092] Step 101: Regardless of whether headphones are plugged in, after the machine is powered on, the CPU controls the MOSFET to be normally open via the GPIO switch.

[0093] In step 102, when an earphone is plugged in, the detection pin DET and the left channel pin L are shorted and pulled low. The left channel pin L is low by default, and at the same time, the voltage of the microphone pin MIC changes due to voltage division. DET is pulled low and the CODEC collects the change in MIC voltage and feeds it back to the CPU through the SPI (Serial Peripheral Interface). The CPU controls the GPIO to keep the MOS normally open, thus realizing normal earphone insertion detection.

[0094] Step 103: When no headphones are plugged in and water has entered the bottom of the headphone jack, the DET and L detection pins are forcibly short-circuited and pulled low. Simultaneously, the waterproof detection GPIO is pulled low, but the microphone voltage remains unchanged. Since DET is pulled low but the encoder (CODEC) does not detect any microphone voltage change, it feeds this information back to the CPU via the SPI interface. The CPU then controls the MOS to turn off via a switch-controlled GPIO, thus avoiding false headphone trigger detection. When the waterproof detection GPIO returns to a high level, it is assumed that the moisture has largely disappeared, and since the CODEC has not detected any microphone voltage change, the CPU controls the MOS to return to its normally open state via a switch-controlled GPIO.

[0095] It should also be understood that the various embodiments described above can be coupled to each other, and this application does not limit this. Furthermore, the sequence number of each process does not imply the order of execution; the execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.

[0096] The term "module" can refer to application-specific integrated circuits (ASICs), electronic circuits, processors (e.g., shared processors, proprietary processors, or group processors) and memories for executing one or more software or firmware programs, integrated logic circuits, and / or other suitable components that support the described functions.

[0097] The aforementioned electronic device is equipped with the corresponding functions performed by each module in the aforementioned dual-path multiplexing coupler; these functions can be implemented in hardware or by hardware executing corresponding software. The hardware or software includes one or more modules corresponding to the aforementioned functions.

[0098] Figure 7 This is a structural schematic diagram of an electronic device provided for another embodiment of this application. Figure 7 The apparatus shown can be used to perform the method of any of the foregoing embodiments.

[0099] like Figure 7 As shown, the electronic device 700 of this embodiment includes: a memory 701, a processor 702, a communication interface 703, and a bus 704. The memory 701, processor 702, and communication interface 703 are interconnected via the bus 704.

[0100] The memory 701 may be a read-only memory (ROM), a static storage device, a dynamic storage device, or a random access memory (RAM). The memory 701 may store a program, and when the program stored in the memory 701 is executed by the processor 702, the processor 702 performs the various steps of the method shown in the above embodiments.

[0101] The processor 702 may be a general-purpose central processing unit (CPU), a microprocessor, an application-specific integrated circuit (ASIC), or one or more integrated circuits, used to execute relevant programs to implement the various methods shown in the embodiments of this application.

[0102] The processor 702 can also be an integrated circuit chip with signal processing capabilities. In implementation, each step of the method in this embodiment can be accomplished through integrated logic circuits in the processor 702 or through software instructions.

[0103] The processor 702 described above can also be a general-purpose processor, a digital signal processor (DSP), an ASIC, a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components. It can implement or execute the methods, steps, and logic block diagrams disclosed in the embodiments of this application. The general-purpose processor can be a microprocessor or any conventional processor.

[0104] The steps of the method disclosed in the embodiments of this application can be directly manifested as being executed by a hardware decoding processor, or executed by a combination of hardware and software modules in the decoding processor. The software modules can reside in random access memory, flash memory, read-only memory, programmable read-only memory, electrically erasable programmable memory, registers, or other mature storage media in the art. This storage medium is located in memory 701, and processor 702 reads the information in memory 701 and, in conjunction with its hardware, completes the functions required by the units included in the device of this application.

[0105] The communication interface 703 can use, but is not limited to, transceivers to enable communication between the electronic device 700 and other devices or communication networks.

[0106] Bus 704 may include a pathway for transmitting information between various components of electronic device 700 (e.g., memory 701, processor 702, communication interface 703).

[0107] It should be understood that the electronic device shown in the embodiments of this application may be a single electronic device, or it may be an integrated device assembled from multiple electronic devices.

[0108] It should be understood that in the various embodiments of this application, the order of the above-mentioned processes does not imply the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of this application.

[0109] Those skilled in the art will recognize that the units and algorithm steps of the various examples described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. Those skilled in the art can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of this application.

[0110] Those skilled in the art will understand that, for the sake of convenience and brevity, the specific working processes of the systems, devices, and units described above can be referred to the corresponding processes in the foregoing method embodiments, and will not be repeated here.

[0111] In the several embodiments provided in this application, it should be understood that the disclosed systems, apparatuses, and methods can be implemented in other ways. For example, the apparatus embodiments described above are merely illustrative; for instance, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces; the indirect coupling or communication connection between apparatuses or units may be electrical, mechanical, or other forms.

[0112] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0113] In addition, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.

[0114] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0115] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.

Claims

1. An earphone insertion detection circuit, characterized in that, The invention relates to an electronic device, which includes an earphone jack. The circuit includes a control module, a water ingress detection module, an earphone microphone detection module, and a switch module. The control module is connected to the earphone microphone detection module, the water ingress detection module, and the switch module. The switch module is also connected to the earphone microphone detection module and the earphone jack. The earphone microphone detection module is also connected to the earphone jack. The headphone microphone detection module is used to detect the insertion status of the headphone and microphone in the headphone jack and output a first detection signal; The water ingress detection module is located outside the headphone insertion hole of the headphone holder and is used to detect water ingress inside the headphone holder and output a second detection signal. The control module is configured to output a first control signal to the switch module based on the first detection signal and the second detection signal; The switch module is used to receive the first control signal and control the connection between the earphone socket and the earphone microphone detection module to be in a conducting state or a disconnected state according to the first control signal. When the first detection signal indicates that the earphone and microphone are not inserted into the earphone holder, and the second detection signal indicates that water has entered the earphone holder, the switch module controls the connection between the earphone holder and the earphone / microphone detection module to be in the disconnected state according to the first control signal.

2. The circuit as described in claim 1, characterized in that, The headphone microphone detection module includes a microphone detection submodule and an encoding control submodule. The microphone detection submodule is connected to the microphone pin of the headphone jack and the encoding control submodule. The encoding control submodule is also connected to the control module and the switch module. The microphone detection submodule is used to obtain the voltage of the microphone pin of the headphone jack and output a first level signal; The encoding control submodule is used to detect the level value of the first level signal and send the first detection signal to the control module; Specifically, when the level value of the first level signal is within a preset voltage threshold, the first detection signal indicates that the earphone jack is plugged into the microphone; when the level value of the first level signal is outside the preset voltage threshold, the first detection signal indicates that the earphone jack is not plugged into the microphone.

3. The circuit as described in claim 2, characterized in that, The headphone microphone detection module further includes a headphone detection submodule, which is connected to the headphone detection pin of the headphone socket and the switch module; The headphone detection submodule is used to obtain the voltage of the headphone detection pin of the headphone socket and output a second level signal; The encoding control submodule is used to detect the level values ​​of the first level signal and the second level signal, and send the first detection signal to the control module; Specifically, when the second level signal is low and the level value of the first level signal is outside the preset voltage threshold, the first detection signal indicates that the earphone jack is not plugged into the earphone and the microphone.

4. The circuit as described in claim 3, characterized in that, The headphone microphone detection module further includes a sound detection submodule, which is connected to the channel pins of the headphone jack and the encoding control submodule. The sound detection submodule is used to obtain the voltage of the channel pins of the headphone jack and output a third level signal; The encoding control submodule is used to detect the level values ​​of the first level signal, the second level signal and the third level signal, and send the first detection signal to the control module; Specifically, when both the second and third level signals are low and the level value of the first level signal is within the preset voltage threshold, the first detection signal indicates that the earphone jack is used to insert the earphone and the microphone.

5. The circuit as described in claim 3, characterized in that, The control module is further configured to output a first control signal to the switch module when the second detection signal indicates that there is no water ingress in the earphone holder, the second level signal is high, or the level value of the first level signal is outside the preset voltage threshold, so that the switch module controls the connection between the earphone holder and the earphone microphone detection module to be in the conducting state according to the first control signal.

6. The circuit as described in claim 1, characterized in that, The control module is further configured to, after outputting a first control signal to the switch module to cause the switch module to control the headphone holder and the headphone microphone detection module to be in a disconnected state, and after detecting a second detection signal indicating that there is no water ingress in the headphone holder, control the switch module to restore the headphone holder and the headphone microphone detection module to a conducting state.

7. The circuit as described in claim 1, characterized in that, The water ingress detection module is also equipped with waterproof foam.

8. The circuit as described in claim 1, characterized in that, When the electronic device is turned on, the control module sends a second control signal to the switch module, so that the switch module controls the connection between the earphone jack and the earphone microphone detection module to be in a conductive state according to the second control signal.

9. The circuit as described in any one of claims 2-8, characterized in that, The microphone detection submodule is an acoustic-to-electrical converter.

10. An electronic device, characterized in that, The electronic device includes an earphone insertion detection circuit as described in any one of claims 1-9.

Citation Information

Patent Citations

  • Earphone jack and earphone jack state detection method and detection device

    CN105307069A

  • Earphone insertion detection circuit

    CN111586549A