CN107005762B - Audio connector identification method and portable electronic equipment - Google Patents

Audio connector identification method and portable electronic equipment Download PDF

Info

Publication number
CN107005762B
CN107005762B CN201580064063.6A CN201580064063A CN107005762B CN 107005762 B CN107005762 B CN 107005762B CN 201580064063 A CN201580064063 A CN 201580064063A CN 107005762 B CN107005762 B CN 107005762B
Authority
CN
China
Prior art keywords
voltage
switch
type
processor
portable electronic
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201580064063.6A
Other languages
Chinese (zh)
Other versions
CN107005762A (en
Inventor
罗文林
周学中
胡家福
彦许星
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Publication of CN107005762A publication Critical patent/CN107005762A/en
Application granted granted Critical
Publication of CN107005762B publication Critical patent/CN107005762B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04RLOUDSPEAKERS, MICROPHONES, GRAMOPHONE PICK-UPS OR LIKE ACOUSTIC ELECTROMECHANICAL TRANSDUCERS; DEAF-AID SETS; PUBLIC ADDRESS SYSTEMS
    • H04R3/00Circuits for transducers, loudspeakers or microphones

Abstract

An audio connector identification method and a portable electronic device are provided, wherein the portable electronic device detects the voltage of a second end (2) of a switch (121), and determines whether an input device is connected to a first end (1) of the switch (121) according to the voltage of the second end (2) of the switch (121); when the portable electronic device determines that the interface of the input device is a three-section interface, the portable electronic device controls the first end (1) of the switch (121) to be connected with the third end (3) of the switch (121), detects the voltage of the third end (3) of the switch (121), and determines the type of the input device according to the voltage of the third end (3) of the switch (121). The portable electronic equipment can identify the three-section microphone and the three-section earphone, and the user can use the three-section microphone K to song, so that the user experience of using the portable electronic equipment K to song is improved.

Description

Audio connector identification method and portable electronic equipment
Technical Field
The embodiment of the invention relates to the technology of electronic equipment, in particular to an audio connector identification method and portable electronic equipment.
background
portable electronic devices (e.g., smart phones and tablet computers) are increasingly rich in functions, many portable electronic devices have a karaoke function, but the input modes of the portable electronic devices in the current market for realizing karaoke mainly include the following: a microphone (MIC for short) of the portable electronic device, a microphone of a wired earphone or a bluetooth microphone; the following output modes are mainly used for K songs: the portable electronic equipment is provided with a loudspeaker, an external small wired sound box, a Bluetooth earphone or a Bluetooth sound box.
In the existing karaoke process, the portable electronic equipment cannot identify the three-section microphone, and a user can only use the microphone of the portable electronic equipment or the microphone karaoke of a wired earphone. When a user uses a microphone of the portable electronic device or a microphone K of a wired earphone to sing, the user needs to sing the portable electronic device due to the limitation of the microphone, and cannot sing freely, so that the user experience is seriously affected; when a user uses the microphone K of the wired earphone to song, the earphone wire of the wired earphone is too short, and the user cannot move freely. In addition, the microphone adopted by the existing K song input mode is an accessory at an amateur level, the input signal quality is poor, the singing voice quality is directly influenced, a good K song atmosphere cannot be created, the entertainment effect is influenced, and the user experience is reduced.
Disclosure of Invention
the embodiment of the invention provides an audio connector identification method and portable electronic equipment, so that the portable electronic equipment can identify a three-section microphone, a user can use a three-section microphone K song, and the user experience of the user using the portable electronic equipment K song is improved.
A first aspect of the present invention provides a portable electronic device comprising: the device comprises a processor, a detection circuit, a first power supply module and a second power supply module, wherein the detection circuit comprises: the circuit comprises a switch, a first voltage division circuit and a second voltage division circuit, wherein the impedance of the first voltage division circuit is greater than that of the second voltage division circuit;
A first end of the switch is used for being connected with an input device, a second end of the switch is respectively connected with a first end of the first voltage division circuit and the processor, a second end of the first voltage division circuit is connected with the first power module, a third end of the switch is respectively connected with a first end of the second voltage division circuit and the processor, and a second end of the second voltage division circuit is connected with the second power module;
the processor is used for detecting the voltage of the second end of the switch and determining whether the input equipment is connected to the first end of the switch according to the voltage of the second end of the switch; wherein, initially, a first end of the switch is connected with a second end of the switch;
And the processor is further configured to control the first end of the switch to be connected with the third end of the switch, detect a voltage at the third end of the switch, and determine the type of the input device according to the voltage at the third end of the switch when the interface of the input device is determined to be a three-stage interface.
with reference to the first aspect, in a first possible implementation manner of the first aspect, the processor is further configured to connect an interface of the input device with a corresponding interface on the processor according to the type of the input device.
With reference to the first aspect or the first possible implementation manner of the first aspect, in a second possible implementation manner of the first aspect, the determining a type of the input device according to a voltage at a third terminal of the switch includes:
if the voltage of the third end of the switch belongs to a first voltage range, the processor determines that the type of the input equipment is a three-section microphone;
If the voltage of the third end of the switch belongs to a second voltage range, the processor determines that the type of the input equipment is a three-section type earphone, and the voltage values in the first voltage range are all larger than the voltage values in the second voltage range.
With reference to the first aspect or the first possible implementation manner of the first aspect, in a third possible implementation manner of the first aspect, the determining a type of the input device according to a voltage at a third terminal of the switch includes:
if the voltage of the third end of the switch is larger than a preset voltage threshold, the processor determines that the type of the input equipment is a three-section microphone;
If the voltage of the third end of the switch is smaller than the voltage threshold, the processor determines that the type of the input equipment is a three-section type earphone.
With reference to the first possible implementation manner of the first aspect, in a fourth possible implementation manner of the first aspect, the connecting, according to the type of the input device, the interface of the input device with the corresponding interface on the processor includes:
If the type of the input equipment is a three-section microphone, the processor connects an interface of the input equipment with an interface of the three-section microphone on the processor;
If the type of the input equipment is a three-section type earphone, the processor connects the interface of the input equipment with the interface of the three-section type earphone on the processor.
with reference to the first aspect, in a fifth possible implementation manner of the first aspect, the portable electronic device further includes: and the first end of the analog-to-digital converter is respectively connected with the second end and the third end of the switch, the second end of the analog-to-digital converter is connected with the processor, and the analog-to-digital converter is used for detecting the voltage of the second end and the third end of the switch, converting the detected voltage into a digital signal and transmitting the digital signal to the processor.
with reference to the first aspect and any one of the first to fifth possible implementation manners of the first aspect, in a sixth possible implementation manner of the first aspect, the first voltage dividing circuit includes a first resistor, the second voltage dividing circuit includes a second resistor, and an impedance of the first resistor is greater than an impedance of the second resistor.
With reference to the first aspect and any one of the first to sixth possible implementation manners of the first aspect, in a seventh possible implementation manner of the first aspect, the processor is further configured to:
when the voltage of the third end of the switch is equal to the voltage of the second power supply module, the processor controls the first end of the switch to be connected with the second end of the switch.
With reference to the first aspect and any one of the first to seventh possible implementation manners of the first aspect, in an eighth possible implementation manner of the first aspect, the processor is further configured to:
And when the type of the input equipment is determined to be the three-section type microphone, starting the Bluetooth output equipment.
The second aspect of the present invention provides an audio connector identification method, which is applied to a portable electronic device, where the portable electronic device includes: the device comprises a processor, a detection circuit, a first power supply module and a second power supply module, wherein the detection circuit comprises: the circuit comprises a switch, a first voltage division circuit and a second voltage division circuit, wherein the impedance of the first voltage division circuit is greater than that of the second voltage division circuit; a first terminal of the switch is connected to an input device, second terminals of the switch are respectively connected to the first terminal of the first voltage-dividing circuit and the processor, a second terminal of the first voltage-dividing circuit is connected to the first power module, third terminals of the switch are respectively connected to the first terminal of the second voltage-dividing circuit and the processor, and a second terminal of the second voltage-dividing circuit is connected to the second power module, the method comprising:
The portable electronic device detects the voltage of the second end of the switch, and determines whether the input device is connected to the first end of the switch according to the voltage of the second end of the switch, wherein the first end of the switch is initially connected with the second end of the switch;
When the portable electronic equipment determines that the interface of the input equipment is a three-section interface, the portable electronic equipment controls the first end of the switch to be connected with the third end of the switch, and detects the voltage of the third end of the switch;
the portable electronic device determines the type of the input device according to the voltage of the third terminal of the switch.
with reference to the second aspect, in a first possible implementation manner of the second aspect, after the portable electronic device determines the type of the input device according to the voltage of the third terminal of the switch, the method further includes:
And the portable electronic equipment connects the interface of the input equipment with the corresponding interface on the processor according to the type of the input equipment.
With reference to the second aspect or the first possible implementation manner of the second aspect, in a second possible implementation manner of the second aspect, the determining, by the portable electronic device, the type of the input device according to the voltage of the third terminal of the switch includes:
if the interface voltage of the input equipment belongs to a first voltage range, the portable electronic equipment determines that the type of the input equipment is a three-section microphone;
If the interface voltage of the input device belongs to a second voltage range, the portable electronic device determines that the type of the input device is a three-section type earphone, and the voltage values in the first voltage range are all larger than the voltage values in the second voltage range.
With reference to the second aspect or the first possible implementation manner of the second aspect, in a third possible implementation manner of the second aspect, the determining, by the portable electronic device, the type of the input device according to the voltage of the third terminal of the switch includes:
If the voltage of the third end of the switch is greater than a preset voltage threshold, the portable electronic device determines that the type of the input device is a three-section microphone;
if the voltage of the third end of the switch is smaller than the voltage threshold, the portable electronic device determines that the type of the input device is a three-section type earphone.
With reference to the first possible implementation manner of the second aspect, in a third possible implementation manner of the second aspect, the connecting, by the portable electronic device, the interface of the input device with the corresponding interface on the processor according to the type of the input device includes:
If the type of the input equipment is a three-section microphone, the portable electronic equipment connects the input equipment with an interface of the three-section microphone on the processor;
and if the type of the input equipment is a three-section type earphone, the portable electronic equipment connects the input equipment with an interface of the three-section type earphone on the processor.
With reference to the second aspect and any one of the first to third possible implementation manners of the second aspect, in a fourth possible implementation manner of the second aspect, the method further includes:
when the voltage of the third end of the switch is equal to the voltage of the second power supply module, the portable electronic device controls the first end of the switch to be connected with the second end of the switch.
With reference to the second aspect and any one of the first to fourth possible implementation manners of the second aspect, in a fifth possible implementation manner of the second aspect, the method further includes:
When the type of the input device is a three-segment microphone, the method further comprises:
And when the type of the input equipment is a three-section microphone, the portable electronic equipment starts the Bluetooth output equipment.
according to the audio connector identification method and the portable electronic device provided by the embodiment of the invention, the portable electronic device detects the voltage of the second end of the switch, and determines whether the input device is connected to the first end of the switch or not according to the voltage of the second end of the switch; when the portable electronic device determines that the interface of the input device is a three-section interface, the portable electronic device controls the first end of the switch to be connected with the third end of the switch, detects the voltage of the third end of the switch, and determines the type of the input device according to the voltage of the third end of the switch. According to the method, the portable electronic equipment can identify the three-section microphone and the three-section earphone, so that a user can use the three-section microphone K song, and the user experience of the user using the portable electronic equipment K song can be improved.
drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings needed to be used in the description of the embodiments or the prior art will be briefly introduced below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to these drawings without creative efforts.
Fig. 1 is a schematic structural diagram of a portable electronic device according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of an interface structure of a three-section earphone and a three-section microphone;
FIG. 3 is a schematic diagram of an interface of the processor 11;
FIG. 4 is a flowchart of an audio connector identification method according to a second embodiment of the present invention;
Fig. 5 is a flowchart of an audio connector identification method according to a third embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all, embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Singing by a portable electronic device (such as a mobile phone and a tablet personal computer) is increasingly popularized in daily life as an entertainment mode, and in the prior art, a user cannot sing freely by singing by a microphone of the portable electronic device or a wired earphone with the microphone, so that the user experience is influenced. In addition, the microphone adopted by the existing K song input mode is an accessory at an amateur level, the input signal quality is poor, the singing voice quality is directly influenced, a good K song atmosphere cannot be created, the entertainment effect is influenced, and the user experience is reduced.
in the prior art, the interface of the wired earphone with the microphone is a four-segment interface, the wired earphone without the microphone is a three-segment interface, hereinafter, the wired earphone without the microphone is referred to as a four-segment wired earphone, the wired earphone with the microphone is referred to as a three-segment wired earphone, and the portable electronic device determines whether the input device is a four-segment earphone or a three-segment earphone by determining the type of the interface of the inserted input device. The interface of the three-section microphone is also a three-section interface, the structure of the three-section wired earphone is the same as that of the external interface of the three-section microphone, and after the interface type of the input device is identified to be the three-section interface in the prior art, the input device cannot be identified to be the three-section microphone or the three-section wired earphone.
In order to enable a portable electronic device to recognize a three-section microphone, a portable electronic device according to a first embodiment of the present invention is provided, and fig. 1 is a schematic structural diagram of the portable electronic device according to the first embodiment of the present invention, as shown in fig. 1, the portable electronic device according to the present embodiment includes: processor 11, detection circuit 12, first power module 13 and second power module 14.
Wherein, detection circuit 12 includes: switch 121, first voltage divider 122 and second voltage divider 133, the impedance of first voltage divider 122 is greater than the impedance of second voltage divider 123. A first terminal of the switch 121 is configured to be connected to an input device, a second terminal of the switch 121 is connected to the first terminal of the first voltage-dividing circuit 122 and the processor 11, respectively, a second terminal of the first voltage-dividing circuit 121 is connected to the first power module 13, a third terminal of the switch 121 is connected to the first terminal of the second voltage-dividing circuit 122 and the processor 11, respectively, and a second terminal of the second voltage-dividing circuit 123 is connected to the second power module 14.
in this embodiment, the switch 121 may be a single-pole double-throw switch, where the single-pole double-throw switch is composed of a moving end and a stationary end, the moving end is a first end of the switch 121, and the stationary end is a second end and a third end of the switch 121. The processor 11 may control the first terminal of the switch 121 to be connected to the second terminal and the third terminal of the switch 121, respectively. In this embodiment, the processor 11 may be an existing processor in the portable electronic device, and the processor may be composed of an Integrated Circuit (IC), for example, a single packaged IC, or a plurality of packaged ICs connected with the same function or different functions. For example, the processor 11 may include only a Central Processing Unit (CPU), or may be a combination of a GPU, a Digital Signal Processor (DSP), and a control chip in the communication Unit. Of course, in order to implement the method of this embodiment, a CPU or a DSP may be added to the portable electronic device, and the added CPU or DSP is the processor 11.
the first voltage dividing circuit 122 and the second voltage dividing circuit 123 are used to implement voltage division on the path, and the impedance of the first voltage dividing circuit 122 should be much larger than that of the second voltage dividing circuit 123, for example, the impedance of the first voltage dividing circuit is 100K ohms, and the impedance of the second voltage dividing circuit is 100 ohms. In a specific implementation, the first voltage dividing circuit 122 and the second voltage dividing circuit 123 may be circuits formed by one resistor, and of course, the first voltage dividing circuit 122 and the second voltage dividing circuit 123 may also be circuits formed by a plurality of electronic components. The first power module 13 and the second power module 14 are configured to provide a required voltage for the detection circuit 12, and the first power module 13 and the second power module 14 may be existing power modules in the portable electronic device or newly added power modules in the portable electronic device.
The first end of the switch 121 is connected to one end of an input device, which may be a three-section earphone, a three-section microphone, or a four-section earphone, and the other end of the input device is connected to the ground. In the prior art, the interface of the input device can be identified as a three-section interface or a four-section interface by the portable electronic device, but when the interface of the input device is the three-section interface, the portable electronic device cannot identify whether the input device is a three-section earphone or a three-section microphone. This is mainly because the external interface structure of the three-piece earphone is the same as that of the three-piece microphone. Fig. 2 is a schematic diagram of an interface structure of a three-section type earphone and a three-section type microphone, as shown in fig. 2, the three-section type earphone and the three-section type microphone are both three sections, signals of the three-section type earphone are defined as a left sound channel L, a right sound channel R and a ground terminal GND from left to right in sequence, and signals of the three-section type microphone are defined as a microphone anode (MIC +), a microphone cathode (MIC-) and a ground terminal from left to right in sequence.
It should be noted that although the external interface structures of the three-section type earphone and the three-section type microphone are the same, the signal definitions and the internal circuits of the devices of the three-section type earphone and the three-section type microphone are different, and the impedance difference between the three-section type earphone and the three-section type microphone to the ground is very large due to the different internal circuits of the three-section type earphone and the three-section type microphone, and table 1 is a comparison schematic diagram of the impedance (in ohm) parameters of the three-section type earphone and the three-section type microphone on the market at present.
TABLE 1
As can be seen from table 1, the impedance of the three-section microphone is much larger than that of the three-section earphone, and in this embodiment, the difference between the impedances of the three-section microphone and the three-section earphone is used to identify the type of the input device. When the input device is a three-segment earphone, the impedance of the three-segment earphone is relatively low, the current of the circuit is large, the voltage drop across the second voltage divider 123 is large, and the voltage V4 at the third terminal of the switch 121 is relatively low. When the input device is a three-segment microphone, since the impedance of the three-segment microphone is relatively large, the path current is small, the voltage drop across the second voltage divider 123 is small, and the voltage V4 at the third terminal of the switch 121 is large, the type of the input device can be determined by the voltage V4 at the third terminal of the switch 121.
initially, the first terminal of the switch 121 is connected to the second terminal of the switch 121, and the voltage V3 of the second terminal of the switch 121 is equal to the voltage V1 of the first power module 13. When an input device is connected, a path is formed from the ground terminal to the first power module 13, the voltage V3 at the second terminal of the switch 121 changes, since the impedance of the first voltage-dividing resistor 122 is large, the impedance of the input device is small relative to the first voltage-dividing resistor 122, most of the voltage is shared by the first voltage-dividing resistor 122, the voltage V3 at the second terminal of the switch 121 is close to 0, and the processor 11 is configured to detect the voltage at the second terminal of the switch 121 and determine that the input device is connected to the first terminal of the switch according to the voltage at the second terminal of the switch 121.
after determining that the input device is accessed, the processor 11 determines the interface type of the input device by detecting the structure of the interface of the input device, that is, determines whether the interface type of the input device is a three-segment interface or a four-segment interface. The processor 11 determines whether the interface type of the input device is a three-segment interface or a four-segment interface, which is not described herein in detail.
when the processor 11 is further configured to, when it is determined that the interface type of the input device is a three-stage interface, the processor 11 controls the first terminal of the switch 121 to be disconnected from the second terminal of the switch 121, and controls the first terminal of the switch 121 to be connected to the third terminal of the switch 121, at this time, a path is formed from the ground terminal to the second power module 14, and the processor 11 detects the voltage V4 at the third terminal of the switch 121, and determines the type of the input device according to the voltage at the third terminal of the switch 121. When the processor 11 determines that the interface type of the input device is a four-segment interface, the processor 11 does not perform any processing, and the first terminal of the switch 121 is still connected to the second terminal of the switch 121.
the processor 11 may specifically determine the type of input device in two ways:
First, if the voltage at the third terminal of the switch 121 belongs to the first voltage range, the processor 11 determines that the type of the input device is a three-segment microphone; if the voltage at the third terminal of the switch 121 belongs to a second voltage range, the processor 11 determines that the type of the input device is a three-segment type earphone, wherein the voltage values in the first voltage range are all larger than the voltage values in the second voltage range.
In a second implementation manner, if the voltage at the third terminal of the switch 121 is greater than the preset voltage threshold, the processor 11 determines that the type of the input device is a three-section microphone; if the voltage at the third terminal of the switch 121 is less than the voltage threshold, the processor 11 determines that the type of input device is a three-segment earphone. It should be noted that the voltage threshold is smaller than the minimum voltage value of the first voltage range, and the voltage threshold is larger than the maximum voltage value of the second voltage range.
In this embodiment, the voltage V4 at the third terminal of the switch 121 is R/(R + R2) U, where R is the impedance of the input device, R2 is the impedance of the second voltage divider, U is the voltage of the second power module 14, and R2 and U are known parameters. Because the impedances of the three-section microphone and the three-section earphone generated by different manufacturers are different, the voltage of the third end of the switch 121 changes when the three-section microphone and the three-section earphone with different impedances are inserted.
In this embodiment, the first voltage range is calculated according to different impedances of the conventional three-segment earphone, the minimum voltage value of the first voltage range is a voltage obtained when the impedance of the three-segment earphone takes the minimum value, the maximum voltage value of the first voltage range is a voltage obtained when the impedance of the three-segment earphone takes the maximum value, and when the first voltage range is specifically calculated, the maximum value and the minimum value of the impedance of the three-segment earphone are substituted into the formula: v4 ═ R/(R + R2) U yields the maximum voltage value and the minimum value of the first voltage range. Similarly, the second voltage range is calculated according to different impedances of the existing three-section microphone, the minimum voltage value of the second voltage range is obtained when the impedance of the three-section microphone takes the minimum value, the maximum voltage value of the second voltage range is obtained when the impedance of the three-section microphone takes the maximum value, and during specific calculation, the maximum value and the minimum value of the impedance of the three-section microphone are substituted into the formula: v4 ═ R/(R + R2) U gives the maximum voltage value and the minimum value of the second voltage range.
after determining the type of the input device, the processor 11 is further configured to connect the interface of the input device with the corresponding interface on the processor 11 according to the type of the input device. Specifically, if the type of the input device is a three-section microphone, the processor 11 connects an interface of the input device with an interface of the three-section microphone on the processor 11; if the type of the input device is a three-segment earphone, the processor 11 connects the interface of the input device with the interface of the three-segment earphone on the processor 11. Fig. 3 is a schematic interface diagram of the processor 11, and as shown in fig. 3, the processor 11 includes the following five interfaces: MIC +, MIC-, ground, left channel, right channel. If the processor detects that the input device type is a three-segment microphone, the MIC +, MIC-, and the ground terminal of the three-segment microphone are respectively connected with the MIC +, MIC-, and the ground terminal of the processor 11 by the processor 11, and if the processor 11 detects that the input device type is a three-segment earphone, the ground terminal, the left channel, and the right channel of the three-segment earphone are respectively connected with the ground terminal, the left channel, and the right channel of the processor 11 by the processor 11, thereby completing the signal connection of the input device to the processor 11.
optionally, the processor 11 is further configured to: and when the type of the input device is determined to be the three-section type microphone, starting the Bluetooth output device, wherein the Bluetooth output device can be a Bluetooth earphone or a Bluetooth sound box. Specifically, the processor 11 may send a start instruction to the bluetooth output device, where the start instruction instructs the user to start the bluetooth output device.
The processor 11 is further configured to: when the voltage V4 at the third terminal of the switch 121 is equal to the voltage V2 of the second power module 14, the processor 11 controls the first terminal of the switch 121 to be disconnected from the third terminal of the switch 121, and controls the first terminal of the switch 121 to be connected to the second terminal of the switch 121. The voltage V4 at the third terminal of the switch 121 is equal to the voltage V2 of the second power module 14, which indicates that the input device is unplugged, and the processor 11 controls the first terminal of the switch 121 to be connected to the second terminal of the switch 121.
optionally, the portable electronic device of this embodiment may further include: an Analog-to-Digital Converter (ADC) having a first end connected to the second end and the third end of the switch 121, a second end connected to the processor 11, and an ADC 11 configured to detect voltages of the second end and the third end of the switch 121, convert the detected voltages into Digital signals, and transmit the Digital signals to the processor 11.
The portable electronic equipment of this embodiment can discern the syllogic microphone branch for the user can use external syllogic microphone K song, can push-and-pull the distance of microphone from the mouth limit, gets rid of plosive, breath, K song high pitch and slowly falls. Support in the aspect of the output when singing with syllogic microphone K, bluetooth output device simultaneous working promotes volume and tone quality, builds good K and sings the atmosphere.
An embodiment of the present invention provides an audio connector identification method, where the method of this embodiment can be applied to a portable electronic device provided in the embodiment of the first embodiment, fig. 4 is a flowchart of the audio connector identification method provided in the embodiment of the second embodiment, and referring to fig. 1 and fig. 4, the method provided in this embodiment may include the following steps:
Step 101, the portable electronic device detects a voltage of the second terminal of the switch, and determines whether the input device is connected to the first terminal of the switch according to the voltage of the second terminal of the switch, wherein, initially, the first terminal of the switch is connected to the second terminal of the switch.
and 102, when the portable electronic equipment determines that the interface of the input equipment is a three-section interface, the portable electronic equipment controls the first end of the switch to be connected with the third end of the switch, and detects the voltage of the third end of the switch.
step 103, the portable electronic device determines the type of the input device according to the voltage of the third terminal of the switch.
In one implementation, if the interface voltage of the input device belongs to a first voltage range, the portable electronic device determines that the type of the input device is a three-section microphone; if the interface voltage of the input device belongs to the second voltage range, the portable electronic device determines that the type of the input device is a three-section type earphone, and the voltage values in the first voltage range are all larger than the voltage values in the second voltage range.
in another implementation manner, if the voltage of the third terminal of the switch is greater than a preset voltage threshold, the portable electronic device determines that the type of the input device is a three-section microphone; if the voltage of the third end of the switch is less than the voltage threshold, the portable electronic device determines that the type of the input device is a three-section type earphone. It should be noted that the voltage threshold is smaller than the minimum voltage value of the first voltage range, and the voltage threshold is larger than the maximum voltage value of the second voltage range.
Optionally, after the portable electronic device determines the type of the input device according to the voltage at the third terminal of the switch, the portable electronic device further connects the interface of the input device with the corresponding interface on the processor according to the type of the input device. Specifically, if the type of the input device is a three-section microphone, the portable electronic device connects the input device with an interface of the three-section microphone on the processor; if the type of the input device is a three-section type earphone, the portable electronic device connects the input device with an interface of the three-section type earphone on the processor.
optionally, when the voltage of the third terminal of the switch is equal to the voltage of the second power module, the portable electronic device controls the first terminal of the switch to be connected with the second terminal of the switch.
optionally, when the type of the input device is a three-section microphone, if the portable electronic device has a bluetooth output device, the portable electronic device turns on the bluetooth output device.
The specific implementation manner of this embodiment may refer to the description related to the first embodiment, and is not described herein again.
Through the method of the embodiment, the portable electronic equipment can identify the three-section earphone and the three-section microphone, so that the method for the user to use the K song of the portable electronic equipment is enriched, and the user can use the K song of the portable electronic equipment in several ways to improve the user experience of the user in using the K song of the portable electronic equipment: (1) when the Bluetooth earphone karaoke is used, the Bluetooth output equipment and the portable electronic equipment are simultaneously output through the own loudspeaker; (2) when the four-section type earphone sings K, the four-section type earphone and the Bluetooth output equipment output simultaneously; (3) when syllogic microphone K sings, support bluetooth output device output.
In the method of this embodiment, the portable electronic device detects the voltage of the second terminal of the switch, and determines whether the input device is connected to the first terminal of the switch according to the voltage of the second terminal of the switch; when the portable electronic device determines that the interface of the input device is a three-section interface, the portable electronic device controls the first end of the switch to be connected with the third end of the switch, detects the voltage of the third end of the switch, and determines the type of the input device according to the voltage of the third end of the switch. According to the method, the portable electronic equipment can identify the three-section microphone and the three-section earphone, so that a user can use the three-section microphone K song, and the user experience of the user using the portable electronic equipment K song can be improved.
Fig. 5 is a flowchart of an audio connector identification method according to a third embodiment of the present invention, and as shown in fig. 5, the method according to this embodiment may include the following steps:
step 201, the portable electronic device detects whether an input device is inserted into the audio interface.
if yes, the step 202 is executed, that is, an input device is inserted into the audio interface, otherwise, the step 201 is executed again, and the detection is continued.
Step 202, the portable electronic device determines whether the interface of the input device is a three-segment interface or a four-segment interface.
if the interface of the input device is a three-segment interface, step 203 is executed, and if the interface of the input device is a four-segment interface, step 204 is executed.
Step 203, the portable electronic device determines whether the input device is a three-section earphone or a three-section microphone.
if the input device is a three-segment microphone, step 205 is executed, and if the input device is a three-segment earphone, step 206 is executed.
and step 204, the portable electronic device connects the interface of the input device with the interface of the four-section earphone on the processor.
and step 205, the portable electronic device connects the interface of the input device with the interface of the three-section earphone on the processor, and simultaneously starts the bluetooth output device.
Step 206, the portable electronic device connects the interface of the input device with the interface of the three-segment earphone on the processor.
step 207, the portable electronic device determines whether the audio interface is unplugged from the input device.
This step is performed after any of steps 204-206 have been performed. If the input device is pulled out, the current identification process is ended, and if the electronic device is not pulled out, the execution returns to 201.
The specific implementation manner of this embodiment may refer to the description related to the first embodiment and the second embodiment, and is not described herein again.
those of ordinary skill in the art will understand that: all or a portion of the steps of implementing the above-described method embodiments may be performed by hardware associated with program instructions. The program may be stored in a computer-readable storage medium. When executed, the program performs steps comprising the method embodiments described above; and the aforementioned storage medium includes: various media that can store program codes, such as ROM, RAM, magnetic or optical disks.
Finally, it should be noted that: the above embodiments are only used to illustrate the technical solution of the present invention, and not to limit the same; while the invention has been described in detail and with reference to the foregoing embodiments, it will be understood by those skilled in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some or all of the technical features may be equivalently replaced; and the modifications or the substitutions do not make the essence of the corresponding technical solutions depart from the scope of the technical solutions of the embodiments of the present invention.

Claims (16)

1. a portable electronic device, comprising: the device comprises a processor, a detection circuit, a first power supply module and a second power supply module, wherein the detection circuit comprises: the circuit comprises a switch, a first voltage division circuit and a second voltage division circuit, wherein the impedance of the first voltage division circuit is greater than that of the second voltage division circuit;
A first end of the switch is used for being connected with an input device, a second end of the switch is respectively connected with a first end of the first voltage division circuit and the processor, a second end of the first voltage division circuit is connected with the first power module, a third end of the switch is respectively connected with a first end of the second voltage division circuit and the processor, and a second end of the second voltage division circuit is connected with the second power module;
the processor is configured to detect a voltage of the second terminal of the switch, and determine whether the input device is connected to the first terminal of the switch according to the voltage of the second terminal of the switch, where initially, the first terminal of the switch is connected to the second terminal of the switch;
And the processor is further configured to control the first end of the switch to be connected with the third end of the switch, detect a voltage at the third end of the switch, and determine the type of the input device according to the voltage at the third end of the switch when the interface of the input device is determined to be a three-stage interface.
2. The device of claim 1, wherein the processor is further configured to connect an interface of the input device with a corresponding interface on the processor according to the type of the input device.
3. The device of claim 1 or 2, wherein the determining the type of the input device according to the voltage at the third terminal of the switch comprises:
If the voltage of the third end of the switch belongs to a first voltage range, the processor determines that the type of the input equipment is a three-section microphone;
if the voltage of the third end of the switch belongs to a second voltage range, the processor determines that the type of the input equipment is a three-section type earphone, and the voltage values in the first voltage range are all larger than the voltage values in the second voltage range.
4. the device of claim 1 or 2, wherein the determining the type of the input device according to the voltage at the third terminal of the switch comprises:
If the voltage of the third end of the switch is larger than a preset voltage threshold, the processor determines that the type of the input equipment is a three-section microphone;
If the voltage of the third end of the switch is smaller than the voltage threshold, the processor determines that the type of the input equipment is a three-section type earphone.
5. the device of claim 2, wherein the connecting the interface of the input device with the corresponding interface on the processor according to the type of the input device comprises:
If the type of the input equipment is a three-section microphone, the processor connects an interface of the input equipment with an interface of the three-section microphone on the processor;
if the type of the input equipment is a three-section type earphone, the processor connects the interface of the input equipment with the interface of the three-section type earphone on the processor.
6. The device of claim 1, wherein the portable electronic device further comprises: and the first end of the analog-to-digital converter is respectively connected with the second end and the third end of the switch, the second end of the analog-to-digital converter is connected with the processor, and the analog-to-digital converter is used for detecting the voltage of the second end and the third end of the switch, converting the detected voltage into a digital signal and transmitting the digital signal to the processor.
7. the apparatus of any of claims 1-2 or 5-6, wherein the first voltage divider circuit comprises a first resistor and the second voltage divider circuit comprises a second resistor, the impedance of the first resistor being greater than the impedance of the second resistor.
8. The apparatus of any of claims 1-2 or 5-6, wherein the processor is further configured to:
When the voltage of the third end of the switch is equal to the voltage of the second power supply module, the processor controls the first end of the switch to be connected with the second end of the switch.
9. The apparatus of any of claims 1-2 or 5-6, wherein the processor is further configured to:
And when the type of the input equipment is determined to be the three-section type microphone, starting the Bluetooth output equipment.
10. an audio connector identification method is applied to a portable electronic device, and the portable electronic device comprises the following steps: the device comprises a processor, a detection circuit, a first power supply module and a second power supply module, wherein the detection circuit comprises: the circuit comprises a switch, a first voltage division circuit and a second voltage division circuit, wherein the impedance of the first voltage division circuit is greater than that of the second voltage division circuit; a first terminal of the switch is connected to an input device, second terminals of the switch are respectively connected to the first terminal of the first voltage-dividing circuit and the processor, a second terminal of the first voltage-dividing circuit is connected to the first power module, third terminals of the switch are respectively connected to the first terminal of the second voltage-dividing circuit and the processor, and a second terminal of the second voltage-dividing circuit is connected to the second power module, the method comprising:
The portable electronic device detects the voltage of the second end of the switch, and determines whether the input device is connected to the first end of the switch according to the voltage of the second end of the switch, wherein the first end of the switch is initially connected with the second end of the switch;
When the portable electronic equipment determines that the interface of the input equipment is a three-section interface, the portable electronic equipment controls the first end of the switch to be connected with the third end of the switch, and detects the voltage of the third end of the switch;
The portable electronic device determines the type of the input device according to the voltage of the third terminal of the switch.
11. The method of claim 10, wherein after the portable electronic device determines the type of the input device based on the voltage at the third terminal of the switch, the method further comprises:
and the portable electronic equipment connects the interface of the input equipment with the corresponding interface on the processor according to the type of the input equipment.
12. the method of claim 10 or 11, wherein the determining, by the portable electronic device, the type of the input device based on the voltage at the third terminal of the switch comprises:
If the interface voltage of the input equipment belongs to a first voltage range, the portable electronic equipment determines that the type of the input equipment is a three-section microphone;
If the interface voltage of the input device belongs to a second voltage range, the portable electronic device determines that the type of the input device is a three-section type earphone, and the voltage values in the first voltage range are all larger than the voltage values in the second voltage range.
13. The method of claim 10 or 11, wherein the determining, by the portable electronic device, the type of the input device based on the voltage at the third terminal of the switch comprises:
If the voltage of the third end of the switch is greater than a preset voltage threshold, the portable electronic device determines that the type of the input device is a three-section microphone;
if the voltage of the third end of the switch is smaller than the voltage threshold, the portable electronic device determines that the type of the input device is a three-section type earphone.
14. The method of claim 11, wherein connecting the interface of the input device with the corresponding interface on the processor by the portable electronic device according to the type of the input device comprises:
If the type of the input equipment is a three-section microphone, the portable electronic equipment connects the input equipment with an interface of the three-section microphone on the processor;
And if the type of the input equipment is a three-section type earphone, the portable electronic equipment connects the input equipment with an interface of the three-section type earphone on the processor.
15. The method according to any one of claims 10-11 or 14, further comprising:
When the voltage of the third end of the switch is equal to the voltage of the second power supply module, the portable electronic device controls the first end of the switch to be connected with the second end of the switch.
16. The method according to any one of claims 10-11 or 14, further comprising:
And when the type of the input equipment is a three-section microphone, the portable electronic equipment starts the Bluetooth output equipment.
CN201580064063.6A 2015-04-09 2015-04-09 Audio connector identification method and portable electronic equipment Active CN107005762B (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2015/076159 WO2016161596A1 (en) 2015-04-09 2015-04-09 Audio connector recognition method and portable electronic device

Publications (2)

Publication Number Publication Date
CN107005762A CN107005762A (en) 2017-08-01
CN107005762B true CN107005762B (en) 2019-12-13

Family

ID=57072966

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201580064063.6A Active CN107005762B (en) 2015-04-09 2015-04-09 Audio connector identification method and portable electronic equipment

Country Status (2)

Country Link
CN (1) CN107005762B (en)
WO (1) WO2016161596A1 (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112327211B (en) * 2020-09-29 2023-07-21 惠州市德赛西威汽车电子股份有限公司 Vehicle-mounted microphone power supply connection state monitoring circuit and method
CN112924499A (en) * 2021-01-27 2021-06-08 三诺生物传感股份有限公司 Test strip inserting strip identification device, test strip sample suction judgment device and test strip sample suction judgment method
CN113316064B (en) * 2021-04-28 2023-01-24 杭州小派智能科技有限公司 Method, system, head-mounted display device and storage medium for earphone and loudspeaker recognition
CN114710583A (en) * 2022-04-08 2022-07-05 维沃移动通信有限公司 Microphone calling method and device, electronic equipment and readable storage medium

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101783986A (en) * 2010-03-17 2010-07-21 青岛海信移动通信技术股份有限公司 Earphone interface circuit and electronic equipment
CN102739183A (en) * 2012-06-13 2012-10-17 天地融科技股份有限公司 Audio interface matching identification method and device for mobile terminal, and electronic signature tool
CN102761804A (en) * 2012-06-14 2012-10-31 天地融科技股份有限公司 Self-adaptive method and self-adaptive device of voice frequency interface, and electronic signature tool
CN103219988A (en) * 2013-03-19 2013-07-24 福建联迪商用设备有限公司 Method for automatically identifying pluggable audio devices and terminal
CN103414981A (en) * 2013-07-17 2013-11-27 天地融科技股份有限公司 Device, method and terminal for recognizing audio interface pins
CN103702055A (en) * 2013-12-13 2014-04-02 乐视致新电子科技(天津)有限公司 Audio and video signal joint self-identifying system and method

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP3664479B2 (en) * 2001-10-18 2005-06-29 インターナショナル・ビジネス・マシーンズ・コーポレーション Notebook PC with microphone and line plug detection circuit, jack shared circuit, adapter for sharing jack, and shared jack
US6856046B1 (en) * 2002-03-08 2005-02-15 Analog Devices, Inc. Plug-in device discrimination circuit and method
KR20040090577A (en) * 2003-04-17 2004-10-26 주식회사 팬택앤큐리텔 The Apparatus and Method to Sensing Strobo of Wireless Communication Terminal Automatically
CN2819226Y (en) * 2005-07-22 2006-09-20 华为技术有限公司 Earphone inserted tester
CN103686535B (en) * 2013-12-02 2017-11-10 Tcl集团股份有限公司 The terminal and recognition methods of automatic identification ear microphone and karaoke equipment
CN203734827U (en) * 2014-03-14 2014-07-23 宁波萨瑞通讯有限公司 Microphone detection circuit and mobile terminal device thereof
CN104093114B (en) * 2014-07-22 2018-03-16 Tcl通讯(宁波)有限公司 A kind of detection means of earphone keystroke, detecting system and detection method

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101783986A (en) * 2010-03-17 2010-07-21 青岛海信移动通信技术股份有限公司 Earphone interface circuit and electronic equipment
CN102739183A (en) * 2012-06-13 2012-10-17 天地融科技股份有限公司 Audio interface matching identification method and device for mobile terminal, and electronic signature tool
CN102761804A (en) * 2012-06-14 2012-10-31 天地融科技股份有限公司 Self-adaptive method and self-adaptive device of voice frequency interface, and electronic signature tool
CN103219988A (en) * 2013-03-19 2013-07-24 福建联迪商用设备有限公司 Method for automatically identifying pluggable audio devices and terminal
CN103414981A (en) * 2013-07-17 2013-11-27 天地融科技股份有限公司 Device, method and terminal for recognizing audio interface pins
CN103702055A (en) * 2013-12-13 2014-04-02 乐视致新电子科技(天津)有限公司 Audio and video signal joint self-identifying system and method

Also Published As

Publication number Publication date
CN107005762A (en) 2017-08-01
WO2016161596A1 (en) 2016-10-13

Similar Documents

Publication Publication Date Title
KR102105315B1 (en) Detection circuit
US20100104119A1 (en) Audio output device
US20180220230A1 (en) Audio i o headset plug and plug detection circuitry
US7623667B2 (en) Electronic device accessory with ultrasonic tone generator
KR101646964B1 (en) Circuit apparatus and method for recognition earphone in electronic device
CN107005762B (en) Audio connector identification method and portable electronic equipment
EP2632177B1 (en) Electronic device, accessory, and method for detecting an accessory
US8787589B2 (en) Electronic device and system and method thereof for identifying electronic accessory and controlling electronic device
US10136209B2 (en) Method, apparatus, and system for supplying power to active noise reduction headset
CN203909716U (en) Novel mind headset
WO2018076628A1 (en) Usb interface circuit, terminal, headset circuit and headset, and storage medium
US20150110331A1 (en) Earjack and electronic device including the same
US9414176B2 (en) Accessory plug detection
JP2013251728A (en) Connector device and electronic device
CN107800853B (en) Memory, mobile phone, audio circuit thereof and method for externally playing audio file
US9247336B2 (en) Apparatus and method for confirming control information of earphone in portable terminal
CN116546410A (en) Access detection method of electronic equipment interface, electronic equipment and storage medium
CN109218914B (en) Audio playing device and audio transmission circuit
JP5211099B2 (en) Conversion adapter and electronic device
CN105848033A (en) Earphone in music listening state capable of communicating with people
KR101721524B1 (en) Portable Sound Device including Common Earphone Connector for Connecting Charger Plug and Earphone Plug
CN115190396A (en) TWS earphone and TWS earphone system
JP5857984B2 (en) Sound data processing device
TW201019742A (en) Audio output device
WO2015176755A1 (en) Audio device with cable socket

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant