CN1867134A - Method for preventing mobile terminal earphone keystroke mis-operation and mobile terminal - Google Patents

Method for preventing mobile terminal earphone keystroke mis-operation and mobile terminal Download PDF

Info

Publication number
CN1867134A
CN1867134A CNA2006100581664A CN200610058166A CN1867134A CN 1867134 A CN1867134 A CN 1867134A CN A2006100581664 A CNA2006100581664 A CN A2006100581664A CN 200610058166 A CN200610058166 A CN 200610058166A CN 1867134 A CN1867134 A CN 1867134A
Authority
CN
China
Prior art keywords
earphone keystroke
keystroke signal
earphone
portable terminal
signal level
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
CNA2006100581664A
Other languages
Chinese (zh)
Other versions
CN100442893C (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
Priority to CNB2006100581664A priority Critical patent/CN100442893C/en
Publication of CN1867134A publication Critical patent/CN1867134A/en
Application granted granted Critical
Publication of CN100442893C publication Critical patent/CN100442893C/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Telephone Function (AREA)

Abstract

The invention relates to a method for avoiding button mistake operation on the mobile terminal earphone, and relative mobile terminal, which is characterized in that: when the mobile terminal detects the earphone button signal, processing button vibration-removal treatment; if said earphone button signal is effective after the button vibration-removal treatment, the mobile terminal detects the change of voltage of earphone button signal, in preset time; the mobile terminal according to the detected result processes relative earphone button operation. With said invention, the false earphone button signal caused by sound self-activated vibration in the inserting or drawing process can be recognized, to avoid the button mistake operation.

Description

Prevent the method and the portable terminal of mobile terminal earphone keystroke mis-operation
Technical field
The present invention relates to network communications technology field, relate in particular to a kind of method and portable terminal that prevents mobile terminal earphone keystroke mis-operation.
Background technology
Mobile phone big city is equipped with Headphone accessory.The Headphone accessory that uses in the mobile phone also has a button usually except receiver (being earphone) and transmitter (being microphone) are arranged, be used for the receiving/hang-up phone.Headphone accessory is divided into two classes usually with interface unit between the mobile phone: a class is to be connected by special headset plug/socket (or claiming earphone jack), another kind ofly is and shared I/O connectors such as the data I/O of mobile phone or charger.
Line between headset plug and the socket is generally 3 lines or 4 lines, and wherein one is Mike as ground wire, one, and in addition one or two is earphone, and therefore the branch of 3 cores and 4 core headset plug/sockets is arranged.
Fig. 1 is 4 core earphone socket hardware principle schematic diagrames, this socket and the supporting use of 4 core headset plugs.When plug did not insert, 3 pin of socket and the connection of 5 pin, 4 pin and 6 pin were connected; Behind the earphones plug inserting to position, 1~4 pin of headset plug is connected one by one with 1~4 pin of socket respectively, and 3 pin of socket and 5 pin, 4 pin and 6 pin disconnect respectively.Usually with 1 pin as ground wire, the order of 2,3,4 pin is self-defined as required by the designer.
Because the pin number of headset connector is limited, button on the handset earphone often adopts the form of pin multiplexing to realize, multiplexing mode normally is biased to certain potentials in mobile phone inside with certain pin, and button is connected in parallel between corresponding with it pin and the ground (or power supply).After earphone was plugged, the voltage of this point was forced to move to ground or supply voltage when button was pressed, and mobile phone inside knows that by level ratio button presses (being that mobile phone receives push button signalling).If a plurality of buttons are arranged on the earphone, can adopt a plurality of resistance series connection or parallel resistor network, when different buttons is pressed, produce different magnitudes of voltage because of voltage ratio is different, mobile phone inside judges it is which button is connected by level ratio.
Fig. 2 is the hardware principle schematic diagram of part of linking to each other with earphone in the mobile phone, and 1 pin of socket be, and 2,3 pin are left and right sound channels, if earphone can be received 3 pin for monophony, 2 pin free time are with compatible 3 cores and 4 core plugs; 5 pin are used for earphone and insert/extract detection, usually receive GPIO (the General Purpose Input/Output of CPU (baseband chip), general I/O pin) on, and draw (or weak drop-down) on a little less than CPU inside is provided with, and 3 pin connect less drop-down (or on the draw) resistance of resistance, 3 pin and 5 pin disconnect when earphone inserts, 3 pin and 5 pin are connected when earphone is extracted, thereby make 5 pin level by low uprise (or by high step-down), CPU just can detect earphone and whether inserts/extract (being that earphone inserts/extract signal) in level or the hopping edge by detecting 5 pin; 4 pin are Mike and button multiplexing pin, this earphone has only a button, and mobile phone inside is biased to certain potentials with MIC (Mike) pin, when earphone keystroke is pressed, 4 pin are forced to move to ground, export corresponding level by voltage comparator circuit and give CPU and carry out that button detects and handle.
Headset plug is inserting or is extracting in the process of earphone socket, can cause particularly short circuit mutually between the adjacent leads between the pin, and this is by itself structures shape.With 4 core sockets is example, and the process that plug inserts is as follows:
1,4 pin of plug contact with 2 pin of socket.Because the distance on the plug between adjacent leads less than the width of ground wire on the socket (1 pin), may cause 3 pin and the 4 pin short circuits of plug; Socket 2 pin and 1 pin may be by 4 pin short circuits of plug simultaneously.
2, plug continues to insert, and 4 pin of plug and 3 pin of socket are connected, and socket 3 pin and 5 pin disconnect.
3,4 pin of 4 pin of plug and socket are connected, and 4 pin and 6 pin disconnect on the socket.May cause 3 pin and the 4 pin short circuits of socket.
As shown in Figure 2,3 pin are the audio output that mobile phone is given earphone, and 4 pin are Mike's input, when 3 pin and 4 pin short circuits, in mobile phone inside the earpiece audio output have directly been received audio input end, because the time-delay and the amplification in mobile phone internal audio frequency loop, can form audio frequency self-oscillation this moment, makes the voltage comparator circuit action, produces false earphone keystroke signal, cause the earphone keystroke mis-operation of mobile phone CPU, cause phone to be connected undesirably or hang up.
Equally, 3 core headset plugs also may cause 1 pin and 2 pin, 2 pin and the of short duration connection of 3 pin during insertion.If 2 pin are MIC and button multiplexing pin, so 2 pin and 1 pin () can produce the earphone keystroke signal of a falseness during short circuit; Can cause the audio frequency self-excitation when 3 pin (earphone) and 2 pin short circuits, also may produce false earphone keystroke signal, thereby cause the earphone keystroke mis-operation of mobile phone CPU.
In addition, earphone keystroke operation itself can produce mechanical shaking, and mechanical shaking also can produce false earphone keystroke signal, thereby causes the earphone keystroke mis-operation of mobile phone CPU.
Be the process of example explanation earphone keystroke operation below with Fig. 2:
If the microphone of handset earphone shown in Figure 2 is an electret.The MIC end has certain DC potential Vmic (about 1V) during operate as normal, and the magnitude of voltage very little (generally below several mV) of microphone output, therefore the comparison threshold Vc of voltage comparator can be set between 0~Vmic, but it is should be than Vmic low and reserve certain allowance, do not having under the situation of button operation when guaranteeing normally to use, the fluctuation of MIC terminal voltage can not be lower than Vc yet.
When the button on the earphone was pressed, the MIC end was forced to move to ground or power supply, and the voltage comparator output level changes thereupon.For narrating for simplicity, suppose that MIC was pulled to ground when button was pressed; The voltage comparator output level is low (0) during the button access failure, and it is high (1) that button is connected the back output voltage.Consider the mechanical shaking phenomenon of button when connecting, during the one-touch operation, the output voltage waveforms of voltage comparator as shown in Figure 3.
Just pressed t1 during this period of time from button,, be called the shake time during this period of time, usually at several mS~tens mS owing to the mechanical contact spring causes voltage comparator to export a string time and width pulse at random.From t1 constantly, button is reliably connected, the high level that voltage comparator output is stable.
For the keystroke mis-operation that prevents that the keyboard mechanical shake from causing, the prior art scheme adopts the method for software delay retaking of a year or grade key-press status usually, promptly when detecting push button signalling, do not handle earlier, whether but it is still effective to detect this push button signalling state again after time-delay a period of time (being generally tens mS), if effectively then carry out the function of button, otherwise do not deal with.
In earphone plug process, when audio output (earphone end) produces self-oscillation with audio output (Mike's end) connection, because audio frequency vibrates in very wide amplitude range, the MIC terminal voltage is crossed when voltage comparator is differentiated point and is caused that the comparator output level correspondingly changes, the voltage comparator output waveform as shown in Figure 4, this phenomenon is similar to key jitter.
Usually button goes the shake time-delay all in tens mS~tens mS scopes, if go the shake time-delay excessive, the user can feel that tangible response is blunt when normal button; And the time of earphone plug process generally will be in hundreds of mS level, though therefore the prior art scheme of above-mentioned software delay retaking of a year or grade key-press status can effectively solve the earphone keystroke mis-operation problem that key jitter causes, how to be identified in the false earphone keystroke signal that produces because of audio frequency self-oscillation in the earphone plug process but but can't solve, thereby to prevent the problem of earphone keystroke mis-operation.
Summary of the invention
In view of above-mentioned existing in prior technology problem, the purpose of this invention is to provide a kind of method and portable terminal that prevents mobile terminal earphone keystroke mis-operation, can discern the false earphone keystroke signal that produces because of audio frequency self-oscillation in the mobile terminal earphone plug process, thereby effectively prevent earphone keystroke mis-operation.
The objective of the invention is to be achieved through the following technical solutions:
The invention provides a kind of method, comprising:
The present invention also provides a kind of method that prevents mobile terminal earphone keystroke mis-operation, comprises the steps:
A, portable terminal detect and carry out button behind the earphone keystroke signal and go dithering process;
B, still effective if described earphone keystroke signal goes after the dithering process through button, then whether portable terminal detects described earphone keystroke signal level and changes in predetermined duration;
C, portable terminal carry out processes relative earphone button operation according to described testing result.
Described step C specifically comprises:
C1, if testing result be in scheduled duration described earphone keystroke signal level took place the variation, portable terminal thinks that described earphone keystroke signal is the false push button signalling that the audio frequency self-oscillation that produces in the earphone plug process causes, does not do any processing to described earphone keystroke signal.
Described step C specifically comprises:
C2, if variation did not take place for described earphone keystroke signal level in scheduled duration in testing result, portable terminal thinks that described earphone keystroke signal is real earphone keystroke signal, the response earphone keystroke is carried out corresponding function.
Described scheduled duration is: 10 milliseconds to 100 milliseconds.
Described step B comprises: whether portable terminal mode by baseband chip CPU counters count voltage comparator output voltage situation of change in scheduled duration detects described earphone keystroke signal level and changes.
Described step B comprises: whether described portable terminal mode by interrupt service routine statistics voltage comparator output voltage situation of change in scheduled duration detects described earphone keystroke signal level and changes.
Described step B specifically comprises:
B1, still effective if described earphone keystroke signal goes after the dithering process through button then starts the interrupt service routine of the CPU interrupt pin that links to each other with the voltage comparator output;
B2, after described scheduled duration finishes, close interrupt service routine, portable terminal judges whether described CPU interrupt pin interrupt event took place, if interrupt event did not take place, then portable terminal confirms that variation did not take place the earphone keystroke signal level; Otherwise portable terminal confirms that the earphone keystroke signal level took place to change.
Described step B comprises: whether portable terminal mode by upper layer application statistics voltage comparator output voltage situation of change in scheduled duration detects described earphone keystroke signal level and changes.
The present invention also provides a kind of portable terminal, be provided with button in this portable terminal and go the dithering process module, be used to detect and carry out button behind effective earphone keystroke signal and go dithering process, if it is still effective that described earphone keystroke signal goes after the dithering process through button, then described push button signalling is transferred to earphone keystroke signal level detection module;
Described earphone keystroke signal level detection module, be used to receive described earphone keystroke signal after, in predetermined duration, detect described earphone keystroke signal level and whether change, and testing result is transferred to described earphone keystroke signal processing module;
Described earphone keystroke signal processing module is used for carrying out processes relative earphone button operation according to described testing result after described scheduled duration finishes.
Described earphone keystroke signal processing module comprises false push button signalling processing sub and true push button signalling processing sub;
Described false push button signalling processing sub, be used for taking place to change for described earphone keystroke signal level in scheduled duration when described testing result, confirm that then described earphone keystroke signal is the false push button signalling that the audio frequency self-oscillation that produces in the earphone plug process causes, does not do any processing to described earphone keystroke signal;
Described true push button signalling processing sub, be used for for described earphone keystroke signal level in scheduled duration variation taking place when described testing result, confirm that then described earphone keystroke signal is real earphone keystroke signal, the response earphone keystroke is carried out corresponding function.
As seen from the above technical solution provided by the invention, adopt method of the present invention and portable terminal to have following advantage:
1, can effectively discern the false earphone keystroke signal that produces because of audio frequency self-oscillation in the mobile terminal earphone plug process, thereby effectively avoid earphone keystroke mis-operation;
2, specific implementation of the present invention variation can adopt the mode of CPU internal hardware (comprising: hardware counter and interrupt pin) to realize, also can realize by upper layer software (applications);
3, adopt the implementation of CPU internal hardware (comprising: hardware counter and interrupt pin) not only can effectively avoid earphone keystroke mis-operation, and this technical scheme can realize in bsp driver, not influence software execution speed.
Description of drawings
Fig. 1 is 4 core earphone socket principle schematic;
Fig. 2 is the hardware principle schematic diagram of part of linking to each other with earphone in the mobile phone;
The output voltage waveform of voltage comparator when Fig. 3 operates for earphone keystroke;
Fig. 4 is the output voltage waveform of voltage comparator when producing audio frequency self-oscillation in the earphone plug process;
Fig. 5 is the flow chart of the described method of the embodiment of the invention;
Fig. 6 detects earphone keystroke signal level variation flow chart for the embodiment of the invention adopts hardware counter;
Fig. 7 detects earphone keystroke signal level variation flow chart for the embodiment of the invention adopts interrupt pin;
Fig. 8 is the structural representation of the described portable terminal of the embodiment of the invention.
Embodiment
The waveform of comparison diagram 4 and Fig. 3, its fundamental difference is can export a stable significant level after the earphone keystroke signal is through certain hour (normally several mS~tens mS) shake, the significant level width is at 100mS~hundreds of mS during generally normal earphone button operation, and the waveform of voltage comparator output is to change always during audio frequency self-oscillation, and the significant level width is less.Because the time-delay characteristics parameter of handset audio loop determines that generally more than tens Hz, promptly cycle of oscillation is below tens mS for the frequency range of audio oscillation.In view of the above, the earphone keystroke input is just suitably improved and can be discerned the false push button signalling that normal earphone keystroke operation signal and audio frequency self-oscillation cause with going to shake, thereby prevent earphone keystroke mis-operation.Concrete steps comprise:
After portable terminal judges that detected earphone keystroke signal effectively, at first carry out button and go dithering process;
If it still is effectively that this earphone keystroke signal goes after the dithering process through button, then detecting this earphone keystroke signal level in predetermined duration has no change;
If this earphone keystroke signal level changes, think that then this earphone keystroke signal is that the audio frequency self-oscillation that produces in the earphone plug process causes, does not deal with this earphone keystroke signal; If this earphone keystroke signal is effectively stable always in predetermined duration, think that then this earphone keystroke signal is real earphone keystroke signal, then respond earphone keystroke, carry out corresponding function.
Because the audio frequency self-oscillation cycle is usually below tens mS, so predetermined duration is comparatively suitable in tens~100mS scope.Because if predetermined duration is too short, then when audio frequency self-oscillation frequency is low, can't effectively detect the situation of change of earphone keystroke signal level, therefore possibly can't correctly discern false push button signalling, thereby cause keystroke mis-operation; The user can feel that tangible response is blunt when normal button if predetermined duration is long, and may cause that very brief button operation is invalid.
For the present invention there being further understanding, method of the present invention is described in detail below in conjunction with accompanying drawing.
The specific implementation of the method for the invention may further comprise the steps as shown in Figure 5:
Step 51: portable terminal detects and carries out button behind effective earphone keystroke signal and go dithering process.
After portable terminal detects the earphone keystroke signal and judges effectively, this push button signalling is not handled earlier, and time-delay a period of time t1 (being generally tens mS) back execution in step 52.
Step 52: portable terminal judges once more whether the earphone keystroke signal is effective, if push button signalling is still effective, then execution in step 53; Otherwise, think that this push button signalling is false push button signalling, does not deal with this push button signalling.
Step 53: start timer, set duration t2.
Wherein, duration t2 is usually in tens~100mS scope.
Step 54: whether portable terminal detects earphone keystroke signal level (promptly producing earphone keystroke voltage of signals comparator output level) and changes, if detect by key level variation taken place, think that then this earphone keystroke signal is the false push button signalling that the audio frequency self-oscillation that produces in the earphone plug process causes, does not do any processing to this push button signalling; If testing result is not for to change by key level, then execution in step 55.
Step 55: judge whether the duration t2 that sets has arrived, if time is up, then execution in step 56, otherwise, return step 54, continue to detect the earphone keystroke signal level and whether change.
Step 56: portable terminal thinks that this earphone keystroke signal is real earphone keystroke signal, and the response earphone keystroke is carried out corresponding function.
Technique scheme can realize by upper layer software (applications), promptly at the fixed time in the t2 mode by upper layer application statistics voltage comparator output voltage situation of change detect the earphone keystroke signal level and whether change.Because the self-oscillatory frequency range broad of audio frequency and certain randomness is arranged, therefore, inquiry times can not be very little, can not be uniformly-spaced between twice inquiry simultaneously, in order to avoid cause that Query Result does not conform to the actual conditions during with self-oscillatory cycle synchronisation.
(tens~100mS) is shorter, and therefore, technique scheme also can adopt the hardware timer of CPU inside to realize in bsp driver, and does not influence software execution speed owing to the timing t2 to push button signalling level change-detection.
According to the hardware resource situation of CPU, the testing process that the push button signalling level is changed can have following two kinds of concrete implementations:
1, the output of voltage comparator is received on the CPU counter input pin, started the back at timer t2 the situation of change of earphone keystroke signal level is counted, stop counting when regularly finishing.If the rolling counters forward value is 0, then portable terminal confirms that the earphone keystroke signal level does not change; Otherwise portable terminal is confirmed the earphone keystroke signal level variation has been taken place.Specific implementation may further comprise the steps as shown in Figure 6:
Step 61: start timer, set duration t2, simultaneously counter is carried out zero clearing and handle and the enabling counting device.
Step 62: counter is counted processing in setting duration t2, promptly add up the situation of change of voltage comparator output level, if the voltage comparator output level takes place once to change, then the count value of counter adds 1; If the voltage comparator output level does not change, then the count value of counter is constant.
Step 63: judge whether the duration t2 that sets has arrived, if time is up, then execution in step 64; Otherwise, return step 62.
Step 64: close counter and timer, read the count value of counter.
Step 65: judge whether count value is 0, if be 0, then portable terminal confirms that the earphone keystroke signal level does not change, thereby confirms that this earphone keystroke signal is real earphone keystroke signal, and the response earphone keystroke is carried out corresponding function; If count value is not 0, then portable terminal confirms that variation has taken place the earphone keystroke signal level, thereby confirms that this earphone keystroke signal is the false push button signalling that audio frequency self-oscillation that earphone plug process produces causes, does not do any processing to this push button signalling.
2, the voltage comparator output is received the interrupt pin (adopting voltage or edge to trigger interrupts) of CPU, realized the detection that the push button signalling level changes by interrupt service routine.If variation did not take place the push button signalling level in timing t 2, interrupt event just can not take place in this pin; Otherwise, this pin generation interrupt event.Timing t 2 finishes the back and judges whether the CPU interrupt pin that links to each other with the voltage comparator output interrupt event has taken place, if do not take place, then portable terminal thinks that the push button signalling level does not change; Otherwise portable terminal thinks that variation has taken place the push button signalling level.
In actual applications, CPU may have a plurality of interrupt sources, therefore in order to distinguish other interrupt events, can define a level change flag (being masked as 1 such as this) in program, shows that variation once took place the voltage comparator output level.When program initialization earlier with this level change flag clear 0.When producing interrupt event, then enter corresponding interrupt service routine, and this level change flag is set in this interrupt service routine if the voltage comparator output level has taken place to change; Can not enter corresponding interrupt service routine if the voltage comparator output level does not change, also just this level change flag can be set.Whether regularly finish the back portable terminal detects this level change flag and is set and can judges whether the push button signalling level variation has taken place.Specific implementation may further comprise the steps as shown in Figure 7:
Step 71: close interrupt service routine, and remove interrupt identification.
Step 72: start timer, set duration t2.
Step 73: remove the level change flag, and start interrupt service routine.
If the voltage comparator output level changes, then interrupt service routine is provided with the level change flag, such as being set to 1; If the voltage comparator output level does not change, the level change flag is not set then.
Step 74: judge whether the duration t2 that sets has arrived, if time is up, then execution in step 75; Otherwise, continue to judge whether the duration t2 that sets has arrived.
Step 75: close interrupt service routine and timer t2.
Step 76: portable terminal judges whether to be provided with the level change flag, whether such as the level change flag is 1, if the level change flag is not 1, then portable terminal confirms that the earphone keystroke signal level does not change, thereby confirm that this earphone keystroke signal is real earphone keystroke signal, the response earphone keystroke is carried out corresponding function; If the level change flag is 1, then portable terminal confirms that variation has taken place the earphone keystroke signal level, thereby confirm that this earphone keystroke signal is the false push button signalling that audio frequency self-oscillation that earphone plug process produces causes, does not do any processing to this push button signalling.
The present invention also provides a kind of portable terminal, and as shown in Figure 8, be provided with button in this portable terminal and remove dithering process module, earphone keystroke signal level detection module and earphone keystroke signal processing module, wherein:
Button goes the function of dithering process module to be: detect and carry out button behind effective earphone keystroke signal and go dithering process, if it is still effective that this earphone keystroke signal goes after the dithering process through button, then this push button signalling is transferred to earphone keystroke signal level detection module;
The function of earphone keystroke signal level detection module is: receive after button removes earphone keystroke signal that dithering process module transmission comes, in predetermined duration, detect this earphone keystroke signal level and whether change, and testing result is transferred to the earphone keystroke signal processing module;
The function of earphone keystroke signal processing module is: scheduled duration finishes the back and carries out processes relative earphone button operation according to the testing result of earphone keystroke signal level variation.
Wherein, the function of earphone keystroke signal processing module can realize by false push button signalling processing sub and true push button signalling processing sub;
The function of false push button signalling processing sub is: when testing result took place to change for this earphone keystroke signal level in scheduled duration, confirm that then this earphone keystroke signal is the false push button signalling that the audio frequency self-oscillation that produces in the earphone plug process causes, does not do any processing to this earphone keystroke signal;
The function of true push button signalling processing sub is: when testing result for this earphone keystroke signal level in scheduled duration variation did not take place, confirm that then this earphone keystroke signal is real earphone keystroke signal, the response earphone keystroke is carried out corresponding function.
In sum, adopt technical scheme of the present invention, can effectively discern the false earphone keystroke signal that produces because of audio frequency self-oscillation in the mobile terminal earphone plug process, thereby avoid earphone keystroke mis-operation; In addition, the specific implementation of the present invention variation can adopt the mode of CPU internal hardware (comprising: hardware counter and interrupt pin) to realize, does not influence software execution speed, also can realize by upper layer software (applications).
The above; only for the preferable embodiment of the present invention, but protection scope of the present invention is not limited thereto, and anyly is familiar with those skilled in the art in the technical scope that the present invention discloses; the variation that can expect easily or replacement all should be encompassed within protection scope of the present invention.Therefore, protection scope of the present invention should be as the criterion with the protection range of claim.

Claims (10)

1, a kind of method that prevents mobile terminal earphone keystroke mis-operation is characterized in that, comprises the steps:
A, portable terminal detect and carry out button behind the earphone keystroke signal and go dithering process;
B, still effective if described earphone keystroke signal goes after the dithering process through button, then whether portable terminal detects described earphone keystroke signal level and changes in predetermined duration;
C, portable terminal carry out processes relative earphone button operation according to described testing result.
2, method according to claim 1 is characterized in that, described step C specifically comprises:
C1, if testing result be in scheduled duration described earphone keystroke signal level took place the variation, portable terminal thinks that described earphone keystroke signal is the false push button signalling that the audio frequency self-oscillation that produces in the earphone plug process causes, does not do any processing to described earphone keystroke signal.
3, method according to claim 1 is characterized in that, described step C specifically comprises:
C2, if variation did not take place for described earphone keystroke signal level in scheduled duration in testing result, portable terminal thinks that described earphone keystroke signal is real earphone keystroke signal, the response earphone keystroke is carried out corresponding function.
4, method according to claim 1 is characterized in that, described scheduled duration is: 10 milliseconds to 100 milliseconds.
5, according to each described method of claim 1 to 4, it is characterized in that described step B comprises: whether portable terminal mode by baseband chip CPU counters count voltage comparator output voltage situation of change in scheduled duration detects described earphone keystroke signal level and changes.
6, according to each described method of claim 1 to 4, it is characterized in that described step B comprises: whether described portable terminal mode by interrupt service routine statistics voltage comparator output voltage situation of change in scheduled duration detects described earphone keystroke signal level and changes.
7, method according to claim 6 is characterized in that, described step B specifically comprises:
B1, still effective if described earphone keystroke signal goes after the dithering process through button then starts the interrupt service routine of the CPU interrupt pin that links to each other with the voltage comparator output;
B2, after described scheduled duration finishes, close interrupt service routine, portable terminal judges whether described CPU interrupt pin interrupt event took place, if interrupt event did not take place, then portable terminal confirms that variation did not take place the earphone keystroke signal level; Otherwise portable terminal confirms that the earphone keystroke signal level took place to change.
8, according to each described method of claim 1 to 4, it is characterized in that described step B comprises: whether portable terminal mode by upper layer application statistics voltage comparator output voltage situation of change in scheduled duration detects described earphone keystroke signal level and changes.
9, a kind of portable terminal, it is characterized in that, be provided with button in this portable terminal and go the dithering process module, be used to detect and carry out button behind effective earphone keystroke signal and go dithering process, if it is still effective that described earphone keystroke signal goes after the dithering process through button, then described push button signalling is transferred to earphone keystroke signal level detection module;
Described earphone keystroke signal level detection module, be used to receive described earphone keystroke signal after, in predetermined duration, detect described earphone keystroke signal level and whether change, and testing result is transferred to described earphone keystroke signal processing module;
Described earphone keystroke signal processing module is used for carrying out processes relative earphone button operation according to described testing result after described scheduled duration finishes.
10, portable terminal according to claim 9 is characterized in that, described earphone keystroke signal processing module comprises false push button signalling processing sub and true push button signalling processing sub;
Described false push button signalling processing sub, be used for taking place to change for described earphone keystroke signal level in scheduled duration when described testing result, confirm that then described earphone keystroke signal is the false push button signalling that the audio frequency self-oscillation that produces in the earphone plug process causes, does not do any processing to described earphone keystroke signal;
Described true push button signalling processing sub, be used for for described earphone keystroke signal level in scheduled duration variation taking place when described testing result, confirm that then described earphone keystroke signal is real earphone keystroke signal, the response earphone keystroke is carried out corresponding function.
CNB2006100581664A 2006-03-08 2006-03-08 Method for preventing mobile terminal earphone keystroke mis-operation and mobile terminal Active CN100442893C (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CNB2006100581664A CN100442893C (en) 2006-03-08 2006-03-08 Method for preventing mobile terminal earphone keystroke mis-operation and mobile terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CNB2006100581664A CN100442893C (en) 2006-03-08 2006-03-08 Method for preventing mobile terminal earphone keystroke mis-operation and mobile terminal

Publications (2)

Publication Number Publication Date
CN1867134A true CN1867134A (en) 2006-11-22
CN100442893C CN100442893C (en) 2008-12-10

Family

ID=37425983

Family Applications (1)

Application Number Title Priority Date Filing Date
CNB2006100581664A Active CN100442893C (en) 2006-03-08 2006-03-08 Method for preventing mobile terminal earphone keystroke mis-operation and mobile terminal

Country Status (1)

Country Link
CN (1) CN100442893C (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101778320A (en) * 2009-12-25 2010-07-14 中兴通讯股份有限公司 Microphone key-press earphone and state identification method
CN102780946A (en) * 2011-05-10 2012-11-14 宏达国际电子股份有限公司 Electronic device, electronic system and method for processing voltage signal of peripheral accessory
CN101784001B (en) * 2009-12-18 2013-04-17 华为终端有限公司 Headset socket and headset keypad detection method
CN103197199A (en) * 2012-11-13 2013-07-10 上海华勤通讯技术有限公司 Disconnection detection device and method
CN104092454A (en) * 2014-06-23 2014-10-08 西安电子工程研究所 Key dithering removal method based on logic gate circuit
CN104821981A (en) * 2015-03-13 2015-08-05 惠州Tcl移动通信有限公司 Detection method for earphone operation
CN106604164A (en) * 2016-04-29 2017-04-26 福建先创电子有限公司 Jitter elimination method and apparatus for key of earphone

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0675680A (en) * 1992-07-21 1994-03-18 Advanced Micro Devicds Inc Key pad scanner mechanism and method for scanning key pad
US6751331B2 (en) * 2001-10-11 2004-06-15 United Global Sourcing Incorporated Communication headset
CN100426901C (en) * 2001-12-31 2008-10-15 中兴通讯股份有限公司 Earphone and pushbutton detection device and method in mobile communication terminal
KR100451144B1 (en) * 2002-11-22 2004-10-13 엘지전자 주식회사 Complement method and apparatus for earphones sensing error in mobile

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101784001B (en) * 2009-12-18 2013-04-17 华为终端有限公司 Headset socket and headset keypad detection method
CN101778320A (en) * 2009-12-25 2010-07-14 中兴通讯股份有限公司 Microphone key-press earphone and state identification method
CN102780946A (en) * 2011-05-10 2012-11-14 宏达国际电子股份有限公司 Electronic device, electronic system and method for processing voltage signal of peripheral accessory
CN102780946B (en) * 2011-05-10 2016-08-03 宏达国际电子股份有限公司 The method of the voltage signal of electronic installation, electronic system and process one periphery accessory
CN103197199A (en) * 2012-11-13 2013-07-10 上海华勤通讯技术有限公司 Disconnection detection device and method
CN103197199B (en) * 2012-11-13 2016-01-20 上海华勤通讯技术有限公司 Interrupt detection apparatus and method
CN104092454A (en) * 2014-06-23 2014-10-08 西安电子工程研究所 Key dithering removal method based on logic gate circuit
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
CN106604164A (en) * 2016-04-29 2017-04-26 福建先创电子有限公司 Jitter elimination method and apparatus for key of earphone

Also Published As

Publication number Publication date
CN100442893C (en) 2008-12-10

Similar Documents

Publication Publication Date Title
CN1867133A (en) Method for preventing mobile terminal earphone keystroke mis-operation and mobile terminal
CN1867134A (en) Method for preventing mobile terminal earphone keystroke mis-operation and mobile terminal
US9681241B2 (en) Apparatus, systems and methods for detecting insertion or removal of an audio accessory from an electronic device
CN101917497B (en) Method and device for earphone and USB to share micro-USB interface
CN102223439B (en) Electronic equipment with USB interface and USB communication starting method thereof
CN2819226Y (en) Earphone inserted tester
CN101453510A (en) Earphone recognition apparatus and method for mobile communication terminal
EP3820168A1 (en) Microphone hole blockage detection method and related product
US20100259399A1 (en) Mobile communication device configured to sense external cable
KR20130063131A (en) Method and apparatus for configuring touch sensing parameter
CN105578344A (en) Earphone interface state detecting system and detecting method
CN111510902B (en) Bluetooth device and Bluetooth state switching method and device thereof
CN109713511B (en) Detection circuit, earphone socket, method and mobile terminal
CN101778320A (en) Microphone key-press earphone and state identification method
CN109391869A (en) A kind of earphone and ear canal judge cut-in method
CN217880302U (en) TYPE-C interface circuit
CN206004880U (en) Earphone
EP2770748A1 (en) Apparatus, systems and methods for detecting insertion or removal of an audio accessory from an electronic device
CN101835083B (en) Earphone hangup detection method, device and electron device
CN102928734A (en) Interrupt detecting device and interrupt detecting method
CN101917659A (en) Detection device, method and mobile terminal of earphone circuit
CN104821981A (en) Detection method for earphone operation
CN204464525U (en) The tongue of electric power connector, socket type electronic connector, mobile terminal, plug-type electronic connector and power supply adaptor
CN1808928A (en) Method of receiving mobile phone and network telephone with Blue Teeth earphone
CN203608335U (en) Drive-by-wire device used for earphones and earphones

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