CN108760042A - Optical sensor calibration method and device, mobile device, medium and electronic equipment - Google Patents

Optical sensor calibration method and device, mobile device, medium and electronic equipment Download PDF

Info

Publication number
CN108760042A
CN108760042A CN201810525549.0A CN201810525549A CN108760042A CN 108760042 A CN108760042 A CN 108760042A CN 201810525549 A CN201810525549 A CN 201810525549A CN 108760042 A CN108760042 A CN 108760042A
Authority
CN
China
Prior art keywords
optical sensor
value
calibration
reading
correspondence
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
CN201810525549.0A
Other languages
Chinese (zh)
Other versions
CN108760042B (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.)
Netease Hangzhou Network Co Ltd
Original Assignee
Netease Hangzhou Network Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Netease Hangzhou Network Co Ltd filed Critical Netease Hangzhou Network Co Ltd
Priority to CN201810525549.0A priority Critical patent/CN108760042B/en
Publication of CN108760042A publication Critical patent/CN108760042A/en
Application granted granted Critical
Publication of CN108760042B publication Critical patent/CN108760042B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01JMEASUREMENT OF INTENSITY, VELOCITY, SPECTRAL CONTENT, POLARISATION, PHASE OR PULSE CHARACTERISTICS OF INFRARED, VISIBLE OR ULTRAVIOLET LIGHT; COLORIMETRY; RADIATION PYROMETRY
    • G01J1/00Photometry, e.g. photographic exposure meter

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Spectroscopy & Molecular Physics (AREA)
  • Photometry And Measurement Of Optical Pulse Characteristics (AREA)

Abstract

The invention discloses a kind of optical sensor calibration method and device, mobile device, medium and electronic equipments, are related to sensor testing techniques field.The optical sensor calibration method of the disclosure includes:Obtain the current illumination reading of optical sensor;Obtain the correspondence between the test reading of the optical sensor and desired illuminance value;The brightness value after calibration is determined according to current illumination reading and the correspondence.The disclosure can accurately correct the brightness value that optical sensor detects.

Description

