WO2020006728A1 - 晶体判定方法、装置及存储介质 - Google Patents

晶体判定方法、装置及存储介质 Download PDF

Info

Publication number
WO2020006728A1
WO2020006728A1 PCT/CN2018/094630 CN2018094630W WO2020006728A1 WO 2020006728 A1 WO2020006728 A1 WO 2020006728A1 CN 2018094630 W CN2018094630 W CN 2018094630W WO 2020006728 A1 WO2020006728 A1 WO 2020006728A1
Authority
WO
WIPO (PCT)
Prior art keywords
value
temperature
fitted
crystal
coefficient
Prior art date
Application number
PCT/CN2018/094630
Other languages
English (en)
French (fr)
Inventor
胡睿
余成志
Original Assignee
华为技术有限公司
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 华为技术有限公司 filed Critical 华为技术有限公司
Priority to CN201880094853.2A priority Critical patent/CN112292814A/zh
Priority to PCT/CN2018/094630 priority patent/WO2020006728A1/zh
Publication of WO2020006728A1 publication Critical patent/WO2020006728A1/zh

Links

Images

Classifications

    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03BGENERATION OF OSCILLATIONS, DIRECTLY OR BY FREQUENCY-CHANGING, BY CIRCUITS EMPLOYING ACTIVE ELEMENTS WHICH OPERATE IN A NON-SWITCHING MANNER; GENERATION OF NOISE BY SUCH CIRCUITS
    • H03B5/00Generation of oscillations using amplifier with regenerative feedback from output to input
    • H03B5/30Generation of oscillations using amplifier with regenerative feedback from output to input with frequency-determining element being electromechanical resonator
    • H03B5/32Generation of oscillations using amplifier with regenerative feedback from output to input with frequency-determining element being electromechanical resonator being a piezoelectric resonator

