CN102769697A - Method and system for preventing false key-pressing caused by earphone inserted into terminal device - Google Patents

Method and system for preventing false key-pressing caused by earphone inserted into terminal device Download PDF

Info

Publication number
CN102769697A
CN102769697A CN2012102243013A CN201210224301A CN102769697A CN 102769697 A CN102769697 A CN 102769697A CN 2012102243013 A CN2012102243013 A CN 2012102243013A CN 201210224301 A CN201210224301 A CN 201210224301A CN 102769697 A CN102769697 A CN 102769697A
Authority
CN
China
Prior art keywords
earphone
hook key
terminal equipment
earphones
line system
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.)
Granted
Application number
CN2012102243013A
Other languages
Chinese (zh)
Other versions
CN102769697B (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.)
Huizhou TCL Mobile Communication Co Ltd
Original Assignee
Huizhou TCL Mobile Communication 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 Huizhou TCL Mobile Communication Co Ltd filed Critical Huizhou TCL Mobile Communication Co Ltd
Priority to CN201210224301.3A priority Critical patent/CN102769697B/en
Publication of CN102769697A publication Critical patent/CN102769697A/en
Application granted granted Critical
Publication of CN102769697B publication Critical patent/CN102769697B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Telephone Function (AREA)

Abstract

The invention discloses a method and a system for preventing false key-pressing caused by an earphone inserted into a terminal device. The method comprises the steps as follows: after the earphone is inserted into the terminal device and before preset time is up, a hook key event is shielded, and the state of a hook key is detected when the preset time is up; when the hook key is pressed, the earphone is determined to be a three-wire earphone, and the hook key event is continuously shielded; when the hook key is not pressed, the earphone is determined to be a four-wire earphone, and the hook key event occurs; and after the earphone is determined to be the three-wire earphone, the earphone is determined to be the four-wire earphone when a releasing event of the hook key is detected, and the hook key event occurs.

Description

A kind of method and system that prevent to produce when earphone from inserting terminal equipment the mistake button
Technical field
The present invention relates to the earphone field, relate in particular to a kind of method and system that prevent to produce when earphone from inserting terminal equipment the mistake button.
Background technology
4 line system earphone interfaces commonly used at present, as shown in Figure 1, the definition of 4 lines wherein is respectively: 1 is the mic line, and 2 is the GND line, and 3 is R channel, and 4 is L channel.And with on computers or the earphone on the mp3 often have only the i.e. 3 line system earphones of 3 lines, 3 line system earphones are exactly the earphone of not being with microphone, it synthesizes a GND line to mic line and GND line, the left and right acoustic channels line remains unchanged.
Because the defective of earphone and testing circuit design thereof; If the user inserts the speed of earphone on portable terminal fast inadequately; Will in the process that earphone inserts, be easy to occur reporting by mistake the situation of the hook key events on the earphone, the user can realize some shirtsleeve operations through the hook key, such as connecing/hanging up; Controls playing device and broadcast receiver etc., but if wrong report hook key then can have to the actual influence that the user causes: 1, insert earphone in the communication process and cause phone to hang up; Insert earphone when 2, sending a telegram here and cause the auto-pickup phone; When 3, inserting earphone, the music player that suspends originally begins automatic broadcast; When 4, inserting earphone, the FM that suspends originally begins automatic broadcast; 5, do not support not to be with the earphone of microphone.
Slowly inserting earphone causes the reason of wrong report hook key to be: when the user inserts 4 line system earphones; If it is fast inadequately that the user inserts the speed of earphone, mic detection line local overstand, the just direct ground connection of mic detection line on the mobile phone that the GND line on the earphone can be on mobile phone; This just is equivalent to the effect that the user presses the hook key; So this moment, software will think it is that the user presses the hook key by mistake, after the user inserts mobile phone to earphone fully, can report the incident that the hook key discharges again by mistake then.What insert as the user is the earphone of 3 line systems, and because of the earphone mic line and the GND line of 3 line systems is same single lines, mobile phone will be in the state that the hook key presses all the time and cause the related application operation exception.
Common solution is at present: after detecting earphone insertion incident, (such as 5 seconds) shield all hook key events in the sufficiently long time, insert earphone to give user's time enough, just begin to detect the hook key afterwards.But this method still is the many places defectives: 1, fast inadequately to the response speed of hook key, such as user's anxious hook key of pressing after inserting earphone, so also last 5 second such as needs afterwards button just can work; Surpass 5 seconds if 2 users insert the time of earphone, perhaps earphone rests on the half the state that is inserted into always, and situation that still can wrong button produces; 3, still do not support 3 line system earphones.
Therefore, prior art awaits to improve and development.
Summary of the invention
In view of the deficiency of above-mentioned prior art, the object of the present invention is to provide a kind of method and system that prevent to produce when earphone from inserting terminal equipment the mistake button, be intended to solve existing earphone and inserted the problem that is easy to generate the mistake button when slow.
Technical scheme of the present invention is following:
A kind of method that prevents to produce when earphone from inserting terminal equipment the mistake button wherein, comprises step:
A, after detecting earphone and inserting terminal equipment, in a scheduled time, the hook key events of control shielding earphone;
B, when detecting earphone and insert terminal equipment and reach said scheduled time, the state of the said hook key of detection starting when said hook key is down state, judges that then current slotting earphone is 3 line system earphones, and continues to control and shield the hook key events; When said hook key during, judge that then said earphone is 4 line system earphones, and enable the hook key events for down state not;
C, when judging that said earphone is 3 line system earphones, and when detecting said hook key and being released incident, judge again that then said earphone is 4 line system earphones, and enable the hook key events.
The said method that prevents to produce when earphone from inserting terminal equipment the mistake button wherein, also comprises step D:
When judging that current slotting earphone is 4 line system earphones, and when detecting the hook key events, report the hook key events to terminal equipment.
The said method that prevents to produce when earphone from inserting terminal equipment the mistake button, wherein, the state that detects the hook key in the said steps A is specially:
Obtain the state of hook key through the state of sense terminals equipment MIC line; Judge that when detecting said terminal equipment MIC line said hook key is a down state, then judge when said terminal equipment MIC line is unearthed state that when detecting said hook key is down state not for ground state.
The said method that prevents to produce when earphone from inserting terminal equipment the mistake button, wherein, the said scheduled time is 1 second.
The said method that prevents to produce when earphone from inserting terminal equipment the mistake button, wherein, said terminal equipment is a mobile phone.
The said method that prevents to produce when earphone from inserting terminal equipment the mistake button, wherein, when judging that current slotting earphone is 3 line system earphones, the MIC that sound collection is set is the MIC on the terminal equipment.
A kind of system that prevents to produce when earphone from inserting terminal equipment the mistake button, it comprises:
Hook key events shroud module is used for after detecting earphone insertion terminal equipment, in a scheduled time, and the hook key events of control shielding earphone;
The headset type determination module; Be used for when detecting earphone and insert terminal equipment and reach said scheduled time, the state of the said hook key of detection starting is when said hook key is down state; Judge that then current slotting earphone is 3 line system earphones, and continue control shielding hook key events; When said hook key during, judge that then said earphone is 4 line system earphones, and enable the hook key events for down state not;
3 line system earphone major punishment cover half pieces are used for when judging that said earphone be 3 line system earphones, and when detecting said hook key and being released incident, judge again that then said earphone is 4 line system earphones, and enable the hook key events.
The said system that prevents to produce when earphone from inserting terminal equipment the mistake button wherein, also comprises:
Hook key events reporting module is used for when judging that current slotting earphone be 4 line system earphones, and when detecting the hook key events, reports the hook key events to terminal equipment.
Beneficial effect: the present invention prevents to produce when earphone from inserting terminal equipment the method and system of mistake button; Through detecting the state of the hook key when the scheduled time of enough lacking; The situation of pressing and not pressing according to the hook key is judged the type of earphone; And determine whether shield or enable the hook key events, when the user inserted terminal equipment with earphone fully, whether the judgement that detects 3 line system earphones again was correct; The present invention has not only prevented to insert earphone and has crossed the situation that produces wrong report hook key events when slow, has also increased the new function that detects headset type.
Description of drawings
Fig. 1 is the earphone interface structural representation of 4 line system earphones in the prior art.
Fig. 2 produces the flow chart of the method preferred embodiment of mistake button when preventing that for the present invention earphone from inserting terminal equipment.
Fig. 3 produces the structured flowchart of system's preferred embodiment of mistake button when preventing that for the present invention earphone from inserting terminal equipment.
Embodiment
The present invention provides a kind of method and system that prevent to produce when earphone from inserting terminal equipment the mistake button, and is clearer, clear and definite for making the object of the invention, technical scheme and effect, below to further explain of the present invention.Should be appreciated that specific embodiment described herein only in order to explanation the present invention, and be not used in qualification the present invention.
See also Fig. 2, Fig. 2 produces the flow chart of the method preferred embodiment of mistake button when preventing that for the present invention earphone from inserting terminal equipment, and as shown in the figure, it comprises step:
S101, after detecting earphone and inserting terminal equipment, in a scheduled time, the hook key events of control shielding earphone;
S102, when detecting earphone and insert terminal equipment and reach said scheduled time, the state of the said hook key of detection starting when said hook key is down state, judges that then current slotting earphone is 3 line system earphones, and continues to control and shield the hook key events; When said hook key during, judge that then said earphone is 4 line system earphones, and enable the hook key events for down state not;
S103, when judging that said earphone is 3 line system earphones, and when detecting said hook key and being released incident, judge again that then said earphone is 4 line system earphones, and enable the hook key events.
In step S101; After detecting the incident that earphone is inserted into terminal equipment; Pick up counting immediately, specifically can carry out timing, and an enough short scheduled time (for example 1 second) is set through a timer; Before reaching this scheduled time, control masks all hook key events;
In step S102, when reaching this scheduled time, detect the state of this hook key; So that judge the type of current slotting earphone, and, judge whether enable the hook key events according to corresponding type; Promptly judge whether allow the hoo key events, behind the state that has detected the hook key, carry out different settings to different state; When said hook key is down state, judge that then said earphone is 3 line system earphones, because in the described scheduled time; The be pressed explanation or to be that the user inserts earphone fast inadequately or by the wrong report hook key that 3 line system earphones cause of hook key can judge temporarily that this earphone is 3 line system earphones at this moment; When said hook key during for down state not, explain that then said earphone is 3 line system earphones scarcely, the said earphone of decidable is 4 line system earphones, and can enable the hook key events, for example, connects/hang up controls playing device and broadcast receiver or the like.
In step S103; When detecting the hook key and be down state, be to judge that said earphone is 3 line system earphones, have also still that a kind of possibly to be that the user inserts the speed of earphone fast inadequately; GND line on the earphone can be on terminal equipment the place of MIC detection line stop long; Be the direct ground connection of MIC detection line on the terminal equipment, so need judge that also its decision method is again again: then again judge when said hook key is released incident that when detecting said earphone is 4 line system earphones to the situation that is judged to be 3 line system earphones; And enable the hook key events, otherwise judge that still said earphone is 3 line system earphones.The principle of this decision method is when the speed of earphone insertion is fast inadequately; It is long that GND line on the earphone rests on time of MIC detection line, but when the user was inserted into earphone in the terminal equipment fully, the GND line can leave the MIC detection line; Then can detect the d/d incident of hook key this moment; If above-mentioned situation can the said earphone of unquestionable judgement be 4 line system earphones, and before this because shielded the hook key events; So can't hook key events before be reported, so avoided the situation of wrong report hook key.
In the present invention; Said scheduled time needs enough to lack, and it is 1 second that the scheduled time for example can be set, and an important evidence of the present invention to be exactly the user can not insert basically again earphone was pressed the hook key within 1 second; Because the hook key is arranged on the earphone cord rather than on the terminal equipment; Only if the user painstakingly tests, otherwise the user does not generally have so fast key scroll, even and the user press the hook key within 1 second inserting earphone; Do not press incident even if do not respond this hook key, can not influence user's hook key events afterwards yet.
After step S103; After being judged to be 4 line system earphones, when detecting the hook key events, report the hook incident, after detecting said earphone and being 4 line system earphones to terminal equipment; Can begin to report the hook key events, for example connect hang up, controls playing device and broadcast receiver etc.And after judging that said earphone is 3 line system earphones, even it is that MIC on the terminal equipment is 3 line system earphones with the earphone that guarantees insertion that the MIC of sound collection also can be set, function such as also can converse normally.
In the present invention, terminal equipment is a mobile phone, because the earphone of on computer or MP3, using is generally 3 line system earphones, promptly not with the earphone of microphone, but the earphone of using on the mobile phone is generally 4 line system earphones, and it needs microphone function such as converse.
Based on said method, the present invention also provides a kind of system that prevents to produce when earphone from inserting terminal equipment the mistake button, and as shown in Figure 3, it comprises:
Hook key events shroud module 100 is used for after detecting earphone insertion terminal equipment, in a scheduled time, and the hook key events of control shielding earphone;
Headset type determination module 200; Be used for when detecting earphone and insert terminal equipment and reach said scheduled time, the state of the said hook key of detection starting is when said hook key is down state; Judge that then current slotting earphone is 3 line system earphones, and continue control shielding hook key events; When said hook key during, judge that then said earphone is 4 line system earphones, and enable the hook key events for down state not;
3 line system earphone major punishment cover half pieces 300 are used for when judging that said earphone be 3 line system earphones, and when detecting said hook key and being released incident, judge again that then said earphone is 4 line system earphones, and enable the hook key events.
Further, said system also comprises:
Hook key events reporting module 400 is used for when judging that current slotting earphone be 4 line system earphones, and when detecting the hook key events, reports the hook key events to terminal equipment.Detail about the function front of above-mentioned each module is existing, so repeat no more.
The present invention prevents to produce when earphone from inserting terminal equipment the method and system of mistake button; Through detecting the state of the hook key when the scheduled time of enough lacking; The situation of pressing and not pressing according to the hook key is judged the type of earphone; And determine whether shield or enable the hook key events, when the user inserted terminal equipment with earphone fully, whether the judgement that detects 3 line system earphones again was correct; The present invention has not only prevented to insert earphone and has crossed the situation that produces wrong report hook key events when slow, has also increased the new function that detects headset type.
Should be understood that application of the present invention is not limited to above-mentioned giving an example, concerning those of ordinary skills, can improve or conversion that all these improvement and conversion all should belong to the protection range of accompanying claims of the present invention according to above-mentioned explanation.