Optical sensor calibration method and device, mobile device, medium and electronic equipment
Technical field
This disclosure relates to sensor testing techniques field, in particular to a kind of optical sensor calibration method, light sensing Device calibrating installation, mobile device, storage medium and electronic equipment.
Background technology
With being constantly progressive for science and technology, the application scenarios of sensor have spread in all trades and professions.Wherein, light passes Sensor has application to as the key element for realizing opto-electronic conversion in various photodetector systems such as Tunnel testing, intelligent lighting The fields such as system, vehicle detection.In addition, optical sensor also has been widely used in mobile device (e.g., mobile phone, tablet etc.), For example, optical sensor can detect ambient light, to automatically adjust the bright-dark degree etc. of screen according to testing result.
Currently, the position of different mobile device installation optical sensors is different, the sensitive volume size of optical sensor is not yet Together.Therefore, the actual read number of optical sensor may be inaccurate, and it is poor that the result that can be provided with manufacturer because of above-mentioned factor exists It is different.
It should be noted that information is only used for reinforcing the reason to the background of the disclosure disclosed in above-mentioned background technology part Solution, therefore may include the information not constituted to the prior art known to persons of ordinary skill in the art.
Invention content
The disclosure is designed to provide a kind of optical sensor calibration method, optical sensor calibrating installation, mobile device, deposits Storage media and electronic equipment, and then the light caused by the limitation and defect of the relevant technologies is overcome to pass at least to a certain extent The problem of sensor actual read number inaccuracy.
According to one aspect of the disclosure, a kind of optical sensor calibration method is provided, including:Obtain the current of optical sensor Illumination reading;Obtain the correspondence between the test reading of the optical sensor and desired illuminance value;According to the current photograph Degree reading and the correspondence determine the brightness value after calibration.
In a kind of exemplary embodiment of the disclosure, the optical sensor calibration method further includes:The light is obtained to pass Multiple test readings of the sensor under the different illuminance of testing light source;Utilize the multiple test reading and the different illumination The desired illuminance value structure calibration line chart of degree;Wherein, using the corresponding piecewise function of the calibration line chart as the correspondence Relationship.
In a kind of exemplary embodiment of the disclosure, the testing light source is the light source that can set brightness value, will be set Brightness value as the desired illuminance value;Or the reading under use illumination instrument read test light source difference illuminance, as The desired illuminance value.
In a kind of exemplary embodiment of the disclosure, school is determined according to current illumination reading and the correspondence Brightness value after standard includes:If the current illumination reading only corresponds to a desired illuminance value in the correspondence, Using an only corresponding desired illuminance value in the correspondence as the brightness value after calibration;If the current illumination reading Limited a desired illuminance value in addition to one is corresponded in the correspondence, then by the flat of limited a desired illuminance value Mean value is as the brightness value after calibration;If the current illumination reading corresponds to numerous desired illuminance in the correspondence Value, then using the average value of maxima and minima in the numerous desired illuminance value as the brightness value after calibration.
In a kind of exemplary embodiment of the disclosure, the optical sensor calibration method further includes:Calculate the segmentation The error of function;Using calculated error as the precision references of the brightness value after being calibrated to current illumination reading.
In a kind of exemplary embodiment of the disclosure, the error for calculating the piecewise function includes:To piecewise function with The absolute value of the difference of desired illuminance function is integrated, to obtain first integral result;Desired illuminance function is integrated, To obtain second integral result;Using the ratio of the first integral result and the second integral result as the piecewise function Error.
According to one aspect of the disclosure, a kind of optical sensor calibrating installation is provided, including:Current illumination acquisition module, Current illumination for obtaining optical sensor is read;Correspondence acquisition module, the test for obtaining the optical sensor are read Correspondence between number and desired illuminance value;Determining module is calibrated, for according to current illumination reading and the correspondence Relationship determines the brightness value after calibration.
In a kind of exemplary embodiment of the disclosure, optical sensor calibrating installation further includes:Test reads acquisition module, For obtaining multiple test readings of the optical sensor under the different illuminance of testing light source;Line chart builds module, uses In the desired illuminance value structure calibration line chart using the multiple test reading and the different illuminance;It wherein, will be described The corresponding piecewise function of line chart is calibrated as the correspondence.
In a kind of exemplary embodiment of the disclosure, the testing light source is the light source that can set brightness value, will be set Brightness value as the desired illuminance value;Or the reading under use illumination instrument read test light source difference illuminance, as The desired illuminance value.
In a kind of exemplary embodiment of the disclosure, calibration determining module includes:First computing unit, if being used for institute It states current illumination reading and only corresponds to a desired illuminance value in the correspondence, then it will be only corresponding in the correspondence One desired illuminance value is as the brightness value after calibration;Second computing unit, if read described for the current illumination Limited a desired illuminance value in addition to one is corresponded in correspondence, then is made the average value of limited a desired illuminance value For the brightness value after calibration;Third computing unit, if corresponding to nothing in the correspondence for current illumination reading Several desired illuminance values, then using the average value of maxima and minima in the numerous desired illuminance value as the photograph after calibration Angle value.
In a kind of exemplary embodiment of the disclosure, optical sensor calibrating installation further includes:Error calculating module is used for Calculate the error of the piecewise function;Error application module, for being read using calculated error as to the current illumination The precision references of brightness value after being calibrated.
In a kind of exemplary embodiment of the disclosure, error calculating module includes:First integral result obtaining unit is used It is integrated in piecewise function and the absolute value of the difference of desired illuminance function, to obtain first integral result;Second integral As a result obtaining unit, for being integrated to desired illuminance function, to obtain second integral result;Error calculation unit is used for Using the ratio of the first integral result and the second integral result as the error of the piecewise function.
According to one aspect of the disclosure, a kind of mobile device is provided, including optical sensor, the mobile device includes upper State the optical sensor calibrating installation described in any one.
According to one aspect of the disclosure, a kind of storage medium is provided, computer program, the computer are stored thereon with The optical sensor calibration method described in above-mentioned any one is realized when program is executed by processor.
According to one aspect of the disclosure, a kind of electronic equipment is provided, including:Processor;And memory, for storing The executable instruction of the processor;Wherein, the processor is configured to above-mentioned to execute via the executable instruction is executed Optical sensor calibration method described in any one.
In the technical solution that some embodiments of the present disclosure are provided, by between test reading and desired illuminance value Correspondence determines the brightness value after being calibrated to current illumination reading, on the one hand, the disclosure can accurately correct light The brightness value that sensor detects;On the other hand, type and principle, the operating system of mobile device of the disclosure to optical sensor And other test environments, there is no limit condition, the process versatility of optical sensor calibration is stronger;In another aspect, in test process In, without will be taken out in optical sensor slave mobile device, without by means of any other extras.
It should be understood that above general description and following detailed description is only exemplary and explanatory, not The disclosure can be limited.
Description of the drawings
The drawings herein are incorporated into the specification and forms part of this specification, and shows the implementation for meeting the disclosure Example, and together with specification for explaining the principles of this disclosure.It should be evident that the accompanying drawings in the following description is only the disclosure Some embodiments for those of ordinary skill in the art without creative efforts, can also basis These attached drawings obtain other attached drawings.In the accompanying drawings:
Fig. 1 diagrammatically illustrates the flow chart of optical sensor calibration method according to an exemplary embodiment of the present disclosure;
Fig. 2 shows the schematic diagrames that optical sensor receives illumination;
Fig. 3 diagrammatically illustrates building using test reading and desired illuminance value for the illustrative embodiments of the disclosure Calibrate line chart;
Fig. 4 diagrammatically illustrate the illustrative embodiments of the disclosure it is a kind of in the case of calibration after brightness value really Determine mode;
Fig. 5 diagrammatically illustrates the brightness value after the calibration in another case of the illustrative embodiments of the disclosure Method of determination;
Fig. 6 diagrammatically illustrate with disclosed illustrative embodiments another in the case of calibration after brightness value Method of determination;
Fig. 7 diagrammatically illustrates the comparison diagram of calibration line chart and desired illuminance value;
Fig. 8 diagrammatically illustrates the block diagram of optical sensor calibrating installation according to an exemplary embodiment of the present disclosure;
Fig. 9 diagrammatically illustrates the box of another optical sensor calibrating installation according to an exemplary embodiment of the present disclosure Figure;
Figure 10 diagrammatically illustrates the block diagram of calibration determining module according to an exemplary embodiment of the present disclosure;
Figure 11 diagrammatically illustrates the side of another optical sensor calibrating installation according to an exemplary embodiment of the present disclosure Block diagram;
Figure 12 diagrammatically illustrates the block diagram of error calculating module according to an exemplary embodiment of the present disclosure;
Figure 13 shows the schematic diagram of storage medium according to an exemplary embodiment of the present disclosure;And
Figure 14 diagrammatically illustrates the block diagram of electronic equipment according to an exemplary embodiment of the present disclosure.
Specific implementation mode
Example embodiment is described more fully with reference to the drawings.However, example embodiment can be with a variety of shapes Formula is implemented, and is not understood as limited to example set forth herein;On the contrary, thesing embodiments are provided so that the disclosure will more Fully and completely, and by the design of example embodiment comprehensively it is communicated to those skilled in the art.Described feature, knot Structure or characteristic can be in any suitable manner incorporated in one or more embodiments.In the following description, it provides perhaps More details fully understand embodiment of the present disclosure to provide.It will be appreciated, however, by one skilled in the art that can It is omitted with technical solution of the disclosure one or more in the specific detail, or others side may be used Method, constituent element, device, step etc..In other cases, be not shown in detail or describe known solution to avoid a presumptuous guest usurps the role of the host and So that all aspects of this disclosure thicken.
In addition, attached drawing is only the schematic illustrations of the disclosure, it is not necessarily drawn to scale.Identical attached drawing mark in figure Note indicates same or similar part, thus will omit repetition thereof.Some block diagrams shown in attached drawing are work( Energy entity, not necessarily must be corresponding with physically or logically independent entity.Software form may be used to realize these work( Energy entity, or these functional entitys are realized in one or more hardware modules or integrated circuit, or at heterogeneous networks and/or place These functional entitys are realized in reason device device and/or microcontroller device.
Flow chart shown in attached drawing is merely illustrative, it is not necessary to including all steps.For example, the step of having It can also decompose, and the step of having can merge or part merges, therefore the sequence actually executed is possible to according to actual conditions Change.
It is currently, there are some schemes that calibration and error testing are carried out to optical sensor.For example, in some technologies, light passes Sensor receives the illumination with reference to maximum brightness value, and practical light value is obtained according to illumination;In the microprocessor for reading optical sensor Practical calibration factor and acquisition practical light value, between practical calibration factor and practical light value ratio be constant;According to It needs the ratio of the target light value demarcated and practical calibration factor and practical light value to recalculate and obtains the target designation factor; By the target designation factor be written optical sensor microprocessor in, by the target designation factor that will be obtained be used as optical sensor this Afterwards in calibration factor used write-in optical sensor, hereafter optical sensor measures light quantity and is all demarcated by the target designation factor, realizes Calibration to optical sensor.However, this optical sensor calibration, only with the illumination of maximum brightness value, calibration effect is not It is good.
In other technologies, the method for calibration of optical sensor may include:Optical sensor is obtained within preset time period The light source data sensed from standard sources is filtered the light source data using preset filtering rule, obtains target light Source data calibrates optical sensor according to the target light source data.However, this scheme solves only the light source of calibration There are problems that abnormal data.
In consideration of it, present disclose provides following optical sensor calibration methods.In addition, though the optical sensor of disclosure description Applied in mobile device, however, it is understood that the optical sensor calibration method described in the disclosure is also applicable to and removes In other scenes except mobile device.
Fig. 1 diagrammatically illustrates the flow chart of the optical sensor calibration method of the illustrative embodiments of the disclosure.With reference to Fig. 1, the optical sensor calibration method may comprise steps of:
S12. the current illumination reading of optical sensor is obtained.
By taking mobile device is mobile phone as an example, optical sensor can usually be installed in the top of mobile device, however, unlimited In this, optical sensor can be configured in any position of mobile device.Furthermore it is possible to be opened optical sensor using a control It opens and closing is controlled, for example, user can be in mobile device and the unlatching to optical sensor on the relevant interface of setting It is configured with closing.
After detecting current illumination in optical sensor, first, optical sensor can be by the illumination reading of detection (that is, inspection The brightness value of survey) it is sent in a storage unit, wherein the storage unit can be individually used for the text of storage sensor reading Part can also be the unit of other users storage data.Then, the processor of mobile device can be obtained from the storage unit The current illumination of optical sensor is read.
In addition, after optical sensor detects current illumination, can current illumination reading be directly sent to mobile device Processor.
S14. the correspondence between the test reading of the optical sensor and desired illuminance value is obtained.
Test reading can be the group number-reading tested in advance optical sensor.In addition, desired illuminance value and test Reading corresponds to, and desired illuminance value can be interpreted as to the actual value of illumination.Specifically, in some embodiments of the present disclosure, it can Using using the light source of brightness value can be set as testing light source, in such a case, it is possible to using the brightness value of setting as ideal Brightness value.In other embodiments of the disclosure, testing light source can not be the light source that can set brightness value, in such case Under, an illumination instrument may be used and read reading under the testing light source difference illuminance, and regard these readings as desired illuminance Value.
In order to ensure the accuracy of calibration, the testing light source described in the disclosure can be parallel light source.That is, can The photosurface of the optical sensor of mobile device to be placed towards parallel light source.With reference to figure 2, test light can be quick in figure It is photosensitive, wherein sensitive light can be pointing directly toward the illumination of optical sensor.In addition, so it is easy to understand that described in Fig. 2 not Sensitive light can not be detected by optical sensor or is seldom detected.
In the illustrative embodiments of the disclosure, when being tested optical sensor using testing light source, on the one hand, The processor of mobile device can obtain desired illuminance value when test;On the other hand, the processor of mobile device can obtain The test reading of optical sensor.By taking 6.0 systems of Android as an example, the reading and relevant information of optical sensor can be stored in It is specific as shown in table 1 in android.hardware.SensorEvent:
Table 1
Wherein, timestamp is timestamp, and values [0] is the illumination of ambient light, and unit is lux (Lux or Lx).
The test of N groups can be carried out to optical sensor, wherein N may be greater than 1 positive integer.The test of N groups can be obtained to read Number and corresponding desired illuminance.It will be illustrated by taking N=6 as an example below.Specifically, 6 groups of data of record are as shown in table 2:
Table 2
Desired illuminance value L1 L2 L3 L4 L5 L6
Test reading D1 D2 D3 D4 D5 D6
Next, the data structure calibration line chart in table 2 can be utilized, specifically, line chart is as shown in Figure 3.In addition, The corresponding piecewise function of line chart can will be calibrated as the correspondence between test reading and desired illuminance value.Piecewise function Can be designated as formula 1:
It is easily understood that mobile device can preserve the total data in formula 1, that is, a1、a2、…、aN;b1、b2、…、 bN;L1、L2、…、LN.Correspondence can will be obtained to be interpreted as obtaining these data.
In addition, the correspondence between the test reading and desired illuminance value of acquisition optical sensor can also include directly will Test reading is saved in corresponding desired illuminance value in a tables of data.It is especially small-pitch in test illumination, it can By directly by tabling look-up in a manner of determine relationship between the reading and actual read number that optical sensor is shown.
S16. the brightness value after calibration is determined according to current illumination reading and the correspondence.
In the illustrative embodiments of the disclosure, after can determining current illumination reading calibration using above-mentioned formula 1 Brightness value.
According to some embodiments of the present disclosure, in the case of getting current illumination reading in step s 12, by using Above-mentioned formula 1 solves equation, if only there are one solutions, using the solution as the brightness value after calibrating.For example, with reference to Fig. 4, current illumination reading are 15 luxs, at this point, only there are one solutions for formula 1.
According to other embodiment, in the case of getting current illumination reading in step s 12, by using above-mentioned Formula 1 solves equation, if there is the limited solution in addition to one, then can make the average value of limited solution For the brightness value after calibration.Specifically, when equation has multiple solution x1、x2、…、xNWhen, the brightness value after calibration can be expressed as:
For example, with reference to figure 5, for there are two solutions, current illumination reading is 15 luxs, at this point, the photograph after calibration Angle value is the average value of two solutions.
According to other embodiment, in the case of getting current illumination reading in step s 12, by using above-mentioned Formula 1 solves equation, if there is numerous desired illuminance value, then by maximum value in numerous desired illuminance value xmaxWith minimum value xminAverage value as calibration after brightness value.In this case, the brightness value after calibration can indicate For:
For example, with reference to figure 6, current illumination reading is 30 luxs, and 30 luxs correspond to the line chart of formula 1 in 30 Le There are numerous solutions between 40 luxs by Ke Si, and therefore, in this case, the brightness value after calibration is 35 luxs.
Pass through above-mentioned calibration process, on the one hand, the disclosure can accurately correct the illumination that optical sensor detects Value;On the other hand, the disclosure there is not the type of optical sensor with principle, the operating system of mobile device and other test environments The process versatility of restricted condition, optical sensor calibration is stronger;In another aspect, during the test, being not necessarily to optical sensor It is taken out in slave mobile device, without by means of any other extras.
In the illustrative embodiments of the disclosure, the disclosure further includes the scheme of optical sensor error calculation.Specifically, Error can be calculated according to test result, more specifically, optical sensor error can be counted using above-mentioned formula 1 It calculates.
With reference to figure 7, record a demerit what the absolute value of piecewise function f (x) and the difference of desired illuminance function y=x integrated Divided by the integral result of desired illuminance function is as error.
Specifically, on the one hand, the absolute value of the difference of f (x) and y=x can be integrated, to obtain first integral knot Fruit Cd, reference formula 2, first integral result CdIt can be expressed as:
On the other hand, desired illuminance function can be integrated, to obtain second integral result Ci, reference formula 3, the Two integral result CiIt can be expressed as:
It is then possible to by first integral result CdWith second integral result CiError D of the ratio as piecewise function, With regard to the error of optical sensor.Wherein, error D can be expressed as formula 4:
After determining error, the precision of the brightness value after being calibrated error as current illumination reading is joined It examines.Specifically, the brightness value after the calculated calibrations of step S16 is Xm, it is D using 4 calculated error of formulam, then after calibrating Final result can be expressed as Xm±Dm, for example, the brightness value after calculated calibration is 100, it is calculated using formula 4 Error is 5, then the final result after calibrating can be expressed as 100 ± 5.
It should be noted that the brightness value after calibration can be directly applied to other processing scenes.For example, automatic adjustment Screen intensity etc..The disclosure does not do the brightness value output application after calibration specifically limited.
It should be noted that although describing each step of method in the disclosure with particular order in the accompanying drawings, this is simultaneously Undesired or hint must execute these steps according to the particular order, or have to carry out the step ability shown in whole Realize desired result.Additional or alternative, it is convenient to omit multiple steps are merged into a step and executed by certain steps, And/or a step is decomposed into execution of multiple steps etc..
Further, a kind of optical sensor calibrating installation is additionally provided in this example embodiment, which can be with Applied in mobile device.
Fig. 8 diagrammatically illustrates the block diagram of the optical sensor calibrating installation of the illustrative embodiments of the disclosure.With reference to Fig. 8, optical sensor calibrating installation 8 according to an exemplary embodiment of the present disclosure may include current illumination acquisition module 81, Correspondence acquisition module 83 and calibration determining module 85.
Specifically, current illumination acquisition module 81 can be used for obtaining the current illumination reading of optical sensor;Correspondence Acquisition module 83 can be used for obtaining the correspondence between the test reading and desired illuminance value of optical sensor;Calibration determines mould Block 85 can be used for determining the brightness value after calibration according to current illumination reading and correspondence.
In the optical sensor calibrating installation that some embodiments of the present disclosure are provided, on the one hand, the disclosure can be calibrated Really correct the brightness value that optical sensor detects;On the other hand, type and principle, mobile device of the disclosure to optical sensor Operating system and other test environments there is no limit condition, the process versatility of optical sensor calibration is stronger;In another aspect, During the test, without will be taken out in optical sensor slave mobile device, without by means of any other extras.
According to an exemplary embodiment of the present disclosure, with reference to figure 9, optical sensor calibrating installation 9 is calibrated compared to optical sensor Device 8 may be used also in addition to it may include current illumination acquisition module 81, correspondence acquisition module 83 and calibration determining module 85 To include that test reading acquisition module 91 and line chart build module 93.
Specifically, test, which reads acquisition module 91, can be used for obtaining optical sensor under the different illuminance of testing light source Multiple test readings;Line chart structure module 93 can be used for the desired illuminance using multiple test readings and different illuminance Value structure calibration line chart;Wherein, the corresponding piecewise function of line chart will be calibrated as correspondence.
According to an exemplary embodiment of the present disclosure, testing light source is the light source that can set brightness value, by the brightness value of setting As desired illuminance value;Or using the reading under illumination instrument read test light source difference illuminance, as desired illuminance value.
According to an exemplary embodiment of the present disclosure, with reference to figure 10, calibration determining module 85 may include the first computing unit 101, the second computing unit 103 and third computing unit 105.
Specifically, if the first computing unit 101 can be used for current illumination reading only corresponds to one in correspondence Desired illuminance value, then using an only corresponding desired illuminance value in correspondence as the brightness value after calibration;Second calculates list If member 103 can be used for current illumination reading corresponding limited a desired illuminance value in addition to one in correspondence, Using the average value of limited a desired illuminance value as the brightness value after calibration;If third computing unit 105 can be used for currently Illumination reading corresponds to numerous desired illuminance value in correspondence, then by maxima and minima in numerous desired illuminance value Average value as calibration after brightness value.
According to an exemplary embodiment of the present disclosure, with reference to figure 11, optical sensor calibrating installation 9 is calibrated compared to optical sensor Device 8 may be used also in addition to it may include current illumination acquisition module 81, correspondence acquisition module 83 and calibration determining module 85 To include error calculating module 111 and error application module 113.
Specifically, error calculating module 111 can be used for calculating the error of piecewise function;Error application module 113 can be with For using calculated error as the precision references of the brightness value after being calibrated to current illumination reading.
According to an exemplary embodiment of the present disclosure, with reference to figure 12, error calculating module 111 may include first integral result Obtaining unit 1201, second integral result obtaining unit 1203 and error calculation unit 1205.
Specifically, first integral result obtaining unit 1201 can be used for the difference to piecewise function and desired illuminance function Absolute value integrated, to obtain first integral result;Second integral result obtaining unit 1203 can be used for shining ideal Degree function is integrated, to obtain second integral result;Error calculation unit 1205 can be used for first integral result and institute State error of the ratio as piecewise function of second integral result.
Since each function module of the program analysis of running performance device of embodiment of the present invention is invented with the above method It is identical in embodiment, therefore details are not described herein.
Further, a kind of mobile device including optical sensor is additionally provided in this example embodiment.The movement is set Standby may include any optical sensor calibrating installation described above.
In an exemplary embodiment of the disclosure, a kind of computer readable storage medium is additionally provided, energy is stored thereon with Enough realize the program product of this specification above method.In some possible embodiments, various aspects of the invention may be used also In the form of being embodied as a kind of program product comprising program code, when described program product is run on the terminal device, institute State program code for make the terminal device execute described in above-mentioned " illustrative methods " part of this specification according to this hair The step of bright various illustrative embodiments.
With reference to shown in figure 13, the program product for realizing the above method according to the embodiment of the present invention is described 1300, portable compact disc read only memory (CD-ROM) may be used and include program code, and can in terminal device, Such as it is run on PC.However, the program product of the present invention is without being limited thereto, in this document, readable storage medium storing program for executing can be with To be any include or the tangible medium of storage program, the program can be commanded execution system, device either device use or It is in connection.
The arbitrary combination of one or more readable mediums may be used in described program product.Readable medium can be readable letter Number medium or readable storage medium storing program for executing.Readable storage medium storing program for executing for example can be but be not limited to electricity, magnetic, optical, electromagnetic, infrared ray or System, device or the device of semiconductor, or the arbitrary above combination.The more specific example of readable storage medium storing program for executing is (non exhaustive List) include:It is electrical connection, portable disc, hard disk, random access memory (RAM) with one or more conducting wires, read-only Memory (ROM), erasable programmable read only memory (EPROM or flash memory), optical fiber, portable compact disc read only memory (CD-ROM), light storage device, magnetic memory device or above-mentioned any appropriate combination.
Computer-readable signal media may include in a base band or as the data-signal that a carrier wave part is propagated, In carry readable program code.The data-signal of this propagation may be used diversified forms, including but not limited to electromagnetic signal, Optical signal or above-mentioned any appropriate combination.Readable signal medium can also be any readable Jie other than readable storage medium storing program for executing Matter, which can send, propagate either transmission for used by instruction execution system, device or device or and its The program of combined use.
The program code for including on readable medium can transmit with any suitable medium, including but not limited to wirelessly, have Line, optical cable, RF etc. or above-mentioned any appropriate combination.
It can be write with any combination of one or more programming languages for executing the program that operates of the present invention Code, described program design language include object oriented program language-Java, C++ etc., further include conventional Procedural programming language-such as " C " language or similar programming language.Program code can be fully in user It executes on computing device, partly execute on a user device, being executed as an independent software package, partly in user's calculating Upper side point is executed or is executed in remote computing device or server completely on a remote computing.It is being related to far In the situation of journey computing device, remote computing device can pass through the network of any kind, including LAN (LAN) or wide area network (WAN), it is connected to user calculating equipment, or, it may be connected to external computing device (such as utilize ISP To be connected by internet).
In an exemplary embodiment of the disclosure, a kind of electronic equipment that can realize the above method is additionally provided.
Person of ordinary skill in the field it is understood that various aspects of the invention can be implemented as system, method or Program product.Therefore, various aspects of the invention can be embodied in the following forms, i.e.,:It is complete hardware embodiment, complete The embodiment combined in terms of full Software Implementation (including firmware, microcode etc.) or hardware and software, can unite here Referred to as circuit, " module " or " system ".
The electronic equipment 1400 of this embodiment according to the present invention is described referring to Figure 14.The electricity that Figure 14 is shown Sub- equipment 1400 is only an example, should not bring any restrictions to the function and use scope of the embodiment of the present invention.
As shown in figure 14, electronic equipment 1400 is showed in the form of universal computing device.The component of electronic equipment 1400 can To include but not limited to:Above-mentioned at least one processing unit 1410, above-mentioned at least one storage unit 1420, connection different system The bus 1430 of component (including storage unit 1420 and processing unit 1410), display unit 1440.
Wherein, the storage unit has program stored therein code, and said program code can be held by the processing unit 1410 Row so that the processing unit 1410 executes various according to the present invention described in above-mentioned " illustrative methods " part of this specification The step of illustrative embodiments.For example, the processing unit 1410 can execute step S12 as shown in fig. 1 to step S16。
Storage unit 1420 may include the readable medium of volatile memory cell form, such as Random Access Storage Unit (RAM) 14201 and/or cache memory unit 14202, it can further include read-only memory unit (ROM) 14203.
Storage unit 1420 can also include program/utility with one group of (at least one) program module 14205 14204, such program module 14205 includes but not limited to:Operating system, one or more application program, other programs Module and program data may include the realization of network environment in each or certain combination in these examples.
Bus 1430 can be to indicate one or more in a few class bus structures, including storage unit bus or storage Cell controller, peripheral bus, graphics acceleration port, processing unit use the arbitrary bus structures in a variety of bus structures Local bus.
Electronic equipment 1400 can also be with one or more external equipments 1500 (such as keyboard, sensing equipment, bluetooth equipment Deng) communication, can also be enabled a user to one or more equipment interact with the electronic equipment 1400 communicate, and/or with make The electronic equipment 1400 can be communicated with one or more of the other computing device any equipment (such as router, modulation Demodulator etc.) communication.This communication can be carried out by input/output (I/O) interface 1450.Also, electronic equipment 1400 Network adapter 1460 and one or more network (such as LAN (LAN), wide area network (WAN) and/or public affairs can also be passed through Common network network, such as internet) communication.As shown, network adapter 1460 passes through its of bus 1430 and electronic equipment 1400 Its module communicates.It should be understood that although not shown in the drawings, other hardware and/or software can be used in conjunction with electronic equipment 1400 Module, including but not limited to:Microcode, device driver, redundant processing unit, external disk drive array, RAID system, magnetic Tape drive and data backup storage system etc..
Through the above description of the embodiments, those skilled in the art is it can be readily appreciated that example described herein is implemented Mode can also be realized by software realization in such a way that software is in conjunction with necessary hardware.Therefore, according to the disclosure The technical solution of embodiment can be expressed in the form of software products, the software product can be stored in one it is non-volatile Property storage medium (can be CD-ROM, USB flash disk, mobile hard disk etc.) in or network on, including some instructions are so that a calculating Equipment (can be personal computer, server, terminal installation or network equipment etc.) is executed according to disclosure embodiment Method.
In addition, above-mentioned attached drawing is only the schematic theory of the processing included by method according to an exemplary embodiment of the present invention It is bright, rather than limit purpose.It can be readily appreciated that the time that above-mentioned processing shown in the drawings did not indicated or limited these processing is suitable Sequence.In addition, being also easy to understand, these processing for example can be executed either synchronously or asynchronously in multiple modules.
It should be noted that although being referred to several modules or list for acting the equipment executed in above-detailed Member, but this division is not enforceable.In fact, according to embodiment of the present disclosure, it is above-described two or more The feature and function of module either unit can embody in a module or unit.Conversely, an above-described mould Either the feature and function of unit can be further divided into and embodied by multiple modules or unit block.
Those skilled in the art after considering the specification and implementing the invention disclosed here, will readily occur to its of the disclosure His embodiment.This application is intended to cover any variations, uses, or adaptations of the disclosure, these modifications, purposes or Adaptive change follow the general principles of this disclosure and include the undocumented common knowledge in the art of the disclosure or Conventional techniques.The description and examples are only to be considered as illustrative, and the true scope and spirit of the disclosure are by claim It points out.
It should be understood that the present disclosure is not limited to the precise structures that have been described above and shown in the drawings, and And various modifications and changes may be made without departing from the scope thereof.The scope of the present disclosure is only limited by the attached claims.

Claims (10)

1. a kind of optical sensor calibration method, which is characterized in that including:
Obtain the current illumination reading of optical sensor;
Obtain the correspondence between the test reading of the optical sensor and desired illuminance value;
The brightness value after calibration is determined according to current illumination reading and the correspondence.
2. optical sensor calibration method according to claim 1, which is characterized in that the optical sensor calibration method also wraps It includes:
Obtain multiple test readings of the optical sensor under the different illuminance of testing light source;
Utilize the desired illuminance value structure calibration line chart of the multiple test reading and the different illuminance;
Wherein, using the corresponding piecewise function of the calibration line chart as the correspondence.
3. optical sensor calibration method according to claim 2, which is characterized in that the testing light source is that can set illumination The light source of value, using the brightness value of setting as the desired illuminance value;Or
Using the reading under illumination instrument read test light source difference illuminance, as the desired illuminance value.
4. optical sensor calibration method according to claim 1 or 2, which is characterized in that read according to the current illumination Determine that the brightness value after calibration includes with the correspondence:
If the current illumination reading only corresponds to a desired illuminance value in the correspondence, by the correspondence In an only corresponding desired illuminance value as calibration after brightness value;
If the current illumination reading corresponds to limited a desired illuminance value in addition to one in the correspondence, will The average value of limited a desired illuminance value is as the brightness value after calibration;
If the current illumination reading corresponds to numerous desired illuminance value in the correspondence, by the numerous reason Think the average value of maxima and minima in brightness value as the brightness value after calibration.
5. optical sensor calibration method according to claim 2, which is characterized in that the optical sensor calibration method also wraps It includes:
Calculate the error of the piecewise function;
Using calculated error as the precision references of the brightness value after being calibrated to current illumination reading.
6. optical sensor calibration method according to claim 5, which is characterized in that calculate the error packet of the piecewise function It includes:
Piecewise function and the absolute value of the difference of desired illuminance function are integrated, to obtain first integral result;
Desired illuminance function is integrated, to obtain second integral result;
Using the ratio of the first integral result and the second integral result as the error of the piecewise function.
7. a kind of optical sensor calibrating installation, which is characterized in that including:
Current illumination acquisition module, the current illumination for obtaining optical sensor are read;
Correspondence acquisition module, for obtaining the corresponding pass between the test reading of the optical sensor and desired illuminance value System;
Determining module is calibrated, for determining the brightness value after calibration according to current illumination reading and the correspondence.
8. a kind of mobile device, including optical sensor, which is characterized in that the mobile device includes the light described in claim 7 Calibrating device for sensors.
9. a kind of storage medium, is stored thereon with computer program, which is characterized in that the computer program is executed by processor Shi Shixian optical sensor calibration methods according to any one of claims 1 to 6.
10. a kind of electronic equipment, which is characterized in that including:
Processor;And
Memory, the executable instruction for storing the processor;
Wherein, the processor is configured to come described in any one of perform claim requirement 1 to 6 via the execution executable instruction Optical sensor calibration method.
CN201810525549.0A 2018-05-28 2018-05-28 Optical sensor calibration method and device, mobile device, medium and electronic device Active CN108760042B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810525549.0A CN108760042B (en) 2018-05-28 2018-05-28 Optical sensor calibration method and device, mobile device, medium and electronic device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810525549.0A CN108760042B (en) 2018-05-28 2018-05-28 Optical sensor calibration method and device, mobile device, medium and electronic device

Publications (2)

Publication Number Publication Date
CN108760042A true CN108760042A (en) 2018-11-06
CN108760042B CN108760042B (en) 2020-11-24

Family

ID=64002992

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810525549.0A Active CN108760042B (en) 2018-05-28 2018-05-28 Optical sensor calibration method and device, mobile device, medium and electronic device

Country Status (1)

Country Link
CN (1) CN108760042B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2022036750A1 (en) * 2020-08-20 2022-02-24 深圳市路美康尔医疗科技有限公司 Exposure intensity calibration method for ultraviolet disinfection cabinet
CN116075019A (en) * 2023-03-27 2023-05-05 厦门普为光电科技有限公司 Illuminance calibration device and method thereof

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102265707A (en) * 2011-04-29 2011-11-30 华为终端有限公司 Method for controlling light-emitting device in terminal equipment, apparatus thereof and terminal equipment
CN102322946A (en) * 2011-07-22 2012-01-18 惠州Tcl移动通信有限公司 Calibration method and system for optical sensor of mobile phone
CN103678070A (en) * 2013-12-27 2014-03-26 上海斐讯数据通信技术有限公司 Calibration method, testing method and manufacturing method for optical sensor of mobile terminal
CN104919289A (en) * 2012-12-26 2015-09-16 皇家飞利浦有限公司 Light sensing system, and method for calibrating a light sensing device
CN107924312A (en) * 2015-09-02 2018-04-17 高通股份有限公司 The optical sensor data of automatic calibration mobile device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102265707A (en) * 2011-04-29 2011-11-30 华为终端有限公司 Method for controlling light-emitting device in terminal equipment, apparatus thereof and terminal equipment
CN102322946A (en) * 2011-07-22 2012-01-18 惠州Tcl移动通信有限公司 Calibration method and system for optical sensor of mobile phone
CN104919289A (en) * 2012-12-26 2015-09-16 皇家飞利浦有限公司 Light sensing system, and method for calibrating a light sensing device
CN103678070A (en) * 2013-12-27 2014-03-26 上海斐讯数据通信技术有限公司 Calibration method, testing method and manufacturing method for optical sensor of mobile terminal
CN107924312A (en) * 2015-09-02 2018-04-17 高通股份有限公司 The optical sensor data of automatic calibration mobile device

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2022036750A1 (en) * 2020-08-20 2022-02-24 深圳市路美康尔医疗科技有限公司 Exposure intensity calibration method for ultraviolet disinfection cabinet
CN116075019A (en) * 2023-03-27 2023-05-05 厦门普为光电科技有限公司 Illuminance calibration device and method thereof

Also Published As

Publication number Publication date
CN108760042B (en) 2020-11-24

Similar Documents

Publication Publication Date Title
US8704767B2 (en) Environmental gesture recognition
EP2808652B1 (en) Portable electronic device with integrated temperature sensor being compensated by other sensing data
EP2793450B1 (en) System and method for determining sensor accuracy of a portable electronic device
CN105866781B (en) Data processing method and electronic equipment
EP3775810B1 (en) Calibrated brightness estimation using ambient color sensors
CN108876857B (en) Method, system, device and storage medium for positioning unmanned vehicle
CN110146161A (en) Detection method, device and the terminal of environment illumination intensity
CN108362310B (en) Method and device for determining geomagnetic accuracy, storage medium and terminal
CN108760042A (en) Optical sensor calibration method and device, mobile device, medium and electronic equipment
EP2938052B1 (en) Electronic device and method for providing environment information
KR20210081576A (en) Method for indoor positioning and the electronic device
CN203554463U (en) A data throughput test system applied to an anechoic chamber
CN114063964A (en) Volume compensation optimization method and device, electronic equipment and readable storage medium
EP2808651A1 (en) Portable electronic device with integrated temperature sensor being compensated by other sensing data
CN110543278B (en) Cross-device screen coordinate adaptation method and device and storage medium
KR20150099672A (en) Electronic device and display controlling method of the same
CN113379852B (en) Method, device, electronic equipment and medium for verifying camera calibration result
WO2014113959A1 (en) Integrated hardware and software for probe
CN113390421B (en) Unmanned aerial vehicle positioning method and device based on Kalman filtering
CN112990163B (en) Fingerprint calibration method, electronic device and storage medium
CN108931213A (en) Measurement method of planeness, device, equipment and storage medium
CN112489111A (en) Camera external parameter calibration method and device and camera external parameter calibration system
SE545781C2 (en) Method for on line monitoring of air flow at air tenninals of a ventilation system
KR20200118949A (en) Portable Apparatus for measuring Air Quality and the Method for Displaying related to Air Quality thereof
US11005677B2 (en) System and method for controlling building systems engineering

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