CN109186657A - Proximity sensor parameter calibrating method, device, terminal device and storage medium - Google Patents

Proximity sensor parameter calibrating method, device, terminal device and storage medium Download PDF

Info

Publication number
CN109186657A
CN109186657A CN201811124230.3A CN201811124230A CN109186657A CN 109186657 A CN109186657 A CN 109186657A CN 201811124230 A CN201811124230 A CN 201811124230A CN 109186657 A CN109186657 A CN 109186657A
Authority
CN
China
Prior art keywords
parameter value
calibration parameter
calibration
proximity sensor
value
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
CN201811124230.3A
Other languages
Chinese (zh)
Other versions
CN109186657B (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.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp 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 Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201811124230.3A priority Critical patent/CN109186657B/en
Publication of CN109186657A publication Critical patent/CN109186657A/en
Application granted granted Critical
Publication of CN109186657B publication Critical patent/CN109186657B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01DMEASURING NOT SPECIALLY ADAPTED FOR A SPECIFIC VARIABLE; ARRANGEMENTS FOR MEASURING TWO OR MORE VARIABLES NOT COVERED IN A SINGLE OTHER SUBCLASS; TARIFF METERING APPARATUS; MEASURING OR TESTING NOT OTHERWISE PROVIDED FOR
    • G01D18/00Testing or calibrating apparatus or arrangements provided for in groups G01D1/00 - G01D15/00

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Electronic Switches (AREA)

Abstract

The embodiment of the present application discloses a kind of proximity sensor parameter calibrating method, device, terminal device and storage medium, and this method includes concentrating the supplemental characteristic of the first calibration parameter value write-in Nonvolatile file;When detecting that the second calibration parameter value generates, first calibration parameter value is obtained, and determine whether the difference of first calibration parameter value and second calibration parameter value meets calibration parameter value update condition;If being unsatisfactory for calibration parameter value update condition, first calibration parameter value is determined as the current calibration parameter of proximity sensor, this programme improves the reasonability of proximity sensor parametric calibration, the perfect parametric calibration function of proximity sensor.

Description

Proximity sensor parameter calibrating method, device, terminal device and storage medium
Technical field
The invention relates to computer technology more particularly to a kind of proximity sensor parameter calibrating methods, device, end End equipment and storage medium.
Background technique
With the raising of terminal device popularity, more and more users' using terminal equipment executes various function Can be to meet self-demand, such as using terminal equipment reads text, viewing video, listens to music, plays game, collects in terminal device At various kinds of sensors to carry out function auxiliary, such as acceleration transducer, optical sensor, proximity sensor and camera.
Wherein, proximity sensor setting is square on the screen, is mainly used for the detection of shelter, when terminal device use process In, detecting the presence of the determination SOT state of termination corresponding when shelter is proximity state, and control screen extinguishes, and detects that there is no hide When block material, determine that the SOT state of termination is to control the bright screen of screen far from state, since the control function of proximity sensor is easy by outer The interference for the greasy dirt that boundary's environment and terminal device itself are stained with, therefore need in proximity sensor use process to proximity sensor Parameter is calibrated, and existing calibrating mode existing defects need to improve.
Summary of the invention
This application provides a kind of proximity sensor parameter calibrating method, device, terminal device and storage mediums, improve The reasonability of proximity sensor parametric calibration, the perfect parametric calibration function of proximity sensor.
In a first aspect, the embodiment of the present application provides a kind of proximity sensor parameter calibrating method, comprising:
The supplemental characteristic of first calibration parameter value write-in Nonvolatile file is concentrated;
When detecting that the second calibration parameter value generates, first calibration parameter value is obtained, and determine first school Whether the difference of quasi- parameter value and second calibration parameter value meets calibration parameter value update condition;
If being unsatisfactory for calibration parameter value update condition, first calibration parameter value is determined as proximity sensor and is worked as Preceding calibration parameter.
Second aspect, the embodiment of the present application also provides a kind of proximity sensor parametric calibration devices, comprising:
Reference record module, for concentrating the supplemental characteristic of the first calibration parameter value write-in Nonvolatile file;
Parameter comparison module, for obtaining first calibration parameter value when detecting that the second calibration parameter value generates, And determine whether the difference of first calibration parameter value and second calibration parameter value meets calibration parameter value update condition;
Parameter updating module, if for being unsatisfactory for calibration parameter value update condition, by first calibration parameter value It is determined as the current calibration parameter of proximity sensor.
The third aspect, the embodiment of the present application also provides a kind of terminal devices, comprising: processor, memory and storage On a memory and the computer program that can run on a processor, the processor are realized such as when executing the computer program Proximity sensor parameter calibrating method described in the embodiment of the present application.
Fourth aspect, the embodiment of the present application also provides a kind of storage medium comprising terminal device executable instruction, institutes Terminal device executable instruction is stated when being executed as terminal device processor for executing described in the embodiment of the present application close to biography Sensor parameter calibrating method.
In the present solution, the supplemental characteristic of the first calibration parameter value write-in Nonvolatile file is concentrated;When detecting second When calibration parameter value generates, first calibration parameter value is obtained, and determine first calibration parameter value and second school Whether the difference of quasi- parameter value meets calibration parameter value update condition;If being unsatisfactory for calibration parameter value update condition, by institute It states the first calibration parameter value and is determined as the current calibration parameter of proximity sensor, this programme improves proximity sensor parametric calibration Reasonability, the perfect parametric calibration function of proximity sensor.
Detailed description of the invention
By reading a detailed description of non-restrictive embodiments in the light of the attached drawings below, the application's is other Feature, objects and advantages will become more apparent upon:
Fig. 1 is a kind of flow chart of proximity sensor parameter calibrating method provided by the embodiments of the present application;
Fig. 2 is the flow chart of another proximity sensor parameter calibrating method provided by the embodiments of the present application;
Fig. 3 is the flow chart of another proximity sensor parameter calibrating method provided by the embodiments of the present application;
Fig. 4 is the flow chart of another proximity sensor parameter calibrating method provided by the embodiments of the present application;
Fig. 5 is a kind of structural block diagram of proximity sensor parametric calibration device provided by the embodiments of the present application;
Fig. 6 is a kind of structural schematic diagram of terminal device provided by the embodiments of the present application.
Specific embodiment
The application is described in further detail with reference to the accompanying drawings and examples.It is understood that this place is retouched The specific embodiment stated is for explaining the application, rather than the restriction to the application.It also should be noted that for the ease of retouching It states, part relevant to the application is illustrated only in attached drawing rather than entire infrastructure.
Fig. 1 is a kind of flow chart of proximity sensor parameter calibrating method provided by the embodiments of the present application, is applicable to pair Proximity sensor is calibrated, and this method can be executed by terminal device provided by the embodiments of the present application, the terminal device The mode that software and/or hardware can be used in proximity sensor parametric calibration device is realized, as shown in Figure 1, provided in this embodiment Concrete scheme is as follows:
Step S101, the supplemental characteristic of the first calibration parameter value write-in Nonvolatile file is concentrated.
In one embodiment, the top of terminal device screen is arranged in proximity sensor, can be infrared proximity sensing Device, wherein infrared proximity transducer includes infrared transmitting tube and infrared receiving tube, and infrared transmitting tube is along screen direction, to outgoing Infrared light is penetrated, is converted into electric signal after the infrared light of shelter reflection is received by infrared receiving tube, electric signal is through amplification and mould Number conversion (A/D conversion) processing, is sent to CPU after obtaining the digital signal corresponding to the infrared luminous intensity of reflection, and CPU is according to being somebody's turn to do Digital signal determines whether terminal device is in occlusion state.Above-mentioned function in use, the ring as locating for terminal device The difference in border, under outdoor strong light environment, the infrared light intensity that infrared receiving tube receives at this time is in dark place ring compared with terminal device It is eager to excel when under border, for another example, after terminal device pad pasting or the upper greasy dirt of contamination, the judgement of the occlusion state of proximity sensor can be also deposited In large error, it is therefore desirable to being calibrated close to sensor parameters so that under difficult environmental conditions, proximity sensor Function keeps normal.
Wherein, Nonvolatile file can be NV (nonvolatile, non-volatile) file of terminal device, NV text Content in part not will receive the influences of operations such as terminal device shutdown, total removing and system upgrade and change.First calibration The supplemental characteristic that the initial calibration value that parameter value can be used as proximity sensor parametric calibration is written to Nonvolatile file is concentrated, The parameter data set also may include the calibration parameter of other sensors, which concentrates the first calibration parameter of record to be used for Subsequent calibrations compare.
In one embodiment, when which can be terminal device factory, proximity sensor is carried out Calibrate obtained calibration parameter value.Terminal device when leaving the factory, needs to carry out hardware, software test and proximity sensor ginseng Several calibrations are so that terminal device meets factory and requires.The calibration parameter value obtained when can be by factory calibration is determined as the first calibration Parameter value, illustratively, first calibration parameter value can be 5,6 or 15 etc..
Step S102, when detecting that the second calibration parameter value generates, first calibration parameter value is obtained, and determine institute Whether the difference for stating the first calibration parameter value and second calibration parameter value meets calibration parameter value update condition.
Terminal device will do it the self calibration of proximity sensor parameter in subsequent use process, which can be The self calibration mode that terminal device is internally integrated can also be that third party developer develops and accesses the self calibration function of control Can, by the self calibration of proximity sensor parameter so that the function of proximity sensor keeps normal under any environmental condition.? In one embodiment, proximity sensor parameter is updated use after completing self calibration, and calibration process may be by perhaps More uncontrollable factors influence the parameter after causing to calibrate, and there are relatively large deviations, if being directly updated use, it will cause close The disabler of sensor.
In one embodiment, which can be the included proximity sensor self calibration side of terminal device The calibration parameter value that formula obtains obtains the first calibration parameter value when second calibration parameter value generates, and determines the first calibration Whether the difference of parameter value and the second calibration parameter value meets calibration parameter value update condition, wherein first calibration parameter value It can be stored in the calibration parameter value that the supplemental characteristic of NV file is concentrated, specifically, whether the difference meets calibration parameter value Update condition includes: whether the absolute value of difference is less than or equal to default updated value, which can be 10, the second school Quasi- parameter value can be -30,5,8,10,20 etc..
If step S103, being unsatisfactory for calibration parameter value update condition, first calibration parameter value is determined as connecing The current calibration parameter of nearly sensor.
In one embodiment, when the difference of the second calibration parameter value and the first calibration parameter value determined is discontented Sufficient calibration parameter value update condition then joins the calibration current as proximity sensor of previously stored first calibration parameter value Number, i.e., without the update of calibration parameter value.If meeting calibration parameter value update condition, the second calibration parameter value is determined For the current calibration parameter of proximity sensor, and the second calibration parameter value is stored in supplemental characteristic, the first calibration of replacement is concentrated to join Numerical value, to be compared when being updated for subsequent calibrations parameter value.
As shown in the above, when terminal device generates new calibration parameter, by the school of the calibration parameter value and storage Quasi- parameter value is compared, and the calibration parameter value that original storage is continued to use if being unsatisfactory for update condition carries out approaching biography The calibration of sensor parameter carries out proximity sensor calibration parameter more using new calibration parameter value if meeting update condition Newly, the reasonability of proximity sensor parametric calibration is improved, the perfect parametric calibration function of proximity sensor.
Fig. 2 is the flow chart of another proximity sensor parameter calibrating method provided by the embodiments of the present application, optionally, Detect the second calibration parameter value generate before, further includes: when detecting starting up's event, to close to sensor parameters into Row calibration generates the second calibration parameter value.As shown in Fig. 2, technical solution is specific as follows:
Step S201, the factory calibration for carrying out proximity sensor parameter, determines the first calibration parameter value.
Step S202, the supplemental characteristic of the first calibration parameter value write-in Nonvolatile file is concentrated.
Step S203, when detecting starting up's event, the second calibration is generated to calibration is carried out close to sensor parameters Parameter value.
In one embodiment, when terminal device is converted to open state by off-mode, correspondingly, carrying out approaching biography The calibration of sensor obtains the second calibration parameter value at this time, after which can be each terminal device booting The calibration parameter value that the self calibration for the first time that proximity sensor is completed is obtained.
Step S204, first calibration parameter value is obtained, and determines first calibration parameter value and second school Whether the difference of quasi- parameter value meets calibration parameter value update condition.
Wherein, which can be with the calibration parameter value update condition one in abovementioned steps S102 It causes, details are not described herein again.
If step S205, meeting calibration parameter value update condition, second calibration parameter value is determined as approaching The current calibration parameter of sensor.
Step S206, second calibration parameter value is stored in the supplemental characteristic concentrates replacement first calibration to join Numerical value.
In one embodiment, after the second calibration parameter value meets update condition, correspondingly, calibration parameter concentrate into The first original calibration parameter value is replaced in the replacement of row calibration parameter with the second calibration parameter value.
It can be seen from the above, being carried out during proximity sensor carries out parametric calibration to the parameter value for meeting update condition It updates and is stored in calibration parameter concentration, so that calibration result in the reasonable scope, avoids accidentally calibration or calibration parameter every time The problem of modification proximity sensor calibration parameter bring fails close to arbitration functions when value deviation is excessive.
Fig. 3 is the flow chart of another proximity sensor parameter calibrating method provided by the embodiments of the present application, optionally, After determining the current calibration parameter of proximity sensor, further includes: when detecting that proximity sensor function is opened, to close to passing Sensor parameter carries out calibration and generates third calibration parameter value;The second calibration parameter value that the supplemental characteristic concentrates storage is obtained, It, will if the difference between the calibration parameter value and the third calibration parameter value of storage meets calibration parameter value update condition The third calibration value is determined as the current calibration parameter of proximity sensor, and updates the calibration that the supplemental characteristic concentrates storage Parameter value.As shown in figure 3, technical solution is specific as follows:
Step S301, the factory calibration for carrying out proximity sensor parameter, determines the first calibration parameter value.
Step S302, the supplemental characteristic of the first calibration parameter value write-in Nonvolatile file is concentrated.
Step S303, when detecting starting up's event, the second calibration is generated to calibration is carried out close to sensor parameters Parameter value.
Step S304, first calibration parameter value is obtained, and determines first calibration parameter value and second school Whether the difference of quasi- parameter value meets calibration parameter value update condition.
If step S305, meeting calibration parameter value update condition, second calibration parameter value is determined as approaching The current calibration parameter of sensor.
Step S306, second calibration parameter value is stored in the supplemental characteristic concentrates replacement first calibration to join Numerical value.
Step S307, when detecting that proximity sensor function is opened, the is generated to calibration is carried out close to sensor parameters Three calibration parameter values.
In one embodiment, primary calibration is carried out when proximity sensor is started to work every time or every preset time Generate third calibration parameter value, specific calibrating mode illustratively may is that when detected block when, obtain close to sensing The REAL TIME INFRARED THERMAL IMAGE signal of device acquisition, compares the size of REAL TIME INFRARED THERMAL IMAGE signal and greasy dirt threshold value, when REAL TIME INFRARED THERMAL IMAGE signal is more than or equal to When greasy dirt threshold value, being judged as has greasy dirt and calculates acquisition correction value (such as 50), and the REAL TIME INFRARED THERMAL IMAGE signal value -50 currently acquired is made For third calibration parameter value.
Step S308, the second calibration parameter value that the supplemental characteristic concentrates storage is obtained, if the calibration parameter of storage Difference between value and the third calibration parameter value meets calibration parameter value update condition, then determines the third calibration value For the current calibration parameter of proximity sensor, and update the calibration parameter value that the supplemental characteristic concentrates storage.
It can be seen from the above, calibration parameter value can be generated according to existing calibrating mode in proximity sensor use process, And judges whether the calibration parameter value meets update condition, carry out the update of calibration parameter value if meeting and carry out storage use In subsequent comparison, reduce calibration parameter fluctuating change bring close to the problem of disabler, at the same can iteration update calibration Parameter value, the calibration parameter value for being are updated in certain variation range, improve calibration accuracy.
Fig. 4 is the flow chart of another proximity sensor parameter calibrating method provided by the embodiments of the present application, optionally, Before determining whether second calibration parameter value or the third calibration parameter value meet calibration parameter value update condition, also wrap It includes: determining whether second calibration parameter value or the third calibration parameter value meet calibration parameter value and update comparison condition. As shown in figure 4, technical solution is specific as follows:
Step S401, the factory calibration for carrying out proximity sensor parameter, determines the first calibration parameter value.
Step S402, the supplemental characteristic of the first calibration parameter value write-in Nonvolatile file is concentrated.
Step S403, when detecting starting up's event, the second calibration is generated to calibration is carried out close to sensor parameters Parameter value.
Step S404, judge whether the second calibration parameter value meets calibration parameter value and update comparison condition, if it is, holding Otherwise row step S405 executes step S406.
In one embodiment, before carrying out the second calibration parameter value and the comparison of the first calibration parameter value, first judgement should The no calibration parameter value that meets of second calibration parameter value updates comparison condition, specifically, can be the size of the second calibration parameter value Greater than -20 or less than or equal to 50.
Step S405, first calibration parameter value is obtained, judges first calibration parameter value and second calibration Whether the difference of parameter value meets calibration parameter value update condition, if so, thening follow the steps S407, otherwise, executes step S406。
Step S406, the first calibration parameter value is determined as the current calibration parameter of proximity sensor.
Step S407, second calibration parameter value is determined as the current calibration parameter of proximity sensor.
Step S408, second calibration parameter value is stored in the supplemental characteristic concentrates replacement first calibration to join Numerical value.
Step S409, when detecting that proximity sensor function is opened, the is generated to calibration is carried out close to sensor parameters Three calibration parameter values.
Step S410, judge whether third calibration parameter value meets calibration parameter value and update comparison condition, if it is, holding Otherwise row step S412 executes step S411.
In one embodiment, before carrying out the second calibration parameter value and the comparison of third calibration parameter value, first judgement should The no calibration parameter value that meets of third calibration parameter value updates comparison condition, specifically, can be the size of third calibration parameter value Greater than -20 or less than or equal to 50.
Step S411, the second calibration parameter value is determined as the current calibration parameter of proximity sensor.
Step S412, the second calibration parameter value is obtained, judges the difference of the second calibration parameter value and third calibration parameter value Whether meet calibration parameter value update condition, if so, thening follow the steps S413, otherwise, executes step S411.
Step S413, the third calibration value is determined as the current calibration parameter of proximity sensor, and updates the ginseng The centrally stored calibration parameter value of number data.
It can be seen from the above, joining before carrying out parameter value comparison and determining whether to meet parameter update condition to the second calibration Numerical value and/or third calibration parameter value own value size are judged, the parameter value and parameter for updating comparison condition will be met The parameter value of data centralized recording is compared to determine whether to improve the parameter in this programme using the parameter value newly calibrated The parametric calibration efficiency of calibration program can directly filter out judgement of the ineligible parameter value without update condition, into one Scheme is walked perfect.
Fig. 5 is a kind of structural block diagram of proximity sensor parametric calibration device provided by the embodiments of the present application, which uses In executing proximity sensor parameter calibrating method provided by the above embodiment, has the corresponding functional module of execution method and beneficial Effect.As shown in figure 5, the device specifically includes: reference record module 101, parameter comparison module 102 and parameter updating module 103, wherein
Reference record module 101, for concentrating the supplemental characteristic of the first calibration parameter value write-in Nonvolatile file.
Wherein, Nonvolatile file can be NV (nonvolatile, non-volatile) file of terminal device, NV text Content in part not will receive the influences of operations such as terminal device shutdown, total removing and system upgrade and change.First calibration The supplemental characteristic that the initial calibration value that parameter value can be used as proximity sensor parametric calibration is written to Nonvolatile file is concentrated, The parameter data set also may include the calibration parameter of other sensors, which concentrates the first calibration parameter of record to be used for Subsequent calibrations compare.
In one embodiment, when which can be terminal device factory, proximity sensor is carried out Calibrate obtained calibration parameter value.Terminal device when leaving the factory, needs to carry out hardware, software test and proximity sensor ginseng Several calibrations are so that terminal device meets factory and requires.The calibration parameter value obtained when can be by factory calibration is determined as the first calibration Parameter value, illustratively, first calibration parameter value can be 5,6 or 15 etc..
Parameter comparison module 102, for obtaining first calibration parameter when detecting that the second calibration parameter value generates Value, and determine whether the difference of first calibration parameter value and second calibration parameter value meets calibration parameter value update item Part.
Terminal device will do it the self calibration of proximity sensor parameter in subsequent use process, which can be The self calibration mode that terminal device is internally integrated can also be that third party developer develops and accesses the self calibration function of control Can, by the self calibration of proximity sensor parameter so that the function of proximity sensor keeps normal under any environmental condition.It is existing Have in technology, proximity sensor parameter is updated use after completing self calibration, and calibration process may be by many not Controllable factor influences the parameter after causing to calibrate, and there are relatively large deviations, if being directly updated use, it will cause close sensings The disabler of device.
In one embodiment, which can be the included proximity sensor self calibration side of terminal device The calibration parameter value that formula obtains obtains the first calibration parameter value when second calibration parameter value generates, and determines the first calibration Whether the difference of parameter value and the second calibration parameter value meets calibration parameter value update condition, wherein first calibration parameter value It can be stored in the calibration parameter value that the supplemental characteristic of NV file is concentrated, specifically, whether the difference meets calibration parameter value Update condition includes: whether the absolute value of difference is less than or equal to default updated value, which can be 10, the second school Quasi- parameter value can be -30,5,8,10,20 etc..
Parameter updating module 103, if for being unsatisfactory for calibration parameter value update condition, by first calibration parameter Value is determined as the current calibration parameter of proximity sensor.
In one embodiment, when the difference of the second calibration parameter value and the first calibration parameter value determined is discontented Sufficient calibration parameter value update condition then joins the calibration current as proximity sensor of previously stored first calibration parameter value Number, i.e., without the update of calibration parameter value.If meeting calibration parameter value update condition, the second calibration parameter value is determined For the current calibration parameter of proximity sensor, and the second calibration parameter value is stored in supplemental characteristic, the first calibration of replacement is concentrated to join Numerical value, to be compared when being updated for subsequent calibrations parameter value.
As shown in the above, when terminal device generates new calibration parameter, by the school of the calibration parameter value and storage Quasi- parameter value is compared, and the calibration parameter value that original storage is continued to use if being unsatisfactory for update condition carries out approaching biography The calibration of sensor parameter carries out proximity sensor calibration parameter more using new calibration parameter value if meeting update condition Newly, the reasonability of proximity sensor parametric calibration is improved, the perfect parametric calibration function of proximity sensor.
In a possible embodiment, which further includes calibration module 104, is used for:
Before the parameter data set that the first calibration parameter value is written to Nonvolatile file, proximity sensor is carried out The factory calibration of parameter determines the first calibration parameter value.
In a possible embodiment, the calibration module 104 is also used to:
Before detecting that the second calibration parameter value generates, when detecting starting up's event, proximity sensor is joined Number carries out calibration and generates the second calibration parameter value.
In a possible embodiment, the parameter updating module 103 is specifically used for: if meeting calibration parameter value more Second calibration parameter value is then determined as the current calibration parameter of proximity sensor, and described second is calibrated by New Terms Parameter value is stored in the supplemental characteristic and concentrates replacement first calibration parameter value.
In a possible embodiment, the calibration module 104 is also used to:
After determining the current calibration parameter of proximity sensor, when detecting that proximity sensor function is opened, docking Nearly sensor parameters carry out calibration and generate third calibration parameter value;
The second calibration parameter value that the supplemental characteristic concentrates storage is obtained, if the calibration parameter value of storage and described the Difference between three calibration parameter values meets calibration parameter value update condition, then is determined as the third calibration value to approach sensing The current calibration parameter of device, and update the calibration parameter value that the supplemental characteristic concentrates storage.
In a possible embodiment, the parameter comparison module 102 is also used to:
Determining whether second calibration parameter value or the third calibration parameter value meet calibration parameter value and update item Before part, determine whether second calibration parameter value or the third calibration parameter value meet calibration parameter value and update comparison item Part.
In a possible embodiment, it includes: the difference that whether the difference, which meets calibration parameter value update condition, Absolute value whether be less than or equal to default updated value;It includes: second calibration that the calibration parameter value, which updates comparison condition, Whether parameter value or the third calibration parameter value are greater than or equal to default comparison value.
The present embodiment provides a kind of terminal device on the basis of the various embodiments described above, and Fig. 6 is that the embodiment of the present application mentions The structural schematic diagram of a kind of terminal device supplied, as shown in fig. 6, the terminal device 200 includes: memory 201, processor (Central Processing Unit, CPU) 202, Peripheral Interface 203, RF (Radio Frequency, radio frequency) circuit 205, Voicefrequency circuit 206, power management chip 208, input/output (I/O) subsystem 209, touch screen 212, approaches loudspeaker 211 Sensor 213, other input/control devicess 210 and outside port 204, these components pass through one or more communication bus Or signal wire 207 communicates.
It should be understood that graphic terminal 200 is only an example of terminal device, and terminal device 200 It can have than shown in the drawings more or less component, can combine two or more components, or can be with It is configured with different components.Various parts shown in the drawings can include one or more signal processings and/or dedicated It is realized in the combination of hardware, software or hardware and software including integrated circuit.
Detailed retouch is carried out with regard to the scheme provided in this embodiment calibrated for terminal device proximity sensor below It states, the terminal device is by taking smart phone as an example.
Memory 201, the memory 201 can be accessed by CPU202, Peripheral Interface 203 etc., and the memory 201 can It can also include nonvolatile memory to include high-speed random access memory, such as one or more disk memory, Flush memory device or other volatile solid-state parts.
The peripheral hardware that outputs and inputs of equipment can be connected to CPU202 and deposited by Peripheral Interface 203, the Peripheral Interface 203 Reservoir 201.
I/O subsystem 209, the I/O subsystem 209 can be by the input/output peripherals in equipment, such as touch screen 212 With other input/control devicess 210, it is connected to Peripheral Interface 203.I/O subsystem 209 may include 2091 He of display controller For controlling one or more input controllers 2092 of other input/control devicess 210.Wherein, one or more input controls Device 2092 processed receives electric signal from other input/control devicess 210 or sends electric signal to other input/control devicess 210, Other input/control devicess 210 may include physical button (push button, rocker buttons etc.), dial, slide switch, behaviour Vertical pole clicks idler wheel.It is worth noting that input controller 2092 can with it is following any one connect: keyboard, infrared port, The indicating equipment of USB interface and such as mouse.
Touch screen 212, the touch screen 212 are the input interface and output interface between user terminal and user, can It is shown to user depending on output, visual output may include figure, text, icon, video etc..
Display controller 2091 in I/O subsystem 209 receives electric signal from touch screen 212 or sends out to touch screen 212 Electric signals.Touch screen 212 detects the contact on touch screen, and the contact that display controller 2091 will test is converted to and is shown The interaction of user interface object on touch screen 212, i.e. realization human-computer interaction, the user interface being shown on touch screen 212 Object can be the icon of running game, the icon for being networked to corresponding network etc..It is worth noting that equipment can also include light Mouse, light mouse are the extensions for the touch sensitive surface for not showing the touch sensitive surface visually exported, or formed by touch screen.
RF circuit 205 is mainly used for establishing the communication of mobile phone Yu wireless network (i.e. network side), realizes mobile phone and wireless network The data receiver of network and transmission.Such as transmitting-receiving short message, Email etc..Specifically, RF circuit 205 receives and sends RF letter Number, RF signal is also referred to as electromagnetic signal, and RF circuit 205 converts electrical signals to electromagnetic signal or electromagnetic signal is converted to telecommunications Number, and communicated by the electromagnetic signal with communication network and other equipment.RF circuit 205 may include for executing The known circuit of these functions comprising but it is not limited to antenna system, RF transceiver, one or more amplifiers, tuner, one A or multiple oscillators, digital signal processor, CODEC (COder-DECoder, coder) chipset, user identifier mould Block (Subscriber Identity Module, SIM) etc..
Voicefrequency circuit 206 is mainly used for receiving audio data from Peripheral Interface 203, which is converted to telecommunications Number, and the electric signal is sent to loudspeaker 211.
Loudspeaker 211 is reduced to sound for mobile phone to be passed through RF circuit 205 from the received voice signal of wireless network And the sound is played to user.
Power management chip 208, the hardware for being connected by CPU202, I/O subsystem and Peripheral Interface are powered And power management.
The proximity sensor parametric calibration device and terminal device of the terminal device provided in above-described embodiment are executable originally The proximity sensor parameter calibrating method for applying for terminal device provided by any embodiment has and executes the corresponding function of this method It can module and beneficial effect.The not technical detail of detailed description in the above-described embodiments, reference can be made to the application any embodiment institute The proximity sensor parameter calibrating method of the terminal device of offer.
The embodiment of the present application also provides a kind of storage medium comprising terminal device executable instruction, and the terminal device can It executes instruction when being executed by terminal device processor for executing a kind of proximity sensor parameter calibrating method, this method packet It includes:
The supplemental characteristic of first calibration parameter value write-in Nonvolatile file is concentrated;
When detecting that the second calibration parameter value generates, first calibration parameter value is obtained, and determine first school Whether the difference of quasi- parameter value and second calibration parameter value meets calibration parameter value update condition;
If being unsatisfactory for calibration parameter value update condition, first calibration parameter value is determined as proximity sensor and is worked as Preceding calibration parameter.
In a possible embodiment, in the supplemental characteristic by the first calibration parameter value write-in Nonvolatile file Before collection, further includes:
The factory calibration for carrying out proximity sensor parameter, determines the first calibration parameter value.
In a possible embodiment, before detecting that the second calibration parameter value generates, further includes:
When detecting starting up's event, the second calibration parameter value is generated to calibration is carried out close to sensor parameters.
In a possible embodiment, if meeting calibration parameter value update condition, by second calibration parameter Value is determined as the current calibration parameter of proximity sensor, and second calibration parameter value is stored in the supplemental characteristic and is concentrated Replace first calibration parameter value.
In a possible embodiment, after determining the current calibration parameter of proximity sensor, further includes:
When detecting that proximity sensor function is opened, third calibration parameter is generated to calibration is carried out close to sensor parameters Value;
The second calibration parameter value that the supplemental characteristic concentrates storage is obtained, if the calibration parameter value of storage and described the Difference between three calibration parameter values meets calibration parameter value update condition, then is determined as the third calibration value to approach sensing The current calibration parameter of device, and update the calibration parameter value that the supplemental characteristic concentrates storage.
In a possible embodiment, determining whether are second calibration parameter value or the third calibration parameter value Before meeting calibration parameter value update condition, further includes:
Determine whether second calibration parameter value or the third calibration parameter value meet calibration parameter value and update comparison Condition.
In a possible embodiment, whether the difference meets calibration parameter value update condition and includes:
Whether the absolute value of the difference is less than or equal to default updated value;
The calibration parameter value updates comparison condition
Whether second calibration parameter value or the third calibration parameter value are greater than or equal to default comparison value.
Storage medium --- any various types of memory devices or storage equipment.Term " storage medium " is intended to wrap It includes: install medium, such as CD-ROM, floppy disk or magnetic tape equipment;Computer system memory or random access memory, such as DRAM, DDR RAM, SRAM, EDO RAM, blue Bath (Rambus) RAM etc.;Nonvolatile memory, such as flash memory, magnetic medium (such as hard disk or optical storage);Register or the memory component of other similar types etc..Storage medium can further include other Memory of type or combinations thereof.In addition, storage medium can be located at program in the first computer system being wherein performed, Or can be located in different second computer systems, second computer system is connected to the by network (such as internet) One computer system.Second computer system can provide program instruction to the first computer for executing." storage is situated between term Matter " may include may reside in different location (such as by network connection different computer systems in) two or More storage mediums.Storage medium can store the program instruction that can be performed by one or more processors and (such as implement For computer program).
Certainly, a kind of storage medium comprising computer executable instructions, computer provided by the embodiment of the present application The proximity sensor parameter calibrating method operation that executable instruction is not limited to the described above, can also be performed the application and arbitrarily implements Relevant operation in proximity sensor parameter calibrating method provided by example.
Note that above are only the preferred embodiment and institute's application technology principle of the application.It will be appreciated by those skilled in the art that The application is not limited to specific embodiment described here, be able to carry out for a person skilled in the art it is various it is apparent variation, The protection scope readjusted and substituted without departing from the application.Therefore, although being carried out by above embodiments to the application It is described in further detail, but the application is not limited only to above embodiments, in the case where not departing from the application design, also It may include more other equivalent embodiments, and scope of the present application is determined by the scope of the appended claims.

Claims (10)

1. proximity sensor parameter calibrating method characterized by comprising
The supplemental characteristic of first calibration parameter value write-in Nonvolatile file is concentrated;
When detecting that the second calibration parameter value generates, first calibration parameter value is obtained, and determines the first calibration ginseng Whether the difference of numerical value and second calibration parameter value meets calibration parameter value update condition;
If being unsatisfactory for calibration parameter value update condition, it is current that first calibration parameter value is determined as proximity sensor Calibration parameter.
2. the method according to claim 1, wherein non-volatile text is written in first calibration parameter value described Before the parameter data set of part, further includes:
The factory calibration for carrying out proximity sensor parameter, determines the first calibration parameter value.
3. the method according to claim 1, wherein also being wrapped before detecting that the second calibration parameter value generates It includes:
When detecting starting up's event, the second calibration parameter value is generated to calibration is carried out close to sensor parameters.
4. method according to any one of claim 1-3, which is characterized in that if meeting calibration parameter value updates item Second calibration parameter value is then determined as the current calibration parameter of proximity sensor by part, and by second calibration parameter Value is stored in the supplemental characteristic and concentrates replacement first calibration parameter value.
5. according to claim 4, which is characterized in that after determining the current calibration parameter of proximity sensor, further includes:
When detecting that proximity sensor function is opened, third calibration parameter value is generated to calibration is carried out close to sensor parameters;
The second calibration parameter value that the supplemental characteristic concentrates storage is obtained, if the calibration parameter value of storage and the third school Difference between quasi- parameter value meets calibration parameter value update condition, then the third calibration value is determined as proximity sensor and worked as Preceding calibration parameter, and update the calibration parameter value that the supplemental characteristic concentrates storage.
6. according to the method described in claim 5, it is characterized in that, determining second calibration parameter value or the third school Whether quasi- parameter value meets before calibration parameter value update condition, further includes:
Determine whether second calibration parameter value or the third calibration parameter value meet calibration parameter value and update comparison condition.
7. according to the method described in claim 6, it is characterized in that, whether the difference meets calibration parameter value update condition packet It includes:
Whether the absolute value of the difference is less than or equal to default updated value;
The calibration parameter value updates comparison condition
Whether second calibration parameter value or the third calibration parameter value are greater than or equal to default comparison value.
8. proximity sensor parametric calibration device characterized by comprising
Reference record module, for concentrating the supplemental characteristic of the first calibration parameter value write-in Nonvolatile file;
Parameter comparison module, for when detecting that the second calibration parameter value generates, obtaining first calibration parameter value, and really Whether the difference of fixed first calibration parameter value and second calibration parameter value meets calibration parameter value update condition;
Parameter updating module, if determined first calibration parameter value for being unsatisfactory for calibration parameter value update condition For the current calibration parameter of proximity sensor.
9. a kind of terminal device, comprising: processor, memory and storage are on a memory and the meter that can run on a processor Calculation machine program, which is characterized in that the processor is realized when executing the computer program such as any one of claim 1-7 institute The proximity sensor parameter calibrating method stated.
10. a kind of storage medium comprising terminal device executable instruction, which is characterized in that the terminal device executable instruction When being executed by terminal device processor for executing such as proximity sensor parametric calibration of any of claims 1-7 Method.
CN201811124230.3A 2018-09-26 2018-09-26 Proximity sensor parameter calibration method and device, terminal equipment and storage medium Active CN109186657B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811124230.3A CN109186657B (en) 2018-09-26 2018-09-26 Proximity sensor parameter calibration method and device, terminal equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811124230.3A CN109186657B (en) 2018-09-26 2018-09-26 Proximity sensor parameter calibration method and device, terminal equipment and storage medium

Publications (2)

Publication Number Publication Date
CN109186657A true CN109186657A (en) 2019-01-11
CN109186657B CN109186657B (en) 2022-03-08

Family

ID=64907295

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811124230.3A Active CN109186657B (en) 2018-09-26 2018-09-26 Proximity sensor parameter calibration method and device, terminal equipment and storage medium

Country Status (1)

Country Link
CN (1) CN109186657B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112712184A (en) * 2020-12-28 2021-04-27 浙江中控技术股份有限公司 Parameter maintenance method of equipment instrument and related equipment
CN113491105A (en) * 2019-02-05 2021-10-08 日本电气株式会社 Learning apparatus, learning method, non-transitory computer-readable medium storing control program, and estimation apparatus

Citations (13)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100164479A1 (en) * 2008-12-29 2010-07-01 Motorola, Inc. Portable Electronic Device Having Self-Calibrating Proximity Sensors
EP2237062A1 (en) * 2009-04-01 2010-10-06 ELSAG DATAMAT S.p.A. Proximity sensor for a parking area
CN103197357A (en) * 2013-02-26 2013-07-10 深圳市中兴移动通信有限公司 Infrared proximity detector self-calibration method and device
CN103442136A (en) * 2013-08-19 2013-12-11 惠州Tcl移动通信有限公司 Method and system for dual calibration of proximity sensor
CN105022530A (en) * 2015-08-04 2015-11-04 广东欧珀移动通信有限公司 Calibration method and system for proximity sensor
CN105866781A (en) * 2016-03-24 2016-08-17 联想(北京)有限公司 Data processing method and electronic equipment
CN106791209A (en) * 2017-03-10 2017-05-31 上海传英信息技术有限公司 The self-checking device and method of distance of mobile terminal sensor
CN106973163A (en) * 2017-03-30 2017-07-21 努比亚技术有限公司 The dynamic calibration method and its device of a kind of infrared proximity transducer
WO2017196062A1 (en) * 2016-05-11 2017-11-16 Samsung Electronics Co., Ltd. Distance sensor, and calibration method performed by device and system including the distance sensor
CN107531041A (en) * 2015-05-08 2018-01-02 惠普深蓝有限责任公司 Survey the correction of sensor distance
WO2018002602A1 (en) * 2016-06-27 2018-01-04 Drayson Technologies (Europe) Limited Method and apparatus for sensing and for improving sensor accuracy
CN108279408A (en) * 2018-01-24 2018-07-13 广东欧珀移动通信有限公司 proximity sensor calibration method, device, mobile terminal and computer-readable medium
CN108415024A (en) * 2018-01-24 2018-08-17 广东欧珀移动通信有限公司 proximity sensor calibration method, device, mobile terminal and computer-readable medium

Patent Citations (14)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100164479A1 (en) * 2008-12-29 2010-07-01 Motorola, Inc. Portable Electronic Device Having Self-Calibrating Proximity Sensors
EP2237062A1 (en) * 2009-04-01 2010-10-06 ELSAG DATAMAT S.p.A. Proximity sensor for a parking area
US20100265118A1 (en) * 2009-04-01 2010-10-21 Merli Silvio Sensor for parking area
CN103197357A (en) * 2013-02-26 2013-07-10 深圳市中兴移动通信有限公司 Infrared proximity detector self-calibration method and device
CN103442136A (en) * 2013-08-19 2013-12-11 惠州Tcl移动通信有限公司 Method and system for dual calibration of proximity sensor
CN107531041A (en) * 2015-05-08 2018-01-02 惠普深蓝有限责任公司 Survey the correction of sensor distance
CN105022530A (en) * 2015-08-04 2015-11-04 广东欧珀移动通信有限公司 Calibration method and system for proximity sensor
CN105866781A (en) * 2016-03-24 2016-08-17 联想(北京)有限公司 Data processing method and electronic equipment
WO2017196062A1 (en) * 2016-05-11 2017-11-16 Samsung Electronics Co., Ltd. Distance sensor, and calibration method performed by device and system including the distance sensor
WO2018002602A1 (en) * 2016-06-27 2018-01-04 Drayson Technologies (Europe) Limited Method and apparatus for sensing and for improving sensor accuracy
CN106791209A (en) * 2017-03-10 2017-05-31 上海传英信息技术有限公司 The self-checking device and method of distance of mobile terminal sensor
CN106973163A (en) * 2017-03-30 2017-07-21 努比亚技术有限公司 The dynamic calibration method and its device of a kind of infrared proximity transducer
CN108279408A (en) * 2018-01-24 2018-07-13 广东欧珀移动通信有限公司 proximity sensor calibration method, device, mobile terminal and computer-readable medium
CN108415024A (en) * 2018-01-24 2018-08-17 广东欧珀移动通信有限公司 proximity sensor calibration method, device, mobile terminal and computer-readable medium

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
SHU LIU等: "Face-to-Face Proximity EstimationUsing Bluetooth On Smartphones", 《FACE-TO-FACE PROXIMITY ESTIMATIONUSING BLUETOOTH ON SMARTPHONES》 *
梁锦: "电感式接近传感器故障自诊断的研究", 《传感器技术》 *

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113491105A (en) * 2019-02-05 2021-10-08 日本电气株式会社 Learning apparatus, learning method, non-transitory computer-readable medium storing control program, and estimation apparatus
CN113491105B (en) * 2019-02-05 2023-09-12 日本电气株式会社 Learning device, learning method, non-transitory computer-readable medium storing control program, and estimation device
US11825185B2 (en) 2019-02-05 2023-11-21 Nec Corporation Learning device, learning method, and non transitory computer-readable medium having control program stored thereon, and estimation device
CN112712184A (en) * 2020-12-28 2021-04-27 浙江中控技术股份有限公司 Parameter maintenance method of equipment instrument and related equipment

Also Published As

Publication number Publication date
CN109186657B (en) 2022-03-08

Similar Documents

Publication Publication Date Title
US11907604B2 (en) Screen mirroring display method using layer orders of target controls and electronic device
EP3435199B1 (en) Method, mobile terminal and non-transitory computer-readable storage medium for adjusting scanning frequency of touch screen
CN108897659B (en) Method, device and storage medium for modifying log level
CN111737100A (en) Data acquisition method, device, equipment and storage medium
CN111459466A (en) Code generation method, device, equipment and storage medium
CN111277991A (en) Operator name display method and device, mobile terminal and storage medium
CN109186657A (en) Proximity sensor parameter calibrating method, device, terminal device and storage medium
CN112199246A (en) Terminal testing method and device, storage medium and mobile terminal
CN109344051A (en) Method, apparatus, electronic equipment and the storage medium of data processing
WO2017031647A1 (en) Method and apparatus for detecting touch mode
CN111354378A (en) Voice endpoint detection method, device, equipment and computer storage medium
CN113843814A (en) Control system, method, device and storage medium for mechanical arm equipment
CN110958352B (en) Network signal display method, device, storage medium and mobile terminal
CN113253964A (en) Data management method, device, equipment and storage medium
CN110336918B (en) Bright screen control method and device, storage medium and mobile terminal
CN106293006B (en) Run the method, device and mobile terminal in Magnetic Sensor calibration algorithm library
CN109511103A (en) Thermometry, device, terminal device and storage medium
CN115220699A (en) Software architecture generation method, device, terminal and storage medium based on model development
CN114706135A (en) Magnetic field intensity compensation method and device, storage medium and mobile terminal
CN110221735A (en) Icon processing method, device and mobile terminal
CN104391742A (en) Application optimization method and device
CN114168873A (en) Method and device for processing page popup frame, terminal device and storage medium
CN113438127A (en) Electric vehicle direct current charging communication intelligent test method, device, terminal and storage medium
CN108536345B (en) Application icon processing method, device and mobile terminal
CN111182153A (en) System language setting method and device, storage medium and mobile terminal

Legal Events

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