Claims (8)

1. a method that prevents to produce when earphone from inserting terminal equipment the mistake button is characterized in that, comprises step:
A, after detecting earphone and inserting terminal equipment, in a scheduled time, the hook key events of control shielding earphone;
B, when detecting earphone and insert terminal equipment and reach said scheduled time, the state of the said hook key of detection starting when said hook key is down state, judges that then current slotting earphone is 3 line system earphones, and continues to control and shield the hook key events; When said hook key during, judge that then said earphone is 4 line system earphones, and enable the hook key events for down state not;
C, when judging that said earphone is 3 line system earphones, and when detecting said hook key and being released incident, judge again that then said earphone is 4 line system earphones, and enable the hook key events.
2. produce the method for mistake button when preventing that according to claim 1 is said earphone from inserting terminal equipment, it is characterized in that, also comprise step D:
When judging that current slotting earphone is 4 line system earphones, and when detecting the hook key events, report the hook key events to terminal equipment.
3. produce the method for mistake button when preventing that according to claim 1 is said earphone from inserting terminal equipment, it is characterized in that the state that detects the hook key in the said steps A is specially:
Obtain the state of hook key through the state of sense terminals equipment MIC line; Judge that when detecting said terminal equipment MIC line said hook key is a down state, then judge when said terminal equipment MIC line is unearthed state that when detecting said hook key is down state not for ground state.
4. produce the method for mistake button when preventing that according to claim 1 is said earphone from inserting terminal equipment, it is characterized in that the said scheduled time is 1 second.
5. produce the method for mistake button when preventing that according to claim 1 is said earphone from inserting terminal equipment, it is characterized in that said terminal equipment is a mobile phone.
6. produce the method for mistake button when preventing that according to claim 5 is said earphone from inserting terminal equipment, it is characterized in that when judging that current slotting earphone is 3 line system earphones, the MIC that sound collection is set is the MIC on the terminal equipment.
7. one kind prevents to produce the system of button by mistake when earphone from inserting terminal equipment, and it comprises:
Hook key events shroud module is used for after detecting earphone insertion terminal equipment, in a scheduled time, and the hook key events of control shielding earphone;
The headset type determination module; Be used for when detecting earphone and insert terminal equipment and reach said scheduled time, the state of the said hook key of detection starting is when said hook key is down state; Judge that then current slotting earphone is 3 line system earphones, and continue control shielding hook key events; When said hook key during, judge that then said earphone is 4 line system earphones, and enable the hook key events for down state not;
3 line system earphone major punishment cover half pieces are used for when judging that said earphone be 3 line system earphones, and when detecting said hook key and being released incident, judge again that then said earphone is 4 line system earphones, and enable the hook key events.
8. produce the system of mistake button when preventing that according to claim 7 is said earphone from inserting terminal equipment, it is characterized in that, also comprise:
Hook key events reporting module is used for when judging that current slotting earphone be 4 line system earphones, and when detecting the hook key events, reports the hook key events to terminal equipment.
CN201210224301.3A 2012-07-02 2012-07-02 Method and system for preventing false key-pressing caused by earphone inserted into terminal device Active CN102769697B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201210224301.3A CN102769697B (en) 2012-07-02 2012-07-02 Method and system for preventing false key-pressing caused by earphone inserted into terminal device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201210224301.3A CN102769697B (en) 2012-07-02 2012-07-02 Method and system for preventing false key-pressing caused by earphone inserted into terminal device

