CN105807911A - Automatic earphone recognition device and method - Google Patents
Automatic earphone recognition device and method Download PDFInfo
- Publication number
- CN105807911A CN105807911A CN201410857318.1A CN201410857318A CN105807911A CN 105807911 A CN105807911 A CN 105807911A CN 201410857318 A CN201410857318 A CN 201410857318A CN 105807911 A CN105807911 A CN 105807911A
- Authority
- CN
- China
- Prior art keywords
- earphone
- driver module
- audio driver
- cpu
- automatic identification
- 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.)
- Pending
Links
Landscapes
- Headphones And Earphones (AREA)
- Circuit For Audible Band Transducer (AREA)
Abstract
The invention discloses an automatic earphone recognition device. The automatic earphone recognition device comprises an audio driving module, wherein the audio driving module is electrically connected with an earphone jack and a CPU; an apparatus is inserted into the earphone jack; the CPU is used for judging the type of the apparatus through the audio driving module; the audio driving module is used for writing in a corresponding set value according to the type of the apparatus; the apparatus works normally. According to the automatic earphone recognition device, the audio driving module is arranged to receive an output signal of the apparatus, and the CPU can directly read the output signal of the apparatus from the audio driving module through an I2C protocol and then judge the type of the apparatus; moreover, a control module is used for automatically switching accesses respectively corresponding to apparatuses of different types, so as to ensure the normal use of the apparatuses; the automatic earphone recognition device is not only capable of decreasing the misjudgement rate of the CPU, but also capable of saving the hardware resources of the CPU.
Description
[skill field]
The present invention relates to a kind of earphone automatic identification equipment and recognition methods, particularly relate to a kind of earphone automatic identification equipment being applied in computer and recognition methods.
[background skill]
nullEarphone has become as portable digital product,The standard configuration adnexa of mobile communication equipment end product,Mobile communication equipment standard configuration earphone is generally the four-section type headset with MIC input,And Portable digital product standard configuration earphone is generally three-section earphone,Also band sound-recording function digital product is had to use four-section type headset,The type of current four-section type headset is mainly: the earphone of L channel/R channel/MIC/ ground and L channel/R channel/ground/MIC two kinds unlike signal order definition,And the headset type arranged in computer is the one in three types,When another kind inserts,Need to access with a patchcord just can normally use,It is all determine whether that equipment inserts by one interrupt signal of transmission to CPU at present in the design of earphone jack,After CPU receives interrupt signal,Judge that whether insertion equipment is with microphone function again through one second Interface status,But,Maneuver can be inserted because of equipment after CPU receives interrupt signal,Such as: the reason such as handshaking will cause the second interface to produce dither signal to cause CPU to judge by accident,Cause that equipment cannot normally use,Therefore because cannot automatically identify different types of earphone,Terminal user will be caused very big puzzlement,Affect the experience of user.
In view of this, being necessary in fact to provide a kind of earphone automatic identification equipment and recognition methods, this earphone automatic identification equipment and recognition methods can solve the problem that cannot automatically identify dissimilar earphone existed in above-mentioned technology.
[summary of the invention]
Therefore, it is an object of the invention to provide a kind of earphone automatic identification equipment and recognition methods, this earphone automatic identification equipment and recognition methods can solve the above-mentioned problem that cannot automatically identify different types of earphone.
To achieve the above object, the earphone automatic identification equipment of the present invention, it is applied in computer, is provided with a CPU in this computer, and this computer is provided with an earphone jack, and this earphone automatic identification equipment includes:
Audio driver module, this audio driver module is electrically connected with described earphone jack, and this audio driver module is electrically connected with described CPU, one equipment inserts in described earphone jack, described CPU passes through this audio driver module judgment device type, described audio driver module is by the setting value corresponding according to device type write, described equipment normal operation.
It is also preferred that the left described audio driver module includes an audio coder.
It is also preferred that the left described audio coder is an IC chip.
It is also preferred that the left described earphone automatic identification equipment also includes a control module, this control module one end is electrically connected with described earphone jack, and the other end is electrically connected with described audio driver module, and this control module is for controlling the signal switching in described earphone jack.
It is also preferred that the left described control module includes an analog switch, this analog switch is for controlling the signalling channel switching in described earphone jack.
It is also preferred that the left by the transmission of I2C protocol realization data between described audio driver module and described CPU.
A kind of method of automatic identification earphone, this identifies that the method for earphone includes step automatically:
100: be loaded into an audio driver module in a computer, an equipment correspondence is inserted in an earphone jack, and this earphone jack will send an interrupt signal;
200: one CPU receive described interrupt signal, and then this CPU reads the device type signal in earphone jack by described audio driver module;
300: described CPU judges the type of described equipment according to the device type signal read, and to described audio driver module transmission device types;
400: described audio driver module arranges corresponding setting value, described equipment normal operation according to the type of input equipment.
It is also preferred that the left include step before described step 100:
1001: described audio driver module is connected with described CPU, and described audio driver module is connected with described earphone jack;
1002;Described booting computer.
It is also preferred that the left by the transmission of I2C protocol realization signal between described audio driver module and described CPU.
It is also preferred that the left described step 200 specifically includes step:
2001: described CPU receives interrupt signal;
2002: described earphone jack transmits data signal to above-mentioned audio driver module;
2003: described CPU reads the data signal in described earphone jack by above-mentioned audio driver module.
Compared to prior art, the earphone automatic identification equipment of the present invention, by arranging an audio driver module, this audio driver module is electrically connected with CPU, and this audio driver module and an earphone jack are electrically connected, this audio driver module can receive the output signal of equipment, and CPU can pass through I2C agreement and directly read output signal the judgment device type of equipment from described audio driver module, in addition, control module by one can automatically switch each self-corresponding path of dissimilar equipment, so that equipment normally uses, this earphone automatic identification equipment not only reduces the False Rate of CPU, and save the hardware resource of CPU.
[accompanying drawing explanation]
Fig. 1 illustrates the structural representation of earphone automatic identification equipment of the present invention.
Fig. 2 illustrates the present invention and automatically identifies the schematic flow sheet of earphone method.[detailed description of the invention]
Referring to Fig. 1 and Fig. 2, respectively the structural representation of earphone automatic identification equipment of the present invention and the present invention identify the schematic flow sheet of earphone method automatically for they.
The earphone automatic identification equipment of the present invention, it is applied in computer, in the present embodiment, please participate in Fig. 1, is provided with a CPU1 in this computer, and this computer is provided with an earphone jack 2, and this earphone automatic identification equipment includes:
Audio driver module 3, this audio driver module 3 is electrically connected with described earphone jack 2, and this audio driver module 3 is electrically connected with described CPU1, one equipment 4 inserts in described earphone jack 2, described CPU1 passes through this audio driver module 3 judgment device 4 type, described audio driver module 3 is by the setting value corresponding according to the write of equipment 4 type, described equipment 4 normal operation, in the present embodiment, this audio driver module 3 includes an audio coder 30, and this audio coder 30 is an IC chip, the model of this IC chip is ALC5625.
In the present embodiment, described earphone automatic identification equipment also includes a control module 5, this control module 5 one end and described earphone jack 2 are electrically connected, the other end and described audio driver module 3 are electrically connected, this control module 5 is for controlling the signal switching in described earphone jack 2, and this control module 5 includes an analog switch 50.
In the present embodiment, by the transmission of I2C protocol realization data between described audio driver module 3 and described CPU1.
A kind of method of automatic identification earphone, in the present embodiment, refers to Fig. 2, and this identifies that the method for earphone includes step automatically:
100: be loaded into an audio driver module 3 in a computer, an equipment 4 is corresponding to be inserted in an earphone jack 2, and this earphone jack 2 will send an interrupt signal;
200: one CPU1 receive described interrupt signal, and then this CPU1 reads equipment 4 type signal in earphone jack 2 by described audio driver module 3;
300: described CPU1 judges the type of described equipment 4 according to equipment 4 type signal read, and sends the signal of equipment 4 type to described audio driver module 3;
400: described audio driver module 3 arranges corresponding setting value, described equipment 4 normal operation according to the type of input equipment 4.
In the present embodiment, before described step 100, include step:
1001: described audio driver module 3 is connected with described CPU1, and described audio driver module 3 is connected with described earphone jack 2;
1002;Described booting computer.
In the present embodiment, described step 200 specifically includes step:
2001: described CPU1 receives interrupt signal;
2002: described earphone jack 2 transmits data signal to above-mentioned audio driver module 3;
2003: described CPU1 reads the data signal in described earphone jack 2 by above-mentioned audio driver module 3.
nullIn the present embodiment,By booting computer,Then audio driver module 3 it is loaded into,Open microphone modes,Equipment 4 is corresponding to be inserted in earphone jack 2,This earphone jack 2 sends interrupt signal,CPU1 receives this interrupt signal,Described equipment 4 is connected with audio driver module 3 by earphone jack 2,This audio driver module 3 receives equipment 4 and exports signal,CPU1 exports signal by I2C agreement reading equipment 4 from audio driver module 3,Type then according to the signal judgment device 4 read,When the signal received is left channel signals、Right-channel signals and earth signal,It it is then three-section earphone,If the signal received is left channel signals、Right-channel signals、MIC signal and earth signal,It is then Section of three MIC earphone,If the signal received is left channel signals、Right-channel signals、Earth signal and MIC signal,It is then Section of four MIC earphone,Equipment 4 type is sent to audio driver module 3 by CPU1,This audio driver module 3 writes corresponding setting value in a register according to equipment 4 type,Equipment 4 can normally use,When being again coupled to the second equipment,If the second device type is different from a front type,Control module 5 is then used to switch corresponding path.
Compared to prior art, the earphone automatic identification equipment of the present invention, by arranging audio driver module 3, this audio driver module 3 can receive the output signal of equipment 4, and CPU1 can pass through I2C agreement and directly read output signal judgment device 4 type of equipment 4 from described audio driver module 3, in addition, control module 5 by one can automatically switch each self-corresponding path of dissimilar equipment 4, so that equipment 4 normally uses, this earphone automatic identification equipment not only reduces the False Rate of CPU1, and saves the hardware resource of CPU1.
Claims (10)
1. an earphone automatic identification equipment, it is applied in computer, is provided with a CPU in this computer, and this computer is provided with an earphone jack, it is characterised in that this earphone automatic identification equipment includes:
Audio driver module, this audio driver module is electrically connected with described earphone jack, and this audio driver module is electrically connected with described CPU, one equipment inserts in described earphone jack, described CPU passes through this audio driver module judgment device type, described audio driver module is by the setting value corresponding according to device type write, described equipment normal operation.
2. earphone automatic identification equipment according to claim 1, it is characterised in that described audio driver module includes an audio coder.
3. earphone automatic identification equipment according to claim 2, it is characterised in that described audio coder is an IC chip.
4. earphone automatic identification equipment according to claim 1, it is characterized in that, described earphone automatic identification equipment also includes a control module, this control module one end is electrically connected with described earphone jack, the other end is electrically connected with described audio driver module, and this control module is for controlling the signalling channel switching in described earphone jack.
5. earphone automatic identification equipment according to claim 4, it is characterised in that described control module includes an analog switch, this analog switch is for controlling the signal switching in described earphone jack.
6. earphone automatic identification equipment according to claim 1, it is characterised in that by the transmission of I2C protocol realization data between described audio driver module and described CPU.
7. the method for an automatic identification earphone, it is characterised in that this identifies that the method for earphone includes step automatically:
100: be loaded into an audio driver module in a computer, an equipment correspondence is inserted in an earphone jack, and this earphone jack will send an interrupt signal;
200: one CPU receive described interrupt signal, and then this CPU reads the device type signal in earphone jack by described audio driver module;
300: described CPU judges the type of described equipment according to the device type signal read, and to described audio driver module transmission device types;
400: described audio driver module arranges corresponding setting value, described equipment normal operation according to the type of input equipment.
8. the method for automatic identification earphone according to claim 7, it is characterised in that include step before described step 100:
1001: described audio driver module is connected with described CPU, and described audio driver module is connected with described earphone jack;
1002;Described booting computer.
9. the method for automatic identification earphone according to claim 7, it is characterised in that by the transmission of I2C protocol realization signal between described audio driver module and described CPU.
10. the method for automatic identification earphone according to claim 7, it is characterised in that described step 200 specifically includes step:
2001: described CPU receives interrupt signal;
2002: described earphone jack transmits data signal to above-mentioned audio driver module;
2003: described CPU reads the data signal in described earphone jack by above-mentioned audio driver module.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410857318.1A CN105807911A (en) | 2014-12-30 | 2014-12-30 | Automatic earphone recognition device and method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201410857318.1A CN105807911A (en) | 2014-12-30 | 2014-12-30 | Automatic earphone recognition device and method |
Publications (1)
Publication Number | Publication Date |
---|---|
CN105807911A true CN105807911A (en) | 2016-07-27 |
Family
ID=56465445
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201410857318.1A Pending CN105807911A (en) | 2014-12-30 | 2014-12-30 | Automatic earphone recognition device and method |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN105807911A (en) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106899908A (en) * | 2017-02-27 | 2017-06-27 | 努比亚技术有限公司 | Earphone, apparatus for processing audio, method and system |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN202425016U (en) * | 2012-01-11 | 2012-09-05 | 广东欧珀移动通信有限公司 | Circuit for identifying earphone type intelligently |
CN103929696A (en) * | 2014-03-17 | 2014-07-16 | 联想(北京)有限公司 | Earphone detection processing method, device and mobile terminal |
CN103945317A (en) * | 2014-04-25 | 2014-07-23 | 矽力杰半导体技术(杭州)有限公司 | Detection method and circuit for detecting type of earphone connector |
CN104105046A (en) * | 2013-04-09 | 2014-10-15 | 宏碁股份有限公司 | Detection circuit |
-
2014
- 2014-12-30 CN CN201410857318.1A patent/CN105807911A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN202425016U (en) * | 2012-01-11 | 2012-09-05 | 广东欧珀移动通信有限公司 | Circuit for identifying earphone type intelligently |
CN104105046A (en) * | 2013-04-09 | 2014-10-15 | 宏碁股份有限公司 | Detection circuit |
CN103929696A (en) * | 2014-03-17 | 2014-07-16 | 联想(北京)有限公司 | Earphone detection processing method, device and mobile terminal |
CN103945317A (en) * | 2014-04-25 | 2014-07-23 | 矽力杰半导体技术(杭州)有限公司 | Detection method and circuit for detecting type of earphone connector |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN106899908A (en) * | 2017-02-27 | 2017-06-27 | 努比亚技术有限公司 | Earphone, apparatus for processing audio, method and system |
CN106899908B (en) * | 2017-02-27 | 2019-06-25 | 努比亚技术有限公司 | Apparatus for processing audio, method and system |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
EP2597844A1 (en) | Method and device for sharing micro-usb interface between earphone and usb | |
US11178707B2 (en) | Connection request processing method and apparatus, bluetooth earphone, wearable device, system and storage medium | |
US20140072129A1 (en) | Method and apparatus for detecting insertion of external audio outputting device in electronic device | |
US9674598B2 (en) | Audio accessory communication with active noise cancellation | |
EP3035171A1 (en) | Apparatus, system and method for communication of touch sensor information | |
JP5988449B2 (en) | Serial communication via communication control pin | |
CN104267924A (en) | Mobile terminal and audio processing method thereof | |
US11403245B2 (en) | Terminal, terminal peripheral, signal transmission system and signal sending and receiving method | |
CN103974163A (en) | Earphone compatible method, earphone compatible device and mobile terminal | |
KR20150017314A (en) | Audio jack system | |
CN103078224A (en) | Connecting line, control method, control circuit and electronic equipment | |
CN108054794A (en) | Charging and discharging method and device for intelligent terminal, terminal and storage medium | |
CN103279410A (en) | Externally-connected device prompt device and method thereof | |
CN104459376B (en) | A kind of interface circuit and peripherals detecting method, outer sensor based on the circuit | |
CN105807911A (en) | Automatic earphone recognition device and method | |
CN105512067B (en) | A kind of mobile terminal and its port multiplexing circuit and method | |
CN108124213A (en) | A kind of method of adjustment, device and the electronic equipment of earphone music | |
CN106603755B (en) | Mobile terminal and data processing method based on mobile terminal | |
CN106792466B (en) | Method for communication between equipment end and host end | |
CN106776083B (en) | Test control method and device and terminal equipment | |
US9369793B2 (en) | Audio playback system, earphone and method for controlling audio playback system | |
CN203760209U (en) | MHL cable and MHL cable hot plug detecting system | |
CN208336689U (en) | A kind of Type-C hub with voice prompting function | |
CN105204817A (en) | Information processing method and electronic equipment | |
CN104850522A (en) | Signal output method and device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
WD01 | Invention patent application deemed withdrawn after publication | ||
WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20160727 |