Definitions

  • the present application relates to the field of communications technologies, and in particular, to a method, a device, and a storage medium for determining a crystal.
  • the clock source on the chip is usually implemented with a passive crystal.
  • a chip with strict requirements for the clock frequency offset value usually adds a heat.
  • the sensitive resistor is used to test the temperature value of the passive crystal, and then the frequency deviation curve is fitted by using different frequency deviation values at different temperature values, and the frequency deviation compensation process is performed according to the frequency deviation curve and temperature value.
  • f (t) c3 (t-t0) 3 + c2 (t-t0) 2 + c1 (t-t0) + c0
  • t temperature value
  • t0 reference temperature value
  • c0 constant term
  • c1 linear term coefficient
  • c2 quadratic term coefficient
  • c3 cubic term coefficient
  • f (t) frequency when temperature value is t Partial value.
  • the c1 value and c0 value can be calculated by extracting the frequency offset values corresponding to the two temperature values, and the c1 value and the c0 value are used to determine whether the crystal is qualified.
  • the c1 value and the c0 value are used as the c1 value and the c0 value of the fitted frequency deviation curve, and the c2 value and the c3 value adopt the given default values.
  • the frequency offset value corresponding to one temperature value is first extracted, and the frequency offset value corresponding to the second temperature value is extracted after increasing the given temperature. Since the frequency offset curve at the normal temperature section is close to a straight line, the second and third terms It can be ignored.
  • the c1 value and c0 value calculated by the above method will have a large deviation, so that many unqualified crystals cannot be found.
  • c1 is calculated by the above method.
  • the values of c1 and c0 may be inaccurate, but they may meet the thresholds of c1 and c0. In this way, the frequency deviation curve of the full temperature band fitted with the c1 value and c0 value is quite different from the actual frequency deviation curve.
  • the embodiments of the present application provide a method, a device and a storage medium for determining crystals, so as to solve the inaccuracy of the primary phase coefficient value and the constant term value of the corresponding frequency deviation curve of the crystal corresponding to the prior art, so that many unqualified crystals cannot be found.
  • the problem is to solve the inaccuracy of the primary phase coefficient value and the constant term value of the corresponding frequency deviation curve of the crystal corresponding to the prior art, so that many unqualified crystals cannot be found.
  • a first aspect of the present application provides a method for determining a crystal, including:
  • t temperature value variable
  • t0 reference temperature value
  • f (t) frequency offset value when temperature value is t
  • the technical solution of the present application uses at least three temperature values and the frequency offset value corresponding to each temperature to determine whether the crystal is qualified. There are many temperature values and frequency offset values involved in the determination, and the determination result is high in accuracy, high reliability, and avoided. The problem that unqualified crystals cannot be found.
  • the determining that the crystal is at the preset temperature is based on the at least three temperature values and a test frequency offset value corresponding to each of the temperature values.
  • the fitted first-order term coefficient value c1 and the fitted constant term value c0 of the frequency offset curve f (t) at the segment include:
  • the least-squares method can be used to easily obtain the fitted first-order term coefficient value c1 and the fitted constant term value c0, and the obtained fitted first-order term coefficient value c1 and the fitted constant term value c0 and The sum of the squares of the errors between the theoretical values is minimal, which lays the foundation for subsequent accurate crystal determination results.
  • determining that the crystal is in the preset according to the at least three temperature values and a test frequency offset value corresponding to each of the temperature values include:
  • each group of the undetermined coefficients includes: a linear term Coefficient value and a constant term value;
  • the mean can reflect the trend in a set of data, Closer to the slope of the frequency deviation curve, the average of the above constant terms It is closer to the constant term of the frequency deviation curve, so the coefficient of the linear term is averaged. Fit the coefficient value c1 of the first-order term as the frequency deviation curve, and average the constant term.
  • the fitting constant term value c0 which is a frequency deviation curve, can more accurately reflect the trend of the coefficient value of the first-order term and the value of the constant term, and the obtained coefficient value of the fitted linear term and the constant value of the fitted constant term have high accuracy.
  • determining whether the crystal is qualified according to the fitting linear term coefficient value c1 and the fitting constant term value c0 includes:
  • (c1) j is the coefficient value of the linear term in the j-th group of pending coefficients
  • (c0) j is the constant term value in the j-th group of pending coefficients
  • M is the number of groups of the at least two sets of pending coefficients
  • j A positive integer greater than or equal to 1 and less than or equal to M;
  • the mean square error can be used to describe the characteristics of the degree of dispersion between each data in the data set and the average value.
  • the mean square error ⁇ c1 of the fitted first-order coefficient value c1 and the mean square error ⁇ of the fitted constant term c0 are calculated. c0 , and then determine whether the crystal is qualified or not. This method is easy to implement and has high accuracy.
  • the method further includes:
  • the at least three are obtained by the following formula (4)
  • the fitted frequency offset value f (t i ) and the test frequency offset value corresponding to each of the temperature values The correlation coefficient value between R 2 ;
  • f (t i ) is a fitted frequency offset value based on the ith temperature value obtained by the frequency offset curve f (t), Is the test frequency offset of the i-th temperature value, Is the average frequency deviation of N temperature values obtained based on the frequency deviation curve f (t), N is the number of the at least three temperature values, and i is a positive integer greater than or equal to 1 and less than or equal to N;
  • the technical solution determines The judgment result of the crystal's eligibility is more accurate and the reliability is higher.
  • the method further includes:
  • each set of undetermined coefficients includes: a linear term coefficient value and a constant term value
  • At least one set of undetermined coefficient absolute values is obtained.
  • Each set of the undetermined coefficient absolute values includes: a linear term coefficient absolute value and a constant term coefficient absolute value.
  • the absolute value of the linear term coefficient is An absolute value obtained by making a difference between two first-order coefficient values of two adjacent groups of undetermined coefficients
  • the absolute value of the constant term coefficient is an absolute value obtained by making a difference between two constant term values of two adjacent groups of undetermined coefficients
  • the technical scheme On the basis of determining the pass of the crystal according to the fitted first-order coefficient value c1 and the fitted constant term value c0, the technical scheme further increases the adjacent first-order coefficient value and constant term value change range to further determine whether the crystal is qualified. On the premise of ensuring that the judgment results are accurate, the technical scheme is simple and easy to implement.
  • the method further includes:
  • RES (t i ) is the residual value difference corresponding to the i-th temperature value
  • f (t i ) is the fitted frequency offset value of the i-th temperature value obtained based on the frequency deviation curve f (t)
  • a test frequency offset value of an i-th temperature value, i is a temperature value of the at least three temperature values
  • a determination result of whether the crystal is qualified is updated.
  • the technical scheme adds a residual value difference to assist in judging whether the crystal is qualified, which makes the accuracy of crystal discrimination higher.
  • updating the determination result of whether the crystal is qualified based on a residual value difference corresponding to each of the at least three temperature values includes: :
  • t2 and t1 are two adjacent temperature values among the at least three temperature values, RES (t1) is a residual value difference corresponding to the temperature value t1, and RES (t2) is a residual value difference corresponding to the temperature value t2.
  • T2 is greater than t1;
  • This technical solution is based on the fitting of the coefficient of the first-order term c1 and the value of the fitting constant term c0 to determine whether the crystal is qualified, and then to determine whether the crystal is qualified by the residual error change rate.
  • the accuracy of the frequency offset point makes the accuracy of crystal discrimination higher.
  • a second aspect of the present application provides a crystal determination device, including: a crystal, a temperature sensor, an analog-to-digital converter ADC, and a power management unit PMU chip;
  • the temperature sensor is configured to obtain at least three temperature values of the crystal in a preset temperature range, and a test frequency offset value corresponding to each of the temperature values;
  • the ADC is configured to perform analog-to-digital conversion processing on the at least three temperature values obtained by the temperature sensor and a test frequency offset value corresponding to each of the temperature values;
  • the PMU chip is configured to determine the crystal when the crystal is in the preset temperature range according to the at least three temperature values processed by the ADC and a test frequency offset value corresponding to each of the temperature values. Corresponding to the fitted linear term coefficient value c1 and the fitted constant term value c0 of the frequency deviation curve f (t), and according to the determined fitted linear term coefficient value c1 and the fitted constant term value c0, determining the Whether the crystal is qualified;
  • t temperature value variable
  • t0 reference temperature value
  • f (t) frequency offset value when temperature value is t.
  • the PMU chip is specifically configured to use the at least three temperature values processed by the ADC and a test frequency offset corresponding to each of the temperature values.
  • the least-squares method is used to calculate the fitted first-order coefficient value c1 and the fitted constant term value c0 of the frequency deviation curve f (t).
  • the PMU chip is specifically configured to be based on two temperature values of the at least three temperature values processed by the ADC and each temperature value.
  • Corresponding frequency deviation test values determine at least two sets of undetermined coefficients of the frequency deviation curve, and determine an average of the coefficients of the first term according to the at least two sets of undetermined coefficients And constant term mean And the average of the linear coefficients As the fitted linear term coefficient value c1, average the constant term As the fitted constant term value c0;
  • the undetermined coefficients of each group include: a linear term coefficient value and a constant term value, and the average of the linear term coefficients Is an average value of coefficient values of all linear terms in the at least two sets of undetermined coefficients, and the average value of the constant terms Is the average of all constant term values in the at least two sets of undetermined coefficients.
  • the PMU chip is further configured to, based on the following formula (2), according to all first-order coefficient values in the at least two sets of undetermined coefficients, and the primary Term coefficient mean Calculate the mean square error ⁇ c1 of the fitted first-order coefficient value c1, based on the following formula (3), according to all constant term values in the at least two sets of pending coefficients and the constant term average Calculate the mean square error ⁇ c0 of the fitted constant term value c0 , and determine whether the crystal is based on the mean square error ⁇ c1 of the fitted linear term coefficient value c1 and the mean square error ⁇ c0 of the fitted constant term value c0 qualified;
  • (c1) j is the coefficient value of the linear term in the j-th group of pending coefficients
  • (c0) j is the constant term value in the j-th group of pending coefficients
  • M is the number of groups of the at least two sets of pending coefficients
  • j A positive integer greater than or equal to 1 and less than or equal to M.
  • the PMU chip is further configured to determine that the crystal is qualified according to the fitting linear term coefficient value c1 and the fitting constant term value c0.
  • the fitted frequency deviation value f (t i ) corresponding to each of the at least three temperature values and the test frequency are obtained by the following formula (4) Partial value A correlation coefficient value R 2 therebetween, and updating a determination result of whether the crystal is qualified according to the correlation coefficient value R 2 ;
  • f (t i ) is a fitted frequency offset value based on the ith temperature value obtained by the frequency offset curve f (t), Is the test frequency offset of the i-th temperature value, Is the average value of the frequency deviations of the N temperature values obtained based on the frequency deviation curve f (t), N is the number of the at least three temperature values, and i is a positive integer greater than or equal to 1 and less than or equal to N.
  • the PMU chip is further configured to determine that the crystal is qualified according to the fitting linear term coefficient value c1 and the fitting constant term value c0. , At least two sets of undetermined coefficients of the frequency deviation curve are determined according to two adjacent temperature values of the at least three temperature values and the frequency deviation test value corresponding to each temperature value after the ADC processing, The at least two sets of undetermined coefficients are described, the at least one set of undetermined coefficients are obtained, and the determination result of whether the crystal is qualified is updated according to the at least one set of undetermined coefficients.
  • the set of undetermined coefficients of each group includes: a linear term coefficient value and a constant term value
  • the absolute value of each set of undetermined coefficients includes: an absolute value of a linear term coefficient and an absolute value of a constant term coefficient
  • the linear term coefficient The absolute value is the absolute value of the difference between the two first-order coefficients of the adjacent two sets of undetermined coefficients
  • the absolute value of the constant term coefficient is the absolute value of the difference between the two constant terms of the adjacent two sets of undetermined coefficients. value.
  • the PMU chip is further configured to determine that the crystal is qualified according to the fitting linear term coefficient value c1 and the fitting constant term value c0.
  • a fitted frequency offset corresponding to each of the at least three temperature values is obtained Value, and based on the following formula (5), according to the test temperature value corresponding to each of the at least three temperature values after the ADC processing and the fitting corresponding to each temperature value of the at least three temperature values A frequency offset value, determining a residual value difference corresponding to each of the temperature values, and updating whether the crystal is qualified based on a residual value difference corresponding to each of the at least three temperature values after the ADC processing Judgment result
  • RES (t i ) is the residual value difference corresponding to the i-th temperature value
  • f (t i ) is the fitted frequency offset value of the i-th temperature value obtained based on the frequency deviation curve f (t)
  • i is one of the at least three temperature values.
  • the PMU chip is further configured to be based on a residual value difference corresponding to each of the at least three temperature values after the ADC processes, Updating the determination result of whether the crystal is qualified is specifically:
  • the PMU chip is further configured to determine at least two residual error change rates based on a residual value difference corresponding to two adjacent temperature values of the at least three temperature values after the ADC processing, based on the following formula (6): RES_s, and updating a determination result of whether the crystal is qualified according to the at least two residual error change rates;
  • t2 and t1 are two adjacent temperature values among the at least three temperature values, RES (t1) is a residual value difference corresponding to the temperature value t1, and RES (t2) is a residual value difference corresponding to the temperature value t2. , T2 is greater than t1.
  • a third aspect of the embodiments of the present application provides a crystal determining device.
  • the crystal determining device includes an obtaining module, a processing module, and a determining module.
  • the obtaining module, the processing module, and the determining module are configured to execute the first Provided on one hand.
  • a fourth aspect of the embodiments of the present application provides a crystal determination device, which includes at least one processing element (or chip) for implementing each of the foregoing first aspects.
  • a fifth aspect of the embodiments of the present application provides a storage medium.
  • the storage medium stores instructions that, when run on a computer, cause the computer to execute the method provided by the first aspect.
  • a sixth aspect of the embodiments of the present application provides a computer program product containing instructions, which when executed on a computer, causes the computer to execute the method provided by the first aspect.
  • FIG. 1 is a schematic structural diagram of a crystal determination circuit according to an embodiment of the present application.
  • FIG. 2 is a schematic diagram of a distribution of two temperature points extracted in the prior art on an actual frequency deviation curve
  • FIG. 3 is a schematic diagram of the distribution of the fitted frequency deviation curve and the actual frequency deviation curve obtained by fitting the two temperature points shown in FIG. 2;
  • FIG. 4 is a schematic flowchart of a first embodiment of a crystal determination method according to an embodiment of the present application
  • FIG. 5 is a schematic flowchart of Embodiment 2 of a crystal determination method provided by this application.
  • FIG. 6 is a schematic flowchart of Embodiment 3 of a crystal determination method provided by this application.
  • FIG. 7 is a schematic diagram of a distribution of undetermined coefficients of each group in the embodiment shown in FIG. 6;
  • FIG. 8 is a schematic flowchart of Embodiment 4 of a crystal determination method provided by this application.
  • FIG. 9 is a schematic structural diagram of a first embodiment of a crystal determination device according to an embodiment of the present application.
  • FIG. 10 is a schematic structural diagram of a second embodiment of a crystal determination device according to an embodiment of the present application.
  • FIG. 1 is a schematic structural diagram of a crystal determination circuit according to an embodiment of the present application.
  • the crystal determination circuit may include a passive crystal 11, a temperature sensor 12, a power management unit (PMU) chip 13, and an analog-to-digital converter (ADC) 14. .
  • the temperature sensor 12 is in contact with the passive crystal 11.
  • the analog-to-digital converter 14 is disposed on the power management unit chip 13.
  • the temperature sensor 12 is electrically connected to the analog-to-digital converter 14.
  • the temperature sensor 12 is used to detect the passive crystal 11.
  • the detected temperature is passed to the analog-to-digital converter 14 to determine the relationship between the temperature of the passive crystal and the frequency offset value according to the value output by the analog-to-digital converter 14.
  • the crystal judgment circuit may further include components such as a power supply, a resistor R1, a load capacitor, and the like, and the crystal judgment circuit also needs to be grounded, and the embodiment of the present application is not limited thereto.
  • the passive crystal involved in the embodiments of the present application needs to be used with an on-chip oscillator of a digital signal processor (DSP).
  • DSP digital signal processor
  • the advantage of a passive crystal is that there is no voltage problem, and the signal level is variable. That is, the signal level of the passive crystal is determined by the start-up circuit.
  • the same crystal can be used for a variety of voltages. For many different clock signal voltage requirements, and the price is usually lower. Therefore, in general, if conditions permit, it is recommended to use passive crystals.
  • the passive crystal has a poor signal quality compared to a crystal oscillator, it is usually necessary to precisely match the peripheral circuits (capacitors, inductors, resistors, etc. for signal matching), and the peripheral configuration circuit needs to be adjusted accordingly when replacing crystals with different frequencies .
  • the passive crystal in the embodiment of the present application may be a quartz crystal with high accuracy.
  • the temperature sensor may be a thermistor with a negative temperature coefficient (NTC) made of a negative temperature coefficient (NTC).
  • NTC refers to the thermistor phenomenon and material with a negative temperature coefficient that decreases exponentially with increasing temperature.
  • the PMU chip is a highly integrated power management solution for portable applications. It integrates traditional discrete power management devices into a single package, which can achieve higher power conversion efficiency and lower power consumption. Power consumption and fewer components to accommodate reduced board space.
  • the PMU chip is a chip that assumes the responsibilities of transforming, distributing, detecting, and managing other electrical energy in electronic equipment systems.
  • the analog-to-digital converter 14 refers to a device that converts a continuously changing analog signal into a discrete digital signal.
  • the analog-to-digital converter 14 is configured to convert an analog temperature signal received from the temperature sensor into a discrete digital signal for processing by the PMU chip.
  • “multiple” means two or more.
  • “And / or” describes the association relationship between related objects and indicates that there can be three types of relationships. For example, A and / or B can indicate that there are three cases in which A exists alone, A and B exist, and B exists alone.
  • the character "/" generally indicates that the related objects are an "or" relationship.
  • the calculation of the c1 value and the c0 value of the frequency deviation curve corresponding to the crystal is performed at normal temperature by extracting two temperature points of the crystal (each temperature point includes a temperature value and a frequency offset value corresponding to the temperature value). Fitted.
  • the c1 value and c0 value calculated by this method may have a large deviation, which causes a problem that many unqualified crystals cannot be found.
  • FIG. 2 is a schematic diagram of a distribution of two temperature points extracted in the prior art on an actual frequency deviation curve.
  • FIG. 3 is a schematic diagram of the distribution of the fitted frequency deviation curve and the actual frequency deviation curve obtained by fitting the two temperature points shown in FIG. 2.
  • the c1 value and c0 value calculated by the prior art method may be inaccurate at this time, but sometimes the error thresholds of the c1 value and c0 value are also satisfied, resulting in the frequency deviation of the full temperature segment of the final fitting There is a large difference between the curve and the actual frequency deviation curve.
  • the thin solid line represents the actual frequency deviation curve
  • the thin dotted line represents the fitted frequency deviation curve.
  • embodiments of the present application provide a method, a device, and a storage medium for determining a crystal, which are used to solve the problem that unqualified crystals cannot be rejected due to inaccurate linear coefficients and constant terms of the frequency deviation curve. problem dicovered.
  • the technical solution of the present application is described in detail through specific embodiments.
  • FIG. 4 is a schematic flowchart of a first embodiment of a crystal determination method according to an embodiment of the present application.
  • the crystal determination method is applied to the scenario shown in FIG. 1.
  • the crystal determination method may include the following steps:
  • Step 41 Obtain at least three temperature values of the crystal in a preset temperature section, and a test frequency offset value corresponding to each temperature value.
  • the crystal determination circuit shown in FIG. 1 when it is necessary to determine whether the crystal is qualified, the crystal determination circuit shown in FIG. 1 can be referred to, and the temperature of the crystal is first controlled to change within a preset temperature range, and then the test is passed.
  • the method obtains at least three temperature values of the crystal in the preset temperature section.
  • the test frequency offset value of the crystal at each of the above temperature values is obtained by a test method.
  • the preset temperature section may refer to a normal temperature section in a slang term.
  • the temperature range of the normal temperature section may be 0 ° C to 25 ° C.
  • Step 42 According to the at least three temperature values and the test frequency deviation value corresponding to each temperature value, determine the fitting coefficient coefficients c1 and f1 of the corresponding frequency deviation curve f (t) of the crystal when the crystal is in the preset temperature range. Fit constant term value c0.
  • the frequency deviation curve is expressed by formula (1):
  • the frequency deviation curve of the crystal at a normal temperature section is close to a straight line. Therefore, when the crystal is in the preset temperature range, the frequency deviation curve of the crystal can be expressed by the foregoing formula (1).
  • t0 is the reference temperature value
  • c0 is the fitted constant term value to be determined
  • c1 is the coefficient value of the fitted linear term to be determined
  • t is the temperature value variable
  • f (t) is the frequency when the temperature value is t. Partial value.
  • the at least three temperature values of the crystal and the test frequency offset value corresponding to each temperature value are obtained, the at least three temperature values and the test frequency offset value corresponding to each temperature value are brought into the
  • the above formula (1) can obtain the fitted first-order coefficient value c1 and the fitted constant term value c0 of the crystal corresponding to the frequency deviation curve f (t) of the crystal at the preset temperature range.
  • this step (based on the at least three temperature values and the test frequency offset value corresponding to each temperature value, determine the fitting coefficient value of the first-order term of the corresponding frequency deviation curve f (t) of the crystal when the crystal is at a preset temperature range.
  • the possible implementation manners of c1 and the fitting constant term value c0) may be any one of the following two possible implementation manners. For details, refer to the following description.
  • this step may be implemented by the following possible implementation manners, as follows:
  • the fitted first-order coefficient value c1 and the fitted constant term value c0 of the frequency deviation curve f (t) are calculated by the least square method.
  • the implementation principle of the least squares method is: the sum of the squares of the deviations of the test frequency offset value and the fitted frequency offset value corresponding to each of the above at least three temperature values The minimum is used as a basis for obtaining the coefficient value c1 of the fitting first term and the value of the fitting constant term c0.
  • f (t i ) is a fitted frequency offset value based on an ith temperature value obtained based on the frequency offset curve f (t), Is the test frequency offset value of the i-th temperature value.
  • Finding the coefficient value c1 and the constant value c0 of the fitted linear term is actually C1 and c0 at the minimum.
  • the partial derivatives of c1 and c0 are obtained respectively, and then the two partial derivative formulas are equal to zero, so as to obtain the coefficient value of the fitted linear term c1 and the value of the fitted constant term c0.
  • the least-squares method can be used to easily obtain the fitted first-order coefficient value c1 and the fitted constant term value c0, and make the obtained fitted first-order coefficient value c1 and the fitted constant term value c0 between the theoretical value and the theoretical value.
  • the sum of the squared errors is minimal, which lays the foundation for subsequent accurate crystal determination results.
  • this step may be implemented in the following manner.
  • steps A1 to A3 refer to the following steps A1 to A3:
  • Step A1 Determine at least two sets of undetermined coefficients of the frequency deviation curve according to the two temperature values of the at least three temperature values and the frequency deviation test value corresponding to each temperature value, where each set of undetermined coefficients includes: a linear term Coefficient value and a constant term value.
  • Step A2 Determine the average of the coefficients of the first term according to the above-mentioned at least two sets of coefficients to be determined And constant term mean
  • the average of the linear coefficient Is the average of the coefficient values of all the first-order terms in the at least two sets of pending coefficients
  • the average of the constant terms Is the average of all the constant term values in the at least two sets of undetermined coefficients.
  • the coefficient values of all first-order terms in the at least two sets of undetermined coefficients are obtained Divide by the number of coefficients of all the first-order terms to get the average of the first-order term coefficients Sum the values of all the constant terms in at least the two sets of undetermined coefficients and then divide by the number of all constant terms to obtain the average value of the constant terms
  • Step A3 average the above-mentioned first term coefficients As the fitted linear term coefficient value c1, average the above constant terms As the fitted constant term value c0.
  • the average value can reflect the trend in a set of data, Closer to the slope of the frequency deviation curve, the average of the above constant terms It is closer to the constant term of the above frequency deviation curve, so when the coefficient of the first-order term is calculated And constant term mean After that, the linear coefficient can be averaged. Fit the coefficient value c1 of the first-order term as the frequency deviation curve, and average the constant term The value of the fitted constant term c0 as the frequency deviation curve.
  • Step 43 Determine whether the crystal is qualified according to the fitting linear term coefficient value c1 and the fitting constant term value c0.
  • the first-order term value range corresponding to the first-order coefficient value of the frequency deviation curve and the constant-term value range corresponding to the constant term value can be preset respectively. Therefore, the After fitting the coefficient value c1 of the primary term and the constant value c0 of the fitting term, it can be determined whether the coefficient value c1 of the fitted linear term is within the preset linear value range and whether the fitted constant term value c0 is within the preset constant. Within the value range of the term, if yes, it is determined that the crystal is qualified; if not, it is determined that the crystal is not qualified.
  • this step can be implemented through the following steps B1 to B3:
  • Step B1 Based on the following formula (2), according to the values of all the coefficients of the first-order terms in the at least two sets of undetermined coefficients, and the average of the coefficients of the first-order terms Calculate the mean square error ⁇ c1 of the coefficient value c1 of the fitted linear term;
  • Step B2 Based on the following formula (3), according to the values of all the constant terms in the at least two sets of undetermined coefficients and the average value of the constant terms Calculate the mean square error ⁇ c0 of the fitted constant term value c0 ;
  • (c1) j is the coefficient value of the linear term in the j-th group of undetermined coefficients
  • (c0) j is the constant term value in the j-th group of undetermined coefficients
  • M is the number of the above-mentioned at least two groups of undetermined coefficients
  • j is A positive integer greater than or equal to 1 and less than or equal to M.
  • the mean square error can describe the degree of dispersion between each data and the average value in the data set
  • all the first-order coefficient values and all the first-order coefficient values in at least two sets of pending coefficients determined according to the above can be determined
  • Calculate the mean square error ⁇ c1 of the coefficient value c1 of the fitted primary term and calculate the mean square error ⁇ of the fitted constant term value according to all the constant term values in at least two sets of undetermined coefficients determined above and the above constant term average.
  • Sub-step B3 The first term of the fitting coefficient value c1 of the variance [sigma] are fitting constants c1 and c0 term mean value of the variance ⁇ c0, determines eligibility crystals.
  • the smaller the mean square error ⁇ c1 of the coefficient value c1 of the fitted linear term indicates that the smaller the fluctuation of the coefficient values of all the linear terms of the at least two sets of undetermined coefficients
  • the smaller the mean square error ⁇ c0 of the fitted constant value c0 Small indicating that the fluctuation of all constant term values in the at least two sets of undetermined coefficients is smaller, so that the stability performance of the crystal can be determined based on it.
  • the embodiment of the present application neither restricts the determination of whether the crystal is qualified directly based on the fitted linear term coefficient value c1 and the fitted constant term value c0, nor limits the mean square error ⁇ of the fitted linear term coefficient value c1.
  • c1 and the mean square error ⁇ c0 of the fitted constant term value c0 to determine whether the crystal is qualified.
  • it may also be obtained by fitting the correlation coefficient of the fitted linear term coefficient value c1, the correlation coefficient of the fitted constant term value c0, or
  • the statistics of the linear term coefficient value c1 and the statistics of the fitting constant term value c0 are combined to determine whether the crystal is qualified or not, which is not limited in the embodiment of the present application, and can be determined according to actual needs.
  • the crystal determination method obtaineds at least three temperature values of a crystal in a preset temperature range and a test frequency offset value corresponding to each temperature value, and according to the at least three temperature values and each temperature value Corresponding test frequency offset value, determine the fitted first-order term coefficient value c1 and fitted constant term value c0 of the corresponding frequency deviation curve f (t) of the crystal at the preset temperature range, and finally according to the fitted first-order term coefficient value c1 And the fitting constant term value c0, determine whether the crystal is qualified.
  • at least three temperature values and the frequency offset value corresponding to each temperature value are used to determine whether the crystal is qualified. The determination result is high in accuracy and high reliability, and the problem that unqualified crystals cannot be found is avoided.
  • FIG. 5 is a schematic flowchart of Embodiment 2 of a crystal determination method provided by the present application.
  • the method for determining a crystal according to the embodiment of the present application may further include the following steps 51 and 52 after step 43 above:
  • Step 51 When it is determined that the crystal is qualified according to the fitted linear term coefficient value c1 and the fitted constant term value c0, based on the frequency deviation curve f (t), use the following formula (4) to obtain each of the at least three temperature values. Fitted temperature offset f (t i ) and test frequency offset The correlation coefficient value between R 2 ;
  • f (t i ) is the fitted frequency offset value based on the i-th temperature value obtained from the frequency offset curve f (t)
  • N is the number of the at least three temperature values mentioned above
  • i is a positive integer greater than or equal to 1 and less than or equal to N.
  • Step 52 Update the determination result of whether the crystal is qualified or not according to the correlation coefficient value R 2 .
  • the correlation coefficient can characterize the degree of linear correlation between two variables, the absolute value of the correlation coefficient value is less than or equal to 1, and the closer the correlation coefficient value is to 1, the stronger the correlation between the two variables. Therefore, in the embodiment shown in FIG. 4 above, when the fitted linear term coefficient value c1 and the fitted constant term value c0 of the frequency deviation curve are determined, the fitted frequency deviation curve can be determined accordingly.
  • the fitting frequency corresponding to each temperature value of the at least three temperature values can be calculated through the above formula (4).
  • the correlation coefficient value R 2 between the bias value and the test frequency bias value, and then the second crystal is judged again as to whether the crystal is qualified or not, and the judgment result of whether the crystal is qualified is updated accordingly.
  • the correlation value range of the correlation coefficient value can be pre-configured. If the correlation coefficient value R 2 between the fitted frequency deviation value and the test frequency deviation value is within the correlation value range, the crystal is deemed to be qualified, otherwise, the crystal is not determined to be qualified. qualified.
  • the determination result of the technical scheme for determining whether the crystal is qualified is more accurate and more reliable.
  • FIG. 6 is a schematic flowchart of Embodiment 3 of a crystal determination method provided by the present application.
  • the method for determining a crystal according to the embodiment of the present application may further include the following steps 61 to 63 after step 43 above:
  • Step 61 When the crystal is determined to be qualified according to the coefficient value c1 of the fitting primary term and the value of the fitting constant term c0, according to two adjacent temperature values among the above at least three temperature values and the frequency deviation test value corresponding to each temperature value , Determine at least two sets of coefficients to be determined for the frequency deviation curve.
  • each group of coefficients to be determined includes: a linear term coefficient value and a constant term value.
  • each set of undetermined coefficients includes a linear term coefficient value and a constant term value.
  • FIG. 7 is a schematic diagram of the distribution of each group of coefficients to be determined in the embodiment shown in FIG. 6. As shown in FIG. 7, in the preset temperature range, a total of n temperature values and the frequency offset value corresponding to each temperature value are obtained. A total of n-1 sets of coefficients to be determined can be obtained through the above method, where n Is an integer greater than 2.
  • Step 62 Obtain at least one set of absolute coefficients according to the at least two sets of pending coefficients.
  • the absolute value of each group of undetermined coefficients includes: an absolute value of a linear term coefficient and an absolute value of a constant term coefficient.
  • the absolute value of the linear term coefficient is the absolute value of the difference between two linear coefficients of the adjacent two sets of undetermined coefficients.
  • the absolute value of the constant term coefficient is the absolute value of the difference between two constant term values in two adjacent sets of coefficients to be determined.
  • an absolute value of a set of undetermined coefficients can be determined, that is, two linear coefficients of the undetermined coefficients of the adjacent two sets of coefficients.
  • the absolute value after the difference is used as the absolute value of the linear term in the absolute value of the set of undetermined coefficients, and the absolute value of the difference between two constant terms in the two sets of undetermined coefficients is used as the absolute value of the set of undetermined coefficients.
  • Constant term coefficient absolute value is used.
  • Step 63 Update the determination result of whether the crystal is qualified according to the absolute value of the at least one set of coefficients to be determined.
  • the one-time absolute value range of the one-time coefficient absolute value and the constant absolute value range of the constant absolute value can be configured in advance. Therefore, after obtaining at least one set of absolute values of the coefficients to be determined, Take out the largest absolute value of the first term coefficient and the largest absolute value of the constant term coefficient, compare the absolute value of the largest linear term coefficient with the preset absolute value range of the linear term, and compare the absolute value of the largest constant term coefficient with the preset absolute value. The absolute value range of the constant term is compared, and the crystal is qualified according to the relationship between the two.
  • the crystal is deemed to be qualified, otherwise , The crystal was found to be unqualified.
  • the crystal when determining that a crystal is qualified according to the coefficient value of the fitted linear term and the value of the fitted constant term, the crystal may be further based on two adjacent temperature values among the at least three temperature values and each temperature.
  • the frequency deviation test value corresponding to the value determines at least two sets of undetermined coefficients of the frequency deviation curve, and then obtains at least one set of undetermined coefficient absolute values.
  • the determination result of whether the crystal is qualified is updated.
  • FIG. 8 is a schematic flowchart of Embodiment 4 of a crystal determination method provided by the present application.
  • the method for determining a crystal according to the embodiment of the present application may further include the following steps 81 to 83 after step 43 above:
  • Step 81 When it is determined that the crystal is qualified according to the fitting linear term coefficient value c1 and the fitting constant term value c0, a frequency deviation curve f (t) obtained based on the fitting linear term coefficient value c1 and the fitting constant term value c0. To obtain a fitted frequency offset value corresponding to each of the at least three temperature values.
  • Step 82 Based on the following formula (5), determine each temperature value according to the test temperature value corresponding to each temperature value of at least three temperature values and the fitted frequency offset value corresponding to each temperature value of at least three temperature values. The corresponding residual value difference;
  • RES (t i ) is the residual value difference corresponding to the i-th temperature value
  • f (t i ) is the fitted frequency offset value of the i-th temperature value based on the frequency deviation curve f (t)
  • i is one of the at least three temperature values.
  • an absolute value obtained by subtracting a test temperature value corresponding to each temperature value and a fitting frequency offset value corresponding to the temperature value from the residual value difference corresponding to the temperature value may be defined.
  • each temperature value in the at least three temperature values can be obtained. Corresponding residual value difference.
  • Step 83 Based on the difference in residual value corresponding to each of the at least three temperature values, update the determination result of whether the crystal is qualified.
  • a residual value difference with the largest value that is, a maximum residual value difference is selected, Furthermore, the difference in the maximum residual value is used to determine whether the crystal is acceptable. Specifically, it is determined whether the maximum residual value difference is within a preset residual value range. If it is, the crystal is determined to be qualified, otherwise, the crystal is determined to be unqualified. Correspondingly, the determination result of whether the crystal is qualified in the embodiment shown in FIG. 4 is updated according to the determination result.
  • an average value of the residual value differences corresponding to all the temperature values that is, the average residual value difference, and then the average residual value may be used.
  • the difference in value determines whether the crystal is qualified.
  • the determination result of whether the crystal is qualified in the embodiment shown in FIG. 4 is updated according to the determination result.
  • a sum of the residual value differences corresponding to all the temperature values may be obtained, and then based on the sum of the residual value differences corresponding to all the temperature values. , Determine whether the crystal is qualified.
  • the determination result of whether the crystal is qualified in the embodiment shown in FIG. 4 is updated according to the determination result.
  • the step 83 (updating the determination result of whether the crystal is qualified based on the difference in residual value corresponding to each of the at least three temperature values above) may also be implemented by the following steps C1 and C2 :
  • Step C1 Based on the following formula (6), determine at least two residual error change rates RES_s according to the residual value differences corresponding to two adjacent temperature values of the at least three temperature values, respectively;
  • t2 and t1 are two adjacent temperature values among the at least three temperature values, RES (t1) is the residual value difference corresponding to the temperature value t1, and RES (t2) is the residual value difference corresponding to the temperature value t2. t2 is greater than t1.
  • each of the at least three temperature values corresponds to a residual value difference. Therefore, based on formula (6), according to the residual value differences corresponding to two adjacent temperature values, The residual error change rate RES_s between the two residual difference values corresponding to the two adjacent temperatures can be obtained. Similarly, at least two residual error change rates can be determined according to the residual value difference corresponding to the at least three temperature values. RES_s.
  • Step C2 Update the determination result of whether the crystal is qualified according to the at least two residual error change rates RES_s.
  • one of the at least two residual error change rates RES_s may be used to further determine whether the crystal is qualified.
  • the maximum residual error change rate that is, the maximum residual error change rate
  • the maximum residual error change rate can be selected from the at least two residual error change rates, and the maximum residual error change rate is used to determine whether the crystal is qualified.
  • an average value of all the residual error change rates among the at least two residual error change rates that is, an average residual error change rate may be obtained, and the average residual error change rate may be used to determine whether the crystal is qualified.
  • the sum of all the residual error change rates among the at least two residual error change rates may be obtained, and whether the crystal is qualified is determined based on the sum of all the residual error change rates.
  • the accuracy of the fitted frequency offset values corresponding to all temperature values can be ensured, and the value of the coefficient of the fitted linear term and the value of the fitted constant term can be more accurate.
  • the frequency obtained based on the fitting linear coefficient value and the fitting constant term value is further used. Partial curve to obtain the fitted frequency offset value corresponding to each of the at least three temperature values, and then according to the test temperature value corresponding to each of the at least three temperature values and each of the at least three temperature values The fitted frequency offset value corresponding to the temperature value determines the residual value difference corresponding to each temperature value, and finally, based on the residual value difference corresponding to each temperature value among the at least three temperature values, the determination result of whether the crystal is qualified is updated.
  • This technical solution can assist in determining whether the coefficient of the fitted primary term and the value of the fitted constant term are accurate through the difference of the residual value, thereby ensuring that the determination result of the qualified crystal is accurate.
  • the method for determining crystals addresses the problem that the unqualified crystals cannot be found in the prior art due to inaccurate values of the linear coefficients and constant terms of the fitting, from different angles and different dimensions
  • the starting point is to improve the accuracy of fitting the coefficient value of the first-order term and the value of the fitting constant term, and improve the judgment result of the crystal's eligibility, which can ensure that most of the unqualified crystals can be found, which lays the foundation for the subsequent improvement of crystal performance.
  • FIG. 9 is a schematic structural diagram of a first embodiment of a crystal determination device according to an embodiment of the present application.
  • the crystal determination device provided in the embodiment of the present application may include an acquisition module 91, a processing module 92, and a determination module 93.
  • the obtaining module 91 is configured to obtain at least three temperature values of a crystal in a preset temperature range, and a test frequency offset value corresponding to each of the temperature values;
  • the processing module 92 is configured to determine, based on the at least three temperature values obtained by the obtaining module 91 and a test frequency offset value corresponding to each of the temperature values, all the crystals in the preset temperature range.
  • the fitted first-order coefficient value c1 and the fitted constant term value c0 of the crystal corresponding to the frequency deviation curve f (t) are described, and the frequency deviation curve f (t) is expressed by formula (1):
  • t temperature value variable
  • t0 reference temperature value
  • f (t) frequency offset value when temperature value is t
  • the determining module 93 is configured to determine whether the crystal is qualified according to the fitting linear term coefficient value c1 and the fitting constant term value c0 determined by the processing module 92.
  • the processing module 92 is specifically configured to use the at least three temperature values obtained by the obtaining module 91 and each of the temperature values corresponds to For a test frequency offset value, a fitted first-order coefficient value c1 and a fitted constant term value c0 of the frequency offset curve f (t) are calculated by a least square method.
  • the processing module 92 is specifically configured to be based on two temperature values of the at least three temperature values obtained by the obtaining module 91 and A frequency deviation test value corresponding to each temperature value, at least two sets of undetermined coefficients of the frequency deviation curve are determined, and an average of a coefficient of a term is determined according to the at least two sets of undetermined coefficients.
  • constant term mean And the average of the linear coefficients As the fitted linear term coefficient value c1, average the constant term As the fitted constant term value c0;
  • the undetermined coefficients of each group include: a linear term coefficient value and a constant term value, and the average of the linear term coefficients Is an average value of coefficient values of all linear terms in the at least two sets of undetermined coefficients, and the average value of the constant terms Is the average of all constant term values in the at least two sets of undetermined coefficients.
  • the determination module 93 is specifically configured to be based on the following formula (2), according to all coefficient values of the first-order terms in the at least two sets of pending coefficients, and First-order coefficient mean Calculate the mean square error ⁇ c1 of the fitted first-order coefficient value c1, based on the following formula (3), according to all constant term values in the at least two sets of pending coefficients and the constant term average Calculate the mean square error ⁇ c0 of the fitted constant term value c0 , and determine whether the crystal is based on the mean square error ⁇ c1 of the fitted linear term coefficient value c1 and the mean square error ⁇ c0 of the fitted constant term value c0 qualified;
  • (c1) j is the coefficient value of the linear term in the j-th group of pending coefficients
  • (c0) j is the constant term value in the j-th group of pending coefficients
  • M is the number of groups of the at least two sets of pending coefficients
  • j A positive integer greater than or equal to 1 and less than or equal to M.
  • the processing module 92 is further configured to determine, in the determining module 93, the coefficient value c1 of the fitting linear term and the fitting constant term
  • the processing module 92 determines, in the determining module 93, the coefficient value c1 of the fitting linear term and the fitting constant term
  • f (t i ) is a fitted frequency offset value based on the ith temperature value obtained by the frequency offset curve f (t), Is the test frequency offset of the i-th temperature value, Is the average frequency deviation of N temperature values obtained based on the frequency deviation curve f (t), N is the number of the at least three temperature values, and i is a positive integer greater than or equal to 1 and less than or equal to N;
  • the determination module 93 is further configured to update a determination result of whether the crystal is qualified according to the correlation coefficient value R 2 .
  • the processing module 92 is further configured to determine, in the determining module 93, the coefficient value c1 of the fitting linear term and the fitting constant term
  • the value c0 determines that the crystal is qualified
  • at least two sets of undetermined coefficients of the frequency deviation curve are determined according to two adjacent temperature values of the at least three temperature values and a frequency deviation test value corresponding to each temperature value, Obtaining at least one set of undetermined coefficient absolute values according to the at least two sets of undetermined coefficients;
  • the set of undetermined coefficients of each group includes: a linear term coefficient value and a constant term value
  • the absolute value of each set of undetermined coefficients includes: an absolute value of a linear term coefficient and an absolute value of a constant term coefficient
  • the linear coefficient The absolute value is the absolute value of the difference between the two first-order coefficients of the adjacent two sets of undetermined coefficients
  • the absolute value of the constant term coefficient is the absolute value of the difference between the two constant terms of the adjacent two sets of undetermined coefficients. value
  • the determination module 93 is further configured to update the determination result of whether the crystal is qualified according to the absolute value of the at least one set of coefficients to be determined.
  • the processing module 92 is further configured to determine, in the determining module 93, the coefficient value c1 of the fitting linear term and the fitting constant term
  • each temperature of the at least three temperature values is obtained based on the frequency deviation curve f (t) obtained by the fitted first-order coefficient value c1 and the fitted constant term value c0.
  • the value of the fitted frequency offset corresponding to the value and based on the following formula (5), according to the test temperature value corresponding to each of the at least three temperature values and the value corresponding to each of the at least three temperature values Fitting a frequency offset value to determine a residual value difference corresponding to each of the temperature values;
  • RES (t i ) is the residual value difference corresponding to the i-th temperature value
  • f (t i ) is the fitted frequency offset value of the i-th temperature value obtained based on the frequency deviation curve f (t)
  • a test frequency offset value of an i-th temperature value, i is a temperature value of the at least three temperature values
  • the determination module 93 is further configured to update a determination result of whether the crystal is qualified based on a residual value difference corresponding to each of the at least three temperature values.
  • the determining module 93 is further configured to update the based on a residual value difference corresponding to each of the at least three temperature values.
  • the results of the determination of whether the crystal is qualified are as follows:
  • the determining module 93 is further configured to determine at least two residual error change rates RES_s based on the following formula (6) based on the residual value differences corresponding to two adjacent temperature values among the at least three temperature values, and according to The at least two residual error change rates update the determination result of whether the crystal is qualified;
  • t2 and t1 are two adjacent temperature values among the at least three temperature values, RES (t1) is a residual value difference corresponding to the temperature value t1, and RES (t2) is a residual value difference corresponding to the temperature value t2. , T2 is greater than t1.
  • the crystal determination device provided in this embodiment may be used to execute the technical solutions of the method embodiments shown in FIG. 4, FIG. 5, FIG. 6, and FIG. 8.
  • the specific implementation manners and technical effects are similar, and are not repeated here.
  • each module of the above device is only a division of logical functions. In actual implementation, it may be fully or partially integrated into a physical entity, or it may be physically separated. And these modules can all be implemented in the form of software through processing element calls; they can also be implemented in hardware; all modules can be implemented in the form of software called by processing elements, and some modules can be implemented in hardware.
  • the determination module may be a separately established processing element, or may be integrated and implemented in a chip of the above-mentioned device. In addition, it may also be stored in the memory of the above-mentioned device in the form of a program code, and may be processed by a certain processing element of the above-mentioned device.
  • each step of the above method or each of the above modules may be completed by an integrated logic circuit of hardware in a processor element or an instruction in the form of software.
  • the above modules may be one or more integrated circuits configured to implement the above method, for example, one or more application specific integrated circuits (ASICs), or one or more microprocessors (digital singnal processor (DSP), or one or more field programmable gate array (FPGA).
  • ASICs application specific integrated circuits
  • DSP digital singnal processor
  • FPGA field programmable gate array
  • the processing element may be a general-purpose processor, such as a central processing unit (CPU) or other processors that can call program code.
  • CPU central processing unit
  • these modules can be integrated together and implemented in the form of a system-on-a-chip (SOC).
  • SOC system-on-a-chip
  • the computer program product includes one or more computer instructions.
  • the computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices.
  • the computer instructions may be stored in a readable storage medium or transmitted from one readable storage medium to another readable storage medium.
  • the computer instructions may be transmitted from a website site, computer, server, or data center through a wired (for example, coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (such as infrared, wireless, microwave, etc.) transmission to another website site, computer, server or data center.
  • the readable storage medium may be any available medium that can be accessed by a computer or a data storage device such as a server, a data center, and the like that includes one or more available medium integration.
  • the available medium may be a magnetic medium (for example, a floppy disk, a hard disk, a magnetic tape), an optical medium (for example, a DVD), or a semiconductor medium (for example, a solid state disk (SSD)).
  • FIG. 10 is a schematic structural diagram of a second embodiment of a crystal determination device according to an embodiment of the present application.
  • the crystal determination device may include: a crystal 101, a temperature sensor 102, an analog-to-digital converter ADC 103, and a power management unit PMU chip 104.
  • the temperature sensor 102 is configured to obtain at least three temperature values of the crystal in a preset temperature range, and a test frequency offset value corresponding to each of the temperature values;
  • the ADC 103 is configured to perform analog-to-digital conversion processing on the at least three temperature values obtained by the temperature sensor 102 and a test frequency offset value corresponding to each of the temperature values;
  • the PMU chip 104 is configured to determine, based on the at least three temperature values processed by the ADC 103 and a test frequency offset value corresponding to each of the temperature values, the position of the crystal in the preset temperature range.
  • the fitting first-order term coefficient value c1 and the fitting constant term value c0 of the corresponding frequency deviation curve f (t) of the crystal are determined according to the determined fitting first-order coefficient value c1 and the fitting constant term value c0 of the fitting. Whether the crystal is qualified;
  • t temperature value variable
  • t0 reference temperature value
  • f (t) frequency offset value when temperature value is t.
  • the PMU chip 104 is specifically configured to use the at least three temperature values processed by the ADC 103 and corresponding to each of the temperature values.
  • a frequency offset value is tested, and a least-squares method is used to calculate a fitted first-order coefficient value c1 and a fitted constant term value c0 of the frequency offset curve f (t).
  • the PMU chip 104 is specifically configured to be based on two temperature values of the at least three temperature values processed by the ADC 103 and each Frequency offset test values corresponding to the two temperature values, determine at least two sets of undetermined coefficients of the frequency offset curve, and determine an average of the coefficients of the first term according to the at least two sets of undetermined coefficients And constant term mean And the average of the linear coefficients As the fitted linear term coefficient value c1, average the constant term As the fitted constant term value c0;
  • the undetermined coefficients of each group include: a linear term coefficient value and a constant term value, and the average of the linear term coefficients Is an average value of coefficient values of all linear terms in the at least two sets of undetermined coefficients, and the average value of the constant terms Is the average of all constant term values in the at least two sets of undetermined coefficients.
  • the PMU chip 104 is further configured to be based on the following formula (2), according to all coefficient values of the first-order terms in the at least two sets of pending coefficients, and all The average of the linear coefficients To calculate the mean square error ⁇ c1 of the coefficient value c1 of the fitted primary term, based on the following formula (3), according to all constant term values in the at least two sets of pending coefficients and the constant term average To calculate the mean square error ⁇ c0 of the fitted constant term value c0 , determine the crystal according to the mean square error ⁇ c1 of the fitted linear term coefficient value c1 and the mean square error ⁇ c0 of the fitted constant term value c0 Eligibility;
  • (c1) j is the coefficient value of the linear term in the j-th group of pending coefficients
  • (c0) j is the constant term value in the j-th group of pending coefficients
  • M is the number of groups of the at least two sets of pending coefficients
  • j A positive integer greater than or equal to 1 and less than or equal to M.
  • the PMU chip 104 is further configured to determine the value according to the fitting linear term coefficient value c1 and the fitting constant term value c0.
  • the following formula (4) is used to obtain the fitted frequency deviation value f (t i ) corresponding to each of the at least three temperature values and Test frequency offset A correlation coefficient value R 2 therebetween, and updating a determination result of whether the crystal is qualified according to the correlation coefficient value R 2 ;
  • f (t i ) is a fitted frequency offset value based on the ith temperature value obtained by the frequency offset curve f (t), Is the test frequency offset of the i-th temperature value, Is the average value of the frequency deviations of the N temperature values obtained based on the frequency deviation curve f (t), N is the number of the at least three temperature values, and i is a positive integer greater than or equal to 1 and less than or equal to N.
  • the PMU chip 104 is further configured to determine the value according to the fitting linear term coefficient value c1 and the fitting constant term value c0.
  • the crystal is qualified, at least two sets of undetermined coefficients of the frequency deviation curve are determined according to two adjacent temperature values of the at least three temperature values processed by the ADC 103 and a frequency deviation test value corresponding to each temperature value, Obtaining at least one set of absolute coefficients according to the at least two sets of pending coefficients, and updating the determination result of whether the crystal is qualified according to the absolute values of the at least one set of pending coefficients
  • the set of undetermined coefficients of each group includes: a linear term coefficient value and a constant term value
  • the absolute value of each set of undetermined coefficients includes: an absolute value of a linear term coefficient and an absolute value of a constant term coefficient
  • the linear term coefficient The absolute value is the absolute value of the difference between the two first-order coefficients of the adjacent two sets of undetermined coefficients
  • the absolute value of the constant term coefficient is the absolute value of the difference between the two constant terms of the adjacent two sets of undetermined coefficients. value.
  • the PMU chip 104 is further configured to determine the value according to the fitting linear term coefficient value c1 and the fitting constant term value c0.
  • the crystal is qualified, based on the frequency deviation curve f (t) obtained by the fitted linear term coefficient value c1 and the fitted constant term value c0, a fitting corresponding to each of the at least three temperature values is obtained.
  • the frequency offset value and based on the following formula (5), according to the test temperature value corresponding to each of the at least three temperature values after processing by the ADC 103 and the temperature value corresponding to each of the at least three temperature values To fit the frequency offset value, determine the residual value difference corresponding to each of the temperature values, and update the residual value difference based on the residual value difference corresponding to each of the at least three temperature values after the ADC 103 processes. Describe the results of the crystal's eligibility;
  • RES (t i ) is the residual value difference corresponding to the i-th temperature value
  • f (t i ) is the fitted frequency offset value of the i-th temperature value obtained based on the frequency deviation curve f (t)
  • i is one of the at least three temperature values.
  • the PMU chip 104 is further configured to be based on a residual corresponding to each of the at least three temperature values after the ADC 103 processes.
  • the difference in value, and the result of determining whether the crystal is qualified is updated as follows:
  • the PMU chip 104 is further configured to determine at least two residual errors based on a residual value difference corresponding to two adjacent temperature values of the at least three temperature values after the processing by the ADC 103 based on the following formula (6): A change rate RES_s, and updating a determination result of whether the crystal is qualified according to the at least two residual error change rates;
  • t2 and t1 are two adjacent temperature values among the at least three temperature values, RES (t1) is a residual value difference corresponding to the temperature value t1, and RES (t2) is a residual value difference corresponding to the temperature value t2. , T2 is greater than t1.
  • the temperature sensor 102 may correspond to the obtaining module 91 in FIG. 9 described above
  • the ADC 103 may complete some functions of the processing module 92 described above
  • the PMU chip 104 may correspond to the processing module 92 and determination module shown in FIG. 9 described above. 93.
  • the crystal determination device provided in this embodiment may be used to execute the technical solutions of the method embodiments shown in FIG. 4, FIG. 5, FIG. 6, and FIG. 8.
  • the specific implementation manners and technical effects are similar, and are not repeated here.
  • An embodiment of the present application provides a storage medium.
  • the storage medium stores instructions.
  • the computer executes the technical solutions of the embodiments shown in FIG. 4, FIG. 5, FIG. 6, and FIG. 8. .
  • the embodiment of the present application provides a chip for running instructions, and the chip is configured to execute the technical solutions of the method embodiments shown in FIG. 4, FIG. 5, FIG. 6, and FIG. 8.
  • the term "plurality” herein refers to two or more.
  • the term “and / or” in this document is only a kind of association relationship describing related objects, which means that there can be three kinds of relationships, for example, A and / or B can mean: A exists alone, A and B exist simultaneously, and exists alone B these three cases.
  • the character "/" in this article generally indicates that the related objects are an "or” relationship; in the formula, the character "/" indicates that the related objects are a "divide” relationship.
  • the size of the serial numbers of the above processes does not mean the order of execution.
  • the execution order of each process should be determined by its function and internal logic, and should not be implemented in this application.
  • the implementation process of the example constitutes any limitation.

Landscapes

  • Oscillators With Electromechanical Resonators (AREA)
  • Control Of Temperature (AREA)

Abstract

一种晶体判定方法、装置及存储介质,其中,该方法包括:获取晶体在预设温度段的至少三个温度值,以及每个温度值对应的测试频偏值,根据该至少三个温度值以及每个温度值对应的测试频偏值,确定晶体在预设温度段时晶体对应频偏曲线的拟合一次项系数值和拟合常数项值,根据得到的拟合一次项系数值和拟合常数项值,判定该晶体是否合格。该方法的判定结果准确度高,可靠性高,避免了不合格晶体无法被发现的问题。

Description

晶体判定方法、装置及存储介质 技术领域
本申请涉及通信技术领域,尤其涉及一种晶体判定方法、装置及存储介质。
背景技术
通常情况下,芯片上的时钟源通常采用无源晶体实现,鉴于无源晶体的频偏值随温度值的变化而变化,因而,对于时钟频偏值有严格要求的芯片,通常会增加一个热敏电阻器来测试无源晶体的温度值,进而利用不同温度值下的不同频偏值拟合出频偏曲线,并根据该频偏曲线和温度值进行频偏补偿处理。现阶段,晶体的频偏值和温度值采用如下拟合频偏曲线表示:f(t)=c3(t-t0) 3+c2(t-t0) 2+c1(t-t0)+c0,式中,t:温度值,t0:基准温度值,c0:常数项,c1:一次项系数,c2:二次项系数,c3:三次项系数,f(t):温度值为t时的频偏值。
目前,基于频偏值和温度值的对应关系,可以通过提取两个温度值对应的频偏值计算c1值和c0值,并通过c1值和c0值来判定晶体是否合格,在确定该晶体合格时,将该c1值和c0值作为拟合频偏曲线的c1值和c0值,而c2值和c3值采用给定的默认值。具体的,首先提取一个温度值对应的频偏值,升高给定温度后再提取第二个温度值对应的频偏值,由于常温段频偏曲线接近于直线,2次项和3次项可以忽略不计,这样利用这两个温度值和以及对应的频偏值拟合的直线可以求解出c1值和c0值,其次判断该c1值和c0值是否分别满足预设门限值,若不满足,则直接判定该晶体不合格。
然而,通过上述方式计算出来的c1值和c0值会存在较大偏差,致使很多不合格晶体无法被发现。例如,当晶体频偏曲线在两个温度值之间出现了较大的跳变,且其中一个温度值对应的频偏值恰好处于不稳定的频偏值之间时,通过上述方法计算出c1值和c0值可能不准确,但可能满足c1值和c0值的门限值,这样利用该c1值和c0值拟合出的全温段频偏曲线和实际的频偏曲线便相差较大。
发明内容
本申请实施例提供一种晶体判定方法、装置及存储介质,以解决现有技术中由于晶体对应拟合频偏曲线的一次相系数值和常数项值不准确,致使很多不合格晶体无法被发现的问题。
本申请第一方面提供一种晶体判定方法,包括:
获取晶体在预设温度段的至少三个温度值,以及每个所述温度值对应的测试频偏值;
根据所述至少三个温度值以及每个所述温度值对应的测试频偏值,确定所述晶体在所述预设温度段时所述晶体对应频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0,所述频偏曲线f(t)采用公式(1)表示:
f(t)=c1(t-t0)+c0             (1)
式中,t:温度值变量,t0:基准温度值,f(t):温度值为t时的频偏值;
根据所述拟合一次项系数值c1和所述拟合常数项值c0,判定所述晶体是否合格。
本申请的技术方案,通过采用至少三个温度值及每个温度值对应的频偏值判定晶体是否合格,参与判定的温度值和频偏值多,判定结果准确高,可靠性高,避免了不合格晶体无法被发现的问题。
可选的,在第一方面的一种可能实现方式中,所述根据所述至少三个温度值以及每个所述温度值对应的测试频偏值,确定所述晶体在所述预设温度段时的频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0,包括:
利用所述至少三个温度值以及每个所述温度值对应的测试频偏值,通过最小二乘法,计算所述频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0。
在本实施例中,利用最小二乘法可以简便地求得拟合一次项系数值c1和拟合常数项值c0,并使得求得的拟合一次项系数值c1和拟合常数项值c0与理论数值之间误差的平方和为最小,为后续得到准确的晶体判定结果奠定了基础。
可选的,在第一方面的另一种可能实现方式中,所述根据所述至少三个温度值以及每个所述温度值对应的测试频偏值,确定所述晶体在所述预设温度段时的频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0,包括:
根据所述至少三个温度值中的两个温度值以及每个温度值对应的频偏测试值,确定所述频偏曲线的至少两组待定系数,每组所述待定系数包括:一个一次项系数值和一个常数项值;
根据所述至少两组待定系数,确定一次项系数平均值
Figure PCTCN2018094630-appb-000001
和常数项平均值
Figure PCTCN2018094630-appb-000002
所述一次项系数平均值
Figure PCTCN2018094630-appb-000003
为所述至少两组待定系数中所有一次项系数值的平均值,所述常数项平均值
Figure PCTCN2018094630-appb-000004
为所述至少两组待定系数中所有常数项值的平均值;
将所述一次项系数平均值
Figure PCTCN2018094630-appb-000005
作为所述拟合一次项系数值c1,将所述常数项平均值
Figure PCTCN2018094630-appb-000006
作为所述拟合常数项值c0。
由于平均值可以反映一组数据集中的趋势,因而,上述一次项系数平均值
Figure PCTCN2018094630-appb-000007
更接近上述频偏曲线的斜率,上述常数项平均值
Figure PCTCN2018094630-appb-000008
更接近于上述频偏曲线的常数项,所以,将该一次项系数平均值
Figure PCTCN2018094630-appb-000009
作为频偏曲线的拟合一次项系数值c1,将该常数项平均值
Figure PCTCN2018094630-appb-000010
作为频偏曲线的拟合常数项值c0可以更精确的反映一次项系数值和常数项值的趋势,得到的拟合一次项系数值和拟合常数项值准确度高。
可选的,在第一方面的该种可能实现方式中,所述根据所述拟合一次项系数值c1和所述拟合常数项值c0,判定所述晶体是否合格,包括:
基于如下公式(2),根据所述至少两组待定系数中所有一次项系数值,以及所述一次项系数平均值
Figure PCTCN2018094630-appb-000011
计算所述拟合一次项系数值c1的均方差σ c1
Figure PCTCN2018094630-appb-000012
基于如下公式(3),根据所述至少两组待定系数中所有常数项值和所述常数项平均值
Figure PCTCN2018094630-appb-000013
计算所述拟合常数项值c0的均方差σ c0
Figure PCTCN2018094630-appb-000014
式中,(c1) j为第j组待定系数中的一次项系数值,(c0) j为第j组待定系数中的常数项值,M为所述至少两组待定系数的组数量,j为大于或等于1且小于或等于M的正整数;
根据所述拟合一次项系数值c1的均方差σ c1以及所述拟合常数项值c0的均方差σ c0,判定所述晶体是否合格。
在本申请实施例中,利用均方差可以描述数据资料集中各数据与平均值的离散程度的特点,计算拟合一次项系数值c1的均方差σ c1以及拟合常数项值c0的均方差σ c0,进而判定晶体是否合格,该方法易于实现,判定准确度高。
可选的,在第一方面的再一种可能实现方式中,所述方法还包括:
在根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,基于所述频偏曲线f(t),通过如下公式(4),获取所述至少三个温度值中每个所述温度值对应的拟合频偏值f(t i)与测试频偏值
Figure PCTCN2018094630-appb-000015
之间的相关系数值R 2
Figure PCTCN2018094630-appb-000016
式中,f(t i)为基于所述频偏曲线f(t)得到的第i个温度值的拟合频偏值,
Figure PCTCN2018094630-appb-000017
为第i个温度值的测试频偏值,
Figure PCTCN2018094630-appb-000018
为基于所述频偏曲线f(t)得到的N个温度值的频偏平均值,N为所述至少三个温度值的数量,i为大于或等于1且小于或等于N的正整数;
根据所述相关系数值R 2,更新所述晶体是否合格的判定结果。
在该技术方案中,由于拟合频偏值和测试频偏值的相关系数值可以反映上述确定的拟合一次项系数值c1和拟合常数项值c0的准确程度,因而,该技术方案判定晶体是否合格的判定结果更加准确,可靠性更高。
可选的,在第一方面的又一种可能实现方式中,所述方法还包括:
在根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,根据所述至少三个温度值中的两个相邻温度值以及每个温度值对应的频偏测试值,确定所述频偏曲线的至少两组待定系数,每组所述待定系数包括:一个一次项系数值和一个常数项值;
根据所述至少两组待定系数,获取至少一组待定系数绝对值,每组所述待定系数绝对值包括:一个一次项系数绝对值和一个常数项系数绝对值,所述一次项系数绝对值是相邻两组待定系数中的两个一次项系数值作差后的绝对值,所述常数项系数绝对值是相邻两组待定系数中的两个常数项值作差后的绝对值;
根据所述至少一组待定系数绝对值,更新所述晶体是否合格的判定结果。
该技术方案在根据拟合一次项系数值c1和拟合常数项值c0确定出晶体合格的基础上,增加了相邻一次项系数值和常数项值变化幅度来进一步判定晶体是否合格,其在保证判定结果准确的前提下,技术方案简单,易于实现。
可选的,在第一方面的又一种可能实现方式中,所述方法还包括:
在根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,基于所述拟合一次项系数值c1和所述拟合常数项值c0得到的频偏曲线f(t),获取所述至少三个温度值中每个温度值对应的拟合频偏值;
基于如下公式(5),根据所述至少三个温度值中每个温度值对应的测试温度值和所述至少三个温度值中每个温度值对应的拟合频偏值,确定每个所述温度值对应的残余值差;
Figure PCTCN2018094630-appb-000019
式中,RES(t i)为第i个温度值对应的残余值差,f(t i)为基于所述频偏曲线f(t)得到的第i个温度值的拟合频偏值,
Figure PCTCN2018094630-appb-000020
为第i个温度值的测试频偏值,i为所述至少三个温度值中的1个温度值;
基于所述至少三个温度值中每个所述温度值对应的残余值差,更新所述晶体是否合格的判定结果。
该技术方案在根据拟合一次项系数值c1和拟合常数项值c0确定出晶体合格的基础上,增加了残余值差来辅助判断晶体是否合格,使得晶体判别的准确度更高。
可选的,在第一方面的该种可能实现方式中,所述基于所述至少三个温度值中每个所述温度值对应的残余值差,更新所述晶体是否合格的判定结果,包括:
基于如下公式(6),根据所述至少三个温度值中两个相邻温度值分别对应的残余值差,确定至少两个残余误差变化率RES_s;
Figure PCTCN2018094630-appb-000021
式中,t2和t1为所述至少三个温度值中相邻的两个温度值,RES(t1)为温度值t1对应的残余值差,RES(t2)为温度值t2对应的残余值差,t2大于t1;
根据所述至少两个残余误差变化率RES_s,更新所述晶体是否合格的判定结果。
该技术方案在根据拟合一次项系数值c1和拟合常数项值c0确定出晶体合格的基础上,再通过残余误差变化率来判定晶体是否合格,可以保证频偏曲线上拟合得到的所有频偏点的准确性,使得晶体判别的准确度更高。
本申请第二方面提供一种晶体判定装置,包括:晶体、温度传感器、模数转换器ADC和电源管理单元PMU芯片;
所述温度传感器,用于获取所述晶体在预设温度段的至少三个温度值,以及每个所述温度值对应的测试频偏值;
所述ADC,用于对所述温度传感器获取到的所述至少三个温度值以及每个所述温度值对应的测试频偏值进行模数转换处理;
所述PMU芯片,用于根据所述ADC处理后的所述至少三个温度值以及每个所述温度值对应的测试频偏值,确定所述晶体在所述预设温度段时所述晶体对应频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0,以及根据确定的所述拟合一次项系数值c1和所述拟合常数项值c0,判定所述晶体是否合格;
其中,所述频偏曲线f(t)采用公式(1)表示:
f(t)=c1(t-t0)+c0               (1)
式中,t:温度值变量,t0:基准温度值,f(t):温度值为t时的频偏值。
可选的,在第二方面的一种可能实现方式中,所述PMU芯片,具体用于利用所述ADC处理后的所述至少三个温度值以及每个所述温度值对应的测试频偏值,通过最小二乘法,计算所述频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0。
可选的,在第二方面的另一种可能实现方式中,所述PMU芯片,具体用于根据所述ADC处理后的所述至少三个温度值中的两个温度值以及每个温度值对应的频偏测试值,确定所述频偏曲线的至少两组待定系数,根据所述至少两组待定系数,确定一次项系数平均 值
Figure PCTCN2018094630-appb-000022
和常数项平均值
Figure PCTCN2018094630-appb-000023
以及将所述一次项系数平均值
Figure PCTCN2018094630-appb-000024
作为所述拟合一次项系数值c1,将所述常数项平均值
Figure PCTCN2018094630-appb-000025
作为所述拟合常数项值c0;
其中,每组所述待定系数包括:一个一次项系数值和一个常数项值,所述一次项系数平均值
Figure PCTCN2018094630-appb-000026
为所述至少两组待定系数中所有一次项系数值的平均值,所述常数项平均值
Figure PCTCN2018094630-appb-000027
为所述至少两组待定系数中所有常数项值的平均值。
可选的,在第二方面的该种可能实现方式中,所述PMU芯片,还用于基于如下公式(2),根据所述至少两组待定系数中所有一次项系数值,以及所述一次项系数平均值
Figure PCTCN2018094630-appb-000028
计算所述拟合一次项系数值c1的均方差σ c1,基于如下公式(3),根据所述至少两组待定系数中所有常数项值和所述常数项平均值
Figure PCTCN2018094630-appb-000029
计算所述拟合常数项值c0的均方差σ c0,根据所述拟合一次项系数值c1的均方差σ c1以及所述拟合常数项值c0的均方差σ c0,判定所述晶体是否合格;
Figure PCTCN2018094630-appb-000030
Figure PCTCN2018094630-appb-000031
式中,(c1) j为第j组待定系数中的一次项系数值,(c0) j为第j组待定系数中的常数项值,M为所述至少两组待定系数的组数量,j为大于或等于1且小于或等于M的正整数。
可选的,在第二方面的再一种可能实现方式中,所述PMU芯片,还用于在根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,基于所述频偏曲线f(t),通过如下公式(4),获取所述至少三个温度值中每个所述温度值对应的拟合频偏值f(t i)与测试频偏值
Figure PCTCN2018094630-appb-000032
之间的相关系数值R 2,以及根据所述相关系数值R 2,更新所述晶体是否合格的判定结果;
Figure PCTCN2018094630-appb-000033
式中,f(t i)为基于所述频偏曲线f(t)得到的第i个温度值的拟合频偏值,
Figure PCTCN2018094630-appb-000034
为第i个温度值的测试频偏值,
Figure PCTCN2018094630-appb-000035
为基于所述频偏曲线f(t)得到的N个温度值的频偏平均值,N为所述至少三个温度值的数量,i为大于或等于1且小于或等于N的正整数。
可选的,在第二方面的又一种可能实现方式中,所述PMU芯片,还用于在根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,根据所述ADC处理后所述至少三个温度值中的两个相邻温度值以及每个温度值对应的频偏测试值,确定所述频偏曲线的至少两组待定系数,根据所述至少两组待定系数,获取至少一组待定系数绝对值,以及根据所述至少一组待定系数绝对值,更新所述晶体是否合格的判定结果
其中,每组所述待定系数包括:一个一次项系数值和一个常数项值,每组所述待定系数绝对值包括:一个一次项系数绝对值和一个常数项系数绝对值,所述一次项系数绝对值是相邻两组待定系数中的两个一次项系数值作差后的绝对值,所述常数项系数绝对值是相邻两组待定系数中的两个常数项值作差后的绝对值。
可选的,在第二方面的又一种可能实现方式中,所述PMU芯片,还用于在根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,基于所述拟合一次项系 数值c1和所述拟合常数项值c0得到的频偏曲线f(t),获取所述至少三个温度值中每个温度值对应的拟合频偏值,以及基于如下公式(5),根据所述ADC处理后所述至少三个温度值中每个温度值对应的测试温度值和所述至少三个温度值中每个温度值对应的拟合频偏值,确定每个所述温度值对应的残余值差,以及基于所述ADC处理后所述至少三个温度值中每个所述温度值对应的残余值差,更新所述晶体是否合格的判定结果;
Figure PCTCN2018094630-appb-000036
式中,RES(t i)为第i个温度值对应的残余值差,f(t i)为基于所述频偏曲线f(t)得到的第i个温度值的拟合频偏值,
Figure PCTCN2018094630-appb-000037
为第i个温度值的测试频偏值,i为所述至少三个温度值中的1个温度值。
可选的,在第二方面的该种可能实现方式中,所述PMU芯片,还用于基于所述ADC处理后所述至少三个温度值中每个所述温度值对应的残余值差,更新所述晶体是否合格的判定结果,具体为:
所述PMU芯片,还用于基于如下公式(6),根据所述ADC处理后所述至少三个温度值中两个相邻温度值分别对应的残余值差,确定至少两个残余误差变化率RES_s,以及根据所述至少两个残余误差变化率,更新所述晶体是否合格的判定结果;
Figure PCTCN2018094630-appb-000038
式中,t2和t1为所述至少三个温度值中相邻的两个温度值,RES(t1)为温度值t1对应的残余值差,RES(t2)为温度值t2对应的残余值差,t2大于t1。
关于本申请实施例第二方面各实现可能的有益效果可参见第一方面各实现可能中的记载,此处不再赘述。
本申请实施例第三方面提供一种晶体判定装置,所述晶体判定装置包括获取模块、处理模块和判定模块,所述获取模块、所述处理模块和所述判定模块,用于执行本申请第一方面提供的方法。
本申请实施例第四方面提供一种晶体判定装置,包括用于执行以上第一方面各中实现可能的至少一个处理元件(或芯片)。
本申请实施例第五方面提供一种存储介质,所述存储介质中存储有指令,当其在计算机上运行时,使得计算机执行上述第一方面提供的方法。
本申请实施例第六方面提供一种包含指令的计算机程序产品,当其在计算机上运行时,使得计算机执行上述第一方面提供的方法。
在以上各个方面中,通过获取晶体在预设温度段的至少三个温度值,以及每个温度值对应的测试频偏值,并根据上述至少三个温度值以及每个温度值对应的测试频偏值,确定晶体在该预设温度段时晶体对应频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0,最后根据拟合一次项系数值c1和拟合常数项值c0,判定晶体是否合格。该技术方案中通过采用至少三个温度值及每个温度值对应的频偏值判定晶体是否合格,判定结果准确高,可靠性高,避免了不合格晶体无法被发现的问题。
附图说明
图1为本申请实施例提供的一种晶体判定电路的结构示意图;
图2为现有技术中提取的两个温度点在实际频偏曲线上的一种分布示意图;
图3为利用图2所示的两个温度点拟合得到的拟合频偏曲线与实际频偏曲线的分布示意图;
图4为本申请实施例提供的晶体判定方法实施例一的流程示意图;
图5为本申请提供的晶体判定方法实施例二的流程示意图;
图6为本申请提供的晶体判定方法实施例三的流程示意图;
图7为图6所示的实施例中每组待定系数的分布示意图;
图8为本申请提供的晶体判定方法实施例四的流程示意图;
图9为本申请实施例提供的晶体判定装置实施例一的结构示意图;
图10为本申请实施例提供的晶体判定装置实施例二的结构示意图。
具体实施方式
本申请下述各实施例提供的晶体判定方法,可适用于晶体判定电路中。图1为本申请实施例提供的一种晶体判定电路的结构示意图。如图1所示,该晶体判定电路中可以包括无源晶体11、温度传感器12、电源管理单元(power management unit,PMU)芯片13和模数转换器(analog-to-digital converter,ADC)14。其中,温度传感器12与无源晶体11接触连接,模数转换器14设置在电源管理单元芯片13上,温度传感器12与模数转换器14电连接,该温度传感器12用于检测无源晶体11的温度,并将检测到的温度传递给模数转换器14,以根据模数转换器14输出的值确定出无源晶体的温度与频偏值之间的关系。可选的,该晶体判定电路还可以包括供电电源、电阻R1、负载电容等元器件,而且,该晶体判定电路还需要接地,本申请实施例不限于此。
本申请实施例涉及的无源晶体需要搭配数字信号处理器(digital signal processor,DSP)片内的振荡器使用。无源晶体的优点是没有电压的问题,信号电平是可变的,也就是说,无源晶振的信号电平是根据起振电路来决定的,同样的晶体可以适用于多种电压,可用于多种不同时钟信号电压要求的DSP,而且价格通常也较低。因此,通常情况下,如果条件许可,建议使用无源晶体。但是,由于无源晶体相对于晶振而言信号质量较差,通常需要精确匹配外围电路(用于信号匹配的电容、电感、电阻等),更换不同频率的晶体时周边配置电路需要做相应的调整。可选的,该本申请实施例中的无源晶体可以是精度较高的石英晶体。
在本申请实施例中,温度传感器可以是由负温度系数(negative temperature coefficient,NTC)制成的具有负温度系数(NTC)的热敏电阻。可选的,NTC是指随温度上升电阻呈指数关系减小、具有负温度系数的热敏电阻现象和材料。
可选的,PMU芯片,是一种高度集成的、针对便携式应用的电源管理方案,即将传统分立的若干类电源管理器件整合在单个封装之内,这样可实现更高的电源转换效率和更低功耗,及更少的组件数以适应缩小的板级空间。PMU芯片是在电子设备系统中担负起对电能的变换、分配、检测及其他电能管理的职责的芯片。
可选的,模数转换器14是指将连续变化的模拟信号转换为离散的数字信号的器件。在本申请实施例中,模数转换器14用于将从温度传感器接收到的模拟温度信号转换为离散的数字信号,以便PMU芯片进行处理。
本申请实施例中,“多个”是指两个或两个以上。“和/或”,描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。字符“/”一般表示前后关联对象是一种“或”的关系。
下面首先针对现有技术中众多不合格晶体无法被发现的问题对本申请的技术方案进行简要说明。
在现有技术中,计算晶体对应频偏曲线的c1值和c0值是在常温段,通过提取晶体的两个温度点(每个温度点包括温度值和该温度值对应的频偏值)进行拟合得到的。但是,在某些情况下,利用该方法计算出来的c1值和c0值会存在较大的偏差,致使很多不合格晶体无法被发现的问题。
举例来说,图2为现有技术中提取的两个温度点在实际频偏曲线上的一种分布示意图。图3为利用图2所示的两个温度点拟合得到的拟合频偏曲线与实际频偏曲线的分布示意图。如图2所示,当晶体的实际频偏曲线在第1个温度点和第2个温度点之间出现了较大的跳变,且其中有一个温度点恰好处于不稳定的频偏曲线段时,这时利用现有技术的方法计算出的c1值和c0值有可能就是不准确的,但是有时也满足c1值和c0值的误差门限值,致使最终拟合的全温段频偏曲线和实际频偏曲线相差较大,具体可参照图3所示,在图3中,细实线表示实际频偏曲线,细虚线表示拟合频偏曲线。
针对现有技术中的上述问题,本申请实施例提供了一种晶体判定方法、装置及存储介质,用于解决由于频偏曲线的一次项系数值和常数项值不准确致使不合格晶体无法被发现的问题。下面,通过具体实施例对本申请的技术方案进行详细说明。
需要说明的是,下面这几个具体的实施例可以相互结合,对于相同或相似的概念或过程可能在某些实施例中不再赘述。
图4为本申请实施例提供的晶体判定方法实施例一的流程示意图。可选的,该晶体判定方法应用于图1所示的场景中。如图4所示,在本申请实施例中,该晶体判定方法可以包括如下步骤:
步骤41:获取晶体在预设温度段的至少三个温度值,以及每个温度值对应的测试频偏值。
可选的,在本申请的实施例中,当需要判定晶体是否合格时,可以参照上述图1所示的晶体判定电路,首先控制该晶体的温度在预设温度段内发生变化,其次通过测试方法获取晶体在该预设温度段中的至少三个温度值,相应的,通过测试方法获取晶体在上述每个温度值时的测试频偏值。
可选的,在本实施例中,该预设温度段可以指俗话中的常温段,通常情况下,常温段的温度范围可以是0℃至25℃。
步骤42:根据上述至少三个温度值以及每个温度值对应的测试频偏值,确定晶体在上述预设温度段时该晶体对应频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0。
所述频偏曲线采用公式(1)表示:
f(t)=c1(t-t0)+c0                (1)
可选的,在本申请实施例中,经过实践证明,晶体在常温段时的频偏曲线接近于直线。因而,晶体在上述预设温度段时,晶体的频偏曲线可以采用上述公式(1)表示。式中,t0为基准温度值,c0为要确定的拟合常数项值,c1为要确定的拟合一次项系数值,t为温度值变量,f(t)指温度值为t时的频偏值。
在本实施例中,当获取到晶体的上述至少三个温度值以及每个温度值对应的测试频偏值之后,将上述至少三个温度值以及每个温度值对应的测试频偏值带入上述公式(1)可以求出晶体在上述预设温度段时该晶体对应频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0。
可选的,该步骤(根据上述至少三个温度值以及每个温度值对应的测试频偏值确定晶体在预设温度段时该晶体对应频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0)的可能实现方式可以为如下两种可能实现方式中的任意一种,具体可参见下述介绍。
可选的,在本申请的一种可能实现方式中,该步骤可以通过如下可能实现方式实现,具体如下:
利用上述至少三个温度值以及每个温度值对应的测试频偏值,通过最小二乘法,计算频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0。
可选的,在该种可能实现方式中,最小二乘法的实现原理是:将上述至少三个温度值中每个温度值对应的测试频偏值与拟合频偏值的离差的平方和最小作为求拟合一次项系数值c1和拟合常数项值c0的依据。
具体的,在本申请实施例中,假设f(t i)为基于频偏曲线f(t)得到的第i个温度值的拟合频偏值,
Figure PCTCN2018094630-appb-000039
为第i个温度值的测试频偏值,求拟合一次项系数值c1和拟合常数项值c0实际上就是求
Figure PCTCN2018094630-appb-000040
为最小值时的c1和c0。可选的,当
Figure PCTCN2018094630-appb-000041
的值为最小时,分别对c1和c0求偏导数,进而令两个偏导数公式等于零,从而求出拟合一次项系数值c1和拟合常数项值c0。
因而,利用最小二乘法可以简便地求得拟合一次项系数值c1和拟合常数项值c0,并使得求得的拟合一次项系数值c1和拟合常数项值c0与理论数值之间误差的平方和为最小,为后续得到准确的晶体判定结果奠定了基础。
可选的,在本申请的另一种可能实现方式中,该步骤可以通过如下方式实现,具体参见如下步骤A1至步骤A3:
步骤A1:根据上述至少三个温度值中的两个温度值以及每个温度值对应的频偏测试值,确定频偏曲线的至少两组待定系数,其中,每组待定系数包括:一个一次项系数值和一个常数项值。
可选的,在该种可能实现方式中,通过从上述至少三个温度值中取出任意两个温度值以及每个温度值对应的频偏值,将其带入上述公式(1)所示的频偏曲线f(t),这样可以求出至少两组待定系数,即至少两组一次项系数值和常数项值。
步骤A2:根据上述至少两组待定系数,确定一次项系数平均值
Figure PCTCN2018094630-appb-000042
和常数项平均值
Figure PCTCN2018094630-appb-000043
其中,该一次项系数平均值
Figure PCTCN2018094630-appb-000044
为上述至少两组待定系数中所有一次项系数值的平均值,该常数项平均值
Figure PCTCN2018094630-appb-000045
为上述至少两组待定系数中所有常数项值的平均值。
可选的,当根据上述至少三个温度值以及每个温度值对应的频偏值确定出频偏曲线的至少两组待定系数时,将该至少两组待定系数中的所有一次项系数值求和后再除以所有一次项系数的个数,得到一次项系数平均值
Figure PCTCN2018094630-appb-000046
将上述至少两组待定系数中所有常数项值求和后再除以所有常数项的个数,得到常数项平均值
Figure PCTCN2018094630-appb-000047
步骤A3:将上述一次项系数平均值
Figure PCTCN2018094630-appb-000048
作为拟合一次项系数值c1,将上述常数项平均值
Figure PCTCN2018094630-appb-000049
作为拟合常数项值c0。
可选的,由于平均值可以反映一组数据集中的趋势,因而,上述一次项系数平均值
Figure PCTCN2018094630-appb-000050
更接近上述频偏曲线的斜率,上述常数项平均值
Figure PCTCN2018094630-appb-000051
更接近于上述频偏曲线的常数项,所以,当求出一次项系数平均值
Figure PCTCN2018094630-appb-000052
和常数项平均值
Figure PCTCN2018094630-appb-000053
之后,可以将该一次项系数平均值
Figure PCTCN2018094630-appb-000054
作为频偏曲线的拟合一次项系数值c1,将该常数项平均值
Figure PCTCN2018094630-appb-000055
作为频偏曲线的拟合常数项值c0。
值得说明的是,本申请实施例并不限定上述两种可能实现方式,其还可以包括其他可能实现方式,此处不再赘述。
步骤43:根据上述拟合一次项系数值c1和拟合常数项值c0,判定该晶体是否合格。
可选的,在晶体判定电路所在的芯片中可以分别预置频偏曲线的一次项系数值对应的一次项数值范围和常数项值对应的常数项数值范围,因而,在确定出频偏曲线的拟合一次项系数值c1和拟合常数项值c0之后,可以判定该拟合一次项系数值c1是否位于预置的一次项数值范围内且该拟合常数项值c0是否位于预置的常数项数值范围内,若是,则确定该晶体合格,若否,确定晶体不合格。
可选的,作为一种示例,当将上述求出的一次项系数平均值
Figure PCTCN2018094630-appb-000056
作为拟合一次项系数值c1,将常数项平均值
Figure PCTCN2018094630-appb-000057
作为拟合常数项值c0时,该步骤可以通过如下步骤B1至步骤B3实现:
步骤B1:基于如下公式(2),根据上述至少两组待定系数中所有一次项系数值,以及上述一次项系数平均值
Figure PCTCN2018094630-appb-000058
计算该拟合一次项系数值c1的均方差σ c1
Figure PCTCN2018094630-appb-000059
步骤B2:基于如下公式(3),根据上述至少两组待定系数中所有常数项值和上述常数项平均值
Figure PCTCN2018094630-appb-000060
计算该拟合常数项值c0的均方差σ c0
Figure PCTCN2018094630-appb-000061
式中,(c1) j为第j组待定系数中的一次项系数值,(c0) j为第j组待定系数中的常数项值,M为上述至少两组待定系数的组数量,j为大于或等于1且小于或等于M的正整数。
具体的,由于均方差可以描述数据资料集中各数据与平均值的离散程度,因而,本实施例中,可以根据上述确定的至少两组待定系数中的所有一次项系数值和所有一次项系数值的平均值,计算拟合一次项系数值c1的均方差σ c1,根据上述确定的至少两组待定系数中的所有常数项值和上述常数项平均值,计算拟合常数项值的均方差σ c0,进而确定至少两组待定系数中的所有一次项系数值与一次项系数平均值的离散程度和所有常数项值与常数项平均值的离散程度。
子步骤B3:根据上述拟合一次项系数值c1的均方差σ c1以及拟合常数项值c0的均方差σ c0,判定晶体是否合格。
可选的,由于拟合一次项系数值c1的均方差σ c1越小,表明上述至少两组待定系数中所有一次项系数值的波动越小,拟合常数项值c0的均方差σ c0越小,表明上述至少两组待定系数中所有常数项值的波动越小,从而可以根据其确定该晶体的稳定性能,所以,可以判定上述拟合一次项系数值c1的均方差σ c1是否位于预置的一次项均方差范围内且该拟合常数项值c0的均方差σ c0是否位于预置的常数项均方差范围内,若是,则确定该晶体合格,若否,确定晶体不合格。
值得说明的是,本申请实施例既不限定直接根据拟合一次项系数值c1和拟合常数项值c0来判定该晶体是否合格,也不限定通过拟合一次项系数值c1的均方差σ c1以及拟合常数项值c0的均方差σ c0来判定晶体是否合格,实际上,其还可能通过求拟合一次项系数值c1的相关系数、拟合常数项值c0的相关系数,或者拟合一次项系数值c1的统计量、拟合常数项值c0的统计量等来判定晶体是否合格,本申请实施例并不对其进行限定,其可根据实际需要进行确定。
本申请实施例提供的晶体判定方法,通过获取晶体在预设温度段的至少三个温度值,以及每个温度值对应的测试频偏值,并根据上述至少三个温度值以及每个温度值对应的测试频偏值,确定晶体在该预设温度段时晶体对应频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0,最后根据拟合一次项系数值c1和拟合常数项值c0,判定晶体是否合格。该技术方案中通过采用至少三个温度值及每个温度值对应的频偏值判定晶体是否合格,判定结果准确高,可靠性高,避免了不合格晶体无法被发现的问题。
可选的,在上述图4所示实施例的基础上,作为一种示例,图5为本申请提供的晶体判定方法实施例二的流程示意图。如图5所示,本申请实施例的晶体判定方法,在上述步骤43之后,还可以包括如下步骤51和步骤52:
步骤51:在根据拟合一次项系数值c1和拟合常数项值c0确定晶体合格时,基于上述频偏曲线f(t),通过如下公式(4),获取上述至少三个温度值中每个温度值对应的拟合频偏值f(t i)与测试频偏值
Figure PCTCN2018094630-appb-000062
之间的相关系数值R 2
Figure PCTCN2018094630-appb-000063
式中,f(t i)为基于频偏曲线f(t)得到的第i个温度值的拟合频偏值,
Figure PCTCN2018094630-appb-000064
为第i个温度值的测试频偏值,
Figure PCTCN2018094630-appb-000065
为基于频偏曲线f(t)得到的N个温度值的频偏平均值,N为上述至少三个温度值的数量,i为大于或等于1且小于或等于N的正整数。
步骤52:根据该相关系数值R 2,更新晶体是否合格的判定结果。
作为一种示例,由于相关系数可以表征两个变量之间的线性相关程度,相关系数值的绝对值小于等于1,相关系数值越接近1,表明两个变量之间的相关性越强。因而,在上述图4所示实施例中确定出频偏曲线的拟合一次项系数值c1和拟合常数项值c0时,相应的,可以确定拟合的频偏曲线,所以,在本申请实施例中,在根据拟合一次项系数值c1和拟合常数项值c0确定出晶体合格时,可以通过上述公式(4)计算上述至少三个温度值中每个温度值对应的拟合频偏值和测试频偏值之间的相关系数值R 2,进而根据该相关系数值的大小再次判定上述晶体是否合格,相应的,更新晶体是否合格的判定结果。
可选的,可以预先配置相关系数值的相关值范围,若拟合频偏值和测试频偏值之间的相关系数值R 2在相关值范围内,则认定晶体合格,否则,认定晶体不合格。
本申请实施例提供的晶体判定方法,在根据拟合一次项系数值c1和拟合常数项值c0确定晶体合格时,再基于频偏曲线f(t),通过如下公式(4),获取至少三个温度值中每个温度值对应的拟合频偏值f(t i)与测试频偏值
Figure PCTCN2018094630-appb-000066
之间的相关系数值R 2,并根据该相关系数值R 2,更新晶体是否合格的判定结果。该技术方案在图4所示实施例的基础上,再求取拟合频偏值和测试频偏值的相关系数值,由于该相关系数值可以反映上述确定的拟合一次项系数值c1和拟合常数项值c0的准确程度,因而,该技术方案判定晶体是否合格的判定结果更加准确,可靠性更高。
可选的,在上述图4所示实施例的基础上,作为另一种示例,图6为本申请提供的晶体判定方法实施例三的流程示意图。如图6所示,本申请实施例的晶体判定方法,在上述步骤43之后,还可以包括如下步骤61至步骤63:
步骤61:在根据拟合一次项系数值c1和拟合常数项值c0确定晶体合格时,根据上述至少三个温度值中的两个相邻温度值以及每个温度值对应的频偏测试值,确定频偏曲线的至少两组待定系数。
其中,每组待定系数包括:一个一次项系数值和一个常数项值。
可选的,在上述图4所示实施例的基础上,当根据拟合一次项系数值c1和拟合常数项值c0确定晶体合格时,可以基于相邻两个温度值以及每个温度值对应的频偏测试值可以计算得到一个一次项系数值和一个常数项值的原理,再次利用上述获取到的至少三个温度值以及每个温度值对应的频偏值,计算出频偏曲线的至少两组待定系数,每组待定系数均包括一个一次项系数值和一个常数项值。
例如,图7为图6所示的实施例中每组待定系数的分布示意图。如图7所示,在上述预设温度段内,假设一共获取到n个温度值以及每个温度值对应的频偏值,通过上述方法一共可以获取到n-1组待定系数,其中,n为大于2的整数。
步骤62:根据上述至少两组待定系数,获取至少一组待定系数绝对值。
其中,每组待定系数绝对值包括:一个一次项系数绝对值和一个常数项系数绝对值,该一次项系数绝对值是相邻两组待定系数中的两个一次项系数值作差后的绝对值,该常数项系数绝对值是相邻两组待定系数中的两个常数项值作差后的绝对值。
可选的,在得到频偏曲线的至少两组待定系数后,根据相邻两组待定系数,可以确定出一组待定系数绝对值,即将相邻两组待定系数中的两个一次项系数值作差后的绝对值作为该组待定系数绝对值中的一次项系数绝对值,将相邻两组待定系数中的两个常数项值作差后的绝对值作为该组待定系数绝对值中的常数项系数绝对值。类似的,根据上述至少两组待定系数可以得到至少一组待定系数绝对值。
步骤63:根据上述至少一组待定系数绝对值,更新晶体是否合格的判定结果。
可选的,在本实施例中,可以预先配置一次项系数绝对值的一次项绝对值范围和常数项绝对值的常数项绝对值范围,因而,在获取到至少一组待定系数绝对值后,从中取出最大的一次项系数绝对值和最大的常数项系数绝对值,将最大的一次项系数绝对值和预置的 一次项绝对值范围进行比较,将最大的常数项系数绝对值和预置的常数项绝对值范围进行比较,根据两者的大小关系确定晶体是否合格。
具体的,在最大的常数项系数绝对值小于或等于预置的常数项绝对值范围,且,最大的常数项系数绝对值小于或等于预置的常数项绝对值范围时,认定晶体合格,否则,认定晶体不合格。
本申请实施例提供的晶体判定方法,在根据拟合一次项系数值和拟合常数项值确定晶体合格时,可以再根据上述至少三个温度值中的两个相邻温度值以及每个温度值对应的频偏测试值,确定频偏曲线的至少两组待定系数,进而获取到至少一组待定系数绝对值,最后根据上述至少一组待定系数绝对值,更新晶体是否合格的判定结果。该技术方案在上述图4所示实施例的基础上,增加了相邻一次项系数值和常数项值变化幅度来判定晶体是否合格,其在保证判定结果准确的前提下,技术方案简单,易于实现。
可选的,在上述图4所示实施例的基础上,作为再一种示例,图8为本申请提供的晶体判定方法实施例四的流程示意图。如图8所示,本申请实施例的晶体判定方法,在上述步骤43之后,还可以包括如下步骤81至步骤83:
步骤81:在根据上述拟合一次项系数值c1和拟合常数项值c0确定晶体合格时,基于上述拟合一次项系数值c1和拟合常数项值c0得到的频偏曲线f(t),获取上述至少三个温度值中每个温度值对应的拟合频偏值。
可选的,将上述获取到的拟合一次项系数值c1和拟合常数项值c0带入晶体对应频偏曲线的公式时,便可以得到上述公式(1)所述的频偏曲线f(t),进而将上述至少三个温度值分别带入公式(1),便可以得到上述至少三个温度值中每个温度值对应的拟合频偏值。
步骤82:基于如下公式(5),根据至少三个温度值中每个温度值对应的测试温度值和至少三个温度值中每个温度值对应的拟合频偏值,确定每个温度值对应的残余值差;
Figure PCTCN2018094630-appb-000067
式中,RES(t i)为第i个温度值对应的残余值差,f(t i)为基于频偏曲线f(t)得到的第i个温度值的拟合频偏值,
Figure PCTCN2018094630-appb-000068
为第i个温度值的测试频偏值,i为至少三个温度值中的1个温度值。
可选的,可以将每个温度值对应的测试温度值和该温度值对应的拟合频偏值相减后的绝对值定义为该温度值对应的残余值差,因而,根据上述至少三个温度值中每个温度值对应的测试温度值和至少三个温度值中每个温度值对应的拟合频偏值,利用上述公式(5)可以得到上述至少三个温度值中每个温度值对应的残余值差。
步骤83:基于上述至少三个温度值中每个温度值对应的残余值差,更新上述晶体是否合格的判定结果。
可选的,在本实施例中,作为一种实现可能,基于上述至少三个温度值中每个温度值对应的残余值差,从中选出数值最大的残余值差,即最大残余值差,进而利用该最大残余值差,判定晶体是否合格。具体的,判定该最大残余值差是否介于预置的残余值范围内,若是,则认定晶体合格,否则,认定晶体不合格。相应的,根据该判定结果更新图4所示实施例中晶体是否合格的判定结果。
作为另一种实现可能,基于上述至少三个温度值中每个温度值对应的残余值差,可以求取所有温度值对应残余值差的平均值,即平均残余值差,进而利用该平均残余值差,判定晶体是否合格。相应的,在确定该判定结果后,根据该判定结果更新图4所示实施例中晶体是否合格的判定结果。
作为再一种实现可能,基于上述至少三个温度值中每个温度值对应的残余值差,可以求取所有温度值对应残余值差的和,进而基于该所有温度值对应残余值差的和,判定晶体是否合格。相应的,在确定该判定结果后,根据该判定结果更新图4所示实施例中晶体是否合格的判定结果。
进一步的,在本申请实施例中,该步骤83(基于上述至少三个温度值中每个温度值对应的残余值差,更新上述晶体是否合格的判定结果)还可以通过如下步骤C1和C2实现:
步骤C1:基于如下公式(6),根据上述至少三个温度值中两个相邻温度值分别对应的残余值差,确定至少两个残余误差变化率RES_s;
Figure PCTCN2018094630-appb-000069
式中,t2和t1为上述至少三个温度值中相邻的两个温度值,RES(t1)为温度值t1对应的残余值差,RES(t2)为温度值t2对应的残余值差,t2大于t1。
可选的,通过上述步骤82可知,上述至少三个温度值中的每个温度值对应一个残余值差,因而,基于公式(6),根据两个相邻温度值分别对应的残余值差,可以求取该两个相邻温度对应的两个残余差值之间的残余误差变化率RES_s,同理,根据上述至少三个温度值对应的残余值差,可以确定至少两个残余误差变化率RES_s。
步骤C2:根据上述至少两个残余误差变化率RES_s,更新上述晶体是否合格的判定结果。
可选的,在本实施例中,可以利用上述至少两个残余误差变化率RES_s中的一个进一步判定晶体是否合格。具体的,可以从上述至少两个残余误差变化率中选出数值最大的残余误差变化率,即最大残余误差变化率,利用该最大残余误差变化率判定晶体是否合格。或者,也可以求取上述至少两个残余误差变化率中所有残余误差变化率的平均值,即平均残余误差变化率,利用该平均残余误差变化率判定晶体是否合格。再或者,也可以求取上述至少两个残余误差变化率中所有残余误差变化率的和,基于所有残余误差变化率的和来判定晶体是否合格。
通过求残余误差变化率可以保证所有温度值对应的拟合频偏值拟合的准确性,进而保证了求出的拟合一次项系数值和拟合常数项值比较准确。
本申请实施例提供的晶体判定方法,在根据上述拟合一次项系数值和拟合常数项值确定晶体合格时,再基于该拟合一次项系数值和所述拟合常数项值得到的频偏曲线,获取上述至少三个温度值中每个温度值对应的拟合频偏值,进而根据上述至少三个温度值中每个温度值对应的测试温度值和至少三个温度值中每个温度值对应的拟合频偏值,确定每个温度值对应的残余值差,最后基于该至少三个温度值中每个温度值对应的残余值差,更新晶体是否合格的判定结果。该技术方案通过残余值差可以辅助判定拟合一次项系数值和拟合常数项值是否准确,进而保证晶体是否合格的判定结果准确。
综上所述,本申请实施例提供的晶体判定方法针对现有技术中由于拟合的一次项系数值和常数项值不准确,导致不合格晶体无法被发现的问题,从不同角度和不同维度出发,提高了拟合一次项系数值和拟合常数项值的准确性,提高了晶体是否合格的判断结果,可以保证大部分不合格晶体均能被发现,为后续提高晶体性能奠定了基础。
图9为本申请实施例提供的晶体判定装置实施例一的结构示意图。如图9所示,本申请实施例提供的晶体判定装置,可以包括:获取模块91、处理模块92和判定模块93。
其中,该获取模块91,用于获取晶体在预设温度段的至少三个温度值,以及每个所述温度值对应的测试频偏值;
该处理模块92,用于根据所述获取模块91获取到的所述至少三个温度值以及每个所述温度值对应的测试频偏值,确定所述晶体在所述预设温度段时所述晶体对应频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0,所述频偏曲线f(t)采用公式(1)表示:
f(t)=c1(t-t0)+c0                   (1)
式中,t:温度值变量,t0:基准温度值,f(t):温度值为t时的频偏值;
该判定模块93,用于根据所述处理模块92确定的所述拟合一次项系数值c1和所述拟合常数项值c0,判定所述晶体是否合格。
可选的,在本申请实施例的一种可能实现方式中,所述处理模块92,具体用于利用所述获取模块91获取到的所述至少三个温度值以及每个所述温度值对应的测试频偏值,通过最小二乘法,计算所述频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0。
可选的,在本申请实施例的另一种可能实现方式中,所述处理模块92,具体用于根据所述获取模块91获取到的所述至少三个温度值中的两个温度值以及每个温度值对应的频偏测试值,确定所述频偏曲线的至少两组待定系数,根据所述至少两组待定系数,确定一次项系数平均值
Figure PCTCN2018094630-appb-000070
和常数项平均值
Figure PCTCN2018094630-appb-000071
以及将所述一次项系数平均值
Figure PCTCN2018094630-appb-000072
作为所述拟合一次项系数值c1,将所述常数项平均值
Figure PCTCN2018094630-appb-000073
作为所述拟合常数项值c0;
其中,每组所述待定系数包括:一个一次项系数值和一个常数项值,所述一次项系数平均值
Figure PCTCN2018094630-appb-000074
为所述至少两组待定系数中所有一次项系数值的平均值,所述常数项平均值
Figure PCTCN2018094630-appb-000075
为所述至少两组待定系数中所有常数项值的平均值。
相应的,在本申请实施例的该种可能实现方式中,所述判定模块93,具体用于基于如下公式(2),根据所述至少两组待定系数中所有一次项系数值,以及所述一次项系数平均值
Figure PCTCN2018094630-appb-000076
计算所述拟合一次项系数值c1的均方差σ c1,基于如下公式(3),根据所述至少两组待定系数中所有常数项值和所述常数项平均值
Figure PCTCN2018094630-appb-000077
计算所述拟合常数项值c0的均方差σ c0,根据所述拟合一次项系数值c1的均方差σ c1以及所述拟合常数项值c0的均方差σ c0,判定所述晶体是否合格;
Figure PCTCN2018094630-appb-000078
Figure PCTCN2018094630-appb-000079
式中,(c1) j为第j组待定系数中的一次项系数值,(c0) j为第j组待定系数中的常数项值,M为所述至少两组待定系数的组数量,j为大于或等于1且小于或等于M的正整数。
可选的,在本申请实施例的再一种可能实现方式中,所述处理模块92,还用于在所述判定模块93根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,基于所述频偏曲线f(t),通过如下公式(4),获取所述至少三个温度值中每个所述温度值对应的拟合频偏值f(t i)与测试频偏值
Figure PCTCN2018094630-appb-000080
之间的相关系数值R 2
Figure PCTCN2018094630-appb-000081
式中,f(t i)为基于所述频偏曲线f(t)得到的第i个温度值的拟合频偏值,
Figure PCTCN2018094630-appb-000082
为第i个温度值的测试频偏值,
Figure PCTCN2018094630-appb-000083
为基于所述频偏曲线f(t)得到的N个温度值的频偏平均值,N为所述至少三个温度值的数量,i为大于或等于1且小于或等于N的正整数;
相应的,所述判定模块93,还用于根据所述相关系数值R 2,更新所述晶体是否合格的判定结果。
可选的,在本申请实施例的又一种可能实现方式中,所述处理模块92,还用于在所述判定模块93根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,根据所述至少三个温度值中的两个相邻温度值以及每个温度值对应的频偏测试值,确定所述频偏曲线的至少两组待定系数,根据所述至少两组待定系数,获取至少一组待定系数绝对值;
其中,每组所述待定系数包括:一个一次项系数值和一个常数项值,每组所述待定系数绝对值包括:一个一次项系数绝对值和一个常数项系数绝对值,所述一次项系数绝对值是相邻两组待定系数中的两个一次项系数值作差后的绝对值,所述常数项系数绝对值是相邻两组待定系数中的两个常数项值作差后的绝对值;
相应的,所述判定模块93,还用于根据所述至少一组待定系数绝对值,更新所述晶体是否合格的判定结果。
可选的,在本申请实施例的又一种可能实现方式中,所述处理模块92,还用于在所述判定模块93根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,基于所述拟合一次项系数值c1和所述拟合常数项值c0得到的频偏曲线f(t),获取所述至少三个温度值中每个温度值对应的拟合频偏值,以及基于如下公式(5),根据所述至少三个温度值中每个温度值对应的测试温度值和所述至少三个温度值中每个温度值对应的拟合频偏值,确定每个所述温度值对应的残余值差;
Figure PCTCN2018094630-appb-000084
式中,RES(t i)为第i个温度值对应的残余值差,f(t i)为基于所述频偏曲线f(t)得到的第i个温度值的拟合频偏值,
Figure PCTCN2018094630-appb-000085
为第i个温度值的测试频偏值,i为所述至少三个温度值中的1个温度值;
相应的,所述判定模块93,还用于基于所述至少三个温度值中每个所述温度值对应的残余值差,更新所述晶体是否合格的判定结果。
可选的,在本申请实施例的该种可能实现方式中,所述判定模块93,还用于基于所述至少三个温度值中每个所述温度值对应的残余值差,更新所述晶体是否合格的判定结果,具体为:
所述判定模块93,还用于基于如下公式(6),根据所述至少三个温度值中两个相邻温度值分别对应的残余值差,确定至少两个残余误差变化率RES_s,以及根据所述至少两个残余误差变化率,更新所述晶体是否合格的判定结果;
Figure PCTCN2018094630-appb-000086
式中,t2和t1为所述至少三个温度值中相邻的两个温度值,RES(t1)为温度值t1对应的残余值差,RES(t2)为温度值t2对应的残余值差,t2大于t1。
本实施例提供的晶体判定装置可用于执行图4、图5、图6和图8所示方法实施例的技术方案,具体实现方式和技术效果类似,这里不再赘述。
需要说明的是,应理解以上装置的各个模块的划分仅仅是一种逻辑功能的划分,实际实现时可以全部或部分集成到一个物理实体上,也可以物理上分开。且这些模块可以全部以软件通过处理元件调用的形式实现;也可以全部以硬件的形式实现;还可以部分模块通过处理元件调用软件的形式实现,部分模块通过硬件的形式实现。例如,确定模块可以为单独设立的处理元件,也可以集成在上述装置的某一个芯片中实现,此外,也可以以程序代码的形式存储于上述装置的存储器中,由上述装置的某一个处理元件调用并执行以上确定模块的功能。其它模块的实现与之类似。此外这些模块全部或部分可以集成在一起,也可以独立实现。这里所述的处理元件可以是一种集成电路,具有信号的处理能力。在实现过程中,上述方法的各步骤或以上各个模块可以通过处理器元件中的硬件的集成逻辑电路或者软件形式的指令完成。
例如,以上这些模块可以是被配置成实施以上方法的一个或多个集成电路,例如:一个或多个特定集成电路(application specific integrated circuit,ASIC),或,一个或多个微处理器(digital singnal processor,DSP),或,一个或者多个现场可编程门阵列(field programmable gate array,FPGA)等。再如,当以上某个模块通过处理元件调度程序代码的形式实现时,该处理元件可以是通用处理器,例如中央处理器(central processing unit,CPU)或其它可以调用程序代码的处理器。再如,这些模块可以集成在一起,以片上系统(system-on-a-chip,SOC)的形式实现。
在上述实施例中,可以全部或部分地通过软件、硬件、固件或者其任意组合来实现。当使用软件实现时,可以全部或部分地以计算机程序产品的形式实现。所述计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行所述计算机程序指令时,全部或部分地产生按照本申请实施例所述的流程或功能。所述计算机可以是通用计算机、专用计算机、计算机网络、或者其他可编程装置。所述计算机指令可以存储在可读存储介质中,或者从一个可读存储介质向另一个可读存储介质传输,例如,所述计算机指令可以从一个网站站点、计算机、服务器或数据中心通过有线(例如同轴电缆、光纤、数字用户线(DSL))或无线(例如红外、无线、微波等)方式向另一个网站站点、计算机、服务器或数据中心进行传输。所述可读存储介质可以是计算机能够存取的任何可用介质或者是包含一个或多个可用介质集成的服务器、数据中心等数据存储设备。所述可用介质可以是磁性介质,(例如,软盘、硬盘、磁带)、光介质(例如,DVD)、或者半导体介质(例如固态硬盘solid state disk(SSD))等。
图10为本申请实施例提供的晶体判定装置实施例二的结构示意图。如图10所示,该晶体判定装置,可以包括:晶体101、温度传感器102、模数转换器ADC 103和电源管理单元PMU芯片104。
其中,所述温度传感器102,用于获取所述晶体在预设温度段的至少三个温度值,以及每个所述温度值对应的测试频偏值;
所述ADC 103,用于对所述温度传感器102获取到的所述至少三个温度值以及每个所述温度值对应的测试频偏值进行模数转换处理;
所述PMU芯片104,用于根据所述ADC 103处理后的所述至少三个温度值以及每个所述温度值对应的测试频偏值,确定所述晶体在所述预设温度段时所述晶体对应频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0,以及根据确定的所述拟合一次项系数值c1和所述拟合常数项值c0,判定所述晶体是否合格;
其中,所述频偏曲线f(t)采用公式(1)表示:
f(t)=c1(t-t0)+c0             (1)
式中,t:温度值变量,t0:基准温度值,f(t):温度值为t时的频偏值。
可选的,在本申请实施例的一种可能实现方式中,所述PMU芯片104,具体用于利用所述ADC 103处理后的所述至少三个温度值以及每个所述温度值对应的测试频偏值,通过最小二乘法,计算所述频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0。
可选的,在本申请实施例的另一种可能实现方式中,所述PMU芯片104,具体用于根据所述ADC 103处理后的所述至少三个温度值中的两个温度值以及每个温度值对应的频偏测试值,确定所述频偏曲线的至少两组待定系数,根据所述至少两组待定系数,确定一次项系数平均值
Figure PCTCN2018094630-appb-000087
和常数项平均值
Figure PCTCN2018094630-appb-000088
以及将所述一次项系数平均值
Figure PCTCN2018094630-appb-000089
作为所述拟合一次项系数值c1,将所述常数项平均值
Figure PCTCN2018094630-appb-000090
作为所述拟合常数项值c0;
其中,每组所述待定系数包括:一个一次项系数值和一个常数项值,所述一次项系数平均值
Figure PCTCN2018094630-appb-000091
为所述至少两组待定系数中所有一次项系数值的平均值,所述常数项平均值
Figure PCTCN2018094630-appb-000092
为所述至少两组待定系数中所有常数项值的平均值。
可选的,在本申请实施例的该种可能实现方式中,所述PMU芯片104,还用于基于如下公式(2),根据所述至少两组待定系数中所有一次项系数值,以及所述一次项系数平均值
Figure PCTCN2018094630-appb-000093
,计算所述拟合一次项系数值c1的均方差σ c1,基于如下公式(3),根据所述至少两组待定系数中所有常数项值和所述常数项平均值
Figure PCTCN2018094630-appb-000094
,计算所述拟合常数项值c0的均方差σ c0,根据所述拟合一次项系数值c1的均方差σ c1以及所述拟合常数项值c0的均方差σ c0,判定所述晶体是否合格;
Figure PCTCN2018094630-appb-000095
Figure PCTCN2018094630-appb-000096
式中,(c1) j为第j组待定系数中的一次项系数值,(c0) j为第j组待定系数中的常数项值,M为所述至少两组待定系数的组数量,j为大于或等于1且小于或等于M的正整数。
可选的,在本申请实施例的再一种可能实现方式中,所述PMU芯片104,还用于在根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,基于所述频偏曲 线f(t),通过如下公式(4),获取所述至少三个温度值中每个所述温度值对应的拟合频偏值f(t i)与测试频偏值
Figure PCTCN2018094630-appb-000097
之间的相关系数值R 2,以及根据所述相关系数值R 2,更新所述晶体是否合格的判定结果;
Figure PCTCN2018094630-appb-000098
式中,f(t i)为基于所述频偏曲线f(t)得到的第i个温度值的拟合频偏值,
Figure PCTCN2018094630-appb-000099
为第i个温度值的测试频偏值,
Figure PCTCN2018094630-appb-000100
为基于所述频偏曲线f(t)得到的N个温度值的频偏平均值,N为所述至少三个温度值的数量,i为大于或等于1且小于或等于N的正整数。
可选的,在本申请实施例的又一种可能实现方式中,所述PMU芯片104,还用于在根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,根据所述ADC103处理后所述至少三个温度值中的两个相邻温度值以及每个温度值对应的频偏测试值,确定所述频偏曲线的至少两组待定系数,根据所述至少两组待定系数,获取至少一组待定系数绝对值,以及根据所述至少一组待定系数绝对值,更新所述晶体是否合格的判定结果
其中,每组所述待定系数包括:一个一次项系数值和一个常数项值,每组所述待定系数绝对值包括:一个一次项系数绝对值和一个常数项系数绝对值,所述一次项系数绝对值是相邻两组待定系数中的两个一次项系数值作差后的绝对值,所述常数项系数绝对值是相邻两组待定系数中的两个常数项值作差后的绝对值。
可选的,在本申请实施例的又一种可能实现方式中,所述PMU芯片104,还用于在根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,基于所述拟合一次项系数值c1和所述拟合常数项值c0得到的频偏曲线f(t),获取所述至少三个温度值中每个温度值对应的拟合频偏值,以及基于如下公式(5),根据所述ADC 103处理后所述至少三个温度值中每个温度值对应的测试温度值和所述至少三个温度值中每个温度值对应的拟合频偏值,确定每个所述温度值对应的残余值差,以及基于所述ADC 103处理后所述至少三个温度值中每个所述温度值对应的残余值差,更新所述晶体是否合格的判定结果;
Figure PCTCN2018094630-appb-000101
式中,RES(t i)为第i个温度值对应的残余值差,f(t i)为基于所述频偏曲线f(t)得到的第i个温度值的拟合频偏值,
Figure PCTCN2018094630-appb-000102
为第i个温度值的测试频偏值,i为所述至少三个温度值中的1个温度值。
可选的,在本申请实施例的该种可能实现方式中,所述PMU芯片104,还用于基于所述ADC 103处理后所述至少三个温度值中每个所述温度值对应的残余值差,更新所述晶体是否合格的判定结果,具体为:
所述PMU芯片104,还用于基于如下公式(6),根据所述ADC 103处理后所述至少三个温度值中两个相邻温度值分别对应的残余值差,确定至少两个残余误差变化率RES_s,以及根据所述至少两个残余误差变化率,更新所述晶体是否合格的判定结果;
Figure PCTCN2018094630-appb-000103
式中,t2和t1为所述至少三个温度值中相邻的两个温度值,RES(t1)为温度值t1对应的残余值差,RES(t2)为温度值t2对应的残余值差,t2大于t1。
可选的,本实施例中温度传感器102可以对应上述图9中的获取模块91,ADC 103可以完成上述处理模块92的部分功能,PMU芯片104可以对应上述图9中的处理模块92和判定模块93。
本实施例提供的晶体判定装置可用于执行图4、图5、图6和图8所示方法实施例的技术方案,具体实现方式和技术效果类似,这里不再赘述。
本申请实施例提供一种存储介质,所述存储介质中存储有指令,当其在计算机上运行时,使得计算机执行如上述图4、图5、图6和图8所示实施例的技术方案。
可选的,本申请实施例提供一种运行指令的芯片,所述芯片用于执行图4、图5、图6和图8所示方法实施例的技术方案。
本文中的术语“多个”是指两个或两个以上。本文中术语“和/或”,仅仅是一种描述关联对象的关联关系,表示可以存在三种关系,例如,A和/或B,可以表示:单独存在A,同时存在A和B,单独存在B这三种情况。另外,本文中字符“/”,一般表示前后关联对象是一种“或”的关系;在公式中,字符“/”,表示前后关联对象是一种“相除”的关系。
可以理解的是,在本申请的实施例中涉及的各种数字编号仅为描述方便进行的区分,并不用来限制本申请的实施例的范围。
可以理解的是,在本申请的实施例中,上述各过程的序号的大小并不意味着执行顺序的先后,各过程的执行顺序应以其功能和内在逻辑确定,而不应对本申请的实施例的实施过程构成任何限定。
以上所述,仅为本申请的具体实施方式,但本申请的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本申请揭露的技术范围内,可轻易想到变化或替换,都应涵盖在本申请的保护范围之内。因此,本申请的保护范围应以所述权利要求的保护范围为准。

Claims (25)

  1. 一种晶体判定方法,其特征在于,包括:
    获取晶体在预设温度段的至少三个温度值,以及每个所述温度值对应的测试频偏值;
    根据所述至少三个温度值以及每个所述温度值对应的测试频偏值,确定所述晶体在所述预设温度段时所述晶体对应频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0,所述频偏曲线f(t)采用公式(1)表示:
    f(t)=c1(t-t0)+c0  (1)式中,t:温度值变量,t0:基准温度值,f(t):温度值为t时的频偏值;
    根据所述拟合一次项系数值c1和所述拟合常数项值c0,判定所述晶体是否合格。
  2. 根据权利要求1所述的方法,其特征在于,所述根据所述至少三个温度值以及每个所述温度值对应的测试频偏值,确定所述晶体在所述预设温度段时的频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0,包括:
    利用所述至少三个温度值以及每个所述温度值对应的测试频偏值,通过最小二乘法,计算所述频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0。
  3. 根据权利要求1所述的方法,其特征在于,所述根据所述至少三个温度值以及每个所述温度值对应的测试频偏值,确定所述晶体在所述预设温度段时的频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0,包括:
    根据所述至少三个温度值中的两个温度值以及每个温度值对应的频偏测试值,确定所述频偏曲线的至少两组待定系数,每组所述待定系数包括:一个一次项系数值和一个常数项值;
    根据所述至少两组待定系数,确定一次项系数平均值
    Figure PCTCN2018094630-appb-100001
    和常数项平均值
    Figure PCTCN2018094630-appb-100002
    所述一次项系数平均值
    Figure PCTCN2018094630-appb-100003
    为所述至少两组待定系数中所有一次项系数值的平均值,所述常数项平均值
    Figure PCTCN2018094630-appb-100004
    为所述至少两组待定系数中所有常数项值的平均值;
    将所述一次项系数平均值
    Figure PCTCN2018094630-appb-100005
    作为所述拟合一次项系数值c1,将所述常数项平均值
    Figure PCTCN2018094630-appb-100006
    作为所述拟合常数项值c0。
  4. 根据权利要求3所述的方法,其特征在于,所述根据所述拟合一次项系数值c1和所述拟合常数项值c0,判定所述晶体是否合格,包括:
    基于如下公式(2),根据所述至少两组待定系数中所有一次项系数值,以及所述一次项系数平均值
    Figure PCTCN2018094630-appb-100007
    计算所述拟合一次项系数值c1的均方差σ c1
    Figure PCTCN2018094630-appb-100008
    基于如下公式(3),根据所述至少两组待定系数中所有常数项值和所述常数项平均值
    Figure PCTCN2018094630-appb-100009
    计算所述拟合常数项值c0的均方差σ c0
    Figure PCTCN2018094630-appb-100010
    式中,(c1) j为第j组待定系数中的一次项系数值,(c0) j为第j组待定系数中的常数项值,M为所述至少两组待定系数的组数量,j为大于或等于1且小于或等于M的正整数;
    根据所述拟合一次项系数值c1的均方差σ c1以及所述拟合常数项值c0的均方差σ c0,判定所述晶体是否合格。
  5. 根据权利要求1-4任一项所述的方法,其特征在于,所述方法还包括:
    在根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,基于所述频偏曲线f(t),通过如下公式(4),获取所述至少三个温度值中每个所述温度值对应的拟合频偏值f(t i)与测试频偏值
    Figure PCTCN2018094630-appb-100011
    之间的相关系数值R 2
    Figure PCTCN2018094630-appb-100012
    式中,f(t i)为基于所述频偏曲线f(t)得到的第i个温度值的拟合频偏值,
    Figure PCTCN2018094630-appb-100013
    为第i个温度值的测试频偏值,
    Figure PCTCN2018094630-appb-100014
    为基于所述频偏曲线f(t)得到的N个温度值的频偏平均值,N为所述至少三个温度值的数量,i为大于或等于1且小于或等于N的正整数;
    根据所述相关系数值R 2,更新所述晶体是否合格的判定结果。
  6. 根据权利要求1-4任一项所述的方法,其特征在于,所述方法还包括:
    在根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,根据所述至少三个温度值中的两个相邻温度值以及每个温度值对应的频偏测试值,确定所述频偏曲线的至少两组待定系数,每组所述待定系数包括:一个一次项系数值和一个常数项值;
    根据所述至少两组待定系数,获取至少一组待定系数绝对值,每组所述待定系数绝对值包括:一个一次项系数绝对值和一个常数项系数绝对值,所述一次项系数绝对值是相邻两组待定系数中的两个一次项系数值作差后的绝对值,所述常数项系数绝对值是相邻两组待定系数中的两个常数项值作差后的绝对值;
    根据所述至少一组待定系数绝对值,更新所述晶体是否合格的判定结果。
  7. 根据权利要求1-4任一项所述的方法,其特征在于,所述方法还包括:
    在根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,基于所述拟合一次项系数值c1和所述拟合常数项值c0得到的频偏曲线f(t),获取所述至少三个温度值中每个温度值对应的拟合频偏值;
    基于如下公式(5),根据所述至少三个温度值中每个温度值对应的测试温度值和所述至少三个温度值中每个温度值对应的拟合频偏值,确定每个所述温度值对应的残余值差;
    Figure PCTCN2018094630-appb-100015
    式中,RES(t i)为第i个温度值对应的残余值差,f(t i)为基于所述频偏曲线f(t)得到的第i个温度值的拟合频偏值,
    Figure PCTCN2018094630-appb-100016
    为第i个温度值的测试频偏值,i为所述至少三个温度值中的1个温度值;
    基于所述至少三个温度值中每个所述温度值对应的残余值差,更新所述晶体是否合格的判定结果。
  8. 根据权利要求7所述的方法,其特征在于,所述基于所述至少三个温度值中每个所述温度值对应的残余值差,更新所述晶体是否合格的判定结果,包括:
    基于如下公式(6),根据所述至少三个温度值中两个相邻温度值分别对应的残余值差,确定至少两个残余误差变化率RES_s;
    Figure PCTCN2018094630-appb-100017
    式中,t2和t1为所述至少三个温度值中相邻的两个温度值,RES(t1)为温度值t1对应的残余值差,RES(t2)为温度值t2对应的残余值差,t2大于t1;
    根据所述至少两个残余误差变化率RES_s,更新所述晶体是否合格的判定结果。
  9. 一种晶体判定装置,其特征在于,包括:
    获取模块,用于获取晶体在预设温度段的至少三个温度值,以及每个所述温度值对应的测试频偏值;
    处理模块,用于根据所述获取模块获取到的所述至少三个温度值以及每个所述温度值对应的测试频偏值,确定所述晶体在所述预设温度段时所述晶体对应频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0,所述频偏曲线f(t)采用公式(1)表示:
    f(t)=c1(t-t0)+c0  (1)式中,t:温度值变量,t0:基准温度值,f(t):温度值为t时的频偏值;
    判定模块,用于根据所述处理模块确定的所述拟合一次项系数值c1和所述拟合常数项值c0,判定所述晶体是否合格。
  10. 根据权利要求9所述的装置,其特征在于,
    所述处理模块,具体用于利用所述获取模块获取到的所述至少三个温度值以及每个所述温度值对应的测试频偏值,通过最小二乘法,计算所述频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0。
  11. 根据权利要求9所述的装置,其特征在于,
    所述处理模块,具体用于根据所述获取模块获取到的所述至少三个温度值中的两个温度值以及每个温度值对应的频偏测试值,确定所述频偏曲线的至少两组待定系数,根据所述至少两组待定系数,确定一次项系数平均值
    Figure PCTCN2018094630-appb-100018
    和常数项平均值
    Figure PCTCN2018094630-appb-100019
    以及将所述一次项系数平均值
    Figure PCTCN2018094630-appb-100020
    作为所述拟合一次项系数值c1,将所述常数项平均值
    Figure PCTCN2018094630-appb-100021
    作为所述拟合常数项值c0;
    其中,每组所述待定系数包括:一个一次项系数值和一个常数项值,所述一次项系数平均值
    Figure PCTCN2018094630-appb-100022
    为所述至少两组待定系数中所有一次项系数值的平均值,所述常数项平均值
    Figure PCTCN2018094630-appb-100023
    为所述至少两组待定系数中所有常数项值的平均值。
  12. 根据权利要求11所述的装置,其特征在于,
    所述判定模块,具体用于基于如下公式(2),根据所述至少两组待定系数中所有一次项系数值,以及所述一次项系数平均值
    Figure PCTCN2018094630-appb-100024
    计算所述拟合一次项系数值c1的均方差σ c1,基于如下公式(3),根据所述至少两组待定系数中所有常数项值和所述常数项平均值
    Figure PCTCN2018094630-appb-100025
    计算所述拟合常数项值c0的均方差σ c0,根据所述拟合一次项系数值c1的均方差σ c1以及所述拟合常数项值c0的均方差σ c0,判定所述晶体是否合格;
    Figure PCTCN2018094630-appb-100026
    Figure PCTCN2018094630-appb-100027
    式中,(c1) j为第j组待定系数中的一次项系数值,(c0) j为第j组待定系数中的常数项值,M为所述至少两组待定系数的组数量,j为大于或等于1且小于或等于M的正整数。
  13. 根据权利要求9-12任一项所述的装置,其特征在于,
    所述处理模块,还用于在所述判定模块根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,基于所述频偏曲线f(t),通过如下公式(4),获取所述至少三个温度值中每个所述温度值对应的拟合频偏值f(t i)与测试频偏值
    Figure PCTCN2018094630-appb-100028
    之间的相关系数值R 2
    Figure PCTCN2018094630-appb-100029
    式中,f(t i)为基于所述频偏曲线f(t)得到的第i个温度值的拟合频偏值,
    Figure PCTCN2018094630-appb-100030
    为第i个温度值的测试频偏值,
    Figure PCTCN2018094630-appb-100031
    为基于所述频偏曲线f(t)得到的N个温度值的频偏平均值,N为所述至少三个温度值的数量,i为大于或等于1且小于或等于N的正整数;
    所述判定模块,还用于根据所述相关系数值R 2,更新所述晶体是否合格的判定结果。
  14. 根据权利要求9-12任一项所述的装置,其特征在于,
    所述处理模块,还用于在所述判定模块根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,根据所述至少三个温度值中的两个相邻温度值以及每个温度值对应的频偏测试值,确定所述频偏曲线的至少两组待定系数,根据所述至少两组待定系数,获取至少一组待定系数绝对值;
    其中,每组所述待定系数包括:一个一次项系数值和一个常数项值,每组所述待定系数绝对值包括:一个一次项系数绝对值和一个常数项系数绝对值,所述一次项系数绝对值是相邻两组待定系数中的两个一次项系数值作差后的绝对值,所述常数项系数绝对值是相邻两组待定系数中的两个常数项值作差后的绝对值;
    所述判定模块,还用于根据所述至少一组待定系数绝对值,更新所述晶体是否合格的判定结果。
  15. 根据权利要求9-12任一项所述的装置,其特征在于,
    所述处理模块,还用于在所述判定模块根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,基于所述拟合一次项系数值c1和所述拟合常数项值c0得到的频偏曲线f(t),获取所述至少三个温度值中每个温度值对应的拟合频偏值,以及基于如下公式(5),根据所述至少三个温度值中每个温度值对应的测试温度值和所述至少三个温度值中每个温度值对应的拟合频偏值,确定每个所述温度值对应的残余值差;
    Figure PCTCN2018094630-appb-100032
    式中,RES(t i)为第i个温度值对应的残余值差,f(t i)为基于所述频偏曲线f(t)得到的第i个温度值的拟合频偏值,
    Figure PCTCN2018094630-appb-100033
    为第i个温度值的测试频偏值,i为所述至少三个温度值中的1个温度值;
    所述判定模块,还用于基于所述至少三个温度值中每个所述温度值对应的残余值差,更新所述晶体是否合格的判定结果。
  16. 根据权利要求15所述的装置,其特征在于,所述判定模块,还用于基于所述至少三个温度值中每个所述温度值对应的残余值差,更新所述晶体是否合格的判定结果,具体为:
    所述判定模块,还用于基于如下公式(6),根据所述至少三个温度值中两个相邻温度值分别对应的残余值差,确定至少两个残余误差变化率RES_s,以及根据所述至少两个残余误差变化率,更新所述晶体是否合格的判定结果;
    Figure PCTCN2018094630-appb-100034
    式中,t2和t1为所述至少三个温度值中相邻的两个温度值,RES(t1)为温度值t1对应的残余值差,RES(t2)为温度值t2对应的残余值差,t2大于t1。
  17. 一种晶体判定装置,其特征在于,包括:晶体、温度传感器、模数转换器ADC和电源管理单元PMU芯片;
    所述温度传感器,用于获取所述晶体在预设温度段的至少三个温度值,以及每个所述温度值对应的测试频偏值;
    所述ADC,用于对所述温度传感器获取到的所述至少三个温度值以及每个所述温度值对应的测试频偏值进行模数转换处理;
    所述PMU芯片,用于根据所述ADC处理后的所述至少三个温度值以及每个所述温度值对应的测试频偏值,确定所述晶体在所述预设温度段时所述晶体对应频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0,以及根据确定的所述拟合一次项系数值c1和所述拟合常数项值c0,判定所述晶体是否合格;
    其中,所述频偏曲线f(t)采用公式(1)表示:
    f(t)=c1(t-t0)+c0  (1)式中,t:温度值变量,t0:基准温度值,f(t):温度值为t时的频偏值。
  18. 根据权利要求17所述的装置,其特征在于,
    所述PMU芯片,具体用于利用所述ADC处理后的所述至少三个温度值以及每个所述温度值对应的测试频偏值,通过最小二乘法,计算所述频偏曲线f(t)的拟合一次项系数值c1和拟合常数项值c0。
  19. 根据权利要求17所述的装置,其特征在于,
    所述PMU芯片,具体用于根据所述ADC处理后的所述至少三个温度值中的两个温度值以及每个温度值对应的频偏测试值,确定所述频偏曲线的至少两组待定系数,根据所述至少两组待定系数,确定一次项系数平均值
    Figure PCTCN2018094630-appb-100035
    和常数项平均值
    Figure PCTCN2018094630-appb-100036
    以及将所述一次项系数平均值
    Figure PCTCN2018094630-appb-100037
    作为所述拟合一次项系数值c1,将所述常数项平均值
    Figure PCTCN2018094630-appb-100038
    作为所述拟合常数项值c0;
    其中,每组所述待定系数包括:一个一次项系数值和一个常数项值,所述一次项系数平均值
    Figure PCTCN2018094630-appb-100039
    为所述至少两组待定系数中所有一次项系数值的平均值,所述常数项平均值
    Figure PCTCN2018094630-appb-100040
    为所述至少两组待定系数中所有常数项值的平均值。
  20. 根据权利要求19所述的装置,其特征在于,
    所述PMU芯片,还用于基于如下公式(2),根据所述至少两组待定系数中所有一次项系数值,以及所述一次项系数平均值
    Figure PCTCN2018094630-appb-100041
    计算所述拟合一次项系数值c1的均方差σ c1, 基于如下公式(3),根据所述至少两组待定系数中所有常数项值和所述常数项平均值
    Figure PCTCN2018094630-appb-100042
    计算所述拟合常数项值c0的均方差σ c0,根据所述拟合一次项系数值c1的均方差σ c1以及所述拟合常数项值c0的均方差σ c0,判定所述晶体是否合格;
    Figure PCTCN2018094630-appb-100043
    Figure PCTCN2018094630-appb-100044
    式中,(c1) j为第j组待定系数中的一次项系数值,(c0) j为第j组待定系数中的常数项值,M为所述至少两组待定系数的组数量,j为大于或等于1且小于或等于M的正整数。
  21. 根据权利要求17-20任一项所述的装置,其特征在于,
    所述PMU芯片,还用于在根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,基于所述频偏曲线f(t),通过如下公式(4),获取所述至少三个温度值中每个所述温度值对应的拟合频偏值f(t i)与测试频偏值
    Figure PCTCN2018094630-appb-100045
    之间的相关系数值R 2,以及根据所述相关系数值R 2,更新所述晶体是否合格的判定结果;
    Figure PCTCN2018094630-appb-100046
    式中,f(t i)为基于所述频偏曲线f(t)得到的第i个温度值的拟合频偏值,
    Figure PCTCN2018094630-appb-100047
    为第i个温度值的测试频偏值,
    Figure PCTCN2018094630-appb-100048
    为基于所述频偏曲线f(t)得到的N个温度值的频偏平均值,N为所述至少三个温度值的数量,i为大于或等于1且小于或等于N的正整数。
  22. 根据权利要求17-20任一项所述的装置,其特征在于,
    所述PMU芯片,还用于在根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,根据所述ADC处理后所述至少三个温度值中的两个相邻温度值以及每个温度值对应的频偏测试值,确定所述频偏曲线的至少两组待定系数,根据所述至少两组待定系数,获取至少一组待定系数绝对值,以及根据所述至少一组待定系数绝对值,更新所述晶体是否合格的判定结果
    其中,每组所述待定系数包括:一个一次项系数值和一个常数项值,每组所述待定系数绝对值包括:一个一次项系数绝对值和一个常数项系数绝对值,所述一次项系数绝对值是相邻两组待定系数中的两个一次项系数值作差后的绝对值,所述常数项系数绝对值是相邻两组待定系数中的两个常数项值作差后的绝对值。
  23. 根据权利要求17-20任一项所述的装置,其特征在于,
    所述PMU芯片,还用于在根据所述拟合一次项系数值c1和所述拟合常数项值c0确定所述晶体合格时,基于所述拟合一次项系数值c1和所述拟合常数项值c0得到的频偏曲线f(t),获取所述至少三个温度值中每个温度值对应的拟合频偏值,以及基于如下公式(5),根据所述ADC处理后所述至少三个温度值中每个温度值对应的测试温度值和所述至少三个温度值中每个温度值对应的拟合频偏值,确定每个所述温度值对应的残余值差,以及基于所述ADC处理后所述至少三个温度值中每个所述温度值对应的残余值差,更新所述晶体是否合格的判定结果;
    Figure PCTCN2018094630-appb-100049
    式中,RES(ti)为第i个温度值对应的残余值差,f(t i)为基于所述频偏曲线f(t)得到的第i个温度值的拟合频偏值,
    Figure PCTCN2018094630-appb-100050
    为第i个温度值的测试频偏值,i为所述至少三个温度值中的1个温度值。
  24. 根据权利要求23所述的装置,其特征在于,
    所述PMU芯片,还用于基于所述ADC处理后所述至少三个温度值中每个所述温度值对应的残余值差,更新所述晶体是否合格的判定结果,具体为:
    所述PMU芯片,还用于基于如下公式(6),根据所述ADC处理后所述至少三个温度值中两个相邻温度值分别对应的残余值差,确定至少两个残余误差变化率RES_s,以及根据所述至少两个残余误差变化率,更新所述晶体是否合格的判定结果;
    Figure PCTCN2018094630-appb-100051
    式中,t2和t1为所述至少三个温度值中相邻的两个温度值,RES(t1)为温度值t1对应的残余值差,RES(t2)为温度值t2对应的残余值差,t2大于t1。
  25. 一种存储介质,其特征在于,所述存储介质中存储有指令,当其在计算机上运行时,使得计算机执行如权利要求1-8任一项所述的方法。
PCT/CN2018/094630 2018-07-05 2018-07-05 晶体判定方法、装置及存储介质 WO2020006728A1 (zh)

Priority Applications (2)

Application Number Priority Date Filing Date Title
CN201880094853.2A CN112292814A (zh) 2018-07-05 2018-07-05 晶体判定方法、装置及存储介质
PCT/CN2018/094630 WO2020006728A1 (zh) 2018-07-05 2018-07-05 晶体判定方法、装置及存储介质

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2018/094630 WO2020006728A1 (zh) 2018-07-05 2018-07-05 晶体判定方法、装置及存储介质

Publications (1)

Publication Number Publication Date
WO2020006728A1 true WO2020006728A1 (zh) 2020-01-09

Family

ID=69059986

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2018/094630 WO2020006728A1 (zh) 2018-07-05 2018-07-05 晶体判定方法、装置及存储介质

Country Status (2)

Country Link
CN (1) CN112292814A (zh)
WO (1) WO2020006728A1 (zh)

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101965568A (zh) * 2008-01-31 2011-02-02 高通股份有限公司 晶体振荡器频率校准
US20160109496A1 (en) * 2014-10-20 2016-04-21 Fujitsu Limited Measurement method and measurement system
CN108227471A (zh) * 2016-12-21 2018-06-29 展讯通信(上海)有限公司 Gps共享时钟的校准方法及装置

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107272821B (zh) * 2017-06-07 2020-02-21 上海东软载波微电子有限公司 实时时钟校准方法及装置、存储介质、电子设备

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101965568A (zh) * 2008-01-31 2011-02-02 高通股份有限公司 晶体振荡器频率校准
US20160109496A1 (en) * 2014-10-20 2016-04-21 Fujitsu Limited Measurement method and measurement system
CN108227471A (zh) * 2016-12-21 2018-06-29 展讯通信(上海)有限公司 Gps共享时钟的校准方法及装置

Also Published As

Publication number Publication date
CN112292814A (zh) 2021-01-29

Similar Documents

Publication Publication Date Title
TWI648606B (zh) System and method for frequency compensation of an instant clock system
WO2020232810A1 (zh) 一种矢量网络分析仪在片s参数的校准方法、系统及设备
CN106054580B (zh) 时钟芯片的秒信号校准方法
CN112816877B (zh) 电池的电流校准方法、设备和存储介质
US11356105B2 (en) Method for calibrating crystal frequency offset through internal loop of central processing unit
CN112818535B (zh) 建立电热仿真模型及获得电热仿真值的方法和装置
WO2023116519A1 (zh) 电池soc的估算方法及相关装置
Andraud et al. One-shot calibration of RF circuits based on non-intrusive sensors
CN116106605A (zh) 一种考虑温度变化的电能表参数补偿方法、介质及系统
WO2020006728A1 (zh) 晶体判定方法、装置及存储介质
CN110519356A (zh) 一种校准燃气表上报成功率的方法及装置
WO2018090650A1 (zh) 时钟补偿电路、时钟电路和微控制器
CN104916083A (zh) 一种基于物联网的智能可燃气体检测探测器及其标定方法
WO2022047767A1 (zh) 一种电池电量的检测方法、装置及便携式电子设备
CN114201001A (zh) 一种实时时钟的补偿方法、装置、终端设备和介质
CN113922813A (zh) 一种数控振荡器的频率校准方法
CN111614408B (zh) 一种Zigbee模块的RF测试方法
WO2024002031A1 (zh) 芯片温度测试方法及装置
CN103746720B (zh) 无线通信模块调整方法
CN114826156A (zh) 振荡器电路输出频率的调节方法、装置、设备及存储介质
CN115173860A (zh) 一种实现自适应补偿adc温变采样偏差的方法及系统
CN107462342A (zh) 热电偶的温度获取方法、电子设备和计算机可读存储介质
US20120290866A1 (en) Method and system for correcting timing errors due to thermal changes within a portable computing device
CN113588099A (zh) 一种红外热电堆阵列环境温度补偿方法及相关组件
CN113218527B (zh) 基于热敏电阻的温度检测方法、装置、设备、介质及系统

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 18925478

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 18925478

Country of ref document: EP

Kind code of ref document: A1