Control circuit and control method applied to earphone port and electronic equipment
By designing the headphone port control circuit, the problem that electronic devices cannot be compatible with PTT headphones is solved, and compatibility between traditional headphones and PTT headphones is achieved, meeting the needs of PTT function use, and reducing design costs.
Patent Information
- Application Number
- CN202411331522.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-24
- Publication Date
- 2024-12-31
AI Technical Summary
Existing electronic devices are not compatible with traditional CTIA or OMTP headsets and PTT headsets that support the push-and-talk function, resulting in the inability to meet the use of PTT headsets in industrial or logistics scenarios.
A headphone port control circuit is designed, including a first analog switch, a second analog switch and a control signal output module. By connecting with a baseband chip, it can switch between the headphone port and a traditional headphone or PTT headphone to realize the transmission of audio signals. and PTT mode control ensures that electronic devices are compatible with two types of headphones.
It realizes compatibility between electronic devices for traditional headphones and PTT headphones, ensures that they can work normally under different headphone types, meets the demand for PTT functions in industrial or logistics scenarios, and reduces the cost of equipment design.
Smart Images

Figure CN119233149A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of electronic technology, and in particular to a control circuit, a control method and an electronic device applied to an earphone port. Background Art
[0002] Push-to-Talk (PTT) is a communication method that changes the state of sending and receiving by pressing the PTT button. With the development of lifestyle, electronic devices used in industrial or logistics scenarios, such as personal digital assistants (PDAs), have a demand for the use of PTT functions in scenarios where they communicate through headphones.
[0003] Different from the traditional headsets used in the Open Mobile Terminal Platform (CTIA) (CTIA headsets for short) or the headsets defined by the Consumer Technology Association (OMTP) (OMTP headsets for short), the headsets supporting the Push-to-Talk (PTT) function (PTT headsets for short) can obtain or release the right to speak by pressing or releasing the PTT button during communication. Specifically, when the PTT button is pressed, the user using the PTT headset obtains the right to speak, the microphone of the PTT headset collects the user's voice signal, and the voice signal is processed and sent to the receiving end user; when the PTT button is released, the user using the PTT headset releases the right to speak, and the user can receive the voice signal sent by the sending end user through the speaker of the PTT headset.
[0004] However, existing electronic devices can only be adapted to traditional CTIA headsets or OMTP headsets, but cannot be adapted to PTT headsets. Summary of the invention
[0005] The present application provides a control circuit, a control method and an electronic device applied to an earphone port. The control circuit applied to the earphone port is configured in the electronic device so that the electronic device is adapted to both a traditional earphone and a PTT earphone.
[0006] In a first aspect, the present application provides a control circuit applied to a headphone port, comprising: a first analog switch, a second analog switch and a control signal output module; wherein the control signal output module is connected to a baseband chip; the first analog switch and the second analog switch are respectively connected to the headphone port; wherein the headphone port is used to connect to an audio output module of a first headphone, or the headphone port is used to connect to a PTT module of a second headphone; the second headphone supports a PTT function; a midpoint of a line connecting the second analog switch and the headphone port is connected to the control signal output module; the first analog switch is used to be turned on when the headphone port is connected to the audio output module, and to send a received audio signal to the audio output module through the headphone port, so that the audio output module outputs the audio signal to a user; the second analog switch is used to be turned on when the headphone port is connected to the PTT module, so that the second analog switch receives the audio signal The first voltage signal can be transmitted to the PTT module through the second analog switch and the headphone port, and is sent to the control signal output module after being processed by the PTT module; wherein the first voltage signal is used to control the PTT working mode of the baseband chip; when the PTT module receives a first instruction from a user to obtain the PTT voice right, the first voltage signal is processed by the PTT module and becomes a second voltage signal; the control signal output module outputs a first control signal based on the received second voltage signal; the first control signal is used to control the baseband chip to be in the PTT sending mode; when the PTT module does not receive the first instruction, the first voltage signal is processed by the PTT module and becomes a third voltage signal; the control signal output module outputs a second control signal based on the received third voltage signal; the second control signal is used to control the baseband chip to be in the PTT receiving mode.
[0007] In some embodiments, the control signal output module includes a comparator; the midpoint of the line connecting the second analog switch and the headphone port is connected to the first end of the comparator; the second end of the comparator is used to receive a reference voltage signal; wherein, the voltage value of the second voltage signal is less than the voltage value of the reference voltage signal, and the first control signal is a low-level signal; the voltage value of the third voltage signal is greater than the voltage value of the reference voltage signal, and the second control signal is a high-level signal.
[0008] In some embodiments, the control circuit further includes a third resistor; the PTT module includes a first resistor, a second resistor and a PTT button, and the pressing of the PTT button indicates that the PTT module has received the first instruction; the headphone port is grounded through the first resistor, and the headphone port is also grounded through the PTT button and the second resistor; the second analog switch is connected to the first power supply device through the third resistor, and the first power supply device sends the first voltage signal to the second analog switch through the third resistor; when the second analog switch is turned on and the PTT button is pressed, the third resistor is used to divide the first voltage signal together with the first resistor and the second resistor, so that the first end of the comparator receives the second voltage signal; when the second analog switch is turned on and the PTT button is released, the third resistor is used to divide the first voltage signal together with the first resistor, so that the first end of the comparator receives the third voltage signal.
[0009] In some embodiments, the control signal output module also includes a fourth resistor and a fifth resistor; the second end of the comparator is connected to the second power supply device through the fourth resistor, and the second end of the comparator is also grounded through the fifth resistor; the fourth resistor and the fifth resistor are used to divide the fourth voltage signal sent by the second power supply device, so that the second end of the comparator receives the reference voltage signal.
[0010] In some embodiments, the control circuit further includes: a detection module; the detection module is connected to the headphone port; the detection module is also connected to the first analog switch and the second analog switch respectively; the detection module is used to detect the impedance of the first module when the first module is connected to the headphone port, and when the impedance of the first module is greater than or equal to a preset threshold, determine that the first module is the PTT module and control the second analog switch to be turned on; when the impedance of the first module is less than the preset threshold, determine that the first module is the audio output module and control the first analog switch to be turned on.
[0011] In some embodiments, the detection module is specifically used to send a third control signal to the first analog switch and the second analog switch respectively when the impedance of the first module is greater than or equal to a preset threshold; wherein the third control signal is used to control the first analog switch to be disconnected, and to control the second analog switch to be turned on; and when the impedance is less than the preset threshold, send a fourth control signal to the first analog switch and the second analog switch respectively; wherein the fourth control signal is used to control the first analog switch to be turned on, and to control the second analog switch to be disconnected.
[0012] In some embodiments, the target analog switch includes a first control terminal, a first common terminal, a second common terminal, a first normally open terminal, a second normally open terminal, a first normally closed terminal, and a second normally closed terminal; wherein the target analog switch is the first analog switch or the second analog switch; for the first analog switch, the first control terminal is connected to the detection module; the first common terminal is used to receive the audio signal; the first normally open terminal is connected to the headphone port; the first normally closed terminal and the second normally closed terminal are suspended; for the second analog switch, the first control terminal is connected to the detection module; the first common terminal is used to receive the first voltage signal; the second common terminal is connected to the first normally closed terminal; the second normally closed terminal is connected to the first terminal of the comparator; the first normally open terminal and the second normally open terminal are suspended; for the first analog switch and the second analog switch, when the first control terminal receives the third control signal, the first common terminal is connected to the first normally closed terminal; the second normally closed terminal is connected to the first terminal of the comparator; the first normally open terminal and the second normally open terminal are suspended. the first common terminal and the first normally open terminal are disconnected; the path between the second common terminal and the second normally open terminal is disconnected; the path between the first common terminal and the first normally closed terminal is connected, and the path between the second common terminal and the second normally closed terminal is connected; the first normally closed terminal and the second normally closed terminal of the second analog switch are short-circuited, so that the first voltage signal received by the first common terminal is sent to the first terminal of the comparator via the first normally closed terminal after being processed by the PTT module; when the first control terminal receives the fourth control signal, the path between the first common terminal and the first normally open terminal is connected; the path between the second common terminal and the second normally open terminal is connected; the path between the first common terminal and the first normally closed terminal is disconnected, and the path between the second common terminal and the second normally closed terminal is disconnected, so that the first analog switch can send the received audio signal to the audio output module through the headphone port.
[0013] In some embodiments, the midpoint of the line connecting the second normally closed end of the second analog switch and the first end of the comparator is also connected to the second normally open end of the first analog switch, and the second common end of the first analog switch is used to receive a fourth voltage signal; the detection module is also connected to the baseband chip, and the detection module is also used to send a first indication signal to the baseband chip when it is detected that the impedance of the first module is less than the preset threshold; the first indication signal is used to indicate that the baseband chip does not process the high-level signal output by the comparator; wherein, when the impedance of the first module is less than the preset threshold, the first control end of the first analog switch receives the fourth control signal, so that the path between the second common end and the second normally open end is turned on, and the first control end of the first analog switch sends the fourth voltage signal to the first end of the comparator through the second normally open end of the first analog signal, so that the comparator outputs the high-level signal.
[0014] In a second aspect, the present application provides a control method for a headphone port, wherein the headphone port is connected to the control circuit described in the first aspect, and the control circuit is also connected to a baseband chip, and the headphone port is used to connect to an audio output module of a first headphone, or the headphone port is used to connect to a push-to-talk (PTT) module of a second headphone; the second headphone supports a PTT function; the method comprises: when the headphone port is connected to the audio output module, controlling a first analog switch of the control circuit to be turned on, and sending the audio signal to the audio output module through the headphone port, so that the audio output module outputs the audio signal to the user; when the headphone port is connected to the PTT module, controlling a second analog switch of the control circuit to be turned on, and sending a first voltage signal to the second analog switch, so that the first voltage signal can pass through the second analog switch and the first The headphone interface is transmitted to the PTT module, and is sent to the control signal output module after being processed by the PTT module; wherein the first voltage signal is used to control the PTT working mode of the baseband chip; when the PTT module receives the first instruction from the user to obtain the PTT voice right, the first voltage signal is processed by the PTT module and becomes a second voltage signal, and the second voltage signal is used to make the control signal output module output a first control signal, and the first control signal is used to control the baseband chip to be in the PTT sending mode; when the PTT module does not receive the first instruction, the first voltage signal is processed by the PTT module and becomes a third voltage signal, and the third voltage signal is used to make the control signal output module output a second control signal; the second control signal is used to control the baseband chip to be in the PTT receiving mode.
[0015] In a third aspect, the present application provides an electronic device, comprising the control circuit applied to the headphone port, the headphone port and the baseband chip described in the embodiment of the first aspect.
[0016] The present application provides a control circuit, a control method and an electronic device applied to a headphone port. The present application sets a control circuit applied to a headphone port in an electronic device, specifically including a first analog switch, a second analog switch and a control signal output module; wherein the first analog switch and the second analog switch are respectively connected to the headphone port; the headphone port is used to connect a first headphone or a second headphone supporting a PTT function. When the headphone port is connected to the first headphone, the first analog switch is turned on, and the audio signal can be transmitted to the audio output module of the first headphone, thereby realizing data transmission between the electronic device and the first headphone. When the headphone port is connected to the second headphone, the second analog switch is turned on, and the first voltage signal can be converted into a corresponding control signal via the PTT module and the control signal output module to control the baseband chip of the electronic device to operate in a PTT mode that matches the state of the PTT module. In this way, it is possible to make the electronic device simultaneously adapt to the first headphone and the second headphone supporting the PTT function. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] Figure 1 It is a schematic diagram of the structure of a CTIA headset or an OMTP headset;
[0018] Figure 2 It is a schematic diagram of the structure of a PTT headset;
[0019] Figure 3 A schematic diagram of the structure of a control circuit provided in an embodiment of the present application;
[0020] Figure 4 A schematic diagram of the structure of a control circuit provided in an embodiment of the present application;
[0021] Figure 5 A schematic diagram of the connection relationship between the control circuit and the second earphone provided in an embodiment of the present application;
[0022] Figure 6 A schematic diagram of the structure of a control circuit provided in an embodiment of the present application;
[0023] Figure 7 A schematic diagram of the structure of a control circuit provided in an embodiment of the present application;
[0024] Figure 8 A schematic diagram of the structure of a first analog switch and a second analog switch provided in an embodiment of the present application;
[0025] Fig. 9 A flow chart of a control method provided in an embodiment of the present application. DETAILED DESCRIPTION
[0026] In this application, "at least one" means one or more, and "plurality" means two or more. "And / or" describes the association relationship of associated objects, indicating that three relationships may exist. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone, where A and B can be singular or plural. The character " / " generally indicates that the associated objects before and after are in an "or" relationship. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single items or plural items. For example, at least one of a, b, or c alone can represent: a, b, c, a and b, a and c, or a, b, and c, where a, b, and c can be single or multiple. In addition, the terms "first" and "second" are used for descriptive purposes only and cannot be understood as indicating or implying relative importance.
[0027] The directions or positional relationships indicated by terms such as "center", "longitudinal", "lateral", "up", "down", "left", "right", "front", and "back" are based on the directions or positional relationships shown in the accompanying drawings and are only for the convenience of describing the present application and simplifying the description. They do not indicate or imply that the device or element referred to must have a specific direction, be constructed and operated in a specific direction, and therefore should not be understood as a limitation on the present application.
[0028] The terms "connected" and "connected" should be understood in a broad sense. For example, the "connected" or "connected" of a circuit structure can refer to not only physical connection, but also electrical connection or signal connection. For example, it can be directly connected, that is, physically connected, or indirectly connected through at least one intermediate element, as long as the circuit is connected, or it can be the internal connection of two elements; signal connection can refer to signal connection through a circuit or through a media medium, such as radio waves. For ordinary technicians in this field, the specific meanings of the above terms in this application can be understood according to specific circumstances.
[0029] First pass Figure 1 and Figure 2 The structures of traditional headsets (CTIA headsets or OMTP headsets) and PTT headsets are introduced.
[0030] Figure 1 Schematic diagram of the structure of a traditional headset.
[0031] like Figure 1 As shown, the conventional earphone 10 is composed of an earphone plug 11 and a circuit part 12. The earphone plug 11 is a four-section plug, which includes a left channel section L1, a right channel section R1, a signal loop section G1 and a microphone section M1.
[0032] Among them, M1 is connected to G1 through microphone MIC1, and MIC1 is connected to button H in parallel.
[0033] L1 is connected to G1 through speaker SPK_L1.
[0034] R1 is connected to G1 through speaker SPK_R1.
[0035] The electronic device is provided with an earphone jack adapted to the four-section plug. The earphone plug is inserted into the earphone jack to realize data transmission between the electronic device and various modules of the circuit part.
[0036] Figure 1 The working principle of the traditional headset in the call scenario is as follows: when a call comes in, press the HOOK button, the electronic device controls MIC1 to be in working state, detects and collects sound signals, and sends sound signals to the caller. At the same time, the electronic device controls SPK_L1 and SPK_R1 to be in working state, receives the caller's sound signal and plays the sound signal to the user through the traditional headset. In other words, the traditional headset 10 is in full-duplex working mode. It can send sound signals to the caller and receive the caller's sound signal at the same time.
[0037] Figure 2 It is a schematic diagram of the structure of a PTT headset.
[0038] like Figure 2 As shown, the PTT headset 20 is composed of an earphone plug 21 and a circuit part 22. Similar to a conventional earphone, the earphone plug 21 is also a four-section plug, wherein the earphone plug 21 includes a left channel section L2, a PTT section P, a signal loop section G2 and a microphone section M2.
[0039] Among them, M2 is connected to G2 through microphone MIC2.
[0040] L2 is connected to G2 via speaker SPK_L2.
[0041] P is connected to G2 via a PTT module.
[0042] The earphone plug 21 is used to connect to the earphone interface of the electronic device to realize data transmission between the electronic device and each module of the circuit part 22 .
[0043] Among them, the PTT module specifically includes a resistor R1, a resistor R2 and a PTT button; the working principle of the PTT headset in the call scenario is as follows: when the PTT button is not pressed, the impedance between P and the ground is fixed and related to R1. At this time, the electronic device controls SPK_L2 to be in a working state and MIC2 to be in a non-working state. The PTT headset can only receive the sound signal sent by the communication party, but cannot collect and send the sound signal to the communication party. When the PTT button is pressed, the impedance between P and the ground changes, which is determined by R1 and R2. In this case, the electronic device controls MIC2 to be in a working state and SPK_L2 to be in a non-working state; PTT can collect the user's sound signal and transmit the sound signal to the communication party, but cannot receive the sound signal from the communication party. In other words, the PTT headset 10 is in a half-duplex working mode. It is impossible to receive the sound signal sent by the communication party while sending a sound signal to the communication party, or it is impossible to send a sound signal to the communication party while receiving the sound signal sent by the communication party.
[0044] Existing electronic devices usually only support data transmission with various modules of traditional headphones through the headphone interface to meet the user's demand for full-duplex communication mode.
[0045] With the development of lifestyle, electronic devices used in industrial or logistics scenarios, such as personal digital assistants (PDAs), have a demand for PTT headsets. However, circuits related to the headphone interface in existing electronic devices are usually designed for traditional headsets and are only adapted to traditional headsets, but not compatible with PTT headsets. After the PTT headset is connected to the headphone interface of the electronic device, it cannot work properly.
[0046] Based on this, the present application provides a control circuit applied to an earphone port. The present application adds the control circuit in an electronic device, and the control circuit can adapt to both traditional earphones and PTT earphones at the same time, so that the electronic device can perform data transmission with the audio output module of the traditional earphone when the traditional earphone is connected, and can also work in PTT mode when the PTT earphone is connected.
[0047] Specifically, the control circuit includes a first analog switch and a second analog switch; the first analog switch and the second analog switch correspond to the first earphone and the second earphone respectively.
[0048] The first analog switch and the second analog switch can be connected to the audio output module in the first earphone or the PTT module in the second earphone through the earphone port.
[0049] If the first earphone is connected to the earphone port, the first analog switch is turned on, and the audio signal generated in the electronic device can be sent to the audio output module of the first earphone through the first analog switch, thereby realizing data transmission between the electronic device and the first earphone.
[0050] If a second earphone is connected to the earphone port, the second analog switch is turned on, so that the PTT module of the second earphone can process the first voltage signal and then send it to the control signal output module. Based on the result of the control signal output module, the baseband chip of the electronic device is controlled to be in which PTT working mode, so that the electronic device works in the corresponding PTT working mode, thereby achieving compatibility of the electronic device with traditional earphones and PTT earphones.
[0051] Next, through Figure 3 The working principle of the control circuit is described in the embodiment.
[0052] Figure 3 A schematic diagram of the structure of a control circuit provided in an embodiment of the present application.
[0053] like Figure 3 As shown, the control circuit 30 includes a first analog switch 31 , a second analog switch 32 and a control signal output module 33 .
[0054] The first analog switch 31 and the second analog switch 32 are respectively connected to the earphone port 41 . The midpoint of the line connecting the second analog switch 32 and the earphone port 41 is also connected to the control signal output module 33 .
[0055] The midpoint of the line connecting the second analog switch 32 and the headphone port 41 refers to any point on the line connecting the second analog switch 32 and the headphone port 41 .
[0056] It can be understood that, as described above, the electronic device is provided with a headphone interface, and the electronic device collects or plays sound signals through any headphone, and the headphone plug needs to be inserted into the headphone interface to perform data transmission between the electronic device and the headphone.
[0057] The electronic device of the present application is adapted to a first earphone and a second earphone, and the first earphone can be as follows Figure 1 The conventional earphone shown in FIG. 1 , the second earphone may be as shown in FIG. Figure 2 PTT headset shown.
[0058] like Figure 1 and Figure 2 As shown, both the conventional headphone plug and the PTT headphone plug are four-section headphone plugs. Accordingly, the headphone interface in the electronic device also includes a headphone port 41, a second headphone port, a third headphone port and a fourth headphone port.
[0059] When the earphone plug is inserted into the earphone interface, the second earphone port is in contact with the L1 of the first earphone or the L2 of the second earphone to achieve data transmission with the SPK_L1 of the first earphone or the SPK_L2 of the second earphone.
[0060] The third earphone port is in contact with the G1 segment of the first earphone or the G2 segment of the second earphone, thereby achieving grounding and providing a signal transmission loop for other modules.
[0061] The fourth earphone port is in contact with the M1 segment of the first earphone or the M2 segment of the second earphone to implement data transmission with the MIC1 of the first earphone or the MIC2 of the second earphone.
[0062] The earphone port 41 is connected to the R segment of the first earphone or the P segment of the second earphone to implement data transmission with the SPK_R1 of the first earphone or the PTT module of the second earphone.
[0063] The earphone port 41 is connected to the R segment of the first earphone or the P segment of the second earphone to implement data transmission with the SPK_R1 of the first earphone or the PTT module of the second earphone.
[0064] like Figure 1 and Figure 2 As shown, the difference between the first earphone and the second earphone is that the first earphone includes two speakers SPK_L1 and SPK_R2, corresponding to the left ear and the right ear respectively, while the second earphone includes only one speaker SPK_L, corresponding to the left ear. A PTT module is added to replace another speaker.
[0065] The audio output module may be a speaker SPK_L1.
[0066] It should be noted that, in the headphone interface of the electronic device, when the headphone port 41 is connected to the audio output module of the first headphone through the R segment of the headphone plug of the first headphone, the second headphone port to the fourth headphone port must be connected to the module corresponding to the second headphone through the corresponding segment of the headphone plug of the first headphone. When the headphone port 41 is connected to the PTT module of the second headphone through the P segment of the headphone plug of the second headphone, the second headphone port to the fourth headphone port must be connected to the module corresponding to the second headphone through the corresponding segment of the headphone plug of the second headphone.
[0067] The control circuit 30 of the embodiment of the present application is only designed for the headphone port 41, and the circuit module in the electronic device connected to the second port to the fourth port for processing the signals input from other sections of the headphone can reuse the existing technology.
[0068] The first analog switch 31 is connected to an audio codec (not shown in the figure), such as Figure 1As shown, the first analog switch 31 is used to receive the audio signal sent by the audio codec. When the earphone port 41 is connected to the audio output module of the first earphone, the first analog switch 31 is turned on, so that the audio signal can be transmitted to the first earphone through the first analog switch 31 and the earphone port 41, thereby realizing data transmission between the electronic device and the audio output module of the first earphone.
[0069] The second analog switch 32 is connected to the first power supply module, and the first power supply module inputs the first voltage signal to the second analog switch 32. When the earphone port 41 is connected to the PTT module of the second earphone, the second analog switch 32 is turned on, so that the first voltage signal is converted into the second voltage signal or the third voltage signal through the processing of the PTT module.
[0070] For details, please refer to Figure 2 and Figure 3 The earphone port 41 is in contact with the P terminal, thereby being electrically connected to the PTT module, and the PTT module includes a first resistor R1, a second resistor R2, and a PTT button B. When the PTT button is pressed, R1 and R2 divide the first voltage signal, so that the first voltage signal is converted into a second voltage signal and then input into the control signal output module 33; when the PTT button is not pressed, only R1 divides the first voltage signal, so that the voltage signal input into the control signal output module 33 is converted into a third voltage signal.
[0071] The second voltage signal is smaller than the third voltage signal.
[0072] The PTT button in the PTT module is used to receive the first instruction of the user to obtain the right to speak; if the PTT button is pressed, it means that the PTT module has received the first instruction and the user needs to obtain the right to speak; at this time, the baseband chip 42 in the electronic device needs to enter the PTT sending mode, collect the user's voice signal through the PTT headset and send it to the communication party. If the PTT button is released, it means that the PTT module has not received the first instruction and the user has released the right to speak; at this time, the baseband chip 42 in the electronic device needs to enter the PTT receiving mode, be able to receive the voice signal sent by the communication party and play it to the user through the PTT headset after processing the voice signal.
[0073] The control signal output module 33 can generate a corresponding control signal based on the input second voltage signal or the third voltage signal to control the baseband chip 42 to enter a PTT working mode corresponding to the PTT key state.
[0074] Specifically, when the control signal output module 33 receives the second voltage signal, it indicates that the PTT button is pressed, and the control signal output module 33 outputs the first control signal; the first control signal is used to control the baseband chip 42 to enter the above-mentioned PTT sending mode.
[0075] When the control signal output module 33 receives the third voltage signal, it indicates that the PTT button is released, and the control signal output module 33 outputs a second control signal; the second control signal is used to control the baseband chip 42 to enter the above-mentioned PTT receiving mode.
[0076] The present application adds a control circuit 30 in the electronic device, and the control circuit 30 can adapt to traditional headphones and PTT headphones. Specifically, the control circuit 30 includes a first analog switch 31, a second analog switch 32 and a control signal output module 33; wherein the first analog switch 31 and the second analog switch 32 are respectively connected to the headphone port 41; the headphone port 41 is used to connect the audio output module of the first headphone or the PTT module of the second headphone. When the headphone port 41 is connected to the first headphone, the first analog switch 31 is turned on, so that the audio signal received by the first analog switch 31 can be transmitted to the audio output module of the first headphone, thereby realizing data transmission between the electronic device and the first headphone. When the headphone port 41 is connected to the second headphone, the second analog switch 32 is turned on, so that the first voltage signal received by the second analog switch 32 is converted into a corresponding control signal via the PTT module to control the electronic device to work in the PTT mode matching the state of the PTT module.
[0077] In the present application, the control signal output module 33 may include a comparator. Next, Figure 4 The embodiment describes the structure of the control circuit 30 when the control signal output module 33 includes a comparator.
[0078] Figure 4 Schematic diagram of the structure of the control circuit 30 provided in the embodiment of the present application. Figure 4 As shown, the control signal output module 33 includes a comparator U.
[0079] The second analog switch 32 is connected to a first terminal of the comparator U, and a second terminal of the comparator U is used to receive a reference voltage signal.
[0080] The first end of the comparator U may be the positive leg of the comparator U, and the second end of the comparator U may be the negative leg of the comparator U. A feedback resistor R is connected between the positive leg and the output end of the comparator U. f Among them, R f Alternatively, in some embodiments, the positive pin of the comparator U is disconnected from the output terminal.
[0081] Among them, if the second voltage signal is smaller than the reference voltage signal, the first control signal output by the comparator U is a low level signal.
[0082] If the third voltage signal is greater than the reference voltage signal, the second control signal output by the comparator U is a high level signal.
[0083] like Figure 2 As shown, the PTT module is composed of a first resistor R1, a second resistor R2 and a PTT button. Therefore, the voltage signal input to the first end of the comparator U can be changed by pressing and releasing the PTT button.
[0084] Next, through Figure 5 The embodiment describes the process of obtaining the second voltage signal and the third voltage signal.
[0085] Figure 5 This is a schematic diagram of the connection between the control circuit 30 provided in an embodiment of the present application and the second earphone.
[0086] like Figure 5 As shown, the control circuit 30 further includes a third resistor R3 , the second analog switch 32 is connected to the first power supply device via the third resistor, and the first power supply device sends a first voltage signal to the second analog switch 32 via the third resistor.
[0087] like Figure 5 As shown, the second analog switch 32 is connected to the first power supply device through the third resistor R3. The earphone port 41 is connected to the PTT module through the P segment of the second earphone.
[0088] When the second analog switch 32 is turned on, if the PTT button B is pressed, the path between the earphone port 41 and R2 is turned on, R3, R1 and R2 jointly divide the first voltage signal, and the voltage value corresponding to the second voltage signal input to the first terminal of the comparator U is: V + =V S1 *(R1 / / R2) / (R3+R1 / / R2). Among them, V S1 is the output voltage of the first power supply device; that is, the voltage value of the first voltage signal, and the “ / / ” symbol represents the meaning of parallel connection, R1 / / R2=(R1*R2) / (R1+R2).
[0089] When the second analog switch 32 is turned on, if the PTT button B is released (not pressed), the path between the earphone port 41 and R2 is disconnected, and R3 and R1 jointly divide the first voltage signal. Then, the voltage value corresponding to the third voltage signal input to the first terminal of the comparator U is: V + =V S1 *R1 / (R3+R1).
[0090] It can be understood that when B is pressed, the resistance value of the equivalent resistor formed by R1, R2, and R3 is smaller than the resistance value of the equivalent resistor formed by R1 and R3 when B is released. Therefore, the voltage value of the second voltage signal obtained when B is pressed is smaller than the voltage value of the third voltage signal obtained when B is released.
[0091] Accordingly, next, Figure 6 The embodiment describes how to obtain a reference voltage signal.
[0092] Figure 6 This is a structural diagram of the control circuit 30 provided in an embodiment of the present application.
[0093] like Figure 6 As shown, the control circuit 30 further includes a fourth resistor R4 and a fifth resistor R5.
[0094] The second end of the comparator U is connected to the second power supply device (not shown) through R4, and the second end of the comparator U is also grounded through R5. The second power supply device is used to provide a fourth voltage signal to the comparator U. R4 and R5 play a voltage dividing role, and divide the fourth voltage signal sent by the second power supply device.
[0095] Thus, the voltage value of the reference voltage signal input to the second terminal of the comparator U is: V- = V f *R5 / (R4+R5). Where, V f is the output voltage of the second power supply device.
[0096] In some embodiments, V S1 Can be 3.3V, V f It can be 1.8 V. The control circuit 30 can be adapted to more different second earphones by designing the sizes of R4, R5 and R3.
[0097] It can be understood that if R1 and / or R2 in the second earphone are different, the second earphone can be considered different. Exemplarily, R3=8KΩ, R4=R5=1MΩ are selected, and Table 1 shows the voltage values of the second voltage signal, the third voltage signal, and the reference voltage signal under different second earphones.
[0098] Table 1
[0099]
[0100] It can be seen that in the embodiment of the present application, by setting the sizes of R3, R4, and R5, the second voltage signals corresponding to different second headphones can be smaller than the reference voltage signal, and the third voltage signals corresponding to different second headphones can be larger than the reference voltage signal, so that the port control circuit is compatible with more second headphones.
[0101] It can be understood that the impedance of the PTT module in the PTT headset is higher than the impedance of the audio output module in the traditional headset. Therefore, in some embodiments, when there is a first module connected to the headphone port 41, it is possible to determine whether the first module connected to the headphone port 41 is a PTT module or an audio output module by detecting the impedance of the first module, thereby controlling the first analog switch 31 or the second analog switch 32 to be turned on.
[0102] Next, through Figure 7 The working principle of the detection module is described in the embodiment.
[0103] Figure 7 A schematic diagram of the structure of the control circuit 30 provided in an embodiment of the present application.
[0104] like Figure 7 As shown, the control circuit 30 further includes a detection module, which is connected to the earphone port 41 , and is also connected to the first analog switch 31 and the second analog switch 32 .
[0105] If there is a first module connected to the earphone port 41 , the detection module can determine whether the first module is an audio output module or a PTT module by detecting the impedance of the first module connected to the earphone port 41 .
[0106] The detection module determines the impedance of the first module and the preset threshold. If the impedance of the first module is greater than or equal to the preset threshold, the detection module determines that the first module is a PTT module and controls the second analog switch 32 to be turned on.
[0107] If the impedance of the first module is less than the preset threshold, the detection module determines that the first module is an audio output module, and controls the first analog switch 31 to be turned on.
[0108] The preset threshold value may be set according to actual experience. For example, the preset threshold value may be 1000Ω.
[0109] It should be noted that in the present application, the states of the first analog switch 31 and the second analog switch 32 are mutually exclusive. That is, when the first analog switch 31 is turned on, the second analog switch 32 is turned off; when the first analog switch 31 is turned off, the second analog switch 32 is turned on.
[0110] The structures of the first analog switch 31 and the second analog switch 32 may be the same or different.
[0111] In some embodiments, the detection module may send different control signals to the first analog switch 31 and the second analog switch 32 respectively to control the first analog switch 31 and the second analog switch 32 to be in different states.
[0112] In some other embodiments, the detection module may send the same control signal to the first analog switch 31 and the second analog switch 32 to control the first analog switch 31 and the second analog switch 32 to be in different states.
[0113] Exemplarily, the first analog switch 31 has the same structure as the second analog switch 32. When the detection module detects that the impedance of the first module is greater than or equal to a preset threshold, the detection module sends a third control signal to the first analog switch 31 and the second analog switch 32 respectively, wherein the third control signal is used to control the first analog switch 31 to be disconnected and the second analog switch 32 to be turned on.
[0114] When the impedance of the first module is less than a preset threshold, the detection module sends a fourth control signal to the first analog switch 31 and the second analog switch 32 respectively, and the fourth control signal is used to control the first analog switch 31 to be turned on and the second analog switch 32 to be turned off.
[0115] The third control signal may be a low level signal, and the fourth control signal may be a high level signal.
[0116] As described above, the first analog switch 31 and the second analog switch 32 have the same structure, and the detection module can send the same control signal to the first analog switch 31 and the second analog switch 32 to control the first analog switch 31 and the second analog switch 32 to be in different states.
[0117] Next, through Figure 8 The embodiment describes the structure of the first analog switch 31 and the second analog switch 32 , and how to control the first analog switch 31 and the second analog switch 32 to achieve compatibility between the traditional headset and the PTT headset.
[0118] Figure 8 FIG. 3 is a structural diagram of a control circuit 30 provided in an embodiment of the present application. Figure 8 As shown, the first analog switch 31 and the second analog switch 32 in the present application have the same structure.
[0119] Reference below Figure 8 The structure of the analog switch is described below. The analog switch is the first analog switch 31 or the second analog switch 32 .
[0120] The analog switch includes a first control terminal IN1, a first common terminal COM1, a second common terminal COM2, a first normally open terminal NO1, a second normally open terminal NO2, a first normally closed terminal NC1, and a second normally closed terminal NC2.
[0121] Among them, for the first analog switch 31, IN1 is connected to the detection module respectively. COM1 is connected to the audio codec for receiving audio signals; NO1 is connected to the earphone port 41; NC1 and NC2 are suspended.
[0122] For the second analog switch 32, IN1 is connected to the detection module, COM1 is connected to the first power supply device, COM2 is connected to NC1, and NC2 is electrically connected to the first end of the comparator U. NO1 and NO2 are suspended. The resistor R6 between NC2 and the comparator U plays a current limiting role.
[0123] When IN1 receives the third control signal (low level signal), the path between COM1 and NO1 is disconnected, the path between COM2 and NO2 is disconnected, the path between COM1 and NC1 is connected, and the path between COM2 and NC2 is connected.
[0124] For the second analog switch 32, since the path between COM1 and NC1 is connected, the path between COM2 and NC2 is connected, and COM2 is connected to NC1, the first voltage signal in the second analog switch 32 can be transmitted to NC2 through COM1, NC1, COM2 in sequence, so that COM1 and NC2 are short-circuited. The midpoint between the second analog switch 32 and the earphone port 41 is also connected to the first end of the comparator U; in this way, the first voltage signal can be transmitted to the first end of the comparator U after being processed by the PTT module.
[0125] For the first analog switch 31 , the path between COM1 and NO1 is disconnected, and the path between COM2 and NO2 is disconnected, so the audio signal sent by the audio codec module cannot be transmitted to the comparator U. Therefore, it can be considered that the first analog switch 31 is not turned on.
[0126] When IN1 receives the fourth control signal (high level signal), the path between COM1 and NO1 is turned on, the path between COM2 and NO2 is turned on, the path between COM1 and NC1 is turned off, and the path between COM2 and NC2 is turned off.
[0127] With respect to the first analog switch 31 , since the path between COM1 and NO1 is connected, the audio signal received by COM1 can be sent to the audio output module via NO1 .
[0128] For the second analog switch 32 , since the path between COM1 and NC1 is disconnected, and the path between COM2 and NC2 is disconnected, the first voltage signal cannot be transmitted from COM1 to NC2 , and it can be considered that the second analog switch 32 is not turned on.
[0129] In some embodiments, Figure 8 As shown, NO2 of the first analog switch 31 is also connected to the first end of the comparator U, and COM2 of the first analog switch 31 is used to receive the fourth voltage signal. In other words, COM2 of the first analog switch 31 is also connected to the second power supply device to receive the fourth voltage signal sent by the second power supply device.
[0130] Then, when IN1 of the first analog switch 31 receives the fourth control signal (high level signal), the fourth voltage signal is input to the first terminal of the comparator U via COM2 and NO2, so that the comparator U outputs a high level signal.
[0131] The detection module is also connected to the baseband chip 42. The detection module is also used to send a first indication signal to the baseband chip 42 when it detects that the impedance of the first module is less than a preset threshold, indicating that the baseband chip 42 does not process the high-level signal output by the comparator U based on the fourth control signal.
[0132] In the embodiment of the present application, the first analog switch 31 and the second analog switch 32 have the same structure, and the connection relationship between the ports of the first analog switch 31 and the second analog switch 32 is set to achieve the use of a control signal to control the first analog switch 31 and the second analog switch 32 to be in different working states. In this way, the first analog switch 31 and the second analog switch 32 with the same structure are used to achieve the compatibility of the electronic device with the PTT headset and the traditional headset, thereby reducing the design cost of the electronic device.
[0133] Based on the above embodiment, the present application provides an electronic device 40, including the control circuit 30, the earphone port 41 and the baseband chip 42 in the embodiment of the present application. The connection relationship between the control circuit 30, the earphone port 41 and the baseband chip 42 is as above. Figure 8 As shown, the functions of the control circuit 30, the earphone port 41 and the baseband chip 42 are as shown in the above embodiment and will not be described in detail here.
[0134] Based on the above embodiments, the present application provides a control method, which is applied to the headphone port 41 in the present application. The headphone port 41 is connected to the control circuit 30, and the control circuit 30 is also connected to the baseband chip. The electronic device controls the control circuit connected to the headphone port to achieve compatibility of the electronic device with the first headphone and the second headphone.
[0135] Fig. 9 The following is a schematic diagram of the implementation flow of the control method provided in the embodiment of the present application. Fig. 9 As shown, the method includes:
[0136] S901: Detect whether the first module connected to the earphone port is an audio output module or a PTT module.
[0137] Among them, S901 can be obtained by the detection module detecting the impedance of the first module. If the impedance of the first module is greater than or equal to a preset threshold, the first module is an audio output module, and S902 is executed.
[0138] If the impedance of the first module is less than the preset threshold, the first module is a PTT module, and S903 is executed.
[0139] S902: Control the first analog switch to be turned on, and send the audio signal to the audio output module through the headphone port, so that the audio output module outputs the audio signal to the user.
[0140] As described above, the control circuit includes a first analog switch and a second analog switch, and the first analog switch and the second analog switch are connected to the earphone port respectively.
[0141] The earphone port is used as a medium between the earphone and the electronic device, and is used to connect the audio output module of the first earphone or the PTT module of the second earphone. The second earphone is a PTT earphone.
[0142] The first earphone corresponds to the first analog switch, and the second earphone corresponds to the second analog switch. When the audio output module of the first earphone is connected to the earphone port, the first analog switch is turned on to realize data communication between the electronic device and the first earphone.
[0143] S903: Control the second analog switch to be turned on, and send the first voltage signal to the second analog switch, so that the first voltage signal can be sent to the control signal output module after being processed by the PTT module.
[0144] The control circuit also includes an output module, which is used to output a control signal for controlling the PTT working mode of the baseband chip.
[0145] When the PTT module of the second earphone is connected to the earphone port, the second analog switch is turned on, so that the first voltage signal can be transmitted to the control signal output module via the PTT module.
[0146] In the present application, the detection module in the control circuit can control the first analog switch or the second analog switch to be turned on based on the detected impedance. The specific implementation method is as described in the above embodiment and will not be repeated here.
[0147] In the embodiment of the present application, when the headphone port is connected to the first headphone, the first analog switch is turned on, so that the audio signal received by the first analog switch can be transmitted to the audio output module of the first headphone, thereby realizing data transmission between the electronic device and the first headphone. When the headphone port is connected to the second headphone, the second analog switch is turned on, so that the first voltage signal received by the second analog switch is converted into a corresponding control signal via the PTT module to control the electronic device to work in the PTT mode matching the state of the PTT module. In this way, the electronic device can adapt to the first headphone and the second headphone at the same time.
[0148] The above is only an implementation method of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
Claims
1. A control circuit applied to an earphone port, characterized in that: include: A first analog switch, a second analog switch and a control signal output module; wherein the control signal output module is connected to a baseband chip; The first analog switch and the second analog switch are connected to the headphone port respectively; wherein the headphone port is used to connect to the audio output module of the first headphone, or the headphone port is used to connect to the push-to-talk (PTT) module of the second headphone; the second headphone supports the PTT function; The midpoint of the line connecting the second analog switch and the headphone port is connected to the control signal output module; The first analog switch is configured to be turned on when the headphone port is connected to the audio output module, and to send the received audio signal to the audio output module through the headphone port, so that the audio output module outputs the audio signal to the user; The second analog switch is used to be turned on when the earphone port is connected to the PTT module, so that the first voltage signal received by the second analog switch can be transmitted to the PTT module through the second analog switch and the earphone port, and sent to the control signal output module after being processed by the PTT module; wherein the first voltage signal is used to control the PTT working mode of the baseband chip; When the PTT module receives a first instruction from a user to obtain the PTT speaking right, the first voltage signal is converted into a second voltage signal after being processed by the PTT module; the control signal output module outputs a first control signal based on the received second voltage signal; the first control signal is used to control the baseband chip to be in the PTT sending mode; When the PTT module does not receive the first instruction, the first voltage signal becomes a third voltage signal after being processed by the PTT module; the control signal output module outputs a second control signal based on the received third voltage signal; the second control signal is used to control the baseband chip to be in PTT receiving mode.
2. The control circuit according to claim 1, characterized in that: The control signal output module includes a comparator; the midpoint of the line connecting the second analog switch and the headphone port is connected to the first end of the comparator; the second end of the comparator is used to receive a reference voltage signal; Wherein, the voltage value of the second voltage signal is less than the voltage value of the reference voltage signal, and the first control signal is a low level signal; The voltage value of the third voltage signal is greater than the voltage value of the reference voltage signal, and the second control signal is a high level signal.
3. The control circuit according to claim 2, characterized in that: The control circuit further includes a third resistor; the PTT module includes a first resistor, a second resistor and a PTT button, and the pressing of the PTT button indicates that the PTT module has received the first instruction; the headphone port is grounded through the first resistor, and the headphone port is also grounded through the PTT button and the second resistor; The second analog switch is connected to the first power supply device through the third resistor, and the first power supply device sends the first voltage signal to the second analog switch through the third resistor; When the second analog switch is turned on and the PTT button is pressed, the third resistor is used to divide the first voltage signal together with the first resistor and the second resistor, so that the first end of the comparator receives the second voltage signal; When the second analog switch is turned on and the PTT button is released, the third resistor is used to divide the first voltage signal together with the first resistor, so that the first end of the comparator receives the third voltage signal.
4. The control circuit according to claim 2 or 3, characterized in that: The control signal output module further includes a fourth resistor and a fifth resistor; the second end of the comparator is connected to the second power supply device through the fourth resistor, and the second end of the comparator is also grounded through the fifth resistor; The fourth resistor and the fifth resistor are used to divide the fourth voltage signal sent by the second power supply device, so that the second end of the comparator receives the reference voltage signal.
5. The control circuit according to claim 4, characterized in that: The control circuit further includes: a detection module; the detection module is connected to the headphone port; the detection module is also connected to the first analog switch and the second analog switch respectively; The detection module is configured to detect the impedance of the first module when the first module is connected to the earphone port, and when the impedance of the first module is greater than or equal to a preset threshold, determine that the first module is the PTT module and control the second analog switch to be turned on; When the impedance of the first module is less than the preset threshold, the first module is determined to be the audio output module and the first analog switch is controlled to be turned on.
6. The control circuit according to claim 5, characterized in that: The detection module is specifically used to send a third control signal to the first analog switch and the second analog switch respectively when the impedance of the first module is greater than or equal to a preset threshold; wherein the third control signal is used to control the first analog switch to be disconnected, and control the second analog switch to be turned on; When the impedance is less than the preset threshold, a fourth control signal is sent to the first analog switch and the second analog switch respectively; wherein the fourth control signal is used to control the first analog switch to be turned on and the second analog switch to be turned off.
7. The control circuit according to claim 6, characterized in that: The target analog switch includes a first control terminal, a first common terminal, a second common terminal, a first normally open terminal, a second normally open terminal, a first normally closed terminal, and a second normally closed terminal; wherein the target analog switch is the first analog switch or the second analog switch; For the first analog switch, the first control end is connected to the detection module; the first common end is used to receive the audio signal; the first normally open end is connected to the headphone port; the first normally closed end and the second normally closed end are suspended; For the second analog switch, the first control end is connected to the detection module; the first common end is used to receive the first voltage signal; the second common end is connected to the first normally closed end; the second normally closed end is connected to the first end of the comparator; the first normally open end and the second normally open end are suspended; For the first analog switch and the second analog switch, when the first control end receives the third control signal, the path between the first common end and the first normally open end is disconnected; the path between the second common end and the second normally open end is disconnected; the path between the first common end and the first normally closed end is connected, and the path between the second common end and the second normally closed end is connected; so that the first normally closed end and the second normally closed end of the second analog switch are short-circuited, so that the first voltage signal received by the first common end is sent to the first end of the comparator via the first normally closed end after being processed by the PTT module; When the first control end receives the fourth control signal, the path between the first common end and the first normally open end is connected; the path between the second common end and the second normally open end is connected; the path between the first common end and the first normally closed end is disconnected, and the path between the second common end and the second normally closed end is disconnected, so that the first analog switch can send the received audio signal to the audio output module through the headphone port.
8. The control circuit according to claim 7, characterized in that: The midpoint of the line connecting the second normally closed end of the second analog switch and the first end of the comparator is also connected to the second normally open end of the first analog switch, and the second common end of the first analog switch is used to receive a fourth voltage signal; The detection module is also connected to the baseband chip, and the detection module is also used to send a first indication signal to the baseband chip when detecting that the impedance of the first module is less than the preset threshold; the first indication signal is used to instruct the baseband chip not to process the high level signal output by the comparator; Among them, when the impedance of the first module is less than the preset threshold, the first control end of the first analog switch receives the fourth control signal, so that the path between the second common end and the second normally open end is turned on, and the first control end of the first analog switch sends the fourth voltage signal to the first end of the comparator through the second normally open end of the first analog signal, so that the comparator outputs the high level signal.
9. A control method applied to an earphone port, characterized in that: The headphone port is connected to the control circuit according to any one of claims 1 to 8, the control circuit is also connected to the baseband chip, the headphone port is used to connect to the audio output module of the first headphone, or the headphone port is used to connect to the push-to-talk (PTT) module of the second headphone; The second headset supports a PTT function; The method comprises: When the earphone port is connected to the audio output module, controlling the first analog switch of the control circuit to be turned on, sending the audio signal to the audio output module through the earphone port, so that the audio output module outputs the audio signal to the user; When the earphone port is connected to the PTT module, the second analog switch of the control circuit is controlled to be turned on, and a first voltage signal is sent to the second analog switch, so that the first voltage signal can be transmitted to the PTT module through the second analog switch and the first earphone interface, and sent to the control signal output module after being processed by the PTT module; wherein the first voltage signal is used to control the PTT working mode of the baseband chip; when the PTT module receives a first instruction from a user to obtain the PTT voice right, the first voltage signal is processed by the PTT module and becomes a second voltage signal, and the second voltage signal is used to make the control signal output module output a first control signal, and the first control signal is used to control the baseband chip to be in the PTT sending mode; when the PTT module does not receive the first instruction, the first voltage signal is processed by the PTT module and becomes a third voltage signal, and the third voltage signal is used to make the control signal output module output a second control signal; the second control signal is used to control the baseband chip to be in the PTT receiving mode.
10. An electronic device, characterized in that: The invention comprises the control circuit, the headphone port and the baseband chip as claimed in any one of claims 1 to 8.