CN110336557B - Frequency compensation method, terminal and storage medium - Google Patents

Frequency compensation method, terminal and storage medium Download PDF

Info

Publication number
CN110336557B
CN110336557B CN201910551114.8A CN201910551114A CN110336557B CN 110336557 B CN110336557 B CN 110336557B CN 201910551114 A CN201910551114 A CN 201910551114A CN 110336557 B CN110336557 B CN 110336557B
Authority
CN
China
Prior art keywords
temperature
frequency deviation
values
preset
frequency
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910551114.8A
Other languages
Chinese (zh)
Other versions
CN110336557A (en
Inventor
杨鑫
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201910551114.8A priority Critical patent/CN110336557B/en
Publication of CN110336557A publication Critical patent/CN110336557A/en
Application granted granted Critical
Publication of CN110336557B publication Critical patent/CN110336557B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01SRADIO DIRECTION-FINDING; RADIO NAVIGATION; DETERMINING DISTANCE OR VELOCITY BY USE OF RADIO WAVES; LOCATING OR PRESENCE-DETECTING BY USE OF THE REFLECTION OR RERADIATION OF RADIO WAVES; ANALOGOUS ARRANGEMENTS USING OTHER WAVES
    • G01S19/00Satellite radio beacon positioning systems; Determining position, velocity or attitude using signals transmitted by such systems
    • G01S19/38Determining a navigation solution using signals transmitted by a satellite radio beacon positioning system
    • G01S19/39Determining a navigation solution using signals transmitted by a satellite radio beacon positioning system the satellite radio beacon positioning system transmitting time-stamped messages, e.g. GPS [Global Positioning System], GLONASS [Global Orbiting Navigation Satellite System] or GALILEO
    • G01S19/42Determining position
    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03LAUTOMATIC CONTROL, STARTING, SYNCHRONISATION OR STABILISATION OF GENERATORS OF ELECTRONIC OSCILLATIONS OR PULSES
    • H03L1/00Stabilisation of generator output against variations of physical values, e.g. power supply
    • H03L1/02Stabilisation of generator output against variations of physical values, e.g. power supply against variations of temperature only
    • H03L1/022Stabilisation of generator output against variations of physical values, e.g. power supply against variations of temperature only by indirect stabilisation, i.e. by generating an electrical correction signal which is a function of the temperature
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02DCLIMATE CHANGE MITIGATION TECHNOLOGIES IN INFORMATION AND COMMUNICATION TECHNOLOGIES [ICT], I.E. INFORMATION AND COMMUNICATION TECHNOLOGIES AIMING AT THE REDUCTION OF THEIR OWN ENERGY USE
    • Y02D10/00Energy efficient computing, e.g. low power processors, power management or thermal management

Landscapes

  • Engineering & Computer Science (AREA)
  • Radar, Positioning & Navigation (AREA)
  • Remote Sensing (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Oscillators With Electromechanical Resonators (AREA)

Abstract

The embodiment of the application provides a frequency compensation method, a terminal and a storage medium, wherein the method comprises the following steps: determining the current temperature of the frequency deviation to be compensated; when the current temperature is in the first working temperature range, searching a first frequency deviation function corresponding to the first working temperature range from the corresponding relation between the preset temperature range and the frequency deviation function; and performing frequency compensation on the frequency deviation to be compensated by using the first frequency deviation function.

Description

Frequency compensation method, terminal and storage medium
Technical Field
The present disclosure relates to the field of crystal oscillators, and in particular, to a frequency compensation method, a terminal, and a storage medium.
Background
In the positioning principle of the global navigation satellite system (Global Navigation Satellite System, GNSS), the distance between the satellite and the terminal device is estimated by multiplying the time of arrival of the satellite transmitting signal at the GNSS receiving module by the propagation velocity of the electromagnetic wave. Thus, the clock accuracy of the terminal device will directly affect the positioning accuracy of the GNSS.
The crystal oscillator can generate a very stable resonance frequency as the clock frequency of the terminal device, and since the frequency is the inverse of time, the frequency error of the crystal oscillator caused by temperature is compensated for in order to improve the clock accuracy. The existing frequency compensation method utilizes a group of C parameters to determine the frequency deviation values of the crystal oscillators in all temperature intervals, which can lead to the problems of large frequency deviation and large GNSS positioning error in the working temperature range.
Disclosure of Invention
The embodiment of the application provides a frequency compensation method, a terminal and a storage medium, which can reduce frequency deviation in a working temperature range and reduce GNSS positioning errors.
The technical scheme of the application is realized as follows:
the embodiment of the application provides a frequency compensation method, which comprises the following steps:
determining the current temperature of the frequency deviation to be compensated;
when the current temperature is in a first working temperature range, searching a first frequency deviation function corresponding to the first working temperature range from the corresponding relation between a preset temperature range and the frequency deviation function;
and carrying out frequency compensation on the frequency deviation to be compensated by utilizing the first frequency deviation function.
In the above method, before the determining obtains the current temperature of the frequency deviation to be compensated, the method further includes:
determining a plurality of groups of preset temperature values from a plurality of working temperature ranges respectively, and acquiring a plurality of groups of frequency deviation values corresponding to the plurality of groups of preset temperature values, wherein one working temperature range corresponds to one group of preset temperature values, and one group of preset temperature values corresponds to one group of frequency deviation values;
respectively determining a plurality of frequency deviation functions corresponding to a plurality of working temperature ranges by utilizing the plurality of groups of preset temperature values and the plurality of groups of frequency deviation values, wherein one working temperature range in the plurality of working temperature ranges corresponds to one frequency deviation function;
and obtaining the corresponding relation between the preset temperature range and the frequency deviation function according to the working temperature ranges and the frequency deviation functions.
In the above method, after the determining that the current temperature of the frequency deviation to be compensated is obtained, before searching the first frequency deviation function corresponding to the first working temperature range from the corresponding relation between the preset temperature range and the frequency deviation function, the method further includes:
determining a first temperature when the frequency compensation is carried out in the previous round;
determining a temperature change trend according to the first temperature and the current temperature;
determining a plurality of temperature intervals corresponding to a plurality of working temperature ranges according to the temperature change trend;
when the current temperature is in a first temperature interval of the plurality of temperature intervals, judging that the current temperature is in the first working temperature range corresponding to the first temperature interval.
In the above method, the determining, according to the temperature change trend, a plurality of temperature intervals corresponding to a plurality of working temperature ranges includes:
determining a plurality of temperature switching values among the plurality of working temperature ranges according to the temperature change trend, wherein one temperature switching value corresponds to each two working temperature ranges among the plurality of working temperature ranges;
and dividing the working temperature ranges into the temperature intervals according to the temperature switching values.
In the above method, the obtaining a plurality of sets of frequency deviation values corresponding to the plurality of sets of preset temperature values includes:
acquiring the generated signal frequency at a first preset temperature value, wherein the first preset temperature is any preset temperature value in the plurality of groups of preset temperature values;
determining the difference between the generated signal frequency and the standard signal frequency corresponding to the first preset temperature value as a first frequency deviation value corresponding to the first preset temperature value;
until the multiple groups of frequency deviation values corresponding to the multiple groups of preset temperature values are obtained.
In the above method, the determining a plurality of frequency deviation functions corresponding to the plurality of working temperature ranges by using the plurality of sets of preset temperature values and the plurality of sets of frequency deviation values includes:
and performing parameter fitting on a plurality of preset frequency deviation functions based on the plurality of preset temperature values and the plurality of frequency deviation values respectively to obtain a plurality of frequency deviation functions corresponding to the plurality of preset frequency deviation functions, wherein one preset frequency deviation function in the plurality of preset frequency deviation functions corresponds to one frequency deviation function.
The embodiment of the application provides a terminal, which comprises:
the determining unit is used for determining the current temperature of the frequency deviation to be compensated;
the acquisition unit is used for searching a first frequency deviation function corresponding to a first working temperature range from the corresponding relation between a preset temperature range and the frequency deviation function when the current temperature is judged to be in the first working temperature range;
and the frequency compensation unit is used for carrying out frequency compensation on the frequency deviation to be compensated by utilizing the first frequency deviation function.
In the above terminal, the obtaining unit is further configured to determine a plurality of sets of preset temperature values from a plurality of working temperature ranges, and obtain a plurality of sets of frequency deviation values corresponding to the plurality of sets of preset temperature values, where one working temperature range corresponds to a set of preset temperature values, and one set of preset temperature values corresponds to a set of frequency deviation values;
the determining unit is further configured to determine a plurality of frequency deviation functions corresponding to the plurality of working temperature ranges by using the plurality of sets of preset temperature values and the plurality of sets of frequency deviation values, where one working temperature range in the plurality of working temperature ranges corresponds to one frequency deviation function; and obtaining the corresponding relation between the preset temperature range and the frequency deviation function according to the working temperature ranges and the frequency deviation functions.
In the above terminal, the determining unit is further configured to determine a first temperature when the frequency compensation is performed in a previous round; determining a temperature change trend according to the first temperature and the current temperature; determining a plurality of temperature intervals corresponding to a plurality of working temperature ranges according to the temperature change trend; when the current temperature is in a first temperature interval of the plurality of temperature intervals, judging that the current temperature is in the first working temperature range corresponding to the first temperature interval.
In the above terminal, the terminal further includes: dividing units;
the determining unit is further configured to determine a plurality of temperature switching values between the plurality of working temperature ranges according to the temperature variation trend, where one temperature switching value corresponds to each two working temperature ranges in the plurality of working temperature ranges;
the dividing unit is used for dividing the working temperature ranges into the temperature intervals according to the temperature switching values.
In the above terminal, the obtaining unit is further configured to obtain a generated signal frequency at a first preset temperature value, where the first preset temperature is any preset temperature value of the multiple sets of preset temperature values; until the multiple groups of frequency deviation values corresponding to the multiple groups of preset temperature values are obtained;
the determining unit is further configured to determine a difference between the generated signal frequency and a standard signal frequency corresponding to the first preset temperature value as a first frequency deviation value corresponding to the first preset temperature value.
In the above terminal, the terminal further includes: a parameter fitting unit;
the parameter fitting unit is configured to perform parameter fitting on a plurality of preset frequency deviation functions based on the plurality of preset temperature values and the plurality of frequency deviation values, so as to obtain a plurality of frequency deviation functions corresponding to the plurality of preset frequency deviation functions, where one preset frequency deviation function in the plurality of preset frequency deviation functions corresponds to one frequency deviation function.
The embodiment of the application provides a terminal, which comprises: a processor, a memory, and a communication bus; the processor, when executing a memory-stored operating program, implements a method as described in any one of the preceding claims.
The embodiment of the application provides a storage medium, on which a computer program is stored, applied to a terminal, the computer program implementing the method according to any one of the above when being executed by a processor.
The embodiment of the application provides a frequency compensation method, a terminal and a storage medium, wherein the method comprises the following steps: determining the current temperature of the frequency deviation to be compensated; when the current temperature is in the first working temperature range, searching a first frequency deviation function corresponding to the first working temperature range from the corresponding relation between the preset temperature range and the frequency deviation function; and performing frequency compensation on the frequency deviation to be compensated by using the first frequency deviation function. By adopting the implementation scheme, the terminal sets different preset frequency deviation functions for different working temperature ranges, performs parameter fitting on the corresponding preset frequency deviation functions based on different preset temperature values and frequency deviation values respectively to obtain the frequency deviation functions corresponding to different working temperature ranges, and searches for a first frequency deviation function corresponding to the first working temperature range from the corresponding relation of the preset temperature range and the frequency deviation function when judging that the current temperature for obtaining the frequency deviation to be compensated is in the first working temperature range, performs frequency compensation according to the first frequency deviation function, and further reduces the influence of frequency compensation parameters of other working temperature ranges on the first frequency deviation function, and reduces the frequency deviation in the working range and the positioning error of GNSS.
Drawings
FIG. 1 is a schematic diagram of sampling frequency offset values and temperature values in the prior art;
fig. 2 is a schematic flow chart of a frequency compensation method according to an embodiment of the present application;
fig. 3 is a schematic diagram of temperature switching values corresponding to an exemplary trend of temperature change from low temperature to high temperature according to an embodiment of the present application;
fig. 4 is a schematic diagram of temperature switching values corresponding to an exemplary trend of temperature change from high temperature to low temperature according to an embodiment of the present application;
FIG. 5 is a schematic diagram of an exemplary acquisition of multiple sets of frequency offset values according to an embodiment of the present application;
fig. 6 is a schematic structural diagram of a terminal according to an embodiment of the present application;
fig. 7 is a schematic structural diagram of a second terminal according to an embodiment of the present application.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the application. And are not intended to limit the present application.
It should be noted that the temperature-frequency deviation characteristic of the crystal oscillator is generally expressed in the form of a unitary cubic equation, and a predetermined frequency deviation function can be determined, as shown in the following formula (1):
f(t)=C3×(t-t 0 ) 3 +C2×(t-t 0 )2+C1×(t-t 0 )+C0 (1)
wherein f (t) is the frequency deviation value of the crystal oscillator at the temperature value t, and C3, C2, C1 and C0 are parameters of a preset frequency deviation function,t 0 Is a preset temperature constant.
It will be appreciated that in the prior art, specific values of C3, C2, C1 and C0 in the preset frequency deviation function can be determined by collecting frequency deviation values at several temperatures, so that the frequency deviation values at different temperatures can be determined by using the function to compensate.
It should be noted that, in the production line calibration and application scenario under normal conditions, the temperature of the crystal oscillator is concentrated in the normal temperature section (20 ℃ to 40 ℃) and the high temperature section (more than 40 ℃), and is difficult to be below 0 ℃, and the current compensation scheme is that, first, the test temperature t=t 0 F (t) at time 0 ) Calculating C0; setting C3 and C2 as fixed constants, wherein C2=0, testing the frequency deviation values of 2 temperature values near t0, substituting the frequency deviation values into formula (1) to calculate C1, specifically, controlling terminal equipment to work under maximum power, driving a crystal oscillator to heat up through working heating to form a certain temperature interval, and substituting the temperature values and the frequency deviation values at two ends of the sampling temperature interval into formula (1) to calculate the value of C1, wherein the temperature interval is usually 30-40 ℃ as shown in fig. 1; finally by collecting a plurality of distances t 0 The frequency deviation value of the farther temperature value, the actual values of C2 and C3 are calculated.
It should be noted that, in the prior art, the frequency deviation function is determined under the normal temperature environment to perform frequency compensation, the frequency deviation of the crystal oscillator is better in the section of 20 ℃ to 50 ℃, and is usually within 0.5ppm, but the frequency deviation after compensation is quite large, usually more than 1ppm, and even more than 3ppm in the temperature range of-20 ℃ to 0 ℃.
In order to reduce the frequency deviation of the crystal oscillator in each temperature interval, the present scheme is proposed, and the following specific description is given by way of examples.
Example 1
An embodiment of the present application provides a frequency compensation method, as shown in fig. 2, the method may include:
s101, determining the current temperature of the frequency deviation to be compensated.
The frequency compensation method provided by the embodiment of the application is suitable for the scene of frequency calibration of the clock frequency of the terminal equipment.
In the embodiment of the application, when the crystal oscillator of the terminal generates the signal frequency, the terminal subtracts the received signal frequency generated by the base station from the signal frequency generated by the crystal oscillator to obtain the frequency deviation to be compensated, wherein the base station carries the signal frequency of the base station when transmitting; when the terminal acquires the frequency deviation to be compensated, determining the current temperature when the frequency deviation to be compensated is acquired.
S102, when the current temperature is in the first working temperature range, searching a first frequency deviation function corresponding to the first working temperature range from the corresponding relation between the preset temperature range and the frequency deviation function.
When the terminal determines that the current temperature is in the first working temperature range after the current temperature is obtained when the frequency deviation to be compensated is obtained, the terminal searches a first frequency deviation function corresponding to the first working temperature range from the corresponding relation between the preset temperature range and the frequency deviation function.
In the embodiment of the present application, a preset temperature range and a frequency deviation function correspondence relation is preset in the terminal, correspondence relation between a plurality of working temperature ranges and a plurality of frequency deviation functions is stored in the terminal, the terminal compares a current temperature with a plurality of working temperature ranges in the preset temperature range and frequency deviation function correspondence relation, searches a first working temperature range where the current temperature is located, and then searches a first frequency deviation function corresponding to the first working temperature range from the preset temperature range and frequency deviation function correspondence relation.
In this embodiment of the present application, in a correspondence between a preset temperature range and a frequency deviation function, a terminal needs to search a working temperature range including a current temperature when searching for a first frequency deviation function terminal corresponding to a first working temperature range, and a specific execution process is: the terminal determines a first temperature when the frequency compensation is carried out in the last round; then, the terminal determines a temperature change trend according to the first temperature and the current temperature; the terminal determines a plurality of temperature intervals corresponding to a plurality of working temperature ranges according to the temperature change trend; and when the terminal judges that the current temperature is in a first temperature interval in the plurality of temperature intervals, the terminal judges that the current temperature is in a first working temperature range corresponding to the first temperature interval.
In the embodiment of the present application, the temperature change trend may include: the temperature changes from high to low and the temperature changes from low to high, and the temperature is specifically selected according to practical situations, and the embodiment of the application is not specifically limited.
In this embodiment, according to the temperature change trend, the process of determining a plurality of temperature intervals corresponding to a plurality of working temperature ranges by the terminal is: the terminal determines a plurality of temperature switching values among a plurality of working temperature ranges according to the temperature change trend, wherein one temperature switching value corresponds to each two working temperature ranges among the plurality of working temperature ranges; and then, the terminal divides the working temperature ranges into a plurality of temperature intervals according to the temperature switching values.
For the temperature change trend from low temperature to high temperature, the temperature switching value is shown in figure 3, wherein the temperature switching value between the limiting temperature section of-30 ℃ to 0 ℃ and the intermediate temperature section of-5 ℃ to 15 ℃ is 0 ℃, namely the temperature interval corresponding to the limiting temperature section is-30 ℃ to 0 ℃, and the temperature interval corresponding to the intermediate temperature section is 0 ℃ to 15 ℃; the temperature switching value between the intermediate temperature section of-5 ℃ to 15 ℃ and the normal temperature section of 10 ℃ to 30 ℃ is 15 ℃, namely the temperature section corresponding to the normal temperature section is 15 ℃ to 30 ℃; the temperature switching value between the normal temperature section of 10 ℃ to 30 ℃ and the intermediate temperature section of 25 ℃ to 45 ℃ is 30 ℃, namely the temperature interval corresponding to the intermediate temperature section is 30 ℃ to 45 ℃; the temperature switching value between the intermediate temperature section of 25-45 ℃ and the limit temperature section of 40-60 ℃ is 45 ℃, namely the temperature section corresponding to the limit temperature section is 45-60 ℃.
For the trend of temperature change from high temperature to low temperature, the temperature switching value is shown in fig. 4, wherein the temperature switching value between a limit temperature section of 40 ℃ to 60 ℃ and an intermediate temperature section of 25 ℃ to 45 ℃ is 40 ℃, namely the temperature interval corresponding to the limit temperature section is 40 ℃ to 60 ℃, and the temperature interval corresponding to the intermediate temperature section is 25 ℃ to 40 ℃; the temperature switching value between the intermediate temperature section of 25-45 ℃ and the normal temperature section of 10-30 ℃ is 25 ℃, namely the temperature section corresponding to the normal temperature section is 10-25 ℃; the temperature switching value between the normal temperature section of 10 ℃ to 30 ℃ and the intermediate temperature section of-5 ℃ to 15 ℃ is 10 ℃, namely the temperature interval corresponding to the intermediate temperature section is-5 ℃ to 10 ℃; the temperature switching value between the intermediate temperature section of-5 ℃ to 15 ℃ and the limit temperature section of-30 ℃ to 0 ℃ is-5 ℃, namely the temperature section corresponding to the limit temperature section is-30 ℃ to 5 ℃.
S103, utilizing the first frequency deviation function to perform frequency compensation on the frequency deviation to be compensated.
And after the terminal finds a first frequency deviation function corresponding to the first working temperature range from the corresponding relation between the preset temperature range and the frequency deviation function, the terminal performs frequency compensation on the frequency deviation to be compensated by using the first frequency deviation function.
In the embodiment of the application, the terminal substitutes the current temperature into the first frequency deviation function to obtain the frequency compensation value corresponding to the current temperature, and then the terminal performs frequency compensation on the frequency deviation to be compensated by using the frequency compensation value, so that in the scene that the terminal realizes the GNSS positioning principle, the clock accuracy of the terminal equipment can be improved, and the positioning accuracy of the GNSS can be calibrated.
It can be understood that the terminal sets different preset frequency deviation functions for different working temperature ranges, performs parameter fitting on the corresponding preset frequency deviation functions based on different preset temperature values and frequency deviation values respectively to obtain frequency deviation functions corresponding to different working temperature ranges, and searches for a first frequency deviation function corresponding to the first working temperature range from the corresponding relation between the preset temperature range and the frequency deviation function when judging that the current temperature for obtaining the frequency deviation to be compensated is in the first working temperature range, performs frequency compensation according to the first frequency deviation function, and further reduces the influence of frequency compensation parameters of other working temperature ranges on the first frequency deviation function, and reduces the frequency deviation in the working range and the positioning error of GNSS.
Based on the first embodiment, in the embodiment of the present application, before determining that the current temperature of the frequency deviation to be compensated is obtained, that is, before step 101, the method for performing frequency compensation by the terminal may further include the following steps:
s104, respectively determining a plurality of groups of preset temperature values from a plurality of working temperature ranges, and obtaining a plurality of groups of frequency deviation values corresponding to the plurality of groups of preset temperature values, wherein one working temperature range corresponds to one group of preset temperature values, and one group of preset temperature values corresponds to one group of frequency deviation values.
In this embodiment, the terminal may determine, in advance, a preset temperature range of the crystal oscillator according to characteristics and manufacturing parameters of the crystal oscillator itself, where the preset temperature range may actually be a temperature range that can be reached in a working process of the crystal oscillator, divide the preset temperature range into a plurality of working temperature ranges, and determine a set of preset temperature values in each working temperature range, thereby determining a plurality of sets of preset temperature values from the plurality of working temperature ranges, and then, the terminal obtains a plurality of sets of frequency offset values corresponding to the plurality of sets of preset temperature values respectively.
The terminal is illustratively divided into three working temperature ranges, namely a normal temperature section (10 ℃ to 30 ℃), an intermediate temperature section (-5 ℃ to 15 ℃, 25 ℃ to 45 ℃) and a limit temperature section (-30 ℃ to 0 ℃,40 ℃ to 60 ℃), the terminal selects 10 ℃, 20 ℃, 30 ℃ as a set of preset temperature values determined in the normal temperature section, the terminal selects-5 ℃, 15 ℃, 25 ℃, 35 ℃, 45 ℃ as a set of preset temperature values determined in the intermediate temperature section, and the terminal selects-30 ℃, -20 ℃, -10 ℃, 0 ℃,40 ℃, 50 ℃, 60 ℃ as a set of preset temperature values determined in the limit temperature section.
It should be noted that, in order to ensure smooth switching of frequency compensation in three operating temperature ranges, overlapping intervals of about 5 ℃ are typically required for each two adjacent operating temperature ranges.
In this embodiment of the present application, the process of obtaining, by a terminal, a plurality of sets of frequency deviation values corresponding to a plurality of sets of preset temperature values is specifically: the terminal obtains the generated signal frequency at a first preset temperature value, wherein the first preset temperature is any preset temperature value in a plurality of groups of preset temperature values; and then, the terminal determines the difference between the generated signal frequency and the standard signal frequency corresponding to the first preset temperature value as a first frequency deviation value corresponding to the first preset temperature value, wherein the first frequency deviation value is a frequency deviation value corresponding to the first preset temperature value in a plurality of groups of frequency deviation values.
It should be noted that, in an ideal situation, the signal frequencies provided by the crystal oscillator at different operating temperatures should be standard signal frequencies, but in a practical application process, the signal frequencies provided by the crystal oscillator at different temperatures cannot actually reach the standard signal frequencies due to the influence of temperature, so that frequency compensation is required, and the specific standard signal frequencies are not limited in the embodiments of the present application.
Fig. 5 is a schematic diagram of an exemplary acquisition of multiple sets of frequency offset values according to an embodiment of the present application. As shown in fig. 5, the crystal oscillator is actually configured on a motherboard to be applied, the motherboard is placed in an incubator, and the working temperature of the crystal oscillator can be controlled by adjusting the temperature of the incubator, so as to obtain multiple groups of frequency deviation values.
S105, utilizing a plurality of groups of preset temperature values and a plurality of groups of frequency deviation values to respectively determine a plurality of frequency deviation functions corresponding to a plurality of working temperature ranges, wherein one working temperature range in the plurality of working temperature ranges corresponds to one frequency deviation function.
After the terminal determines a plurality of groups of preset temperature values from a plurality of working temperature ranges respectively and obtains a plurality of groups of frequency deviation values corresponding to the plurality of groups of preset temperature values, the terminal respectively determines a plurality of frequency deviation functions corresponding to the plurality of working temperature ranges by utilizing the plurality of groups of preset temperature values and the plurality of groups of frequency deviation values.
In this embodiment of the present application, the terminal performs parameter fitting on a plurality of preset frequency deviation functions based on a plurality of preset temperature values and a plurality of frequency deviation values, so as to obtain a plurality of frequency deviation functions corresponding to the plurality of preset frequency deviation functions, where one preset frequency deviation function in the plurality of preset frequency deviation functions corresponds to one frequency deviation function.
In this embodiment of the present application, different working temperature ranges correspond to different preset frequency deviation functions, each preset frequency deviation function includes a set of frequency compensation parameters, and the terminal performs parameter fitting on the preset frequency deviation functions based on a set of preset temperature values and a set of frequency deviation values corresponding to the set of preset temperature values, so as to fit a set of frequency compensation parameters corresponding to the preset frequency deviation functions, thereby obtaining a plurality of frequency deviation functions corresponding to the working temperature ranges.
Illustratively, the preset frequency deviation function corresponding to the normal temperature section is a unitary linear equation, as shown in formula (2),
f(t)=C1(t-t0)+C0 (2)
wherein, C1 and C0 are frequency compensation parameters corresponding to normal temperature section, f (t) represents frequency deviation value of the crystal oscillator when the temperature value is t, and t0 represents preset temperature constant.
Illustratively, the preset frequency deviation function corresponding to the intermediate temperature segment is a unitary quadratic equation, as shown in equation (3),
f(t)=C2(t-t0) 2 +C1(t-t0)+C0 (3)
wherein, C2, C1 and C0 are frequency compensation parameters corresponding to the intermediate temperature section, f (t) represents a frequency deviation value of the crystal oscillator when the temperature value is t, and t0 represents a preset temperature constant.
The preset frequency deviation function corresponding to the limiting temperature segment is illustratively a unitary cubic equation, as shown in equation (4),
f(t)=C3(t-t0) 3 +C2(t-t0) 2 +C1(t-t0)+C0 (4)
wherein C3, C2, C1 and C0 are frequency compensation parameters corresponding to the limit temperature section, f (t) represents a frequency deviation value of the crystal oscillator when the temperature value is t, and t0 represents a preset temperature constant.
It should be noted that, the specific values of C1 and C0 in the normal temperature section, the intermediate temperature section and the limit temperature section are determined together according to different preset frequency deviation functions, different working temperature ranges corresponding to the different preset frequency deviation functions, and different frequency deviation values corresponding to the different working temperature ranges, so that the specific values of C1 and C0 corresponding to the different working temperature ranges are different; as discussed above, the specific values of C2 in the intermediate temperature range and the extreme temperature range are also different.
S106, obtaining the corresponding relation between the preset temperature range and the frequency deviation function according to the working temperature ranges and the frequency deviation functions.
After the terminal respectively determines a plurality of frequency deviation functions corresponding to a plurality of working temperature ranges by utilizing a plurality of groups of preset temperature values and a plurality of groups of frequency deviation values, the terminal obtains the corresponding relation between the preset temperature ranges and the frequency deviation functions according to the plurality of working temperature ranges and the plurality of frequency deviation functions.
In this embodiment of the present application, a terminal adds a plurality of operating temperature intervals and a plurality of frequency deviation functions to a preset temperature range and frequency deviation function correspondence relationship, so as to determine different frequency deviation functions according to different operating temperature intervals during frequency compensation.
Example two
The embodiment of the present application provides a terminal 1, as shown in fig. 6, the terminal 1 may include:
a determining unit 10, configured to determine a current temperature at which a frequency deviation to be compensated is obtained;
an obtaining unit 11, configured to find a first frequency deviation function corresponding to a first operating temperature range from a preset temperature range and frequency deviation function correspondence when it is determined that the current temperature is in the first operating temperature range;
and the frequency compensation unit 12 is configured to perform frequency compensation on the frequency deviation to be compensated by using the first frequency deviation function.
Optionally, the obtaining unit 11 is further configured to determine a plurality of sets of preset temperature values from a plurality of working temperature ranges, and obtain a plurality of sets of frequency deviation values corresponding to the plurality of sets of preset temperature values, where one working temperature range corresponds to a set of preset temperature values, and one set of preset temperature values corresponds to a set of frequency deviation values;
the determining unit 10 is further configured to determine a plurality of frequency deviation functions corresponding to the plurality of operating temperature ranges by using the plurality of sets of preset temperature values and the plurality of sets of frequency deviation values, where one operating temperature range of the plurality of operating temperature ranges corresponds to one frequency deviation function; and obtaining the corresponding relation between the preset temperature range and the frequency deviation function according to the working temperature ranges and the frequency deviation functions.
Optionally, the determining unit 10 is further configured to determine a first temperature when the frequency compensation is performed in the previous round; determining a temperature change trend according to the first temperature and the current temperature; determining a plurality of temperature intervals corresponding to a plurality of working temperature ranges according to the temperature change trend; when the current temperature is in a first temperature interval of the plurality of temperature intervals, judging that the current temperature is in the first working temperature range corresponding to the first temperature interval.
Optionally, the terminal further includes: a dividing unit 13;
the determining unit 10 is further configured to determine a plurality of temperature switching values between the plurality of operating temperature ranges according to the temperature variation trend, where one temperature switching value corresponds to each two operating temperature ranges in the plurality of operating temperature ranges;
the dividing unit 13 is configured to divide the plurality of operating temperature ranges into the plurality of temperature intervals according to the plurality of temperature switching values.
Optionally, the acquiring unit 11 is further configured to acquire the generated signal frequency at a first preset temperature value, where the first preset temperature is any preset temperature value of the multiple sets of preset temperature values; until the multiple groups of frequency deviation values corresponding to the multiple groups of preset temperature values are obtained;
the determining unit 10 is further configured to determine a difference between the generated signal frequency and a standard signal frequency corresponding to the first preset temperature value as a first frequency deviation value corresponding to the first preset temperature value.
Optionally, the terminal further includes: a parameter fitting unit 14;
the parameter fitting unit 14 is configured to perform parameter fitting on a plurality of preset frequency deviation functions based on the plurality of preset temperature values and the plurality of frequency deviation values, so as to obtain the plurality of frequency deviation functions corresponding to the plurality of preset frequency deviation functions, where one preset frequency deviation function in the plurality of preset frequency deviation functions corresponds to one frequency deviation function.
The terminal provided by the embodiment of the application determines the current temperature of the frequency deviation to be compensated; when the current temperature is in the first working temperature range, searching a first frequency deviation function corresponding to the first working temperature range from the corresponding relation between the preset temperature range and the frequency deviation function; and performing frequency compensation on the frequency deviation to be compensated by using the first frequency deviation function. Therefore, the terminal provided in this embodiment sets different preset frequency deviation functions for different working temperature ranges, performs parameter fitting on corresponding preset frequency deviation functions based on different preset temperature values and frequency deviation values, and obtains the frequency deviation functions corresponding to different working temperature ranges, when the terminal determines that the current temperature for obtaining the frequency deviation to be compensated is in the first working temperature range, the terminal searches the first frequency deviation function corresponding to the first working temperature range from the corresponding relation between the preset temperature range and the frequency deviation function, performs frequency compensation according to the first frequency deviation function, and further reduces the influence of frequency compensation parameters of other working temperature ranges on the first frequency deviation function, and reduces the frequency deviation in the working range and the positioning error of the GNSS.
Fig. 7 is a schematic diagram of a second component structure of a terminal 1 according to the embodiment of the present application, in practical application, based on the same disclosure concept of the above embodiment, as shown in fig. 7, the terminal 1 of the present embodiment includes: a processor 15, a memory 16 and a communication bus 17.
In a specific embodiment, the determining unit 10, the acquiring unit 11, the frequency compensating unit 12, the dividing unit 13 and the parameter fitting unit 14 may be implemented by a processor 15 located on the terminal 1, where the processor 15 may be at least one of an application specific integrated circuit (ASIC, application Specific Integrated Circuit), a digital signal processor (DSP, digital Signal Processor), a digital signal processing device (DSPD, digital Signal Processing Device), a programmable logic device (PLD, programmable Logic Device), a field programmable gate array (FPGA, field Programmable Gate Array), a CPU, a controller, a microcontroller, and a microprocessor. It will be appreciated that the electronics for implementing the above-described processor functions may be other for different devices, and the present embodiment is not particularly limited.
In the embodiment of the present application, the above-mentioned communication bus 17 is used to implement connection communication between the processor 15 and the memory 16; the processor 15 implements the frequency compensation method according to the first embodiment when executing the running program stored in the memory 16.
The embodiment of the application provides a storage medium, on which a computer program is stored, where the computer readable storage medium stores one or more programs, where the one or more programs are executable by one or more processors and applied to a terminal, and the computer program implements the frequency compensation method according to the embodiment one.
The foregoing description is only of the preferred embodiments of the present application and is not intended to limit the scope of the present application.

Claims (10)

1. A method of frequency compensation, the method comprising:
determining the current temperature of the frequency deviation to be compensated;
determining a first temperature when the frequency compensation is carried out in the previous round;
determining a temperature change trend according to the first temperature and the current temperature;
determining a plurality of temperature switching values among a plurality of working temperature ranges according to the temperature change trend, wherein one temperature switching value corresponds to each two working temperature ranges among the plurality of working temperature ranges;
dividing the working temperature ranges into temperature intervals according to the temperature switching values;
when the current temperature is in a first temperature interval of the plurality of temperature intervals, judging that the current temperature is in a first working temperature range corresponding to the first temperature interval;
when the current temperature is in a first working temperature range, searching a first frequency deviation function corresponding to the first working temperature range from the corresponding relation between a preset temperature range and the frequency deviation function;
and carrying out frequency compensation on the frequency deviation to be compensated by utilizing the first frequency deviation function.
2. The method of claim 1, wherein the determining obtains a current temperature of the frequency deviation to be compensated, the method further comprising:
determining a plurality of groups of preset temperature values from a plurality of working temperature ranges respectively, and acquiring a plurality of groups of frequency deviation values corresponding to the plurality of groups of preset temperature values, wherein one working temperature range corresponds to one group of preset temperature values, and one group of preset temperature values corresponds to one group of frequency deviation values;
respectively determining a plurality of frequency deviation functions corresponding to a plurality of working temperature ranges by utilizing the plurality of groups of preset temperature values and the plurality of groups of frequency deviation values, wherein one working temperature range in the plurality of working temperature ranges corresponds to one frequency deviation function;
and obtaining the corresponding relation between the preset temperature range and the frequency deviation function according to the working temperature ranges and the frequency deviation functions.
3. The method according to claim 2, wherein the obtaining a plurality of sets of frequency deviation values corresponding to the plurality of sets of preset temperature values includes:
acquiring the generated signal frequency at a first preset temperature value, wherein the first preset temperature is any preset temperature value in the plurality of groups of preset temperature values;
determining the difference between the generated signal frequency and the standard signal frequency corresponding to the first preset temperature value as a first frequency deviation value corresponding to the first preset temperature value;
until the multiple groups of frequency deviation values corresponding to the multiple groups of preset temperature values are obtained.
4. The method of claim 2, wherein determining a plurality of frequency deviation functions corresponding to the plurality of operating temperature ranges using the plurality of sets of preset temperature values and the plurality of sets of frequency deviation values, respectively, comprises:
and performing parameter fitting on a plurality of preset frequency deviation functions based on the plurality of preset temperature values and the plurality of frequency deviation values respectively to obtain a plurality of frequency deviation functions corresponding to the plurality of preset frequency deviation functions, wherein one preset frequency deviation function in the plurality of preset frequency deviation functions corresponds to one frequency deviation function.
5. A terminal, the terminal comprising:
the determining unit is used for determining the current temperature of the frequency deviation to be compensated;
the determining unit is further used for determining a first temperature when the frequency compensation is performed in the previous round; determining a temperature change trend according to the first temperature and the current temperature; determining a plurality of temperature switching values among a plurality of working temperature ranges according to the temperature change trend, wherein one temperature switching value corresponds to each two working temperature ranges among the plurality of working temperature ranges;
the dividing unit is used for dividing the working temperature ranges into a plurality of temperature intervals according to the temperature switching values;
the determining unit is further configured to determine that the current temperature is in a first working temperature range corresponding to a first temperature interval when the current temperature is in the first temperature interval of the plurality of temperature intervals;
the acquisition unit is used for searching a first frequency deviation function corresponding to a first working temperature range from the corresponding relation between a preset temperature range and the frequency deviation function when the current temperature is judged to be in the first working temperature range;
and the frequency compensation unit is used for carrying out frequency compensation on the frequency deviation to be compensated by utilizing the first frequency deviation function.
6. The terminal of claim 5, wherein the terminal comprises a base station,
the acquisition unit is further used for determining a plurality of groups of preset temperature values from a plurality of working temperature ranges respectively, and acquiring a plurality of groups of frequency deviation values corresponding to the plurality of groups of preset temperature values, wherein one working temperature range corresponds to one group of preset temperature values, and one group of preset temperature values corresponds to one group of frequency deviation values;
the determining unit is further configured to determine a plurality of frequency deviation functions corresponding to the plurality of working temperature ranges by using the plurality of sets of preset temperature values and the plurality of sets of frequency deviation values, where one working temperature range in the plurality of working temperature ranges corresponds to one frequency deviation function; and obtaining the corresponding relation between the preset temperature range and the frequency deviation function according to the working temperature ranges and the frequency deviation functions.
7. The terminal of claim 6, wherein the terminal comprises a base station,
the acquisition unit is further used for acquiring the generated signal frequency at a first preset temperature value, wherein the first preset temperature is any preset temperature value in the plurality of groups of preset temperature values; until the multiple groups of frequency deviation values corresponding to the multiple groups of preset temperature values are obtained;
the determining unit is further configured to determine a difference between the generated signal frequency and a standard signal frequency corresponding to the first preset temperature value as a first frequency deviation value corresponding to the first preset temperature value.
8. The terminal of claim 6, wherein the terminal further comprises: a parameter fitting unit;
the parameter fitting unit is configured to perform parameter fitting on a plurality of preset frequency deviation functions based on the plurality of preset temperature values and the plurality of frequency deviation values, so as to obtain a plurality of frequency deviation functions corresponding to the plurality of preset frequency deviation functions, where one preset frequency deviation function in the plurality of preset frequency deviation functions corresponds to one frequency deviation function.
9. A terminal, the terminal comprising: a processor, a memory, and a communication bus; the processor, when executing a memory-stored operating program, implements the method of any one of claims 1-4.
10. A storage medium having stored thereon a computer program for application to a terminal, which computer program, when executed by a processor, implements the method according to any of claims 1-4.
CN201910551114.8A 2019-06-24 2019-06-24 Frequency compensation method, terminal and storage medium Active CN110336557B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910551114.8A CN110336557B (en) 2019-06-24 2019-06-24 Frequency compensation method, terminal and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910551114.8A CN110336557B (en) 2019-06-24 2019-06-24 Frequency compensation method, terminal and storage medium

Publications (2)

Publication Number Publication Date
CN110336557A CN110336557A (en) 2019-10-15
CN110336557B true CN110336557B (en) 2023-05-30

Family

ID=68142579

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910551114.8A Active CN110336557B (en) 2019-06-24 2019-06-24 Frequency compensation method, terminal and storage medium

Country Status (1)

Country Link
CN (1) CN110336557B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112261670B (en) * 2020-10-15 2023-04-07 锐迪科(重庆)微电子科技有限公司 Method and device for determining frequency deviation

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104702214A (en) * 2014-12-30 2015-06-10 广东大普通信技术有限公司 Crystal oscillator frequency compensation method
CN106301224A (en) * 2016-08-15 2017-01-04 成都菁汇科技有限公司 A kind of crystal oscillator automatic temperature compensation system

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8373515B2 (en) * 2010-02-10 2013-02-12 Maxlinear, Inc. TCXO replacement for GPS
CN107465393B (en) * 2017-07-05 2020-12-01 广州昂宝电子有限公司 System and method for frequency compensation of real time clock system

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104702214A (en) * 2014-12-30 2015-06-10 广东大普通信技术有限公司 Crystal oscillator frequency compensation method
CN106301224A (en) * 2016-08-15 2017-01-04 成都菁汇科技有限公司 A kind of crystal oscillator automatic temperature compensation system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
一种高精度温度补偿型实时钟电路;陈富涛;《电子与封装》;20161220(第12期);全文 *

Also Published As

Publication number Publication date
CN110336557A (en) 2019-10-15

Similar Documents

Publication Publication Date Title
CN110311673B (en) Frequency calibration method, terminal and storage medium
CN103001583B (en) Temperature compensation and crystal oscillator
US8497717B2 (en) Reference frequency generating device
US7791419B1 (en) Timing calibration for crystal oscillators within a mesh network
CN106569544B (en) Real-time timepiece chip and its clock correcting method, device
CN102185663B (en) Frequency calibration method and device
CN110336557B (en) Frequency compensation method, terminal and storage medium
EP4207671A1 (en) Clock calibration method, clock calibration apparatus, electronic device, and readable medium
EP2371063B1 (en) Frequency reference correction for temperature-frequency hysteresis error
US7253767B1 (en) Flat model software compensated crystal oscillator for GPS receiver
CN113114108A (en) Method for estimating crystal oscillator frequency
CN101488752B (en) Temperature frequency correcting apparatus
JP2010088071A (en) Reference signal generating device
CN111045317B (en) Calibration method, device and system of equipment clock, self-calibration method and equipment
CN111045318B (en) Calibration method, device and system of equipment clock, self-calibration method and equipment
CN101488751B (en) Measurement system and method for temperature frequency correcting apparatus
CN110212911B (en) Frequency calibration method and device and storage medium
CN101388646B (en) Successive approximation temperature and frequency correcting method and device
KR102038814B1 (en) Impedance estimating apparatus
CN111026232A (en) Clock calibration method, chip and electronic equipment
CN112019317B (en) Frequency calibration method and device, storage medium and electronic device
CN115856793A (en) Radar signal frequency deviation estimation compensation method
CN110830033B (en) Clock frequency compensation method and system for GNSS system, storage medium and terminal
CN201515347U (en) Temperature frequency correcting device
CN105143912A (en) Radar device

Legal Events

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