Publications (2)

Publication Number Publication Date
CN102769697A true CN102769697A (en) 2012-11-07
CN102769697B CN102769697B (en) 2015-03-25

Family

ID=47096944

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201210224301.3A Active CN102769697B (en) 2012-07-02 2012-07-02 Method and system for preventing false key-pressing caused by earphone inserted into terminal device

Country Status (1)

Country Link
CN (1) CN102769697B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103442133A (en) * 2013-08-16 2013-12-11 上海闻泰电子科技有限公司 Mobile terminal simultaneously supporting three-section type earphone and four-section type earphone and operation method
CN104093114A (en) * 2014-07-22 2014-10-08 Tcl通讯(宁波)有限公司 Detection device, system and method for headset buttons
CN104821981A (en) * 2015-03-13 2015-08-05 惠州Tcl移动通信有限公司 Detection method for earphone operation

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5832075A (en) * 1996-09-20 1998-11-03 Mitel Corporation Off-hook detector for headset
CN1867133A (en) * 2006-03-08 2006-11-22 华为技术有限公司 Method for preventing mobile terminal earphone keystroke mis-operation and mobile terminal
CN101184284A (en) * 2007-11-20 2008-05-21 东莞欧珀移动通信有限公司 Control method for judging insertion type of earphone by mobile phone
CN101945172A (en) * 2010-09-17 2011-01-12 惠州Tcl移动通信有限公司 Mobile phone-based earphone recognition calling method and mobile phone
CN102075845A (en) * 2010-12-29 2011-05-25 上海华勤通讯技术有限公司 Method for identifying earphone types

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5832075A (en) * 1996-09-20 1998-11-03 Mitel Corporation Off-hook detector for headset
CN1867133A (en) * 2006-03-08 2006-11-22 华为技术有限公司 Method for preventing mobile terminal earphone keystroke mis-operation and mobile terminal
CN101184284A (en) * 2007-11-20 2008-05-21 东莞欧珀移动通信有限公司 Control method for judging insertion type of earphone by mobile phone
CN101945172A (en) * 2010-09-17 2011-01-12 惠州Tcl移动通信有限公司 Mobile phone-based earphone recognition calling method and mobile phone
CN102075845A (en) * 2010-12-29 2011-05-25 上海华勤通讯技术有限公司 Method for identifying earphone types

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103442133A (en) * 2013-08-16 2013-12-11 上海闻泰电子科技有限公司 Mobile terminal simultaneously supporting three-section type earphone and four-section type earphone and operation method
CN104093114A (en) * 2014-07-22 2014-10-08 Tcl通讯(宁波)有限公司 Detection device, system and method for headset buttons
CN104093114B (en) * 2014-07-22 2018-03-16 Tcl通讯(宁波)有限公司 A kind of detection means of earphone keystroke, detecting system and detection method
CN104821981A (en) * 2015-03-13 2015-08-05 惠州Tcl移动通信有限公司 Detection method for earphone operation
CN104821981B (en) * 2015-03-13 2017-11-07 惠州Tcl移动通信有限公司 A kind of detection method of earphone operation

