CN106484141B - The setting method and mobile terminal of threshold value - Google Patents
The setting method and mobile terminal of threshold value Download PDFInfo
- Publication number
- CN106484141B CN106484141B CN201610912412.1A CN201610912412A CN106484141B CN 106484141 B CN106484141 B CN 106484141B CN 201610912412 A CN201610912412 A CN 201610912412A CN 106484141 B CN106484141 B CN 106484141B
- Authority
- CN
- China
- Prior art keywords
- proximity
- proximity values
- threshold value
- values
- close
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
- G06F3/01—Input arrangements or combined input and output arrangements for interaction between user and computer
- G06F3/03—Arrangements for converting the position or the displacement of a member into a coded form
Abstract
The present invention is suitable for field of communication technology, provides the setting method and mobile terminal of a kind of threshold value, and the setting method includes: to obtain the first proximity values that proximity sensor currently acquires when mobile terminal starting;Compare first proximity values and preset second proximity values;When first proximity values are greater than or equal to second proximity values, according to first method be arranged the proximity sensor close to threshold value;When first proximity values are less than second proximity values, according to second method be arranged the proximity sensor close to threshold value.Exception is set close to threshold value caused by the proximity values that the present invention solves the problems, such as that proximity sensor is acquired in mobile terminal starting are larger, effectively improves the detection effect of proximity sensor.
Description
Technical field
The invention belongs to field of communication technology more particularly to the setting methods and mobile terminal of a kind of threshold value.
Background technique
The prior art is before allowing access to sensor, and proximity sensor samples close when needing to be started according to mobile terminal
Value come initialize proximity sensor close to threshold value and far from threshold value.However, when user starts mobile terminal under occlusion
When, the collected proximity values of proximity sensor will be very big, be positioned proximate to according to the proximity values threshold value and far from threshold value have compared with
Big uncertainty is easy to cause proximity sensor to be constantly in reduce the state-detection accuracy of proximity sensor
Proximity state, and then mobile terminal is caused to cannot achieve the functions such as anti-error triggering or closing fingerprint.
Therefore, it is necessary to propose a kind of new technical solution, to solve the above technical problems.
Summary of the invention
In consideration of it, the embodiment of the invention provides a kind of setting method of threshold value and mobile terminal, to solve the prior art
Middle proximity sensor problem abnormal close to threshold value setting caused by proximity values collected are larger when mobile terminal starts,
Improve the state-detection accuracy of proximity sensor.
In a first aspect, providing a kind of setting method of threshold value, the setting method includes:
When mobile terminal starting, the first proximity values that proximity sensor currently acquires are obtained;
Compare first proximity values and preset second proximity values;
It is described close to biography according to first method setting when first proximity values are greater than or equal to second proximity values
Sensor close to threshold value;
When first proximity values are less than second proximity values, the proximity sensor is set according to second method
Close to threshold value.
Further, before obtaining the first proximity values that proximity sensor currently acquires, the setting method further include:
The second proximity values of the proximity sensor are obtained and are arranged, second proximity values are the proximity sensor
Average sample value.
Further, described when first proximity values are greater than or equal to second proximity values, according to first method
The proximity sensor is arranged includes: close to threshold value
When first proximity values are greater than or equal to second proximity values, become according to second proximity values and greasy dirt
Change range initialize the proximity sensor close to threshold value;
Wherein, it is described close to threshold value be the sum of second proximity values and greasy dirt maximum changing value.
Further, the setting method further include:
When according to it is described determine that the mobile terminal is in far from state close to threshold value when, reacquire described close to sensing
The first proximity values that device acquires under the separate state;
First proximity values are saved, and update described approach according to the first proximity values and greasy dirt variation range saved
Sensor close to threshold value;
Wherein, it is described close to threshold value be the sum of first proximity values and greasy dirt maximum changing value.
Further, described when first proximity values are less than second proximity values, according to second method, institute is set
State proximity sensor includes: close to threshold value
When first proximity values are less than second proximity values, first proximity values are saved;
According to the first proximity values and greasy dirt variation range that are saved initialize the proximity sensor close to threshold value;
Wherein, it is described close to threshold value be the sum of first proximity values and greasy dirt maximum changing value.
Second aspect, provides a kind of mobile terminal, and the mobile terminal includes:
First obtains module, for obtaining the first proximity values that proximity sensor currently acquires when mobile terminal starting;
Comparison module, for comparing first proximity values and preset second proximity values;
First setup module is used for when first proximity values are greater than or equal to second proximity values, according to first
Mode be arranged the proximity sensor close to threshold value;
Second setup module, for being set according to second method when first proximity values are less than second proximity values
Set the proximity sensor close to threshold value.
The third aspect, provides a kind of mobile terminal, and the mobile terminal includes:
Processor, for obtaining the first proximity values that proximity sensor currently acquires when mobile terminal starting;Compare institute
State the first proximity values and preset second proximity values;When first proximity values are greater than or equal to second proximity values, press
According to first method be arranged the proximity sensor close to threshold value;When first proximity values are less than second proximity values,
According to second method be arranged the proximity sensor close to threshold value.
Compared with prior art, the embodiment of the present invention when mobile terminal starts, currently adopt by acquisition proximity sensor first
First proximity values of collection;Then first proximity values and preset second proximity values are compared, to judge that mobile terminal-opening opens
Whether proximity state is in when dynamic;When first proximity values are greater than or equal to second proximity values, i.e., at mobile terminal
In proximity state, then according to first method be arranged the proximity sensor close to threshold value;When first proximity values are less than institute
When stating the second proximity values, i.e., in far from state, then according to second method be arranged the proximity sensor close to threshold value;To
Close to threshold value caused by solving proximity sensor in the prior art proximity values collected be larger in mobile terminal starting
Abnormal problem is set, even if starting mobile terminal under occlusion, or proximity sensor setting is conventional to be approached
Threshold value effectively improves the accuracy of the state-detection of proximity sensor.
Detailed description of the invention
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, to embodiment or will show below
There is attached drawing needed in technical description to be briefly described, it should be apparent that, the accompanying drawings in the following description is only this
Some embodiments of invention for those of ordinary skill in the art without creative efforts, can be with
Other accompanying drawings can also be obtained according to these attached drawings.
Fig. 1 is the implementation flow chart of the setting method for the threshold value that first embodiment of the invention provides;
Fig. 2 is the implementation flow chart of step S103 in the setting method for the threshold value that first embodiment of the invention provides;
Fig. 3 is the implementation flow chart of step S104 in the setting method for the threshold value that first embodiment of the invention provides;
Fig. 4 is the schematic block diagram for the mobile terminal that second embodiment of the invention provides;
Fig. 5 is the schematic block diagram for the mobile terminal that third embodiment of the invention provides;
Fig. 6 is the schematic block diagram for the mobile terminal that fourth embodiment of the invention provides.
Specific embodiment
In order to make the objectives, technical solutions, and advantages of the present invention clearer, with reference to the accompanying drawings and embodiments, right
The present invention is further elaborated.It should be appreciated that the specific embodiments described herein are merely illustrative of the present invention, and
It is not used in the restriction present invention.
The embodiment of the present invention obtains the first proximity values that proximity sensor currently acquires when mobile terminal starts first;
Then first proximity values and preset second proximity values are compared, whether to be in close when judging mobile terminal-opening starting
State;When first proximity values be greater than or equal to second proximity values when, i.e., mobile terminal is in proximity state, then according to
First method be arranged the proximity sensor close to threshold value;When first proximity values are less than second proximity values, i.e.,
In far from state, then according to second method be arranged the proximity sensor close to threshold value;To solve in the prior art
Proximity sensor problem abnormal close to threshold value setting caused by proximity values collected are larger when mobile terminal starts, i.e.,
Make to start mobile terminal under occlusion, or proximity sensor setting it is conventional close to threshold value, effectively improve
The accuracy of the state-detection of proximity sensor.The embodiment of the invention also provides corresponding mobile terminals, carry out individually below
Detailed description.
Fig. 1 shows the implementation process of the setting method of the threshold value of first embodiment of the invention offer.
In embodiments of the present invention, the setting method of the threshold value be applied to mobile terminal, the mobile terminal include but
It is not limited to smart phone, tablet computer, learning machine etc..
Refering to fig. 1, the setting method of the threshold value includes:
In step s101, when mobile terminal starts, the first proximity values that proximity sensor currently acquires are obtained.
Herein, the proximity sensor on mobile terminal initializes first in mobile terminal-opening.That is, every
When mobile terminal-opening starting, proximity sensor carries out the acquisition of proximity values.In the prior art, proximity values collected are direct
As proximity sensor close to threshold value and far from the initialization standard of threshold value.Unlike this, the embodiment of the present invention will also be to institute
It states proximity values and is compared judgement.For the ease of narration, the proximity values that proximity sensor acquires are denoted as the first proximity values here.
In step s 102, first proximity values and preset second proximity values are compared.
Herein, the embodiment of the present invention is before step S101, presets and store proximity sensor second connects
Close values.Optionally, second proximity values are the average sample value of proximity sensor.Preferably on a batch of mobile terminal
The average value of proximity values that is acquired in starting up of proximity sensor, by before factory to several mobile terminals into
Row test statistics obtain.Second proximity values, which are used as, judges whether proximity sensor acquires described first under non-occluded state
Whether the standard of proximity values, the first proximity values for measuring step S101 acquisition are effective.Therefore, start in mobile terminal-opening
When, if getting the first proximity values that proximity sensor currently acquires, first proximity values and the second proximity values are carried out
It compares, to judge whether current mobile terminal is blocked.
In step s 103, when first proximity values are greater than or equal to second proximity values, according to first method
Be arranged the proximity sensor close to threshold value.
Herein, it when first proximity values are greater than or equal to second proximity values, indicates under this starting up
Mobile terminal is blocked, and the first proximity values proximity sensor is acquired in the case where being blocked, then root
Threshold value is positioned proximate to according to preset first method.
As a preferable example of the invention, since current proximity sensor first proximity values collected are not
It is acquired when being blocked, i.e., described first proximity values are not virtual values, can direct basis in the first method
Second proximity values come initialize the proximity sensor close to threshold value.Specifically:
According to second proximity values and greasy dirt variation range initialize the proximity sensor close to threshold value, it is described to connect
Nearly threshold value is the sum of second proximity values and greasy dirt maximum changing value.
It is described to be connect close to threshold value as mobile terminal after this booting after completing initialization close to threshold value
Nearly state and the judgment criteria far from state.Since second proximity values are the average sample values of proximity sensor, with described
Second proximity values come initialize proximity sensor close to threshold value, solve proximity sensor in the prior art and opened in mobile terminal
When dynamic due to the proximity values of acquisition it is larger caused by the problem abnormal close to threshold value setting, even if starting moves under occlusion
Dynamic terminal, or proximity sensor setting it is conventional close to threshold value, effectively improve the state-detection of proximity sensor
Accuracy.
As another preferable example of the invention, the proximity sensor is being initialized according to second proximity values
Close to after threshold value, be also based on the separate state that proximity sensor is judged close to threshold value, then again according to
The proximity sensor is arranged based on the first proximity values resurveyed to resurvey the first proximity values in the separate state
Close to threshold value, to further increase the accuracy being arranged close to threshold value.
Fig. 2 shows the specific implementation streams of step S103 in the setting method of the threshold value of first embodiment of the invention offer
Journey.Referring to Fig.2, the step S103 includes:
In step s 201, when first proximity values are greater than or equal to second proximity values, according to described second
Proximity values and greasy dirt variation range initialize the proximity sensor close to threshold value, it is described close to threshold value be described second close
The sum of value and greasy dirt maximum changing value.
In step S202, when according to it is described determine that the mobile terminal is in far from state close to threshold value when, obtain again
The first proximity values for taking the proximity sensor to acquire under the separate state.
In embodiments of the present invention, according to second proximity values be positioned proximate to sensor close to after threshold value, can
To judge that mobile terminal is currently at proximity state or far from state close to threshold value according to described.Judgment method specifically
For the prior art, details are not described herein again, to realize the functions such as anti-error triggering or closing fingerprint.When mobile terminal is located again
When far from state, then the first proximity values that proximity sensor acquires under the separate state are reacquired, and with described heavy
Freshly harvested first proximity values are updated close to threshold value, are obtained really close to threshold value.
In step S203, first proximity values are saved, and change model according to the first proximity values and greasy dirt saved
Enclose update the proximity sensor close to threshold value, it is described close to threshold value be first proximity values and greasy dirt maximum changing value it
With.
Herein, the first proximity values saved in step S203 are collected in the case where mobile terminal is in far from state
, close to threshold value, and by updated judge to move close to threshold value to update proximity sensor with first proximity values
Terminal state in which further improves proximity state and the accuracy far from state-detection, is conducive to improve anti-error triggering
Or close the realization effect of the functions such as fingerprint.
In step S104, when first proximity values are less than second proximity values, institute is set according to second method
State proximity sensor close to threshold value.
Herein, when first proximity values be less than second proximity values when, indicate this starting up be not by
It blocks, first proximity values are effective proximity values, then the proximity sensor is arranged according to preset second method
Close to threshold value.Optionally, second predetermined manner is described close to threshold value according to first proximity values setting.
As another preferable example of the invention, Fig. 3 shows the setting of the threshold value of first embodiment of the invention offer
The specific implementation flow of step S104 in method.
Refering to Fig. 3, the step S104 includes:
In step S301, when first proximity values are less than the second proximity values, first proximity values are saved.
In step s 302, the proximity sensor is initialized according to the first proximity values and greasy dirt variation range saved
Close to threshold value, it is described close to threshold value be the sum of first proximity values and greasy dirt maximum changing value.
Herein, the embodiment of the present invention is less than preset second in first proximity values that proximity sensor acquires and approaches
When value, confirm that the first proximity values proximity sensor acquires under far from state.First proximity values are saved,
And mobile terminal is judged close to threshold value close to threshold value, and by described come initialize proximity sensor with first proximity values
State in which realizes the functions such as anti-error triggering or closing fingerprint.
In conclusion the embodiment of the present invention is when mobile terminal starts, first acquisition proximity sensor currently acquire the
One proximity values;Then first proximity values and preset second proximity values are compared, to be when judging mobile terminal-opening starting
It is no to be in proximity state;When first proximity values are greater than or equal to second proximity values, i.e., mobile terminal is in close
State, then according to first method be arranged the proximity sensor close to threshold value;When first proximity values are less than described second
When proximity values, i.e., in far from state, then according to second method be arranged the proximity sensor close to threshold value;To solve
Proximity sensor is arranged caused by when mobile terminal starts, proximity values collected are larger close to threshold value different in the prior art
Normal problem, even if starting mobile terminal under occlusion, or proximity sensor setting it is conventional close to threshold value, have
Improve to effect the accuracy of the state-detection of proximity sensor.
The schematic block diagram that Fig. 4 shows the mobile terminal of second embodiment of the invention offer is only shown for ease of description
Part related to the embodiment of the present invention is gone out.
In embodiments of the present invention, the mobile terminal is for realizing threshold described in above-mentioned Fig. 1 to Fig. 3 any embodiment
The setting method of value.The mobile terminal includes but is not limited to smart phone, tablet computer etc..Herein, the threshold value refers to
Proximity sensor close to threshold value.
Refering to Fig. 4, the mobile terminal includes:
First obtains module 41, close for when mobile terminal starting, obtaining proximity sensor currently acquires first
Value;
Comparison module 42, for comparing first proximity values and preset second proximity values;
First setup module 43, for when first proximity values are greater than or equal to second proximity values, according to the
One mode be arranged the proximity sensor close to threshold value;
Second setup module 44 is used for when first proximity values are less than second proximity values, according to second method
Be arranged the proximity sensor close to threshold value.
Further, the mobile terminal further include:
Second obtains module 45, and for obtaining and being arranged the second proximity values of the proximity sensor, described second is close
Value is the average sample value of the proximity sensor.
Herein, second proximity values are preferably with the proximity sensor on a batch of mobile terminal in starting up
When the average value of proximity values that acquires, obtained by carrying out test statistics to several mobile terminals before factory.Described
Two proximity values are as judging whether proximity sensor acquires under non-occluded state the standard of first proximity values, for measuring
Whether the first proximity values that the first acquisition module 41 acquires are effective.Therefore, when mobile terminal-opening starts, if getting close
Then first proximity values are compared with the second proximity values for the first proximity values that sensor currently acquires, current to judge
Whether mobile terminal is blocked.
Further, first setup module 43 includes:
First initialization unit 431 is used for when first proximity values are greater than or equal to second proximity values, according to
Second proximity values and greasy dirt variation range initialize the proximity sensor close to threshold value;
Wherein, it is described close to threshold value be the sum of second proximity values and greasy dirt maximum changing value.
When first proximity values are greater than or equal to second proximity values, mobile terminal under this starting up is indicated
It is blocked, the first proximity values proximity sensor is acquired in the case where being blocked, i.e., described first connects
Close values are not virtual values.In the first method, can directly it be initialized according to second proximity values described close to biography
Sensor close to threshold value.The sum of described second proximity values and greasy dirt maximum changing value are set as close to threshold value by described.By institute
The average sample value that the second proximity values are proximity sensors is stated, initializes the close of proximity sensor with second proximity values
Threshold value is solved caused by proximity sensor is larger due to the proximity values of acquisition in mobile terminal starting in the prior art and is connect
The abnormal problem of nearly threshold value setting, even if starting mobile terminal under occlusion, or proximity sensor setting is conventional
Close to threshold value, the accuracy of the state-detection of proximity sensor is effectively promoted.
As another preferable example of the invention, the proximity sensor is being initialized according to second proximity values
Close to after threshold value, be also based on after the proximity state close to threshold value to judge proximity sensor far from state, so
Afterwards in separate state to resurvey the first proximity values, and the proximity sensor is set based on the first proximity values resurveyed
Close to threshold value, to obtain really close to threshold value, further improving the setting accuracy close to threshold value.
First setup module 43 further include:
Acquiring unit 432, for when according to it is described determine that the mobile terminal is in far from state close to threshold value when, again
Obtain the first proximity values that the proximity sensor acquires under the separate state;
Updating unit 433 changes for saving first proximity values, and according to the first proximity values and greasy dirt saved
Range update the proximity sensor close to threshold value;
Wherein, it is described close to threshold value be the sum of first proximity values and greasy dirt maximum changing value.
Further, when first proximity values are less than second proximity values, indicate that this starting up is that do not have
It is blocked, first proximity values are effective proximity values, then are arranged according to preset second method described close to sensing
Device close to threshold value.Optionally, second predetermined manner is described close to threshold value according to first proximity values setting.
As another preferable example of the invention, second setup module 44 includes:
Storage unit 441, for it is close to save described first when first proximity values are less than second proximity values
Value;
Second initialization unit 442, for according to the first proximity values and greasy dirt the variation range initialization saved
Proximity sensor close to threshold value;
Wherein, it is described close to threshold value be the sum of first proximity values and greasy dirt maximum changing value.
It should be noted that the mobile terminal in the embodiment of the present invention can be used to implement it is complete in above method embodiment
The function of portion's technical solution, each functional module can be implemented according to the method in above method embodiment, specific
Realization process can refer to the associated description in examples detailed above, and details are not described herein again.
It is the schematic block diagram for the mobile terminal that third embodiment of the invention provides referring to Fig. 5.The movement as shown in the figure
Terminal may include: one or more processors 501 (one is only shown in figure);One or more input equipments 502 are (in figure only
Show one), one or more output equipments 503 (one is only shown in figure), memory 504.Above-mentioned processor 501, input
Equipment 502, output equipment 503, memory 504 are connected by bus 506.Memory 504 for storing instruction, processor 501
For executing the instruction of the storage of memory 504.Wherein:
The processor 501, it is close for when mobile terminal starting, obtaining proximity sensor currently acquires first
Value;Compare first proximity values and preset second proximity values;It is connect when first proximity values are greater than or equal to described second
When close values, according to first method be arranged the proximity sensor close to threshold value;When first proximity values are less than described second
When proximity values, according to second method be arranged the proximity sensor close to threshold value.
Optionally, the processor 501 is also used to: the second proximity values of the proximity sensor are obtained and are arranged, it is described
Second proximity values are the average sample value of the proximity sensor.
Optionally, the processor 501 is also used to:
When first proximity values are greater than or equal to second proximity values, become according to second proximity values and greasy dirt
Change range initialize the proximity sensor close to threshold value, described close to threshold value is that second proximity values and greasy dirt maximum become
The sum of change value.
Optionally, the processor 501 is also used to:
When according to it is described determine that the mobile terminal is in far from state close to threshold value when, reacquire described close to sensing
The first proximity values that device acquires under the separate state;
First proximity values are saved, and update described approach according to the first proximity values and greasy dirt variation range saved
Sensor close to threshold value, it is described close to threshold value be the sum of first proximity values and greasy dirt maximum changing value.
Optionally, the processor 501 is also used to:
When first proximity values are less than second proximity values, first proximity values are saved;According to what is saved
First proximity values and greasy dirt variation range initialize the proximity sensor close to threshold value;Wherein, it is described close to threshold value be institute
State the sum of the first proximity values and greasy dirt maximum changing value.
It should be appreciated that in embodiments of the present invention, alleged processor 501 can be central processing unit (Central
Processing Unit, CPU) and/or graphics processor (Graphic Processing Unit, GPU), it can also be in this base
Other general processors, digital signal processor (Digital Signal Processor, DSP), dedicated integrated are combined on plinth
Circuit (Application Specific Integrated Circuit, ASIC), ready-made programmable gate array (Field-
Programmable Gate Array, FPGA) either other programmable logic device, discrete gate or transistor logic,
Discrete hardware components etc..
Input equipment 502 may include that Trackpad, fingerprint adopt sensor (for acquiring the finger print information and fingerprint of user
Directional information), microphone, communication module (such as Wi-Fi module, 2G/3G/4G network module), physical button etc..
Output equipment 503 may include display (LCD etc.), loudspeaker etc..Wherein, display can be used for showing by user
The information of input or the information etc. for being supplied to user.Display may include display panel, optionally, can use liquid crystal display
(Liquid Crystal Display, LCD), Organic Light Emitting Diode (Organic Light-Emitting Diode,
) etc. OLED forms configure display panel.Further, above-mentioned touch screen can cover over the display, when touch screen detects
After touch operation on it or nearby, processor 501 is sent to determine the type of touch event, is followed by subsequent processing device 501
Corresponding visual output is provided over the display according to the type of touch event.
In the specific implementation, processor 501 described in the embodiment of the present invention, input equipment 502, output equipment 503, depositing
Implementation described in the embodiment of the setting method of threshold value provided in an embodiment of the present invention can be performed in reservoir 504, herein
It repeats no more.
Fig. 6 is a kind of schematic block diagram for mobile terminal that fourth embodiment of the invention provides, which can use
In the setting method for the threshold value for implementing to provide in above-described embodiment.
As shown in fig. 6, mobile terminal 1200 may include RF (Radio Frequency, radio frequency) circuit 110, include
The memory 120 of one or more (one is only shown in figure) computer readable storage mediums, input unit 130, display
Unit 140, voicefrequency circuit 160, transmission module 170, includes one or more than one and (only shows one in figure sensor 150
It is a) processor 180 of processing core and the equal components of power supply 190.It will be understood by those skilled in the art that shifting shown in Fig. 6
Dynamic 1200 structure of terminal does not constitute the restriction to mobile terminal 1200, may include components more more or fewer than diagram, or
Person combines certain components or different component layouts.Wherein:
RF circuit 110 realizes the mutual conversion of electromagnetic wave and electric signal, thus with logical for receiving and transmitting electromagnetic wave
News network or other equipment are communicated.RF circuit 110 may include various existing for executing the circuit elements of these functions
Part, for example, antenna, RF transceiver, digital signal processor, encryption/deciphering chip, subscriber identity module (SIM) card, storage
Device etc..RF circuit 110 can carry out communicating or by wireless with various networks such as internet, intranet, wireless network
Network is communicated with other equipment.Above-mentioned wireless network may include cellular telephone networks, WLAN or Metropolitan Area Network (MAN).
Various communication standards, agreement and technology, including but not limited to global system for mobile communications can be used in above-mentioned wireless network
(Global System for Mobile Communication, GSM), enhanced mobile communication technology (Enhanced Data
GSM Environment, EDGE), Wideband CDMA Technology (wideband code division multiple
Access, W-CDMA), Code Division Multiple Access (Code division access, CDMA), time division multiple access technology (time
Division multiple access, TDMA), adopting wireless fidelity technology (Wireless, Fidelity, WiFi) (such as U.S.'s electricity
Gas and Electronic Engineering Association standard IEEE 802.11a, IEEE 802.11b, IEEE802.11g and/or IEEE
802.11n), the networking telephone (Voice over internet protocal, VoIP), worldwide interoperability for microwave accesses
(Worldwide Interoperability for Microwave Access, Wi-Max), other be used for mail, Instant Messenger
The agreement and any other suitable communications protocol of news and short message, or even may include that those are not developed currently yet
Agreement.
Memory 120 can be used for storing software program and module, as the corresponding program instruction of method in above-described embodiment/
Module, the software program and module that processor 180 is stored in memory 120 by operation, is answered thereby executing various functions
With and data processing, that is, the second proximity values are set, are connect in mobile terminal starting according to the first proximity values of acquisition and second
The comparison result of close values is initialized close to threshold value.Memory 120 may include high speed random access memory, may also include non-volatile
Memory, such as one or more magnetic storage device, flash memory or other non-volatile solid state memories.In some examples
In, memory 120 can further comprise the memory remotely located relative to processor 180, these remote memories can lead to
Network connection is crossed to mobile terminal 1200.The example of above-mentioned network include but is not limited to internet, intranet, local area network,
Mobile radio communication and combinations thereof.
Input unit 130 can be used for receiving the number or character information of input, and generate and user setting and function
Control related keyboard, mouse, operating stick, optics or trackball signal input.Specifically, input unit 130 may include touching
Sensitive surfaces 131 and other input equipments 132.Touch sensitive surface 131, also referred to as touch display screen or Trackpad are collected and are used
Family on it or nearby touch operation (such as user using any suitable object or attachment such as finger, stylus in touch-sensitive table
Operation on face 131 or near touch sensitive surface 131), and corresponding attachment device is driven according to preset formula.It is optional
, touch sensitive surface 131 may include both touch detecting apparatus and touch controller.Wherein, touch detecting apparatus detection is used
The touch orientation at family, and touch operation bring signal is detected, transmit a signal to touch controller;Touch controller is from touch
Touch information is received in detection device, and is converted into contact coordinate, then gives processor 180, and can receive processor 180
The order sent simultaneously is executed.Furthermore, it is possible to using multiple types such as resistance-type, condenser type, infrared ray and surface acoustic waves
Realize touch sensitive surface 131.In addition to touch sensitive surface 131, input unit 130 can also include other input equipments 132.Specifically,
Other input equipments 132 can include but is not limited to physical keyboard, function key (such as volume control button, switch key etc.),
One of trace ball, mouse, operating stick etc. are a variety of.
Display unit 140 can be used for showing information input by user or the information and mobile terminal that are supplied to user
1200 various graphical user interface, these graphical user interface can be by figure, text, icon, video and any combination thereof
To constitute.Display unit 140 may include display panel 141, optionally, can use LCD (Liquid Crystal
Display, liquid crystal display), the forms such as OLED (Organic Light-Emitting Diode, Organic Light Emitting Diode) come
Configure display panel 141.Further, touch sensitive surface 131 can cover display panel 141, when touch sensitive surface 131 is detected at it
On or near touch operation after, send processor 180 to determine the type of touch event, be followed by subsequent processing device 180 according to touching
The type for touching event provides corresponding visual output on display panel 141.Although in Fig. 6, touch sensitive surface 131 and display surface
Plate 141 is to realize input and input function as two independent components, but in some embodiments it is possible to by touch-sensitive table
Face 131 and display panel 141 integrate and realize and output and input function.
Mobile terminal 1200 may also include at least one sensor 150, for example, optical sensor, motion sensor and other
Sensor.Specifically, optical sensor may include ambient light sensor and proximity sensor, wherein ambient light sensor can basis
The light and shade of ambient light adjusts the brightness of display panel 141, proximity sensor can when mobile terminal 1200 is moved in one's ear,
Close display panel 141 and/or backlight.As a kind of motion sensor, gravity accelerometer can detect all directions
The size of upper (generally three axis) acceleration, can detect that size and the direction of gravity, can be used for detecting tilt angle when static,
And application (such as horizontal/vertical screen switching, dependent game, magnetometer pose calibrating), the Vibration identification correlation function of identification mobile phone posture
Energy (such as pedometer, percussion) etc.;The gyroscope that can also configure as mobile terminal 1200, barometer, hygrometer, thermometer,
The other sensors such as infrared sensor, details are not described herein.
Voicefrequency circuit 160, loudspeaker 161, the audio that microphone 162 can provide between user and mobile terminal 1200 connect
Mouthful.Electric signal after the audio data received conversion can be transferred to loudspeaker 161, by loudspeaker 161 by voicefrequency circuit 160
Be converted to voice signal output;On the other hand, the voice signal of collection is converted to electric signal by microphone 162, by voicefrequency circuit
160 receive after be converted to audio data, then by after the processing of audio data output processor 180, through RF circuit 110 to be sent to ratio
Such as another terminal, or audio data is exported to memory 120 to be further processed.Voicefrequency circuit 160 is also possible that
Earphone jack, to provide the communication of peripheral hardware earphone Yu mobile terminal 1200.
Mobile terminal 1200 can help user send and receive e-mail, is clear by transmission module 170 (such as WiFi module)
Look at webpage and access streaming video etc., it provides wireless broadband internet for user and accesses.Although Fig. 6 shows transmission mould
Block 170, but it is understood that, and it is not belonging to must be configured into for mobile terminal 1200, it is can according to need completely not
Change in the range of the essence of invention and omits.
Processor 180 is the control centre of mobile terminal 1200, utilizes each of various interfaces and connection whole mobile phone
A part by running or execute the software program and/or module that are stored in memory 120, and calls and is stored in storage
Data in device 120 execute the various functions and processing data of mobile terminal 1200, to carry out integral monitoring to mobile phone.It can
Choosing, processor 180 may include one or more processing cores;Preferably, processor 180 can integrate application processor and modulation
Demodulation processor, wherein the main processing operation system of application processor, user interface and application program etc., modulation /demodulation processing
Device mainly handles wireless communication.It is understood that above-mentioned modem processor can not also be integrated into processor 180.
Mobile terminal 1200 further includes the power supply 190 (such as battery) powered to all parts, it is preferred that power supply can lead to
Cross power-supply management system and processor 180 be logically contiguous, thus by power-supply management system realize management charging, electric discharge and
The functions such as power managed.Power supply 190 can also include one or more direct current or AC power source, recharging system, electricity
The random components such as source fault detection circuit, power adapter or inverter, power supply status indicator.
Although being not shown, mobile terminal 1200 can also include camera, bluetooth module etc., and details are not described herein.Specifically
In the present embodiment, the display unit of mobile terminal is touch-screen display, and mobile terminal further includes having memory and one
Perhaps more than one program one of them or more than one program is stored in memory, and be configured to by one or
The execution of more than one processor of person states one or more than one program includes the instruction for performing the following operation:
When mobile terminal starting, the first proximity values that proximity sensor currently acquires are obtained;
Compare first proximity values and preset second proximity values;
It is described close to biography according to first method setting when first proximity values are greater than or equal to second proximity values
Sensor close to threshold value;
When first proximity values are less than second proximity values, the proximity sensor is set according to second method
Close to threshold value.
Assuming that above-mentioned is the first possible embodiment, then provided based on the first possible embodiment
Second of possible embodiment in, in the memory of the mobile terminal, also include instructions for performing the following operations:
Before obtaining the first proximity values that proximity sensor currently acquires, the setting method further include:
The second proximity values of the proximity sensor are obtained and are arranged, second proximity values are the proximity sensor
Average sample value.
In the third the possible embodiment provided based on the first or second of possible embodiment,
Also include instructions for performing the following operations in the memory of the mobile terminal:
It is described when first proximity values be greater than or equal to second proximity values when, according to first method be arranged described in connect
Closely sensor includes: close to threshold value
When first proximity values are greater than or equal to second proximity values, become according to second proximity values and greasy dirt
Change range initialize the proximity sensor close to threshold value;
Wherein, it is described close to threshold value be the sum of second proximity values and greasy dirt maximum changing value.
In the 4th kind of possible embodiment provided based on the third possible embodiment, the movement
Also include instructions for performing the following operations in the memory of terminal:
The setting method further include:
When according to it is described determine that the mobile terminal is in far from state close to threshold value when, reacquire described close to sensing
The first proximity values that device acquires under the separate state;
First proximity values are saved, and update described approach according to the first proximity values and greasy dirt variation range saved
Sensor close to threshold value;
Wherein, it is described close to threshold value be the sum of first proximity values and greasy dirt maximum changing value.
In the 5th kind of possible embodiment provided based on the first or second of possible embodiment,
Also include instructions for performing the following operations in the memory of the mobile terminal:
It is described when first proximity values be less than second proximity values when, according to second method setting it is described close to sensing
Device includes: close to threshold value
When first proximity values are less than second proximity values, first proximity values are saved;
According to the first proximity values and greasy dirt variation range that are saved initialize the proximity sensor close to threshold value;
Wherein, it is described close to threshold value be the sum of first proximity values and greasy dirt maximum changing value.
The embodiment of the present invention obtains the first proximity values that proximity sensor currently acquires when mobile terminal starts first;
Then first proximity values and preset second proximity values are compared, whether to be in close when judging mobile terminal-opening starting
State;When first proximity values be greater than or equal to second proximity values when, i.e., mobile terminal is in proximity state, then according to
First method be arranged the proximity sensor close to threshold value;When first proximity values are less than second proximity values, i.e.,
In far from state, then according to second method be arranged the proximity sensor close to threshold value;To solve in the prior art
Proximity sensor problem abnormal close to threshold value setting caused by proximity values collected are larger when mobile terminal starts, i.e.,
Make to start mobile terminal under occlusion, or proximity sensor setting it is conventional close to threshold value, effectively improve
The accuracy of the state-detection of proximity sensor.
Those of ordinary skill in the art may be aware that list described in conjunction with the examples disclosed in the embodiments of the present disclosure
Member and algorithm steps can be realized with the combination of electronic hardware or computer software and electronic hardware.These functions are actually
It is implemented in hardware or software, the specific application and design constraint depending on technical solution.Professional technician
Each specific application can be used different methods to achieve the described function, but this realization is it is not considered that exceed
The scope of the present invention.
It is apparent to those skilled in the art that for convenience and simplicity of description, the module of foregoing description
It with the specific work process of unit, can refer to corresponding processes in the foregoing method embodiment, details are not described herein.
In several embodiments provided herein, it should be understood that disclosed method and mobile terminal, Ke Yitong
Other modes are crossed to realize.For example, embodiments described above is only schematical, for example, the module, unit are drawn
Point, only a kind of logical function partition, there may be another division manner in actual implementation, such as multiple units or components can
To combine or be desirably integrated into another system, or some features can be ignored or not executed.Another point, it is shown or beg for
The mutual coupling, direct-coupling or communication connection of opinion can be through some interfaces, the INDIRECT COUPLING of module or unit
Or communication connection, it can be electrical property, mechanical or other forms.
The unit as illustrated by the separation member may or may not be physically separated, aobvious as unit
The component shown may or may not be physical unit, it can and it is in one place, or may be distributed over multiple
In network unit.It can select some or all of unit therein according to the actual needs to realize the mesh of this embodiment scheme
's.
In addition, each functional unit in each embodiment of the present invention, module can integrate in one processing unit,
Can be each unit, module physically exists alone, can also be integrated in one unit with two or more units, module
In.
It, can be with if the function is realized in the form of SFU software functional unit and when sold or used as an independent product
It is stored in a computer readable storage medium.Based on this understanding, technical solution of the present invention is substantially in other words
The part of the part that contributes to existing technology or the technical solution can be embodied in the form of software products, the meter
Calculation machine software product is stored in a storage medium, including some instructions are used so that a computer equipment (can be a
People's computer, server or network equipment etc.) it performs all or part of the steps of the method described in the various embodiments of the present invention.
And storage medium above-mentioned includes: that USB flash disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), arbitrary access are deposited
The various media that can store program code such as reservoir (RAM, Random Access Memory), magnetic or disk.
The above description is merely a specific embodiment, but scope of protection of the present invention is not limited thereto, any
Those familiar with the art in the technical scope disclosed by the present invention, can easily think of the change or the replacement, and should all contain
Lid is within protection scope of the present invention.Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.
Claims (9)
1. a kind of setting method of threshold value, which is characterized in that the setting method includes:
When mobile terminal starting, the first proximity values that proximity sensor currently acquires are obtained;
Compare first proximity values and preset second proximity values;
When first proximity values are greater than or equal to second proximity values, the proximity sensor is set according to first method
Close to threshold value;
When first proximity values are less than second proximity values, the close of the proximity sensor is set according to second method
Threshold value;
It is described when first proximity values be greater than or equal to second proximity values when, according to first method setting it is described close to pass
Sensor includes: close to threshold value
When first proximity values are greater than or equal to second proximity values, change model according to second proximity values and greasy dirt
Enclose the initialization proximity sensor close to threshold value, wherein this is that second proximity values and greasy dirt maximum become close to threshold value
The sum of change value;
It is described when first proximity values be less than second proximity values when, according to second method, the proximity sensor is set
Include: close to threshold value
When first proximity values are less than second proximity values, first proximity values are saved;
According to the first proximity values and greasy dirt variation range that are saved initialize the proximity sensor close to threshold value, wherein
This close to threshold value be the sum of first proximity values and greasy dirt maximum changing value;
Wherein, the greasy dirt variation range refers to the proximity values that the proximity sensor acquires when having greasy dirt on mobile terminal screen
With the variation range of the difference of the proximity values of proximity sensor acquisition described when not having greasy dirt on mobile terminal screen, the greasy dirt
Maximum changing value refers to the maximum value in the greasy dirt variation range.
2. the setting method of threshold value as described in claim 1, which is characterized in that in obtain that proximity sensor currently acquires the
Before one proximity values, the setting method further include:
The second proximity values of the proximity sensor are obtained and are arranged, second proximity values are being averaged for the proximity sensor
Sampled value.
3. the setting method of threshold value as described in claim 1, which is characterized in that the setting method further include:
When according to it is described determine that the mobile terminal is in far from state close to threshold value when, reacquire the proximity sensor and exist
The first proximity values acquired under the separate state;
First proximity values are saved, and update the close sensing according to the first proximity values and greasy dirt variation range saved
Device close to threshold value, wherein this close to threshold value be the sum of first proximity values and greasy dirt maximum changing value.
4. a kind of mobile terminal, which is characterized in that the mobile terminal includes:
First obtains module, for obtaining the first proximity values that proximity sensor currently acquires when mobile terminal starting;
Comparison module, for comparing first proximity values and preset second proximity values;
First setup module is used for when first proximity values are greater than or equal to second proximity values, according to first method
Be arranged the proximity sensor close to threshold value;
Second setup module, for institute to be arranged according to second method when first proximity values are less than second proximity values
State proximity sensor close to threshold value;
First setup module includes:
First initialization unit, for when first proximity values are greater than or equal to second proximity values, according to described the
Two proximity values and greasy dirt variation range initialize the proximity sensor close to threshold value, wherein this close to threshold value be described the
The sum of two proximity values and greasy dirt maximum changing value;
Second setup module includes:
Storage unit, for saving first proximity values when first proximity values are less than second proximity values;
Second initialization unit, for described close to sensing according to the first proximity values and greasy dirt the variation range initialization saved
Device close to threshold value, wherein this close to threshold value be the sum of first proximity values and greasy dirt maximum changing value;
Wherein, the greasy dirt variation range refers to the proximity values that the proximity sensor acquires when having greasy dirt on mobile terminal screen
With the variation range of the difference of the proximity values of proximity sensor acquisition described when not having greasy dirt on mobile terminal screen, the greasy dirt
Maximum changing value refers to the maximum value in the greasy dirt variation range.
5. mobile terminal as claimed in claim 4, which is characterized in that the mobile terminal further include:
Second obtains module, and for obtaining and being arranged the second proximity values of the proximity sensor, second proximity values are institute
State the average sample value of proximity sensor.
6. mobile terminal as claimed in claim 4, which is characterized in that first setup module further include:
Acquiring unit, for when according to it is described determine that the mobile terminal is in far from state close to threshold value when, reacquire institute
State the first proximity values that proximity sensor acquires under the separate state;
Updating unit, for saving first proximity values, and more according to the first proximity values and greasy dirt variation range saved
The new proximity sensor close to threshold value, wherein this close to threshold value be first proximity values and greasy dirt maximum changing value it
With.
7. a kind of mobile terminal, which is characterized in that the mobile terminal includes:
Processor, for obtaining the first proximity values that proximity sensor currently acquires when mobile terminal starting;Compare described
One proximity values and preset second proximity values;When first proximity values are greater than or equal to second proximity values, according to the
One mode be arranged the proximity sensor close to threshold value;When first proximity values are less than second proximity values, according to
Second method be arranged the proximity sensor close to threshold value;
The processor is also used to:
When first proximity values are greater than or equal to second proximity values, change model according to second proximity values and greasy dirt
Enclose the initialization proximity sensor close to threshold value, wherein this is that second proximity values and greasy dirt maximum become close to threshold value
The sum of change value;
When first proximity values are less than second proximity values, first proximity values are saved;
According to the first proximity values and greasy dirt variation range that are saved initialize the proximity sensor close to threshold value, wherein
This close to threshold value be the sum of first proximity values and greasy dirt maximum changing value;
Wherein, the greasy dirt variation range refers to the proximity values that the proximity sensor acquires when having greasy dirt on mobile terminal screen
With the variation range of the difference of the proximity values of proximity sensor acquisition described when not having greasy dirt on mobile terminal screen, the greasy dirt
Maximum changing value refers to the maximum value in the greasy dirt variation range.
8. mobile terminal as claimed in claim 7, which is characterized in that the processor is also used to:
The second proximity values of the proximity sensor are obtained and are arranged, second proximity values are being averaged for the proximity sensor
Sampled value.
9. mobile terminal as claimed in claim 7, which is characterized in that the processor is also used to:
When according to it is described determine that the mobile terminal is in far from state close to threshold value when, reacquire the proximity sensor and exist
The first proximity values acquired under the separate state;
First proximity values are saved, and update the close sensing according to the first proximity values and greasy dirt variation range saved
Device close to threshold value, wherein this close to threshold value be the sum of first proximity values and greasy dirt maximum changing value.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610912412.1A CN106484141B (en) | 2016-10-19 | 2016-10-19 | The setting method and mobile terminal of threshold value |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610912412.1A CN106484141B (en) | 2016-10-19 | 2016-10-19 | The setting method and mobile terminal of threshold value |
Publications (2)
Publication Number | Publication Date |
---|---|
CN106484141A CN106484141A (en) | 2017-03-08 |
CN106484141B true CN106484141B (en) | 2019-03-29 |
Family
ID=58270286
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610912412.1A Active CN106484141B (en) | 2016-10-19 | 2016-10-19 | The setting method and mobile terminal of threshold value |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN106484141B (en) |
Families Citing this family (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107291313B (en) * | 2017-07-05 | 2020-10-02 | Oppo广东移动通信有限公司 | Fingerprint awakening control method and device, storage medium and mobile terminal |
WO2019071426A1 (en) * | 2017-10-10 | 2019-04-18 | 深圳市云中飞网络科技有限公司 | Threshold setting method and related product |
CN111625129B (en) * | 2020-05-14 | 2022-09-27 | 维沃移动通信有限公司 | Screen control method and device, electronic equipment and readable storage medium |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102160290A (en) * | 2008-09-19 | 2011-08-17 | 艾勒博科技股份有限公司 | Sensor, sensing method thereof, and filter therefor |
JP2013118565A (en) * | 2011-12-05 | 2013-06-13 | Panasonic Corp | Portable terminal and proximity sensor |
CN103837910A (en) * | 2014-03-20 | 2014-06-04 | 深圳市金立通信设备有限公司 | Method for determining threshold value of proximity sensor and terminal |
-
2016
- 2016-10-19 CN CN201610912412.1A patent/CN106484141B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102160290A (en) * | 2008-09-19 | 2011-08-17 | 艾勒博科技股份有限公司 | Sensor, sensing method thereof, and filter therefor |
JP2013118565A (en) * | 2011-12-05 | 2013-06-13 | Panasonic Corp | Portable terminal and proximity sensor |
CN103837910A (en) * | 2014-03-20 | 2014-06-04 | 深圳市金立通信设备有限公司 | Method for determining threshold value of proximity sensor and terminal |
Also Published As
Publication number | Publication date |
---|---|
CN106484141A (en) | 2017-03-08 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN105306682B (en) | The method and device of network connection switch is automatically closed | |
CN106484555B (en) | The method and mobile terminal of abnormality detection and recovery | |
CN104571787B (en) | A kind of message display method and communication terminal | |
US11023296B2 (en) | Method for managing multiple operating systems in a terminal | |
CN107203147B (en) | Internet of Things network control system based on cloud platform and method | |
CN106453839B (en) | The method of adjustment and mobile terminal of antenna | |
CN105892850B (en) | Open method, device and the mobile terminal of application program for mobile terminal | |
CN104077184B (en) | A kind of course control method and computer system of application program | |
CN106445721B (en) | The method and mobile terminal of house dog fault-tolerant processing | |
CN106101776B (en) | Method, smart machine and the speaker of volume adjustment | |
CN106657566B (en) | The method of adjustment and mobile terminal of physical button | |
US20210132791A1 (en) | Key control method, storage medium, and smart terminal | |
CN106484141B (en) | The setting method and mobile terminal of threshold value | |
CN106817489B (en) | The reminding method and mobile terminal of message | |
CN105807908B (en) | A kind of method and apparatus of switching working mode | |
CN110691168B (en) | Screen control method and device of mobile terminal and storage medium | |
CN106385486B (en) | A kind of control method of proximity sensor, device and mobile terminal | |
CN105100361B (en) | The way of recording and device of mobile terminal | |
CN106500751B (en) | The calibration method and mobile terminal of proximity sensor | |
CN109062643A (en) | A kind of display interface method of adjustment, device and terminal | |
CN111432387B (en) | Many-to-many switching module, multi-machine wireless communication system and communication method thereof | |
CN105282330B (en) | The method and device of automatic connection network | |
CN110062412B (en) | Wireless pairing method, system, storage medium and mobile terminal | |
CN110022600A (en) | Adjusting method, device, storage medium and the mobile terminal of driving current | |
CN109547640A (en) | Mobile terminal WIFI control method, device, mobile terminal and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
CB02 | Change of applicant information | ||
CB02 | Change of applicant information |
Address after: 523860 No. 18, Wu Sha Beach Road, Changan Town, Dongguan, Guangdong Applicant after: OPPO Guangdong Mobile Communications Co., Ltd. Address before: 523841 No. 18, Wu Sha Beach Road, Changan Town, Dongguan, Guangdong Applicant before: Guangdong OPPO Mobile Communications Co., Ltd. |
|
GR01 | Patent grant | ||
GR01 | Patent grant |