Headset detection circuit with high compatibility
By designing a headset detection circuit including MIC access port, constant current source circuit, comparator, AND gate and MCU, the problem of access still detected in the prior art after disassembly of the headset microphone is solved, and accurate judgment of the microphone status and high compatibility of the recording equipment are achieved.
Patent Information
- Application Number
- CN202420713816.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Utility models(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-09
- Publication Date
- 2025-03-28
- Estimated Expiration
- 2034-04-09
AI Technical Summary
The existing headset detection circuit still detects access after the headset microphone is removed, resulting in other microphones being disabled, silent recording occurs, affecting the user experience.
Design a high-compatibility headset detection circuit to detect whether the microphone is connected and works normally through the combination of the MIC access port, constant current source circuit, comparator, AND gate and MCU. The microphone status is determined by comparing the reference voltages U3 and U6, and enable or disable different microphone signals.
Effectively determine whether the microphone is connected and works normally, ensuring that the recording device can use other types of microphones to record without access or microphone disassembly, improve compatibility and avoid silent recording problems.
Smart Images

Figure CN222691870U_ABST
Abstract
Description
Technical Field
[0001] The utility model relates to the technical field of audio, in particular to a headset detection circuit with high compatibility. Background Art
[0002] With the continuous development of the audio industry, diversified audio products emerge in an endless stream, providing users with more choices.
[0003] Currently, the headphones on the market are divided into those with microphones and those without microphones. Generally, headphones without microphones use a 3.5mm TRS interface, while headphones with microphones use a 3.5mm TRRS interface. Headphones with microphones are further divided into two types: detachable microphones and non-detachable microphones. This diversified classification has caused compatibility issues for the headphone interface (HEADSET) on the mixing console.
[0004] To solve the above problems, a headset detection circuit needs to be added. The traditional headset detection circuit determines whether the microphone is connected by detecting the level change of the detection pin of the headset interface. This method can meet the needs of most headsets, but when the microphone of the headset is removed, the detection circuit will still detect that the microphone is connected. In this case, when multiple microphones exist at the same time, the connection of the headset may cause other microphones to be disabled. However, in actual use, the headset does not exist, resulting in silence during recording, which brings great inconvenience to users.
[0005] Therefore, there is an urgent need to provide a highly compatible headset detection circuit to solve the above problems. Utility Model Content
[0006] The purpose of the utility model is to overcome the shortcomings and defects of the prior art and provide a highly compatible headset detection circuit that is compatible with 3.5mmTRRS headphones and ensures that the recording device can use other microphones for recording when the microphone is removed.
[0007] The purpose of this utility model is achieved through the following technical solutions:
[0008] A highly compatible headset detection circuit, used to detect whether a MIC is connected to a headset, comprises:
[0009] MIC access port, used to connect a headset;
[0010] A constant current source circuit is connected to the MIC input port and is used to provide a bias voltage to the MIC;
[0011] A comparator, provided with reference voltages U3 and U6, the reference voltages being used to compare with the bias voltages and outputting a result signal;
[0012] An AND gate, which is respectively connected to a comparator and an MCU, is used to receive and judge the result signal output by the comparator, and output it to the MCU through the DET_OUT port;
[0013] The MCU is used to detect the signal of the DET_OUT port and isolate or receive the MIC signal according to the detection result.
[0014] As a preferred technical solution of the present invention, the constant current source circuit includes a constant current source 1 and a constant current source 2. The constant current source 1 is connected to the MIC access port, and the constant current source 2 is connected to the comparator.
[0015] As a preferred technical solution of the present invention, the earphone detection circuit includes a low-pass filter. The low-pass filter is connected to the comparator. The low-pass filter includes a capacitor C1 and a resistor R3, and the capacitor C1 and the resistor R3 are connected in series.
[0016] As a preferred technical solution of the present invention, a capacitor C2 is connected in parallel between the constant current source 1 and the low-pass filter, and a resistor R4 is connected in series between the low-pass filter and the capacitor C2.
[0017] As a preferred technical solution of the present invention, the comparator includes a first voltage-dividing resistor, a second voltage-dividing resistor and a third voltage-dividing resistor, and the first voltage-dividing resistor, the second voltage-dividing resistor and the third voltage-dividing resistor are connected in series.
[0018] As a preferred technical solution of the present invention, the detection circuit is also provided with a non-inverting amplifier. The input end of the non-inverting amplifier is connected to the MIC access port, and the output end of the non-inverting amplifier is connected to the MCU.
[0019] Compared with the prior art, the present invention has the following beneficial effects:
[0020] The present invention uses an earphone detection circuit to detect whether a MIC is connected to an earphone, provides a stable bias voltage through a constant current source circuit, compares the bias voltage with the reference voltages U3 and U6 set by the comparator. When the comparison result is U6 < U DET < U3, both the pin 1 and pin 7 of the comparator U1 output high level, and the DET_OUT port of the AND gate outputs high level; when the comparison result does not satisfy U6 < U DET < U3, the DET_OUT port of the AND gate outputs low level; then the MCU judges the level state of the DET_OUT port and enables or disables different microphone signals according to the level state. Through the earphone detection circuit of the present invention, it can effectively judge whether the microphone is connected to the earphone and whether it works properly, ensuring that the recording device can use other types of microphones for recording when the earphone is not connected or the earphone is disassembled, improving compatibility. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] Figure 1 This is a circuit schematic diagram of the utility model. DETAILED DESCRIPTION
[0022] The present invention is further described in detail below in conjunction with embodiments and drawings, but the implementation manner of the present invention is not limited thereto.
[0023] The specific implementation process of the utility model is as follows:
[0024] like Figure 1 As shown, a highly compatible headset detection circuit is used to detect whether a MIC is connected to a headset, comprising: a MIC access port CZ1, used to connect a headset; a constant current source circuit, connected to the MIC access port CZ1, used to provide a stable bias voltage to the headset; a comparator, provided with reference voltages U3 and U6, the reference voltage is used to compare with the bias voltage, and output a result signal; an AND gate, respectively connected to the comparator and the MCU, used to receive and judge the result signal output by the comparator, and output the result to the MCU through the DET_OUT port; the MCU, used to detect the signal of the DET_OUT port, and isolate or receive the MIC signal according to the detection result.
[0025] Specific principle of the circuit: The detection circuit is connected to the headset to form a loop, and a bias voltage is generated through the constant current source circuit. The bias voltage is used to establish the static operating point of the microphone, so that when the electret inside the microphone is vibrated by the sound, it can generate an electrical signal based on this static operating point, thereby realizing the conversion of sound to electrical signal, and the electrical signal can be recognized by the MCU. Different microphones are connected, and the static operating point will be different. In order to ensure that the microphone can work normally after being connected, it is necessary to define a threshold, that is, a reference voltage, and determine whether the microphone is connected by judging whether the static operating point is within the threshold. When the microphone is connected, the MCU will detect whether its static operating point reaches or exceeds this threshold. If the static operating point is within the threshold range, it means that the microphone has established the static operating point normally and can work normally; if the static operating point is not within the threshold range, it means that the microphone is not connected correctly or there is a fault, and corresponding processing is required.
[0026] Specifically, the HEADSET_DET voltage is U DET The headset is connected to the microphone through the MIC input port CZ1, the potential changes, and the constant current source circuit provides a bias voltage U to pins 1 and 5 of the MIC input port CZ1. DET ; Set the bias voltage U DET Compare with the reference voltage U3 and U6 set by the comparator. When the comparison result is U6 DET <U3, the pins 1 and 7 of the comparator U1 both output high levels, and the DET_OUT port of the AND gate outputs a high level; when the comparison result does not satisfy U6 < U DET <U3, the DET_OUT port of the AND gate outputs a low level; then the MCU judges the level state of the DET_OUT port and enables or disables different microphone signals according to the level state.
[0027] When the DET_OUT port is at a high level, the MCU will recognize that a valid microphone has been connected and send a control signal to disable other unnecessary microphone signals to avoid signal interference or echo that may be generated when multiple microphones work simultaneously; when the DET_OUT port is at a low level, the MCU will judge that no valid microphone is connected or the microphone has been disassembled. At this time, the MCU will send a control signal to isolate the MIC signal and enable other standby microphone signals. Specifically, it can be set according to the application scenario and functional requirements.
[0028] When the MCU confirms that a valid microphone has been connected, the MIC signal will enter through the MIC access port CZ1, and after passing through the coupling capacitor C8, the MIC signal will enter the non-inverting amplifier. The amplitude of the signal is enhanced through the non-inverting amplifier, and the phase of the input signal and the output signal is kept consistent. The amplified MIC signal is collected by the MCU for processing and converted into high-quality audio data.
[0029] In the embodiment of the present utility model, a first voltage-dividing resistor, a second voltage-dividing resistor and a third voltage-dividing resistor are arranged on the comparator, and the first voltage-dividing resistor, the second voltage-dividing resistor and the third voltage-dividing resistor are connected in series. The reference voltage is obtained by voltage division through the first voltage-dividing resistor, the second voltage-dividing resistor and the third voltage-dividing resistor. Specifically, the voltages of the pins 1 and 7 of the comparator U1 are U1 and U7 respectively. Since the voltage drop between the base and the emitter of the triode Q1 is U be , the voltage drop of the resistor R2 is U be , and the flowing current is I = U be / R2. Ignoring the base current of the triode Q4, according to the voltage division principle, the reference voltage U3 is obtained by the common voltage division of the resistors R11 and R13, then the reference voltage U3 = (R11 + R13) * I = (R11 + R13) * U be / R2; the reference voltage U6 is obtained by the voltage division of R13, U6 = R13 * I = R13 * U be / R2. Among them, the threshold range (U3, U6) of the reference voltage setting cannot be too small because the loads of different earphones are different, resulting in differences in U DET as well.
[0030] In an embodiment of the present utility model, the constant current source circuit includes a constant current source 1 and a constant current source 2. The constant current source 1 is connected to the MIC access port CZ1, and the constant current source 2 is connected to a comparator. The constant current source 1 is used to provide a stable bias voltage to the MIC; the constant current source 2 is used to improve the stability of the reference voltage, prevent the reference voltage from shifting due to power fluctuations, and cause misjudgment by the comparator.
[0031] In an embodiment of the present utility model, the earphone detection circuit includes a low-pass filter. The low-pass filter is connected to the comparator. The low-pass filter includes a capacitor C1 and a resistor R3, and the capacitor C1 and the resistor R3 are connected in series. Specifically, when the earphone is inserted, the microphone will capture the sound signal. The low-pass filter is used to smooth the sound signal to eliminate high-frequency noise and other forms of interference signals in the sound signal, prevent these interference signals from being introduced into the comparator to interfere with the normal sound signal, ensure the quality of the sound signal, and also prevent misjudgment caused by interference signals, and avoid the MCU misjudging that the earphone has been inserted or not correctly identifying the earphone state.
[0032] In an embodiment of the present utility model, a capacitor C2 is connected in parallel between the constant current source 1 and the low-pass filter. The capacitor C2 is used to reduce the ripple of the bias voltage and smooth the high-frequency noise in the power supply, making the bias voltage provided to the earphone more stable; a resistor R4 is connected in series between the low-pass filter and the capacitor C2. The resistor R4 is used to adjust the static operating point of the MIC to ensure that the MIC operates at an appropriate operating voltage.
[0033] In an embodiment of the present utility model, the earphone interface can support the access of various types of earphones. The access of different types of earphones will result in different circuit responses, so that the type and state of the earphone can be judged. Specifically:
[0034] When a 3.5mm TRS interface earphone is accessed: Pins 1 and 5 of the MIC access port CZ1 will be connected to GND, resulting in U DET = 0V. Through the judgment of the comparator, since U DET < U3, U1 is at a high potential; at the same time, U DET is also < U6, and U7 is at a low potential. Through the logical operation of the AND gate, pin 3 of the AND gate D1 is at a low potential, so DET_OUT outputs a low level, and it is judged that no microphone is connected.
[0035] When a 3.5mm TRRS earphone is accessed: Pins 1 and 5 of the MIC access port CZ1 will access the microphone, and at this time U DET is the static operating point voltage of the microphone. Through the logical judgment of the comparator and the AND gate, if U DET < U3, U1 is at a high potential; at the same time, if U DET>U6 and U7 are at high potential, and pin 3 of AND gate D1 is at high potential, so DET_OUT outputs a high level, and it is judged that a microphone is connected.
[0036] When a 3.5mm TRRS headset is connected, but the microphone is removed and the MIC pin is close to being suspended, pins 1 and 5 of the MIC access port CZ1 will also be close to being suspended. DET Between 4V and 5V. Through the logic judgment of the comparator and the AND gate, U DET >U3, U1 is low potential; at the same time, U DET >U6, U7 keep high potential. Through the AND gate logic judgment, the pin 3 of the AND gate D1 is low potential, so DET_OUT outputs low level, judging that the microphone is not connected.
[0037] The headset interface passes the detection U DET The voltage is compared with the reference voltages U3 and U6, and combined with the logic operation of the AND gate, the type of headphones connected and the status of the microphone can be accurately determined, ensuring the compatibility and accuracy of the headset interface for different types of headphones. The utility model is compatible with 3.5mmTRRS headphones, and when the microphone is removed, it ensures that the recording device can use other microphones for recording. It is compatible with most wired headsets on the market, providing users with a more convenient and flexible audio experience.
[0038] The above-mentioned embodiments only express the implementation methods of the utility model, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the patent of the utility model. It should be pointed out that, for ordinary technicians in this field, several modifications and improvements can be made without departing from the concept of the utility model, and these all belong to the protection scope of the utility model. Therefore, the protection scope of the utility model patent shall be based on the attached claims.
Claims
1. A highly compatible headset detection circuit, used to detect whether a MIC is connected to a headset, characterized in that: include: MIC access port, used to connect a headset; A constant current source circuit is connected to the MIC input port and is used to provide a bias voltage to the MIC; A comparator, provided with reference voltages U3 and U6, the reference voltages being used to compare with the bias voltages and outputting a result signal; The AND gate is connected to the comparator and the MCU respectively, and is used to receive and judge the result signal output by the comparator, and output it to the MCU through the DET_OUT port; The MCU is used to detect the signal of the DET_OUT port and isolate or receive the MIC signal according to the detection result.
2. The high-compatibility headset detection circuit according to claim 1, characterized in that: The constant current source circuit comprises a constant current source 1 and a constant current source 2, wherein the constant current source 1 is connected to the MIC access port, and the constant current source 2 is connected to the comparator.
3. The high-compatibility earphone detection circuit according to claim 2, characterized in that: The earphone detection circuit includes a low-pass filter, which is connected to the comparator. The low-pass filter includes a capacitor C1 and a resistor R3, and the capacitor C1 and the resistor R3 are connected in series.
4. The high-compatibility earphone detection circuit according to claim 3, characterized in that: A capacitor C2 is connected in parallel between the constant current source 1 and the low-pass filter, and a resistor R4 is connected in series between the low-pass filter and the capacitor C2.
5. The high-compatibility headset detection circuit according to claim 1, characterized in that: The comparator includes a first voltage-dividing resistor, a second voltage-dividing resistor and a third voltage-dividing resistor, and the first voltage-dividing resistor, the second voltage-dividing resistor and the third voltage-dividing resistor are connected in series.
6. The high-compatibility headset detection circuit according to claim 1, characterized in that: The detection circuit is further provided with a common-phase amplifier, the input end of the common-phase amplifier is connected to the MIC access port, and the output end of the common-phase amplifier is connected to the MCU.