Also Published As

Publication number Publication date
CN102769697B (en) 2015-03-25

Similar Documents

Publication Publication Date Title
CN103118191B (en) Using control method and mobile terminal for iPhone wire control earphone
CN110278509A (en) A kind of wireless headset control method, device and wireless headset and storage medium
CN102915751A (en) Method for automatically regulating sound volume and terminal equipment thereof
CN104834601B (en) The automated testing method of intelligent terminal RAM leakage based on android system
CN105786520A (en) Method and device for managing applications of electronic equipment
CN101841599A (en) Method and mobile phone for preventing mistaken hanging up in conversation of mobile phone
CN104267924A (en) Mobile terminal and audio processing method thereof
CN105487899A (en) Headphone wearing state reporting method and system and headphone
CN105372026A (en) Air tightness detection device and method of microphone pickup structure path
US20220353627A1 (en) Wireless earphone synchronization detection method, apparatus, wireless earphones and storage medium
CN103095915A (en) Method of preventing faulty operation based on touch screen mobile phone and mobile phone
CN103118173A (en) Method and device conducting event notice through mobile terminal
CN103631613A (en) Terminal unlocking and program running triggering method
CN102769697A (en) Method and system for preventing false key-pressing caused by earphone inserted into terminal device
CN106453791A (en) A sound signal output method and apparatus and an earphone state detection method and apparatus
CN205754521U (en) A kind of audio frequency automatization test system based on Wifi communication and equipment
KR20120060570A (en) Apparatus and method displaying event notification
CN103873650A (en) Information processing method and electronic device
CN107241642B (en) A kind of playback method and terminal
CN103067601B (en) Mobile terminal and detecting method of earphone inserting state thereof
CN103279410A (en) Externally-connected device prompt device and method thereof
CN105373371A (en) Method and system for controlling volume of windows equipment through browser
CN104754098A (en) Volume adjusting method and system for single-key earphone
CN104821981B (en) A kind of detection method of earphone operation
CN105848030A (en) Time obtaining method and device, mobile terminal and earphone

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant